@flesler/cursor-canvas-web 1.0.1 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -8
- package/dist/cursor-canvas.cjs +1 -1
- package/dist/cursor-canvas.js +530 -701
- package/dist/host-tokens-Cjzmp0z_.cjs +1 -0
- package/dist/host-tokens-Dh2BFFjv.js +412 -0
- package/dist/runtime/index.d.ts +5 -7
- package/dist/runtime.cjs +1 -1
- package/dist/runtime.js +101 -14
- package/package.json +22 -12
- package/src/vendor/canvas/SKILL.md +113 -0
- package/src/vendor/canvas-sdk/callout-tone-icons.d.ts +10 -0
- package/src/vendor/canvas-sdk/canvas-tokens.d.ts +259 -0
- package/src/vendor/canvas-sdk/chart-primitives.d.ts +272 -0
- package/src/vendor/canvas-sdk/collapsible-section.d.ts +66 -0
- package/src/vendor/canvas-sdk/dag-layout.d.ts +101 -0
- package/src/vendor/canvas-sdk/diff-view.d.ts +129 -0
- package/src/vendor/canvas-sdk/form-primitives.d.ts +194 -0
- package/src/vendor/canvas-sdk/hooks.d.ts +173 -0
- package/src/vendor/canvas-sdk/index.d.ts +65 -0
- package/src/vendor/canvas-sdk/internal/canvas-action-dispatch.d.ts +17 -0
- package/src/vendor/canvas-sdk/manifest.json +5 -0
- package/src/vendor/canvas-sdk/swatch.d.ts +39 -0
- package/src/vendor/canvas-sdk/theme.d.ts +107 -0
- package/src/vendor/canvas-sdk/todo-list.d.ts +48 -0
- package/src/vendor/canvas-sdk/ui-primitives.d.ts +569 -0
- package/src/vendor/canvas-sdk/usage-bar.d.ts +55 -0
- package/dist/shim/charts.d.ts +0 -62
- package/dist/shim/cursor-canvas.d.ts +0 -278
- package/dist/shim/dag.d.ts +0 -55
- package/dist/shim/diff.d.ts +0 -23
- package/dist/shim/theme.d.ts +0 -319
- package/dist/shim/todo.d.ts +0 -22
- package/dist/shim/use-tokens.d.ts +0 -6
package/dist/cursor-canvas.js
CHANGED
|
@@ -1,203 +1,11 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { useComputedColorScheme as
|
|
3
|
-
import { useState as
|
|
4
|
-
import { useEffect as
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
foregroundTertiary: "#E4E4E45E",
|
|
10
|
-
foregroundQuaternary: "#E4E4E442",
|
|
11
|
-
editor: "#181818",
|
|
12
|
-
chrome: "#141414",
|
|
13
|
-
sidebar: "#141414",
|
|
14
|
-
elevated: "#181818",
|
|
15
|
-
fillPrimary: "#E4E4E430",
|
|
16
|
-
fillSecondary: "#E4E4E41E",
|
|
17
|
-
fillTertiary: "#E4E4E411",
|
|
18
|
-
fillQuaternary: "#E4E4E40A",
|
|
19
|
-
strokePrimary: "#E4E4E433",
|
|
20
|
-
strokeSecondary: "#E4E4E41F",
|
|
21
|
-
strokeTertiary: "#E4E4E414",
|
|
22
|
-
strokeFocused: "#599CE7",
|
|
23
|
-
accent: "#599CE7",
|
|
24
|
-
buttonBackground: "#599CE7",
|
|
25
|
-
buttonForeground: "#191c22",
|
|
26
|
-
buttonHoverBackground: "#6AABE9",
|
|
27
|
-
link: "#87c3ff",
|
|
28
|
-
diffInsertedLine: "#3FA26633",
|
|
29
|
-
diffRemovedLine: "#B8004933",
|
|
30
|
-
diffStripAdded: "#3FA2668F",
|
|
31
|
-
diffStripRemoved: "#FC6B838F"
|
|
32
|
-
}, ae = {
|
|
33
|
-
foreground: "#141414F0",
|
|
34
|
-
foregroundSecondary: "#141414BD",
|
|
35
|
-
foregroundTertiary: "#1414148A",
|
|
36
|
-
foregroundQuaternary: "#1414145C",
|
|
37
|
-
editor: "#FCFCFC",
|
|
38
|
-
chrome: "#F8F8F8",
|
|
39
|
-
sidebar: "#F3F3F3",
|
|
40
|
-
elevated: "#FCFCFC",
|
|
41
|
-
fillPrimary: "#14141433",
|
|
42
|
-
fillSecondary: "#14141424",
|
|
43
|
-
fillTertiary: "#14141414",
|
|
44
|
-
fillQuaternary: "#1414140F",
|
|
45
|
-
strokePrimary: "#14141433",
|
|
46
|
-
strokeSecondary: "#1414141F",
|
|
47
|
-
strokeTertiary: "#14141414",
|
|
48
|
-
strokeFocused: "#3685BF",
|
|
49
|
-
accent: "#3685BF",
|
|
50
|
-
buttonBackground: "#3685BF",
|
|
51
|
-
buttonForeground: "#FCFCFC",
|
|
52
|
-
buttonHoverBackground: "#2E76AB",
|
|
53
|
-
link: "#3685BF",
|
|
54
|
-
diffInsertedLine: "#1F8A651F",
|
|
55
|
-
diffRemovedLine: "#CF2D5614",
|
|
56
|
-
diffStripAdded: "#1F8A65CC",
|
|
57
|
-
diffStripRemoved: "#CF2D56CC"
|
|
58
|
-
}, j = {
|
|
59
|
-
gray: "#8888A8E0",
|
|
60
|
-
purple: "#7B64B8F0",
|
|
61
|
-
green: "#1F8A65E8",
|
|
62
|
-
yellow: "#E8C030E0",
|
|
63
|
-
cyan: "#2A9A8AE0",
|
|
64
|
-
pink: "#C85898E0",
|
|
65
|
-
blue: "#2E79B5E0",
|
|
66
|
-
orange: "#F0A040E0",
|
|
67
|
-
red: "#C04848E0"
|
|
68
|
-
}, ie = {
|
|
69
|
-
gray: "#8888A8E0",
|
|
70
|
-
purple: "#7B64B8F0",
|
|
71
|
-
green: "#1F8A65E8",
|
|
72
|
-
yellow: "#E8C030E0",
|
|
73
|
-
cyan: "#2A9A8AE0",
|
|
74
|
-
pink: "#C85898E0",
|
|
75
|
-
blue: "#2E79B5E0",
|
|
76
|
-
orange: "#F0A088E0",
|
|
77
|
-
red: "#CF2D56E0"
|
|
78
|
-
};
|
|
79
|
-
function ce(e, t) {
|
|
80
|
-
return {
|
|
81
|
-
bg: {
|
|
82
|
-
editor: e.editor,
|
|
83
|
-
chrome: e.chrome,
|
|
84
|
-
elevated: e.elevated
|
|
85
|
-
},
|
|
86
|
-
text: {
|
|
87
|
-
primary: e.foreground,
|
|
88
|
-
secondary: e.foregroundSecondary,
|
|
89
|
-
tertiary: e.foregroundTertiary,
|
|
90
|
-
quaternary: e.foregroundQuaternary,
|
|
91
|
-
link: e.link,
|
|
92
|
-
onAccent: e.buttonForeground
|
|
93
|
-
},
|
|
94
|
-
stroke: {
|
|
95
|
-
primary: e.strokePrimary,
|
|
96
|
-
secondary: e.strokeSecondary,
|
|
97
|
-
tertiary: e.strokeTertiary,
|
|
98
|
-
focused: e.strokeFocused
|
|
99
|
-
},
|
|
100
|
-
fill: {
|
|
101
|
-
primary: e.fillPrimary,
|
|
102
|
-
secondary: e.fillSecondary,
|
|
103
|
-
tertiary: e.fillTertiary,
|
|
104
|
-
quaternary: e.fillQuaternary
|
|
105
|
-
},
|
|
106
|
-
accent: {
|
|
107
|
-
primary: e.accent,
|
|
108
|
-
control: e.buttonBackground,
|
|
109
|
-
controlHover: e.buttonHoverBackground
|
|
110
|
-
},
|
|
111
|
-
diff: {
|
|
112
|
-
insertedLine: e.diffInsertedLine,
|
|
113
|
-
removedLine: e.diffRemovedLine,
|
|
114
|
-
stripAdded: e.diffStripAdded,
|
|
115
|
-
stripRemoved: e.diffStripRemoved
|
|
116
|
-
},
|
|
117
|
-
category: t
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
const Ie = ce(
|
|
121
|
-
oe,
|
|
122
|
-
j
|
|
123
|
-
), We = ce(
|
|
124
|
-
ae,
|
|
125
|
-
ie
|
|
126
|
-
), nt = j, te = [
|
|
127
|
-
"blue",
|
|
128
|
-
"purple",
|
|
129
|
-
"green",
|
|
130
|
-
"yellow",
|
|
131
|
-
"cyan",
|
|
132
|
-
"pink",
|
|
133
|
-
"orange",
|
|
134
|
-
"red",
|
|
135
|
-
"gray"
|
|
136
|
-
], Ge = {
|
|
137
|
-
green: "#1F8A65E8",
|
|
138
|
-
darkGreen: "#0D855AE0",
|
|
139
|
-
lightGreen: "#52B896E0",
|
|
140
|
-
mintGreen: "#7DCAB0E0",
|
|
141
|
-
blue: "#2E79B5E0",
|
|
142
|
-
lightBlue: "#70B0D8E0",
|
|
143
|
-
indigo: "#5A6CC0F0",
|
|
144
|
-
lightIndigo: "#9AAADCE0",
|
|
145
|
-
purple: "#7B64B8F0",
|
|
146
|
-
lightPurple: "#AA98D8E0",
|
|
147
|
-
warmPink: "#C85898E0",
|
|
148
|
-
lightPink: "#E8A0C4E0",
|
|
149
|
-
brightOrange: "#F0A040E0",
|
|
150
|
-
deepOrange: "#C06028E0",
|
|
151
|
-
goldenYellow: "#E8C030E0",
|
|
152
|
-
darkAmber: "#C04848E0",
|
|
153
|
-
warmPeach: "#F0A088E0",
|
|
154
|
-
vibrantTeal: "#2A9A8AE0",
|
|
155
|
-
muted: "#8888A8E0",
|
|
156
|
-
neutralLine: "#888899D0"
|
|
157
|
-
}, je = {
|
|
158
|
-
h1: { fontSize: "24px", lineHeight: "30px", fontWeight: 590 },
|
|
159
|
-
h2: { fontSize: "18px", lineHeight: "24px", fontWeight: 590 },
|
|
160
|
-
h3: { fontSize: "16px", lineHeight: "22px", fontWeight: 590 },
|
|
161
|
-
body: { fontSize: "14px", lineHeight: "20px", fontWeight: 400 },
|
|
162
|
-
small: { fontSize: "12px", lineHeight: "16px", fontWeight: 400 }
|
|
163
|
-
}, Ne = {
|
|
164
|
-
"0.5": 2,
|
|
165
|
-
1: 4,
|
|
166
|
-
"1.5": 6,
|
|
167
|
-
2: 8,
|
|
168
|
-
"2.5": 10,
|
|
169
|
-
3: 12,
|
|
170
|
-
"3.5": 14,
|
|
171
|
-
4: 16,
|
|
172
|
-
"4.5": 18,
|
|
173
|
-
5: 20,
|
|
174
|
-
6: 24,
|
|
175
|
-
7: 28,
|
|
176
|
-
8: 32,
|
|
177
|
-
9: 36,
|
|
178
|
-
10: 40
|
|
179
|
-
}, Oe = {
|
|
180
|
-
none: 0,
|
|
181
|
-
xs: 2,
|
|
182
|
-
sm: 4,
|
|
183
|
-
md: 6,
|
|
184
|
-
lg: 8,
|
|
185
|
-
xl: 12,
|
|
186
|
-
full: 9999
|
|
187
|
-
}, I = [
|
|
188
|
-
"#1F8A65E8",
|
|
189
|
-
"#70B0D8E0",
|
|
190
|
-
"#5A6CC0F0",
|
|
191
|
-
"#F0A040E0",
|
|
192
|
-
"#C06028E0",
|
|
193
|
-
"#E8C030E0",
|
|
194
|
-
"#C85898E0",
|
|
195
|
-
"#F0A088E0",
|
|
196
|
-
"#7B64B8F0",
|
|
197
|
-
"#7DCAB0E0",
|
|
198
|
-
"#8888A8E0",
|
|
199
|
-
"#2A9A8AE0"
|
|
200
|
-
], b = {
|
|
1
|
+
import { jsx as s, jsxs as p } from "react/jsx-runtime";
|
|
2
|
+
import { useComputedColorScheme as ht, Button as pt, Alert as yt, Card as gt, Checkbox as mt, Divider as xt, Title as E, ActionIcon as vt, Badge as bt, Group as kt, Select as St, Stack as wt, Text as H, Table as S, Textarea as Ct, TextInput as Tt, Switch as Lt } from "@mantine/core";
|
|
3
|
+
import { useState as I, createContext as Mt, useCallback as j, useContext as rt } from "react";
|
|
4
|
+
import { useEffect as Ae, useMemo as Ie, useRef as Pe, useState as Re } from "react";
|
|
5
|
+
import { r as Bt, u as tt } from "./host-tokens-Dh2BFFjv.js";
|
|
6
|
+
import { c as He, a as Ee, b as je, d as Ge, e as Ne, f as Oe, g as _e, h as Ke, i as Xe } from "./host-tokens-Dh2BFFjv.js";
|
|
7
|
+
import { BarChart as Ft, AreaChart as $t, LineChart as zt, DonutChart as Dt, PieChart as At } from "@mantine/charts";
|
|
8
|
+
const k = {
|
|
201
9
|
success: "#1F8A65",
|
|
202
10
|
danger: "#CF2D56",
|
|
203
11
|
warning: "#E8A33D",
|
|
@@ -206,7 +14,7 @@ const Ie = ce(
|
|
|
206
14
|
added: "#1F8A65",
|
|
207
15
|
deleted: "#CF2D56",
|
|
208
16
|
renamed: "#5A6CC0"
|
|
209
|
-
},
|
|
17
|
+
}, nt = {
|
|
210
18
|
success: "green",
|
|
211
19
|
danger: "red",
|
|
212
20
|
warning: "orange",
|
|
@@ -216,153 +24,138 @@ const Ie = ce(
|
|
|
216
24
|
deleted: "red",
|
|
217
25
|
renamed: "indigo"
|
|
218
26
|
};
|
|
219
|
-
function
|
|
220
|
-
const t =
|
|
221
|
-
return
|
|
222
|
-
...t,
|
|
223
|
-
kind: e,
|
|
224
|
-
tokens: t,
|
|
225
|
-
palette: e === "dark" ? oe : ae,
|
|
226
|
-
category: e === "dark" ? j : ie,
|
|
227
|
-
// Back-compat: real IDE canvases read these on useHostTheme(); public hooks.d.ts
|
|
228
|
-
// is sometimes narrower — see COMPAT.md (not a second theme API version).
|
|
229
|
-
chart: { palette: Ge, sequence: I },
|
|
230
|
-
radius: Oe,
|
|
231
|
-
typography: je,
|
|
232
|
-
spacing: Ne
|
|
233
|
-
};
|
|
27
|
+
function y() {
|
|
28
|
+
const t = ht("light") === "dark" ? "dark" : "light";
|
|
29
|
+
return Bt(t);
|
|
234
30
|
}
|
|
235
|
-
function
|
|
236
|
-
const
|
|
237
|
-
return
|
|
31
|
+
function G() {
|
|
32
|
+
const t = y().chart.sequence;
|
|
33
|
+
return (r, n) => r ? k[r] : t[n % t.length];
|
|
238
34
|
}
|
|
239
|
-
function
|
|
240
|
-
return e
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
for (const n of t)
|
|
246
|
-
c[n.name] = n.data[a] ?? 0;
|
|
247
|
-
return c;
|
|
35
|
+
function ot(e, t) {
|
|
36
|
+
return e.map((r, n) => {
|
|
37
|
+
const i = { category: r };
|
|
38
|
+
for (const o of t)
|
|
39
|
+
i[o.name] = o.data[n] ?? 0;
|
|
40
|
+
return i;
|
|
248
41
|
});
|
|
249
42
|
}
|
|
250
|
-
function
|
|
251
|
-
return e.map((
|
|
252
|
-
name:
|
|
253
|
-
color:
|
|
43
|
+
function at(e, t) {
|
|
44
|
+
return e.map((r, n) => ({
|
|
45
|
+
name: r.name,
|
|
46
|
+
color: t(r.tone, n)
|
|
254
47
|
}));
|
|
255
48
|
}
|
|
256
|
-
function
|
|
49
|
+
function it(e, t) {
|
|
257
50
|
if (!(!e && !t))
|
|
258
51
|
return (r) => `${t ?? ""}${r}${e ?? ""}`;
|
|
259
52
|
}
|
|
260
|
-
function
|
|
53
|
+
function It(e, t) {
|
|
261
54
|
if (e != null && e.length)
|
|
262
55
|
return e.map((r) => ({
|
|
263
56
|
...t ? { x: r.value } : { y: r.value },
|
|
264
57
|
label: r.label,
|
|
265
|
-
color: r.tone ?
|
|
58
|
+
color: r.tone ? k[r.tone] : k.neutral
|
|
266
59
|
}));
|
|
267
60
|
}
|
|
268
|
-
function
|
|
269
|
-
const t =
|
|
61
|
+
function st(e) {
|
|
62
|
+
const t = It(e.referenceLines, !!e.horizontal);
|
|
270
63
|
if (e.stacked || e.normalized)
|
|
271
64
|
return { referenceLines: t };
|
|
272
|
-
const r = e.beginAtZero !== !1,
|
|
65
|
+
const r = e.beginAtZero !== !1, n = [
|
|
273
66
|
e.yMin ?? (r ? 0 : "auto"),
|
|
274
67
|
e.yMax ?? "auto"
|
|
275
68
|
];
|
|
276
|
-
return e.horizontal ? { xAxisProps: { domain:
|
|
69
|
+
return e.horizontal ? { xAxisProps: { domain: n }, referenceLines: t } : { yAxisProps: { domain: n }, referenceLines: t };
|
|
277
70
|
}
|
|
278
|
-
function
|
|
71
|
+
function Pt(e, t, r) {
|
|
279
72
|
return e !== void 0 ? e : t.length === 1 && r.length <= 8;
|
|
280
73
|
}
|
|
281
|
-
function
|
|
74
|
+
function qt({
|
|
282
75
|
categories: e,
|
|
283
76
|
series: t,
|
|
284
77
|
height: r = 240,
|
|
285
|
-
fill:
|
|
286
|
-
valueSuffix:
|
|
287
|
-
valuePrefix:
|
|
78
|
+
fill: n,
|
|
79
|
+
valueSuffix: i,
|
|
80
|
+
valuePrefix: o,
|
|
288
81
|
showValues: l,
|
|
289
82
|
showHoverGuide: u = !0,
|
|
290
83
|
beginAtZero: d,
|
|
291
|
-
yMin:
|
|
84
|
+
yMin: c,
|
|
292
85
|
yMax: f,
|
|
293
|
-
referenceLines:
|
|
86
|
+
referenceLines: m,
|
|
294
87
|
style: x
|
|
295
88
|
}) {
|
|
296
|
-
const
|
|
89
|
+
const b = G(), B = ot(e, t), w = at(t, b), T = st({
|
|
297
90
|
beginAtZero: d,
|
|
298
|
-
yMin:
|
|
91
|
+
yMin: c,
|
|
299
92
|
yMax: f,
|
|
300
|
-
referenceLines:
|
|
93
|
+
referenceLines: m,
|
|
301
94
|
horizontal: !1
|
|
302
95
|
}), C = {
|
|
303
96
|
h: r,
|
|
304
|
-
data:
|
|
97
|
+
data: B,
|
|
305
98
|
dataKey: "category",
|
|
306
99
|
series: w,
|
|
307
100
|
curveType: "monotone",
|
|
308
101
|
withLegend: t.length > 1,
|
|
309
|
-
valueFormatter:
|
|
102
|
+
valueFormatter: it(i, o),
|
|
310
103
|
withPointLabels: l ?? e.length <= 20,
|
|
311
104
|
tooltipProps: u ? void 0 : { cursor: !1 },
|
|
312
|
-
...
|
|
105
|
+
...T,
|
|
313
106
|
style: x
|
|
314
107
|
};
|
|
315
|
-
return
|
|
108
|
+
return n ? /* @__PURE__ */ s($t, { ...C }) : /* @__PURE__ */ s(zt, { ...C });
|
|
316
109
|
}
|
|
317
|
-
function
|
|
110
|
+
function Vt({
|
|
318
111
|
categories: e,
|
|
319
112
|
series: t,
|
|
320
113
|
height: r = 240,
|
|
321
|
-
stacked:
|
|
322
|
-
horizontal:
|
|
323
|
-
normalized:
|
|
114
|
+
stacked: n,
|
|
115
|
+
horizontal: i,
|
|
116
|
+
normalized: o,
|
|
324
117
|
valueSuffix: l,
|
|
325
118
|
valuePrefix: u,
|
|
326
119
|
showValues: d,
|
|
327
|
-
beginAtZero:
|
|
120
|
+
beginAtZero: c,
|
|
328
121
|
yMin: f,
|
|
329
|
-
yMax:
|
|
122
|
+
yMax: m,
|
|
330
123
|
referenceLines: x,
|
|
331
|
-
style:
|
|
124
|
+
style: b
|
|
332
125
|
}) {
|
|
333
|
-
const w =
|
|
334
|
-
beginAtZero:
|
|
126
|
+
const B = G(), w = ot(e, t), T = o ? "percent" : n ? "stacked" : "default", C = st({
|
|
127
|
+
beginAtZero: c,
|
|
335
128
|
yMin: f,
|
|
336
|
-
yMax:
|
|
129
|
+
yMax: m,
|
|
337
130
|
referenceLines: x,
|
|
338
|
-
horizontal:
|
|
339
|
-
stacked:
|
|
340
|
-
normalized:
|
|
341
|
-
}),
|
|
342
|
-
return /* @__PURE__ */
|
|
343
|
-
|
|
131
|
+
horizontal: i,
|
|
132
|
+
stacked: n,
|
|
133
|
+
normalized: o
|
|
134
|
+
}), F = !n && !o && Pt(d, t, e);
|
|
135
|
+
return /* @__PURE__ */ s(
|
|
136
|
+
Ft,
|
|
344
137
|
{
|
|
345
138
|
h: r,
|
|
346
139
|
data: w,
|
|
347
140
|
dataKey: "category",
|
|
348
|
-
series:
|
|
349
|
-
type:
|
|
350
|
-
orientation:
|
|
141
|
+
series: at(t, B),
|
|
142
|
+
type: T,
|
|
143
|
+
orientation: i ? "vertical" : "horizontal",
|
|
351
144
|
withLegend: t.length > 1,
|
|
352
|
-
valueFormatter:
|
|
353
|
-
withBarValueLabel:
|
|
145
|
+
valueFormatter: it(l, u),
|
|
146
|
+
withBarValueLabel: F,
|
|
354
147
|
...C,
|
|
355
|
-
style:
|
|
148
|
+
style: b
|
|
356
149
|
}
|
|
357
150
|
);
|
|
358
151
|
}
|
|
359
|
-
function
|
|
360
|
-
const
|
|
361
|
-
name:
|
|
362
|
-
value:
|
|
363
|
-
color:
|
|
152
|
+
function Yt({ data: e, size: t = 200, donut: r, style: n }) {
|
|
153
|
+
const i = G(), o = e.map((u, d) => ({
|
|
154
|
+
name: u.label,
|
|
155
|
+
value: u.value,
|
|
156
|
+
color: i(u.tone, d)
|
|
364
157
|
}));
|
|
365
|
-
return /* @__PURE__ */
|
|
158
|
+
return /* @__PURE__ */ s(
|
|
366
159
|
"div",
|
|
367
160
|
{
|
|
368
161
|
style: {
|
|
@@ -373,117 +166,109 @@ function it({ data: e, size: t = 200, donut: r, style: a }) {
|
|
|
373
166
|
alignItems: "center",
|
|
374
167
|
justifyContent: "center"
|
|
375
168
|
},
|
|
376
|
-
children: r ? /* @__PURE__ */
|
|
377
|
-
|
|
378
|
-
{
|
|
379
|
-
data: c,
|
|
380
|
-
size: t,
|
|
381
|
-
withTooltip: !0,
|
|
382
|
-
style: a
|
|
383
|
-
}
|
|
384
|
-
) : /* @__PURE__ */ i(
|
|
385
|
-
He,
|
|
169
|
+
children: r ? /* @__PURE__ */ s(Dt, { data: o, size: t, withTooltip: !0, style: n }) : /* @__PURE__ */ s(
|
|
170
|
+
At,
|
|
386
171
|
{
|
|
387
|
-
data:
|
|
172
|
+
data: o,
|
|
388
173
|
size: t,
|
|
389
174
|
withTooltip: !0,
|
|
390
175
|
withLabelsLine: !1,
|
|
391
|
-
style:
|
|
176
|
+
style: n
|
|
392
177
|
}
|
|
393
178
|
)
|
|
394
179
|
}
|
|
395
180
|
);
|
|
396
181
|
}
|
|
397
|
-
function
|
|
182
|
+
function Jt(e) {
|
|
398
183
|
const {
|
|
399
184
|
nodes: t,
|
|
400
185
|
edges: r,
|
|
401
|
-
direction:
|
|
402
|
-
nodeWidth:
|
|
403
|
-
nodeHeight:
|
|
186
|
+
direction: n = "vertical",
|
|
187
|
+
nodeWidth: i = 160,
|
|
188
|
+
nodeHeight: o = 40,
|
|
404
189
|
rankGap: l = 64,
|
|
405
190
|
nodeGap: u = 48,
|
|
406
191
|
padding: d = 24
|
|
407
|
-
} = e,
|
|
408
|
-
for (const
|
|
409
|
-
for (const
|
|
410
|
-
f.has(
|
|
411
|
-
const x = 0,
|
|
412
|
-
|
|
413
|
-
for (const h of
|
|
414
|
-
const
|
|
415
|
-
|
|
192
|
+
} = e, c = t.map((a) => a.id), f = new Set(c), m = /* @__PURE__ */ new Map();
|
|
193
|
+
for (const a of c) m.set(a, []);
|
|
194
|
+
for (const a of r)
|
|
195
|
+
f.has(a.from) && f.has(a.to) && m.get(a.from).push(a.to);
|
|
196
|
+
const x = 0, b = 1, B = 2, w = new Map(c.map((a) => [a, x])), T = /* @__PURE__ */ new Set(), C = (a, h) => `${a}\0${h}`, F = (a) => {
|
|
197
|
+
w.set(a, b);
|
|
198
|
+
for (const h of m.get(a) ?? []) {
|
|
199
|
+
const g = w.get(h);
|
|
200
|
+
g === b ? T.add(C(a, h)) : g === x && F(h);
|
|
416
201
|
}
|
|
417
|
-
|
|
202
|
+
w.set(a, B);
|
|
418
203
|
};
|
|
419
|
-
for (const
|
|
420
|
-
const
|
|
421
|
-
(
|
|
422
|
-
),
|
|
423
|
-
for (const
|
|
424
|
-
|
|
425
|
-
const
|
|
426
|
-
for (;
|
|
427
|
-
const
|
|
428
|
-
for (const
|
|
429
|
-
|
|
204
|
+
for (const a of c) w.get(a) === x && F(a);
|
|
205
|
+
const lt = r.filter(
|
|
206
|
+
(a) => f.has(a.from) && f.has(a.to) && !T.has(C(a.from, a.to))
|
|
207
|
+
), L = new Map(c.map((a) => [a, 0])), _ = new Map(c.map((a) => [a, []]));
|
|
208
|
+
for (const a of lt)
|
|
209
|
+
_.get(a.from).push(a.to), L.set(a.to, (L.get(a.to) ?? 0) + 1);
|
|
210
|
+
const $ = new Map(c.map((a) => [a, 0])), P = c.filter((a) => (L.get(a) ?? 0) === 0);
|
|
211
|
+
for (; P.length > 0; ) {
|
|
212
|
+
const a = P.shift(), h = $.get(a);
|
|
213
|
+
for (const g of _.get(a))
|
|
214
|
+
$.set(g, Math.max($.get(g), h + 1)), L.set(g, L.get(g) - 1), L.get(g) === 0 && P.push(g);
|
|
430
215
|
}
|
|
431
|
-
const
|
|
432
|
-
for (const
|
|
433
|
-
const h =
|
|
434
|
-
|
|
216
|
+
const M = /* @__PURE__ */ new Map();
|
|
217
|
+
for (const a of c) {
|
|
218
|
+
const h = $.get(a);
|
|
219
|
+
M.has(h) || M.set(h, []), M.get(h).push(a);
|
|
435
220
|
}
|
|
436
|
-
const
|
|
221
|
+
const z = [...M.keys()].sort((a, h) => a - h), v = n === "vertical", K = (a) => a * (v ? i : o) + Math.max(0, a - 1) * u, X = Math.max(
|
|
437
222
|
0,
|
|
438
|
-
...
|
|
439
|
-
), D = /* @__PURE__ */ new Map(),
|
|
440
|
-
|
|
441
|
-
const
|
|
442
|
-
|
|
443
|
-
const
|
|
444
|
-
D.set(U, { id: U, x:
|
|
445
|
-
}),
|
|
446
|
-
rank:
|
|
447
|
-
x:
|
|
448
|
-
y:
|
|
449
|
-
width:
|
|
450
|
-
height:
|
|
451
|
-
nodeIds:
|
|
223
|
+
...z.map((a) => K(M.get(a).length))
|
|
224
|
+
), D = /* @__PURE__ */ new Map(), q = [];
|
|
225
|
+
z.forEach((a, h) => {
|
|
226
|
+
const g = M.get(a), R = K(g.length), W = d + (X - R) / 2, A = d + h * ((v ? o : i) + l);
|
|
227
|
+
g.forEach((U, Z) => {
|
|
228
|
+
const Q = W + Z * ((v ? i : o) + u), ut = v ? Q : A, ft = v ? A : Q;
|
|
229
|
+
D.set(U, { id: U, x: ut, y: ft, rank: a, order: Z });
|
|
230
|
+
}), q.push({
|
|
231
|
+
rank: a,
|
|
232
|
+
x: v ? W : A,
|
|
233
|
+
y: v ? A : W,
|
|
234
|
+
width: v ? R : i,
|
|
235
|
+
height: v ? o : R,
|
|
236
|
+
nodeIds: g
|
|
452
237
|
});
|
|
453
238
|
});
|
|
454
|
-
const
|
|
455
|
-
x:
|
|
456
|
-
y: h === "source" ?
|
|
239
|
+
const V = (a, h) => a ? v ? {
|
|
240
|
+
x: a.x + i / 2,
|
|
241
|
+
y: h === "source" ? a.y + o : a.y
|
|
457
242
|
} : {
|
|
458
|
-
x: h === "source" ?
|
|
459
|
-
y:
|
|
460
|
-
} : { x: 0, y: 0 },
|
|
461
|
-
const h =
|
|
243
|
+
x: h === "source" ? a.x + i : a.x,
|
|
244
|
+
y: a.y + o / 2
|
|
245
|
+
} : { x: 0, y: 0 }, dt = r.filter((a) => f.has(a.from) && f.has(a.to)).map((a) => {
|
|
246
|
+
const h = V(D.get(a.from), "source"), g = V(D.get(a.to), "target");
|
|
462
247
|
return {
|
|
463
|
-
from:
|
|
464
|
-
to:
|
|
248
|
+
from: a.from,
|
|
249
|
+
to: a.to,
|
|
465
250
|
sourceX: h.x,
|
|
466
251
|
sourceY: h.y,
|
|
467
|
-
targetX:
|
|
468
|
-
targetY:
|
|
469
|
-
isBackEdge:
|
|
252
|
+
targetX: g.x,
|
|
253
|
+
targetY: g.y,
|
|
254
|
+
isBackEdge: T.has(C(a.from, a.to))
|
|
470
255
|
};
|
|
471
|
-
}),
|
|
256
|
+
}), Y = d * 2 + z.length * (v ? o : i) + Math.max(0, z.length - 1) * l, J = d * 2 + X;
|
|
472
257
|
return {
|
|
473
258
|
nodes: [...D.values()],
|
|
474
|
-
edges:
|
|
475
|
-
ranks:
|
|
476
|
-
direction:
|
|
477
|
-
width:
|
|
478
|
-
height:
|
|
259
|
+
edges: dt,
|
|
260
|
+
ranks: q,
|
|
261
|
+
direction: n,
|
|
262
|
+
width: v ? J : Y,
|
|
263
|
+
height: v ? Y : J
|
|
479
264
|
};
|
|
480
265
|
}
|
|
481
|
-
function
|
|
266
|
+
function Ut({
|
|
482
267
|
additions: e = 0,
|
|
483
268
|
deletions: t = 0,
|
|
484
269
|
style: r
|
|
485
270
|
}) {
|
|
486
|
-
return e === 0 && t === 0 ? null : /* @__PURE__ */
|
|
271
|
+
return e === 0 && t === 0 ? null : /* @__PURE__ */ p(
|
|
487
272
|
"span",
|
|
488
273
|
{
|
|
489
274
|
style: {
|
|
@@ -495,11 +280,11 @@ function st({
|
|
|
495
280
|
...r
|
|
496
281
|
},
|
|
497
282
|
children: [
|
|
498
|
-
e > 0 && /* @__PURE__ */
|
|
283
|
+
e > 0 && /* @__PURE__ */ p("span", { style: { color: k.added }, children: [
|
|
499
284
|
"+",
|
|
500
285
|
e
|
|
501
286
|
] }),
|
|
502
|
-
t > 0 && /* @__PURE__ */
|
|
287
|
+
t > 0 && /* @__PURE__ */ p("span", { style: { color: k.deleted }, children: [
|
|
503
288
|
"-",
|
|
504
289
|
t
|
|
505
290
|
] })
|
|
@@ -507,41 +292,41 @@ function st({
|
|
|
507
292
|
}
|
|
508
293
|
);
|
|
509
294
|
}
|
|
510
|
-
const
|
|
295
|
+
const Rt = {
|
|
511
296
|
added: "+",
|
|
512
297
|
removed: "-",
|
|
513
298
|
unchanged: " "
|
|
514
299
|
};
|
|
515
|
-
function
|
|
300
|
+
function Zt({
|
|
516
301
|
lines: e,
|
|
517
302
|
showLineNumbers: t = !0,
|
|
518
303
|
coloredLineNumbers: r = !0,
|
|
519
|
-
showAccentStrip:
|
|
520
|
-
style:
|
|
304
|
+
showAccentStrip: n = !0,
|
|
305
|
+
style: i
|
|
521
306
|
}) {
|
|
522
|
-
const
|
|
523
|
-
return /* @__PURE__ */
|
|
307
|
+
const o = y(), l = (c) => c === "added" ? o.diff.insertedLine : c === "removed" ? o.diff.removedLine : "transparent", u = (c) => c === "added" ? o.diff.stripAdded : c === "removed" ? o.diff.stripRemoved : "transparent", d = (c) => r && c === "added" ? k.added : r && c === "removed" ? k.deleted : o.text.tertiary;
|
|
308
|
+
return /* @__PURE__ */ s(
|
|
524
309
|
"div",
|
|
525
310
|
{
|
|
526
311
|
style: {
|
|
527
312
|
fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Code", monospace',
|
|
528
313
|
fontSize: 12.5,
|
|
529
314
|
lineHeight: "18px",
|
|
530
|
-
color:
|
|
315
|
+
color: o.text.primary,
|
|
531
316
|
overflowX: "auto",
|
|
532
|
-
...
|
|
317
|
+
...i
|
|
533
318
|
},
|
|
534
|
-
children: e.map((
|
|
319
|
+
children: e.map((c, f) => /* @__PURE__ */ p(
|
|
535
320
|
"div",
|
|
536
321
|
{
|
|
537
322
|
style: {
|
|
538
323
|
display: "flex",
|
|
539
324
|
alignItems: "stretch",
|
|
540
|
-
background: l(
|
|
541
|
-
borderLeft:
|
|
325
|
+
background: l(c.type),
|
|
326
|
+
borderLeft: n ? `3px solid ${u(c.type)}` : void 0
|
|
542
327
|
},
|
|
543
328
|
children: [
|
|
544
|
-
t && /* @__PURE__ */
|
|
329
|
+
t && /* @__PURE__ */ s(
|
|
545
330
|
"span",
|
|
546
331
|
{
|
|
547
332
|
style: {
|
|
@@ -550,12 +335,12 @@ function lt({
|
|
|
550
335
|
textAlign: "right",
|
|
551
336
|
paddingRight: 10,
|
|
552
337
|
userSelect: "none",
|
|
553
|
-
color: d(
|
|
338
|
+
color: d(c.type)
|
|
554
339
|
},
|
|
555
|
-
children:
|
|
340
|
+
children: c.lineNumber ?? ""
|
|
556
341
|
}
|
|
557
342
|
),
|
|
558
|
-
/* @__PURE__ */
|
|
343
|
+
/* @__PURE__ */ s(
|
|
559
344
|
"span",
|
|
560
345
|
{
|
|
561
346
|
style: {
|
|
@@ -563,12 +348,12 @@ function lt({
|
|
|
563
348
|
width: 14,
|
|
564
349
|
textAlign: "center",
|
|
565
350
|
userSelect: "none",
|
|
566
|
-
color: d(
|
|
351
|
+
color: d(c.type)
|
|
567
352
|
},
|
|
568
|
-
children:
|
|
353
|
+
children: Rt[c.type]
|
|
569
354
|
}
|
|
570
355
|
),
|
|
571
|
-
/* @__PURE__ */
|
|
356
|
+
/* @__PURE__ */ s(
|
|
572
357
|
"pre",
|
|
573
358
|
{
|
|
574
359
|
style: {
|
|
@@ -577,7 +362,7 @@ function lt({
|
|
|
577
362
|
whiteSpace: "pre",
|
|
578
363
|
fontFamily: "inherit"
|
|
579
364
|
},
|
|
580
|
-
children:
|
|
365
|
+
children: c.content
|
|
581
366
|
}
|
|
582
367
|
)
|
|
583
368
|
]
|
|
@@ -587,9 +372,9 @@ function lt({
|
|
|
587
372
|
}
|
|
588
373
|
);
|
|
589
374
|
}
|
|
590
|
-
function
|
|
591
|
-
const t =
|
|
592
|
-
return /* @__PURE__ */
|
|
375
|
+
function Wt({ status: e }) {
|
|
376
|
+
const t = y(), r = e === "completed" ? k.success : e === "in_progress" ? t.accent.primary : e === "cancelled" ? k.danger : t.text.tertiary;
|
|
377
|
+
return /* @__PURE__ */ p(
|
|
593
378
|
"svg",
|
|
594
379
|
{
|
|
595
380
|
width: 14,
|
|
@@ -599,8 +384,8 @@ function Xe({ status: e }) {
|
|
|
599
384
|
style: { flex: "0 0 auto", marginTop: 3 },
|
|
600
385
|
"aria-hidden": !0,
|
|
601
386
|
children: [
|
|
602
|
-
/* @__PURE__ */
|
|
603
|
-
e === "completed" && /* @__PURE__ */
|
|
387
|
+
/* @__PURE__ */ s("circle", { cx: 7, cy: 7, r: 6, stroke: r, strokeWidth: 1.4 }),
|
|
388
|
+
e === "completed" && /* @__PURE__ */ s(
|
|
604
389
|
"path",
|
|
605
390
|
{
|
|
606
391
|
d: "M4 7.2l2 2 4-4.4",
|
|
@@ -610,8 +395,8 @@ function Xe({ status: e }) {
|
|
|
610
395
|
strokeLinejoin: "round"
|
|
611
396
|
}
|
|
612
397
|
),
|
|
613
|
-
e === "in_progress" && /* @__PURE__ */
|
|
614
|
-
e === "cancelled" && /* @__PURE__ */
|
|
398
|
+
e === "in_progress" && /* @__PURE__ */ s("circle", { cx: 7, cy: 7, r: 3, fill: r }),
|
|
399
|
+
e === "cancelled" && /* @__PURE__ */ s(
|
|
615
400
|
"path",
|
|
616
401
|
{
|
|
617
402
|
d: "M4.8 4.8l4.4 4.4M9.2 4.8l-4.4 4.4",
|
|
@@ -624,20 +409,20 @@ function Xe({ status: e }) {
|
|
|
624
409
|
}
|
|
625
410
|
);
|
|
626
411
|
}
|
|
627
|
-
function
|
|
412
|
+
function Ht({
|
|
628
413
|
todos: e,
|
|
629
414
|
dimmedTodoIds: t,
|
|
630
415
|
onTodoClick: r,
|
|
631
|
-
style:
|
|
416
|
+
style: n
|
|
632
417
|
}) {
|
|
633
|
-
const
|
|
634
|
-
return e.length === 0 ? null : /* @__PURE__ */
|
|
635
|
-
const l = t == null ? void 0 : t.has(
|
|
636
|
-
return /* @__PURE__ */
|
|
418
|
+
const i = y();
|
|
419
|
+
return e.length === 0 ? null : /* @__PURE__ */ s("div", { style: { display: "flex", flexDirection: "column", ...n }, children: e.map((o) => {
|
|
420
|
+
const l = t == null ? void 0 : t.has(o.id);
|
|
421
|
+
return /* @__PURE__ */ p(
|
|
637
422
|
"button",
|
|
638
423
|
{
|
|
639
424
|
type: "button",
|
|
640
|
-
onClick: () => r == null ? void 0 : r(
|
|
425
|
+
onClick: () => r == null ? void 0 : r(o),
|
|
641
426
|
style: {
|
|
642
427
|
display: "flex",
|
|
643
428
|
gap: 8,
|
|
@@ -648,54 +433,54 @@ function Ye({
|
|
|
648
433
|
background: "transparent",
|
|
649
434
|
border: "none",
|
|
650
435
|
cursor: r ? "pointer" : "default",
|
|
651
|
-
color:
|
|
436
|
+
color: i.text.primary,
|
|
652
437
|
fontSize: 14,
|
|
653
438
|
lineHeight: "20px",
|
|
654
439
|
opacity: l ? 0.45 : 1
|
|
655
440
|
},
|
|
656
441
|
children: [
|
|
657
|
-
/* @__PURE__ */
|
|
658
|
-
/* @__PURE__ */
|
|
442
|
+
/* @__PURE__ */ s(Wt, { status: o.status }),
|
|
443
|
+
/* @__PURE__ */ s(
|
|
659
444
|
"span",
|
|
660
445
|
{
|
|
661
446
|
style: {
|
|
662
|
-
textDecoration:
|
|
663
|
-
color:
|
|
447
|
+
textDecoration: o.status === "cancelled" ? "line-through" : void 0,
|
|
448
|
+
color: o.status === "cancelled" ? i.text.tertiary : void 0
|
|
664
449
|
},
|
|
665
|
-
children:
|
|
450
|
+
children: o.content
|
|
666
451
|
}
|
|
667
452
|
)
|
|
668
453
|
]
|
|
669
454
|
},
|
|
670
|
-
|
|
455
|
+
o.id
|
|
671
456
|
);
|
|
672
457
|
}) });
|
|
673
458
|
}
|
|
674
|
-
function
|
|
459
|
+
function Qt({
|
|
675
460
|
todos: e,
|
|
676
461
|
dimmedTodoIds: t,
|
|
677
462
|
defaultExpanded: r = !1,
|
|
678
|
-
onTodoClick:
|
|
679
|
-
style:
|
|
463
|
+
onTodoClick: n,
|
|
464
|
+
style: i
|
|
680
465
|
}) {
|
|
681
|
-
const
|
|
466
|
+
const o = y(), [l, u] = I(r);
|
|
682
467
|
if (e.length === 0) return null;
|
|
683
|
-
const d = e.filter((
|
|
684
|
-
return /* @__PURE__ */
|
|
468
|
+
const d = e.filter((c) => c.status === "completed").length;
|
|
469
|
+
return /* @__PURE__ */ p(
|
|
685
470
|
"div",
|
|
686
471
|
{
|
|
687
472
|
style: {
|
|
688
|
-
border: `1px solid ${
|
|
473
|
+
border: `1px solid ${o.stroke.primary}`,
|
|
689
474
|
borderRadius: 6,
|
|
690
475
|
overflow: "hidden",
|
|
691
|
-
...
|
|
476
|
+
...i
|
|
692
477
|
},
|
|
693
478
|
children: [
|
|
694
|
-
/* @__PURE__ */
|
|
479
|
+
/* @__PURE__ */ p(
|
|
695
480
|
"button",
|
|
696
481
|
{
|
|
697
482
|
type: "button",
|
|
698
|
-
onClick: () => u((
|
|
483
|
+
onClick: () => u((c) => !c),
|
|
699
484
|
style: {
|
|
700
485
|
display: "flex",
|
|
701
486
|
alignItems: "center",
|
|
@@ -705,12 +490,12 @@ function dt({
|
|
|
705
490
|
background: "transparent",
|
|
706
491
|
border: "none",
|
|
707
492
|
cursor: "pointer",
|
|
708
|
-
color:
|
|
493
|
+
color: o.text.secondary,
|
|
709
494
|
fontSize: 12,
|
|
710
495
|
fontWeight: 600
|
|
711
496
|
},
|
|
712
497
|
children: [
|
|
713
|
-
/* @__PURE__ */
|
|
498
|
+
/* @__PURE__ */ s(
|
|
714
499
|
"svg",
|
|
715
500
|
{
|
|
716
501
|
width: 12,
|
|
@@ -722,7 +507,7 @@ function dt({
|
|
|
722
507
|
transition: "transform 120ms"
|
|
723
508
|
},
|
|
724
509
|
"aria-hidden": !0,
|
|
725
|
-
children: /* @__PURE__ */
|
|
510
|
+
children: /* @__PURE__ */ s(
|
|
726
511
|
"path",
|
|
727
512
|
{
|
|
728
513
|
d: "M4 2.5L8 6l-4 3.5",
|
|
@@ -734,9 +519,9 @@ function dt({
|
|
|
734
519
|
)
|
|
735
520
|
}
|
|
736
521
|
),
|
|
737
|
-
/* @__PURE__ */
|
|
738
|
-
/* @__PURE__ */
|
|
739
|
-
/* @__PURE__ */
|
|
522
|
+
/* @__PURE__ */ s("span", { children: "Todos" }),
|
|
523
|
+
/* @__PURE__ */ s("span", { style: { flex: 1 } }),
|
|
524
|
+
/* @__PURE__ */ p("span", { children: [
|
|
740
525
|
d,
|
|
741
526
|
" of ",
|
|
742
527
|
e.length,
|
|
@@ -745,20 +530,20 @@ function dt({
|
|
|
745
530
|
]
|
|
746
531
|
}
|
|
747
532
|
),
|
|
748
|
-
l && /* @__PURE__ */
|
|
749
|
-
|
|
533
|
+
l && /* @__PURE__ */ s("div", { style: { padding: 6 }, children: /* @__PURE__ */ s(
|
|
534
|
+
Ht,
|
|
750
535
|
{
|
|
751
536
|
todos: e,
|
|
752
537
|
dimmedTodoIds: t,
|
|
753
|
-
onTodoClick:
|
|
538
|
+
onTodoClick: n
|
|
754
539
|
}
|
|
755
540
|
) })
|
|
756
541
|
]
|
|
757
542
|
}
|
|
758
543
|
);
|
|
759
544
|
}
|
|
760
|
-
function
|
|
761
|
-
const r = `canvas:${e}`, [
|
|
545
|
+
function te(e, t) {
|
|
546
|
+
const r = `canvas:${e}`, [n, i] = I(() => {
|
|
762
547
|
if (typeof localStorage > "u") return t;
|
|
763
548
|
try {
|
|
764
549
|
const l = localStorage.getItem(r);
|
|
@@ -766,9 +551,9 @@ function ut(e, t) {
|
|
|
766
551
|
} catch {
|
|
767
552
|
return t;
|
|
768
553
|
}
|
|
769
|
-
}),
|
|
554
|
+
}), o = j(
|
|
770
555
|
(l) => {
|
|
771
|
-
|
|
556
|
+
i((u) => {
|
|
772
557
|
const d = typeof l == "function" ? l(u) : l;
|
|
773
558
|
try {
|
|
774
559
|
localStorage == null || localStorage.setItem(r, JSON.stringify(d));
|
|
@@ -779,63 +564,85 @@ function ut(e, t) {
|
|
|
779
564
|
},
|
|
780
565
|
[r]
|
|
781
566
|
);
|
|
782
|
-
return [
|
|
567
|
+
return [n, o];
|
|
783
568
|
}
|
|
784
|
-
function
|
|
785
|
-
return
|
|
569
|
+
function ee() {
|
|
570
|
+
return j((e) => {
|
|
786
571
|
}, []);
|
|
787
572
|
}
|
|
788
|
-
function
|
|
573
|
+
function re(e, t) {
|
|
789
574
|
return { ...e, ...t };
|
|
790
575
|
}
|
|
791
|
-
function
|
|
792
|
-
|
|
576
|
+
function N(e, t, r) {
|
|
577
|
+
const n = e.typography[t];
|
|
578
|
+
return {
|
|
579
|
+
fontFamily: e.typography.fontFamily,
|
|
580
|
+
fontSize: n.fontSize,
|
|
581
|
+
lineHeight: n.lineHeight,
|
|
582
|
+
fontWeight: n.fontWeight,
|
|
583
|
+
color: e.text.primary,
|
|
584
|
+
margin: 0,
|
|
585
|
+
...r
|
|
586
|
+
};
|
|
587
|
+
}
|
|
588
|
+
function ne({ children: e, style: t }) {
|
|
589
|
+
const r = y();
|
|
590
|
+
return /* @__PURE__ */ s(E, { order: 1, style: N(r, "h1", t), children: e });
|
|
793
591
|
}
|
|
794
|
-
function
|
|
795
|
-
|
|
592
|
+
function oe({ children: e, style: t }) {
|
|
593
|
+
const r = y();
|
|
594
|
+
return /* @__PURE__ */ s(E, { order: 2, style: N(r, "h2", t), children: e });
|
|
796
595
|
}
|
|
797
|
-
function
|
|
798
|
-
|
|
596
|
+
function ae({ children: e, style: t }) {
|
|
597
|
+
const r = y();
|
|
598
|
+
return /* @__PURE__ */ s(E, { order: 3, style: N(r, "h3", t), children: e });
|
|
799
599
|
}
|
|
800
|
-
const
|
|
600
|
+
const Et = {
|
|
801
601
|
normal: 400,
|
|
802
602
|
medium: 500,
|
|
803
603
|
semibold: 600,
|
|
804
604
|
bold: 700
|
|
805
605
|
};
|
|
806
|
-
function
|
|
606
|
+
function ie({
|
|
807
607
|
children: e,
|
|
808
608
|
tone: t = "primary",
|
|
809
609
|
size: r = "body",
|
|
810
|
-
as:
|
|
811
|
-
weight:
|
|
812
|
-
italic:
|
|
610
|
+
as: n = "p",
|
|
611
|
+
weight: i = "normal",
|
|
612
|
+
italic: o,
|
|
813
613
|
truncate: l,
|
|
814
614
|
style: u
|
|
815
615
|
}) {
|
|
816
|
-
const d =
|
|
817
|
-
return /* @__PURE__ */
|
|
616
|
+
const d = y();
|
|
617
|
+
return /* @__PURE__ */ s(
|
|
818
618
|
H,
|
|
819
619
|
{
|
|
820
|
-
component:
|
|
620
|
+
component: n,
|
|
821
621
|
size: r === "small" ? "xs" : "sm",
|
|
822
|
-
fw:
|
|
622
|
+
fw: Et[i],
|
|
823
623
|
c: t === "primary" ? void 0 : d.text[t],
|
|
824
624
|
truncate: l,
|
|
825
|
-
style: {
|
|
625
|
+
style: {
|
|
626
|
+
fontStyle: o ? "italic" : void 0,
|
|
627
|
+
...t === "primary" ? { color: d.text.primary } : void 0,
|
|
628
|
+
fontFamily: d.typography.fontFamily,
|
|
629
|
+
...u
|
|
630
|
+
},
|
|
826
631
|
children: e
|
|
827
632
|
}
|
|
828
633
|
);
|
|
829
634
|
}
|
|
830
|
-
function
|
|
831
|
-
|
|
635
|
+
function se({ children: e, style: t }) {
|
|
636
|
+
const r = y();
|
|
637
|
+
return /* @__PURE__ */ s(
|
|
832
638
|
"code",
|
|
833
639
|
{
|
|
834
640
|
style: {
|
|
835
641
|
fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Code", monospace',
|
|
836
642
|
fontSize: "0.92em",
|
|
837
|
-
|
|
838
|
-
|
|
643
|
+
color: r.text.primary,
|
|
644
|
+
background: r.fill.secondary,
|
|
645
|
+
borderRadius: r.radius.sm,
|
|
839
646
|
padding: "1px 4px",
|
|
840
647
|
...t
|
|
841
648
|
},
|
|
@@ -843,136 +650,142 @@ function xt({ children: e, style: t }) {
|
|
|
843
650
|
}
|
|
844
651
|
);
|
|
845
652
|
}
|
|
846
|
-
function
|
|
847
|
-
|
|
653
|
+
function ce({ children: e, href: t, style: r }) {
|
|
654
|
+
const n = y();
|
|
655
|
+
return /* @__PURE__ */ s(
|
|
848
656
|
"a",
|
|
849
657
|
{
|
|
850
658
|
href: t,
|
|
851
659
|
target: "_blank",
|
|
852
660
|
rel: "noreferrer",
|
|
853
|
-
style: { color:
|
|
661
|
+
style: { color: n.text.link, ...r },
|
|
854
662
|
children: e
|
|
855
663
|
}
|
|
856
664
|
);
|
|
857
665
|
}
|
|
858
|
-
function
|
|
859
|
-
return /* @__PURE__ */
|
|
666
|
+
function le({ children: e, gap: t, style: r }) {
|
|
667
|
+
return /* @__PURE__ */ s(wt, { gap: t, style: r, children: e });
|
|
860
668
|
}
|
|
861
|
-
const
|
|
669
|
+
const et = {
|
|
862
670
|
start: "flex-start",
|
|
863
671
|
center: "center",
|
|
864
672
|
end: "flex-end",
|
|
865
673
|
stretch: "stretch",
|
|
866
674
|
"space-between": "space-between"
|
|
867
675
|
};
|
|
868
|
-
function
|
|
676
|
+
function de({
|
|
869
677
|
children: e,
|
|
870
678
|
gap: t,
|
|
871
679
|
align: r = "center",
|
|
872
|
-
justify:
|
|
873
|
-
wrap:
|
|
874
|
-
style:
|
|
680
|
+
justify: n = "start",
|
|
681
|
+
wrap: i = !1,
|
|
682
|
+
style: o
|
|
875
683
|
}) {
|
|
876
|
-
return /* @__PURE__ */
|
|
877
|
-
|
|
684
|
+
return /* @__PURE__ */ s(
|
|
685
|
+
kt,
|
|
878
686
|
{
|
|
879
687
|
gap: t,
|
|
880
|
-
align:
|
|
881
|
-
justify:
|
|
882
|
-
wrap:
|
|
883
|
-
style:
|
|
688
|
+
align: et[r],
|
|
689
|
+
justify: et[n],
|
|
690
|
+
wrap: i ? "wrap" : "nowrap",
|
|
691
|
+
style: o,
|
|
884
692
|
children: e
|
|
885
693
|
}
|
|
886
694
|
);
|
|
887
695
|
}
|
|
888
|
-
function
|
|
889
|
-
return /* @__PURE__ */
|
|
696
|
+
function ue() {
|
|
697
|
+
return /* @__PURE__ */ s("div", { style: { flex: 1 } });
|
|
890
698
|
}
|
|
891
|
-
function
|
|
892
|
-
const
|
|
893
|
-
return /* @__PURE__ */
|
|
699
|
+
function fe({ children: e, columns: t, gap: r = 16, align: n, style: i }) {
|
|
700
|
+
const o = typeof t == "number" ? `repeat(${t}, minmax(0, 1fr))` : t;
|
|
701
|
+
return /* @__PURE__ */ s(
|
|
894
702
|
"div",
|
|
895
703
|
{
|
|
896
704
|
style: {
|
|
897
705
|
display: "grid",
|
|
898
|
-
gridTemplateColumns:
|
|
706
|
+
gridTemplateColumns: o,
|
|
899
707
|
gap: r,
|
|
900
|
-
alignItems:
|
|
901
|
-
...
|
|
708
|
+
alignItems: n,
|
|
709
|
+
...i
|
|
902
710
|
},
|
|
903
711
|
children: e
|
|
904
712
|
}
|
|
905
713
|
);
|
|
906
714
|
}
|
|
907
|
-
function
|
|
908
|
-
return /* @__PURE__ */
|
|
715
|
+
function he({ style: e }) {
|
|
716
|
+
return /* @__PURE__ */ s(xt, { style: e });
|
|
909
717
|
}
|
|
910
|
-
const O =
|
|
718
|
+
const O = Mt({
|
|
911
719
|
collapsible: !1,
|
|
912
720
|
open: !0,
|
|
913
721
|
toggle: () => {
|
|
914
722
|
}
|
|
915
723
|
});
|
|
916
|
-
function
|
|
724
|
+
function pe({
|
|
917
725
|
children: e,
|
|
918
726
|
variant: t = "default",
|
|
919
727
|
collapsible: r = !1,
|
|
920
|
-
defaultOpen:
|
|
921
|
-
open:
|
|
922
|
-
onOpenChange:
|
|
728
|
+
defaultOpen: n = !0,
|
|
729
|
+
open: i,
|
|
730
|
+
onOpenChange: o,
|
|
923
731
|
style: l
|
|
924
732
|
}) {
|
|
925
|
-
const
|
|
926
|
-
const
|
|
927
|
-
|
|
928
|
-
}, [
|
|
929
|
-
return /* @__PURE__ */
|
|
930
|
-
|
|
733
|
+
const u = y(), [d, c] = I(n), f = i ?? d, m = j(() => {
|
|
734
|
+
const x = !f;
|
|
735
|
+
i === void 0 && c(x), o == null || o(x);
|
|
736
|
+
}, [f, i, o]);
|
|
737
|
+
return /* @__PURE__ */ s(
|
|
738
|
+
gt,
|
|
931
739
|
{
|
|
932
740
|
withBorder: t !== "borderless",
|
|
933
|
-
radius:
|
|
741
|
+
radius: u.radius.md,
|
|
934
742
|
padding: 0,
|
|
935
|
-
style:
|
|
936
|
-
|
|
743
|
+
style: {
|
|
744
|
+
background: u.bg.elevated,
|
|
745
|
+
borderColor: u.stroke.secondary,
|
|
746
|
+
...l
|
|
747
|
+
},
|
|
748
|
+
children: /* @__PURE__ */ s(O.Provider, { value: { collapsible: r, open: f, toggle: m }, children: e })
|
|
937
749
|
}
|
|
938
750
|
);
|
|
939
751
|
}
|
|
940
|
-
function
|
|
941
|
-
const { collapsible:
|
|
942
|
-
return /* @__PURE__ */
|
|
752
|
+
function ye({ children: e, trailing: t, style: r }) {
|
|
753
|
+
const n = y(), { collapsible: i, open: o, toggle: l } = rt(O);
|
|
754
|
+
return /* @__PURE__ */ p(
|
|
943
755
|
"div",
|
|
944
756
|
{
|
|
945
|
-
onClick:
|
|
757
|
+
onClick: i ? l : void 0,
|
|
946
758
|
style: {
|
|
947
759
|
display: "flex",
|
|
948
760
|
alignItems: "center",
|
|
949
761
|
justifyContent: "space-between",
|
|
950
762
|
gap: 8,
|
|
951
763
|
padding: "8px 14px",
|
|
952
|
-
borderBottom:
|
|
953
|
-
fontSize:
|
|
954
|
-
fontWeight:
|
|
955
|
-
color:
|
|
956
|
-
|
|
957
|
-
|
|
764
|
+
borderBottom: `1px solid ${n.stroke.secondary}`,
|
|
765
|
+
fontSize: n.typography.small.fontSize,
|
|
766
|
+
fontWeight: n.typography.h3.fontWeight,
|
|
767
|
+
color: n.text.tertiary,
|
|
768
|
+
fontFamily: n.typography.fontFamily,
|
|
769
|
+
cursor: i ? "pointer" : void 0,
|
|
770
|
+
userSelect: i ? "none" : void 0,
|
|
958
771
|
...r
|
|
959
772
|
},
|
|
960
773
|
children: [
|
|
961
|
-
/* @__PURE__ */
|
|
962
|
-
|
|
774
|
+
/* @__PURE__ */ p("span", { style: { display: "inline-flex", alignItems: "center", gap: 6 }, children: [
|
|
775
|
+
i && /* @__PURE__ */ s(ct, { expanded: o }),
|
|
963
776
|
e
|
|
964
777
|
] }),
|
|
965
|
-
t != null && /* @__PURE__ */
|
|
778
|
+
t != null && /* @__PURE__ */ s("span", { children: t })
|
|
966
779
|
]
|
|
967
780
|
}
|
|
968
781
|
);
|
|
969
782
|
}
|
|
970
|
-
function
|
|
971
|
-
const { collapsible: r, open:
|
|
972
|
-
return r && !
|
|
783
|
+
function ge({ children: e, style: t }) {
|
|
784
|
+
const { collapsible: r, open: n } = rt(O);
|
|
785
|
+
return r && !n ? null : /* @__PURE__ */ s("div", { style: { padding: 14, ...t }, children: e });
|
|
973
786
|
}
|
|
974
|
-
function
|
|
975
|
-
return /* @__PURE__ */
|
|
787
|
+
function ct({ expanded: e }) {
|
|
788
|
+
return /* @__PURE__ */ s(
|
|
976
789
|
"svg",
|
|
977
790
|
{
|
|
978
791
|
width: 12,
|
|
@@ -984,7 +797,7 @@ function he({ expanded: e }) {
|
|
|
984
797
|
transition: "transform 120ms"
|
|
985
798
|
},
|
|
986
799
|
"aria-hidden": !0,
|
|
987
|
-
children: /* @__PURE__ */
|
|
800
|
+
children: /* @__PURE__ */ s(
|
|
988
801
|
"path",
|
|
989
802
|
{
|
|
990
803
|
d: "M4 2.5L8 6l-4 3.5",
|
|
@@ -997,40 +810,54 @@ function he({ expanded: e }) {
|
|
|
997
810
|
}
|
|
998
811
|
);
|
|
999
812
|
}
|
|
1000
|
-
function
|
|
1001
|
-
|
|
1002
|
-
|
|
813
|
+
function me({ value: e, label: t, tone: r, style: n }) {
|
|
814
|
+
const i = y();
|
|
815
|
+
return /* @__PURE__ */ p("div", { style: n, children: [
|
|
816
|
+
/* @__PURE__ */ s(
|
|
1003
817
|
H,
|
|
1004
818
|
{
|
|
1005
819
|
fz: 22,
|
|
1006
820
|
fw: 700,
|
|
1007
821
|
lh: 1.2,
|
|
1008
|
-
|
|
822
|
+
style: {
|
|
823
|
+
color: r ? k[r] : i.text.primary,
|
|
824
|
+
fontFamily: i.typography.fontFamily
|
|
825
|
+
},
|
|
1009
826
|
children: e
|
|
1010
827
|
}
|
|
1011
828
|
),
|
|
1012
|
-
/* @__PURE__ */
|
|
829
|
+
/* @__PURE__ */ s(
|
|
830
|
+
H,
|
|
831
|
+
{
|
|
832
|
+
fz: 12,
|
|
833
|
+
style: {
|
|
834
|
+
color: i.text.tertiary,
|
|
835
|
+
fontFamily: i.typography.fontFamily
|
|
836
|
+
},
|
|
837
|
+
children: t
|
|
838
|
+
}
|
|
839
|
+
)
|
|
1013
840
|
] });
|
|
1014
841
|
}
|
|
1015
|
-
function
|
|
842
|
+
function xe({
|
|
1016
843
|
children: e,
|
|
1017
844
|
active: t,
|
|
1018
845
|
tone: r = "neutral",
|
|
1019
|
-
size:
|
|
1020
|
-
leadingContent:
|
|
1021
|
-
keyboardHint:
|
|
846
|
+
size: n = "md",
|
|
847
|
+
leadingContent: i,
|
|
848
|
+
keyboardHint: o,
|
|
1022
849
|
title: l,
|
|
1023
850
|
style: u,
|
|
1024
851
|
onClick: d
|
|
1025
852
|
}) {
|
|
1026
|
-
return /* @__PURE__ */
|
|
1027
|
-
|
|
853
|
+
return /* @__PURE__ */ s(
|
|
854
|
+
bt,
|
|
1028
855
|
{
|
|
1029
|
-
color:
|
|
856
|
+
color: nt[r],
|
|
1030
857
|
variant: t ? "filled" : "light",
|
|
1031
|
-
size:
|
|
1032
|
-
leftSection:
|
|
1033
|
-
rightSection:
|
|
858
|
+
size: n === "sm" ? "sm" : "md",
|
|
859
|
+
leftSection: i,
|
|
860
|
+
rightSection: o,
|
|
1034
861
|
title: l,
|
|
1035
862
|
onClick: d,
|
|
1036
863
|
style: {
|
|
@@ -1042,67 +869,67 @@ function Tt({
|
|
|
1042
869
|
}
|
|
1043
870
|
);
|
|
1044
871
|
}
|
|
1045
|
-
function
|
|
872
|
+
function ve({
|
|
1046
873
|
children: e,
|
|
1047
874
|
tone: t = "neutral",
|
|
1048
875
|
title: r,
|
|
1049
|
-
icon:
|
|
1050
|
-
style:
|
|
876
|
+
icon: n,
|
|
877
|
+
style: i
|
|
1051
878
|
}) {
|
|
1052
|
-
return /* @__PURE__ */
|
|
1053
|
-
|
|
879
|
+
return /* @__PURE__ */ s(
|
|
880
|
+
yt,
|
|
1054
881
|
{
|
|
1055
|
-
color:
|
|
882
|
+
color: nt[t],
|
|
1056
883
|
title: r,
|
|
1057
|
-
icon:
|
|
884
|
+
icon: n,
|
|
1058
885
|
variant: "light",
|
|
1059
|
-
style:
|
|
886
|
+
style: i,
|
|
1060
887
|
children: e
|
|
1061
888
|
}
|
|
1062
889
|
);
|
|
1063
890
|
}
|
|
1064
|
-
const
|
|
891
|
+
const jt = {
|
|
1065
892
|
success: "rgba(31,138,101,0.12)",
|
|
1066
893
|
danger: "rgba(207,45,86,0.12)",
|
|
1067
894
|
warning: "rgba(232,163,61,0.14)",
|
|
1068
895
|
info: "rgba(46,121,181,0.12)",
|
|
1069
896
|
neutral: "rgba(136,136,168,0.12)"
|
|
1070
897
|
};
|
|
1071
|
-
function
|
|
898
|
+
function be({
|
|
1072
899
|
headers: e,
|
|
1073
900
|
rows: t,
|
|
1074
901
|
columnAlign: r,
|
|
1075
|
-
rowTone:
|
|
1076
|
-
framed:
|
|
1077
|
-
striped:
|
|
902
|
+
rowTone: n,
|
|
903
|
+
framed: i = !0,
|
|
904
|
+
striped: o,
|
|
1078
905
|
stickyHeader: l,
|
|
1079
906
|
style: u,
|
|
1080
907
|
emptyMessage: d
|
|
1081
908
|
}) {
|
|
1082
|
-
return /* @__PURE__ */
|
|
1083
|
-
|
|
909
|
+
return /* @__PURE__ */ p(
|
|
910
|
+
S,
|
|
1084
911
|
{
|
|
1085
|
-
withTableBorder:
|
|
912
|
+
withTableBorder: i,
|
|
1086
913
|
withColumnBorders: !1,
|
|
1087
|
-
striped:
|
|
914
|
+
striped: o,
|
|
1088
915
|
stickyHeader: l,
|
|
1089
916
|
highlightOnHover: !0,
|
|
1090
917
|
style: u,
|
|
1091
918
|
children: [
|
|
1092
|
-
/* @__PURE__ */
|
|
1093
|
-
/* @__PURE__ */
|
|
1094
|
-
const
|
|
1095
|
-
return /* @__PURE__ */
|
|
1096
|
-
|
|
919
|
+
/* @__PURE__ */ s(S.Thead, { children: /* @__PURE__ */ s(S.Tr, { children: e.map((c, f) => /* @__PURE__ */ s(S.Th, { ta: (r == null ? void 0 : r[f]) ?? "left", children: c }, f)) }) }),
|
|
920
|
+
/* @__PURE__ */ s(S.Tbody, { children: t.length === 0 ? /* @__PURE__ */ s(S.Tr, { children: /* @__PURE__ */ s(S.Td, { colSpan: e.length, ta: "center", c: "dimmed", children: d ?? "No data" }) }) : t.map((c, f) => {
|
|
921
|
+
const m = n == null ? void 0 : n[f];
|
|
922
|
+
return /* @__PURE__ */ s(
|
|
923
|
+
S.Tr,
|
|
1097
924
|
{
|
|
1098
|
-
style:
|
|
1099
|
-
children: e.map((x,
|
|
1100
|
-
|
|
925
|
+
style: m ? { background: jt[m] } : void 0,
|
|
926
|
+
children: e.map((x, b) => /* @__PURE__ */ s(
|
|
927
|
+
S.Td,
|
|
1101
928
|
{
|
|
1102
|
-
ta: (r == null ? void 0 : r[
|
|
1103
|
-
children:
|
|
929
|
+
ta: (r == null ? void 0 : r[b]) ?? "left",
|
|
930
|
+
children: c[b]
|
|
1104
931
|
},
|
|
1105
|
-
|
|
932
|
+
b
|
|
1106
933
|
))
|
|
1107
934
|
},
|
|
1108
935
|
f
|
|
@@ -1112,160 +939,161 @@ function Dt({
|
|
|
1112
939
|
}
|
|
1113
940
|
);
|
|
1114
941
|
}
|
|
1115
|
-
const
|
|
942
|
+
const Gt = {
|
|
1116
943
|
primary: "filled",
|
|
1117
944
|
secondary: "default",
|
|
1118
945
|
ghost: "subtle"
|
|
1119
946
|
};
|
|
1120
|
-
function
|
|
947
|
+
function ke({
|
|
1121
948
|
children: e,
|
|
1122
949
|
variant: t = "secondary",
|
|
1123
950
|
disabled: r,
|
|
1124
|
-
type:
|
|
1125
|
-
style:
|
|
1126
|
-
onClick:
|
|
951
|
+
type: n = "button",
|
|
952
|
+
style: i,
|
|
953
|
+
onClick: o
|
|
1127
954
|
}) {
|
|
1128
|
-
return /* @__PURE__ */
|
|
1129
|
-
|
|
955
|
+
return /* @__PURE__ */ s(
|
|
956
|
+
pt,
|
|
1130
957
|
{
|
|
1131
|
-
variant:
|
|
958
|
+
variant: Gt[t],
|
|
959
|
+
color: t === "primary" ? "accent" : void 0,
|
|
1132
960
|
size: "xs",
|
|
1133
961
|
disabled: r,
|
|
1134
|
-
type:
|
|
1135
|
-
onClick:
|
|
1136
|
-
style:
|
|
962
|
+
type: n,
|
|
963
|
+
onClick: o,
|
|
964
|
+
style: i,
|
|
1137
965
|
children: e
|
|
1138
966
|
}
|
|
1139
967
|
);
|
|
1140
968
|
}
|
|
1141
|
-
function
|
|
969
|
+
function Se({
|
|
1142
970
|
children: e,
|
|
1143
971
|
onClick: t,
|
|
1144
972
|
disabled: r,
|
|
1145
|
-
title:
|
|
1146
|
-
variant:
|
|
1147
|
-
size:
|
|
973
|
+
title: n,
|
|
974
|
+
variant: i = "default",
|
|
975
|
+
size: o = "md",
|
|
1148
976
|
style: l
|
|
1149
977
|
}) {
|
|
1150
|
-
return /* @__PURE__ */
|
|
1151
|
-
|
|
978
|
+
return /* @__PURE__ */ s(
|
|
979
|
+
vt,
|
|
1152
980
|
{
|
|
1153
|
-
variant:
|
|
1154
|
-
radius:
|
|
1155
|
-
size:
|
|
981
|
+
variant: i === "circle" ? "light" : "subtle",
|
|
982
|
+
radius: i === "circle" ? "xl" : "sm",
|
|
983
|
+
size: o === "sm" ? "sm" : "md",
|
|
1156
984
|
color: "gray",
|
|
1157
985
|
disabled: r,
|
|
1158
|
-
title:
|
|
1159
|
-
"aria-label":
|
|
986
|
+
title: n,
|
|
987
|
+
"aria-label": n,
|
|
1160
988
|
onClick: t,
|
|
1161
989
|
style: l,
|
|
1162
990
|
children: e
|
|
1163
991
|
}
|
|
1164
992
|
);
|
|
1165
993
|
}
|
|
1166
|
-
function
|
|
994
|
+
function we({
|
|
1167
995
|
value: e,
|
|
1168
996
|
onChange: t,
|
|
1169
997
|
options: r,
|
|
1170
|
-
placeholder:
|
|
1171
|
-
disabled:
|
|
1172
|
-
style:
|
|
998
|
+
placeholder: n,
|
|
999
|
+
disabled: i,
|
|
1000
|
+
style: o
|
|
1173
1001
|
}) {
|
|
1174
|
-
return /* @__PURE__ */
|
|
1175
|
-
|
|
1002
|
+
return /* @__PURE__ */ s(
|
|
1003
|
+
St,
|
|
1176
1004
|
{
|
|
1177
1005
|
value: e,
|
|
1178
1006
|
data: r,
|
|
1179
|
-
placeholder:
|
|
1180
|
-
disabled:
|
|
1007
|
+
placeholder: n,
|
|
1008
|
+
disabled: i,
|
|
1181
1009
|
allowDeselect: !1,
|
|
1182
1010
|
onChange: (l) => {
|
|
1183
1011
|
l !== null && (t == null || t(l));
|
|
1184
1012
|
},
|
|
1185
|
-
style:
|
|
1013
|
+
style: o
|
|
1186
1014
|
}
|
|
1187
1015
|
);
|
|
1188
1016
|
}
|
|
1189
|
-
function
|
|
1017
|
+
function Ce({
|
|
1190
1018
|
checked: e,
|
|
1191
1019
|
onChange: t,
|
|
1192
1020
|
disabled: r,
|
|
1193
|
-
label:
|
|
1194
|
-
style:
|
|
1021
|
+
label: n,
|
|
1022
|
+
style: i
|
|
1195
1023
|
}) {
|
|
1196
|
-
return /* @__PURE__ */
|
|
1197
|
-
|
|
1024
|
+
return /* @__PURE__ */ s(
|
|
1025
|
+
mt,
|
|
1198
1026
|
{
|
|
1199
1027
|
checked: e,
|
|
1200
1028
|
disabled: r,
|
|
1201
|
-
label:
|
|
1202
|
-
onChange: (
|
|
1203
|
-
style:
|
|
1029
|
+
label: n,
|
|
1030
|
+
onChange: (o) => t == null ? void 0 : t(o.currentTarget.checked),
|
|
1031
|
+
style: i
|
|
1204
1032
|
}
|
|
1205
1033
|
);
|
|
1206
1034
|
}
|
|
1207
|
-
function
|
|
1035
|
+
function Te({
|
|
1208
1036
|
checked: e,
|
|
1209
1037
|
onChange: t,
|
|
1210
1038
|
disabled: r,
|
|
1211
|
-
size:
|
|
1212
|
-
style:
|
|
1039
|
+
size: n = "sm",
|
|
1040
|
+
style: i
|
|
1213
1041
|
}) {
|
|
1214
|
-
return /* @__PURE__ */
|
|
1215
|
-
|
|
1042
|
+
return /* @__PURE__ */ s(
|
|
1043
|
+
Lt,
|
|
1216
1044
|
{
|
|
1217
1045
|
checked: e,
|
|
1218
1046
|
disabled: r,
|
|
1219
|
-
size:
|
|
1220
|
-
onChange: (
|
|
1221
|
-
style:
|
|
1047
|
+
size: n === "sm" ? "sm" : "md",
|
|
1048
|
+
onChange: (o) => t == null ? void 0 : t(o.currentTarget.checked),
|
|
1049
|
+
style: i
|
|
1222
1050
|
}
|
|
1223
1051
|
);
|
|
1224
1052
|
}
|
|
1225
|
-
function
|
|
1053
|
+
function Le({
|
|
1226
1054
|
value: e,
|
|
1227
1055
|
onChange: t,
|
|
1228
1056
|
placeholder: r,
|
|
1229
|
-
disabled:
|
|
1230
|
-
type:
|
|
1231
|
-
style:
|
|
1057
|
+
disabled: n,
|
|
1058
|
+
type: i,
|
|
1059
|
+
style: o
|
|
1232
1060
|
}) {
|
|
1233
|
-
return /* @__PURE__ */
|
|
1234
|
-
|
|
1061
|
+
return /* @__PURE__ */ s(
|
|
1062
|
+
Tt,
|
|
1235
1063
|
{
|
|
1236
1064
|
value: e,
|
|
1237
1065
|
placeholder: r,
|
|
1238
|
-
disabled:
|
|
1239
|
-
type:
|
|
1066
|
+
disabled: n,
|
|
1067
|
+
type: i,
|
|
1240
1068
|
onChange: (l) => t == null ? void 0 : t(l.currentTarget.value),
|
|
1241
|
-
style:
|
|
1069
|
+
style: o
|
|
1242
1070
|
}
|
|
1243
1071
|
);
|
|
1244
1072
|
}
|
|
1245
|
-
function
|
|
1073
|
+
function Me({
|
|
1246
1074
|
value: e,
|
|
1247
1075
|
onChange: t,
|
|
1248
1076
|
placeholder: r,
|
|
1249
|
-
disabled:
|
|
1250
|
-
rows:
|
|
1251
|
-
style:
|
|
1077
|
+
disabled: n,
|
|
1078
|
+
rows: i = 3,
|
|
1079
|
+
style: o
|
|
1252
1080
|
}) {
|
|
1253
|
-
return /* @__PURE__ */
|
|
1254
|
-
|
|
1081
|
+
return /* @__PURE__ */ s(
|
|
1082
|
+
Ct,
|
|
1255
1083
|
{
|
|
1256
1084
|
value: e,
|
|
1257
1085
|
placeholder: r,
|
|
1258
|
-
disabled:
|
|
1086
|
+
disabled: n,
|
|
1259
1087
|
autosize: !0,
|
|
1260
|
-
minRows:
|
|
1088
|
+
minRows: i,
|
|
1261
1089
|
onChange: (l) => t == null ? void 0 : t(l.currentTarget.value),
|
|
1262
|
-
style:
|
|
1090
|
+
style: o
|
|
1263
1091
|
}
|
|
1264
1092
|
);
|
|
1265
1093
|
}
|
|
1266
|
-
function
|
|
1267
|
-
const r =
|
|
1268
|
-
return /* @__PURE__ */
|
|
1094
|
+
function Be({ color: e, style: t }) {
|
|
1095
|
+
const r = y();
|
|
1096
|
+
return /* @__PURE__ */ s(
|
|
1269
1097
|
"span",
|
|
1270
1098
|
{
|
|
1271
1099
|
style: {
|
|
@@ -1280,55 +1108,55 @@ function Wt({ color: e, style: t }) {
|
|
|
1280
1108
|
}
|
|
1281
1109
|
);
|
|
1282
1110
|
}
|
|
1283
|
-
function
|
|
1111
|
+
function Fe({
|
|
1284
1112
|
segments: e,
|
|
1285
1113
|
total: t,
|
|
1286
1114
|
topLeftLabel: r,
|
|
1287
|
-
topRightLabel:
|
|
1288
|
-
style:
|
|
1115
|
+
topRightLabel: n,
|
|
1116
|
+
style: i
|
|
1289
1117
|
}) {
|
|
1290
|
-
const
|
|
1291
|
-
(
|
|
1118
|
+
const o = y(), l = t > 0 ? t : 1, u = e.reduce(
|
|
1119
|
+
(c, f) => c + (Number.isFinite(f.value) && f.value > 0 ? f.value : 0),
|
|
1292
1120
|
0
|
|
1293
1121
|
), d = Math.max(0, l - u);
|
|
1294
|
-
return /* @__PURE__ */
|
|
1295
|
-
(r != null ||
|
|
1122
|
+
return /* @__PURE__ */ p("div", { style: i, children: [
|
|
1123
|
+
(r != null || n != null) && /* @__PURE__ */ p(
|
|
1296
1124
|
"div",
|
|
1297
1125
|
{
|
|
1298
1126
|
style: {
|
|
1299
1127
|
display: "flex",
|
|
1300
1128
|
justifyContent: "space-between",
|
|
1301
1129
|
fontSize: 12,
|
|
1302
|
-
color:
|
|
1130
|
+
color: o.text.secondary,
|
|
1303
1131
|
marginBottom: 6
|
|
1304
1132
|
},
|
|
1305
1133
|
children: [
|
|
1306
|
-
/* @__PURE__ */
|
|
1307
|
-
/* @__PURE__ */
|
|
1134
|
+
/* @__PURE__ */ s("span", { children: r }),
|
|
1135
|
+
/* @__PURE__ */ s("span", { children: n })
|
|
1308
1136
|
]
|
|
1309
1137
|
}
|
|
1310
1138
|
),
|
|
1311
|
-
/* @__PURE__ */
|
|
1312
|
-
e.map((
|
|
1313
|
-
const
|
|
1314
|
-
return /* @__PURE__ */
|
|
1139
|
+
/* @__PURE__ */ p("div", { style: { display: "flex", gap: 2, height: 8 }, children: [
|
|
1140
|
+
e.map((c, f) => {
|
|
1141
|
+
const m = Number.isFinite(c.value) && c.value > 0 ? c.value : 0, x = o.category[c.color ?? tt[f % tt.length]];
|
|
1142
|
+
return /* @__PURE__ */ s(
|
|
1315
1143
|
"div",
|
|
1316
1144
|
{
|
|
1317
1145
|
style: {
|
|
1318
|
-
width: `${
|
|
1146
|
+
width: `${m / l * 100}%`,
|
|
1319
1147
|
background: x,
|
|
1320
1148
|
borderRadius: 3
|
|
1321
1149
|
}
|
|
1322
1150
|
},
|
|
1323
|
-
|
|
1151
|
+
c.id
|
|
1324
1152
|
);
|
|
1325
1153
|
}),
|
|
1326
|
-
d > 0 && /* @__PURE__ */
|
|
1154
|
+
d > 0 && /* @__PURE__ */ s(
|
|
1327
1155
|
"div",
|
|
1328
1156
|
{
|
|
1329
1157
|
style: {
|
|
1330
1158
|
width: `${d / l * 100}%`,
|
|
1331
|
-
background:
|
|
1159
|
+
background: o.fill.tertiary,
|
|
1332
1160
|
borderRadius: 3
|
|
1333
1161
|
}
|
|
1334
1162
|
}
|
|
@@ -1336,21 +1164,21 @@ function Gt({
|
|
|
1336
1164
|
] })
|
|
1337
1165
|
] });
|
|
1338
1166
|
}
|
|
1339
|
-
function
|
|
1167
|
+
function $e({
|
|
1340
1168
|
title: e,
|
|
1341
1169
|
leading: t,
|
|
1342
1170
|
count: r,
|
|
1343
|
-
trailing:
|
|
1344
|
-
children:
|
|
1345
|
-
defaultOpen:
|
|
1171
|
+
trailing: n,
|
|
1172
|
+
children: i,
|
|
1173
|
+
defaultOpen: o = !1,
|
|
1346
1174
|
style: l
|
|
1347
1175
|
}) {
|
|
1348
|
-
const u =
|
|
1349
|
-
return /* @__PURE__ */
|
|
1350
|
-
/* @__PURE__ */
|
|
1176
|
+
const u = y(), [d, c] = I(o);
|
|
1177
|
+
return /* @__PURE__ */ p("div", { style: l, children: [
|
|
1178
|
+
/* @__PURE__ */ p(
|
|
1351
1179
|
"div",
|
|
1352
1180
|
{
|
|
1353
|
-
onClick: () =>
|
|
1181
|
+
onClick: () => c((f) => !f),
|
|
1354
1182
|
style: {
|
|
1355
1183
|
display: "flex",
|
|
1356
1184
|
alignItems: "center",
|
|
@@ -1362,70 +1190,71 @@ function jt({
|
|
|
1362
1190
|
fontSize: 14
|
|
1363
1191
|
},
|
|
1364
1192
|
children: [
|
|
1365
|
-
/* @__PURE__ */
|
|
1193
|
+
/* @__PURE__ */ s(ct, { expanded: d }),
|
|
1366
1194
|
t,
|
|
1367
|
-
/* @__PURE__ */
|
|
1368
|
-
r != null && /* @__PURE__ */
|
|
1369
|
-
/* @__PURE__ */
|
|
1370
|
-
|
|
1195
|
+
/* @__PURE__ */ s("span", { style: { fontWeight: 500 }, children: e }),
|
|
1196
|
+
r != null && /* @__PURE__ */ s("span", { style: { color: u.text.tertiary, fontSize: 12 }, children: r }),
|
|
1197
|
+
/* @__PURE__ */ s("span", { style: { flex: 1 } }),
|
|
1198
|
+
n != null && /* @__PURE__ */ s("span", { style: { color: u.text.tertiary }, children: n })
|
|
1371
1199
|
]
|
|
1372
1200
|
}
|
|
1373
1201
|
),
|
|
1374
|
-
d && /* @__PURE__ */
|
|
1202
|
+
d && /* @__PURE__ */ s("div", { style: { paddingLeft: 18, paddingBottom: 4 }, children: i })
|
|
1375
1203
|
] });
|
|
1376
1204
|
}
|
|
1377
1205
|
export {
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1206
|
+
Vt as BarChart,
|
|
1207
|
+
ke as Button,
|
|
1208
|
+
ve as Callout,
|
|
1209
|
+
pe as Card,
|
|
1210
|
+
ge as CardBody,
|
|
1211
|
+
ye as CardHeader,
|
|
1212
|
+
Ce as Checkbox,
|
|
1213
|
+
se as Code,
|
|
1214
|
+
$e as CollapsibleSection,
|
|
1215
|
+
Ut as DiffStats,
|
|
1216
|
+
Zt as DiffView,
|
|
1217
|
+
he as Divider,
|
|
1218
|
+
fe as Grid,
|
|
1219
|
+
ne as H1,
|
|
1220
|
+
oe as H2,
|
|
1221
|
+
ae as H3,
|
|
1222
|
+
Se as IconButton,
|
|
1223
|
+
qt as LineChart,
|
|
1224
|
+
ce as Link,
|
|
1225
|
+
Yt as PieChart,
|
|
1226
|
+
xe as Pill,
|
|
1227
|
+
de as Row,
|
|
1228
|
+
we as Select,
|
|
1229
|
+
ue as Spacer,
|
|
1230
|
+
le as Stack,
|
|
1231
|
+
me as Stat,
|
|
1232
|
+
Be as Swatch,
|
|
1233
|
+
be as Table,
|
|
1234
|
+
ie as Text,
|
|
1235
|
+
Me as TextArea,
|
|
1236
|
+
Le as TextInput,
|
|
1237
|
+
Ht as TodoList,
|
|
1238
|
+
Qt as TodoListCard,
|
|
1239
|
+
Te as Toggle,
|
|
1240
|
+
Fe as UsageBar,
|
|
1241
|
+
He as canvasPaletteDark,
|
|
1242
|
+
Ee as canvasPaletteGrokDark,
|
|
1243
|
+
je as canvasPaletteGrokLight,
|
|
1244
|
+
Ge as canvasPaletteLight,
|
|
1245
|
+
Ne as canvasTokens,
|
|
1246
|
+
Oe as canvasTokensLight,
|
|
1247
|
+
_e as categoryPaletteDark,
|
|
1248
|
+
Ke as categoryPaletteLight,
|
|
1249
|
+
Xe as colorPalette,
|
|
1250
|
+
Jt as computeDAGLayout,
|
|
1251
|
+
re as mergeStyle,
|
|
1252
|
+
tt as usageColorSequence,
|
|
1253
|
+
ee as useCanvasAction,
|
|
1254
|
+
te as useCanvasState,
|
|
1255
|
+
Ae as useEffect,
|
|
1256
|
+
y as useHostTheme,
|
|
1257
|
+
Ie as useMemo,
|
|
1258
|
+
Pe as useRef,
|
|
1259
|
+
Re as useState
|
|
1431
1260
|
};
|