@yamada-ui/charts 1.5.0-dev-20240825090212 → 1.5.0-dev-20240825095648

Sign up to get free protection for your applications and to get access to all the features.
Files changed (76) hide show
  1. package/dist/area-chart-split.js +2 -4
  2. package/dist/area-chart-split.js.map +1 -1
  3. package/dist/area-chart-split.mjs +1 -1
  4. package/dist/area-chart.js +47 -47
  5. package/dist/area-chart.js.map +1 -1
  6. package/dist/area-chart.mjs +4 -4
  7. package/dist/bar-chart.js +6 -4
  8. package/dist/bar-chart.js.map +1 -1
  9. package/dist/bar-chart.mjs +3 -3
  10. package/dist/{chunk-NHJDUFKO.mjs → chunk-6ICKO7GY.mjs} +7 -5
  11. package/dist/chunk-6ICKO7GY.mjs.map +1 -0
  12. package/dist/{chunk-WDGSALCA.mjs → chunk-7HKRIEAT.mjs} +2 -2
  13. package/dist/{chunk-PKRKJQQL.mjs → chunk-BNTTQQFO.mjs} +2 -2
  14. package/dist/{chunk-RXQNFP7K.mjs → chunk-DKZISSE6.mjs} +4 -4
  15. package/dist/{chunk-BRSSQCO4.mjs → chunk-FIWHBTKQ.mjs} +8 -6
  16. package/dist/chunk-FIWHBTKQ.mjs.map +1 -0
  17. package/dist/{chunk-TZ62XGYL.mjs → chunk-IF4O4CBA.mjs} +6 -8
  18. package/dist/chunk-IF4O4CBA.mjs.map +1 -0
  19. package/dist/{chunk-UCZQ22IS.mjs → chunk-LF3ENX7Z.mjs} +2 -2
  20. package/dist/{chunk-WRKSJCFE.mjs → chunk-LHW3WK3C.mjs} +6 -5
  21. package/dist/chunk-LHW3WK3C.mjs.map +1 -0
  22. package/dist/{chunk-MGTMKKSH.mjs → chunk-PNE3JG54.mjs} +3 -5
  23. package/dist/chunk-PNE3JG54.mjs.map +1 -0
  24. package/dist/{chunk-LOXFDA6Z.mjs → chunk-Q7CCSKX3.mjs} +3 -3
  25. package/dist/chunk-Q7CCSKX3.mjs.map +1 -0
  26. package/dist/{chunk-VO2I73WT.mjs → chunk-QNX4DJVS.mjs} +3 -3
  27. package/dist/{chunk-WAKQGKGK.mjs → chunk-WPJDHMPD.mjs} +11 -9
  28. package/dist/chunk-WPJDHMPD.mjs.map +1 -0
  29. package/dist/{chunk-ZHM6LP7J.mjs → chunk-WY5PI2CR.mjs} +3 -3
  30. package/dist/donut-chart.js +4 -3
  31. package/dist/donut-chart.js.map +1 -1
  32. package/dist/donut-chart.mjs +2 -2
  33. package/dist/index.js +62 -56
  34. package/dist/index.js.map +1 -1
  35. package/dist/index.mjs +13 -13
  36. package/dist/line-chart.js +7 -5
  37. package/dist/line-chart.js.map +1 -1
  38. package/dist/line-chart.mjs +3 -3
  39. package/dist/pie-chart.js +4 -3
  40. package/dist/pie-chart.js.map +1 -1
  41. package/dist/pie-chart.mjs +2 -2
  42. package/dist/radar-chart.js +4 -3
  43. package/dist/radar-chart.js.map +1 -1
  44. package/dist/radar-chart.mjs +2 -2
  45. package/dist/use-area-chart.js +9 -7
  46. package/dist/use-area-chart.js.map +1 -1
  47. package/dist/use-area-chart.mjs +1 -1
  48. package/dist/use-bar-chart.js +5 -3
  49. package/dist/use-bar-chart.js.map +1 -1
  50. package/dist/use-bar-chart.mjs +1 -1
  51. package/dist/use-chart-reference-line.js +1 -1
  52. package/dist/use-chart-reference-line.js.map +1 -1
  53. package/dist/use-chart-reference-line.mjs +1 -1
  54. package/dist/use-line-chart.js +6 -4
  55. package/dist/use-line-chart.js.map +1 -1
  56. package/dist/use-line-chart.mjs +1 -1
  57. package/dist/use-pie-chart.js +4 -3
  58. package/dist/use-pie-chart.js.map +1 -1
  59. package/dist/use-pie-chart.mjs +1 -1
  60. package/dist/use-radar-chart.js +4 -3
  61. package/dist/use-radar-chart.js.map +1 -1
  62. package/dist/use-radar-chart.mjs +1 -1
  63. package/package.json +3 -3
  64. package/dist/chunk-BRSSQCO4.mjs.map +0 -1
  65. package/dist/chunk-LOXFDA6Z.mjs.map +0 -1
  66. package/dist/chunk-MGTMKKSH.mjs.map +0 -1
  67. package/dist/chunk-NHJDUFKO.mjs.map +0 -1
  68. package/dist/chunk-TZ62XGYL.mjs.map +0 -1
  69. package/dist/chunk-WAKQGKGK.mjs.map +0 -1
  70. package/dist/chunk-WRKSJCFE.mjs.map +0 -1
  71. /package/dist/{chunk-WDGSALCA.mjs.map → chunk-7HKRIEAT.mjs.map} +0 -0
  72. /package/dist/{chunk-PKRKJQQL.mjs.map → chunk-BNTTQQFO.mjs.map} +0 -0
  73. /package/dist/{chunk-RXQNFP7K.mjs.map → chunk-DKZISSE6.mjs.map} +0 -0
  74. /package/dist/{chunk-UCZQ22IS.mjs.map → chunk-LF3ENX7Z.mjs.map} +0 -0
  75. /package/dist/{chunk-VO2I73WT.mjs.map → chunk-QNX4DJVS.mjs.map} +0 -0
  76. /package/dist/{chunk-ZHM6LP7J.mjs.map → chunk-WY5PI2CR.mjs.map} +0 -0
@@ -24,16 +24,14 @@ __export(area_chart_split_exports, {
24
24
  AreaSplit: () => AreaSplit
25
25
  });
26
26
  module.exports = __toCommonJS(area_chart_split_exports);
27
- var import_core = require("@yamada-ui/core");
28
27
  var import_jsx_runtime = require("react/jsx-runtime");
29
28
  var AreaSplit = ({ offset, id, fillOpacity }) => {
30
- const { theme } = (0, import_core.useTheme)();
31
29
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("linearGradient", { id, x1: "0", y1: "0", x2: "0", y2: "1", children: [
32
30
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
33
31
  "stop",
34
32
  {
35
33
  offset,
36
- stopColor: (0, import_core.getVar)(`area-split-0`)(theme),
34
+ stopColor: "var(--ui-area-split-0)",
37
35
  stopOpacity: fillOpacity != null ? fillOpacity : 0.4
38
36
  }
39
37
  ),
@@ -41,7 +39,7 @@ var AreaSplit = ({ offset, id, fillOpacity }) => {
41
39
  "stop",
42
40
  {
43
41
  offset,
44
- stopColor: (0, import_core.getVar)(`area-split-1`)(theme),
42
+ stopColor: "var(--ui-area-split-1)",
45
43
  stopOpacity: fillOpacity != null ? fillOpacity : 0.4
46
44
  }
47
45
  )
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/area-chart-split.tsx"],"sourcesContent":["import { getVar, useTheme } from \"@yamada-ui/core\"\n\nexport type AreaSplitProps = {\n offset: number\n id?: string\n fillOpacity: number | string | undefined\n}\n\nexport const AreaSplit = ({ offset, id, fillOpacity }: AreaSplitProps) => {\n const { theme } = useTheme()\n\n return (\n <linearGradient id={id} x1=\"0\" y1=\"0\" x2=\"0\" y2=\"1\">\n <stop\n offset={offset}\n stopColor={getVar(`area-split-0`)(theme)}\n stopOpacity={fillOpacity ?? 0.4}\n />\n <stop\n offset={offset}\n stopColor={getVar(`area-split-1`)(theme)}\n stopOpacity={fillOpacity ?? 0.4}\n />\n </linearGradient>\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiC;AAY7B;AAJG,IAAM,YAAY,CAAC,EAAE,QAAQ,IAAI,YAAY,MAAsB;AACxE,QAAM,EAAE,MAAM,QAAI,sBAAS;AAE3B,SACE,6CAAC,oBAAe,IAAQ,IAAG,KAAI,IAAG,KAAI,IAAG,KAAI,IAAG,KAC9C;AAAA;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,eAAW,oBAAO,cAAc,EAAE,KAAK;AAAA,QACvC,aAAa,oCAAe;AAAA;AAAA,IAC9B;AAAA,IACA;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,eAAW,oBAAO,cAAc,EAAE,KAAK;AAAA,QACvC,aAAa,oCAAe;AAAA;AAAA,IAC9B;AAAA,KACF;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../src/area-chart-split.tsx"],"sourcesContent":["export type AreaSplitProps = {\n offset: number\n id?: string\n fillOpacity: number | string | undefined\n}\n\nexport const AreaSplit = ({ offset, id, fillOpacity }: AreaSplitProps) => {\n return (\n <linearGradient id={id} x1=\"0\" y1=\"0\" x2=\"0\" y2=\"1\">\n <stop\n offset={offset}\n stopColor=\"var(--ui-area-split-0)\"\n stopOpacity={fillOpacity ?? 0.4}\n />\n <stop\n offset={offset}\n stopColor=\"var(--ui-area-split-1)\"\n stopOpacity={fillOpacity ?? 0.4}\n />\n </linearGradient>\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAQI;AAFG,IAAM,YAAY,CAAC,EAAE,QAAQ,IAAI,YAAY,MAAsB;AACxE,SACE,6CAAC,oBAAe,IAAQ,IAAG,KAAI,IAAG,KAAI,IAAG,KAAI,IAAG,KAC9C;AAAA;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,WAAU;AAAA,QACV,aAAa,oCAAe;AAAA;AAAA,IAC9B;AAAA,IACA;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,WAAU;AAAA,QACV,aAAa,oCAAe;AAAA;AAAA,IAC9B;AAAA,KACF;AAEJ;","names":[]}
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
  import {
3
3
  AreaSplit
4
- } from "./chunk-MGTMKKSH.mjs";
4
+ } from "./chunk-PNE3JG54.mjs";
5
5
  export {
6
6
  AreaSplit
7
7
  };
@@ -24,7 +24,7 @@ __export(area_chart_exports, {
24
24
  AreaChart: () => AreaChart
25
25
  });
26
26
  module.exports = __toCommonJS(area_chart_exports);
27
- var import_core11 = require("@yamada-ui/core");
27
+ var import_core10 = require("@yamada-ui/core");
28
28
  var import_utils11 = require("@yamada-ui/utils");
29
29
  var import_react8 = require("react");
30
30
  var import_recharts = require("recharts");
@@ -48,16 +48,14 @@ var AreaGradient = ({
48
48
  };
49
49
 
50
50
  // src/area-chart-split.tsx
51
- var import_core = require("@yamada-ui/core");
52
51
  var import_jsx_runtime2 = require("react/jsx-runtime");
53
52
  var AreaSplit = ({ offset, id, fillOpacity }) => {
54
- const { theme } = (0, import_core.useTheme)();
55
53
  return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("linearGradient", { id, x1: "0", y1: "0", x2: "0", y2: "1", children: [
56
54
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
57
55
  "stop",
58
56
  {
59
57
  offset,
60
- stopColor: (0, import_core.getVar)(`area-split-0`)(theme),
58
+ stopColor: "var(--ui-area-split-0)",
61
59
  stopOpacity: fillOpacity != null ? fillOpacity : 0.4
62
60
  }
63
61
  ),
@@ -65,7 +63,7 @@ var AreaSplit = ({ offset, id, fillOpacity }) => {
65
63
  "stop",
66
64
  {
67
65
  offset,
68
- stopColor: (0, import_core.getVar)(`area-split-1`)(theme),
66
+ stopColor: "var(--ui-area-split-1)",
69
67
  stopOpacity: fillOpacity != null ? fillOpacity : 0.4
70
68
  }
71
69
  )
@@ -73,20 +71,20 @@ var AreaSplit = ({ offset, id, fillOpacity }) => {
73
71
  };
74
72
 
75
73
  // src/chart-legend.tsx
76
- var import_core4 = require("@yamada-ui/core");
74
+ var import_core3 = require("@yamada-ui/core");
77
75
  var import_utils3 = require("@yamada-ui/utils");
78
76
 
79
77
  // src/use-chart.ts
80
- var import_core3 = require("@yamada-ui/core");
78
+ var import_core2 = require("@yamada-ui/core");
81
79
  var import_utils2 = require("@yamada-ui/utils");
82
80
  var import_react = require("react");
83
81
 
84
82
  // src/chart-utils.ts
85
- var import_core2 = require("@yamada-ui/core");
83
+ var import_core = require("@yamada-ui/core");
86
84
  var import_utils = require("@yamada-ui/utils");
87
85
  var getClassName = (...styles) => (theme) => (0, import_utils.cx)(
88
86
  ...styles.map(
89
- (style) => (0, import_utils.isString)(style) ? style : (0, import_core2.getCSS)(style)(theme)
87
+ (style) => (0, import_utils.isString)(style) ? style : (0, import_core.getCSS)(style)(theme)
90
88
  )
91
89
  );
92
90
  var getComponentProps = ([obj, keys], ...props) => (theme, isContain) => {
@@ -338,7 +336,7 @@ var [ChartProvider, useChartContext] = (0, import_utils2.createContext)({
338
336
  errorMessage: `useChartContext returned is 'undefined'. Seems you forgot to wrap the components in "<LineChart />" or "<BarChart />" etc.`
339
337
  });
340
338
  var useChart = ({ containerProps = {} }) => {
341
- const { theme } = (0, import_core3.useTheme)();
339
+ const { theme } = (0, import_core2.useTheme)();
342
340
  const [reChartsProps, propClassName] = getComponentProps([
343
341
  containerProps,
344
342
  containerProperties
@@ -371,13 +369,13 @@ var useTooltip = ({} = {}) => {
371
369
 
372
370
  // src/chart-legend.tsx
373
371
  var import_jsx_runtime3 = require("react/jsx-runtime");
374
- var ChartLegend = (0, import_core4.forwardRef)(
372
+ var ChartLegend = (0, import_core3.forwardRef)(
375
373
  ({ className, payload = [], onHighlight, ...rest }, ref) => {
376
374
  const { styles } = useLegend();
377
375
  const items = payload.map(({ dataKey, value: valueProp, color }, index) => {
378
376
  const value = dataKey != null ? dataKey : valueProp;
379
377
  return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
380
- import_core4.ui.div,
378
+ import_core3.ui.div,
381
379
  {
382
380
  className: "ui-chart__legend-item",
383
381
  onMouseEnter: () => onHighlight(value),
@@ -385,21 +383,21 @@ var ChartLegend = (0, import_core4.forwardRef)(
385
383
  __css: styles.legendItem,
386
384
  children: [
387
385
  /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
388
- import_core4.ui.div,
386
+ import_core3.ui.div,
389
387
  {
390
388
  className: "ui-chart__legend-swatch",
391
389
  background: color,
392
390
  __css: styles.legendSwatch
393
391
  }
394
392
  ),
395
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_core4.ui.span, { className: "ui-chart__legend-label", children: value })
393
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_core3.ui.span, { className: "ui-chart__legend-label", children: value })
396
394
  ]
397
395
  },
398
396
  `legend-${index}`
399
397
  );
400
398
  });
401
399
  return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
402
- import_core4.ui.div,
400
+ import_core3.ui.div,
403
401
  {
404
402
  ref,
405
403
  className: (0, import_utils3.cx)("ui-chart__legend", className),
@@ -412,10 +410,10 @@ var ChartLegend = (0, import_core4.forwardRef)(
412
410
  );
413
411
 
414
412
  // src/chart-tooltip.tsx
415
- var import_core5 = require("@yamada-ui/core");
413
+ var import_core4 = require("@yamada-ui/core");
416
414
  var import_utils4 = require("@yamada-ui/utils");
417
415
  var import_jsx_runtime4 = require("react/jsx-runtime");
418
- var ChartTooltip = (0, import_core5.forwardRef)(
416
+ var ChartTooltip = (0, import_core4.forwardRef)(
419
417
  ({
420
418
  label,
421
419
  className,
@@ -441,13 +439,13 @@ var ChartTooltip = (0, import_core5.forwardRef)(
441
439
  value = (_a2 = valueFormatter == null ? void 0 : valueFormatter(valueProp)) != null ? _a2 : valueProp;
442
440
  }
443
441
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
444
- import_core5.ui.div,
442
+ import_core4.ui.div,
445
443
  {
446
444
  className: "ui-chart__tooltip-item",
447
445
  __css: styles.tooltipItem,
448
446
  children: [
449
447
  /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
450
- import_core5.ui.div,
448
+ import_core4.ui.div,
451
449
  {
452
450
  className: "ui-chart__tooltip-swatch",
453
451
  background: color,
@@ -455,7 +453,7 @@ var ChartTooltip = (0, import_core5.forwardRef)(
455
453
  }
456
454
  ),
457
455
  /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
458
- import_core5.ui.span,
456
+ import_core4.ui.span,
459
457
  {
460
458
  className: "ui-chart__tooltip-label",
461
459
  __css: styles.tooltipLabel,
@@ -463,7 +461,7 @@ var ChartTooltip = (0, import_core5.forwardRef)(
463
461
  }
464
462
  ),
465
463
  /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
466
- import_core5.ui.span,
464
+ import_core4.ui.span,
467
465
  {
468
466
  className: "ui-chart__tooltip-value",
469
467
  __css: styles.tooltipValue,
@@ -480,15 +478,15 @@ var ChartTooltip = (0, import_core5.forwardRef)(
480
478
  }
481
479
  );
482
480
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
483
- import_core5.ui.div,
481
+ import_core4.ui.div,
484
482
  {
485
483
  ref,
486
484
  className: (0, import_utils4.cx)("ui-chart__tooltip", className),
487
485
  __css: styles.tooltip,
488
486
  ...rest,
489
487
  children: [
490
- label ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_core5.ui.p, { className: "ui-chart__tooltip-title", __css: styles.tooltipTitle, children: (_a = labelFormatter == null ? void 0 : labelFormatter(label)) != null ? _a : label }) : null,
491
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_core5.ui.div, { className: "ui-chart__tooltip-list", __css: styles.tooltipList, children: items })
488
+ label ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_core4.ui.p, { className: "ui-chart__tooltip-title", __css: styles.tooltipTitle, children: (_a = labelFormatter == null ? void 0 : labelFormatter(label)) != null ? _a : label }) : null,
489
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_core4.ui.div, { className: "ui-chart__tooltip-list", __css: styles.tooltipList, children: items })
492
490
  ]
493
491
  }
494
492
  );
@@ -496,7 +494,7 @@ var ChartTooltip = (0, import_core5.forwardRef)(
496
494
  );
497
495
 
498
496
  // src/use-area-chart.ts
499
- var import_core6 = require("@yamada-ui/core");
497
+ var import_core5 = require("@yamada-ui/core");
500
498
  var import_utils5 = require("@yamada-ui/utils");
501
499
  var import_react2 = require("react");
502
500
  var useAreaChart = ({
@@ -522,7 +520,7 @@ var useAreaChart = ({
522
520
  }) => {
523
521
  var _a;
524
522
  const uuid = (0, import_react2.useId)();
525
- const { theme } = (0, import_core6.useTheme)();
523
+ const { theme } = (0, import_core5.useTheme)();
526
524
  const [highlightedArea, setHighlightedArea] = (0, import_react2.useState)(null);
527
525
  const splitId = `${uuid}-split`;
528
526
  const stacked = type === "stacked" || type === "percent";
@@ -537,6 +535,7 @@ var useAreaChart = ({
537
535
  } = (_a = rest.areaProps) != null ? _a : {};
538
536
  const areaColors = (0, import_react2.useMemo)(
539
537
  () => series.map(({ color }, index) => ({
538
+ __prefix: "ui",
540
539
  name: `area-${index}`,
541
540
  token: "colors",
542
541
  value: color != null ? color : "transparent"
@@ -545,6 +544,7 @@ var useAreaChart = ({
545
544
  );
546
545
  const areaSplitColors = (0, import_react2.useMemo)(
547
546
  () => splitColors.map((color, index) => ({
547
+ __prefix: "ui",
548
548
  name: `area-split-${index}`,
549
549
  token: "colors",
550
550
  value: color != null ? color : "transparent"
@@ -553,6 +553,7 @@ var useAreaChart = ({
553
553
  );
554
554
  const referenceLineColors = (0, import_react2.useMemo)(
555
555
  () => referenceLineProps ? referenceLineProps.map(({ color }, index) => ({
556
+ __prefix: "ui",
556
557
  name: `reference-line-${index}`,
557
558
  token: "colors",
558
559
  value: color != null ? color : "transparent"
@@ -564,10 +565,9 @@ var useAreaChart = ({
564
565
  ...areaColors,
565
566
  ...areaSplitColors,
566
567
  ...referenceLineColors,
567
- { name: "fill-opacity", value: fillOpacity }
568
+ { __prefix: "ui", name: "fill-opacity", value: fillOpacity }
568
569
  ];
569
570
  }, [areaColors, areaSplitColors, referenceLineColors, fillOpacity]);
570
- const fillOpacityVar = (0, import_react2.useMemo)(() => (0, import_core6.getVar)("fill-opacity")(theme), [theme]);
571
571
  const [chartProps, areaChartClassName] = (0, import_react2.useMemo)(
572
572
  () => {
573
573
  var _a2;
@@ -642,7 +642,7 @@ var useAreaChart = ({
642
642
  ...computedProps
643
643
  } = props;
644
644
  const id = `${uuid}-${dataKey}`;
645
- const color = (0, import_core6.getVar)(`area-${index}`)(theme);
645
+ const color = `var(--ui-area-${index})`;
646
646
  const dimmed = shouldHighlight && highlightedArea !== dataKey;
647
647
  const computedDimArea = { ...dimAreaProps, ...dimArea2 };
648
648
  const resolvedProps = {
@@ -754,10 +754,10 @@ var useAreaChart = ({
754
754
  (props = {}) => ({
755
755
  id: splitId,
756
756
  offset: splitOffset != null ? splitOffset : defaultSplitOffset,
757
- fillOpacity: fillOpacityVar,
757
+ fillOpacity: "var(--ui-fill-opacity)",
758
758
  ...props
759
759
  }),
760
- [defaultSplitOffset, splitId, splitOffset, fillOpacityVar]
760
+ [defaultSplitOffset, splitId, splitOffset]
761
761
  );
762
762
  const getAreaProps = (0, import_react2.useCallback)(
763
763
  ({ index, className: classNameProp, ...props }, ref = null) => {
@@ -804,10 +804,10 @@ var useAreaChart = ({
804
804
  const getAreaGradientProps = (0, import_react2.useCallback)(
805
805
  (props = {}) => ({
806
806
  withGradient,
807
- fillOpacity: fillOpacityVar,
807
+ fillOpacity: "var(--ui-fill-opacity)",
808
808
  ...props
809
809
  }),
810
- [withGradient, fillOpacityVar]
810
+ [withGradient]
811
811
  );
812
812
  return {
813
813
  getAreaChartProps,
@@ -820,7 +820,7 @@ var useAreaChart = ({
820
820
  };
821
821
 
822
822
  // src/use-chart-axis.ts
823
- var import_core7 = require("@yamada-ui/core");
823
+ var import_core6 = require("@yamada-ui/core");
824
824
  var import_utils6 = require("@yamada-ui/utils");
825
825
  var import_react3 = require("react");
826
826
  var useChartAxis = ({
@@ -840,7 +840,7 @@ var useChartAxis = ({
840
840
  ...rest
841
841
  }) => {
842
842
  var _a, _b, _c, _d;
843
- const { theme } = (0, import_core7.useTheme)();
843
+ const { theme } = (0, import_core6.useTheme)();
844
844
  const xAxisKey = (0, import_react3.useMemo)(
845
845
  () => layoutType === "vertical" ? { type: "number" } : { dataKey },
846
846
  [dataKey, layoutType]
@@ -961,7 +961,7 @@ var valueToPercent = (value) => {
961
961
  };
962
962
 
963
963
  // src/use-chart-grid.ts
964
- var import_core8 = require("@yamada-ui/core");
964
+ var import_core7 = require("@yamada-ui/core");
965
965
  var import_utils7 = require("@yamada-ui/utils");
966
966
  var import_react4 = require("react");
967
967
  var useChartGrid = ({
@@ -970,7 +970,7 @@ var useChartGrid = ({
970
970
  strokeDasharray = "5 5",
971
971
  styles
972
972
  }) => {
973
- const { theme } = (0, import_core8.useTheme)();
973
+ const { theme } = (0, import_core7.useTheme)();
974
974
  const [reChartsProps, propClassName] = getComponentProps(
975
975
  [gridProps, gridProperties],
976
976
  styles.grid
@@ -1015,22 +1015,22 @@ var useChartLegend = ({
1015
1015
  };
1016
1016
 
1017
1017
  // src/use-chart-reference-line.ts
1018
- var import_core9 = require("@yamada-ui/core");
1018
+ var import_core8 = require("@yamada-ui/core");
1019
1019
  var import_utils9 = require("@yamada-ui/utils");
1020
1020
  var import_react6 = require("react");
1021
1021
  var useChartReferenceLine = ({
1022
1022
  referenceLineProps = [],
1023
1023
  styles
1024
1024
  }) => {
1025
- const { theme } = (0, import_core9.useTheme)();
1026
- const styleClassName = (0, import_core9.getCSS)(styles.referenceLine)(theme);
1025
+ const { theme } = (0, import_core8.useTheme)();
1026
+ const styleClassName = (0, import_core8.getCSS)(styles.referenceLine)(theme);
1027
1027
  const propList = (0, import_react6.useMemo)(
1028
1028
  () => referenceLineProps.map((props, index) => {
1029
1029
  const [{ label: labelProp, ...rest }, propClassName] = getComponentProps(
1030
1030
  [props, referenceLineProperties],
1031
1031
  styleClassName
1032
1032
  )(theme);
1033
- const color = (0, import_core9.getVar)(`reference-line-${index}`)(theme);
1033
+ const color = `var(--ui-reference-line-${index})`;
1034
1034
  const label = {
1035
1035
  value: labelProp,
1036
1036
  fill: color,
@@ -1059,7 +1059,7 @@ var useChartReferenceLine = ({
1059
1059
  };
1060
1060
 
1061
1061
  // src/use-chart-tooltip.ts
1062
- var import_core10 = require("@yamada-ui/core");
1062
+ var import_core9 = require("@yamada-ui/core");
1063
1063
  var import_utils10 = require("@yamada-ui/utils");
1064
1064
  var import_react7 = require("react");
1065
1065
  var useChartTooltip = ({
@@ -1067,7 +1067,7 @@ var useChartTooltip = ({
1067
1067
  tooltipAnimationDuration = 0,
1068
1068
  styles
1069
1069
  }) => {
1070
- const { theme } = (0, import_core10.useTheme)();
1070
+ const { theme } = (0, import_core9.useTheme)();
1071
1071
  const { cursor, ...rest } = _tooltipProps;
1072
1072
  const cursorClassName = (0, import_react7.useMemo)(
1073
1073
  () => getClassName({ ...styles.cursor, ...cursor })(theme),
@@ -1095,8 +1095,8 @@ var useChartTooltip = ({
1095
1095
 
1096
1096
  // src/area-chart.tsx
1097
1097
  var import_jsx_runtime5 = require("react/jsx-runtime");
1098
- var AreaChart = (0, import_core11.forwardRef)((props, ref) => {
1099
- const [styles, mergedProps] = (0, import_core11.useMultiComponentStyle)("AreaChart", props);
1098
+ var AreaChart = (0, import_core10.forwardRef)((props, ref) => {
1099
+ const [styles, mergedProps] = (0, import_core10.useMultiComponentStyle)("AreaChart", props);
1100
1100
  const {
1101
1101
  className,
1102
1102
  series,
@@ -1141,7 +1141,7 @@ var AreaChart = (0, import_core11.forwardRef)((props, ref) => {
1141
1141
  splitOffset,
1142
1142
  syncId,
1143
1143
  ...rest
1144
- } = (0, import_core11.omitThemeProps)(mergedProps);
1144
+ } = (0, import_core10.omitThemeProps)(mergedProps);
1145
1145
  const {
1146
1146
  getAreaChartProps,
1147
1147
  getAreaSplitProps,
@@ -1241,7 +1241,7 @@ var AreaChart = (0, import_core11.forwardRef)((props, ref) => {
1241
1241
  [getReferenceLineProps, referenceLineProps]
1242
1242
  );
1243
1243
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ChartProvider, { value: { styles }, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1244
- import_core11.ui.div,
1244
+ import_core10.ui.div,
1245
1245
  {
1246
1246
  ref,
1247
1247
  className: (0, import_utils11.cx)("ui-area-chart", className),