@economic/taco 2.57.0-charts.8 → 2.57.0

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/taco.js CHANGED
@@ -7719,6 +7719,9 @@ const defaultLocalisationTexts = {
7719
7719
  today: "Today"
7720
7720
  }
7721
7721
  },
7722
+ card: {
7723
+ menu: "Open menu"
7724
+ },
7722
7725
  combobox: {
7723
7726
  tooltip: "Search in list"
7724
7727
  },
@@ -8017,7 +8020,7 @@ const defaultLocalisationTexts = {
8017
8020
  }
8018
8021
  };
8019
8022
  const defaultLocalizationContext = {
8020
- locale: "en-GB",
8023
+ locale: "da-DK",
8021
8024
  texts: defaultLocalisationTexts,
8022
8025
  formatting: {
8023
8026
  date: "dd.mm.yy"
@@ -11630,11 +11633,21 @@ const Content$8 = React.forwardRef(function CardContent(externalProps, ref) {
11630
11633
  });
11631
11634
  const Card = React.forwardRef(function Card2(props, ref) {
11632
11635
  const { title, menu, children, className, ...otherProps } = props;
11636
+ const localization = useLocalization();
11633
11637
  const cardClassName = clsx(
11634
11638
  "bg-white flex flex-col rounded-xl border border-solid border-radius-[12px] border-grey-300 hover:border-grey-500",
11635
11639
  className
11636
11640
  );
11637
- return /* @__PURE__ */ React.createElement("div", { ...otherProps, className: cardClassName, "data-taco": "card", ref }, /* @__PURE__ */ React.createElement("div", { className: "flex justify-between px-4 pb-2 pt-4" }, title && /* @__PURE__ */ React.createElement(Truncate, { tooltip: title }, /* @__PURE__ */ React.createElement("h4", { className: "mb-0 flex-grow truncate text-left" }, title)), menu ? /* @__PURE__ */ React.createElement(IconButton, { icon: "ellipsis-horizontal", appearance: "discrete", menu, className: "-mt-[4px]" }) : null), children);
11641
+ return /* @__PURE__ */ React.createElement("div", { ...otherProps, className: cardClassName, "data-taco": "card", ref }, /* @__PURE__ */ React.createElement("div", { className: "flex justify-between px-4 pb-2 pt-4" }, title && /* @__PURE__ */ React.createElement(Truncate, { tooltip: title }, /* @__PURE__ */ React.createElement("h4", { className: "mb-0 flex-grow truncate text-left" }, title)), menu ? /* @__PURE__ */ React.createElement(
11642
+ IconButton,
11643
+ {
11644
+ "aria-label": localization.texts.card.menu,
11645
+ icon: "ellipsis-horizontal",
11646
+ appearance: "discrete",
11647
+ menu,
11648
+ className: "-mt-[4px]"
11649
+ }
11650
+ ) : null), children);
11638
11651
  });
11639
11652
  Card.Content = Content$8;
11640
11653
  function $010c2913dbd2fe3d$export$5cae361ad82dce8b(value) {
@@ -82743,20 +82756,48 @@ var AreaChart$1 = generateCategoricalChart({
82743
82756
  }],
82744
82757
  formatAxisMap: formatAxisMap2
82745
82758
  });
82746
- function getAxisProps(scale2, tickFormatter, dataKey, width) {
82747
- const isYAxis = dataKey === void 0;
82759
+ function getAxisProps(axis, props, inverted = false) {
82760
+ const { showXAxis = true, showYAxis = false } = props;
82761
+ const isYAxis = axis === "y";
82762
+ let hide2 = isYAxis ? !showYAxis : !showXAxis;
82763
+ let dataKey = isYAxis ? void 0 : props.dataKey;
82764
+ let minTickGap = 5;
82765
+ let type;
82766
+ if (inverted) {
82767
+ dataKey = isYAxis ? props.dataKey : void 0;
82768
+ hide2 = isYAxis ? !showXAxis : !showYAxis;
82769
+ minTickGap = isYAxis ? 1 : minTickGap;
82770
+ type = isYAxis ? "category" : "number";
82771
+ }
82748
82772
  return {
82749
82773
  axisLine: false,
82750
82774
  dataKey,
82751
82775
  fontSize: 11,
82776
+ hide: hide2,
82752
82777
  interval: "preserveStartEnd",
82753
- scale: scale2,
82778
+ minTickGap,
82779
+ scale: isYAxis ? props.yAxisScale : props.xAxisScale,
82754
82780
  tickLine: false,
82755
- tickMargin: isYAxis ? 2 : 6,
82756
- tickFormatter,
82757
- width: width ?? 55
82781
+ tickMargin: axis === "y" ? 2 : 6,
82782
+ tickFormatter: isYAxis ? props.yAxisTickFormatter : props.xAxisTickFormatter,
82783
+ type,
82784
+ width: (isYAxis ? props.yAxisWidth : void 0) ?? 55
82758
82785
  };
82759
82786
  }
82787
+ function stripCartesianProps(props) {
82788
+ const {
82789
+ dataKey,
82790
+ showXAxis,
82791
+ showYAxis,
82792
+ xAxisScale,
82793
+ xAxisTickFormatter,
82794
+ yAxisScale,
82795
+ yAxisTickFormatter,
82796
+ yAxisWidth,
82797
+ ...otherProps
82798
+ } = props;
82799
+ return otherProps;
82800
+ }
82760
82801
  function ChartWrapper(props) {
82761
82802
  const { onSetWidth: handleSetWidth, ...attributes } = props;
82762
82803
  const ref = React__default.useRef(null);
@@ -82772,11 +82813,11 @@ function ChartWrapper(props) {
82772
82813
  function Tooltip(props) {
82773
82814
  const { active, payload = [], style, title } = props;
82774
82815
  if (active && payload.length) {
82775
- return /* @__PURE__ */ React__default.createElement("div", { className: "border-grey-300 z-20 flex flex-col gap-y-1 rounded-md border bg-white px-2 py-1.5 text-xs shadow-sm" }, title ? /* @__PURE__ */ React__default.createElement("span", { className: "font-bold" }, title) : null, /* @__PURE__ */ React__default.createElement("dl", { className: "m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5", style }, payload.map((entry, index2) => {
82816
+ return /* @__PURE__ */ React__default.createElement("div", { className: "border-grey-300 z-20 z-[999] flex flex-col gap-y-1 rounded-md border bg-white px-2 py-1.5 text-xs shadow-sm" }, title ? /* @__PURE__ */ React__default.createElement("span", { className: "font-bold" }, title) : null, /* @__PURE__ */ React__default.createElement("dl", { className: "m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5", style }, payload.map((entry, index2) => {
82776
82817
  const color2 = entry.color ?? entry.payload.color;
82777
82818
  const formatter = entry.formatter ?? entry.payload.formatter;
82778
82819
  const unit2 = entry.unit ?? entry.payload.unit;
82779
- return /* @__PURE__ */ React__default.createElement(React__default.Fragment, { key: `${entry.name}-${index2}` }, /* @__PURE__ */ React__default.createElement("dt", { className: "text-grey-700 mb-0 flex items-center gap-1 font-normal" }, /* @__PURE__ */ React__default.createElement("span", { className: "-mt-px h-2.5 w-2.5 rounded-sm", style: { background: color2 } }), entry.name), /* @__PURE__ */ React__default.createElement("dd", { className: "mb-0 text-right font-bold tabular-nums text-black" }, (formatter == null ? void 0 : formatter(entry.value ?? "", entry.name ?? "", entry, index2, entry.payload)) ?? entry.value, " ", unit2 ? /* @__PURE__ */ React__default.createElement("span", { className: "text-grey-700" }, unit2) : null));
82820
+ return /* @__PURE__ */ React__default.createElement(React__default.Fragment, { key: `${entry.name}-${index2}` }, /* @__PURE__ */ React__default.createElement("dt", { className: "text-grey-700 mb-0 flex items-center gap-1 font-normal", "data-taco": "chart-tooltip" }, /* @__PURE__ */ React__default.createElement("span", { className: "-mt-px h-2.5 w-2.5 rounded-sm", style: { background: color2 } }), entry.name), /* @__PURE__ */ React__default.createElement("dd", { className: "mb-0 text-right font-bold tabular-nums text-black" }, (formatter == null ? void 0 : formatter(entry.value ?? "", entry.name ?? "", entry, index2, entry.payload)) ?? entry.value, " ", unit2 ? /* @__PURE__ */ React__default.createElement("span", { className: "text-grey-700" }, unit2) : null));
82780
82821
  })));
82781
82822
  }
82782
82823
  return null;
@@ -82808,7 +82849,7 @@ function Legend$1(props) {
82808
82849
  return /* @__PURE__ */ React__default.createElement(
82809
82850
  "button",
82810
82851
  {
82811
- key: item.label,
82852
+ key: `${item.label}_${index2}`,
82812
82853
  className: "hover:bg-grey-200 focus-visible:yt-focus flex items-center rounded px-1 !text-xs",
82813
82854
  onClick: (event) => {
82814
82855
  event == null ? void 0 : event.preventDefault();
@@ -82978,7 +83019,8 @@ function useChart(children, options) {
82978
83019
  const [activeIndex, setActiveIndex] = React__default.useState();
82979
83020
  const [hiddenItems, toggleItem] = useChartDataHiddenState();
82980
83021
  const localization = useLocalization();
82981
- const defaultFormatter2 = (value) => new Intl.NumberFormat(localization.locale).format(value);
83022
+ const defaultFormatter2 = (value) => new Intl.NumberFormat(localization.locale, { minimumFractionDigits: 2 }).format(value);
83023
+ const globalFormatter = (options == null ? void 0 : options.formatter) ?? defaultFormatter2;
82982
83024
  const { items, shapes } = React__default.useMemo(() => {
82983
83025
  const items2 = React__default.Children.toArray(children).filter((child) => React__default.isValidElement(child)).map((child) => {
82984
83026
  const dataKey = child.props.dataKey ?? child.props.label;
@@ -82986,7 +83028,7 @@ function useChart(children, options) {
82986
83028
  ...child.props,
82987
83029
  dataKey,
82988
83030
  color: getThemeColor(child.props.color, "blue-300"),
82989
- formatter: child.props.formatter ?? (options == null ? void 0 : options.formatter) ?? defaultFormatter2,
83031
+ formatter: child.props.formatter ?? globalFormatter,
82990
83032
  isHidden: !!hiddenItems[dataKey],
82991
83033
  unit: child.props.unit ?? (options == null ? void 0 : options.unit)
82992
83034
  };
@@ -83013,7 +83055,7 @@ function useChart(children, options) {
83013
83055
  });
83014
83056
  return { items: items2, shapes: shapes2 };
83015
83057
  }, [children, hiddenItems]);
83016
- return { items, shapes, activeIndex, setActiveIndex, toggleItem };
83058
+ return { items, shapes, activeIndex, setActiveIndex, globalFormatter, toggleItem };
83017
83059
  }
83018
83060
  function useChartDataHiddenState() {
83019
83061
  const [state, setState] = React__default.useState({});
@@ -83035,21 +83077,13 @@ function AreaChart(props) {
83035
83077
  children,
83036
83078
  className: customClassName,
83037
83079
  data,
83038
- dataKey,
83039
- showDots = false,
83040
83080
  showLegend = false,
83041
- showXAxis = true,
83042
- showYAxis = false,
83081
+ showDots = false,
83043
83082
  stacked = false,
83044
83083
  tooltipTitle,
83045
83084
  type = "natural",
83046
- xAxisScale,
83047
- xAxisTickFormatter,
83048
- yAxisScale,
83049
- yAxisTickFormatter,
83050
- yAxisWidth,
83051
83085
  ...attributes
83052
- } = props;
83086
+ } = stripCartesianProps(props);
83053
83087
  const className = clsx("relative aspect-video", { "pb-8": showLegend }, customClassName);
83054
83088
  const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart(children);
83055
83089
  return /* @__PURE__ */ React__default.createElement("div", { className, "data-taco": "chart-wrapper" }, /* @__PURE__ */ React__default.createElement(ChartWrapper, { ...attributes, className: "h-full w-full", "data-taco": "chart-area" }, /* @__PURE__ */ React__default.createElement(
@@ -83067,20 +83101,8 @@ function AreaChart(props) {
83067
83101
  },
83068
83102
  /* @__PURE__ */ React__default.createElement(CartesianGrid, { vertical: false }),
83069
83103
  /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip, { title: tooltipTitle }) }),
83070
- /* @__PURE__ */ React__default.createElement(
83071
- XAxis,
83072
- {
83073
- ...getAxisProps(xAxisScale, xAxisTickFormatter, dataKey),
83074
- hide: !showXAxis
83075
- }
83076
- ),
83077
- /* @__PURE__ */ React__default.createElement(
83078
- YAxis,
83079
- {
83080
- ...getAxisProps(yAxisScale, yAxisTickFormatter, void 0, yAxisWidth),
83081
- hide: !showYAxis
83082
- }
83083
- ),
83104
+ /* @__PURE__ */ React__default.createElement(XAxis, { ...getAxisProps("x", props) }),
83105
+ /* @__PURE__ */ React__default.createElement(YAxis, { ...getAxisProps("y", props) }),
83084
83106
  shapes.map((shape) => /* @__PURE__ */ React__default.createElement(
83085
83107
  Area$1,
83086
83108
  {
@@ -83100,24 +83122,18 @@ function Area(_) {
83100
83122
  AreaChart.Area = Area;
83101
83123
  const BAR_WIDTH = 18;
83102
83124
  function BarChart(props) {
83103
- const isHorizontal = props.layout === "horizontal";
83104
83125
  const {
83105
83126
  children,
83106
83127
  className: customClassName,
83107
83128
  data,
83108
- dataKey,
83129
+ orientation,
83109
83130
  showLabels = false,
83110
83131
  showLegend = false,
83111
- showXAxis = !isHorizontal,
83112
- showYAxis = isHorizontal,
83113
83132
  stacked = false,
83114
- xAxisScale,
83115
- xAxisTickFormatter,
83116
- yAxisScale,
83117
- yAxisTickFormatter,
83118
- yAxisWidth,
83133
+ tooltipTitle,
83119
83134
  ...attributes
83120
- } = props;
83135
+ } = stripCartesianProps(props);
83136
+ const isHorizontal = props.orientation === "horizontal";
83121
83137
  const className = clsx("relative aspect-video", { "pb-8": showLegend }, customClassName);
83122
83138
  const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart(children);
83123
83139
  return /* @__PURE__ */ React__default.createElement("div", { className, "data-taco": "chart-wrapper" }, /* @__PURE__ */ React__default.createElement(ChartWrapper, { ...attributes, className: "h-full w-full", "data-taco": "chart-bar" }, /* @__PURE__ */ React__default.createElement(
@@ -83137,29 +83153,9 @@ function BarChart(props) {
83137
83153
  stackOffset: stacked === "expand" ? "expand" : void 0
83138
83154
  },
83139
83155
  /* @__PURE__ */ React__default.createElement(CartesianGrid, { horizontal: !isHorizontal, vertical: false }),
83140
- /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip, null) }),
83141
- /* @__PURE__ */ React__default.createElement(
83142
- XAxis,
83143
- {
83144
- ...getAxisProps(xAxisScale, xAxisTickFormatter, isHorizontal ? void 0 : dataKey),
83145
- hide: !showXAxis,
83146
- type: isHorizontal ? "number" : void 0
83147
- }
83148
- ),
83149
- /* @__PURE__ */ React__default.createElement(
83150
- YAxis,
83151
- {
83152
- ...getAxisProps(
83153
- yAxisScale,
83154
- yAxisTickFormatter,
83155
- isHorizontal ? dataKey : void 0,
83156
- yAxisWidth
83157
- ),
83158
- hide: !showYAxis,
83159
- minTickGap: isHorizontal ? 1 : 5,
83160
- type: isHorizontal ? "category" : void 0
83161
- }
83162
- ),
83156
+ /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip, { title: tooltipTitle }) }),
83157
+ /* @__PURE__ */ React__default.createElement(XAxis, { ...getAxisProps("x", props, isHorizontal) }),
83158
+ /* @__PURE__ */ React__default.createElement(YAxis, { ...getAxisProps("y", props, isHorizontal) }),
83163
83159
  shapes.map((shape, index2) => /* @__PURE__ */ React__default.createElement(
83164
83160
  Bar$1,
83165
83161
  {
@@ -83203,7 +83199,7 @@ BarChart.Bar = Bar;
83203
83199
  const PIE_ACTIVE_WIDTH = 10;
83204
83200
  const PIE_ACTIVE_WIDTH_OFFSET = 2;
83205
83201
  function usePieChart(children, options) {
83206
- const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart(children, options);
83202
+ const { items, shapes, activeIndex, setActiveIndex, globalFormatter, toggleItem } = useChart(children, options);
83207
83203
  const [radius, _setRadius] = React__default.useState(0);
83208
83204
  function setRadius(width) {
83209
83205
  _setRadius((width - 2 * (PIE_ACTIVE_WIDTH + PIE_ACTIVE_WIDTH_OFFSET)) / 2);
@@ -83224,7 +83220,7 @@ function usePieChart(children, options) {
83224
83220
  labelLine: false,
83225
83221
  outerRadius: radius
83226
83222
  };
83227
- return { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, toggleItem, shapes };
83223
+ return { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem, shapes };
83228
83224
  }
83229
83225
  const PIE_CHART_HOVER = 10;
83230
83226
  const PIE_CHART_HOVER_OFFSET = 2;
@@ -83243,18 +83239,21 @@ function ActiveShape$1(props) {
83243
83239
  const DONUT_WIDTH$1 = 20;
83244
83240
  function DonutChart(props) {
83245
83241
  const { children, formatter, showLegend = false, showTotal = false, tooltipTitle, unit: unit2, ...attributes } = props;
83246
- const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, toggleItem } = usePieChart(children, {
83247
- formatter,
83248
- unit: unit2
83249
- });
83242
+ const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem } = usePieChart(
83243
+ children,
83244
+ {
83245
+ formatter,
83246
+ unit: unit2
83247
+ }
83248
+ );
83250
83249
  const className = clsx("aspect-square", attributes.className);
83251
- return /* @__PURE__ */ React__default.createElement("div", { className: "relative", "data-taco": "chart-wrapper" }, /* @__PURE__ */ React__default.createElement(ChartWrapper, { ...attributes, className, "data-taco": "chart-donut", onSetWidth: setRadius }, /* @__PURE__ */ React__default.createElement(PieChart$1, null, /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip$3, { title: tooltipTitle }) }), /* @__PURE__ */ React__default.createElement(Pie, { ...pieProps, innerRadius: radius - DONUT_WIDTH$1 }))), showTotal ? /* @__PURE__ */ React__default.createElement(
83250
+ return /* @__PURE__ */ React__default.createElement("div", { className: "relative", "data-taco": "chart-wrapper" }, /* @__PURE__ */ React__default.createElement(ChartWrapper, { ...attributes, className, "data-taco": "chart-donut", onSetWidth: setRadius }, /* @__PURE__ */ React__default.createElement(PieChart$1, null, /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip, { title: tooltipTitle }) }), /* @__PURE__ */ React__default.createElement(Pie, { ...pieProps, innerRadius: radius - DONUT_WIDTH$1 }))), showTotal ? /* @__PURE__ */ React__default.createElement(
83252
83251
  Total,
83253
83252
  {
83254
- formatter,
83253
+ formatter: globalFormatter,
83255
83254
  items,
83256
83255
  unit: unit2,
83257
- style: { top: radius / 2 - 2, width: radius + DONUT_WIDTH$1 }
83256
+ style: { top: radius + DONUT_WIDTH$1 / 2, width: radius + DONUT_WIDTH$1 * 2 }
83258
83257
  }
83259
83258
  ) : null, showLegend ? /* @__PURE__ */ React__default.createElement(Legend$1, { items, hoverIndex: activeIndex, onHover: setActiveIndex, onToggle: toggleItem }) : null);
83260
83259
  }
@@ -83264,19 +83263,18 @@ function Segment$2(_) {
83264
83263
  DonutChart.Segment = Segment$2;
83265
83264
  function Total(props) {
83266
83265
  const { formatter, items, unit: unit2, ...attributes } = props;
83267
- const localization = useLocalization();
83268
83266
  const total = React__default.useMemo(() => {
83269
83267
  const total2 = items.filter((item) => !item.isHidden).reduce((acc, curr) => acc + curr.value, 0);
83270
- return (formatter == null ? void 0 : formatter(total2)) ?? new Intl.NumberFormat(localization.locale).format(total2);
83268
+ return formatter(total2);
83271
83269
  }, [items]);
83272
83270
  return /* @__PURE__ */ React__default.createElement(
83273
83271
  "div",
83274
83272
  {
83275
83273
  ...attributes,
83276
- className: "absolute-center-x flex aspect-square flex-col items-center justify-center overflow-hidden rounded-full pt-[2px]",
83274
+ className: "absolute-center flex aspect-video flex-col items-center justify-center overflow-hidden rounded-full",
83277
83275
  "data-taco": "chart-donut-total"
83278
83276
  },
83279
- /* @__PURE__ */ React__default.createElement(Tooltip$3, { title: total }, /* @__PURE__ */ React__default.createElement("span", { className: "w-full truncate text-center font-bold tabular-nums" }, total)),
83277
+ /* @__PURE__ */ React__default.createElement(Tooltip$3, { title: total }, /* @__PURE__ */ React__default.createElement("span", { className: "w-full truncate text-center text-lg font-bold tabular-nums" }, total)),
83280
83278
  unit2 ? /* @__PURE__ */ React__default.createElement("span", { className: "text-grey-700 -mb-1 -mt-0.5 truncate text-xs" }, unit2) : null
83281
83279
  );
83282
83280
  }
@@ -83469,20 +83467,12 @@ function LineChart(props) {
83469
83467
  children,
83470
83468
  className: customClassName,
83471
83469
  data,
83472
- dataKey,
83473
- showDots = false,
83474
83470
  showLegend = false,
83475
- showXAxis = true,
83476
- showYAxis = false,
83471
+ showDots = false,
83477
83472
  tooltipTitle,
83478
83473
  type = "natural",
83479
- xAxisScale,
83480
- xAxisTickFormatter,
83481
- yAxisScale,
83482
- yAxisTickFormatter,
83483
- yAxisWidth,
83484
83474
  ...attributes
83485
- } = props;
83475
+ } = stripCartesianProps(props);
83486
83476
  const className = clsx("relative aspect-video", { "pb-8": showLegend }, customClassName);
83487
83477
  const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart(children);
83488
83478
  return /* @__PURE__ */ React__default.createElement("div", { className, "data-taco": "chart-wrapper" }, /* @__PURE__ */ React__default.createElement(ChartWrapper, { ...attributes, className: "h-full w-full", "data-taco": "chart-line" }, /* @__PURE__ */ React__default.createElement(
@@ -83499,20 +83489,8 @@ function LineChart(props) {
83499
83489
  },
83500
83490
  /* @__PURE__ */ React__default.createElement(CartesianGrid, { vertical: false }),
83501
83491
  /* @__PURE__ */ React__default.createElement(Tooltip$1, { content: /* @__PURE__ */ React__default.createElement(Tooltip, { title: tooltipTitle }) }),
83502
- /* @__PURE__ */ React__default.createElement(
83503
- XAxis,
83504
- {
83505
- ...getAxisProps(xAxisScale, xAxisTickFormatter, dataKey),
83506
- hide: !showXAxis
83507
- }
83508
- ),
83509
- /* @__PURE__ */ React__default.createElement(
83510
- YAxis,
83511
- {
83512
- ...getAxisProps(yAxisScale, yAxisTickFormatter, void 0, yAxisWidth),
83513
- hide: !showYAxis
83514
- }
83515
- ),
83492
+ /* @__PURE__ */ React__default.createElement(XAxis, { ...getAxisProps("x", props) }),
83493
+ /* @__PURE__ */ React__default.createElement(YAxis, { ...getAxisProps("y", props) }),
83516
83494
  shapes.map((shape) => /* @__PURE__ */ React__default.createElement(Line$1, { key: shape.dataKey, ...shape, dot: showDots ? shape.dot : false, type }))
83517
83495
  )), showLegend ? /* @__PURE__ */ React__default.createElement(Legend$1, { items, hoverIndex: activeIndex, onHover: setActiveIndex, onToggle: toggleItem }) : null);
83518
83496
  }