Python API¶
Dash component¶
- class dash_echartsx.DashEChartsX(id=None, className=None, style=None, option=None, maps=None, enable_gl=None, gl_bundle_url=None, notMerge=None, lazyUpdate=None, renderer=None, theme=None, click_data=None, dblclick_data=None, hover_data=None, selected_data=None, legend_status=None, zoom_data=None, dispatch_action=None, append_data=None, ref=None, key=None, **kwargs)[source]¶
Bases:
ComponentA DashEChartsX component.
Keyword arguments:
- id (string; optional):
Unique identifier for the component. Defaults to None when omitted.
- append_data (dict; optional):
Append a batch of data to an ECharts series without resending its full option. Defaults to None when omitted.
append_data is a dict with keys:
seriesIndex (number; required)
data (boolean | number | string | dict | list; required)
- className (string; optional):
CSS class applied to the component container. Defaults to None when omitted.
- click_data (boolean | number | string | dict | list; optional):
Latest click event with seriesIndex, dataIndex, name, and value when available. Defaults to None when omitted.
- dblclick_data (boolean | number | string | dict | list; optional):
Latest double-click event with seriesIndex, dataIndex, name, and value when available. Defaults to None when omitted.
- dispatch_action (boolean | number | string | dict | list; optional):
Dispatch a supported ECharts action when this payload changes. Defaults to None when omitted.
- enable_gl (boolean; optional):
Lazily load ECharts-GL before applying 3D/WebGL options. Defaults to False.
- gl_bundle_url (string; optional):
Optional URL override for the separately served ECharts-GL bundle. Defaults to None when omitted.
- hover_data (boolean | number | string | dict | list; optional):
Latest pointer-over event with seriesIndex, dataIndex, name, and value when available. Defaults to None when omitted.
key (string | number; optional)
- lazyUpdate (boolean; optional):
Defer option updates until the next animation frame. Defaults to False.
- legend_status (boolean | number | string | dict | list; optional):
Latest legend selection event with the legend name and selection state. Defaults to None when omitted.
- maps (boolean | number | string | dict | list; optional):
GeoJSON or SVG map definitions registered before applying the option. Defaults to None when omitted.
- notMerge (boolean; optional):
Replace the current option instead of merging it. Defaults to False.
- option (boolean | number | string | dict | list; optional):
ECharts option object. Defaults to None when omitted.
- ref (string; optional):
Allows getting a ref to the component instance. Once the component unmounts, React will set ref.current to None (or call the ref with None if you passed a callback ref). @,see,,{@link ,https://react.dev/learn/referencing-values-with-refs#refs-and-the-dom React Docs,}.
- renderer (a value equal to: None, ‘canvas’, ‘svg’; optional):
Rendering engine used by ECharts. Defaults to “canvas”.
- selected_data (boolean | number | string | dict | list; optional):
Latest selection-change event, including the selected series and data indexes. Defaults to None when omitted.
- theme (dict; optional):
Named light/dark theme or a custom ECharts theme object. Defaults to None when omitted.
- zoom_data (boolean | number | string | dict | list; optional):
Latest data-zoom event with range and value bounds when available. Defaults to None when omitted.
- Parameters:
className (str | None)
style (Any | None)
option (Any | None)
maps (Any | None)
enable_gl (bool | None)
gl_bundle_url (str | None)
notMerge (bool | None)
lazyUpdate (bool | None)
renderer (Literal[None, 'canvas', 'svg'] | None)
theme (dict | Literal['light'] | ~typing.Literal['dark'] | None)
click_data (Any | None)
dblclick_data (Any | None)
hover_data (Any | None)
selected_data (Any | None)
legend_status (Any | None)
zoom_data (Any | None)
dispatch_action (Any | None)
append_data (AppendData | None)
key (str | Annotated[SupportsFloat | SupportsInt | SupportsComplex, _NumberSchema] | None)
- class AppendData¶
Bases:
TypedDict