@actioneer/ads 0.5.8 → 0.6.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.
Files changed (40) hide show
  1. package/components/assistant-ui/composer-harness.js +12 -10
  2. package/components/avatar.d.ts +1 -0
  3. package/components/avatar.js +5 -4
  4. package/components/breadcrumbs.d.ts +3 -1
  5. package/components/breadcrumbs.js +62 -56
  6. package/components/button.js +11 -11
  7. package/components/card.js +19 -18
  8. package/components/chart.d.ts +6 -0
  9. package/components/chart.js +747 -657
  10. package/components/date-range-picker.d.ts +25 -0
  11. package/components/date-range-picker.js +187 -0
  12. package/components/drawer.d.ts +3 -1
  13. package/components/drawer.js +115 -95
  14. package/components/index.d.ts +1 -0
  15. package/components/index.js +499 -497
  16. package/components/modal.d.ts +5 -1
  17. package/components/modal.js +74 -61
  18. package/components/panel.js +31 -28
  19. package/components/pixel-icon.d.ts +4 -0
  20. package/components/pixel-icon.js +210 -163
  21. package/components/segmented.d.ts +1 -0
  22. package/components/segmented.js +31 -28
  23. package/components/select.d.ts +5 -0
  24. package/components/select.js +177 -132
  25. package/components/table.d.ts +7 -0
  26. package/components/table.js +183 -173
  27. package/components/tabs.js +1 -1
  28. package/components/tree.js +86 -58
  29. package/components/viz-charts.js +186 -183
  30. package/demo/components/add-to-artifact.js +131 -107
  31. package/demo/lib/artifact-library.js +37 -29
  32. package/demo/lib/artifact-pin-guard.js +12 -0
  33. package/fonts.css +2 -0
  34. package/lib/icons.d.ts +20 -0
  35. package/lib/icons.js +112 -107
  36. package/llms.txt +23 -3
  37. package/manifest.json +13774 -14
  38. package/package.json +4 -1
  39. package/styles.css +76 -60
  40. package/theme.css +70 -57
@@ -1,174 +1,188 @@
1
1
  "use client";
2
- import { jsxs as N, jsx as e, Fragment as V } from "react/jsx-runtime";
3
- import * as k from "react";
4
- import { ResponsiveContainer as j, LineChart as ve, Tooltip as S, Line as ie, AreaChart as be, Area as ge, CartesianGrid as X, XAxis as Z, YAxis as E, BarChart as pe, Bar as le, Cell as oe, ComposedChart as Ne, ScatterChart as we, Scatter as Ae, PieChart as ye, Pie as Ce, RadarChart as ke, PolarGrid as Re, PolarAngleAxis as se, PolarRadiusAxis as Me, Radar as $e, RadialBarChart as Le, RadialBar as Fe, Treemap as Se, ReferenceArea as Oe, ReferenceLine as Te, ReferenceDot as Ie } from "recharts";
5
- import { MotionConfig as Be, AnimatePresence as De, motion as We } from "motion/react";
2
+ import { jsxs as A, jsx as e, Fragment as K } from "react/jsx-runtime";
3
+ import * as R from "react";
4
+ import { ResponsiveContainer as j, LineChart as be, Tooltip as O, Line as se, AreaChart as pe, Area as Ne, CartesianGrid as te, XAxis as ne, YAxis as U, BarChart as we, Bar as ce, Cell as de, ComposedChart as Ae, ScatterChart as Ce, Scatter as ye, PieChart as Re, Pie as ke, RadarChart as Me, PolarGrid as $e, PolarAngleAxis as ue, PolarRadiusAxis as Se, Radar as Le, RadialBarChart as Fe, RadialBar as Oe, Treemap as Te, ReferenceArea as Ie, ReferenceLine as Be, ReferenceDot as De } from "recharts";
5
+ import { MotionConfig as Ee, AnimatePresence as We, motion as ze } from "motion/react";
6
6
  import { cn as $ } from "../lib/cn.js";
7
7
  import { floatVariants as je } from "../lib/motion.js";
8
- const _ = (t) => `var(--color-chart-${t % 6 + 1})`, Y = (t) => _(t), Q = "var(--chart-context)", D = {
8
+ const V = (t) => `var(--color-chart-${t % 6 + 1})`, ee = (t) => V(t), re = "var(--chart-context)", Y = 2.5, He = 2.5, W = {
9
9
  primary: { ref: "var(--brand)", pill: "bg-fill text-fill-foreground" },
10
10
  success: { ref: "var(--color-success-600)", pill: "bg-success-50 text-success-700" },
11
11
  warning: { ref: "var(--color-warning-500)", pill: "bg-warning-50 text-warning-700" },
12
12
  danger: { ref: "var(--color-danger-500)", pill: "bg-danger-50 text-danger-700" },
13
13
  info: { ref: "var(--color-info-500)", pill: "bg-info-50 text-info-700" }
14
- }, F = (t) => new Intl.NumberFormat("en-US", { notation: "compact", maximumFractionDigits: 1 }).format(t), ce = (t, r) => {
15
- const n = [];
16
- for (const l of t)
17
- for (const o of Object.keys(l))
18
- o !== r && typeof l[o] == "number" && !n.includes(o) && n.push(o);
19
- return n;
14
+ }, F = (t) => new Intl.NumberFormat("en-US", { notation: "compact", maximumFractionDigits: 1 }).format(t), me = (t, r) => {
15
+ const a = [];
16
+ for (const i of t)
17
+ for (const o of Object.keys(i))
18
+ o !== r && typeof i[o] == "number" && !a.includes(o) && a.push(o);
19
+ return a;
20
20
  };
21
- function I({ x: t, y: r, payload: n, anchor: l, dy: o, format: a }) {
22
- const s = (n == null ? void 0 : n.value) ?? "", u = a ? a(s) : s;
23
- return /* @__PURE__ */ e("text", { x: t, y: r, dy: o, textAnchor: l, className: "fill-tertiary text-xs tabular-nums", children: u });
21
+ function D({ x: t, y: r, payload: a, anchor: i, dy: o, format: n }) {
22
+ const l = (a == null ? void 0 : a.value) ?? "", x = n ? n(l) : l;
23
+ return /* @__PURE__ */ e("text", { x: t, y: r, dy: o, textAnchor: i, className: "fill-tertiary text-xs tabular-nums", children: x });
24
24
  }
25
- function de({
25
+ function fe({
26
26
  x: t,
27
27
  y: r,
28
- value: n,
29
- hidden: l,
30
- format: o
28
+ value: a,
29
+ hidden: i,
30
+ color: o,
31
+ format: n
31
32
  }) {
32
- if (l || t == null || r == null || n == null || n === "") return null;
33
- const a = Number(n);
34
- return Number.isNaN(a) ? null : /* @__PURE__ */ e(
33
+ if (i || t == null || r == null || a == null || a === "") return null;
34
+ const l = Number(a);
35
+ return Number.isNaN(l) ? null : /* @__PURE__ */ e(
35
36
  "text",
36
37
  {
37
38
  x: Number(t),
38
39
  y: Number(r) - 10,
39
40
  textAnchor: "middle",
40
- className: "fill-secondary text-xs tabular-nums",
41
- children: o(a)
41
+ fill: o,
42
+ className: $(!o && "fill-secondary", "text-xs tabular-nums"),
43
+ children: n(l)
42
44
  }
43
45
  );
44
46
  }
45
- function ze({
47
+ function E({
48
+ cx: t,
49
+ cy: r,
50
+ color: a,
51
+ active: i = !1
52
+ }) {
53
+ return t == null || r == null ? null : /* @__PURE__ */ e(
54
+ "circle",
55
+ {
56
+ "aria-hidden": !0,
57
+ cx: t,
58
+ cy: r,
59
+ r: i ? 5.5 : 4,
60
+ fill: "var(--background)",
61
+ stroke: a,
62
+ strokeWidth: i ? 3 : He
63
+ }
64
+ );
65
+ }
66
+ function Pe({
46
67
  x: t,
47
68
  y: r,
48
- width: n,
49
- height: l,
69
+ width: a,
70
+ height: i,
50
71
  value: o,
51
- format: a,
52
- horizontal: s
72
+ format: n,
73
+ horizontal: l
53
74
  }) {
54
75
  if (t == null || r == null || o == null || o === "") return null;
55
- const u = Number(o);
56
- if (Number.isNaN(u)) return null;
57
- const c = Number(t), f = Number(r), d = Number(n ?? 0), x = Number(l ?? 0);
58
- return s ? /* @__PURE__ */ e(
76
+ const x = Number(o);
77
+ if (Number.isNaN(x)) return null;
78
+ const c = Number(t), m = Number(r), u = Number(a ?? 0), N = Number(i ?? 0);
79
+ return l ? /* @__PURE__ */ e(
59
80
  "text",
60
81
  {
61
- x: c + d + 8,
62
- y: f + x / 2,
82
+ x: c + u + 8,
83
+ y: m + N / 2,
63
84
  dy: "0.32em",
64
85
  textAnchor: "start",
65
86
  className: "fill-secondary text-xs tabular-nums",
66
- children: a(u)
87
+ children: n(x)
67
88
  }
68
89
  ) : /* @__PURE__ */ e(
69
90
  "text",
70
91
  {
71
- x: c + d / 2,
72
- y: f - 8,
92
+ x: c + u / 2,
93
+ y: m - 8,
73
94
  textAnchor: "middle",
74
95
  className: "fill-secondary text-xs tabular-nums",
75
- children: a(u)
96
+ children: n(x)
76
97
  }
77
98
  );
78
99
  }
79
- function q({
80
- cx: t,
81
- cy: r,
82
- fill: n
83
- }) {
84
- return t == null || r == null ? null : /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 4.5, fill: n, stroke: "var(--background)", strokeWidth: 2 });
85
- }
86
- function O({
100
+ function T({
87
101
  active: t,
88
102
  payload: r,
89
- label: n,
90
- format: l,
103
+ label: a,
104
+ format: i,
91
105
  labelKey: o,
92
- renderer: a
106
+ renderer: n
93
107
  }) {
94
- var x, v;
95
- const s = (r ?? []).map((m, b) => {
96
- const w = m.payload && typeof m.payload == "object" ? m.payload : void 0;
108
+ var N, b;
109
+ const l = (r ?? []).map((f, y) => {
110
+ const C = f.payload && typeof f.payload == "object" ? f.payload : void 0;
97
111
  return {
98
- key: m.dataKey ?? b,
99
- name: m.name ?? m.dataKey ?? b,
100
- value: m.value,
101
- color: m.color,
102
- datum: w
112
+ key: f.dataKey ?? y,
113
+ name: f.name ?? f.dataKey ?? y,
114
+ value: f.value,
115
+ color: f.color,
116
+ datum: C
103
117
  };
104
- }), u = o ? (v = (x = s[0]) == null ? void 0 : x.datum) == null ? void 0 : v[o] : void 0, c = {
118
+ }), x = o ? (b = (N = l[0]) == null ? void 0 : N.datum) == null ? void 0 : b[o] : void 0, c = {
105
119
  active: !!t,
106
- label: typeof u == "string" || typeof u == "number" ? u : n,
107
- items: s,
108
- formatValue: l
120
+ label: typeof x == "string" || typeof x == "number" ? x : a,
121
+ items: l,
122
+ formatValue: i
109
123
  };
110
- if (a) return /* @__PURE__ */ e(V, { children: a(c) });
111
- if (!c.active || !s.length) return null;
112
- const f = s.length === 1, d = c.label ?? (f ? s[0].name : void 0);
113
- return /* @__PURE__ */ N("div", { className: "rounded-md bg-foreground px-2.5 py-1.5 text-xs text-background", children: [
114
- /* @__PURE__ */ e("div", { className: $("text-xs font-normal tracking-wide uppercase text-background/60", !f && "mb-1"), children: d }),
115
- s.map((m) => /* @__PURE__ */ N("div", { className: "flex items-center gap-1.5", children: [
116
- !f && /* @__PURE__ */ N(V, { children: [
117
- /* @__PURE__ */ e("span", { "aria-hidden": !0, className: "size-1.5 rounded-dot", style: { background: m.color } }),
118
- /* @__PURE__ */ e("span", { className: "text-background/70", children: m.name })
124
+ if (n) return /* @__PURE__ */ e(K, { children: n(c) });
125
+ if (!c.active || !l.length) return null;
126
+ const m = l.length === 1, u = c.label ?? (m ? l[0].name : void 0);
127
+ return /* @__PURE__ */ A("div", { className: "rounded-md bg-foreground px-2.5 py-1.5 text-xs text-background", children: [
128
+ /* @__PURE__ */ e("div", { className: $("text-xs font-normal tracking-wide uppercase text-background/60", !m && "mb-1"), children: u }),
129
+ l.map((f) => /* @__PURE__ */ A("div", { className: "flex items-center gap-1.5", children: [
130
+ !m && /* @__PURE__ */ A(K, { children: [
131
+ /* @__PURE__ */ e("span", { "aria-hidden": !0, className: "size-1.5 rounded-dot", style: { background: f.color } }),
132
+ /* @__PURE__ */ e("span", { className: "text-background/70", children: f.name })
119
133
  ] }),
120
- /* @__PURE__ */ e("span", { className: "ml-auto pl-3 font-normal tabular-nums", children: typeof m.value == "number" ? l(m.value) : String(m.value ?? "") })
121
- ] }, m.key))
134
+ /* @__PURE__ */ e("span", { className: "ml-auto pl-3 font-normal tabular-nums", children: typeof f.value == "number" ? i(f.value) : String(f.value ?? "") })
135
+ ] }, f.key))
122
136
  ] });
123
137
  }
124
- const ue = "pointer-events-none inline-flex min-h-4 items-center rounded-full px-2 py-0.5 text-xs font-normal whitespace-nowrap";
125
- function Pe({
138
+ const he = "pointer-events-none inline-flex min-h-4 items-center rounded-full px-2 py-0.5 text-xs font-normal whitespace-nowrap";
139
+ function _e({
126
140
  viewBox: t,
127
141
  label: r,
128
- value: n,
129
- color: l,
142
+ value: a,
143
+ color: i,
130
144
  axis: o
131
145
  }) {
132
- const a = t ?? {}, s = /* @__PURE__ */ N("span", { className: $(ue, D[l].pill), children: [
146
+ const n = t ?? {}, l = /* @__PURE__ */ A("span", { className: $(he, W[i].pill), children: [
133
147
  r,
134
- n != null && /* @__PURE__ */ e("span", { className: "ml-1 tabular-nums", children: n })
148
+ a != null && /* @__PURE__ */ e("span", { className: "ml-1 tabular-nums", children: a })
135
149
  ] });
136
- return o === "y" ? /* @__PURE__ */ e("foreignObject", { x: a.x ?? 0, y: (a.y ?? 0) - 12, width: a.width ?? 0, height: 24, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center justify-end pr-1", children: s }) }) : /* @__PURE__ */ e("foreignObject", { x: (a.x ?? 0) - 90, y: (a.y ?? 0) - 12, width: 180, height: 24, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center justify-center", children: s }) });
150
+ return o === "y" ? /* @__PURE__ */ e("foreignObject", { x: n.x ?? 0, y: (n.y ?? 0) - 12, width: n.width ?? 0, height: 24, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center justify-end pr-1", children: l }) }) : /* @__PURE__ */ e("foreignObject", { x: (n.x ?? 0) - 90, y: (n.y ?? 0) - 12, width: 180, height: 24, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center justify-center", children: l }) });
137
151
  }
138
- function Ee({ viewBox: t, label: r, color: n }) {
139
- const l = t ?? {};
140
- return /* @__PURE__ */ e("foreignObject", { x: l.x ?? 0, y: l.y ?? 0, width: l.width ?? 0, height: 28, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center pl-1.5", children: /* @__PURE__ */ e("span", { className: $(ue, D[n].pill), children: r }) }) });
152
+ function Ge({ viewBox: t, label: r, color: a }) {
153
+ const i = t ?? {};
154
+ return /* @__PURE__ */ e("foreignObject", { x: i.x ?? 0, y: i.y ?? 0, width: i.width ?? 0, height: 28, className: "overflow-visible", children: /* @__PURE__ */ e("div", { className: "flex h-full items-center pl-1.5", children: /* @__PURE__ */ e("span", { className: $(he, W[a].pill), children: r }) }) });
141
155
  }
142
- function _e({
156
+ function Ue({
143
157
  cx: t,
144
158
  cy: r,
145
- n,
146
- ann: l,
159
+ n: a,
160
+ ann: i,
147
161
  onEnter: o,
148
- onLeave: a
162
+ onLeave: n
149
163
  }) {
150
- const [s, u] = k.useState(!1);
164
+ const [l, x] = R.useState(!1);
151
165
  if (t == null || r == null || !Number.isFinite(t) || !Number.isFinite(r)) return /* @__PURE__ */ e("g", {});
152
- const c = () => o({ ann: l, n, cx: t, cy: r }), f = () => a();
153
- return /* @__PURE__ */ N(
166
+ const c = () => o({ ann: i, n: a, cx: t, cy: r }), m = () => n();
167
+ return /* @__PURE__ */ A(
154
168
  "g",
155
169
  {
156
170
  tabIndex: 0,
157
171
  role: "img",
158
- "aria-label": `Annotation ${n}: ${l.label}`,
172
+ "aria-label": `Annotation ${a}: ${i.label}`,
159
173
  className: "cursor-default outline-none [transform-box:fill-box] origin-center transition-transform ease-out [transition-duration:150ms] hover:scale-110 focus-visible:scale-110 motion-reduce:transition-none motion-reduce:hover:scale-100 motion-reduce:focus-visible:scale-100",
160
174
  onMouseEnter: c,
161
- onMouseLeave: f,
175
+ onMouseLeave: m,
162
176
  onFocus: () => {
163
- u(!0), c();
177
+ x(!0), c();
164
178
  },
165
179
  onBlur: () => {
166
- u(!1), f();
180
+ x(!1), m();
167
181
  },
168
182
  children: [
169
- s && /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 12, fill: "none", stroke: "var(--ring)", strokeWidth: 2 }),
183
+ l && /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 12, fill: "none", stroke: "var(--ring)", strokeWidth: 2 }),
170
184
  /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 10, fill: "var(--background)" }),
171
- /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 8, fill: D[l.color ?? "primary"].ref }),
185
+ /* @__PURE__ */ e("circle", { cx: t, cy: r, r: 8, fill: W[i.color ?? "primary"].ref }),
172
186
  /* @__PURE__ */ e(
173
187
  "text",
174
188
  {
@@ -177,15 +191,15 @@ function _e({
177
191
  dy: "0.35em",
178
192
  textAnchor: "middle",
179
193
  className: "pointer-events-none fill-brand-foreground text-xs font-medium select-none",
180
- children: n
194
+ children: a
181
195
  }
182
196
  )
183
197
  ]
184
198
  }
185
199
  );
186
200
  }
187
- function Ge({ hovered: t, frameWidth: r, format: n }) {
188
- return /* @__PURE__ */ e(Be, { reducedMotion: "user", children: /* @__PURE__ */ e(De, { children: t && /* @__PURE__ */ e(
201
+ function Ve({ hovered: t, frameWidth: r, format: a }) {
202
+ return /* @__PURE__ */ e(Ee, { reducedMotion: "user", children: /* @__PURE__ */ e(We, { children: t && /* @__PURE__ */ e(
189
203
  "div",
190
204
  {
191
205
  className: "pointer-events-none absolute z-10",
@@ -193,8 +207,8 @@ function Ge({ hovered: t, frameWidth: r, format: n }) {
193
207
  left: Math.max(96, Math.min(t.cx, Math.max(r - 96, 96))),
194
208
  top: t.cy - 16
195
209
  },
196
- children: /* @__PURE__ */ N(
197
- We.div,
210
+ children: /* @__PURE__ */ A(
211
+ ze.div,
198
212
  {
199
213
  variants: je,
200
214
  initial: "hidden",
@@ -202,23 +216,23 @@ function Ge({ hovered: t, frameWidth: r, format: n }) {
202
216
  exit: "hidden",
203
217
  className: "w-max max-w-60 -translate-x-1/2 -translate-y-full origin-bottom rounded-lg bg-elevated p-3 shadow-elevation",
204
218
  children: [
205
- /* @__PURE__ */ N("div", { className: "flex items-center gap-2", children: [
219
+ /* @__PURE__ */ A("div", { className: "flex items-center gap-2", children: [
206
220
  /* @__PURE__ */ e(
207
221
  "span",
208
222
  {
209
223
  "aria-hidden": !0,
210
224
  className: "flex size-4.5 shrink-0 items-center justify-center rounded-full text-xs font-medium text-brand-foreground",
211
- style: { background: D[t.ann.color ?? "primary"].ref },
225
+ style: { background: W[t.ann.color ?? "primary"].ref },
212
226
  children: t.n
213
227
  }
214
228
  ),
215
229
  /* @__PURE__ */ e("span", { className: "text-xs font-normal text-foreground", children: t.ann.label })
216
230
  ] }),
217
231
  t.ann.description && /* @__PURE__ */ e("p", { className: "mt-1.5 text-xs leading-relaxed text-secondary", children: t.ann.description }),
218
- /* @__PURE__ */ N("div", { className: "mt-1.5 text-xs font-normal tracking-wide uppercase text-tertiary tabular-nums", children: [
232
+ /* @__PURE__ */ A("div", { className: "mt-1.5 text-xs font-normal tracking-wide uppercase text-tertiary tabular-nums", children: [
219
233
  t.ann.x,
220
234
  " · ",
221
- n(t.ann.y)
235
+ a(t.ann.y)
222
236
  ] })
223
237
  ]
224
238
  }
@@ -226,299 +240,362 @@ function Ge({ hovered: t, frameWidth: r, format: n }) {
226
240
  }
227
241
  ) }) });
228
242
  }
229
- function me(t, r) {
230
- const [n, l] = k.useState(null), o = k.useCallback(() => l(null), []), { back: a, front: s } = k.useMemo(() => {
231
- const u = [], c = [];
232
- let f = 0;
233
- return (t ?? []).forEach((d, x) => {
234
- const v = d.color ?? "primary";
235
- if (d.kind === "band") {
236
- const m = d.axis ?? "y";
237
- u.push(
243
+ function xe(t, r) {
244
+ const [a, i] = R.useState(null), o = R.useCallback(() => i(null), []), { back: n, front: l } = R.useMemo(() => {
245
+ const x = [], c = [];
246
+ let m = 0;
247
+ return (t ?? []).forEach((u, N) => {
248
+ const b = u.color ?? "primary";
249
+ if (u.kind === "band") {
250
+ const f = u.axis ?? "y";
251
+ x.push(
238
252
  /* @__PURE__ */ e(
239
- Oe,
253
+ Ie,
240
254
  {
241
- ...m === "y" ? { y1: d.from, y2: d.to } : { x1: d.from, x2: d.to },
242
- fill: D[v].ref,
255
+ ...f === "y" ? { y1: u.from, y2: u.to } : { x1: u.from, x2: u.to },
256
+ fill: W[b].ref,
243
257
  fillOpacity: 0.06,
244
258
  stroke: "none",
245
- ifOverflow: m === "y" ? "extendDomain" : "visible",
246
- label: d.label ? /* @__PURE__ */ e(Ee, { label: d.label, color: v }) : void 0
259
+ ifOverflow: f === "y" ? "extendDomain" : "visible",
260
+ label: u.label ? /* @__PURE__ */ e(Ge, { label: u.label, color: b }) : void 0
247
261
  },
248
- `ann-${x}`
262
+ `ann-${N}`
249
263
  )
250
264
  );
251
- } else if (d.kind === "line") {
252
- const m = d.axis ?? "y";
265
+ } else if (u.kind === "line") {
266
+ const f = u.axis ?? "y";
253
267
  c.push(
254
268
  /* @__PURE__ */ e(
255
- Te,
269
+ Be,
256
270
  {
257
- ...m === "y" ? { y: d.value } : { x: d.value },
258
- stroke: D[v].ref,
271
+ ...f === "y" ? { y: u.value } : { x: u.value },
272
+ stroke: W[b].ref,
259
273
  strokeWidth: 1,
260
274
  strokeDasharray: "4 4",
261
- ifOverflow: m === "y" ? "extendDomain" : "visible",
262
- label: d.label ? /* @__PURE__ */ e(
263
- Pe,
275
+ ifOverflow: f === "y" ? "extendDomain" : "visible",
276
+ label: u.label ? /* @__PURE__ */ e(
277
+ _e,
264
278
  {
265
- label: d.label,
266
- value: typeof d.value == "number" ? r(d.value) : String(d.value),
267
- color: v,
268
- axis: m
279
+ label: u.label,
280
+ value: typeof u.value == "number" ? r(u.value) : String(u.value),
281
+ color: b,
282
+ axis: f
269
283
  }
270
284
  ) : void 0
271
285
  },
272
- `ann-${x}`
286
+ `ann-${N}`
273
287
  )
274
288
  );
275
289
  } else {
276
- f += 1;
277
- const m = f;
290
+ m += 1;
291
+ const f = m;
278
292
  c.push(
279
293
  /* @__PURE__ */ e(
280
- Ie,
294
+ De,
281
295
  {
282
- x: d.x,
283
- y: d.y,
296
+ x: u.x,
297
+ y: u.y,
284
298
  ifOverflow: "visible",
285
- shape: (b) => /* @__PURE__ */ e(_e, { cx: b.cx, cy: b.cy, n: m, ann: d, onEnter: l, onLeave: o })
299
+ shape: (y) => /* @__PURE__ */ e(Ue, { cx: y.cx, cy: y.cy, n: f, ann: u, onEnter: i, onLeave: o })
286
300
  },
287
- `ann-${x}`
301
+ `ann-${N}`
288
302
  )
289
303
  );
290
304
  }
291
- }), { back: u, front: c };
305
+ }), { back: x, front: c };
292
306
  }, [t, r, o]);
293
- return { back: a, front: s, hovered: n };
307
+ return { back: n, front: l, hovered: a };
294
308
  }
295
- function G({
309
+ function X({
296
310
  items: t,
297
311
  align: r = "end",
298
- className: n
312
+ className: a,
313
+ onToggle: i
299
314
  }) {
300
- const l = {
315
+ const o = {
301
316
  start: "justify-start",
302
317
  center: "justify-center",
303
318
  end: "justify-end"
304
319
  }[r];
305
- return /* @__PURE__ */ e("div", { className: $("mb-3 flex flex-wrap items-center gap-x-4 gap-y-1", l, n), children: t.map((o) => /* @__PURE__ */ N("span", { className: "inline-flex items-center gap-1.5 text-xs text-secondary", children: [
306
- /* @__PURE__ */ e("span", { "aria-hidden": !0, className: "size-2 rounded-dot", style: { background: o.color } }),
307
- o.label
308
- ] }, o.label)) });
320
+ return /* @__PURE__ */ e("div", { className: $("mb-3 flex flex-wrap items-center gap-x-4 gap-y-1", o, a), children: t.map(
321
+ (n) => i && n.key !== void 0 ? /* @__PURE__ */ A(
322
+ "button",
323
+ {
324
+ type: "button",
325
+ "aria-pressed": !n.hidden,
326
+ "aria-label": `Toggle ${n.label} series`,
327
+ onClick: () => i(n.key),
328
+ className: $(
329
+ "inline-flex cursor-pointer items-center gap-1.5 rounded-sm text-xs outline-none",
330
+ "transition-colors duration-150 ease-out motion-reduce:transition-none",
331
+ "focus-visible:ring-2 focus-visible:ring-ring",
332
+ n.hidden ? "text-tertiary" : "text-secondary hover:text-foreground"
333
+ ),
334
+ children: [
335
+ /* @__PURE__ */ e(
336
+ "span",
337
+ {
338
+ "aria-hidden": !0,
339
+ className: $(
340
+ "size-2 rounded-dot transition-opacity duration-150 ease-out motion-reduce:transition-none",
341
+ n.hidden && "opacity-25"
342
+ ),
343
+ style: { background: n.color }
344
+ }
345
+ ),
346
+ n.label
347
+ ]
348
+ },
349
+ n.label
350
+ ) : /* @__PURE__ */ A("span", { className: "inline-flex items-center gap-1.5 text-xs text-secondary", children: [
351
+ /* @__PURE__ */ e("span", { "aria-hidden": !0, className: "size-2 rounded-dot", style: { background: n.color } }),
352
+ n.label
353
+ ] }, n.label)
354
+ ) });
309
355
  }
310
- const W = k.forwardRef(
311
- ({ className: t, height: r, legendItems: n, hovered: l, format: o, children: a, ...s }, u) => {
312
- var d;
313
- const c = k.useRef(null);
314
- return /* @__PURE__ */ N("div", { ref: (x) => {
315
- c.current = x, typeof u == "function" ? u(x) : u && (u.current = x);
316
- }, className: $("relative w-full font-sans", t), ...s, children: [
317
- n && /* @__PURE__ */ e(G, { items: n }),
318
- /* @__PURE__ */ e(j, { width: "100%", height: Math.max(r, T), children: a }),
319
- /* @__PURE__ */ e(Ge, { hovered: l, frameWidth: ((d = c.current) == null ? void 0 : d.clientWidth) ?? 0, format: o })
356
+ const z = R.forwardRef(
357
+ ({ className: t, height: r, legendItems: a, hovered: i, format: o, onLegendToggle: n, children: l, ...x }, c) => {
358
+ var N;
359
+ const m = R.useRef(null);
360
+ return /* @__PURE__ */ A("div", { ref: (b) => {
361
+ m.current = b, typeof c == "function" ? c(b) : c && (c.current = b);
362
+ }, className: $("relative w-full font-sans", t), ...x, children: [
363
+ a && /* @__PURE__ */ e(X, { items: a, onToggle: n }),
364
+ /* @__PURE__ */ e(j, { width: "100%", height: Math.max(r, I), children: l }),
365
+ /* @__PURE__ */ e(Ve, { hovered: i, frameWidth: ((N = m.current) == null ? void 0 : N.clientWidth) ?? 0, format: o })
320
366
  ] });
321
367
  }
322
368
  );
323
- W.displayName = "ChartFrame";
324
- function H(t) {
369
+ z.displayName = "ChartFrame";
370
+ function Z(t) {
325
371
  const {
326
372
  data: r,
327
- categoryKey: n,
328
- series: l,
373
+ categoryKey: a,
374
+ series: i,
329
375
  seriesLabels: o,
330
- highlight: a,
331
- annotations: s,
332
- grid: u = !1,
376
+ highlight: n,
377
+ annotations: l,
378
+ grid: x = !1,
333
379
  legend: c,
334
- showYAxis: f = !0,
335
- formatValue: d,
336
- xScale: x = "category",
337
- xDomain: v,
338
- yDomain: m,
339
- xTickFormatter: b,
340
- yTickFormatter: w,
341
- yAxisWidth: A = 44
342
- } = t, p = k.useMemo(() => l ?? ce(r, n), [l, r, n]), i = d ?? F, h = w ?? ((M) => typeof M == "number" ? i(M) : M), y = me(s, i), C = (M, B) => a && p.includes(a) ? M === a ? "var(--color-chart-1)" : Q : _(B), R = (M) => (o == null ? void 0 : o[M]) ?? M, g = c ?? p.length > 1 ? p.map((M, B) => ({ label: R(M), color: C(M, B) })) : null;
343
- return { names: p, format: i, layers: y, legendItems: g, furniture: [
344
- /* Gridlines one step below the border token — guides, not content. */
345
- u ? /* @__PURE__ */ e(X, { vertical: !1, stroke: "var(--chart-grid)" }, "grid") : null,
346
- /* @__PURE__ */ e(
347
- Z,
348
- {
349
- dataKey: n,
350
- type: x === "time" ? "number" : "category",
351
- scale: x === "time" ? "time" : "auto",
352
- domain: x === "time" ? v ?? ["dataMin", "dataMax"] : v,
353
- allowDataOverflow: !!v,
354
- axisLine: { stroke: "var(--chart-axis)" },
355
- tickLine: !1,
356
- minTickGap: 28,
357
- tickMargin: 24,
358
- padding: { left: 16, right: 16 },
359
- height: 40,
360
- tick: /* @__PURE__ */ e(I, { anchor: "middle", dy: 0, format: b })
361
- },
362
- "x"
363
- ),
364
- f ? /* @__PURE__ */ e(
365
- E,
366
- {
367
- width: A,
368
- domain: m,
369
- allowDataOverflow: !!m,
370
- axisLine: { stroke: "var(--chart-axis)" },
371
- tickLine: !1,
372
- tickMargin: 12,
373
- tick: /* @__PURE__ */ e(I, { anchor: "end", dy: "0.32em", format: h })
374
- },
375
- "y"
376
- ) : null
377
- ], colorFor: C, labelFor: R };
380
+ showYAxis: m = !0,
381
+ formatValue: u,
382
+ xScale: N = "category",
383
+ xDomain: b,
384
+ yDomain: f,
385
+ xTickFormatter: y,
386
+ yTickFormatter: C,
387
+ yAxisWidth: w = 44
388
+ } = t, p = R.useMemo(() => i ?? me(r, a), [i, r, a]), h = u ?? F, k = C ?? ((M) => typeof M == "number" ? h(M) : M), d = xe(l, h), s = (M, B) => n && p.includes(n) ? M === n ? "var(--color-chart-1)" : re : V(B), v = (M) => (o == null ? void 0 : o[M]) ?? M, [g, S] = R.useState(
389
+ () => /* @__PURE__ */ new Set()
390
+ ), L = R.useCallback((M) => {
391
+ S((B) => {
392
+ const _ = new Set(B);
393
+ return _.has(M) ? _.delete(M) : _.add(M), _;
394
+ });
395
+ }, []), P = (M) => g.has(M), Q = c ?? p.length > 1 ? p.map((M, B) => ({
396
+ key: M,
397
+ label: v(M),
398
+ color: s(M, B),
399
+ hidden: g.has(M)
400
+ })) : null;
401
+ return {
402
+ names: p,
403
+ format: h,
404
+ layers: d,
405
+ legendItems: Q,
406
+ furniture: [
407
+ /* Gridlines one step below the border token — guides, not content. */
408
+ x ? /* @__PURE__ */ e(te, { vertical: !1, stroke: "var(--chart-grid)" }, "grid") : null,
409
+ /* @__PURE__ */ e(
410
+ ne,
411
+ {
412
+ dataKey: a,
413
+ type: N === "time" ? "number" : "category",
414
+ scale: N === "time" ? "time" : "auto",
415
+ domain: N === "time" ? b ?? ["dataMin", "dataMax"] : b,
416
+ allowDataOverflow: !!b,
417
+ axisLine: { stroke: "var(--chart-axis)" },
418
+ tickLine: !1,
419
+ minTickGap: 28,
420
+ tickMargin: 24,
421
+ padding: { left: 16, right: 16 },
422
+ height: 40,
423
+ tick: /* @__PURE__ */ e(D, { anchor: "middle", dy: 0, format: y })
424
+ },
425
+ "x"
426
+ ),
427
+ m ? /* @__PURE__ */ e(
428
+ U,
429
+ {
430
+ width: w,
431
+ domain: f,
432
+ allowDataOverflow: !!f,
433
+ axisLine: { stroke: "var(--chart-axis)" },
434
+ tickLine: !1,
435
+ tickMargin: 12,
436
+ tick: /* @__PURE__ */ e(D, { anchor: "end", dy: "0.32em", format: k })
437
+ },
438
+ "y"
439
+ ) : null
440
+ ],
441
+ colorFor: s,
442
+ labelFor: v,
443
+ toggleSeries: L,
444
+ isHidden: P
445
+ };
378
446
  }
379
- const T = 300, z = { top: 24, right: 12, bottom: 8, left: 0 };
380
- function J(t, r, n, l) {
381
- if (l === !0) return new Set(t);
382
- if (l === !1) return /* @__PURE__ */ new Set();
383
- if (n && t.includes(n)) {
384
- const a = (r ?? []).filter((s) => s !== n);
385
- return /* @__PURE__ */ new Set([n, ...a]);
447
+ const I = 300, H = { top: 24, right: 12, bottom: 8, left: 0 };
448
+ function ae(t, r, a, i) {
449
+ if (i === !0) return new Set(t);
450
+ if (i === !1) return /* @__PURE__ */ new Set();
451
+ if (a && t.includes(a)) {
452
+ const n = (r ?? []).filter((l) => l !== a);
453
+ return /* @__PURE__ */ new Set([a, ...n]);
386
454
  }
387
- return t.filter((a) => !(r != null && r.includes(a))).length === 1 ? new Set(t) : /* @__PURE__ */ new Set();
455
+ return t.filter((n) => !(r != null && r.includes(n))).length === 1 ? new Set(t) : /* @__PURE__ */ new Set();
388
456
  }
389
- function fe(t, r, n) {
390
- return k.useCallback(
391
- (l, o) => {
392
- if (!(r != null && r.includes(l))) return n(l, o);
393
- const a = t.filter((u) => !r.includes(u)), s = a[r.indexOf(l)] ?? a[0];
394
- return s ? n(s, t.indexOf(s)) : n(l, o);
457
+ function ge(t, r, a) {
458
+ return R.useCallback(
459
+ (i, o) => {
460
+ if (!(r != null && r.includes(i))) return a(i, o);
461
+ const n = t.filter((x) => !r.includes(x)), l = n[r.indexOf(i)] ?? n[0];
462
+ return l ? a(l, t.indexOf(l)) : a(i, o);
395
463
  },
396
- [t, r, n]
464
+ [t, r, a]
397
465
  );
398
466
  }
399
- const He = k.forwardRef(
467
+ const Ye = R.forwardRef(
400
468
  // Straight segments by default: the house line is a solid stroke with a DOT
401
469
  // at every observation — the data points are visible, the path connects them
402
470
  // without inventing values between them.
403
471
  // A smooth curve invents values between observations; opt back in with
404
472
  // `curve="natural"` when the interpolation is the point.
405
- ({ height: t = T, curve: r = "linear", forecastKeys: n, showValues: l, className: o, ...a }, s) => {
406
- const { names: u, format: c, layers: f, legendItems: d, furniture: x, colorFor: v, labelFor: m } = H(a), b = fe(u, n, v), w = J(u, n, a.highlight, l), [A, p] = k.useState(null);
407
- return /* @__PURE__ */ e(W, { ref: s, className: o, height: t, legendItems: d, hovered: f.hovered, format: c, children: /* @__PURE__ */ N(
408
- ve,
473
+ ({ height: t = I, curve: r = "linear", forecastKeys: a, animatedSeriesKeys: i, showValues: o, className: n, ...l }, x) => {
474
+ const { names: c, format: m, layers: u, legendItems: N, furniture: b, colorFor: f, labelFor: y, toggleSeries: C, isHidden: w } = Z(l), p = ge(c, a, f), h = ae(c, a, l.highlight, o), [k, d] = R.useState(null);
475
+ return /* @__PURE__ */ e(z, { ref: x, className: n, height: t, legendItems: N, hovered: u.hovered, format: m, onLegendToggle: C, children: /* @__PURE__ */ A(
476
+ be,
409
477
  {
410
- data: a.data,
411
- margin: z,
412
- onMouseMove: (i) => p((i == null ? void 0 : i.activeTooltipIndex) ?? null),
413
- onMouseLeave: () => p(null),
478
+ data: l.data,
479
+ margin: H,
480
+ onMouseMove: (s) => d((s == null ? void 0 : s.activeTooltipIndex) ?? null),
481
+ onMouseLeave: () => d(null),
414
482
  children: [
415
- x,
416
- a.tooltip !== !1 && /* @__PURE__ */ e(
417
- S,
483
+ b,
484
+ l.tooltip !== !1 && /* @__PURE__ */ e(
485
+ O,
418
486
  {
419
487
  content: /* @__PURE__ */ e(
420
- O,
488
+ T,
421
489
  {
422
- format: c,
423
- renderer: a.tooltip
490
+ format: m,
491
+ renderer: l.tooltip
424
492
  }
425
493
  ),
426
494
  cursor: { stroke: "var(--border-strong)" },
427
495
  isAnimationActive: !1
428
496
  }
429
497
  ),
430
- f.back,
431
- u.map((i, h) => /* @__PURE__ */ e(
432
- ie,
498
+ u.back,
499
+ c.map((s, v) => /* @__PURE__ */ e(
500
+ se,
433
501
  {
434
- dataKey: i,
435
- name: m(i),
502
+ dataKey: s,
503
+ name: y(s),
436
504
  type: r,
437
- stroke: b(i, h),
438
- strokeWidth: 1.5,
439
- strokeDasharray: n != null && n.includes(i) ? "6 4" : void 0,
440
- dot: { r: 3, fill: b(i, h), strokeWidth: 0 },
441
- activeDot: /* @__PURE__ */ e(q, { fill: b(i, h) }),
442
- label: w.has(i) ? /* @__PURE__ */ e(de, { format: c, hidden: A != null }) : void 0,
443
- isAnimationActive: !1
505
+ stroke: p(s, v),
506
+ strokeWidth: Y,
507
+ strokeDasharray: a != null && a.includes(s) ? "6 4" : void 0,
508
+ dot: /* @__PURE__ */ e(E, { color: p(s, v) }),
509
+ activeDot: /* @__PURE__ */ e(E, { color: p(s, v), active: !0 }),
510
+ label: h.has(s) ? /* @__PURE__ */ e(
511
+ fe,
512
+ {
513
+ color: p(s, v),
514
+ format: m,
515
+ hidden: k != null
516
+ }
517
+ ) : void 0,
518
+ hide: w(s),
519
+ isAnimationActive: (i == null ? void 0 : i.includes(s)) ?? !1
444
520
  },
445
- i
521
+ s
446
522
  )),
447
- f.front
523
+ u.front
448
524
  ]
449
525
  }
450
526
  ) });
451
527
  }
452
528
  );
453
- He.displayName = "LineChart";
454
- const Ue = k.forwardRef(
455
- ({ height: t = T, curve: r = "linear", stacked: n = !1, forecastKeys: l, showValues: o, className: a, ...s }, u) => {
456
- const { names: c, format: f, layers: d, legendItems: x, furniture: v, colorFor: m, labelFor: b } = H(s), w = fe(c, l, m), A = n ? /* @__PURE__ */ new Set() : J(c, l, s.highlight, o), [p, i] = k.useState(null), h = k.useId().replace(/[^a-zA-Z0-9]/g, "");
457
- return /* @__PURE__ */ e(W, { ref: u, className: a, height: t, legendItems: x, hovered: d.hovered, format: f, children: /* @__PURE__ */ N(
458
- be,
529
+ Ye.displayName = "LineChart";
530
+ const Xe = R.forwardRef(
531
+ ({ height: t = I, curve: r = "linear", stacked: a = !1, forecastKeys: i, showValues: o, className: n, ...l }, x) => {
532
+ const { names: c, format: m, layers: u, legendItems: N, furniture: b, colorFor: f, labelFor: y, toggleSeries: C, isHidden: w } = Z(l), p = ge(c, i, f), h = a ? /* @__PURE__ */ new Set() : ae(c, i, l.highlight, o), [k, d] = R.useState(null), s = R.useId().replace(/[^a-zA-Z0-9]/g, "");
533
+ return /* @__PURE__ */ e(z, { ref: x, className: n, height: t, legendItems: N, hovered: u.hovered, format: m, onLegendToggle: C, children: /* @__PURE__ */ A(
534
+ pe,
459
535
  {
460
- data: s.data,
461
- margin: z,
462
- onMouseMove: (y) => i((y == null ? void 0 : y.activeTooltipIndex) ?? null),
463
- onMouseLeave: () => i(null),
536
+ data: l.data,
537
+ margin: H,
538
+ onMouseMove: (v) => d((v == null ? void 0 : v.activeTooltipIndex) ?? null),
539
+ onMouseLeave: () => d(null),
464
540
  children: [
465
- /* @__PURE__ */ e("defs", { children: c.map((y, C) => /* @__PURE__ */ N("linearGradient", { id: `${h}-${C}`, x1: "0", y1: "0", x2: "0", y2: "1", children: [
466
- /* @__PURE__ */ e("stop", { offset: "0%", stopColor: m(y, C), stopOpacity: 0.18 }),
467
- /* @__PURE__ */ e("stop", { offset: "100%", stopColor: m(y, C), stopOpacity: 0.02 })
468
- ] }, y)) }),
469
- v,
470
- s.tooltip !== !1 && /* @__PURE__ */ e(
471
- S,
541
+ /* @__PURE__ */ e("defs", { children: c.map((v, g) => /* @__PURE__ */ A("linearGradient", { id: `${s}-${g}`, x1: "0", y1: "0", x2: "0", y2: "1", children: [
542
+ /* @__PURE__ */ e("stop", { offset: "0%", stopColor: f(v, g), stopOpacity: 0.18 }),
543
+ /* @__PURE__ */ e("stop", { offset: "100%", stopColor: f(v, g), stopOpacity: 0.02 })
544
+ ] }, v)) }),
545
+ b,
546
+ l.tooltip !== !1 && /* @__PURE__ */ e(
547
+ O,
472
548
  {
473
549
  content: /* @__PURE__ */ e(
474
- O,
550
+ T,
475
551
  {
476
- format: f,
477
- renderer: s.tooltip
552
+ format: m,
553
+ renderer: l.tooltip
478
554
  }
479
555
  ),
480
556
  cursor: { stroke: "var(--border-strong)" },
481
557
  isAnimationActive: !1
482
558
  }
483
559
  ),
484
- d.back,
485
- c.map((y, C) => /* @__PURE__ */ e(
486
- ge,
560
+ u.back,
561
+ c.map((v, g) => /* @__PURE__ */ e(
562
+ Ne,
487
563
  {
488
- dataKey: y,
489
- name: b(y),
564
+ dataKey: v,
565
+ name: y(v),
490
566
  type: r,
491
- stackId: n ? "stack" : void 0,
492
- stroke: w(y, C),
493
- strokeWidth: 1.5,
494
- strokeDasharray: l != null && l.includes(y) ? "6 4" : void 0,
495
- fill: `url(#${h}-${C})`,
496
- dot: { r: 3, fill: m(y, C), strokeWidth: 0 },
497
- activeDot: /* @__PURE__ */ e(q, { fill: w(y, C) }),
498
- label: A.has(y) ? /* @__PURE__ */ e(de, { format: f, hidden: p != null }) : void 0,
567
+ stackId: a ? "stack" : void 0,
568
+ stroke: p(v, g),
569
+ strokeWidth: Y,
570
+ strokeDasharray: i != null && i.includes(v) ? "6 4" : void 0,
571
+ fill: `url(#${s}-${g})`,
572
+ dot: /* @__PURE__ */ e(E, { color: p(v, g) }),
573
+ activeDot: /* @__PURE__ */ e(E, { color: p(v, g), active: !0 }),
574
+ label: h.has(v) ? /* @__PURE__ */ e(fe, { color: p(v, g), format: m, hidden: k != null }) : void 0,
575
+ hide: w(v),
499
576
  isAnimationActive: !1
500
577
  },
501
- y
578
+ v
502
579
  )),
503
- d.front
580
+ u.front
504
581
  ]
505
582
  }
506
583
  ) });
507
584
  }
508
585
  );
509
- Ue.displayName = "AreaChart";
510
- const Ve = k.forwardRef(
586
+ Xe.displayName = "AreaChart";
587
+ const Ze = R.forwardRef(
511
588
  ({
512
- height: t = T,
589
+ height: t = I,
513
590
  stacked: r = !1,
514
- layout: n = "vertical",
515
- showValues: l,
591
+ layout: a = "vertical",
592
+ showValues: i,
516
593
  className: o,
517
- ...a
518
- }, s) => {
519
- const { names: u, format: c, layers: f, legendItems: d, furniture: x, colorFor: v, labelFor: m } = H(a), b = n === "horizontal", w = r ? /* @__PURE__ */ new Set() : J(u, void 0, a.highlight, l), A = a.xTickFormatter ?? ((h) => typeof h == "number" ? c(h) : h), p = [
520
- a.grid !== !1 ? /* @__PURE__ */ e(
521
- X,
594
+ ...n
595
+ }, l) => {
596
+ const { names: x, format: c, layers: m, legendItems: u, furniture: N, colorFor: b, labelFor: f, toggleSeries: y, isHidden: C } = Z(n), w = a === "horizontal", p = r ? /* @__PURE__ */ new Set() : ae(x, void 0, n.highlight, i), h = n.xTickFormatter ?? ((s) => typeof s == "number" ? c(s) : s), k = [
597
+ n.grid !== !1 ? /* @__PURE__ */ e(
598
+ te,
522
599
  {
523
600
  horizontal: !1,
524
601
  vertical: !0,
@@ -527,105 +604,116 @@ const Ve = k.forwardRef(
527
604
  "grid"
528
605
  ) : null,
529
606
  /* @__PURE__ */ e(
530
- Z,
607
+ ne,
531
608
  {
532
609
  type: "number",
533
- domain: a.xDomain,
534
- allowDataOverflow: !!a.xDomain,
610
+ domain: n.xDomain,
611
+ allowDataOverflow: !!n.xDomain,
535
612
  axisLine: !1,
536
613
  tickLine: !1,
537
614
  minTickGap: 28,
538
615
  tickMargin: 10,
539
- tick: /* @__PURE__ */ e(I, { anchor: "middle", dy: 0, format: A })
616
+ tick: /* @__PURE__ */ e(D, { anchor: "middle", dy: 0, format: h })
540
617
  },
541
618
  "x"
542
619
  ),
543
- a.showYAxis !== !1 ? /* @__PURE__ */ e(
544
- E,
620
+ n.showYAxis !== !1 ? /* @__PURE__ */ e(
621
+ U,
545
622
  {
546
623
  type: "category",
547
- dataKey: a.categoryKey,
548
- width: a.yAxisWidth ?? 144,
624
+ dataKey: n.categoryKey,
625
+ width: n.yAxisWidth ?? 144,
549
626
  axisLine: !1,
550
627
  tickLine: !1,
551
628
  tickMargin: 6,
552
629
  tick: /* @__PURE__ */ e(
553
- I,
630
+ D,
554
631
  {
555
632
  anchor: "end",
556
633
  dy: "0.32em",
557
- format: a.yTickFormatter
634
+ format: n.yTickFormatter
558
635
  }
559
636
  )
560
637
  },
561
638
  "y"
562
639
  ) : null
563
- ], i = a.highlight && u.length === 1 && !u.includes(a.highlight) ? a.highlight : null;
564
- return /* @__PURE__ */ e(W, { ref: s, className: o, height: t, legendItems: d, hovered: f.hovered, format: c, children: /* @__PURE__ */ N(
565
- pe,
640
+ ], d = n.highlight && x.length === 1 && !x.includes(n.highlight) ? n.highlight : null;
641
+ return /* @__PURE__ */ e(z, { ref: l, className: o, height: t, legendItems: u, hovered: m.hovered, format: c, onLegendToggle: y, children: /* @__PURE__ */ A(
642
+ we,
566
643
  {
567
- data: a.data,
568
- layout: b ? "vertical" : "horizontal",
569
- margin: z,
644
+ data: n.data,
645
+ layout: w ? "vertical" : "horizontal",
646
+ margin: H,
570
647
  barCategoryGap: "24%",
571
648
  children: [
572
- b ? p : x,
573
- a.tooltip !== !1 && /* @__PURE__ */ e(
574
- S,
649
+ w ? k : N,
650
+ n.tooltip !== !1 && /* @__PURE__ */ e(
651
+ O,
575
652
  {
576
653
  content: /* @__PURE__ */ e(
577
- O,
654
+ T,
578
655
  {
579
656
  format: c,
580
- renderer: a.tooltip
657
+ renderer: n.tooltip
581
658
  }
582
659
  ),
583
660
  cursor: { fill: "var(--muted)" },
584
661
  isAnimationActive: !1
585
662
  }
586
663
  ),
587
- f.back,
588
- u.map((h, y) => {
589
- const C = r ? y === u.length - 1 : !0, R = b ? [0, 4, 4, 0] : [4, 4, 0, 0];
664
+ m.back,
665
+ x.map((s, v) => {
666
+ const g = r ? v === x.length - 1 : !0, S = w ? [0, 4, 4, 0] : [4, 4, 0, 0];
590
667
  return /* @__PURE__ */ e(
591
- le,
668
+ ce,
592
669
  {
593
- dataKey: h,
594
- name: m(h),
670
+ dataKey: s,
671
+ name: f(s),
595
672
  stackId: r ? "stack" : void 0,
596
- fill: v(h, y),
597
- radius: C ? R : 0,
673
+ fill: b(s, v),
674
+ radius: g ? S : 0,
598
675
  maxBarSize: 48,
599
- label: w.has(h) ? /* @__PURE__ */ e(ze, { format: c, horizontal: b }) : void 0,
676
+ label: p.has(s) ? /* @__PURE__ */ e(Pe, { format: c, horizontal: w }) : void 0,
677
+ hide: C(s),
600
678
  isAnimationActive: !1,
601
- children: i && a.data.map((g) => /* @__PURE__ */ e(
602
- oe,
679
+ children: d && n.data.map((L) => /* @__PURE__ */ e(
680
+ de,
603
681
  {
604
- fill: g[a.categoryKey] === i ? "var(--color-chart-1)" : Q
682
+ fill: L[n.categoryKey] === d ? "var(--color-chart-1)" : re
605
683
  },
606
- String(g[a.categoryKey])
684
+ String(L[n.categoryKey])
607
685
  ))
608
686
  },
609
- h
687
+ s
610
688
  );
611
689
  }),
612
- f.front
690
+ m.front
613
691
  ]
614
692
  }
615
693
  ) });
616
694
  }
617
695
  );
618
- Ve.displayName = "BarChart";
619
- const he = k.forwardRef(
620
- ({ height: t = T, lineKeys: r, dualAxis: n = !1, stacked: l = !1, forecastKeys: o, className: a, ...s }, u) => {
621
- const { names: c, format: f, layers: d, furniture: x, colorFor: v, labelFor: m } = H(s), b = c.filter((i) => !r.includes(i)), w = (i, h) => r.length ? "var(--chart-axis)" : v(i, h), A = (i, h) => r.length ? "var(--color-chart-1)" : v(i, h), p = c.length > 1 ? [
622
- ...b.map((i) => ({ label: m(i), color: w(i, c.indexOf(i)) })),
623
- ...r.map((i) => ({ label: m(i), color: A(i, c.indexOf(i)) }))
696
+ Ze.displayName = "BarChart";
697
+ const ve = R.forwardRef(
698
+ ({ height: t = I, lineKeys: r, dualAxis: a = !1, stacked: i = !1, forecastKeys: o, className: n, ...l }, x) => {
699
+ const { names: c, format: m, layers: u, furniture: N, colorFor: b, labelFor: f, toggleSeries: y, isHidden: C } = Z(l), w = c.filter((d) => !r.includes(d)), p = (d, s) => r.length ? "var(--chart-axis)" : b(d, s), h = (d, s) => r.length ? "var(--color-chart-1)" : b(d, s), k = c.length > 1 ? [
700
+ ...w.map((d) => ({
701
+ key: d,
702
+ label: f(d),
703
+ color: p(d, c.indexOf(d)),
704
+ hidden: C(d)
705
+ })),
706
+ ...r.map((d) => ({
707
+ key: d,
708
+ label: f(d),
709
+ color: h(d, c.indexOf(d)),
710
+ hidden: C(d)
711
+ }))
624
712
  ] : null;
625
- return /* @__PURE__ */ e(W, { ref: u, className: a, height: t, legendItems: p, hovered: d.hovered, format: f, children: /* @__PURE__ */ N(Ne, { data: s.data, margin: z, barCategoryGap: "24%", children: [
626
- x,
627
- n && /* @__PURE__ */ e(
628
- E,
713
+ return /* @__PURE__ */ e(z, { ref: x, className: n, height: t, legendItems: k, hovered: u.hovered, format: m, onLegendToggle: y, children: /* @__PURE__ */ A(Ae, { data: l.data, margin: H, barCategoryGap: "24%", children: [
714
+ N,
715
+ a && /* @__PURE__ */ e(
716
+ U,
629
717
  {
630
718
  yAxisId: "right",
631
719
  orientation: "right",
@@ -634,254 +722,256 @@ const he = k.forwardRef(
634
722
  tickLine: !1,
635
723
  tickMargin: 6,
636
724
  tick: /* @__PURE__ */ e(
637
- I,
725
+ D,
638
726
  {
639
727
  anchor: "start",
640
728
  dy: "0.32em",
641
- format: (i) => typeof i == "number" ? f(i) : i
729
+ format: (d) => typeof d == "number" ? m(d) : d
642
730
  }
643
731
  )
644
732
  }
645
733
  ),
646
- s.tooltip !== !1 && /* @__PURE__ */ e(
647
- S,
734
+ l.tooltip !== !1 && /* @__PURE__ */ e(
735
+ O,
648
736
  {
649
737
  content: /* @__PURE__ */ e(
650
- O,
738
+ T,
651
739
  {
652
- format: f,
653
- renderer: s.tooltip
740
+ format: m,
741
+ renderer: l.tooltip
654
742
  }
655
743
  ),
656
744
  cursor: { fill: "var(--muted)" },
657
745
  isAnimationActive: !1
658
746
  }
659
747
  ),
660
- d.back,
661
- b.map((i) => {
662
- const h = c.indexOf(i), y = l ? i === b[b.length - 1] : !0;
748
+ u.back,
749
+ w.map((d) => {
750
+ const s = c.indexOf(d), v = i ? d === w[w.length - 1] : !0;
663
751
  return /* @__PURE__ */ e(
664
- le,
752
+ ce,
665
753
  {
666
- dataKey: i,
667
- name: m(i),
668
- stackId: l ? "stack" : void 0,
669
- fill: w(i, h),
670
- radius: y ? [4, 4, 0, 0] : 0,
754
+ dataKey: d,
755
+ name: f(d),
756
+ stackId: i ? "stack" : void 0,
757
+ fill: p(d, s),
758
+ radius: v ? [4, 4, 0, 0] : 0,
671
759
  maxBarSize: 48,
760
+ hide: C(d),
672
761
  isAnimationActive: !1
673
762
  },
674
- i
763
+ d
675
764
  );
676
765
  }),
677
- r.map((i) => {
678
- const h = c.indexOf(i);
766
+ r.map((d) => {
767
+ const s = c.indexOf(d);
679
768
  return /* @__PURE__ */ e(
680
- ie,
769
+ se,
681
770
  {
682
- dataKey: i,
683
- name: m(i),
684
- yAxisId: n ? "right" : void 0,
771
+ dataKey: d,
772
+ name: f(d),
773
+ yAxisId: a ? "right" : void 0,
685
774
  type: "linear",
686
- stroke: A(i, h),
687
- strokeWidth: 2,
688
- strokeDasharray: o != null && o.includes(i) ? "6 4" : void 0,
689
- dot: { r: 3, fill: A(i, h), strokeWidth: 0 },
690
- activeDot: /* @__PURE__ */ e(q, { fill: A(i, h) }),
775
+ stroke: h(d, s),
776
+ strokeWidth: Y,
777
+ strokeDasharray: o != null && o.includes(d) ? "6 4" : void 0,
778
+ dot: /* @__PURE__ */ e(E, { color: h(d, s) }),
779
+ activeDot: /* @__PURE__ */ e(E, { color: h(d, s), active: !0 }),
780
+ hide: C(d),
691
781
  isAnimationActive: !1
692
782
  },
693
- i
783
+ d
694
784
  );
695
785
  }),
696
- d.front
786
+ u.front
697
787
  ] }) });
698
788
  }
699
789
  );
700
- he.displayName = "ComboChart";
701
- const Ye = k.forwardRef(
702
- (t, r) => /* @__PURE__ */ e(he, { ref: r, ...t })
790
+ ve.displayName = "ComboChart";
791
+ const Qe = R.forwardRef(
792
+ (t, r) => /* @__PURE__ */ e(ve, { ref: r, ...t })
703
793
  );
704
- Ye.displayName = "ComposedChart";
705
- const Xe = k.forwardRef(
794
+ Qe.displayName = "ComposedChart";
795
+ const qe = R.forwardRef(
706
796
  ({
707
797
  data: t,
708
798
  xKey: r,
709
- yKey: n,
710
- labelKey: l,
799
+ yKey: a,
800
+ labelKey: i,
711
801
  annotations: o,
712
- height: a = T,
713
- grid: s = !1,
714
- showYAxis: u = !0,
802
+ height: n = I,
803
+ grid: l = !1,
804
+ showYAxis: x = !0,
715
805
  formatValue: c,
716
- xScale: f = "number",
717
- xDomain: d,
718
- yDomain: x,
719
- xTickFormatter: v,
720
- yTickFormatter: m,
721
- yAxisWidth: b = 44,
722
- tooltip: w,
723
- className: A
806
+ xScale: m = "number",
807
+ xDomain: u,
808
+ yDomain: N,
809
+ xTickFormatter: b,
810
+ yTickFormatter: f,
811
+ yAxisWidth: y = 44,
812
+ tooltip: C,
813
+ className: w
724
814
  }, p) => {
725
- const i = c ?? F, h = v ?? ((R) => typeof R == "number" ? F(R) : R), y = m ?? ((R) => typeof R == "number" ? i(R) : R), C = me(o, i);
726
- return /* @__PURE__ */ e(W, { ref: p, className: A, height: a, legendItems: null, hovered: C.hovered, format: i, children: /* @__PURE__ */ N(we, { margin: z, children: [
727
- s && /* @__PURE__ */ e(X, { vertical: !1, stroke: "var(--chart-grid)" }),
815
+ const h = c ?? F, k = b ?? ((v) => typeof v == "number" ? F(v) : v), d = f ?? ((v) => typeof v == "number" ? h(v) : v), s = xe(o, h);
816
+ return /* @__PURE__ */ e(z, { ref: p, className: w, height: n, legendItems: null, hovered: s.hovered, format: h, children: /* @__PURE__ */ A(Ce, { margin: H, children: [
817
+ l && /* @__PURE__ */ e(te, { vertical: !1, stroke: "var(--chart-grid)" }),
728
818
  /* @__PURE__ */ e(
729
- Z,
819
+ ne,
730
820
  {
731
821
  type: "number",
732
822
  dataKey: r,
733
- scale: f === "time" ? "time" : "auto",
734
- domain: d ?? (f === "time" ? ["dataMin", "dataMax"] : ["auto", "auto"]),
735
- allowDataOverflow: !!d,
823
+ scale: m === "time" ? "time" : "auto",
824
+ domain: u ?? (m === "time" ? ["dataMin", "dataMax"] : ["auto", "auto"]),
825
+ allowDataOverflow: !!u,
736
826
  axisLine: !1,
737
827
  tickLine: !1,
738
828
  minTickGap: 28,
739
829
  tickMargin: 10,
740
- tick: /* @__PURE__ */ e(I, { anchor: "middle", dy: 0, format: h })
830
+ tick: /* @__PURE__ */ e(D, { anchor: "middle", dy: 0, format: k })
741
831
  }
742
832
  ),
743
- u && /* @__PURE__ */ e(
744
- E,
833
+ x && /* @__PURE__ */ e(
834
+ U,
745
835
  {
746
836
  type: "number",
747
- dataKey: n,
748
- width: b,
749
- domain: x,
750
- allowDataOverflow: !!x,
837
+ dataKey: a,
838
+ width: y,
839
+ domain: N,
840
+ allowDataOverflow: !!N,
751
841
  axisLine: !1,
752
842
  tickLine: !1,
753
843
  tickMargin: 6,
754
- tick: /* @__PURE__ */ e(I, { anchor: "end", dy: "0.32em", format: y })
844
+ tick: /* @__PURE__ */ e(D, { anchor: "end", dy: "0.32em", format: d })
755
845
  }
756
846
  ),
757
- w !== !1 && /* @__PURE__ */ e(
758
- S,
847
+ C !== !1 && /* @__PURE__ */ e(
848
+ O,
759
849
  {
760
850
  content: /* @__PURE__ */ e(
761
- O,
851
+ T,
762
852
  {
763
- format: i,
764
- labelKey: l,
765
- renderer: w
853
+ format: h,
854
+ labelKey: i,
855
+ renderer: C
766
856
  }
767
857
  ),
768
858
  cursor: { stroke: "var(--border-strong)", strokeDasharray: "4 4" },
769
859
  isAnimationActive: !1
770
860
  }
771
861
  ),
772
- C.back,
862
+ s.back,
773
863
  /* @__PURE__ */ e(
774
- Ae,
864
+ ye,
775
865
  {
776
866
  data: t,
777
867
  fill: "var(--color-chart-1)",
778
- shape: (R) => /* @__PURE__ */ e("circle", { cx: R.cx, cy: R.cy, r: 4.5, fill: "var(--color-chart-1)", fillOpacity: 0.75 }),
868
+ shape: (v) => /* @__PURE__ */ e("circle", { cx: v.cx, cy: v.cy, r: 4.5, fill: "var(--color-chart-1)", fillOpacity: 0.75 }),
779
869
  isAnimationActive: !1
780
870
  }
781
871
  ),
782
- C.front
872
+ s.front
783
873
  ] }) });
784
874
  }
785
875
  );
786
- Xe.displayName = "ScatterChart";
787
- const Ze = k.forwardRef(
876
+ qe.displayName = "ScatterChart";
877
+ const Je = R.forwardRef(
788
878
  ({
789
879
  data: t,
790
880
  nameKey: r,
791
- valueKey: n,
792
- donut: l = !0,
881
+ valueKey: a,
882
+ donut: i = !0,
793
883
  centerLabel: o,
794
- highlight: a,
795
- height: s = 260,
796
- legend: u = !0,
884
+ highlight: n,
885
+ height: l = 260,
886
+ legend: x = !0,
797
887
  formatValue: c,
798
- tooltip: f,
799
- className: d
800
- }, x) => {
801
- const v = c ?? F, m = t.reduce((p, i) => p + (typeof i[n] == "number" ? i[n] : 0), 0), b = (p, i) => _(i), w = (p) => a && p !== a ? 0.3 : 1, A = u ? t.map((p, i) => ({
802
- label: `${p[r]} · ${m ? Math.round(Number(p[n]) / m * 100) : 0}%`,
803
- color: b(String(p[r]), i)
888
+ tooltip: m,
889
+ className: u
890
+ }, N) => {
891
+ const b = c ?? F, f = t.reduce((p, h) => p + (typeof h[a] == "number" ? h[a] : 0), 0), y = (p, h) => V(h), C = (p) => n && p !== n ? 0.3 : 1, w = x ? t.map((p, h) => ({
892
+ label: `${p[r]} · ${f ? Math.round(Number(p[a]) / f * 100) : 0}%`,
893
+ color: y(String(p[r]), h)
804
894
  })) : null;
805
- return /* @__PURE__ */ N("div", { ref: x, className: $("relative w-full font-sans", d), children: [
806
- A && /* @__PURE__ */ e(G, { items: A }),
807
- /* @__PURE__ */ N("div", { className: "relative", children: [
808
- /* @__PURE__ */ e(j, { width: "100%", height: s, children: /* @__PURE__ */ N(ye, { margin: { top: 8, right: 8, bottom: 8, left: 8 }, children: [
809
- f !== !1 && /* @__PURE__ */ e(
810
- S,
895
+ return /* @__PURE__ */ A("div", { ref: N, className: $("relative w-full font-sans", u), children: [
896
+ w && /* @__PURE__ */ e(X, { items: w }),
897
+ /* @__PURE__ */ A("div", { className: "relative", children: [
898
+ /* @__PURE__ */ e(j, { width: "100%", height: l, children: /* @__PURE__ */ A(Re, { margin: { top: 8, right: 8, bottom: 8, left: 8 }, children: [
899
+ m !== !1 && /* @__PURE__ */ e(
900
+ O,
811
901
  {
812
902
  content: /* @__PURE__ */ e(
813
- O,
903
+ T,
814
904
  {
815
- format: v,
816
- renderer: f
905
+ format: b,
906
+ renderer: m
817
907
  }
818
908
  ),
819
909
  isAnimationActive: !1
820
910
  }
821
911
  ),
822
912
  /* @__PURE__ */ e(
823
- Ce,
913
+ ke,
824
914
  {
825
915
  data: t,
826
- dataKey: n,
916
+ dataKey: a,
827
917
  nameKey: r,
828
- innerRadius: l ? "62%" : 0,
918
+ innerRadius: i ? "62%" : 0,
829
919
  outerRadius: "88%",
830
- paddingAngle: l ? 2 : 1,
831
- cornerRadius: l ? 4 : 2,
920
+ paddingAngle: i ? 2 : 1,
921
+ cornerRadius: i ? 4 : 2,
832
922
  stroke: "none",
833
923
  isAnimationActive: !1,
834
- children: t.map((p, i) => /* @__PURE__ */ e(
835
- oe,
924
+ children: t.map((p, h) => /* @__PURE__ */ e(
925
+ de,
836
926
  {
837
927
  role: "presentation",
838
928
  "aria-hidden": "true",
839
- fill: b(String(p[r]), i),
840
- fillOpacity: w(String(p[r]))
929
+ fill: y(String(p[r]), h),
930
+ fillOpacity: C(String(p[r]))
841
931
  },
842
932
  String(p[r])
843
933
  ))
844
934
  }
845
935
  )
846
936
  ] }) }),
847
- l && /* @__PURE__ */ N("div", { className: "pointer-events-none absolute inset-0 flex flex-col items-center justify-center", children: [
848
- /* @__PURE__ */ e("div", { className: "text-xl font-medium text-foreground tabular-nums", children: v(m) }),
937
+ i && /* @__PURE__ */ A("div", { className: "pointer-events-none absolute inset-0 flex flex-col items-center justify-center", children: [
938
+ /* @__PURE__ */ e("div", { className: "text-xl font-medium text-foreground tabular-nums", children: b(f) }),
849
939
  o && /* @__PURE__ */ e("div", { className: "mt-0.5 text-xs font-normal tracking-wide uppercase text-tertiary", children: o })
850
940
  ] })
851
941
  ] })
852
942
  ] });
853
943
  }
854
944
  );
855
- Ze.displayName = "PieChart";
856
- const Qe = k.forwardRef(
945
+ Je.displayName = "PieChart";
946
+ const Ke = R.forwardRef(
857
947
  ({
858
948
  data: t,
859
949
  categoryKey: r,
860
- series: n,
861
- seriesLabels: l,
950
+ series: a,
951
+ seriesLabels: i,
862
952
  highlight: o,
863
- maxValue: a,
864
- height: s = 300,
865
- legend: u,
953
+ maxValue: n,
954
+ height: l = 300,
955
+ legend: x,
866
956
  formatValue: c,
867
- tooltip: f,
868
- className: d
869
- }, x) => {
870
- const v = k.useMemo(
871
- () => n ?? ce(t, r),
872
- [r, t, n]
873
- ), m = c ?? F, b = a ?? Math.max(
957
+ tooltip: m,
958
+ className: u
959
+ }, N) => {
960
+ const b = R.useMemo(
961
+ () => a ?? me(t, r),
962
+ [r, t, a]
963
+ ), f = c ?? F, y = n ?? Math.max(
874
964
  1,
875
965
  ...t.flatMap(
876
- (i) => v.map(
877
- (h) => typeof i[h] == "number" ? i[h] : 0
966
+ (h) => b.map(
967
+ (k) => typeof h[k] == "number" ? h[k] : 0
878
968
  )
879
969
  )
880
- ), w = (i) => (l == null ? void 0 : l[i]) ?? i, A = (i, h) => o && v.includes(o) ? i === o ? "var(--color-chart-1)" : Q : _(h), p = u ?? v.length > 1 ? v.map((i, h) => ({ label: w(i), color: A(i, h) })) : null;
881
- return /* @__PURE__ */ N("div", { ref: x, className: $("relative w-full font-sans", d), children: [
882
- p && /* @__PURE__ */ e(G, { items: p, align: "center" }),
883
- /* @__PURE__ */ e("div", { className: "mx-auto w-full max-w-[520px]", children: /* @__PURE__ */ e(j, { width: "100%", height: s, children: /* @__PURE__ */ N(
884
- ke,
970
+ ), C = (h) => (i == null ? void 0 : i[h]) ?? h, w = (h, k) => o && b.includes(o) ? h === o ? "var(--color-chart-1)" : re : V(k), p = x ?? b.length > 1 ? b.map((h, k) => ({ label: C(h), color: w(h, k) })) : null;
971
+ return /* @__PURE__ */ A("div", { ref: N, className: $("relative w-full font-sans", u), children: [
972
+ p && /* @__PURE__ */ e(X, { items: p, align: "center" }),
973
+ /* @__PURE__ */ e("div", { className: "mx-auto w-full max-w-[520px]", children: /* @__PURE__ */ e(j, { width: "100%", height: l, children: /* @__PURE__ */ A(
974
+ Me,
885
975
  {
886
976
  data: t,
887
977
  cx: "50%",
@@ -889,50 +979,50 @@ const Qe = k.forwardRef(
889
979
  outerRadius: "68%",
890
980
  margin: { top: 10, right: 56, bottom: 16, left: 56 },
891
981
  children: [
892
- /* @__PURE__ */ e(Re, { stroke: "var(--border)", radialLines: !0 }),
982
+ /* @__PURE__ */ e($e, { stroke: "var(--border)", radialLines: !0 }),
893
983
  /* @__PURE__ */ e(
894
- se,
984
+ ue,
895
985
  {
896
986
  dataKey: r,
897
987
  tick: { fill: "var(--text-secondary)", fontSize: 11, fontWeight: 500 }
898
988
  }
899
989
  ),
900
990
  /* @__PURE__ */ e(
901
- Me,
991
+ Se,
902
992
  {
903
993
  angle: 90,
904
- domain: [0, b],
994
+ domain: [0, y],
905
995
  tick: !1,
906
996
  axisLine: !1,
907
997
  tickLine: !1
908
998
  }
909
999
  ),
910
- f !== !1 && /* @__PURE__ */ e(
911
- S,
1000
+ m !== !1 && /* @__PURE__ */ e(
1001
+ O,
912
1002
  {
913
1003
  content: /* @__PURE__ */ e(
914
- O,
1004
+ T,
915
1005
  {
916
- format: m,
917
- renderer: f
1006
+ format: f,
1007
+ renderer: m
918
1008
  }
919
1009
  ),
920
1010
  isAnimationActive: !1
921
1011
  }
922
1012
  ),
923
- v.map((i, h) => /* @__PURE__ */ e(
924
- $e,
1013
+ b.map((h, k) => /* @__PURE__ */ e(
1014
+ Le,
925
1015
  {
926
- dataKey: i,
927
- name: w(i),
928
- stroke: A(i, h),
929
- fill: A(i, h),
930
- fillOpacity: o ? i === o ? 0.16 : 0.05 : 0.1,
931
- strokeWidth: 2,
932
- dot: { r: 2.5, fill: A(i, h), strokeWidth: 0 },
1016
+ dataKey: h,
1017
+ name: C(h),
1018
+ stroke: w(h, k),
1019
+ fill: w(h, k),
1020
+ fillOpacity: o ? h === o ? 0.16 : 0.05 : 0.1,
1021
+ strokeWidth: Y,
1022
+ dot: /* @__PURE__ */ e(E, { color: w(h, k) }),
933
1023
  isAnimationActive: !1
934
1024
  },
935
- i
1025
+ h
936
1026
  ))
937
1027
  ]
938
1028
  }
@@ -940,51 +1030,51 @@ const Qe = k.forwardRef(
940
1030
  ] });
941
1031
  }
942
1032
  );
943
- Qe.displayName = "RadarChart";
944
- const qe = k.forwardRef(
1033
+ Ke.displayName = "RadarChart";
1034
+ const et = R.forwardRef(
945
1035
  ({
946
1036
  data: t,
947
1037
  nameKey: r,
948
- valueKey: n,
949
- maxValue: l = 100,
1038
+ valueKey: a,
1039
+ maxValue: i = 100,
950
1040
  centerLabel: o,
951
- height: a = T,
952
- legend: s = !0,
953
- formatValue: u,
1041
+ height: n = I,
1042
+ legend: l = !0,
1043
+ formatValue: x,
954
1044
  tooltip: c,
955
- className: f
956
- }, d) => {
957
- const x = u ?? F, v = t.map((w, A) => ({
958
- ...w,
959
- name: String(w[r]),
960
- fill: Y(A)
961
- })), m = v.length ? v.reduce(
962
- (w, A) => w + (typeof A[n] == "number" ? A[n] : 0),
1045
+ className: m
1046
+ }, u) => {
1047
+ const N = x ?? F, b = t.map((C, w) => ({
1048
+ ...C,
1049
+ name: String(C[r]),
1050
+ fill: ee(w)
1051
+ })), f = b.length ? b.reduce(
1052
+ (C, w) => C + (typeof w[a] == "number" ? w[a] : 0),
963
1053
  0
964
- ) / v.length : 0, b = s ? v.map((w, A) => ({
965
- label: String(w[r]),
966
- color: Y(A)
1054
+ ) / b.length : 0, y = l ? b.map((C, w) => ({
1055
+ label: String(C[r]),
1056
+ color: ee(w)
967
1057
  })) : null;
968
- return /* @__PURE__ */ N("div", { ref: d, className: $("relative w-full font-sans", f), children: [
969
- /* @__PURE__ */ N("div", { className: "relative mx-auto w-full max-w-[420px]", children: [
970
- /* @__PURE__ */ e(j, { width: "100%", height: a, children: /* @__PURE__ */ N(
971
- Le,
1058
+ return /* @__PURE__ */ A("div", { ref: u, className: $("relative w-full font-sans", m), children: [
1059
+ /* @__PURE__ */ A("div", { className: "relative mx-auto w-full max-w-[420px]", children: [
1060
+ /* @__PURE__ */ e(j, { width: "100%", height: n, children: /* @__PURE__ */ A(
1061
+ Fe,
972
1062
  {
973
- data: v,
1063
+ data: b,
974
1064
  innerRadius: "48%",
975
1065
  outerRadius: "82%",
976
1066
  startAngle: 90,
977
1067
  endAngle: -270,
978
1068
  margin: { top: 6, right: 6, bottom: 6, left: 6 },
979
1069
  children: [
980
- /* @__PURE__ */ e(se, { type: "number", domain: [0, l], tick: !1 }),
1070
+ /* @__PURE__ */ e(ue, { type: "number", domain: [0, i], tick: !1 }),
981
1071
  c !== !1 && /* @__PURE__ */ e(
982
- S,
1072
+ O,
983
1073
  {
984
1074
  content: /* @__PURE__ */ e(
985
- O,
1075
+ T,
986
1076
  {
987
- format: x,
1077
+ format: N,
988
1078
  renderer: c
989
1079
  }
990
1080
  ),
@@ -992,9 +1082,9 @@ const qe = k.forwardRef(
992
1082
  }
993
1083
  ),
994
1084
  /* @__PURE__ */ e(
995
- Fe,
1085
+ Oe,
996
1086
  {
997
- dataKey: n,
1087
+ dataKey: a,
998
1088
  background: { fill: "var(--muted)" },
999
1089
  cornerRadius: 999,
1000
1090
  maxBarSize: 18,
@@ -1004,71 +1094,71 @@ const qe = k.forwardRef(
1004
1094
  ]
1005
1095
  }
1006
1096
  ) }),
1007
- /* @__PURE__ */ N("div", { className: "pointer-events-none absolute inset-0 flex flex-col items-center justify-center", children: [
1008
- /* @__PURE__ */ e("div", { className: "text-xl font-medium text-foreground tabular-nums", children: x(Math.round(m)) }),
1097
+ /* @__PURE__ */ A("div", { className: "pointer-events-none absolute inset-0 flex flex-col items-center justify-center", children: [
1098
+ /* @__PURE__ */ e("div", { className: "text-xl font-medium text-foreground tabular-nums", children: N(Math.round(f)) }),
1009
1099
  o && /* @__PURE__ */ e("div", { className: "mt-0.5 text-xs font-normal tracking-wide uppercase text-tertiary", children: o })
1010
1100
  ] })
1011
1101
  ] }),
1012
- b && /* @__PURE__ */ e(G, { items: b, align: "center", className: "mb-0 mt-3" })
1102
+ y && /* @__PURE__ */ e(X, { items: y, align: "center", className: "mb-0 mt-3" })
1013
1103
  ] });
1014
1104
  }
1015
1105
  );
1016
- qe.displayName = "RadialBarChart";
1017
- function Je({
1106
+ et.displayName = "RadialBarChart";
1107
+ function tt({
1018
1108
  x: t = 0,
1019
1109
  y: r = 0,
1020
- width: n = 0,
1021
- height: l = 0,
1110
+ width: a = 0,
1111
+ height: i = 0,
1022
1112
  depth: o = 0,
1023
- index: a = 0,
1024
- name: s,
1025
- value: u,
1113
+ index: n = 0,
1114
+ name: l,
1115
+ value: x,
1026
1116
  format: c = F
1027
1117
  }) {
1028
1118
  if (o === 0) return /* @__PURE__ */ e("g", {});
1029
- const f = o === 0 ? "transparent" : Y(a), d = o > 0 && a < 4, x = n > 72 && l > 38;
1030
- return /* @__PURE__ */ N("g", { children: [
1119
+ const m = o === 0 ? "transparent" : ee(n), u = o > 0 && n < 4, N = a > 72 && i > 38;
1120
+ return /* @__PURE__ */ A("g", { children: [
1031
1121
  /* @__PURE__ */ e(
1032
1122
  "rect",
1033
1123
  {
1034
1124
  x: t,
1035
1125
  y: r,
1036
- width: n,
1037
- height: l,
1126
+ width: a,
1127
+ height: i,
1038
1128
  rx: 6,
1039
1129
  ry: 6,
1040
- fill: f,
1130
+ fill: m,
1041
1131
  stroke: "var(--background)",
1042
1132
  strokeWidth: 4
1043
1133
  }
1044
1134
  ),
1045
- x && /* @__PURE__ */ e(
1135
+ N && /* @__PURE__ */ e(
1046
1136
  "foreignObject",
1047
1137
  {
1048
1138
  x: t + 8,
1049
1139
  y: r + 8,
1050
- width: Math.max(0, n - 16),
1051
- height: Math.max(0, l - 16),
1140
+ width: Math.max(0, a - 16),
1141
+ height: Math.max(0, i - 16),
1052
1142
  className: "pointer-events-none overflow-hidden",
1053
- children: /* @__PURE__ */ N("div", { className: "flex h-full flex-col justify-between", children: [
1143
+ children: /* @__PURE__ */ A("div", { className: "flex h-full flex-col justify-between", children: [
1054
1144
  /* @__PURE__ */ e(
1055
1145
  "p",
1056
1146
  {
1057
1147
  className: $(
1058
1148
  "truncate text-xs font-medium",
1059
- d ? "text-background" : "text-foreground"
1149
+ u ? "text-background" : "text-foreground"
1060
1150
  ),
1061
- children: s
1151
+ children: l
1062
1152
  }
1063
1153
  ),
1064
- typeof u == "number" && l > 58 && /* @__PURE__ */ e(
1154
+ typeof x == "number" && i > 58 && /* @__PURE__ */ e(
1065
1155
  "p",
1066
1156
  {
1067
1157
  className: $(
1068
1158
  "text-xs tabular-nums",
1069
- d ? "text-background/70" : "text-tertiary"
1159
+ u ? "text-background/70" : "text-tertiary"
1070
1160
  ),
1071
- children: c(u)
1161
+ children: c(x)
1072
1162
  }
1073
1163
  )
1074
1164
  ] })
@@ -1076,53 +1166,53 @@ function Je({
1076
1166
  )
1077
1167
  ] });
1078
1168
  }
1079
- function Ke(t, r, n) {
1080
- const l = [], o = (a) => {
1081
- const s = Array.isArray(a.children) ? a.children : void 0;
1082
- if (s != null && s.length) {
1083
- s.forEach(o);
1169
+ function nt(t, r, a) {
1170
+ const i = [], o = (n) => {
1171
+ const l = Array.isArray(n.children) ? n.children : void 0;
1172
+ if (l != null && l.length) {
1173
+ l.forEach(o);
1084
1174
  return;
1085
1175
  }
1086
- typeof a[n] == "number" && l.push({
1087
- ...a,
1088
- name: String(a[r] ?? ""),
1089
- value: a[n]
1176
+ typeof n[a] == "number" && i.push({
1177
+ ...n,
1178
+ name: String(n[r] ?? ""),
1179
+ value: n[a]
1090
1180
  });
1091
1181
  };
1092
- return t.forEach(o), l.length ? l : t;
1182
+ return t.forEach(o), i.length ? i : t;
1093
1183
  }
1094
- const et = k.forwardRef(
1184
+ const rt = R.forwardRef(
1095
1185
  ({
1096
1186
  data: t,
1097
1187
  nameKey: r,
1098
- valueKey: n,
1099
- height: l = T,
1188
+ valueKey: a,
1189
+ height: i = I,
1100
1190
  formatValue: o,
1101
- tooltip: a,
1102
- className: s
1103
- }, u) => {
1104
- const c = o ?? F, f = k.useMemo(
1105
- () => Ke(t, r, n),
1106
- [t, r, n]
1191
+ tooltip: n,
1192
+ className: l
1193
+ }, x) => {
1194
+ const c = o ?? F, m = R.useMemo(
1195
+ () => nt(t, r, a),
1196
+ [t, r, a]
1107
1197
  );
1108
- return /* @__PURE__ */ e("div", { ref: u, className: $("relative w-full font-sans", s), children: /* @__PURE__ */ e(j, { width: "100%", height: l, children: /* @__PURE__ */ e(
1109
- Se,
1198
+ return /* @__PURE__ */ e("div", { ref: x, className: $("relative w-full font-sans", l), children: /* @__PURE__ */ e(j, { width: "100%", height: i, children: /* @__PURE__ */ e(
1199
+ Te,
1110
1200
  {
1111
- data: f,
1201
+ data: m,
1112
1202
  nameKey: r,
1113
- dataKey: n,
1203
+ dataKey: a,
1114
1204
  type: "flat",
1115
1205
  aspectRatio: 1.6,
1116
- content: /* @__PURE__ */ e(Je, { format: c }),
1206
+ content: /* @__PURE__ */ e(tt, { format: c }),
1117
1207
  isAnimationActive: !1,
1118
- children: a !== !1 && /* @__PURE__ */ e(
1119
- S,
1208
+ children: n !== !1 && /* @__PURE__ */ e(
1209
+ O,
1120
1210
  {
1121
1211
  content: /* @__PURE__ */ e(
1122
- O,
1212
+ T,
1123
1213
  {
1124
1214
  format: c,
1125
- renderer: a
1215
+ renderer: n
1126
1216
  }
1127
1217
  ),
1128
1218
  isAnimationActive: !1
@@ -1132,90 +1222,90 @@ const et = k.forwardRef(
1132
1222
  ) }) });
1133
1223
  }
1134
1224
  );
1135
- et.displayName = "TreemapChart";
1136
- const U = "var(--color-chart-1)", tt = "var(--chart-track)", P = 24, rt = 44, re = 0.55, ne = 4, ae = (t, r, n, l, o) => {
1137
- const a = Math.min(o, n / 2, l);
1138
- return `M ${t},${r + l} L ${t},${r + a} Q ${t},${r} ${t + a},${r} L ${t + n - a},${r} Q ${t + n},${r} ${t + n},${r + a} L ${t + n},${r + l} Z`;
1225
+ rt.displayName = "TreemapChart";
1226
+ const J = "var(--color-chart-1)", at = "var(--chart-track)", G = 24, it = 44, ie = 0.55, oe = 4, le = (t, r, a, i, o) => {
1227
+ const n = Math.min(o, a / 2, i);
1228
+ return `M ${t},${r + i} L ${t},${r + n} Q ${t},${r} ${t + n},${r} L ${t + a - n},${r} Q ${t + a},${r} ${t + a},${r + n} L ${t + a},${r + i} Z`;
1139
1229
  };
1140
- function nt() {
1141
- const t = k.useRef(null), [r, n] = k.useState(0);
1142
- return k.useLayoutEffect(() => {
1143
- const l = t.current;
1144
- if (!l) return;
1145
- n(l.getBoundingClientRect().width);
1146
- const o = new ResizeObserver((a) => {
1147
- var u;
1148
- const s = ((u = a[0]) == null ? void 0 : u.contentRect.width) ?? 0;
1149
- n((c) => Math.abs(c - s) > 0.5 ? s : c);
1230
+ function ot() {
1231
+ const t = R.useRef(null), [r, a] = R.useState(0);
1232
+ return R.useLayoutEffect(() => {
1233
+ const i = t.current;
1234
+ if (!i) return;
1235
+ a(i.getBoundingClientRect().width);
1236
+ const o = new ResizeObserver((n) => {
1237
+ var x;
1238
+ const l = ((x = n[0]) == null ? void 0 : x.contentRect.width) ?? 0;
1239
+ a((c) => Math.abs(c - l) > 0.5 ? l : c);
1150
1240
  });
1151
- return o.observe(l), () => o.disconnect();
1241
+ return o.observe(i), () => o.disconnect();
1152
1242
  }, []), { ref: t, width: r };
1153
1243
  }
1154
- const at = k.forwardRef(
1244
+ const lt = R.forwardRef(
1155
1245
  ({
1156
1246
  data: t,
1157
1247
  nameKey: r,
1158
- valueKey: n,
1159
- height: l = T,
1248
+ valueKey: a,
1249
+ height: i = I,
1160
1250
  formatValue: o,
1161
- label: a,
1162
- tooltip: s,
1163
- className: u
1251
+ label: n,
1252
+ tooltip: l,
1253
+ className: x
1164
1254
  }, c) => {
1165
- var R;
1166
- const f = o ?? F, { ref: d, width: x } = nt(), [v, m] = k.useState(null), b = Number(((R = t[0]) == null ? void 0 : R[n]) ?? 0), w = t.length, A = Math.max(0, l - P - rt), p = P + A, i = w > 0 ? x / (w + (w - 1) * re) : 0, h = i * re, y = t.map((g, L) => {
1167
- var te;
1168
- const M = Number(g[n]), B = Number(((te = t[L - 1]) == null ? void 0 : te[n]) ?? M), xe = b ? M / b * 100 : 0, K = B ? M / B * 100 : 0, ee = b && M > 0 ? Math.max(2, M / b * A) : 0;
1255
+ var v;
1256
+ const m = o ?? F, { ref: u, width: N } = ot(), [b, f] = R.useState(null), y = Number(((v = t[0]) == null ? void 0 : v[a]) ?? 0), C = t.length, w = Math.max(0, i - G - it), p = G + w, h = C > 0 ? N / (C + (C - 1) * ie) : 0, k = h * ie, d = t.map((g, S) => {
1257
+ var B;
1258
+ const L = Number(g[a]), P = Number(((B = t[S - 1]) == null ? void 0 : B[a]) ?? L), Q = y ? L / y * 100 : 0, q = P ? L / P * 100 : 0, M = y && L > 0 ? Math.max(2, L / y * w) : 0;
1169
1259
  return {
1170
1260
  datum: g,
1171
- index: L,
1261
+ index: S,
1172
1262
  name: String(g[r]),
1173
- value: M,
1174
- conversionFromFirst: xe,
1175
- conversionFromPrevious: K,
1176
- dropOffFromPrevious: L === 0 ? 0 : 100 - K,
1177
- x: L * (i + h),
1178
- y: p - ee,
1179
- width: i,
1180
- height: ee,
1181
- formatValue: f
1263
+ value: L,
1264
+ conversionFromFirst: Q,
1265
+ conversionFromPrevious: q,
1266
+ dropOffFromPrevious: S === 0 ? 0 : 100 - q,
1267
+ x: S * (h + k),
1268
+ y: p - M,
1269
+ width: h,
1270
+ height: M,
1271
+ formatValue: m
1182
1272
  };
1183
- }), C = v != null ? y[v] : void 0;
1184
- return /* @__PURE__ */ e("div", { ref: c, className: $("relative w-full font-sans", u), children: /* @__PURE__ */ N("div", { ref: d, className: "relative w-full", style: { height: l }, children: [
1185
- x > 0 && w > 0 && /* @__PURE__ */ N("svg", { width: x, height: l, className: "block", children: [
1186
- y.slice(1).map((g) => {
1187
- const L = y[g.index - 1];
1273
+ }), s = b != null ? d[b] : void 0;
1274
+ return /* @__PURE__ */ e("div", { ref: c, className: $("relative w-full font-sans", x), children: /* @__PURE__ */ A("div", { ref: u, className: "relative w-full", style: { height: i }, children: [
1275
+ N > 0 && C > 0 && /* @__PURE__ */ A("svg", { width: N, height: i, className: "block", children: [
1276
+ d.slice(1).map((g) => {
1277
+ const S = d[g.index - 1];
1188
1278
  return /* @__PURE__ */ e(
1189
1279
  "path",
1190
1280
  {
1191
- d: `M ${L.x + L.width},${L.y} L ${g.x},${g.y} L ${g.x},${p} L ${L.x + L.width},${p} Z`,
1192
- fill: U,
1281
+ d: `M ${S.x + S.width},${S.y} L ${g.x},${g.y} L ${g.x},${p} L ${S.x + S.width},${p} Z`,
1282
+ fill: J,
1193
1283
  opacity: 0.14
1194
1284
  },
1195
1285
  `connector-${g.index}`
1196
1286
  );
1197
1287
  }),
1198
- y.map((g) => /* @__PURE__ */ N(
1288
+ d.map((g) => /* @__PURE__ */ A(
1199
1289
  "g",
1200
1290
  {
1201
1291
  role: "img",
1202
- "aria-label": `${g.name}: ${f(g.value)} (${Math.round(g.conversionFromFirst)}% of ${y[0].name})`,
1292
+ "aria-label": `${g.name}: ${m(g.value)} (${Math.round(g.conversionFromFirst)}% of ${d[0].name})`,
1203
1293
  children: [
1204
1294
  /* @__PURE__ */ e(
1205
1295
  "path",
1206
1296
  {
1207
- d: ae(g.x, P, g.width, A, ne),
1208
- fill: tt
1297
+ d: le(g.x, G, g.width, w, oe),
1298
+ fill: at
1209
1299
  }
1210
1300
  ),
1211
1301
  g.height > 0 && /* @__PURE__ */ e(
1212
1302
  "path",
1213
1303
  {
1214
- d: ae(g.x, g.y, g.width, g.height, ne),
1215
- fill: U
1304
+ d: le(g.x, g.y, g.width, g.height, oe),
1305
+ fill: J
1216
1306
  }
1217
1307
  ),
1218
- a !== !1 && (a ? a(g) : /* @__PURE__ */ N(
1308
+ n !== !1 && (n ? n(g) : /* @__PURE__ */ A(
1219
1309
  "text",
1220
1310
  {
1221
1311
  x: g.x,
@@ -1245,19 +1335,19 @@ const at = k.forwardRef(
1245
1335
  y: p + 34,
1246
1336
  textAnchor: "start",
1247
1337
  className: "fill-tertiary text-xs tabular-nums",
1248
- children: f(g.value)
1338
+ children: m(g.value)
1249
1339
  }
1250
1340
  ),
1251
1341
  /* @__PURE__ */ e(
1252
1342
  "rect",
1253
1343
  {
1254
1344
  x: g.x,
1255
- y: P,
1256
- width: g.index === w - 1 ? i : i + h,
1257
- height: A,
1345
+ y: G,
1346
+ width: g.index === C - 1 ? h : h + k,
1347
+ height: w,
1258
1348
  fill: "transparent",
1259
- onMouseEnter: () => m(g.index),
1260
- onMouseLeave: () => m(null)
1349
+ onMouseEnter: () => f(g.index),
1350
+ onMouseLeave: () => f(null)
1261
1351
  }
1262
1352
  )
1263
1353
  ]
@@ -1265,34 +1355,34 @@ const at = k.forwardRef(
1265
1355
  `${g.name}-${g.index}`
1266
1356
  ))
1267
1357
  ] }),
1268
- s !== !1 && C && /* @__PURE__ */ e(
1358
+ l !== !1 && s && /* @__PURE__ */ e(
1269
1359
  "div",
1270
1360
  {
1271
1361
  className: "pointer-events-none absolute z-10 -translate-x-1/2 -translate-y-full",
1272
- style: { left: C.x + C.width / 2, top: C.y - 10 },
1273
- children: s ? s({
1362
+ style: { left: s.x + s.width / 2, top: s.y - 10 },
1363
+ children: l ? l({
1274
1364
  active: !0,
1275
- label: C.name,
1365
+ label: s.name,
1276
1366
  items: [
1277
1367
  {
1278
- key: C.name,
1279
- name: C.name,
1280
- value: C.value,
1281
- color: U,
1282
- datum: C.datum
1368
+ key: s.name,
1369
+ name: s.name,
1370
+ value: s.value,
1371
+ color: J,
1372
+ datum: s.datum
1283
1373
  }
1284
1374
  ],
1285
- formatValue: f
1286
- }) : /* @__PURE__ */ N("div", { className: "rounded-md bg-foreground px-2.5 py-1.5 text-xs whitespace-nowrap text-background", children: [
1287
- /* @__PURE__ */ e("div", { className: "text-xs font-normal tracking-wide uppercase text-background/60", children: C.name }),
1288
- /* @__PURE__ */ e("div", { className: "font-normal tabular-nums", children: f(C.value) }),
1289
- /* @__PURE__ */ N("div", { className: "text-background/70 tabular-nums", children: [
1290
- Math.round(C.conversionFromFirst),
1375
+ formatValue: m
1376
+ }) : /* @__PURE__ */ A("div", { className: "rounded-md bg-foreground px-2.5 py-1.5 text-xs whitespace-nowrap text-background", children: [
1377
+ /* @__PURE__ */ e("div", { className: "text-xs font-normal tracking-wide uppercase text-background/60", children: s.name }),
1378
+ /* @__PURE__ */ e("div", { className: "font-normal tabular-nums", children: m(s.value) }),
1379
+ /* @__PURE__ */ A("div", { className: "text-background/70 tabular-nums", children: [
1380
+ Math.round(s.conversionFromFirst),
1291
1381
  "% of ",
1292
- y[0].name,
1293
- C.index > 0 && /* @__PURE__ */ N(V, { children: [
1382
+ d[0].name,
1383
+ s.index > 0 && /* @__PURE__ */ A(K, { children: [
1294
1384
  " · −",
1295
- Math.round(C.dropOffFromPrevious),
1385
+ Math.round(s.dropOffFromPrevious),
1296
1386
  "% step"
1297
1387
  ] })
1298
1388
  ] })
@@ -1302,18 +1392,18 @@ const at = k.forwardRef(
1302
1392
  ] }) });
1303
1393
  }
1304
1394
  );
1305
- at.displayName = "FunnelChart";
1395
+ lt.displayName = "FunnelChart";
1306
1396
  export {
1307
- Ue as AreaChart,
1308
- Ve as BarChart,
1309
- he as ComboChart,
1310
- Ye as ComposedChart,
1311
- at as FunnelChart,
1312
- He as LineChart,
1313
- T as MIN_HEIGHT,
1314
- Ze as PieChart,
1315
- Qe as RadarChart,
1316
- qe as RadialBarChart,
1317
- Xe as ScatterChart,
1318
- et as TreemapChart
1397
+ Xe as AreaChart,
1398
+ Ze as BarChart,
1399
+ ve as ComboChart,
1400
+ Qe as ComposedChart,
1401
+ lt as FunnelChart,
1402
+ Ye as LineChart,
1403
+ I as MIN_HEIGHT,
1404
+ Je as PieChart,
1405
+ Ke as RadarChart,
1406
+ et as RadialBarChart,
1407
+ qe as ScatterChart,
1408
+ rt as TreemapChart
1319
1409
  };