@opendata-ai/openchart-vue 8.0.0-rc.24 → 8.0.0-rc.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
- import { BarListSpec, ThemeConfig, DarkMode, ChartSpec, LayerSpec, GraphSpec, ElementRef, MarkEvent, Annotation, TextAnnotation, AnnotationOffset, ElementEdit, MapSpec, ChartLayout, TableSpec, SortState, SankeySpec, TileMapSpec, VizSpec } from '@opendata-ai/openchart-core';
1
+ import { BarListSpec, ThemeConfig, DarkMode, ChartSpec, LayerSpec, GraphSpec, ElementRef, MarkEvent, Annotation, TextAnnotation, AnnotationOffset, ElementEdit, GeoMapSpec, ChartLayout, TableSpec, SortState, SankeySpec, TileMapSpec, VizSpec } from '@opendata-ai/openchart-core';
2
2
  export * from '@opendata-ai/openchart-core';
3
- import { MountOptions, ChartInstance, CameraFlightOptions, GraphHighlightTarget, GraphLegendData, GraphInstance, TableInstance, TableState, TableMountOptions, GraphTooltipFormatter, MapMarkEvent } from '@opendata-ai/openchart-vanilla';
4
- export { JPGExportOptions, PNGExportOptions, exportCSV, exportJPG, exportPNG, exportSVG } from '@opendata-ai/openchart-vanilla';
5
- export { ChartRenderer, CompileResult, CompiledGraphEdge, CompiledGraphNode, GraphCompilation, NormalizedBarListSpec, NormalizedChartSpec, NormalizedChrome, NormalizedGraphSpec, NormalizedMapSpec, NormalizedSankeySpec, NormalizedSpec, NormalizedTableSpec, SimulationConfig, ValidationError, ValidationErrorCode, ValidationResult, clearRenderers, compile, compileBarList, compileChart, compileGraph, compileMap, compileSankey, compileTable, getChartRenderer, normalizeSpec, registerChartRenderer, validateSpec } from '@opendata-ai/openchart-engine';
3
+ import { MountOptions, ChartInstance, CameraFlightOptions, GraphHighlightTarget, GraphLegendData, GraphInstance, TableInstance, TableState, TableMountOptions, GeoMapMarkEvent, GraphTooltipFormatter } from '@opendata-ai/openchart-vanilla';
4
+ export { JPGExportOptions, PNGExportOptions, SVGExportOptions, SpecSequenceOptions, exportCSV, exportJPG, exportPNG, exportSVG, exportSVGWithFonts, exportSpecSequence } from '@opendata-ai/openchart-vanilla';
5
+ export { ChartRenderer, CompileResult, CompiledGraphEdge, CompiledGraphNode, GraphCompilation, NormalizedBarListSpec, NormalizedChartSpec, NormalizedChrome, NormalizedGeoMapSpec, NormalizedGraphSpec, NormalizedSankeySpec, NormalizedSpec, NormalizedTableSpec, NormalizedTileMapSpec, SimulationConfig, ValidationError, ValidationErrorCode, ValidationResult, clearRenderers, compile, compileBarList, compileChart, compileGeoMap, compileGraph, compileSankey, compileTable, compileTileMap, getChartRenderer, normalizeSpec, registerChartRenderer, validateSpec } from '@opendata-ai/openchart-engine';
6
6
  import * as vue from 'vue';
7
7
  import { PropType, CSSProperties, VNode, Ref, ShallowRef, InjectionKey, ComputedRef } from 'vue';
8
8
  import { ChartStoryOptions } from '@opendata-ai/openchart-vanilla/story';
@@ -80,6 +80,8 @@ interface ChartProps {
80
80
  spec: ChartSpec | LayerSpec | GraphSpec;
81
81
  theme?: ThemeConfig;
82
82
  darkMode?: DarkMode;
83
+ /** Rendering backend for point marks; see the vanilla `MountOptions.renderer`. */
84
+ renderer?: 'auto' | 'svg' | 'canvas';
83
85
  class?: string;
84
86
  style?: string | CSSProperties;
85
87
  }
@@ -96,6 +98,10 @@ declare const Chart: vue.DefineComponent<vue.ExtractPropTypes<{
96
98
  type: PropType<DarkMode>;
97
99
  default: undefined;
98
100
  };
101
+ renderer: {
102
+ type: PropType<"auto" | "svg" | "canvas">;
103
+ default: undefined;
104
+ };
99
105
  class: {
100
106
  type: StringConstructor;
101
107
  default: undefined;
@@ -143,6 +149,10 @@ declare const Chart: vue.DefineComponent<vue.ExtractPropTypes<{
143
149
  type: PropType<DarkMode>;
144
150
  default: undefined;
145
151
  };
152
+ renderer: {
153
+ type: PropType<"auto" | "svg" | "canvas">;
154
+ default: undefined;
155
+ };
146
156
  class: {
147
157
  type: StringConstructor;
148
158
  default: undefined;
@@ -180,13 +190,14 @@ declare const Chart: vue.DefineComponent<vue.ExtractPropTypes<{
180
190
  darkMode: DarkMode;
181
191
  class: string;
182
192
  style: string | CSSProperties;
193
+ renderer: "auto" | "canvas" | "svg";
183
194
  selectedElement: ElementRef;
184
195
  highlight: string[] | null;
185
196
  editable: boolean;
186
197
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
187
198
 
188
199
  interface ChartStoryProps {
189
- spec: ChartSpec | LayerSpec | GraphSpec | MapSpec;
200
+ spec: ChartSpec | LayerSpec | GraphSpec | GeoMapSpec;
190
201
  steps: ChartStoryOptions['steps'];
191
202
  narrative?: VNode[];
192
203
  step?: number;
@@ -196,7 +207,7 @@ interface ChartStoryProps {
196
207
  }
197
208
  declare const ChartStory: vue.DefineComponent<vue.ExtractPropTypes<{
198
209
  spec: {
199
- type: PropType<ChartSpec | LayerSpec | GraphSpec | MapSpec>;
210
+ type: PropType<ChartSpec | LayerSpec | GraphSpec | GeoMapSpec>;
200
211
  required: true;
201
212
  };
202
213
  steps: {
@@ -227,7 +238,7 @@ declare const ChartStory: vue.DefineComponent<vue.ExtractPropTypes<{
227
238
  [key: string]: any;
228
239
  }>, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<{
229
240
  spec: {
230
- type: PropType<ChartSpec | LayerSpec | GraphSpec | MapSpec>;
241
+ type: PropType<ChartSpec | LayerSpec | GraphSpec | GeoMapSpec>;
231
242
  required: true;
232
243
  };
233
244
  steps: {
@@ -280,6 +291,8 @@ interface UseChartOptions {
280
291
  onDataPointClick?: MountOptions['onDataPointClick'];
281
292
  /** Enable responsive resizing. Defaults to true. */
282
293
  responsive?: boolean;
294
+ /** Rendering backend for point marks; see the vanilla `MountOptions.renderer`. */
295
+ renderer?: MountOptions['renderer'];
283
296
  }
284
297
  interface UseChartReturn {
285
298
  /** Template ref to attach to the container div. */
@@ -612,6 +625,70 @@ declare const DataTable: vue.DefineComponent<vue.ExtractPropTypes<{
612
625
  page: number;
613
626
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
614
627
 
628
+ interface GeoMapProps {
629
+ spec: GeoMapSpec;
630
+ theme?: ThemeConfig;
631
+ darkMode?: DarkMode;
632
+ class?: string;
633
+ style?: string | CSSProperties;
634
+ }
635
+ declare const GeoMap: vue.DefineComponent<vue.ExtractPropTypes<{
636
+ spec: {
637
+ type: PropType<GeoMapSpec>;
638
+ required: true;
639
+ };
640
+ theme: {
641
+ type: PropType<ThemeConfig>;
642
+ default: undefined;
643
+ };
644
+ darkMode: {
645
+ type: PropType<DarkMode>;
646
+ default: undefined;
647
+ };
648
+ class: {
649
+ type: StringConstructor;
650
+ default: undefined;
651
+ };
652
+ style: {
653
+ type: PropType<string | CSSProperties>;
654
+ default: undefined;
655
+ };
656
+ }>, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
657
+ [key: string]: any;
658
+ }>, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
659
+ 'mark-click': (_event: GeoMapMarkEvent) => true;
660
+ 'mark-hover': (_event: GeoMapMarkEvent | null) => true;
661
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<{
662
+ spec: {
663
+ type: PropType<GeoMapSpec>;
664
+ required: true;
665
+ };
666
+ theme: {
667
+ type: PropType<ThemeConfig>;
668
+ default: undefined;
669
+ };
670
+ darkMode: {
671
+ type: PropType<DarkMode>;
672
+ default: undefined;
673
+ };
674
+ class: {
675
+ type: StringConstructor;
676
+ default: undefined;
677
+ };
678
+ style: {
679
+ type: PropType<string | CSSProperties>;
680
+ default: undefined;
681
+ };
682
+ }>> & Readonly<{
683
+ "onMark-click"?: ((_event: GeoMapMarkEvent) => any) | undefined;
684
+ "onMark-hover"?: ((_event: GeoMapMarkEvent | null) => any) | undefined;
685
+ }>, {
686
+ theme: ThemeConfig;
687
+ darkMode: DarkMode;
688
+ class: string;
689
+ style: string | CSSProperties;
690
+ }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
691
+
615
692
  /** Tooltip prop: `false` off, `true` default, or an object with a formatter. */
616
693
  type GraphTooltipProp = boolean | {
617
694
  formatter?: GraphTooltipFormatter;
@@ -743,70 +820,6 @@ declare const Graph: vue.DefineComponent<vue.ExtractPropTypes<{
743
820
  fitOnLoad: boolean;
744
821
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
745
822
 
746
- interface MapProps {
747
- spec: MapSpec;
748
- theme?: ThemeConfig;
749
- darkMode?: DarkMode;
750
- class?: string;
751
- style?: string | CSSProperties;
752
- }
753
- declare const GeoMap: vue.DefineComponent<vue.ExtractPropTypes<{
754
- spec: {
755
- type: PropType<MapSpec>;
756
- required: true;
757
- };
758
- theme: {
759
- type: PropType<ThemeConfig>;
760
- default: undefined;
761
- };
762
- darkMode: {
763
- type: PropType<DarkMode>;
764
- default: undefined;
765
- };
766
- class: {
767
- type: StringConstructor;
768
- default: undefined;
769
- };
770
- style: {
771
- type: PropType<string | CSSProperties>;
772
- default: undefined;
773
- };
774
- }>, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
775
- [key: string]: any;
776
- }>, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
777
- 'mark-click': (_event: MapMarkEvent) => true;
778
- 'mark-hover': (_event: MapMarkEvent | null) => true;
779
- }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<{
780
- spec: {
781
- type: PropType<MapSpec>;
782
- required: true;
783
- };
784
- theme: {
785
- type: PropType<ThemeConfig>;
786
- default: undefined;
787
- };
788
- darkMode: {
789
- type: PropType<DarkMode>;
790
- default: undefined;
791
- };
792
- class: {
793
- type: StringConstructor;
794
- default: undefined;
795
- };
796
- style: {
797
- type: PropType<string | CSSProperties>;
798
- default: undefined;
799
- };
800
- }>> & Readonly<{
801
- "onMark-click"?: ((_event: MapMarkEvent) => any) | undefined;
802
- "onMark-hover"?: ((_event: MapMarkEvent | null) => any) | undefined;
803
- }>, {
804
- theme: ThemeConfig;
805
- darkMode: DarkMode;
806
- class: string;
807
- style: string | CSSProperties;
808
- }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
809
-
810
823
  interface SankeyProps {
811
824
  spec: SankeySpec;
812
825
  theme?: ThemeConfig;
@@ -1032,4 +1045,4 @@ declare const Visualization: vue.DefineComponent<vue.ExtractPropTypes<{
1032
1045
  style: string | CSSProperties;
1033
1046
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
1034
1047
 
1035
- export { BarList, type BarListProps, type BarListRowEvent, Chart, type ChartProps, ChartStory, type ChartStoryProps, DataTable, type DataTableProps, GeoMap, Graph, type GraphHandle, type GraphProps, type MapProps, Sankey, type SankeyProps, TileMap, type TileMapProps, type UseChartOptions, type UseChartReturn, type UseGraphReturn, type UseTableReturn, type UseTableStateOptions, type UseTableStateReturn, Visualization, type VisualizationProps, VizDarkModeKey, VizThemeKey, VizThemeProvider, type VizThemeProviderProps, useChart, useDarkMode, useGraph, useTable, useTableState, useVizDarkMode, useVizTheme };
1048
+ export { BarList, type BarListProps, type BarListRowEvent, Chart, type ChartProps, ChartStory, type ChartStoryProps, DataTable, type DataTableProps, GeoMap, type GeoMapProps, Graph, type GraphHandle, type GraphProps, Sankey, type SankeyProps, TileMap, type TileMapProps, type UseChartOptions, type UseChartReturn, type UseGraphReturn, type UseTableReturn, type UseTableStateOptions, type UseTableStateReturn, Visualization, type VisualizationProps, VizDarkModeKey, VizThemeKey, VizThemeProvider, type VizThemeProviderProps, useChart, useDarkMode, useGraph, useTable, useTableState, useVizDarkMode, useVizTheme };