@thekestongroup/ui 0.12.0 → 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 +3 -0
- package/dist/components/Header/Header.vue.d.ts +1 -1
- package/dist/components/Slideover/Slideover.vue.d.ts +1 -1
- package/dist/i18n/en.d.ts +3 -0
- package/dist/index.d.ts +3 -0
- package/dist/keston-ui.js +989 -894
- 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 +5 -0
- package/src/components/AppShell/AppShell.vue +7 -1
- package/src/components/Footer/footer.test.ts +2 -2
- package/src/components/Footer/links.ts +3 -3
- package/src/i18n/en.ts +1 -0
- package/src/index.ts +3 -0
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,7 +229,233 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
229
229
|
"class"
|
|
230
230
|
]));
|
|
231
231
|
}
|
|
232
|
-
}),
|
|
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({
|
|
233
|
+
__name: "Popover",
|
|
234
|
+
props: /*@__PURE__*/ g({
|
|
235
|
+
mode: { default: "click" },
|
|
236
|
+
content: {},
|
|
237
|
+
arrow: {
|
|
238
|
+
type: [Boolean, Object],
|
|
239
|
+
default: !1
|
|
240
|
+
},
|
|
241
|
+
portal: {
|
|
242
|
+
type: [Boolean, String],
|
|
243
|
+
default: !0
|
|
244
|
+
},
|
|
245
|
+
dismissible: {
|
|
246
|
+
type: Boolean,
|
|
247
|
+
default: !0
|
|
248
|
+
},
|
|
249
|
+
modal: {
|
|
250
|
+
type: Boolean,
|
|
251
|
+
default: !1
|
|
252
|
+
},
|
|
253
|
+
defaultOpen: { type: Boolean },
|
|
254
|
+
openDelay: { default: 0 },
|
|
255
|
+
closeDelay: { default: 0 },
|
|
256
|
+
ui: {}
|
|
257
|
+
}, {
|
|
258
|
+
open: {
|
|
259
|
+
type: Boolean,
|
|
260
|
+
default: void 0
|
|
261
|
+
},
|
|
262
|
+
openModifiers: {}
|
|
263
|
+
}),
|
|
264
|
+
emits: /*@__PURE__*/ g(["close:prevent"], ["update:open"]),
|
|
265
|
+
setup(e, { emit: t }) {
|
|
266
|
+
let n = e, r = t, i = F(e, "open"), s = E(i.value ?? n.defaultOpen ?? !1);
|
|
267
|
+
z(i, (e) => {
|
|
268
|
+
e !== void 0 && (s.value = e);
|
|
269
|
+
});
|
|
270
|
+
function l(e) {
|
|
271
|
+
s.value = e, i.value = e;
|
|
272
|
+
}
|
|
273
|
+
function u() {
|
|
274
|
+
p = !1, l(!1);
|
|
275
|
+
}
|
|
276
|
+
let f = {
|
|
277
|
+
side: "bottom",
|
|
278
|
+
sideOffset: 8,
|
|
279
|
+
collisionPadding: 8
|
|
280
|
+
}, p = !1, m = !1, h, g;
|
|
281
|
+
function v(e) {
|
|
282
|
+
n.mode === "hover" && e.pointerType === "mouse" && (clearTimeout(g), clearTimeout(h), h = setTimeout(() => l(!0), n.openDelay));
|
|
283
|
+
}
|
|
284
|
+
function b(e) {
|
|
285
|
+
n.mode !== "hover" || e.pointerType !== "mouse" || p || (clearTimeout(h), g = setTimeout(() => l(!1), Math.max(n.closeDelay, 100)));
|
|
286
|
+
}
|
|
287
|
+
function x() {
|
|
288
|
+
n.mode === "hover" && (m = s.value && !p);
|
|
289
|
+
}
|
|
290
|
+
S(() => {
|
|
291
|
+
clearTimeout(h), clearTimeout(g);
|
|
292
|
+
});
|
|
293
|
+
function C(e) {
|
|
294
|
+
if (n.mode === "hover") {
|
|
295
|
+
if (!e && m) {
|
|
296
|
+
m = !1, p = !0;
|
|
297
|
+
return;
|
|
298
|
+
}
|
|
299
|
+
m = !1, p = e;
|
|
300
|
+
}
|
|
301
|
+
l(e);
|
|
302
|
+
}
|
|
303
|
+
let T = 0;
|
|
304
|
+
function D(e) {
|
|
305
|
+
if (n.dismissible) return;
|
|
306
|
+
e.preventDefault();
|
|
307
|
+
let t = performance.now();
|
|
308
|
+
t - T > 50 && r("close:prevent"), T = t;
|
|
309
|
+
}
|
|
310
|
+
function k(e) {
|
|
311
|
+
n.mode === "hover" && e.preventDefault();
|
|
312
|
+
}
|
|
313
|
+
let A = () => typeof n.portal == "string" || n.portal instanceof HTMLElement ? n.portal : void 0;
|
|
314
|
+
return (t, n) => (w(), a(M(Bt), {
|
|
315
|
+
open: s.value,
|
|
316
|
+
modal: e.modal,
|
|
317
|
+
"onUpdate:open": C
|
|
318
|
+
}, {
|
|
319
|
+
default: V(() => [
|
|
320
|
+
t.$slots.anchor ? (w(), a(M(It), {
|
|
321
|
+
key: 0,
|
|
322
|
+
"as-child": ""
|
|
323
|
+
}, {
|
|
324
|
+
default: V(() => [O(t.$slots, "anchor")]),
|
|
325
|
+
_: 3
|
|
326
|
+
})) : o("", !0),
|
|
327
|
+
t.$slots.default ? (w(), a(M(Vt), {
|
|
328
|
+
key: 1,
|
|
329
|
+
"as-child": "",
|
|
330
|
+
onPointerdown: x,
|
|
331
|
+
onPointerenter: v,
|
|
332
|
+
onPointerleave: b
|
|
333
|
+
}, {
|
|
334
|
+
default: V(() => [O(t.$slots, "default")]),
|
|
335
|
+
_: 3
|
|
336
|
+
})) : o("", !0),
|
|
337
|
+
d(M(zt), {
|
|
338
|
+
disabled: e.portal === !1,
|
|
339
|
+
to: A()
|
|
340
|
+
}, {
|
|
341
|
+
default: V(() => [d(M(Rt), _({
|
|
342
|
+
...f,
|
|
343
|
+
...e.content
|
|
344
|
+
}, {
|
|
345
|
+
class: M(X)(M(Qn), e.ui?.content),
|
|
346
|
+
onPointerenter: v,
|
|
347
|
+
onPointerleave: b,
|
|
348
|
+
onEscapeKeyDown: D,
|
|
349
|
+
onInteractOutside: D,
|
|
350
|
+
onOpenAutoFocus: k,
|
|
351
|
+
onCloseAutoFocus: k
|
|
352
|
+
}), {
|
|
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)]),
|
|
355
|
+
_: 1
|
|
356
|
+
}, 16)) : o("", !0)]),
|
|
357
|
+
_: 3
|
|
358
|
+
}, 16, ["class"])]),
|
|
359
|
+
_: 3
|
|
360
|
+
}, 8, ["disabled", "to"])
|
|
361
|
+
]),
|
|
362
|
+
_: 3
|
|
363
|
+
}, 8, ["open", "modal"]));
|
|
364
|
+
}
|
|
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({
|
|
233
459
|
__name: "Link",
|
|
234
460
|
props: {
|
|
235
461
|
href: {},
|
|
@@ -253,7 +479,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
253
479
|
"hover:text-black hover:decoration-2",
|
|
254
480
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
255
481
|
];
|
|
256
|
-
return (i, l) => (w(), a(M(
|
|
482
|
+
return (i, l) => (w(), a(M(Ht), {
|
|
257
483
|
as: e.as,
|
|
258
484
|
href: e.href,
|
|
259
485
|
type: e.as === "button" ? "button" : void 0,
|
|
@@ -261,7 +487,7 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
261
487
|
rel: e.newTab ? "noopener noreferrer" : void 0,
|
|
262
488
|
class: y(M(X)(r, t.class))
|
|
263
489
|
}, {
|
|
264
|
-
default: V(() => [O(i.$slots, "default"), e.newTab ? (w(), s(n, { key: 0 }, [e.icon ? (w(), a(M(
|
|
490
|
+
default: V(() => [O(i.$slots, "default"), e.newTab ? (w(), s(n, { key: 0 }, [e.icon ? (w(), a(M(Y), {
|
|
265
491
|
key: 0,
|
|
266
492
|
class: "ms-0.5 inline size-[0.9em] align-[-0.1em]",
|
|
267
493
|
"aria-hidden": "true"
|
|
@@ -278,30 +504,30 @@ var Fn = ["stroke-dashoffset", "stroke-opacity"], In = {
|
|
|
278
504
|
}
|
|
279
505
|
});
|
|
280
506
|
// src/components/Footer/footer.ts
|
|
281
|
-
function
|
|
507
|
+
function fr(e, t) {
|
|
282
508
|
return t && t < e ? `${t}–${e}` : String(e);
|
|
283
509
|
}
|
|
284
|
-
function
|
|
510
|
+
function pr(e) {
|
|
285
511
|
return e ? /^v/i.test(e) ? `v${e.slice(1)}` : `v${e}` : "";
|
|
286
512
|
}
|
|
287
|
-
function
|
|
513
|
+
function mr(e) {
|
|
288
514
|
return e ? e.replace(/^v/i, "") : "";
|
|
289
515
|
}
|
|
290
516
|
// src/components/Footer/links.ts
|
|
291
|
-
var
|
|
517
|
+
var hr = [
|
|
292
518
|
{
|
|
293
519
|
label: "Help & support",
|
|
294
|
-
href: "https://
|
|
520
|
+
href: "https://thekestongroup.com/help"
|
|
295
521
|
},
|
|
296
522
|
{
|
|
297
523
|
label: "Privacy Policy",
|
|
298
|
-
href: "https://
|
|
524
|
+
href: "https://thekestongroup.com/privacy"
|
|
299
525
|
},
|
|
300
526
|
{
|
|
301
527
|
label: "Terms & Conditions",
|
|
302
|
-
href: "https://
|
|
528
|
+
href: "https://thekestongroup.com/terms"
|
|
303
529
|
}
|
|
304
|
-
],
|
|
530
|
+
], gr = [
|
|
305
531
|
{
|
|
306
532
|
label: "Keston ID",
|
|
307
533
|
href: "https://id.keston.co"
|
|
@@ -318,23 +544,23 @@ var Yn = [
|
|
|
318
544
|
label: "Design system",
|
|
319
545
|
href: "https://ui.keston.co"
|
|
320
546
|
}
|
|
321
|
-
],
|
|
547
|
+
], _r = ["aria-label"], vr = { class: "flex flex-wrap items-center gap-x-4 gap-y-1" }, yr = {
|
|
322
548
|
key: 0,
|
|
323
549
|
class: "hidden h-4 w-px bg-black/15 sm:block",
|
|
324
550
|
"aria-hidden": "true"
|
|
325
|
-
},
|
|
551
|
+
}, br = {
|
|
326
552
|
key: 0,
|
|
327
553
|
class: "flex flex-wrap items-baseline gap-x-1.5"
|
|
328
|
-
},
|
|
554
|
+
}, xr = {
|
|
329
555
|
key: 0,
|
|
330
556
|
class: "font-bold text-black/80"
|
|
331
|
-
},
|
|
557
|
+
}, Sr = { key: 1 }, Cr = { class: "sr-only" }, wr = { "aria-hidden": "true" }, Tr = ["title"], Er = { class: "sr-only" }, Dr = {
|
|
332
558
|
class: "font-mono text-xs text-black/55",
|
|
333
559
|
"aria-hidden": "true"
|
|
334
|
-
},
|
|
560
|
+
}, Or = /* @__PURE__ */ f({
|
|
335
561
|
__name: "Footer",
|
|
336
562
|
props: {
|
|
337
|
-
links: { default: () =>
|
|
563
|
+
links: { default: () => hr },
|
|
338
564
|
moreLinks: { default: () => [] },
|
|
339
565
|
linkComponent: { default: void 0 },
|
|
340
566
|
appName: {},
|
|
@@ -353,7 +579,7 @@ var Yn = [
|
|
|
353
579
|
ui: {}
|
|
354
580
|
},
|
|
355
581
|
setup(e) {
|
|
356
|
-
let { t } = K(), r = e, a = i(() =>
|
|
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 }) : "");
|
|
357
583
|
function m(e) {
|
|
358
584
|
return e.to === void 0 ? {
|
|
359
585
|
href: e.href,
|
|
@@ -367,24 +593,24 @@ var Yn = [
|
|
|
367
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", {
|
|
368
594
|
"aria-label": M(t)("ui.footer.label"),
|
|
369
595
|
class: y(M(X)("min-w-0", e.ui?.links))
|
|
370
|
-
}, [O(i.$slots, "nav", {}, () => [c("ul",
|
|
371
|
-
(w(!0), s(n, null, D(e.links, (e) => (w(), s("li", { key: e.label }, [d(
|
|
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 }), {
|
|
372
598
|
default: V(() => [u(j(e.label), 1)]),
|
|
373
599
|
_: 2
|
|
374
600
|
}, 1040)]))), 128)),
|
|
375
|
-
e.moreLinks.length ? (w(), s("li",
|
|
376
|
-
(w(!0), s(n, null, D(e.moreLinks, (e) => (w(), s("li", { key: e.label }, [d(
|
|
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 }), {
|
|
377
603
|
default: V(() => [u(j(e.label), 1)]),
|
|
378
604
|
_: 2
|
|
379
605
|
}, 1040)]))), 128))
|
|
380
|
-
])])], 10,
|
|
381
|
-
e.appName || e.version || e.build ? (w(), s("p",
|
|
382
|
-
e.appName ? (w(), s("span",
|
|
383
|
-
e.version ? (w(), s("span",
|
|
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),
|
|
384
610
|
e.build ? (w(), s("span", {
|
|
385
611
|
key: 2,
|
|
386
612
|
title: p.value
|
|
387
|
-
}, [c("span",
|
|
613
|
+
}, [c("span", Er, j(p.value), 1), c("span", Dr, j(e.build), 1)], 8, Tr)) : o("", !0)
|
|
388
614
|
])) : o("", !0),
|
|
389
615
|
c("p", null, j(M(t)("ui.footer.copyright", {
|
|
390
616
|
years: a.value,
|
|
@@ -395,175 +621,42 @@ var Yn = [
|
|
|
395
621
|
}
|
|
396
622
|
});
|
|
397
623
|
// src/lib/initials.ts
|
|
398
|
-
function
|
|
624
|
+
function kr(e) {
|
|
399
625
|
let t = e.trim().split(/\s+/).filter(Boolean);
|
|
400
626
|
if (!t.length) return "";
|
|
401
627
|
let n = t[0], r = t.length > 1 ? t[t.length - 1] : "";
|
|
402
628
|
return (n[0] + (r[0] ?? "")).toUpperCase();
|
|
403
629
|
}
|
|
404
|
-
// src/components/
|
|
405
|
-
var
|
|
406
|
-
__name: "Popover",
|
|
407
|
-
props: /*@__PURE__*/ g({
|
|
408
|
-
mode: { default: "click" },
|
|
409
|
-
content: {},
|
|
410
|
-
arrow: {
|
|
411
|
-
type: [Boolean, Object],
|
|
412
|
-
default: !1
|
|
413
|
-
},
|
|
414
|
-
portal: {
|
|
415
|
-
type: [Boolean, String],
|
|
416
|
-
default: !0
|
|
417
|
-
},
|
|
418
|
-
dismissible: {
|
|
419
|
-
type: Boolean,
|
|
420
|
-
default: !0
|
|
421
|
-
},
|
|
422
|
-
modal: {
|
|
423
|
-
type: Boolean,
|
|
424
|
-
default: !1
|
|
425
|
-
},
|
|
426
|
-
defaultOpen: { type: Boolean },
|
|
427
|
-
openDelay: { default: 0 },
|
|
428
|
-
closeDelay: { default: 0 },
|
|
429
|
-
ui: {}
|
|
430
|
-
}, {
|
|
431
|
-
open: {
|
|
432
|
-
type: Boolean,
|
|
433
|
-
default: void 0
|
|
434
|
-
},
|
|
435
|
-
openModifiers: {}
|
|
436
|
-
}),
|
|
437
|
-
emits: /*@__PURE__*/ g(["close:prevent"], ["update:open"]),
|
|
438
|
-
setup(e, { emit: t }) {
|
|
439
|
-
let n = e, r = t, i = F(e, "open"), s = E(i.value ?? n.defaultOpen ?? !1);
|
|
440
|
-
z(i, (e) => {
|
|
441
|
-
e !== void 0 && (s.value = e);
|
|
442
|
-
});
|
|
443
|
-
function l(e) {
|
|
444
|
-
s.value = e, i.value = e;
|
|
445
|
-
}
|
|
446
|
-
function u() {
|
|
447
|
-
p = !1, l(!1);
|
|
448
|
-
}
|
|
449
|
-
let f = {
|
|
450
|
-
side: "bottom",
|
|
451
|
-
sideOffset: 8,
|
|
452
|
-
collisionPadding: 8
|
|
453
|
-
}, p = !1, m = !1, h, g;
|
|
454
|
-
function v(e) {
|
|
455
|
-
n.mode === "hover" && e.pointerType === "mouse" && (clearTimeout(g), clearTimeout(h), h = setTimeout(() => l(!0), n.openDelay));
|
|
456
|
-
}
|
|
457
|
-
function b(e) {
|
|
458
|
-
n.mode !== "hover" || e.pointerType !== "mouse" || p || (clearTimeout(h), g = setTimeout(() => l(!1), Math.max(n.closeDelay, 100)));
|
|
459
|
-
}
|
|
460
|
-
function x() {
|
|
461
|
-
n.mode === "hover" && (m = s.value && !p);
|
|
462
|
-
}
|
|
463
|
-
S(() => {
|
|
464
|
-
clearTimeout(h), clearTimeout(g);
|
|
465
|
-
});
|
|
466
|
-
function C(e) {
|
|
467
|
-
if (n.mode === "hover") {
|
|
468
|
-
if (!e && m) {
|
|
469
|
-
m = !1, p = !0;
|
|
470
|
-
return;
|
|
471
|
-
}
|
|
472
|
-
m = !1, p = e;
|
|
473
|
-
}
|
|
474
|
-
l(e);
|
|
475
|
-
}
|
|
476
|
-
let T = 0;
|
|
477
|
-
function D(e) {
|
|
478
|
-
if (n.dismissible) return;
|
|
479
|
-
e.preventDefault();
|
|
480
|
-
let t = performance.now();
|
|
481
|
-
t - T > 50 && r("close:prevent"), T = t;
|
|
482
|
-
}
|
|
483
|
-
function k(e) {
|
|
484
|
-
n.mode === "hover" && e.preventDefault();
|
|
485
|
-
}
|
|
486
|
-
let A = () => typeof n.portal == "string" || n.portal instanceof HTMLElement ? n.portal : void 0;
|
|
487
|
-
return (t, n) => (w(), a(M(Nt), {
|
|
488
|
-
open: s.value,
|
|
489
|
-
modal: e.modal,
|
|
490
|
-
"onUpdate:open": C
|
|
491
|
-
}, {
|
|
492
|
-
default: V(() => [
|
|
493
|
-
t.$slots.anchor ? (w(), a(M(kt), {
|
|
494
|
-
key: 0,
|
|
495
|
-
"as-child": ""
|
|
496
|
-
}, {
|
|
497
|
-
default: V(() => [O(t.$slots, "anchor")]),
|
|
498
|
-
_: 3
|
|
499
|
-
})) : o("", !0),
|
|
500
|
-
t.$slots.default ? (w(), a(M(Pt), {
|
|
501
|
-
key: 1,
|
|
502
|
-
"as-child": "",
|
|
503
|
-
onPointerdown: x,
|
|
504
|
-
onPointerenter: v,
|
|
505
|
-
onPointerleave: b
|
|
506
|
-
}, {
|
|
507
|
-
default: V(() => [O(t.$slots, "default")]),
|
|
508
|
-
_: 3
|
|
509
|
-
})) : o("", !0),
|
|
510
|
-
d(M(Mt), {
|
|
511
|
-
disabled: e.portal === !1,
|
|
512
|
-
to: A()
|
|
513
|
-
}, {
|
|
514
|
-
default: V(() => [d(M(jt), _({
|
|
515
|
-
...f,
|
|
516
|
-
...e.content
|
|
517
|
-
}, {
|
|
518
|
-
class: M(X)(M(ur), e.ui?.content),
|
|
519
|
-
onPointerenter: v,
|
|
520
|
-
onPointerleave: b,
|
|
521
|
-
onEscapeKeyDown: D,
|
|
522
|
-
onInteractOutside: D,
|
|
523
|
-
onOpenAutoFocus: k,
|
|
524
|
-
onCloseAutoFocus: k
|
|
525
|
-
}), {
|
|
526
|
-
default: V(() => [O(t.$slots, "content", { close: u }), e.arrow ? (w(), a(M(At), _({ key: 0 }, typeof e.arrow == "object" ? e.arrow : {}, { "as-child": "" }), {
|
|
527
|
-
default: V(() => [c("span", { class: y(M(X)(M(dr), e.ui?.arrow)) }, null, 2)]),
|
|
528
|
-
_: 1
|
|
529
|
-
}, 16)) : o("", !0)]),
|
|
530
|
-
_: 3
|
|
531
|
-
}, 16, ["class"])]),
|
|
532
|
-
_: 3
|
|
533
|
-
}, 8, ["disabled", "to"])
|
|
534
|
-
]),
|
|
535
|
-
_: 3
|
|
536
|
-
}, 8, ["open", "modal"]));
|
|
537
|
-
}
|
|
538
|
-
}), pr = ["aria-label"], mr = [
|
|
630
|
+
// src/components/Avatar/Avatar.vue?vue&type=script&setup=true&lang.ts
|
|
631
|
+
var Ar = ["aria-label"], jr = [
|
|
539
632
|
"src",
|
|
540
633
|
"width",
|
|
541
634
|
"height"
|
|
542
|
-
],
|
|
635
|
+
], Mr = {
|
|
543
636
|
key: 1,
|
|
544
637
|
"aria-hidden": "true"
|
|
545
|
-
},
|
|
638
|
+
}, Nr = { class: "flex flex-col" }, Pr = {
|
|
546
639
|
key: 0,
|
|
547
640
|
class: "truncate px-4 pt-3 text-xs font-bold text-black/65 uppercase"
|
|
548
|
-
},
|
|
641
|
+
}, Fr = { class: "flex items-center gap-3 px-4 py-3" }, Ir = [
|
|
549
642
|
"src",
|
|
550
643
|
"width",
|
|
551
644
|
"height"
|
|
552
|
-
],
|
|
645
|
+
], Lr = { class: "flex min-w-0 flex-col" }, Rr = { class: "truncate font-bold" }, zr = {
|
|
553
646
|
key: 0,
|
|
554
647
|
class: "truncate text-sm text-black/65"
|
|
555
|
-
},
|
|
648
|
+
}, Br = ["href"], Vr = [
|
|
556
649
|
"role",
|
|
557
650
|
"aria-label",
|
|
558
651
|
"aria-hidden"
|
|
559
|
-
],
|
|
652
|
+
], Hr = [
|
|
560
653
|
"src",
|
|
561
654
|
"width",
|
|
562
655
|
"height"
|
|
563
|
-
],
|
|
656
|
+
], Ur = {
|
|
564
657
|
key: 1,
|
|
565
658
|
"aria-hidden": "true"
|
|
566
|
-
},
|
|
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({
|
|
567
660
|
__name: "Avatar",
|
|
568
661
|
props: {
|
|
569
662
|
user: {},
|
|
@@ -579,7 +672,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
579
672
|
] }
|
|
580
673
|
},
|
|
581
674
|
setup(e) {
|
|
582
|
-
let t = e, r = i(() =>
|
|
675
|
+
let t = e, r = i(() => kr(t.user.name)), l = E(!1);
|
|
583
676
|
z(() => t.user.avatar, () => l.value = !1);
|
|
584
677
|
let d = i(() => !!t.user.avatar && !l.value), f = i(() => d.value || !r.value ? t.user.name : `${r.value}, ${t.user.name}`), p = {
|
|
585
678
|
xs: "size-5 text-xs",
|
|
@@ -594,7 +687,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
594
687
|
lg: 48,
|
|
595
688
|
xl: 64
|
|
596
689
|
};
|
|
597
|
-
return (i, h) => e.profile ? (w(), a(
|
|
690
|
+
return (i, h) => e.profile ? (w(), a(er, {
|
|
598
691
|
key: 0,
|
|
599
692
|
mode: "hover",
|
|
600
693
|
"open-delay": 300,
|
|
@@ -606,8 +699,8 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
606
699
|
},
|
|
607
700
|
ui: { content: "w-64" }
|
|
608
701
|
}, {
|
|
609
|
-
content: V(() => [c("div",
|
|
610
|
-
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)),
|
|
611
704
|
"aria-hidden": "true"
|
|
612
705
|
}, [d.value ? (w(), s("img", {
|
|
613
706
|
key: 0,
|
|
@@ -618,19 +711,19 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
618
711
|
decoding: "async",
|
|
619
712
|
alt: "",
|
|
620
713
|
class: "size-full object-cover"
|
|
621
|
-
}, null, 8,
|
|
622
|
-
c("span",
|
|
623
|
-
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),
|
|
624
717
|
e.user.email ? (w(), s("a", {
|
|
625
718
|
key: 1,
|
|
626
719
|
href: `mailto:${e.user.email}`,
|
|
627
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"
|
|
628
|
-
}, j(e.user.email), 9,
|
|
721
|
+
}, j(e.user.email), 9, Br)) : o("", !0)
|
|
629
722
|
])])])]),
|
|
630
723
|
default: V(() => [c("button", {
|
|
631
724
|
type: "button",
|
|
632
725
|
"aria-label": f.value,
|
|
633
|
-
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))
|
|
634
727
|
}, [d.value ? (w(), s("img", {
|
|
635
728
|
key: 0,
|
|
636
729
|
src: e.user.avatar,
|
|
@@ -641,14 +734,14 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
641
734
|
alt: "",
|
|
642
735
|
class: "size-full object-cover",
|
|
643
736
|
onError: h[0] ||= (e) => l.value = !0
|
|
644
|
-
}, null, 40,
|
|
737
|
+
}, null, 40, jr)) : (w(), s("span", Mr, j(r.value), 1))], 10, Ar)]),
|
|
645
738
|
_: 1
|
|
646
739
|
})) : (w(), s("span", {
|
|
647
740
|
key: 1,
|
|
648
741
|
role: e.decorative ? void 0 : "img",
|
|
649
742
|
"aria-label": e.decorative ? void 0 : e.user.name,
|
|
650
743
|
"aria-hidden": e.decorative || void 0,
|
|
651
|
-
class: y(M(X)(
|
|
744
|
+
class: y(M(X)(Wr, p[e.size], t.class))
|
|
652
745
|
}, [d.value ? (w(), s("img", {
|
|
653
746
|
key: 0,
|
|
654
747
|
src: e.user.avatar,
|
|
@@ -659,15 +752,15 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
659
752
|
alt: "",
|
|
660
753
|
class: "size-full object-cover",
|
|
661
754
|
onError: h[1] ||= (e) => l.value = !0
|
|
662
|
-
}, null, 40,
|
|
755
|
+
}, null, 40, Hr)) : (w(), s("span", Ur, j(r.value), 1))], 10, Vr));
|
|
663
756
|
}
|
|
664
|
-
}),
|
|
757
|
+
}), Kr = { class: "flex flex-col" }, qr = {
|
|
665
758
|
key: 0,
|
|
666
759
|
class: "border-b border-black/15"
|
|
667
|
-
},
|
|
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 = {
|
|
668
761
|
key: 1,
|
|
669
762
|
class: "flex items-center gap-2 border-t border-black/15 px-4 py-3"
|
|
670
|
-
},
|
|
763
|
+
}, ei = /* @__PURE__ */ f({
|
|
671
764
|
__name: "Header",
|
|
672
765
|
props: {
|
|
673
766
|
title: {},
|
|
@@ -714,7 +807,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
714
807
|
"sign-in"
|
|
715
808
|
],
|
|
716
809
|
setup(e, { emit: t }) {
|
|
717
|
-
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", {
|
|
718
811
|
initials: f.value,
|
|
719
812
|
name: r.user.name
|
|
720
813
|
}) : ""), m = i(() => {
|
|
@@ -735,7 +828,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
735
828
|
class: y(M(X)("-ml-2.5", e.ui?.menu)),
|
|
736
829
|
onClick: i[0] ||= (e) => l("menu")
|
|
737
830
|
}, {
|
|
738
|
-
default: V(() => [d(M(
|
|
831
|
+
default: V(() => [d(M(Ae))]),
|
|
739
832
|
_: 1
|
|
740
833
|
}, 8, [
|
|
741
834
|
"aria-label",
|
|
@@ -752,43 +845,43 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
752
845
|
t.$slots.trailing || t.$slots.account || e.user || e.signIn ? (w(), s("div", {
|
|
753
846
|
key: 2,
|
|
754
847
|
class: y(M(X)("flex shrink-0 items-center gap-1", e.ui?.trailing))
|
|
755
|
-
}, [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, {
|
|
756
849
|
key: 0,
|
|
757
850
|
content: { align: "end" },
|
|
758
851
|
ui: { content: M(X)("w-80", e.ui?.userMenu) }
|
|
759
852
|
}, {
|
|
760
|
-
content: V(({ close: n }) => [c("div",
|
|
761
|
-
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", {
|
|
762
855
|
class: "truncate px-4 py-3 text-xs font-bold text-black/65 uppercase",
|
|
763
856
|
title: e.user.organisation
|
|
764
|
-
}, j(e.user.organisation), 9,
|
|
765
|
-
c("div",
|
|
766
|
-
d(
|
|
857
|
+
}, j(e.user.organisation), 9, Jr)])])) : o("", !0),
|
|
858
|
+
c("div", Yr, [
|
|
859
|
+
d(Gr, {
|
|
767
860
|
user: e.user,
|
|
768
861
|
size: "lg",
|
|
769
862
|
decorative: ""
|
|
770
863
|
}, null, 8, ["user"]),
|
|
771
|
-
c("div",
|
|
864
|
+
c("div", Xr, [c("span", {
|
|
772
865
|
class: "truncate font-bold",
|
|
773
866
|
title: e.user.name
|
|
774
|
-
}, j(e.user.name), 9,
|
|
867
|
+
}, j(e.user.name), 9, Zr), e.user.email ? (w(), s("span", {
|
|
775
868
|
key: 0,
|
|
776
869
|
class: "truncate text-sm text-black/65",
|
|
777
870
|
title: e.user.email
|
|
778
|
-
}, j(e.user.email), 9,
|
|
871
|
+
}, j(e.user.email), 9, Qr)) : o("", !0)]),
|
|
779
872
|
e.userActions.includes("account-settings") ? (w(), a(Z, {
|
|
780
873
|
key: 0,
|
|
781
874
|
size: "sm",
|
|
782
875
|
class: "col-start-2 justify-self-start",
|
|
783
876
|
onClick: (e) => g("account-settings", n)
|
|
784
877
|
}, {
|
|
785
|
-
leading: V(() => [d(M(
|
|
878
|
+
leading: V(() => [d(M(Ie))]),
|
|
786
879
|
default: V(() => [i[2] ||= u(" Account settings ", -1)]),
|
|
787
880
|
_: 1
|
|
788
881
|
}, 8, ["onClick"])) : o("", !0)
|
|
789
882
|
]),
|
|
790
883
|
O(t.$slots, "account-menu", { close: n }),
|
|
791
|
-
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, {
|
|
792
885
|
key: 0,
|
|
793
886
|
onClick: (e) => g("switch-account", n)
|
|
794
887
|
}, {
|
|
@@ -800,7 +893,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
800
893
|
class: "ml-auto",
|
|
801
894
|
onClick: (e) => g("log-out", n)
|
|
802
895
|
}, {
|
|
803
|
-
leading: V(() => [d(M(
|
|
896
|
+
leading: V(() => [d(M(ke))]),
|
|
804
897
|
default: V(() => [i[4] ||= u(" Log out ", -1)]),
|
|
805
898
|
_: 1
|
|
806
899
|
}, 8, ["onClick"])) : o("", !0)])) : o("", !0)
|
|
@@ -811,7 +904,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
811
904
|
"aria-label": p.value,
|
|
812
905
|
class: "-mr-1.5 rounded-full"
|
|
813
906
|
}, {
|
|
814
|
-
default: V(() => [d(
|
|
907
|
+
default: V(() => [d(Gr, {
|
|
815
908
|
user: e.user,
|
|
816
909
|
size: "sm",
|
|
817
910
|
decorative: ""
|
|
@@ -830,7 +923,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
830
923
|
})) : o("", !0)])], 2)) : o("", !0)
|
|
831
924
|
], 2));
|
|
832
925
|
}
|
|
833
|
-
}),
|
|
926
|
+
}), ti = "inline-flex shrink-0 items-center whitespace-nowrap rounded-full border border-black/15 font-bold", ni = /* @__PURE__ */ f({
|
|
834
927
|
__name: "Badge",
|
|
835
928
|
props: {
|
|
836
929
|
color: { default: "basic" },
|
|
@@ -856,7 +949,7 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
856
949
|
md: "h-6 px-2 text-xs gap-1 [&_svg]:size-3.5",
|
|
857
950
|
lg: "h-7 px-2.5 text-sm gap-1.5 [&_svg]:size-4"
|
|
858
951
|
};
|
|
859
|
-
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)) }, [
|
|
860
953
|
O(i.$slots, "leading"),
|
|
861
954
|
O(i.$slots, "default"),
|
|
862
955
|
O(i.$slots, "trailing")
|
|
@@ -864,27 +957,27 @@ var ur = ["z-50 rounded border border-black/15 bg-white text-black shadow-md out
|
|
|
864
957
|
}
|
|
865
958
|
});
|
|
866
959
|
// src/components/Sidebar/sidebar.ts
|
|
867
|
-
function
|
|
960
|
+
function ri(e = [], t = []) {
|
|
868
961
|
for (let n of [...e, ...t.flatMap((e) => e.items)]) {
|
|
869
962
|
if (n.active) return [n];
|
|
870
963
|
if (n.children?.length) {
|
|
871
|
-
let e =
|
|
964
|
+
let e = ri(n.children);
|
|
872
965
|
if (e.length) return [n, ...e];
|
|
873
966
|
}
|
|
874
967
|
}
|
|
875
968
|
return [];
|
|
876
969
|
}
|
|
877
970
|
// src/components/Sidebar/Sidebar.vue?vue&type=script&setup=true&lang.ts
|
|
878
|
-
var
|
|
971
|
+
var ii = ["data-collapsed"], ai = ["aria-label"], oi = ["data-level"], si = {
|
|
879
972
|
key: 0,
|
|
880
973
|
class: "-mb-2 flex flex-col gap-1 border-b border-black/15 pb-2"
|
|
881
|
-
},
|
|
974
|
+
}, ci = ["title"], li = {
|
|
882
975
|
key: 0,
|
|
883
976
|
class: "relative flex h-6 items-center px-3"
|
|
884
|
-
},
|
|
977
|
+
}, ui = ["id"], di = ["aria-labelledby"], fi = {
|
|
885
978
|
key: 0,
|
|
886
979
|
class: "sr-only"
|
|
887
|
-
},
|
|
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({
|
|
888
981
|
__name: "Sidebar",
|
|
889
982
|
props: /*@__PURE__*/ g({
|
|
890
983
|
items: { default: () => [] },
|
|
@@ -920,7 +1013,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
920
1013
|
e.push(r), t = r.children;
|
|
921
1014
|
}
|
|
922
1015
|
return e;
|
|
923
|
-
}), 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)));
|
|
924
1017
|
z(() => T.value.map((e) => e.label).join("\0"), () => {
|
|
925
1018
|
b.value = T.value.slice(0, -1).map((e) => e.label);
|
|
926
1019
|
}, { immediate: !0 });
|
|
@@ -965,10 +1058,10 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
965
1058
|
"aria-disabled": !0
|
|
966
1059
|
} : e.to === void 0 ? { href: e.href } : { to: e.to };
|
|
967
1060
|
}
|
|
968
|
-
function
|
|
1061
|
+
function q(e, t) {
|
|
969
1062
|
e.disabled ? t.preventDefault() : e.children?.length ? U(e) : (e.onSelect?.(t), p("select", e, t));
|
|
970
1063
|
}
|
|
971
|
-
let
|
|
1064
|
+
let J = [
|
|
972
1065
|
"flex h-9.5 w-full items-center gap-3 overflow-hidden rounded px-3 text-left text-sm whitespace-nowrap select-none",
|
|
973
1066
|
"cursor-pointer transition [&_svg]:size-4 [&_svg]:shrink-0",
|
|
974
1067
|
"outline-2 -outline-offset-2 outline-transparent forced-colors:not-focus-visible:outline-0",
|
|
@@ -994,21 +1087,21 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
994
1087
|
key: N.value,
|
|
995
1088
|
"data-level": N.value,
|
|
996
1089
|
class: "flex flex-col gap-4"
|
|
997
|
-
}, [S.value ? (w(), s("div",
|
|
1090
|
+
}, [S.value ? (w(), s("div", si, [c("button", {
|
|
998
1091
|
type: "button",
|
|
999
1092
|
"data-back": "",
|
|
1000
1093
|
title: m.value ? M(l)("ui.sidebar.backFrom", { name: S.value.label }) : void 0,
|
|
1001
|
-
class: y(M(X)(
|
|
1094
|
+
class: y(M(X)(J, "font-bold", e.ui?.item)),
|
|
1002
1095
|
onClick: ee
|
|
1003
|
-
}, [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", {
|
|
1004
1097
|
key: i,
|
|
1005
1098
|
class: "flex flex-col gap-1"
|
|
1006
|
-
}, [r.label ? (w(), s("div",
|
|
1099
|
+
}, [r.label ? (w(), s("div", li, [c("div", {
|
|
1007
1100
|
id: `${M(h)}-section-${i}`,
|
|
1008
|
-
class: y(M(X)("truncate text-xs font-bold text-black/65 uppercase",
|
|
1009
|
-
}, 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", {
|
|
1010
1103
|
"aria-hidden": "true",
|
|
1011
|
-
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"))
|
|
1012
1105
|
}, null, 2)])) : o("", !0), c("ul", {
|
|
1013
1106
|
class: "flex flex-col gap-1",
|
|
1014
1107
|
"aria-labelledby": r.label ? `${M(h)}-section-${i}` : void 0
|
|
@@ -1017,8 +1110,8 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1017
1110
|
"data-parent": n.children?.length ? n.label : void 0,
|
|
1018
1111
|
"aria-current": n.active ? "page" : void 0,
|
|
1019
1112
|
title: m.value ? n.label : void 0,
|
|
1020
|
-
class: M(X)(
|
|
1021
|
-
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)
|
|
1022
1115
|
}), {
|
|
1023
1116
|
default: V(() => [O(t.$slots, "item", {
|
|
1024
1117
|
item: n,
|
|
@@ -1029,20 +1122,20 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1029
1122
|
key: 0,
|
|
1030
1123
|
"aria-hidden": "true"
|
|
1031
1124
|
})) : o("", !0),
|
|
1032
|
-
c("span", { class: y(M(X)("min-w-0 flex-1 truncate",
|
|
1033
|
-
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, {
|
|
1034
1127
|
key: 1,
|
|
1035
1128
|
size: "sm",
|
|
1036
1129
|
color: n.badgeColor,
|
|
1037
|
-
class: y(M(X)(
|
|
1130
|
+
class: y(M(X)(pi, m.value && "opacity-0"))
|
|
1038
1131
|
}, {
|
|
1039
1132
|
default: V(() => [u(j(n.badge), 1)]),
|
|
1040
1133
|
_: 2
|
|
1041
1134
|
}, 1032, ["color", "class"])) : o("", !0),
|
|
1042
|
-
n.children?.length ? (w(), a(M(
|
|
1135
|
+
n.children?.length ? (w(), a(M(me), {
|
|
1043
1136
|
key: 2,
|
|
1044
1137
|
"aria-hidden": "true",
|
|
1045
|
-
class: y(M(X)("opacity-70",
|
|
1138
|
+
class: y(M(X)("opacity-70", pi, m.value && "opacity-0"))
|
|
1046
1139
|
}, null, 8, ["class"])) : o("", !0)
|
|
1047
1140
|
])]),
|
|
1048
1141
|
_: 2
|
|
@@ -1052,9 +1145,9 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1052
1145
|
"title",
|
|
1053
1146
|
"class",
|
|
1054
1147
|
"onClick"
|
|
1055
|
-
]))]))), 128))], 8,
|
|
1148
|
+
]))]))), 128))], 8, di)]))), 128))], 8, oi))]),
|
|
1056
1149
|
_: 3
|
|
1057
|
-
}, 16)], 10,
|
|
1150
|
+
}, 16)], 10, ai),
|
|
1058
1151
|
t.$slots.footer || e.collapsible ? (w(), s("div", {
|
|
1059
1152
|
key: 1,
|
|
1060
1153
|
class: y(M(X)("flex shrink-0 flex-col gap-1 overflow-hidden border-t border-black/15 p-2", e.ui?.footer))
|
|
@@ -1067,12 +1160,12 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1067
1160
|
class: "self-start",
|
|
1068
1161
|
onClick: i[0] ||= (e) => m.value = !m.value
|
|
1069
1162
|
}, {
|
|
1070
|
-
default: V(() => [m.value ? (w(), a(M(
|
|
1163
|
+
default: V(() => [m.value ? (w(), a(M(Pe), { key: 0 })) : (w(), a(M(Ne), { key: 1 }))]),
|
|
1071
1164
|
_: 1
|
|
1072
1165
|
}, 8, ["aria-label", "aria-expanded"])) : o("", !0)], 2)) : o("", !0)
|
|
1073
|
-
], 10,
|
|
1166
|
+
], 10, ii));
|
|
1074
1167
|
}
|
|
1075
|
-
}),
|
|
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({
|
|
1076
1169
|
__name: "Progress",
|
|
1077
1170
|
props: {
|
|
1078
1171
|
value: { default: null },
|
|
@@ -1092,23 +1185,23 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1092
1185
|
current: l.value,
|
|
1093
1186
|
total: r.max
|
|
1094
1187
|
}) : `${Math.round(u.value)}%`;
|
|
1095
|
-
return (t, i) => (w(), a(M(
|
|
1188
|
+
return (t, i) => (w(), a(M(Wt), {
|
|
1096
1189
|
"model-value": o.value ? null : l.value,
|
|
1097
1190
|
max: e.max,
|
|
1098
1191
|
"get-value-label": () => e.label,
|
|
1099
1192
|
"get-value-text": d,
|
|
1100
1193
|
"aria-busy": o.value || void 0,
|
|
1101
|
-
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))
|
|
1102
1195
|
}, {
|
|
1103
1196
|
default: V(() => [e.segments && !o.value ? (w(!0), s(n, { key: 0 }, D(e.max, (e) => (w(), s("div", {
|
|
1104
1197
|
key: e,
|
|
1105
|
-
class: y(M(X)(
|
|
1106
|
-
}, [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), {
|
|
1107
1200
|
key: 1,
|
|
1108
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"
|
|
1109
|
-
})) : (w(), a(M(
|
|
1202
|
+
})) : (w(), a(M(Ut), {
|
|
1110
1203
|
key: 2,
|
|
1111
|
-
class: y(
|
|
1204
|
+
class: y(vi),
|
|
1112
1205
|
style: x({ translate: `${u.value - 100}% 0` })
|
|
1113
1206
|
}, null, 8, ["style"]))]),
|
|
1114
1207
|
_: 1
|
|
@@ -1120,14 +1213,14 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1120
1213
|
"class"
|
|
1121
1214
|
]));
|
|
1122
1215
|
}
|
|
1123
|
-
}),
|
|
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 = {
|
|
1124
1217
|
key: 1,
|
|
1125
1218
|
class: "sr-only"
|
|
1126
|
-
},
|
|
1219
|
+
}, Ti = {
|
|
1127
1220
|
key: 1,
|
|
1128
1221
|
"aria-live": "polite",
|
|
1129
1222
|
class: "sr-only"
|
|
1130
|
-
},
|
|
1223
|
+
}, Ei = ["role", "aria-labelledby"], Di = "textarea, [contenteditable=\"true\"], input[type=checkbox], input[type=radio], input[type=button], input[type=submit]", Oi = /* @__PURE__ */ f({
|
|
1131
1224
|
__name: "Slideover",
|
|
1132
1225
|
props: /*@__PURE__*/ g({
|
|
1133
1226
|
title: {},
|
|
@@ -1208,7 +1301,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1208
1301
|
}
|
|
1209
1302
|
function L(e) {
|
|
1210
1303
|
let t = e.target;
|
|
1211
|
-
!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());
|
|
1212
1305
|
}
|
|
1213
1306
|
let R = 0;
|
|
1214
1307
|
function B(e) {
|
|
@@ -1234,32 +1327,32 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1234
1327
|
let n = t.querySelector("[autofocus], [data-autofocus]"), i = window.matchMedia("(pointer: coarse)").matches ? null : t.querySelector(H), a = n ?? i;
|
|
1235
1328
|
a && (e.preventDefault(), a.focus());
|
|
1236
1329
|
}
|
|
1237
|
-
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 = {
|
|
1238
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",
|
|
1239
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",
|
|
1240
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",
|
|
1241
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"
|
|
1242
|
-
},
|
|
1243
|
-
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), {
|
|
1244
1337
|
open: m.value,
|
|
1245
1338
|
modal: e.modal,
|
|
1246
1339
|
"onUpdate:open": h
|
|
1247
1340
|
}, {
|
|
1248
|
-
default: V(() => [t.$slots.default ? (w(), a(M(
|
|
1341
|
+
default: V(() => [t.$slots.default ? (w(), a(M(wt), {
|
|
1249
1342
|
key: 0,
|
|
1250
1343
|
"as-child": ""
|
|
1251
1344
|
}, {
|
|
1252
1345
|
default: V(() => [O(t.$slots, "default")]),
|
|
1253
1346
|
_: 3
|
|
1254
|
-
})) : o("", !0), d(M(
|
|
1347
|
+
})) : o("", !0), d(M(xt), {
|
|
1255
1348
|
disabled: e.portal === !1,
|
|
1256
1349
|
to: G()
|
|
1257
1350
|
}, {
|
|
1258
|
-
default: V(() => [e.overlay ? (w(), a(M(
|
|
1351
|
+
default: V(() => [e.overlay ? (w(), a(M(bt), {
|
|
1259
1352
|
key: 0,
|
|
1260
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))
|
|
1261
|
-
}, null, 8, ["class"])) : o("", !0), d(M(
|
|
1262
|
-
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),
|
|
1263
1356
|
onEscapeKeyDown: B,
|
|
1264
1357
|
onInteractOutside: B,
|
|
1265
1358
|
onOpenAutoFocus: W
|
|
@@ -1273,8 +1366,8 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1273
1366
|
key: 0,
|
|
1274
1367
|
id: T,
|
|
1275
1368
|
class: "text-sm text-black/65"
|
|
1276
|
-
}, [u(" Step " + j(b.value + 1) + " of " + j(x.value) + ": ", 1), c("span",
|
|
1277
|
-
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, {
|
|
1278
1371
|
key: 1,
|
|
1279
1372
|
label: e.title ?? M(n)("ui.slideover.steps"),
|
|
1280
1373
|
segments: "",
|
|
@@ -1285,21 +1378,21 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1285
1378
|
"value",
|
|
1286
1379
|
"max"
|
|
1287
1380
|
])) : o("", !0),
|
|
1288
|
-
c("div",
|
|
1289
|
-
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") }, {
|
|
1290
1383
|
default: V(() => [O(t.$slots, "title", {}, () => [u(j(e.title), 1)])]),
|
|
1291
1384
|
_: 3
|
|
1292
1385
|
}, 8, ["class"]),
|
|
1293
|
-
e.description || t.$slots.description || e.steps ? (w(), a(M(
|
|
1386
|
+
e.description || t.$slots.description || e.steps ? (w(), a(M(yt), {
|
|
1294
1387
|
key: 0,
|
|
1295
1388
|
as: "div",
|
|
1296
1389
|
class: "flex flex-col gap-1 text-sm text-black/65"
|
|
1297
1390
|
}, {
|
|
1298
|
-
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)]),
|
|
1299
1392
|
_: 3
|
|
1300
1393
|
})) : o("", !0),
|
|
1301
|
-
e.steps ? (w(), s("p",
|
|
1302
|
-
]), 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), {
|
|
1303
1396
|
key: 0,
|
|
1304
1397
|
"as-child": ""
|
|
1305
1398
|
}, {
|
|
@@ -1309,7 +1402,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1309
1402
|
"aria-label": M(n)("ui.slideover.close"),
|
|
1310
1403
|
class: "-my-1.5 -mr-3 shrink-0"
|
|
1311
1404
|
}, {
|
|
1312
|
-
default: V(() => [d(M(
|
|
1405
|
+
default: V(() => [d(M(Ve))]),
|
|
1313
1406
|
_: 1
|
|
1314
1407
|
}, 8, ["aria-label"])]),
|
|
1315
1408
|
_: 1
|
|
@@ -1325,7 +1418,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1325
1418
|
}, [O(t.$slots, "body", {
|
|
1326
1419
|
close: g,
|
|
1327
1420
|
step: b.value
|
|
1328
|
-
})], 42,
|
|
1421
|
+
})], 42, Ei),
|
|
1329
1422
|
t.$slots.footer || e.steps ? (w(), s("footer", {
|
|
1330
1423
|
key: 1,
|
|
1331
1424
|
class: y(M(X)("flex justify-end gap-2 border-t border-black/15 px-6 py-4", e.ui?.footer))
|
|
@@ -1338,7 +1431,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1338
1431
|
_: 2
|
|
1339
1432
|
}, [b.value > 0 ? {
|
|
1340
1433
|
name: "leading",
|
|
1341
|
-
fn: V(() => [d(M(
|
|
1434
|
+
fn: V(() => [d(M(pe))]),
|
|
1342
1435
|
key: "0"
|
|
1343
1436
|
} : void 0]), 1032, ["disabled"]), d(Z, {
|
|
1344
1437
|
variant: "primary",
|
|
@@ -1349,7 +1442,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1349
1442
|
_: 2
|
|
1350
1443
|
}, [S.value ? void 0 : {
|
|
1351
1444
|
name: "trailing",
|
|
1352
|
-
fn: V(() => [d(M(
|
|
1445
|
+
fn: V(() => [d(M(me))]),
|
|
1353
1446
|
key: "0"
|
|
1354
1447
|
}]), 1032, ["status"])])], 2)) : o("", !0)
|
|
1355
1448
|
])]),
|
|
@@ -1360,7 +1453,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1360
1453
|
_: 3
|
|
1361
1454
|
}, 8, ["open", "modal"]));
|
|
1362
1455
|
}
|
|
1363
|
-
}),
|
|
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({
|
|
1364
1457
|
__name: "AppShell",
|
|
1365
1458
|
props: /*@__PURE__*/ g({
|
|
1366
1459
|
title: {},
|
|
@@ -1378,6 +1471,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1378
1471
|
default: !0
|
|
1379
1472
|
},
|
|
1380
1473
|
footer: {},
|
|
1474
|
+
launcher: { type: [Boolean, Object] },
|
|
1381
1475
|
linkComponent: {},
|
|
1382
1476
|
header: {},
|
|
1383
1477
|
sidebar: {},
|
|
@@ -1415,7 +1509,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1415
1509
|
f = window.matchMedia("(min-width: 64rem)"), f.addEventListener("change", m);
|
|
1416
1510
|
}), S(() => f?.removeEventListener("change", m));
|
|
1417
1511
|
let h = P(), g = `${h}-main`, v = `${h}-sidebar`;
|
|
1418
|
-
return (t, f) => (w(), a(M(
|
|
1512
|
+
return (t, f) => (w(), a(M(yn), {
|
|
1419
1513
|
"delay-duration": 400,
|
|
1420
1514
|
"skip-delay-duration": 300
|
|
1421
1515
|
}, {
|
|
@@ -1423,8 +1517,8 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1423
1517
|
c("a", {
|
|
1424
1518
|
href: `#${g}`,
|
|
1425
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"
|
|
1426
|
-
}, " Skip to content ", 8,
|
|
1427
|
-
d(
|
|
1520
|
+
}, " Skip to content ", 8, ki),
|
|
1521
|
+
d(ei, _(e.header, {
|
|
1428
1522
|
title: e.title,
|
|
1429
1523
|
"title-to": e.titleTo,
|
|
1430
1524
|
"link-component": e.linkComponent,
|
|
@@ -1454,15 +1548,15 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1454
1548
|
class: "-ml-2.5 max-lg:hidden",
|
|
1455
1549
|
onClick: f[0] ||= (e) => s.value = !s.value
|
|
1456
1550
|
}, {
|
|
1457
|
-
default: V(() => [d(M(
|
|
1551
|
+
default: V(() => [d(M(Ae))]),
|
|
1458
1552
|
_: 1
|
|
1459
1553
|
}, 8, ["aria-label", "aria-expanded"])) : o("", !0), O(t.$slots, "header-leading")]),
|
|
1460
1554
|
default: V(() => [O(t.$slots, "header-middle")]),
|
|
1461
1555
|
_: 2
|
|
1462
1556
|
}, [
|
|
1463
|
-
t.$slots["header-trailing"] ? {
|
|
1557
|
+
t.$slots["header-trailing"] || e.launcher ? {
|
|
1464
1558
|
name: "trailing",
|
|
1465
|
-
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)]),
|
|
1466
1560
|
key: "0"
|
|
1467
1561
|
} : void 0,
|
|
1468
1562
|
t.$slots.account ? {
|
|
@@ -1490,8 +1584,8 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1490
1584
|
"sign-in",
|
|
1491
1585
|
"ui"
|
|
1492
1586
|
]),
|
|
1493
|
-
c("div",
|
|
1494
|
-
c("div",
|
|
1587
|
+
c("div", Ai, [
|
|
1588
|
+
c("div", ji, [d(gi, _(e.sidebar, {
|
|
1495
1589
|
id: v,
|
|
1496
1590
|
collapsed: s.value,
|
|
1497
1591
|
"onUpdate:collapsed": f[6] ||= (e) => s.value = e,
|
|
@@ -1512,7 +1606,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1512
1606
|
"sections",
|
|
1513
1607
|
"link-component"
|
|
1514
1608
|
])]),
|
|
1515
|
-
d(
|
|
1609
|
+
d(Oi, {
|
|
1516
1610
|
open: u.value,
|
|
1517
1611
|
"onUpdate:open": f[8] ||= (e) => u.value = e,
|
|
1518
1612
|
side: "left",
|
|
@@ -1524,7 +1618,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1524
1618
|
body: "flex p-0"
|
|
1525
1619
|
}
|
|
1526
1620
|
}, {
|
|
1527
|
-
body: V(() => [d(
|
|
1621
|
+
body: V(() => [d(gi, _(e.sidebar, {
|
|
1528
1622
|
items: e.items,
|
|
1529
1623
|
sections: e.sections,
|
|
1530
1624
|
"link-component": e.linkComponent,
|
|
@@ -1541,11 +1635,11 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1541
1635
|
])]),
|
|
1542
1636
|
_: 3
|
|
1543
1637
|
}, 8, ["open", "title"]),
|
|
1544
|
-
c("div",
|
|
1638
|
+
c("div", Mi, [c("main", {
|
|
1545
1639
|
id: g,
|
|
1546
1640
|
tabindex: "-1",
|
|
1547
1641
|
class: y(M(X)("min-w-0 flex-1 outline-none", e.ui?.main))
|
|
1548
|
-
}, [O(t.$slots, "default")], 2), e.footer ? (w(), a(
|
|
1642
|
+
}, [O(t.$slots, "default")], 2), e.footer ? (w(), a(Or, b(_({ key: 0 }, {
|
|
1549
1643
|
linkComponent: e.linkComponent,
|
|
1550
1644
|
...e.footer
|
|
1551
1645
|
})), null, 16)) : o("", !0)])
|
|
@@ -1554,7 +1648,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1554
1648
|
_: 3
|
|
1555
1649
|
}));
|
|
1556
1650
|
}
|
|
1557
|
-
}),
|
|
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({
|
|
1558
1652
|
__name: "Breadcrumb",
|
|
1559
1653
|
props: {
|
|
1560
1654
|
items: {},
|
|
@@ -1590,29 +1684,29 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1590
1684
|
return (t, l) => (w(), s("nav", {
|
|
1591
1685
|
"aria-label": e.label ?? M(r)("ui.breadcrumb.label"),
|
|
1592
1686
|
class: y(M(X)("min-w-0 text-sm", i.class))
|
|
1593
|
-
}, [c("ol",
|
|
1687
|
+
}, [c("ol", Fi, [(w(!0), s(n, null, D(e.items, (t, n) => (w(), s("li", {
|
|
1594
1688
|
key: `${t.label}-${n}`,
|
|
1595
1689
|
class: "flex min-w-0 items-center gap-1.5"
|
|
1596
1690
|
}, [n === e.items.length - 1 ? (w(), s("span", {
|
|
1597
1691
|
key: 0,
|
|
1598
1692
|
"aria-current": "page",
|
|
1599
1693
|
title: t.label,
|
|
1600
|
-
class: y(M(X)(
|
|
1694
|
+
class: y(M(X)(Vi, "text-black"))
|
|
1601
1695
|
}, [t.icon ? (w(), a(k(t.icon), {
|
|
1602
1696
|
key: 0,
|
|
1603
1697
|
"aria-hidden": "true"
|
|
1604
|
-
})) : o("", !0), c("span",
|
|
1698
|
+
})) : o("", !0), c("span", Li, j(t.label), 1)], 10, Ii)) : u(t) ? (w(), a(k(u(t)), _({
|
|
1605
1699
|
key: 1,
|
|
1606
1700
|
ref_for: !0
|
|
1607
1701
|
}, d(t), {
|
|
1608
1702
|
title: t.label,
|
|
1609
|
-
class: M(X)(
|
|
1703
|
+
class: M(X)(Vi, p),
|
|
1610
1704
|
onClick: (e) => f(t, e)
|
|
1611
1705
|
}), {
|
|
1612
1706
|
default: V(() => [t.icon ? (w(), a(k(t.icon), {
|
|
1613
1707
|
key: 0,
|
|
1614
1708
|
"aria-hidden": "true"
|
|
1615
|
-
})) : o("", !0), c("span",
|
|
1709
|
+
})) : o("", !0), c("span", Ri, j(t.label), 1)]),
|
|
1616
1710
|
_: 2
|
|
1617
1711
|
}, 1040, [
|
|
1618
1712
|
"title",
|
|
@@ -1621,17 +1715,17 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1621
1715
|
])) : (w(), s("span", {
|
|
1622
1716
|
key: 2,
|
|
1623
1717
|
title: t.label,
|
|
1624
|
-
class: y(M(X)(
|
|
1718
|
+
class: y(M(X)(Vi, "text-black/65"))
|
|
1625
1719
|
}, [t.icon ? (w(), a(k(t.icon), {
|
|
1626
1720
|
key: 0,
|
|
1627
1721
|
"aria-hidden": "true"
|
|
1628
|
-
})) : 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), {
|
|
1629
1723
|
key: 3,
|
|
1630
1724
|
"aria-hidden": "true",
|
|
1631
1725
|
class: "size-3.5 shrink-0 text-black/40"
|
|
1632
|
-
})) : o("", !0)]))), 128))])], 10,
|
|
1726
|
+
})) : o("", !0)]))), 128))])], 10, Pi));
|
|
1633
1727
|
}
|
|
1634
|
-
}),
|
|
1728
|
+
}), Ui = /* @__PURE__ */ f({
|
|
1635
1729
|
__name: "Menu",
|
|
1636
1730
|
props: {
|
|
1637
1731
|
items: {},
|
|
@@ -1660,8 +1754,8 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1660
1754
|
"data-highlighted:bg-black/10",
|
|
1661
1755
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
1662
1756
|
];
|
|
1663
|
-
return (l, f) => (w(), a(M(
|
|
1664
|
-
default: V(() => [d(M(
|
|
1757
|
+
return (l, f) => (w(), a(M(Ot), { modal: !1 }, {
|
|
1758
|
+
default: V(() => [d(M(kt), { "as-child": "" }, {
|
|
1665
1759
|
default: V(() => [d(Z, {
|
|
1666
1760
|
variant: "ghost",
|
|
1667
1761
|
square: "",
|
|
@@ -1669,7 +1763,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1669
1763
|
"aria-label": e.label,
|
|
1670
1764
|
class: y(t.class)
|
|
1671
1765
|
}, {
|
|
1672
|
-
default: V(() => [d(M(
|
|
1766
|
+
default: V(() => [d(M(xe))]),
|
|
1673
1767
|
_: 1
|
|
1674
1768
|
}, 8, [
|
|
1675
1769
|
"size",
|
|
@@ -1677,14 +1771,14 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1677
1771
|
"class"
|
|
1678
1772
|
])]),
|
|
1679
1773
|
_: 1
|
|
1680
|
-
}), d(M(
|
|
1681
|
-
default: V(() => [d(M(
|
|
1774
|
+
}), d(M(Dt), null, {
|
|
1775
|
+
default: V(() => [d(M(Tt), {
|
|
1682
1776
|
align: "end",
|
|
1683
1777
|
"side-offset": 4,
|
|
1684
1778
|
"collision-padding": 8,
|
|
1685
|
-
class: y(M(X)(M(
|
|
1779
|
+
class: y(M(X)(M(Qn), "min-w-48 p-1"))
|
|
1686
1780
|
}, {
|
|
1687
|
-
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), _({
|
|
1688
1782
|
key: e.label,
|
|
1689
1783
|
as: r(e)
|
|
1690
1784
|
}, { ref_for: !0 }, i(e), {
|
|
@@ -1709,18 +1803,18 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1709
1803
|
_: 1
|
|
1710
1804
|
}));
|
|
1711
1805
|
}
|
|
1712
|
-
}),
|
|
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 = {
|
|
1713
1807
|
key: 0,
|
|
1714
1808
|
class: "flex shrink-0 items-center gap-2 px-3 text-sm font-bold",
|
|
1715
1809
|
"aria-live": "polite"
|
|
1716
|
-
},
|
|
1810
|
+
}, Yi = {
|
|
1717
1811
|
"aria-hidden": "true",
|
|
1718
1812
|
inert: "",
|
|
1719
1813
|
class: "invisible absolute top-0 left-0 size-0 overflow-hidden"
|
|
1720
|
-
},
|
|
1814
|
+
}, Xi = {
|
|
1721
1815
|
key: 1,
|
|
1722
1816
|
class: "flex shrink-0 items-center gap-2 px-3 text-sm"
|
|
1723
|
-
},
|
|
1817
|
+
}, Zi = /* @__PURE__ */ f({
|
|
1724
1818
|
__name: "PageHeader",
|
|
1725
1819
|
props: {
|
|
1726
1820
|
title: {},
|
|
@@ -1763,12 +1857,12 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1763
1857
|
}), S(() => x?.disconnect()), z(() => r.toolbar?.map((e) => `${e.label}${e.disabled ? "-" : ""}`).join("|"), () => v(b));
|
|
1764
1858
|
let T = i(() => (r.toolbar ?? []).slice(0, _.value)), A = i(() => (r.toolbar ?? []).slice(_.value));
|
|
1765
1859
|
return (i, p) => (w(), s("header", { class: y(M(X)("flex flex-col gap-2", r.class)) }, [
|
|
1766
|
-
e.breadcrumb && e.breadcrumb.length > 1 ? (w(), a(
|
|
1860
|
+
e.breadcrumb && e.breadcrumb.length > 1 ? (w(), a(Hi, {
|
|
1767
1861
|
key: 0,
|
|
1768
1862
|
items: e.breadcrumb,
|
|
1769
1863
|
"link-component": e.linkComponent
|
|
1770
1864
|
}, null, 8, ["items", "link-component"])) : o("", !0),
|
|
1771
|
-
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", {
|
|
1772
1866
|
key: 0,
|
|
1773
1867
|
class: y(M(X)("max-w-prose text-sm text-black/65", e.ui?.description))
|
|
1774
1868
|
}, [O(i.$slots, "description", {}, () => [u(j(e.description), 1)])], 2)) : o("", !0)]), i.$slots.actions ? (w(), s("div", {
|
|
@@ -1781,7 +1875,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1781
1875
|
"aria-label": M(t)("ui.pageHeader.actions", { title: e.title }),
|
|
1782
1876
|
class: y(M(X)("flex items-center gap-1 rounded-lg border border-black/15 bg-white p-1", e.ui?.toolbar))
|
|
1783
1877
|
}, [
|
|
1784
|
-
i.$slots["toolbar-start"] ? (w(), s("div",
|
|
1878
|
+
i.$slots["toolbar-start"] ? (w(), s("div", Ji, [O(i.$slots, "toolbar-start")])) : o("", !0),
|
|
1785
1879
|
c("div", {
|
|
1786
1880
|
ref_key: "fitArea",
|
|
1787
1881
|
ref: h,
|
|
@@ -1810,7 +1904,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1810
1904
|
"disabled",
|
|
1811
1905
|
"onClick"
|
|
1812
1906
|
]))), 128)),
|
|
1813
|
-
A.value.length ? (w(), a(
|
|
1907
|
+
A.value.length ? (w(), a(Ui, {
|
|
1814
1908
|
key: 0,
|
|
1815
1909
|
items: A.value,
|
|
1816
1910
|
label: M(t)("ui.pageHeader.moreActions"),
|
|
@@ -1821,7 +1915,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1821
1915
|
"label",
|
|
1822
1916
|
"link-component"
|
|
1823
1917
|
])) : o("", !0),
|
|
1824
|
-
c("div",
|
|
1918
|
+
c("div", Yi, [c("div", {
|
|
1825
1919
|
ref_key: "measure",
|
|
1826
1920
|
ref: g,
|
|
1827
1921
|
class: "flex w-max gap-1"
|
|
@@ -1847,18 +1941,18 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1847
1941
|
_: 1
|
|
1848
1942
|
})], 512)])
|
|
1849
1943
|
], 512),
|
|
1850
|
-
i.$slots["toolbar-end"] ? (w(), s("div",
|
|
1851
|
-
], 10,
|
|
1944
|
+
i.$slots["toolbar-end"] ? (w(), s("div", Xi, [O(i.$slots, "toolbar-end")])) : o("", !0)
|
|
1945
|
+
], 10, qi)) : o("", !0),
|
|
1852
1946
|
O(i.$slots, "default")
|
|
1853
1947
|
], 2));
|
|
1854
1948
|
}
|
|
1855
|
-
}),
|
|
1949
|
+
}), Qi = { class: "flex min-w-0 flex-col gap-0.5" }, $i = {
|
|
1856
1950
|
class: "text-sm",
|
|
1857
1951
|
"aria-hidden": "true"
|
|
1858
|
-
},
|
|
1952
|
+
}, ea = {
|
|
1859
1953
|
key: 0,
|
|
1860
1954
|
class: "text-xs text-black/65"
|
|
1861
|
-
},
|
|
1955
|
+
}, ta = { class: "w-full shrink-0 sm:w-80" }, na = /* @__PURE__ */ f({
|
|
1862
1956
|
__name: "SettingsRow",
|
|
1863
1957
|
props: {
|
|
1864
1958
|
label: {},
|
|
@@ -1873,12 +1967,12 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1873
1967
|
},
|
|
1874
1968
|
setup(e) {
|
|
1875
1969
|
let t = e;
|
|
1876
|
-
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));
|
|
1877
1971
|
}
|
|
1878
|
-
}),
|
|
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 = {
|
|
1879
1973
|
key: 0,
|
|
1880
1974
|
class: "ml-auto shrink-0 truncate text-xs text-black/65"
|
|
1881
|
-
},
|
|
1975
|
+
}, la = /* @__PURE__ */ f({
|
|
1882
1976
|
__name: "AvatarGroup",
|
|
1883
1977
|
props: {
|
|
1884
1978
|
users: {},
|
|
@@ -1924,7 +2018,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1924
2018
|
}, [(w(!0), s(n, null, D(a.value, (t, n) => (w(), s("span", {
|
|
1925
2019
|
key: `${t.name}-${n}`,
|
|
1926
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]))
|
|
1927
|
-
}, [d(
|
|
2021
|
+
}, [d(Gr, {
|
|
1928
2022
|
user: t,
|
|
1929
2023
|
size: e.size,
|
|
1930
2024
|
profile: e.profile
|
|
@@ -1935,7 +2029,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1935
2029
|
])], 2))), 128)), l.value.length ? (w(), s("span", {
|
|
1936
2030
|
key: 0,
|
|
1937
2031
|
class: y(M(X)("relative flex rounded-full ring-white hover:z-10 focus-within:z-10", f[e.size], u[e.size]))
|
|
1938
|
-
}, [d(
|
|
2032
|
+
}, [d(er, {
|
|
1939
2033
|
mode: "hover",
|
|
1940
2034
|
"open-delay": 300,
|
|
1941
2035
|
"close-delay": 150,
|
|
@@ -1946,17 +2040,17 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1946
2040
|
},
|
|
1947
2041
|
ui: { content: "w-56" }
|
|
1948
2042
|
}, {
|
|
1949
|
-
content: V(() => [c("ul",
|
|
2043
|
+
content: V(() => [c("ul", oa, [(w(!0), s(n, null, D(l.value, (e, t) => (w(), s("li", {
|
|
1950
2044
|
key: `${e.name}-${t}`,
|
|
1951
2045
|
class: "flex items-center gap-2"
|
|
1952
2046
|
}, [
|
|
1953
|
-
d(
|
|
2047
|
+
d(Gr, {
|
|
1954
2048
|
user: e,
|
|
1955
2049
|
size: "xs",
|
|
1956
2050
|
decorative: ""
|
|
1957
2051
|
}, null, 8, ["user"]),
|
|
1958
|
-
c("span",
|
|
1959
|
-
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)
|
|
1960
2054
|
]))), 128))])]),
|
|
1961
2055
|
default: V(() => [c("button", {
|
|
1962
2056
|
type: "button",
|
|
@@ -1965,17 +2059,17 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
1965
2059
|
names: l.value.map((e) => e.name).join(", ")
|
|
1966
2060
|
}),
|
|
1967
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]))
|
|
1968
|
-
}, [c("span",
|
|
2062
|
+
}, [c("span", aa, "+" + j(l.value.length), 1)], 10, ia)]),
|
|
1969
2063
|
_: 1
|
|
1970
|
-
})], 2)) : o("", !0)], 10,
|
|
2064
|
+
})], 2)) : o("", !0)], 10, ra));
|
|
1971
2065
|
}
|
|
1972
|
-
}),
|
|
2066
|
+
}), ua = { class: "flex min-w-0 flex-col gap-1" }, da = {
|
|
1973
2067
|
key: 1,
|
|
1974
2068
|
class: "text-sm text-black/65"
|
|
1975
|
-
},
|
|
2069
|
+
}, fa = {
|
|
1976
2070
|
key: 0,
|
|
1977
2071
|
class: "flex shrink-0 items-center gap-2"
|
|
1978
|
-
},
|
|
2072
|
+
}, pa = /* @__PURE__ */ f({
|
|
1979
2073
|
__name: "Card",
|
|
1980
2074
|
props: {
|
|
1981
2075
|
title: {},
|
|
@@ -2009,25 +2103,25 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
2009
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", {
|
|
2010
2104
|
key: 0,
|
|
2011
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))
|
|
2012
|
-
}, [O(i.$slots, "header", {}, () => [c("div",
|
|
2106
|
+
}, [O(i.$slots, "header", {}, () => [c("div", ua, [e.title ? (w(), a(k(`h${e.headingLevel}`), {
|
|
2013
2107
|
key: 0,
|
|
2014
2108
|
id: n,
|
|
2015
2109
|
class: "text-base font-bold"
|
|
2016
2110
|
}, {
|
|
2017
2111
|
default: V(() => [u(j(e.title), 1)]),
|
|
2018
2112
|
_: 1
|
|
2019
|
-
})) : 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", {
|
|
2020
2114
|
key: 0,
|
|
2021
2115
|
class: y(M(X)("flex flex-wrap justify-end gap-2 border-t border-black/15", d[e.padding], e.ui?.footer))
|
|
2022
2116
|
}, [O(i.$slots, "footer")], 2)) : o("", !0)]),
|
|
2023
2117
|
_: 3
|
|
2024
2118
|
}, 8, ["aria-labelledby", "class"]));
|
|
2025
2119
|
}
|
|
2026
|
-
}),
|
|
2120
|
+
}), ma = { class: "min-w-0 truncate" }, ha = [
|
|
2027
2121
|
"tabindex",
|
|
2028
2122
|
"aria-label",
|
|
2029
2123
|
"disabled"
|
|
2030
|
-
],
|
|
2124
|
+
], ga = /* @__PURE__ */ f({
|
|
2031
2125
|
__name: "Chip",
|
|
2032
2126
|
props: {
|
|
2033
2127
|
size: { default: "md" },
|
|
@@ -2060,7 +2154,7 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
2060
2154
|
};
|
|
2061
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)) }, [
|
|
2062
2156
|
O(t.$slots, "leading"),
|
|
2063
|
-
c("span",
|
|
2157
|
+
c("span", ma, [O(t.$slots, "default")]),
|
|
2064
2158
|
e.removable ? (w(), s("button", {
|
|
2065
2159
|
key: 0,
|
|
2066
2160
|
type: "button",
|
|
@@ -2069,10 +2163,10 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
2069
2163
|
disabled: e.disabled,
|
|
2070
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])),
|
|
2071
2165
|
onClick: p[0] ||= (e) => i("remove")
|
|
2072
|
-
}, [d(M(
|
|
2166
|
+
}, [d(M(Ve), { "aria-hidden": "true" })], 10, ha)) : o("", !0)
|
|
2073
2167
|
], 2));
|
|
2074
2168
|
}
|
|
2075
|
-
}),
|
|
2169
|
+
}), _a = ["role", "aria-label"], va = { class: "shrink-0" }, ya = /* @__PURE__ */ f({
|
|
2076
2170
|
__name: "Divider",
|
|
2077
2171
|
props: {
|
|
2078
2172
|
orientation: { default: "horizontal" },
|
|
@@ -2101,12 +2195,12 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
2101
2195
|
"aria-hidden": "true",
|
|
2102
2196
|
class: "h-px flex-1 bg-black/15"
|
|
2103
2197
|
}, null, -1),
|
|
2104
|
-
c("span",
|
|
2198
|
+
c("span", va, [O(n.$slots, "default", {}, () => [u(j(e.label), 1)])]),
|
|
2105
2199
|
r[1] ||= c("span", {
|
|
2106
2200
|
"aria-hidden": "true",
|
|
2107
2201
|
class: "h-px flex-1 bg-black/15"
|
|
2108
2202
|
}, null, -1)
|
|
2109
|
-
], 10,
|
|
2203
|
+
], 10, _a)) : (w(), a(M(on), {
|
|
2110
2204
|
key: 1,
|
|
2111
2205
|
orientation: e.orientation,
|
|
2112
2206
|
decorative: e.decorative,
|
|
@@ -2119,17 +2213,17 @@ var Vr = ["data-collapsed"], Hr = ["aria-label"], Ur = ["data-level"], Wr = {
|
|
|
2119
2213
|
}
|
|
2120
2214
|
});
|
|
2121
2215
|
// src/components/ChangeIndicator/changeIndicator.ts
|
|
2122
|
-
function
|
|
2216
|
+
function ba(e, t) {
|
|
2123
2217
|
return t ? `${e} ${t}` : String(e);
|
|
2124
2218
|
}
|
|
2125
|
-
function
|
|
2219
|
+
function xa(e, t) {
|
|
2126
2220
|
return String(e) !== String(t);
|
|
2127
2221
|
}
|
|
2128
2222
|
// src/components/ChangeIndicator/ChangeIndicator.vue?vue&type=script&setup=true&lang.ts
|
|
2129
|
-
var
|
|
2223
|
+
var Sa = { class: "sr-only" }, Ca = {
|
|
2130
2224
|
"aria-hidden": "true",
|
|
2131
2225
|
class: "font-normal line-through decoration-blue/60"
|
|
2132
|
-
},
|
|
2226
|
+
}, wa = { "aria-hidden": "true" }, Ta = /* @__PURE__ */ f({
|
|
2133
2227
|
__name: "ChangeIndicator",
|
|
2134
2228
|
props: {
|
|
2135
2229
|
from: {},
|
|
@@ -2144,24 +2238,24 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2144
2238
|
] }
|
|
2145
2239
|
},
|
|
2146
2240
|
setup(e) {
|
|
2147
|
-
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", {
|
|
2148
2242
|
from: r.from,
|
|
2149
|
-
to:
|
|
2243
|
+
to: ba(r.to, r.unit)
|
|
2150
2244
|
}));
|
|
2151
2245
|
return (t, i) => a.value ? (w(), s("span", {
|
|
2152
2246
|
key: 0,
|
|
2153
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))
|
|
2154
2248
|
}, [
|
|
2155
|
-
c("span",
|
|
2156
|
-
c("span",
|
|
2249
|
+
c("span", Sa, j(l.value), 1),
|
|
2250
|
+
c("span", Ca, j(e.from), 1),
|
|
2157
2251
|
d(M(re), {
|
|
2158
2252
|
"aria-hidden": "true",
|
|
2159
2253
|
class: "size-3 shrink-0"
|
|
2160
2254
|
}),
|
|
2161
|
-
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)])
|
|
2162
2256
|
], 2)) : o("", !0);
|
|
2163
2257
|
}
|
|
2164
|
-
}),
|
|
2258
|
+
}), Ea = ["aria-label"], Da = { class: "max-w-64 px-3 py-2 text-xs" }, Oa = /* @__PURE__ */ f({
|
|
2165
2259
|
__name: "InfoTip",
|
|
2166
2260
|
props: {
|
|
2167
2261
|
text: {},
|
|
@@ -2176,27 +2270,27 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2176
2270
|
},
|
|
2177
2271
|
setup(e) {
|
|
2178
2272
|
let t = e, n = `${P()}-description`;
|
|
2179
|
-
return (r, i) => (w(), a(
|
|
2273
|
+
return (r, i) => (w(), a(er, {
|
|
2180
2274
|
mode: "hover",
|
|
2181
2275
|
content: {
|
|
2182
2276
|
side: "top",
|
|
2183
2277
|
sideOffset: 6
|
|
2184
2278
|
}
|
|
2185
2279
|
}, {
|
|
2186
|
-
content: V(() => [c("p",
|
|
2280
|
+
content: V(() => [c("p", Da, j(e.text), 1)]),
|
|
2187
2281
|
default: V(() => [c("button", {
|
|
2188
2282
|
type: "button",
|
|
2189
2283
|
"aria-label": e.label,
|
|
2190
2284
|
"aria-describedby": n,
|
|
2191
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))
|
|
2192
|
-
}, [d(M(
|
|
2286
|
+
}, [d(M(ye), { "aria-hidden": "true" }), c("span", {
|
|
2193
2287
|
id: n,
|
|
2194
2288
|
hidden: ""
|
|
2195
|
-
}, j(e.text), 1)], 10,
|
|
2289
|
+
}, j(e.text), 1)], 10, Ea)]),
|
|
2196
2290
|
_: 1
|
|
2197
2291
|
}));
|
|
2198
2292
|
}
|
|
2199
|
-
}),
|
|
2293
|
+
}), ka = { class: "overflow-hidden" }, Aa = ["id"], ja = /* @__PURE__ */ f({
|
|
2200
2294
|
__name: "FieldMessage",
|
|
2201
2295
|
props: {
|
|
2202
2296
|
id: {},
|
|
@@ -2213,13 +2307,13 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2213
2307
|
success: "text-green",
|
|
2214
2308
|
loading: "text-black/65"
|
|
2215
2309
|
}, p = {
|
|
2216
|
-
error:
|
|
2217
|
-
success:
|
|
2310
|
+
error: _e,
|
|
2311
|
+
success: ve
|
|
2218
2312
|
};
|
|
2219
2313
|
return (t, i) => (w(), s(n, null, [c("div", {
|
|
2220
2314
|
"aria-hidden": "true",
|
|
2221
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"))
|
|
2222
|
-
}, [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, {
|
|
2223
2317
|
key: 0,
|
|
2224
2318
|
size: "sm",
|
|
2225
2319
|
class: "size-3.5"
|
|
@@ -2227,12 +2321,12 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2227
2321
|
id: e.id,
|
|
2228
2322
|
"aria-live": "polite",
|
|
2229
2323
|
class: "sr-only"
|
|
2230
|
-
}, j(e.text), 9,
|
|
2324
|
+
}, j(e.text), 9, Aa)], 64));
|
|
2231
2325
|
}
|
|
2232
|
-
}),
|
|
2326
|
+
}), Ma = { class: "flex items-center gap-1" }, Na = ["hidden"], Pa = {
|
|
2233
2327
|
key: 0,
|
|
2234
2328
|
class: "col-start-2 row-start-1 flex h-5 items-center text-xs"
|
|
2235
|
-
},
|
|
2329
|
+
}, Fa = "input, textarea, [role=\"spinbutton\"], [contenteditable=\"true\"]", Ia = /* @__PURE__ */ f({
|
|
2236
2330
|
__name: "FormField",
|
|
2237
2331
|
props: {
|
|
2238
2332
|
label: {},
|
|
@@ -2255,7 +2349,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2255
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);
|
|
2256
2350
|
function _(e) {
|
|
2257
2351
|
let t = e.target;
|
|
2258
|
-
n.disabled || t.closest(`${
|
|
2352
|
+
n.disabled || t.closest(`${Fa}, button`) || (e.preventDefault(), e.currentTarget.querySelector(Fa)?.focus());
|
|
2259
2353
|
}
|
|
2260
2354
|
function v() {
|
|
2261
2355
|
let e = document.getElementById(l);
|
|
@@ -2273,12 +2367,12 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2273
2367
|
loading: ""
|
|
2274
2368
|
};
|
|
2275
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")) }, [
|
|
2276
|
-
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", {
|
|
2277
2371
|
id: u,
|
|
2278
2372
|
for: l,
|
|
2279
2373
|
class: "text-sm",
|
|
2280
2374
|
onClick: v
|
|
2281
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
2375
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
2282
2376
|
key: 0,
|
|
2283
2377
|
text: e.helper,
|
|
2284
2378
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -2287,7 +2381,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2287
2381
|
id: f,
|
|
2288
2382
|
hidden: e.helperPlacement === "icon",
|
|
2289
2383
|
class: "text-xs text-black/65"
|
|
2290
|
-
}, j(e.helper), 9,
|
|
2384
|
+
}, j(e.helper), 9, Na)) : o("", !0)], 2),
|
|
2291
2385
|
c("div", {
|
|
2292
2386
|
class: y(M(X)(b, "col-span-2 row-start-2", m.value && x[m.value], e.disabled && "opacity-40 cursor-not-allowed")),
|
|
2293
2387
|
onPointerdown: _
|
|
@@ -2301,20 +2395,20 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2301
2395
|
}),
|
|
2302
2396
|
O(r.$slots, "trailing")
|
|
2303
2397
|
], 34),
|
|
2304
|
-
r.$slots["label-trailing"] ? (w(), s("div",
|
|
2305
|
-
], 2), d(
|
|
2398
|
+
r.$slots["label-trailing"] ? (w(), s("div", Pa, [O(r.$slots, "label-trailing")])) : o("", !0)
|
|
2399
|
+
], 2), d(ja, {
|
|
2306
2400
|
id: p,
|
|
2307
2401
|
status: m.value,
|
|
2308
2402
|
text: h.value
|
|
2309
2403
|
}, null, 8, ["status", "text"])], 2));
|
|
2310
2404
|
}
|
|
2311
|
-
}),
|
|
2405
|
+
}), La = [
|
|
2312
2406
|
"id",
|
|
2313
2407
|
"spellcheck",
|
|
2314
2408
|
"disabled",
|
|
2315
2409
|
"aria-invalid",
|
|
2316
2410
|
"aria-describedby"
|
|
2317
|
-
],
|
|
2411
|
+
], Ra = /* @__PURE__ */ f({
|
|
2318
2412
|
inheritAttrs: !1,
|
|
2319
2413
|
__name: "Input",
|
|
2320
2414
|
props: /*@__PURE__*/ g({
|
|
@@ -2346,7 +2440,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2346
2440
|
if (n.maxLength !== void 0 && e > n.maxLength) return t("ui.input.maxLength", { count: n.maxLength });
|
|
2347
2441
|
if (o.value && n.minLength !== void 0 && e > 0 && e < n.minLength) return t("ui.input.minLength", { count: n.minLength });
|
|
2348
2442
|
}), u = i(() => n.status ?? (s.value ? "error" : void 0)), d = i(() => n.statusText ?? s.value);
|
|
2349
|
-
return (t, i) => (w(), a(
|
|
2443
|
+
return (t, i) => (w(), a(Ia, {
|
|
2350
2444
|
label: e.label,
|
|
2351
2445
|
helper: e.helper,
|
|
2352
2446
|
"helper-placement": e.helperPlacement,
|
|
@@ -2367,7 +2461,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2367
2461
|
"aria-describedby": a,
|
|
2368
2462
|
class: "h-5 min-w-0 flex-1 bg-transparent outline-none placeholder:text-black/55 disabled:cursor-not-allowed",
|
|
2369
2463
|
onBlur: i[1] ||= (e) => o.value = !0
|
|
2370
|
-
}), null, 16,
|
|
2464
|
+
}), null, 16, La), [[L, r.value]])]),
|
|
2371
2465
|
_: 2
|
|
2372
2466
|
}, [t.$slots.leading ? {
|
|
2373
2467
|
name: "leading",
|
|
@@ -2389,7 +2483,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2389
2483
|
"class"
|
|
2390
2484
|
]));
|
|
2391
2485
|
}
|
|
2392
|
-
}),
|
|
2486
|
+
}), za = "-ml-3 rounded-l border-r border-black/15", Ba = "-mr-3 rounded-r border-l border-black/15", Va = /* @__PURE__ */ f({
|
|
2393
2487
|
inheritAttrs: !1,
|
|
2394
2488
|
__name: "InputNumber",
|
|
2395
2489
|
props: /*@__PURE__*/ g({
|
|
@@ -2424,7 +2518,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2424
2518
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
2425
2519
|
"disabled:cursor-not-allowed disabled:[&_svg]:opacity-40!"
|
|
2426
2520
|
];
|
|
2427
|
-
return (t, i) => (w(), a(
|
|
2521
|
+
return (t, i) => (w(), a(Ia, {
|
|
2428
2522
|
label: e.label,
|
|
2429
2523
|
helper: e.helper,
|
|
2430
2524
|
"helper-placement": e.helperPlacement,
|
|
@@ -2435,7 +2529,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2435
2529
|
disabled: e.disabled,
|
|
2436
2530
|
class: y(t.$props.class)
|
|
2437
2531
|
}, {
|
|
2438
|
-
default: V(({ id: a, describedBy: s, invalid: c }) => [d(M(
|
|
2532
|
+
default: V(({ id: a, describedBy: s, invalid: c }) => [d(M(Nt), {
|
|
2439
2533
|
id: a,
|
|
2440
2534
|
modelValue: n.value,
|
|
2441
2535
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -2448,11 +2542,11 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2448
2542
|
class: "contents"
|
|
2449
2543
|
}, {
|
|
2450
2544
|
default: V(() => [
|
|
2451
|
-
d(M(
|
|
2452
|
-
default: V(() => [d(M(
|
|
2545
|
+
d(M(At), { class: y([o, za]) }, {
|
|
2546
|
+
default: V(() => [d(M(je))]),
|
|
2453
2547
|
_: 1
|
|
2454
2548
|
}, 8, ["class"]),
|
|
2455
|
-
d(M(
|
|
2549
|
+
d(M(Mt), _(t.$attrs, {
|
|
2456
2550
|
"aria-invalid": c,
|
|
2457
2551
|
"aria-describedby": s,
|
|
2458
2552
|
"aria-valuetext": r.value,
|
|
@@ -2462,8 +2556,8 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2462
2556
|
"aria-describedby",
|
|
2463
2557
|
"aria-valuetext"
|
|
2464
2558
|
]),
|
|
2465
|
-
d(M(
|
|
2466
|
-
default: V(() => [d(M(
|
|
2559
|
+
d(M(jt), { class: y([o, Ba]) }, {
|
|
2560
|
+
default: V(() => [d(M(Fe))]),
|
|
2467
2561
|
_: 1
|
|
2468
2562
|
}, 8, ["class"])
|
|
2469
2563
|
]),
|
|
@@ -2491,26 +2585,26 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2491
2585
|
"class"
|
|
2492
2586
|
]));
|
|
2493
2587
|
}
|
|
2494
|
-
}),
|
|
2588
|
+
}), Ha = { class: "flex items-center" }, Ua = ["aria-label", "disabled"], Wa = ["aria-label", "disabled"], Ga = {
|
|
2495
2589
|
key: 2,
|
|
2496
2590
|
class: "px-1.5 py-1 text-sm tabular-nums"
|
|
2497
|
-
},
|
|
2591
|
+
}, Ka = {
|
|
2498
2592
|
key: 0,
|
|
2499
2593
|
class: "mt-3 grid w-56 grid-cols-3 gap-1"
|
|
2500
|
-
},
|
|
2594
|
+
}, qa = [
|
|
2501
2595
|
"aria-current",
|
|
2502
2596
|
"aria-pressed",
|
|
2503
2597
|
"disabled",
|
|
2504
2598
|
"onClick"
|
|
2505
|
-
],
|
|
2599
|
+
], Ja = {
|
|
2506
2600
|
key: 1,
|
|
2507
2601
|
class: "mt-3 grid w-56 grid-cols-3 gap-1"
|
|
2508
|
-
},
|
|
2602
|
+
}, Ya = [
|
|
2509
2603
|
"aria-current",
|
|
2510
2604
|
"aria-pressed",
|
|
2511
2605
|
"disabled",
|
|
2512
2606
|
"onClick"
|
|
2513
|
-
],
|
|
2607
|
+
], Xa = /* @__PURE__ */ f({
|
|
2514
2608
|
__name: "Calendar",
|
|
2515
2609
|
props: /*@__PURE__*/ g({
|
|
2516
2610
|
min: {},
|
|
@@ -2534,7 +2628,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2534
2628
|
let { t } = K(), r = e, l = F(e, "modelValue");
|
|
2535
2629
|
function f(e) {
|
|
2536
2630
|
if (e) try {
|
|
2537
|
-
return
|
|
2631
|
+
return Dn(e);
|
|
2538
2632
|
} catch {
|
|
2539
2633
|
return;
|
|
2540
2634
|
}
|
|
@@ -2545,15 +2639,15 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2545
2639
|
}
|
|
2546
2640
|
let _ = E("days"), v = A(b());
|
|
2547
2641
|
function b() {
|
|
2548
|
-
if (p.value) return
|
|
2549
|
-
let e =
|
|
2550
|
-
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;
|
|
2551
2645
|
}
|
|
2552
2646
|
z(p, (e) => {
|
|
2553
|
-
e && (v.value =
|
|
2647
|
+
e && (v.value = kn(e));
|
|
2554
2648
|
});
|
|
2555
2649
|
function x(e) {
|
|
2556
|
-
v.value =
|
|
2650
|
+
v.value = kn(e);
|
|
2557
2651
|
}
|
|
2558
2652
|
let S = i(() => {
|
|
2559
2653
|
let e = new Intl.DateTimeFormat(r.locale, { month: "short" });
|
|
@@ -2569,41 +2663,41 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2569
2663
|
v.value = v.value.set({ month: e }), _.value = "days";
|
|
2570
2664
|
}
|
|
2571
2665
|
function I(e) {
|
|
2572
|
-
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 });
|
|
2573
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";
|
|
2574
2668
|
}
|
|
2575
2669
|
function L(e) {
|
|
2576
2670
|
_.value === "months" ? v.value = v.value.add({ years: e }) : T.value += 12 * e;
|
|
2577
2671
|
}
|
|
2578
2672
|
function R(e) {
|
|
2579
|
-
let t = new
|
|
2673
|
+
let t = new Cn(v.value.year, e, 1), n = t.add({ months: 1 }).subtract({ days: 1 });
|
|
2580
2674
|
return !!(m.value && n.compare(m.value) < 0 || h.value && t.compare(h.value) > 0);
|
|
2581
2675
|
}
|
|
2582
2676
|
function B(e) {
|
|
2583
2677
|
return !!(m.value && e < m.value.year || h.value && e > h.value.year);
|
|
2584
2678
|
}
|
|
2585
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) => {
|
|
2586
|
-
let t =
|
|
2680
|
+
let t = An(Tn());
|
|
2587
2681
|
return v.value.year === t.year && e === t.month;
|
|
2588
|
-
},
|
|
2682
|
+
}, q = (e) => e === An(Tn()).year, J = [
|
|
2589
2683
|
"inline-flex items-center gap-0.5 rounded px-1.5 py-1 text-sm cursor-pointer transition",
|
|
2590
2684
|
"hover:bg-black/10 active:bg-black/15 [&_svg]:size-3.5",
|
|
2591
2685
|
"disabled:cursor-not-allowed disabled:hover:bg-transparent",
|
|
2592
2686
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2593
|
-
],
|
|
2687
|
+
], te = [
|
|
2594
2688
|
"relative aria-[current=date]:font-bold",
|
|
2595
2689
|
"aria-[current=date]:after:absolute aria-[current=date]:after:left-1/2 aria-[current=date]:after:size-1",
|
|
2596
2690
|
"aria-[current=date]:after:-translate-x-1/2 aria-[current=date]:after:rounded-full aria-[current=date]:after:bg-current"
|
|
2597
|
-
],
|
|
2598
|
-
...
|
|
2691
|
+
], ne = [
|
|
2692
|
+
...te,
|
|
2599
2693
|
"aria-[current=date]:after:bottom-2",
|
|
2600
2694
|
"flex h-12 items-center justify-center rounded text-sm tabular-nums cursor-pointer transition",
|
|
2601
2695
|
"hover:bg-black/10",
|
|
2602
2696
|
"aria-pressed:bg-primary aria-pressed:text-white aria-pressed:hover:bg-primary",
|
|
2603
2697
|
"disabled:cursor-not-allowed disabled:text-black/25 disabled:hover:bg-transparent",
|
|
2604
2698
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2605
|
-
],
|
|
2606
|
-
...
|
|
2699
|
+
], re = [
|
|
2700
|
+
...te,
|
|
2607
2701
|
"aria-[current=date]:after:bottom-0.5",
|
|
2608
2702
|
"flex size-8 items-center justify-center rounded text-sm tabular-nums cursor-pointer transition",
|
|
2609
2703
|
"hover:bg-black/10",
|
|
@@ -2613,7 +2707,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2613
2707
|
"data-[unavailable]:line-through",
|
|
2614
2708
|
"outline-2 outline-offset-1 outline-transparent focus-visible:outline-focus"
|
|
2615
2709
|
];
|
|
2616
|
-
return (i, l) => (w(), a(M(
|
|
2710
|
+
return (i, l) => (w(), a(M(Qe), {
|
|
2617
2711
|
"model-value": p.value,
|
|
2618
2712
|
placeholder: v.value,
|
|
2619
2713
|
"min-value": m.value,
|
|
@@ -2628,9 +2722,9 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2628
2722
|
"onUpdate:placeholder": x
|
|
2629
2723
|
}, {
|
|
2630
2724
|
default: V(({ weekDays: r, grid: i }) => [
|
|
2631
|
-
d(M(
|
|
2725
|
+
d(M(Ye), { class: "flex items-center justify-between gap-1" }, {
|
|
2632
2726
|
default: V(() => [
|
|
2633
|
-
_.value === "days" ? (w(), a(M(
|
|
2727
|
+
_.value === "days" ? (w(), a(M(Ze), {
|
|
2634
2728
|
key: 0,
|
|
2635
2729
|
"as-child": ""
|
|
2636
2730
|
}, {
|
|
@@ -2640,7 +2734,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2640
2734
|
square: "",
|
|
2641
2735
|
"aria-label": M(t)("ui.calendar.previousMonth")
|
|
2642
2736
|
}, {
|
|
2643
|
-
default: V(() => [d(M(
|
|
2737
|
+
default: V(() => [d(M(pe))]),
|
|
2644
2738
|
_: 1
|
|
2645
2739
|
}, 8, ["aria-label"])]),
|
|
2646
2740
|
_: 1
|
|
@@ -2653,25 +2747,25 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2653
2747
|
disabled: e.disabled || H.value,
|
|
2654
2748
|
onClick: l[0] ||= (e) => L(-1)
|
|
2655
2749
|
}, {
|
|
2656
|
-
default: V(() => [d(M(
|
|
2750
|
+
default: V(() => [d(M(pe))]),
|
|
2657
2751
|
_: 1
|
|
2658
2752
|
}, 8, ["aria-label", "disabled"])),
|
|
2659
|
-
c("div",
|
|
2753
|
+
c("div", Ha, [_.value === "days" ? (w(), s("button", {
|
|
2660
2754
|
key: 0,
|
|
2661
2755
|
type: "button",
|
|
2662
|
-
class: y(
|
|
2756
|
+
class: y(J),
|
|
2663
2757
|
"aria-label": M(t)("ui.calendar.chooseMonth"),
|
|
2664
2758
|
disabled: e.disabled,
|
|
2665
2759
|
onClick: k
|
|
2666
|
-
}, [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", {
|
|
2667
2761
|
key: 1,
|
|
2668
2762
|
type: "button",
|
|
2669
|
-
class: y(
|
|
2763
|
+
class: y(J),
|
|
2670
2764
|
"aria-label": M(t)("ui.calendar.chooseYear"),
|
|
2671
2765
|
disabled: e.disabled,
|
|
2672
2766
|
onClick: N
|
|
2673
|
-
}, [u(j(v.value.year) + " ", 1), d(M(
|
|
2674
|
-
_.value === "days" ? (w(), a(M(
|
|
2767
|
+
}, [u(j(v.value.year) + " ", 1), d(M(fe))], 8, Wa))]),
|
|
2768
|
+
_.value === "days" ? (w(), a(M(Xe), {
|
|
2675
2769
|
key: 2,
|
|
2676
2770
|
"as-child": ""
|
|
2677
2771
|
}, {
|
|
@@ -2681,7 +2775,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2681
2775
|
square: "",
|
|
2682
2776
|
"aria-label": M(t)("ui.calendar.nextMonth")
|
|
2683
2777
|
}, {
|
|
2684
|
-
default: V(() => [d(M(
|
|
2778
|
+
default: V(() => [d(M(me))]),
|
|
2685
2779
|
_: 1
|
|
2686
2780
|
}, 8, ["aria-label"])]),
|
|
2687
2781
|
_: 1
|
|
@@ -2694,36 +2788,36 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2694
2788
|
disabled: e.disabled || U.value,
|
|
2695
2789
|
onClick: l[1] ||= (e) => L(1)
|
|
2696
2790
|
}, {
|
|
2697
|
-
default: V(() => [d(M(
|
|
2791
|
+
default: V(() => [d(M(me))]),
|
|
2698
2792
|
_: 1
|
|
2699
2793
|
}, 8, ["aria-label", "disabled"]))
|
|
2700
2794
|
]),
|
|
2701
2795
|
_: 1
|
|
2702
2796
|
}),
|
|
2703
|
-
_.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", {
|
|
2704
2798
|
key: e,
|
|
2705
2799
|
type: "button",
|
|
2706
|
-
class: y(
|
|
2800
|
+
class: y(ne),
|
|
2707
2801
|
"aria-current": G(t + 1) ? "date" : void 0,
|
|
2708
2802
|
"aria-pressed": ee(t + 1),
|
|
2709
2803
|
disabled: R(t + 1),
|
|
2710
2804
|
onClick: (e) => P(t + 1)
|
|
2711
|
-
}, 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", {
|
|
2712
2806
|
key: e,
|
|
2713
2807
|
type: "button",
|
|
2714
|
-
class: y(
|
|
2715
|
-
"aria-current":
|
|
2808
|
+
class: y(ne),
|
|
2809
|
+
"aria-current": q(e) ? "date" : void 0,
|
|
2716
2810
|
"aria-pressed": W(e),
|
|
2717
2811
|
disabled: B(e),
|
|
2718
2812
|
onClick: (t) => I(e)
|
|
2719
|
-
}, j(e), 9,
|
|
2720
|
-
(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), {
|
|
2721
2815
|
key: e.value.toString(),
|
|
2722
2816
|
class: "mt-3 border-collapse select-none"
|
|
2723
2817
|
}, {
|
|
2724
|
-
default: V(() => [d(M(
|
|
2725
|
-
default: V(() => [d(M(
|
|
2726
|
-
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), {
|
|
2727
2821
|
key: e,
|
|
2728
2822
|
class: "w-8 pb-1 text-xs font-normal text-black/55"
|
|
2729
2823
|
}, {
|
|
@@ -2733,20 +2827,20 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2733
2827
|
_: 2
|
|
2734
2828
|
}, 1024)]),
|
|
2735
2829
|
_: 2
|
|
2736
|
-
}, 1024), d(M(
|
|
2737
|
-
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), {
|
|
2738
2832
|
key: `week-${r}`,
|
|
2739
2833
|
class: "flex"
|
|
2740
2834
|
}, {
|
|
2741
|
-
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), {
|
|
2742
2836
|
key: t.toString(),
|
|
2743
2837
|
date: t
|
|
2744
2838
|
}, {
|
|
2745
|
-
default: V(() => [d(M(
|
|
2839
|
+
default: V(() => [d(M(Ue), {
|
|
2746
2840
|
day: t,
|
|
2747
2841
|
month: e.value,
|
|
2748
|
-
"aria-current": M(
|
|
2749
|
-
class: y(
|
|
2842
|
+
"aria-current": M(En)(t, M(Tn)()) ? "date" : void 0,
|
|
2843
|
+
class: y(re)
|
|
2750
2844
|
}, null, 8, [
|
|
2751
2845
|
"day",
|
|
2752
2846
|
"month",
|
|
@@ -2773,7 +2867,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2773
2867
|
"class"
|
|
2774
2868
|
]));
|
|
2775
2869
|
}
|
|
2776
|
-
}),
|
|
2870
|
+
}), Za = {
|
|
2777
2871
|
monday: 1,
|
|
2778
2872
|
mon: 1,
|
|
2779
2873
|
tuesday: 2,
|
|
@@ -2792,7 +2886,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2792
2886
|
sat: 6,
|
|
2793
2887
|
sunday: 7,
|
|
2794
2888
|
sun: 7
|
|
2795
|
-
}, Q = `(${Object.keys(
|
|
2889
|
+
}, Q = `(${Object.keys(Za).join("|")})`, Qa = {
|
|
2796
2890
|
january: 1,
|
|
2797
2891
|
jan: 1,
|
|
2798
2892
|
february: 2,
|
|
@@ -2817,7 +2911,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2817
2911
|
nov: 11,
|
|
2818
2912
|
december: 12,
|
|
2819
2913
|
dec: 12
|
|
2820
|
-
},
|
|
2914
|
+
}, $a = `(${Object.keys(Qa).sort((e, t) => t.length - e.length).join("|")})`, eo = {
|
|
2821
2915
|
a: 1,
|
|
2822
2916
|
an: 1,
|
|
2823
2917
|
one: 1,
|
|
@@ -2841,7 +2935,7 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2841
2935
|
nineteen: 19,
|
|
2842
2936
|
twenty: 20,
|
|
2843
2937
|
thirty: 30
|
|
2844
|
-
},
|
|
2938
|
+
}, to = `(\\d+|${Object.keys(eo).join("|")})`, no = "(day|week|fortnight|month|year)s?", ro = {
|
|
2845
2939
|
first: 1,
|
|
2846
2940
|
second: 2,
|
|
2847
2941
|
third: 3,
|
|
@@ -2863,37 +2957,37 @@ var aa = { class: "sr-only" }, oa = {
|
|
|
2863
2957
|
nineteenth: 19,
|
|
2864
2958
|
twentieth: 20,
|
|
2865
2959
|
thirtieth: 30
|
|
2866
|
-
},
|
|
2867
|
-
function
|
|
2960
|
+
}, io = Object.keys(ro).join("|");
|
|
2961
|
+
function ao(e) {
|
|
2868
2962
|
return new Date(e.year, e.month - 1, e.day).getDay() || 7;
|
|
2869
2963
|
}
|
|
2870
|
-
function
|
|
2871
|
-
return e.subtract({ days:
|
|
2964
|
+
function oo(e) {
|
|
2965
|
+
return e.subtract({ days: ao(e) - 1 });
|
|
2872
2966
|
}
|
|
2873
2967
|
function $(e, t, n) {
|
|
2874
2968
|
if (!Number.isInteger(e) || t < 1 || t > 12 || n < 1) return;
|
|
2875
|
-
let r = new
|
|
2876
|
-
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);
|
|
2877
2971
|
}
|
|
2878
|
-
function
|
|
2972
|
+
function so(e, t, n, r) {
|
|
2879
2973
|
if (r === -1) {
|
|
2880
|
-
let r =
|
|
2881
|
-
return r.subtract({ days: (
|
|
2974
|
+
let r = wn(new Cn(e, t, 1));
|
|
2975
|
+
return r.subtract({ days: (ao(r) - n + 7) % 7 });
|
|
2882
2976
|
}
|
|
2883
|
-
let i = new
|
|
2977
|
+
let i = new Cn(e, t, 1), a = i.add({ days: (n - ao(i) + 7) % 7 + (r - 1) * 7 });
|
|
2884
2978
|
return a.month === t ? a : void 0;
|
|
2885
2979
|
}
|
|
2886
|
-
function
|
|
2980
|
+
function co(e) {
|
|
2887
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;
|
|
2888
|
-
return new
|
|
2982
|
+
return new Cn(e, p, m);
|
|
2889
2983
|
}
|
|
2890
|
-
function
|
|
2984
|
+
function lo(e, t) {
|
|
2891
2985
|
if (e.length === 4) return Number(e);
|
|
2892
2986
|
if (e.length !== 2) return NaN;
|
|
2893
2987
|
let n = Number(e);
|
|
2894
2988
|
return n <= t.year % 100 ? 2e3 + n : 1900 + n;
|
|
2895
2989
|
}
|
|
2896
|
-
var
|
|
2990
|
+
var uo = [
|
|
2897
2991
|
["(?:christmas|xmas) eve", (e) => $(e, 12, 24)],
|
|
2898
2992
|
["(?:christmas|xmas)(?: day)?", (e) => $(e, 12, 25)],
|
|
2899
2993
|
["boxing day", (e) => $(e, 12, 26)],
|
|
@@ -2901,16 +2995,16 @@ var qa = [
|
|
|
2901
2995
|
["new years?(?: day)?", (e) => $(e, 1, 1)],
|
|
2902
2996
|
["valentines(?: day)?", (e) => $(e, 2, 14)],
|
|
2903
2997
|
["(?:st )?(?:patricks|paddys) day", (e) => $(e, 3, 17)],
|
|
2904
|
-
["good friday", (e) =>
|
|
2905
|
-
["easter monday", (e) =>
|
|
2906
|
-
["easter(?: sunday| day)?", (e) =>
|
|
2907
|
-
["(?:mothers day|mothering sunday)", (e) =>
|
|
2908
|
-
["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)],
|
|
2909
3003
|
["halloween", (e) => $(e, 10, 31)],
|
|
2910
3004
|
["(?:bonfire night|guy fawkes(?: night| day)?)", (e) => $(e, 11, 5)],
|
|
2911
3005
|
["(?:remembrance|armistice) day", (e) => $(e, 11, 11)]
|
|
2912
3006
|
];
|
|
2913
|
-
function
|
|
3007
|
+
function fo(e, t, n) {
|
|
2914
3008
|
let r = e.filter((e) => !!e).sort((e, t) => e.compare(t));
|
|
2915
3009
|
return n === "future" ? r.find((e) => e.compare(t) >= 0) : n === "past" ? r.findLast((e) => e.compare(t) <= 0) : r.reduce((e, n) => {
|
|
2916
3010
|
if (!e) return n;
|
|
@@ -2918,39 +3012,39 @@ function Ja(e, t, n) {
|
|
|
2918
3012
|
return r < i || r === i && n.compare(t) > 0 ? n : e;
|
|
2919
3013
|
}, void 0);
|
|
2920
3014
|
}
|
|
2921
|
-
function
|
|
3015
|
+
function po(e, t, n, r, i) {
|
|
2922
3016
|
if (!e) return n.yearValue === void 0 ? r.add(t) : void 0;
|
|
2923
3017
|
switch (e.kind) {
|
|
2924
3018
|
case "date": return n.yearValue === void 0 ? e.date.add(t) : void 0;
|
|
2925
3019
|
case "yearless": return n.yearValue === void 0 ? n.year || t.years ? e.resolve(r.year + t.years)?.add({
|
|
2926
3020
|
...t,
|
|
2927
3021
|
years: 0
|
|
2928
|
-
}) :
|
|
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({
|
|
2929
3023
|
...t,
|
|
2930
3024
|
years: 0
|
|
2931
3025
|
});
|
|
2932
3026
|
case "dayOfMonth":
|
|
2933
3027
|
if (n.yearValue !== void 0) return;
|
|
2934
3028
|
if (n.month || t.months) {
|
|
2935
|
-
let n =
|
|
3029
|
+
let n = On(r).add({ months: t.months });
|
|
2936
3030
|
return $(n.year, n.month, e.day)?.add({
|
|
2937
3031
|
...t,
|
|
2938
3032
|
months: 0
|
|
2939
3033
|
});
|
|
2940
3034
|
}
|
|
2941
|
-
return
|
|
3035
|
+
return fo([
|
|
2942
3036
|
-1,
|
|
2943
3037
|
0,
|
|
2944
3038
|
1
|
|
2945
|
-
].map((e) =>
|
|
3039
|
+
].map((e) => On(r).add({ months: e })).map((t) => $(t.year, t.month, e.day)), r, i)?.add(t);
|
|
2946
3040
|
case "weekday": {
|
|
2947
3041
|
if (n.yearValue !== void 0) return;
|
|
2948
|
-
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 });
|
|
2949
3043
|
return (i === "past" || i === "nearest" && o < a ? c : s).add(t);
|
|
2950
3044
|
}
|
|
2951
3045
|
}
|
|
2952
3046
|
}
|
|
2953
|
-
function
|
|
3047
|
+
function mo(e, t, n) {
|
|
2954
3048
|
let r = e.trim(), i = /^(\d{4})-(\d{1,2})-(\d{1,2})$/.exec(r);
|
|
2955
3049
|
if (i) {
|
|
2956
3050
|
let e = $(Number(i[1]), Number(i[2]), Number(i[3]));
|
|
@@ -2976,29 +3070,29 @@ function Xa(e, t, n) {
|
|
|
2976
3070
|
kind: "yearless",
|
|
2977
3071
|
resolve: (e) => $(e, o, i)
|
|
2978
3072
|
};
|
|
2979
|
-
let s = $(
|
|
3073
|
+
let s = $(lo(r.year, t), o, i);
|
|
2980
3074
|
return s && {
|
|
2981
3075
|
kind: "date",
|
|
2982
3076
|
date: s
|
|
2983
3077
|
};
|
|
2984
3078
|
}
|
|
2985
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) => {
|
|
2986
|
-
let i = Number(e), a =
|
|
3080
|
+
let i = Number(e), a = Qa[n];
|
|
2987
3081
|
if (r === void 0) return {
|
|
2988
3082
|
kind: "yearless",
|
|
2989
3083
|
resolve: (e) => $(e, a, i)
|
|
2990
3084
|
};
|
|
2991
|
-
let o = $(
|
|
3085
|
+
let o = $(lo(r, t), a, i);
|
|
2992
3086
|
return o && {
|
|
2993
3087
|
kind: "date",
|
|
2994
3088
|
date: o
|
|
2995
3089
|
};
|
|
2996
3090
|
}, c;
|
|
2997
|
-
if (c = RegExp(`^(\\d{1,2}) ${
|
|
2998
|
-
if (c = RegExp(`^${
|
|
2999
|
-
if (c = RegExp(`^(\\d{4}) ${
|
|
3000
|
-
if (c = RegExp(`^${
|
|
3001
|
-
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]];
|
|
3002
3096
|
if (c[2]) {
|
|
3003
3097
|
let t = $(Number(c[2]), e, 1);
|
|
3004
3098
|
return t && {
|
|
@@ -3019,22 +3113,22 @@ function Xa(e, t, n) {
|
|
|
3019
3113
|
} : void 0;
|
|
3020
3114
|
}
|
|
3021
3115
|
}
|
|
3022
|
-
function
|
|
3116
|
+
function ho(e) {
|
|
3023
3117
|
return `${e}${e % 100 >= 11 && e % 100 <= 13 ? "th" : {
|
|
3024
3118
|
1: "st",
|
|
3025
3119
|
2: "nd",
|
|
3026
3120
|
3: "rd"
|
|
3027
3121
|
}[e % 10] ?? "th"}`;
|
|
3028
3122
|
}
|
|
3029
|
-
function
|
|
3030
|
-
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();
|
|
3031
3125
|
}
|
|
3032
|
-
function
|
|
3126
|
+
function _o(e, t) {
|
|
3033
3127
|
let { today: n, order: r = [
|
|
3034
3128
|
"day",
|
|
3035
3129
|
"month",
|
|
3036
3130
|
"year"
|
|
3037
|
-
], prefer: i = "future" } = t, a =
|
|
3131
|
+
], prefer: i = "future" } = t, a = go(e);
|
|
3038
3132
|
if (!a) return;
|
|
3039
3133
|
let o = ` ${a} `, s = !1, c = !1, l = [], u = !1, d = {
|
|
3040
3134
|
days: 0,
|
|
@@ -3044,7 +3138,7 @@ function $a(e, t) {
|
|
|
3044
3138
|
}, f = {
|
|
3045
3139
|
year: !1,
|
|
3046
3140
|
month: !1
|
|
3047
|
-
}, p =
|
|
3141
|
+
}, p = oo(n);
|
|
3048
3142
|
function m(e) {
|
|
3049
3143
|
let t = RegExp(` ${e} `).exec(o);
|
|
3050
3144
|
return t && (o = o.replace(t[0], " "), s = !0), t;
|
|
@@ -3054,37 +3148,37 @@ function $a(e, t) {
|
|
|
3054
3148
|
}, g = (e) => e && {
|
|
3055
3149
|
kind: "date",
|
|
3056
3150
|
date: e
|
|
3057
|
-
}, _ = (e, t = 1) => e.slice(t).find((e) => e !== void 0), v = (e) => e === "fortnight" ? ["weeks", 2] : [`${e}s`, 1], y = (e) =>
|
|
3058
|
-
if (m("eow") && h(g(p.add({ days: 4 }))), m("eom") && h(g(
|
|
3059
|
-
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]];
|
|
3060
3154
|
if (x[4]) {
|
|
3061
|
-
let n =
|
|
3062
|
-
x[5] ? h(g(
|
|
3155
|
+
let n = Qa[x[4]];
|
|
3156
|
+
x[5] ? h(g(so(Number(x[5]), n, t, e))) : h({
|
|
3063
3157
|
kind: "yearless",
|
|
3064
|
-
resolve: (r) =>
|
|
3158
|
+
resolve: (r) => so(r, n, t, e)
|
|
3065
3159
|
});
|
|
3066
3160
|
} else {
|
|
3067
|
-
let r = x[3] === "next" ? 1 : x[3] === "last" ? -1 : 0, i =
|
|
3068
|
-
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)));
|
|
3069
3163
|
}
|
|
3070
3164
|
}
|
|
3071
3165
|
if (x = m("(start|beginning|middle|mid|end) (?:of )?(?:(this|next|last) )?(week|month|year)")) {
|
|
3072
3166
|
let e = x[2] === "next" ? 1 : x[2] === "last" ? -1 : 0, t = x[1] === "beginning" ? "start" : x[1] === "middle" ? "mid" : x[1];
|
|
3073
3167
|
if (x[3] === "week") h(g(p.add({ weeks: e }).add({ days: t === "start" ? 0 : t === "mid" ? 2 : 4 })));
|
|
3074
3168
|
else if (x[3] === "month") {
|
|
3075
|
-
let r =
|
|
3076
|
-
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)));
|
|
3077
3171
|
} else {
|
|
3078
3172
|
let r = n.year + e;
|
|
3079
|
-
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)));
|
|
3080
3174
|
}
|
|
3081
3175
|
}
|
|
3082
|
-
if (x = m(`(start|beginning|early|middle|mid|late|end) (?:of )?${
|
|
3083
|
-
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) => [
|
|
3084
3178
|
"start",
|
|
3085
3179
|
"beginning",
|
|
3086
3180
|
"early"
|
|
3087
|
-
].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));
|
|
3088
3182
|
h(x[3] ? g(n(Number(x[3]))) : {
|
|
3089
3183
|
kind: "yearless",
|
|
3090
3184
|
resolve: n
|
|
@@ -3097,38 +3191,38 @@ function $a(e, t) {
|
|
|
3097
3191
|
kind: "weekday",
|
|
3098
3192
|
weekday: 6
|
|
3099
3193
|
});
|
|
3100
|
-
for (let [e, t] of
|
|
3194
|
+
for (let [e, t] of uo) m(e) && h({
|
|
3101
3195
|
kind: "yearless",
|
|
3102
3196
|
resolve: t
|
|
3103
3197
|
});
|
|
3104
|
-
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}`)) {
|
|
3105
3199
|
let [e, t] = v(x[2]);
|
|
3106
|
-
h(g(b(
|
|
3200
|
+
h(g(b(Za[x[3]]).add({ [e]: y(x[1]) * t })));
|
|
3107
3201
|
}
|
|
3108
|
-
if (x = m(`${
|
|
3202
|
+
if (x = m(`${to} ${no} (today|tomorrow|tmrw|tmr)`)) {
|
|
3109
3203
|
let [e, t] = v(x[2]);
|
|
3110
3204
|
h(g((x[3] === "today" ? n : n.add({ days: 1 })).add({ [e]: y(x[1]) * t })));
|
|
3111
3205
|
}
|
|
3112
3206
|
for ((x = m(`(?:next week ${Q}|${Q} next week|next ${Q})`)) && h(g(p.add({
|
|
3113
3207
|
weeks: 1,
|
|
3114
|
-
days:
|
|
3115
|
-
}))), (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({
|
|
3116
3210
|
kind: "weekday",
|
|
3117
|
-
weekday:
|
|
3118
|
-
}, !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}`);) {
|
|
3119
3213
|
let [e, t] = v(x[2]);
|
|
3120
3214
|
d[e] += (x[1] === "next" ? 1 : -1) * t;
|
|
3121
3215
|
}
|
|
3122
3216
|
let S = !1;
|
|
3123
|
-
for (; x = m(`in ${
|
|
3217
|
+
for (; x = m(`in ${to} ${no}`);) {
|
|
3124
3218
|
let [e, t] = v(x[2]);
|
|
3125
3219
|
d[e] += y(x[1]) * t, S = !0;
|
|
3126
3220
|
}
|
|
3127
|
-
for (; S && (x = m(`(?:and )?${
|
|
3221
|
+
for (; S && (x = m(`(?:and )?${to} ${no}(?! (?:ago|before|earlier|from|after|later))`));) {
|
|
3128
3222
|
let [e, t] = v(x[2]);
|
|
3129
3223
|
d[e] += y(x[1]) * t;
|
|
3130
3224
|
}
|
|
3131
|
-
for (; x = m(`${
|
|
3225
|
+
for (; x = m(`${to} ${no} (ago|before|earlier|from|after|later)`);) {
|
|
3132
3226
|
let [e, t] = v(x[2]), n = [
|
|
3133
3227
|
"ago",
|
|
3134
3228
|
"before",
|
|
@@ -3139,24 +3233,24 @@ function $a(e, t) {
|
|
|
3139
3233
|
for (; m("(?:on|of|at|by|for)"););
|
|
3140
3234
|
let C = o.trim();
|
|
3141
3235
|
if (s && /^\d{4}$/.test(C) && (f.yearValue = Number(C), C = ""), C) {
|
|
3142
|
-
let e =
|
|
3236
|
+
let e = mo(C, n, r);
|
|
3143
3237
|
if (!e) return;
|
|
3144
3238
|
l.length === 1 && u && l.pop(), l.push(e);
|
|
3145
3239
|
} else if (!s) return;
|
|
3146
|
-
if (!(c || l.length > 1)) return
|
|
3240
|
+
if (!(c || l.length > 1)) return po(l[0], d, f, n, i);
|
|
3147
3241
|
}
|
|
3148
3242
|
// src/components/InputDate/InputDate.vue?vue&type=script&setup=true&lang.ts
|
|
3149
|
-
var
|
|
3243
|
+
var vo = [
|
|
3150
3244
|
"id",
|
|
3151
3245
|
"placeholder",
|
|
3152
3246
|
"disabled",
|
|
3153
3247
|
"aria-invalid",
|
|
3154
3248
|
"aria-describedby"
|
|
3155
|
-
],
|
|
3249
|
+
], yo = {
|
|
3156
3250
|
key: 0,
|
|
3157
3251
|
"aria-hidden": "true",
|
|
3158
3252
|
class: "shrink-0 tabular-nums text-black/55"
|
|
3159
|
-
},
|
|
3253
|
+
}, bo = /* @__PURE__ */ f({
|
|
3160
3254
|
inheritAttrs: !1,
|
|
3161
3255
|
__name: "InputDate",
|
|
3162
3256
|
props: /*@__PURE__*/ g({
|
|
@@ -3188,7 +3282,7 @@ var eo = [
|
|
|
3188
3282
|
let { t } = K(), n = e, r = F(e, "modelValue");
|
|
3189
3283
|
function l(e) {
|
|
3190
3284
|
if (e) try {
|
|
3191
|
-
return
|
|
3285
|
+
return Dn(e);
|
|
3192
3286
|
} catch {
|
|
3193
3287
|
return;
|
|
3194
3288
|
}
|
|
@@ -3215,8 +3309,8 @@ var eo = [
|
|
|
3215
3309
|
return g.value.format(new Date(e.year, e.month - 1, e.day));
|
|
3216
3310
|
}
|
|
3217
3311
|
function D(e) {
|
|
3218
|
-
return
|
|
3219
|
-
today:
|
|
3312
|
+
return _o(e, {
|
|
3313
|
+
today: An(Tn()),
|
|
3220
3314
|
order: b.value,
|
|
3221
3315
|
prefer: n.prefer
|
|
3222
3316
|
});
|
|
@@ -3250,17 +3344,17 @@ var eo = [
|
|
|
3250
3344
|
t && O.value === T(t) || (e.preventDefault(), I());
|
|
3251
3345
|
}
|
|
3252
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);
|
|
3253
|
-
function
|
|
3347
|
+
function q(e) {
|
|
3254
3348
|
r.value = e, G.value = !1;
|
|
3255
3349
|
}
|
|
3256
|
-
let
|
|
3350
|
+
let J = [
|
|
3257
3351
|
"flex w-9 shrink-0 -my-2 -mr-3 self-stretch items-center justify-center",
|
|
3258
3352
|
"rounded-r border-l border-black/15 bg-white cursor-pointer transition",
|
|
3259
3353
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
3260
3354
|
"data-[state=open]:brightness-90 disabled:cursor-not-allowed",
|
|
3261
3355
|
"outline-2 -outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
3262
3356
|
];
|
|
3263
|
-
return (i, l) => (w(), a(
|
|
3357
|
+
return (i, l) => (w(), a(Ia, {
|
|
3264
3358
|
label: e.label,
|
|
3265
3359
|
helper: e.helper,
|
|
3266
3360
|
"helper-placement": e.helperPlacement,
|
|
@@ -3271,7 +3365,7 @@ var eo = [
|
|
|
3271
3365
|
disabled: e.disabled,
|
|
3272
3366
|
class: y(n.class)
|
|
3273
3367
|
}, {
|
|
3274
|
-
default: V(({ id: n, describedBy: a, invalid: u }) => [d(M(
|
|
3368
|
+
default: V(({ id: n, describedBy: a, invalid: u }) => [d(M(ht), {
|
|
3275
3369
|
open: G.value,
|
|
3276
3370
|
"onUpdate:open": l[1] ||= (e) => G.value = e,
|
|
3277
3371
|
disabled: e.disabled
|
|
@@ -3291,26 +3385,26 @@ var eo = [
|
|
|
3291
3385
|
onInput: P,
|
|
3292
3386
|
onBlur: I,
|
|
3293
3387
|
onKeydown: U(L, ["enter"])
|
|
3294
|
-
}), null, 16,
|
|
3295
|
-
k.value ? (w(), s("span",
|
|
3296
|
-
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), {
|
|
3297
3391
|
"aria-label": M(t)("ui.inputDate.openCalendar"),
|
|
3298
|
-
class: y(
|
|
3392
|
+
class: y(J)
|
|
3299
3393
|
}, {
|
|
3300
|
-
default: V(() => [d(M(
|
|
3394
|
+
default: V(() => [d(M(ue))]),
|
|
3301
3395
|
_: 1
|
|
3302
3396
|
}, 8, ["aria-label"]),
|
|
3303
|
-
d(M(
|
|
3397
|
+
d(M(mt), {
|
|
3304
3398
|
"side-offset": 6,
|
|
3305
3399
|
align: "end",
|
|
3306
|
-
class: y([M(
|
|
3400
|
+
class: y([M(Qn), "p-3"])
|
|
3307
3401
|
}, {
|
|
3308
|
-
default: V(() => [d(
|
|
3402
|
+
default: V(() => [d(Xa, {
|
|
3309
3403
|
"model-value": r.value,
|
|
3310
3404
|
min: e.min,
|
|
3311
3405
|
max: e.max,
|
|
3312
3406
|
locale: e.locale,
|
|
3313
|
-
"onUpdate:modelValue":
|
|
3407
|
+
"onUpdate:modelValue": q
|
|
3314
3408
|
}, null, 8, [
|
|
3315
3409
|
"model-value",
|
|
3316
3410
|
"min",
|
|
@@ -3335,7 +3429,7 @@ var eo = [
|
|
|
3335
3429
|
"class"
|
|
3336
3430
|
]));
|
|
3337
3431
|
}
|
|
3338
|
-
}),
|
|
3432
|
+
}), xo = /* @__PURE__ */ f({
|
|
3339
3433
|
__name: "Tooltip",
|
|
3340
3434
|
props: {
|
|
3341
3435
|
text: {},
|
|
@@ -3352,20 +3446,20 @@ var eo = [
|
|
|
3352
3446
|
] }
|
|
3353
3447
|
},
|
|
3354
3448
|
setup(e) {
|
|
3355
|
-
let t = e, n =
|
|
3449
|
+
let t = e, n = Sn(null) !== null, r = (e, { slots: r }) => n ? r.default?.() : m(yn, {
|
|
3356
3450
|
delayDuration: t.delay,
|
|
3357
3451
|
skipDelayDuration: 300
|
|
3358
3452
|
}, r);
|
|
3359
3453
|
return (n, i) => (w(), a(r, null, {
|
|
3360
|
-
default: V(() => [d(M(
|
|
3454
|
+
default: V(() => [d(M(bn), {
|
|
3361
3455
|
disabled: e.disabled,
|
|
3362
3456
|
"delay-duration": e.delay
|
|
3363
3457
|
}, {
|
|
3364
|
-
default: V(() => [d(M(
|
|
3458
|
+
default: V(() => [d(M(xn), { "as-child": "" }, {
|
|
3365
3459
|
default: V(() => [O(n.$slots, "default")]),
|
|
3366
3460
|
_: 3
|
|
3367
|
-
}), d(M(
|
|
3368
|
-
default: V(() => [d(M(
|
|
3461
|
+
}), d(M(vn), null, {
|
|
3462
|
+
default: V(() => [d(M(_n), {
|
|
3369
3463
|
side: e.side,
|
|
3370
3464
|
align: e.align,
|
|
3371
3465
|
"side-offset": 8,
|
|
@@ -3386,7 +3480,7 @@ var eo = [
|
|
|
3386
3480
|
_: 3
|
|
3387
3481
|
}));
|
|
3388
3482
|
}
|
|
3389
|
-
}),
|
|
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({
|
|
3390
3484
|
__name: "InputRichText",
|
|
3391
3485
|
props: /*@__PURE__*/ g({
|
|
3392
3486
|
label: {},
|
|
@@ -3411,19 +3505,19 @@ var eo = [
|
|
|
3411
3505
|
}),
|
|
3412
3506
|
emits: ["update:modelValue"],
|
|
3413
3507
|
setup(e) {
|
|
3414
|
-
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({
|
|
3415
3509
|
content: i.value,
|
|
3416
3510
|
editable: !r.disabled,
|
|
3417
3511
|
extensions: [
|
|
3418
|
-
|
|
3419
|
-
Dn,
|
|
3420
|
-
On,
|
|
3421
|
-
kn,
|
|
3422
|
-
An,
|
|
3423
|
-
jn,
|
|
3424
|
-
Mn,
|
|
3512
|
+
Nn,
|
|
3425
3513
|
Pn,
|
|
3426
|
-
|
|
3514
|
+
Fn,
|
|
3515
|
+
In,
|
|
3516
|
+
Ln,
|
|
3517
|
+
Rn,
|
|
3518
|
+
zn,
|
|
3519
|
+
Vn,
|
|
3520
|
+
Bn.configure({ placeholder: () => r.placeholder ?? "" })
|
|
3427
3521
|
],
|
|
3428
3522
|
onUpdate: () => {
|
|
3429
3523
|
i.value = o();
|
|
@@ -3470,7 +3564,7 @@ var eo = [
|
|
|
3470
3564
|
get label() {
|
|
3471
3565
|
return t("ui.inputRichText.bold");
|
|
3472
3566
|
},
|
|
3473
|
-
icon:
|
|
3567
|
+
icon: ce,
|
|
3474
3568
|
key: "B",
|
|
3475
3569
|
toggle: () => l.value?.chain().focus().toggleBold().run()
|
|
3476
3570
|
},
|
|
@@ -3479,7 +3573,7 @@ var eo = [
|
|
|
3479
3573
|
get label() {
|
|
3480
3574
|
return t("ui.inputRichText.italic");
|
|
3481
3575
|
},
|
|
3482
|
-
icon:
|
|
3576
|
+
icon: Ee,
|
|
3483
3577
|
key: "I",
|
|
3484
3578
|
toggle: () => l.value?.chain().focus().toggleItalic().run()
|
|
3485
3579
|
},
|
|
@@ -3488,12 +3582,12 @@ var eo = [
|
|
|
3488
3582
|
get label() {
|
|
3489
3583
|
return t("ui.inputRichText.underline");
|
|
3490
3584
|
},
|
|
3491
|
-
icon:
|
|
3585
|
+
icon: ze,
|
|
3492
3586
|
key: "U",
|
|
3493
3587
|
toggle: () => l.value?.chain().focus().toggleUnderline().run()
|
|
3494
3588
|
}
|
|
3495
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)]";
|
|
3496
|
-
return (i, o) => (w(), a(
|
|
3590
|
+
return (i, o) => (w(), a(Ia, {
|
|
3497
3591
|
label: e.label,
|
|
3498
3592
|
helper: e.helper,
|
|
3499
3593
|
"helper-placement": e.helperPlacement,
|
|
@@ -3504,14 +3598,14 @@ var eo = [
|
|
|
3504
3598
|
disabled: e.disabled,
|
|
3505
3599
|
class: y(r.class)
|
|
3506
3600
|
}, {
|
|
3507
|
-
default: V((r) => [c("div",
|
|
3601
|
+
default: V((r) => [c("div", So, [
|
|
3508
3602
|
c("div", {
|
|
3509
3603
|
role: "toolbar",
|
|
3510
3604
|
"aria-label": M(t)("ui.inputRichText.formattingFor", { label: e.label }),
|
|
3511
3605
|
"aria-controls": r.id,
|
|
3512
3606
|
class: "flex items-center gap-0.5 border-b border-black/15 px-1.5 py-1 [&_svg]:opacity-100!",
|
|
3513
3607
|
onMousedown: o[0] ||= ee(() => {}, ["prevent"])
|
|
3514
|
-
}, [(w(), s(n, null, D(_, (t) => d(
|
|
3608
|
+
}, [(w(), s(n, null, D(_, (t) => d(xo, {
|
|
3515
3609
|
key: t.name,
|
|
3516
3610
|
text: `${t.label} (${M(g)}${t.key})`,
|
|
3517
3611
|
disabled: e.disabled
|
|
@@ -3537,9 +3631,9 @@ var eo = [
|
|
|
3537
3631
|
"onClick"
|
|
3538
3632
|
])]),
|
|
3539
3633
|
_: 2
|
|
3540
|
-
}, 1032, ["text", "disabled"])), 64))], 40,
|
|
3634
|
+
}, 1032, ["text", "disabled"])), 64))], 40, Co),
|
|
3541
3635
|
d(M(m), { ids: r }, null, 8, ["ids"]),
|
|
3542
|
-
d(M(
|
|
3636
|
+
d(M(jn), {
|
|
3543
3637
|
editor: M(l),
|
|
3544
3638
|
class: y(M(X)("min-w-0", e.disabled && "cursor-not-allowed [&_*]:cursor-not-allowed"))
|
|
3545
3639
|
}, null, 8, ["editor", "class"])
|
|
@@ -3557,18 +3651,18 @@ var eo = [
|
|
|
3557
3651
|
"class"
|
|
3558
3652
|
]));
|
|
3559
3653
|
}
|
|
3560
|
-
}),
|
|
3654
|
+
}), To = [
|
|
3561
3655
|
"id",
|
|
3562
3656
|
"type",
|
|
3563
3657
|
"autocomplete",
|
|
3564
3658
|
"disabled",
|
|
3565
3659
|
"aria-invalid",
|
|
3566
3660
|
"aria-describedby"
|
|
3567
|
-
],
|
|
3661
|
+
], Eo = [
|
|
3568
3662
|
"aria-controls",
|
|
3569
3663
|
"aria-pressed",
|
|
3570
3664
|
"disabled"
|
|
3571
|
-
],
|
|
3665
|
+
], Do = { class: "sr-only" }, Oo = /* @__PURE__ */ f({
|
|
3572
3666
|
inheritAttrs: !1,
|
|
3573
3667
|
__name: "InputPassword",
|
|
3574
3668
|
props: /*@__PURE__*/ g({
|
|
@@ -3607,7 +3701,7 @@ var eo = [
|
|
|
3607
3701
|
"not-disabled:hover:brightness-90 not-disabled:active:brightness-80 [&_svg]:opacity-100!",
|
|
3608
3702
|
"outline-none focus-visible:bg-black/5 disabled:cursor-not-allowed"
|
|
3609
3703
|
];
|
|
3610
|
-
return (i, o) => (w(), a(
|
|
3704
|
+
return (i, o) => (w(), a(Ia, {
|
|
3611
3705
|
label: e.label,
|
|
3612
3706
|
helper: e.helper,
|
|
3613
3707
|
"helper-placement": e.helperPlacement,
|
|
@@ -3636,7 +3730,7 @@ var eo = [
|
|
|
3636
3730
|
onKeydown: h,
|
|
3637
3731
|
onKeyup: h,
|
|
3638
3732
|
onBlur: o[1] ||= (e) => m.value = !1
|
|
3639
|
-
}), null, 16,
|
|
3733
|
+
}), null, 16, To), [[L, r.value]]), c("button", {
|
|
3640
3734
|
type: "button",
|
|
3641
3735
|
class: y(v),
|
|
3642
3736
|
"aria-controls": n,
|
|
@@ -3644,13 +3738,13 @@ var eo = [
|
|
|
3644
3738
|
disabled: e.disabled,
|
|
3645
3739
|
onPointerdown: o[2] ||= ee(() => {}, ["prevent"]),
|
|
3646
3740
|
onClick: o[3] ||= (e) => d.value = !d.value
|
|
3647
|
-
}, [c("span",
|
|
3741
|
+
}, [c("span", Do, j(M(t)("ui.inputPassword.show")), 1), d.value ? (w(), a(M(Ce), {
|
|
3648
3742
|
key: 0,
|
|
3649
3743
|
"aria-hidden": "true"
|
|
3650
|
-
})) : (w(), a(M(
|
|
3744
|
+
})) : (w(), a(M(Se), {
|
|
3651
3745
|
key: 1,
|
|
3652
3746
|
"aria-hidden": "true"
|
|
3653
|
-
}))], 40,
|
|
3747
|
+
}))], 40, Eo)]),
|
|
3654
3748
|
_: 2
|
|
3655
3749
|
}, [i.$slots.leading ? {
|
|
3656
3750
|
name: "leading",
|
|
@@ -3672,7 +3766,7 @@ var eo = [
|
|
|
3672
3766
|
"class"
|
|
3673
3767
|
]));
|
|
3674
3768
|
}
|
|
3675
|
-
}),
|
|
3769
|
+
}), ko = { class: "flex flex-col gap-0.5" }, Ao = { class: "flex items-center gap-1" }, jo = ["for"], Mo = ["hidden"], No = /* @__PURE__ */ f({
|
|
3676
3770
|
__name: "InputCode",
|
|
3677
3771
|
props: /*@__PURE__*/ g({
|
|
3678
3772
|
label: {},
|
|
@@ -3715,11 +3809,11 @@ var eo = [
|
|
|
3715
3809
|
loading: ""
|
|
3716
3810
|
};
|
|
3717
3811
|
return (t, i) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", l.class)) }, [
|
|
3718
|
-
c("div",
|
|
3812
|
+
c("div", ko, [c("div", Ao, [c("label", {
|
|
3719
3813
|
id: m,
|
|
3720
3814
|
for: `${M(p)}-0`,
|
|
3721
3815
|
class: "text-sm"
|
|
3722
|
-
}, j(e.label), 9,
|
|
3816
|
+
}, j(e.label), 9, jo), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
3723
3817
|
key: 0,
|
|
3724
3818
|
text: e.helper,
|
|
3725
3819
|
label: M(r)("ui.formField.about", { label: e.label })
|
|
@@ -3728,8 +3822,8 @@ var eo = [
|
|
|
3728
3822
|
id: h,
|
|
3729
3823
|
hidden: e.helperPlacement === "icon",
|
|
3730
3824
|
class: "text-xs text-black/65"
|
|
3731
|
-
}, j(e.helper), 9,
|
|
3732
|
-
d(M(
|
|
3825
|
+
}, j(e.helper), 9, Mo)) : o("", !0)]),
|
|
3826
|
+
d(M(Ft), {
|
|
3733
3827
|
"model-value": x.value,
|
|
3734
3828
|
type: e.alphanumeric ? "text" : "number",
|
|
3735
3829
|
name: e.name,
|
|
@@ -3742,7 +3836,7 @@ var eo = [
|
|
|
3742
3836
|
"onUpdate:modelValue": C,
|
|
3743
3837
|
onComplete: T
|
|
3744
3838
|
}, {
|
|
3745
|
-
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), {
|
|
3746
3840
|
id: `${M(p)}-${n}`,
|
|
3747
3841
|
key: n,
|
|
3748
3842
|
index: n,
|
|
@@ -3771,32 +3865,32 @@ var eo = [
|
|
|
3771
3865
|
"disabled",
|
|
3772
3866
|
"class"
|
|
3773
3867
|
]),
|
|
3774
|
-
d(
|
|
3868
|
+
d(ja, {
|
|
3775
3869
|
id: g,
|
|
3776
3870
|
status: _.value,
|
|
3777
3871
|
text: v.value
|
|
3778
3872
|
}, null, 8, ["status", "text"])
|
|
3779
3873
|
], 2));
|
|
3780
3874
|
}
|
|
3781
|
-
}),
|
|
3875
|
+
}), Po = {
|
|
3782
3876
|
key: 0,
|
|
3783
3877
|
class: "flex min-w-0 flex-1 flex-wrap gap-1"
|
|
3784
|
-
},
|
|
3878
|
+
}, Fo = {
|
|
3785
3879
|
key: 1,
|
|
3786
3880
|
class: "h-5 min-w-0 flex-1 truncate"
|
|
3787
|
-
},
|
|
3881
|
+
}, Io = { class: "flex h-5 shrink-0 items-center" }, Lo = { class: "min-w-0 flex-1 truncate" }, Ro = { class: "truncate" }, zo = {
|
|
3788
3882
|
key: 0,
|
|
3789
3883
|
class: "flex h-5 shrink-0 items-center"
|
|
3790
|
-
},
|
|
3884
|
+
}, Bo = { class: "flex min-w-0 flex-1 flex-col" }, Vo = {
|
|
3791
3885
|
key: 0,
|
|
3792
3886
|
class: "sr-only"
|
|
3793
|
-
},
|
|
3887
|
+
}, Ho = {
|
|
3794
3888
|
key: 0,
|
|
3795
3889
|
class: "text-xs text-black/65"
|
|
3796
|
-
},
|
|
3890
|
+
}, Uo = {
|
|
3797
3891
|
key: 1,
|
|
3798
3892
|
class: "text-xs text-black/65"
|
|
3799
|
-
},
|
|
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({
|
|
3800
3894
|
__name: "Select",
|
|
3801
3895
|
props: /*@__PURE__*/ g({
|
|
3802
3896
|
label: {},
|
|
@@ -3857,15 +3951,15 @@ var eo = [
|
|
|
3857
3951
|
function B(e) {
|
|
3858
3952
|
r.multiple && !oe.value && p.value.length && (e.preventDefault(), z(p.value[p.value.length - 1]));
|
|
3859
3953
|
}
|
|
3860
|
-
let H = (e) => A.value.find((t) => t.option.value === e)?.option.label ?? "", W = E([]), G = i(() => W.value[W.value.length - 1]),
|
|
3861
|
-
function
|
|
3862
|
-
|
|
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;
|
|
3863
3957
|
}
|
|
3864
|
-
function
|
|
3865
|
-
e.target.select(),
|
|
3958
|
+
function te(e) {
|
|
3959
|
+
e.target.select(), re.value = ne;
|
|
3866
3960
|
}
|
|
3867
|
-
let
|
|
3868
|
-
|
|
3961
|
+
let ne = !1, re = E(!1), ie = () => ne = !0, ae = () => {
|
|
3962
|
+
ne = !1, re.value = !1;
|
|
3869
3963
|
};
|
|
3870
3964
|
C(() => {
|
|
3871
3965
|
document.addEventListener("pointerdown", ie, !0), document.addEventListener("keydown", ae, !0), document.fonts?.load(`700 1em ${getComputedStyle(document.body).fontFamily}`).catch(() => {});
|
|
@@ -3879,7 +3973,7 @@ var eo = [
|
|
|
3879
3973
|
option: e,
|
|
3880
3974
|
parent: r
|
|
3881
3975
|
};
|
|
3882
|
-
}),
|
|
3976
|
+
}), le = i(() => {
|
|
3883
3977
|
if (r.searchable && oe.value && N.value) {
|
|
3884
3978
|
let e = /* @__PURE__ */ new Map();
|
|
3885
3979
|
for (let t of A.value) {
|
|
@@ -3898,10 +3992,10 @@ var eo = [
|
|
|
3898
3992
|
icon: e.icon,
|
|
3899
3993
|
rows: ce(e.options, `group-${t}`)
|
|
3900
3994
|
}));
|
|
3901
|
-
}),
|
|
3995
|
+
}), ue = i(() => !!G.value && !(r.searchable && oe.value)), he = { back: !0 }, ge = (e) => ({ parent: e.key }), _e = `${P()}-list`;
|
|
3902
3996
|
async function ve(e) {
|
|
3903
3997
|
await v();
|
|
3904
|
-
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]");
|
|
3905
3999
|
i && (r.searchable ? i.dispatchEvent(new PointerEvent("pointermove", { bubbles: !0 })) : i.focus());
|
|
3906
4000
|
}
|
|
3907
4001
|
function ye(e, t) {
|
|
@@ -3916,35 +4010,35 @@ var eo = [
|
|
|
3916
4010
|
if (!(e.defaultPrevented || r.searchable && oe.value)) {
|
|
3917
4011
|
if (e.key === "ArrowLeft" && W.value.length) e.preventDefault(), be();
|
|
3918
4012
|
else if (e.key === "ArrowRight") {
|
|
3919
|
-
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);
|
|
3920
4014
|
if (!n) return;
|
|
3921
4015
|
e.preventDefault(), ye(e, n.option);
|
|
3922
4016
|
}
|
|
3923
4017
|
}
|
|
3924
4018
|
}
|
|
3925
4019
|
let Y = i(() => r.searchable ? {
|
|
3926
|
-
Root:
|
|
3927
|
-
Portal:
|
|
3928
|
-
Content:
|
|
3929
|
-
Viewport:
|
|
3930
|
-
Group:
|
|
3931
|
-
Label:
|
|
3932
|
-
Separator:
|
|
3933
|
-
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,
|
|
3934
4028
|
ItemText: "span",
|
|
3935
|
-
Indicator:
|
|
4029
|
+
Indicator: st
|
|
3936
4030
|
} : {
|
|
3937
|
-
Root:
|
|
3938
|
-
Portal:
|
|
3939
|
-
Content:
|
|
3940
|
-
Viewport:
|
|
3941
|
-
Group:
|
|
3942
|
-
Label:
|
|
3943
|
-
Separator:
|
|
3944
|
-
Item:
|
|
3945
|
-
ItemText:
|
|
3946
|
-
Indicator:
|
|
3947
|
-
}), 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 = [
|
|
3948
4042
|
"relative flex min-h-8 cursor-pointer items-start gap-2 rounded px-2 py-1.5 text-sm outline-none select-none",
|
|
3949
4043
|
"data-highlighted:bg-black/10",
|
|
3950
4044
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
@@ -3953,7 +4047,7 @@ var eo = [
|
|
|
3953
4047
|
e.option.description,
|
|
3954
4048
|
e.path
|
|
3955
4049
|
].filter(Boolean).join(" ") : e.option.label;
|
|
3956
|
-
return (i, f) => (w(), a(
|
|
4050
|
+
return (i, f) => (w(), a(Ia, {
|
|
3957
4051
|
label: e.label,
|
|
3958
4052
|
helper: e.helper,
|
|
3959
4053
|
"helper-placement": e.helperPlacement,
|
|
@@ -3975,21 +4069,21 @@ var eo = [
|
|
|
3975
4069
|
class: "contents"
|
|
3976
4070
|
} : {}, {
|
|
3977
4071
|
"onUpdate:modelValue": h,
|
|
3978
|
-
open:
|
|
3979
|
-
"onUpdate:open":
|
|
4072
|
+
open: q.value,
|
|
4073
|
+
"onUpdate:open": J
|
|
3980
4074
|
}), {
|
|
3981
|
-
default: V(() => [e.searchable ? (w(), a(M(
|
|
4075
|
+
default: V(() => [e.searchable ? (w(), a(M(tt), {
|
|
3982
4076
|
key: 0,
|
|
3983
|
-
class: y(
|
|
3984
|
-
onPointerdown: f[4] ||= (e) =>
|
|
3985
|
-
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)
|
|
3986
4080
|
}, {
|
|
3987
4081
|
default: V(() => [
|
|
3988
4082
|
O(i.$slots, "leading", {}, () => [L.value?.icon ? (w(), a(k(L.value.icon), {
|
|
3989
4083
|
key: 0,
|
|
3990
4084
|
"aria-hidden": "true"
|
|
3991
4085
|
})) : o("", !0)]),
|
|
3992
|
-
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, {
|
|
3993
4087
|
key: String(n.value),
|
|
3994
4088
|
size: "sm",
|
|
3995
4089
|
removable: "",
|
|
@@ -4009,7 +4103,7 @@ var eo = [
|
|
|
4009
4103
|
"remove-label",
|
|
4010
4104
|
"disabled",
|
|
4011
4105
|
"onRemove"
|
|
4012
|
-
]))), 128)), d(M(
|
|
4106
|
+
]))), 128)), d(M(at), {
|
|
4013
4107
|
id: r,
|
|
4014
4108
|
ref_key: "searchInput",
|
|
4015
4109
|
ref: se,
|
|
@@ -4021,9 +4115,9 @@ var eo = [
|
|
|
4021
4115
|
"aria-describedby": p,
|
|
4022
4116
|
autocomplete: "off",
|
|
4023
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")),
|
|
4024
|
-
"data-pointer-focus":
|
|
4025
|
-
onFocus:
|
|
4026
|
-
onBlur: f[2] ||= (e) =>
|
|
4118
|
+
"data-pointer-focus": re.value || void 0,
|
|
4119
|
+
onFocus: te,
|
|
4120
|
+
onBlur: f[2] ||= (e) => re.value = !1,
|
|
4027
4121
|
onKeydown: [f[3] ||= (e) => e.target.ariaExpanded === "true" && xe(e), U(B, ["backspace"])]
|
|
4028
4122
|
}, null, 8, [
|
|
4029
4123
|
"id",
|
|
@@ -4035,34 +4129,34 @@ var eo = [
|
|
|
4035
4129
|
"class",
|
|
4036
4130
|
"data-pointer-focus"
|
|
4037
4131
|
])], 2),
|
|
4038
|
-
d(M(
|
|
4132
|
+
d(M(ft), {
|
|
4039
4133
|
tabindex: "-1",
|
|
4040
4134
|
"aria-label": M(t)("ui.select.showOptions"),
|
|
4041
4135
|
class: "flex cursor-pointer disabled:cursor-not-allowed"
|
|
4042
4136
|
}, {
|
|
4043
|
-
default: V(() => [d(M(
|
|
4137
|
+
default: V(() => [d(M(fe), {
|
|
4044
4138
|
"aria-hidden": "true",
|
|
4045
|
-
class: y(
|
|
4139
|
+
class: y(Ko)
|
|
4046
4140
|
})]),
|
|
4047
4141
|
_: 1
|
|
4048
4142
|
}, 8, ["aria-label"])
|
|
4049
4143
|
]),
|
|
4050
4144
|
_: 2
|
|
4051
|
-
}, 1024)) : (w(), a(M(
|
|
4145
|
+
}, 1024)) : (w(), a(M(rn), {
|
|
4052
4146
|
key: 1,
|
|
4053
4147
|
id: r,
|
|
4054
4148
|
"aria-invalid": v,
|
|
4055
4149
|
"aria-describedby": p,
|
|
4056
|
-
"data-pointer-focus":
|
|
4057
|
-
onBlur: f[6] ||= (e) =>
|
|
4058
|
-
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"))
|
|
4059
4153
|
}, {
|
|
4060
4154
|
default: V(() => [
|
|
4061
4155
|
O(i.$slots, "leading", {}, () => [L.value?.icon ? (w(), a(k(L.value.icon), {
|
|
4062
4156
|
key: 0,
|
|
4063
4157
|
"aria-hidden": "true"
|
|
4064
4158
|
})) : o("", !0)]),
|
|
4065
|
-
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, {
|
|
4066
4160
|
key: String(e.value),
|
|
4067
4161
|
size: "sm"
|
|
4068
4162
|
}, l({
|
|
@@ -4072,10 +4166,10 @@ var eo = [
|
|
|
4072
4166
|
name: "leading",
|
|
4073
4167
|
fn: V(() => [(w(), a(k(e.icon), { "aria-hidden": "true" }))]),
|
|
4074
4168
|
key: "0"
|
|
4075
|
-
} : void 0]), 1024))), 128))])) : (w(), s("span",
|
|
4076
|
-
d(M(
|
|
4169
|
+
} : void 0]), 1024))), 128))])) : (w(), s("span", Fo, j(L.value?.label ?? g.value), 1)),
|
|
4170
|
+
d(M(fe), {
|
|
4077
4171
|
"aria-hidden": "true",
|
|
4078
|
-
class: y(
|
|
4172
|
+
class: y(Ko)
|
|
4079
4173
|
})
|
|
4080
4174
|
]),
|
|
4081
4175
|
_: 3
|
|
@@ -4096,27 +4190,27 @@ var eo = [
|
|
|
4096
4190
|
}, {
|
|
4097
4191
|
default: V(() => [(w(), a(k(Y.value.Viewport), { class: "flex flex-col gap-0.5 p-1 [scrollbar-width:thin]! [&::-webkit-scrollbar]:block!" }, {
|
|
4098
4192
|
default: V(() => [
|
|
4099
|
-
e.searchable ? (w(), a(M(
|
|
4193
|
+
e.searchable ? (w(), a(M(rt), {
|
|
4100
4194
|
key: 0,
|
|
4101
4195
|
class: "px-2 py-1.5 text-sm text-black/65"
|
|
4102
4196
|
}, {
|
|
4103
4197
|
default: V(() => [u(j(e.emptyText ?? M(t)("ui.select.noMatches")), 1)]),
|
|
4104
4198
|
_: 1
|
|
4105
4199
|
})) : o("", !0),
|
|
4106
|
-
|
|
4200
|
+
ue.value ? (w(), s(n, { key: 1 }, [(w(), a(k(Y.value.Item), {
|
|
4107
4201
|
value: he,
|
|
4108
4202
|
"data-back": "",
|
|
4109
4203
|
"text-value": G.value.label,
|
|
4110
4204
|
class: y(M(X)(Ce, "font-bold")),
|
|
4111
4205
|
onSelect: be
|
|
4112
4206
|
}, {
|
|
4113
|
-
default: V(() => [c("span",
|
|
4207
|
+
default: V(() => [c("span", Io, [d(M(pe), {
|
|
4114
4208
|
"aria-hidden": "true",
|
|
4115
4209
|
class: "size-4"
|
|
4116
|
-
})]), c("span",
|
|
4210
|
+
})]), c("span", Lo, [f[9] ||= c("span", { class: "sr-only" }, "Back from ", -1), u(j(G.value.label), 1)])]),
|
|
4117
4211
|
_: 1
|
|
4118
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),
|
|
4119
|
-
(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), {
|
|
4120
4214
|
key: 0,
|
|
4121
4215
|
class: "-mx-1 my-0.5 border-t border-black/15"
|
|
4122
4216
|
})) : o("", !0), (w(), a(k(Y.value.Group), { class: "flex flex-col gap-0.5" }, {
|
|
@@ -4128,7 +4222,7 @@ var eo = [
|
|
|
4128
4222
|
key: 0,
|
|
4129
4223
|
"aria-hidden": "true",
|
|
4130
4224
|
class: "size-3.5 shrink-0"
|
|
4131
|
-
})) : o("", !0), c("span",
|
|
4225
|
+
})) : o("", !0), c("span", Ro, j(e.label), 1)]),
|
|
4132
4226
|
_: 2
|
|
4133
4227
|
}, 1024)) : o("", !0), (w(!0), s(n, null, D(e.rows, (e) => (w(), a(k(Y.value.Item), {
|
|
4134
4228
|
key: e.key,
|
|
@@ -4140,24 +4234,24 @@ var eo = [
|
|
|
4140
4234
|
onSelect: (t) => e.parent && ye(t, e.option)
|
|
4141
4235
|
}, {
|
|
4142
4236
|
default: V(() => [
|
|
4143
|
-
e.option.icon ? (w(), s("span",
|
|
4237
|
+
e.option.icon ? (w(), s("span", zo, [(w(), a(k(e.option.icon), {
|
|
4144
4238
|
"aria-hidden": "true",
|
|
4145
4239
|
class: "size-4 opacity-70"
|
|
4146
4240
|
}))])) : o("", !0),
|
|
4147
|
-
c("span",
|
|
4241
|
+
c("span", Bo, [
|
|
4148
4242
|
(w(), a(k(Y.value.ItemText), { class: "truncate in-data-[state=checked]:font-bold" }, {
|
|
4149
|
-
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)]),
|
|
4150
4244
|
_: 2
|
|
4151
4245
|
}, 1024)),
|
|
4152
|
-
e.path ? (w(), s("span",
|
|
4153
|
-
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)
|
|
4154
4248
|
]),
|
|
4155
|
-
c("span",
|
|
4249
|
+
c("span", Wo, [e.parent ? (w(), a(M(me), {
|
|
4156
4250
|
key: 0,
|
|
4157
4251
|
"aria-hidden": "true",
|
|
4158
4252
|
class: "size-4 opacity-70"
|
|
4159
4253
|
})) : (w(), a(k(Y.value.Indicator), { key: 1 }, {
|
|
4160
|
-
default: V(() => [d(M(
|
|
4254
|
+
default: V(() => [d(M(de), { class: "size-4" })]),
|
|
4161
4255
|
_: 1
|
|
4162
4256
|
}))])
|
|
4163
4257
|
]),
|
|
@@ -4200,7 +4294,7 @@ var eo = [
|
|
|
4200
4294
|
"class"
|
|
4201
4295
|
]));
|
|
4202
4296
|
}
|
|
4203
|
-
}),
|
|
4297
|
+
}), Jo = { class: "flex items-start gap-2" }, Yo = /* @__PURE__ */ f({
|
|
4204
4298
|
__name: "Checkbox",
|
|
4205
4299
|
props: /*@__PURE__*/ g({
|
|
4206
4300
|
label: {},
|
|
@@ -4239,7 +4333,7 @@ var eo = [
|
|
|
4239
4333
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus",
|
|
4240
4334
|
"[&_svg]:size-3.5 [&_svg]:stroke-3"
|
|
4241
4335
|
];
|
|
4242
|
-
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), {
|
|
4243
4337
|
id: l,
|
|
4244
4338
|
modelValue: n.value,
|
|
4245
4339
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -4251,11 +4345,11 @@ var eo = [
|
|
|
4251
4345
|
"aria-describedby": p.value,
|
|
4252
4346
|
class: y(M(X)(h, e.errorText ? "border-red" : "border-black/55"))
|
|
4253
4347
|
}, {
|
|
4254
|
-
default: V(() => [d(M(
|
|
4255
|
-
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), {
|
|
4256
4350
|
key: 0,
|
|
4257
4351
|
"aria-hidden": "true"
|
|
4258
|
-
})) : (w(), a(M(
|
|
4352
|
+
})) : (w(), a(M(de), {
|
|
4259
4353
|
key: 1,
|
|
4260
4354
|
"aria-hidden": "true"
|
|
4261
4355
|
}))]),
|
|
@@ -4281,13 +4375,13 @@ var eo = [
|
|
|
4281
4375
|
key: 0,
|
|
4282
4376
|
id: u,
|
|
4283
4377
|
class: "text-xs text-black/65"
|
|
4284
|
-
}, j(e.description), 1)) : o("", !0)], 2)]), d(
|
|
4378
|
+
}, j(e.description), 1)) : o("", !0)], 2)]), d(ja, {
|
|
4285
4379
|
id: f,
|
|
4286
4380
|
status: e.errorText ? "error" : void 0,
|
|
4287
4381
|
text: e.errorText
|
|
4288
4382
|
}, null, 8, ["status", "text"])], 2));
|
|
4289
4383
|
}
|
|
4290
|
-
}),
|
|
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({
|
|
4291
4385
|
__name: "RadioGroup",
|
|
4292
4386
|
props: /*@__PURE__*/ g({
|
|
4293
4387
|
label: {},
|
|
@@ -4322,10 +4416,10 @@ var eo = [
|
|
|
4322
4416
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
4323
4417
|
];
|
|
4324
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)) }, [
|
|
4325
|
-
c("div",
|
|
4419
|
+
c("div", Xo, [c("div", Zo, [c("span", {
|
|
4326
4420
|
id: f,
|
|
4327
4421
|
class: "text-sm"
|
|
4328
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4422
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4329
4423
|
key: 0,
|
|
4330
4424
|
text: e.helper,
|
|
4331
4425
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -4334,8 +4428,8 @@ var eo = [
|
|
|
4334
4428
|
id: p,
|
|
4335
4429
|
hidden: e.helperPlacement === "icon",
|
|
4336
4430
|
class: "text-xs text-black/65"
|
|
4337
|
-
}, j(e.helper), 9,
|
|
4338
|
-
d(M(
|
|
4431
|
+
}, j(e.helper), 9, Qo)) : o("", !0)]),
|
|
4432
|
+
d(M(qt), {
|
|
4339
4433
|
modelValue: l.value,
|
|
4340
4434
|
"onUpdate:modelValue": v[0] ||= (e) => l.value = e,
|
|
4341
4435
|
name: e.name,
|
|
@@ -4349,14 +4443,14 @@ var eo = [
|
|
|
4349
4443
|
default: V(() => [(w(!0), s(n, null, D(e.options, (t, n) => (w(), s("div", {
|
|
4350
4444
|
key: String(t.value),
|
|
4351
4445
|
class: "flex items-start gap-2"
|
|
4352
|
-
}, [d(M(
|
|
4446
|
+
}, [d(M(Kt), {
|
|
4353
4447
|
id: `${M(u)}-${n}`,
|
|
4354
4448
|
value: t.value,
|
|
4355
4449
|
disabled: t.disabled,
|
|
4356
4450
|
"aria-describedby": t.description ? `${M(u)}-${n}-description` : void 0,
|
|
4357
4451
|
class: y(M(X)(_, e.errorText ? "border-red" : "border-black/55", t.disabled && !e.disabled && "opacity-40"))
|
|
4358
4452
|
}, {
|
|
4359
|
-
default: V(() => [d(M(
|
|
4453
|
+
default: V(() => [d(M(Gt), { class: "size-2 rounded-full bg-primary" })]),
|
|
4360
4454
|
_: 1
|
|
4361
4455
|
}, 8, [
|
|
4362
4456
|
"id",
|
|
@@ -4370,11 +4464,11 @@ var eo = [
|
|
|
4370
4464
|
}, [c("label", {
|
|
4371
4465
|
for: `${M(u)}-${n}`,
|
|
4372
4466
|
class: y(M(X)("text-sm", e.disabled || t.disabled ? "cursor-not-allowed" : "cursor-pointer"))
|
|
4373
|
-
}, j(t.label), 11,
|
|
4467
|
+
}, j(t.label), 11, es), t.description ? (w(), s("p", {
|
|
4374
4468
|
key: 0,
|
|
4375
4469
|
id: `${M(u)}-${n}-description`,
|
|
4376
4470
|
class: "text-xs text-black/65"
|
|
4377
|
-
}, j(t.description), 9,
|
|
4471
|
+
}, j(t.description), 9, ts)) : o("", !0)], 10, $o)]))), 128))]),
|
|
4378
4472
|
_: 1
|
|
4379
4473
|
}, 8, [
|
|
4380
4474
|
"modelValue",
|
|
@@ -4384,14 +4478,14 @@ var eo = [
|
|
|
4384
4478
|
"aria-describedby",
|
|
4385
4479
|
"aria-invalid"
|
|
4386
4480
|
]),
|
|
4387
|
-
d(
|
|
4481
|
+
d(ja, {
|
|
4388
4482
|
id: m,
|
|
4389
4483
|
status: e.errorText ? "error" : void 0,
|
|
4390
4484
|
text: e.errorText
|
|
4391
4485
|
}, null, 8, ["status", "text"])
|
|
4392
4486
|
], 2));
|
|
4393
4487
|
}
|
|
4394
|
-
}),
|
|
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({
|
|
4395
4489
|
__name: "Switch",
|
|
4396
4490
|
props: /*@__PURE__*/ g({
|
|
4397
4491
|
label: {},
|
|
@@ -4428,7 +4522,7 @@ var eo = [
|
|
|
4428
4522
|
"disabled:cursor-not-allowed",
|
|
4429
4523
|
"outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus"
|
|
4430
4524
|
];
|
|
4431
|
-
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), {
|
|
4432
4526
|
id: a,
|
|
4433
4527
|
modelValue: n.value,
|
|
4434
4528
|
"onUpdate:modelValue": i[0] ||= (e) => n.value = e,
|
|
@@ -4438,7 +4532,7 @@ var eo = [
|
|
|
4438
4532
|
"aria-describedby": m.value,
|
|
4439
4533
|
class: y(g)
|
|
4440
4534
|
}, {
|
|
4441
|
-
default: V(() => [d(M(
|
|
4535
|
+
default: V(() => [d(M(cn), { class: y(is) })]),
|
|
4442
4536
|
_: 1
|
|
4443
4537
|
}, 8, [
|
|
4444
4538
|
"modelValue",
|
|
@@ -4456,19 +4550,19 @@ var eo = [
|
|
|
4456
4550
|
key: 0,
|
|
4457
4551
|
id: l,
|
|
4458
4552
|
class: "text-xs text-black/65"
|
|
4459
|
-
}, j(e.description), 1)) : o("", !0)], 2)]), d(
|
|
4553
|
+
}, j(e.description), 1)) : o("", !0)], 2)]), d(ja, {
|
|
4460
4554
|
id: u,
|
|
4461
4555
|
status: f.value,
|
|
4462
4556
|
text: p.value
|
|
4463
4557
|
}, null, 8, ["status", "text"])], 2));
|
|
4464
4558
|
}
|
|
4465
|
-
}),
|
|
4559
|
+
}), os = [
|
|
4466
4560
|
"id",
|
|
4467
4561
|
"placeholder",
|
|
4468
4562
|
"disabled",
|
|
4469
4563
|
"aria-invalid",
|
|
4470
4564
|
"aria-describedby"
|
|
4471
|
-
],
|
|
4565
|
+
], ss = /* @__PURE__ */ f({
|
|
4472
4566
|
inheritAttrs: !1,
|
|
4473
4567
|
__name: "InputTextArea",
|
|
4474
4568
|
props: /*@__PURE__*/ g({
|
|
@@ -4496,7 +4590,7 @@ var eo = [
|
|
|
4496
4590
|
emits: ["update:modelValue"],
|
|
4497
4591
|
setup(e, { expose: t }) {
|
|
4498
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();
|
|
4499
|
-
return t({ focus: () => d.value?.focus() }), (t, r) => (w(), a(
|
|
4593
|
+
return t({ focus: () => d.value?.focus() }), (t, r) => (w(), a(Ia, {
|
|
4500
4594
|
label: e.label,
|
|
4501
4595
|
helper: e.helper,
|
|
4502
4596
|
"helper-placement": e.helperPlacement,
|
|
@@ -4518,7 +4612,7 @@ var eo = [
|
|
|
4518
4612
|
"aria-invalid": a,
|
|
4519
4613
|
"aria-describedby": i,
|
|
4520
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"
|
|
4521
|
-
}), null, 16,
|
|
4615
|
+
}), null, 16, os), [[R, o.value]])]),
|
|
4522
4616
|
_: 1
|
|
4523
4617
|
}, 8, [
|
|
4524
4618
|
"label",
|
|
@@ -4532,7 +4626,7 @@ var eo = [
|
|
|
4532
4626
|
"class"
|
|
4533
4627
|
]));
|
|
4534
4628
|
}
|
|
4535
|
-
}),
|
|
4629
|
+
}), cs = { class: "flex items-center gap-1" }, ls = ["hidden"], us = ["aria-describedby", "aria-invalid"], ds = /* @__PURE__ */ f({
|
|
4536
4630
|
__name: "CheckboxGroup",
|
|
4537
4631
|
props: /*@__PURE__*/ g({
|
|
4538
4632
|
label: {},
|
|
@@ -4560,10 +4654,10 @@ var eo = [
|
|
|
4560
4654
|
l.value = t ? [...l.value, e] : l.value.filter((t) => t !== e);
|
|
4561
4655
|
}
|
|
4562
4656
|
return (i, u) => (w(), s("div", { class: y(M(X)("flex flex-col gap-1.5 text-black", t.class)) }, [
|
|
4563
|
-
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", {
|
|
4564
4658
|
id: f,
|
|
4565
4659
|
class: "text-sm"
|
|
4566
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4660
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4567
4661
|
key: 0,
|
|
4568
4662
|
text: e.helper,
|
|
4569
4663
|
label: M(r)("ui.formField.about", { label: e.label })
|
|
@@ -4572,14 +4666,14 @@ var eo = [
|
|
|
4572
4666
|
id: p,
|
|
4573
4667
|
hidden: e.helperPlacement === "icon",
|
|
4574
4668
|
class: "text-xs text-black/65"
|
|
4575
|
-
}, j(e.helper), 9,
|
|
4669
|
+
}, j(e.helper), 9, ls)) : o("", !0)], 2),
|
|
4576
4670
|
c("div", {
|
|
4577
4671
|
role: "group",
|
|
4578
4672
|
"aria-labelledby": f,
|
|
4579
4673
|
"aria-describedby": h.value,
|
|
4580
4674
|
"aria-invalid": e.errorText ? !0 : void 0,
|
|
4581
4675
|
class: "flex flex-col gap-3"
|
|
4582
|
-
}, [(w(!0), s(n, null, D(e.options, (t) => (w(), a(
|
|
4676
|
+
}, [(w(!0), s(n, null, D(e.options, (t) => (w(), a(Yo, {
|
|
4583
4677
|
key: String(t.value),
|
|
4584
4678
|
"model-value": l.value.includes(t.value),
|
|
4585
4679
|
label: t.label,
|
|
@@ -4592,15 +4686,15 @@ var eo = [
|
|
|
4592
4686
|
"description",
|
|
4593
4687
|
"disabled",
|
|
4594
4688
|
"onUpdate:modelValue"
|
|
4595
|
-
]))), 128))], 8,
|
|
4596
|
-
d(
|
|
4689
|
+
]))), 128))], 8, us),
|
|
4690
|
+
d(ja, {
|
|
4597
4691
|
id: m,
|
|
4598
4692
|
status: e.errorText ? "error" : void 0,
|
|
4599
4693
|
text: e.errorText
|
|
4600
4694
|
}, null, 8, ["status", "text"])
|
|
4601
4695
|
], 2));
|
|
4602
4696
|
}
|
|
4603
|
-
}),
|
|
4697
|
+
}), fs = /* @__PURE__ */ f({
|
|
4604
4698
|
__name: "LanguageSwitcher",
|
|
4605
4699
|
props: {
|
|
4606
4700
|
label: {},
|
|
@@ -4630,7 +4724,7 @@ var eo = [
|
|
|
4630
4724
|
label: s(e),
|
|
4631
4725
|
value: e
|
|
4632
4726
|
})));
|
|
4633
|
-
return (i, o) => (w(), a(
|
|
4727
|
+
return (i, o) => (w(), a(qo, {
|
|
4634
4728
|
modelValue: M(r),
|
|
4635
4729
|
"onUpdate:modelValue": o[0] ||= (e) => h(r) ? r.value = e : null,
|
|
4636
4730
|
label: e.label ?? M(n)("ui.languageSwitcher.label"),
|
|
@@ -4639,7 +4733,7 @@ var eo = [
|
|
|
4639
4733
|
disabled: e.disabled,
|
|
4640
4734
|
class: y(t.class)
|
|
4641
4735
|
}, {
|
|
4642
|
-
leading: V(() => [d(M(
|
|
4736
|
+
leading: V(() => [d(M(De), { "aria-hidden": "true" })]),
|
|
4643
4737
|
_: 1
|
|
4644
4738
|
}, 8, [
|
|
4645
4739
|
"modelValue",
|
|
@@ -4650,7 +4744,7 @@ var eo = [
|
|
|
4650
4744
|
"class"
|
|
4651
4745
|
]));
|
|
4652
4746
|
}
|
|
4653
|
-
}),
|
|
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({
|
|
4654
4748
|
__name: "CardSelect",
|
|
4655
4749
|
props: /*@__PURE__*/ g({
|
|
4656
4750
|
label: {},
|
|
@@ -4693,10 +4787,10 @@ var eo = [
|
|
|
4693
4787
|
"motion-reduce:transition-none"
|
|
4694
4788
|
];
|
|
4695
4789
|
return (i, v) => (w(), s("div", { class: y(M(X)("flex flex-col gap-2 text-black", e.disabled && "opacity-40", r.class)) }, [
|
|
4696
|
-
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", {
|
|
4697
4791
|
id: f,
|
|
4698
4792
|
class: "text-sm"
|
|
4699
|
-
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(
|
|
4793
|
+
}, j(e.label), 1), e.helper && e.helperPlacement === "icon" ? (w(), a(Oa, {
|
|
4700
4794
|
key: 0,
|
|
4701
4795
|
text: e.helper,
|
|
4702
4796
|
label: M(t)("ui.formField.about", { label: e.label })
|
|
@@ -4705,8 +4799,8 @@ var eo = [
|
|
|
4705
4799
|
id: p,
|
|
4706
4800
|
hidden: e.helperPlacement === "icon",
|
|
4707
4801
|
class: "text-xs text-black/65"
|
|
4708
|
-
}, j(e.helper), 9,
|
|
4709
|
-
d(M(
|
|
4802
|
+
}, j(e.helper), 9, ms)) : o("", !0)], 2),
|
|
4803
|
+
d(M(qt), {
|
|
4710
4804
|
modelValue: l.value,
|
|
4711
4805
|
"onUpdate:modelValue": v[0] ||= (e) => l.value = e,
|
|
4712
4806
|
name: e.name,
|
|
@@ -4717,7 +4811,7 @@ var eo = [
|
|
|
4717
4811
|
"aria-invalid": e.errorText ? !0 : void 0,
|
|
4718
4812
|
class: y(M(X)("grid gap-2", g.value))
|
|
4719
4813
|
}, {
|
|
4720
|
-
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), {
|
|
4721
4815
|
id: `${M(u)}-${n}`,
|
|
4722
4816
|
key: String(t.value),
|
|
4723
4817
|
value: t.value,
|
|
@@ -4731,11 +4825,11 @@ var eo = [
|
|
|
4731
4825
|
"aria-hidden": "true",
|
|
4732
4826
|
class: "mt-0.5 size-4 shrink-0 text-black/65 group-data-[state=checked]:text-primary"
|
|
4733
4827
|
})) : o("", !0),
|
|
4734
|
-
c("span",
|
|
4828
|
+
c("span", hs, [c("span", gs, j(t.title), 1), t.description ? (w(), s("span", {
|
|
4735
4829
|
key: 0,
|
|
4736
4830
|
id: `${M(u)}-${n}-description`,
|
|
4737
4831
|
class: "text-xs text-black/65"
|
|
4738
|
-
}, j(t.description), 9,
|
|
4832
|
+
}, j(t.description), 9, _s)) : o("", !0)]),
|
|
4739
4833
|
v[1] ||= c("span", {
|
|
4740
4834
|
"aria-hidden": "true",
|
|
4741
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"
|
|
@@ -4759,14 +4853,14 @@ var eo = [
|
|
|
4759
4853
|
"aria-invalid",
|
|
4760
4854
|
"class"
|
|
4761
4855
|
]),
|
|
4762
|
-
d(
|
|
4856
|
+
d(ja, {
|
|
4763
4857
|
id: m,
|
|
4764
4858
|
status: e.errorText ? "error" : void 0,
|
|
4765
4859
|
text: e.errorText
|
|
4766
4860
|
}, null, 8, ["status", "text"])
|
|
4767
4861
|
], 2));
|
|
4768
4862
|
}
|
|
4769
|
-
}),
|
|
4863
|
+
}), ys = /* @__PURE__ */ f({
|
|
4770
4864
|
__name: "EmptyState",
|
|
4771
4865
|
props: {
|
|
4772
4866
|
title: {},
|
|
@@ -4822,15 +4916,15 @@ var eo = [
|
|
|
4822
4916
|
}, [O(r.$slots, "actions")], 2)) : o("", !0)
|
|
4823
4917
|
], 2));
|
|
4824
4918
|
}
|
|
4825
|
-
}),
|
|
4919
|
+
}), bs = new Intl.Collator("en-GB", {
|
|
4826
4920
|
numeric: !0,
|
|
4827
4921
|
sensitivity: "base"
|
|
4828
4922
|
});
|
|
4829
|
-
function
|
|
4923
|
+
function xs(e, t) {
|
|
4830
4924
|
let n = e == null || e === "", r = t == null || t === "";
|
|
4831
|
-
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));
|
|
4832
4926
|
}
|
|
4833
|
-
function
|
|
4927
|
+
function Ss(e, t, n) {
|
|
4834
4928
|
let r = n && t.find((e) => e.key === n.key);
|
|
4835
4929
|
if (!n || !r) return [...e];
|
|
4836
4930
|
let i = r.sortValue ?? ((e) => e[r.key]), a = n.direction === "asc" ? 1 : -1;
|
|
@@ -4840,10 +4934,10 @@ function as(e, t, n) {
|
|
|
4840
4934
|
value: i(e)
|
|
4841
4935
|
})).sort((e, t) => {
|
|
4842
4936
|
let n = e.value === null || e.value === void 0 || e.value === "", r = t.value === null || t.value === void 0 || t.value === "";
|
|
4843
|
-
return (n || r ?
|
|
4937
|
+
return (n || r ? xs(e.value, t.value) : a * xs(e.value, t.value)) || e.index - t.index;
|
|
4844
4938
|
}).map((e) => e.row);
|
|
4845
4939
|
}
|
|
4846
|
-
function
|
|
4940
|
+
function Cs(e, t) {
|
|
4847
4941
|
return e?.key === t ? e.direction === "asc" ? {
|
|
4848
4942
|
key: t,
|
|
4849
4943
|
direction: "desc"
|
|
@@ -4853,24 +4947,24 @@ function os(e, t) {
|
|
|
4853
4947
|
};
|
|
4854
4948
|
}
|
|
4855
4949
|
// src/components/Table/Table.vue?vue&type=script&setup=true&lang.ts
|
|
4856
|
-
var
|
|
4950
|
+
var ws = [
|
|
4857
4951
|
"tabindex",
|
|
4858
4952
|
"role",
|
|
4859
4953
|
"aria-labelledby",
|
|
4860
4954
|
"aria-label"
|
|
4861
|
-
],
|
|
4955
|
+
], Ts = ["aria-busy"], Es = {
|
|
4862
4956
|
key: 1,
|
|
4863
4957
|
class: "sr-only"
|
|
4864
|
-
},
|
|
4958
|
+
}, Ds = ["aria-sort"], Os = {
|
|
4865
4959
|
key: 0,
|
|
4866
4960
|
class: "sr-only"
|
|
4867
|
-
},
|
|
4961
|
+
}, ks = ["onClick"], As = { key: 0 }, js = ["colspan"], Ms = {
|
|
4868
4962
|
key: 0,
|
|
4869
4963
|
class: "inline-flex items-center gap-2"
|
|
4870
|
-
},
|
|
4964
|
+
}, Ns = ["onClick"], Ps = {
|
|
4871
4965
|
key: 1,
|
|
4872
4966
|
"aria-hidden": "true"
|
|
4873
|
-
},
|
|
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({
|
|
4874
4968
|
__name: "Table",
|
|
4875
4969
|
props: /*@__PURE__*/ g({
|
|
4876
4970
|
columns: {},
|
|
@@ -4920,7 +5014,7 @@ var ss = [
|
|
|
4920
5014
|
function T(e, t) {
|
|
4921
5015
|
e.target.closest("button, label, .sr-only") || t();
|
|
4922
5016
|
}
|
|
4923
|
-
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));
|
|
4924
5018
|
function I(e, t) {
|
|
4925
5019
|
return typeof r.rowKey == "function" ? r.rowKey(e, t) : r.rowKey ? e[r.rowKey] : t;
|
|
4926
5020
|
}
|
|
@@ -4948,16 +5042,16 @@ var ss = [
|
|
|
4948
5042
|
return X(e.align === "end" && "text-right", e.nowrap !== !1 && "whitespace-nowrap", e.class);
|
|
4949
5043
|
}
|
|
4950
5044
|
let W = E(), G = E(!1), q;
|
|
4951
|
-
function
|
|
5045
|
+
function te() {
|
|
4952
5046
|
let e = W.value;
|
|
4953
5047
|
e && (G.value = e.scrollWidth > e.clientWidth + 1 || e.scrollHeight > e.clientHeight + 1);
|
|
4954
5048
|
}
|
|
4955
5049
|
return C(() => {
|
|
4956
|
-
|
|
5050
|
+
te(), q = new ResizeObserver(te), W.value && (q.observe(W.value), W.value.firstElementChild && q.observe(W.value.firstElementChild));
|
|
4957
5051
|
}), S(() => q?.disconnect()), (i, f) => (w(), s("div", {
|
|
4958
5052
|
ref_key: "scroller",
|
|
4959
5053
|
ref: W,
|
|
4960
|
-
class: y(M(X)("relative overflow-auto", G.value &&
|
|
5054
|
+
class: y(M(X)("relative overflow-auto", G.value && zs, r.class)),
|
|
4961
5055
|
tabindex: G.value ? 0 : void 0,
|
|
4962
5056
|
role: G.value ? "region" : void 0,
|
|
4963
5057
|
"aria-labelledby": G.value && (e.caption || i.$slots.caption) ? p : void 0,
|
|
@@ -4974,54 +5068,54 @@ var ss = [
|
|
|
4974
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", {
|
|
4975
5069
|
key: 0,
|
|
4976
5070
|
scope: "col",
|
|
4977
|
-
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)),
|
|
4978
5072
|
onClick: f[1] ||= (e) => T(e, () => h.value.length && x(b.value !== !0))
|
|
4979
|
-
}, [h.value.length ? (w(), a(
|
|
5073
|
+
}, [h.value.length ? (w(), a(Yo, {
|
|
4980
5074
|
key: 0,
|
|
4981
5075
|
"model-value": b.value,
|
|
4982
5076
|
label: M(t)("ui.table.selectAll"),
|
|
4983
5077
|
"hide-label": "",
|
|
4984
5078
|
"onUpdate:modelValue": f[0] ||= (e) => x(e === !0)
|
|
4985
|
-
}, 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", {
|
|
4986
5080
|
key: e.key,
|
|
4987
5081
|
scope: "col",
|
|
4988
5082
|
"aria-sort": L(e),
|
|
4989
5083
|
class: y(M(X)("border-b border-black/15 font-bold text-black/65", U.value, ee(e)))
|
|
4990
|
-
}, [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", {
|
|
4991
5085
|
key: 1,
|
|
4992
5086
|
type: "button",
|
|
4993
|
-
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",
|
|
4994
|
-
onClick: (t) => l.value = M(
|
|
4995
|
-
}, [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), {
|
|
4996
5090
|
key: 0,
|
|
4997
5091
|
class: "size-4 shrink-0",
|
|
4998
5092
|
"aria-hidden": "true"
|
|
4999
|
-
})) : l.value?.key === e.key ? (w(), a(M(
|
|
5093
|
+
})) : l.value?.key === e.key ? (w(), a(M(J), {
|
|
5000
5094
|
key: 1,
|
|
5001
5095
|
class: "size-4 shrink-0",
|
|
5002
5096
|
"aria-hidden": "true"
|
|
5003
|
-
})) : (w(), a(M(
|
|
5097
|
+
})) : (w(), a(M(he), {
|
|
5004
5098
|
key: 2,
|
|
5005
5099
|
class: "size-4 shrink-0 text-black/40",
|
|
5006
5100
|
"aria-hidden": "true"
|
|
5007
|
-
}))], 10,
|
|
5101
|
+
}))], 10, ks)) : (w(), s(n, { key: 2 }, [u(j(e.label), 1)], 64))])], 10, Ds))), 128))])], 2),
|
|
5008
5102
|
c("tbody", { class: y(M(X)(e.loading && N.value.length && "opacity-50 transition-opacity")) }, [
|
|
5009
|
-
N.value.length ? o("", !0) : (w(), s("tr",
|
|
5103
|
+
N.value.length ? o("", !0) : (w(), s("tr", As, [c("td", {
|
|
5010
5104
|
colspan: A.value,
|
|
5011
5105
|
class: "px-4 py-8 text-center text-black/65"
|
|
5012
|
-
}, [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, {
|
|
5013
5107
|
size: "sm",
|
|
5014
5108
|
description: e.emptyText ?? M(t)("ui.table.empty"),
|
|
5015
5109
|
class: "p-0"
|
|
5016
|
-
}, null, 8, ["description"])], void 0, 1)], 8,
|
|
5110
|
+
}, null, 8, ["description"])], void 0, 1)], 8, js)])),
|
|
5017
5111
|
(w(!0), s(n, null, D(N.value, (r, c) => (w(), s("tr", {
|
|
5018
5112
|
key: I(r, c),
|
|
5019
5113
|
class: y(M(X)("group/row", z(r, c) && H, e.ui?.row))
|
|
5020
5114
|
}, [e.selectable ? (w(), s("td", {
|
|
5021
5115
|
key: 0,
|
|
5022
|
-
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)),
|
|
5023
5117
|
onClick: (e) => m(r) && T(e, () => v(r, c, !g(r, c)))
|
|
5024
|
-
}, [m(r) ? (w(), a(
|
|
5118
|
+
}, [m(r) ? (w(), a(Yo, {
|
|
5025
5119
|
key: 0,
|
|
5026
5120
|
"model-value": g(r, c),
|
|
5027
5121
|
label: e.rowLabel ? e.rowLabel(r, c) : M(t)("ui.table.selectRow", { n: c + 1 }),
|
|
@@ -5031,7 +5125,7 @@ var ss = [
|
|
|
5031
5125
|
"model-value",
|
|
5032
5126
|
"label",
|
|
5033
5127
|
"onUpdate:modelValue"
|
|
5034
|
-
])) : 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"), {
|
|
5035
5129
|
key: t.key,
|
|
5036
5130
|
scope: t.rowHeader ? "row" : void 0,
|
|
5037
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)))
|
|
@@ -5043,7 +5137,7 @@ var ss = [
|
|
|
5043
5137
|
"data-row-overlay": "",
|
|
5044
5138
|
tabindex: "-1",
|
|
5045
5139
|
"aria-hidden": "true",
|
|
5046
|
-
class:
|
|
5140
|
+
class: Ls
|
|
5047
5141
|
}), null, 16)) : o("", !0), t.key === R.value && z(r, c) ? (w(), a(k(e.linkComponent), _({
|
|
5048
5142
|
key: 1,
|
|
5049
5143
|
ref_for: !0
|
|
@@ -5064,33 +5158,33 @@ var ss = [
|
|
|
5064
5158
|
}, () => [u(j(r[t.key] ?? ""), 1)], void 0, 2)]),
|
|
5065
5159
|
_: 2
|
|
5066
5160
|
}, 1032, ["scope", "class"]))), 128))], 2))), 128)),
|
|
5067
|
-
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", {
|
|
5068
5162
|
colspan: A.value,
|
|
5069
5163
|
class: "h-2 p-0 sm:h-4"
|
|
5070
|
-
}, null, 8,
|
|
5164
|
+
}, null, 8, Fs)])) : o("", !0)
|
|
5071
5165
|
], 2),
|
|
5072
5166
|
i.$slots.footer ? (w(), s("tfoot", {
|
|
5073
5167
|
key: 1,
|
|
5074
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"))
|
|
5075
5169
|
}, [O(i.$slots, "footer")], 2)) : o("", !0)
|
|
5076
|
-
], 10,
|
|
5170
|
+
], 10, Ts)], 10, ws));
|
|
5077
5171
|
}
|
|
5078
|
-
}),
|
|
5172
|
+
}), Vs = { class: "flex flex-wrap items-baseline gap-x-2 gap-y-1" }, Hs = { class: "text-2xl font-bold tabular-nums" }, Us = {
|
|
5079
5173
|
key: 1,
|
|
5080
5174
|
class: "sr-only"
|
|
5081
|
-
},
|
|
5175
|
+
}, Ws = {
|
|
5082
5176
|
key: 2,
|
|
5083
5177
|
class: "font-bold tabular-nums"
|
|
5084
|
-
},
|
|
5178
|
+
}, Gs = {
|
|
5085
5179
|
key: 3,
|
|
5086
5180
|
class: "text-black/65"
|
|
5087
|
-
},
|
|
5181
|
+
}, Ks = {
|
|
5088
5182
|
key: 1,
|
|
5089
5183
|
class: "text-sm text-black/65"
|
|
5090
|
-
},
|
|
5184
|
+
}, qs = {
|
|
5091
5185
|
key: 2,
|
|
5092
5186
|
class: "mt-2 text-sm"
|
|
5093
|
-
},
|
|
5187
|
+
}, Js = /* @__PURE__ */ f({
|
|
5094
5188
|
__name: "StatTile",
|
|
5095
5189
|
props: {
|
|
5096
5190
|
label: {},
|
|
@@ -5120,23 +5214,23 @@ var ss = [
|
|
|
5120
5214
|
positive: "text-green",
|
|
5121
5215
|
negative: "text-red",
|
|
5122
5216
|
neutral: "text-black/65"
|
|
5123
|
-
}, p = i(() => n.trend === "up" ?
|
|
5217
|
+
}, p = i(() => n.trend === "up" ? ae : n.trend === "down" ? te : n.trend === "flat" ? re : void 0), m = i(() => ({
|
|
5124
5218
|
up: t("ui.statTile.up"),
|
|
5125
5219
|
down: t("ui.statTile.down"),
|
|
5126
5220
|
flat: t("ui.statTile.flat")
|
|
5127
5221
|
}));
|
|
5128
|
-
return (t, i) => (w(), a(M(
|
|
5222
|
+
return (t, i) => (w(), a(M(Ht), {
|
|
5129
5223
|
as: r.value ? e.as ?? "a" : "template",
|
|
5130
5224
|
href: r.value ? e.href : void 0,
|
|
5131
5225
|
class: y(r.value && "group block h-full cursor-pointer rounded-lg outline-2 outline-offset-2 outline-transparent focus-visible:outline-focus")
|
|
5132
5226
|
}, {
|
|
5133
|
-
default: V(() => [d(
|
|
5227
|
+
default: V(() => [d(pa, {
|
|
5134
5228
|
padding: "sm",
|
|
5135
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)),
|
|
5136
5230
|
ui: { body: "gap-1" }
|
|
5137
5231
|
}, {
|
|
5138
5232
|
default: V(() => [
|
|
5139
|
-
r.value ? (w(), a(M(
|
|
5233
|
+
r.value ? (w(), a(M(ae), {
|
|
5140
5234
|
key: 0,
|
|
5141
5235
|
class: "absolute end-4 top-4 size-4 text-black/65",
|
|
5142
5236
|
"aria-hidden": "true"
|
|
@@ -5146,7 +5240,7 @@ var ss = [
|
|
|
5146
5240
|
class: "size-4 shrink-0",
|
|
5147
5241
|
"aria-hidden": "true"
|
|
5148
5242
|
})) : o("", !0), u(" " + j(e.label), 1)], 2),
|
|
5149
|
-
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", {
|
|
5150
5244
|
key: 0,
|
|
5151
5245
|
class: y(M(X)("inline-flex items-center gap-0.5 text-sm", f[l.value]))
|
|
5152
5246
|
}, [
|
|
@@ -5155,12 +5249,12 @@ var ss = [
|
|
|
5155
5249
|
class: "size-4 shrink-0",
|
|
5156
5250
|
"aria-hidden": "true"
|
|
5157
5251
|
})) : o("", !0),
|
|
5158
|
-
e.trend ? (w(), s("span",
|
|
5159
|
-
e.change ? (w(), s("span",
|
|
5160
|
-
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)
|
|
5161
5255
|
], 2)) : o("", !0)]),
|
|
5162
|
-
e.description || t.$slots.description ? (w(), s("p",
|
|
5163
|
-
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)
|
|
5164
5258
|
]),
|
|
5165
5259
|
_: 3
|
|
5166
5260
|
}, 8, ["class"])]),
|
|
@@ -5171,19 +5265,19 @@ var ss = [
|
|
|
5171
5265
|
"class"
|
|
5172
5266
|
]));
|
|
5173
5267
|
}
|
|
5174
|
-
}),
|
|
5268
|
+
}), Ys = { class: "col-span-2 text-black/65 @sm:col-span-1" }, Xs = { class: "sr-only" }, Zs = {
|
|
5175
5269
|
key: 0,
|
|
5176
5270
|
class: "mt-0.5 block text-black/65"
|
|
5177
|
-
},
|
|
5271
|
+
}, Qs = {
|
|
5178
5272
|
key: 0,
|
|
5179
5273
|
class: "justify-self-end"
|
|
5180
|
-
},
|
|
5274
|
+
}, $s = { class: "text-black/65" }, ec = { class: "sr-only" }, tc = {
|
|
5181
5275
|
key: 0,
|
|
5182
5276
|
class: "mt-0.5 block font-normal text-black/65"
|
|
5183
|
-
},
|
|
5277
|
+
}, nc = {
|
|
5184
5278
|
key: 1,
|
|
5185
5279
|
class: "mt-1 block font-normal"
|
|
5186
|
-
},
|
|
5280
|
+
}, rc = /* @__PURE__ */ f({
|
|
5187
5281
|
__name: "SummaryList",
|
|
5188
5282
|
props: {
|
|
5189
5283
|
items: {},
|
|
@@ -5208,37 +5302,37 @@ var ss = [
|
|
|
5208
5302
|
key: r.label,
|
|
5209
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]))
|
|
5210
5304
|
}, [
|
|
5211
|
-
c("dt",
|
|
5305
|
+
c("dt", Ys, j(r.label), 1),
|
|
5212
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", {
|
|
5213
5307
|
item: r,
|
|
5214
5308
|
index: f
|
|
5215
5309
|
}, () => [i(r.value) ? (w(), s(n, { key: 1 }, [d[0] ||= c("span", {
|
|
5216
5310
|
class: "text-black/40",
|
|
5217
5311
|
"aria-hidden": "true"
|
|
5218
|
-
}, "—", -1), c("span",
|
|
5219
|
-
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", {
|
|
5220
5314
|
item: r,
|
|
5221
5315
|
index: f
|
|
5222
5316
|
})])) : o("", !0)
|
|
5223
5317
|
], 2))), 128)) : (w(!0), s(n, { key: 1 }, D(e.items, (r, a) => (w(), s("div", {
|
|
5224
5318
|
key: r.label,
|
|
5225
5319
|
class: y(e.layout === "compact" ? "col-span-2 grid grid-cols-subgrid items-baseline" : "flex min-w-0 flex-col gap-1")
|
|
5226
|
-
}, [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")) }, [
|
|
5227
5321
|
O(l.$slots, "value", {
|
|
5228
5322
|
item: r,
|
|
5229
5323
|
index: a
|
|
5230
5324
|
}, () => [i(r.value) ? (w(), s(n, { key: 1 }, [d[1] ||= c("span", {
|
|
5231
5325
|
class: "text-black/40",
|
|
5232
5326
|
"aria-hidden": "true"
|
|
5233
|
-
}, "—", -1), c("span",
|
|
5234
|
-
r.description ? (w(), s("span",
|
|
5235
|
-
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", {
|
|
5236
5330
|
item: r,
|
|
5237
5331
|
index: a
|
|
5238
5332
|
})])) : o("", !0)
|
|
5239
5333
|
], 2)], 2))), 128))], 2)], 2));
|
|
5240
5334
|
}
|
|
5241
|
-
}),
|
|
5335
|
+
}), ic = { class: "flex h-5 shrink-0 items-center" }, ac = { class: "sr-only" }, oc = /* @__PURE__ */ f({
|
|
5242
5336
|
__name: "Checklist",
|
|
5243
5337
|
props: {
|
|
5244
5338
|
items: {},
|
|
@@ -5256,19 +5350,19 @@ var ss = [
|
|
|
5256
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", {
|
|
5257
5351
|
key: t.label,
|
|
5258
5352
|
class: "flex items-start gap-2"
|
|
5259
|
-
}, [c("span",
|
|
5353
|
+
}, [c("span", ic, [t.done ? (w(), a(M(ve), {
|
|
5260
5354
|
key: 0,
|
|
5261
5355
|
class: "size-4 text-green",
|
|
5262
5356
|
"aria-hidden": "true"
|
|
5263
|
-
})) : (w(), a(M(
|
|
5357
|
+
})) : (w(), a(M(ge), {
|
|
5264
5358
|
key: 1,
|
|
5265
5359
|
class: y(M(X)("size-4", e.invalid ? "text-red" : "text-black/40")),
|
|
5266
5360
|
"aria-hidden": "true"
|
|
5267
|
-
}, 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));
|
|
5268
5362
|
}
|
|
5269
5363
|
});
|
|
5270
5364
|
// src/lib/dates.ts
|
|
5271
|
-
function
|
|
5365
|
+
function sc(e) {
|
|
5272
5366
|
if (e instanceof Date) return e;
|
|
5273
5367
|
if (typeof e == "string" && /^\d{4}-\d{2}-\d{2}$/.test(e)) {
|
|
5274
5368
|
let [t, n, r] = e.split("-").map(Number);
|
|
@@ -5276,59 +5370,59 @@ function Ws(e) {
|
|
|
5276
5370
|
}
|
|
5277
5371
|
return new Date(e);
|
|
5278
5372
|
}
|
|
5279
|
-
var
|
|
5373
|
+
var cc = [
|
|
5280
5374
|
["year", 31536e3],
|
|
5281
5375
|
["month", 2592e3],
|
|
5282
5376
|
["week", 604800],
|
|
5283
5377
|
["day", 86400],
|
|
5284
5378
|
["hour", 3600],
|
|
5285
5379
|
["minute", 60]
|
|
5286
|
-
],
|
|
5287
|
-
function
|
|
5288
|
-
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);
|
|
5289
5383
|
if (Math.abs(n) < 60) return "Just now";
|
|
5290
|
-
for (let [e, t] of
|
|
5291
|
-
let r =
|
|
5384
|
+
for (let [e, t] of cc) if (Math.abs(n) >= t) {
|
|
5385
|
+
let r = lc.format(Math.trunc(n / t), e);
|
|
5292
5386
|
return r.charAt(0).toUpperCase() + r.slice(1);
|
|
5293
5387
|
}
|
|
5294
5388
|
return "Just now";
|
|
5295
5389
|
}
|
|
5296
|
-
function
|
|
5297
|
-
let t =
|
|
5390
|
+
function dc(e) {
|
|
5391
|
+
let t = sc(e), n = t.toLocaleDateString("en-GB", { weekday: "long" }), r = t.toLocaleTimeString("en-GB", {
|
|
5298
5392
|
hour: "2-digit",
|
|
5299
5393
|
minute: "2-digit"
|
|
5300
5394
|
});
|
|
5301
|
-
return `${n} ${
|
|
5395
|
+
return `${n} ${fc(t)} at ${r}`;
|
|
5302
5396
|
}
|
|
5303
|
-
function
|
|
5304
|
-
return
|
|
5397
|
+
function fc(e) {
|
|
5398
|
+
return sc(e).toLocaleDateString("en-GB", {
|
|
5305
5399
|
day: "numeric",
|
|
5306
5400
|
month: "long",
|
|
5307
5401
|
year: "numeric"
|
|
5308
5402
|
});
|
|
5309
5403
|
}
|
|
5310
|
-
function
|
|
5311
|
-
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();
|
|
5312
5406
|
return (i < 0 || i === 0 && t.getDate() < n.getDate()) && r--, r;
|
|
5313
5407
|
}
|
|
5314
|
-
function
|
|
5315
|
-
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) => {
|
|
5316
5410
|
let t = new Date(e, n.getMonth(), n.getDate());
|
|
5317
5411
|
return t.getMonth() === n.getMonth() ? t : new Date(e, 2, 1);
|
|
5318
5412
|
}, a = i(r.getFullYear());
|
|
5319
5413
|
return a < r && (a = i(r.getFullYear() + 1)), Math.round((a.getTime() - r.getTime()) / 864e5);
|
|
5320
5414
|
}
|
|
5321
5415
|
// src/lib/useNow.ts
|
|
5322
|
-
var
|
|
5323
|
-
function
|
|
5416
|
+
var hc = E(/* @__PURE__ */ new Date()), gc = 0, _c;
|
|
5417
|
+
function vc() {
|
|
5324
5418
|
return C(() => {
|
|
5325
|
-
|
|
5419
|
+
gc++ === 0 && (hc.value = /* @__PURE__ */ new Date(), _c = setInterval(() => hc.value = /* @__PURE__ */ new Date(), 3e4));
|
|
5326
5420
|
}), S(() => {
|
|
5327
|
-
|
|
5328
|
-
}),
|
|
5421
|
+
--gc === 0 && clearInterval(_c);
|
|
5422
|
+
}), hc;
|
|
5329
5423
|
}
|
|
5330
5424
|
// src/components/RelativeTime/RelativeTime.vue?vue&type=script&setup=true&lang.ts
|
|
5331
|
-
var
|
|
5425
|
+
var yc = ["datetime"], bc = /* @__PURE__ */ f({
|
|
5332
5426
|
__name: "RelativeTime",
|
|
5333
5427
|
props: {
|
|
5334
5428
|
date: {},
|
|
@@ -5343,17 +5437,17 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5343
5437
|
] }
|
|
5344
5438
|
},
|
|
5345
5439
|
setup(e) {
|
|
5346
|
-
let t = e, n =
|
|
5347
|
-
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 }, {
|
|
5348
5442
|
default: V(() => [c("time", {
|
|
5349
5443
|
datetime: r.value.toISOString(),
|
|
5350
5444
|
tabindex: "0",
|
|
5351
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))
|
|
5352
|
-
}, j(o.value), 11,
|
|
5446
|
+
}, j(o.value), 11, yc)]),
|
|
5353
5447
|
_: 1
|
|
5354
5448
|
}, 8, ["text"]));
|
|
5355
5449
|
}
|
|
5356
|
-
}),
|
|
5450
|
+
}), xc = ["data-birth-date"], Sc = /* @__PURE__ */ f({
|
|
5357
5451
|
__name: "Age",
|
|
5358
5452
|
props: {
|
|
5359
5453
|
birthDate: {},
|
|
@@ -5368,26 +5462,26 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5368
5462
|
] }
|
|
5369
5463
|
},
|
|
5370
5464
|
setup(e) {
|
|
5371
|
-
let { t } = K(), r = e, l =
|
|
5372
|
-
let e =
|
|
5373
|
-
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}`;
|
|
5374
5468
|
}), h = i(() => {
|
|
5375
5469
|
let e = d.value;
|
|
5376
5470
|
return `${e.getFullYear()}-${String(e.getMonth() + 1).padStart(2, "0")}-${String(e.getDate()).padStart(2, "0")}`;
|
|
5377
5471
|
});
|
|
5378
|
-
return (t, i) => (w(), a(
|
|
5472
|
+
return (t, i) => (w(), a(xo, { text: m.value }, {
|
|
5379
5473
|
default: V(() => [c("span", {
|
|
5380
5474
|
tabindex: "0",
|
|
5381
5475
|
"data-birth-date": h.value,
|
|
5382
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))
|
|
5383
|
-
}, [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)]),
|
|
5384
5478
|
_: 1
|
|
5385
5479
|
}, 8, ["text"]));
|
|
5386
5480
|
}
|
|
5387
|
-
}),
|
|
5481
|
+
}), Cc = {
|
|
5388
5482
|
class: "text-sm text-black/65",
|
|
5389
5483
|
"aria-live": "polite"
|
|
5390
|
-
},
|
|
5484
|
+
}, wc = { class: "text-black" }, Tc = /* @__PURE__ */ f({
|
|
5391
5485
|
__name: "Steps",
|
|
5392
5486
|
props: {
|
|
5393
5487
|
steps: {},
|
|
@@ -5403,16 +5497,16 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5403
5497
|
},
|
|
5404
5498
|
setup(e) {
|
|
5405
5499
|
let t = e;
|
|
5406
|
-
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), {
|
|
5407
5501
|
keypath: "ui.steps.stepOfNamed",
|
|
5408
5502
|
scope: "global",
|
|
5409
5503
|
tag: "span"
|
|
5410
5504
|
}, {
|
|
5411
5505
|
current: V(() => [u(j(e.step + 1), 1)]),
|
|
5412
5506
|
total: V(() => [u(j(e.steps.length), 1)]),
|
|
5413
|
-
name: V(() => [c("span",
|
|
5507
|
+
name: V(() => [c("span", wc, j(e.steps[e.step]), 1)]),
|
|
5414
5508
|
_: 1
|
|
5415
|
-
})]), d(
|
|
5509
|
+
})]), d(yi, {
|
|
5416
5510
|
label: e.label,
|
|
5417
5511
|
segments: "",
|
|
5418
5512
|
value: e.step + 1,
|
|
@@ -5423,7 +5517,7 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5423
5517
|
"max"
|
|
5424
5518
|
])], 2));
|
|
5425
5519
|
}
|
|
5426
|
-
}),
|
|
5520
|
+
}), Ec = /* @__PURE__ */ f({
|
|
5427
5521
|
__name: "Tabs",
|
|
5428
5522
|
props: /*@__PURE__*/ g({
|
|
5429
5523
|
tabs: {},
|
|
@@ -5449,16 +5543,16 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5449
5543
|
"focus-visible:rounded focus-visible:ring-2 focus-visible:ring-primary",
|
|
5450
5544
|
"data-disabled:cursor-not-allowed data-disabled:opacity-40"
|
|
5451
5545
|
];
|
|
5452
|
-
return (l, f) => (w(), a(M(
|
|
5546
|
+
return (l, f) => (w(), a(M(fn), {
|
|
5453
5547
|
"model-value": r.value ?? e.tabs[0]?.value,
|
|
5454
5548
|
class: y(M(X)("flex flex-col gap-6", t.class)),
|
|
5455
5549
|
"onUpdate:modelValue": f[0] ||= (e) => r.value = String(e)
|
|
5456
5550
|
}, {
|
|
5457
|
-
default: V(() => [d(M(
|
|
5551
|
+
default: V(() => [d(M(dn), {
|
|
5458
5552
|
"aria-label": e.label,
|
|
5459
5553
|
class: "relative flex overflow-x-auto overflow-y-hidden border-b border-black/15"
|
|
5460
5554
|
}, {
|
|
5461
|
-
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), {
|
|
5462
5556
|
key: e.value,
|
|
5463
5557
|
value: e.value,
|
|
5464
5558
|
disabled: e.disabled,
|
|
@@ -5469,12 +5563,12 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5469
5563
|
"aria-hidden": "true"
|
|
5470
5564
|
})) : o("", !0), u(" " + j(e.label), 1)]),
|
|
5471
5565
|
_: 2
|
|
5472
|
-
}, 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" }, {
|
|
5473
5567
|
default: V(() => [...f[1] ||= [c("span", { class: "block size-full rounded-full bg-primary" }, null, -1)]]),
|
|
5474
5568
|
_: 1
|
|
5475
5569
|
})]),
|
|
5476
5570
|
_: 1
|
|
5477
|
-
}, 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), {
|
|
5478
5572
|
key: e.value,
|
|
5479
5573
|
value: e.value,
|
|
5480
5574
|
class: "outline-none"
|
|
@@ -5485,11 +5579,11 @@ var nc = ["datetime"], rc = /* @__PURE__ */ f({
|
|
|
5485
5579
|
_: 3
|
|
5486
5580
|
}, 8, ["model-value", "class"]));
|
|
5487
5581
|
}
|
|
5488
|
-
}),
|
|
5489
|
-
function
|
|
5582
|
+
}), Dc = 0, Oc = () => `notification-${Date.now().toString(36)}-${(Dc++).toString(36)}`;
|
|
5583
|
+
function kc(e, t) {
|
|
5490
5584
|
return t === void 0 ? e.type === "error" ? Infinity : e.action ? e.compact ? 1e4 : Infinity : 6e3 : t;
|
|
5491
5585
|
}
|
|
5492
|
-
function
|
|
5586
|
+
function Ac(e = []) {
|
|
5493
5587
|
let t = T({
|
|
5494
5588
|
items: e.map(n).sort((e, t) => t.createdAt.getTime() - e.createdAt.getTime()),
|
|
5495
5589
|
toasts: [],
|
|
@@ -5499,7 +5593,7 @@ function pc(e = []) {
|
|
|
5499
5593
|
function n(e) {
|
|
5500
5594
|
return {
|
|
5501
5595
|
...e,
|
|
5502
|
-
id: e.id ??
|
|
5596
|
+
id: e.id ?? Oc(),
|
|
5503
5597
|
type: e.type ?? "info",
|
|
5504
5598
|
createdAt: e.createdAt ?? /* @__PURE__ */ new Date(),
|
|
5505
5599
|
read: e.read ?? !1
|
|
@@ -5509,7 +5603,7 @@ function pc(e = []) {
|
|
|
5509
5603
|
let i = n(e);
|
|
5510
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), {
|
|
5511
5605
|
id: i.id,
|
|
5512
|
-
duration:
|
|
5606
|
+
duration: kc(i, r.duration),
|
|
5513
5607
|
item: i
|
|
5514
5608
|
}]), i.id;
|
|
5515
5609
|
}
|
|
@@ -5558,25 +5652,25 @@ function pc(e = []) {
|
|
|
5558
5652
|
markAllRead: c
|
|
5559
5653
|
};
|
|
5560
5654
|
}
|
|
5561
|
-
var
|
|
5562
|
-
function
|
|
5563
|
-
return
|
|
5655
|
+
var jc;
|
|
5656
|
+
function Mc() {
|
|
5657
|
+
return jc ??= Ac();
|
|
5564
5658
|
}
|
|
5565
5659
|
// src/components/Notification/Notification.vue?vue&type=script&setup=true&lang.ts
|
|
5566
|
-
var
|
|
5660
|
+
var Nc = { class: "sr-only" }, Pc = {
|
|
5567
5661
|
key: 0,
|
|
5568
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"
|
|
5569
|
-
},
|
|
5663
|
+
}, Fc = {
|
|
5570
5664
|
key: 1,
|
|
5571
5665
|
class: "flex items-center gap-1.5 text-xs text-black/65"
|
|
5572
|
-
},
|
|
5666
|
+
}, Ic = {
|
|
5573
5667
|
key: 0,
|
|
5574
5668
|
class: "size-2 shrink-0 rounded-full bg-primary",
|
|
5575
5669
|
"aria-hidden": "true"
|
|
5576
|
-
},
|
|
5670
|
+
}, Lc = {
|
|
5577
5671
|
key: 1,
|
|
5578
5672
|
class: "sr-only"
|
|
5579
|
-
},
|
|
5673
|
+
}, Rc = ["href"], zc = /* @__PURE__ */ f({
|
|
5580
5674
|
__name: "Notification",
|
|
5581
5675
|
props: {
|
|
5582
5676
|
type: { default: "info" },
|
|
@@ -5605,22 +5699,22 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5605
5699
|
setup(e, { emit: t }) {
|
|
5606
5700
|
let { t: n } = K(), r = e, l = t, f = `${P()}-title`, p = {
|
|
5607
5701
|
info: {
|
|
5608
|
-
icon:
|
|
5702
|
+
icon: Te,
|
|
5609
5703
|
colour: "text-blue",
|
|
5610
5704
|
word: "Information"
|
|
5611
5705
|
},
|
|
5612
5706
|
success: {
|
|
5613
|
-
icon:
|
|
5707
|
+
icon: ve,
|
|
5614
5708
|
colour: "text-green",
|
|
5615
5709
|
word: "Success"
|
|
5616
5710
|
},
|
|
5617
5711
|
warning: {
|
|
5618
|
-
icon:
|
|
5712
|
+
icon: Re,
|
|
5619
5713
|
colour: "text-yellow",
|
|
5620
5714
|
word: "Warning"
|
|
5621
5715
|
},
|
|
5622
5716
|
error: {
|
|
5623
|
-
icon:
|
|
5717
|
+
icon: be,
|
|
5624
5718
|
colour: "text-red",
|
|
5625
5719
|
word: "Error"
|
|
5626
5720
|
}
|
|
@@ -5641,12 +5735,12 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5641
5735
|
c("p", {
|
|
5642
5736
|
id: f,
|
|
5643
5737
|
class: y(M(X)("font-bold", h.value && "min-w-0 flex-1 py-1"))
|
|
5644
|
-
}, [c("span",
|
|
5645
|
-
!h.value && (e.description || t.$slots.default) ? (w(), s("div",
|
|
5646
|
-
e.appearance === "row" && (e.createdAt || e.unread) ? (w(), s("p",
|
|
5647
|
-
e.unread ? (w(), s("span",
|
|
5648
|
-
e.unread ? (w(), s("span",
|
|
5649
|
-
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, {
|
|
5650
5744
|
key: 2,
|
|
5651
5745
|
date: e.createdAt,
|
|
5652
5746
|
now: e.now
|
|
@@ -5661,7 +5755,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5661
5755
|
"as-child": "",
|
|
5662
5756
|
onClick: g
|
|
5663
5757
|
}, {
|
|
5664
|
-
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)]),
|
|
5665
5759
|
_: 1
|
|
5666
5760
|
})) : e.action ? (w(), a(Z, {
|
|
5667
5761
|
key: 1,
|
|
@@ -5682,16 +5776,16 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5682
5776
|
"aria-label": e.dismissLabel ?? M(n)("ui.notifications.dismiss", { title: e.title }),
|
|
5683
5777
|
onClick: i[0] ||= (e) => l("dismiss")
|
|
5684
5778
|
}, {
|
|
5685
|
-
default: V(() => [d(M(
|
|
5779
|
+
default: V(() => [d(M(Ve))]),
|
|
5686
5780
|
_: 1
|
|
5687
5781
|
}, 8, ["class", "aria-label"])) : o("", !0)
|
|
5688
5782
|
], 2));
|
|
5689
5783
|
}
|
|
5690
|
-
}),
|
|
5784
|
+
}), Bc = {
|
|
5691
5785
|
key: 0,
|
|
5692
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",
|
|
5693
5787
|
"aria-hidden": "true"
|
|
5694
|
-
},
|
|
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({
|
|
5695
5789
|
__name: "NotificationPane",
|
|
5696
5790
|
props: /*@__PURE__*/ g({
|
|
5697
5791
|
notifications: {},
|
|
@@ -5707,7 +5801,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5707
5801
|
}),
|
|
5708
5802
|
emits: ["update:open"],
|
|
5709
5803
|
setup(e) {
|
|
5710
|
-
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", {
|
|
5711
5805
|
label: g.value,
|
|
5712
5806
|
count: h.value
|
|
5713
5807
|
}) : g.value), b = `${P()}-heading`, x = E(), S = E();
|
|
@@ -5743,7 +5837,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5743
5837
|
easing: "cubic-bezier(0, 0, 0.2, 1)"
|
|
5744
5838
|
});
|
|
5745
5839
|
}
|
|
5746
|
-
return (r, i) => (w(), a(
|
|
5840
|
+
return (r, i) => (w(), a(er, {
|
|
5747
5841
|
open: l.value,
|
|
5748
5842
|
"onUpdate:open": i[1] ||= (e) => l.value = e,
|
|
5749
5843
|
content: {
|
|
@@ -5757,7 +5851,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5757
5851
|
ref: C,
|
|
5758
5852
|
"aria-labelledby": b,
|
|
5759
5853
|
class: "flex min-h-0 flex-col"
|
|
5760
|
-
}, [c("div",
|
|
5854
|
+
}, [c("div", Vc, [c("h2", {
|
|
5761
5855
|
id: b,
|
|
5762
5856
|
ref_key: "heading",
|
|
5763
5857
|
ref: x,
|
|
@@ -5782,7 +5876,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5782
5876
|
}, [(w(!0), s(n, null, D(p.value, (e, t) => (w(), s("li", {
|
|
5783
5877
|
key: e.id,
|
|
5784
5878
|
class: "border-b border-black/15 last:border-b-0"
|
|
5785
|
-
}, [d(
|
|
5879
|
+
}, [d(zc, {
|
|
5786
5880
|
appearance: "row",
|
|
5787
5881
|
type: e.type,
|
|
5788
5882
|
title: e.title,
|
|
@@ -5801,10 +5895,10 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5801
5895
|
"unread",
|
|
5802
5896
|
"onDismiss",
|
|
5803
5897
|
"onAction"
|
|
5804
|
-
])]))), 128))], 42,
|
|
5898
|
+
])]))), 128))], 42, Hc)) : (w(), a(ys, {
|
|
5805
5899
|
key: 1,
|
|
5806
5900
|
size: "sm",
|
|
5807
|
-
icon: M(
|
|
5901
|
+
icon: M(se),
|
|
5808
5902
|
description: e.emptyText ?? M(t)("ui.notifications.empty"),
|
|
5809
5903
|
class: y(M(X)(O.value && "motion-safe:animate-empty-in")),
|
|
5810
5904
|
ui: { icon: M(X)("origin-top", O.value && "motion-safe:animate-bell-wobble") }
|
|
@@ -5820,13 +5914,13 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5820
5914
|
"aria-label": _.value,
|
|
5821
5915
|
class: y(M(X)("relative overflow-visible", e.ui?.trigger))
|
|
5822
5916
|
}, {
|
|
5823
|
-
default: V(() => [d(M(
|
|
5917
|
+
default: V(() => [d(M(oe)), m.value ? (w(), s("span", Bc, j(h.value), 1)) : o("", !0)]),
|
|
5824
5918
|
_: 1
|
|
5825
5919
|
}, 8, ["aria-label", "class"])]),
|
|
5826
5920
|
_: 1
|
|
5827
5921
|
}, 8, ["open", "ui"]));
|
|
5828
5922
|
}
|
|
5829
|
-
}),
|
|
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({
|
|
5830
5924
|
__name: "Toaster",
|
|
5831
5925
|
props: {
|
|
5832
5926
|
notifications: {},
|
|
@@ -5843,15 +5937,15 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5843
5937
|
},
|
|
5844
5938
|
emits: ["more"],
|
|
5845
5939
|
setup(e, { emit: t }) {
|
|
5846
|
-
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;
|
|
5847
5941
|
C(() => window.addEventListener("resize", g)), S(() => window.removeEventListener("resize", g));
|
|
5848
|
-
let _ = i(() => Math.max(h.value -
|
|
5849
|
-
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();
|
|
5850
5944
|
if (r <= _.value) n.forEach((e) => i.add(e.id));
|
|
5851
5945
|
else {
|
|
5852
5946
|
let e = 44;
|
|
5853
5947
|
for (let r of n) {
|
|
5854
|
-
let n = e + t(r) + (i.size ?
|
|
5948
|
+
let n = e + t(r) + (i.size ? qc : 0);
|
|
5855
5949
|
if (i.size && n > _.value) break;
|
|
5856
5950
|
i.add(r.id), e = n;
|
|
5857
5951
|
}
|
|
@@ -5876,7 +5970,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5876
5970
|
z(() => p.value.paneOpen, (e) => {
|
|
5877
5971
|
if (!e) return;
|
|
5878
5972
|
let t = new Set(k.value.map((e) => e.id));
|
|
5879
|
-
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);
|
|
5880
5974
|
});
|
|
5881
5975
|
function I() {
|
|
5882
5976
|
p.value.openPane(), f("more");
|
|
@@ -5899,23 +5993,23 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5899
5993
|
})));
|
|
5900
5994
|
}
|
|
5901
5995
|
let W = T(/* @__PURE__ */ new Set()), G = /* @__PURE__ */ new Map();
|
|
5902
|
-
function
|
|
5996
|
+
function q(e, t) {
|
|
5903
5997
|
t || W.has(e) || (W.add(e), setTimeout(() => {
|
|
5904
5998
|
p.value.hideToast(e), W.delete(e), U.delete(e), G.delete(e), L.delete(e);
|
|
5905
5999
|
}, 200));
|
|
5906
6000
|
}
|
|
5907
|
-
let
|
|
6001
|
+
let J = i(() => {
|
|
5908
6002
|
let e = k.value.filter((e) => !W.has(e.id)), t = /* @__PURE__ */ new Map(), n = [], r = 0;
|
|
5909
|
-
for (let t of e) n.push(r), r += (L.get(t.id) ?? 0) +
|
|
5910
|
-
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;
|
|
5911
6005
|
for (; o < e.length && (o === 0 || n[o] + (L.get(e[o].id) ?? 0) <= a);) o++;
|
|
5912
|
-
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;
|
|
5913
6007
|
e.forEach((r, i) => {
|
|
5914
6008
|
let a = i >= o;
|
|
5915
6009
|
t.set(r.id, {
|
|
5916
6010
|
spread: n[i],
|
|
5917
6011
|
stacked: a ? d : n[i],
|
|
5918
|
-
scale: a ?
|
|
6012
|
+
scale: a ? Jc : 1,
|
|
5919
6013
|
opacity: +!a,
|
|
5920
6014
|
z: e.length - i
|
|
5921
6015
|
});
|
|
@@ -5926,19 +6020,19 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5926
6020
|
places: t,
|
|
5927
6021
|
spreadHeight: i + (A.value > 0 ? 44 : 0),
|
|
5928
6022
|
stackedHeight: p,
|
|
5929
|
-
moreOffset: i + (i ?
|
|
6023
|
+
moreOffset: i + (i ? qc : 0),
|
|
5930
6024
|
notInView: f,
|
|
5931
6025
|
pillOffset: d
|
|
5932
6026
|
};
|
|
5933
6027
|
});
|
|
5934
|
-
function
|
|
5935
|
-
let t = W.has(e) ? G.get(e) :
|
|
5936
|
-
"--toast-spread": r(
|
|
5937
|
-
"--toast-stacked": r(
|
|
5938
|
-
"--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,
|
|
5939
6033
|
"--toast-opacity": 0,
|
|
5940
6034
|
"--toast-spread-opacity": 0,
|
|
5941
|
-
"--toast-spread-scale":
|
|
6035
|
+
"--toast-spread-scale": Jc,
|
|
5942
6036
|
"--toast-z": 0
|
|
5943
6037
|
};
|
|
5944
6038
|
if (!t && N.has(e) || t && !U.has(e) && P.has(e)) return i;
|
|
@@ -5964,9 +6058,9 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5964
6058
|
"--toast-z": t.z
|
|
5965
6059
|
};
|
|
5966
6060
|
}
|
|
5967
|
-
let
|
|
5968
|
-
"--toast-more": `${
|
|
5969
|
-
"--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`
|
|
5970
6064
|
}));
|
|
5971
6065
|
function ie(e) {
|
|
5972
6066
|
e.currentTarget.closest("[data-expanded]") ? I() : ae();
|
|
@@ -5976,27 +6070,27 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
5976
6070
|
(e && R.get(e.id)?.parentElement)?.focus({ focusVisible: !1 });
|
|
5977
6071
|
}
|
|
5978
6072
|
let oe = i(() => ({
|
|
5979
|
-
"--toast-stack-spread": `${
|
|
5980
|
-
"--toast-stack-stacked": `${
|
|
6073
|
+
"--toast-stack-spread": `${J.value.spreadHeight}px`,
|
|
6074
|
+
"--toast-stack-stacked": `${J.value.stackedHeight}px`
|
|
5981
6075
|
})), se = {
|
|
5982
6076
|
"bottom-right": "right-4 bottom-4 left-4 sm:left-auto sm:w-96",
|
|
5983
6077
|
"top-right": "top-16 right-4 left-4 sm:left-auto sm:w-96",
|
|
5984
6078
|
"bottom-center": "bottom-4 left-1/2 w-[calc(100%-2rem)] -translate-x-1/2 sm:w-96"
|
|
5985
6079
|
};
|
|
5986
|
-
return (t, i) => (w(), a(M(
|
|
6080
|
+
return (t, i) => (w(), a(M(mn), {
|
|
5987
6081
|
"swipe-direction": "right",
|
|
5988
6082
|
label: M(r)("ui.notifications.region")
|
|
5989
6083
|
}, {
|
|
5990
|
-
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), {
|
|
5991
6085
|
key: e.id,
|
|
5992
6086
|
open: !W.has(e.id),
|
|
5993
6087
|
duration: e.duration,
|
|
5994
6088
|
type: e.item.type === "error" || e.item.type === "warning" ? "foreground" : "background",
|
|
5995
|
-
style: x(
|
|
6089
|
+
style: x(te(e.id)),
|
|
5996
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")),
|
|
5997
|
-
"onUpdate:open": (t) =>
|
|
6091
|
+
"onUpdate:open": (t) => q(e.id, t)
|
|
5998
6092
|
}, {
|
|
5999
|
-
default: V(() => [d(
|
|
6093
|
+
default: V(() => [d(zc, {
|
|
6000
6094
|
ref_for: !0,
|
|
6001
6095
|
ref: (t) => H(e.id, t),
|
|
6002
6096
|
type: e.item.type,
|
|
@@ -6006,8 +6100,8 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6006
6100
|
compact: e.item.compact,
|
|
6007
6101
|
class: "shadow-md",
|
|
6008
6102
|
"dismiss-label": M(r)("ui.notifications.close", { title: e.item.title }),
|
|
6009
|
-
onDismiss: (t) =>
|
|
6010
|
-
onAction: (t) =>
|
|
6103
|
+
onDismiss: (t) => q(e.id, !1),
|
|
6104
|
+
onAction: (t) => q(e.id, !1)
|
|
6011
6105
|
}, null, 8, [
|
|
6012
6106
|
"type",
|
|
6013
6107
|
"title",
|
|
@@ -6026,20 +6120,20 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6026
6120
|
"style",
|
|
6027
6121
|
"class",
|
|
6028
6122
|
"onUpdate:open"
|
|
6029
|
-
]))), 128)), d(M(
|
|
6123
|
+
]))), 128)), d(M(gn), {
|
|
6030
6124
|
label: M(r)("ui.notifications.hotkeyRegion", { hotkey: "{hotkey}" }),
|
|
6031
6125
|
style: x(oe.value),
|
|
6032
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))
|
|
6033
6127
|
}, {
|
|
6034
|
-
default: V(() => [
|
|
6128
|
+
default: V(() => [J.value.notInView ? (w(), s("li", {
|
|
6035
6129
|
key: 0,
|
|
6036
|
-
style: x(
|
|
6130
|
+
style: x(re.value),
|
|
6037
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"))
|
|
6038
6132
|
}, [c("button", {
|
|
6039
6133
|
type: "button",
|
|
6040
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")),
|
|
6041
6135
|
onClick: ie
|
|
6042
|
-
}, [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)]),
|
|
6043
6137
|
_: 1
|
|
6044
6138
|
}, 8, [
|
|
6045
6139
|
"label",
|
|
@@ -6049,14 +6143,14 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6049
6143
|
_: 1
|
|
6050
6144
|
}, 8, ["label"]));
|
|
6051
6145
|
}
|
|
6052
|
-
}),
|
|
6146
|
+
}), Zc = {
|
|
6053
6147
|
key: 0,
|
|
6054
6148
|
"aria-hidden": "true",
|
|
6055
6149
|
class: "h-20"
|
|
6056
|
-
},
|
|
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 = {
|
|
6057
6151
|
role: "status",
|
|
6058
6152
|
class: "flex items-center gap-2 text-sm font-bold"
|
|
6059
|
-
},
|
|
6153
|
+
}, tl = { class: "flex shrink-0 items-center gap-2" }, nl = /* @__PURE__ */ f({
|
|
6060
6154
|
__name: "UnsavedChangesBar",
|
|
6061
6155
|
props: {
|
|
6062
6156
|
open: { type: Boolean },
|
|
@@ -6079,7 +6173,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6079
6173
|
emits: ["discard", "save"],
|
|
6080
6174
|
setup(e, { emit: t }) {
|
|
6081
6175
|
let { t: a } = K(), l = e, f = t, p = i(() => l.status === "loading");
|
|
6082
|
-
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, {
|
|
6083
6177
|
"enter-active-class": "transition duration-300 ease-out motion-reduce:transition-none",
|
|
6084
6178
|
"leave-active-class": "transition duration-200 ease-in motion-reduce:transition-none",
|
|
6085
6179
|
"enter-from-class": "translate-y-full motion-reduce:translate-y-0 motion-reduce:opacity-0",
|
|
@@ -6090,10 +6184,10 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6090
6184
|
role: "region",
|
|
6091
6185
|
"aria-label": e.message ?? M(a)("ui.unsavedChangesBar.message"),
|
|
6092
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))
|
|
6093
|
-
}, [c("div",
|
|
6187
|
+
}, [c("div", $c, [c("p", el, [i[2] ||= c("span", {
|
|
6094
6188
|
"aria-hidden": "true",
|
|
6095
6189
|
class: "size-2 shrink-0 rounded-full bg-yellow"
|
|
6096
|
-
}, 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, {
|
|
6097
6191
|
disabled: p.value,
|
|
6098
6192
|
onClick: i[0] ||= (e) => f("discard")
|
|
6099
6193
|
}, {
|
|
@@ -6107,11 +6201,11 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6107
6201
|
}, {
|
|
6108
6202
|
default: V(() => [u(j(e.saveLabel ?? M(a)("ui.unsavedChangesBar.save")), 1)]),
|
|
6109
6203
|
_: 1
|
|
6110
|
-
}, 8, ["status", "disabled"])])])], 10,
|
|
6204
|
+
}, 8, ["status", "disabled"])])])], 10, Qc)) : o("", !0)]),
|
|
6111
6205
|
_: 1
|
|
6112
6206
|
})], 64));
|
|
6113
6207
|
}
|
|
6114
|
-
}),
|
|
6208
|
+
}), rl = { ui: {
|
|
6115
6209
|
age: {
|
|
6116
6210
|
born: "Born {date}",
|
|
6117
6211
|
birthdayToday: "Birthday today",
|
|
@@ -6144,6 +6238,7 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6144
6238
|
},
|
|
6145
6239
|
changeIndicator: { changed: "Changed from {from} to {to}" },
|
|
6146
6240
|
chip: { remove: "Remove" },
|
|
6241
|
+
appLauncher: { label: "Keston apps" },
|
|
6147
6242
|
footer: {
|
|
6148
6243
|
label: "Help and legal",
|
|
6149
6244
|
version: "Version {version}",
|
|
@@ -6239,16 +6334,16 @@ var gc = { class: "sr-only" }, _c = {
|
|
|
6239
6334
|
discard: "Discard",
|
|
6240
6335
|
save: "Save"
|
|
6241
6336
|
}
|
|
6242
|
-
} },
|
|
6243
|
-
function
|
|
6244
|
-
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 = {};
|
|
6245
6340
|
for (let e of i) a[e] = {
|
|
6246
|
-
...
|
|
6341
|
+
...il[e],
|
|
6247
6342
|
...t[e]
|
|
6248
6343
|
};
|
|
6249
6344
|
let o = G({
|
|
6250
6345
|
legacy: !1,
|
|
6251
|
-
locale: e.locale ??
|
|
6346
|
+
locale: e.locale ?? ol(i, n, r),
|
|
6252
6347
|
fallbackLocale: n,
|
|
6253
6348
|
messages: a
|
|
6254
6349
|
});
|
|
@@ -6259,7 +6354,7 @@ function Hc(e = {}) {
|
|
|
6259
6354
|
typeof document < "u" && (document.documentElement.lang = e);
|
|
6260
6355
|
}, { immediate: !0 }), o;
|
|
6261
6356
|
}
|
|
6262
|
-
function
|
|
6357
|
+
function ol(e, t, n) {
|
|
6263
6358
|
try {
|
|
6264
6359
|
let t = localStorage.getItem(n);
|
|
6265
6360
|
if (t && e.includes(t)) return t;
|
|
@@ -6270,4 +6365,4 @@ function Uc(e, t, n) {
|
|
|
6270
6365
|
}
|
|
6271
6366
|
return t;
|
|
6272
6367
|
}
|
|
6273
|
-
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 };
|