import "@arcgis/charts-components/components/arcgis-charts-action-bar";
The ArcGIS charts action bar component enhances chart functionality by offering context-specific actions such as rotation, zooming, and filtering. It also supports general actions like exporting the chart as an image or CSV. This component is designed to be used with a chart component and is not intended for standalone use.
See also:
Demo
Properties
Property | Attribute | Type |
---|---|---|
action-bar-selection-mode | "monoSelection" | "multiSelection" | "multiSelectionWithCtrlKey" | |
| ||
chart-type | "barSeries" | "boxPlotSeries" | "comboLineAndBarSeries" | "gaugeSeries" | "histogramSeries" | "lineSeries" | "pieSeries" | "radarSeries" | "scatterSeries" | |
clear-selection-state | "disabled" | "enabled" | |
clear-selection-title | string | |
clear-selection-toggle | "active" | "inactive" | |
| Array<"number" | "cursorCrosshair" | "chartText" | "category" | "date" | "chartAxis" | "chartLegend" | "chartOverlay" | "sizeScale" | "chartOverlays" | "scatterSeries" | "chart" | "gaugeAxisTick" | "gaugeNeedle" | "chartGuide" | "pieSeries" | "pieTick" | "gaugeSeries" | "lineSeries" | "barSeries" | "histogramSeries" | "boxPlotSeries" | "radarSeries" | "comboLineAndBarSeries" | "buffer"> | |
disabled-export-action | boolean | |
edit-chart-state | "disabled" | "enabled" | |
edit-chart-title | string | |
edit-chart-toggle | "active" | "inactive" | |
expanded | boolean | |
export-as-csv-state | "disabled" | "enabled" | |
export-as-csv-title | string | |
export-as-image-state | "disabled" | "enabled" | |
export-as-image-title | string | |
filter-by-extent-state | "disabled" | "enabled" | |
filter-by-extent-title | string | |
filter-by-extent-toggle | "active" | "inactive" | |
filter-by-selection-state | "disabled" | "enabled" | |
filter-by-selection-title | string | |
filter-by-selection-toggle | "active" | "inactive" | |
force-disable-actions | boolean | |
full-extent-state | "disabled" | "enabled" | |
full-extent-title | string | |
full-extent-toggle | "active" | "inactive" | |
| Array<"zoom" | "legend" | "fullExtent" | "filterBySelection" | "filterByExtent" | "rotateChart" | "selection" | "clearSelection" | "switchSelection" | "editChart" | "exportAsImage" | "exportAsCSV"> | |
legend-state | "disabled" | "enabled" | |
legend-title | string | |
legend-toggle | "active" | "inactive" | |
| Record<string, unknown> | |
rotate-chart-state | "disabled" | "enabled" | |
rotate-chart-title | string | |
rotate-chart-toggle | "active" | "inactive" | |
selection-state | "disabled" | "enabled" | |
selection-title | string | |
selection-toggle | "active" | "inactive" | |
switch-selection-state | "disabled" | "enabled" | |
switch-selection-title | string | |
switch-selection-toggle | "active" | "inactive" | |
zoom-state | "disabled" | "enabled" | |
zoom-title | string | |
zoom-toggle | "active" | "inactive" |
actionBarSelectionMode
actionBarSelectionMode: "monoSelection" | "multiSelection" | "multiSelectionWithCtrlKey"
Action bar selection mode. Defines which selection mode the slotted action bar should use.
- Attribute
- action-bar-selection-mode
- Default value
- "multiSelectionWithCtrlKey"
chartElement
chartElement: HTMLArcgisChartElement
Chart element reference with which the action bar is associated.
- Default value
- undefined
chartType
chartType: "barSeries" | "boxPlotSeries" | "comboLineAndBarSeries" | "gaugeSeries" | "histogramSeries" | "lineSeries" | "pieSeries" | "radarSeries" | "scatterSeries"
Chart type used to determine which default actions to display.
- Attribute
- chart-type
- Default value
- undefined
clearSelectionState
clearSelectionState: "disabled" | "enabled"
When disabled, interaction with the clear selection action is prevented and the component is displayed with lower opacity.
- Attribute
- clear-selection-state
- Default value
- "enabled"
clearSelectionTitle
clearSelectionTitle: string
Custom title for the clear selection action.
- Attribute
- clear-selection-title
- Default value
- undefined
clearSelectionToggle
clearSelectionToggle: "active" | "inactive"
When active, the clear selection action is highlighted.
- Attribute
- clear-selection-toggle
- Default value
- "inactive"
disableCSVExportForChartTypes
disableCSVExportForChartTypes: Array<"number" | "cursorCrosshair" | "chartText" | "category" | "date" | "chartAxis" | "chartLegend" | "chartOverlay" | "sizeScale" | "chartOverlays" | "scatterSeries" | "chart" | "gaugeAxisTick" | "gaugeNeedle" | "chartGuide" | "pieSeries" | "pieTick" | "gaugeSeries" | "lineSeries" | "barSeries" | "histogramSeries" | "boxPlotSeries" | "radarSeries" | "comboLineAndBarSeries" | "buffer">
The CSV export action is disabled for certain chart types.
Modify this property to add or remove chart types from the list of disabled types.
- Default value
- [WebChartTypes.ScatterSeries, WebChartTypes.BoxPlotSeries]
disabledExportAction
disabledExportAction: boolean
When true
, the export action is disabled.
- Attribute
- disabled-export-action
- Default value
- false
editChartState
editChartState: "disabled" | "enabled"
When disabled, interaction with the edit chart action is prevented and the component is displayed with lower opacity.
- Attribute
- edit-chart-state
- Default value
- "disabled"
editChartTitle
editChartTitle: string
Custom title for the edit chart action.
- Attribute
- edit-chart-title
- Default value
- undefined
editChartToggle
editChartToggle: "active" | "inactive"
When active, the edit chart action is highlighted.
- Attribute
- edit-chart-toggle
- Default value
- "inactive"
exportAsCSVState
exportAsCSVState: "disabled" | "enabled"
When disabled, interaction with the download CSV is prevented and the component is displayed with lower opacity.
- Attribute
- export-as-csv-state
- Default value
- "enabled"
exportAsCSVTitle
exportAsCSVTitle: string
Custom title for the download CSV action.
- Attribute
- export-as-csv-title
- Default value
- undefined
exportAsImageState
exportAsImageState: "disabled" | "enabled"
When disabled, interaction with the download image is prevented and the component is displayed with lower opacity.
- Attribute
- export-as-image-state
- Default value
- "enabled"
exportAsImageTitle
exportAsImageTitle: string
Custom title for the download chart action.
- Attribute
- export-as-image-title
- Default value
- undefined
filterByExtentState
filterByExtentState: "disabled" | "enabled"
When disabled, interaction with the filter by extent action is prevented and the component is displayed with lower opacity.
- Attribute
- filter-by-extent-state
- Default value
- "enabled"
filterByExtentTitle
filterByExtentTitle: string
Custom title for the filter by extent action.
- Attribute
- filter-by-extent-title
- Default value
- undefined
filterByExtentToggle
filterByExtentToggle: "active" | "inactive"
When active, the filter by extent action is highlighted.
- Attribute
- filter-by-extent-toggle
- Default value
- "inactive"
filterBySelectionState
filterBySelectionState: "disabled" | "enabled"
When disabled, interaction with the filter by selection action is prevented and the component is displayed with lower opacity.
- Attribute
- filter-by-selection-state
- Default value
- "enabled"
filterBySelectionTitle
filterBySelectionTitle: string
Custom title for the filter by selection action.
- Attribute
- filter-by-selection-title
- Default value
- undefined
filterBySelectionToggle
filterBySelectionToggle: "active" | "inactive"
When active, the filter by selection action is highlighted.
- Attribute
- filter-by-selection-toggle
- Default value
- "inactive"
forceDisableActions
forceDisableActions: boolean
When true
, overrides the individual settings for each action to instead force disable them all.
- Attribute
- force-disable-actions
- Default value
- false
fullExtentState
fullExtentState: "disabled" | "enabled"
When disabled, interaction with the full extent action is prevented and the component is displayed with lower opacity.
- Attribute
- full-extent-state
- Default value
- "enabled"
fullExtentTitle
fullExtentTitle: string
Custom title for the full extent action.
- Attribute
- full-extent-title
- Default value
- undefined
fullExtentToggle
fullExtentToggle: "active" | "inactive"
When active, the full extent action is highlighted.
- Attribute
- full-extent-toggle
- Default value
- "inactive"
hiddenActions
hiddenActions: Array<"zoom" | "legend" | "fullExtent" | "filterBySelection" | "filterByExtent" | "rotateChart" | "selection" | "clearSelection" | "switchSelection" | "editChart" | "exportAsImage" | "exportAsCSV">
Holds a list of actions to hide from the action bar.
Note: The edit chart action is hidden by default. To show it, remove its value from this array.
- Default value
- ["editChart"]
legendState
legendState: "disabled" | "enabled"
When disabled, interaction with the legend action is prevented and the component is displayed with lower opacity.
- Attribute
- legend-state
- Default value
- "enabled"
legendTitle
legendTitle: string
Custom title for the legend action.
- Attribute
- legend-title
- Default value
- undefined
legendToggle
legendToggle: "active" | "inactive"
When active, the legend action is highlighted.
- Attribute
- legend-toggle
- Default value
- "inactive"
messageOverrides
messageOverrides: Record<string, unknown>
Overwrite localized strings for this component
rotateChartState
rotateChartState: "disabled" | "enabled"
When disabled, interaction with the rotate chart action is prevented and the component is displayed with lower opacity.
- Attribute
- rotate-chart-state
- Default value
- "enabled"
rotateChartTitle
rotateChartTitle: string
Custom title for the rotate chart action.
- Attribute
- rotate-chart-title
- Default value
- undefined
rotateChartToggle
rotateChartToggle: "active" | "inactive"
When active, the rotate chart action is highlighted.
- Attribute
- rotate-chart-toggle
- Default value
- "inactive"
selectionState
selectionState: "disabled" | "enabled"
When disabled, interaction with the selection action is prevented and the component is displayed with lower opacity.
- Attribute
- selection-state
- Default value
- "enabled"
selectionTitle
selectionTitle: string
Custom title for the selection action.
- Attribute
- selection-title
- Default value
- undefined
selectionToggle
selectionToggle: "active" | "inactive"
When active, the selection action is highlighted.
- Attribute
- selection-toggle
- Default value
- "inactive"
switchSelectionState
switchSelectionState: "disabled" | "enabled"
When disabled, interaction with the switch selection action is prevented and the component is displayed with lower opacity.
- Attribute
- switch-selection-state
- Default value
- "enabled"
switchSelectionTitle
switchSelectionTitle: string
Custom title for the switch selection action.
- Attribute
- switch-selection-title
- Default value
- undefined
switchSelectionToggle
switchSelectionToggle: "active" | "inactive"
When active, the switch selection action is highlighted.
- Attribute
- switch-selection-toggle
- Default value
- "inactive"
zoomState
zoomState: "disabled" | "enabled"
When disabled, interaction with the zoom action is prevented and the component is displayed with lower opacity.
- Attribute
- zoom-state
- Default value
- "enabled"
zoomTitle
zoomTitle: string
Custom title for the zoom action.
- Attribute
- zoom-title
- Default value
- undefined
zoomToggle
zoomToggle: "active" | "inactive"
When active, the zoom action is highlighted.
- Attribute
- zoom-toggle
- Default value
- "inactive"
Slots
Name | Description |
---|---|
A slot for adding custom `calcite-action` to the top of the default actions. | |
A slot for adding custom `calcite-action` to the bottom of the default actions. |
Events
Event | Type |
---|---|
CustomEvent<boolean> | |
CustomEvent<{
actionId: DefaultChartActions;
actionActive: boolean;
}> |
arcgisActionBarToggle
arcgisActionBarToggle: CustomEvent<boolean>
Event triggered once action bar expand is toggled
Events triggered on this element will be propagated to their outermost elements.
The event is composable and will propagate across the shadow DOM into the standard DOM.
The event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
arcgisDefaultActionSelect
arcgisDefaultActionSelect: CustomEvent<{
actionId: DefaultChartActions;
actionActive: boolean;
}>
Event triggered once a default action is selected
Events triggered on this element will be propagated to their outermost elements.
The event is composable and will propagate across the shadow DOM into the standard DOM.
The event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
Methods
Method | Signature |
---|---|
componentOnReady(): Promise<void> |
componentOnReady
componentOnReady(): Promise<void>
Create a promise that resolves once component is fully loaded.
Example
const arcgisChartsActionBar = document.querySelector("arcgis-charts-action-bar");
document.body.append(arcgisChartsActionBar);
await arcgisChartsActionBar.componentOnReady();
console.log("arcgis-charts-action-bar is ready to go!");
- Returns
- Promise<void>