@gears-frontx/ui-kit 0.4.0-alpha.5 → 0.4.0-alpha.7
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/button.js +60 -57
- package/dist/button.js.map +1 -1
- package/dist/carousel.js.map +1 -1
- package/dist/chart.js +184 -122
- package/dist/chart.js.map +1 -1
- package/dist/chunks/button.BWdRnIvz.css +1 -0
- package/dist/chunks/combobox.CKhQGu5a.css +1 -0
- package/dist/chunks/pagination.CKDEuWt6.css +1 -0
- package/dist/chunks/spinner.CLQsj9Ky.css +1 -0
- package/dist/chunks/table.CMm41tvy.css +1 -0
- package/dist/combobox.js +135 -116
- package/dist/combobox.js.map +1 -1
- package/dist/components/button/button.d.ts +18 -5
- package/dist/components/button/button.d.ts.map +1 -1
- package/dist/components/carousel/carousel.d.ts +2 -2
- package/dist/components/carousel/carousel.d.ts.map +1 -1
- package/dist/components/chart/chart.d.ts +7 -6
- package/dist/components/chart/chart.d.ts.map +1 -1
- package/dist/components/combobox/combobox.d.ts +12 -1
- package/dist/components/combobox/combobox.d.ts.map +1 -1
- package/dist/components/pagination/pagination.d.ts +33 -2
- package/dist/components/pagination/pagination.d.ts.map +1 -1
- package/dist/components/pagination/public.d.ts +1 -1
- package/dist/components/pagination/public.d.ts.map +1 -1
- package/dist/components/sidebar/sidebar.d.ts +1 -1
- package/dist/components/sidebar/sidebar.d.ts.map +1 -1
- package/dist/components/spinner/spinner.d.ts +11 -1
- package/dist/components/spinner/spinner.d.ts.map +1 -1
- package/dist/components/table/table.d.ts +18 -2
- package/dist/components/table/table.d.ts.map +1 -1
- package/dist/docs/button.md +24 -4
- package/dist/docs/combobox.md +147 -0
- package/dist/docs/pagination.md +84 -5
- package/dist/docs/spinner.md +5 -1
- package/dist/docs/table.md +95 -11
- package/dist/index.js +198 -195
- package/dist/pagination.js +96 -52
- package/dist/pagination.js.map +1 -1
- package/dist/sidebar.js.map +1 -1
- package/dist/spinner.js +30 -27
- package/dist/spinner.js.map +1 -1
- package/dist/table.js +106 -97
- package/dist/table.js.map +1 -1
- package/llms.txt +27 -9
- package/package.json +1 -1
- package/dist/chunks/button.DgUTlW0_.css +0 -1
- package/dist/chunks/combobox.DZZ3tHP_.css +0 -1
- package/dist/chunks/pagination.bFb5us_w.css +0 -1
- package/dist/chunks/spinner.sH6x_1Uf.css +0 -1
- package/dist/chunks/table.DR2nFT0x.css +0 -1
package/dist/chart.js
CHANGED
|
@@ -1,208 +1,270 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as i, jsxs as g, Fragment as
|
|
3
|
-
import { useId as j, useMemo as
|
|
4
|
-
import { cx as
|
|
5
|
-
import * as
|
|
6
|
-
import './chunks/chart.CeyctrXQ.css';const
|
|
7
|
-
container:
|
|
8
|
-
tooltipContent:
|
|
9
|
-
tooltipLabel:
|
|
10
|
-
tooltipItems:
|
|
11
|
-
tooltipItem:
|
|
12
|
-
tooltipItemCentered:
|
|
13
|
-
indicator:
|
|
14
|
-
indicatorDot:
|
|
15
|
-
indicatorLine:
|
|
16
|
-
indicatorDashed:
|
|
17
|
-
indicatorNested:
|
|
18
|
-
tooltipItemBody:
|
|
19
|
-
tooltipItemBodyNested:
|
|
20
|
-
tooltipItemBodyInline:
|
|
21
|
-
tooltipItemLabelGroup:
|
|
22
|
-
tooltipItemName:
|
|
23
|
-
tooltipItemValue:
|
|
24
|
-
legendContent:
|
|
25
|
-
legendTop:
|
|
26
|
-
legendBottom:
|
|
27
|
-
legendItem:
|
|
28
|
-
legendSwatch:
|
|
29
|
-
},
|
|
2
|
+
import { jsx as i, jsxs as g, Fragment as R } from "react/jsx-runtime";
|
|
3
|
+
import { useId as j, useMemo as O, createContext as V, useContext as G } from "react";
|
|
4
|
+
import { cx as h } from "class-variance-authority";
|
|
5
|
+
import * as B from "recharts";
|
|
6
|
+
import './chunks/chart.CeyctrXQ.css';const H = "_container_2ox8r_24", U = "_tooltipContent_2ox8r_92", k = "_tooltipLabel_2ox8r_104", F = "_tooltipItems_2ox8r_108", M = "_tooltipItem_2ox8r_108", q = "_tooltipItemCentered_2ox8r_124", z = "_indicator_2ox8r_134", K = "_indicatorDot_2ox8r_139", Z = "_indicatorLine_2ox8r_147", W = "_indicatorDashed_2ox8r_151", J = "_indicatorNested_2ox8r_158", Q = "_tooltipItemBody_2ox8r_163", X = "_tooltipItemBodyNested_2ox8r_169", Y = "_tooltipItemBodyInline_2ox8r_173", tt = "_tooltipItemLabelGroup_2ox8r_177", et = "_tooltipItemName_2ox8r_182", ot = "_tooltipItemValue_2ox8r_186", nt = "_legendContent_2ox8r_195", rt = "_legendTop_2ox8r_202", lt = "_legendBottom_2ox8r_206", it = "_legendItem_2ox8r_210", ct = "_legendSwatch_2ox8r_224", n = {
|
|
7
|
+
container: H,
|
|
8
|
+
tooltipContent: U,
|
|
9
|
+
tooltipLabel: k,
|
|
10
|
+
tooltipItems: F,
|
|
11
|
+
tooltipItem: M,
|
|
12
|
+
tooltipItemCentered: q,
|
|
13
|
+
indicator: z,
|
|
14
|
+
indicatorDot: K,
|
|
15
|
+
indicatorLine: Z,
|
|
16
|
+
indicatorDashed: W,
|
|
17
|
+
indicatorNested: J,
|
|
18
|
+
tooltipItemBody: Q,
|
|
19
|
+
tooltipItemBodyNested: X,
|
|
20
|
+
tooltipItemBodyInline: Y,
|
|
21
|
+
tooltipItemLabelGroup: tt,
|
|
22
|
+
tooltipItemName: et,
|
|
23
|
+
tooltipItemValue: ot,
|
|
24
|
+
legendContent: nt,
|
|
25
|
+
legendTop: rt,
|
|
26
|
+
legendBottom: lt,
|
|
27
|
+
legendItem: it,
|
|
28
|
+
legendSwatch: ct
|
|
29
|
+
}, at = { width: 320, height: 200 }, D = [
|
|
30
30
|
"var(--chart-1)",
|
|
31
31
|
"var(--chart-2)",
|
|
32
32
|
"var(--chart-3)",
|
|
33
33
|
"var(--chart-4)",
|
|
34
34
|
"var(--chart-5)"
|
|
35
|
-
],
|
|
36
|
-
function
|
|
37
|
-
const
|
|
38
|
-
if (!
|
|
35
|
+
], $ = V(null);
|
|
36
|
+
function A() {
|
|
37
|
+
const o = G($);
|
|
38
|
+
if (!o)
|
|
39
39
|
throw new Error("useChart must be used within a <ChartContainer />");
|
|
40
|
-
return
|
|
40
|
+
return o;
|
|
41
41
|
}
|
|
42
|
-
const
|
|
43
|
-
function
|
|
44
|
-
return
|
|
42
|
+
const st = /[^a-zA-Z0-9_-]/g, dt = /[;{}<>\\]|\/\*|\*\//;
|
|
43
|
+
function y(o) {
|
|
44
|
+
return o.replace(st, "_");
|
|
45
45
|
}
|
|
46
|
-
function
|
|
47
|
-
return !
|
|
46
|
+
function ut(o) {
|
|
47
|
+
return !dt.test(o);
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
id:
|
|
49
|
+
function ft({
|
|
50
|
+
id: o,
|
|
51
51
|
className: t,
|
|
52
52
|
children: r,
|
|
53
53
|
config: l,
|
|
54
|
-
initialDimension: a =
|
|
55
|
-
...
|
|
54
|
+
initialDimension: a = at,
|
|
55
|
+
...p
|
|
56
56
|
}) {
|
|
57
|
-
const
|
|
58
|
-
return /* @__PURE__ */ i(
|
|
59
|
-
/* @__PURE__ */ i(
|
|
60
|
-
/* @__PURE__ */ i(
|
|
57
|
+
const d = j(), c = y(`chart-${o ?? d}`);
|
|
58
|
+
return /* @__PURE__ */ i($.Provider, { value: { config: l }, children: /* @__PURE__ */ g("div", { ...p, "data-chart": c, className: h(n.container, t), children: [
|
|
59
|
+
/* @__PURE__ */ i(_t, { id: c, config: l }),
|
|
60
|
+
/* @__PURE__ */ i(B.ResponsiveContainer, { initialDimension: a, children: r })
|
|
61
61
|
] }) });
|
|
62
62
|
}
|
|
63
|
-
function
|
|
63
|
+
function _t({ id: o, config: t }) {
|
|
64
64
|
const r = Object.entries(t);
|
|
65
65
|
if (!r.length)
|
|
66
66
|
return null;
|
|
67
|
-
const l =
|
|
68
|
-
var
|
|
69
|
-
const I = ((
|
|
70
|
-
return !I || !
|
|
71
|
-
}).filter((
|
|
72
|
-
`),
|
|
67
|
+
const l = y(o), a = (m) => r.map(([_, s], L) => {
|
|
68
|
+
var N;
|
|
69
|
+
const I = ((N = s.theme) == null ? void 0 : N[m]) ?? s.color ?? D[L % D.length];
|
|
70
|
+
return !I || !ut(I) ? null : ` --color-${y(_)}: ${I};`;
|
|
71
|
+
}).filter((_) => _ !== null).join(`
|
|
72
|
+
`), p = a("light"), d = a("dark"), c = `
|
|
73
73
|
[data-chart='${l}'] {
|
|
74
|
-
${
|
|
74
|
+
${p}
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
[data-theme='dark'] [data-chart='${l}'] {
|
|
78
|
-
${
|
|
78
|
+
${d}
|
|
79
79
|
}
|
|
80
80
|
|
|
81
81
|
@media (prefers-color-scheme: dark) {
|
|
82
82
|
:root:not([data-theme='light']) [data-chart='${l}'] {
|
|
83
|
-
${
|
|
83
|
+
${d}
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
`;
|
|
87
|
-
return /* @__PURE__ */ i("style", { children:
|
|
87
|
+
return /* @__PURE__ */ i("style", { children: c });
|
|
88
88
|
}
|
|
89
|
-
const
|
|
90
|
-
function
|
|
91
|
-
|
|
89
|
+
const vt = B.Tooltip;
|
|
90
|
+
function P(o, t) {
|
|
91
|
+
return Object.fromEntries(
|
|
92
|
+
Object.entries(o).filter(([r]) => !/^on[A-Z]/.test(r) && !t.has(r))
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
const ht = /* @__PURE__ */ new Set([
|
|
96
|
+
"accessibilityLayer",
|
|
97
|
+
"activeIndex",
|
|
98
|
+
"allowEscapeViewBox",
|
|
99
|
+
"animationDuration",
|
|
100
|
+
"animationEasing",
|
|
101
|
+
"axisId",
|
|
102
|
+
"children",
|
|
103
|
+
"content",
|
|
104
|
+
"contentStyle",
|
|
105
|
+
"coordinate",
|
|
106
|
+
"cursor",
|
|
107
|
+
"dangerouslySetInnerHTML",
|
|
108
|
+
"defaultIndex",
|
|
109
|
+
"filterNull",
|
|
110
|
+
"includeHidden",
|
|
111
|
+
"isAnimationActive",
|
|
112
|
+
"itemSorter",
|
|
113
|
+
"itemStyle",
|
|
114
|
+
"labelStyle",
|
|
115
|
+
"offset",
|
|
116
|
+
"payloadUniqBy",
|
|
117
|
+
"portal",
|
|
118
|
+
"position",
|
|
119
|
+
"reverseDirection",
|
|
120
|
+
"separator",
|
|
121
|
+
"shared",
|
|
122
|
+
"trigger",
|
|
123
|
+
"useTranslate3d",
|
|
124
|
+
"wrapperClassName",
|
|
125
|
+
"wrapperStyle"
|
|
126
|
+
]);
|
|
127
|
+
function Nt({
|
|
128
|
+
active: o,
|
|
92
129
|
payload: t,
|
|
93
130
|
className: r,
|
|
94
131
|
indicator: l = "dot",
|
|
95
132
|
hideLabel: a = !1,
|
|
96
|
-
hideIndicator:
|
|
97
|
-
label:
|
|
98
|
-
labelFormatter:
|
|
99
|
-
labelClassName:
|
|
100
|
-
formatter:
|
|
101
|
-
color:
|
|
133
|
+
hideIndicator: p = !1,
|
|
134
|
+
label: d,
|
|
135
|
+
labelFormatter: c,
|
|
136
|
+
labelClassName: m,
|
|
137
|
+
formatter: _,
|
|
138
|
+
color: s,
|
|
102
139
|
nameKey: L,
|
|
103
|
-
labelKey: I
|
|
140
|
+
labelKey: I,
|
|
141
|
+
...N
|
|
104
142
|
}) {
|
|
105
|
-
const { config:
|
|
106
|
-
var
|
|
143
|
+
const { config: x } = A(), E = O(() => {
|
|
144
|
+
var v;
|
|
107
145
|
if (a || !(t != null && t.length))
|
|
108
146
|
return null;
|
|
109
|
-
const [
|
|
110
|
-
return
|
|
111
|
-
}, [
|
|
112
|
-
if (!
|
|
147
|
+
const [e] = t, S = `${I ?? (e == null ? void 0 : e.dataKey) ?? (e == null ? void 0 : e.name) ?? "value"}`, f = b(x, e, S), u = !I && typeof d == "string" ? ((v = x[d]) == null ? void 0 : v.label) ?? d : f == null ? void 0 : f.label;
|
|
148
|
+
return c ? /* @__PURE__ */ i("div", { className: h(n.tooltipLabel, m), children: c(u, t) }) : u ? /* @__PURE__ */ i("div", { className: h(n.tooltipLabel, m), children: u }) : null;
|
|
149
|
+
}, [d, c, t, a, m, x, I]);
|
|
150
|
+
if (!o || !(t != null && t.length))
|
|
113
151
|
return null;
|
|
114
|
-
const
|
|
115
|
-
return /* @__PURE__ */ g("div", { className:
|
|
116
|
-
|
|
117
|
-
/* @__PURE__ */ i("div", { className:
|
|
152
|
+
const C = t.length === 1 && l !== "dot";
|
|
153
|
+
return /* @__PURE__ */ g("div", { ...P(N, ht), className: h(n.tooltipContent, r), children: [
|
|
154
|
+
C ? null : E,
|
|
155
|
+
/* @__PURE__ */ i("div", { className: n.tooltipItems, children: t.filter((e) => e.type !== "none").map((e, S) => {
|
|
118
156
|
var T;
|
|
119
|
-
const
|
|
157
|
+
const f = `${L ?? e.name ?? e.dataKey ?? "value"}`, u = b(x, e, f), v = s ?? ((T = e.payload) == null ? void 0 : T.fill) ?? e.color;
|
|
120
158
|
return /* @__PURE__ */ i(
|
|
121
159
|
"div",
|
|
122
160
|
{
|
|
123
|
-
className:
|
|
124
|
-
children:
|
|
125
|
-
|
|
161
|
+
className: h(n.tooltipItem, l === "dot" && n.tooltipItemCentered),
|
|
162
|
+
children: _ && (e == null ? void 0 : e.value) !== void 0 && e.name ? _(e.value, e.name, e, S, e.payload) : /* @__PURE__ */ g(R, { children: [
|
|
163
|
+
u != null && u.icon ? /* @__PURE__ */ i(u.icon, {}) : !p && /* @__PURE__ */ i(
|
|
126
164
|
"div",
|
|
127
165
|
{
|
|
128
|
-
className:
|
|
129
|
-
|
|
130
|
-
l === "dot" &&
|
|
131
|
-
l === "line" &&
|
|
132
|
-
l === "dashed" &&
|
|
133
|
-
l === "dashed" &&
|
|
166
|
+
className: h(
|
|
167
|
+
n.indicator,
|
|
168
|
+
l === "dot" && n.indicatorDot,
|
|
169
|
+
l === "line" && n.indicatorLine,
|
|
170
|
+
l === "dashed" && n.indicatorDashed,
|
|
171
|
+
l === "dashed" && C && n.indicatorNested
|
|
134
172
|
),
|
|
135
|
-
style: l === "dashed" ? { borderColor:
|
|
173
|
+
style: l === "dashed" ? { borderColor: v } : { backgroundColor: v }
|
|
136
174
|
}
|
|
137
175
|
),
|
|
138
176
|
/* @__PURE__ */ g(
|
|
139
177
|
"div",
|
|
140
178
|
{
|
|
141
|
-
className:
|
|
142
|
-
|
|
143
|
-
|
|
179
|
+
className: h(
|
|
180
|
+
n.tooltipItemBody,
|
|
181
|
+
C ? n.tooltipItemBodyNested : n.tooltipItemBodyInline
|
|
144
182
|
),
|
|
145
183
|
children: [
|
|
146
|
-
/* @__PURE__ */ g("div", { className:
|
|
147
|
-
|
|
148
|
-
/* @__PURE__ */ i("span", { className:
|
|
184
|
+
/* @__PURE__ */ g("div", { className: n.tooltipItemLabelGroup, children: [
|
|
185
|
+
C ? E : null,
|
|
186
|
+
/* @__PURE__ */ i("span", { className: n.tooltipItemName, children: (u == null ? void 0 : u.label) ?? e.name })
|
|
149
187
|
] }),
|
|
150
|
-
|
|
188
|
+
e.value != null && /* @__PURE__ */ i("span", { className: n.tooltipItemValue, children: typeof e.value == "number" ? e.value.toLocaleString() : String(e.value) })
|
|
151
189
|
]
|
|
152
190
|
}
|
|
153
191
|
)
|
|
154
192
|
] })
|
|
155
193
|
},
|
|
156
|
-
|
|
194
|
+
S
|
|
157
195
|
);
|
|
158
196
|
}) })
|
|
159
197
|
] });
|
|
160
198
|
}
|
|
161
|
-
const
|
|
162
|
-
|
|
163
|
-
|
|
199
|
+
const xt = B.Legend, pt = /* @__PURE__ */ new Set([
|
|
200
|
+
"align",
|
|
201
|
+
"chartHeight",
|
|
202
|
+
"chartWidth",
|
|
203
|
+
"children",
|
|
204
|
+
"content",
|
|
205
|
+
"dangerouslySetInnerHTML",
|
|
206
|
+
"formatter",
|
|
207
|
+
"height",
|
|
208
|
+
"iconSize",
|
|
209
|
+
"iconType",
|
|
210
|
+
"inactiveColor",
|
|
211
|
+
"itemSorter",
|
|
212
|
+
"labelStyle",
|
|
213
|
+
"layout",
|
|
214
|
+
"margin",
|
|
215
|
+
"offset",
|
|
216
|
+
"payloadUniqBy",
|
|
217
|
+
"portal",
|
|
218
|
+
"position",
|
|
219
|
+
"width",
|
|
220
|
+
"wrapperStyle"
|
|
221
|
+
]);
|
|
222
|
+
function Ct({
|
|
223
|
+
className: o,
|
|
164
224
|
hideIcon: t = !1,
|
|
165
225
|
payload: r,
|
|
166
226
|
verticalAlign: l = "bottom",
|
|
167
|
-
nameKey: a
|
|
227
|
+
nameKey: a,
|
|
228
|
+
...p
|
|
168
229
|
}) {
|
|
169
|
-
const { config:
|
|
230
|
+
const { config: d } = A();
|
|
170
231
|
return r != null && r.length ? /* @__PURE__ */ i(
|
|
171
232
|
"div",
|
|
172
233
|
{
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
n
|
|
234
|
+
...P(p, pt),
|
|
235
|
+
className: h(
|
|
236
|
+
n.legendContent,
|
|
237
|
+
l === "top" ? n.legendTop : n.legendBottom,
|
|
238
|
+
o
|
|
177
239
|
),
|
|
178
|
-
children: r.filter((c) => c.type !== "none").map((c,
|
|
179
|
-
const
|
|
180
|
-
return /* @__PURE__ */ g("div", { className:
|
|
181
|
-
s != null && s.icon && !t ? /* @__PURE__ */ i(s.icon, {}) : /* @__PURE__ */ i("div", { className:
|
|
240
|
+
children: r.filter((c) => c.type !== "none").map((c, m) => {
|
|
241
|
+
const _ = `${a ?? c.dataKey ?? "value"}`, s = b(d, c, _);
|
|
242
|
+
return /* @__PURE__ */ g("div", { className: n.legendItem, children: [
|
|
243
|
+
s != null && s.icon && !t ? /* @__PURE__ */ i(s.icon, {}) : /* @__PURE__ */ i("div", { className: n.legendSwatch, style: { backgroundColor: c.color } }),
|
|
182
244
|
s == null ? void 0 : s.label
|
|
183
|
-
] },
|
|
245
|
+
] }, m);
|
|
184
246
|
})
|
|
185
247
|
}
|
|
186
248
|
) : null;
|
|
187
249
|
}
|
|
188
|
-
function
|
|
189
|
-
if (!(t in
|
|
250
|
+
function w(o, t) {
|
|
251
|
+
if (!(t in o))
|
|
190
252
|
return;
|
|
191
|
-
const r =
|
|
253
|
+
const r = o[t];
|
|
192
254
|
return typeof r == "string" ? r : void 0;
|
|
193
255
|
}
|
|
194
|
-
function
|
|
256
|
+
function b(o, t, r) {
|
|
195
257
|
if (typeof t != "object" || t === null)
|
|
196
258
|
return;
|
|
197
|
-
const l = "payload" in t && typeof t.payload == "object" && t.payload !== null ? t.payload : void 0, a =
|
|
198
|
-
return a in
|
|
259
|
+
const l = "payload" in t && typeof t.payload == "object" && t.payload !== null ? t.payload : void 0, a = w(t, r) ?? (l && w(l, r)) ?? r;
|
|
260
|
+
return a in o ? o[a] : o[r];
|
|
199
261
|
}
|
|
200
262
|
export {
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
263
|
+
ft as ChartContainer,
|
|
264
|
+
xt as ChartLegend,
|
|
265
|
+
Ct as ChartLegendContent,
|
|
266
|
+
_t as ChartStyle,
|
|
267
|
+
vt as ChartTooltip,
|
|
268
|
+
Nt as ChartTooltipContent
|
|
207
269
|
};
|
|
208
270
|
//# sourceMappingURL=chart.js.map
|
package/dist/chart.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chart.js","sources":["../src/components/chart/chart.tsx"],"sourcesContent":["'use client';\n\n/*\n * Upstream (apps/v4/registry/bases/base/ui/chart.tsx) wraps Recharts:\n * ChartContainer supplies the ResponsiveContainer plus a per-instance\n * runtime `<style>` tag (ChartStyle) that turns each `ChartConfig` entry\n * into a `--color-<key>` custom property scoped to that one chart instance\n * via a `data-chart` id — the hook a consumer's own Bar/Line/Area elements\n * read from (`fill=\"var(--color-desktop)\"`) to pick up branded series\n * colors without prop-drilling them through Recharts' own API. `data-chart`\n * is that scoping id, not this kit's usual `data-slot` marker — there is no\n * `data-slot` here by design, same as every other ported part.\n *\n * Two deliberate deviations from upstream, both forced by this kit's own\n * constraints rather than a style preference — see chart.md's \"Porting\n * notes\" for the consumer-facing summary:\n *\n * 1. THEMES / dark selector - upstream keys the per-theme color map by\n * `{ light: \"\", dark: \".dark\" }`, a literal dark-mode class selector.\n * This kit has no such class (see theme.css's header): dark\n * mode is `[data-theme='dark']` plus a `prefers-color-scheme` fallback\n * guarded by `:not([data-theme='light'])`. ChartStyle below emits BOTH\n * selectors for the dark entry instead of one, mirroring theme.css's own\n * dual mechanism. The public `ChartConfig['theme']` keys stay exactly\n * `light`/`dark` regardless — that part is upstream's real API, not the\n * selector text it happens to compile to.\n * 2. Palette fallback - theme.css publishes `--chart-1`..`--chart-5`, and a\n * `ChartConfig` entry that names neither a `color` nor a `theme` pair\n * takes the step at its own position in the config (see CHART_PALETTE\n * below). A consumer still supplies every series colour through\n * `ChartConfig` itself when they want to, and an explicit value always\n * wins; the fallback only decides what an unbranded chart paints.\n */\n\nimport {\n type ComponentProps,\n type ComponentType,\n type ReactNode,\n createContext,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport { cx } from 'class-variance-authority';\nimport * as RechartsPrimitive from 'recharts';\nimport type { DefaultLegendContentProps, DefaultTooltipContentProps, TooltipValueType } from 'recharts';\n\nimport styles from './chart.module.css';\n\n// Matches Recharts' own default (used when a chart mounts with no measured\n// size yet) being {-1,-1} — upstream overrides it to a real, positive size\n// so ChartContainer's children render immediately instead of waiting for a\n// ResizeObserver entry that jsdom (and a slow first paint) may delay.\nconst INITIAL_DIMENSION = { width: 320, height: 200 } as const;\n\n// The published series palette, in order. A ChartConfig entry naming no\n// colour of its own takes the step at ITS OWN index in the config, not at\n// its index among the uncoloured entries: a caller who brands one series\n// and leaves the rest alone then still gets distinct steps for the rest,\n// instead of a fallback landing on the same hue they just chose. Five\n// series is what the spec draws; a sixth wraps to the first, which reads\n// better than a series painting in the charting library's stock colour.\nconst CHART_PALETTE = [\n 'var(--chart-1)',\n 'var(--chart-2)',\n 'var(--chart-3)',\n 'var(--chart-4)',\n 'var(--chart-5)',\n] as const;\n\ntype TooltipNameType = number | string;\n\nexport type ChartConfig = Record<\n string,\n {\n label?: ReactNode;\n icon?: ComponentType;\n } & (\n | { color?: string; theme?: never }\n | { color?: never; theme: Record<'light' | 'dark', string> }\n )\n>;\n\ninterface ChartContextValue {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextValue | null>(null);\n\nfunction useChart() {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\nexport type ChartContainerProps = Omit<ComponentProps<'div'>, 'className' | 'children'> & {\n className?: string;\n config: ChartConfig;\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n initialDimension?: { width: number; height: number };\n};\n\n/*\n * Everything ChartStyle interpolates into its <style> tag is\n * consumer-supplied — the chart's `id`, every `ChartConfig` key, every\n * colour string — and React does not parse or validate CSS syntax within\n * it, whether the string reaches the tag as JSX children or via\n * `dangerouslySetInnerHTML`. An id of `x] { } body { display: none` would\n * end the selector and start a rule of its own; a colour of `red; } body {\n * … }` does the same one line down; either could carry a literal\n * `</style>` and try to leave CSS altogether. So the two shapes that reach\n * the stylesheet are constrained rather than trusted: identifiers are\n * reduced to a character set that cannot express any of those, and colour\n * VALUES (which have no such small alphabet — they run from `red` to\n * `color-mix(in oklab, …)`) are checked for the characters that would let\n * one escape its own declaration, and dropped whole if they carry any.\n */\nconst CSS_IDENT_UNSAFE = /[^a-zA-Z0-9_-]/g;\n\n// Anything that could close a declaration, a rule, a comment, or the\n// <style> element itself. Backslash is in the list because a CSS escape\n// sequence is another way to spell any of them.\nconst CSS_VALUE_UNSAFE = /[;{}<>\\\\]|\\/\\*|\\*\\//;\n\nfunction cssIdentifier(value: string): string {\n return value.replace(CSS_IDENT_UNSAFE, '_');\n}\n\nfunction isSafeCssValue(value: string): boolean {\n return !CSS_VALUE_UNSAFE.test(value);\n}\n\nexport function ChartContainer({\n id,\n className,\n children,\n config,\n initialDimension = INITIAL_DIMENSION,\n ...props\n}: ChartContainerProps) {\n const uniqueId = useId();\n // Normalized here, not just inside ChartStyle: the same string has to\n // land in the `data-chart` attribute and in the selector that targets\n // it, so they must be normalized by the same rule or they stop matching.\n const chartId = cssIdentifier(`chart-${id ?? uniqueId}`);\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div data-chart={chartId} className={cx(styles.container, className)} {...props}>\n <ChartStyle id={chartId} config={config} />\n <RechartsPrimitive.ResponsiveContainer initialDimension={initialDimension}>\n {children}\n </RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n}\n\nexport interface ChartStyleProps {\n id: string;\n config: ChartConfig;\n}\n\n// Exported standalone (matching upstream) for a consumer building their own\n// chart shell without ChartContainer's div/ResponsiveContainer wrapper, who\n// still wants the same per-instance `--color-*` custom-property injection.\nexport function ChartStyle({ id, config }: ChartStyleProps) {\n const colorConfig = Object.entries(config);\n\n if (!colorConfig.length) {\n return null;\n }\n\n const safeId = cssIdentifier(id);\n\n const declarationsFor = (theme: 'light' | 'dark') =>\n colorConfig\n .map(([key, itemConfig], index) => {\n const color =\n itemConfig.theme?.[theme] ??\n itemConfig.color ??\n CHART_PALETTE[index % CHART_PALETTE.length];\n // A rejected colour drops its whole declaration rather than\n // emitting a broken one: the series then paints in Recharts' own\n // default instead of taking the rest of the stylesheet with it.\n if (!color || !isSafeCssValue(color)) {\n return null;\n }\n return ` --color-${cssIdentifier(key)}: ${color};`;\n })\n .filter((declaration): declaration is string => declaration !== null)\n .join('\\n');\n\n const lightDeclarations = declarationsFor('light');\n const darkDeclarations = declarationsFor('dark');\n\n // See the file header's point 1: two dark blocks (an explicit attribute\n // selector plus a prefers-color-scheme fallback) instead of upstream's\n // single `.dark` class, mirroring theme.css's own dual mechanism. The\n // light block carries no selector prefix, same as upstream's `THEMES.light\n // === \"\"` — it is the unconditional default every chart instance starts\n // from, which the dark blocks below layer on top of.\n const css = `\n[data-chart='${safeId}'] {\n${lightDeclarations}\n}\n\n[data-theme='dark'] [data-chart='${safeId}'] {\n${darkDeclarations}\n}\n\n@media (prefers-color-scheme: dark) {\n :root:not([data-theme='light']) [data-chart='${safeId}'] {\n${darkDeclarations}\n }\n}\n`;\n\n // Per-instance, consumer-supplied colors have no other way to reach a\n // scoped CSS custom property — there is no static class this kit's build\n // could hash for an arbitrary runtime string. Passing `css` as the\n // `<style>` element's JSX children — rather than through\n // `dangerouslySetInnerHTML` — gets it React 19's own `</style`-escaping on\n // the server (so a value containing a literal `</style><script>…` cannot\n // break out of the tag in SSR output) and, on the client, lands it as a\n // single inert Text node that is never parsed as markup. Either way it\n // cannot execute as script. `isSafeCssValue`/`cssIdentifier` above still\n // matter here even though they're no longer the primary XSS defense: they\n // keep `<`/`>` out of the string entirely, which is what keeps server and\n // client output identical (a raw `</style` would escape only on the\n // server, producing a hydration mismatch).\n return <style>{css}</style>;\n}\n\nexport const ChartTooltip = RechartsPrimitive.Tooltip;\n\nexport type ChartTooltipContentProps = ComponentProps<typeof RechartsPrimitive.Tooltip> &\n Omit<ComponentProps<'div'>, 'className'> & {\n className?: string;\n hideLabel?: boolean;\n hideIndicator?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n nameKey?: string;\n labelKey?: string;\n } & Omit<DefaultTooltipContentProps<TooltipValueType, TooltipNameType>, 'accessibilityLayer'>;\n\nexport function ChartTooltipContent({\n active,\n payload,\n className,\n indicator = 'dot',\n hideLabel = false,\n hideIndicator = false,\n label,\n labelFormatter,\n labelClassName,\n formatter,\n color,\n nameKey,\n labelKey,\n}: ChartTooltipContentProps) {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n const key = `${labelKey ?? item?.dataKey ?? item?.name ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value =\n !labelKey && typeof label === 'string' ? (config[label]?.label ?? label) : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cx(styles.tooltipLabel, labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cx(styles.tooltipLabel, labelClassName)}>{value}</div>;\n }, [label, labelFormatter, payload, hideLabel, labelClassName, config, labelKey]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div className={cx(styles.tooltipContent, className)}>\n {!nestLabel ? tooltipLabel : null}\n <div className={styles.tooltipItems}>\n {payload\n .filter((item) => item.type !== 'none')\n .map((item, index) => {\n const key = `${nameKey ?? item.name ?? item.dataKey ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color ?? item.payload?.fill ?? item.color;\n\n return (\n <div\n key={index}\n className={cx(styles.tooltipItem, indicator === 'dot' && styles.tooltipItemCentered)}\n >\n {formatter && item?.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload)\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cx(\n styles.indicator,\n indicator === 'dot' && styles.indicatorDot,\n indicator === 'line' && styles.indicatorLine,\n indicator === 'dashed' && styles.indicatorDashed,\n indicator === 'dashed' && nestLabel && styles.indicatorNested,\n )}\n // Two paint targets, not one custom-property pair like\n // upstream's `bg-(--color-bg)`/`border-(--color-border)`\n // arbitrary-value classes: dot/line indicators are filled\n // swatches (background only — chart.module.css's `.indicator`\n // sets no border), the dashed indicator is a hollow\n // dashed-border swatch (border only — `.indicatorDashed`\n // keeps its own background transparent). Setting both\n // properties unconditionally, like upstream does via two\n // always-present custom properties, would depend on which\n // upstream utility wins the cascade for the dashed case;\n // branching here is unambiguous.\n style={\n indicator === 'dashed'\n ? { borderColor: indicatorColor }\n : { backgroundColor: indicatorColor }\n }\n />\n )\n )}\n <div\n className={cx(\n styles.tooltipItemBody,\n nestLabel ? styles.tooltipItemBodyNested : styles.tooltipItemBodyInline,\n )}\n >\n <div className={styles.tooltipItemLabelGroup}>\n {nestLabel ? tooltipLabel : null}\n <span className={styles.tooltipItemName}>{itemConfig?.label ?? item.name}</span>\n </div>\n {item.value != null && (\n <span className={styles.tooltipItemValue}>\n {typeof item.value === 'number' ? item.value.toLocaleString() : String(item.value)}\n </span>\n )}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n}\n\nexport const ChartLegend = RechartsPrimitive.Legend;\n\nexport type ChartLegendContentProps = Omit<ComponentProps<'div'>, 'className'> & {\n className?: string;\n hideIcon?: boolean;\n nameKey?: string;\n} & DefaultLegendContentProps;\n\nexport function ChartLegendContent({\n className,\n hideIcon = false,\n payload,\n verticalAlign = 'bottom',\n nameKey,\n}: ChartLegendContentProps) {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n className={cx(\n styles.legendContent,\n verticalAlign === 'top' ? styles.legendTop : styles.legendBottom,\n className,\n )}\n >\n {payload\n .filter((item) => item.type !== 'none')\n .map((item, index) => {\n const key = `${nameKey ?? item.dataKey ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div key={index} className={styles.legendItem}>\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div className={styles.legendSwatch} style={{ backgroundColor: item.color }} />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n}\n\n// Guarded, single-purpose replacement for upstream's two inline\n// `payload[key as keyof typeof payload] as string` assertions: `in` proves\n// the property exists at runtime, this narrows the read value itself\n// instead of asserting the container's shape.\nfunction getStringField(source: object, key: string): string | undefined {\n if (!(key in source)) {\n return undefined;\n }\n const value = (source as Record<string, unknown>)[key];\n return typeof value === 'string' ? value : undefined;\n}\n\nfunction getPayloadConfigFromPayload(\n config: ChartConfig,\n payload: unknown,\n key: string,\n): ChartConfig[string] | undefined {\n if (typeof payload !== 'object' || payload === null) {\n return undefined;\n }\n\n const payloadPayload =\n 'payload' in payload && typeof payload.payload === 'object' && payload.payload !== null\n ? payload.payload\n : undefined;\n\n const configLabelKey =\n getStringField(payload, key) ?? (payloadPayload && getStringField(payloadPayload, key)) ?? key;\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n"],"names":["INITIAL_DIMENSION","CHART_PALETTE","ChartContext","createContext","useChart","context","useContext","CSS_IDENT_UNSAFE","CSS_VALUE_UNSAFE","cssIdentifier","value","isSafeCssValue","ChartContainer","id","className","children","config","initialDimension","props","uniqueId","useId","chartId","jsxs","cx","styles","jsx","ChartStyle","RechartsPrimitive","colorConfig","safeId","declarationsFor","theme","key","itemConfig","index","color","_a","declaration","lightDeclarations","darkDeclarations","css","ChartTooltip","ChartTooltipContent","active","payload","indicator","hideLabel","hideIndicator","label","labelFormatter","labelClassName","formatter","nameKey","labelKey","tooltipLabel","useMemo","item","getPayloadConfigFromPayload","nestLabel","indicatorColor","Fragment","ChartLegend","ChartLegendContent","hideIcon","verticalAlign","getStringField","source","payloadPayload","configLabelKey"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDMA,KAAoB,EAAE,OAAO,KAAK,QAAQ,IAAA,GAS1CC,IAAgB;AAAA,EACpB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAmBMC,IAAeC,EAAwC,IAAI;AAEjE,SAASC,IAAW;AAClB,QAAMC,IAAUC,EAAWJ,CAAY;AAEvC,MAAI,CAACG;AACH,UAAM,IAAI,MAAM,mDAAmD;AAGrE,SAAOA;AACT;AAwBA,MAAME,KAAmB,mBAKnBC,KAAmB;AAEzB,SAASC,EAAcC,GAAuB;AAC5C,SAAOA,EAAM,QAAQH,IAAkB,GAAG;AAC5C;AAEA,SAASI,GAAeD,GAAwB;AAC9C,SAAO,CAACF,GAAiB,KAAKE,CAAK;AACrC;AAEO,SAASE,GAAe;AAAA,EAC7B,IAAAC;AAAA,EACA,WAAAC;AAAA,EACA,UAAAC;AAAA,EACA,QAAAC;AAAA,EACA,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AAG;AAEhE,eACE,gBAAAV,EAAC,OAAA,EAAgB,WAAWE,EAAO,YAChC,UAAA;AAAA,UAAAS,KAAA,QAAAA,EAAY,QAAQ,CAAC8B,sBACnB9B,EAAW,MAAX,CAAA,CAAgB,IAEjB,gBAAAR,EAAC,OAAA,EAAI,WAAWD,EAAO,cAAc,OAAO,EAAE,iBAAiBgC,EAAK,SAAS;AAAA,UAE9EvB,KAAA,gBAAAA,EAAY;AAAA,QAAA,EAAA,GANLC,CAOV;AAAA,MAEJ,CAAC;AAAA,IAAA;AAAA,EAAA,IA3BE;AA8BX;AAMA,SAAS+B,EAAeC,GAAgBlC,GAAiC;AACvE,MAAI,EAAEA,KAAOkC;AACX;AAEF,QAAMxD,IAASwD,EAAmClC,CAAG;AACrD,SAAO,OAAOtB,KAAU,WAAWA,IAAQ;AAC7C;AAEA,SAAS+C,EACPzC,GACA4B,GACAZ,GACiC;AACjC,MAAI,OAAOY,KAAY,YAAYA,MAAY;AAC7C;AAGF,QAAMuB,IACJ,aAAavB,KAAW,OAAOA,EAAQ,WAAY,YAAYA,EAAQ,YAAY,OAC/EA,EAAQ,UACR,QAEAwB,IACJH,EAAerB,GAASZ,CAAG,MAAMmC,KAAkBF,EAAeE,GAAgBnC,CAAG,MAAMA;AAE7F,SAAOoC,KAAkBpD,IAASA,EAAOoD,CAAc,IAAIpD,EAAOgB,CAAG;AACvE;"}
|
|
1
|
+
{"version":3,"file":"chart.js","sources":["../src/components/chart/chart.tsx"],"sourcesContent":["'use client';\n\n/*\n * Upstream (apps/v4/registry/bases/base/ui/chart.tsx) wraps Recharts:\n * ChartContainer supplies the ResponsiveContainer plus a per-instance\n * runtime `<style>` tag (ChartStyle) that turns each `ChartConfig` entry\n * into a `--color-<key>` custom property scoped to that one chart instance\n * via a `data-chart` id — the hook a consumer's own Bar/Line/Area elements\n * read from (`fill=\"var(--color-desktop)\"`) to pick up branded series\n * colors without prop-drilling them through Recharts' own API. `data-chart`\n * is that scoping id, not this kit's usual `data-slot` marker — there is no\n * `data-slot` here by design, same as every other ported part.\n *\n * Two deliberate deviations from upstream, both forced by this kit's own\n * constraints rather than a style preference — see chart.md's \"Porting\n * notes\" for the consumer-facing summary:\n *\n * 1. THEMES / dark selector - upstream keys the per-theme color map by\n * `{ light: \"\", dark: \".dark\" }`, a literal dark-mode class selector.\n * This kit has no such class (see theme.css's header): dark\n * mode is `[data-theme='dark']` plus a `prefers-color-scheme` fallback\n * guarded by `:not([data-theme='light'])`. ChartStyle below emits BOTH\n * selectors for the dark entry instead of one, mirroring theme.css's own\n * dual mechanism. The public `ChartConfig['theme']` keys stay exactly\n * `light`/`dark` regardless — that part is upstream's real API, not the\n * selector text it happens to compile to.\n * 2. Palette fallback - theme.css publishes `--chart-1`..`--chart-5`, and a\n * `ChartConfig` entry that names neither a `color` nor a `theme` pair\n * takes the step at its own position in the config (see CHART_PALETTE\n * below). A consumer still supplies every series colour through\n * `ChartConfig` itself when they want to, and an explicit value always\n * wins; the fallback only decides what an unbranded chart paints.\n */\n\nimport {\n type ComponentProps,\n type ComponentType,\n type DOMAttributes,\n type ReactNode,\n createContext,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport { cx } from 'class-variance-authority';\nimport * as RechartsPrimitive from 'recharts';\nimport type { DefaultLegendContentProps, DefaultTooltipContentProps, TooltipValueType } from 'recharts';\n\nimport styles from './chart.module.css';\n\n// Matches Recharts' own default (used when a chart mounts with no measured\n// size yet) being {-1,-1} — upstream overrides it to a real, positive size\n// so ChartContainer's children render immediately instead of waiting for a\n// ResizeObserver entry that jsdom (and a slow first paint) may delay.\nconst INITIAL_DIMENSION = { width: 320, height: 200 } as const;\n\n// The published series palette, in order. A ChartConfig entry naming no\n// colour of its own takes the step at ITS OWN index in the config, not at\n// its index among the uncoloured entries: a caller who brands one series\n// and leaves the rest alone then still gets distinct steps for the rest,\n// instead of a fallback landing on the same hue they just chose. Five\n// series is what the spec draws; a sixth wraps to the first, which reads\n// better than a series painting in the charting library's stock colour.\nconst CHART_PALETTE = [\n 'var(--chart-1)',\n 'var(--chart-2)',\n 'var(--chart-3)',\n 'var(--chart-4)',\n 'var(--chart-5)',\n] as const;\n\ntype TooltipNameType = number | string;\n\nexport type ChartConfig = Record<\n string,\n {\n label?: ReactNode;\n icon?: ComponentType;\n } & (\n | { color?: string; theme?: never }\n | { color?: never; theme: Record<'light' | 'dark', string> }\n )\n>;\n\ninterface ChartContextValue {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextValue | null>(null);\n\nfunction useChart() {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\nexport type ChartContainerProps = Omit<ComponentProps<'div'>, 'className' | 'children'> & {\n className?: string;\n config: ChartConfig;\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n initialDimension?: { width: number; height: number };\n};\n\n/*\n * Everything ChartStyle interpolates into its <style> tag is\n * consumer-supplied — the chart's `id`, every `ChartConfig` key, every\n * colour string — and React does not parse or validate CSS syntax within\n * it, whether the string reaches the tag as JSX children or via\n * `dangerouslySetInnerHTML`. An id of `x] { } body { display: none` would\n * end the selector and start a rule of its own; a colour of `red; } body {\n * … }` does the same one line down; either could carry a literal\n * `</style>` and try to leave CSS altogether. So the two shapes that reach\n * the stylesheet are constrained rather than trusted: identifiers are\n * reduced to a character set that cannot express any of those, and colour\n * VALUES (which have no such small alphabet — they run from `red` to\n * `color-mix(in oklab, …)`) are checked for the characters that would let\n * one escape its own declaration, and dropped whole if they carry any.\n */\nconst CSS_IDENT_UNSAFE = /[^a-zA-Z0-9_-]/g;\n\n// Anything that could close a declaration, a rule, a comment, or the\n// <style> element itself. Backslash is in the list because a CSS escape\n// sequence is another way to spell any of them.\nconst CSS_VALUE_UNSAFE = /[;{}<>\\\\]|\\/\\*|\\*\\//;\n\nfunction cssIdentifier(value: string): string {\n return value.replace(CSS_IDENT_UNSAFE, '_');\n}\n\nfunction isSafeCssValue(value: string): boolean {\n return !CSS_VALUE_UNSAFE.test(value);\n}\n\nexport function ChartContainer({\n id,\n className,\n children,\n config,\n initialDimension = INITIAL_DIMENSION,\n ...props\n}: ChartContainerProps) {\n const uniqueId = useId();\n // Normalized here, not just inside ChartStyle: the same string has to\n // land in the `data-chart` attribute and in the selector that targets\n // it, so they must be normalized by the same rule or they stop matching.\n const chartId = cssIdentifier(`chart-${id ?? uniqueId}`);\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div {...props} data-chart={chartId} className={cx(styles.container, className)}>\n <ChartStyle id={chartId} config={config} />\n <RechartsPrimitive.ResponsiveContainer initialDimension={initialDimension}>\n {children}\n </RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n}\n\nexport interface ChartStyleProps {\n id: string;\n config: ChartConfig;\n}\n\n// Exported standalone (matching upstream) for a consumer building their own\n// chart shell without ChartContainer's div/ResponsiveContainer wrapper, who\n// still wants the same per-instance `--color-*` custom-property injection.\nexport function ChartStyle({ id, config }: ChartStyleProps) {\n const colorConfig = Object.entries(config);\n\n if (!colorConfig.length) {\n return null;\n }\n\n const safeId = cssIdentifier(id);\n\n const declarationsFor = (theme: 'light' | 'dark') =>\n colorConfig\n .map(([key, itemConfig], index) => {\n const color =\n itemConfig.theme?.[theme] ??\n itemConfig.color ??\n CHART_PALETTE[index % CHART_PALETTE.length];\n // A rejected colour drops its whole declaration rather than\n // emitting a broken one: the series then paints in Recharts' own\n // default instead of taking the rest of the stylesheet with it.\n if (!color || !isSafeCssValue(color)) {\n return null;\n }\n return ` --color-${cssIdentifier(key)}: ${color};`;\n })\n .filter((declaration): declaration is string => declaration !== null)\n .join('\\n');\n\n const lightDeclarations = declarationsFor('light');\n const darkDeclarations = declarationsFor('dark');\n\n // See the file header's point 1: two dark blocks (an explicit attribute\n // selector plus a prefers-color-scheme fallback) instead of upstream's\n // single `.dark` class, mirroring theme.css's own dual mechanism. The\n // light block carries no selector prefix, same as upstream's `THEMES.light\n // === \"\"` — it is the unconditional default every chart instance starts\n // from, which the dark blocks below layer on top of.\n const css = `\n[data-chart='${safeId}'] {\n${lightDeclarations}\n}\n\n[data-theme='dark'] [data-chart='${safeId}'] {\n${darkDeclarations}\n}\n\n@media (prefers-color-scheme: dark) {\n :root:not([data-theme='light']) [data-chart='${safeId}'] {\n${darkDeclarations}\n }\n}\n`;\n\n // Per-instance, consumer-supplied colors have no other way to reach a\n // scoped CSS custom property — there is no static class this kit's build\n // could hash for an arbitrary runtime string. Passing `css` as the\n // `<style>` element's JSX children — rather than through\n // `dangerouslySetInnerHTML` — gets it React 19's own `</style`-escaping on\n // the server (so a value containing a literal `</style><script>…` cannot\n // break out of the tag in SSR output) and, on the client, lands it as a\n // single inert Text node that is never parsed as markup. Either way it\n // cannot execute as script. `isSafeCssValue`/`cssIdentifier` above still\n // matter here even though they're no longer the primary XSS defense: they\n // keep `<`/`>` out of the string entirely, which is what keeps server and\n // client output identical (a raw `</style` would escape only on the\n // server, producing a hydration mismatch).\n return <style>{css}</style>;\n}\n\nexport const ChartTooltip = RechartsPrimitive.Tooltip;\n\n// A content renderer's root div takes the div's attributes but none of its\n// event handlers or content props: the chart hands the renderer props of\n// its own under those names, and the renderer supplies the content itself.\ntype ContentRootAttributes = Omit<ComponentProps<'div'>, 'className' | 'content' | keyof DOMAttributes<HTMLDivElement>>;\n\n// Keeps every key a content renderer's root div must not receive off it: an\n// event handler (the chart's own are typed for its items, not for this\n// div) and whatever the chart passes in under a name of its own.\nfunction rootAttributes(props: object, rendererProps: ReadonlySet<string>): Record<string, unknown> {\n return Object.fromEntries(\n Object.entries(props).filter(([key]) => !/^on[A-Z]/.test(key) && !rendererProps.has(key)),\n );\n}\n\nexport type ChartTooltipContentProps = ComponentProps<typeof RechartsPrimitive.Tooltip> &\n ContentRootAttributes & {\n className?: string;\n hideLabel?: boolean;\n hideIndicator?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n nameKey?: string;\n labelKey?: string;\n } & Omit<DefaultTooltipContentProps<TooltipValueType, TooltipNameType>, 'accessibilityLayer'>;\n\n// What Recharts' Tooltip hands its content renderer besides the rows it\n// reads: the tooltip's own settings, the active index and coordinate, and\n// the accessibility-layer flag - plus the two ways of supplying content that\n// the rows replace. None of them is an attribute of the root div.\nconst TOOLTIP_RENDERER_PROPS: ReadonlySet<string> = new Set([\n 'accessibilityLayer',\n 'activeIndex',\n 'allowEscapeViewBox',\n 'animationDuration',\n 'animationEasing',\n 'axisId',\n 'children',\n 'content',\n 'contentStyle',\n 'coordinate',\n 'cursor',\n 'dangerouslySetInnerHTML',\n 'defaultIndex',\n 'filterNull',\n 'includeHidden',\n 'isAnimationActive',\n 'itemSorter',\n 'itemStyle',\n 'labelStyle',\n 'offset',\n 'payloadUniqBy',\n 'portal',\n 'position',\n 'reverseDirection',\n 'separator',\n 'shared',\n 'trigger',\n 'useTranslate3d',\n 'wrapperClassName',\n 'wrapperStyle',\n]);\n\nexport function ChartTooltipContent({\n active,\n payload,\n className,\n indicator = 'dot',\n hideLabel = false,\n hideIndicator = false,\n label,\n labelFormatter,\n labelClassName,\n formatter,\n color,\n nameKey,\n labelKey,\n ...props\n}: ChartTooltipContentProps) {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n const key = `${labelKey ?? item?.dataKey ?? item?.name ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value =\n !labelKey && typeof label === 'string' ? (config[label]?.label ?? label) : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cx(styles.tooltipLabel, labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cx(styles.tooltipLabel, labelClassName)}>{value}</div>;\n }, [label, labelFormatter, payload, hideLabel, labelClassName, config, labelKey]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div {...rootAttributes(props, TOOLTIP_RENDERER_PROPS)} className={cx(styles.tooltipContent, className)}>\n {!nestLabel ? tooltipLabel : null}\n <div className={styles.tooltipItems}>\n {payload\n .filter((item) => item.type !== 'none')\n .map((item, index) => {\n const key = `${nameKey ?? item.name ?? item.dataKey ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color ?? item.payload?.fill ?? item.color;\n\n return (\n <div\n key={index}\n className={cx(styles.tooltipItem, indicator === 'dot' && styles.tooltipItemCentered)}\n >\n {formatter && item?.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload)\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cx(\n styles.indicator,\n indicator === 'dot' && styles.indicatorDot,\n indicator === 'line' && styles.indicatorLine,\n indicator === 'dashed' && styles.indicatorDashed,\n indicator === 'dashed' && nestLabel && styles.indicatorNested,\n )}\n // Two paint targets, not one custom-property pair like\n // upstream's `bg-(--color-bg)`/`border-(--color-border)`\n // arbitrary-value classes: dot/line indicators are filled\n // swatches (background only — chart.module.css's `.indicator`\n // sets no border), the dashed indicator is a hollow\n // dashed-border swatch (border only — `.indicatorDashed`\n // keeps its own background transparent). Setting both\n // properties unconditionally, like upstream does via two\n // always-present custom properties, would depend on which\n // upstream utility wins the cascade for the dashed case;\n // branching here is unambiguous.\n style={\n indicator === 'dashed'\n ? { borderColor: indicatorColor }\n : { backgroundColor: indicatorColor }\n }\n />\n )\n )}\n <div\n className={cx(\n styles.tooltipItemBody,\n nestLabel ? styles.tooltipItemBodyNested : styles.tooltipItemBodyInline,\n )}\n >\n <div className={styles.tooltipItemLabelGroup}>\n {nestLabel ? tooltipLabel : null}\n <span className={styles.tooltipItemName}>{itemConfig?.label ?? item.name}</span>\n </div>\n {item.value != null && (\n <span className={styles.tooltipItemValue}>\n {typeof item.value === 'number' ? item.value.toLocaleString() : String(item.value)}\n </span>\n )}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n}\n\nexport const ChartLegend = RechartsPrimitive.Legend;\n\nexport type ChartLegendContentProps = ContentRootAttributes & {\n className?: string;\n hideIcon?: boolean;\n nameKey?: string;\n} & Omit<\n DefaultLegendContentProps,\n keyof DOMAttributes<HTMLDivElement> | Extract<keyof DefaultLegendContentProps, `on${Capitalize<string>}`>\n >;\n\n// What Recharts' Legend hands its content renderer besides the payload: its\n// own layout settings and the chart's measurements - plus the two ways of\n// supplying content that the legend items replace. None of them is an\n// attribute of the root div; the legend's event handlers, which its default\n// content attaches to each item, are kept off it by rootAttributes.\nconst LEGEND_RENDERER_PROPS: ReadonlySet<string> = new Set([\n 'align',\n 'chartHeight',\n 'chartWidth',\n 'children',\n 'content',\n 'dangerouslySetInnerHTML',\n 'formatter',\n 'height',\n 'iconSize',\n 'iconType',\n 'inactiveColor',\n 'itemSorter',\n 'labelStyle',\n 'layout',\n 'margin',\n 'offset',\n 'payloadUniqBy',\n 'portal',\n 'position',\n 'width',\n 'wrapperStyle',\n]);\n\nexport function ChartLegendContent({\n className,\n hideIcon = false,\n payload,\n verticalAlign = 'bottom',\n nameKey,\n ...props\n}: ChartLegendContentProps) {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n {...rootAttributes(props, LEGEND_RENDERER_PROPS)}\n className={cx(\n styles.legendContent,\n verticalAlign === 'top' ? styles.legendTop : styles.legendBottom,\n className,\n )}\n >\n {payload\n .filter((item) => item.type !== 'none')\n .map((item, index) => {\n const key = `${nameKey ?? item.dataKey ?? 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div key={index} className={styles.legendItem}>\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div className={styles.legendSwatch} style={{ backgroundColor: item.color }} />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n}\n\n// Guarded, single-purpose replacement for upstream's two inline\n// `payload[key as keyof typeof payload] as string` assertions: `in` proves\n// the property exists at runtime, this narrows the read value itself\n// instead of asserting the container's shape.\nfunction getStringField(source: object, key: string): string | undefined {\n if (!(key in source)) {\n return undefined;\n }\n const value = (source as Record<string, unknown>)[key];\n return typeof value === 'string' ? value : undefined;\n}\n\nfunction getPayloadConfigFromPayload(\n config: ChartConfig,\n payload: unknown,\n key: string,\n): ChartConfig[string] | undefined {\n if (typeof payload !== 'object' || payload === null) {\n return undefined;\n }\n\n const payloadPayload =\n 'payload' in payload && typeof payload.payload === 'object' && payload.payload !== null\n ? payload.payload\n : undefined;\n\n const configLabelKey =\n getStringField(payload, key) ?? (payloadPayload && getStringField(payloadPayload, key)) ?? key;\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n"],"names":["INITIAL_DIMENSION","CHART_PALETTE","ChartContext","createContext","useChart","context","useContext","CSS_IDENT_UNSAFE","CSS_VALUE_UNSAFE","cssIdentifier","value","isSafeCssValue","ChartContainer","id","className","children","config","initialDimension","props","uniqueId","useId","chartId","jsxs","cx","styles","jsx","ChartStyle","RechartsPrimitive","colorConfig","safeId","declarationsFor","theme","key","itemConfig","index","color","_a","declaration","lightDeclarations","darkDeclarations","css","ChartTooltip","rootAttributes","rendererProps","TOOLTIP_RENDERER_PROPS","ChartTooltipContent","active","payload","indicator","hideLabel","hideIndicator","label","labelFormatter","labelClassName","formatter","nameKey","labelKey","tooltipLabel","useMemo","item","getPayloadConfigFromPayload","nestLabel","indicatorColor","Fragment","ChartLegend","LEGEND_RENDERER_PROPS","ChartLegendContent","hideIcon","verticalAlign","getStringField","source","payloadPayload","configLabelKey"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDMA,KAAoB,EAAE,OAAO,KAAK,QAAQ,IAAA,GAS1CC,IAAgB;AAAA,EACpB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAmBMC,IAAeC,EAAwC,IAAI;AAEjE,SAASC,IAAW;AAClB,QAAMC,IAAUC,EAAWJ,CAAY;AAEvC,MAAI,CA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,IAAM,GAAGuB,KAAWI,EAAK,WAAW,OAAO,IAC3C1B,IAAa2B,EAA4B5C,GAAQ2C,GAAM3B,CAAG;AAEhE,eACE,gBAAAV,EAAC,OAAA,EAAgB,WAAWE,EAAO,YAChC,UAAA;AAAA,UAAAS,KAAA,QAAAA,EAAY,QAAQ,CAACkC,sBACnBlC,EAAW,MAAX,CAAA,CAAgB,IAEjB,gBAAAR,EAAC,OAAA,EAAI,WAAWD,EAAO,cAAc,OAAO,EAAE,iBAAiBmC,EAAK,SAAS;AAAA,UAE9E1B,KAAA,gBAAAA,EAAY;AAAA,QAAA,EAAA,GANLC,CAOV;AAAA,MAEJ,CAAC;AAAA,IAAA;AAAA,EAAA,IA5BE;AA+BX;AAMA,SAASmC,EAAeC,GAAgBtC,GAAiC;AACvE,MAAI,EAAEA,KAAOsC;AACX;AAEF,QAAM5D,IAAS4D,EAAmCtC,CAAG;AACrD,SAAO,OAAOtB,KAAU,WAAWA,IAAQ;AAC7C;AAEA,SAASkD,EACP5C,GACA+B,GACAf,GACiC;AACjC,MAAI,OAAOe,KAAY,YAAYA,MAAY;AAC7C;AAGF,QAAMwB,IACJ,aAAaxB,KAAW,OAAOA,EAAQ,WAAY,YAAYA,EAAQ,YAAY,OAC/EA,EAAQ,UACR,QAEAyB,IACJH,EAAetB,GAASf,CAAG,MAAMuC,KAAkBF,EAAeE,GAAgBvC,CAAG,MAAMA;AAE7F,SAAOwC,KAAkBxD,IAASA,EAAOwD,CAAc,IAAIxD,EAAOgB,CAAG;AACvE;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._button_49i8a_6{box-sizing:border-box;--button-focus-ring: var(--ring);position:relative;display:inline-flex;align-items:center;justify-content:center;gap:var(--space-2);white-space:nowrap;flex-shrink:0;border:var(--border-width) solid var(--button-border, transparent);border-radius:var(--radius-lg);font-family:inherit;font-size:var(--text-label-size);line-height:var(--text-label-line-height);font-weight:var(--text-label-weight);letter-spacing:var(--text-label-tracking);cursor:pointer;-webkit-user-select:none;user-select:none;text-decoration:none;transition:color .15s ease,background-color .15s ease,border-color .15s ease,box-shadow .15s ease}._button_49i8a_6:focus-visible{outline:var(--border-width-focus) solid var(--button-focus-ring);outline-offset:2px}@media(forced-colors:active){._button_49i8a_6:focus-visible{outline-color:Highlight}}._button_49i8a_6:disabled{pointer-events:none;opacity:var(--opacity-disabled)}._button_49i8a_6[data-loading]{pointer-events:none;opacity:var(--opacity-disabled)}._variantDefault_49i8a_132{background-color:var(--button-bg, var(--primary));color:var(--button-fg, var(--primary-foreground))}._variantDefault_49i8a_132:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--primary-hover)));color:var(--button-fg-hover, var(--button-fg, var(--primary-foreground)))}._variantDestructive_49i8a_164{--tint: 10%;--tint-hover: 20%;background-color:var(--button-bg, color-mix(in oklab, var(--destructive) var(--tint), transparent));color:var(--button-fg, var(--destructive))}[data-theme=dark] ._variantDestructive_49i8a_164{--tint: 20%;--tint-hover: 30%}@media(prefers-color-scheme:dark){:root:not([data-theme=light]) ._variantDestructive_49i8a_164{--tint: 20%;--tint-hover: 30%}}._variantDestructive_49i8a_164:hover{background-color:var(--button-bg-hover, var(--button-bg, color-mix(in oklab, var(--destructive) var(--tint-hover), transparent)));color:var(--button-fg-hover, var(--button-fg, var(--destructive)))}._variantOutline_49i8a_196{border-color:var(--button-border, var(--border-strong));background-color:var(--button-bg, var(--surface-elevated));color:var(--button-fg, var(--foreground))}._variantOutline_49i8a_196:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--muted)));color:var(--button-fg-hover, var(--button-fg, var(--foreground)))}._variantSecondary_49i8a_216{background-color:var(--button-bg, var(--secondary));color:var(--button-fg, var(--secondary-foreground))}._variantSecondary_49i8a_216:hover{background-color:var(--button-bg-hover, var(--button-bg, color-mix(in oklab, var(--secondary) 80%, transparent)));color:var(--button-fg-hover, var(--button-fg, var(--secondary-foreground)))}._variantGhost_49i8a_233{background-color:var(--button-bg, transparent);color:var(--button-fg, var(--muted-foreground))}._variantGhost_49i8a_233:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--muted)));color:var(--button-fg-hover, var(--button-fg, var(--foreground)))}._variantLink_49i8a_254{background-color:var(--button-bg, transparent);color:var(--button-fg, var(--link-foreground));text-underline-offset:4px}._variantLink_49i8a_254:hover{background-color:var(--button-bg-hover, var(--button-bg, transparent));color:var(--button-fg-hover, var(--button-fg, var(--link-foreground)));text-decoration:underline}._variantNavigation_49i8a_273{border-color:var(--button-border, var(--border));background-color:var(--button-bg, var(--card));color:var(--button-fg, var(--muted-foreground))}._variantNavigation_49i8a_273:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--muted)));color:var(--button-fg-hover, var(--button-fg, var(--muted-foreground)))}._variantNavigation_49i8a_273[data-current],._variantNavigation_49i8a_273[data-current]:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--secondary)));color:var(--button-fg-hover, var(--button-fg, var(--secondary-foreground)))}._button_49i8a_6._variantAvatar_49i8a_312{height:auto;padding:0;border:0;border-radius:var(--radius-full)}._variantAvatar_49i8a_312{background-color:var(--button-bg, transparent);color:var(--button-fg, inherit)}._variantAvatar_49i8a_312:hover{background-color:var(--button-bg-hover, var(--button-bg, transparent));color:var(--button-fg-hover, var(--button-fg, inherit))}._variantAvatar_49i8a_312:hover,._variantAvatar_49i8a_312[data-popup-open],._variantAvatar_49i8a_312[aria-expanded=true]{box-shadow:0 0 0 var(--border-width-focus) color-mix(in oklab,var(--primary) 35%,transparent)}._variantUtility_49i8a_343{border-color:transparent;background-color:var(--button-bg, transparent);color:var(--button-fg, var(--muted-foreground))}._variantUtility_49i8a_343:hover{background-color:var(--button-bg-hover, var(--button-bg, var(--muted)));color:var(--button-fg-hover, var(--button-fg, var(--foreground)))}._variantUtility_49i8a_343 ._icon_49i8a_357 svg,._variantUtility_49i8a_343 ._end_49i8a_359 svg{width:18px;height:18px}._variantDefault_49i8a_132{--button-focus-ring: var(--primary-ring)}._variantDestructive_49i8a_164{--button-focus-ring: var(--destructive-ring)}._sizeDefault_49i8a_393{height:var(--control-height-md);padding:0 var(--space-4)}._sizeSm_49i8a_308{height:var(--control-height-sm);padding:0 var(--space-3);border-radius:var(--radius-md)}._sizeLg_49i8a_412{height:var(--control-height-lg);padding:0 var(--space-5)}._button_49i8a_6[data-icon-only]{aspect-ratio:1;padding:0}._icon_49i8a_357,._end_49i8a_359{display:inline-flex}._icon_49i8a_357 svg,._end_49i8a_359 svg{width:var(--icon-size-sm);height:var(--icon-size-sm)}._sizeLg_49i8a_412 ._icon_49i8a_357 svg,._sizeLg_49i8a_412 ._end_49i8a_359 svg{width:var(--icon-size-md);height:var(--icon-size-md)}._button_49i8a_6[data-loading] ._icon_49i8a_357,._button_49i8a_6[data-loading] ._label_49i8a_457,._button_49i8a_6[data-loading] ._end_49i8a_359{opacity:0}._spinner_49i8a_42{box-sizing:border-box;position:absolute;top:0;right:0;bottom:0;left:0;margin:auto;width:var(--icon-size-xs);height:var(--icon-size-xs);border:2px solid color-mix(in oklab,currentColor 25%,transparent);border-top-color:currentColor;border-radius:50%;animation:_button-spin_49i8a_1 .8s linear infinite}@keyframes _button-spin_49i8a_1{to{rotate:360deg}}@media(prefers-reduced-motion:reduce){._spinner_49i8a_42{animation-duration:2.4s}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._inputWrap_1w5u7_15{position:relative;display:inline-flex;width:fit-content}._input_1w5u7_15{box-sizing:border-box;display:block;width:100%;min-width:12rem;height:var(--control-height-lg);padding:var(--space-1) var(--space-3);border:var(--border-width) solid var(--input);border-radius:var(--radius-lg);background-color:var(--surface-elevated);color:var(--foreground);font-family:inherit;font-size:var(--text-label-size);line-height:var(--text-label-line-height);font-weight:var(--text-body-weight);letter-spacing:var(--text-label-tracking);outline:none;transition:color .15s ease,border-color .15s ease,box-shadow .15s ease}._input_1w5u7_15::placeholder{color:var(--muted-foreground)}._input_1w5u7_15:focus-visible{border-color:var(--ring);box-shadow:inset 0 0 0 var(--ring-inset) var(--ring)}@media(forced-colors:active){._input_1w5u7_15:focus-visible{outline:2px solid Highlight;outline-offset:2px}}._input_1w5u7_15:disabled{cursor:not-allowed;opacity:var(--opacity-disabled)}._input_1w5u7_15[aria-invalid=true]{border-color:var(--destructive);box-shadow:inset 0 0 0 var(--ring-inset) var(--destructive)}._hasTrailingControl_1w5u7_110{padding-inline-end:calc(var(--space-2) + var(--control-height-sm) + var(--space-1))}._inputTrigger_1w5u7_15,._inputClear_1w5u7_15{box-sizing:border-box;position:absolute;inset-inline-end:var(--space-2);top:50%;translate:0 -50%;display:inline-flex;align-items:center;justify-content:center;width:var(--control-height-sm);height:var(--control-height-sm);padding:0;border:none;border-radius:var(--radius-sm);background-color:transparent;color:var(--muted-foreground);cursor:pointer;transition:background-color .15s ease,color .15s ease}._inputTrigger_1w5u7_15:hover,._inputClear_1w5u7_15:hover{background-color:var(--muted);color:var(--foreground)}._inputTrigger_1w5u7_15:focus-visible,._inputClear_1w5u7_15:focus-visible{outline:2px solid var(--ring);outline-offset:1px}._inputTrigger_1w5u7_15:disabled,._inputClear_1w5u7_15:disabled{cursor:not-allowed;opacity:var(--opacity-disabled)}._inputWrap_1w5u7_15:has(._inputClear_1w5u7_15) ._inputTrigger_1w5u7_15{display:none}._selectTrigger_1w5u7_177{box-sizing:border-box;display:flex;width:fit-content;max-width:100%;height:var(--control-height-sm);align-items:center;justify-content:space-between;gap:var(--space-2);padding-block:var(--space-2);padding-inline:10px var(--space-2);border:var(--border-width) solid var(--input);border-radius:var(--radius-lg);background-color:var(--surface-elevated);color:var(--foreground);font-family:inherit;font-size:var(--text-label-size);line-height:var(--text-label-line-height);font-weight:var(--text-body-weight);letter-spacing:var(--text-label-tracking);white-space:nowrap;text-align:start;cursor:pointer;outline:none;transition:color .15s ease,border-color .15s ease,box-shadow .15s ease}._selectTrigger_1w5u7_177[data-placeholder]{color:var(--muted-foreground)}._selectTrigger_1w5u7_177:focus-visible{border-color:var(--ring);box-shadow:inset 0 0 0 var(--ring-inset) var(--ring)}@media(forced-colors:active){._selectTrigger_1w5u7_177:focus-visible{outline:2px solid Highlight;outline-offset:2px}}._selectTrigger_1w5u7_177[data-disabled]{cursor:not-allowed;opacity:var(--opacity-disabled)}._selectTrigger_1w5u7_177[aria-invalid=true]{border-color:var(--destructive);box-shadow:inset 0 0 0 var(--ring-inset) var(--destructive)}._selectValue_1w5u7_177{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._selectValue_1w5u7_177>svg{vertical-align:middle;margin-inline-end:var(--space-2)}._selectTriggerIcon_1w5u7_177{color:var(--muted-foreground)}._popup_1w5u7_294 ._inputWrap_1w5u7_15{display:flex;width:auto;margin:var(--space-1) var(--space-1) 0}._popup_1w5u7_294 ._input_1w5u7_15{min-width:0}._positioner_1w5u7_306{isolation:isolate;z-index:50}._popup_1w5u7_294{box-sizing:border-box;display:flex;flex-direction:column;position:relative;isolation:isolate;z-index:50;max-height:var(--available-height);width:var(--anchor-width);min-width:9rem;overflow:hidden;border-radius:var(--radius-lg);border:var(--border-width) solid var(--popover-border);background-color:var(--popover);color:var(--popover-foreground);box-shadow:var(--popover-shadow);transform-origin:var(--transform-origin);transition:opacity .1s ease,transform .1s ease}@media(prefers-reduced-motion:reduce){._popup_1w5u7_294{transition:opacity .1s ease}}._popup_1w5u7_294[data-starting-style],._popup_1w5u7_294[data-ending-style]{opacity:0;transform:scale(.95)}._list_1w5u7_322{overflow-x:hidden;overflow-y:auto;min-height:0;padding:var(--space-1)}._empty_1w5u7_381{padding:var(--space-4) var(--space-2);color:var(--muted-foreground);text-align:center;font-size:var(--text-meta-size);line-height:var(--text-meta-line-height)}._group_1w5u7_389{scroll-margin:var(--space-1) 0}._groupLabel_1w5u7_393{padding:var(--space-1) var(--space-2);color:var(--muted-foreground);font-size:var(--text-meta-size);line-height:var(--text-meta-line-height)}._item_1w5u7_400{box-sizing:border-box;position:relative;display:flex;width:100%;align-items:center;gap:var(--space-2);padding:var(--space-2) var(--space-8) var(--space-2) var(--space-2);border-radius:var(--radius-sm);cursor:default;-webkit-user-select:none;user-select:none;font-size:var(--text-meta-size);line-height:var(--text-meta-line-height);outline:none}._item_1w5u7_400:focus,._item_1w5u7_400[data-highlighted]{background-color:var(--accent);color:var(--accent-foreground)}._item_1w5u7_400[data-disabled]{pointer-events:none;opacity:var(--opacity-disabled)}._itemIndicator_1w5u7_406{pointer-events:none;position:absolute;inset-inline-end:var(--space-2);display:flex;width:var(--icon-size-sm);height:var(--icon-size-sm);align-items:center;justify-content:center}._separator_1w5u7_452{pointer-events:none;margin:var(--space-2) calc(-1 * var(--space-1));height:var(--border-width);background-color:var(--border)}._chips_1w5u7_463{box-sizing:border-box;display:flex;flex-wrap:wrap;align-items:center;gap:var(--space-1);width:100%;min-width:12rem;min-height:var(--control-height-lg);padding:var(--space-1) var(--space-2);border:var(--border-width) solid var(--input);border-radius:var(--radius-lg);background-color:var(--surface-elevated);cursor:text;transition:border-color .15s ease,box-shadow .15s ease}._chips_1w5u7_463:focus-within{border-color:var(--ring);box-shadow:inset 0 0 0 var(--ring-inset) var(--ring)}@media(forced-colors:active){._chips_1w5u7_463:focus-within{outline:2px solid Highlight;outline-offset:2px}}._chips_1w5u7_463[aria-invalid=true]{border-color:var(--destructive);box-shadow:inset 0 0 0 var(--ring-inset) var(--destructive)}._chip_1w5u7_463{box-sizing:border-box;display:inline-flex;align-items:center;gap:var(--space-1);padding:var(--space-1) var(--space-2);border-radius:var(--radius-full);background-color:var(--secondary);color:var(--secondary-foreground);font-size:var(--text-meta-size);line-height:var(--text-meta-line-height);white-space:nowrap}._chip_1w5u7_463[data-disabled]{opacity:var(--opacity-disabled)}._chipRemove_1w5u7_463{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--icon-size-md);height:var(--icon-size-md);padding:0;border:none;border-radius:var(--radius-full);background-color:transparent;color:inherit;cursor:pointer}._chipRemove_1w5u7_463:hover{background-color:color-mix(in oklab,var(--secondary-foreground) 15%,transparent)}._chipRemove_1w5u7_463:focus-visible{outline:2px solid var(--ring);outline-offset:1px}._chipRemove_1w5u7_463:disabled{cursor:not-allowed;opacity:var(--opacity-disabled)}._chipRemoveIcon_1w5u7_565{width:var(--icon-size-xs);height:var(--icon-size-xs);flex-shrink:0;pointer-events:none}._chipsInput_1w5u7_463{flex:1 1 auto;min-width:4rem;border:none;outline:none;background-color:transparent;color:var(--foreground);font-family:inherit;font-size:var(--text-label-size);line-height:var(--text-label-line-height);font-weight:var(--text-body-weight);letter-spacing:var(--text-label-tracking)}._chipsInput_1w5u7_463::placeholder{color:var(--muted-foreground)}._chipsInput_1w5u7_463:disabled{cursor:not-allowed}._selectTrigger_1w5u7_177:has(._chips_1w5u7_463){height:auto;min-height:var(--control-height-sm);padding-block:var(--space-1)}._selectTrigger_1w5u7_177 ._chips_1w5u7_463{flex:1;width:auto;min-width:0;min-height:0;padding:0;border:none;border-radius:0;background-color:transparent;box-shadow:none;cursor:inherit}._svgIcon_1w5u7_620{width:var(--icon-size-sm);height:var(--icon-size-sm);flex-shrink:0;pointer-events:none}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._pagination_7mc4q_16{display:flex;width:100%;justify-content:center}._content_7mc4q_22{display:flex;align-items:center;gap:var(--space-1);margin:0;padding:0;list-style:none}._link_7mc4q_37{box-sizing:border-box;display:inline-flex;height:var(--control-height-xs);align-items:center;justify-content:center;gap:var(--space-1);border:0;border-radius:var(--radius-sm);padding-block:0;padding-inline:var(--space-2);background-color:transparent;color:var(--muted-foreground);font-family:inherit;font-size:var(--text-label-size);line-height:var(--text-label-line-height);font-weight:var(--text-label-weight);letter-spacing:var(--text-label-tracking);text-decoration:none;white-space:nowrap;cursor:pointer;transition:color .15s ease,background-color .15s ease}._link_7mc4q_37:hover{color:var(--foreground)}._link_7mc4q_37:focus-visible{outline:var(--border-width-focus) solid var(--ring);outline-offset:2px}@media(forced-colors:active){._link_7mc4q_37:focus-visible{outline-color:Highlight}}._link_7mc4q_37:disabled,._link_7mc4q_37[data-disabled]{pointer-events:none;opacity:var(--opacity-disabled)}._link_7mc4q_37[data-active]{background-color:var(--background);color:var(--primary)}._link_7mc4q_37._square_7mc4q_120{width:var(--control-height-xs);padding-inline:0}._previousNextText_7mc4q_125{display:none}@media(min-width:640px){._previousNextText_7mc4q_125{display:block}}._icon_7mc4q_138{width:var(--icon-size-sm);height:var(--icon-size-sm)}._chevron_7mc4q_147:dir(rtl){transform:scaleX(-1)}._ellipsis_7mc4q_153{display:flex;align-items:center;justify-content:center;width:var(--control-height-xs);height:var(--control-height-xs);color:var(--muted-foreground)}._srOnly_7mc4q_164{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._spinner_1avxn_6{width:var(--icon-size-sm);height:var(--icon-size-sm);animation:_spin_1avxn_6 1s linear infinite}._spinner_1avxn_6[data-compact]{width:14px;height:14px}._spinner_1avxn_6[data-size=lg]{width:2rem;height:2rem}._block_1avxn_39{display:inline-flex;flex-direction:column;align-items:center;gap:var(--space-2);text-align:center}._indicator_1avxn_55{display:inline-flex;align-items:center;justify-content:center;width:2.25rem;height:2.25rem}._indicator_1avxn_55 ._spinner_1avxn_6{width:18px;height:18px}._block_1avxn_39[data-compact] ._indicator_1avxn_55{width:1.75rem;height:1.75rem}._block_1avxn_39[data-compact] ._indicator_1avxn_55 ._spinner_1avxn_6{width:14px;height:14px}._block_1avxn_39[data-size=lg] ._indicator_1avxn_55{width:4rem;height:4rem}._block_1avxn_39[data-size=lg] ._indicator_1avxn_55 ._spinner_1avxn_6{width:2rem;height:2rem}._label_1avxn_96{font-family:var(--font-mono);font-size:var(--text-mono-size);line-height:var(--text-mono-line-height);font-weight:var(--text-mono-weight);letter-spacing:.08em;text-transform:uppercase;color:var(--foreground)}._description_1avxn_108{font-size:var(--text-meta-size);line-height:var(--text-meta-line-height);font-weight:var(--text-meta-weight);letter-spacing:var(--text-meta-tracking);color:var(--muted-foreground)}@keyframes _spin_1avxn_6{to{rotate:360deg}}@media(prefers-reduced-motion:reduce){._spinner_1avxn_6{animation-duration:2.4s}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._tableContainer_pfb4y_8{position:relative;width:100%;overflow:auto}._tableContainer_pfb4y_8:focus-visible{outline:var(--border-width-focus) solid var(--ring);outline-offset:2px}@media(forced-colors:active){._tableContainer_pfb4y_8:focus-visible{outline:2px solid Highlight;outline-offset:2px}}._table_pfb4y_8{width:100%;border-collapse:collapse;caption-side:bottom;font-size:var(--text-meta-size);line-height:var(--text-meta-line-height);font-weight:var(--text-meta-weight);letter-spacing:var(--text-meta-tracking)}._stickyHeader_pfb4y_79{border-collapse:separate;border-spacing:0}:where(._stickyHeader_pfb4y_79) ._tableHeader_pfb4y_91 ._tableHead_pfb4y_70{position:sticky;top:0;z-index:2;background-color:var(--table-header-fill, var(--card))}._tableRow_pfb4y_59{--table-row-fill: transparent;background-color:var(--table-row-fill);transition:color .15s ease,background-color .15s ease}._tableBody_pfb4y_147:last-child ._tableRow_pfb4y_59:last-child>*{border-bottom:0}._tableBody_pfb4y_147 ._tableRow_pfb4y_59:hover,._tableBody_pfb4y_147 ._tableRow_pfb4y_59:has([aria-expanded=true]){--table-row-fill: var(--card-hover)}._tableBody_pfb4y_147 ._tableRow_pfb4y_59[data-state=selected]{--table-row-fill: var(--selection-subtle)}._tableBody_pfb4y_147 ._tableRow_pfb4y_59[data-state=stale]{--table-row-fill: var(--warning-soft)}._tableBody_pfb4y_147 ._tableRow_pfb4y_59[data-state=restricted]{--table-row-fill: var(--danger-soft)}._tableHead_pfb4y_70{box-sizing:border-box;position:relative;height:var(--control-height-md);padding:0 var(--space-4);border-bottom:var(--border-width) solid var(--border);text-align:start;vertical-align:middle;font-family:var(--font-mono);font-size:var(--text-mono-size);line-height:var(--text-mono-line-height);font-weight:var(--text-mono-weight);letter-spacing:var(--text-mono-tracking);text-transform:uppercase;white-space:nowrap;color:var(--subtle-foreground)}._tableHead_pfb4y_70:has([role=checkbox]){padding-inline-end:0}._columnResizer_pfb4y_279{position:absolute;top:0;bottom:0;z-index:1;padding:0;border:0;background:none;cursor:col-resize;touch-action:none;outline:none}._columnResizer_pfb4y_279:after{content:"";position:absolute;top:0;bottom:0;left:50%;width:var(--border-width);translate:-50% 0;background-color:var(--border);transition:width var(--duration-micro) var(--ease-standard),background-color var(--duration-micro) var(--ease-standard)}._columnResizer_pfb4y_279:hover:after,._columnResizer_pfb4y_279:focus-visible:after,._columnResizer_pfb4y_279:active:after{width:var(--border-width-focus);background-color:var(--primary)}@media(forced-colors:active){._columnResizer_pfb4y_279:focus-visible:after{background-color:Highlight}}._tableCell_pfb4y_127{box-sizing:border-box;padding:var(--space-3) var(--space-4);height:var(--control-height-lg);border-bottom:var(--border-width) solid var(--border);vertical-align:middle;white-space:nowrap}._tableCell_pfb4y_127:has([role=checkbox]){padding-inline-end:0}._variantCollection_pfb4y_94{table-layout:fixed;min-width:960px}._variantCollection_pfb4y_94 ._tableHead_pfb4y_70{position:sticky;top:0;z-index:2;height:var(--control-height-lg);padding:0 var(--space-3);background-color:var(--card);color:var(--muted-foreground);line-height:16px}._variantCollection_pfb4y_94 ._tableBody_pfb4y_147 ._tableRow_pfb4y_59{height:4rem}._variantCollection_pfb4y_94 ._tableCell_pfb4y_127{height:auto;padding:var(--space-3) var(--space-2);font-size:var(--text-meta-size);line-height:var(--text-meta-line-height);white-space:normal}._variantCollection_pfb4y_94 ._tableBody_pfb4y_147 ._tableRow_pfb4y_59:focus-visible{outline:none;box-shadow:inset 0 0 0 var(--border-width-focus) var(--primary)}._variantCollection_pfb4y_94 ._tableBody_pfb4y_147 ._tableRow_pfb4y_59[tabindex]{cursor:pointer;transition:background-color var(--duration-micro) var(--ease-standard)}._variantCollection_pfb4y_94 ._tableBody_pfb4y_147 ._tableRow_pfb4y_59[data-pending]{--table-row-fill: var(--muted);cursor:progress}._densityCompact_pfb4y_461 ._tableHead_pfb4y_70{height:var(--control-height-sm)}._densityCompact_pfb4y_461 ._tableCell_pfb4y_127{padding-block:var(--space-2);height:auto}._tableCaption_pfb4y_470{margin-top:var(--space-4);font-size:var(--text-body-size);line-height:var(--text-body-line-height);color:var(--muted-foreground)}._tableFooter_pfb4y_492{font-weight:var(--text-label-weight)}._tableFooter_pfb4y_492 ._tableRow_pfb4y_59{--table-row-fill: var(--muted)}._tableFooter_pfb4y_492 ._tableRow_pfb4y_59:last-child>*{border-bottom:0}
|