ExportingMenu

Type class

Displays a menu for Exporting.

Click here for more info

Sources

ExportingMenu can be used (imported) via one of the following packages.

// Import ExportingMenu
import * as am5plugins_exporting from "@amcharts/amcharts5/plugins/exporting";

am5plugins_exporting.ExportingMenu.new(root, {
  // ... config if applicable
});
<!-- Load ExportingMenu -->
<script src="plugins/exporting.js">

<script>
// Create ExportingMenu
am5plugins_exporting.ExportingMenu.new(root, {
  // ... config if applicable
});
</script>

Inheritance

ExportingMenu extends Entity.

ExportingMenu is not extended by any other symbol.

Settings

Set these settings on a ExportingMenu object using its set() and setAll() methods.

Read about settings concept.

align
#

Type "left" | "right"

Default "right"

Horizontal alignment of the menu.

autoClose
#

Type undefined | false | true

Default true

If set to true the menu will close automatically when export operation is initiated.

container
#

Type HTMLElement

A reference to an element in the document to place export menu in.

If not set, will use root element's container.

deactivateRoot
#

Type undefined | false | true

Default true

Menu will disable all interactions for the underlying chart when browsing the menu.

exporting
#

Type Exporting

A reference to related Exporting object.

id
#

Type undefined | string

Inherited from IEntitySettings

A custom string ID for the element.

If set, element can be looked up via am5.registry.entitiesById.

Will raise error if an element with the same ID already exists.

items
#

Type IExportingMenuItem[]

A list of menu items.

stateAnimationDuration
#

Type undefined | number

Inherited from IEntitySettings

Duration of transition from one state to another.

stateAnimationEasing
#

Type $ease.Easing

Inherited from IEntitySettings

Easing of transition from one state to another.

themeTags
#

Type Array

Inherited from IEntitySettings

Tags which can be used by the theme rules.

Click here for more info

themeTagsSelf
#

Type Array

Inherited from IEntitySettings

Tags which can be used by the theme rules.

These tags only apply to this object, not any children.

Click here for more info

themes
#

Type Array

Inherited from IEntitySettings

A list of themes applied to the element.

useDefaultCSS
#

Type undefined | false | true

Default true

If set to false the legend will not load default CSS.

userData
#

Type any

Inherited from IEntitySettings

A storage for any custom user data that needs to be associated with the element.

valign
#

Type "top" | "bottom"

Default "top"

Vertical alignment of the menu.

There are 7 inherited items currently hidden from this list.

Private settings

These are read-only settings accessible from a ExportingMenu object using its getPrivate() method.

Read about private settings.

listElement
#

Read only

Type HTMLUListElement

A top-level <ul> element containing menu items.

menuElement
#

Read only

Type HTMLDivElement

A <div> element that acts as a container for other menu elements.

Properties

adapters
#

Type Adapters

Default new Adapters(this)

Inherited from Entity

className
#

Static

Type string

Default "ExportingMenu"

classNames
#

Static

Type Array

Default "ExportingMenu", "Entity"

events
#

Type EventDispatcher

Default this._createEvents()

Inherited from Entity

isOpen
#

Type boolean

Default false

root
#

Type Root

Inherited from Entity

An instance of Root object.

@readonly
@since 5.0.6

states
#

Type States

Default new States(this)

Inherited from Entity

template
#

Type Template | undefined

Inherited from Entity

@todo needs description

uid
#

Type number

Default ++counter

Inherited from Settings

Unique ID.

There are 6 inherited items currently hidden from this list.

Methods

animate(

options: AnimationOptions

)

#

Returns Animation

Inherited from Settings

Animates setting values from current/start values to new ones.

Click here for more info

close()

#

Returns void

Closes menu.

dispose()

#

Returns void

Inherited from Settings

Disposes this object.

get(

key: Key,
fallback: F

)

#

Returns NonNullable | F

Inherited from Entity

Returns settings value for the specified key.

If there is no value, fallback is returned instead (if set).

Click here for more info

isDisposed()

#

Returns boolean

Inherited from Settings

Returns true if this element is disposed.

isType(

type: string

)

#

Returns this

Inherited from Entity

Checks if element is of certain class (or inherits one).

new(

root: Root,
settings: ITSettings,
template?: Template

)

#

Static

Returns T

Inherited from Entity

Use this method to create an instance of this class.

Click here for more info

on(

key: Key,
callback: ( value: [""], target: this, key: Key) => void

)

#

Returns IDisposer

Inherited from Settings

Sets a callback function to invoke when specific key of settings changes or is set.

Click here for more info

open()

#

Returns void

Opens menu.

remove(

key: Key

)

#

Returns void

Inherited from Entity

Removes a setting value for the specified key.

Click here for more info

removeAll()

#

Returns void

Inherited from Settings

Removes all keys;

Click here for more info

set(

key: Key,
value: Value

)

#

Returns Value

Inherited from Entity

Sets a setting value for the specified key, and returns the same value.

Click here for more info

setAll(

settings: Partial

)

#

Returns void

Inherited from Settings

Sets multiple settings at once.

settings must be an object with key: value pairs.

Click here for more info

setTimeout(

fn: () => void,
delay: number

)

#

Returns IDisposer

Inherited from Entity

Creates and returns a "disposable" timeout.

toggle()

#

Returns void

Toggles menu open and close.

There are 12 inherited items currently hidden from this list.

Events

Add event handlers to ExportingMenu object using its events.on() method.

Read about adding event handlers.

#menuclosed

Param { type: "menuclosed",
  target: this }

#menucreated

Param { type: "menucreated",
  target: this }

#menuopened

Param { type: "menuopened",
  target: this }