@thekestongroup/ui 0.11.1 → 0.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/AppLauncher/AppLauncher.vue.d.ts +33 -0
- package/dist/components/AppLauncher/apps.d.ts +3 -0
- package/dist/components/AppShell/AppShell.vue.d.ts +10 -0
- package/dist/components/CardSelect/CardSelect.vue.d.ts +1 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.vue.d.ts +1 -1
- package/dist/components/Footer/Footer.vue.d.ts +66 -0
- package/dist/components/Footer/footer.d.ts +6 -0
- package/dist/components/Footer/links.d.ts +8 -0
- package/dist/components/FormField/FormField.vue.d.ts +1 -1
- package/dist/components/Input/Input.vue.d.ts +1 -1
- package/dist/components/InputCode/InputCode.vue.d.ts +1 -1
- package/dist/components/InputDate/InputDate.vue.d.ts +1 -1
- package/dist/components/InputNumber/InputNumber.vue.d.ts +1 -1
- package/dist/components/InputPassword/InputPassword.vue.d.ts +1 -1
- package/dist/components/InputRichText/InputRichText.vue.d.ts +1 -1
- package/dist/components/InputTextArea/InputTextArea.vue.d.ts +1 -1
- package/dist/components/RadioGroup/RadioGroup.vue.d.ts +1 -1
- package/dist/components/Select/Select.vue.d.ts +1 -1
- package/dist/i18n/en.d.ts +9 -0
- package/dist/index.d.ts +6 -0
- package/dist/keston-ui.js +1052 -798
- package/package.json +1 -1
- package/src/components/AppLauncher/AppLauncher.stories.ts +32 -0
- package/src/components/AppLauncher/AppLauncher.vue +91 -0
- package/src/components/AppLauncher/apps.ts +10 -0
- package/src/components/AppShell/AppShell.stories.ts +13 -0
- package/src/components/AppShell/AppShell.vue +21 -4
- package/src/components/Avatar/Avatar.vue +6 -3
- package/src/components/Card/Card.stories.ts +1 -1
- package/src/components/Checklist/Checklist.stories.ts +1 -1
- package/src/components/Footer/Footer.stories.ts +82 -0
- package/src/components/Footer/Footer.vue +123 -0
- package/src/components/Footer/footer.test.ts +41 -0
- package/src/components/Footer/footer.ts +15 -0
- package/src/components/Footer/links.ts +19 -0
- package/src/components/Input/Input.vue +1 -0
- package/src/components/StatTile/StatTile.stories.ts +1 -1
- package/src/examples/AppPages.stories.ts +1 -1
- package/src/examples/SchoolPages.stories.ts +2 -2
- package/src/i18n/en.ts +7 -0
- package/src/index.ts +6 -0
- package/src/lib/parseDate.ts +1 -1
package/dist/keston-ui.js
CHANGED
|
@@ -2,28 +2,28 @@ import { clsx as e } from "clsx";
|
|
|
2
2
|
import { twMerge as t } from "tailwind-merge";
|
|
3
3
|
import { Fragment as n, Transition as r, computed as i, createBlock as a, createCommentVNode as o, createElementBlock as s, createElementVNode as c, createSlots as l, createTextVNode as u, createVNode as d, defineComponent as f, guardReactiveProps as p, h as m, isRef as h, mergeModels as g, mergeProps as _, nextTick as v, normalizeClass as y, normalizeProps as b, normalizeStyle as x, onBeforeUnmount as S, onMounted as C, openBlock as w, reactive as T, ref as E, renderList as D, renderSlot as O, resolveDynamicComponent as k, shallowRef as A, toDisplayString as j, unref as M, useAttrs as N, useId as P, useModel as F, useSlots as I, vModelDynamic as L, vModelText as R, watch as z, watchEffect as B, withCtx as V, withDirectives as H, withKeys as U, withModifiers as ee } from "vue";
|
|
4
4
|
import { I18nT as W, createI18n as G, useI18n as K } from "vue-i18n";
|
|
5
|
-
import { ArrowDown as
|
|
6
|
-
import { CalendarCell as
|
|
7
|
-
import { CalendarDate as
|
|
8
|
-
import { EditorContent as
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import { Placeholder as
|
|
5
|
+
import { AppWindow as q, ArrowDown as J, ArrowDownRight as te, ArrowLeftRight as ne, ArrowRight as re, ArrowUp as ie, ArrowUpRight as ae, Bell as oe, BellOff as se, Bold as ce, BriefcaseBusiness as le, CalendarDays as ue, Check as de, ChevronDown as fe, ChevronLeft as pe, ChevronRight as me, ChevronsUpDown as he, Circle as ge, CircleAlert as _e, CircleCheck as ve, CircleHelp as ye, CircleX as be, Ellipsis as xe, ExternalLink as Y, Eye as Se, EyeOff as Ce, IdCard as we, Info as Te, Italic as Ee, Languages as De, LayoutGrid as Oe, LogOut as ke, Menu as Ae, Minus as je, Palette as Me, PanelLeftClose as Ne, PanelLeftOpen as Pe, Plus as Fe, Settings as Ie, ShieldCheck as Le, TriangleAlert as Re, Underline as ze, Wrench as Be, X as Ve } from "@lucide/vue";
|
|
6
|
+
import { CalendarCell as He, CalendarCellTrigger as Ue, CalendarGrid as We, CalendarGridBody as Ge, CalendarGridHead as Ke, CalendarGridRow as qe, CalendarHeadCell as Je, CalendarHeader as Ye, CalendarNext as Xe, CalendarPrev as Ze, CalendarRoot as Qe, CheckboxIndicator as $e, CheckboxRoot as et, ComboboxAnchor as tt, ComboboxContent as nt, ComboboxEmpty as rt, ComboboxGroup as it, ComboboxInput as at, ComboboxItem as ot, ComboboxItemIndicator as st, ComboboxLabel as ct, ComboboxPortal as lt, ComboboxRoot as ut, ComboboxSeparator as dt, ComboboxTrigger as ft, ComboboxViewport as pt, DatePickerContent as mt, DatePickerRoot as ht, DatePickerTrigger as gt, DialogClose as _t, DialogContent as vt, DialogDescription as yt, DialogOverlay as bt, DialogPortal as xt, DialogRoot as St, DialogTitle as Ct, DialogTrigger as wt, DropdownMenuContent as Tt, DropdownMenuItem as Et, DropdownMenuPortal as Dt, DropdownMenuRoot as Ot, DropdownMenuTrigger as kt, NumberFieldDecrement as At, NumberFieldIncrement as jt, NumberFieldInput as Mt, NumberFieldRoot as Nt, PinInputInput as Pt, PinInputRoot as Ft, PopoverAnchor as It, PopoverArrow as Lt, PopoverContent as Rt, PopoverPortal as zt, PopoverRoot as Bt, PopoverTrigger as Vt, Primitive as Ht, ProgressIndicator as Ut, ProgressRoot as Wt, RadioGroupIndicator as Gt, RadioGroupItem as Kt, RadioGroupRoot as qt, SelectContent as Jt, SelectGroup as Yt, SelectItem as Xt, SelectItemIndicator as Zt, SelectItemText as Qt, SelectLabel as $t, SelectPortal as en, SelectRoot as tn, SelectSeparator as nn, SelectTrigger as rn, SelectViewport as an, Separator as on, SwitchRoot as sn, SwitchThumb as cn, TabsContent as ln, TabsIndicator as un, TabsList as dn, TabsRoot as fn, TabsTrigger as pn, ToastProvider as mn, ToastRoot as hn, ToastViewport as gn, TooltipContent as _n, TooltipPortal as vn, TooltipProvider as yn, TooltipRoot as bn, TooltipTrigger as xn, injectTooltipProviderContext as Sn } from "reka-ui";
|
|
7
|
+
import { CalendarDate as Cn, endOfMonth as wn, getLocalTimeZone as Tn, isToday as En, parseDate as Dn, startOfMonth as On, toCalendarDate as kn, today as An } from "@internationalized/date";
|
|
8
|
+
import { EditorContent as jn, useEditor as Mn } from "@tiptap/vue-3";
|
|
9
|
+
import Nn from "@tiptap/extension-document";
|
|
10
|
+
import Pn from "@tiptap/extension-paragraph";
|
|
11
|
+
import Fn from "@tiptap/extension-text";
|
|
12
|
+
import In from "@tiptap/extension-hard-break";
|
|
13
|
+
import Ln from "@tiptap/extension-bold";
|
|
14
|
+
import Rn from "@tiptap/extension-italic";
|
|
15
|
+
import zn from "@tiptap/extension-underline";
|
|
16
|
+
import { Placeholder as Bn, UndoRedo as Vn } from "@tiptap/extensions";
|
|
17
17
|
// src/lib/cn.ts
|
|
18
18
|
function X(...n) {
|
|
19
19
|
return t(e(n));
|
|
20
20
|
}
|
|
21
21
|
// src/components/Spinner/Spinner.vue?vue&type=script&setup=true&lang.ts
|
|
22
|
-
var
|
|
22
|
+
var Hn = ["stroke-dashoffset", "stroke-opacity"], Un = {
|
|
23
23
|
key: 0,
|
|
24
24
|
"aria-hidden": "true",
|
|
25
25
|
class: "absolute text-xs tabular-nums"
|
|
26
|
-
},
|
|
26
|
+
}, Wn = 10, Gn = /* @__PURE__ */ f({
|
|
27
27
|
__name: "Spinner",
|
|
28
28
|
props: {
|
|
29
29
|
value: {},
|
|
@@ -40,12 +40,12 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
40
40
|
] }
|
|
41
41
|
},
|
|
42
42
|
setup(e) {
|
|
43
|
-
let { t } = K(), n = e, r = i(() => n.value === null || n.value === void 0), l = i(() => r.value ? 0 : Math.min(Math.max(n.value / n.max, 0), 1)), u = i(() => Math.round(l.value * 100)), d = 2 * Math.PI *
|
|
43
|
+
let { t } = K(), n = e, r = i(() => n.value === null || n.value === void 0), l = i(() => r.value ? 0 : Math.min(Math.max(n.value / n.max, 0), 1)), u = i(() => Math.round(l.value * 100)), d = 2 * Math.PI * Wn, f = i(() => d * (r.value ? .75 : 1 - l.value)), p = {
|
|
44
44
|
sm: "size-4",
|
|
45
45
|
md: "size-6",
|
|
46
46
|
lg: "size-12"
|
|
47
47
|
};
|
|
48
|
-
return (i, m) => (w(), a(M(
|
|
48
|
+
return (i, m) => (w(), a(M(Wt), {
|
|
49
49
|
as: "span",
|
|
50
50
|
"model-value": r.value ? null : l.value * e.max,
|
|
51
51
|
max: e.max,
|
|
@@ -60,14 +60,14 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
60
60
|
}, [c("circle", {
|
|
61
61
|
cx: "12",
|
|
62
62
|
cy: "12",
|
|
63
|
-
r:
|
|
63
|
+
r: Wn,
|
|
64
64
|
stroke: "currentColor",
|
|
65
65
|
"stroke-opacity": "0.2",
|
|
66
66
|
"stroke-width": "2.5"
|
|
67
67
|
}), c("circle", {
|
|
68
68
|
cx: "12",
|
|
69
69
|
cy: "12",
|
|
70
|
-
r:
|
|
70
|
+
r: Wn,
|
|
71
71
|
stroke: "currentColor",
|
|
72
72
|
"stroke-width": "2.5",
|
|
73
73
|
"stroke-linecap": "round",
|
|
@@ -75,7 +75,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
75
75
|
"stroke-dashoffset": f.value,
|
|
76
76
|
"stroke-opacity": !r.value && l.value === 0 ? 0 : 1,
|
|
77
77
|
class: "transition-[stroke-dashoffset] duration-300 ease-out motion-reduce:transition-none"
|
|
78
|
-
}, null, 8,
|
|
78
|
+
}, null, 8, Hn)], 2)), e.showValue && e.size === "lg" && !r.value ? (w(), s("span", Un, j(u.value) + "% ", 1)) : o("", !0)]),
|
|
79
79
|
_: 1
|
|
80
80
|
}, 8, [
|
|
81
81
|
"model-value",
|
|
@@ -84,13 +84,13 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
84
84
|
"class"
|
|
85
85
|
]));
|
|
86
86
|
}
|
|
87
|
-
}),
|
|
87
|
+
}), Kn = {
|
|
88
88
|
key: 1,
|
|
89
89
|
class: "inline-grid place-items-center gap-[inherit]"
|
|
90
|
-
},
|
|
90
|
+
}, qn = { key: 2 }, Jn = {
|
|
91
91
|
class: "sr-only",
|
|
92
92
|
role: "status"
|
|
93
|
-
},
|
|
93
|
+
}, Yn = 300, Xn = "not-disabled:not-aria-disabled:hover:brightness-90 not-disabled:not-aria-disabled:active:brightness-80", Zn = "not-disabled:not-aria-disabled:hover:bg-black/10 not-disabled:not-aria-disabled:active:bg-black/15", Z = /* @__PURE__ */ f({
|
|
94
94
|
__name: "Button",
|
|
95
95
|
props: {
|
|
96
96
|
variant: { default: "basic" },
|
|
@@ -117,7 +117,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
117
117
|
setup(e, { emit: t }) {
|
|
118
118
|
let n = e, l = t, u = i(() => n.status !== "idle" && !n.asChild), f, p = E(!1), m;
|
|
119
119
|
z(() => n.status, (e, t) => {
|
|
120
|
-
clearTimeout(f), clearTimeout(m), p.value = e === "idle" && (t === "success" || t === "error"), p.value && (m = setTimeout(() => p.value = !1,
|
|
120
|
+
clearTimeout(f), clearTimeout(m), p.value = e === "idle" && (t === "success" || t === "error"), p.value && (m = setTimeout(() => p.value = !1, Yn)), (e === "success" || e === "error") && (f = setTimeout(() => l("update:status", "idle"), n.statusDuration));
|
|
121
121
|
}, { immediate: !0 }), S(() => {
|
|
122
122
|
clearTimeout(f), clearTimeout(m);
|
|
123
123
|
});
|
|
@@ -125,8 +125,8 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
125
125
|
u.value && (e.preventDefault(), e.stopImmediatePropagation());
|
|
126
126
|
}
|
|
127
127
|
let g = {
|
|
128
|
-
success:
|
|
129
|
-
error:
|
|
128
|
+
success: de,
|
|
129
|
+
error: Ve
|
|
130
130
|
}, _ = i(() => {
|
|
131
131
|
switch (n.status) {
|
|
132
132
|
case "loading": return n.loadingText;
|
|
@@ -146,7 +146,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
146
146
|
await v(), x?.cancel();
|
|
147
147
|
let n = e.getBoundingClientRect().width;
|
|
148
148
|
Math.abs(n - t) < .5 || window.matchMedia("(prefers-reduced-motion: reduce)").matches || (x = e.animate([{ width: `${t}px` }, { width: `${n}px` }], {
|
|
149
|
-
duration:
|
|
149
|
+
duration: Yn,
|
|
150
150
|
easing: "cubic-bezier(0, 0, 0.2, 1)"
|
|
151
151
|
}));
|
|
152
152
|
}, { flush: "pre" });
|
|
@@ -162,10 +162,10 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
162
162
|
"outline-2 outline-offset-1 outline-transparent forced-colors:not-focus-visible:outline-0",
|
|
163
163
|
"focus-visible:outline-focus"
|
|
164
164
|
], D = {
|
|
165
|
-
basic: `bg-white text-black ${
|
|
166
|
-
primary: `bg-primary text-white ${
|
|
167
|
-
ghost: `bg-transparent text-black border-transparent ${
|
|
168
|
-
danger: `bg-red text-white ${
|
|
165
|
+
basic: `bg-white text-black ${Xn}`,
|
|
166
|
+
primary: `bg-primary text-white ${Xn}`,
|
|
167
|
+
ghost: `bg-transparent text-black border-transparent ${Zn}`,
|
|
168
|
+
danger: `bg-red text-white ${Xn}`
|
|
169
169
|
}, A = {
|
|
170
170
|
idle: "",
|
|
171
171
|
loading: "",
|
|
@@ -180,7 +180,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
180
180
|
md: "size-9.5 p-0",
|
|
181
181
|
lg: "size-12.5 p-0"
|
|
182
182
|
};
|
|
183
|
-
return (t, i) => (w(), a(M(
|
|
183
|
+
return (t, i) => (w(), a(M(Ht), {
|
|
184
184
|
ref_key: "rootRef",
|
|
185
185
|
ref: b,
|
|
186
186
|
as: e.as,
|
|
@@ -193,7 +193,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
193
193
|
class: y(M(X)(T, D[e.variant], u.value && A[e.status], p.value && "duration-300", N[e.size], e.square && P[e.size], n.class)),
|
|
194
194
|
onClickCapture: h
|
|
195
195
|
}, {
|
|
196
|
-
default: V(() => [e.asChild ? O(t.$slots, "default", {}, void 0, void 0, 0) : (w(), s("span",
|
|
196
|
+
default: V(() => [e.asChild ? O(t.$slots, "default", {}, void 0, void 0, 0) : (w(), s("span", Kn, [
|
|
197
197
|
c("span", { class: y(["col-start-1 row-start-1 inline-flex items-center gap-[inherit] transition-[opacity,visibility]", u.value ? "invisible opacity-0 duration-150" : "delay-150 duration-150"]) }, [
|
|
198
198
|
O(t.$slots, "leading"),
|
|
199
199
|
O(t.$slots, "default"),
|
|
@@ -209,13 +209,13 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
209
209
|
key: e.status,
|
|
210
210
|
"aria-hidden": "true",
|
|
211
211
|
class: "col-start-1 row-start-1 inline-flex items-center gap-2"
|
|
212
|
-
}, [e.status === "loading" ? (w(), a(
|
|
212
|
+
}, [e.status === "loading" ? (w(), a(Gn, {
|
|
213
213
|
key: 0,
|
|
214
214
|
class: "size-auto"
|
|
215
|
-
})) : (w(), a(k(g[e.status]), { key: 1 })), _.value ? (w(), s("span",
|
|
215
|
+
})) : (w(), a(k(g[e.status]), { key: 1 })), _.value ? (w(), s("span", qn, j(_.value), 1)) : o("", !0)])) : o("", !0)]),
|
|
216
216
|
_: 1
|
|
217
217
|
}),
|
|
218
|
-
c("span",
|
|
218
|
+
c("span", Jn, j(C.value), 1)
|
|
219
219
|
]))]),
|
|
220
220
|
_: 3
|
|
221
221
|
}, 8, [
|
|
@@ -229,16 +229,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
229
229
|
"class"
|
|
230
230
|
]));
|
|
231
231
|
}
|
|
232
|
-
})
|
|
233
|
-
// src/lib/initials.ts
|
|
234
|
-
function Gn(e) {
|
|
235
|
-
let t = e.trim().split(/\s+/).filter(Boolean);
|
|
236
|
-
if (!t.length) return "";
|
|
237
|
-
let n = t[0], r = t.length > 1 ? t[t.length - 1] : "";
|
|
238
|
-
return (n[0] + (r[0] ?? "")).toUpperCase();
|
|
239
|
-
}
|
|
240
|
-
// src/components/Popover/popover.ts
|
|
241
|
-
var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md outline-none", "data-[state=open]:animate-fade-in data-[state=closed]:animate-fade-out"], qn = "block size-2.5 -translate-y-1/2 rotate-45 border-r border-b border-black/15 bg-white", Jn = /* @__PURE__ */ f({
|
|
232
|
+
}), Qn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md outline-none", "data-[state=open]:animate-fade-in data-[state=closed]:animate-fade-out"], $n = "block size-2.5 -translate-y-1/2 rotate-45 border-r border-b border-black/15 bg-white", er = /* @__PURE__ */ f({
|
|
242
233
|
__name: "Popover",
|
|
243
234
|
props: /*@__PURE__*/ g({
|
|
244
235
|
mode: { default: "click" },
|
|
@@ -320,20 +311,20 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
320
311
|
n.mode === "hover" && e.preventDefault();
|
|
321
312
|
}
|
|
322
313
|
let A = () => typeof n.portal == "string" || n.portal instanceof HTMLElement ? n.portal : void 0;
|
|
323
|
-
return (t, n) => (w(), a(M(
|
|
314
|
+
return (t, n) => (w(), a(M(Bt), {
|
|
324
315
|
open: s.value,
|
|
325
316
|
modal: e.modal,
|
|
326
317
|
"onUpdate:open": C
|
|
327
318
|
}, {
|
|
328
319
|
default: V(() => [
|
|
329
|
-
t.$slots.anchor ? (w(), a(M(
|
|
320
|
+
t.$slots.anchor ? (w(), a(M(It), {
|
|
330
321
|
key: 0,
|
|
331
322
|
"as-child": ""
|
|
332
323
|
}, {
|
|
333
324
|
default: V(() => [O(t.$slots, "anchor")]),
|
|
334
325
|
_: 3
|
|
335
326
|
})) : o("", !0),
|
|
336
|
-
t.$slots.default ? (w(), a(M(
|
|
327
|
+
t.$slots.default ? (w(), a(M(Vt), {
|
|
337
328
|
key: 1,
|
|
338
329
|
"as-child": "",
|
|
339
330
|
onPointerdown: x,
|
|
@@ -343,15 +334,15 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
343
334
|
default: V(() => [O(t.$slots, "default")]),
|
|
344
335
|
_: 3
|
|
345
336
|
})) : o("", !0),
|
|
346
|
-
d(M(
|
|
337
|
+
d(M(zt), {
|
|
347
338
|
disabled: e.portal === !1,
|
|
348
339
|
to: A()
|
|
349
340
|
}, {
|
|
350
|
-
default: V(() => [d(M(
|
|
341
|
+
default: V(() => [d(M(Rt), _({
|
|
351
342
|
...f,
|
|
352
343
|
...e.content
|
|
353
344
|
}, {
|
|
354
|
-
class: M(X)(M(
|
|
345
|
+
class: M(X)(M(Qn), e.ui?.content),
|
|
355
346
|
onPointerenter: v,
|
|
356
347
|
onPointerleave: b,
|
|
357
348
|
onEscapeKeyDown: D,
|
|
@@ -359,8 +350,8 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
359
350
|
onOpenAutoFocus: k,
|
|
360
351
|
onCloseAutoFocus: k
|
|
361
352
|
}), {
|
|
362
|
-
default: V(() => [O(t.$slots, "content", { close: u }), e.arrow ? (w(), a(M(
|
|
363
|
-
default: V(() => [c("span", { class: y(M(X)(M(
|
|
353
|
+
default: V(() => [O(t.$slots, "content", { close: u }), e.arrow ? (w(), a(M(Lt), _({ key: 0 }, typeof e.arrow == "object" ? e.arrow : {}, { "as-child": "" }), {
|
|
354
|
+
default: V(() => [c("span", { class: y(M(X)(M($n), e.ui?.arrow)) }, null, 2)]),
|
|
364
355
|
_: 1
|
|
365
356
|
}, 16)) : o("", !0)]),
|
|
366
357
|
_: 3
|
|
@@ -371,23 +362,301 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
371
362
|
_: 3
|
|
372
363
|
}, 8, ["open", "modal"]));
|
|
373
364
|
}
|
|
374
|
-
}),
|
|
365
|
+
}), tr = [
|
|
366
|
+
{
|
|
367
|
+
id: "id",
|
|
368
|
+
label: "Keston ID",
|
|
369
|
+
description: "Your account and sign-in",
|
|
370
|
+
href: "https://id.keston.co",
|
|
371
|
+
icon: "id"
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
id: "admin",
|
|
375
|
+
label: "Admin",
|
|
376
|
+
description: "Manage people and access",
|
|
377
|
+
href: "https://admin.keston.co",
|
|
378
|
+
icon: "admin"
|
|
379
|
+
},
|
|
380
|
+
{
|
|
381
|
+
id: "work",
|
|
382
|
+
label: "Work",
|
|
383
|
+
description: "Day-to-day work",
|
|
384
|
+
href: "https://work.keston.co",
|
|
385
|
+
icon: "work"
|
|
386
|
+
},
|
|
387
|
+
{
|
|
388
|
+
id: "utilities",
|
|
389
|
+
label: "Utilities",
|
|
390
|
+
description: "Small tools that run on your device",
|
|
391
|
+
href: "https://utilities.keston.co",
|
|
392
|
+
icon: "utilities"
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
id: "design",
|
|
396
|
+
label: "Design system",
|
|
397
|
+
description: "Keston UI",
|
|
398
|
+
href: "https://ui.keston.co",
|
|
399
|
+
icon: "design"
|
|
400
|
+
}
|
|
401
|
+
], nr = ["aria-label"], rr = { class: "grid grid-cols-2 gap-1" }, ir = [
|
|
402
|
+
"href",
|
|
403
|
+
"aria-current",
|
|
404
|
+
"onClick"
|
|
405
|
+
], ar = { class: "flex size-9 items-center justify-center rounded-lg bg-black/5 text-black" }, or = { class: "min-w-0" }, sr = { class: "block font-bold text-black" }, cr = {
|
|
406
|
+
key: 0,
|
|
407
|
+
class: "block text-xs text-black/65"
|
|
408
|
+
}, lr = {
|
|
409
|
+
id: we,
|
|
410
|
+
admin: Le,
|
|
411
|
+
work: le,
|
|
412
|
+
utilities: Be,
|
|
413
|
+
design: Me
|
|
414
|
+
}, ur = /* @__PURE__ */ f({
|
|
415
|
+
__name: "AppLauncher",
|
|
416
|
+
props: {
|
|
417
|
+
apps: { default: () => tr },
|
|
418
|
+
current: {},
|
|
419
|
+
label: {},
|
|
420
|
+
class: { type: [
|
|
421
|
+
Boolean,
|
|
422
|
+
null,
|
|
423
|
+
String,
|
|
424
|
+
Object,
|
|
425
|
+
Array
|
|
426
|
+
] }
|
|
427
|
+
},
|
|
428
|
+
setup(e) {
|
|
429
|
+
let { t } = K(), r = e;
|
|
430
|
+
function i(e) {
|
|
431
|
+
return typeof e.icon == "string" ? lr[e.icon] ?? q : e.icon ?? q;
|
|
432
|
+
}
|
|
433
|
+
return (l, u) => (w(), a(er, {
|
|
434
|
+
content: { align: "end" },
|
|
435
|
+
ui: { content: "w-80 p-2" }
|
|
436
|
+
}, {
|
|
437
|
+
content: V(({ close: r }) => [c("nav", { "aria-label": e.label ?? M(t)("ui.appLauncher.label") }, [c("ul", rr, [(w(!0), s(n, null, D(e.apps, (t) => (w(), s("li", { key: t.id }, [c("a", {
|
|
438
|
+
href: t.href,
|
|
439
|
+
"aria-current": t.id === e.current ? "page" : void 0,
|
|
440
|
+
class: y(M(X)("flex h-full flex-col items-start gap-2 rounded-lg p-3 text-sm outline-none hover:bg-black/5 focus-visible:outline-2 focus-visible:outline-focus", t.id === e.current && "bg-black/5")),
|
|
441
|
+
onClick: (e) => r()
|
|
442
|
+
}, [c("span", ar, [(w(), a(k(i(t)), {
|
|
443
|
+
class: "size-5",
|
|
444
|
+
"aria-hidden": "true"
|
|
445
|
+
}))]), c("span", or, [c("span", sr, j(t.label), 1), t.description ? (w(), s("span", cr, j(t.description), 1)) : o("", !0)])], 10, ir)]))), 128))])], 8, nr)]),
|
|
446
|
+
default: V(() => [d(Z, {
|
|
447
|
+
variant: "ghost",
|
|
448
|
+
square: "",
|
|
449
|
+
"aria-label": e.label ?? M(t)("ui.appLauncher.label"),
|
|
450
|
+
class: y(r.class)
|
|
451
|
+
}, {
|
|
452
|
+
default: V(() => [d(M(Oe))]),
|
|
453
|
+
_: 1
|
|
454
|
+
}, 8, ["aria-label", "class"])]),
|
|
455
|
+
_: 1
|
|
456
|
+
}));
|
|
457
|
+
}
|
|
458
|
+
}), dr = /* @__PURE__ */ f({
|
|
459
|
+
__name: "Link",
|
|
460
|
+
props: {
|
|
461
|
+
href: {},
|
|
462
|
+
newTab: { type: Boolean },
|
|
463
|
+
icon: {
|
|
464
|
+
type: Boolean,
|
|
465
|
+
default: !0
|
|
466
|
+
},
|
|
467
|
+
as: { default: "a" },
|
|
468
|
+
class: { type: [
|
|
469
|
+
Boolean,
|
|
470
|
+
null,
|
|
471
|
+
String,
|
|
472
|
+
Object,
|
|
473
|
+
Array
|
|
474
|
+
] }
|
|
475
|
+
},
|
|
476
|
+
setup(e) {
|
|
477
|
+
let t = e, r = [
|
|
478
|
+
"cursor-pointer rounded-xs underline underline-offset-2 transition-colors",
|
|
479
|
+
"hover:text-black hover:decoration-2",
|
|
480
|
+
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
481
|
+
];
|
|
482
|
+
return (i, l) => (w(), a(M(Ht), {
|
|
483
|
+
as: e.as,
|
|
484
|
+
href: e.href,
|
|
485
|
+
type: e.as === "button" ? "button" : void 0,
|
|
486
|
+
target: e.newTab ? "_blank" : void 0,
|
|
487
|
+
rel: e.newTab ? "noopener noreferrer" : void 0,
|
|
488
|
+
class: y(M(X)(r, t.class))
|
|
489
|
+
}, {
|
|
490
|
+
default: V(() => [O(i.$slots, "default"), e.newTab ? (w(), s(n, { key: 0 }, [e.icon ? (w(), a(M(Y), {
|
|
491
|
+
key: 0,
|
|
492
|
+
class: "ms-0.5 inline size-[0.9em] align-[-0.1em]",
|
|
493
|
+
"aria-hidden": "true"
|
|
494
|
+
})) : o("", !0), l[0] ||= c("span", { class: "sr-only" }, " (opens in a new tab)", -1)], 64)) : o("", !0)]),
|
|
495
|
+
_: 3
|
|
496
|
+
}, 8, [
|
|
497
|
+
"as",
|
|
498
|
+
"href",
|
|
499
|
+
"type",
|
|
500
|
+
"target",
|
|
501
|
+
"rel",
|
|
502
|
+
"class"
|
|
503
|
+
]));
|
|
504
|
+
}
|
|
505
|
+
});
|
|
506
|
+
// src/components/Footer/footer.ts
|
|
507
|
+
function fr(e, t) {
|
|
508
|
+
return t && t < e ? `${t}–${e}` : String(e);
|
|
509
|
+
}
|
|
510
|
+
function pr(e) {
|
|
511
|
+
return e ? /^v/i.test(e) ? `v${e.slice(1)}` : `v${e}` : "";
|
|
512
|
+
}
|
|
513
|
+
function mr(e) {
|
|
514
|
+
return e ? e.replace(/^v/i, "") : "";
|
|
515
|
+
}
|
|
516
|
+
// src/components/Footer/links.ts
|
|
517
|
+
var hr = [
|
|
518
|
+
{
|
|
519
|
+
label: "Help & support",
|
|
520
|
+
href: "https://thekestongroup.com/help"
|
|
521
|
+
},
|
|
522
|
+
{
|
|
523
|
+
label: "Privacy Policy",
|
|
524
|
+
href: "https://thekestongroup.com/privacy"
|
|
525
|
+
},
|
|
526
|
+
{
|
|
527
|
+
label: "Terms & Conditions",
|
|
528
|
+
href: "https://thekestongroup.com/terms"
|
|
529
|
+
}
|
|
530
|
+
], gr = [
|
|
531
|
+
{
|
|
532
|
+
label: "Keston ID",
|
|
533
|
+
href: "https://id.keston.co"
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
label: "Admin",
|
|
537
|
+
href: "https://admin.keston.co"
|
|
538
|
+
},
|
|
539
|
+
{
|
|
540
|
+
label: "Work",
|
|
541
|
+
href: "https://work.keston.co"
|
|
542
|
+
},
|
|
543
|
+
{
|
|
544
|
+
label: "Design system",
|
|
545
|
+
href: "https://ui.keston.co"
|
|
546
|
+
}
|
|
547
|
+
], _r = ["aria-label"], vr = { class: "flex flex-wrap items-center gap-x-4 gap-y-1" }, yr = {
|
|
548
|
+
key: 0,
|
|
549
|
+
class: "hidden h-4 w-px bg-black/15 sm:block",
|
|
550
|
+
"aria-hidden": "true"
|
|
551
|
+
}, br = {
|
|
552
|
+
key: 0,
|
|
553
|
+
class: "flex flex-wrap items-baseline gap-x-1.5"
|
|
554
|
+
}, xr = {
|
|
555
|
+
key: 0,
|
|
556
|
+
class: "font-bold text-black/80"
|
|
557
|
+
}, Sr = { key: 1 }, Cr = { class: "sr-only" }, wr = { "aria-hidden": "true" }, Tr = ["title"], Er = { class: "sr-only" }, Dr = {
|
|
558
|
+
class: "font-mono text-xs text-black/55",
|
|
559
|
+
"aria-hidden": "true"
|
|
560
|
+
}, Or = /* @__PURE__ */ f({
|
|
561
|
+
__name: "Footer",
|
|
562
|
+
props: {
|
|
563
|
+
links: { default: () => hr },
|
|
564
|
+
moreLinks: { default: () => [] },
|
|
565
|
+
linkComponent: { default: void 0 },
|
|
566
|
+
appName: {},
|
|
567
|
+
version: {},
|
|
568
|
+
build: {},
|
|
569
|
+
holder: { default: "The Keston Group" },
|
|
570
|
+
year: {},
|
|
571
|
+
since: {},
|
|
572
|
+
class: { type: [
|
|
573
|
+
Boolean,
|
|
574
|
+
null,
|
|
575
|
+
String,
|
|
576
|
+
Object,
|
|
577
|
+
Array
|
|
578
|
+
] },
|
|
579
|
+
ui: {}
|
|
580
|
+
},
|
|
581
|
+
setup(e) {
|
|
582
|
+
let { t } = K(), r = e, a = i(() => fr(r.year ?? (/* @__PURE__ */ new Date()).getFullYear(), r.since)), l = i(() => pr(r.version)), f = i(() => r.version ? t("ui.footer.version", { version: mr(r.version) }) : ""), p = i(() => r.build ? t("ui.footer.build", { build: r.build }) : "");
|
|
583
|
+
function m(e) {
|
|
584
|
+
return e.to === void 0 ? {
|
|
585
|
+
href: e.href,
|
|
586
|
+
newTab: e.newTab ?? !0
|
|
587
|
+
} : {
|
|
588
|
+
as: r.linkComponent,
|
|
589
|
+
to: e.to,
|
|
590
|
+
newTab: e.newTab ?? !1
|
|
591
|
+
};
|
|
592
|
+
}
|
|
593
|
+
return (i, h) => (w(), s("footer", { class: y(M(X)("flex shrink-0 flex-col gap-3 border-t border-black/15 bg-white px-4 py-4 text-sm text-black/65 sm:flex-row sm:items-center sm:justify-between sm:px-6", r.class)) }, [c("nav", {
|
|
594
|
+
"aria-label": M(t)("ui.footer.label"),
|
|
595
|
+
class: y(M(X)("min-w-0", e.ui?.links))
|
|
596
|
+
}, [O(i.$slots, "nav", {}, () => [c("ul", vr, [
|
|
597
|
+
(w(!0), s(n, null, D(e.links, (e) => (w(), s("li", { key: e.label }, [d(dr, _({ ref_for: !0 }, m(e), { icon: !1 }), {
|
|
598
|
+
default: V(() => [u(j(e.label), 1)]),
|
|
599
|
+
_: 2
|
|
600
|
+
}, 1040)]))), 128)),
|
|
601
|
+
e.moreLinks.length ? (w(), s("li", yr)) : o("", !0),
|
|
602
|
+
(w(!0), s(n, null, D(e.moreLinks, (e) => (w(), s("li", { key: e.label }, [d(dr, _({ ref_for: !0 }, m(e), { icon: !1 }), {
|
|
603
|
+
default: V(() => [u(j(e.label), 1)]),
|
|
604
|
+
_: 2
|
|
605
|
+
}, 1040)]))), 128))
|
|
606
|
+
])])], 10, _r), c("div", { class: y(M(X)("flex flex-wrap items-center gap-x-3 gap-y-1 sm:justify-end", e.ui?.meta)) }, [
|
|
607
|
+
e.appName || e.version || e.build ? (w(), s("p", br, [
|
|
608
|
+
e.appName ? (w(), s("span", xr, j(e.appName), 1)) : o("", !0),
|
|
609
|
+
e.version ? (w(), s("span", Sr, [c("span", Cr, j(f.value), 1), c("span", wr, j(l.value), 1)])) : o("", !0),
|
|
610
|
+
e.build ? (w(), s("span", {
|
|
611
|
+
key: 2,
|
|
612
|
+
title: p.value
|
|
613
|
+
}, [c("span", Er, j(p.value), 1), c("span", Dr, j(e.build), 1)], 8, Tr)) : o("", !0)
|
|
614
|
+
])) : o("", !0),
|
|
615
|
+
c("p", null, j(M(t)("ui.footer.copyright", {
|
|
616
|
+
years: a.value,
|
|
617
|
+
holder: e.holder
|
|
618
|
+
})), 1),
|
|
619
|
+
O(i.$slots, "end")
|
|
620
|
+
], 2)], 2));
|
|
621
|
+
}
|
|
622
|
+
});
|
|
623
|
+
// src/lib/initials.ts
|
|
624
|
+
function kr(e) {
|
|
625
|
+
let t = e.trim().split(/\s+/).filter(Boolean);
|
|
626
|
+
if (!t.length) return "";
|
|
627
|
+
let n = t[0], r = t.length > 1 ? t[t.length - 1] : "";
|
|
628
|
+
return (n[0] + (r[0] ?? "")).toUpperCase();
|
|
629
|
+
}
|
|
630
|
+
// src/components/Avatar/Avatar.vue?vue&type=script&setup=true&lang.ts
|
|
631
|
+
var Ar = ["aria-label"], jr = [
|
|
632
|
+
"src",
|
|
633
|
+
"width",
|
|
634
|
+
"height"
|
|
635
|
+
], Mr = {
|
|
375
636
|
key: 1,
|
|
376
637
|
"aria-hidden": "true"
|
|
377
|
-
},
|
|
638
|
+
}, Nr = { class: "flex flex-col" }, Pr = {
|
|
378
639
|
key: 0,
|
|
379
640
|
class: "truncate px-4 pt-3 text-xs font-bold text-black/65 uppercase"
|
|
380
|
-
},
|
|
641
|
+
}, Fr = { class: "flex items-center gap-3 px-4 py-3" }, Ir = [
|
|
642
|
+
"src",
|
|
643
|
+
"width",
|
|
644
|
+
"height"
|
|
645
|
+
], Lr = { class: "flex min-w-0 flex-col" }, Rr = { class: "truncate font-bold" }, zr = {
|
|
381
646
|
key: 0,
|
|
382
647
|
class: "truncate text-sm text-black/65"
|
|
383
|
-
},
|
|
648
|
+
}, Br = ["href"], Vr = [
|
|
384
649
|
"role",
|
|
385
650
|
"aria-label",
|
|
386
651
|
"aria-hidden"
|
|
387
|
-
],
|
|
652
|
+
], Hr = [
|
|
653
|
+
"src",
|
|
654
|
+
"width",
|
|
655
|
+
"height"
|
|
656
|
+
], Ur = {
|
|
388
657
|
key: 1,
|
|
389
658
|
"aria-hidden": "true"
|
|
390
|
-
},
|
|
659
|
+
}, Wr = "relative inline-flex shrink-0 items-center justify-center overflow-hidden rounded-full bg-primary font-bold text-white select-none", Gr = /* @__PURE__ */ f({
|
|
391
660
|
__name: "Avatar",
|
|
392
661
|
props: {
|
|
393
662
|
user: {},
|
|
@@ -403,7 +672,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
403
672
|
] }
|
|
404
673
|
},
|
|
405
674
|
setup(e) {
|
|
406
|
-
let t = e, r = i(() =>
|
|
675
|
+
let t = e, r = i(() => kr(t.user.name)), l = E(!1);
|
|
407
676
|
z(() => t.user.avatar, () => l.value = !1);
|
|
408
677
|
let d = i(() => !!t.user.avatar && !l.value), f = i(() => d.value || !r.value ? t.user.name : `${r.value}, ${t.user.name}`), p = {
|
|
409
678
|
xs: "size-5 text-xs",
|
|
@@ -411,8 +680,14 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
411
680
|
md: "size-9 text-sm",
|
|
412
681
|
lg: "size-12 text-base",
|
|
413
682
|
xl: "size-16 text-xl"
|
|
683
|
+
}, m = {
|
|
684
|
+
xs: 20,
|
|
685
|
+
sm: 28,
|
|
686
|
+
md: 36,
|
|
687
|
+
lg: 48,
|
|
688
|
+
xl: 64
|
|
414
689
|
};
|
|
415
|
-
return (i,
|
|
690
|
+
return (i, h) => e.profile ? (w(), a(er, {
|
|
416
691
|
key: 0,
|
|
417
692
|
mode: "hover",
|
|
418
693
|
"open-delay": 300,
|
|
@@ -424,56 +699,68 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
424
699
|
},
|
|
425
700
|
ui: { content: "w-64" }
|
|
426
701
|
}, {
|
|
427
|
-
content: V(() => [c("div",
|
|
428
|
-
class: y(M(X)(
|
|
702
|
+
content: V(() => [c("div", Nr, [e.user.organisation ? (w(), s("p", Pr, j(e.user.organisation), 1)) : o("", !0), c("div", Fr, [c("span", {
|
|
703
|
+
class: y(M(X)(Wr, p.lg)),
|
|
429
704
|
"aria-hidden": "true"
|
|
430
705
|
}, [d.value ? (w(), s("img", {
|
|
431
706
|
key: 0,
|
|
432
707
|
src: e.user.avatar,
|
|
708
|
+
width: m.lg,
|
|
709
|
+
height: m.lg,
|
|
710
|
+
loading: "lazy",
|
|
711
|
+
decoding: "async",
|
|
433
712
|
alt: "",
|
|
434
713
|
class: "size-full object-cover"
|
|
435
|
-
}, null, 8,
|
|
436
|
-
c("span",
|
|
437
|
-
e.user.role ? (w(), s("span",
|
|
714
|
+
}, null, 8, Ir)) : (w(), s(n, { key: 1 }, [u(j(r.value), 1)], 64))], 2), c("div", Lr, [
|
|
715
|
+
c("span", Rr, j(e.user.name), 1),
|
|
716
|
+
e.user.role ? (w(), s("span", zr, j(e.user.role), 1)) : o("", !0),
|
|
438
717
|
e.user.email ? (w(), s("a", {
|
|
439
718
|
key: 1,
|
|
440
719
|
href: `mailto:${e.user.email}`,
|
|
441
720
|
class: "truncate rounded-sm text-sm text-black/65 underline-offset-2 hover:text-black hover:underline outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
442
|
-
}, j(e.user.email), 9,
|
|
721
|
+
}, j(e.user.email), 9, Br)) : o("", !0)
|
|
443
722
|
])])])]),
|
|
444
723
|
default: V(() => [c("button", {
|
|
445
724
|
type: "button",
|
|
446
725
|
"aria-label": f.value,
|
|
447
|
-
class: y(M(X)(
|
|
726
|
+
class: y(M(X)(Wr, p[e.size], "cursor-pointer outline-2 outline-offset-1 outline-transparent transition focus-visible:outline-focus", t.class))
|
|
448
727
|
}, [d.value ? (w(), s("img", {
|
|
449
728
|
key: 0,
|
|
450
729
|
src: e.user.avatar,
|
|
730
|
+
width: m[e.size],
|
|
731
|
+
height: m[e.size],
|
|
732
|
+
loading: "lazy",
|
|
733
|
+
decoding: "async",
|
|
451
734
|
alt: "",
|
|
452
735
|
class: "size-full object-cover",
|
|
453
|
-
onError:
|
|
454
|
-
}, null, 40,
|
|
736
|
+
onError: h[0] ||= (e) => l.value = !0
|
|
737
|
+
}, null, 40, jr)) : (w(), s("span", Mr, j(r.value), 1))], 10, Ar)]),
|
|
455
738
|
_: 1
|
|
456
739
|
})) : (w(), s("span", {
|
|
457
740
|
key: 1,
|
|
458
741
|
role: e.decorative ? void 0 : "img",
|
|
459
742
|
"aria-label": e.decorative ? void 0 : e.user.name,
|
|
460
743
|
"aria-hidden": e.decorative || void 0,
|
|
461
|
-
class: y(M(X)(
|
|
744
|
+
class: y(M(X)(Wr, p[e.size], t.class))
|
|
462
745
|
}, [d.value ? (w(), s("img", {
|
|
463
746
|
key: 0,
|
|
464
747
|
src: e.user.avatar,
|
|
748
|
+
width: m[e.size],
|
|
749
|
+
height: m[e.size],
|
|
750
|
+
loading: "lazy",
|
|
751
|
+
decoding: "async",
|
|
465
752
|
alt: "",
|
|
466
753
|
class: "size-full object-cover",
|
|
467
|
-
onError:
|
|
468
|
-
}, null, 40,
|
|
754
|
+
onError: h[1] ||= (e) => l.value = !0
|
|
755
|
+
}, null, 40, Hr)) : (w(), s("span", Ur, j(r.value), 1))], 10, Vr));
|
|
469
756
|
}
|
|
470
|
-
}),
|
|
757
|
+
}), Kr = { class: "flex flex-col" }, qr = {
|
|
471
758
|
key: 0,
|
|
472
759
|
class: "border-b border-black/15"
|
|
473
|
-
},
|
|
760
|
+
}, Jr = ["title"], Yr = { class: "grid grid-cols-[auto_minmax(0,1fr)] items-start gap-x-3 gap-y-2 px-4 py-3" }, Xr = { class: "flex min-w-0 flex-col" }, Zr = ["title"], Qr = ["title"], $r = {
|
|
474
761
|
key: 1,
|
|
475
762
|
class: "flex items-center gap-2 border-t border-black/15 px-4 py-3"
|
|
476
|
-
},
|
|
763
|
+
}, ei = /* @__PURE__ */ f({
|
|
477
764
|
__name: "Header",
|
|
478
765
|
props: {
|
|
479
766
|
title: {},
|
|
@@ -520,7 +807,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
520
807
|
"sign-in"
|
|
521
808
|
],
|
|
522
809
|
setup(e, { emit: t }) {
|
|
523
|
-
let { t: n } = K(), r = e, l = t, f = i(() =>
|
|
810
|
+
let { t: n } = K(), r = e, l = t, f = i(() => kr(r.user?.name ?? "")), p = i(() => r.user ? r.user.avatar || !f.value ? n("ui.header.account", { name: r.user.name }) : n("ui.header.accountWithInitials", {
|
|
524
811
|
initials: f.value,
|
|
525
812
|
name: r.user.name
|
|
526
813
|
}) : ""), m = i(() => {
|
|
@@ -541,7 +828,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
541
828
|
class: y(M(X)("-ml-2.5", e.ui?.menu)),
|
|
542
829
|
onClick: i[0] ||= (e) => l("menu")
|
|
543
830
|
}, {
|
|
544
|
-
default: V(() => [d(M(
|
|
831
|
+
default: V(() => [d(M(Ae))]),
|
|
545
832
|
_: 1
|
|
546
833
|
}, 8, [
|
|
547
834
|
"aria-label",
|
|
@@ -558,43 +845,43 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
558
845
|
t.$slots.trailing || t.$slots.account || e.user || e.signIn ? (w(), s("div", {
|
|
559
846
|
key: 2,
|
|
560
847
|
class: y(M(X)("flex shrink-0 items-center gap-1", e.ui?.trailing))
|
|
561
|
-
}, [O(t.$slots, "trailing"), O(t.$slots, "account", {}, () => [e.user ? (w(), a(
|
|
848
|
+
}, [O(t.$slots, "trailing"), O(t.$slots, "account", {}, () => [e.user ? (w(), a(er, {
|
|
562
849
|
key: 0,
|
|
563
850
|
content: { align: "end" },
|
|
564
851
|
ui: { content: M(X)("w-80", e.ui?.userMenu) }
|
|
565
852
|
}, {
|
|
566
|
-
content: V(({ close: n }) => [c("div",
|
|
567
|
-
e.user.organisation || t.$slots.organisation ? (w(), s("div",
|
|
853
|
+
content: V(({ close: n }) => [c("div", Kr, [
|
|
854
|
+
e.user.organisation || t.$slots.organisation ? (w(), s("div", qr, [O(t.$slots, "organisation", { close: n }, () => [c("p", {
|
|
568
855
|
class: "truncate px-4 py-3 text-xs font-bold text-black/65 uppercase",
|
|
569
856
|
title: e.user.organisation
|
|
570
|
-
}, j(e.user.organisation), 9,
|
|
571
|
-
c("div",
|
|
572
|
-
d(
|
|
857
|
+
}, j(e.user.organisation), 9, Jr)])])) : o("", !0),
|
|
858
|
+
c("div", Yr, [
|
|
859
|
+
d(Gr, {
|
|
573
860
|
user: e.user,
|
|
574
861
|
size: "lg",
|
|
575
862
|
decorative: ""
|
|
576
863
|
}, null, 8, ["user"]),
|
|
577
|
-
c("div",
|
|
864
|
+
c("div", Xr, [c("span", {
|
|
578
865
|
class: "truncate font-bold",
|
|
579
866
|
title: e.user.name
|
|
580
|
-
}, j(e.user.name), 9,
|
|
867
|
+
}, j(e.user.name), 9, Zr), e.user.email ? (w(), s("span", {
|
|
581
868
|
key: 0,
|
|
582
869
|
class: "truncate text-sm text-black/65",
|
|
583
870
|
title: e.user.email
|
|
584
|
-
}, j(e.user.email), 9,
|
|
871
|
+
}, j(e.user.email), 9, Qr)) : o("", !0)]),
|
|
585
872
|
e.userActions.includes("account-settings") ? (w(), a(Z, {
|
|
586
873
|
key: 0,
|
|
587
874
|
size: "sm",
|
|
588
875
|
class: "col-start-2 justify-self-start",
|
|
589
876
|
onClick: (e) => g("account-settings", n)
|
|
590
877
|
}, {
|
|
591
|
-
leading: V(() => [d(M(
|
|
878
|
+
leading: V(() => [d(M(Ie))]),
|
|
592
879
|
default: V(() => [i[2] ||= u(" Account settings ", -1)]),
|
|
593
880
|
_: 1
|
|
594
881
|
}, 8, ["onClick"])) : o("", !0)
|
|
595
882
|
]),
|
|
596
883
|
O(t.$slots, "account-menu", { close: n }),
|
|
597
|
-
e.userActions.includes("switch-account") || e.userActions.includes("log-out") ? (w(), s("div",
|
|
884
|
+
e.userActions.includes("switch-account") || e.userActions.includes("log-out") ? (w(), s("div", $r, [e.userActions.includes("switch-account") ? (w(), a(Z, {
|
|
598
885
|
key: 0,
|
|
599
886
|
onClick: (e) => g("switch-account", n)
|
|
600
887
|
}, {
|
|
@@ -606,7 +893,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
606
893
|
class: "ml-auto",
|
|
607
894
|
onClick: (e) => g("log-out", n)
|
|
608
895
|
}, {
|
|
609
|
-
leading: V(() => [d(M(
|
|
896
|
+
leading: V(() => [d(M(ke))]),
|
|
610
897
|
default: V(() => [i[4] ||= u(" Log out ", -1)]),
|
|
611
898
|
_: 1
|
|
612
899
|
}, 8, ["onClick"])) : o("", !0)])) : o("", !0)
|
|
@@ -617,7 +904,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
617
904
|
"aria-label": p.value,
|
|
618
905
|
class: "-mr-1.5 rounded-full"
|
|
619
906
|
}, {
|
|
620
|
-
default: V(() => [d(
|
|
907
|
+
default: V(() => [d(Gr, {
|
|
621
908
|
user: e.user,
|
|
622
909
|
size: "sm",
|
|
623
910
|
decorative: ""
|
|
@@ -636,7 +923,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
636
923
|
})) : o("", !0)])], 2)) : o("", !0)
|
|
637
924
|
], 2));
|
|
638
925
|
}
|
|
639
|
-
}),
|
|
926
|
+
}), ti = "inline-flex shrink-0 items-center whitespace-nowrap rounded-full border border-black/15 font-bold", ni = /* @__PURE__ */ f({
|
|
640
927
|
__name: "Badge",
|
|
641
928
|
props: {
|
|
642
929
|
color: { default: "basic" },
|
|
@@ -662,7 +949,7 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
662
949
|
md: "h-6 px-2 text-xs gap-1 [&_svg]:size-3.5",
|
|
663
950
|
lg: "h-7 px-2.5 text-sm gap-1.5 [&_svg]:size-4"
|
|
664
951
|
};
|
|
665
|
-
return (i, a) => (w(), s("span", { class: y(M(X)(
|
|
952
|
+
return (i, a) => (w(), s("span", { class: y(M(X)(ti, n[e.color], r[e.size], t.class)) }, [
|
|
666
953
|
O(i.$slots, "leading"),
|
|
667
954
|
O(i.$slots, "default"),
|
|
668
955
|
O(i.$slots, "trailing")
|
|
@@ -670,27 +957,27 @@ var Kn = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
670
957
|
}
|
|
671
958
|
});
|
|
672
959
|
// src/components/Sidebar/sidebar.ts
|
|
673
|
-
function
|
|
960
|
+
function ri(e = [], t = []) {
|
|
674
961
|
for (let n of [...e, ...t.flatMap((e) => e.items)]) {
|
|
675
962
|
if (n.active) return [n];
|
|
676
963
|
if (n.children?.length) {
|
|
677
|
-
let e =
|
|
964
|
+
let e = ri(n.children);
|
|
678
965
|
if (e.length) return [n, ...e];
|
|
679
966
|
}
|
|
680
967
|
}
|
|
681
968
|
return [];
|
|
682
969
|
}
|
|
683
970
|
// src/components/Sidebar/Sidebar.vue?vue&type=script&setup=true&lang.ts
|
|
684
|
-
var
|
|
971
|
+
var ii = ["data-collapsed"], ai = ["aria-label"], oi = ["data-level"], si = {
|
|
685
972
|
key: 0,
|
|
686
973
|
class: "-mb-2 flex flex-col gap-1 border-b border-black/15 pb-2"
|
|
687
|
-
},
|
|
974
|
+
}, ci = ["title"], li = {
|
|
688
975
|
key: 0,
|
|
689
976
|
class: "relative flex h-6 items-center px-3"
|
|
690
|
-
},
|
|
977
|
+
}, ui = ["id"], di = ["aria-labelledby"], fi = {
|
|
691
978
|
key: 0,
|
|
692
979
|
class: "sr-only"
|
|
693
|
-
},
|
|
980
|
+
}, pi = "transition-opacity duration-150 motion-reduce:transition-none", mi = "bg-primary/10 font-bold text-primary not-aria-disabled:not-disabled:hover:bg-primary/15", hi = "font-bold text-primary", gi = /* @__PURE__ */ f({
|
|
694
981
|
__name: "Sidebar",
|
|
695
982
|
props: /*@__PURE__*/ g({
|
|
696
983
|
items: { default: () => [] },
|
|
@@ -726,7 +1013,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
726
1013
|
e.push(r), t = r.children;
|
|
727
1014
|
}
|
|
728
1015
|
return e;
|
|
729
|
-
}), S = i(() => x.value[x.value.length - 1]), C = i(() => S.value ? [{ items: S.value.children }] : g.value), T = i(() =>
|
|
1016
|
+
}), S = i(() => x.value[x.value.length - 1]), C = i(() => S.value ? [{ items: S.value.children }] : g.value), T = i(() => ri(f.items, f.sections)), A = i(() => new Set(T.value.slice(0, -1).map((e) => e.label)));
|
|
730
1017
|
z(() => T.value.map((e) => e.label).join("\0"), () => {
|
|
731
1018
|
b.value = T.value.slice(0, -1).map((e) => e.label);
|
|
732
1019
|
}, { immediate: !0 });
|
|
@@ -771,10 +1058,10 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
771
1058
|
"aria-disabled": !0
|
|
772
1059
|
} : e.to === void 0 ? { href: e.href } : { to: e.to };
|
|
773
1060
|
}
|
|
774
|
-
function
|
|
1061
|
+
function q(e, t) {
|
|
775
1062
|
e.disabled ? t.preventDefault() : e.children?.length ? U(e) : (e.onSelect?.(t), p("select", e, t));
|
|
776
1063
|
}
|
|
777
|
-
let
|
|
1064
|
+
let J = [
|
|
778
1065
|
"flex h-9.5 w-full items-center gap-3 overflow-hidden rounded px-3 text-left text-sm whitespace-nowrap select-none",
|
|
779
1066
|
"cursor-pointer transition [&_svg]:size-4 [&_svg]:shrink-0",
|
|
780
1067
|
"outline-2 -outline-offset-2 outline-transparent forced-colors:not-focus-visible:outline-0",
|
|
@@ -800,21 +1087,21 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
800
1087
|
key: N.value,
|
|
801
1088
|
"data-level": N.value,
|
|
802
1089
|
class: "flex flex-col gap-4"
|
|
803
|
-
}, [S.value ? (w(), s("div",
|
|
1090
|
+
}, [S.value ? (w(), s("div", si, [c("button", {
|
|
804
1091
|
type: "button",
|
|
805
1092
|
"data-back": "",
|
|
806
1093
|
title: m.value ? M(l)("ui.sidebar.backFrom", { name: S.value.label }) : void 0,
|
|
807
|
-
class: y(M(X)(
|
|
1094
|
+
class: y(M(X)(J, "font-bold", e.ui?.item)),
|
|
808
1095
|
onClick: ee
|
|
809
|
-
}, [d(M(
|
|
1096
|
+
}, [d(M(pe), { "aria-hidden": "true" }), c("span", { class: y(M(X)("min-w-0 flex-1 truncate", pi, m.value && "opacity-0")) }, [i[1] ||= c("span", { class: "sr-only" }, "Back from ", -1), u(j(S.value.label), 1)], 2)], 10, ci)])) : o("", !0), (w(!0), s(n, null, D(C.value, (r, i) => (w(), s("div", {
|
|
810
1097
|
key: i,
|
|
811
1098
|
class: "flex flex-col gap-1"
|
|
812
|
-
}, [r.label ? (w(), s("div",
|
|
1099
|
+
}, [r.label ? (w(), s("div", li, [c("div", {
|
|
813
1100
|
id: `${M(h)}-section-${i}`,
|
|
814
|
-
class: y(M(X)("truncate text-xs font-bold text-black/65 uppercase",
|
|
815
|
-
}, j(r.label), 11,
|
|
1101
|
+
class: y(M(X)("truncate text-xs font-bold text-black/65 uppercase", pi, m.value && "opacity-0"))
|
|
1102
|
+
}, j(r.label), 11, ui), c("div", {
|
|
816
1103
|
"aria-hidden": "true",
|
|
817
|
-
class: y(M(X)("absolute inset-x-2 top-1/2 border-t border-black/15",
|
|
1104
|
+
class: y(M(X)("absolute inset-x-2 top-1/2 border-t border-black/15", pi, !m.value && "opacity-0"))
|
|
818
1105
|
}, null, 2)])) : o("", !0), c("ul", {
|
|
819
1106
|
class: "flex flex-col gap-1",
|
|
820
1107
|
"aria-labelledby": r.label ? `${M(h)}-section-${i}` : void 0
|
|
@@ -823,8 +1110,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
823
1110
|
"data-parent": n.children?.length ? n.label : void 0,
|
|
824
1111
|
"aria-current": n.active ? "page" : void 0,
|
|
825
1112
|
title: m.value ? n.label : void 0,
|
|
826
|
-
class: M(X)(
|
|
827
|
-
onClick: (e) =>
|
|
1113
|
+
class: M(X)(J, n.active && mi, A.value.has(n.label) && hi, e.ui?.item),
|
|
1114
|
+
onClick: (e) => q(n, e)
|
|
828
1115
|
}), {
|
|
829
1116
|
default: V(() => [O(t.$slots, "item", {
|
|
830
1117
|
item: n,
|
|
@@ -835,20 +1122,20 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
835
1122
|
key: 0,
|
|
836
1123
|
"aria-hidden": "true"
|
|
837
1124
|
})) : o("", !0),
|
|
838
|
-
c("span", { class: y(M(X)("min-w-0 flex-1 truncate",
|
|
839
|
-
n.badge !== void 0 && n.badge !== "" ? (w(), a(
|
|
1125
|
+
c("span", { class: y(M(X)("min-w-0 flex-1 truncate", pi, m.value && "opacity-0")) }, [u(j(n.label), 1), n.children?.length ? (w(), s("span", fi, ", more options")) : o("", !0)], 2),
|
|
1126
|
+
n.badge !== void 0 && n.badge !== "" ? (w(), a(ni, {
|
|
840
1127
|
key: 1,
|
|
841
1128
|
size: "sm",
|
|
842
1129
|
color: n.badgeColor,
|
|
843
|
-
class: y(M(X)(
|
|
1130
|
+
class: y(M(X)(pi, m.value && "opacity-0"))
|
|
844
1131
|
}, {
|
|
845
1132
|
default: V(() => [u(j(n.badge), 1)]),
|
|
846
1133
|
_: 2
|
|
847
1134
|
}, 1032, ["color", "class"])) : o("", !0),
|
|
848
|
-
n.children?.length ? (w(), a(M(
|
|
1135
|
+
n.children?.length ? (w(), a(M(me), {
|
|
849
1136
|
key: 2,
|
|
850
1137
|
"aria-hidden": "true",
|
|
851
|
-
class: y(M(X)("opacity-70",
|
|
1138
|
+
class: y(M(X)("opacity-70", pi, m.value && "opacity-0"))
|
|
852
1139
|
}, null, 8, ["class"])) : o("", !0)
|
|
853
1140
|
])]),
|
|
854
1141
|
_: 2
|
|
@@ -858,9 +1145,9 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
858
1145
|
"title",
|
|
859
1146
|
"class",
|
|
860
1147
|
"onClick"
|
|
861
|
-
]))]))), 128))], 8,
|
|
1148
|
+
]))]))), 128))], 8, di)]))), 128))], 8, oi))]),
|
|
862
1149
|
_: 3
|
|
863
|
-
}, 16)], 10,
|
|
1150
|
+
}, 16)], 10, ai),
|
|
864
1151
|
t.$slots.footer || e.collapsible ? (w(), s("div", {
|
|
865
1152
|
key: 1,
|
|
866
1153
|
class: y(M(X)("flex shrink-0 flex-col gap-1 overflow-hidden border-t border-black/15 p-2", e.ui?.footer))
|
|
@@ -873,12 +1160,12 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
873
1160
|
class: "self-start",
|
|
874
1161
|
onClick: i[0] ||= (e) => m.value = !m.value
|
|
875
1162
|
}, {
|
|
876
|
-
default: V(() => [m.value ? (w(), a(M(
|
|
1163
|
+
default: V(() => [m.value ? (w(), a(M(Pe), { key: 0 })) : (w(), a(M(Ne), { key: 1 }))]),
|
|
877
1164
|
_: 1
|
|
878
1165
|
}, 8, ["aria-label", "aria-expanded"])) : o("", !0)], 2)) : o("", !0)
|
|
879
|
-
], 10,
|
|
1166
|
+
], 10, ii));
|
|
880
1167
|
}
|
|
881
|
-
}),
|
|
1168
|
+
}), _i = "h-1.5 overflow-hidden rounded-full bg-black/10", vi = "h-full rounded-full bg-primary transition-[translate,background-color] duration-300 ease-out motion-reduce:transition-none", yi = /* @__PURE__ */ f({
|
|
882
1169
|
__name: "Progress",
|
|
883
1170
|
props: {
|
|
884
1171
|
value: { default: null },
|
|
@@ -898,23 +1185,23 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
898
1185
|
current: l.value,
|
|
899
1186
|
total: r.max
|
|
900
1187
|
}) : `${Math.round(u.value)}%`;
|
|
901
|
-
return (t, i) => (w(), a(M(
|
|
1188
|
+
return (t, i) => (w(), a(M(Wt), {
|
|
902
1189
|
"model-value": o.value ? null : l.value,
|
|
903
1190
|
max: e.max,
|
|
904
1191
|
"get-value-label": () => e.label,
|
|
905
1192
|
"get-value-text": d,
|
|
906
1193
|
"aria-busy": o.value || void 0,
|
|
907
|
-
class: y(M(X)(e.segments && !o.value ? "flex gap-1" :
|
|
1194
|
+
class: y(M(X)(e.segments && !o.value ? "flex gap-1" : _i, r.class))
|
|
908
1195
|
}, {
|
|
909
1196
|
default: V(() => [e.segments && !o.value ? (w(!0), s(n, { key: 0 }, D(e.max, (e) => (w(), s("div", {
|
|
910
1197
|
key: e,
|
|
911
|
-
class: y(M(X)(
|
|
912
|
-
}, [c("div", { class: y(M(X)(
|
|
1198
|
+
class: y(M(X)(_i, "flex-1"))
|
|
1199
|
+
}, [c("div", { class: y(M(X)(vi, e <= l.value ? "translate-x-0" : "-translate-x-full")) }, null, 2)], 2))), 128)) : o.value ? (w(), a(M(Ut), {
|
|
913
1200
|
key: 1,
|
|
914
1201
|
class: "h-full w-2/5 rounded-full bg-primary animate-progress-indeterminate motion-reduce:w-full motion-reduce:translate-x-0 motion-reduce:animate-pulse"
|
|
915
|
-
})) : (w(), a(M(
|
|
1202
|
+
})) : (w(), a(M(Ut), {
|
|
916
1203
|
key: 2,
|
|
917
|
-
class: y(
|
|
1204
|
+
class: y(vi),
|
|
918
1205
|
style: x({ translate: `${u.value - 100}% 0` })
|
|
919
1206
|
}, null, 8, ["style"]))]),
|
|
920
1207
|
_: 1
|
|
@@ -926,14 +1213,14 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
926
1213
|
"class"
|
|
927
1214
|
]));
|
|
928
1215
|
}
|
|
929
|
-
}),
|
|
1216
|
+
}), bi = { class: "text-black" }, xi = { class: "flex items-start gap-4" }, Si = { class: "flex min-w-0 flex-1 flex-col gap-1" }, Ci = { key: 0 }, wi = {
|
|
930
1217
|
key: 1,
|
|
931
1218
|
class: "sr-only"
|
|
932
|
-
},
|
|
1219
|
+
}, Ti = {
|
|
933
1220
|
key: 1,
|
|
934
1221
|
"aria-live": "polite",
|
|
935
1222
|
class: "sr-only"
|
|
936
|
-
},
|
|
1223
|
+
}, Ei = ["role", "aria-labelledby"], Di = "textarea, [contenteditable=\"true\"], input[type=checkbox], input[type=radio], input[type=button], input[type=submit]", Oi = /* @__PURE__ */ f({
|
|
937
1224
|
__name: "Slideover",
|
|
938
1225
|
props: /*@__PURE__*/ g({
|
|
939
1226
|
title: {},
|
|
@@ -1014,7 +1301,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1014
1301
|
}
|
|
1015
1302
|
function L(e) {
|
|
1016
1303
|
let t = e.target;
|
|
1017
|
-
!r.steps || e.defaultPrevented || e.isComposing || t.tagName !== "INPUT" || t.closest(
|
|
1304
|
+
!r.steps || e.defaultPrevented || e.isComposing || t.tagName !== "INPUT" || t.closest(Di) || (e.preventDefault(), I());
|
|
1018
1305
|
}
|
|
1019
1306
|
let R = 0;
|
|
1020
1307
|
function B(e) {
|
|
@@ -1040,32 +1327,32 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1040
1327
|
let n = t.querySelector("[autofocus], [data-autofocus]"), i = window.matchMedia("(pointer: coarse)").matches ? null : t.querySelector(H), a = n ?? i;
|
|
1041
1328
|
a && (e.preventDefault(), a.focus());
|
|
1042
1329
|
}
|
|
1043
|
-
let G = () => typeof r.portal == "string" || r.portal instanceof HTMLElement ? r.portal : void 0,
|
|
1330
|
+
let G = () => typeof r.portal == "string" || r.portal instanceof HTMLElement ? r.portal : void 0, q = {
|
|
1044
1331
|
right: "inset-y-0 right-0 w-full max-w-md border-l data-[state=open]:animate-slide-in-right data-[state=closed]:animate-slide-out-right",
|
|
1045
1332
|
left: "inset-y-0 left-0 w-full max-w-md border-r data-[state=open]:animate-slide-in-left data-[state=closed]:animate-slide-out-left",
|
|
1046
1333
|
top: "inset-x-0 top-0 max-h-full border-b data-[state=open]:animate-slide-in-top data-[state=closed]:animate-slide-out-top",
|
|
1047
1334
|
bottom: "inset-x-0 bottom-0 max-h-full border-t data-[state=open]:animate-slide-in-bottom data-[state=closed]:animate-slide-out-bottom"
|
|
1048
|
-
},
|
|
1049
|
-
return (t, r) => (w(), a(M(
|
|
1335
|
+
}, J = ["fixed z-50 flex flex-col bg-white text-black border-black/15 shadow-xl outline-none", "motion-reduce:data-[state=open]:animate-fade-in motion-reduce:data-[state=closed]:animate-fade-out"];
|
|
1336
|
+
return (t, r) => (w(), a(M(St), {
|
|
1050
1337
|
open: m.value,
|
|
1051
1338
|
modal: e.modal,
|
|
1052
1339
|
"onUpdate:open": h
|
|
1053
1340
|
}, {
|
|
1054
|
-
default: V(() => [t.$slots.default ? (w(), a(M(
|
|
1341
|
+
default: V(() => [t.$slots.default ? (w(), a(M(wt), {
|
|
1055
1342
|
key: 0,
|
|
1056
1343
|
"as-child": ""
|
|
1057
1344
|
}, {
|
|
1058
1345
|
default: V(() => [O(t.$slots, "default")]),
|
|
1059
1346
|
_: 3
|
|
1060
|
-
})) : o("", !0), d(M(
|
|
1347
|
+
})) : o("", !0), d(M(xt), {
|
|
1061
1348
|
disabled: e.portal === !1,
|
|
1062
1349
|
to: G()
|
|
1063
1350
|
}, {
|
|
1064
|
-
default: V(() => [e.overlay ? (w(), a(M(
|
|
1351
|
+
default: V(() => [e.overlay ? (w(), a(M(bt), {
|
|
1065
1352
|
key: 0,
|
|
1066
1353
|
class: y(M(X)("fixed inset-0 z-50 bg-black/40 data-[state=open]:animate-fade-in data-[state=closed]:animate-fade-out", e.ui?.overlay))
|
|
1067
|
-
}, null, 8, ["class"])) : o("", !0), d(M(
|
|
1068
|
-
class: M(X)(
|
|
1354
|
+
}, null, 8, ["class"])) : o("", !0), d(M(vt), _(e.content, {
|
|
1355
|
+
class: M(X)(J, q[e.side], e.ui?.content),
|
|
1069
1356
|
onEscapeKeyDown: B,
|
|
1070
1357
|
onInteractOutside: B,
|
|
1071
1358
|
onOpenAutoFocus: W
|
|
@@ -1079,8 +1366,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1079
1366
|
key: 0,
|
|
1080
1367
|
id: T,
|
|
1081
1368
|
class: "text-sm text-black/65"
|
|
1082
|
-
}, [u(" Step " + j(b.value + 1) + " of " + j(x.value) + ": ", 1), c("span",
|
|
1083
|
-
e.steps ? (w(), a(
|
|
1369
|
+
}, [u(" Step " + j(b.value + 1) + " of " + j(x.value) + ": ", 1), c("span", bi, j(e.steps[b.value]), 1)])) : o("", !0),
|
|
1370
|
+
e.steps ? (w(), a(yi, {
|
|
1084
1371
|
key: 1,
|
|
1085
1372
|
label: e.title ?? M(n)("ui.slideover.steps"),
|
|
1086
1373
|
segments: "",
|
|
@@ -1091,21 +1378,21 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1091
1378
|
"value",
|
|
1092
1379
|
"max"
|
|
1093
1380
|
])) : o("", !0),
|
|
1094
|
-
c("div",
|
|
1095
|
-
d(M(
|
|
1381
|
+
c("div", xi, [O(t.$slots, "header", { close: g }, () => [c("div", Si, [
|
|
1382
|
+
d(M(Ct), { class: y(e.title || t.$slots.title ? M(X)("text-lg", e.ui?.title) : "sr-only") }, {
|
|
1096
1383
|
default: V(() => [O(t.$slots, "title", {}, () => [u(j(e.title), 1)])]),
|
|
1097
1384
|
_: 3
|
|
1098
1385
|
}, 8, ["class"]),
|
|
1099
|
-
e.description || t.$slots.description || e.steps ? (w(), a(M(
|
|
1386
|
+
e.description || t.$slots.description || e.steps ? (w(), a(M(yt), {
|
|
1100
1387
|
key: 0,
|
|
1101
1388
|
as: "div",
|
|
1102
1389
|
class: "flex flex-col gap-1 text-sm text-black/65"
|
|
1103
1390
|
}, {
|
|
1104
|
-
default: V(() => [e.description || t.$slots.description ? (w(), s("p",
|
|
1391
|
+
default: V(() => [e.description || t.$slots.description ? (w(), s("p", Ci, [O(t.$slots, "description", {}, () => [u(j(e.description), 1)])])) : o("", !0), e.steps ? (w(), s("p", wi, j(D.value), 1)) : o("", !0)]),
|
|
1105
1392
|
_: 3
|
|
1106
1393
|
})) : o("", !0),
|
|
1107
|
-
e.steps ? (w(), s("p",
|
|
1108
|
-
]), e.close ? (w(), a(M(
|
|
1394
|
+
e.steps ? (w(), s("p", Ti, j(k.value), 1)) : o("", !0)
|
|
1395
|
+
]), e.close ? (w(), a(M(_t), {
|
|
1109
1396
|
key: 0,
|
|
1110
1397
|
"as-child": ""
|
|
1111
1398
|
}, {
|
|
@@ -1115,7 +1402,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1115
1402
|
"aria-label": M(n)("ui.slideover.close"),
|
|
1116
1403
|
class: "-my-1.5 -mr-3 shrink-0"
|
|
1117
1404
|
}, {
|
|
1118
|
-
default: V(() => [d(M(
|
|
1405
|
+
default: V(() => [d(M(Ve))]),
|
|
1119
1406
|
_: 1
|
|
1120
1407
|
}, 8, ["aria-label"])]),
|
|
1121
1408
|
_: 1
|
|
@@ -1131,7 +1418,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1131
1418
|
}, [O(t.$slots, "body", {
|
|
1132
1419
|
close: g,
|
|
1133
1420
|
step: b.value
|
|
1134
|
-
})], 42,
|
|
1421
|
+
})], 42, Ei),
|
|
1135
1422
|
t.$slots.footer || e.steps ? (w(), s("footer", {
|
|
1136
1423
|
key: 1,
|
|
1137
1424
|
class: y(M(X)("flex justify-end gap-2 border-t border-black/15 px-6 py-4", e.ui?.footer))
|
|
@@ -1144,7 +1431,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1144
1431
|
_: 2
|
|
1145
1432
|
}, [b.value > 0 ? {
|
|
1146
1433
|
name: "leading",
|
|
1147
|
-
fn: V(() => [d(M(
|
|
1434
|
+
fn: V(() => [d(M(pe))]),
|
|
1148
1435
|
key: "0"
|
|
1149
1436
|
} : void 0]), 1032, ["disabled"]), d(Z, {
|
|
1150
1437
|
variant: "primary",
|
|
@@ -1155,7 +1442,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1155
1442
|
_: 2
|
|
1156
1443
|
}, [S.value ? void 0 : {
|
|
1157
1444
|
name: "trailing",
|
|
1158
|
-
fn: V(() => [d(M(
|
|
1445
|
+
fn: V(() => [d(M(me))]),
|
|
1159
1446
|
key: "0"
|
|
1160
1447
|
}]), 1032, ["status"])])], 2)) : o("", !0)
|
|
1161
1448
|
])]),
|
|
@@ -1166,7 +1453,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1166
1453
|
_: 3
|
|
1167
1454
|
}, 8, ["open", "modal"]));
|
|
1168
1455
|
}
|
|
1169
|
-
}),
|
|
1456
|
+
}), ki = ["href"], Ai = { class: "flex flex-1" }, ji = { class: "sticky top-12 hidden h-[calc(100dvh-var(--spacing)*12)] shrink-0 self-start lg:flex" }, Mi = { class: "flex min-w-0 flex-1 flex-col" }, Ni = /* @__PURE__ */ f({
|
|
1170
1457
|
__name: "AppShell",
|
|
1171
1458
|
props: /*@__PURE__*/ g({
|
|
1172
1459
|
title: {},
|
|
@@ -1183,6 +1470,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1183
1470
|
type: Boolean,
|
|
1184
1471
|
default: !0
|
|
1185
1472
|
},
|
|
1473
|
+
footer: {},
|
|
1474
|
+
launcher: { type: [Boolean, Object] },
|
|
1186
1475
|
linkComponent: {},
|
|
1187
1476
|
header: {},
|
|
1188
1477
|
sidebar: {},
|
|
@@ -1220,7 +1509,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1220
1509
|
f = window.matchMedia("(min-width: 64rem)"), f.addEventListener("change", m);
|
|
1221
1510
|
}), S(() => f?.removeEventListener("change", m));
|
|
1222
1511
|
let h = P(), g = `${h}-main`, v = `${h}-sidebar`;
|
|
1223
|
-
return (t, f) => (w(), a(M(
|
|
1512
|
+
return (t, f) => (w(), a(M(yn), {
|
|
1224
1513
|
"delay-duration": 400,
|
|
1225
1514
|
"skip-delay-duration": 300
|
|
1226
1515
|
}, {
|
|
@@ -1228,8 +1517,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1228
1517
|
c("a", {
|
|
1229
1518
|
href: `#${g}`,
|
|
1230
1519
|
class: "sr-only z-50 rounded bg-white px-4 py-2 text-sm focus:not-sr-only focus:fixed focus:top-2 focus:left-2 focus:outline-2 focus:outline-focus"
|
|
1231
|
-
}, " Skip to content ", 8,
|
|
1232
|
-
d(
|
|
1520
|
+
}, " Skip to content ", 8, ki),
|
|
1521
|
+
d(ei, _(e.header, {
|
|
1233
1522
|
title: e.title,
|
|
1234
1523
|
"title-to": e.titleTo,
|
|
1235
1524
|
"link-component": e.linkComponent,
|
|
@@ -1259,15 +1548,15 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1259
1548
|
class: "-ml-2.5 max-lg:hidden",
|
|
1260
1549
|
onClick: f[0] ||= (e) => s.value = !s.value
|
|
1261
1550
|
}, {
|
|
1262
|
-
default: V(() => [d(M(
|
|
1551
|
+
default: V(() => [d(M(Ae))]),
|
|
1263
1552
|
_: 1
|
|
1264
1553
|
}, 8, ["aria-label", "aria-expanded"])) : o("", !0), O(t.$slots, "header-leading")]),
|
|
1265
1554
|
default: V(() => [O(t.$slots, "header-middle")]),
|
|
1266
1555
|
_: 2
|
|
1267
1556
|
}, [
|
|
1268
|
-
t.$slots["header-trailing"] ? {
|
|
1557
|
+
t.$slots["header-trailing"] || e.launcher ? {
|
|
1269
1558
|
name: "trailing",
|
|
1270
|
-
fn: V(() => [O(t.$slots, "header-trailing")]),
|
|
1559
|
+
fn: V(() => [O(t.$slots, "header-trailing"), e.launcher ? (w(), a(ur, b(_({ key: 0 }, e.launcher === !0 ? {} : e.launcher)), null, 16)) : o("", !0)]),
|
|
1271
1560
|
key: "0"
|
|
1272
1561
|
} : void 0,
|
|
1273
1562
|
t.$slots.account ? {
|
|
@@ -1295,8 +1584,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1295
1584
|
"sign-in",
|
|
1296
1585
|
"ui"
|
|
1297
1586
|
]),
|
|
1298
|
-
c("div",
|
|
1299
|
-
c("div",
|
|
1587
|
+
c("div", Ai, [
|
|
1588
|
+
c("div", ji, [d(gi, _(e.sidebar, {
|
|
1300
1589
|
id: v,
|
|
1301
1590
|
collapsed: s.value,
|
|
1302
1591
|
"onUpdate:collapsed": f[6] ||= (e) => s.value = e,
|
|
@@ -1317,7 +1606,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1317
1606
|
"sections",
|
|
1318
1607
|
"link-component"
|
|
1319
1608
|
])]),
|
|
1320
|
-
d(
|
|
1609
|
+
d(Oi, {
|
|
1321
1610
|
open: u.value,
|
|
1322
1611
|
"onUpdate:open": f[8] ||= (e) => u.value = e,
|
|
1323
1612
|
side: "left",
|
|
@@ -1329,7 +1618,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1329
1618
|
body: "flex p-0"
|
|
1330
1619
|
}
|
|
1331
1620
|
}, {
|
|
1332
|
-
body: V(() => [d(
|
|
1621
|
+
body: V(() => [d(gi, _(e.sidebar, {
|
|
1333
1622
|
items: e.items,
|
|
1334
1623
|
sections: e.sections,
|
|
1335
1624
|
"link-component": e.linkComponent,
|
|
@@ -1346,17 +1635,20 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1346
1635
|
])]),
|
|
1347
1636
|
_: 3
|
|
1348
1637
|
}, 8, ["open", "title"]),
|
|
1349
|
-
c("main", {
|
|
1638
|
+
c("div", Mi, [c("main", {
|
|
1350
1639
|
id: g,
|
|
1351
1640
|
tabindex: "-1",
|
|
1352
1641
|
class: y(M(X)("min-w-0 flex-1 outline-none", e.ui?.main))
|
|
1353
|
-
}, [O(t.$slots, "default")], 2)
|
|
1642
|
+
}, [O(t.$slots, "default")], 2), e.footer ? (w(), a(Or, b(_({ key: 0 }, {
|
|
1643
|
+
linkComponent: e.linkComponent,
|
|
1644
|
+
...e.footer
|
|
1645
|
+
})), null, 16)) : o("", !0)])
|
|
1354
1646
|
])
|
|
1355
1647
|
], 2)]),
|
|
1356
1648
|
_: 3
|
|
1357
1649
|
}));
|
|
1358
1650
|
}
|
|
1359
|
-
}),
|
|
1651
|
+
}), Pi = ["aria-label"], Fi = { class: "flex flex-wrap items-center gap-x-1.5 gap-y-1" }, Ii = ["title"], Li = { class: "truncate" }, Ri = { class: "truncate" }, zi = ["title"], Bi = { class: "truncate" }, Vi = "inline-flex max-w-60 min-w-0 items-center gap-1.5 [&_svg]:size-3.5 [&_svg]:shrink-0", Hi = /* @__PURE__ */ f({
|
|
1360
1652
|
__name: "Breadcrumb",
|
|
1361
1653
|
props: {
|
|
1362
1654
|
items: {},
|
|
@@ -1392,29 +1684,29 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1392
1684
|
return (t, l) => (w(), s("nav", {
|
|
1393
1685
|
"aria-label": e.label ?? M(r)("ui.breadcrumb.label"),
|
|
1394
1686
|
class: y(M(X)("min-w-0 text-sm", i.class))
|
|
1395
|
-
}, [c("ol",
|
|
1687
|
+
}, [c("ol", Fi, [(w(!0), s(n, null, D(e.items, (t, n) => (w(), s("li", {
|
|
1396
1688
|
key: `${t.label}-${n}`,
|
|
1397
1689
|
class: "flex min-w-0 items-center gap-1.5"
|
|
1398
1690
|
}, [n === e.items.length - 1 ? (w(), s("span", {
|
|
1399
1691
|
key: 0,
|
|
1400
1692
|
"aria-current": "page",
|
|
1401
1693
|
title: t.label,
|
|
1402
|
-
class: y(M(X)(
|
|
1694
|
+
class: y(M(X)(Vi, "text-black"))
|
|
1403
1695
|
}, [t.icon ? (w(), a(k(t.icon), {
|
|
1404
1696
|
key: 0,
|
|
1405
1697
|
"aria-hidden": "true"
|
|
1406
|
-
})) : o("", !0), c("span",
|
|
1698
|
+
})) : o("", !0), c("span", Li, j(t.label), 1)], 10, Ii)) : u(t) ? (w(), a(k(u(t)), _({
|
|
1407
1699
|
key: 1,
|
|
1408
1700
|
ref_for: !0
|
|
1409
1701
|
}, d(t), {
|
|
1410
1702
|
title: t.label,
|
|
1411
|
-
class: M(X)(
|
|
1703
|
+
class: M(X)(Vi, p),
|
|
1412
1704
|
onClick: (e) => f(t, e)
|
|
1413
1705
|
}), {
|
|
1414
1706
|
default: V(() => [t.icon ? (w(), a(k(t.icon), {
|
|
1415
1707
|
key: 0,
|
|
1416
1708
|
"aria-hidden": "true"
|
|
1417
|
-
})) : o("", !0), c("span",
|
|
1709
|
+
})) : o("", !0), c("span", Ri, j(t.label), 1)]),
|
|
1418
1710
|
_: 2
|
|
1419
1711
|
}, 1040, [
|
|
1420
1712
|
"title",
|
|
@@ -1423,17 +1715,17 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1423
1715
|
])) : (w(), s("span", {
|
|
1424
1716
|
key: 2,
|
|
1425
1717
|
title: t.label,
|
|
1426
|
-
class: y(M(X)(
|
|
1718
|
+
class: y(M(X)(Vi, "text-black/65"))
|
|
1427
1719
|
}, [t.icon ? (w(), a(k(t.icon), {
|
|
1428
1720
|
key: 0,
|
|
1429
1721
|
"aria-hidden": "true"
|
|
1430
|
-
})) : o("", !0), c("span",
|
|
1722
|
+
})) : o("", !0), c("span", Bi, j(t.label), 1)], 10, zi)), n < e.items.length - 1 ? (w(), a(M(me), {
|
|
1431
1723
|
key: 3,
|
|
1432
1724
|
"aria-hidden": "true",
|
|
1433
1725
|
class: "size-3.5 shrink-0 text-black/40"
|
|
1434
|
-
})) : o("", !0)]))), 128))])], 10,
|
|
1726
|
+
})) : o("", !0)]))), 128))])], 10, Pi));
|
|
1435
1727
|
}
|
|
1436
|
-
}),
|
|
1728
|
+
}), Ui = /* @__PURE__ */ f({
|
|
1437
1729
|
__name: "Menu",
|
|
1438
1730
|
props: {
|
|
1439
1731
|
items: {},
|
|
@@ -1462,8 +1754,8 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1462
1754
|
"data-highlighted:bg-black/10",
|
|
1463
1755
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
1464
1756
|
];
|
|
1465
|
-
return (l, f) => (w(), a(M(
|
|
1466
|
-
default: V(() => [d(M(
|
|
1757
|
+
return (l, f) => (w(), a(M(Ot), { modal: !1 }, {
|
|
1758
|
+
default: V(() => [d(M(kt), { "as-child": "" }, {
|
|
1467
1759
|
default: V(() => [d(Z, {
|
|
1468
1760
|
variant: "ghost",
|
|
1469
1761
|
square: "",
|
|
@@ -1471,7 +1763,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1471
1763
|
"aria-label": e.label,
|
|
1472
1764
|
class: y(t.class)
|
|
1473
1765
|
}, {
|
|
1474
|
-
default: V(() => [d(M(
|
|
1766
|
+
default: V(() => [d(M(xe))]),
|
|
1475
1767
|
_: 1
|
|
1476
1768
|
}, 8, [
|
|
1477
1769
|
"size",
|
|
@@ -1479,14 +1771,14 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1479
1771
|
"class"
|
|
1480
1772
|
])]),
|
|
1481
1773
|
_: 1
|
|
1482
|
-
}), d(M(
|
|
1483
|
-
default: V(() => [d(M(
|
|
1774
|
+
}), d(M(Dt), null, {
|
|
1775
|
+
default: V(() => [d(M(Tt), {
|
|
1484
1776
|
align: "end",
|
|
1485
1777
|
"side-offset": 4,
|
|
1486
1778
|
"collision-padding": 8,
|
|
1487
|
-
class: y(M(X)(M(
|
|
1779
|
+
class: y(M(X)(M(Qn), "min-w-48 p-1"))
|
|
1488
1780
|
}, {
|
|
1489
|
-
default: V(() => [(w(!0), s(n, null, D(e.items, (e) => (w(), a(M(
|
|
1781
|
+
default: V(() => [(w(!0), s(n, null, D(e.items, (e) => (w(), a(M(Et), _({
|
|
1490
1782
|
key: e.label,
|
|
1491
1783
|
as: r(e)
|
|
1492
1784
|
}, { ref_for: !0 }, i(e), {
|
|
@@ -1511,18 +1803,18 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1511
1803
|
_: 1
|
|
1512
1804
|
}));
|
|
1513
1805
|
}
|
|
1514
|
-
}),
|
|
1806
|
+
}), Wi = { class: "flex flex-wrap items-start justify-between gap-x-6 gap-y-3" }, Gi = { class: "flex min-w-0 flex-col gap-1" }, Ki = { class: "flex flex-wrap items-center gap-x-2 gap-y-1" }, qi = ["aria-label"], Ji = {
|
|
1515
1807
|
key: 0,
|
|
1516
1808
|
class: "flex shrink-0 items-center gap-2 px-3 text-sm font-bold",
|
|
1517
1809
|
"aria-live": "polite"
|
|
1518
|
-
},
|
|
1810
|
+
}, Yi = {
|
|
1519
1811
|
"aria-hidden": "true",
|
|
1520
1812
|
inert: "",
|
|
1521
1813
|
class: "invisible absolute top-0 left-0 size-0 overflow-hidden"
|
|
1522
|
-
},
|
|
1814
|
+
}, Xi = {
|
|
1523
1815
|
key: 1,
|
|
1524
1816
|
class: "flex shrink-0 items-center gap-2 px-3 text-sm"
|
|
1525
|
-
},
|
|
1817
|
+
}, Zi = /* @__PURE__ */ f({
|
|
1526
1818
|
__name: "PageHeader",
|
|
1527
1819
|
props: {
|
|
1528
1820
|
title: {},
|
|
@@ -1565,12 +1857,12 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1565
1857
|
}), S(() => x?.disconnect()), z(() => r.toolbar?.map((e) => `${e.label}${e.disabled ? "-" : ""}`).join("|"), () => v(b));
|
|
1566
1858
|
let T = i(() => (r.toolbar ?? []).slice(0, _.value)), A = i(() => (r.toolbar ?? []).slice(_.value));
|
|
1567
1859
|
return (i, p) => (w(), s("header", { class: y(M(X)("flex flex-col gap-2", r.class)) }, [
|
|
1568
|
-
e.breadcrumb && e.breadcrumb.length > 1 ? (w(), a(
|
|
1860
|
+
e.breadcrumb && e.breadcrumb.length > 1 ? (w(), a(Hi, {
|
|
1569
1861
|
key: 0,
|
|
1570
1862
|
items: e.breadcrumb,
|
|
1571
1863
|
"link-component": e.linkComponent
|
|
1572
1864
|
}, null, 8, ["items", "link-component"])) : o("", !0),
|
|
1573
|
-
c("div",
|
|
1865
|
+
c("div", Wi, [c("div", Gi, [c("div", Ki, [c("h1", { class: y(M(X)("min-w-0 text-2xl font-bold break-words", e.ui?.title)) }, j(e.title), 3), O(i.$slots, "badge")]), e.description || i.$slots.description ? (w(), s("p", {
|
|
1574
1866
|
key: 0,
|
|
1575
1867
|
class: y(M(X)("max-w-prose text-sm text-black/65", e.ui?.description))
|
|
1576
1868
|
}, [O(i.$slots, "description", {}, () => [u(j(e.description), 1)])], 2)) : o("", !0)]), i.$slots.actions ? (w(), s("div", {
|
|
@@ -1583,7 +1875,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1583
1875
|
"aria-label": M(t)("ui.pageHeader.actions", { title: e.title }),
|
|
1584
1876
|
class: y(M(X)("flex items-center gap-1 rounded-lg border border-black/15 bg-white p-1", e.ui?.toolbar))
|
|
1585
1877
|
}, [
|
|
1586
|
-
i.$slots["toolbar-start"] ? (w(), s("div",
|
|
1878
|
+
i.$slots["toolbar-start"] ? (w(), s("div", Ji, [O(i.$slots, "toolbar-start")])) : o("", !0),
|
|
1587
1879
|
c("div", {
|
|
1588
1880
|
ref_key: "fitArea",
|
|
1589
1881
|
ref: h,
|
|
@@ -1612,7 +1904,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1612
1904
|
"disabled",
|
|
1613
1905
|
"onClick"
|
|
1614
1906
|
]))), 128)),
|
|
1615
|
-
A.value.length ? (w(), a(
|
|
1907
|
+
A.value.length ? (w(), a(Ui, {
|
|
1616
1908
|
key: 0,
|
|
1617
1909
|
items: A.value,
|
|
1618
1910
|
label: M(t)("ui.pageHeader.moreActions"),
|
|
@@ -1623,7 +1915,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1623
1915
|
"label",
|
|
1624
1916
|
"link-component"
|
|
1625
1917
|
])) : o("", !0),
|
|
1626
|
-
c("div",
|
|
1918
|
+
c("div", Yi, [c("div", {
|
|
1627
1919
|
ref_key: "measure",
|
|
1628
1920
|
ref: g,
|
|
1629
1921
|
class: "flex w-max gap-1"
|
|
@@ -1649,18 +1941,18 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1649
1941
|
_: 1
|
|
1650
1942
|
})], 512)])
|
|
1651
1943
|
], 512),
|
|
1652
|
-
i.$slots["toolbar-end"] ? (w(), s("div",
|
|
1653
|
-
], 10,
|
|
1944
|
+
i.$slots["toolbar-end"] ? (w(), s("div", Xi, [O(i.$slots, "toolbar-end")])) : o("", !0)
|
|
1945
|
+
], 10, qi)) : o("", !0),
|
|
1654
1946
|
O(i.$slots, "default")
|
|
1655
1947
|
], 2));
|
|
1656
1948
|
}
|
|
1657
|
-
}),
|
|
1949
|
+
}), Qi = { class: "flex min-w-0 flex-col gap-0.5" }, $i = {
|
|
1658
1950
|
class: "text-sm",
|
|
1659
1951
|
"aria-hidden": "true"
|
|
1660
|
-
},
|
|
1952
|
+
}, ea = {
|
|
1661
1953
|
key: 0,
|
|
1662
1954
|
class: "text-xs text-black/65"
|
|
1663
|
-
},
|
|
1955
|
+
}, ta = { class: "w-full shrink-0 sm:w-80" }, na = /* @__PURE__ */ f({
|
|
1664
1956
|
__name: "SettingsRow",
|
|
1665
1957
|
props: {
|
|
1666
1958
|
label: {},
|
|
@@ -1675,12 +1967,12 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1675
1967
|
},
|
|
1676
1968
|
setup(e) {
|
|
1677
1969
|
let t = e;
|
|
1678
|
-
return (n, r) => (w(), s("div", { class: y(M(X)("flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between sm:gap-6", t.class)) }, [c("div",
|
|
1970
|
+
return (n, r) => (w(), s("div", { class: y(M(X)("flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between sm:gap-6", t.class)) }, [c("div", Qi, [c("p", $i, j(e.label), 1), e.description ? (w(), s("p", ea, j(e.description), 1)) : o("", !0)]), c("div", ta, [O(n.$slots, "default")])], 2));
|
|
1679
1971
|
}
|
|
1680
|
-
}),
|
|
1972
|
+
}), ra = ["aria-label"], ia = ["aria-label"], aa = { "aria-hidden": "true" }, oa = { class: "flex max-h-72 flex-col gap-2 overflow-y-auto p-3 text-sm [scrollbar-width:thin]" }, sa = { class: "min-w-0 truncate" }, ca = {
|
|
1681
1973
|
key: 0,
|
|
1682
1974
|
class: "ml-auto shrink-0 truncate text-xs text-black/65"
|
|
1683
|
-
},
|
|
1975
|
+
}, la = /* @__PURE__ */ f({
|
|
1684
1976
|
__name: "AvatarGroup",
|
|
1685
1977
|
props: {
|
|
1686
1978
|
users: {},
|
|
@@ -1726,7 +2018,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1726
2018
|
}, [(w(!0), s(n, null, D(a.value, (t, n) => (w(), s("span", {
|
|
1727
2019
|
key: `${t.name}-${n}`,
|
|
1728
2020
|
class: y(M(X)("relative flex rounded-full ring-white hover:z-10 focus-within:z-10", f[e.size], n > 0 && u[e.size]))
|
|
1729
|
-
}, [d(
|
|
2021
|
+
}, [d(Gr, {
|
|
1730
2022
|
user: t,
|
|
1731
2023
|
size: e.size,
|
|
1732
2024
|
profile: e.profile
|
|
@@ -1737,7 +2029,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1737
2029
|
])], 2))), 128)), l.value.length ? (w(), s("span", {
|
|
1738
2030
|
key: 0,
|
|
1739
2031
|
class: y(M(X)("relative flex rounded-full ring-white hover:z-10 focus-within:z-10", f[e.size], u[e.size]))
|
|
1740
|
-
}, [d(
|
|
2032
|
+
}, [d(er, {
|
|
1741
2033
|
mode: "hover",
|
|
1742
2034
|
"open-delay": 300,
|
|
1743
2035
|
"close-delay": 150,
|
|
@@ -1748,17 +2040,17 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1748
2040
|
},
|
|
1749
2041
|
ui: { content: "w-56" }
|
|
1750
2042
|
}, {
|
|
1751
|
-
content: V(() => [c("ul",
|
|
2043
|
+
content: V(() => [c("ul", oa, [(w(!0), s(n, null, D(l.value, (e, t) => (w(), s("li", {
|
|
1752
2044
|
key: `${e.name}-${t}`,
|
|
1753
2045
|
class: "flex items-center gap-2"
|
|
1754
2046
|
}, [
|
|
1755
|
-
d(
|
|
2047
|
+
d(Gr, {
|
|
1756
2048
|
user: e,
|
|
1757
2049
|
size: "xs",
|
|
1758
2050
|
decorative: ""
|
|
1759
2051
|
}, null, 8, ["user"]),
|
|
1760
|
-
c("span",
|
|
1761
|
-
e.role ? (w(), s("span",
|
|
2052
|
+
c("span", sa, j(e.name), 1),
|
|
2053
|
+
e.role ? (w(), s("span", ca, j(e.role), 1)) : o("", !0)
|
|
1762
2054
|
]))), 128))])]),
|
|
1763
2055
|
default: V(() => [c("button", {
|
|
1764
2056
|
type: "button",
|
|
@@ -1767,17 +2059,17 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1767
2059
|
names: l.value.map((e) => e.name).join(", ")
|
|
1768
2060
|
}),
|
|
1769
2061
|
class: y(M(X)("inline-flex shrink-0 cursor-pointer items-center justify-center rounded-full bg-surface font-bold text-black select-none", "outline-2 outline-offset-1 outline-transparent transition focus-visible:outline-focus", p[e.size]))
|
|
1770
|
-
}, [c("span",
|
|
2062
|
+
}, [c("span", aa, "+" + j(l.value.length), 1)], 10, ia)]),
|
|
1771
2063
|
_: 1
|
|
1772
|
-
})], 2)) : o("", !0)], 10,
|
|
2064
|
+
})], 2)) : o("", !0)], 10, ra));
|
|
1773
2065
|
}
|
|
1774
|
-
}),
|
|
2066
|
+
}), ua = { class: "flex min-w-0 flex-col gap-1" }, da = {
|
|
1775
2067
|
key: 1,
|
|
1776
2068
|
class: "text-sm text-black/65"
|
|
1777
|
-
},
|
|
2069
|
+
}, fa = {
|
|
1778
2070
|
key: 0,
|
|
1779
2071
|
class: "flex shrink-0 items-center gap-2"
|
|
1780
|
-
},
|
|
2072
|
+
}, pa = /* @__PURE__ */ f({
|
|
1781
2073
|
__name: "Card",
|
|
1782
2074
|
props: {
|
|
1783
2075
|
title: {},
|
|
@@ -1811,25 +2103,25 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1811
2103
|
default: V(() => [c("div", { class: y(M(X)("flex min-w-0 flex-1 flex-col gap-4", l[e.padding], e.ui?.body)) }, [e.title || e.description || i.$slots.header || i.$slots.actions ? (w(), s("div", {
|
|
1812
2104
|
key: 0,
|
|
1813
2105
|
class: y(M(X)("flex items-start justify-between gap-3", e.padding === "none" && "px-4 pt-4 sm:px-6 sm:pt-6", e.ui?.header))
|
|
1814
|
-
}, [O(i.$slots, "header", {}, () => [c("div",
|
|
2106
|
+
}, [O(i.$slots, "header", {}, () => [c("div", ua, [e.title ? (w(), a(k(`h${e.headingLevel}`), {
|
|
1815
2107
|
key: 0,
|
|
1816
2108
|
id: n,
|
|
1817
2109
|
class: "text-base font-bold"
|
|
1818
2110
|
}, {
|
|
1819
2111
|
default: V(() => [u(j(e.title), 1)]),
|
|
1820
2112
|
_: 1
|
|
1821
|
-
})) : o("", !0), e.description ? (w(), s("p",
|
|
2113
|
+
})) : o("", !0), e.description ? (w(), s("p", da, j(e.description), 1)) : o("", !0)])]), i.$slots.actions ? (w(), s("div", fa, [O(i.$slots, "actions")])) : o("", !0)], 2)) : o("", !0), O(i.$slots, "default")], 2), i.$slots.footer ? (w(), s("div", {
|
|
1822
2114
|
key: 0,
|
|
1823
2115
|
class: y(M(X)("flex flex-wrap justify-end gap-2 border-t border-black/15", d[e.padding], e.ui?.footer))
|
|
1824
2116
|
}, [O(i.$slots, "footer")], 2)) : o("", !0)]),
|
|
1825
2117
|
_: 3
|
|
1826
2118
|
}, 8, ["aria-labelledby", "class"]));
|
|
1827
2119
|
}
|
|
1828
|
-
}),
|
|
2120
|
+
}), ma = { class: "min-w-0 truncate" }, ha = [
|
|
1829
2121
|
"tabindex",
|
|
1830
2122
|
"aria-label",
|
|
1831
2123
|
"disabled"
|
|
1832
|
-
],
|
|
2124
|
+
], ga = /* @__PURE__ */ f({
|
|
1833
2125
|
__name: "Chip",
|
|
1834
2126
|
props: {
|
|
1835
2127
|
size: { default: "md" },
|
|
@@ -1862,7 +2154,7 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1862
2154
|
};
|
|
1863
2155
|
return (t, p) => (w(), s("span", { class: y(M(X)(a, l[e.size], e.removable && u[e.size], e.disabled && "opacity-40", r.class)) }, [
|
|
1864
2156
|
O(t.$slots, "leading"),
|
|
1865
|
-
c("span",
|
|
2157
|
+
c("span", ma, [O(t.$slots, "default")]),
|
|
1866
2158
|
e.removable ? (w(), s("button", {
|
|
1867
2159
|
key: 0,
|
|
1868
2160
|
type: "button",
|
|
@@ -1871,10 +2163,10 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1871
2163
|
disabled: e.disabled,
|
|
1872
2164
|
class: y(M(X)("flex shrink-0 cursor-pointer items-center justify-center rounded-sm transition", "not-disabled:hover:bg-black/10 not-disabled:active:bg-black/15 disabled:cursor-not-allowed", "outline-2 outline-offset-0 outline-transparent focus-visible:outline-focus", f[e.size])),
|
|
1873
2165
|
onClick: p[0] ||= (e) => i("remove")
|
|
1874
|
-
}, [d(M(
|
|
2166
|
+
}, [d(M(Ve), { "aria-hidden": "true" })], 10, ha)) : o("", !0)
|
|
1875
2167
|
], 2));
|
|
1876
2168
|
}
|
|
1877
|
-
}),
|
|
2169
|
+
}), _a = ["role", "aria-label"], va = { class: "shrink-0" }, ya = /* @__PURE__ */ f({
|
|
1878
2170
|
__name: "Divider",
|
|
1879
2171
|
props: {
|
|
1880
2172
|
orientation: { default: "horizontal" },
|
|
@@ -1903,12 +2195,12 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1903
2195
|
"aria-hidden": "true",
|
|
1904
2196
|
class: "h-px flex-1 bg-black/15"
|
|
1905
2197
|
}, null, -1),
|
|
1906
|
-
c("span",
|
|
2198
|
+
c("span", va, [O(n.$slots, "default", {}, () => [u(j(e.label), 1)])]),
|
|
1907
2199
|
r[1] ||= c("span", {
|
|
1908
2200
|
"aria-hidden": "true",
|
|
1909
2201
|
class: "h-px flex-1 bg-black/15"
|
|
1910
2202
|
}, null, -1)
|
|
1911
|
-
], 10,
|
|
2203
|
+
], 10, _a)) : (w(), a(M(on), {
|
|
1912
2204
|
key: 1,
|
|
1913
2205
|
orientation: e.orientation,
|
|
1914
2206
|
decorative: e.decorative,
|
|
@@ -1921,17 +2213,17 @@ var Cr = ["data-collapsed"], wr = ["aria-label"], Tr = ["data-level"], Er = {
|
|
|
1921
2213
|
}
|
|
1922
2214
|
});
|
|
1923
2215
|
// src/components/ChangeIndicator/changeIndicator.ts
|
|
1924
|
-
function
|
|
2216
|
+
function ba(e, t) {
|
|
1925
2217
|
return t ? `${e} ${t}` : String(e);
|
|
1926
2218
|
}
|
|
1927
|
-
function
|
|
2219
|
+
function xa(e, t) {
|
|
1928
2220
|
return String(e) !== String(t);
|
|
1929
2221
|
}
|
|
1930
2222
|
// src/components/ChangeIndicator/ChangeIndicator.vue?vue&type=script&setup=true&lang.ts
|
|
1931
|
-
var
|
|
2223
|
+
var Sa = { class: "sr-only" }, Ca = {
|
|
1932
2224
|
"aria-hidden": "true",
|
|
1933
2225
|
class: "font-normal line-through decoration-blue/60"
|
|
1934
|
-
},
|
|
2226
|
+
}, wa = { "aria-hidden": "true" }, Ta = /* @__PURE__ */ f({
|
|
1935
2227
|
__name: "ChangeIndicator",
|
|
1936
2228
|
props: {
|
|
1937
2229
|
from: {},
|
|
@@ -1946,24 +2238,24 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
1946
2238
|
] }
|
|
1947
2239
|
},
|
|
1948
2240
|
setup(e) {
|
|
1949
|
-
let { t } = K(), r = e, a = i(() =>
|
|
2241
|
+
let { t } = K(), r = e, a = i(() => xa(r.from, r.to)), l = i(() => t("ui.changeIndicator.changed", {
|
|
1950
2242
|
from: r.from,
|
|
1951
|
-
to:
|
|
2243
|
+
to: ba(r.to, r.unit)
|
|
1952
2244
|
}));
|
|
1953
2245
|
return (t, i) => a.value ? (w(), s("span", {
|
|
1954
2246
|
key: 0,
|
|
1955
2247
|
class: y(M(X)("inline-flex items-center gap-1 whitespace-nowrap rounded-full border border-blue/30 bg-blue/10 px-2 text-xs font-bold text-blue", r.class))
|
|
1956
2248
|
}, [
|
|
1957
|
-
c("span",
|
|
1958
|
-
c("span",
|
|
2249
|
+
c("span", Sa, j(l.value), 1),
|
|
2250
|
+
c("span", Ca, j(e.from), 1),
|
|
1959
2251
|
d(M(re), {
|
|
1960
2252
|
"aria-hidden": "true",
|
|
1961
2253
|
class: "size-3 shrink-0"
|
|
1962
2254
|
}),
|
|
1963
|
-
c("span",
|
|
2255
|
+
c("span", wa, [u(j(e.to), 1), e.unit ? (w(), s(n, { key: 0 }, [u(j(e.unit), 1)], 64)) : o("", !0)])
|
|
1964
2256
|
], 2)) : o("", !0);
|
|
1965
2257
|
}
|
|
1966
|
-
}),
|
|
2258
|
+
}), Ea = ["aria-label"], Da = { class: "max-w-64 px-3 py-2 text-xs" }, Oa = /* @__PURE__ */ f({
|
|
1967
2259
|
__name: "InfoTip",
|
|
1968
2260
|
props: {
|
|
1969
2261
|
text: {},
|
|
@@ -1978,27 +2270,27 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
1978
2270
|
},
|
|
1979
2271
|
setup(e) {
|
|
1980
2272
|
let t = e, n = `${P()}-description`;
|
|
1981
|
-
return (r, i) => (w(), a(
|
|
2273
|
+
return (r, i) => (w(), a(er, {
|
|
1982
2274
|
mode: "hover",
|
|
1983
2275
|
content: {
|
|
1984
2276
|
side: "top",
|
|
1985
2277
|
sideOffset: 6
|
|
1986
2278
|
}
|
|
1987
2279
|
}, {
|
|
1988
|
-
content: V(() => [c("p",
|
|
2280
|
+
content: V(() => [c("p", Da, j(e.text), 1)]),
|
|
1989
2281
|
default: V(() => [c("button", {
|
|
1990
2282
|
type: "button",
|
|
1991
2283
|
"aria-label": e.label,
|
|
1992
2284
|
"aria-describedby": n,
|
|
1993
2285
|
class: y(M(X)("inline-flex shrink-0 rounded-full p-0.5 align-middle text-black transition hover:bg-black/10 data-[state=open]:bg-black/10", "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus [&_svg]:size-4", t.class))
|
|
1994
|
-
}, [d(M(
|
|
2286
|
+
}, [d(M(ye), { "aria-hidden": "true" }), c("span", {
|
|
1995
2287
|
id: n,
|
|
1996
2288
|
hidden: ""
|
|
1997
|
-
}, j(e.text), 1)], 10,
|
|
2289
|
+
}, j(e.text), 1)], 10, Ea)]),
|
|
1998
2290
|
_: 1
|
|
1999
2291
|
}));
|
|
2000
2292
|
}
|
|
2001
|
-
}),
|
|
2293
|
+
}), ka = { class: "overflow-hidden" }, Aa = ["id"], ja = /* @__PURE__ */ f({
|
|
2002
2294
|
__name: "FieldMessage",
|
|
2003
2295
|
props: {
|
|
2004
2296
|
id: {},
|
|
@@ -2015,13 +2307,13 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2015
2307
|
success: "text-green",
|
|
2016
2308
|
loading: "text-black/65"
|
|
2017
2309
|
}, p = {
|
|
2018
|
-
error:
|
|
2019
|
-
success:
|
|
2310
|
+
error: _e,
|
|
2311
|
+
success: ve
|
|
2020
2312
|
};
|
|
2021
2313
|
return (t, i) => (w(), s(n, null, [c("div", {
|
|
2022
2314
|
"aria-hidden": "true",
|
|
2023
2315
|
class: y(M(X)("-mt-1.5 grid transition-[grid-template-rows,visibility] duration-150 ease-out motion-reduce:transition-none", r.value ? "grid-rows-[1fr]" : "invisible grid-rows-[0fr] delay-100"))
|
|
2024
|
-
}, [c("div",
|
|
2316
|
+
}, [c("div", ka, [c("p", { class: y(M(X)("flex items-center gap-1 pt-1.5 text-xs transition-[translate,opacity,color] ease-out motion-reduce:transition-none [&_svg]:size-3.5 [&_svg]:shrink-0", d.value && f[d.value], r.value ? "duration-150 delay-100" : "-translate-y-1 opacity-0 duration-100")) }, [d.value === "loading" ? (w(), a(Gn, {
|
|
2025
2317
|
key: 0,
|
|
2026
2318
|
size: "sm",
|
|
2027
2319
|
class: "size-3.5"
|
|
@@ -2029,12 +2321,12 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2029
2321
|
id: e.id,
|
|
2030
2322
|
"aria-live": "polite",
|
|
2031
2323
|
class: "sr-only"
|
|
2032
|
-
}, j(e.text), 9,
|
|
2324
|
+
}, j(e.text), 9, Aa)], 64));
|
|
2033
2325
|
}
|
|
2034
|
-
}),
|
|
2326
|
+
}), Ma = { class: "flex items-center gap-1" }, Na = ["hidden"], Pa = {
|
|
2035
2327
|
key: 0,
|
|
2036
2328
|
class: "col-start-2 row-start-1 flex h-5 items-center text-xs"
|
|
2037
|
-
},
|
|
2329
|
+
}, Fa = "input, textarea, [role=\"spinbutton\"], [contenteditable=\"true\"]", Ia = /* @__PURE__ */ f({
|
|
2038
2330
|
__name: "FormField",
|
|
2039
2331
|
props: {
|
|
2040
2332
|
label: {},
|
|
@@ -2057,7 +2349,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2057
2349
|
let { t } = K(), n = e, r = P(), l = `${r}-control`, u = `${r}-label`, f = `${r}-helper`, p = `${r}-status`, m = i(() => n.errorText ? "error" : n.status), h = i(() => n.errorText || n.statusText), g = i(() => [n.helper && f, h.value && p].filter(Boolean).join(" ") || void 0);
|
|
2058
2350
|
function _(e) {
|
|
2059
2351
|
let t = e.target;
|
|
2060
|
-
n.disabled || t.closest(`${
|
|
2352
|
+
n.disabled || t.closest(`${Fa}, button`) || (e.preventDefault(), e.currentTarget.querySelector(Fa)?.focus());
|
|
2061
2353
|
}
|
|
2062
2354
|
function v() {
|
|
2063
2355
|
let e = document.getElementById(l);
|
|
@@ -2075,12 +2367,12 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2075
2367
|
loading: ""
|
|
2076
2368
|
};
|
|
2077
2369
|
return (r, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", n.class)) }, [c("div", { class: y(M(X)("grid grid-cols-[minmax(0,1fr)_auto]", !e.hideLabel && "gap-y-1.5", r.$slots["label-trailing"] && "gap-x-3")) }, [
|
|
2078
|
-
c("div", { class: y(M(X)("col-start-1 row-start-1 flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div",
|
|
2370
|
+
c("div", { class: y(M(X)("col-start-1 row-start-1 flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div", Ma, [c("label", {
|
|
2079
2371
|
id: u,
|
|
2080
2372
|
for: l,
|
|
2081
2373
|
class: "text-sm",
|
|
2082
2374
|
onClick: v
|
|
2083
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
2375
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
2084
2376
|
key: 0,
|
|
2085
2377
|
text: e.helper,
|
|
2086
2378
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -2089,7 +2381,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2089
2381
|
id: f,
|
|
2090
2382
|
hidden: e.helperPlacement === "icon",
|
|
2091
2383
|
class: "text-xs text-black/65"
|
|
2092
|
-
}, j(e.helper), 9,
|
|
2384
|
+
}, j(e.helper), 9, Na)) : o("", !0)], 2),
|
|
2093
2385
|
c("div", {
|
|
2094
2386
|
class: y(M(X)(b, "col-span-2 row-start-2", m.value && x[m.value], e.disabled && "opacity-40 cursor-not-allowed")),
|
|
2095
2387
|
onPointerdown: _
|
|
@@ -2103,19 +2395,20 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2103
2395
|
}),
|
|
2104
2396
|
O(r.$slots, "trailing")
|
|
2105
2397
|
], 34),
|
|
2106
|
-
r.$slots["label-trailing"] ? (w(), s("div",
|
|
2107
|
-
], 2), d(
|
|
2398
|
+
r.$slots["label-trailing"] ? (w(), s("div", Pa, [O(r.$slots, "label-trailing")])) : o("", !0)
|
|
2399
|
+
], 2), d(ja, {
|
|
2108
2400
|
id: p,
|
|
2109
2401
|
status: m.value,
|
|
2110
2402
|
text: h.value
|
|
2111
2403
|
}, null, 8, ["status", "text"])], 2));
|
|
2112
2404
|
}
|
|
2113
|
-
}),
|
|
2405
|
+
}), La = [
|
|
2114
2406
|
"id",
|
|
2407
|
+
"spellcheck",
|
|
2115
2408
|
"disabled",
|
|
2116
2409
|
"aria-invalid",
|
|
2117
2410
|
"aria-describedby"
|
|
2118
|
-
],
|
|
2411
|
+
], Ra = /* @__PURE__ */ f({
|
|
2119
2412
|
inheritAttrs: !1,
|
|
2120
2413
|
__name: "Input",
|
|
2121
2414
|
props: /*@__PURE__*/ g({
|
|
@@ -2147,7 +2440,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2147
2440
|
if (n.maxLength !== void 0 && e > n.maxLength) return t("ui.input.maxLength", { count: n.maxLength });
|
|
2148
2441
|
if (o.value && n.minLength !== void 0 && e > 0 && e < n.minLength) return t("ui.input.minLength", { count: n.minLength });
|
|
2149
2442
|
}), u = i(() => n.status ?? (s.value ? "error" : void 0)), d = i(() => n.statusText ?? s.value);
|
|
2150
|
-
return (t, i) => (w(), a(
|
|
2443
|
+
return (t, i) => (w(), a(Ia, {
|
|
2151
2444
|
label: e.label,
|
|
2152
2445
|
helper: e.helper,
|
|
2153
2446
|
"helper-placement": e.helperPlacement,
|
|
@@ -2160,14 +2453,15 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2160
2453
|
}, l({
|
|
2161
2454
|
default: V(({ id: n, describedBy: a, invalid: s }) => [H(c("input", _({
|
|
2162
2455
|
id: n,
|
|
2163
|
-
"onUpdate:modelValue": i[0] ||= (e) => r.value = e
|
|
2456
|
+
"onUpdate:modelValue": i[0] ||= (e) => r.value = e,
|
|
2457
|
+
spellcheck: t.$attrs.type !== "email" && void 0
|
|
2164
2458
|
}, t.$attrs, {
|
|
2165
2459
|
disabled: e.disabled,
|
|
2166
2460
|
"aria-invalid": s,
|
|
2167
2461
|
"aria-describedby": a,
|
|
2168
2462
|
class: "h-5 min-w-0 flex-1 bg-transparent outline-none placeholder:text-black/55 disabled:cursor-not-allowed",
|
|
2169
2463
|
onBlur: i[1] ||= (e) => o.value = !0
|
|
2170
|
-
}), null, 16,
|
|
2464
|
+
}), null, 16, La), [[L, r.value]])]),
|
|
2171
2465
|
_: 2
|
|
2172
2466
|
}, [t.$slots.leading ? {
|
|
2173
2467
|
name: "leading",
|
|
@@ -2189,7 +2483,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2189
2483
|
"class"
|
|
2190
2484
|
]));
|
|
2191
2485
|
}
|
|
2192
|
-
}),
|
|
2486
|
+
}), za = "-ml-3 rounded-l border-r border-black/15", Ba = "-mr-3 rounded-r border-l border-black/15", Va = /* @__PURE__ */ f({
|
|
2193
2487
|
inheritAttrs: !1,
|
|
2194
2488
|
__name: "InputNumber",
|
|
2195
2489
|
props: /*@__PURE__*/ g({
|
|
@@ -2224,7 +2518,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2224
2518
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
2225
2519
|
"disabled:cursor-not-allowed disabled:[&_svg]:opacity-40!"
|
|
2226
2520
|
];
|
|
2227
|
-
return (t, i) => (w(), a(
|
|
2521
|
+
return (t, i) => (w(), a(Ia, {
|
|
2228
2522
|
label: e.label,
|
|
2229
2523
|
helper: e.helper,
|
|
2230
2524
|
"helper-placement": e.helperPlacement,
|
|
@@ -2235,7 +2529,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2235
2529
|
disabled: e.disabled,
|
|
2236
2530
|
class: y(t.$props.class)
|
|
2237
2531
|
}, {
|
|
2238
|
-
default: V(({ id: a, describedBy: s, invalid: c }) => [d(M(
|
|
2532
|
+
default: V(({ id: a, describedBy: s, invalid: c }) => [d(M(Nt), {
|
|
2239
2533
|
id: a,
|
|
2240
2534
|
modelValue: n.value,
|
|
2241
2535
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -2248,11 +2542,11 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2248
2542
|
class: "contents"
|
|
2249
2543
|
}, {
|
|
2250
2544
|
default: V(() => [
|
|
2251
|
-
d(M(
|
|
2252
|
-
default: V(() => [d(M(
|
|
2545
|
+
d(M(At), { class: y([o, za]) }, {
|
|
2546
|
+
default: V(() => [d(M(je))]),
|
|
2253
2547
|
_: 1
|
|
2254
2548
|
}, 8, ["class"]),
|
|
2255
|
-
d(M(
|
|
2549
|
+
d(M(Mt), _(t.$attrs, {
|
|
2256
2550
|
"aria-invalid": c,
|
|
2257
2551
|
"aria-describedby": s,
|
|
2258
2552
|
"aria-valuetext": r.value,
|
|
@@ -2262,8 +2556,8 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2262
2556
|
"aria-describedby",
|
|
2263
2557
|
"aria-valuetext"
|
|
2264
2558
|
]),
|
|
2265
|
-
d(M(
|
|
2266
|
-
default: V(() => [d(M(
|
|
2559
|
+
d(M(jt), { class: y([o, Ba]) }, {
|
|
2560
|
+
default: V(() => [d(M(Fe))]),
|
|
2267
2561
|
_: 1
|
|
2268
2562
|
}, 8, ["class"])
|
|
2269
2563
|
]),
|
|
@@ -2291,26 +2585,26 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2291
2585
|
"class"
|
|
2292
2586
|
]));
|
|
2293
2587
|
}
|
|
2294
|
-
}),
|
|
2588
|
+
}), Ha = { class: "flex items-center" }, Ua = ["aria-label", "disabled"], Wa = ["aria-label", "disabled"], Ga = {
|
|
2295
2589
|
key: 2,
|
|
2296
2590
|
class: "px-1.5 py-1 text-sm tabular-nums"
|
|
2297
|
-
},
|
|
2591
|
+
}, Ka = {
|
|
2298
2592
|
key: 0,
|
|
2299
2593
|
class: "mt-3 grid w-56 grid-cols-3 gap-1"
|
|
2300
|
-
},
|
|
2594
|
+
}, qa = [
|
|
2301
2595
|
"aria-current",
|
|
2302
2596
|
"aria-pressed",
|
|
2303
2597
|
"disabled",
|
|
2304
2598
|
"onClick"
|
|
2305
|
-
],
|
|
2599
|
+
], Ja = {
|
|
2306
2600
|
key: 1,
|
|
2307
2601
|
class: "mt-3 grid w-56 grid-cols-3 gap-1"
|
|
2308
|
-
},
|
|
2602
|
+
}, Ya = [
|
|
2309
2603
|
"aria-current",
|
|
2310
2604
|
"aria-pressed",
|
|
2311
2605
|
"disabled",
|
|
2312
2606
|
"onClick"
|
|
2313
|
-
],
|
|
2607
|
+
], Xa = /* @__PURE__ */ f({
|
|
2314
2608
|
__name: "Calendar",
|
|
2315
2609
|
props: /*@__PURE__*/ g({
|
|
2316
2610
|
min: {},
|
|
@@ -2334,7 +2628,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2334
2628
|
let { t } = K(), r = e, l = F(e, "modelValue");
|
|
2335
2629
|
function f(e) {
|
|
2336
2630
|
if (e) try {
|
|
2337
|
-
return
|
|
2631
|
+
return Dn(e);
|
|
2338
2632
|
} catch {
|
|
2339
2633
|
return;
|
|
2340
2634
|
}
|
|
@@ -2345,15 +2639,15 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2345
2639
|
}
|
|
2346
2640
|
let _ = E("days"), v = A(b());
|
|
2347
2641
|
function b() {
|
|
2348
|
-
if (p.value) return
|
|
2349
|
-
let e =
|
|
2350
|
-
return m.value && e.compare(m.value) < 0 ?
|
|
2642
|
+
if (p.value) return kn(p.value);
|
|
2643
|
+
let e = An(Tn());
|
|
2644
|
+
return m.value && e.compare(m.value) < 0 ? kn(m.value) : h.value && e.compare(h.value) > 0 ? kn(h.value) : e;
|
|
2351
2645
|
}
|
|
2352
2646
|
z(p, (e) => {
|
|
2353
|
-
e && (v.value =
|
|
2647
|
+
e && (v.value = kn(e));
|
|
2354
2648
|
});
|
|
2355
2649
|
function x(e) {
|
|
2356
|
-
v.value =
|
|
2650
|
+
v.value = kn(e);
|
|
2357
2651
|
}
|
|
2358
2652
|
let S = i(() => {
|
|
2359
2653
|
let e = new Intl.DateTimeFormat(r.locale, { month: "short" });
|
|
@@ -2369,41 +2663,41 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2369
2663
|
v.value = v.value.set({ month: e }), _.value = "days";
|
|
2370
2664
|
}
|
|
2371
2665
|
function I(e) {
|
|
2372
|
-
let t = v.value.set({ year: e }), n = m.value &&
|
|
2666
|
+
let t = v.value.set({ year: e }), n = m.value && kn(m.value).set({ day: 1 }), r = h.value && kn(h.value).set({ day: 1 });
|
|
2373
2667
|
n && t.compare(n) < 0 && (t = t.set({ month: n.month })), r && t.compare(r) > 0 && (t = t.set({ month: r.month })), v.value = t, _.value = "days";
|
|
2374
2668
|
}
|
|
2375
2669
|
function L(e) {
|
|
2376
2670
|
_.value === "months" ? v.value = v.value.add({ years: e }) : T.value += 12 * e;
|
|
2377
2671
|
}
|
|
2378
2672
|
function R(e) {
|
|
2379
|
-
let t = new
|
|
2673
|
+
let t = new Cn(v.value.year, e, 1), n = t.add({ months: 1 }).subtract({ days: 1 });
|
|
2380
2674
|
return !!(m.value && n.compare(m.value) < 0 || h.value && t.compare(h.value) > 0);
|
|
2381
2675
|
}
|
|
2382
2676
|
function B(e) {
|
|
2383
2677
|
return !!(m.value && e < m.value.year || h.value && e > h.value.year);
|
|
2384
2678
|
}
|
|
2385
2679
|
let H = i(() => _.value === "months" ? B(v.value.year - 1) : B(T.value - 1)), U = i(() => _.value === "months" ? B(v.value.year + 1) : B(T.value + 12)), ee = (e) => p.value?.year === v.value.year && p.value?.month === e, W = (e) => p.value?.year === e, G = (e) => {
|
|
2386
|
-
let t =
|
|
2680
|
+
let t = An(Tn());
|
|
2387
2681
|
return v.value.year === t.year && e === t.month;
|
|
2388
|
-
},
|
|
2682
|
+
}, q = (e) => e === An(Tn()).year, J = [
|
|
2389
2683
|
"inline-flex items-center gap-0.5 rounded px-1.5 py-1 text-sm cursor-pointer transition",
|
|
2390
2684
|
"hover:bg-black/10 active:bg-black/15 [&_svg]:size-3.5",
|
|
2391
2685
|
"disabled:cursor-not-allowed disabled:hover:bg-transparent",
|
|
2392
2686
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2393
|
-
],
|
|
2687
|
+
], te = [
|
|
2394
2688
|
"relative aria-[current=date]:font-bold",
|
|
2395
2689
|
"aria-[current=date]:after:absolute aria-[current=date]:after:left-1/2 aria-[current=date]:after:size-1",
|
|
2396
2690
|
"aria-[current=date]:after:-translate-x-1/2 aria-[current=date]:after:rounded-full aria-[current=date]:after:bg-current"
|
|
2397
|
-
],
|
|
2398
|
-
...
|
|
2691
|
+
], ne = [
|
|
2692
|
+
...te,
|
|
2399
2693
|
"aria-[current=date]:after:bottom-2",
|
|
2400
2694
|
"flex h-12 items-center justify-center rounded text-sm tabular-nums cursor-pointer transition",
|
|
2401
2695
|
"hover:bg-black/10",
|
|
2402
2696
|
"aria-pressed:bg-primary aria-pressed:text-white aria-pressed:hover:bg-primary",
|
|
2403
2697
|
"disabled:cursor-not-allowed disabled:text-black/25 disabled:hover:bg-transparent",
|
|
2404
2698
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2405
|
-
],
|
|
2406
|
-
...
|
|
2699
|
+
], re = [
|
|
2700
|
+
...te,
|
|
2407
2701
|
"aria-[current=date]:after:bottom-0.5",
|
|
2408
2702
|
"flex size-8 items-center justify-center rounded text-sm tabular-nums cursor-pointer transition",
|
|
2409
2703
|
"hover:bg-black/10",
|
|
@@ -2413,7 +2707,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2413
2707
|
"data-[unavailable]:line-through",
|
|
2414
2708
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2415
2709
|
];
|
|
2416
|
-
return (i, l) => (w(), a(M(
|
|
2710
|
+
return (i, l) => (w(), a(M(Qe), {
|
|
2417
2711
|
"model-value": p.value,
|
|
2418
2712
|
placeholder: v.value,
|
|
2419
2713
|
"min-value": m.value,
|
|
@@ -2428,9 +2722,9 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2428
2722
|
"onUpdate:placeholder": x
|
|
2429
2723
|
}, {
|
|
2430
2724
|
default: V(({ weekDays: r, grid: i }) => [
|
|
2431
|
-
d(M(
|
|
2725
|
+
d(M(Ye), { class: "flex items-center justify-between gap-1" }, {
|
|
2432
2726
|
default: V(() => [
|
|
2433
|
-
_.value === "days" ? (w(), a(M(
|
|
2727
|
+
_.value === "days" ? (w(), a(M(Ze), {
|
|
2434
2728
|
key: 0,
|
|
2435
2729
|
"as-child": ""
|
|
2436
2730
|
}, {
|
|
@@ -2440,7 +2734,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2440
2734
|
square: "",
|
|
2441
2735
|
"aria-label": M(t)("ui.calendar.previousMonth")
|
|
2442
2736
|
}, {
|
|
2443
|
-
default: V(() => [d(M(
|
|
2737
|
+
default: V(() => [d(M(pe))]),
|
|
2444
2738
|
_: 1
|
|
2445
2739
|
}, 8, ["aria-label"])]),
|
|
2446
2740
|
_: 1
|
|
@@ -2453,25 +2747,25 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2453
2747
|
disabled: e.disabled || H.value,
|
|
2454
2748
|
onClick: l[0] ||= (e) => L(-1)
|
|
2455
2749
|
}, {
|
|
2456
|
-
default: V(() => [d(M(
|
|
2750
|
+
default: V(() => [d(M(pe))]),
|
|
2457
2751
|
_: 1
|
|
2458
2752
|
}, 8, ["aria-label", "disabled"])),
|
|
2459
|
-
c("div",
|
|
2753
|
+
c("div", Ha, [_.value === "days" ? (w(), s("button", {
|
|
2460
2754
|
key: 0,
|
|
2461
2755
|
type: "button",
|
|
2462
|
-
class: y(
|
|
2756
|
+
class: y(J),
|
|
2463
2757
|
"aria-label": M(t)("ui.calendar.chooseMonth"),
|
|
2464
2758
|
disabled: e.disabled,
|
|
2465
2759
|
onClick: k
|
|
2466
|
-
}, [u(j(C.value) + " ", 1), d(M(
|
|
2760
|
+
}, [u(j(C.value) + " ", 1), d(M(fe))], 8, Ua)) : o("", !0), _.value === "years" ? (w(), s("span", Ga, j(O.value[0]) + " – " + j(O.value[O.value.length - 1]), 1)) : (w(), s("button", {
|
|
2467
2761
|
key: 1,
|
|
2468
2762
|
type: "button",
|
|
2469
|
-
class: y(
|
|
2763
|
+
class: y(J),
|
|
2470
2764
|
"aria-label": M(t)("ui.calendar.chooseYear"),
|
|
2471
2765
|
disabled: e.disabled,
|
|
2472
2766
|
onClick: N
|
|
2473
|
-
}, [u(j(v.value.year) + " ", 1), d(M(
|
|
2474
|
-
_.value === "days" ? (w(), a(M(
|
|
2767
|
+
}, [u(j(v.value.year) + " ", 1), d(M(fe))], 8, Wa))]),
|
|
2768
|
+
_.value === "days" ? (w(), a(M(Xe), {
|
|
2475
2769
|
key: 2,
|
|
2476
2770
|
"as-child": ""
|
|
2477
2771
|
}, {
|
|
@@ -2481,7 +2775,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2481
2775
|
square: "",
|
|
2482
2776
|
"aria-label": M(t)("ui.calendar.nextMonth")
|
|
2483
2777
|
}, {
|
|
2484
|
-
default: V(() => [d(M(
|
|
2778
|
+
default: V(() => [d(M(me))]),
|
|
2485
2779
|
_: 1
|
|
2486
2780
|
}, 8, ["aria-label"])]),
|
|
2487
2781
|
_: 1
|
|
@@ -2494,36 +2788,36 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2494
2788
|
disabled: e.disabled || U.value,
|
|
2495
2789
|
onClick: l[1] ||= (e) => L(1)
|
|
2496
2790
|
}, {
|
|
2497
|
-
default: V(() => [d(M(
|
|
2791
|
+
default: V(() => [d(M(me))]),
|
|
2498
2792
|
_: 1
|
|
2499
2793
|
}, 8, ["aria-label", "disabled"]))
|
|
2500
2794
|
]),
|
|
2501
2795
|
_: 1
|
|
2502
2796
|
}),
|
|
2503
|
-
_.value === "months" ? (w(), s("div",
|
|
2797
|
+
_.value === "months" ? (w(), s("div", Ka, [(w(!0), s(n, null, D(S.value, (e, t) => (w(), s("button", {
|
|
2504
2798
|
key: e,
|
|
2505
2799
|
type: "button",
|
|
2506
|
-
class: y(
|
|
2800
|
+
class: y(ne),
|
|
2507
2801
|
"aria-current": G(t + 1) ? "date" : void 0,
|
|
2508
2802
|
"aria-pressed": ee(t + 1),
|
|
2509
2803
|
disabled: R(t + 1),
|
|
2510
2804
|
onClick: (e) => P(t + 1)
|
|
2511
|
-
}, j(e), 9,
|
|
2805
|
+
}, j(e), 9, qa))), 128))])) : _.value === "years" ? (w(), s("div", Ja, [(w(!0), s(n, null, D(O.value, (e) => (w(), s("button", {
|
|
2512
2806
|
key: e,
|
|
2513
2807
|
type: "button",
|
|
2514
|
-
class: y(
|
|
2515
|
-
"aria-current":
|
|
2808
|
+
class: y(ne),
|
|
2809
|
+
"aria-current": q(e) ? "date" : void 0,
|
|
2516
2810
|
"aria-pressed": W(e),
|
|
2517
2811
|
disabled: B(e),
|
|
2518
2812
|
onClick: (t) => I(e)
|
|
2519
|
-
}, j(e), 9,
|
|
2520
|
-
(w(!0), s(n, null, D(_.value === "days" ? i : [], (e) => (w(), a(M(
|
|
2813
|
+
}, j(e), 9, Ya))), 128))])) : o("", !0),
|
|
2814
|
+
(w(!0), s(n, null, D(_.value === "days" ? i : [], (e) => (w(), a(M(We), {
|
|
2521
2815
|
key: e.value.toString(),
|
|
2522
2816
|
class: "mt-3 border-collapse select-none"
|
|
2523
2817
|
}, {
|
|
2524
|
-
default: V(() => [d(M(
|
|
2525
|
-
default: V(() => [d(M(
|
|
2526
|
-
default: V(() => [(w(!0), s(n, null, D(r, (e) => (w(), a(M(
|
|
2818
|
+
default: V(() => [d(M(Ke), null, {
|
|
2819
|
+
default: V(() => [d(M(qe), { class: "flex" }, {
|
|
2820
|
+
default: V(() => [(w(!0), s(n, null, D(r, (e) => (w(), a(M(Je), {
|
|
2527
2821
|
key: e,
|
|
2528
2822
|
class: "w-8 pb-1 text-xs font-normal text-black/55"
|
|
2529
2823
|
}, {
|
|
@@ -2533,20 +2827,20 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2533
2827
|
_: 2
|
|
2534
2828
|
}, 1024)]),
|
|
2535
2829
|
_: 2
|
|
2536
|
-
}, 1024), d(M(
|
|
2537
|
-
default: V(() => [(w(!0), s(n, null, D(e.rows, (t, r) => (w(), a(M(
|
|
2830
|
+
}, 1024), d(M(Ge), null, {
|
|
2831
|
+
default: V(() => [(w(!0), s(n, null, D(e.rows, (t, r) => (w(), a(M(qe), {
|
|
2538
2832
|
key: `week-${r}`,
|
|
2539
2833
|
class: "flex"
|
|
2540
2834
|
}, {
|
|
2541
|
-
default: V(() => [(w(!0), s(n, null, D(t, (t) => (w(), a(M(
|
|
2835
|
+
default: V(() => [(w(!0), s(n, null, D(t, (t) => (w(), a(M(He), {
|
|
2542
2836
|
key: t.toString(),
|
|
2543
2837
|
date: t
|
|
2544
2838
|
}, {
|
|
2545
|
-
default: V(() => [d(M(
|
|
2839
|
+
default: V(() => [d(M(Ue), {
|
|
2546
2840
|
day: t,
|
|
2547
2841
|
month: e.value,
|
|
2548
|
-
"aria-current": M(
|
|
2549
|
-
class: y(
|
|
2842
|
+
"aria-current": M(En)(t, M(Tn)()) ? "date" : void 0,
|
|
2843
|
+
class: y(re)
|
|
2550
2844
|
}, null, 8, [
|
|
2551
2845
|
"day",
|
|
2552
2846
|
"month",
|
|
@@ -2573,7 +2867,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2573
2867
|
"class"
|
|
2574
2868
|
]));
|
|
2575
2869
|
}
|
|
2576
|
-
}),
|
|
2870
|
+
}), Za = {
|
|
2577
2871
|
monday: 1,
|
|
2578
2872
|
mon: 1,
|
|
2579
2873
|
tuesday: 2,
|
|
@@ -2592,7 +2886,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2592
2886
|
sat: 6,
|
|
2593
2887
|
sunday: 7,
|
|
2594
2888
|
sun: 7
|
|
2595
|
-
}, Q = `(${Object.keys(
|
|
2889
|
+
}, Q = `(${Object.keys(Za).join("|")})`, Qa = {
|
|
2596
2890
|
january: 1,
|
|
2597
2891
|
jan: 1,
|
|
2598
2892
|
february: 2,
|
|
@@ -2617,7 +2911,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2617
2911
|
nov: 11,
|
|
2618
2912
|
december: 12,
|
|
2619
2913
|
dec: 12
|
|
2620
|
-
},
|
|
2914
|
+
}, $a = `(${Object.keys(Qa).sort((e, t) => t.length - e.length).join("|")})`, eo = {
|
|
2621
2915
|
a: 1,
|
|
2622
2916
|
an: 1,
|
|
2623
2917
|
one: 1,
|
|
@@ -2641,7 +2935,7 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2641
2935
|
nineteen: 19,
|
|
2642
2936
|
twenty: 20,
|
|
2643
2937
|
thirty: 30
|
|
2644
|
-
},
|
|
2938
|
+
}, to = `(\\d+|${Object.keys(eo).join("|")})`, no = "(day|week|fortnight|month|year)s?", ro = {
|
|
2645
2939
|
first: 1,
|
|
2646
2940
|
second: 2,
|
|
2647
2941
|
third: 3,
|
|
@@ -2663,37 +2957,37 @@ var Bi = { class: "sr-only" }, Vi = {
|
|
|
2663
2957
|
nineteenth: 19,
|
|
2664
2958
|
twentieth: 20,
|
|
2665
2959
|
thirtieth: 30
|
|
2666
|
-
},
|
|
2667
|
-
function
|
|
2960
|
+
}, io = Object.keys(ro).join("|");
|
|
2961
|
+
function ao(e) {
|
|
2668
2962
|
return new Date(e.year, e.month - 1, e.day).getDay() || 7;
|
|
2669
2963
|
}
|
|
2670
|
-
function
|
|
2671
|
-
return e.subtract({ days:
|
|
2964
|
+
function oo(e) {
|
|
2965
|
+
return e.subtract({ days: ao(e) - 1 });
|
|
2672
2966
|
}
|
|
2673
2967
|
function $(e, t, n) {
|
|
2674
2968
|
if (!Number.isInteger(e) || t < 1 || t > 12 || n < 1) return;
|
|
2675
|
-
let r = new
|
|
2676
|
-
if (!(n > r.calendar.getDaysInMonth(r))) return new
|
|
2969
|
+
let r = new Cn(e, t, 1);
|
|
2970
|
+
if (!(n > r.calendar.getDaysInMonth(r))) return new Cn(e, t, n);
|
|
2677
2971
|
}
|
|
2678
|
-
function
|
|
2972
|
+
function so(e, t, n, r) {
|
|
2679
2973
|
if (r === -1) {
|
|
2680
|
-
let r =
|
|
2681
|
-
return r.subtract({ days: (
|
|
2974
|
+
let r = wn(new Cn(e, t, 1));
|
|
2975
|
+
return r.subtract({ days: (ao(r) - n + 7) % 7 });
|
|
2682
2976
|
}
|
|
2683
|
-
let i = new
|
|
2977
|
+
let i = new Cn(e, t, 1), a = i.add({ days: (n - ao(i) + 7) % 7 + (r - 1) * 7 });
|
|
2684
2978
|
return a.month === t ? a : void 0;
|
|
2685
2979
|
}
|
|
2686
|
-
function
|
|
2980
|
+
function co(e) {
|
|
2687
2981
|
let t = e % 19, n = Math.floor(e / 100), r = e % 100, i = Math.floor(n / 4), a = n % 4, o = Math.floor((n + 8) / 25), s = Math.floor((n - o + 1) / 3), c = (19 * t + n - i - s + 15) % 30, l = Math.floor(r / 4), u = r % 4, d = (32 + 2 * a + 2 * l - c - u) % 7, f = Math.floor((t + 11 * c + 22 * d) / 451), p = Math.floor((c + d - 7 * f + 114) / 31), m = (c + d - 7 * f + 114) % 31 + 1;
|
|
2688
|
-
return new
|
|
2982
|
+
return new Cn(e, p, m);
|
|
2689
2983
|
}
|
|
2690
|
-
function
|
|
2984
|
+
function lo(e, t) {
|
|
2691
2985
|
if (e.length === 4) return Number(e);
|
|
2692
2986
|
if (e.length !== 2) return NaN;
|
|
2693
2987
|
let n = Number(e);
|
|
2694
2988
|
return n <= t.year % 100 ? 2e3 + n : 1900 + n;
|
|
2695
2989
|
}
|
|
2696
|
-
var
|
|
2990
|
+
var uo = [
|
|
2697
2991
|
["(?:christmas|xmas) eve", (e) => $(e, 12, 24)],
|
|
2698
2992
|
["(?:christmas|xmas)(?: day)?", (e) => $(e, 12, 25)],
|
|
2699
2993
|
["boxing day", (e) => $(e, 12, 26)],
|
|
@@ -2701,56 +2995,56 @@ var Oa = [
|
|
|
2701
2995
|
["new years?(?: day)?", (e) => $(e, 1, 1)],
|
|
2702
2996
|
["valentines(?: day)?", (e) => $(e, 2, 14)],
|
|
2703
2997
|
["(?:st )?(?:patricks|paddys) day", (e) => $(e, 3, 17)],
|
|
2704
|
-
["good friday", (e) =>
|
|
2705
|
-
["easter monday", (e) =>
|
|
2706
|
-
["easter(?: sunday| day)?", (e) =>
|
|
2707
|
-
["(?:mothers day|mothering sunday)", (e) =>
|
|
2708
|
-
["fathers day", (e) =>
|
|
2998
|
+
["good friday", (e) => co(e).subtract({ days: 2 })],
|
|
2999
|
+
["easter monday", (e) => co(e).add({ days: 1 })],
|
|
3000
|
+
["easter(?: sunday| day)?", (e) => co(e)],
|
|
3001
|
+
["(?:mothers day|mothering sunday)", (e) => co(e).subtract({ weeks: 3 })],
|
|
3002
|
+
["fathers day", (e) => so(e, 6, 7, 3)],
|
|
2709
3003
|
["halloween", (e) => $(e, 10, 31)],
|
|
2710
3004
|
["(?:bonfire night|guy fawkes(?: night| day)?)", (e) => $(e, 11, 5)],
|
|
2711
3005
|
["(?:remembrance|armistice) day", (e) => $(e, 11, 11)]
|
|
2712
3006
|
];
|
|
2713
|
-
function
|
|
3007
|
+
function fo(e, t, n) {
|
|
2714
3008
|
let r = e.filter((e) => !!e).sort((e, t) => e.compare(t));
|
|
2715
|
-
return n === "future" ? r.find((e) => e.compare(t) >= 0) : n === "past" ?
|
|
3009
|
+
return n === "future" ? r.find((e) => e.compare(t) >= 0) : n === "past" ? r.findLast((e) => e.compare(t) <= 0) : r.reduce((e, n) => {
|
|
2716
3010
|
if (!e) return n;
|
|
2717
3011
|
let r = Math.abs(n.compare(t)), i = Math.abs(e.compare(t));
|
|
2718
3012
|
return r < i || r === i && n.compare(t) > 0 ? n : e;
|
|
2719
3013
|
}, void 0);
|
|
2720
3014
|
}
|
|
2721
|
-
function
|
|
3015
|
+
function po(e, t, n, r, i) {
|
|
2722
3016
|
if (!e) return n.yearValue === void 0 ? r.add(t) : void 0;
|
|
2723
3017
|
switch (e.kind) {
|
|
2724
3018
|
case "date": return n.yearValue === void 0 ? e.date.add(t) : void 0;
|
|
2725
3019
|
case "yearless": return n.yearValue === void 0 ? n.year || t.years ? e.resolve(r.year + t.years)?.add({
|
|
2726
3020
|
...t,
|
|
2727
3021
|
years: 0
|
|
2728
|
-
}) :
|
|
3022
|
+
}) : fo(Array.from({ length: 9 }, (e, t) => r.year - 4 + t).map(e.resolve), r, i)?.add(t) : e.resolve(n.yearValue + t.years)?.add({
|
|
2729
3023
|
...t,
|
|
2730
3024
|
years: 0
|
|
2731
3025
|
});
|
|
2732
3026
|
case "dayOfMonth":
|
|
2733
3027
|
if (n.yearValue !== void 0) return;
|
|
2734
3028
|
if (n.month || t.months) {
|
|
2735
|
-
let n =
|
|
3029
|
+
let n = On(r).add({ months: t.months });
|
|
2736
3030
|
return $(n.year, n.month, e.day)?.add({
|
|
2737
3031
|
...t,
|
|
2738
3032
|
months: 0
|
|
2739
3033
|
});
|
|
2740
3034
|
}
|
|
2741
|
-
return
|
|
3035
|
+
return fo([
|
|
2742
3036
|
-1,
|
|
2743
3037
|
0,
|
|
2744
3038
|
1
|
|
2745
|
-
].map((e) =>
|
|
3039
|
+
].map((e) => On(r).add({ months: e })).map((t) => $(t.year, t.month, e.day)), r, i)?.add(t);
|
|
2746
3040
|
case "weekday": {
|
|
2747
3041
|
if (n.yearValue !== void 0) return;
|
|
2748
|
-
let a = (e.weekday -
|
|
3042
|
+
let a = (e.weekday - ao(r) + 7) % 7 || 7, o = (ao(r) - e.weekday + 7) % 7 || 7, s = r.add({ days: a }), c = r.subtract({ days: o });
|
|
2749
3043
|
return (i === "past" || i === "nearest" && o < a ? c : s).add(t);
|
|
2750
3044
|
}
|
|
2751
3045
|
}
|
|
2752
3046
|
}
|
|
2753
|
-
function
|
|
3047
|
+
function mo(e, t, n) {
|
|
2754
3048
|
let r = e.trim(), i = /^(\d{4})-(\d{1,2})-(\d{1,2})$/.exec(r);
|
|
2755
3049
|
if (i) {
|
|
2756
3050
|
let e = $(Number(i[1]), Number(i[2]), Number(i[3]));
|
|
@@ -2776,29 +3070,29 @@ function ja(e, t, n) {
|
|
|
2776
3070
|
kind: "yearless",
|
|
2777
3071
|
resolve: (e) => $(e, o, i)
|
|
2778
3072
|
};
|
|
2779
|
-
let s = $(
|
|
3073
|
+
let s = $(lo(r.year, t), o, i);
|
|
2780
3074
|
return s && {
|
|
2781
3075
|
kind: "date",
|
|
2782
3076
|
date: s
|
|
2783
3077
|
};
|
|
2784
3078
|
}
|
|
2785
3079
|
let o = r.replace(/(\d)(st|nd|rd|th)\b/g, "$1").replace(/\bof\b/g, " ").replace(/[,/.\-]/g, " ").replace(/\s+/g, " ").trim(), s = (e, n, r) => {
|
|
2786
|
-
let i = Number(e), a =
|
|
3080
|
+
let i = Number(e), a = Qa[n];
|
|
2787
3081
|
if (r === void 0) return {
|
|
2788
3082
|
kind: "yearless",
|
|
2789
3083
|
resolve: (e) => $(e, a, i)
|
|
2790
3084
|
};
|
|
2791
|
-
let o = $(
|
|
3085
|
+
let o = $(lo(r, t), a, i);
|
|
2792
3086
|
return o && {
|
|
2793
3087
|
kind: "date",
|
|
2794
3088
|
date: o
|
|
2795
3089
|
};
|
|
2796
3090
|
}, c;
|
|
2797
|
-
if (c = RegExp(`^(\\d{1,2}) ${
|
|
2798
|
-
if (c = RegExp(`^${
|
|
2799
|
-
if (c = RegExp(`^(\\d{4}) ${
|
|
2800
|
-
if (c = RegExp(`^${
|
|
2801
|
-
let e =
|
|
3091
|
+
if (c = RegExp(`^(\\d{1,2}) ${$a}(?: (\\d{2}|\\d{4}))?$`).exec(o)) return s(c[1], c[2], c[3]);
|
|
3092
|
+
if (c = RegExp(`^${$a} (\\d{1,2})(?: (\\d{2}|\\d{4}))?$`).exec(o)) return s(c[2], c[1], c[3]);
|
|
3093
|
+
if (c = RegExp(`^(\\d{4}) ${$a} (\\d{1,2})$`).exec(o)) return s(c[3], c[2], c[1]);
|
|
3094
|
+
if (c = RegExp(`^${$a}(?: (\\d{4}))?$`).exec(o)) {
|
|
3095
|
+
let e = Qa[c[1]];
|
|
2802
3096
|
if (c[2]) {
|
|
2803
3097
|
let t = $(Number(c[2]), e, 1);
|
|
2804
3098
|
return t && {
|
|
@@ -2819,22 +3113,22 @@ function ja(e, t, n) {
|
|
|
2819
3113
|
} : void 0;
|
|
2820
3114
|
}
|
|
2821
3115
|
}
|
|
2822
|
-
function
|
|
3116
|
+
function ho(e) {
|
|
2823
3117
|
return `${e}${e % 100 >= 11 && e % 100 <= 13 ? "th" : {
|
|
2824
3118
|
1: "st",
|
|
2825
3119
|
2: "nd",
|
|
2826
3120
|
3: "rd"
|
|
2827
3121
|
}[e % 10] ?? "th"}`;
|
|
2828
3122
|
}
|
|
2829
|
-
function
|
|
2830
|
-
return e.toLowerCase().replace(/['’]/g, "").replace(/,/g, " ").replace(/\.+$/, "").replace(RegExp(`\\b(twenty|thirty)[ -](${
|
|
3123
|
+
function go(e) {
|
|
3124
|
+
return e.toLowerCase().replace(/['’]/g, "").replace(/,/g, " ").replace(/\.+$/, "").replace(RegExp(`\\b(twenty|thirty)[ -](${io})\\b`, "g"), (e, t, n) => ho((t === "twenty" ? 20 : 30) + ro[n])).replace(RegExp(`\\b(${io})\\b`, "g"), (e) => ho(ro[e])).replace(/\b(?:a )?couple(?: of)?\b/g, "2").replace(/\b(?:a )?few\b/g, "3").replace(/\b(?:at |@ ?)?\d{1,2}(?::\d{2})? ?(?:am|pm)\b/g, " ").replace(/\b(?:at |@ ?)\d{1,2}(?::\d{2})?\b(?![/.\-]\d)/g, " ").replace(/\b\d{1,2}:\d{2}\b/g, " ").replace(/\b(?:at )?(?:noon|midday|midnight)\b/g, " ").replace(/\b(?:tonight|this (?:morning|afternoon|evening)|eod|end of (?:the )?day)\b/g, " today ").replace(/\b(?:in the )?(?:morning|afternoon|evening|(?<!bonfire |fawkes )night)\b/g, " ").replace(/\bthe\b/g, " ").replace(/\s+/g, " ").trim();
|
|
2831
3125
|
}
|
|
2832
|
-
function
|
|
3126
|
+
function _o(e, t) {
|
|
2833
3127
|
let { today: n, order: r = [
|
|
2834
3128
|
"day",
|
|
2835
3129
|
"month",
|
|
2836
3130
|
"year"
|
|
2837
|
-
], prefer: i = "future" } = t, a =
|
|
3131
|
+
], prefer: i = "future" } = t, a = go(e);
|
|
2838
3132
|
if (!a) return;
|
|
2839
3133
|
let o = ` ${a} `, s = !1, c = !1, l = [], u = !1, d = {
|
|
2840
3134
|
days: 0,
|
|
@@ -2844,7 +3138,7 @@ function Pa(e, t) {
|
|
|
2844
3138
|
}, f = {
|
|
2845
3139
|
year: !1,
|
|
2846
3140
|
month: !1
|
|
2847
|
-
}, p =
|
|
3141
|
+
}, p = oo(n);
|
|
2848
3142
|
function m(e) {
|
|
2849
3143
|
let t = RegExp(` ${e} `).exec(o);
|
|
2850
3144
|
return t && (o = o.replace(t[0], " "), s = !0), t;
|
|
@@ -2854,37 +3148,37 @@ function Pa(e, t) {
|
|
|
2854
3148
|
}, g = (e) => e && {
|
|
2855
3149
|
kind: "date",
|
|
2856
3150
|
date: e
|
|
2857
|
-
}, _ = (e, t = 1) => e.slice(t).find((e) => e !== void 0), v = (e) => e === "fortnight" ? ["weeks", 2] : [`${e}s`, 1], y = (e) =>
|
|
2858
|
-
if (m("eow") && h(g(p.add({ days: 4 }))), m("eom") && h(g(
|
|
2859
|
-
let e = x[1] === "last" ? -1 : Number(x[1][0]), t =
|
|
3151
|
+
}, _ = (e, t = 1) => e.slice(t).find((e) => e !== void 0), v = (e) => e === "fortnight" ? ["weeks", 2] : [`${e}s`, 1], y = (e) => eo[e] ?? Number(e), b = (e) => n.add({ days: (e - ao(n) + 7) % 7 || 7 }), x;
|
|
3152
|
+
if (m("eow") && h(g(p.add({ days: 4 }))), m("eom") && h(g(wn(n))), m("eoy") && h(g(new Cn(n.year, 12, 31))), x = m(`(1st|2nd|3rd|4th|5th|last) ${Q} (?:of|in) (?:(this|next|last) month|month|${$a}(?: (\\d{4}))?)`)) {
|
|
3153
|
+
let e = x[1] === "last" ? -1 : Number(x[1][0]), t = Za[x[2]];
|
|
2860
3154
|
if (x[4]) {
|
|
2861
|
-
let n =
|
|
2862
|
-
x[5] ? h(g(
|
|
3155
|
+
let n = Qa[x[4]];
|
|
3156
|
+
x[5] ? h(g(so(Number(x[5]), n, t, e))) : h({
|
|
2863
3157
|
kind: "yearless",
|
|
2864
|
-
resolve: (r) =>
|
|
3158
|
+
resolve: (r) => so(r, n, t, e)
|
|
2865
3159
|
});
|
|
2866
3160
|
} else {
|
|
2867
|
-
let r = x[3] === "next" ? 1 : x[3] === "last" ? -1 : 0, i =
|
|
2868
|
-
h(g(
|
|
3161
|
+
let r = x[3] === "next" ? 1 : x[3] === "last" ? -1 : 0, i = On(n).add({ months: r });
|
|
3162
|
+
h(g(so(i.year, i.month, t, e)));
|
|
2869
3163
|
}
|
|
2870
3164
|
}
|
|
2871
3165
|
if (x = m("(start|beginning|middle|mid|end) (?:of )?(?:(this|next|last) )?(week|month|year)")) {
|
|
2872
3166
|
let e = x[2] === "next" ? 1 : x[2] === "last" ? -1 : 0, t = x[1] === "beginning" ? "start" : x[1] === "middle" ? "mid" : x[1];
|
|
2873
3167
|
if (x[3] === "week") h(g(p.add({ weeks: e }).add({ days: t === "start" ? 0 : t === "mid" ? 2 : 4 })));
|
|
2874
3168
|
else if (x[3] === "month") {
|
|
2875
|
-
let r =
|
|
2876
|
-
h(g(t === "start" ? r : t === "mid" ? r.set({ day: 15 }) :
|
|
3169
|
+
let r = On(n).add({ months: e });
|
|
3170
|
+
h(g(t === "start" ? r : t === "mid" ? r.set({ day: 15 }) : wn(r)));
|
|
2877
3171
|
} else {
|
|
2878
3172
|
let r = n.year + e;
|
|
2879
|
-
h(g(t === "start" ? new
|
|
3173
|
+
h(g(t === "start" ? new Cn(r, 1, 1) : t === "mid" ? new Cn(r, 7, 1) : new Cn(r, 12, 31)));
|
|
2880
3174
|
}
|
|
2881
3175
|
}
|
|
2882
|
-
if (x = m(`(start|beginning|early|middle|mid|late|end) (?:of )?${
|
|
2883
|
-
let e = x[1], t =
|
|
3176
|
+
if (x = m(`(start|beginning|early|middle|mid|late|end) (?:of )?${$a}(?: (\\d{4}))?`)) {
|
|
3177
|
+
let e = x[1], t = Qa[x[2]], n = (n) => [
|
|
2884
3178
|
"start",
|
|
2885
3179
|
"beginning",
|
|
2886
3180
|
"early"
|
|
2887
|
-
].includes(e) ? $(n, t, 1) : ["middle", "mid"].includes(e) ? $(n, t, 15) :
|
|
3181
|
+
].includes(e) ? $(n, t, 1) : ["middle", "mid"].includes(e) ? $(n, t, 15) : wn(new Cn(n, t, 1));
|
|
2888
3182
|
h(x[3] ? g(n(Number(x[3]))) : {
|
|
2889
3183
|
kind: "yearless",
|
|
2890
3184
|
resolve: n
|
|
@@ -2897,38 +3191,38 @@ function Pa(e, t) {
|
|
|
2897
3191
|
kind: "weekday",
|
|
2898
3192
|
weekday: 6
|
|
2899
3193
|
});
|
|
2900
|
-
for (let [e, t] of
|
|
3194
|
+
for (let [e, t] of uo) m(e) && h({
|
|
2901
3195
|
kind: "yearless",
|
|
2902
3196
|
resolve: t
|
|
2903
3197
|
});
|
|
2904
|
-
if ((x = m(`${Q} after next`)) && h(g(b(
|
|
3198
|
+
if ((x = m(`${Q} after next`)) && h(g(b(Za[x[1]]).add({ weeks: 1 }))), (x = m(`${Q} (week|fortnight)`)) && h(g(b(Za[x[1]]).add({ weeks: x[2] === "fortnight" ? 2 : 1 }))), x = m(`${to} ${no} on ${Q}`)) {
|
|
2905
3199
|
let [e, t] = v(x[2]);
|
|
2906
|
-
h(g(b(
|
|
3200
|
+
h(g(b(Za[x[3]]).add({ [e]: y(x[1]) * t })));
|
|
2907
3201
|
}
|
|
2908
|
-
if (x = m(`${
|
|
3202
|
+
if (x = m(`${to} ${no} (today|tomorrow|tmrw|tmr)`)) {
|
|
2909
3203
|
let [e, t] = v(x[2]);
|
|
2910
3204
|
h(g((x[3] === "today" ? n : n.add({ days: 1 })).add({ [e]: y(x[1]) * t })));
|
|
2911
3205
|
}
|
|
2912
3206
|
for ((x = m(`(?:next week ${Q}|${Q} next week|next ${Q})`)) && h(g(p.add({
|
|
2913
3207
|
weeks: 1,
|
|
2914
|
-
days:
|
|
2915
|
-
}))), (x = m(`(?:last week ${Q}|${Q} last week)`)) && h(g(p.subtract({ weeks: 1 }).add({ days:
|
|
3208
|
+
days: Za[_(x)] - 1
|
|
3209
|
+
}))), (x = m(`(?:last week ${Q}|${Q} last week)`)) && h(g(p.subtract({ weeks: 1 }).add({ days: Za[_(x)] - 1 }))), (x = m(`(?:this week ${Q}|${Q} this week|this ${Q})`)) && h(g(p.add({ days: Za[_(x)] - 1 }))), (x = m(`last ${Q}`)) && h(g(n.subtract({ days: (ao(n) - Za[x[1]] + 7) % 7 || 7 }))), m("day after (?:tomorrow|tmrw|tmr)") && h(g(n.add({ days: 2 }))), m("day before yesterday") && h(g(n.subtract({ days: 2 }))), m("(?:tomorrow|tmrw|tmr|tmw|tomoz)") && h(g(n.add({ days: 1 }))), m("(?:yesterday|yday|yest)") && h(g(n.subtract({ days: 1 }))), m("(?:today|now|tdy)") && h(g(n)), (x = m(`(?:on )?${Q}`)) && h({
|
|
2916
3210
|
kind: "weekday",
|
|
2917
|
-
weekday:
|
|
2918
|
-
}, !0), m("this year") && (f.year = !0), m("this month") && (f.month = !0); x = m(`(next|last) ${
|
|
3211
|
+
weekday: Za[x[1]]
|
|
3212
|
+
}, !0), m("this year") && (f.year = !0), m("this month") && (f.month = !0); x = m(`(next|last) ${no}`);) {
|
|
2919
3213
|
let [e, t] = v(x[2]);
|
|
2920
3214
|
d[e] += (x[1] === "next" ? 1 : -1) * t;
|
|
2921
3215
|
}
|
|
2922
3216
|
let S = !1;
|
|
2923
|
-
for (; x = m(`in ${
|
|
3217
|
+
for (; x = m(`in ${to} ${no}`);) {
|
|
2924
3218
|
let [e, t] = v(x[2]);
|
|
2925
3219
|
d[e] += y(x[1]) * t, S = !0;
|
|
2926
3220
|
}
|
|
2927
|
-
for (; S && (x = m(`(?:and )?${
|
|
3221
|
+
for (; S && (x = m(`(?:and )?${to} ${no}(?! (?:ago|before|earlier|from|after|later))`));) {
|
|
2928
3222
|
let [e, t] = v(x[2]);
|
|
2929
3223
|
d[e] += y(x[1]) * t;
|
|
2930
3224
|
}
|
|
2931
|
-
for (; x = m(`${
|
|
3225
|
+
for (; x = m(`${to} ${no} (ago|before|earlier|from|after|later)`);) {
|
|
2932
3226
|
let [e, t] = v(x[2]), n = [
|
|
2933
3227
|
"ago",
|
|
2934
3228
|
"before",
|
|
@@ -2939,24 +3233,24 @@ function Pa(e, t) {
|
|
|
2939
3233
|
for (; m("(?:on|of|at|by|for)"););
|
|
2940
3234
|
let C = o.trim();
|
|
2941
3235
|
if (s && /^\d{4}$/.test(C) && (f.yearValue = Number(C), C = ""), C) {
|
|
2942
|
-
let e =
|
|
3236
|
+
let e = mo(C, n, r);
|
|
2943
3237
|
if (!e) return;
|
|
2944
3238
|
l.length === 1 && u && l.pop(), l.push(e);
|
|
2945
3239
|
} else if (!s) return;
|
|
2946
|
-
if (!(c || l.length > 1)) return
|
|
3240
|
+
if (!(c || l.length > 1)) return po(l[0], d, f, n, i);
|
|
2947
3241
|
}
|
|
2948
3242
|
// src/components/InputDate/InputDate.vue?vue&type=script&setup=true&lang.ts
|
|
2949
|
-
var
|
|
3243
|
+
var vo = [
|
|
2950
3244
|
"id",
|
|
2951
3245
|
"placeholder",
|
|
2952
3246
|
"disabled",
|
|
2953
3247
|
"aria-invalid",
|
|
2954
3248
|
"aria-describedby"
|
|
2955
|
-
],
|
|
3249
|
+
], yo = {
|
|
2956
3250
|
key: 0,
|
|
2957
3251
|
"aria-hidden": "true",
|
|
2958
3252
|
class: "shrink-0 tabular-nums text-black/55"
|
|
2959
|
-
},
|
|
3253
|
+
}, bo = /* @__PURE__ */ f({
|
|
2960
3254
|
inheritAttrs: !1,
|
|
2961
3255
|
__name: "InputDate",
|
|
2962
3256
|
props: /*@__PURE__*/ g({
|
|
@@ -2988,7 +3282,7 @@ var Fa = [
|
|
|
2988
3282
|
let { t } = K(), n = e, r = F(e, "modelValue");
|
|
2989
3283
|
function l(e) {
|
|
2990
3284
|
if (e) try {
|
|
2991
|
-
return
|
|
3285
|
+
return Dn(e);
|
|
2992
3286
|
} catch {
|
|
2993
3287
|
return;
|
|
2994
3288
|
}
|
|
@@ -3015,8 +3309,8 @@ var Fa = [
|
|
|
3015
3309
|
return g.value.format(new Date(e.year, e.month - 1, e.day));
|
|
3016
3310
|
}
|
|
3017
3311
|
function D(e) {
|
|
3018
|
-
return
|
|
3019
|
-
today:
|
|
3312
|
+
return _o(e, {
|
|
3313
|
+
today: An(Tn()),
|
|
3020
3314
|
order: b.value,
|
|
3021
3315
|
prefer: n.prefer
|
|
3022
3316
|
});
|
|
@@ -3050,17 +3344,17 @@ var Fa = [
|
|
|
3050
3344
|
t && O.value === T(t) || (e.preventDefault(), I());
|
|
3051
3345
|
}
|
|
3052
3346
|
let B = i(() => A.value ?? h.value), ee = i(() => n.status ?? (B.value ? "error" : void 0)), W = i(() => n.statusText ?? B.value), G = E(!1);
|
|
3053
|
-
function
|
|
3347
|
+
function q(e) {
|
|
3054
3348
|
r.value = e, G.value = !1;
|
|
3055
3349
|
}
|
|
3056
|
-
let
|
|
3350
|
+
let J = [
|
|
3057
3351
|
"flex w-9 shrink-0 -my-2 -mr-3 self-stretch items-center justify-center",
|
|
3058
3352
|
"rounded-r border-l border-black/15 bg-white cursor-pointer transition",
|
|
3059
3353
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
3060
3354
|
"data-[state=open]:brightness-90 disabled:cursor-not-allowed",
|
|
3061
3355
|
"outline-2 -outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
3062
3356
|
];
|
|
3063
|
-
return (i, l) => (w(), a(
|
|
3357
|
+
return (i, l) => (w(), a(Ia, {
|
|
3064
3358
|
label: e.label,
|
|
3065
3359
|
helper: e.helper,
|
|
3066
3360
|
"helper-placement": e.helperPlacement,
|
|
@@ -3071,7 +3365,7 @@ var Fa = [
|
|
|
3071
3365
|
disabled: e.disabled,
|
|
3072
3366
|
class: y(n.class)
|
|
3073
3367
|
}, {
|
|
3074
|
-
default: V(({ id: n, describedBy: a, invalid: u }) => [d(M(
|
|
3368
|
+
default: V(({ id: n, describedBy: a, invalid: u }) => [d(M(ht), {
|
|
3075
3369
|
open: G.value,
|
|
3076
3370
|
"onUpdate:open": l[1] ||= (e) => G.value = e,
|
|
3077
3371
|
disabled: e.disabled
|
|
@@ -3091,26 +3385,26 @@ var Fa = [
|
|
|
3091
3385
|
onInput: P,
|
|
3092
3386
|
onBlur: I,
|
|
3093
3387
|
onKeydown: U(L, ["enter"])
|
|
3094
|
-
}), null, 16,
|
|
3095
|
-
k.value ? (w(), s("span",
|
|
3096
|
-
d(M(
|
|
3388
|
+
}), null, 16, vo), [[R, O.value]]),
|
|
3389
|
+
k.value ? (w(), s("span", yo, j(k.value), 1)) : o("", !0),
|
|
3390
|
+
d(M(gt), {
|
|
3097
3391
|
"aria-label": M(t)("ui.inputDate.openCalendar"),
|
|
3098
|
-
class: y(
|
|
3392
|
+
class: y(J)
|
|
3099
3393
|
}, {
|
|
3100
|
-
default: V(() => [d(M(
|
|
3394
|
+
default: V(() => [d(M(ue))]),
|
|
3101
3395
|
_: 1
|
|
3102
3396
|
}, 8, ["aria-label"]),
|
|
3103
|
-
d(M(
|
|
3397
|
+
d(M(mt), {
|
|
3104
3398
|
"side-offset": 6,
|
|
3105
3399
|
align: "end",
|
|
3106
|
-
class: y([M(
|
|
3400
|
+
class: y([M(Qn), "p-3"])
|
|
3107
3401
|
}, {
|
|
3108
|
-
default: V(() => [d(
|
|
3402
|
+
default: V(() => [d(Xa, {
|
|
3109
3403
|
"model-value": r.value,
|
|
3110
3404
|
min: e.min,
|
|
3111
3405
|
max: e.max,
|
|
3112
3406
|
locale: e.locale,
|
|
3113
|
-
"onUpdate:modelValue":
|
|
3407
|
+
"onUpdate:modelValue": q
|
|
3114
3408
|
}, null, 8, [
|
|
3115
3409
|
"model-value",
|
|
3116
3410
|
"min",
|
|
@@ -3135,7 +3429,7 @@ var Fa = [
|
|
|
3135
3429
|
"class"
|
|
3136
3430
|
]));
|
|
3137
3431
|
}
|
|
3138
|
-
}),
|
|
3432
|
+
}), xo = /* @__PURE__ */ f({
|
|
3139
3433
|
__name: "Tooltip",
|
|
3140
3434
|
props: {
|
|
3141
3435
|
text: {},
|
|
@@ -3152,20 +3446,20 @@ var Fa = [
|
|
|
3152
3446
|
] }
|
|
3153
3447
|
},
|
|
3154
3448
|
setup(e) {
|
|
3155
|
-
let t = e, n =
|
|
3449
|
+
let t = e, n = Sn(null) !== null, r = (e, { slots: r }) => n ? r.default?.() : m(yn, {
|
|
3156
3450
|
delayDuration: t.delay,
|
|
3157
3451
|
skipDelayDuration: 300
|
|
3158
3452
|
}, r);
|
|
3159
3453
|
return (n, i) => (w(), a(r, null, {
|
|
3160
|
-
default: V(() => [d(M(
|
|
3454
|
+
default: V(() => [d(M(bn), {
|
|
3161
3455
|
disabled: e.disabled,
|
|
3162
3456
|
"delay-duration": e.delay
|
|
3163
3457
|
}, {
|
|
3164
|
-
default: V(() => [d(M(
|
|
3458
|
+
default: V(() => [d(M(xn), { "as-child": "" }, {
|
|
3165
3459
|
default: V(() => [O(n.$slots, "default")]),
|
|
3166
3460
|
_: 3
|
|
3167
|
-
}), d(M(
|
|
3168
|
-
default: V(() => [d(M(
|
|
3461
|
+
}), d(M(vn), null, {
|
|
3462
|
+
default: V(() => [d(M(_n), {
|
|
3169
3463
|
side: e.side,
|
|
3170
3464
|
align: e.align,
|
|
3171
3465
|
"side-offset": 8,
|
|
@@ -3186,7 +3480,7 @@ var Fa = [
|
|
|
3186
3480
|
_: 3
|
|
3187
3481
|
}));
|
|
3188
3482
|
}
|
|
3189
|
-
}),
|
|
3483
|
+
}), So = { class: "-mx-3 -my-2 flex min-w-0 flex-1 flex-col self-stretch" }, Co = ["aria-label", "aria-controls"], wo = /* @__PURE__ */ f({
|
|
3190
3484
|
__name: "InputRichText",
|
|
3191
3485
|
props: /*@__PURE__*/ g({
|
|
3192
3486
|
label: {},
|
|
@@ -3211,19 +3505,19 @@ var Fa = [
|
|
|
3211
3505
|
}),
|
|
3212
3506
|
emits: ["update:modelValue"],
|
|
3213
3507
|
setup(e) {
|
|
3214
|
-
let { t } = K(), r = e, i = F(e, "modelValue"), o = () => l.value?.isEmpty ? "" : l.value?.getHTML() ?? "", l =
|
|
3508
|
+
let { t } = K(), r = e, i = F(e, "modelValue"), o = () => l.value?.isEmpty ? "" : l.value?.getHTML() ?? "", l = Mn({
|
|
3215
3509
|
content: i.value,
|
|
3216
3510
|
editable: !r.disabled,
|
|
3217
3511
|
extensions: [
|
|
3218
|
-
|
|
3219
|
-
Dn,
|
|
3220
|
-
On,
|
|
3221
|
-
kn,
|
|
3222
|
-
An,
|
|
3223
|
-
jn,
|
|
3224
|
-
Mn,
|
|
3512
|
+
Nn,
|
|
3225
3513
|
Pn,
|
|
3226
|
-
|
|
3514
|
+
Fn,
|
|
3515
|
+
In,
|
|
3516
|
+
Ln,
|
|
3517
|
+
Rn,
|
|
3518
|
+
zn,
|
|
3519
|
+
Vn,
|
|
3520
|
+
Bn.configure({ placeholder: () => r.placeholder ?? "" })
|
|
3227
3521
|
],
|
|
3228
3522
|
onUpdate: () => {
|
|
3229
3523
|
i.value = o();
|
|
@@ -3270,7 +3564,7 @@ var Fa = [
|
|
|
3270
3564
|
get label() {
|
|
3271
3565
|
return t("ui.inputRichText.bold");
|
|
3272
3566
|
},
|
|
3273
|
-
icon:
|
|
3567
|
+
icon: ce,
|
|
3274
3568
|
key: "B",
|
|
3275
3569
|
toggle: () => l.value?.chain().focus().toggleBold().run()
|
|
3276
3570
|
},
|
|
@@ -3279,7 +3573,7 @@ var Fa = [
|
|
|
3279
3573
|
get label() {
|
|
3280
3574
|
return t("ui.inputRichText.italic");
|
|
3281
3575
|
},
|
|
3282
|
-
icon:
|
|
3576
|
+
icon: Ee,
|
|
3283
3577
|
key: "I",
|
|
3284
3578
|
toggle: () => l.value?.chain().focus().toggleItalic().run()
|
|
3285
3579
|
},
|
|
@@ -3288,12 +3582,12 @@ var Fa = [
|
|
|
3288
3582
|
get label() {
|
|
3289
3583
|
return t("ui.inputRichText.underline");
|
|
3290
3584
|
},
|
|
3291
|
-
icon:
|
|
3585
|
+
icon: ze,
|
|
3292
3586
|
key: "U",
|
|
3293
3587
|
toggle: () => l.value?.chain().focus().toggleUnderline().run()
|
|
3294
3588
|
}
|
|
3295
3589
|
], v = "min-h-24 max-h-80 overflow-y-auto px-3 py-2 text-sm pointer-coarse:text-base outline-none cursor-text [&_p+p]:mt-2 [&_p.is-editor-empty:first-child]:before:pointer-events-none [&_p.is-editor-empty:first-child]:before:float-left [&_p.is-editor-empty:first-child]:before:h-0 [&_p.is-editor-empty:first-child]:before:text-black/55 [&_p.is-editor-empty:first-child]:before:content-[attr(data-placeholder)]";
|
|
3296
|
-
return (i, o) => (w(), a(
|
|
3590
|
+
return (i, o) => (w(), a(Ia, {
|
|
3297
3591
|
label: e.label,
|
|
3298
3592
|
helper: e.helper,
|
|
3299
3593
|
"helper-placement": e.helperPlacement,
|
|
@@ -3304,14 +3598,14 @@ var Fa = [
|
|
|
3304
3598
|
disabled: e.disabled,
|
|
3305
3599
|
class: y(r.class)
|
|
3306
3600
|
}, {
|
|
3307
|
-
default: V((r) => [c("div",
|
|
3601
|
+
default: V((r) => [c("div", So, [
|
|
3308
3602
|
c("div", {
|
|
3309
3603
|
role: "toolbar",
|
|
3310
3604
|
"aria-label": M(t)("ui.inputRichText.formattingFor", { label: e.label }),
|
|
3311
3605
|
"aria-controls": r.id,
|
|
3312
3606
|
class: "flex items-center gap-0.5 border-b border-black/15 px-1.5 py-1 [&_svg]:opacity-100!",
|
|
3313
3607
|
onMousedown: o[0] ||= ee(() => {}, ["prevent"])
|
|
3314
|
-
}, [(w(), s(n, null, D(_, (t) => d(
|
|
3608
|
+
}, [(w(), s(n, null, D(_, (t) => d(xo, {
|
|
3315
3609
|
key: t.name,
|
|
3316
3610
|
text: `${t.label} (${M(g)}${t.key})`,
|
|
3317
3611
|
disabled: e.disabled
|
|
@@ -3337,9 +3631,9 @@ var Fa = [
|
|
|
3337
3631
|
"onClick"
|
|
3338
3632
|
])]),
|
|
3339
3633
|
_: 2
|
|
3340
|
-
}, 1032, ["text", "disabled"])), 64))], 40,
|
|
3634
|
+
}, 1032, ["text", "disabled"])), 64))], 40, Co),
|
|
3341
3635
|
d(M(m), { ids: r }, null, 8, ["ids"]),
|
|
3342
|
-
d(M(
|
|
3636
|
+
d(M(jn), {
|
|
3343
3637
|
editor: M(l),
|
|
3344
3638
|
class: y(M(X)("min-w-0", e.disabled && "cursor-not-allowed [&_*]:cursor-not-allowed"))
|
|
3345
3639
|
}, null, 8, ["editor", "class"])
|
|
@@ -3357,18 +3651,18 @@ var Fa = [
|
|
|
3357
3651
|
"class"
|
|
3358
3652
|
]));
|
|
3359
3653
|
}
|
|
3360
|
-
}),
|
|
3654
|
+
}), To = [
|
|
3361
3655
|
"id",
|
|
3362
3656
|
"type",
|
|
3363
3657
|
"autocomplete",
|
|
3364
3658
|
"disabled",
|
|
3365
3659
|
"aria-invalid",
|
|
3366
3660
|
"aria-describedby"
|
|
3367
|
-
],
|
|
3661
|
+
], Eo = [
|
|
3368
3662
|
"aria-controls",
|
|
3369
3663
|
"aria-pressed",
|
|
3370
3664
|
"disabled"
|
|
3371
|
-
],
|
|
3665
|
+
], Do = { class: "sr-only" }, Oo = /* @__PURE__ */ f({
|
|
3372
3666
|
inheritAttrs: !1,
|
|
3373
3667
|
__name: "InputPassword",
|
|
3374
3668
|
props: /*@__PURE__*/ g({
|
|
@@ -3407,7 +3701,7 @@ var Fa = [
|
|
|
3407
3701
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
3408
3702
|
"outline-none focus-visible:bg-black/5 disabled:cursor-not-allowed"
|
|
3409
3703
|
];
|
|
3410
|
-
return (i, o) => (w(), a(
|
|
3704
|
+
return (i, o) => (w(), a(Ia, {
|
|
3411
3705
|
label: e.label,
|
|
3412
3706
|
helper: e.helper,
|
|
3413
3707
|
"helper-placement": e.helperPlacement,
|
|
@@ -3436,7 +3730,7 @@ var Fa = [
|
|
|
3436
3730
|
onKeydown: h,
|
|
3437
3731
|
onKeyup: h,
|
|
3438
3732
|
onBlur: o[1] ||= (e) => m.value = !1
|
|
3439
|
-
}), null, 16,
|
|
3733
|
+
}), null, 16, To), [[L, r.value]]), c("button", {
|
|
3440
3734
|
type: "button",
|
|
3441
3735
|
class: y(v),
|
|
3442
3736
|
"aria-controls": n,
|
|
@@ -3444,13 +3738,13 @@ var Fa = [
|
|
|
3444
3738
|
disabled: e.disabled,
|
|
3445
3739
|
onPointerdown: o[2] ||= ee(() => {}, ["prevent"]),
|
|
3446
3740
|
onClick: o[3] ||= (e) => d.value = !d.value
|
|
3447
|
-
}, [c("span",
|
|
3741
|
+
}, [c("span", Do, j(M(t)("ui.inputPassword.show")), 1), d.value ? (w(), a(M(Ce), {
|
|
3448
3742
|
key: 0,
|
|
3449
3743
|
"aria-hidden": "true"
|
|
3450
|
-
})) : (w(), a(M(
|
|
3744
|
+
})) : (w(), a(M(Se), {
|
|
3451
3745
|
key: 1,
|
|
3452
3746
|
"aria-hidden": "true"
|
|
3453
|
-
}))], 40,
|
|
3747
|
+
}))], 40, Eo)]),
|
|
3454
3748
|
_: 2
|
|
3455
3749
|
}, [i.$slots.leading ? {
|
|
3456
3750
|
name: "leading",
|
|
@@ -3472,7 +3766,7 @@ var Fa = [
|
|
|
3472
3766
|
"class"
|
|
3473
3767
|
]));
|
|
3474
3768
|
}
|
|
3475
|
-
}),
|
|
3769
|
+
}), ko = { class: "flex flex-col gap-0.5" }, Ao = { class: "flex items-center gap-1" }, jo = ["for"], Mo = ["hidden"], No = /* @__PURE__ */ f({
|
|
3476
3770
|
__name: "InputCode",
|
|
3477
3771
|
props: /*@__PURE__*/ g({
|
|
3478
3772
|
label: {},
|
|
@@ -3515,11 +3809,11 @@ var Fa = [
|
|
|
3515
3809
|
loading: ""
|
|
3516
3810
|
};
|
|
3517
3811
|
return (t, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", l.class)) }, [
|
|
3518
|
-
c("div",
|
|
3812
|
+
c("div", ko, [c("div", Ao, [c("label", {
|
|
3519
3813
|
id: m,
|
|
3520
3814
|
for: `${M(p)}-0`,
|
|
3521
3815
|
class: "text-sm"
|
|
3522
|
-
}, j(e.label), 9,
|
|
3816
|
+
}, j(e.label), 9, jo), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
3523
3817
|
key: 0,
|
|
3524
3818
|
text: e.helper,
|
|
3525
3819
|
label: M(r)("ui.formField.about", { label: e.label })
|
|
@@ -3528,8 +3822,8 @@ var Fa = [
|
|
|
3528
3822
|
id: h,
|
|
3529
3823
|
hidden: e.helperPlacement === "icon",
|
|
3530
3824
|
class: "text-xs text-black/65"
|
|
3531
|
-
}, j(e.helper), 9,
|
|
3532
|
-
d(M(
|
|
3825
|
+
}, j(e.helper), 9, Mo)) : o("", !0)]),
|
|
3826
|
+
d(M(Ft), {
|
|
3533
3827
|
"model-value": x.value,
|
|
3534
3828
|
type: e.alphanumeric ? "text" : "number",
|
|
3535
3829
|
name: e.name,
|
|
@@ -3542,7 +3836,7 @@ var Fa = [
|
|
|
3542
3836
|
"onUpdate:modelValue": C,
|
|
3543
3837
|
onComplete: T
|
|
3544
3838
|
}, {
|
|
3545
|
-
default: V(() => [(w(!0), s(n, null, D(e.length, (t, n) => (w(), a(M(
|
|
3839
|
+
default: V(() => [(w(!0), s(n, null, D(e.length, (t, n) => (w(), a(M(Pt), {
|
|
3546
3840
|
id: `${M(p)}-${n}`,
|
|
3547
3841
|
key: n,
|
|
3548
3842
|
index: n,
|
|
@@ -3571,32 +3865,32 @@ var Fa = [
|
|
|
3571
3865
|
"disabled",
|
|
3572
3866
|
"class"
|
|
3573
3867
|
]),
|
|
3574
|
-
d(
|
|
3868
|
+
d(ja, {
|
|
3575
3869
|
id: g,
|
|
3576
3870
|
status: _.value,
|
|
3577
3871
|
text: v.value
|
|
3578
3872
|
}, null, 8, ["status", "text"])
|
|
3579
3873
|
], 2));
|
|
3580
3874
|
}
|
|
3581
|
-
}),
|
|
3875
|
+
}), Po = {
|
|
3582
3876
|
key: 0,
|
|
3583
3877
|
class: "flex min-w-0 flex-1 flex-wrap gap-1"
|
|
3584
|
-
},
|
|
3878
|
+
}, Fo = {
|
|
3585
3879
|
key: 1,
|
|
3586
3880
|
class: "h-5 min-w-0 flex-1 truncate"
|
|
3587
|
-
},
|
|
3881
|
+
}, Io = { class: "flex h-5 shrink-0 items-center" }, Lo = { class: "min-w-0 flex-1 truncate" }, Ro = { class: "truncate" }, zo = {
|
|
3588
3882
|
key: 0,
|
|
3589
3883
|
class: "flex h-5 shrink-0 items-center"
|
|
3590
|
-
},
|
|
3884
|
+
}, Bo = { class: "flex min-w-0 flex-1 flex-col" }, Vo = {
|
|
3591
3885
|
key: 0,
|
|
3592
3886
|
class: "sr-only"
|
|
3593
|
-
},
|
|
3887
|
+
}, Ho = {
|
|
3594
3888
|
key: 0,
|
|
3595
3889
|
class: "text-xs text-black/65"
|
|
3596
|
-
},
|
|
3890
|
+
}, Uo = {
|
|
3597
3891
|
key: 1,
|
|
3598
3892
|
class: "text-xs text-black/65"
|
|
3599
|
-
},
|
|
3893
|
+
}, Wo = { class: "flex h-5 w-4 shrink-0 items-center justify-center" }, Go = "-mx-3 -my-2 flex min-w-0 flex-1 items-center gap-2 self-stretch px-3 py-2", Ko = "transition-transform duration-150 in-data-[state=open]:rotate-180 motion-reduce:transition-none", qo = /* @__PURE__ */ f({
|
|
3600
3894
|
__name: "Select",
|
|
3601
3895
|
props: /*@__PURE__*/ g({
|
|
3602
3896
|
label: {},
|
|
@@ -3657,15 +3951,15 @@ var Fa = [
|
|
|
3657
3951
|
function B(e) {
|
|
3658
3952
|
r.multiple && !oe.value && p.value.length && (e.preventDefault(), z(p.value[p.value.length - 1]));
|
|
3659
3953
|
}
|
|
3660
|
-
let H = (e) => A.value.find((t) => t.option.value === e)?.option.label ?? "", W = E([]), G = i(() => W.value[W.value.length - 1]),
|
|
3661
|
-
function
|
|
3662
|
-
|
|
3954
|
+
let H = (e) => A.value.find((t) => t.option.value === e)?.option.label ?? "", W = E([]), G = i(() => W.value[W.value.length - 1]), q = E(!1);
|
|
3955
|
+
function J(e) {
|
|
3956
|
+
q.value = e, e ? W.value = I.value ? [...I.value.path] : [] : re.value = ne;
|
|
3663
3957
|
}
|
|
3664
|
-
function
|
|
3665
|
-
e.target.select(),
|
|
3958
|
+
function te(e) {
|
|
3959
|
+
e.target.select(), re.value = ne;
|
|
3666
3960
|
}
|
|
3667
|
-
let
|
|
3668
|
-
|
|
3961
|
+
let ne = !1, re = E(!1), ie = () => ne = !0, ae = () => {
|
|
3962
|
+
ne = !1, re.value = !1;
|
|
3669
3963
|
};
|
|
3670
3964
|
C(() => {
|
|
3671
3965
|
document.addEventListener("pointerdown", ie, !0), document.addEventListener("keydown", ae, !0), document.fonts?.load(`700 1em ${getComputedStyle(document.body).fontFamily}`).catch(() => {});
|
|
@@ -3679,7 +3973,7 @@ var Fa = [
|
|
|
3679
3973
|
option: e,
|
|
3680
3974
|
parent: r
|
|
3681
3975
|
};
|
|
3682
|
-
}),
|
|
3976
|
+
}), le = i(() => {
|
|
3683
3977
|
if (r.searchable && oe.value && N.value) {
|
|
3684
3978
|
let e = /* @__PURE__ */ new Map();
|
|
3685
3979
|
for (let t of A.value) {
|
|
@@ -3698,10 +3992,10 @@ var Fa = [
|
|
|
3698
3992
|
icon: e.icon,
|
|
3699
3993
|
rows: ce(e.options, `group-${t}`)
|
|
3700
3994
|
}));
|
|
3701
|
-
}),
|
|
3995
|
+
}), ue = i(() => !!G.value && !(r.searchable && oe.value)), he = { back: !0 }, ge = (e) => ({ parent: e.key }), _e = `${P()}-list`;
|
|
3702
3996
|
async function ve(e) {
|
|
3703
3997
|
await v();
|
|
3704
|
-
let t = document.querySelector(`[data-list-id="${_e}"]`), n = e &&
|
|
3998
|
+
let t = document.querySelector(`[data-list-id="${_e}"]`), n = e && le.value.flatMap((e) => e.rows).find((t) => t.parent && t.option.label === e.label)?.key, i = n && t?.querySelector(`[data-parent-key="${n}"]`) || t?.querySelector("[role=\"option\"]:not([data-disabled]):not([data-back])") || t?.querySelector("[role=\"option\"][data-back]");
|
|
3705
3999
|
i && (r.searchable ? i.dispatchEvent(new PointerEvent("pointermove", { bubbles: !0 })) : i.focus());
|
|
3706
4000
|
}
|
|
3707
4001
|
function ye(e, t) {
|
|
@@ -3716,35 +4010,35 @@ var Fa = [
|
|
|
3716
4010
|
if (!(e.defaultPrevented || r.searchable && oe.value)) {
|
|
3717
4011
|
if (e.key === "ArrowLeft" && W.value.length) e.preventDefault(), be();
|
|
3718
4012
|
else if (e.key === "ArrowRight") {
|
|
3719
|
-
let t = document.querySelector(`[data-list-id="${_e}"]`)?.querySelector("[data-highlighted][data-parent-key]"), n = t &&
|
|
4013
|
+
let t = document.querySelector(`[data-list-id="${_e}"]`)?.querySelector("[data-highlighted][data-parent-key]"), n = t && le.value.flatMap((e) => e.rows).find((e) => e.key === t.dataset.parentKey);
|
|
3720
4014
|
if (!n) return;
|
|
3721
4015
|
e.preventDefault(), ye(e, n.option);
|
|
3722
4016
|
}
|
|
3723
4017
|
}
|
|
3724
4018
|
}
|
|
3725
4019
|
let Y = i(() => r.searchable ? {
|
|
3726
|
-
Root:
|
|
3727
|
-
Portal:
|
|
3728
|
-
Content:
|
|
3729
|
-
Viewport:
|
|
3730
|
-
Group:
|
|
3731
|
-
Label:
|
|
3732
|
-
Separator:
|
|
3733
|
-
Item:
|
|
4020
|
+
Root: ut,
|
|
4021
|
+
Portal: lt,
|
|
4022
|
+
Content: nt,
|
|
4023
|
+
Viewport: pt,
|
|
4024
|
+
Group: it,
|
|
4025
|
+
Label: ct,
|
|
4026
|
+
Separator: dt,
|
|
4027
|
+
Item: ot,
|
|
3734
4028
|
ItemText: "span",
|
|
3735
|
-
Indicator:
|
|
4029
|
+
Indicator: st
|
|
3736
4030
|
} : {
|
|
3737
|
-
Root:
|
|
3738
|
-
Portal:
|
|
3739
|
-
Content:
|
|
3740
|
-
Viewport:
|
|
3741
|
-
Group:
|
|
3742
|
-
Label:
|
|
3743
|
-
Separator:
|
|
3744
|
-
Item:
|
|
3745
|
-
ItemText:
|
|
3746
|
-
Indicator:
|
|
3747
|
-
}), Se = i(() => X(
|
|
4031
|
+
Root: tn,
|
|
4032
|
+
Portal: en,
|
|
4033
|
+
Content: Jt,
|
|
4034
|
+
Viewport: an,
|
|
4035
|
+
Group: Yt,
|
|
4036
|
+
Label: $t,
|
|
4037
|
+
Separator: nn,
|
|
4038
|
+
Item: Xt,
|
|
4039
|
+
ItemText: Qt,
|
|
4040
|
+
Indicator: Zt
|
|
4041
|
+
}), Se = i(() => X(Qn, "overflow-hidden", r.searchable ? "max-h-(--reka-combobox-content-available-height) min-w-(--reka-combobox-trigger-width) max-w-[max(var(--reka-combobox-trigger-width),--spacing(80))]" : "max-h-(--reka-select-content-available-height) min-w-(--reka-select-trigger-width) max-w-[max(var(--reka-select-trigger-width),--spacing(80))]")), Ce = [
|
|
3748
4042
|
"relative flex min-h-8 cursor-pointer items-start gap-2 rounded px-2 py-1.5 text-sm outline-none select-none",
|
|
3749
4043
|
"data-highlighted:bg-black/10",
|
|
3750
4044
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
@@ -3753,7 +4047,7 @@ var Fa = [
|
|
|
3753
4047
|
e.option.description,
|
|
3754
4048
|
e.path
|
|
3755
4049
|
].filter(Boolean).join(" ") : e.option.label;
|
|
3756
|
-
return (i, f) => (w(), a(
|
|
4050
|
+
return (i, f) => (w(), a(Ia, {
|
|
3757
4051
|
label: e.label,
|
|
3758
4052
|
helper: e.helper,
|
|
3759
4053
|
"helper-placement": e.helperPlacement,
|
|
@@ -3775,21 +4069,21 @@ var Fa = [
|
|
|
3775
4069
|
class: "contents"
|
|
3776
4070
|
} : {}, {
|
|
3777
4071
|
"onUpdate:modelValue": h,
|
|
3778
|
-
open:
|
|
3779
|
-
"onUpdate:open":
|
|
4072
|
+
open: q.value,
|
|
4073
|
+
"onUpdate:open": J
|
|
3780
4074
|
}), {
|
|
3781
|
-
default: V(() => [e.searchable ? (w(), a(M(
|
|
4075
|
+
default: V(() => [e.searchable ? (w(), a(M(tt), {
|
|
3782
4076
|
key: 0,
|
|
3783
|
-
class: y(
|
|
3784
|
-
onPointerdown: f[4] ||= (e) =>
|
|
3785
|
-
onClick: f[5] ||= (t) => !e.disabled && !t.target.closest("button") &&
|
|
4077
|
+
class: y(Go),
|
|
4078
|
+
onPointerdown: f[4] ||= (e) => re.value = !0,
|
|
4079
|
+
onClick: f[5] ||= (t) => !e.disabled && !t.target.closest("button") && J(!0)
|
|
3786
4080
|
}, {
|
|
3787
4081
|
default: V(() => [
|
|
3788
4082
|
O(i.$slots, "leading", {}, () => [L.value?.icon ? (w(), a(k(L.value.icon), {
|
|
3789
4083
|
key: 0,
|
|
3790
4084
|
"aria-hidden": "true"
|
|
3791
4085
|
})) : o("", !0)]),
|
|
3792
|
-
c("span", { class: y(e.multiple ? "flex min-w-0 flex-1 flex-wrap items-center gap-1" : "contents") }, [(w(!0), s(n, null, D(R.value, (n) => (w(), a(
|
|
4086
|
+
c("span", { class: y(e.multiple ? "flex min-w-0 flex-1 flex-wrap items-center gap-1" : "contents") }, [(w(!0), s(n, null, D(R.value, (n) => (w(), a(ga, {
|
|
3793
4087
|
key: String(n.value),
|
|
3794
4088
|
size: "sm",
|
|
3795
4089
|
removable: "",
|
|
@@ -3809,7 +4103,7 @@ var Fa = [
|
|
|
3809
4103
|
"remove-label",
|
|
3810
4104
|
"disabled",
|
|
3811
4105
|
"onRemove"
|
|
3812
|
-
]))), 128)), d(M(
|
|
4106
|
+
]))), 128)), d(M(at), {
|
|
3813
4107
|
id: r,
|
|
3814
4108
|
ref_key: "searchInput",
|
|
3815
4109
|
ref: se,
|
|
@@ -3821,9 +4115,9 @@ var Fa = [
|
|
|
3821
4115
|
"aria-describedby": p,
|
|
3822
4116
|
autocomplete: "off",
|
|
3823
4117
|
class: y(M(X)("h-5 min-w-0 flex-1 bg-transparent outline-none placeholder:text-black/55 disabled:cursor-not-allowed", e.multiple && "min-w-16")),
|
|
3824
|
-
"data-pointer-focus":
|
|
3825
|
-
onFocus:
|
|
3826
|
-
onBlur: f[2] ||= (e) =>
|
|
4118
|
+
"data-pointer-focus": re.value || void 0,
|
|
4119
|
+
onFocus: te,
|
|
4120
|
+
onBlur: f[2] ||= (e) => re.value = !1,
|
|
3827
4121
|
onKeydown: [f[3] ||= (e) => e.target.ariaExpanded === "true" && xe(e), U(B, ["backspace"])]
|
|
3828
4122
|
}, null, 8, [
|
|
3829
4123
|
"id",
|
|
@@ -3835,34 +4129,34 @@ var Fa = [
|
|
|
3835
4129
|
"class",
|
|
3836
4130
|
"data-pointer-focus"
|
|
3837
4131
|
])], 2),
|
|
3838
|
-
d(M(
|
|
4132
|
+
d(M(ft), {
|
|
3839
4133
|
tabindex: "-1",
|
|
3840
4134
|
"aria-label": M(t)("ui.select.showOptions"),
|
|
3841
4135
|
class: "flex cursor-pointer disabled:cursor-not-allowed"
|
|
3842
4136
|
}, {
|
|
3843
|
-
default: V(() => [d(M(
|
|
4137
|
+
default: V(() => [d(M(fe), {
|
|
3844
4138
|
"aria-hidden": "true",
|
|
3845
|
-
class: y(
|
|
4139
|
+
class: y(Ko)
|
|
3846
4140
|
})]),
|
|
3847
4141
|
_: 1
|
|
3848
4142
|
}, 8, ["aria-label"])
|
|
3849
4143
|
]),
|
|
3850
4144
|
_: 2
|
|
3851
|
-
}, 1024)) : (w(), a(M(
|
|
4145
|
+
}, 1024)) : (w(), a(M(rn), {
|
|
3852
4146
|
key: 1,
|
|
3853
4147
|
id: r,
|
|
3854
4148
|
"aria-invalid": v,
|
|
3855
4149
|
"aria-describedby": p,
|
|
3856
|
-
"data-pointer-focus":
|
|
3857
|
-
onBlur: f[6] ||= (e) =>
|
|
3858
|
-
class: y(M(X)(
|
|
4150
|
+
"data-pointer-focus": re.value || void 0,
|
|
4151
|
+
onBlur: f[6] ||= (e) => re.value = !1,
|
|
4152
|
+
class: y(M(X)(Go, "cursor-pointer text-left outline-none disabled:cursor-not-allowed data-placeholder:text-black/55"))
|
|
3859
4153
|
}, {
|
|
3860
4154
|
default: V(() => [
|
|
3861
4155
|
O(i.$slots, "leading", {}, () => [L.value?.icon ? (w(), a(k(L.value.icon), {
|
|
3862
4156
|
key: 0,
|
|
3863
4157
|
"aria-hidden": "true"
|
|
3864
4158
|
})) : o("", !0)]),
|
|
3865
|
-
e.multiple && R.value.length ? (w(), s("span",
|
|
4159
|
+
e.multiple && R.value.length ? (w(), s("span", Po, [(w(!0), s(n, null, D(R.value, (e) => (w(), a(ga, {
|
|
3866
4160
|
key: String(e.value),
|
|
3867
4161
|
size: "sm"
|
|
3868
4162
|
}, l({
|
|
@@ -3872,10 +4166,10 @@ var Fa = [
|
|
|
3872
4166
|
name: "leading",
|
|
3873
4167
|
fn: V(() => [(w(), a(k(e.icon), { "aria-hidden": "true" }))]),
|
|
3874
4168
|
key: "0"
|
|
3875
|
-
} : void 0]), 1024))), 128))])) : (w(), s("span",
|
|
3876
|
-
d(M(
|
|
4169
|
+
} : void 0]), 1024))), 128))])) : (w(), s("span", Fo, j(L.value?.label ?? g.value), 1)),
|
|
4170
|
+
d(M(fe), {
|
|
3877
4171
|
"aria-hidden": "true",
|
|
3878
|
-
class: y(
|
|
4172
|
+
class: y(Ko)
|
|
3879
4173
|
})
|
|
3880
4174
|
]),
|
|
3881
4175
|
_: 3
|
|
@@ -3896,27 +4190,27 @@ var Fa = [
|
|
|
3896
4190
|
}, {
|
|
3897
4191
|
default: V(() => [(w(), a(k(Y.value.Viewport), { class: "flex flex-col gap-0.5 p-1 [scrollbar-width:thin]! [&::-webkit-scrollbar]:block!" }, {
|
|
3898
4192
|
default: V(() => [
|
|
3899
|
-
e.searchable ? (w(), a(M(
|
|
4193
|
+
e.searchable ? (w(), a(M(rt), {
|
|
3900
4194
|
key: 0,
|
|
3901
4195
|
class: "px-2 py-1.5 text-sm text-black/65"
|
|
3902
4196
|
}, {
|
|
3903
4197
|
default: V(() => [u(j(e.emptyText ?? M(t)("ui.select.noMatches")), 1)]),
|
|
3904
4198
|
_: 1
|
|
3905
4199
|
})) : o("", !0),
|
|
3906
|
-
|
|
4200
|
+
ue.value ? (w(), s(n, { key: 1 }, [(w(), a(k(Y.value.Item), {
|
|
3907
4201
|
value: he,
|
|
3908
4202
|
"data-back": "",
|
|
3909
4203
|
"text-value": G.value.label,
|
|
3910
4204
|
class: y(M(X)(Ce, "font-bold")),
|
|
3911
4205
|
onSelect: be
|
|
3912
4206
|
}, {
|
|
3913
|
-
default: V(() => [c("span",
|
|
4207
|
+
default: V(() => [c("span", Io, [d(M(pe), {
|
|
3914
4208
|
"aria-hidden": "true",
|
|
3915
4209
|
class: "size-4"
|
|
3916
|
-
})]), c("span",
|
|
4210
|
+
})]), c("span", Lo, [f[9] ||= c("span", { class: "sr-only" }, "Back from ", -1), u(j(G.value.label), 1)])]),
|
|
3917
4211
|
_: 1
|
|
3918
4212
|
}, 40, ["text-value", "class"])), (w(), a(k(Y.value.Separator), { class: "-mx-1 my-0.5 border-t border-black/15" }))], 64)) : o("", !0),
|
|
3919
|
-
(w(!0), s(n, null, D(
|
|
4213
|
+
(w(!0), s(n, null, D(le.value, (e, t) => (w(), s(n, { key: t }, [t > 0 && !oe.value ? (w(), a(k(Y.value.Separator), {
|
|
3920
4214
|
key: 0,
|
|
3921
4215
|
class: "-mx-1 my-0.5 border-t border-black/15"
|
|
3922
4216
|
})) : o("", !0), (w(), a(k(Y.value.Group), { class: "flex flex-col gap-0.5" }, {
|
|
@@ -3928,7 +4222,7 @@ var Fa = [
|
|
|
3928
4222
|
key: 0,
|
|
3929
4223
|
"aria-hidden": "true",
|
|
3930
4224
|
class: "size-3.5 shrink-0"
|
|
3931
|
-
})) : o("", !0), c("span",
|
|
4225
|
+
})) : o("", !0), c("span", Ro, j(e.label), 1)]),
|
|
3932
4226
|
_: 2
|
|
3933
4227
|
}, 1024)) : o("", !0), (w(!0), s(n, null, D(e.rows, (e) => (w(), a(k(Y.value.Item), {
|
|
3934
4228
|
key: e.key,
|
|
@@ -3940,24 +4234,24 @@ var Fa = [
|
|
|
3940
4234
|
onSelect: (t) => e.parent && ye(t, e.option)
|
|
3941
4235
|
}, {
|
|
3942
4236
|
default: V(() => [
|
|
3943
|
-
e.option.icon ? (w(), s("span",
|
|
4237
|
+
e.option.icon ? (w(), s("span", zo, [(w(), a(k(e.option.icon), {
|
|
3944
4238
|
"aria-hidden": "true",
|
|
3945
4239
|
class: "size-4 opacity-70"
|
|
3946
4240
|
}))])) : o("", !0),
|
|
3947
|
-
c("span",
|
|
4241
|
+
c("span", Bo, [
|
|
3948
4242
|
(w(), a(k(Y.value.ItemText), { class: "truncate in-data-[state=checked]:font-bold" }, {
|
|
3949
|
-
default: V(() => [u(j(e.option.label), 1), e.parent ? (w(), s("span",
|
|
4243
|
+
default: V(() => [u(j(e.option.label), 1), e.parent ? (w(), s("span", Vo, ", more options")) : o("", !0)]),
|
|
3950
4244
|
_: 2
|
|
3951
4245
|
}, 1024)),
|
|
3952
|
-
e.path ? (w(), s("span",
|
|
3953
|
-
e.option.description ? (w(), s("span",
|
|
4246
|
+
e.path ? (w(), s("span", Ho, j(e.path), 1)) : o("", !0),
|
|
4247
|
+
e.option.description ? (w(), s("span", Uo, j(e.option.description), 1)) : o("", !0)
|
|
3954
4248
|
]),
|
|
3955
|
-
c("span",
|
|
4249
|
+
c("span", Wo, [e.parent ? (w(), a(M(me), {
|
|
3956
4250
|
key: 0,
|
|
3957
4251
|
"aria-hidden": "true",
|
|
3958
4252
|
class: "size-4 opacity-70"
|
|
3959
4253
|
})) : (w(), a(k(Y.value.Indicator), { key: 1 }, {
|
|
3960
|
-
default: V(() => [d(M(
|
|
4254
|
+
default: V(() => [d(M(de), { class: "size-4" })]),
|
|
3961
4255
|
_: 1
|
|
3962
4256
|
}))])
|
|
3963
4257
|
]),
|
|
@@ -4000,7 +4294,7 @@ var Fa = [
|
|
|
4000
4294
|
"class"
|
|
4001
4295
|
]));
|
|
4002
4296
|
}
|
|
4003
|
-
}),
|
|
4297
|
+
}), Jo = { class: "flex items-start gap-2" }, Yo = /* @__PURE__ */ f({
|
|
4004
4298
|
__name: "Checkbox",
|
|
4005
4299
|
props: /*@__PURE__*/ g({
|
|
4006
4300
|
label: {},
|
|
@@ -4039,7 +4333,7 @@ var Fa = [
|
|
|
4039
4333
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus",
|
|
4040
4334
|
"[&_svg]:size-3.5 [&_svg]:stroke-3"
|
|
4041
4335
|
];
|
|
4042
|
-
return (r, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", e.disabled && "opacity-40", t.class)) }, [c("div",
|
|
4336
|
+
return (r, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", e.disabled && "opacity-40", t.class)) }, [c("div", Jo, [d(M(et), {
|
|
4043
4337
|
id: l,
|
|
4044
4338
|
modelValue: n.value,
|
|
4045
4339
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -4051,11 +4345,11 @@ var Fa = [
|
|
|
4051
4345
|
"aria-describedby": p.value,
|
|
4052
4346
|
class: y(M(X)(h, e.errorText ? "border-red" : "border-black/55"))
|
|
4053
4347
|
}, {
|
|
4054
|
-
default: V(() => [d(M(
|
|
4055
|
-
default: V(() => [n.value === "indeterminate" ? (w(), a(M(
|
|
4348
|
+
default: V(() => [d(M($e), { class: "flex" }, {
|
|
4349
|
+
default: V(() => [n.value === "indeterminate" ? (w(), a(M(je), {
|
|
4056
4350
|
key: 0,
|
|
4057
4351
|
"aria-hidden": "true"
|
|
4058
|
-
})) : (w(), a(M(
|
|
4352
|
+
})) : (w(), a(M(de), {
|
|
4059
4353
|
key: 1,
|
|
4060
4354
|
"aria-hidden": "true"
|
|
4061
4355
|
}))]),
|
|
@@ -4081,13 +4375,13 @@ var Fa = [
|
|
|
4081
4375
|
key: 0,
|
|
4082
4376
|
id: u,
|
|
4083
4377
|
class: "text-xs text-black/65"
|
|
4084
|
-
}, j(e.description), 1)) : o("", !0)], 2)]), d(
|
|
4378
|
+
}, j(e.description), 1)) : o("", !0)], 2)]), d(ja, {
|
|
4085
4379
|
id: f,
|
|
4086
4380
|
status: e.errorText ? "error" : void 0,
|
|
4087
4381
|
text: e.errorText
|
|
4088
4382
|
}, null, 8, ["status", "text"])], 2));
|
|
4089
4383
|
}
|
|
4090
|
-
}),
|
|
4384
|
+
}), Xo = { class: "flex flex-col gap-0.5" }, Zo = { class: "flex items-center gap-1" }, Qo = ["hidden"], $o = ["onClick"], es = ["for"], ts = ["id"], ns = /* @__PURE__ */ f({
|
|
4091
4385
|
__name: "RadioGroup",
|
|
4092
4386
|
props: /*@__PURE__*/ g({
|
|
4093
4387
|
label: {},
|
|
@@ -4122,10 +4416,10 @@ var Fa = [
|
|
|
4122
4416
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
4123
4417
|
];
|
|
4124
4418
|
return (i, v) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", e.disabled && "opacity-40", r.class)) }, [
|
|
4125
|
-
c("div",
|
|
4419
|
+
c("div", Xo, [c("div", Zo, [c("span", {
|
|
4126
4420
|
id: f,
|
|
4127
4421
|
class: "text-sm"
|
|
4128
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4422
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4129
4423
|
key: 0,
|
|
4130
4424
|
text: e.helper,
|
|
4131
4425
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -4134,8 +4428,8 @@ var Fa = [
|
|
|
4134
4428
|
id: p,
|
|
4135
4429
|
hidden: e.helperPlacement === "icon",
|
|
4136
4430
|
class: "text-xs text-black/65"
|
|
4137
|
-
}, j(e.helper), 9,
|
|
4138
|
-
d(M(
|
|
4431
|
+
}, j(e.helper), 9, Qo)) : o("", !0)]),
|
|
4432
|
+
d(M(qt), {
|
|
4139
4433
|
modelValue: l.value,
|
|
4140
4434
|
"onUpdate:modelValue": v[0] ||= (e) => l.value = e,
|
|
4141
4435
|
name: e.name,
|
|
@@ -4149,14 +4443,14 @@ var Fa = [
|
|
|
4149
4443
|
default: V(() => [(w(!0), s(n, null, D(e.options, (t, n) => (w(), s("div", {
|
|
4150
4444
|
key: String(t.value),
|
|
4151
4445
|
class: "flex items-start gap-2"
|
|
4152
|
-
}, [d(M(
|
|
4446
|
+
}, [d(M(Kt), {
|
|
4153
4447
|
id: `${M(u)}-${n}`,
|
|
4154
4448
|
value: t.value,
|
|
4155
4449
|
disabled: t.disabled,
|
|
4156
4450
|
"aria-describedby": t.description ? `${M(u)}-${n}-description` : void 0,
|
|
4157
4451
|
class: y(M(X)(_, e.errorText ? "border-red" : "border-black/55", t.disabled && !e.disabled && "opacity-40"))
|
|
4158
4452
|
}, {
|
|
4159
|
-
default: V(() => [d(M(
|
|
4453
|
+
default: V(() => [d(M(Gt), { class: "size-2 rounded-full bg-primary" })]),
|
|
4160
4454
|
_: 1
|
|
4161
4455
|
}, 8, [
|
|
4162
4456
|
"id",
|
|
@@ -4170,11 +4464,11 @@ var Fa = [
|
|
|
4170
4464
|
}, [c("label", {
|
|
4171
4465
|
for: `${M(u)}-${n}`,
|
|
4172
4466
|
class: y(M(X)("text-sm", e.disabled || t.disabled ? "cursor-not-allowed" : "cursor-pointer"))
|
|
4173
|
-
}, j(t.label), 11,
|
|
4467
|
+
}, j(t.label), 11, es), t.description ? (w(), s("p", {
|
|
4174
4468
|
key: 0,
|
|
4175
4469
|
id: `${M(u)}-${n}-description`,
|
|
4176
4470
|
class: "text-xs text-black/65"
|
|
4177
|
-
}, j(t.description), 9,
|
|
4471
|
+
}, j(t.description), 9, ts)) : o("", !0)], 10, $o)]))), 128))]),
|
|
4178
4472
|
_: 1
|
|
4179
4473
|
}, 8, [
|
|
4180
4474
|
"modelValue",
|
|
@@ -4184,14 +4478,14 @@ var Fa = [
|
|
|
4184
4478
|
"aria-describedby",
|
|
4185
4479
|
"aria-invalid"
|
|
4186
4480
|
]),
|
|
4187
|
-
d(
|
|
4481
|
+
d(ja, {
|
|
4188
4482
|
id: m,
|
|
4189
4483
|
status: e.errorText ? "error" : void 0,
|
|
4190
4484
|
text: e.errorText
|
|
4191
4485
|
}, null, 8, ["status", "text"])
|
|
4192
4486
|
], 2));
|
|
4193
4487
|
}
|
|
4194
|
-
}),
|
|
4488
|
+
}), rs = { class: "flex items-start gap-2" }, is = "size-4 rounded-full bg-white shadow-sm transition-transform data-[state=checked]:translate-x-4 motion-reduce:transition-none", as = /* @__PURE__ */ f({
|
|
4195
4489
|
__name: "Switch",
|
|
4196
4490
|
props: /*@__PURE__*/ g({
|
|
4197
4491
|
label: {},
|
|
@@ -4228,7 +4522,7 @@ var Fa = [
|
|
|
4228
4522
|
"disabled:cursor-not-allowed",
|
|
4229
4523
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
4230
4524
|
];
|
|
4231
|
-
return (r, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", e.disabled && "opacity-40", t.class)) }, [c("div",
|
|
4525
|
+
return (r, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", e.disabled && "opacity-40", t.class)) }, [c("div", rs, [d(M(sn), {
|
|
4232
4526
|
id: a,
|
|
4233
4527
|
modelValue: n.value,
|
|
4234
4528
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -4238,7 +4532,7 @@ var Fa = [
|
|
|
4238
4532
|
"aria-describedby": m.value,
|
|
4239
4533
|
class: y(g)
|
|
4240
4534
|
}, {
|
|
4241
|
-
default: V(() => [d(M(
|
|
4535
|
+
default: V(() => [d(M(cn), { class: y(is) })]),
|
|
4242
4536
|
_: 1
|
|
4243
4537
|
}, 8, [
|
|
4244
4538
|
"modelValue",
|
|
@@ -4256,19 +4550,19 @@ var Fa = [
|
|
|
4256
4550
|
key: 0,
|
|
4257
4551
|
id: l,
|
|
4258
4552
|
class: "text-xs text-black/65"
|
|
4259
|
-
}, j(e.description), 1)) : o("", !0)], 2)]), d(
|
|
4553
|
+
}, j(e.description), 1)) : o("", !0)], 2)]), d(ja, {
|
|
4260
4554
|
id: u,
|
|
4261
4555
|
status: f.value,
|
|
4262
4556
|
text: p.value
|
|
4263
4557
|
}, null, 8, ["status", "text"])], 2));
|
|
4264
4558
|
}
|
|
4265
|
-
}),
|
|
4559
|
+
}), os = [
|
|
4266
4560
|
"id",
|
|
4267
4561
|
"placeholder",
|
|
4268
4562
|
"disabled",
|
|
4269
4563
|
"aria-invalid",
|
|
4270
4564
|
"aria-describedby"
|
|
4271
|
-
],
|
|
4565
|
+
], ss = /* @__PURE__ */ f({
|
|
4272
4566
|
inheritAttrs: !1,
|
|
4273
4567
|
__name: "InputTextArea",
|
|
4274
4568
|
props: /*@__PURE__*/ g({
|
|
@@ -4296,7 +4590,7 @@ var Fa = [
|
|
|
4296
4590
|
emits: ["update:modelValue"],
|
|
4297
4591
|
setup(e, { expose: t }) {
|
|
4298
4592
|
let n = e, { t: r } = K(), o = F(e, "modelValue"), s = i(() => n.maxLength !== void 0 && o.value.length > n.maxLength ? r("ui.input.maxLength", { count: n.maxLength }) : void 0), l = i(() => n.status ?? (s.value ? "error" : void 0)), u = i(() => n.statusText ?? s.value), d = E();
|
|
4299
|
-
return t({ focus: () => d.value?.focus() }), (t, r) => (w(), a(
|
|
4593
|
+
return t({ focus: () => d.value?.focus() }), (t, r) => (w(), a(Ia, {
|
|
4300
4594
|
label: e.label,
|
|
4301
4595
|
helper: e.helper,
|
|
4302
4596
|
"helper-placement": e.helperPlacement,
|
|
@@ -4318,7 +4612,7 @@ var Fa = [
|
|
|
4318
4612
|
"aria-invalid": a,
|
|
4319
4613
|
"aria-describedby": i,
|
|
4320
4614
|
class: "field-sizing-content -my-0.5 max-h-80 min-h-24 min-w-0 flex-1 resize-none bg-transparent text-sm leading-5 outline-none placeholder:text-black/55 disabled:cursor-not-allowed pointer-coarse:text-base"
|
|
4321
|
-
}), null, 16,
|
|
4615
|
+
}), null, 16, os), [[R, o.value]])]),
|
|
4322
4616
|
_: 1
|
|
4323
4617
|
}, 8, [
|
|
4324
4618
|
"label",
|
|
@@ -4332,7 +4626,7 @@ var Fa = [
|
|
|
4332
4626
|
"class"
|
|
4333
4627
|
]));
|
|
4334
4628
|
}
|
|
4335
|
-
}),
|
|
4629
|
+
}), cs = { class: "flex items-center gap-1" }, ls = ["hidden"], us = ["aria-describedby", "aria-invalid"], ds = /* @__PURE__ */ f({
|
|
4336
4630
|
__name: "CheckboxGroup",
|
|
4337
4631
|
props: /*@__PURE__*/ g({
|
|
4338
4632
|
label: {},
|
|
@@ -4360,10 +4654,10 @@ var Fa = [
|
|
|
4360
4654
|
l.value = t ? [...l.value, e] : l.value.filter((t) => t !== e);
|
|
4361
4655
|
}
|
|
4362
4656
|
return (i, u) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", t.class)) }, [
|
|
4363
|
-
c("div", { class: y(M(X)("flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div",
|
|
4657
|
+
c("div", { class: y(M(X)("flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div", cs, [c("span", {
|
|
4364
4658
|
id: f,
|
|
4365
4659
|
class: "text-sm"
|
|
4366
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4660
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4367
4661
|
key: 0,
|
|
4368
4662
|
text: e.helper,
|
|
4369
4663
|
label: M(r)("ui.formField.about", { label: e.label })
|
|
@@ -4372,14 +4666,14 @@ var Fa = [
|
|
|
4372
4666
|
id: p,
|
|
4373
4667
|
hidden: e.helperPlacement === "icon",
|
|
4374
4668
|
class: "text-xs text-black/65"
|
|
4375
|
-
}, j(e.helper), 9,
|
|
4669
|
+
}, j(e.helper), 9, ls)) : o("", !0)], 2),
|
|
4376
4670
|
c("div", {
|
|
4377
4671
|
role: "group",
|
|
4378
4672
|
"aria-labelledby": f,
|
|
4379
4673
|
"aria-describedby": h.value,
|
|
4380
4674
|
"aria-invalid": e.errorText ? !0 : void 0,
|
|
4381
4675
|
class: "flex flex-col gap-3"
|
|
4382
|
-
}, [(w(!0), s(n, null, D(e.options, (t) => (w(), a(
|
|
4676
|
+
}, [(w(!0), s(n, null, D(e.options, (t) => (w(), a(Yo, {
|
|
4383
4677
|
key: String(t.value),
|
|
4384
4678
|
"model-value": l.value.includes(t.value),
|
|
4385
4679
|
label: t.label,
|
|
@@ -4392,15 +4686,15 @@ var Fa = [
|
|
|
4392
4686
|
"description",
|
|
4393
4687
|
"disabled",
|
|
4394
4688
|
"onUpdate:modelValue"
|
|
4395
|
-
]))), 128))], 8,
|
|
4396
|
-
d(
|
|
4689
|
+
]))), 128))], 8, us),
|
|
4690
|
+
d(ja, {
|
|
4397
4691
|
id: m,
|
|
4398
4692
|
status: e.errorText ? "error" : void 0,
|
|
4399
4693
|
text: e.errorText
|
|
4400
4694
|
}, null, 8, ["status", "text"])
|
|
4401
4695
|
], 2));
|
|
4402
4696
|
}
|
|
4403
|
-
}),
|
|
4697
|
+
}), fs = /* @__PURE__ */ f({
|
|
4404
4698
|
__name: "LanguageSwitcher",
|
|
4405
4699
|
props: {
|
|
4406
4700
|
label: {},
|
|
@@ -4430,7 +4724,7 @@ var Fa = [
|
|
|
4430
4724
|
label: s(e),
|
|
4431
4725
|
value: e
|
|
4432
4726
|
})));
|
|
4433
|
-
return (i, o) => (w(), a(
|
|
4727
|
+
return (i, o) => (w(), a(qo, {
|
|
4434
4728
|
modelValue: M(r),
|
|
4435
4729
|
"onUpdate:modelValue": o[0] ||= (e) => h(r) ? r.value = e : null,
|
|
4436
4730
|
label: e.label ?? M(n)("ui.languageSwitcher.label"),
|
|
@@ -4439,7 +4733,7 @@ var Fa = [
|
|
|
4439
4733
|
disabled: e.disabled,
|
|
4440
4734
|
class: y(t.class)
|
|
4441
4735
|
}, {
|
|
4442
|
-
leading: V(() => [d(M(
|
|
4736
|
+
leading: V(() => [d(M(De), { "aria-hidden": "true" })]),
|
|
4443
4737
|
_: 1
|
|
4444
4738
|
}, 8, [
|
|
4445
4739
|
"modelValue",
|
|
@@ -4450,7 +4744,7 @@ var Fa = [
|
|
|
4450
4744
|
"class"
|
|
4451
4745
|
]));
|
|
4452
4746
|
}
|
|
4453
|
-
}),
|
|
4747
|
+
}), ps = { class: "flex items-center gap-1" }, ms = ["hidden"], hs = { class: "flex min-w-0 flex-1 flex-col gap-0.5" }, gs = { class: "text-sm font-bold" }, _s = ["id"], vs = /* @__PURE__ */ f({
|
|
4454
4748
|
__name: "CardSelect",
|
|
4455
4749
|
props: /*@__PURE__*/ g({
|
|
4456
4750
|
label: {},
|
|
@@ -4493,10 +4787,10 @@ var Fa = [
|
|
|
4493
4787
|
"motion-reduce:transition-none"
|
|
4494
4788
|
];
|
|
4495
4789
|
return (i, v) => (w(), s("div", { class: y(M(X)("flex flex-col gap-2 text-black", e.disabled && "opacity-40", r.class)) }, [
|
|
4496
|
-
c("div", { class: y(M(X)("flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div",
|
|
4790
|
+
c("div", { class: y(M(X)("flex flex-col gap-0.5", e.hideLabel && "sr-only")) }, [c("div", ps, [c("span", {
|
|
4497
4791
|
id: f,
|
|
4498
4792
|
class: "text-sm"
|
|
4499
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4793
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4500
4794
|
key: 0,
|
|
4501
4795
|
text: e.helper,
|
|
4502
4796
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -4505,8 +4799,8 @@ var Fa = [
|
|
|
4505
4799
|
id: p,
|
|
4506
4800
|
hidden: e.helperPlacement === "icon",
|
|
4507
4801
|
class: "text-xs text-black/65"
|
|
4508
|
-
}, j(e.helper), 9,
|
|
4509
|
-
d(M(
|
|
4802
|
+
}, j(e.helper), 9, ms)) : o("", !0)], 2),
|
|
4803
|
+
d(M(qt), {
|
|
4510
4804
|
modelValue: l.value,
|
|
4511
4805
|
"onUpdate:modelValue": v[0] ||= (e) => l.value = e,
|
|
4512
4806
|
name: e.name,
|
|
@@ -4517,7 +4811,7 @@ var Fa = [
|
|
|
4517
4811
|
"aria-invalid": e.errorText ? !0 : void 0,
|
|
4518
4812
|
class: y(M(X)("grid gap-2", g.value))
|
|
4519
4813
|
}, {
|
|
4520
|
-
default: V(() => [(w(!0), s(n, null, D(e.options, (t, n) => (w(), a(M(
|
|
4814
|
+
default: V(() => [(w(!0), s(n, null, D(e.options, (t, n) => (w(), a(M(Kt), {
|
|
4521
4815
|
id: `${M(u)}-${n}`,
|
|
4522
4816
|
key: String(t.value),
|
|
4523
4817
|
value: t.value,
|
|
@@ -4531,11 +4825,11 @@ var Fa = [
|
|
|
4531
4825
|
"aria-hidden": "true",
|
|
4532
4826
|
class: "mt-0.5 size-4 shrink-0 text-black/65 group-data-[state=checked]:text-primary"
|
|
4533
4827
|
})) : o("", !0),
|
|
4534
|
-
c("span",
|
|
4828
|
+
c("span", hs, [c("span", gs, j(t.title), 1), t.description ? (w(), s("span", {
|
|
4535
4829
|
key: 0,
|
|
4536
4830
|
id: `${M(u)}-${n}-description`,
|
|
4537
4831
|
class: "text-xs text-black/65"
|
|
4538
|
-
}, j(t.description), 9,
|
|
4832
|
+
}, j(t.description), 9, _s)) : o("", !0)]),
|
|
4539
4833
|
v[1] ||= c("span", {
|
|
4540
4834
|
"aria-hidden": "true",
|
|
4541
4835
|
class: "mt-0.5 flex size-4 shrink-0 items-center justify-center rounded-full border border-black/55 bg-white group-data-[state=checked]:border-primary"
|
|
@@ -4559,14 +4853,14 @@ var Fa = [
|
|
|
4559
4853
|
"aria-invalid",
|
|
4560
4854
|
"class"
|
|
4561
4855
|
]),
|
|
4562
|
-
d(
|
|
4856
|
+
d(ja, {
|
|
4563
4857
|
id: m,
|
|
4564
4858
|
status: e.errorText ? "error" : void 0,
|
|
4565
4859
|
text: e.errorText
|
|
4566
4860
|
}, null, 8, ["status", "text"])
|
|
4567
4861
|
], 2));
|
|
4568
4862
|
}
|
|
4569
|
-
}),
|
|
4863
|
+
}), ys = /* @__PURE__ */ f({
|
|
4570
4864
|
__name: "EmptyState",
|
|
4571
4865
|
props: {
|
|
4572
4866
|
title: {},
|
|
@@ -4622,15 +4916,15 @@ var Fa = [
|
|
|
4622
4916
|
}, [O(r.$slots, "actions")], 2)) : o("", !0)
|
|
4623
4917
|
], 2));
|
|
4624
4918
|
}
|
|
4625
|
-
}),
|
|
4919
|
+
}), bs = new Intl.Collator("en-GB", {
|
|
4626
4920
|
numeric: !0,
|
|
4627
4921
|
sensitivity: "base"
|
|
4628
4922
|
});
|
|
4629
|
-
function
|
|
4923
|
+
function xs(e, t) {
|
|
4630
4924
|
let n = e == null || e === "", r = t == null || t === "";
|
|
4631
|
-
return n || r ? n === r ? 0 : n ? 1 : -1 : typeof e == "number" && typeof t == "number" ? e - t : e instanceof Date && t instanceof Date ? e.getTime() - t.getTime() : typeof e == "boolean" && typeof t == "boolean" ? Number(e) - Number(t) :
|
|
4925
|
+
return n || r ? n === r ? 0 : n ? 1 : -1 : typeof e == "number" && typeof t == "number" ? e - t : e instanceof Date && t instanceof Date ? e.getTime() - t.getTime() : typeof e == "boolean" && typeof t == "boolean" ? Number(e) - Number(t) : bs.compare(String(e), String(t));
|
|
4632
4926
|
}
|
|
4633
|
-
function
|
|
4927
|
+
function Ss(e, t, n) {
|
|
4634
4928
|
let r = n && t.find((e) => e.key === n.key);
|
|
4635
4929
|
if (!n || !r) return [...e];
|
|
4636
4930
|
let i = r.sortValue ?? ((e) => e[r.key]), a = n.direction === "asc" ? 1 : -1;
|
|
@@ -4640,10 +4934,10 @@ function Bo(e, t, n) {
|
|
|
4640
4934
|
value: i(e)
|
|
4641
4935
|
})).sort((e, t) => {
|
|
4642
4936
|
let n = e.value === null || e.value === void 0 || e.value === "", r = t.value === null || t.value === void 0 || t.value === "";
|
|
4643
|
-
return (n || r ?
|
|
4937
|
+
return (n || r ? xs(e.value, t.value) : a * xs(e.value, t.value)) || e.index - t.index;
|
|
4644
4938
|
}).map((e) => e.row);
|
|
4645
4939
|
}
|
|
4646
|
-
function
|
|
4940
|
+
function Cs(e, t) {
|
|
4647
4941
|
return e?.key === t ? e.direction === "asc" ? {
|
|
4648
4942
|
key: t,
|
|
4649
4943
|
direction: "desc"
|
|
@@ -4653,24 +4947,24 @@ function Vo(e, t) {
|
|
|
4653
4947
|
};
|
|
4654
4948
|
}
|
|
4655
4949
|
// src/components/Table/Table.vue?vue&type=script&setup=true&lang.ts
|
|
4656
|
-
var
|
|
4950
|
+
var ws = [
|
|
4657
4951
|
"tabindex",
|
|
4658
4952
|
"role",
|
|
4659
4953
|
"aria-labelledby",
|
|
4660
4954
|
"aria-label"
|
|
4661
|
-
],
|
|
4955
|
+
], Ts = ["aria-busy"], Es = {
|
|
4662
4956
|
key: 1,
|
|
4663
4957
|
class: "sr-only"
|
|
4664
|
-
},
|
|
4958
|
+
}, Ds = ["aria-sort"], Os = {
|
|
4665
4959
|
key: 0,
|
|
4666
4960
|
class: "sr-only"
|
|
4667
|
-
},
|
|
4961
|
+
}, ks = ["onClick"], As = { key: 0 }, js = ["colspan"], Ms = {
|
|
4668
4962
|
key: 0,
|
|
4669
4963
|
class: "inline-flex items-center gap-2"
|
|
4670
|
-
},
|
|
4964
|
+
}, Ns = ["onClick"], Ps = {
|
|
4671
4965
|
key: 1,
|
|
4672
4966
|
"aria-hidden": "true"
|
|
4673
|
-
},
|
|
4967
|
+
}, Fs = ["colspan"], Is = "relative z-1 w-0 cursor-pointer", Ls = "absolute inset-0 outline-none", Rs = "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0", zs = "outline-2 -outline-offset-2 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0", Bs = /* @__PURE__ */ f({
|
|
4674
4968
|
__name: "Table",
|
|
4675
4969
|
props: /*@__PURE__*/ g({
|
|
4676
4970
|
columns: {},
|
|
@@ -4720,7 +5014,7 @@ var Ho = [
|
|
|
4720
5014
|
function T(e, t) {
|
|
4721
5015
|
e.target.closest("button, label, .sr-only") || t();
|
|
4722
5016
|
}
|
|
4723
|
-
let A = i(() => r.columns.length + +!!r.selectable), N = i(() => r.manualSort ? r.rows :
|
|
5017
|
+
let A = i(() => r.columns.length + +!!r.selectable), N = i(() => r.manualSort ? r.rows : Ss(r.rows, r.columns, l.value));
|
|
4724
5018
|
function I(e, t) {
|
|
4725
5019
|
return typeof r.rowKey == "function" ? r.rowKey(e, t) : r.rowKey ? e[r.rowKey] : t;
|
|
4726
5020
|
}
|
|
@@ -4748,16 +5042,16 @@ var Ho = [
|
|
|
4748
5042
|
return X(e.align === "end" && "text-right", e.nowrap !== !1 && "whitespace-nowrap", e.class);
|
|
4749
5043
|
}
|
|
4750
5044
|
let W = E(), G = E(!1), q;
|
|
4751
|
-
function
|
|
5045
|
+
function te() {
|
|
4752
5046
|
let e = W.value;
|
|
4753
5047
|
e && (G.value = e.scrollWidth > e.clientWidth + 1 || e.scrollHeight > e.clientHeight + 1);
|
|
4754
5048
|
}
|
|
4755
5049
|
return C(() => {
|
|
4756
|
-
|
|
5050
|
+
te(), q = new ResizeObserver(te), W.value && (q.observe(W.value), W.value.firstElementChild && q.observe(W.value.firstElementChild));
|
|
4757
5051
|
}), S(() => q?.disconnect()), (i, f) => (w(), s("div", {
|
|
4758
5052
|
ref_key: "scroller",
|
|
4759
5053
|
ref: W,
|
|
4760
|
-
class: y(M(X)("relative overflow-auto", G.value &&
|
|
5054
|
+
class: y(M(X)("relative overflow-auto", G.value && zs, r.class)),
|
|
4761
5055
|
tabindex: G.value ? 0 : void 0,
|
|
4762
5056
|
role: G.value ? "region" : void 0,
|
|
4763
5057
|
"aria-labelledby": G.value && (e.caption || i.$slots.caption) ? p : void 0,
|
|
@@ -4774,54 +5068,54 @@ var Ho = [
|
|
|
4774
5068
|
c("thead", { class: y(M(X)(e.stickyHeader && "sticky top-0 z-10 bg-white", e.ui?.header)) }, [c("tr", null, [e.selectable ? (w(), s("th", {
|
|
4775
5069
|
key: 0,
|
|
4776
5070
|
scope: "col",
|
|
4777
|
-
class: y(M(X)("border-b border-black/15", U.value, h.value.length &&
|
|
5071
|
+
class: y(M(X)("border-b border-black/15", U.value, h.value.length && Is)),
|
|
4778
5072
|
onClick: f[1] ||= (e) => T(e, () => h.value.length && x(b.value !== !0))
|
|
4779
|
-
}, [h.value.length ? (w(), a(
|
|
5073
|
+
}, [h.value.length ? (w(), a(Yo, {
|
|
4780
5074
|
key: 0,
|
|
4781
5075
|
"model-value": b.value,
|
|
4782
5076
|
label: M(t)("ui.table.selectAll"),
|
|
4783
5077
|
"hide-label": "",
|
|
4784
5078
|
"onUpdate:modelValue": f[0] ||= (e) => x(e === !0)
|
|
4785
|
-
}, null, 8, ["model-value", "label"])) : (w(), s("span",
|
|
5079
|
+
}, null, 8, ["model-value", "label"])) : (w(), s("span", Es, j(M(t)("ui.table.select")), 1))], 2)) : o("", !0), (w(!0), s(n, null, D(e.columns, (e) => (w(), s("th", {
|
|
4786
5080
|
key: e.key,
|
|
4787
5081
|
scope: "col",
|
|
4788
5082
|
"aria-sort": L(e),
|
|
4789
5083
|
class: y(M(X)("border-b border-black/15 font-bold text-black/65", U.value, ee(e)))
|
|
4790
|
-
}, [O(i.$slots, `header-${e.key}`, { column: e }, () => [e.hideLabel ? (w(), s("span",
|
|
5084
|
+
}, [O(i.$slots, `header-${e.key}`, { column: e }, () => [e.hideLabel ? (w(), s("span", Os, j(e.label), 1)) : e.sortable ? (w(), s("button", {
|
|
4791
5085
|
key: 1,
|
|
4792
5086
|
type: "button",
|
|
4793
|
-
class: y(M(X)("-mx-1 inline-flex cursor-pointer items-center gap-1 rounded px-1 font-bold hover:text-black", e.align === "end" && "flex-row-reverse", l.value?.key === e.key && "text-black",
|
|
4794
|
-
onClick: (t) => l.value = M(
|
|
4795
|
-
}, [u(j(e.label) + " ", 1), l.value?.key === e.key && l.value.direction === "asc" ? (w(), a(M(
|
|
5087
|
+
class: y(M(X)("-mx-1 inline-flex cursor-pointer items-center gap-1 rounded px-1 font-bold hover:text-black", e.align === "end" && "flex-row-reverse", l.value?.key === e.key && "text-black", Rs)),
|
|
5088
|
+
onClick: (t) => l.value = M(Cs)(l.value, e.key)
|
|
5089
|
+
}, [u(j(e.label) + " ", 1), l.value?.key === e.key && l.value.direction === "asc" ? (w(), a(M(ie), {
|
|
4796
5090
|
key: 0,
|
|
4797
5091
|
class: "size-4 shrink-0",
|
|
4798
5092
|
"aria-hidden": "true"
|
|
4799
|
-
})) : l.value?.key === e.key ? (w(), a(M(
|
|
5093
|
+
})) : l.value?.key === e.key ? (w(), a(M(J), {
|
|
4800
5094
|
key: 1,
|
|
4801
5095
|
class: "size-4 shrink-0",
|
|
4802
5096
|
"aria-hidden": "true"
|
|
4803
|
-
})) : (w(), a(M(
|
|
5097
|
+
})) : (w(), a(M(he), {
|
|
4804
5098
|
key: 2,
|
|
4805
5099
|
class: "size-4 shrink-0 text-black/40",
|
|
4806
5100
|
"aria-hidden": "true"
|
|
4807
|
-
}))], 10,
|
|
5101
|
+
}))], 10, ks)) : (w(), s(n, { key: 2 }, [u(j(e.label), 1)], 64))])], 10, Ds))), 128))])], 2),
|
|
4808
5102
|
c("tbody", { class: y(M(X)(e.loading && N.value.length && "opacity-50 transition-opacity")) }, [
|
|
4809
|
-
N.value.length ? o("", !0) : (w(), s("tr",
|
|
5103
|
+
N.value.length ? o("", !0) : (w(), s("tr", As, [c("td", {
|
|
4810
5104
|
colspan: A.value,
|
|
4811
5105
|
class: "px-4 py-8 text-center text-black/65"
|
|
4812
|
-
}, [e.loading ? (w(), s("span",
|
|
5106
|
+
}, [e.loading ? (w(), s("span", Ms, [d(Gn, { size: "sm" }), f[2] ||= u(" Loading… ", -1)])) : O(i.$slots, "empty", {}, () => [d(ys, {
|
|
4813
5107
|
size: "sm",
|
|
4814
5108
|
description: e.emptyText ?? M(t)("ui.table.empty"),
|
|
4815
5109
|
class: "p-0"
|
|
4816
|
-
}, null, 8, ["description"])], void 0, 1)], 8,
|
|
5110
|
+
}, null, 8, ["description"])], void 0, 1)], 8, js)])),
|
|
4817
5111
|
(w(!0), s(n, null, D(N.value, (r, c) => (w(), s("tr", {
|
|
4818
5112
|
key: I(r, c),
|
|
4819
5113
|
class: y(M(X)("group/row", z(r, c) && H, e.ui?.row))
|
|
4820
5114
|
}, [e.selectable ? (w(), s("td", {
|
|
4821
5115
|
key: 0,
|
|
4822
|
-
class: y(M(X)("border-b border-black/15 align-middle", !e.inset && "group-last/row:border-b-0", U.value, m(r) &&
|
|
5116
|
+
class: y(M(X)("border-b border-black/15 align-middle", !e.inset && "group-last/row:border-b-0", U.value, m(r) && Is)),
|
|
4823
5117
|
onClick: (e) => m(r) && T(e, () => v(r, c, !g(r, c)))
|
|
4824
|
-
}, [m(r) ? (w(), a(
|
|
5118
|
+
}, [m(r) ? (w(), a(Yo, {
|
|
4825
5119
|
key: 0,
|
|
4826
5120
|
"model-value": g(r, c),
|
|
4827
5121
|
label: e.rowLabel ? e.rowLabel(r, c) : M(t)("ui.table.selectRow", { n: c + 1 }),
|
|
@@ -4831,7 +5125,7 @@ var Ho = [
|
|
|
4831
5125
|
"model-value",
|
|
4832
5126
|
"label",
|
|
4833
5127
|
"onUpdate:modelValue"
|
|
4834
|
-
])) : o("", !0)], 10,
|
|
5128
|
+
])) : o("", !0)], 10, Ns)) : o("", !0), (w(!0), s(n, null, D(e.columns, (t) => (w(), a(k(t.rowHeader ? "th" : "td"), {
|
|
4835
5129
|
key: t.key,
|
|
4836
5130
|
scope: t.rowHeader ? "row" : void 0,
|
|
4837
5131
|
class: y(M(X)("border-b border-black/15 align-middle", !e.inset && "group-last/row:border-b-0", t.rowHeader ? "font-bold" : "font-normal", t.align === "end" && "tabular-nums", U.value, z(r, c) && "relative", ee(t)))
|
|
@@ -4843,7 +5137,7 @@ var Ho = [
|
|
|
4843
5137
|
"data-row-overlay": "",
|
|
4844
5138
|
tabindex: "-1",
|
|
4845
5139
|
"aria-hidden": "true",
|
|
4846
|
-
class:
|
|
5140
|
+
class: Ls
|
|
4847
5141
|
}), null, 16)) : o("", !0), t.key === R.value && z(r, c) ? (w(), a(k(e.linkComponent), _({
|
|
4848
5142
|
key: 1,
|
|
4849
5143
|
ref_for: !0
|
|
@@ -4864,33 +5158,33 @@ var Ho = [
|
|
|
4864
5158
|
}, () => [u(j(r[t.key] ?? ""), 1)], void 0, 2)]),
|
|
4865
5159
|
_: 2
|
|
4866
5160
|
}, 1032, ["scope", "class"]))), 128))], 2))), 128)),
|
|
4867
|
-
e.inset && N.value.length && !i.$slots.footer ? (w(), s("tr",
|
|
5161
|
+
e.inset && N.value.length && !i.$slots.footer ? (w(), s("tr", Ps, [c("td", {
|
|
4868
5162
|
colspan: A.value,
|
|
4869
5163
|
class: "h-2 p-0 sm:h-4"
|
|
4870
|
-
}, null, 8,
|
|
5164
|
+
}, null, 8, Fs)])) : o("", !0)
|
|
4871
5165
|
], 2),
|
|
4872
5166
|
i.$slots.footer ? (w(), s("tfoot", {
|
|
4873
5167
|
key: 1,
|
|
4874
5168
|
class: y(M(X)("font-bold *:*:border-t *:*:border-black/15", e.size === "sm" ? "*:*:px-4 *:*:py-2" : "*:*:px-4 *:*:py-3", e.inset && "*:*:sm:first:pl-6 *:*:sm:last:pr-6"))
|
|
4875
5169
|
}, [O(i.$slots, "footer")], 2)) : o("", !0)
|
|
4876
|
-
], 10,
|
|
5170
|
+
], 10, Ts)], 10, ws));
|
|
4877
5171
|
}
|
|
4878
|
-
}),
|
|
5172
|
+
}), Vs = { class: "flex flex-wrap items-baseline gap-x-2 gap-y-1" }, Hs = { class: "text-2xl font-bold tabular-nums" }, Us = {
|
|
4879
5173
|
key: 1,
|
|
4880
5174
|
class: "sr-only"
|
|
4881
|
-
},
|
|
5175
|
+
}, Ws = {
|
|
4882
5176
|
key: 2,
|
|
4883
5177
|
class: "font-bold tabular-nums"
|
|
4884
|
-
},
|
|
5178
|
+
}, Gs = {
|
|
4885
5179
|
key: 3,
|
|
4886
5180
|
class: "text-black/65"
|
|
4887
|
-
},
|
|
5181
|
+
}, Ks = {
|
|
4888
5182
|
key: 1,
|
|
4889
5183
|
class: "text-sm text-black/65"
|
|
4890
|
-
},
|
|
5184
|
+
}, qs = {
|
|
4891
5185
|
key: 2,
|
|
4892
5186
|
class: "mt-2 text-sm"
|
|
4893
|
-
},
|
|
5187
|
+
}, Js = /* @__PURE__ */ f({
|
|
4894
5188
|
__name: "StatTile",
|
|
4895
5189
|
props: {
|
|
4896
5190
|
label: {},
|
|
@@ -4920,23 +5214,23 @@ var Ho = [
|
|
|
4920
5214
|
positive: "text-green",
|
|
4921
5215
|
negative: "text-red",
|
|
4922
5216
|
neutral: "text-black/65"
|
|
4923
|
-
}, p = i(() => n.trend === "up" ?
|
|
5217
|
+
}, p = i(() => n.trend === "up" ? ae : n.trend === "down" ? te : n.trend === "flat" ? re : void 0), m = i(() => ({
|
|
4924
5218
|
up: t("ui.statTile.up"),
|
|
4925
5219
|
down: t("ui.statTile.down"),
|
|
4926
5220
|
flat: t("ui.statTile.flat")
|
|
4927
5221
|
}));
|
|
4928
|
-
return (t, i) => (w(), a(M(
|
|
5222
|
+
return (t, i) => (w(), a(M(Ht), {
|
|
4929
5223
|
as: r.value ? e.as ?? "a" : "template",
|
|
4930
5224
|
href: r.value ? e.href : void 0,
|
|
4931
5225
|
class: y(r.value && "group block h-full cursor-pointer rounded-lg outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus")
|
|
4932
5226
|
}, {
|
|
4933
|
-
default: V(() => [d(
|
|
5227
|
+
default: V(() => [d(pa, {
|
|
4934
5228
|
padding: "sm",
|
|
4935
5229
|
class: y(M(X)(r.value && "relative h-full transition-[border-color,box-shadow,background-color] duration-150 motion-reduce:transition-none group-hover:border-black/40 group-hover:shadow-md group-active:bg-black/1", n.class)),
|
|
4936
5230
|
ui: { body: "gap-1" }
|
|
4937
5231
|
}, {
|
|
4938
5232
|
default: V(() => [
|
|
4939
|
-
r.value ? (w(), a(M(
|
|
5233
|
+
r.value ? (w(), a(M(ae), {
|
|
4940
5234
|
key: 0,
|
|
4941
5235
|
class: "absolute end-4 top-4 size-4 text-black/65",
|
|
4942
5236
|
"aria-hidden": "true"
|
|
@@ -4946,7 +5240,7 @@ var Ho = [
|
|
|
4946
5240
|
class: "size-4 shrink-0",
|
|
4947
5241
|
"aria-hidden": "true"
|
|
4948
5242
|
})) : o("", !0), u(" " + j(e.label), 1)], 2),
|
|
4949
|
-
c("div",
|
|
5243
|
+
c("div", Vs, [c("p", Hs, [O(t.$slots, "value", {}, () => [u(j(e.value ?? "—"), 1)])]), e.change || e.trend ? (w(), s("p", {
|
|
4950
5244
|
key: 0,
|
|
4951
5245
|
class: y(M(X)("inline-flex items-center gap-0.5 text-sm", f[l.value]))
|
|
4952
5246
|
}, [
|
|
@@ -4955,12 +5249,12 @@ var Ho = [
|
|
|
4955
5249
|
class: "size-4 shrink-0",
|
|
4956
5250
|
"aria-hidden": "true"
|
|
4957
5251
|
})) : o("", !0),
|
|
4958
|
-
e.trend ? (w(), s("span",
|
|
4959
|
-
e.change ? (w(), s("span",
|
|
4960
|
-
e.changeLabel ? (w(), s("span",
|
|
5252
|
+
e.trend ? (w(), s("span", Us, j(m.value[e.trend]), 1)) : o("", !0),
|
|
5253
|
+
e.change ? (w(), s("span", Ws, j(e.change), 1)) : o("", !0),
|
|
5254
|
+
e.changeLabel ? (w(), s("span", Gs, "\xA0" + j(e.changeLabel), 1)) : o("", !0)
|
|
4961
5255
|
], 2)) : o("", !0)]),
|
|
4962
|
-
e.description || t.$slots.description ? (w(), s("p",
|
|
4963
|
-
t.$slots.footer && !r.value ? (w(), s("div",
|
|
5256
|
+
e.description || t.$slots.description ? (w(), s("p", Ks, [O(t.$slots, "description", {}, () => [u(j(e.description), 1)])])) : o("", !0),
|
|
5257
|
+
t.$slots.footer && !r.value ? (w(), s("div", qs, [O(t.$slots, "footer")])) : o("", !0)
|
|
4964
5258
|
]),
|
|
4965
5259
|
_: 3
|
|
4966
5260
|
}, 8, ["class"])]),
|
|
@@ -4971,19 +5265,19 @@ var Ho = [
|
|
|
4971
5265
|
"class"
|
|
4972
5266
|
]));
|
|
4973
5267
|
}
|
|
4974
|
-
}),
|
|
5268
|
+
}), Ys = { class: "col-span-2 text-black/65 @sm:col-span-1" }, Xs = { class: "sr-only" }, Zs = {
|
|
4975
5269
|
key: 0,
|
|
4976
5270
|
class: "mt-0.5 block text-black/65"
|
|
4977
|
-
},
|
|
5271
|
+
}, Qs = {
|
|
4978
5272
|
key: 0,
|
|
4979
5273
|
class: "justify-self-end"
|
|
4980
|
-
},
|
|
5274
|
+
}, $s = { class: "text-black/65" }, ec = { class: "sr-only" }, tc = {
|
|
4981
5275
|
key: 0,
|
|
4982
5276
|
class: "mt-0.5 block font-normal text-black/65"
|
|
4983
|
-
},
|
|
5277
|
+
}, nc = {
|
|
4984
5278
|
key: 1,
|
|
4985
5279
|
class: "mt-1 block font-normal"
|
|
4986
|
-
},
|
|
5280
|
+
}, rc = /* @__PURE__ */ f({
|
|
4987
5281
|
__name: "SummaryList",
|
|
4988
5282
|
props: {
|
|
4989
5283
|
items: {},
|
|
@@ -5008,37 +5302,37 @@ var Ho = [
|
|
|
5008
5302
|
key: r.label,
|
|
5009
5303
|
class: y(M(X)("grid grid-cols-[1fr_auto] gap-x-4 gap-y-1 border-b border-black/15 py-3 first:pt-0 last:border-b-0 last:pb-0", a[e.labelWidth]))
|
|
5010
5304
|
}, [
|
|
5011
|
-
c("dt",
|
|
5305
|
+
c("dt", Ys, j(r.label), 1),
|
|
5012
5306
|
c("dd", { class: y(M(X)("min-w-0 break-words", r.emphasis && "font-bold", !l.$slots.action && "col-span-2")) }, [O(l.$slots, "value", {
|
|
5013
5307
|
item: r,
|
|
5014
5308
|
index: f
|
|
5015
5309
|
}, () => [i(r.value) ? (w(), s(n, { key: 1 }, [d[0] ||= c("span", {
|
|
5016
5310
|
class: "text-black/40",
|
|
5017
5311
|
"aria-hidden": "true"
|
|
5018
|
-
}, "—", -1), c("span",
|
|
5019
|
-
l.$slots.action ? (w(), s("dd",
|
|
5312
|
+
}, "—", -1), c("span", Xs, j(e.emptyLabel ?? M(t)("ui.summaryList.notSet")), 1)], 64)) : (w(), s(n, { key: 0 }, [u(j(r.value), 1)], 64))]), r.description ? (w(), s("span", Zs, j(r.description), 1)) : o("", !0)], 2),
|
|
5313
|
+
l.$slots.action ? (w(), s("dd", Qs, [O(l.$slots, "action", {
|
|
5020
5314
|
item: r,
|
|
5021
5315
|
index: f
|
|
5022
5316
|
})])) : o("", !0)
|
|
5023
5317
|
], 2))), 128)) : (w(!0), s(n, { key: 1 }, D(e.items, (r, a) => (w(), s("div", {
|
|
5024
5318
|
key: r.label,
|
|
5025
5319
|
class: y(e.layout === "compact" ? "col-span-2 grid grid-cols-subgrid items-baseline" : "flex min-w-0 flex-col gap-1")
|
|
5026
|
-
}, [c("dt",
|
|
5320
|
+
}, [c("dt", $s, j(r.label), 1), c("dd", { class: y(M(X)("min-w-0 break-words", e.layout === "compact" && "text-right font-bold tabular-nums", r.emphasis && "font-bold")) }, [
|
|
5027
5321
|
O(l.$slots, "value", {
|
|
5028
5322
|
item: r,
|
|
5029
5323
|
index: a
|
|
5030
5324
|
}, () => [i(r.value) ? (w(), s(n, { key: 1 }, [d[1] ||= c("span", {
|
|
5031
5325
|
class: "text-black/40",
|
|
5032
5326
|
"aria-hidden": "true"
|
|
5033
|
-
}, "—", -1), c("span",
|
|
5034
|
-
r.description ? (w(), s("span",
|
|
5035
|
-
l.$slots.action ? (w(), s("span",
|
|
5327
|
+
}, "—", -1), c("span", ec, j(e.emptyLabel ?? M(t)("ui.summaryList.notSet")), 1)], 64)) : (w(), s(n, { key: 0 }, [u(j(r.value), 1)], 64))]),
|
|
5328
|
+
r.description ? (w(), s("span", tc, j(r.description), 1)) : o("", !0),
|
|
5329
|
+
l.$slots.action ? (w(), s("span", nc, [O(l.$slots, "action", {
|
|
5036
5330
|
item: r,
|
|
5037
5331
|
index: a
|
|
5038
5332
|
})])) : o("", !0)
|
|
5039
5333
|
], 2)], 2))), 128))], 2)], 2));
|
|
5040
5334
|
}
|
|
5041
|
-
}),
|
|
5335
|
+
}), ic = { class: "flex h-5 shrink-0 items-center" }, ac = { class: "sr-only" }, oc = /* @__PURE__ */ f({
|
|
5042
5336
|
__name: "Checklist",
|
|
5043
5337
|
props: {
|
|
5044
5338
|
items: {},
|
|
@@ -5056,19 +5350,19 @@ var Ho = [
|
|
|
5056
5350
|
return (r, i) => (w(), s("ul", { class: y(M(X)("flex flex-col gap-2 text-sm", t.class)) }, [(w(!0), s(n, null, D(e.items, (t) => (w(), s("li", {
|
|
5057
5351
|
key: t.label,
|
|
5058
5352
|
class: "flex items-start gap-2"
|
|
5059
|
-
}, [c("span",
|
|
5353
|
+
}, [c("span", ic, [t.done ? (w(), a(M(ve), {
|
|
5060
5354
|
key: 0,
|
|
5061
5355
|
class: "size-4 text-green",
|
|
5062
5356
|
"aria-hidden": "true"
|
|
5063
|
-
})) : (w(), a(M(
|
|
5357
|
+
})) : (w(), a(M(ge), {
|
|
5064
5358
|
key: 1,
|
|
5065
5359
|
class: y(M(X)("size-4", e.invalid ? "text-red" : "text-black/40")),
|
|
5066
5360
|
"aria-hidden": "true"
|
|
5067
|
-
}, null, 8, ["class"]))]), c("span", { class: y(t.done ? "text-black" : "text-black/65") }, [u(j(t.label), 1), c("span",
|
|
5361
|
+
}, null, 8, ["class"]))]), c("span", { class: y(t.done ? "text-black" : "text-black/65") }, [u(j(t.label), 1), c("span", ac, j(t.done ? " (done)" : " (to do)"), 1)], 2)]))), 128))], 2));
|
|
5068
5362
|
}
|
|
5069
5363
|
});
|
|
5070
5364
|
// src/lib/dates.ts
|
|
5071
|
-
function
|
|
5365
|
+
function sc(e) {
|
|
5072
5366
|
if (e instanceof Date) return e;
|
|
5073
5367
|
if (typeof e == "string" && /^\d{4}-\d{2}-\d{2}$/.test(e)) {
|
|
5074
5368
|
let [t, n, r] = e.split("-").map(Number);
|
|
@@ -5076,59 +5370,59 @@ function Ts(e) {
|
|
|
5076
5370
|
}
|
|
5077
5371
|
return new Date(e);
|
|
5078
5372
|
}
|
|
5079
|
-
var
|
|
5373
|
+
var cc = [
|
|
5080
5374
|
["year", 31536e3],
|
|
5081
5375
|
["month", 2592e3],
|
|
5082
5376
|
["week", 604800],
|
|
5083
5377
|
["day", 86400],
|
|
5084
5378
|
["hour", 3600],
|
|
5085
5379
|
["minute", 60]
|
|
5086
|
-
],
|
|
5087
|
-
function
|
|
5088
|
-
let n = Math.round((
|
|
5380
|
+
], lc = new Intl.RelativeTimeFormat("en-GB", { numeric: "auto" });
|
|
5381
|
+
function uc(e, t = /* @__PURE__ */ new Date()) {
|
|
5382
|
+
let n = Math.round((sc(e).getTime() - t.getTime()) / 1e3);
|
|
5089
5383
|
if (Math.abs(n) < 60) return "Just now";
|
|
5090
|
-
for (let [e, t] of
|
|
5091
|
-
let r =
|
|
5384
|
+
for (let [e, t] of cc) if (Math.abs(n) >= t) {
|
|
5385
|
+
let r = lc.format(Math.trunc(n / t), e);
|
|
5092
5386
|
return r.charAt(0).toUpperCase() + r.slice(1);
|
|
5093
5387
|
}
|
|
5094
5388
|
return "Just now";
|
|
5095
5389
|
}
|
|
5096
|
-
function
|
|
5097
|
-
let t =
|
|
5390
|
+
function dc(e) {
|
|
5391
|
+
let t = sc(e), n = t.toLocaleDateString("en-GB", { weekday: "long" }), r = t.toLocaleTimeString("en-GB", {
|
|
5098
5392
|
hour: "2-digit",
|
|
5099
5393
|
minute: "2-digit"
|
|
5100
5394
|
});
|
|
5101
|
-
return `${n} ${
|
|
5395
|
+
return `${n} ${fc(t)} at ${r}`;
|
|
5102
5396
|
}
|
|
5103
|
-
function
|
|
5104
|
-
return
|
|
5397
|
+
function fc(e) {
|
|
5398
|
+
return sc(e).toLocaleDateString("en-GB", {
|
|
5105
5399
|
day: "numeric",
|
|
5106
5400
|
month: "long",
|
|
5107
5401
|
year: "numeric"
|
|
5108
5402
|
});
|
|
5109
5403
|
}
|
|
5110
|
-
function
|
|
5111
|
-
let n =
|
|
5404
|
+
function pc(e, t = /* @__PURE__ */ new Date()) {
|
|
5405
|
+
let n = sc(e), r = t.getFullYear() - n.getFullYear(), i = t.getMonth() - n.getMonth();
|
|
5112
5406
|
return (i < 0 || i === 0 && t.getDate() < n.getDate()) && r--, r;
|
|
5113
5407
|
}
|
|
5114
|
-
function
|
|
5115
|
-
let n =
|
|
5408
|
+
function mc(e, t = /* @__PURE__ */ new Date()) {
|
|
5409
|
+
let n = sc(e), r = new Date(t.getFullYear(), t.getMonth(), t.getDate()), i = (e) => {
|
|
5116
5410
|
let t = new Date(e, n.getMonth(), n.getDate());
|
|
5117
5411
|
return t.getMonth() === n.getMonth() ? t : new Date(e, 2, 1);
|
|
5118
5412
|
}, a = i(r.getFullYear());
|
|
5119
5413
|
return a < r && (a = i(r.getFullYear() + 1)), Math.round((a.getTime() - r.getTime()) / 864e5);
|
|
5120
5414
|
}
|
|
5121
5415
|
// src/lib/useNow.ts
|
|
5122
|
-
var
|
|
5123
|
-
function
|
|
5416
|
+
var hc = E(/* @__PURE__ */ new Date()), gc = 0, _c;
|
|
5417
|
+
function vc() {
|
|
5124
5418
|
return C(() => {
|
|
5125
|
-
|
|
5419
|
+
gc++ === 0 && (hc.value = /* @__PURE__ */ new Date(), _c = setInterval(() => hc.value = /* @__PURE__ */ new Date(), 3e4));
|
|
5126
5420
|
}), S(() => {
|
|
5127
|
-
--
|
|
5128
|
-
}),
|
|
5421
|
+
--gc === 0 && clearInterval(_c);
|
|
5422
|
+
}), hc;
|
|
5129
5423
|
}
|
|
5130
5424
|
// src/components/RelativeTime/RelativeTime.vue?vue&type=script&setup=true&lang.ts
|
|
5131
|
-
var
|
|
5425
|
+
var yc = ["datetime"], bc = /* @__PURE__ */ f({
|
|
5132
5426
|
__name: "RelativeTime",
|
|
5133
5427
|
props: {
|
|
5134
5428
|
date: {},
|
|
@@ -5143,17 +5437,17 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5143
5437
|
] }
|
|
5144
5438
|
},
|
|
5145
5439
|
setup(e) {
|
|
5146
|
-
let t = e, n =
|
|
5147
|
-
return (e, n) => (w(), a(
|
|
5440
|
+
let t = e, n = vc(), r = i(() => sc(t.date)), o = i(() => uc(r.value, t.now ?? n.value)), s = i(() => t.tooltip ? t.tooltip(r.value) : dc(r.value));
|
|
5441
|
+
return (e, n) => (w(), a(xo, { text: s.value }, {
|
|
5148
5442
|
default: V(() => [c("time", {
|
|
5149
5443
|
datetime: r.value.toISOString(),
|
|
5150
5444
|
tabindex: "0",
|
|
5151
5445
|
class: y(M(X)("cursor-default rounded-sm underline decoration-current/40 decoration-dotted underline-offset-2", "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0", t.class))
|
|
5152
|
-
}, j(o.value), 11,
|
|
5446
|
+
}, j(o.value), 11, yc)]),
|
|
5153
5447
|
_: 1
|
|
5154
5448
|
}, 8, ["text"]));
|
|
5155
5449
|
}
|
|
5156
|
-
}),
|
|
5450
|
+
}), xc = ["data-birth-date"], Sc = /* @__PURE__ */ f({
|
|
5157
5451
|
__name: "Age",
|
|
5158
5452
|
props: {
|
|
5159
5453
|
birthDate: {},
|
|
@@ -5168,73 +5462,26 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5168
5462
|
] }
|
|
5169
5463
|
},
|
|
5170
5464
|
setup(e) {
|
|
5171
|
-
let { t } = K(), r = e, l =
|
|
5172
|
-
let e =
|
|
5173
|
-
return `${t("ui.age.born", { date:
|
|
5465
|
+
let { t } = K(), r = e, l = vc(), d = i(() => sc(r.birthDate)), f = i(() => r.now ?? l.value), p = i(() => pc(d.value, f.value)), m = i(() => {
|
|
5466
|
+
let e = mc(d.value, f.value), n = e === 0 ? ` · ${t("ui.age.birthdayToday")}` : e === 1 ? ` · ${t("ui.age.birthdayTomorrow")}` : e <= 7 ? ` · ${t("ui.age.birthdayInDays", { days: e })}` : "";
|
|
5467
|
+
return `${t("ui.age.born", { date: fc(d.value) })}${n}`;
|
|
5174
5468
|
}), h = i(() => {
|
|
5175
5469
|
let e = d.value;
|
|
5176
5470
|
return `${e.getFullYear()}-${String(e.getMonth() + 1).padStart(2, "0")}-${String(e.getDate()).padStart(2, "0")}`;
|
|
5177
5471
|
});
|
|
5178
|
-
return (t, i) => (w(), a(
|
|
5472
|
+
return (t, i) => (w(), a(xo, { text: m.value }, {
|
|
5179
5473
|
default: V(() => [c("span", {
|
|
5180
5474
|
tabindex: "0",
|
|
5181
5475
|
"data-birth-date": h.value,
|
|
5182
5476
|
class: y(M(X)("cursor-default rounded-sm tabular-nums underline decoration-current/40 decoration-dotted underline-offset-2", "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0", r.class))
|
|
5183
|
-
}, [u(j(p.value), 1), e.suffix ? (w(), s(n, { key: 0 }, [u("\xA0" + j(e.suffix), 1)], 64)) : o("", !0)], 10,
|
|
5477
|
+
}, [u(j(p.value), 1), e.suffix ? (w(), s(n, { key: 0 }, [u("\xA0" + j(e.suffix), 1)], 64)) : o("", !0)], 10, xc)]),
|
|
5184
5478
|
_: 1
|
|
5185
5479
|
}, 8, ["text"]));
|
|
5186
5480
|
}
|
|
5187
|
-
}),
|
|
5188
|
-
__name: "Link",
|
|
5189
|
-
props: {
|
|
5190
|
-
href: {},
|
|
5191
|
-
newTab: { type: Boolean },
|
|
5192
|
-
icon: {
|
|
5193
|
-
type: Boolean,
|
|
5194
|
-
default: !0
|
|
5195
|
-
},
|
|
5196
|
-
as: { default: "a" },
|
|
5197
|
-
class: { type: [
|
|
5198
|
-
Boolean,
|
|
5199
|
-
null,
|
|
5200
|
-
String,
|
|
5201
|
-
Object,
|
|
5202
|
-
Array
|
|
5203
|
-
] }
|
|
5204
|
-
},
|
|
5205
|
-
setup(e) {
|
|
5206
|
-
let t = e, r = [
|
|
5207
|
-
"cursor-pointer rounded-xs underline underline-offset-2 transition-colors",
|
|
5208
|
-
"hover:text-black hover:decoration-2",
|
|
5209
|
-
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
5210
|
-
];
|
|
5211
|
-
return (i, l) => (w(), a(M(Ft), {
|
|
5212
|
-
as: e.as,
|
|
5213
|
-
href: e.href,
|
|
5214
|
-
type: e.as === "button" ? "button" : void 0,
|
|
5215
|
-
target: e.newTab ? "_blank" : void 0,
|
|
5216
|
-
rel: e.newTab ? "noopener noreferrer" : void 0,
|
|
5217
|
-
class: y(M(X)(r, t.class))
|
|
5218
|
-
}, {
|
|
5219
|
-
default: V(() => [O(i.$slots, "default"), e.newTab ? (w(), s(n, { key: 0 }, [e.icon ? (w(), a(M(be), {
|
|
5220
|
-
key: 0,
|
|
5221
|
-
class: "ms-0.5 inline size-[0.9em] align-[-0.1em]",
|
|
5222
|
-
"aria-hidden": "true"
|
|
5223
|
-
})) : o("", !0), l[0] ||= c("span", { class: "sr-only" }, " (opens in a new tab)", -1)], 64)) : o("", !0)]),
|
|
5224
|
-
_: 3
|
|
5225
|
-
}, 8, [
|
|
5226
|
-
"as",
|
|
5227
|
-
"href",
|
|
5228
|
-
"type",
|
|
5229
|
-
"target",
|
|
5230
|
-
"rel",
|
|
5231
|
-
"class"
|
|
5232
|
-
]));
|
|
5233
|
-
}
|
|
5234
|
-
}), Hs = {
|
|
5481
|
+
}), Cc = {
|
|
5235
5482
|
class: "text-sm text-black/65",
|
|
5236
5483
|
"aria-live": "polite"
|
|
5237
|
-
},
|
|
5484
|
+
}, wc = { class: "text-black" }, Tc = /* @__PURE__ */ f({
|
|
5238
5485
|
__name: "Steps",
|
|
5239
5486
|
props: {
|
|
5240
5487
|
steps: {},
|
|
@@ -5250,16 +5497,16 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5250
5497
|
},
|
|
5251
5498
|
setup(e) {
|
|
5252
5499
|
let t = e;
|
|
5253
|
-
return (n, r) => (w(), s("div", { class: y(M(X)("flex flex-col gap-3", t.class)) }, [c("p",
|
|
5500
|
+
return (n, r) => (w(), s("div", { class: y(M(X)("flex flex-col gap-3", t.class)) }, [c("p", Cc, [d(M(W), {
|
|
5254
5501
|
keypath: "ui.steps.stepOfNamed",
|
|
5255
5502
|
scope: "global",
|
|
5256
5503
|
tag: "span"
|
|
5257
5504
|
}, {
|
|
5258
5505
|
current: V(() => [u(j(e.step + 1), 1)]),
|
|
5259
5506
|
total: V(() => [u(j(e.steps.length), 1)]),
|
|
5260
|
-
name: V(() => [c("span",
|
|
5507
|
+
name: V(() => [c("span", wc, j(e.steps[e.step]), 1)]),
|
|
5261
5508
|
_: 1
|
|
5262
|
-
})]), d(
|
|
5509
|
+
})]), d(yi, {
|
|
5263
5510
|
label: e.label,
|
|
5264
5511
|
segments: "",
|
|
5265
5512
|
value: e.step + 1,
|
|
@@ -5270,7 +5517,7 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5270
5517
|
"max"
|
|
5271
5518
|
])], 2));
|
|
5272
5519
|
}
|
|
5273
|
-
}),
|
|
5520
|
+
}), Ec = /* @__PURE__ */ f({
|
|
5274
5521
|
__name: "Tabs",
|
|
5275
5522
|
props: /*@__PURE__*/ g({
|
|
5276
5523
|
tabs: {},
|
|
@@ -5296,16 +5543,16 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5296
5543
|
"focus-visible:rounded focus-visible:ring-2 focus-visible:ring-primary",
|
|
5297
5544
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
5298
5545
|
];
|
|
5299
|
-
return (l, f) => (w(), a(M(
|
|
5546
|
+
return (l, f) => (w(), a(M(fn), {
|
|
5300
5547
|
"model-value": r.value ?? e.tabs[0]?.value,
|
|
5301
5548
|
class: y(M(X)("flex flex-col gap-6", t.class)),
|
|
5302
5549
|
"onUpdate:modelValue": f[0] ||= (e) => r.value = String(e)
|
|
5303
5550
|
}, {
|
|
5304
|
-
default: V(() => [d(M(
|
|
5551
|
+
default: V(() => [d(M(dn), {
|
|
5305
5552
|
"aria-label": e.label,
|
|
5306
5553
|
class: "relative flex overflow-x-auto overflow-y-hidden border-b border-black/15"
|
|
5307
5554
|
}, {
|
|
5308
|
-
default: V(() => [(w(!0), s(n, null, D(e.tabs, (e) => (w(), a(M(
|
|
5555
|
+
default: V(() => [(w(!0), s(n, null, D(e.tabs, (e) => (w(), a(M(pn), {
|
|
5309
5556
|
key: e.value,
|
|
5310
5557
|
value: e.value,
|
|
5311
5558
|
disabled: e.disabled,
|
|
@@ -5316,12 +5563,12 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5316
5563
|
"aria-hidden": "true"
|
|
5317
5564
|
})) : o("", !0), u(" " + j(e.label), 1)]),
|
|
5318
5565
|
_: 2
|
|
5319
|
-
}, 1032, ["value", "disabled"]))), 128)), d(M(
|
|
5566
|
+
}, 1032, ["value", "disabled"]))), 128)), d(M(un), { class: "absolute bottom-0 left-0 h-0.5 w-(--reka-tabs-indicator-size) translate-x-(--reka-tabs-indicator-position) rounded-full transition-[width,translate] duration-200 motion-reduce:transition-none" }, {
|
|
5320
5567
|
default: V(() => [...f[1] ||= [c("span", { class: "block size-full rounded-full bg-primary" }, null, -1)]]),
|
|
5321
5568
|
_: 1
|
|
5322
5569
|
})]),
|
|
5323
5570
|
_: 1
|
|
5324
|
-
}, 8, ["aria-label"]), (w(!0), s(n, null, D(e.tabs, (e) => (w(), a(M(
|
|
5571
|
+
}, 8, ["aria-label"]), (w(!0), s(n, null, D(e.tabs, (e) => (w(), a(M(ln), {
|
|
5325
5572
|
key: e.value,
|
|
5326
5573
|
value: e.value,
|
|
5327
5574
|
class: "outline-none"
|
|
@@ -5332,11 +5579,11 @@ var Ls = ["datetime"], Rs = /* @__PURE__ */ f({
|
|
|
5332
5579
|
_: 3
|
|
5333
5580
|
}, 8, ["model-value", "class"]));
|
|
5334
5581
|
}
|
|
5335
|
-
}),
|
|
5336
|
-
function
|
|
5582
|
+
}), Dc = 0, Oc = () => `notification-${Date.now().toString(36)}-${(Dc++).toString(36)}`;
|
|
5583
|
+
function kc(e, t) {
|
|
5337
5584
|
return t === void 0 ? e.type === "error" ? Infinity : e.action ? e.compact ? 1e4 : Infinity : 6e3 : t;
|
|
5338
5585
|
}
|
|
5339
|
-
function
|
|
5586
|
+
function Ac(e = []) {
|
|
5340
5587
|
let t = T({
|
|
5341
5588
|
items: e.map(n).sort((e, t) => t.createdAt.getTime() - e.createdAt.getTime()),
|
|
5342
5589
|
toasts: [],
|
|
@@ -5346,7 +5593,7 @@ function Ys(e = []) {
|
|
|
5346
5593
|
function n(e) {
|
|
5347
5594
|
return {
|
|
5348
5595
|
...e,
|
|
5349
|
-
id: e.id ??
|
|
5596
|
+
id: e.id ?? Oc(),
|
|
5350
5597
|
type: e.type ?? "info",
|
|
5351
5598
|
createdAt: e.createdAt ?? /* @__PURE__ */ new Date(),
|
|
5352
5599
|
read: e.read ?? !1
|
|
@@ -5356,7 +5603,7 @@ function Ys(e = []) {
|
|
|
5356
5603
|
let i = n(e);
|
|
5357
5604
|
return t.items = [i, ...t.items.filter((e) => e.id !== i.id)], r.toast !== !1 && !t.paneOpen && (t.toasts = [...t.toasts.filter((e) => e.id !== i.id), {
|
|
5358
5605
|
id: i.id,
|
|
5359
|
-
duration:
|
|
5606
|
+
duration: kc(i, r.duration),
|
|
5360
5607
|
item: i
|
|
5361
5608
|
}]), i.id;
|
|
5362
5609
|
}
|
|
@@ -5405,25 +5652,25 @@ function Ys(e = []) {
|
|
|
5405
5652
|
markAllRead: c
|
|
5406
5653
|
};
|
|
5407
5654
|
}
|
|
5408
|
-
var
|
|
5409
|
-
function
|
|
5410
|
-
return
|
|
5655
|
+
var jc;
|
|
5656
|
+
function Mc() {
|
|
5657
|
+
return jc ??= Ac();
|
|
5411
5658
|
}
|
|
5412
5659
|
// src/components/Notification/Notification.vue?vue&type=script&setup=true&lang.ts
|
|
5413
|
-
var
|
|
5660
|
+
var Nc = { class: "sr-only" }, Pc = {
|
|
5414
5661
|
key: 0,
|
|
5415
5662
|
class: "text-black/65 [&_a]:font-bold [&_a]:text-primary [&_a]:underline [&_b]:font-bold [&_b]:text-black [&_strong]:font-bold [&_strong]:text-black"
|
|
5416
|
-
},
|
|
5663
|
+
}, Fc = {
|
|
5417
5664
|
key: 1,
|
|
5418
5665
|
class: "flex items-center gap-1.5 text-xs text-black/65"
|
|
5419
|
-
},
|
|
5666
|
+
}, Ic = {
|
|
5420
5667
|
key: 0,
|
|
5421
5668
|
class: "size-2 shrink-0 rounded-full bg-primary",
|
|
5422
5669
|
"aria-hidden": "true"
|
|
5423
|
-
},
|
|
5670
|
+
}, Lc = {
|
|
5424
5671
|
key: 1,
|
|
5425
5672
|
class: "sr-only"
|
|
5426
|
-
},
|
|
5673
|
+
}, Rc = ["href"], zc = /* @__PURE__ */ f({
|
|
5427
5674
|
__name: "Notification",
|
|
5428
5675
|
props: {
|
|
5429
5676
|
type: { default: "info" },
|
|
@@ -5452,22 +5699,22 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5452
5699
|
setup(e, { emit: t }) {
|
|
5453
5700
|
let { t: n } = K(), r = e, l = t, f = `${P()}-title`, p = {
|
|
5454
5701
|
info: {
|
|
5455
|
-
icon:
|
|
5702
|
+
icon: Te,
|
|
5456
5703
|
colour: "text-blue",
|
|
5457
5704
|
word: "Information"
|
|
5458
5705
|
},
|
|
5459
5706
|
success: {
|
|
5460
|
-
icon:
|
|
5707
|
+
icon: ve,
|
|
5461
5708
|
colour: "text-green",
|
|
5462
5709
|
word: "Success"
|
|
5463
5710
|
},
|
|
5464
5711
|
warning: {
|
|
5465
|
-
icon:
|
|
5712
|
+
icon: Re,
|
|
5466
5713
|
colour: "text-yellow",
|
|
5467
5714
|
word: "Warning"
|
|
5468
5715
|
},
|
|
5469
5716
|
error: {
|
|
5470
|
-
icon:
|
|
5717
|
+
icon: be,
|
|
5471
5718
|
colour: "text-red",
|
|
5472
5719
|
word: "Error"
|
|
5473
5720
|
}
|
|
@@ -5488,12 +5735,12 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5488
5735
|
c("p", {
|
|
5489
5736
|
id: f,
|
|
5490
5737
|
class: y(M(X)("font-bold", h.value && "min-w-0 flex-1 py-1"))
|
|
5491
|
-
}, [c("span",
|
|
5492
|
-
!h.value && (e.description || t.$slots.default) ? (w(), s("div",
|
|
5493
|
-
e.appearance === "row" && (e.createdAt || e.unread) ? (w(), s("p",
|
|
5494
|
-
e.unread ? (w(), s("span",
|
|
5495
|
-
e.unread ? (w(), s("span",
|
|
5496
|
-
e.createdAt ? (w(), a(
|
|
5738
|
+
}, [c("span", Nc, j(p[e.type].word) + ": ", 1), u(j(e.title), 1)], 2),
|
|
5739
|
+
!h.value && (e.description || t.$slots.default) ? (w(), s("div", Pc, [O(t.$slots, "default", {}, () => [d(m)])])) : o("", !0),
|
|
5740
|
+
e.appearance === "row" && (e.createdAt || e.unread) ? (w(), s("p", Fc, [
|
|
5741
|
+
e.unread ? (w(), s("span", Ic)) : o("", !0),
|
|
5742
|
+
e.unread ? (w(), s("span", Lc, "Unread, ")) : o("", !0),
|
|
5743
|
+
e.createdAt ? (w(), a(bc, {
|
|
5497
5744
|
key: 2,
|
|
5498
5745
|
date: e.createdAt,
|
|
5499
5746
|
now: e.now
|
|
@@ -5508,7 +5755,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5508
5755
|
"as-child": "",
|
|
5509
5756
|
onClick: g
|
|
5510
5757
|
}, {
|
|
5511
|
-
default: V(() => [c("a", { href: e.action.href }, j(e.action.label), 9,
|
|
5758
|
+
default: V(() => [c("a", { href: e.action.href }, j(e.action.label), 9, Rc)]),
|
|
5512
5759
|
_: 1
|
|
5513
5760
|
})) : e.action ? (w(), a(Z, {
|
|
5514
5761
|
key: 1,
|
|
@@ -5529,16 +5776,16 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5529
5776
|
"aria-label": e.dismissLabel ?? M(n)("ui.notifications.dismiss", { title: e.title }),
|
|
5530
5777
|
onClick: i[0] ||= (e) => l("dismiss")
|
|
5531
5778
|
}, {
|
|
5532
|
-
default: V(() => [d(M(
|
|
5779
|
+
default: V(() => [d(M(Ve))]),
|
|
5533
5780
|
_: 1
|
|
5534
5781
|
}, 8, ["class", "aria-label"])) : o("", !0)
|
|
5535
5782
|
], 2));
|
|
5536
5783
|
}
|
|
5537
|
-
}),
|
|
5784
|
+
}), Bc = {
|
|
5538
5785
|
key: 0,
|
|
5539
5786
|
class: "absolute top-1 left-1/2 ml-1 flex h-4 min-w-4 items-center justify-center rounded-full bg-red px-1 text-xs leading-none font-bold text-white ring-2 ring-white",
|
|
5540
5787
|
"aria-hidden": "true"
|
|
5541
|
-
},
|
|
5788
|
+
}, Vc = { class: "flex h-11 shrink-0 items-center justify-between gap-2 border-b border-black/15 pr-2 pl-4" }, Hc = ["inert"], Uc = /* @__PURE__ */ f({
|
|
5542
5789
|
__name: "NotificationPane",
|
|
5543
5790
|
props: /*@__PURE__*/ g({
|
|
5544
5791
|
notifications: {},
|
|
@@ -5554,7 +5801,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5554
5801
|
}),
|
|
5555
5802
|
emits: ["update:open"],
|
|
5556
5803
|
setup(e) {
|
|
5557
|
-
let { t } = K(), r = e, l = F(e, "open"), f = i(() => r.notifications ??
|
|
5804
|
+
let { t } = K(), r = e, l = F(e, "open"), f = i(() => r.notifications ?? Mc()), p = i(() => f.value.items), m = i(() => f.value.unreadCount.value), h = i(() => m.value > 99 ? "99+" : String(m.value)), g = i(() => r.label ?? t("ui.notifications.title")), _ = i(() => m.value ? t("ui.notifications.withUnread", {
|
|
5558
5805
|
label: g.value,
|
|
5559
5806
|
count: h.value
|
|
5560
5807
|
}) : g.value), b = `${P()}-heading`, x = E(), S = E();
|
|
@@ -5590,7 +5837,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5590
5837
|
easing: "cubic-bezier(0, 0, 0.2, 1)"
|
|
5591
5838
|
});
|
|
5592
5839
|
}
|
|
5593
|
-
return (r, i) => (w(), a(
|
|
5840
|
+
return (r, i) => (w(), a(er, {
|
|
5594
5841
|
open: l.value,
|
|
5595
5842
|
"onUpdate:open": i[1] ||= (e) => l.value = e,
|
|
5596
5843
|
content: {
|
|
@@ -5604,7 +5851,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5604
5851
|
ref: C,
|
|
5605
5852
|
"aria-labelledby": b,
|
|
5606
5853
|
class: "flex min-h-0 flex-col"
|
|
5607
|
-
}, [c("div",
|
|
5854
|
+
}, [c("div", Vc, [c("h2", {
|
|
5608
5855
|
id: b,
|
|
5609
5856
|
ref_key: "heading",
|
|
5610
5857
|
ref: x,
|
|
@@ -5629,7 +5876,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5629
5876
|
}, [(w(!0), s(n, null, D(p.value, (e, t) => (w(), s("li", {
|
|
5630
5877
|
key: e.id,
|
|
5631
5878
|
class: "border-b border-black/15 last:border-b-0"
|
|
5632
|
-
}, [d(
|
|
5879
|
+
}, [d(zc, {
|
|
5633
5880
|
appearance: "row",
|
|
5634
5881
|
type: e.type,
|
|
5635
5882
|
title: e.title,
|
|
@@ -5648,10 +5895,10 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5648
5895
|
"unread",
|
|
5649
5896
|
"onDismiss",
|
|
5650
5897
|
"onAction"
|
|
5651
|
-
])]))), 128))], 42,
|
|
5898
|
+
])]))), 128))], 42, Hc)) : (w(), a(ys, {
|
|
5652
5899
|
key: 1,
|
|
5653
5900
|
size: "sm",
|
|
5654
|
-
icon: M(
|
|
5901
|
+
icon: M(se),
|
|
5655
5902
|
description: e.emptyText ?? M(t)("ui.notifications.empty"),
|
|
5656
5903
|
class: y(M(X)(O.value && "motion-safe:animate-empty-in")),
|
|
5657
5904
|
ui: { icon: M(X)("origin-top", O.value && "motion-safe:animate-bell-wobble") }
|
|
@@ -5667,13 +5914,13 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5667
5914
|
"aria-label": _.value,
|
|
5668
5915
|
class: y(M(X)("relative overflow-visible", e.ui?.trigger))
|
|
5669
5916
|
}, {
|
|
5670
|
-
default: V(() => [d(M(
|
|
5917
|
+
default: V(() => [d(M(oe)), m.value ? (w(), s("span", Bc, j(h.value), 1)) : o("", !0)]),
|
|
5671
5918
|
_: 1
|
|
5672
5919
|
}, 8, ["aria-label", "class"])]),
|
|
5673
5920
|
_: 1
|
|
5674
5921
|
}, 8, ["open", "ui"]));
|
|
5675
5922
|
}
|
|
5676
|
-
}),
|
|
5923
|
+
}), Wc = { class: "in-data-expanded:hidden" }, Gc = { class: "hidden in-data-expanded:inline" }, Kc = { class: "sr-only" }, qc = 8, Jc = .5, Yc = 80, Xc = /* @__PURE__ */ f({
|
|
5677
5924
|
__name: "Toaster",
|
|
5678
5925
|
props: {
|
|
5679
5926
|
notifications: {},
|
|
@@ -5690,15 +5937,15 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5690
5937
|
},
|
|
5691
5938
|
emits: ["more"],
|
|
5692
5939
|
setup(e, { emit: t }) {
|
|
5693
|
-
let { t: r } = K(), l = e, f = t, p = i(() => l.notifications ??
|
|
5940
|
+
let { t: r } = K(), l = e, f = t, p = i(() => l.notifications ?? Mc()), m = i(() => l.position === "top-right"), h = E(typeof window > "u" ? 800 : window.innerHeight), g = () => h.value = window.innerHeight;
|
|
5694
5941
|
C(() => window.addEventListener("resize", g)), S(() => window.removeEventListener("resize", g));
|
|
5695
|
-
let _ = i(() => Math.max(h.value -
|
|
5696
|
-
let e = p.value.toasts.slice(-l.limit).reverse(), t = (e) => L.get(e.id) ?? b(e.item), n = e.filter((e) => !W.has(e.id)), r = n.reduce((e, n) => e + t(n) +
|
|
5942
|
+
let _ = i(() => Math.max(h.value - Yc, 108)), b = (e) => e.compact ? 42 : e.action ? 116 : e.description ? 78 : 56, O = i(() => {
|
|
5943
|
+
let e = p.value.toasts.slice(-l.limit).reverse(), t = (e) => L.get(e.id) ?? b(e.item), n = e.filter((e) => !W.has(e.id)), r = n.reduce((e, n) => e + t(n) + qc, -8), i = /* @__PURE__ */ new Set();
|
|
5697
5944
|
if (r <= _.value) n.forEach((e) => i.add(e.id));
|
|
5698
5945
|
else {
|
|
5699
5946
|
let e = 44;
|
|
5700
5947
|
for (let r of n) {
|
|
5701
|
-
let n = e + t(r) + (i.size ?
|
|
5948
|
+
let n = e + t(r) + (i.size ? qc : 0);
|
|
5702
5949
|
if (i.size && n > _.value) break;
|
|
5703
5950
|
i.add(r.id), e = n;
|
|
5704
5951
|
}
|
|
@@ -5723,7 +5970,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5723
5970
|
z(() => p.value.paneOpen, (e) => {
|
|
5724
5971
|
if (!e) return;
|
|
5725
5972
|
let t = new Set(k.value.map((e) => e.id));
|
|
5726
|
-
for (let e of [...p.value.toasts]) t.has(e.id) ?
|
|
5973
|
+
for (let e of [...p.value.toasts]) t.has(e.id) ? q(e.id, !1) : p.value.hideToast(e.id);
|
|
5727
5974
|
});
|
|
5728
5975
|
function I() {
|
|
5729
5976
|
p.value.openPane(), f("more");
|
|
@@ -5746,23 +5993,23 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5746
5993
|
})));
|
|
5747
5994
|
}
|
|
5748
5995
|
let W = T(/* @__PURE__ */ new Set()), G = /* @__PURE__ */ new Map();
|
|
5749
|
-
function
|
|
5996
|
+
function q(e, t) {
|
|
5750
5997
|
t || W.has(e) || (W.add(e), setTimeout(() => {
|
|
5751
5998
|
p.value.hideToast(e), W.delete(e), U.delete(e), G.delete(e), L.delete(e);
|
|
5752
5999
|
}, 200));
|
|
5753
6000
|
}
|
|
5754
|
-
let
|
|
6001
|
+
let J = i(() => {
|
|
5755
6002
|
let e = k.value.filter((e) => !W.has(e.id)), t = /* @__PURE__ */ new Map(), n = [], r = 0;
|
|
5756
|
-
for (let t of e) n.push(r), r += (L.get(t.id) ?? 0) +
|
|
5757
|
-
let i = Math.max(r -
|
|
6003
|
+
for (let t of e) n.push(r), r += (L.get(t.id) ?? 0) + qc;
|
|
6004
|
+
let i = Math.max(r - qc, 0), a = Math.min(l.maxHeight, _.value), o = 0;
|
|
5758
6005
|
for (; o < e.length && (o === 0 || n[o] + (L.get(e[o].id) ?? 0) <= a);) o++;
|
|
5759
|
-
let s = e[o - 1], c = n[o - 1] ?? 0, u = s ? L.get(s.id) ?? 0 : 0, d = c + u +
|
|
6006
|
+
let s = e[o - 1], c = n[o - 1] ?? 0, u = s ? L.get(s.id) ?? 0 : 0, d = c + u + qc;
|
|
5760
6007
|
e.forEach((r, i) => {
|
|
5761
6008
|
let a = i >= o;
|
|
5762
6009
|
t.set(r.id, {
|
|
5763
6010
|
spread: n[i],
|
|
5764
6011
|
stacked: a ? d : n[i],
|
|
5765
|
-
scale: a ?
|
|
6012
|
+
scale: a ? Jc : 1,
|
|
5766
6013
|
opacity: +!a,
|
|
5767
6014
|
z: e.length - i
|
|
5768
6015
|
});
|
|
@@ -5773,19 +6020,19 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5773
6020
|
places: t,
|
|
5774
6021
|
spreadHeight: i + (A.value > 0 ? 44 : 0),
|
|
5775
6022
|
stackedHeight: p,
|
|
5776
|
-
moreOffset: i + (i ?
|
|
6023
|
+
moreOffset: i + (i ? qc : 0),
|
|
5777
6024
|
notInView: f,
|
|
5778
6025
|
pillOffset: d
|
|
5779
6026
|
};
|
|
5780
6027
|
});
|
|
5781
|
-
function
|
|
5782
|
-
let t = W.has(e) ? G.get(e) :
|
|
5783
|
-
"--toast-spread": r(
|
|
5784
|
-
"--toast-stacked": r(
|
|
5785
|
-
"--toast-scale":
|
|
6028
|
+
function te(e) {
|
|
6029
|
+
let t = W.has(e) ? G.get(e) : J.value.places.get(e), n = m.value ? 1 : -1, r = (e) => `${n * e}px`, i = {
|
|
6030
|
+
"--toast-spread": r(J.value.moreOffset),
|
|
6031
|
+
"--toast-stacked": r(J.value.pillOffset),
|
|
6032
|
+
"--toast-scale": Jc,
|
|
5786
6033
|
"--toast-opacity": 0,
|
|
5787
6034
|
"--toast-spread-opacity": 0,
|
|
5788
|
-
"--toast-spread-scale":
|
|
6035
|
+
"--toast-spread-scale": Jc,
|
|
5789
6036
|
"--toast-z": 0
|
|
5790
6037
|
};
|
|
5791
6038
|
if (!t && N.has(e) || t && !U.has(e) && P.has(e)) return i;
|
|
@@ -5811,9 +6058,9 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5811
6058
|
"--toast-z": t.z
|
|
5812
6059
|
};
|
|
5813
6060
|
}
|
|
5814
|
-
let
|
|
5815
|
-
"--toast-more": `${
|
|
5816
|
-
"--toast-pill": `${
|
|
6061
|
+
let ne = i(() => m.value ? 1 : -1), re = i(() => ({
|
|
6062
|
+
"--toast-more": `${ne.value * J.value.moreOffset}px`,
|
|
6063
|
+
"--toast-pill": `${ne.value * J.value.pillOffset}px`
|
|
5817
6064
|
}));
|
|
5818
6065
|
function ie(e) {
|
|
5819
6066
|
e.currentTarget.closest("[data-expanded]") ? I() : ae();
|
|
@@ -5823,27 +6070,27 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5823
6070
|
(e && R.get(e.id)?.parentElement)?.focus({ focusVisible: !1 });
|
|
5824
6071
|
}
|
|
5825
6072
|
let oe = i(() => ({
|
|
5826
|
-
"--toast-stack-spread": `${
|
|
5827
|
-
"--toast-stack-stacked": `${
|
|
6073
|
+
"--toast-stack-spread": `${J.value.spreadHeight}px`,
|
|
6074
|
+
"--toast-stack-stacked": `${J.value.stackedHeight}px`
|
|
5828
6075
|
})), se = {
|
|
5829
6076
|
"bottom-right": "right-4 bottom-4 left-4 sm:left-auto sm:w-96",
|
|
5830
6077
|
"top-right": "top-16 right-4 left-4 sm:left-auto sm:w-96",
|
|
5831
6078
|
"bottom-center": "bottom-4 left-1/2 w-[calc(100%-2rem)] -translate-x-1/2 sm:w-96"
|
|
5832
6079
|
};
|
|
5833
|
-
return (t, i) => (w(), a(M(
|
|
6080
|
+
return (t, i) => (w(), a(M(mn), {
|
|
5834
6081
|
"swipe-direction": "right",
|
|
5835
6082
|
label: M(r)("ui.notifications.region")
|
|
5836
6083
|
}, {
|
|
5837
|
-
default: V(() => [(w(!0), s(n, null, D(F.value, (e) => (w(), a(M(
|
|
6084
|
+
default: V(() => [(w(!0), s(n, null, D(F.value, (e) => (w(), a(M(hn), {
|
|
5838
6085
|
key: e.id,
|
|
5839
6086
|
open: !W.has(e.id),
|
|
5840
6087
|
duration: e.duration,
|
|
5841
6088
|
type: e.item.type === "error" || e.item.type === "warning" ? "foreground" : "background",
|
|
5842
|
-
style: x(
|
|
6089
|
+
style: x(te(e.id)),
|
|
5843
6090
|
class: y(M(X)("absolute inset-x-0 z-(--toast-z) list-none rounded", "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0", m.value ? "top-0 origin-top" : "bottom-0 origin-bottom", "translate-y-(--toast-stacked) scale-(--toast-scale) opacity-(--toast-opacity)", "data-expanded:translate-y-(--toast-spread) data-expanded:scale-(--toast-spread-scale) data-expanded:opacity-(--toast-spread-opacity)", "transition-[translate,scale,opacity] duration-300 ease-out motion-reduce:transition-none", "data-[state=closed]:animate-fade-out", "data-[swipe=move]:translate-x-(--reka-toast-swipe-move-x) data-[swipe=move]:transition-none", "data-[swipe=cancel]:translate-x-0", "data-[swipe=end]:animate-slide-out-right")),
|
|
5844
|
-
"onUpdate:open": (t) =>
|
|
6091
|
+
"onUpdate:open": (t) => q(e.id, t)
|
|
5845
6092
|
}, {
|
|
5846
|
-
default: V(() => [d(
|
|
6093
|
+
default: V(() => [d(zc, {
|
|
5847
6094
|
ref_for: !0,
|
|
5848
6095
|
ref: (t) => H(e.id, t),
|
|
5849
6096
|
type: e.item.type,
|
|
@@ -5853,8 +6100,8 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5853
6100
|
compact: e.item.compact,
|
|
5854
6101
|
class: "shadow-md",
|
|
5855
6102
|
"dismiss-label": M(r)("ui.notifications.close", { title: e.item.title }),
|
|
5856
|
-
onDismiss: (t) =>
|
|
5857
|
-
onAction: (t) =>
|
|
6103
|
+
onDismiss: (t) => q(e.id, !1),
|
|
6104
|
+
onAction: (t) => q(e.id, !1)
|
|
5858
6105
|
}, null, 8, [
|
|
5859
6106
|
"type",
|
|
5860
6107
|
"title",
|
|
@@ -5873,20 +6120,20 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5873
6120
|
"style",
|
|
5874
6121
|
"class",
|
|
5875
6122
|
"onUpdate:open"
|
|
5876
|
-
]))), 128)), d(M(
|
|
6123
|
+
]))), 128)), d(M(gn), {
|
|
5877
6124
|
label: M(r)("ui.notifications.hotkeyRegion", { hotkey: "{hotkey}" }),
|
|
5878
6125
|
style: x(oe.value),
|
|
5879
6126
|
class: y(M(X)("fixed z-100 m-0 list-none p-0 outline-none", "h-(--toast-stack-stacked) data-expanded:h-(--toast-stack-spread)", se[e.position], l.class))
|
|
5880
6127
|
}, {
|
|
5881
|
-
default: V(() => [
|
|
6128
|
+
default: V(() => [J.value.notInView ? (w(), s("li", {
|
|
5882
6129
|
key: 0,
|
|
5883
|
-
style: x(
|
|
6130
|
+
style: x(re.value),
|
|
5884
6131
|
class: y(M(X)("absolute inset-x-0 z-0 flex list-none justify-center", m.value ? "top-0" : "bottom-0", "translate-y-(--toast-pill) transition-[translate,opacity,visibility] duration-300 ease-out motion-reduce:transition-none", A.value ? "in-data-expanded:translate-y-(--toast-more)" : "in-data-expanded:invisible in-data-expanded:opacity-0 in-data-expanded:duration-150"))
|
|
5885
6132
|
}, [c("button", {
|
|
5886
6133
|
type: "button",
|
|
5887
6134
|
class: y(M(X)("flex cursor-pointer items-center justify-center overflow-hidden border border-black/15 bg-white font-bold whitespace-nowrap text-black shadow-md hover:bg-surface-elevated", "h-7 w-24 rounded-2xl text-xs", A.value && "in-data-expanded:h-9 in-data-expanded:w-full in-data-expanded:rounded in-data-expanded:text-sm", "transition-[width,height,border-radius,font-size,background-color] duration-300 ease-out motion-reduce:transition-none", "outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus forced-colors:not-focus-visible:outline-0")),
|
|
5888
6135
|
onClick: ie
|
|
5889
|
-
}, [A.value ? (w(), s(n, { key: 0 }, [c("span",
|
|
6136
|
+
}, [A.value ? (w(), s(n, { key: 0 }, [c("span", Wc, j(M(r)("ui.notifications.more", { count: J.value.notInView })), 1), c("span", Gc, j(M(r)("ui.notifications.more", { count: A.value })), 1)], 64)) : (w(), s(n, { key: 1 }, [u(j(M(r)("ui.notifications.more", { count: J.value.notInView })), 1)], 64)), c("span", Kc, "\xA0" + j(M(r)("ui.notifications.notifications")), 1)], 2)], 6)) : o("", !0)]),
|
|
5890
6137
|
_: 1
|
|
5891
6138
|
}, 8, [
|
|
5892
6139
|
"label",
|
|
@@ -5896,14 +6143,14 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5896
6143
|
_: 1
|
|
5897
6144
|
}, 8, ["label"]));
|
|
5898
6145
|
}
|
|
5899
|
-
}),
|
|
6146
|
+
}), Zc = {
|
|
5900
6147
|
key: 0,
|
|
5901
6148
|
"aria-hidden": "true",
|
|
5902
6149
|
class: "h-20"
|
|
5903
|
-
},
|
|
6150
|
+
}, Qc = ["aria-label"], $c = { class: "pointer-events-auto flex w-full max-w-2xl items-center justify-between gap-3 rounded-lg border border-black/15 bg-white p-3 pl-4 shadow-lg" }, el = {
|
|
5904
6151
|
role: "status",
|
|
5905
6152
|
class: "flex items-center gap-2 text-sm font-bold"
|
|
5906
|
-
},
|
|
6153
|
+
}, tl = { class: "flex shrink-0 items-center gap-2" }, nl = /* @__PURE__ */ f({
|
|
5907
6154
|
__name: "UnsavedChangesBar",
|
|
5908
6155
|
props: {
|
|
5909
6156
|
open: { type: Boolean },
|
|
@@ -5926,7 +6173,7 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5926
6173
|
emits: ["discard", "save"],
|
|
5927
6174
|
setup(e, { emit: t }) {
|
|
5928
6175
|
let { t: a } = K(), l = e, f = t, p = i(() => l.status === "loading");
|
|
5929
|
-
return (t, i) => (w(), s(n, null, [e.open && e.reserveSpace ? (w(), s("div",
|
|
6176
|
+
return (t, i) => (w(), s(n, null, [e.open && e.reserveSpace ? (w(), s("div", Zc)) : o("", !0), d(r, {
|
|
5930
6177
|
"enter-active-class": "transition duration-300 ease-out motion-reduce:transition-none",
|
|
5931
6178
|
"leave-active-class": "transition duration-200 ease-in motion-reduce:transition-none",
|
|
5932
6179
|
"enter-from-class": "translate-y-full motion-reduce:translate-y-0 motion-reduce:opacity-0",
|
|
@@ -5937,10 +6184,10 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5937
6184
|
role: "region",
|
|
5938
6185
|
"aria-label": e.message ?? M(a)("ui.unsavedChangesBar.message"),
|
|
5939
6186
|
class: y(M(X)("fixed inset-x-0 bottom-0 z-40 flex justify-center px-4 pb-4 pointer-events-none", l.class))
|
|
5940
|
-
}, [c("div",
|
|
6187
|
+
}, [c("div", $c, [c("p", el, [i[2] ||= c("span", {
|
|
5941
6188
|
"aria-hidden": "true",
|
|
5942
6189
|
class: "size-2 shrink-0 rounded-full bg-yellow"
|
|
5943
|
-
}, null, -1), u(" " + j(e.message ?? M(a)("ui.unsavedChangesBar.message")), 1)]), c("div",
|
|
6190
|
+
}, null, -1), u(" " + j(e.message ?? M(a)("ui.unsavedChangesBar.message")), 1)]), c("div", tl, [d(Z, {
|
|
5944
6191
|
disabled: p.value,
|
|
5945
6192
|
onClick: i[0] ||= (e) => f("discard")
|
|
5946
6193
|
}, {
|
|
@@ -5954,11 +6201,11 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5954
6201
|
}, {
|
|
5955
6202
|
default: V(() => [u(j(e.saveLabel ?? M(a)("ui.unsavedChangesBar.save")), 1)]),
|
|
5956
6203
|
_: 1
|
|
5957
|
-
}, 8, ["status", "disabled"])])])], 10,
|
|
6204
|
+
}, 8, ["status", "disabled"])])])], 10, Qc)) : o("", !0)]),
|
|
5958
6205
|
_: 1
|
|
5959
6206
|
})], 64));
|
|
5960
6207
|
}
|
|
5961
|
-
}),
|
|
6208
|
+
}), rl = { ui: {
|
|
5962
6209
|
age: {
|
|
5963
6210
|
born: "Born {date}",
|
|
5964
6211
|
birthdayToday: "Birthday today",
|
|
@@ -5991,6 +6238,13 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
5991
6238
|
},
|
|
5992
6239
|
changeIndicator: { changed: "Changed from {from} to {to}" },
|
|
5993
6240
|
chip: { remove: "Remove" },
|
|
6241
|
+
appLauncher: { label: "Keston apps" },
|
|
6242
|
+
footer: {
|
|
6243
|
+
label: "Help and legal",
|
|
6244
|
+
version: "Version {version}",
|
|
6245
|
+
build: "Build {build}",
|
|
6246
|
+
copyright: "© {years} {holder}"
|
|
6247
|
+
},
|
|
5994
6248
|
formField: { about: "About {label}" },
|
|
5995
6249
|
header: {
|
|
5996
6250
|
menu: "Menu",
|
|
@@ -6080,16 +6334,16 @@ var Qs = { class: "sr-only" }, $s = {
|
|
|
6080
6334
|
discard: "Discard",
|
|
6081
6335
|
save: "Save"
|
|
6082
6336
|
}
|
|
6083
|
-
} },
|
|
6084
|
-
function
|
|
6085
|
-
let { messages: t = {}, fallbackLocale: n = "en", storageKey: r = "keston-locale" } = e, i = [.../* @__PURE__ */ new Set([...Object.keys(
|
|
6337
|
+
} }, il = { en: rl };
|
|
6338
|
+
function al(e = {}) {
|
|
6339
|
+
let { messages: t = {}, fallbackLocale: n = "en", storageKey: r = "keston-locale" } = e, i = [.../* @__PURE__ */ new Set([...Object.keys(il), ...Object.keys(t)])], a = {};
|
|
6086
6340
|
for (let e of i) a[e] = {
|
|
6087
|
-
...
|
|
6341
|
+
...il[e],
|
|
6088
6342
|
...t[e]
|
|
6089
6343
|
};
|
|
6090
6344
|
let o = G({
|
|
6091
6345
|
legacy: !1,
|
|
6092
|
-
locale: e.locale ??
|
|
6346
|
+
locale: e.locale ?? ol(i, n, r),
|
|
6093
6347
|
fallbackLocale: n,
|
|
6094
6348
|
messages: a
|
|
6095
6349
|
});
|
|
@@ -6100,7 +6354,7 @@ function wc(e = {}) {
|
|
|
6100
6354
|
typeof document < "u" && (document.documentElement.lang = e);
|
|
6101
6355
|
}, { immediate: !0 }), o;
|
|
6102
6356
|
}
|
|
6103
|
-
function
|
|
6357
|
+
function ol(e, t, n) {
|
|
6104
6358
|
try {
|
|
6105
6359
|
let t = localStorage.getItem(n);
|
|
6106
6360
|
if (t && e.includes(t)) return t;
|
|
@@ -6111,4 +6365,4 @@ function Tc(e, t, n) {
|
|
|
6111
6365
|
}
|
|
6112
6366
|
return t;
|
|
6113
6367
|
}
|
|
6114
|
-
export {
|
|
6368
|
+
export { Sc as Age, ur as AppLauncher, Ni as AppShell, Gr as Avatar, la as AvatarGroup, ni as Badge, Hi as Breadcrumb, Z as Button, Xa as Calendar, pa as Card, vs as CardSelect, Ta as ChangeIndicator, Yo as Checkbox, ds as CheckboxGroup, oc as Checklist, ga as Chip, ya as Divider, ys as EmptyState, Or as Footer, Ia as FormField, ei as Header, Oa as InfoTip, Ra as Input, No as InputCode, bo as InputDate, Va as InputNumber, Oo as InputPassword, wo as InputRichText, ss as InputTextArea, fs as LanguageSwitcher, dr as Link, Ui as Menu, zc as Notification, Uc as NotificationPane, Zi as PageHeader, er as Popover, yi as Progress, ns as RadioGroup, bc as RelativeTime, qo as Select, na as SettingsRow, gi as Sidebar, Oi as Slideover, Gn as Spinner, Js as StatTile, Tc as Steps, rc as SummaryList, as as Switch, Bs as Table, Ec as Tabs, Xc as Toaster, xo as Tooltip, nl as UnsavedChangesBar, pc as age, X as cn, al as createKestonI18n, Ac as createNotifications, mc as daysToBirthday, rl as en, fc as formatDate, dc as formatDateTime, tr as kestonApps, hr as kestonFooterLinks, gr as kestonGroupLinks, uc as relativeTime, ri as sidebarTrail, Ss as sortRows, sc as toDate, il as uiMessages, Mc as useNotifications, vc as useNow };
|