@leonardaustin/ui 0.17.0 → 0.18.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.
|
@@ -24,10 +24,12 @@ export interface SideSheetProps {
|
|
|
24
24
|
* sheet is never wider than the viewport minus 2rem.
|
|
25
25
|
*/
|
|
26
26
|
widthClassName?: string;
|
|
27
|
+
/** Enable pointer and keyboard resizing at viewport widths of 640px and up. Defaults to `false`. */
|
|
28
|
+
resizable?: boolean;
|
|
27
29
|
/** Additional utility classes for the sheet panel. */
|
|
28
30
|
className?: string;
|
|
29
31
|
/** Additional utility classes for the scrolling body. */
|
|
30
32
|
contentClassName?: string;
|
|
31
33
|
}
|
|
32
|
-
export declare function SideSheet({ open, onClose, title, children, footer, side, widthClassName, className, contentClassName, }: SideSheetProps): import("react").ReactPortal | null;
|
|
34
|
+
export declare function SideSheet({ open, onClose, title, children, footer, side, widthClassName, resizable, className, contentClassName, }: SideSheetProps): import("react").ReactPortal | null;
|
|
33
35
|
//# sourceMappingURL=SideSheet.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SideSheet.d.ts","sourceRoot":"","sources":["../../../src/components/ui/SideSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"SideSheet.d.ts","sourceRoot":"","sources":["../../../src/components/ui/SideSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAmBf,MAAM,WAAW,cAAc;IAC7B,mEAAmE;IACnE,IAAI,EAAE,OAAO,CAAC;IACd;;;;OAIG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,gEAAgE;IAChE,QAAQ,EAAE,SAAS,CAAC;IACpB,6EAA6E;IAC7E,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,0DAA0D;IAC1D,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IACxB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oGAAoG;IACpG,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,sDAAsD;IACtD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,yDAAyD;IACzD,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,wBAAgB,SAAS,CAAC,EACxB,IAAI,EACJ,OAAO,EACP,KAAK,EACL,QAAQ,EACR,MAAM,EACN,IAAc,EACd,cAA4B,EAC5B,SAAiB,EACjB,SAAS,EACT,gBAAgB,GACjB,EAAE,cAAc,sCAwFhB"}
|
package/dist/index.js
CHANGED
|
@@ -10267,29 +10267,30 @@ function oc({ label: e, description: t, action: n, className: r }) {
|
|
|
10267
10267
|
}
|
|
10268
10268
|
//#endregion
|
|
10269
10269
|
//#region src/components/ui/SideSheet.tsx
|
|
10270
|
-
function sc({ open: e, onClose: t, title: n, children: r, footer: i, side: a = "right", widthClassName: o = "w-[360px]",
|
|
10271
|
-
let
|
|
10272
|
-
gt(
|
|
10273
|
-
let
|
|
10270
|
+
function sc({ open: e, onClose: t, title: n, children: r, footer: i, side: a = "right", widthClassName: o = "w-[360px]", resizable: s = !1, className: c, contentClassName: l }) {
|
|
10271
|
+
let d = u(), f = Wn(), p = m(null), [h, g] = Ft(p);
|
|
10272
|
+
gt(p, e);
|
|
10273
|
+
let y = Tt(e, () => t());
|
|
10274
10274
|
return Et(e), e ? q(/* @__PURE__ */ _(wt.Provider, {
|
|
10275
|
-
value:
|
|
10275
|
+
value: y,
|
|
10276
10276
|
children: /* @__PURE__ */ _(Nt.Provider, {
|
|
10277
|
-
value:
|
|
10277
|
+
value: h,
|
|
10278
10278
|
children: /* @__PURE__ */ v("div", {
|
|
10279
10279
|
className: "fixed inset-0 z-50",
|
|
10280
10280
|
children: [/* @__PURE__ */ _("div", {
|
|
10281
10281
|
className: "bg-bg-overlay animate-fade-in absolute inset-0",
|
|
10282
10282
|
onClick: t
|
|
10283
10283
|
}), /* @__PURE__ */ v("div", {
|
|
10284
|
-
ref:
|
|
10285
|
-
|
|
10284
|
+
ref: g,
|
|
10285
|
+
id: s ? d : void 0,
|
|
10286
|
+
className: J("bg-bg-secondary border-border absolute inset-y-0 flex flex-col shadow-lg", o, a === "right" ? "animate-slide-in-right right-0 border-l" : "animate-slide-in-left left-0 border-r", c),
|
|
10286
10287
|
style: { maxWidth: "calc(100vw - 2rem)" },
|
|
10287
10288
|
role: "dialog",
|
|
10288
10289
|
"aria-modal": "true",
|
|
10289
10290
|
"aria-label": typeof n == "string" ? n : "Panel",
|
|
10290
10291
|
children: [
|
|
10291
10292
|
/* @__PURE__ */ v("div", {
|
|
10292
|
-
"data-control-size":
|
|
10293
|
+
"data-control-size": f,
|
|
10293
10294
|
className: "ui-bar border-border flex shrink-0 items-center justify-between gap-2 border-b px-3 py-2.5",
|
|
10294
10295
|
children: [n && /* @__PURE__ */ _("h3", {
|
|
10295
10296
|
className: "text-text-primary truncate text-sm font-medium",
|
|
@@ -10305,13 +10306,17 @@ function sc({ open: e, onClose: t, title: n, children: r, footer: i, side: a = "
|
|
|
10305
10306
|
})]
|
|
10306
10307
|
}),
|
|
10307
10308
|
/* @__PURE__ */ _("div", {
|
|
10308
|
-
className: J("ui-surface-body flex-1 overflow-y-auto p-3",
|
|
10309
|
+
className: J("ui-surface-body flex-1 overflow-y-auto p-3", l),
|
|
10309
10310
|
children: r
|
|
10310
10311
|
}),
|
|
10311
10312
|
i && /* @__PURE__ */ _("div", {
|
|
10312
|
-
"data-control-size":
|
|
10313
|
+
"data-control-size": f,
|
|
10313
10314
|
className: "ui-bar border-border bg-bg-primary/50 flex shrink-0 items-center gap-2 border-t px-3 py-2.5",
|
|
10314
10315
|
children: i
|
|
10316
|
+
}),
|
|
10317
|
+
s && h && /* @__PURE__ */ _(fc, {
|
|
10318
|
+
sheet: h,
|
|
10319
|
+
side: a
|
|
10315
10320
|
})
|
|
10316
10321
|
]
|
|
10317
10322
|
})]
|
|
@@ -10319,28 +10324,122 @@ function sc({ open: e, onClose: t, title: n, children: r, footer: i, side: a = "
|
|
|
10319
10324
|
})
|
|
10320
10325
|
}), document.body) : null;
|
|
10321
10326
|
}
|
|
10327
|
+
function cc(e, t) {
|
|
10328
|
+
e.style.width = t === null ? "" : `${t}px`;
|
|
10329
|
+
}
|
|
10330
|
+
function lc(e) {
|
|
10331
|
+
let t = e.ownerDocument.body, n = t.style.userSelect, r = t.style.cursor;
|
|
10332
|
+
return t.style.userSelect = "none", t.style.cursor = "col-resize", () => {
|
|
10333
|
+
t.style.userSelect = n, t.style.cursor = r;
|
|
10334
|
+
};
|
|
10335
|
+
}
|
|
10336
|
+
function uc(e) {
|
|
10337
|
+
let t = e.style.width;
|
|
10338
|
+
cc(e, null);
|
|
10339
|
+
let n = e.getBoundingClientRect().width;
|
|
10340
|
+
return e.style.width = t, n;
|
|
10341
|
+
}
|
|
10342
|
+
function dc(e) {
|
|
10343
|
+
let t = e.ownerDocument.defaultView, n = parseFloat(t.getComputedStyle(e.ownerDocument.documentElement).fontSize);
|
|
10344
|
+
return Math.max(0, t.innerWidth - 2 * n);
|
|
10345
|
+
}
|
|
10346
|
+
function fc({ sheet: e, side: t }) {
|
|
10347
|
+
let n = e.ownerDocument.defaultView, [r, i] = h(() => ({
|
|
10348
|
+
width: e.getBoundingClientRect().width,
|
|
10349
|
+
min: e.getBoundingClientRect().width,
|
|
10350
|
+
max: dc(e),
|
|
10351
|
+
desktop: n.innerWidth >= 640
|
|
10352
|
+
})), a = m(null), o = m(null), c = m(null);
|
|
10353
|
+
function u() {
|
|
10354
|
+
o.current = null, c.current?.(), c.current = null;
|
|
10355
|
+
}
|
|
10356
|
+
let d = s((t) => {
|
|
10357
|
+
let r = dc(e), o = Math.min(uc(e), r), s = n.innerWidth >= 640;
|
|
10358
|
+
a.current = s && t !== null ? Math.min(r, Math.max(o, t)) : null, a.current !== null && a.current <= o && (a.current = null), cc(e, a.current), i({
|
|
10359
|
+
width: e.getBoundingClientRect().width,
|
|
10360
|
+
min: o,
|
|
10361
|
+
max: r,
|
|
10362
|
+
desktop: s
|
|
10363
|
+
});
|
|
10364
|
+
}, [e, n]);
|
|
10365
|
+
return l(() => {
|
|
10366
|
+
let t = () => {
|
|
10367
|
+
u(), d(a.current);
|
|
10368
|
+
}, r = new ResizeObserver(() => d(a.current));
|
|
10369
|
+
return r.observe(e), n.addEventListener("resize", t), () => {
|
|
10370
|
+
r.disconnect(), n.removeEventListener("resize", t), u(), cc(e, null);
|
|
10371
|
+
};
|
|
10372
|
+
}, [
|
|
10373
|
+
d,
|
|
10374
|
+
e,
|
|
10375
|
+
n
|
|
10376
|
+
]), r.desktop ? /* @__PURE__ */ _("div", {
|
|
10377
|
+
role: "separator",
|
|
10378
|
+
tabIndex: 0,
|
|
10379
|
+
"aria-orientation": "vertical",
|
|
10380
|
+
"aria-label": "Resize panel",
|
|
10381
|
+
"aria-controls": e.id,
|
|
10382
|
+
"aria-valuenow": Math.round(r.width),
|
|
10383
|
+
"aria-valuemin": Math.round(r.min),
|
|
10384
|
+
"aria-valuemax": Math.round(r.max),
|
|
10385
|
+
className: J("hover:bg-accent/30 active:bg-accent/50 focus-visible:outline-accent absolute inset-y-0 z-10 w-1 cursor-col-resize select-none focus-visible:outline-2 focus-visible:outline-offset-0", t === "right" ? "left-0" : "right-0"),
|
|
10386
|
+
style: { touchAction: "none" },
|
|
10387
|
+
onPointerDown: (t) => {
|
|
10388
|
+
if (!t.isPrimary || t.button !== 0 || o.current) return;
|
|
10389
|
+
t.preventDefault(), t.currentTarget.focus(), t.currentTarget.setPointerCapture(t.pointerId);
|
|
10390
|
+
let n = uc(e);
|
|
10391
|
+
o.current = {
|
|
10392
|
+
pointerId: t.pointerId,
|
|
10393
|
+
x: t.clientX,
|
|
10394
|
+
width: a.current ?? n
|
|
10395
|
+
}, c.current = lc(e);
|
|
10396
|
+
},
|
|
10397
|
+
onPointerMove: (e) => {
|
|
10398
|
+
let n = o.current;
|
|
10399
|
+
!n || n.pointerId !== e.pointerId || d(n.width + (e.clientX - n.x) * (t === "right" ? -1 : 1));
|
|
10400
|
+
},
|
|
10401
|
+
onPointerUp: (e) => {
|
|
10402
|
+
o.current?.pointerId === e.pointerId && (u(), e.currentTarget.releasePointerCapture(e.pointerId));
|
|
10403
|
+
},
|
|
10404
|
+
onPointerCancel: (e) => {
|
|
10405
|
+
o.current?.pointerId === e.pointerId && u();
|
|
10406
|
+
},
|
|
10407
|
+
onLostPointerCapture: u,
|
|
10408
|
+
onDoubleClick: () => d(null),
|
|
10409
|
+
onKeyDown: (n) => {
|
|
10410
|
+
let r;
|
|
10411
|
+
if (n.key === "Home") r = null;
|
|
10412
|
+
else if (n.key === "End") r = Infinity;
|
|
10413
|
+
else if (n.key === "ArrowLeft" || n.key === "ArrowRight") {
|
|
10414
|
+
let i = n.key === "ArrowLeft" == (t === "right");
|
|
10415
|
+
r = (a.current ?? uc(e)) + (i ? 16 : -16);
|
|
10416
|
+
} else return;
|
|
10417
|
+
n.preventDefault(), d(r);
|
|
10418
|
+
}
|
|
10419
|
+
}) : null;
|
|
10420
|
+
}
|
|
10322
10421
|
//#endregion
|
|
10323
10422
|
//#region src/components/ui/SplitPaneLayout.tsx
|
|
10324
|
-
function
|
|
10423
|
+
function pc({ children: e, direction: t = "row", className: n }) {
|
|
10325
10424
|
return /* @__PURE__ */ _("div", {
|
|
10326
10425
|
className: J("-m-4 md:-m-6", "flex h-[calc(100vh-var(--topbar-height)-var(--bottomnav-height))] gap-0 md:h-[calc(100vh-var(--topbar-height))]", t === "column" && "flex-col", n),
|
|
10327
10426
|
children: e
|
|
10328
10427
|
});
|
|
10329
10428
|
}
|
|
10330
|
-
function
|
|
10429
|
+
function mc({ children: e, className: t }) {
|
|
10331
10430
|
return /* @__PURE__ */ _("div", {
|
|
10332
10431
|
className: J("flex min-h-0 min-w-0 flex-1 flex-col overflow-hidden", t),
|
|
10333
10432
|
children: e
|
|
10334
10433
|
});
|
|
10335
10434
|
}
|
|
10336
|
-
var
|
|
10435
|
+
var hc = Object.assign(pc, { Main: mc }), gc = {
|
|
10337
10436
|
active: "success",
|
|
10338
10437
|
inactive: "neutral",
|
|
10339
10438
|
pending: "warning",
|
|
10340
10439
|
error: "danger"
|
|
10341
10440
|
};
|
|
10342
|
-
function
|
|
10343
|
-
let r = Cn(
|
|
10441
|
+
function _c({ status: e, label: t, className: n }) {
|
|
10442
|
+
let r = Cn(gc[e]);
|
|
10344
10443
|
return /* @__PURE__ */ v("span", {
|
|
10345
10444
|
className: J("inline-flex items-center gap-1.5", n),
|
|
10346
10445
|
children: [/* @__PURE__ */ _("span", { className: J("h-2 w-2 rounded-full", r.dot, e === "pending" && "animate-pulse-subtle") }), t && /* @__PURE__ */ _("span", {
|
|
@@ -10351,7 +10450,7 @@ function fc({ status: e, label: t, className: n }) {
|
|
|
10351
10450
|
}
|
|
10352
10451
|
//#endregion
|
|
10353
10452
|
//#region src/components/ui/StepProgress.tsx
|
|
10354
|
-
function
|
|
10453
|
+
function vc({ steps: e, currentStep: t, className: n }) {
|
|
10355
10454
|
return /* @__PURE__ */ _("div", {
|
|
10356
10455
|
className: J("flex items-center justify-between", n),
|
|
10357
10456
|
children: e.map((n, r) => /* @__PURE__ */ v("div", {
|
|
@@ -10378,7 +10477,7 @@ function pc({ steps: e, currentStep: t, className: n }) {
|
|
|
10378
10477
|
}
|
|
10379
10478
|
//#endregion
|
|
10380
10479
|
//#region src/components/ui/Tabs.tsx
|
|
10381
|
-
function
|
|
10480
|
+
function yc({ tabs: e, defaultTab: t, value: n, onChange: r, className: i }) {
|
|
10382
10481
|
let [a, o] = h(t || e[0]?.key), s = n ?? a, c = e.some((e) => e.key === s) ? s : e[0]?.key, l = e.find((e) => e.key === c);
|
|
10383
10482
|
function d(e) {
|
|
10384
10483
|
n === void 0 && o(e), r?.(e);
|
|
@@ -10417,7 +10516,7 @@ function mc({ tabs: e, defaultTab: t, value: n, onChange: r, className: i }) {
|
|
|
10417
10516
|
}
|
|
10418
10517
|
//#endregion
|
|
10419
10518
|
//#region src/components/ui/Textarea.tsx
|
|
10420
|
-
var
|
|
10519
|
+
var bc = a(({ label: e, error: t, showCount: n, maxLength: r, value: i, className: a, id: o, hint: s, controlSize: c, required: l, "aria-describedby": u, "aria-invalid": d, ...f }, p) => {
|
|
10421
10520
|
let m = Ds({
|
|
10422
10521
|
id: o,
|
|
10423
10522
|
error: t,
|
|
@@ -10469,10 +10568,10 @@ var hc = a(({ label: e, error: t, showCount: n, maxLength: r, value: i, classNam
|
|
|
10469
10568
|
]
|
|
10470
10569
|
});
|
|
10471
10570
|
});
|
|
10472
|
-
|
|
10571
|
+
bc.displayName = "Textarea";
|
|
10473
10572
|
//#endregion
|
|
10474
10573
|
//#region src/components/ui/TextInput.tsx
|
|
10475
|
-
var
|
|
10574
|
+
var xc = a(({ label: e, error: t, icon: n, className: r, id: i, readOnly: a, hint: o, controlSize: s, required: c, "aria-describedby": l, "aria-invalid": u, ...d }, f) => {
|
|
10476
10575
|
let p = Ds({
|
|
10477
10576
|
id: i,
|
|
10478
10577
|
error: t,
|
|
@@ -10522,10 +10621,10 @@ var gc = a(({ label: e, error: t, icon: n, className: r, id: i, readOnly: a, hin
|
|
|
10522
10621
|
]
|
|
10523
10622
|
});
|
|
10524
10623
|
});
|
|
10525
|
-
|
|
10624
|
+
xc.displayName = "TextInput";
|
|
10526
10625
|
//#endregion
|
|
10527
10626
|
//#region src/components/ui/Timeline.tsx
|
|
10528
|
-
function
|
|
10627
|
+
function Sc({ items: e, className: t }) {
|
|
10529
10628
|
return /* @__PURE__ */ _("div", {
|
|
10530
10629
|
className: J("space-y-0", t),
|
|
10531
10630
|
children: e.map((t, n) => /* @__PURE__ */ v("div", {
|
|
@@ -10548,13 +10647,13 @@ function _c({ items: e, className: t }) {
|
|
|
10548
10647
|
}
|
|
10549
10648
|
//#endregion
|
|
10550
10649
|
//#region src/components/ui/Tooltip.tsx
|
|
10551
|
-
var
|
|
10650
|
+
var Cc = {
|
|
10552
10651
|
top: "bottom-full left-1/2 -translate-x-1/2 mb-2",
|
|
10553
10652
|
bottom: "top-full left-1/2 -translate-x-1/2 mt-2",
|
|
10554
10653
|
left: "right-full top-1/2 -translate-y-1/2 mr-2",
|
|
10555
10654
|
right: "left-full top-1/2 -translate-y-1/2 ml-2"
|
|
10556
10655
|
};
|
|
10557
|
-
function
|
|
10656
|
+
function wc(e, t) {
|
|
10558
10657
|
if (typeof e == "function") {
|
|
10559
10658
|
let n = e(t);
|
|
10560
10659
|
return typeof n == "function" ? n : () => e(null);
|
|
@@ -10563,7 +10662,7 @@ function yc(e, t) {
|
|
|
10563
10662
|
e && (e.current = null);
|
|
10564
10663
|
};
|
|
10565
10664
|
}
|
|
10566
|
-
function
|
|
10665
|
+
function Tc(e, t) {
|
|
10567
10666
|
let n = { ...e };
|
|
10568
10667
|
for (let [r, i] of Object.entries(t)) {
|
|
10569
10668
|
if (i === void 0) continue;
|
|
@@ -10581,14 +10680,14 @@ function bc(e, t) {
|
|
|
10581
10680
|
}
|
|
10582
10681
|
return n;
|
|
10583
10682
|
}
|
|
10584
|
-
function
|
|
10683
|
+
function Ec({ element: e, merged: t, ...r }) {
|
|
10585
10684
|
return n(e, {
|
|
10586
10685
|
...t,
|
|
10587
10686
|
...r
|
|
10588
10687
|
});
|
|
10589
10688
|
}
|
|
10590
|
-
var
|
|
10591
|
-
function
|
|
10689
|
+
var Dc = (e, t) => t instanceof Node && e.contains(t);
|
|
10690
|
+
function Oc({ content: e, placement: n = "top", children: r, ref: i, ...a }) {
|
|
10592
10691
|
let [c, d] = h(!1), f = u();
|
|
10593
10692
|
l(() => {
|
|
10594
10693
|
if (!c) return;
|
|
@@ -10599,35 +10698,35 @@ function Cc({ content: e, placement: n = "top", children: r, ref: i, ...a }) {
|
|
|
10599
10698
|
}, [c]);
|
|
10600
10699
|
let p = o(r) && r.type !== t ? r : null, m = p?.props.ref, g = s((e) => {
|
|
10601
10700
|
if (!e) return;
|
|
10602
|
-
let t = [
|
|
10701
|
+
let t = [wc(m, e), wc(i, e)];
|
|
10603
10702
|
return () => t.forEach((e) => e());
|
|
10604
10703
|
}, [m, i]), y = {
|
|
10605
10704
|
onMouseOver: (e) => {
|
|
10606
10705
|
let { currentTarget: t, target: n, relatedTarget: r } = e;
|
|
10607
|
-
|
|
10706
|
+
Dc(t, n) && !Dc(t, r) && d(!0);
|
|
10608
10707
|
},
|
|
10609
10708
|
onMouseOut: (e) => {
|
|
10610
|
-
|
|
10709
|
+
Dc(e.currentTarget, e.relatedTarget) || d(!1);
|
|
10611
10710
|
},
|
|
10612
10711
|
onFocus: (e) => {
|
|
10613
|
-
d(
|
|
10712
|
+
d(Dc(e.currentTarget, e.target));
|
|
10614
10713
|
},
|
|
10615
10714
|
onBlur: () => d(!1)
|
|
10616
|
-
}, b = p ? /* @__PURE__ */ _(
|
|
10715
|
+
}, b = p ? /* @__PURE__ */ _(Ec, {
|
|
10617
10716
|
element: p,
|
|
10618
|
-
merged:
|
|
10717
|
+
merged: Tc(p.props, {
|
|
10619
10718
|
...a,
|
|
10620
10719
|
"aria-describedby": [a["aria-describedby"], f].filter(Boolean).join(" ")
|
|
10621
10720
|
}),
|
|
10622
10721
|
ref: g
|
|
10623
10722
|
}) : r;
|
|
10624
10723
|
return /* @__PURE__ */ v("div", {
|
|
10625
|
-
...p ? y :
|
|
10724
|
+
...p ? y : Tc(y, a),
|
|
10626
10725
|
ref: p ? void 0 : g,
|
|
10627
10726
|
className: J("relative inline-flex", !p && a.className),
|
|
10628
10727
|
children: [b, c && /* @__PURE__ */ _("div", {
|
|
10629
10728
|
id: f,
|
|
10630
|
-
className: J("text-2xs absolute z-50 px-2 py-1 font-medium whitespace-nowrap", "bg-bg-tertiary text-text-primary border-border rounded border shadow-md", "animate-fade-in pointer-events-none",
|
|
10729
|
+
className: J("text-2xs absolute z-50 px-2 py-1 font-medium whitespace-nowrap", "bg-bg-tertiary text-text-primary border-border rounded border shadow-md", "animate-fade-in pointer-events-none", Cc[n]),
|
|
10631
10730
|
role: "tooltip",
|
|
10632
10731
|
children: e
|
|
10633
10732
|
})]
|
|
@@ -10635,7 +10734,7 @@ function Cc({ content: e, placement: n = "top", children: r, ref: i, ...a }) {
|
|
|
10635
10734
|
}
|
|
10636
10735
|
//#endregion
|
|
10637
10736
|
//#region src/components/ui/Toolbar.tsx
|
|
10638
|
-
function
|
|
10737
|
+
function kc({ start: e, end: t, children: n, className: r, startClassName: i, endClassName: a }) {
|
|
10639
10738
|
return /* @__PURE__ */ v("div", {
|
|
10640
10739
|
className: J("flex items-center justify-between gap-3", r),
|
|
10641
10740
|
children: [/* @__PURE__ */ _("div", {
|
|
@@ -10649,7 +10748,7 @@ function wc({ start: e, end: t, children: n, className: r, startClassName: i, en
|
|
|
10649
10748
|
}
|
|
10650
10749
|
//#endregion
|
|
10651
10750
|
//#region src/components/ui/UploadDropzone.tsx
|
|
10652
|
-
var
|
|
10751
|
+
var Ac = a(function({ title: e = "Drag and drop files here, or click to browse", description: t, icon: n, multiple: r, disabled: i, onChange: a, onFilesChange: o, className: s, id: c, "aria-describedby": l, ...f }, p) {
|
|
10653
10752
|
let h = m(null);
|
|
10654
10753
|
d(p, () => h.current, []);
|
|
10655
10754
|
let g = u(), y = `${c ?? g}-description`;
|
|
@@ -10696,29 +10795,29 @@ var Tc = a(function({ title: e = "Drag and drop files here, or click to browse",
|
|
|
10696
10795
|
})
|
|
10697
10796
|
]
|
|
10698
10797
|
});
|
|
10699
|
-
}),
|
|
10798
|
+
}), jc = r({ theme: "dark" });
|
|
10700
10799
|
//#endregion
|
|
10701
10800
|
//#region src/hooks/useTheme.ts
|
|
10702
|
-
function
|
|
10703
|
-
return c(
|
|
10801
|
+
function Mc() {
|
|
10802
|
+
return c(jc);
|
|
10704
10803
|
}
|
|
10705
10804
|
//#endregion
|
|
10706
10805
|
//#region src/lib/formatDate.ts
|
|
10707
|
-
function
|
|
10806
|
+
function Nc(e) {
|
|
10708
10807
|
return (/* @__PURE__ */ new Date(e + "T00:00:00")).toLocaleDateString("en-US", {
|
|
10709
10808
|
month: "short",
|
|
10710
10809
|
day: "numeric",
|
|
10711
10810
|
year: "numeric"
|
|
10712
10811
|
});
|
|
10713
10812
|
}
|
|
10714
|
-
function
|
|
10813
|
+
function Pc(e) {
|
|
10715
10814
|
return (/* @__PURE__ */ new Date(e + "T00:00:00")).toLocaleDateString("en-US", {
|
|
10716
10815
|
month: "long",
|
|
10717
10816
|
day: "numeric",
|
|
10718
10817
|
year: "numeric"
|
|
10719
10818
|
});
|
|
10720
10819
|
}
|
|
10721
|
-
function
|
|
10820
|
+
function Fc(e, t = /* @__PURE__ */ new Date()) {
|
|
10722
10821
|
let n = t.getTime() - e.getTime(), r = Math.floor(n / 1e3);
|
|
10723
10822
|
if (r < 60) return "just now";
|
|
10724
10823
|
let i = Math.floor(r / 60);
|
|
@@ -10731,13 +10830,13 @@ function Ac(e, t = /* @__PURE__ */ new Date()) {
|
|
|
10731
10830
|
}
|
|
10732
10831
|
//#endregion
|
|
10733
10832
|
//#region src/providers/SettingsProvider.tsx
|
|
10734
|
-
var
|
|
10833
|
+
var Ic = {
|
|
10735
10834
|
"archivo-expanded": "\"Archivo\", \"Arial Black\", \"Avenir Next Condensed\", \"HelveticaNeue-CondensedBold\", system-ui, sans-serif",
|
|
10736
10835
|
inter: "\"Inter\", system-ui, -apple-system, BlinkMacSystemFont, sans-serif",
|
|
10737
10836
|
"jetbrains-mono": "\"JetBrains Mono\", Menlo, Monaco, Consolas, monospace",
|
|
10738
10837
|
"pt-serif": "\"PT Serif\", Georgia, ui-serif, Cambria, \"Times New Roman\", Times, serif",
|
|
10739
10838
|
system: "system-ui, -apple-system, BlinkMacSystemFont, sans-serif"
|
|
10740
|
-
},
|
|
10839
|
+
}, Lc = {
|
|
10741
10840
|
purple: {
|
|
10742
10841
|
base: "#7C5CFC",
|
|
10743
10842
|
hover: "#6B4AEB",
|
|
@@ -10794,43 +10893,43 @@ var jc = {
|
|
|
10794
10893
|
muted: "rgba(99,102,241,0.15)",
|
|
10795
10894
|
subtle: "rgba(99,102,241,0.08)"
|
|
10796
10895
|
}
|
|
10797
|
-
},
|
|
10896
|
+
}, Rc = "leonardaustin-ui-settings", zc = new Set(Object.keys(Lc)), Bc = new Set(Object.keys(Gt)), Vc = new Set(Object.keys(Ic)), Hc = new Set([
|
|
10798
10897
|
"light",
|
|
10799
10898
|
"dark",
|
|
10800
10899
|
"system"
|
|
10801
10900
|
]);
|
|
10802
|
-
function
|
|
10901
|
+
function Uc(e, t, n, r) {
|
|
10803
10902
|
return typeof e != "number" || !isFinite(e) ? r : Y(e, t, n);
|
|
10804
10903
|
}
|
|
10805
|
-
function
|
|
10904
|
+
function Wc(e) {
|
|
10806
10905
|
let t = {};
|
|
10807
|
-
if (
|
|
10906
|
+
if (zc.has(e.accentColor) && (t.accentColor = e.accentColor), Hc.has(e.colorMode) && (t.colorMode = e.colorMode), Bc.has(e.preferredDarkTheme) && !Bt(e.preferredDarkTheme) && (t.preferredDarkTheme = e.preferredDarkTheme), Bc.has(e.preferredLightTheme) && Bt(e.preferredLightTheme) && (t.preferredLightTheme = e.preferredLightTheme), typeof e.sidebarCollapsed == "boolean" && (t.sidebarCollapsed = e.sidebarCollapsed), typeof e.reducedMotion == "boolean" && (t.reducedMotion = e.reducedMotion), typeof e.sidebarWidth == "number" && (t.sidebarWidth = Uc(e.sidebarWidth, 160, 400, 220)), e.themeOverrides && typeof e.themeOverrides == "object") {
|
|
10808
10907
|
let n = {};
|
|
10809
10908
|
for (let [t, r] of Object.entries(e.themeOverrides)) {
|
|
10810
|
-
if (!
|
|
10909
|
+
if (!Bc.has(t) || !r || typeof r != "object") continue;
|
|
10811
10910
|
let e = r, i = Gt[t];
|
|
10812
10911
|
n[t] = {
|
|
10813
|
-
uiFont:
|
|
10814
|
-
headingFont:
|
|
10815
|
-
proseFont:
|
|
10816
|
-
controlFont:
|
|
10817
|
-
labelFont:
|
|
10818
|
-
navigationFont:
|
|
10819
|
-
dataFont:
|
|
10820
|
-
codeFont:
|
|
10821
|
-
fontSize:
|
|
10822
|
-
borderRadius:
|
|
10823
|
-
borderWidth:
|
|
10824
|
-
tracking:
|
|
10825
|
-
lineHeight:
|
|
10826
|
-
density:
|
|
10912
|
+
uiFont: Vc.has(e.uiFont) ? e.uiFont : i.uiFont,
|
|
10913
|
+
headingFont: Vc.has(e.headingFont) ? e.headingFont : i.headingFont,
|
|
10914
|
+
proseFont: Vc.has(e.proseFont) ? e.proseFont : i.proseFont,
|
|
10915
|
+
controlFont: Vc.has(e.controlFont) ? e.controlFont : i.controlFont,
|
|
10916
|
+
labelFont: Vc.has(e.labelFont) ? e.labelFont : i.labelFont,
|
|
10917
|
+
navigationFont: Vc.has(e.navigationFont) ? e.navigationFont : i.navigationFont,
|
|
10918
|
+
dataFont: Vc.has(e.dataFont) ? e.dataFont : i.dataFont,
|
|
10919
|
+
codeFont: Vc.has(e.codeFont) ? e.codeFont : i.codeFont,
|
|
10920
|
+
fontSize: Uc(e.fontSize, 11, 18, i.fontSize),
|
|
10921
|
+
borderRadius: Uc(e.borderRadius, 0, 16, i.borderRadius),
|
|
10922
|
+
borderWidth: Uc(e.borderWidth, 1, 3, i.borderWidth),
|
|
10923
|
+
tracking: Uc(e.tracking, 0, .3, i.tracking),
|
|
10924
|
+
lineHeight: Uc(e.lineHeight, 1.2, 2, i.lineHeight),
|
|
10925
|
+
density: Uc(e.density, .18, .32, i.density)
|
|
10827
10926
|
};
|
|
10828
10927
|
}
|
|
10829
10928
|
t.themeOverrides = n;
|
|
10830
10929
|
}
|
|
10831
10930
|
return t;
|
|
10832
10931
|
}
|
|
10833
|
-
var
|
|
10932
|
+
var Gc = {
|
|
10834
10933
|
accentColor: "purple",
|
|
10835
10934
|
sidebarCollapsed: !1,
|
|
10836
10935
|
sidebarWidth: 220,
|
|
@@ -10840,35 +10939,35 @@ var Bc = {
|
|
|
10840
10939
|
preferredLightTheme: "light",
|
|
10841
10940
|
themeOverrides: {}
|
|
10842
10941
|
};
|
|
10843
|
-
function
|
|
10942
|
+
function Kc(e, t) {
|
|
10844
10943
|
let n = {
|
|
10845
|
-
...
|
|
10846
|
-
...
|
|
10944
|
+
...Gc,
|
|
10945
|
+
...Wc(t ?? {})
|
|
10847
10946
|
};
|
|
10848
10947
|
if (typeof localStorage > "u") return n;
|
|
10849
10948
|
try {
|
|
10850
10949
|
let t = localStorage.getItem(e);
|
|
10851
10950
|
if (t) return {
|
|
10852
10951
|
...n,
|
|
10853
|
-
...
|
|
10952
|
+
...Wc(JSON.parse(t))
|
|
10854
10953
|
};
|
|
10855
10954
|
} catch (e) {
|
|
10856
10955
|
console.warn("[SettingsProvider] Failed to load settings:", e);
|
|
10857
10956
|
}
|
|
10858
10957
|
return n;
|
|
10859
10958
|
}
|
|
10860
|
-
function
|
|
10959
|
+
function qc(e, t) {
|
|
10861
10960
|
let n = Gt[e] ?? Gt.dark;
|
|
10862
10961
|
return t[e] ? {
|
|
10863
10962
|
...n,
|
|
10864
10963
|
...t[e]
|
|
10865
10964
|
} : n;
|
|
10866
10965
|
}
|
|
10867
|
-
function
|
|
10966
|
+
function Jc(e, t) {
|
|
10868
10967
|
return e.uiFont === t.uiFont && e.headingFont === t.headingFont && e.proseFont === t.proseFont && e.controlFont === t.controlFont && e.labelFont === t.labelFont && e.navigationFont === t.navigationFont && e.dataFont === t.dataFont && e.codeFont === t.codeFont && e.fontSize === t.fontSize && e.borderRadius === t.borderRadius && e.borderWidth === t.borderWidth && e.tracking === t.tracking && e.lineHeight === t.lineHeight && e.density === t.density;
|
|
10869
10968
|
}
|
|
10870
|
-
function
|
|
10871
|
-
let [i, a] = h(() =>
|
|
10969
|
+
function Yc({ children: e, storageKey: t = Rc, initialSettings: n, forcedTheme: r }) {
|
|
10970
|
+
let [i, a] = h(() => Kc(t, n)), [o, c] = h(() => typeof window < "u" && window.matchMedia("(prefers-color-scheme: dark)").matches);
|
|
10872
10971
|
l(() => {
|
|
10873
10972
|
if (typeof window > "u") return;
|
|
10874
10973
|
let e = window.matchMedia("(prefers-color-scheme: dark)"), t = (e) => c(e.matches);
|
|
@@ -10880,9 +10979,9 @@ function Wc({ children: e, storageKey: t = Nc, initialSettings: n, forcedTheme:
|
|
|
10880
10979
|
i.preferredDarkTheme,
|
|
10881
10980
|
i.preferredLightTheme,
|
|
10882
10981
|
o
|
|
10883
|
-
]), [d, f] = h(() =>
|
|
10982
|
+
]), [d, f] = h(() => qc(u, i.themeOverrides));
|
|
10884
10983
|
l(() => {
|
|
10885
|
-
f(
|
|
10984
|
+
f(qc(u, i.themeOverrides));
|
|
10886
10985
|
}, [u]);
|
|
10887
10986
|
let m = s((e) => {
|
|
10888
10987
|
a((n) => {
|
|
@@ -10899,15 +10998,15 @@ function Wc({ children: e, storageKey: t = Nc, initialSettings: n, forcedTheme:
|
|
|
10899
10998
|
});
|
|
10900
10999
|
}, [t]);
|
|
10901
11000
|
l(() => {
|
|
10902
|
-
let e = document.documentElement, t =
|
|
11001
|
+
let e = document.documentElement, t = Lc[i.accentColor];
|
|
10903
11002
|
e.style.setProperty("--accent", t.base), e.style.setProperty("--accent-hover", t.hover), e.style.setProperty("--accent-active", t.active), e.style.setProperty("--accent-muted", t.muted), e.style.setProperty("--accent-subtle", t.subtle);
|
|
10904
11003
|
}, [i.accentColor]), l(() => {
|
|
10905
11004
|
document.documentElement.classList.toggle("reduced-motion", i.reducedMotion);
|
|
10906
11005
|
}, [i.reducedMotion]), l(() => {
|
|
10907
11006
|
let e = document.documentElement, t = d.borderRadius;
|
|
10908
|
-
e.style.fontSize = `${d.fontSize / 13 * 100}%`, e.style.setProperty("--font-ui",
|
|
11007
|
+
e.style.fontSize = `${d.fontSize / 13 * 100}%`, e.style.setProperty("--font-ui", Ic[d.uiFont]), e.style.setProperty("--font-heading", Ic[d.headingFont]), e.style.setProperty("--font-prose", Ic[d.proseFont]), e.style.setProperty("--font-control", Ic[d.controlFont]), e.style.setProperty("--font-label", Ic[d.labelFont]), e.style.setProperty("--font-navigation", Ic[d.navigationFont]), e.style.setProperty("--font-data", Ic[d.dataFont]), e.style.setProperty("--font-code", Ic[d.codeFont]), e.style.setProperty("--ui-radius", t === 0 ? "0" : `${Math.round(t * 2 / 3)}px`), e.style.setProperty("--ui-radius-md", t === 0 ? "0" : `${t}px`), e.style.setProperty("--ui-radius-lg", t === 0 ? "0" : `${Math.round(t * 4 / 3)}px`), e.style.setProperty("--ui-radius-xl", t === 0 ? "0" : `${t * 2}px`), e.style.setProperty("--ui-border-width", `${d.borderWidth}px`), e.style.setProperty("--ui-tracking", `${d.tracking}em`), e.style.setProperty("--ui-line-height", String(d.lineHeight)), e.style.setProperty("--ui-density", `${d.density}rem`);
|
|
10909
11008
|
}, [d]);
|
|
10910
|
-
let g = p(() =>
|
|
11009
|
+
let g = p(() => qc(u, i.themeOverrides), [u, i.themeOverrides]), v = u in i.themeOverrides, y = !Jc(d, g), b = s(() => {
|
|
10911
11010
|
m({ themeOverrides: {
|
|
10912
11011
|
...i.themeOverrides,
|
|
10913
11012
|
[u]: { ...d }
|
|
@@ -11031,7 +11130,7 @@ function Wc({ children: e, storageKey: t = Nc, initialSettings: n, forcedTheme:
|
|
|
11031
11130
|
}
|
|
11032
11131
|
//#endregion
|
|
11033
11132
|
//#region src/providers/ThemeProvider.tsx
|
|
11034
|
-
var
|
|
11133
|
+
var Xc = {
|
|
11035
11134
|
dark: "",
|
|
11036
11135
|
light: "theme-light",
|
|
11037
11136
|
lightInverted: "theme-light-inverted",
|
|
@@ -11041,23 +11140,23 @@ var Gc = {
|
|
|
11041
11140
|
cyberBrutalLight: "theme-cyber-brutal-light",
|
|
11042
11141
|
hashiTheme: "theme-hashi"
|
|
11043
11142
|
};
|
|
11044
|
-
function
|
|
11143
|
+
function Zc({ children: e }) {
|
|
11045
11144
|
let { resolvedTheme: t } = c(pn);
|
|
11046
11145
|
return l(() => {
|
|
11047
11146
|
let e = document.documentElement;
|
|
11048
|
-
Object.values(
|
|
11147
|
+
Object.values(Xc).forEach((t) => {
|
|
11049
11148
|
t && e.classList.remove(t);
|
|
11050
11149
|
});
|
|
11051
|
-
let n =
|
|
11150
|
+
let n = Xc[t];
|
|
11052
11151
|
n && e.classList.add(n);
|
|
11053
|
-
}, [t]), /* @__PURE__ */ _(
|
|
11152
|
+
}, [t]), /* @__PURE__ */ _(jc.Provider, {
|
|
11054
11153
|
value: { theme: t },
|
|
11055
11154
|
children: e
|
|
11056
11155
|
});
|
|
11057
11156
|
}
|
|
11058
11157
|
//#endregion
|
|
11059
11158
|
//#region src/components/ui/FormField.tsx
|
|
11060
|
-
function
|
|
11159
|
+
function Qc({ id: e, label: t, hint: n, error: r, required: i, optionalLabel: a, labelPlacement: o = "above", children: c, className: l, ...d }) {
|
|
11061
11160
|
let f = u(), p = e ?? f, m = n ? `${p}-hint` : void 0, g = r ? `${p}-error` : void 0, y = `${p}-label`, [b, x] = h(0), S = s(() => (x((e) => e + 1), () => x((e) => e - 1)), []), C = o === "placeholder" && typeof t == "string" && t ? t : void 0, w = {
|
|
11062
11161
|
id: p,
|
|
11063
11162
|
"aria-describedby": cr(m, g),
|
|
@@ -11106,13 +11205,13 @@ function qc({ id: e, label: t, hint: n, error: r, required: i, optionalLabel: a,
|
|
|
11106
11205
|
})
|
|
11107
11206
|
});
|
|
11108
11207
|
}
|
|
11109
|
-
function
|
|
11208
|
+
function $c({ className: e, ...t }) {
|
|
11110
11209
|
return /* @__PURE__ */ _("p", {
|
|
11111
11210
|
...t,
|
|
11112
11211
|
className: J("text-text-secondary text-xs", e)
|
|
11113
11212
|
});
|
|
11114
11213
|
}
|
|
11115
|
-
function
|
|
11214
|
+
function el({ className: e, ...t }) {
|
|
11116
11215
|
return /* @__PURE__ */ _("p", {
|
|
11117
11216
|
...t,
|
|
11118
11217
|
className: J("text-red text-xs", e)
|
|
@@ -11120,7 +11219,7 @@ function Yc({ className: e, ...t }) {
|
|
|
11120
11219
|
}
|
|
11121
11220
|
//#endregion
|
|
11122
11221
|
//#region src/components/ui/Fieldset.tsx
|
|
11123
|
-
function
|
|
11222
|
+
function tl({ id: e, legend: t, hint: n, error: r, children: i, className: a, "aria-describedby": o, ...s }) {
|
|
11124
11223
|
let c = u(), l = e ?? c, d = n ? `${l}-hint` : void 0, f = r ? `${l}-error` : void 0, p = cr(o, d, f);
|
|
11125
11224
|
return /* @__PURE__ */ v("fieldset", {
|
|
11126
11225
|
...s,
|
|
@@ -11154,7 +11253,7 @@ function Xc({ id: e, legend: t, hint: n, error: r, children: i, className: a, "a
|
|
|
11154
11253
|
}
|
|
11155
11254
|
//#endregion
|
|
11156
11255
|
//#region src/components/ui/Radio.tsx
|
|
11157
|
-
var
|
|
11256
|
+
var nl = a(({ label: e, description: t, controlSize: n, className: r, id: i, "aria-describedby": a, "aria-invalid": o, ...s }, l) => {
|
|
11158
11257
|
let d = u(), f = Wn(n), p = c(sr), m = i ?? p?.id ?? d, h = t ? `${m}-description` : void 0;
|
|
11159
11258
|
return /* @__PURE__ */ v("label", {
|
|
11160
11259
|
className: J("ui-choice flex items-start gap-2.5", r),
|
|
@@ -11177,14 +11276,14 @@ var Zc = a(({ label: e, description: t, controlSize: n, className: r, id: i, "ar
|
|
|
11177
11276
|
})]
|
|
11178
11277
|
});
|
|
11179
11278
|
});
|
|
11180
|
-
|
|
11181
|
-
function
|
|
11279
|
+
nl.displayName = "Radio";
|
|
11280
|
+
function rl({ name: e, id: t, options: n, value: r, onChange: i, required: a, disabled: o, controlSize: s, ...c }) {
|
|
11182
11281
|
let l = u(), d = t ?? l;
|
|
11183
|
-
return /* @__PURE__ */ _(
|
|
11282
|
+
return /* @__PURE__ */ _(tl, {
|
|
11184
11283
|
...c,
|
|
11185
11284
|
id: d,
|
|
11186
11285
|
disabled: o,
|
|
11187
|
-
children: n.map((t, n) => /* @__PURE__ */ _(
|
|
11286
|
+
children: n.map((t, n) => /* @__PURE__ */ _(nl, {
|
|
11188
11287
|
id: `${d}-${n}`,
|
|
11189
11288
|
name: e ?? d,
|
|
11190
11289
|
value: t.value,
|
|
@@ -11198,17 +11297,17 @@ function Qc({ name: e, id: t, options: n, value: r, onChange: i, required: a, di
|
|
|
11198
11297
|
}, t.value))
|
|
11199
11298
|
});
|
|
11200
11299
|
}
|
|
11201
|
-
var
|
|
11300
|
+
var il = Object.assign(nl, { Group: rl }), al = {
|
|
11202
11301
|
pending: "Pending",
|
|
11203
11302
|
uploading: "Uploading",
|
|
11204
11303
|
processing: "Processing",
|
|
11205
11304
|
ready: "Ready",
|
|
11206
11305
|
error: "Upload failed"
|
|
11207
11306
|
};
|
|
11208
|
-
function
|
|
11307
|
+
function ol(e) {
|
|
11209
11308
|
return e < 1024 ? `${e} B` : e < 1024 * 1024 ? `${(e / 1024).toFixed(1)} KB` : `${(e / (1024 * 1024)).toFixed(1)} MB`;
|
|
11210
11309
|
}
|
|
11211
|
-
function
|
|
11310
|
+
function sl({ name: e, size: t, status: n = "ready", statusLabel: r, error: i, onRetry: a, onRemove: o, onDownload: s, downloadHref: c, actionsDisabled: l, className: u, ...d }) {
|
|
11212
11311
|
return /* @__PURE__ */ v("li", {
|
|
11213
11312
|
...d,
|
|
11214
11313
|
className: J("ui-attachment-item border-border flex items-center justify-between gap-3 rounded-md border p-3", u),
|
|
@@ -11221,7 +11320,7 @@ function nl({ name: e, size: t, status: n = "ready", statusLabel: r, error: i, o
|
|
|
11221
11320
|
}),
|
|
11222
11321
|
t !== void 0 && /* @__PURE__ */ _("p", {
|
|
11223
11322
|
className: "text-text-tertiary text-2xs",
|
|
11224
|
-
children:
|
|
11323
|
+
children: ol(t)
|
|
11225
11324
|
}),
|
|
11226
11325
|
/* @__PURE__ */ v("div", {
|
|
11227
11326
|
role: "status",
|
|
@@ -11230,7 +11329,7 @@ function nl({ name: e, size: t, status: n = "ready", statusLabel: r, error: i, o
|
|
|
11230
11329
|
children: [
|
|
11231
11330
|
e,
|
|
11232
11331
|
": ",
|
|
11233
|
-
i ?? r ??
|
|
11332
|
+
i ?? r ?? al[n]
|
|
11234
11333
|
]
|
|
11235
11334
|
})
|
|
11236
11335
|
]
|
|
@@ -11272,7 +11371,7 @@ function nl({ name: e, size: t, status: n = "ready", statusLabel: r, error: i, o
|
|
|
11272
11371
|
})]
|
|
11273
11372
|
});
|
|
11274
11373
|
}
|
|
11275
|
-
function
|
|
11374
|
+
function cl({ children: e, className: t, "aria-label": n = "Attachments", ...r }) {
|
|
11276
11375
|
return /* @__PURE__ */ _("ul", {
|
|
11277
11376
|
...r,
|
|
11278
11377
|
"aria-label": n,
|
|
@@ -11282,7 +11381,7 @@ function rl({ children: e, className: t, "aria-label": n = "Attachments", ...r }
|
|
|
11282
11381
|
}
|
|
11283
11382
|
//#endregion
|
|
11284
11383
|
//#region src/lib/dateParts.ts
|
|
11285
|
-
function
|
|
11384
|
+
function ll(e, { required: t = !1, minYear: n = 1900, maxYear: r = 2100 } = {}) {
|
|
11286
11385
|
let i = [
|
|
11287
11386
|
e.day,
|
|
11288
11387
|
e.month,
|
|
@@ -11312,10 +11411,10 @@ function il(e, { required: t = !1, minYear: n = 1900, maxYear: r = 2100 } = {})
|
|
|
11312
11411
|
}
|
|
11313
11412
|
//#endregion
|
|
11314
11413
|
//#region src/components/ui/DatePartsInput.tsx
|
|
11315
|
-
function
|
|
11414
|
+
function ul({ value: e, onChange: t, label: n, hint: r, error: i, id: a, name: o, disabled: s, required: c, className: d, inputProps: f, minYear: p = 1900, maxYear: g = 2100 }) {
|
|
11316
11415
|
let y = u(), b = m({}), [x, S] = h(!1);
|
|
11317
11416
|
if (!Number.isInteger(p) || !Number.isInteger(g) || p < 1 || g > 9999 || p > g) throw RangeError("DatePartsInput requires year bounds between 1 and 9999, with minYear <= maxYear");
|
|
11318
|
-
let C =
|
|
11417
|
+
let C = ll(e, {
|
|
11319
11418
|
required: c,
|
|
11320
11419
|
minYear: p,
|
|
11321
11420
|
maxYear: g
|
|
@@ -11364,7 +11463,7 @@ function al({ value: e, onChange: t, label: n, hint: r, error: i, id: a, name: o
|
|
|
11364
11463
|
"year"
|
|
11365
11464
|
].map((n) => /* @__PURE__ */ v("div", {
|
|
11366
11465
|
className: "ui-date-part",
|
|
11367
|
-
children: [/* @__PURE__ */ _(
|
|
11466
|
+
children: [/* @__PURE__ */ _(xc, {
|
|
11368
11467
|
inputMode: "numeric",
|
|
11369
11468
|
"data-1p-ignore": "true",
|
|
11370
11469
|
...f?.[n],
|
|
@@ -11431,7 +11530,7 @@ function al({ value: e, onChange: t, label: n, hint: r, error: i, id: a, name: o
|
|
|
11431
11530
|
}
|
|
11432
11531
|
//#endregion
|
|
11433
11532
|
//#region src/components/ui/Skeleton.tsx
|
|
11434
|
-
function
|
|
11533
|
+
function dl({ className: e, width: t, height: n, style: r, ...i }) {
|
|
11435
11534
|
return /* @__PURE__ */ _("div", {
|
|
11436
11535
|
...i,
|
|
11437
11536
|
"aria-hidden": "true",
|
|
@@ -11445,7 +11544,7 @@ function ol({ className: e, width: t, height: n, style: r, ...i }) {
|
|
|
11445
11544
|
}
|
|
11446
11545
|
//#endregion
|
|
11447
11546
|
//#region src/components/ui/NavTabs.tsx
|
|
11448
|
-
function
|
|
11547
|
+
function fl({ items: e, activeKey: t, renderLink: n, className: r, "aria-label": i = "Sections", ...a }) {
|
|
11449
11548
|
return /* @__PURE__ */ _("nav", {
|
|
11450
11549
|
...a,
|
|
11451
11550
|
"aria-label": i,
|
|
@@ -11470,7 +11569,7 @@ function sl({ items: e, activeKey: t, renderLink: n, className: r, "aria-label":
|
|
|
11470
11569
|
}
|
|
11471
11570
|
//#endregion
|
|
11472
11571
|
//#region src/components/ui/CharacterCount.tsx
|
|
11473
|
-
function
|
|
11572
|
+
function pl({ value: e, maxLength: t, announcementDelay: n = 1e3, className: r, ...i }) {
|
|
11474
11573
|
let a = t - e.length, o = Math.abs(a), s = `${o} ${o === 1 ? "character" : "characters"} ${a < 0 ? "over the limit" : "remaining"}`, [c, u] = h(s);
|
|
11475
11574
|
return l(() => {
|
|
11476
11575
|
let e = setTimeout(() => u(s), n);
|
|
@@ -11492,7 +11591,7 @@ function cl({ value: e, maxLength: t, announcementDelay: n = 1e3, className: r,
|
|
|
11492
11591
|
}
|
|
11493
11592
|
//#endregion
|
|
11494
11593
|
//#region src/providers/ControlSizeProvider.tsx
|
|
11495
|
-
function
|
|
11594
|
+
function ml({ size: e, children: t }) {
|
|
11496
11595
|
return /* @__PURE__ */ _(Un.Provider, {
|
|
11497
11596
|
value: e,
|
|
11498
11597
|
children: t
|
|
@@ -11500,7 +11599,7 @@ function ll({ size: e, children: t }) {
|
|
|
11500
11599
|
}
|
|
11501
11600
|
//#endregion
|
|
11502
11601
|
//#region src/components/ui/ProgressBar.tsx
|
|
11503
|
-
var
|
|
11602
|
+
var hl = a(function({ label: e, value: t, min: n = 0, max: r = 100, color: i = "accent", striped: a = !1, animated: o = !1, id: s, className: c, ...l }, d) {
|
|
11504
11603
|
let f = u(), p = s ?? f;
|
|
11505
11604
|
if (!Number.isFinite(n) || !Number.isFinite(r) || r <= n) throw RangeError("ProgressBar requires a finite max greater than min");
|
|
11506
11605
|
if (t !== void 0 && !Number.isFinite(t)) throw RangeError("ProgressBar value must be finite");
|
|
@@ -11538,7 +11637,7 @@ var ul = a(function({ label: e, value: t, min: n = 0, max: r = 100, color: i = "
|
|
|
11538
11637
|
});
|
|
11539
11638
|
//#endregion
|
|
11540
11639
|
//#region src/components/ui/Stack.tsx
|
|
11541
|
-
function
|
|
11640
|
+
function gl({ as: e, gap: t = 0, align: n = "stretch", justify: r = "start", className: a, style: o, ...s }) {
|
|
11542
11641
|
return i(e ?? "div", {
|
|
11543
11642
|
...s,
|
|
11544
11643
|
className: J("ui-stack", a),
|
|
@@ -11552,7 +11651,7 @@ function dl({ as: e, gap: t = 0, align: n = "stretch", justify: r = "start", cla
|
|
|
11552
11651
|
}
|
|
11553
11652
|
//#endregion
|
|
11554
11653
|
//#region src/components/ui/Inline.tsx
|
|
11555
|
-
function
|
|
11654
|
+
function _l({ as: e, gap: t = 0, gapX: n, gapY: r, align: a = "stretch", justify: o = "start", wrap: s = !1, inline: c = !1, stackBelow: l, className: u, style: d, ...f }) {
|
|
11556
11655
|
return i(e ?? "div", {
|
|
11557
11656
|
...f,
|
|
11558
11657
|
className: J("ui-inline", u),
|
|
@@ -11572,7 +11671,7 @@ function fl({ as: e, gap: t = 0, gapX: n, gapY: r, align: a = "stretch", justify
|
|
|
11572
11671
|
}
|
|
11573
11672
|
//#endregion
|
|
11574
11673
|
//#region src/components/ui/Grid.tsx
|
|
11575
|
-
function
|
|
11674
|
+
function vl({ as: e, columns: t = 1, gap: n = 0, gapX: r, gapY: a, align: o = "stretch", justify: s = "stretch", className: c, style: l, ...u }) {
|
|
11576
11675
|
return i(e ?? "div", {
|
|
11577
11676
|
...u,
|
|
11578
11677
|
className: J("ui-grid", c),
|
|
@@ -11587,7 +11686,7 @@ function pl({ as: e, columns: t = 1, gap: n = 0, gapX: r, gapY: a, align: o = "s
|
|
|
11587
11686
|
}
|
|
11588
11687
|
//#endregion
|
|
11589
11688
|
//#region src/components/ui/GridItem.tsx
|
|
11590
|
-
function
|
|
11689
|
+
function yl({ as: e, span: t = 1, className: n, style: r, ...a }) {
|
|
11591
11690
|
return i(e ?? "div", {
|
|
11592
11691
|
...a,
|
|
11593
11692
|
className: J("ui-grid-item", n),
|
|
@@ -11598,4 +11697,4 @@ function ml({ as: e, span: t = 1, className: n, style: r, ...a }) {
|
|
|
11598
11697
|
});
|
|
11599
11698
|
}
|
|
11600
11699
|
//#endregion
|
|
11601
|
-
export { Wr as Alert, wr as AppShell, Ke as AreaChart,
|
|
11700
|
+
export { Wr as Alert, wr as AppShell, Ke as AreaChart, sl as AttachmentItem, cl as AttachmentList, Gr as AuthCard, Tr as AuthLayout, Kr as AuthorByline, vn as Avatar, Er as BackLink, ei as Badge, Ye as BarChart, mt as BottomNav, Vn as Breadcrumbs, Zn as Button, Dt as COMMAND_PALETTE_EVENT, Wa as Calendar, Qa as CalendarGrid, $a as Card, pl as CharacterCount, Dr as Checkbox, ao as CodeInput, Ar as ColumnPicker, oo as Combobox, Mt as CommandPalette, ml as ControlSizeProvider, Fa as DEFAULT_CALENDAR_LABELS, Ot as DEFAULT_COMMAND_PALETTE_SHORTCUT, so as DangerZone, ul as DatePartsInput, lo as DatePicker, po as DateRangePicker, vo as DateTimePicker, Co as DetailPanel, Xo as Dialog, Zo as DialogActions, Qo as DividerLabel, Ze as DonutChart, ts as DropdownMenu, ns as EmptyState, rs as ErrorBoundary, el as FieldError, $c as FieldHint, tl as Fieldset, Or as FilterButton, is as FilterDropdown, Qc as FormField, vl as Grid, yl as GridItem, _l as Inline, as as Kbd, ss as LoadingSpinner, hs as MetadataGrid, _s as MetricCard, Lt as MobileDrawer, fl as NavTabs, Ss as OAuthButton, Cs as PageHeader, ws as PageSection, jr as Pagination, Es as PaginationBar, Os as PasswordInput, js as PasswordRequirements, Nt as PortalContainerContext, Ms as ProfileHeader, hl as ProgressBar, Ns as ProseContent, Ps as QrCapacityError, rc as QrCode, Qe as RadarChart, $e as RadialBarChart, il as Radio, Ia as RadioPill, Vr as ResourceTable, ic as SearchInput, Qn as SectionHeader, ac as Select, ur as SelectDropdown, oc as SettingRow, pn as SettingsContext, Yc as SettingsProvider, sc as SideSheet, zn as Sidebar, dl as Skeleton, fr as Slider, et as SparkLine, hc as SplitPaneLayout, gl as Stack, st as StackedBarChart, _c as StatusDot, vc as StepProgress, hr as THEME_MENU_EVENT, Nr as Table, Fr as TableBody, Rr as TableCell, zr as TableEmptyRow, Pr as TableHead, Lr as TableHeaderCell, Ir as TableRow, yc as Tabs, xc as TextInput, bc as Textarea, jc as ThemeContext, vr as ThemeMenu, pr as ThemePreview, Zc as ThemeProvider, Sc as Timeline, En as ToastProvider, mr as Toggle, kc as Toolbar, Oc as Tooltip, Sr as TopBar, Ac as UploadDropzone, ut as VerticalBarChart, qt as accentItems, li as addDays, ui as addMinutes, di as addMonths, ti as badgeColors, ii as calendarDateFromParts, $ as calendarDateParts, J as cn, ea as createCalendarDateMath, Ht as darkThemes, vi as dateAtMinutes, ks as defaultPasswordRequirements, hi as differenceInDays, nc as encodeQrCode, qi as expandAvailabilityRules, Kt as fontOptions, Pc as formatDateLong, Nc as formatDateShort, Ii as formatRangeTitle, Fc as formatRelative, Mi as formatTime, bi as formatTimeOfDay, Ni as formatTimeRange, Si as fromDateKey, Ki as getActiveResourceIds, Oi as getViewRange, Ei as getVisibleDays, ft as handleAppShellNavigate, $i as isAllDayLike, dt as isAppShellPathActive, Bt as isLightTheme, mi as isSameDay, Ti as isTimeGridView, xn as isTone, Vi as layoutOverlaps, Vt as lightThemes, At as matchesCommandPaletteShortcut, As as meetsPasswordRequirements, gi as minutesOfDay, pt as navigateToPath, kt as openCommandPalette, gr as openThemeMenu, yi as parseTime, Li as rangesOverlap, yn as semanticTones, ki as shiftDate, wi as snapDate, Ci as snapMinutes, Mr as sortRows, ci as startOfDay, pi as startOfMonth, fi as startOfWeek, Gt as themeDefaults, Rt as themeItems, xi as toDateKey, Cn as toneClasses, Sn as toneColor, bn as tones, Hn as useApplyTheme, Wn as useControlSize, fn as useDismiss, gt as useFocusTrap, Pt as usePortalContainer, mn as useSettings, Mc as useTheme, Tn as useToast };
|