vue-chrts 2.1.0-beta-8 → 2.1.0-beta-9

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.
Files changed (168) hide show
  1. package/dist/components/AreaChart/AreaChart.d.ts +185 -0
  2. package/dist/components/AreaChart/AreaChart.js +1 -1
  3. package/dist/components/AreaChart/AreaChart.vue.d.ts +1 -1
  4. package/dist/components/AreaChart/index.d.ts +2 -0
  5. package/dist/components/BarChart/BarChart.d.ts +192 -0
  6. package/dist/components/BarChart/BarChart.js +1 -1
  7. package/dist/components/BarChart/BarChart.vue.d.ts +1 -1
  8. package/dist/components/BarChart/index.d.ts +2 -0
  9. package/dist/components/BubbleChart/BubbleChart.d.ts +173 -0
  10. package/dist/components/BubbleChart/BubbleChart.js +1 -1
  11. package/dist/components/BubbleChart/BubbleChart.vue.d.ts +1 -1
  12. package/dist/components/BubbleChart/index.d.ts +2 -0
  13. package/dist/components/DagreGraph/DagreGraph.d.ts +254 -0
  14. package/dist/components/DagreGraph/DagreGraph.js +1 -1
  15. package/dist/components/DagreGraph/DagreGraph.vue.d.ts +1 -1
  16. package/dist/components/DagreGraph/index.d.ts +2 -0
  17. package/dist/components/DagreGraph/types.d.ts +2 -1
  18. package/dist/components/DonutChart/DonutChart.d.ts +68 -0
  19. package/dist/components/DonutChart/DonutChart.js +4 -4
  20. package/dist/components/DonutChart/DonutChart.vue.d.ts +1 -1
  21. package/dist/components/DonutChart/DonutChart2.js +2 -2
  22. package/dist/components/DonutChart/DonutChart3.js +4 -0
  23. package/dist/components/DonutChart/index.d.ts +2 -0
  24. package/dist/components/DualChart/DualChart.d.ts +195 -0
  25. package/dist/components/DualChart/DualChart.js +1 -1
  26. package/dist/components/DualChart/DualChart.vue.d.ts +1 -1
  27. package/dist/components/DualChart/index.d.ts +2 -0
  28. package/dist/components/DualChart/types.d.ts +2 -2
  29. package/dist/components/GanttChart/GanttChart.d.ts +125 -0
  30. package/dist/components/GanttChart/GanttChart.js +1 -1
  31. package/dist/components/GanttChart/GanttChart.vue.d.ts +1 -1
  32. package/dist/components/GanttChart/index.d.ts +2 -0
  33. package/dist/components/LineChart/LineChart.d.ts +2 -0
  34. package/dist/components/LineChart/LineChart.vue.d.ts +1 -1
  35. package/dist/components/LineChart/index.d.ts +2 -0
  36. package/dist/components/Maps/DottedMap/DottedMap.vue.d.ts +2 -2
  37. package/dist/components/Maps/DottedMap/core.vue.d.ts +3 -3
  38. package/dist/components/Maps/DottedMap/mapUtils.js +22 -22
  39. package/dist/components/Maps/TopoJSONMap/TopoJSONMap.js +1 -1
  40. package/dist/components/Maps/TopoJSONMap/TopoJSONMap.vue.d.ts +2 -2
  41. package/dist/components/Maps/TopoJSONMap/types.d.ts +2 -1
  42. package/dist/components/Maps/index.d.ts +5 -0
  43. package/dist/components/SankeyChart/SankeyChart.d.ts +117 -0
  44. package/dist/components/SankeyChart/SankeyChart.js +1 -1
  45. package/dist/components/SankeyChart/SankeyChart.vue.d.ts +1 -1
  46. package/dist/components/SankeyChart/index.d.ts +2 -0
  47. package/dist/components/SankeyChart/types.d.ts +2 -1
  48. package/dist/enums.d.ts +32 -0
  49. package/dist/enums.js +6 -0
  50. package/dist/index.d.ts +12 -14
  51. package/dist/index.js +31 -31
  52. package/dist/types.d.ts +57 -7
  53. package/package.json +12 -12
  54. package/dist/components/AreaChart/types.d.ts +0 -1
  55. package/dist/components/BarChart/types.d.ts +0 -1
  56. package/dist/components/BubbleChart/types.d.ts +0 -1
  57. package/dist/components/DonutChart/types.d.ts +0 -2
  58. package/dist/components/GanttChart/types.d.ts +0 -1
  59. package/dist/components/LineChart/types.d.ts +0 -1
  60. package/dist/node_modules/.pnpm/@turf_boolean-point-in-polygon@7.3.2/node_modules/@turf/boolean-point-in-polygon/dist/esm/index.js +0 -28
  61. package/dist/node_modules/.pnpm/@turf_invariant@7.3.2/node_modules/@turf/invariant/dist/esm/index.js +0 -20
  62. package/dist/node_modules/.pnpm/mgrs@1.0.0/node_modules/mgrs/mgrs.js +0 -222
  63. package/dist/node_modules/.pnpm/point-in-polygon-hao@1.2.4/node_modules/point-in-polygon-hao/dist/esm/index.js +0 -25
  64. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/Point.js +0 -24
  65. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/Proj.js +0 -46
  66. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/adjust_axis.js +0 -31
  67. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/checkSanity.js +0 -15
  68. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_lat.js +0 -8
  69. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_lon.js +0 -8
  70. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_zone.js +0 -13
  71. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/asinhy.js +0 -9
  72. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/asinz.js +0 -6
  73. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/clens.js +0 -8
  74. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/clens_cmplx.js +0 -10
  75. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/cosh.js +0 -7
  76. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e0fn.js +0 -6
  77. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e1fn.js +0 -6
  78. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e2fn.js +0 -6
  79. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e3fn.js +0 -6
  80. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/gN.js +0 -7
  81. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/gatg.js +0 -8
  82. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/hypot.js +0 -8
  83. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/imlfn.js +0 -11
  84. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/iqsfnz.js +0 -13
  85. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/log1py.js +0 -7
  86. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/mlfn.js +0 -6
  87. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/msfnz.js +0 -7
  88. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/phi2z.js +0 -10
  89. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_enfn.js +0 -10
  90. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_inv_mlfn.js +0 -14
  91. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_mlfn.js +0 -6
  92. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/qsfnz.js +0 -7
  93. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/sign.js +0 -6
  94. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/sinh.js +0 -7
  95. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/srat.js +0 -6
  96. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/toPoint.js +0 -10
  97. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/tsfnz.js +0 -8
  98. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/vincenty.js +0 -33
  99. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/Datum.js +0 -1278
  100. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/Ellipsoid.js +0 -226
  101. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/PrimeMeridian.js +0 -17
  102. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/units.js +0 -25
  103. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/values.js +0 -22
  104. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/core.js +0 -65
  105. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datum.js +0 -8
  106. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datumUtils.js +0 -82
  107. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datum_transform.js +0 -94
  108. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/defs.js +0 -39
  109. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/deriveConstants.js +0 -30
  110. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/extend.js +0 -12
  111. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/global.js +0 -9
  112. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/index.js +0 -25
  113. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/match.js +0 -11
  114. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/nadgrid.js +0 -128
  115. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/parseCode.js +0 -47
  116. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projString.js +0 -119
  117. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/aea.js +0 -43
  118. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/aeqd.js +0 -36
  119. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/bonne.js +0 -55
  120. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/cass.js +0 -52
  121. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/cea.js +0 -36
  122. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqc.js +0 -27
  123. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqdc.js +0 -48
  124. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqearth.js +0 -30
  125. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/etmerc.js +0 -54
  126. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/gauss.js +0 -27
  127. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/geocent.js +0 -26
  128. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/geos.js +0 -49
  129. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/gnom.js +0 -28
  130. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/krovak.js +0 -31
  131. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/laea.js +0 -134
  132. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/lcc.js +0 -61
  133. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/longlat.js +0 -19
  134. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/merc.js +0 -49
  135. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/mill.js +0 -26
  136. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/moll.js +0 -37
  137. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/nzmg.js +0 -48
  138. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/ob_tran.js +0 -173
  139. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/omerc.js +0 -58
  140. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/ortho.js +0 -28
  141. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/poly.js +0 -68
  142. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/qsc.js +0 -67
  143. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/robin.js +0 -104
  144. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/sinu.js +0 -47
  145. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/somerc.js +0 -34
  146. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/stere.js +0 -46
  147. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/sterea.js +0 -33
  148. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/tmerc.js +0 -60
  149. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/tpers.js +0 -110
  150. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/utm.js +0 -22
  151. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/vandg.js +0 -34
  152. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections.js +0 -34
  153. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/transform.js +0 -49
  154. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/projs.js +0 -38
  155. package/dist/node_modules/.pnpm/robust-predicates@3.0.2/node_modules/robust-predicates/esm/orient2d.js +0 -23
  156. package/dist/node_modules/.pnpm/robust-predicates@3.0.2/node_modules/robust-predicates/esm/util.js +0 -30
  157. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilder2015.js +0 -9
  158. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilder2019.js +0 -20
  159. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilderBase.js +0 -171
  160. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/buildPROJJSON.js +0 -11
  161. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/detectWKTVersion.js +0 -7
  162. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/index.js +0 -104
  163. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/parser.js +0 -117
  164. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/process.js +0 -89
  165. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/transformPROJJSON.js +0 -73
  166. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/util.js +0 -12
  167. package/dist/packages/shared/dist/donut-chart.js +0 -7
  168. package/dist/packages/shared/dist/index.js +0 -19
@@ -0,0 +1,185 @@
1
+ import { AxisConfig, axisFormatter, BulletLegendItemInterface, CrosshairConfig, MarkerConfig, TooltipConfig } from '../../types';
2
+ import { CurveType, LegendPosition } from '../../enums';
3
+ export interface AreaChartProps<T> {
4
+ /**
5
+ * The data to be displayed in the area chart.
6
+ * Each element of the array represents a data point.
7
+ * The structure of 'T' should be compatible with the chart's rendering logic.
8
+ */
9
+ data: T[];
10
+ /**
11
+ * The height of the chart in pixels.
12
+ */
13
+ height: number;
14
+ /**
15
+ * Optional label for the x-axis.
16
+ */
17
+ xLabel?: string;
18
+ /**
19
+ * Optional label for the y-axis.
20
+ */
21
+ yLabel?: string;
22
+ /**
23
+ * Optional padding applied to the chart.
24
+ * Allows specifying individual padding values for the top, right, bottom, and left sides.
25
+ */
26
+ padding?: {
27
+ top: number;
28
+ right: number;
29
+ bottom: number;
30
+ left: number;
31
+ };
32
+ /**
33
+ * A record mapping category keys to `BulletLegendItemInterface` objects.
34
+ * This defines the visual representation and labels for each category in the chart's legend.
35
+ */
36
+ categories: Record<string, BulletLegendItemInterface>;
37
+ /**
38
+ * A record mapping marker keys to show custom patterns.
39
+ */
40
+ markerConfig?: MarkerConfig;
41
+ /**
42
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the x-axis.
43
+ * @param {number} i - The index of the tick in the `ticks` array.
44
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the x-axis.
45
+ * @returns {string} The formatted string representation of the tick.
46
+ */
47
+ xFormatter?: axisFormatter;
48
+ /**
49
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the y-axis.
50
+ * @param {number} i - The index of the tick in the `ticks` array.
51
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the y-axis.
52
+ * @returns {string} The formatted string representation of the tick.
53
+ */
54
+ yFormatter?: axisFormatter;
55
+ /**
56
+ * Use custom formatter for tooltip titles
57
+ */
58
+ tooltipTitleFormatter?: (data: T) => string | number;
59
+ /**
60
+ * The type of curve to use for the area chart lines.
61
+ * See `CurveType` for available options.
62
+ */
63
+ curveType?: CurveType;
64
+ /**
65
+ * If `true`, hides the area fill, displaying only the line.
66
+ */
67
+ hideArea?: boolean;
68
+ /**
69
+ * Edit the gradient stops for the area fill.
70
+ */
71
+ gradientStops?: Array<{
72
+ offset: string;
73
+ stopOpacity: number;
74
+ }>;
75
+ /**
76
+ * The width of the line in pixels. Default is 2px.
77
+ */
78
+ lineWidth?: number;
79
+ /**
80
+ * Line dash array, see SVG's stroke-dasharray. Default: `undefined`
81
+ */
82
+ lineDashArray?: number[][];
83
+ /**
84
+ * The desired number of ticks on the x-axis.
85
+ */
86
+ xNumTicks?: number;
87
+ /**
88
+ * Force specific ticks on the x-axis.
89
+ */
90
+ xExplicitTicks?: (number | string | Date)[];
91
+ /**
92
+ * Force only first and last ticks on the x-axis.
93
+ */
94
+ minMaxTicksOnly?: boolean;
95
+ /**
96
+ * The desired number of ticks on the y-axis.
97
+ */
98
+ yNumTicks?: number;
99
+ /**
100
+ * Force specific ticks on the y-axis.
101
+ */
102
+ yExplicitTicks?: (number | string | Date)[];
103
+ /**
104
+ * If `true`, hides the chart legend.
105
+ */
106
+ hideLegend?: boolean;
107
+ /**
108
+ * If `true`, hides the chart tooltip.
109
+ */
110
+ hideTooltip?: boolean;
111
+ /**
112
+ * Optional position for the legend, if applicable.
113
+ * See `LegendPosition` for available options.
114
+ */
115
+ legendPosition?: LegendPosition;
116
+ /**
117
+ * Optional style object for the legend container. Allows custom CSS styling.
118
+ */
119
+ legendStyle?: string | Record<string, string>;
120
+ /**
121
+ * If `true`, displays a domain line (axis line) along the x-axis.
122
+ */
123
+ xDomainLine?: boolean;
124
+ /**
125
+ * If `true`, displays a domain line (axis line) along the y-axis.
126
+ */
127
+ yDomainLine?: boolean;
128
+ /**
129
+ * If `true`, displays tick lines on the x-axis.
130
+ */
131
+ xTickLine?: boolean;
132
+ /**
133
+ * If `true`, displays tick lines on the y-axis.
134
+ */
135
+ yTickLine?: boolean;
136
+ /**
137
+ * If `true`, displays grid lines along the x-axis.
138
+ */
139
+ xGridLine?: boolean;
140
+ /**
141
+ * If `true`, displays grid lines along the y-axis.
142
+ */
143
+ yGridLine?: boolean;
144
+ /**
145
+ * If `true`, hide the x-axis.
146
+ */
147
+ hideXAxis?: boolean;
148
+ /**
149
+ * If `true`, hide the y-axis.
150
+ */
151
+ hideYAxis?: boolean;
152
+ /**
153
+ * Crosshair configuration object for customizing the appearance of the crosshair line.
154
+ */
155
+ crosshairConfig?: CrosshairConfig;
156
+ /**
157
+ * Axis configuration object for customizing the appearance of the axes.
158
+ */
159
+ xAxisConfig?: AxisConfig;
160
+ /**
161
+ * Axis configuration object for customizing the appearance of the axes.
162
+ */
163
+ yAxisConfig?: AxisConfig;
164
+ /**
165
+ * The domain for the y-axis, specified as a tuple of two values.
166
+ */
167
+ yDomain?: [number | undefined, number | undefined];
168
+ /**
169
+ * The domain for the x-axis, specified as a tuple of two values.
170
+ */
171
+ xDomain?: [number | undefined, number | undefined];
172
+ /**
173
+ * If `true`, creates a stacked area chart where areas are stacked on top of each other.
174
+ * When false (default), areas are overlaid on top of each other.
175
+ */
176
+ stacked?: boolean;
177
+ /**
178
+ * Animation duration in milliseconds for the chart components.
179
+ */
180
+ duration?: number;
181
+ /**
182
+ * Configuration object for the chart tooltip.
183
+ */
184
+ tooltip?: TooltipConfig;
185
+ }
@@ -3,7 +3,7 @@ import { Position as $, CurveType as h } from "@unovis/ts";
3
3
  import { createScopedMarkers as ie } from "../../utils.js";
4
4
  import oe from "../Tooltip.js";
5
5
  import { VisXYContainer as ne, VisTooltip as ae, VisArea as B, VisLine as O, VisAxis as w, VisCrosshair as re, VisBulletLegend as le } from "@unovis/vue";
6
- import { LegendPosition as ce } from "../../packages/shared/dist/index.js";
6
+ import { LegendPosition as ce } from "../../enums.js";
7
7
  const se = ["id"], ue = {
8
8
  ref: "slotWrapper",
9
9
  style: { display: "none" }
@@ -1,4 +1,4 @@
1
- import { AreaChartProps } from './types';
1
+ import { AreaChartProps } from './AreaChart';
2
2
  declare const _default: <T>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
3
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
4
  readonly onClick?: ((event: MouseEvent, values?: T | undefined) => any) | undefined;
@@ -0,0 +1,2 @@
1
+ export { default as AreaChart } from './AreaChart.vue';
2
+ export * from './AreaChart';
@@ -0,0 +1,192 @@
1
+ import { Orientation } from '@unovis/ts';
2
+ import { axisFormatter, AxisConfig, TooltipConfig, BulletLegendItemInterface } from '../../types';
3
+ import { LegendPosition } from '../../enums';
4
+ export type BarChartPropsBase<T> = {
5
+ /**
6
+ * The data to be displayed in the bar chart.
7
+ * Each element of the array represents a data point.
8
+ * The structure of 'T' should be compatible with the chart's rendering logic.
9
+ */
10
+ data: T[];
11
+ /**
12
+ * If `true`, creates a stacked bar chart instead of grouped bars.
13
+ */
14
+ stacked?: boolean;
15
+ /**
16
+ * The height of the chart in pixels.
17
+ */
18
+ height: number;
19
+ /**
20
+ * Optional label for the x-axis.
21
+ */
22
+ xLabel?: string;
23
+ /**
24
+ * Optional label for the y-axis.
25
+ */
26
+ yLabel?: string;
27
+ /**
28
+ * Optional padding applied to the chart.
29
+ * Allows specifying individual padding values for the top, right, bottom, and left sides.
30
+ */
31
+ padding?: {
32
+ top: number;
33
+ right: number;
34
+ bottom: number;
35
+ left: number;
36
+ };
37
+ /**
38
+ * A record mapping category keys to `BulletLegendItemInterface` objects.
39
+ * This defines the visual representation and labels for each category in the chart's legend.
40
+ */
41
+ categories: Record<string, BulletLegendItemInterface>;
42
+ /**
43
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the x-axis.
44
+ * @param {number} i - The index of the tick in the `ticks` array.
45
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the x-axis.
46
+ * @returns {string} The formatted string representation of the tick.
47
+ */
48
+ xFormatter?: axisFormatter;
49
+ /**
50
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the y-axis.
51
+ * @param {number} i - The index of the tick in the `ticks` array.
52
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the y-axis.
53
+ * @returns {string} The formatted string representation of the tick.
54
+ */
55
+ yFormatter?: axisFormatter;
56
+ /**
57
+ * Use custom formatter for tooltip titles
58
+ */
59
+ tooltipTitleFormatter?: (data: T) => string | number;
60
+ /**
61
+ * The desired number of ticks on the y-axis.
62
+ */
63
+ yNumTicks?: number;
64
+ /**
65
+ * Force only first and last ticks on the x-axis.
66
+ */
67
+ minMaxTicksOnly?: boolean;
68
+ /**
69
+ * The desired number of ticks on the x-axis.
70
+ */
71
+ xNumTicks?: number;
72
+ /**
73
+ * Force specific ticks on the x-axis.
74
+ */
75
+ xExplicitTicks?: (number | string | Date)[];
76
+ /**
77
+ * An array of property keys from the data object type 'T' to be used for the y-axis values.
78
+ */
79
+ yAxis: (keyof T)[];
80
+ /**
81
+ * The padding between groups of bars in pixels.
82
+ */
83
+ groupPadding?: number;
84
+ /**
85
+ * Fractional padding between the bars in the range of [0,1). Default: 0
86
+ */
87
+ barPadding?: number;
88
+ /**
89
+ * Rounded corners for top bars. Boolean or number (to set the radius in pixels). Default: 2
90
+ */
91
+ radius?: number;
92
+ /**
93
+ * If `true`, hides the chart legend.
94
+ */
95
+ hideLegend?: boolean;
96
+ /**
97
+ * If `true`, hides the chart tooltip.
98
+ */
99
+ hideTooltip?: boolean;
100
+ /**
101
+ * The orientation of the bars (vertical or horizontal).
102
+ * See `Orientation` for available options.
103
+ */
104
+ orientation?: Orientation;
105
+ /**
106
+ * Optional position for the legend, if applicable.
107
+ * See `LegendPosition` for available options.
108
+ */
109
+ legendPosition?: LegendPosition;
110
+ /**
111
+ * Optional style object for the legend container. Allows custom CSS styling.
112
+ */
113
+ legendStyle?: string | Record<string, string>;
114
+ /**
115
+ * If `true`, displays a domain line (axis line) along the x-axis.
116
+ */
117
+ xDomainLine?: boolean;
118
+ /**
119
+ * If `true`, displays a domain line (axis line) along the y-axis.
120
+ */
121
+ yDomainLine?: boolean;
122
+ /**
123
+ * If `true`, displays tick lines on the x-axis.
124
+ */
125
+ xTickLine?: boolean;
126
+ /**
127
+ * If `true`, displays tick lines on the y-axis.
128
+ */
129
+ yTickLine?: boolean;
130
+ /**
131
+ * If `true`, displays grid lines along the x-axis.
132
+ */
133
+ xGridLine?: boolean;
134
+ /**
135
+ * If `true`, displays grid lines along the y-axis.
136
+ */
137
+ yGridLine?: boolean;
138
+ /**
139
+ * If `true`, hide the x-axis.
140
+ */
141
+ hideXAxis?: boolean;
142
+ /**
143
+ * If `true`, hide the y-axis.
144
+ */
145
+ hideYAxis?: boolean;
146
+ /**
147
+ * Specific spacing between stacked and grouped bars in pixels.
148
+ * Only applicable if `stackAndGrouped` is `true`.
149
+ */
150
+ stackedGroupedSpacing?: number;
151
+ /**
152
+ * Axis configuration object for customizing the appearance of the axes.
153
+ */
154
+ xAxisConfig?: AxisConfig;
155
+ /**
156
+ * Axis configuration object for customizing the appearance of the axes.
157
+ */
158
+ yAxisConfig?: AxisConfig;
159
+ /**
160
+ * Animation duration in milliseconds for the chart components.
161
+ */
162
+ duration?: number;
163
+ /**
164
+ * Configuration object for the chart tooltip.
165
+ */
166
+ tooltip?: TooltipConfig;
167
+ };
168
+ export type BarChartProps<T> = BarChartPropsBase<T> & {
169
+ /**
170
+ * Whether the bars should be stacked and grouped.
171
+ * If true, `valueLabel` is optional and `xAxis` is required.
172
+ */
173
+ stackAndGrouped?: boolean;
174
+ /**
175
+ * Configuration for the value label display.
176
+ * Required if `stackAndGrouped` is false and `xAxis` is present.
177
+ * Optional otherwise.
178
+ */
179
+ valueLabel?: ValueLabel;
180
+ /**
181
+ * The data key for the X-axis.
182
+ * Required if `stackAndGrouped` is true, or if `stackAndGrouped` is false AND `valueLabel` is present.
183
+ */
184
+ xAxis?: keyof T;
185
+ };
186
+ export type ValueLabel = {
187
+ label: (d: any, index: number) => string | number;
188
+ labelSpacing?: number;
189
+ backgroundColor?: string;
190
+ color?: string;
191
+ labelFontSize?: number;
192
+ };
@@ -3,7 +3,7 @@ import { Orientation as g, StackedBar as U, GroupedBar as J } from "@unovis/ts";
3
3
  import { useStackedGrouped as K } from "./stackedGroupedUtils.js";
4
4
  import { VisXYContainer as Q, VisXYLabels as Z, VisTooltip as _, VisStackedBar as G, VisGroupedBar as ee, VisAxis as V, VisBulletLegend as te } from "@unovis/vue";
5
5
  import ae from "../Tooltip.js";
6
- import { LegendPosition as ie } from "../../packages/shared/dist/index.js";
6
+ import { LegendPosition as ie } from "../../enums.js";
7
7
  const ne = {
8
8
  ref: "slotWrapper",
9
9
  style: { display: "none" }
@@ -1,4 +1,4 @@
1
- import { BarChartProps } from './types';
1
+ import { BarChartProps } from './BarChart';
2
2
  declare const _default: <T extends {}>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
3
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
4
  readonly onClick?: ((event: MouseEvent, values?: T | undefined) => any) | undefined;
@@ -0,0 +1,2 @@
1
+ export { default as BarChart } from './BarChart.vue';
2
+ export * from './BarChart';
@@ -0,0 +1,173 @@
1
+ import { axisFormatter, BulletLegendItemInterface, CrosshairConfig, AxisConfig, TooltipConfig } from '../../types';
2
+ import { LegendPosition } from '../../enums';
3
+ import { NumericAccessor, Position } from '@unovis/ts';
4
+ export interface SizeOptions {
5
+ minRadius?: number;
6
+ maxRadius?: number;
7
+ }
8
+ export interface BubbleChartProps<T> {
9
+ /**
10
+ * Accessor for x value (index, property, etc). If not provided, defaults to d.beakLength.
11
+ */
12
+ xAccessor?: NumericAccessor<T>;
13
+ /**
14
+ * Accessor for y value. If not provided, defaults to d.flipperLength.
15
+ */
16
+ yAccessor?: NumericAccessor<T>;
17
+ /**
18
+ * Accessor for bubble size. If not provided, defaults to 1.
19
+ */
20
+ sizeAccessor?: NumericAccessor<T>;
21
+ /**
22
+ * Label position for bubbles (default: Position.Bottom)
23
+ */
24
+ labelPosition?: Position;
25
+ /**
26
+ * Range for bubble sizes (default: [1, 20])
27
+ */
28
+ sizeRange?: [number, number];
29
+ /**
30
+ * Opacity for bubbles
31
+ */
32
+ opacity?: number;
33
+ /**
34
+ * Explicit tick values for x axis
35
+ */
36
+ xExplicitTicks?: (number | string | Date)[];
37
+ /**
38
+ * Only show min/max ticks for x axis
39
+ */
40
+ minMaxTicksOnly?: boolean;
41
+ /**
42
+ * The data to be displayed in the bubble chart.
43
+ * Each element of the array represents a data point.
44
+ * The structure of 'T' should be compatible with the chart's rendering logic.
45
+ */
46
+ data: T[];
47
+ /**
48
+ * If `true`, hides the chart legend.
49
+ */
50
+ hideLegend?: boolean;
51
+ /**
52
+ * The height of the chart in pixels.
53
+ */
54
+ height: number;
55
+ /**
56
+ * Optional label for the x-axis.
57
+ */
58
+ xLabel?: string;
59
+ /**
60
+ * Optional label for the y-axis.
61
+ */
62
+ yLabel?: string;
63
+ /**
64
+ * Optional padding applied to the chart.
65
+ * Allows specifying individual padding values for the top, right, bottom, and left sides.
66
+ */
67
+ padding?: {
68
+ top: number;
69
+ right: number;
70
+ bottom: number;
71
+ left: number;
72
+ };
73
+ /**
74
+ * A record mapping category keys to `BulletLegendItemInterface` objects.
75
+ * This defines the visual representation and labels for each category in the chart's legend.
76
+ * REQUIRED: Each unique value in your data's categoryKey field must have a corresponding entry with a color.
77
+ */
78
+ categories: Record<string, BulletLegendItemInterface>;
79
+ categoryKey: keyof T;
80
+ /**
81
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the x-axis.
82
+ * @param {number} i - The index of the tick in the `ticks` array.
83
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the x-axis.
84
+ * @returns {string} The formatted string representation of the tick.
85
+ */
86
+ xFormatter?: axisFormatter;
87
+ /**
88
+ * @param {number|Date} tick - The value of the tick. This can be a number or a Date object depending on the scale of the y-axis.
89
+ * @param {number} i - The index of the tick in the `ticks` array.
90
+ * @param {(number[]|Date[])} ticks - An array of all tick values for the y-axis.
91
+ * @returns {string} The formatted string representation of the tick.
92
+ */
93
+ yFormatter?: axisFormatter;
94
+ /**
95
+ * Use custom formatter for tooltip titles
96
+ */
97
+ tooltipTitleFormatter?: (data: T) => string | number;
98
+ /**
99
+ * Optional position for the legend, if applicable.
100
+ * See `LegendPosition` for available options.
101
+ */
102
+ legendPosition?: LegendPosition;
103
+ /**
104
+ * Optional inline CSS styles for the legend container.
105
+ */
106
+ legendStyle?: Record<string, string>;
107
+ /** Options for controlling bubble sizes. */
108
+ sizeOptions?: SizeOptions;
109
+ /**
110
+ * If `true`, displays a domain line (axis line) along the x-axis.
111
+ */
112
+ xDomainLine?: boolean;
113
+ /**
114
+ * If `true`, displays a domain line (axis line) along the y-axis.
115
+ */
116
+ yDomainLine?: boolean;
117
+ /**
118
+ * If `true`, displays tick lines on the x-axis.
119
+ */
120
+ xTickLine?: boolean;
121
+ /**
122
+ * If `true`, displays tick lines on the y-axis.
123
+ */
124
+ yTickLine?: boolean;
125
+ /**
126
+ * If `true`, displays grid lines along the x-axis.
127
+ */
128
+ xGridLine?: boolean;
129
+ /**
130
+ * If `true`, displays grid lines along the y-axis.
131
+ */
132
+ yGridLine?: boolean;
133
+ /**
134
+ * If `true`, hide the x-axis.
135
+ */
136
+ hideXAxis?: boolean;
137
+ /**
138
+ * If `true`, hide the y-axis.
139
+ */
140
+ hideYAxis?: boolean;
141
+ /**
142
+ * The desired number of ticks on the x-axis.
143
+ */
144
+ xNumTicks?: number;
145
+ /**
146
+ * The desired number of ticks on the y-axis.
147
+ */
148
+ yNumTicks?: number;
149
+ /**
150
+ * If `true`, hides the tooltip.
151
+ */
152
+ hideTooltip?: boolean;
153
+ /**
154
+ * Crosshair configuration object for customizing the appearance of the crosshair line.
155
+ */
156
+ crosshairConfig?: CrosshairConfig;
157
+ /**
158
+ * Axis configuration object for customizing the appearance of the axes.
159
+ */
160
+ xAxisConfig?: AxisConfig;
161
+ /**
162
+ * Axis configuration object for customizing the appearance of the axes.
163
+ */
164
+ yAxisConfig?: AxisConfig;
165
+ /**
166
+ * Animation duration in milliseconds for the chart components.
167
+ */
168
+ duration?: number;
169
+ /**
170
+ * Configuration object for the chart tooltip.
171
+ */
172
+ tooltip?: TooltipConfig;
173
+ }
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as D, useSlots as N, useTemplateRef as O, ref as S, computed as p, openBlock as r, createElementBlock as g, normalizeStyle as d, createVNode as c, unref as t, withCtx as R, createBlock as u, createCommentVNode as n, mergeProps as x, createElementVNode as K, renderSlot as k } from "vue";
2
2
  import { Scatter as M, Position as E } from "@unovis/ts";
3
3
  import { VisXYContainer as G, VisTooltip as W, VisScatter as $, VisAxis as L, VisBulletLegend as j } from "@unovis/vue";
4
- import { LegendPosition as X } from "../../packages/shared/dist/index.js";
4
+ import { LegendPosition as X } from "../../enums.js";
5
5
  import Y from "../Tooltip.js";
6
6
  const q = {
7
7
  ref: "slotWrapper",
@@ -1,4 +1,4 @@
1
- import { BubbleChartProps } from './types';
1
+ import { BubbleChartProps } from './BubbleChart';
2
2
  declare const _default: <T>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
3
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
4
  readonly onClick?: ((event: MouseEvent, values?: T | undefined) => any) | undefined;
@@ -0,0 +1,2 @@
1
+ export { default as BubbleChart } from './BubbleChart.vue';
2
+ export * from './BubbleChart';