@hotelinking/ui 5.37.7 → 5.38.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -1
- package/dist/ui.es.js +327 -314
- package/dist/ui.umd.cjs +1 -1
- package/package.json +12 -12
package/dist/ui.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { openBlock as e, createBlock as t, resolveDynamicComponent as l, normalizeClass as n, createElementBlock as a, createVNode as o, renderSlot as r, createElementVNode as i, ref as s, computed as u, unref as d, shallowRef as c, watch as p, triggerRef as g, onScopeDispose as m, inject as f, nextTick as v, watchEffect as h, onMounted as b, cloneVNode as y, h as x, Fragment as w, defineComponent as k, provide as S, reactive as C, onUnmounted as O, toRaw as M, getCurrentInstance as D, Teleport as
|
|
1
|
+
import { openBlock as e, createBlock as t, resolveDynamicComponent as l, normalizeClass as n, createElementBlock as a, createVNode as o, renderSlot as r, createElementVNode as i, ref as s, computed as u, unref as d, shallowRef as c, watch as p, triggerRef as g, onScopeDispose as m, inject as f, nextTick as v, watchEffect as h, onMounted as b, cloneVNode as y, h as x, Fragment as w, defineComponent as k, provide as S, reactive as C, onUnmounted as O, toRaw as M, getCurrentInstance as D, Teleport as T, withCtx as E, createTextVNode as I, toDisplayString as _, Transition as P, renderList as j, createCommentVNode as R, withDirectives as B, vModelDynamic as A, vShow as L, withModifiers as F, vModelText as N, createStaticVNode as z, resolveComponent as $, vModelCheckbox as V, isRef as H } from "vue";
|
|
2
2
|
import Y from "dayjs";
|
|
3
3
|
import U from "vue3-apexcharts";
|
|
4
4
|
import q from "vue3-draggable";
|
|
@@ -36,7 +36,7 @@ function de(e2, t2, l2) {
|
|
|
36
36
|
}
|
|
37
37
|
function ce(e2, t2) {
|
|
38
38
|
if (void 0 === e2)
|
|
39
|
-
throw new Error("Unexpected undefined"
|
|
39
|
+
throw new Error("Unexpected undefined");
|
|
40
40
|
return e2;
|
|
41
41
|
}
|
|
42
42
|
const pe = (e2, t2) => {
|
|
@@ -80,7 +80,7 @@ const pe = (e2, t2) => {
|
|
|
80
80
|
const a2 = he ? () => {
|
|
81
81
|
} : pe(() => {
|
|
82
82
|
t2(n2, false);
|
|
83
|
-
},
|
|
83
|
+
}, e2.options.isScrollingResetDelay), o2 = (o3) => () => {
|
|
84
84
|
n2 = l2[e2.options.horizontal ? "scrollLeft" : "scrollTop"], a2(), t2(n2, o3);
|
|
85
85
|
}, r2 = o2(true), i2 = o2(false);
|
|
86
86
|
return i2(), l2.addEventListener("scroll", r2, ve), l2.addEventListener("scrollend", i2, ve), () => {
|
|
@@ -122,7 +122,7 @@ class we {
|
|
|
122
122
|
Object.entries(e3).forEach(([t2, l2]) => {
|
|
123
123
|
void 0 === l2 && delete e3[t2];
|
|
124
124
|
}), this.options = { debug: false, initialOffset: 0, overscan: 1, paddingStart: 0, paddingEnd: 0, scrollPaddingStart: 0, scrollPaddingEnd: 0, horizontal: false, getItemKey: ge, rangeExtractor: me, onChange: () => {
|
|
125
|
-
}, measureElement: ye, initialRect: { width: 0, height: 0 }, scrollMargin: 0, gap: 0, indexAttribute: "data-index", initialMeasurementsCache: [], lanes: 1, ...e3 };
|
|
125
|
+
}, measureElement: ye, initialRect: { width: 0, height: 0 }, scrollMargin: 0, gap: 0, indexAttribute: "data-index", initialMeasurementsCache: [], lanes: 1, isScrollingResetDelay: 150, ...e3 };
|
|
126
126
|
}, this.notify = (e3, t2) => {
|
|
127
127
|
var l2, n2;
|
|
128
128
|
const { startIndex: a2, endIndex: o2 } = this.range ?? { startIndex: void 0, endIndex: void 0 }, r2 = this.calculateRange();
|
|
@@ -280,20 +280,20 @@ let Oe = Symbol("headlessui.useid"), Me = 0;
|
|
|
280
280
|
function De() {
|
|
281
281
|
return f(Oe, () => "" + ++Me)();
|
|
282
282
|
}
|
|
283
|
-
function
|
|
283
|
+
function Te(e2) {
|
|
284
284
|
var t2;
|
|
285
285
|
if (null == e2 || null == e2.value)
|
|
286
286
|
return null;
|
|
287
287
|
let l2 = null != (t2 = e2.value.$el) ? t2 : e2.value;
|
|
288
288
|
return l2 instanceof Node ? l2 : null;
|
|
289
289
|
}
|
|
290
|
-
function
|
|
290
|
+
function Ee(e2, t2, ...l2) {
|
|
291
291
|
if (e2 in t2) {
|
|
292
292
|
let n3 = t2[e2];
|
|
293
293
|
return "function" == typeof n3 ? n3(...l2) : n3;
|
|
294
294
|
}
|
|
295
295
|
let n2 = new Error(`Tried to handle "${e2}" but there is no handler defined. Only defined handlers are: ${Object.keys(t2).map((e3) => `"${e3}"`).join(", ")}.`);
|
|
296
|
-
throw Error.captureStackTrace && Error.captureStackTrace(n2,
|
|
296
|
+
throw Error.captureStackTrace && Error.captureStackTrace(n2, Ee), n2;
|
|
297
297
|
}
|
|
298
298
|
var Ie = Object.defineProperty, _e = (e2, t2, l2) => (((e3, t3, l3) => {
|
|
299
299
|
t3 in e3 ? Ie(e3, t3, { enumerable: true, configurable: true, writable: true, value: l3 }) : e3[t3] = l3;
|
|
@@ -327,7 +327,7 @@ function je(e2) {
|
|
|
327
327
|
if (e2 instanceof Node)
|
|
328
328
|
return e2.ownerDocument;
|
|
329
329
|
if (null != e2 && e2.hasOwnProperty("value")) {
|
|
330
|
-
let t2 =
|
|
330
|
+
let t2 = Te(e2);
|
|
331
331
|
if (t2)
|
|
332
332
|
return t2.ownerDocument;
|
|
333
333
|
}
|
|
@@ -341,7 +341,7 @@ function Fe(e2 = document.body) {
|
|
|
341
341
|
var Ne = ((e2) => (e2[e2.Strict = 0] = "Strict", e2[e2.Loose = 1] = "Loose", e2))(Ne || {});
|
|
342
342
|
function ze(e2, t2 = 0) {
|
|
343
343
|
var l2;
|
|
344
|
-
return e2 !== (null == (l2 = je(e2)) ? void 0 : l2.body) &&
|
|
344
|
+
return e2 !== (null == (l2 = je(e2)) ? void 0 : l2.body) && Ee(t2, { 0: () => e2.matches(Re), 1() {
|
|
345
345
|
let t3 = e2;
|
|
346
346
|
for (; null !== t3; ) {
|
|
347
347
|
if (t3.matches(Re))
|
|
@@ -445,7 +445,7 @@ function Ze(e2, t2, l2 = u(() => true)) {
|
|
|
445
445
|
for (let e3 of r2) {
|
|
446
446
|
if (null === e3)
|
|
447
447
|
continue;
|
|
448
|
-
let t3 = e3 instanceof HTMLElement ? e3 :
|
|
448
|
+
let t3 = e3 instanceof HTMLElement ? e3 : Te(e3);
|
|
449
449
|
if (null != t3 && t3.contains(o2) || n3.composed && n3.composedPath().includes(t3))
|
|
450
450
|
return;
|
|
451
451
|
}
|
|
@@ -474,7 +474,7 @@ function Qe(e2, t2) {
|
|
|
474
474
|
l2.value = Xe(e2.value.type, e2.value.as);
|
|
475
475
|
}), h(() => {
|
|
476
476
|
var e3;
|
|
477
|
-
l2.value ||
|
|
477
|
+
l2.value || Te(t2) && Te(t2) instanceof HTMLButtonElement && (null == (e3 = Te(t2)) || !e3.hasAttribute("type")) && (l2.value = "button");
|
|
478
478
|
}), l2;
|
|
479
479
|
}
|
|
480
480
|
function et(e2) {
|
|
@@ -509,7 +509,7 @@ function ot({ visible: e2 = true, features: t2 = 0, ourProps: l2, theirProps: n2
|
|
|
509
509
|
if (e2 || 2 & t2 && r2.static)
|
|
510
510
|
return rt(i2);
|
|
511
511
|
if (1 & t2) {
|
|
512
|
-
return
|
|
512
|
+
return Ee(null == (o2 = r2.unmount) || o2 ? 0 : 1, { 0: () => null, 1: () => rt({ ...a2, props: { ...r2, hidden: true, style: { display: "none" } } }) });
|
|
513
513
|
}
|
|
514
514
|
return rt(i2);
|
|
515
515
|
}
|
|
@@ -699,10 +699,10 @@ function Ot(e2, t2, l2) {
|
|
|
699
699
|
else
|
|
700
700
|
l2 instanceof Date ? e2.push([t2, l2.toISOString()]) : "boolean" == typeof l2 ? e2.push([t2, l2 ? "1" : "0"]) : "string" == typeof l2 ? e2.push([t2, l2]) : "number" == typeof l2 ? e2.push([t2, `${l2}`]) : null == l2 ? e2.push([t2, ""]) : St(l2, t2, e2);
|
|
701
701
|
}
|
|
702
|
-
var Mt = ((e2) => (e2[e2.Open = 0] = "Open", e2[e2.Closed = 1] = "Closed", e2))(Mt || {}), Dt = ((e2) => (e2[e2.Single = 0] = "Single", e2[e2.Multi = 1] = "Multi", e2))(Dt || {}),
|
|
703
|
-
let
|
|
702
|
+
var Mt = ((e2) => (e2[e2.Open = 0] = "Open", e2[e2.Closed = 1] = "Closed", e2))(Mt || {}), Dt = ((e2) => (e2[e2.Single = 0] = "Single", e2[e2.Multi = 1] = "Multi", e2))(Dt || {}), Tt = ((e2) => (e2[e2.Pointer = 0] = "Pointer", e2[e2.Focus = 1] = "Focus", e2[e2.Other = 2] = "Other", e2))(Tt || {});
|
|
703
|
+
let Et = Symbol("ComboboxContext");
|
|
704
704
|
function It(e2) {
|
|
705
|
-
let t2 = f(
|
|
705
|
+
let t2 = f(Et, null);
|
|
706
706
|
if (null === t2) {
|
|
707
707
|
let t3 = new Error(`<${e2} /> is missing a parent <Combobox /> component.`);
|
|
708
708
|
throw Error.captureStackTrace && Error.captureStackTrace(t3, It), t3;
|
|
@@ -711,12 +711,12 @@ function It(e2) {
|
|
|
711
711
|
}
|
|
712
712
|
let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, { slots: t2 }) {
|
|
713
713
|
let l2 = It("VirtualProvider"), n2 = u(() => {
|
|
714
|
-
let e3 =
|
|
714
|
+
let e3 = Te(l2.optionsRef);
|
|
715
715
|
if (!e3)
|
|
716
716
|
return { start: 0, end: 0 };
|
|
717
717
|
let t3 = window.getComputedStyle(e3);
|
|
718
718
|
return { start: parseFloat(t3.paddingBlockStart || t3.paddingTop), end: parseFloat(t3.paddingBlockEnd || t3.paddingBottom) };
|
|
719
|
-
}), a2 = Se(u(() => ({ scrollPaddingStart: n2.value.start, scrollPaddingEnd: n2.value.end, count: l2.virtual.value.options.length, estimateSize: () => 40, getScrollElement: () =>
|
|
719
|
+
}), a2 = Se(u(() => ({ scrollPaddingStart: n2.value.start, scrollPaddingEnd: n2.value.end, count: l2.virtual.value.options.length, estimateSize: () => 40, getScrollElement: () => Te(l2.optionsRef), overscan: 12 }))), o2 = u(() => {
|
|
720
720
|
var e3;
|
|
721
721
|
return null == (e3 = l2.virtual.value) ? void 0 : e3.options;
|
|
722
722
|
}), r2 = s(0);
|
|
@@ -732,12 +732,12 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
732
732
|
} }), jt = k({ name: "Combobox", emits: { "update:modelValue": (e2) => true }, props: { as: { type: [Object, String], default: "template" }, disabled: { type: [Boolean], default: false }, by: { type: [String, Function], nullable: true, default: null }, modelValue: { type: [Object, String, Number, Boolean], default: void 0 }, defaultValue: { type: [Object, String, Number, Boolean], default: void 0 }, form: { type: String, optional: true }, name: { type: String, optional: true }, nullable: { type: Boolean, default: false }, multiple: { type: [Boolean], default: false }, immediate: { type: [Boolean], default: false }, virtual: { type: Object, default: null } }, inheritAttrs: false, setup(e2, { slots: t2, attrs: l2, emit: n2 }) {
|
|
733
733
|
let a2 = s(1), o2 = s(null), r2 = s(null), i2 = s(null), d2 = s(null), c2 = s({ static: false, hold: false }), g2 = s([]), m2 = s(null), f2 = s(2), v2 = s(false);
|
|
734
734
|
function h2(e3 = (e4) => e4) {
|
|
735
|
-
let t3 = null !== m2.value ? g2.value[m2.value] : null, l3 = e3(g2.value.slice()), n3 = l3.length > 0 && null !== l3[0].dataRef.order.value ? l3.sort((e4, t4) => e4.dataRef.order.value - t4.dataRef.order.value) : Ue(l3, (e4) =>
|
|
735
|
+
let t3 = null !== m2.value ? g2.value[m2.value] : null, l3 = e3(g2.value.slice()), n3 = l3.length > 0 && null !== l3[0].dataRef.order.value ? l3.sort((e4, t4) => e4.dataRef.order.value - t4.dataRef.order.value) : Ue(l3, (e4) => Te(e4.dataRef.domRef)), a3 = t3 ? n3.indexOf(t3) : null;
|
|
736
736
|
return -1 === a3 && (a3 = null), { options: n3, activeOptionIndex: a3 };
|
|
737
737
|
}
|
|
738
|
-
let y2 = u(() => e2.multiple ? 1 : 0), k2 = u(() => e2.nullable), [O2, D2] = Ce(u(() => e2.modelValue), (e3) => n2("update:modelValue", e3), u(() => e2.defaultValue)),
|
|
738
|
+
let y2 = u(() => e2.multiple ? 1 : 0), k2 = u(() => e2.nullable), [O2, D2] = Ce(u(() => e2.modelValue), (e3) => n2("update:modelValue", e3), u(() => e2.defaultValue)), T2 = u(() => void 0 === O2.value ? Ee(y2.value, { 1: [], 0: void 0 }) : O2.value), E2 = null, I2 = null;
|
|
739
739
|
function _2(e3) {
|
|
740
|
-
return
|
|
740
|
+
return Ee(y2.value, { 0: () => null == D2 ? void 0 : D2(e3), 1: () => {
|
|
741
741
|
let t3 = M(j2.value.value).slice(), l3 = M(e3), n3 = t3.findIndex((e4) => j2.compare(l3, M(e4)));
|
|
742
742
|
return -1 === n3 ? t3.push(l3) : t3.splice(n3, 1), null == D2 ? void 0 : D2(t3);
|
|
743
743
|
} });
|
|
@@ -750,7 +750,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
750
750
|
m2.value = -1 !== l3 ? l3 : null;
|
|
751
751
|
}
|
|
752
752
|
});
|
|
753
|
-
let j2 = { comboboxState: a2, value:
|
|
753
|
+
let j2 = { comboboxState: a2, value: T2, mode: y2, compare(t3, l3) {
|
|
754
754
|
if ("string" == typeof e2.by) {
|
|
755
755
|
let n3 = e2.by;
|
|
756
756
|
return (null == t3 ? void 0 : t3[n3]) === (null == l3 ? void 0 : l3[n3]);
|
|
@@ -788,7 +788,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
788
788
|
}, setActivationTrigger(e3) {
|
|
789
789
|
f2.value = e3;
|
|
790
790
|
}, goToOption(t3, l3, n3) {
|
|
791
|
-
v2.value = false, null !==
|
|
791
|
+
v2.value = false, null !== E2 && cancelAnimationFrame(E2), E2 = requestAnimationFrame(() => {
|
|
792
792
|
if (e2.disabled || d2.value && !c2.value.static && 1 === a2.value)
|
|
793
793
|
return;
|
|
794
794
|
if (j2.virtual.value)
|
|
@@ -831,23 +831,23 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
831
831
|
return void g2.value.push(l3);
|
|
832
832
|
I2 && cancelAnimationFrame(I2);
|
|
833
833
|
let n3 = h2((e4) => (e4.push(l3), e4));
|
|
834
|
-
null === m2.value && j2.isSelected(t3.value.value) && (n3.activeOptionIndex = n3.options.indexOf(l3)), g2.value = n3.options, m2.value = n3.activeOptionIndex, f2.value = 2, n3.options.some((e4) => !
|
|
834
|
+
null === m2.value && j2.isSelected(t3.value.value) && (n3.activeOptionIndex = n3.options.indexOf(l3)), g2.value = n3.options, m2.value = n3.activeOptionIndex, f2.value = 2, n3.options.some((e4) => !Te(e4.dataRef.domRef)) && (I2 = requestAnimationFrame(() => {
|
|
835
835
|
let e4 = h2();
|
|
836
836
|
g2.value = e4.options, m2.value = e4.activeOptionIndex;
|
|
837
837
|
}));
|
|
838
838
|
}, unregisterOption(e3, t3) {
|
|
839
|
-
if (null !==
|
|
839
|
+
if (null !== E2 && cancelAnimationFrame(E2), t3 && (v2.value = true), j2.virtual.value)
|
|
840
840
|
return void (g2.value = g2.value.filter((t4) => t4.id !== e3));
|
|
841
841
|
let l3 = h2((t4) => {
|
|
842
842
|
let l4 = t4.findIndex((t5) => t5.id === e3);
|
|
843
843
|
return -1 !== l4 && t4.splice(l4, 1), t4;
|
|
844
844
|
});
|
|
845
845
|
g2.value = l3.options, m2.value = l3.activeOptionIndex, f2.value = 2;
|
|
846
|
-
}, isSelected: (e3) =>
|
|
847
|
-
Ze([r2, i2, d2], () => j2.closeCombobox(), u(() => 0 === a2.value)), S(
|
|
846
|
+
}, isSelected: (e3) => Ee(y2.value, { 0: () => j2.compare(M(j2.value.value), M(e3)), 1: () => M(j2.value.value).some((t3) => j2.compare(M(t3), M(e3))) }), isActive: (e3) => m2.value === j2.calculateIndex(e3) };
|
|
847
|
+
Ze([r2, i2, d2], () => j2.closeCombobox(), u(() => 0 === a2.value)), S(Et, j2), vt(u(() => Ee(a2.value, { 0: mt.Open, 1: mt.Closed })));
|
|
848
848
|
let R2 = u(() => {
|
|
849
849
|
var e3;
|
|
850
|
-
return null == (e3 =
|
|
850
|
+
return null == (e3 = Te(r2)) ? void 0 : e3.closest("form");
|
|
851
851
|
});
|
|
852
852
|
return b(() => {
|
|
853
853
|
p([R2], () => {
|
|
@@ -862,15 +862,15 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
862
862
|
}, { immediate: true });
|
|
863
863
|
}), () => {
|
|
864
864
|
var n3, o3, r3;
|
|
865
|
-
let { name: i3, disabled: s2, form: u2, ...d3 } = e2, c3 = { open: 0 === a2.value, disabled: s2, activeIndex: j2.activeOptionIndex.value, activeOption: null === j2.activeOptionIndex.value ? null : j2.virtual.value ? j2.virtual.value.options[null != (n3 = j2.activeOptionIndex.value) ? n3 : 0] : null != (r3 = null == (o3 = j2.options.value[j2.activeOptionIndex.value]) ? void 0 : o3.dataRef.value) ? r3 : null, value:
|
|
866
|
-
return x(w, [...null != i3 && null !=
|
|
865
|
+
let { name: i3, disabled: s2, form: u2, ...d3 } = e2, c3 = { open: 0 === a2.value, disabled: s2, activeIndex: j2.activeOptionIndex.value, activeOption: null === j2.activeOptionIndex.value ? null : j2.virtual.value ? j2.virtual.value.options[null != (n3 = j2.activeOptionIndex.value) ? n3 : 0] : null != (r3 = null == (o3 = j2.options.value[j2.activeOptionIndex.value]) ? void 0 : o3.dataRef.value) ? r3 : null, value: T2.value };
|
|
866
|
+
return x(w, [...null != i3 && null != T2.value ? St({ [i3]: T2.value }).map(([e3, t3]) => x(pt, ut({ features: ct.Hidden, key: e3, as: "input", type: "hidden", hidden: true, readOnly: true, form: u2, disabled: s2, name: e3, value: t3 }))) : [], ot({ theirProps: { ...l2, ...dt(d3, ["by", "defaultValue", "immediate", "modelValue", "multiple", "nullable", "onUpdate:modelValue", "virtual"]) }, ourProps: {}, slot: c3, slots: t2, attrs: l2, name: "Combobox" })]);
|
|
867
867
|
};
|
|
868
868
|
} }), Rt = k({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2 }) {
|
|
869
869
|
var n2;
|
|
870
870
|
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-combobox-label-${De()}`, o2 = It("ComboboxLabel");
|
|
871
871
|
function r2() {
|
|
872
872
|
var e3;
|
|
873
|
-
null == (e3 =
|
|
873
|
+
null == (e3 = Te(o2.inputRef)) || e3.focus({ preventScroll: true });
|
|
874
874
|
}
|
|
875
875
|
return () => {
|
|
876
876
|
let n3 = { open: 0 === o2.comboboxState.value, disabled: o2.disabled.value }, { ...i2 } = e2;
|
|
@@ -882,7 +882,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
882
882
|
function i2(e3) {
|
|
883
883
|
r2.disabled.value || (0 === r2.comboboxState.value ? r2.closeCombobox() : (e3.preventDefault(), r2.openCombobox()), v(() => {
|
|
884
884
|
var e4;
|
|
885
|
-
return null == (e4 =
|
|
885
|
+
return null == (e4 = Te(r2.inputRef)) ? void 0 : e4.focus({ preventScroll: true });
|
|
886
886
|
}));
|
|
887
887
|
}
|
|
888
888
|
function s2(e3) {
|
|
@@ -913,27 +913,27 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
913
913
|
return () => {
|
|
914
914
|
var n3, a3;
|
|
915
915
|
let u2 = { open: 0 === r2.comboboxState.value, disabled: r2.disabled.value, value: r2.value.value }, { ...c2 } = e2;
|
|
916
|
-
return ot({ ourProps: { ref: r2.buttonRef, id: o2, type: d2.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": null == (n3 =
|
|
916
|
+
return ot({ ourProps: { ref: r2.buttonRef, id: o2, type: d2.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": null == (n3 = Te(r2.optionsRef)) ? void 0 : n3.id, "aria-expanded": 0 === r2.comboboxState.value, "aria-labelledby": r2.labelRef.value ? [null == (a3 = Te(r2.labelRef)) ? void 0 : a3.id, o2].join(" ") : void 0, disabled: true === r2.disabled.value || void 0, onKeydown: s2, onClick: i2 }, theirProps: c2, slot: u2, attrs: t2, slots: l2, name: "ComboboxButton" });
|
|
917
917
|
};
|
|
918
918
|
} }), At = k({ name: "ComboboxInput", props: { as: { type: [Object, String], default: "input" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, displayValue: { type: Function }, defaultValue: { type: String, default: void 0 }, id: { type: String, default: null } }, emits: { change: (e2) => true }, setup(e2, { emit: t2, attrs: l2, slots: n2, expose: a2 }) {
|
|
919
919
|
var o2;
|
|
920
|
-
let r2 = null != (o2 = e2.id) ? o2 : `headlessui-combobox-input-${De()}`, i2 = It("ComboboxInput"), d2 = u(() => je(
|
|
920
|
+
let r2 = null != (o2 = e2.id) ? o2 : `headlessui-combobox-input-${De()}`, i2 = It("ComboboxInput"), d2 = u(() => je(Te(i2.inputRef))), c2 = { value: false };
|
|
921
921
|
function g2() {
|
|
922
922
|
i2.change(null);
|
|
923
|
-
let e3 =
|
|
923
|
+
let e3 = Te(i2.optionsRef);
|
|
924
924
|
e3 && (e3.scrollTop = 0), i2.goToOption(yt.Nothing);
|
|
925
925
|
}
|
|
926
926
|
a2({ el: i2.inputRef, $el: i2.inputRef });
|
|
927
927
|
let m2 = u(() => {
|
|
928
928
|
var t3;
|
|
929
929
|
let l3 = i2.value.value;
|
|
930
|
-
return
|
|
930
|
+
return Te(i2.inputRef) ? void 0 !== e2.displayValue && void 0 !== l3 ? null != (t3 = e2.displayValue(l3)) ? t3 : "" : "string" == typeof l3 ? l3 : "" : "";
|
|
931
931
|
});
|
|
932
932
|
b(() => {
|
|
933
933
|
p([m2, i2.comboboxState, d2], ([e3, t3], [l3, n3]) => {
|
|
934
934
|
if (c2.value)
|
|
935
935
|
return;
|
|
936
|
-
let a3 =
|
|
936
|
+
let a3 = Te(i2.inputRef);
|
|
937
937
|
a3 && ((0 === n3 && 1 === t3 || e3 !== l3) && (a3.value = e3), requestAnimationFrame(() => {
|
|
938
938
|
var e4;
|
|
939
939
|
if (c2.value || !a3 || (null == (e4 = d2.value) ? void 0 : e4.activeElement) !== a3)
|
|
@@ -945,7 +945,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
945
945
|
if (0 === e3 && 1 === t3) {
|
|
946
946
|
if (c2.value)
|
|
947
947
|
return;
|
|
948
|
-
let e4 =
|
|
948
|
+
let e4 = Te(i2.inputRef);
|
|
949
949
|
if (!e4)
|
|
950
950
|
return;
|
|
951
951
|
let t4 = e4.value, { selectionStart: l3, selectionEnd: n3, selectionDirection: a3 } = e4;
|
|
@@ -972,9 +972,9 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
972
972
|
i2.selectActiveOption(), 0 === i2.mode.value && i2.closeCombobox();
|
|
973
973
|
break;
|
|
974
974
|
case ht.ArrowDown:
|
|
975
|
-
return c2.value = false, e3.preventDefault(), e3.stopPropagation(),
|
|
975
|
+
return c2.value = false, e3.preventDefault(), e3.stopPropagation(), Ee(i2.comboboxState.value, { 0: () => i2.goToOption(yt.Next), 1: () => i2.openCombobox() });
|
|
976
976
|
case ht.ArrowUp:
|
|
977
|
-
return c2.value = false, e3.preventDefault(), e3.stopPropagation(),
|
|
977
|
+
return c2.value = false, e3.preventDefault(), e3.stopPropagation(), Ee(i2.comboboxState.value, { 0: () => i2.goToOption(yt.Previous), 1: () => {
|
|
978
978
|
i2.openCombobox(), v(() => {
|
|
979
979
|
i2.value.value || i2.goToOption(yt.Last);
|
|
980
980
|
});
|
|
@@ -1008,13 +1008,13 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
1008
1008
|
function k2(e3) {
|
|
1009
1009
|
var t3, l3, n3;
|
|
1010
1010
|
let a3 = null != (t3 = e3.relatedTarget) ? t3 : bt.find((t4) => t4 !== e3.currentTarget);
|
|
1011
|
-
if (c2.value = false, !(null != (l3 =
|
|
1011
|
+
if (c2.value = false, !(null != (l3 = Te(i2.optionsRef)) && l3.contains(a3) || null != (n3 = Te(i2.buttonRef)) && n3.contains(a3) || 0 !== i2.comboboxState.value))
|
|
1012
1012
|
return e3.preventDefault(), 0 === i2.mode.value && (i2.nullable.value && null === i2.value.value ? g2() : 1 !== i2.activationTrigger.value && i2.selectActiveOption()), i2.closeCombobox();
|
|
1013
1013
|
}
|
|
1014
1014
|
function S2(e3) {
|
|
1015
1015
|
var t3, l3, n3;
|
|
1016
1016
|
let a3 = null != (t3 = e3.relatedTarget) ? t3 : bt.find((t4) => t4 !== e3.currentTarget);
|
|
1017
|
-
null != (l3 =
|
|
1017
|
+
null != (l3 = Te(i2.buttonRef)) && l3.contains(a3) || null != (n3 = Te(i2.optionsRef)) && n3.contains(a3) || i2.disabled.value || i2.immediate.value && 0 !== i2.comboboxState.value && (i2.openCombobox(), kt().nextFrame(() => {
|
|
1018
1018
|
i2.setActivationTrigger(1);
|
|
1019
1019
|
}));
|
|
1020
1020
|
}
|
|
@@ -1024,7 +1024,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
1024
1024
|
});
|
|
1025
1025
|
return () => {
|
|
1026
1026
|
var t3, a3, o3, s2, u2, d3, c3;
|
|
1027
|
-
let p2 = { open: 0 === i2.comboboxState.value }, { displayValue: g3, onChange: m3, ...f3 } = e2, v2 = { "aria-controls": null == (t3 = i2.optionsRef.value) ? void 0 : t3.id, "aria-expanded": 0 === i2.comboboxState.value, "aria-activedescendant": null === i2.activeOptionIndex.value ? void 0 : i2.virtual.value ? null == (a3 = i2.options.value.find((e3) => !i2.virtual.value.disabled(e3.dataRef.value) && i2.compare(e3.dataRef.value, i2.virtual.value.options[i2.activeOptionIndex.value]))) ? void 0 : a3.id : null == (o3 = i2.options.value[i2.activeOptionIndex.value]) ? void 0 : o3.id, "aria-labelledby": null != (d3 = null == (s2 =
|
|
1027
|
+
let p2 = { open: 0 === i2.comboboxState.value }, { displayValue: g3, onChange: m3, ...f3 } = e2, v2 = { "aria-controls": null == (t3 = i2.optionsRef.value) ? void 0 : t3.id, "aria-expanded": 0 === i2.comboboxState.value, "aria-activedescendant": null === i2.activeOptionIndex.value ? void 0 : i2.virtual.value ? null == (a3 = i2.options.value.find((e3) => !i2.virtual.value.disabled(e3.dataRef.value) && i2.compare(e3.dataRef.value, i2.virtual.value.options[i2.activeOptionIndex.value]))) ? void 0 : a3.id : null == (o3 = i2.options.value[i2.activeOptionIndex.value]) ? void 0 : o3.id, "aria-labelledby": null != (d3 = null == (s2 = Te(i2.labelRef)) ? void 0 : s2.id) ? d3 : null == (u2 = Te(i2.buttonRef)) ? void 0 : u2.id, "aria-autocomplete": "list", id: r2, onCompositionstart: h2, onCompositionend: y2, onKeydown: x2, onInput: w2, onFocus: S2, onBlur: k2, role: "combobox", type: null != (c3 = l2.type) ? c3 : "text", tabIndex: 0, ref: i2.inputRef, defaultValue: C2.value, disabled: true === i2.disabled.value || void 0 };
|
|
1028
1028
|
return ot({ ourProps: v2, theirProps: f3, slot: p2, attrs: l2, slots: n2, features: nt.RenderStrategy | nt.Static, name: "ComboboxInput" });
|
|
1029
1029
|
};
|
|
1030
1030
|
} }), Lt = k({ name: "ComboboxOptions", props: { as: { type: [Object, String], default: "ul" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, hold: { type: [Boolean], default: false } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
@@ -1035,12 +1035,15 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
1035
1035
|
a2.optionsPropsRef.value.hold = e2.hold;
|
|
1036
1036
|
});
|
|
1037
1037
|
let r2 = ft(), i2 = u(() => null !== r2 ? (r2.value & mt.Open) === mt.Open : 0 === a2.comboboxState.value);
|
|
1038
|
-
|
|
1038
|
+
function s2(e3) {
|
|
1039
|
+
e3.preventDefault();
|
|
1040
|
+
}
|
|
1041
|
+
return lt({ container: u(() => Te(a2.optionsRef)), enabled: u(() => 0 === a2.comboboxState.value), accept: (e3) => "option" === e3.getAttribute("role") ? NodeFilter.FILTER_REJECT : e3.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT, walk(e3) {
|
|
1039
1042
|
e3.setAttribute("role", "none");
|
|
1040
1043
|
} }), () => {
|
|
1041
|
-
var n3, r3,
|
|
1042
|
-
let
|
|
1043
|
-
return ot({ ourProps: { "aria-labelledby": null != (
|
|
1044
|
+
var n3, r3, u2;
|
|
1045
|
+
let d2 = { open: 0 === a2.comboboxState.value };
|
|
1046
|
+
return ot({ ourProps: { "aria-labelledby": null != (u2 = null == (n3 = Te(a2.labelRef)) ? void 0 : n3.id) ? u2 : null == (r3 = Te(a2.buttonRef)) ? void 0 : r3.id, id: o2, ref: a2.optionsRef, role: "listbox", "aria-multiselectable": 1 === a2.mode.value || void 0, onMousedown: s2 }, theirProps: dt(e2, ["hold"]), slot: d2, attrs: t2, slots: a2.virtual.value && 0 === a2.comboboxState.value ? { ...l2, default: () => [x(Pt, {}, l2.default)] } : l2, features: nt.RenderStrategy | nt.Static, visible: i2.value, name: "ComboboxOptions" });
|
|
1044
1047
|
};
|
|
1045
1048
|
} }), Ft = k({ name: "ComboboxOption", props: { as: { type: [Object, String], default: "li" }, value: { type: [Object, String, Number, Boolean] }, disabled: { type: Boolean, default: false }, order: { type: [Number], default: null } }, setup(e2, { slots: t2, attrs: l2, expose: n2 }) {
|
|
1046
1049
|
let a2 = It("ComboboxOption"), o2 = `headlessui-combobox-option-${De()}`, r2 = s(null);
|
|
@@ -1055,7 +1058,7 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
1055
1058
|
return t3.preventDefault();
|
|
1056
1059
|
a2.selectOption(o2), Ke() || requestAnimationFrame(() => {
|
|
1057
1060
|
var e3;
|
|
1058
|
-
return null == (e3 =
|
|
1061
|
+
return null == (e3 = Te(a2.inputRef)) ? void 0 : e3.focus({ preventScroll: true });
|
|
1059
1062
|
}), 0 === a2.mode.value && requestAnimationFrame(() => a2.closeCombobox());
|
|
1060
1063
|
}
|
|
1061
1064
|
function m2() {
|
|
@@ -1066,12 +1069,12 @@ let _t = Symbol("VirtualContext"), Pt = k({ name: "VirtualProvider", setup(e2, {
|
|
|
1066
1069
|
a2.goToOption(yt.Specific, l3);
|
|
1067
1070
|
}
|
|
1068
1071
|
b(() => a2.registerOption(o2, p2)), O(() => a2.unregisterOption(o2, i2.value)), h(() => {
|
|
1069
|
-
let e3 =
|
|
1072
|
+
let e3 = Te(r2);
|
|
1070
1073
|
e3 && (null == c2 || c2.value.measureElement(e3));
|
|
1071
1074
|
}), h(() => {
|
|
1072
1075
|
0 === a2.comboboxState.value && i2.value && (a2.virtual.value || 0 !== a2.activationTrigger.value && v(() => {
|
|
1073
1076
|
var e3, t3;
|
|
1074
|
-
return null == (t3 = null == (e3 =
|
|
1077
|
+
return null == (t3 = null == (e3 = Te(r2)) ? void 0 : e3.scrollIntoView) ? void 0 : t3.call(e3, { block: "nearest" });
|
|
1075
1078
|
}));
|
|
1076
1079
|
});
|
|
1077
1080
|
let y2 = tt();
|
|
@@ -1107,7 +1110,7 @@ function $t(e2) {
|
|
|
1107
1110
|
return new Set(e2());
|
|
1108
1111
|
let t2 = /* @__PURE__ */ new Set();
|
|
1109
1112
|
for (let l2 of e2.value) {
|
|
1110
|
-
let e3 =
|
|
1113
|
+
let e3 = Te(l2);
|
|
1111
1114
|
e3 instanceof HTMLElement && t2.add(e3);
|
|
1112
1115
|
}
|
|
1113
1116
|
return t2;
|
|
@@ -1144,12 +1147,12 @@ let Ht = Object.assign(k({ name: "FocusTrap", props: { as: { type: [Object, Stri
|
|
|
1144
1147
|
p([t3, l3, n3], (r3, i3) => {
|
|
1145
1148
|
if (r3.every((e4, t4) => (null == i3 ? void 0 : i3[t4]) === e4) || !n3.value)
|
|
1146
1149
|
return;
|
|
1147
|
-
let s2 =
|
|
1150
|
+
let s2 = Te(t3);
|
|
1148
1151
|
s2 && wt(() => {
|
|
1149
1152
|
var t4, n4;
|
|
1150
1153
|
if (!o3.value)
|
|
1151
1154
|
return;
|
|
1152
|
-
let r4 =
|
|
1155
|
+
let r4 = Te(l3), i4 = null == (t4 = e3.value) ? void 0 : t4.activeElement;
|
|
1153
1156
|
if (r4) {
|
|
1154
1157
|
if (r4 === i4)
|
|
1155
1158
|
return void (a3.value = i4);
|
|
@@ -1166,7 +1169,7 @@ let Ht = Object.assign(k({ name: "FocusTrap", props: { as: { type: [Object, Stri
|
|
|
1166
1169
|
if (!a3.value)
|
|
1167
1170
|
return;
|
|
1168
1171
|
let o4 = $t(l3);
|
|
1169
|
-
|
|
1172
|
+
Te(t3) instanceof HTMLElement && o4.add(Te(t3));
|
|
1170
1173
|
let r3 = n3.value;
|
|
1171
1174
|
if (!r3)
|
|
1172
1175
|
return;
|
|
@@ -1181,8 +1184,8 @@ let Ht = Object.assign(k({ name: "FocusTrap", props: { as: { type: [Object, Stri
|
|
|
1181
1184
|
}), e3;
|
|
1182
1185
|
}();
|
|
1183
1186
|
function c2(e3) {
|
|
1184
|
-
let t3 =
|
|
1185
|
-
t3 &&
|
|
1187
|
+
let t3 = Te(a2);
|
|
1188
|
+
t3 && Ee(d2.value, { [zt.Forwards]: () => {
|
|
1186
1189
|
qe(t3, Be.First, { skipElements: [e3.relatedTarget] });
|
|
1187
1190
|
}, [zt.Backwards]: () => {
|
|
1188
1191
|
qe(t3, Be.Last, { skipElements: [e3.relatedTarget] });
|
|
@@ -1198,9 +1201,9 @@ let Ht = Object.assign(k({ name: "FocusTrap", props: { as: { type: [Object, Stri
|
|
|
1198
1201
|
if (!r2.value)
|
|
1199
1202
|
return;
|
|
1200
1203
|
let l3 = $t(e2.containers);
|
|
1201
|
-
|
|
1204
|
+
Te(a2) instanceof HTMLElement && l3.add(Te(a2));
|
|
1202
1205
|
let n3 = t3.relatedTarget;
|
|
1203
|
-
n3 instanceof HTMLElement && "true" !== n3.dataset.headlessuiFocusGuard && (Yt(l3, n3) || (g2.value ? qe(
|
|
1206
|
+
n3 instanceof HTMLElement && "true" !== n3.dataset.headlessuiFocusGuard && (Yt(l3, n3) || (g2.value ? qe(Te(a2), Ee(d2.value, { [zt.Forwards]: () => Be.Next, [zt.Backwards]: () => Be.Previous }) | Be.WrapAround, { relativeTo: t3.target }) : t3.target instanceof HTMLElement && He(t3.target)));
|
|
1204
1207
|
}
|
|
1205
1208
|
return () => {
|
|
1206
1209
|
let n3 = { ref: a2, onKeydown: m2, onFocusout: f2 }, { features: o3, initialFocus: r3, containers: i3, ...s2 } = e2;
|
|
@@ -1333,7 +1336,7 @@ function Zt(e2, t2 = s(true)) {
|
|
|
1333
1336
|
var n2;
|
|
1334
1337
|
if (!t2.value)
|
|
1335
1338
|
return;
|
|
1336
|
-
let a2 =
|
|
1339
|
+
let a2 = Te(e2);
|
|
1337
1340
|
if (!a2)
|
|
1338
1341
|
return;
|
|
1339
1342
|
l2(function() {
|
|
@@ -1396,8 +1399,16 @@ k({ name: "Description", props: { as: { type: [Object, String], default: "p" },
|
|
|
1396
1399
|
return ot({ ourProps: c2, theirProps: u2, slot: r2.value, attrs: t2, slots: l2, name: n3 });
|
|
1397
1400
|
};
|
|
1398
1401
|
} });
|
|
1399
|
-
|
|
1400
|
-
|
|
1402
|
+
const rl = /* @__PURE__ */ new WeakMap();
|
|
1403
|
+
function il(e2, t2) {
|
|
1404
|
+
let l2 = t2(function(e3) {
|
|
1405
|
+
var t3;
|
|
1406
|
+
return null != (t3 = rl.get(e3)) ? t3 : 0;
|
|
1407
|
+
}(e2));
|
|
1408
|
+
return l2 <= 0 ? rl.delete(e2) : rl.set(e2, l2), l2;
|
|
1409
|
+
}
|
|
1410
|
+
let sl = k({ name: "Portal", props: { as: { type: [Object, String], default: "div" } }, setup(e2, { slots: t2, attrs: l2 }) {
|
|
1411
|
+
let n2 = s(null), a2 = u(() => je(n2)), o2 = Qt(), r2 = f(dl, null), i2 = s(true === o2 || null == r2 ? function(e3) {
|
|
1401
1412
|
let t3 = je(e3);
|
|
1402
1413
|
if (!t3) {
|
|
1403
1414
|
if (null === e3)
|
|
@@ -1409,59 +1420,61 @@ let rl = k({ name: "Portal", props: { as: { type: [Object, String], default: "di
|
|
|
1409
1420
|
return l3;
|
|
1410
1421
|
let n3 = t3.createElement("div");
|
|
1411
1422
|
return n3.setAttribute("id", "headlessui-portal-root"), t3.body.appendChild(n3);
|
|
1412
|
-
}(n2.value) : r2.resolveTarget())
|
|
1423
|
+
}(n2.value) : r2.resolveTarget());
|
|
1424
|
+
i2.value && il(i2.value, (e3) => e3 + 1);
|
|
1425
|
+
let d2 = s(false);
|
|
1413
1426
|
b(() => {
|
|
1414
1427
|
d2.value = true;
|
|
1415
1428
|
}), h(() => {
|
|
1416
1429
|
o2 || null != r2 && (i2.value = r2.resolveTarget());
|
|
1417
1430
|
});
|
|
1418
|
-
let c2 = f(
|
|
1431
|
+
let c2 = f(ul, null), g2 = false, m2 = D();
|
|
1419
1432
|
return p(n2, () => {
|
|
1420
1433
|
if (g2 || !c2)
|
|
1421
1434
|
return;
|
|
1422
|
-
let e3 =
|
|
1435
|
+
let e3 = Te(n2);
|
|
1423
1436
|
e3 && (O(c2.register(e3), m2), g2 = true);
|
|
1424
1437
|
}), O(() => {
|
|
1425
1438
|
var e3, t3;
|
|
1426
1439
|
let l3 = null == (e3 = a2.value) ? void 0 : e3.getElementById("headlessui-portal-root");
|
|
1427
|
-
l3
|
|
1440
|
+
!l3 || i2.value !== l3 || il(i2.value, (e4) => e4 - 1) || i2.value.children.length > 0 || null == (t3 = i2.value.parentElement) || t3.removeChild(i2.value);
|
|
1428
1441
|
}), () => {
|
|
1429
1442
|
if (!d2.value || null === i2.value)
|
|
1430
1443
|
return null;
|
|
1431
1444
|
let a3 = { ref: n2, "data-headlessui-portal": "" };
|
|
1432
|
-
return x(
|
|
1445
|
+
return x(T, { to: i2.value }, ot({ ourProps: a3, theirProps: e2, slot: {}, attrs: l2, slots: t2, name: "Portal" }));
|
|
1433
1446
|
};
|
|
1434
|
-
} }),
|
|
1435
|
-
let
|
|
1447
|
+
} }), ul = Symbol("PortalParentContext");
|
|
1448
|
+
let dl = Symbol("PortalGroupContext"), cl = k({ name: "PortalGroup", props: { as: { type: [Object, String], default: "template" }, target: { type: Object, default: null } }, setup(e2, { attrs: t2, slots: l2 }) {
|
|
1436
1449
|
let n2 = C({ resolveTarget: () => e2.target });
|
|
1437
|
-
return S(
|
|
1450
|
+
return S(dl, n2), () => {
|
|
1438
1451
|
let { target: n3, ...a2 } = e2;
|
|
1439
1452
|
return ot({ theirProps: a2, ourProps: {}, slot: {}, attrs: t2, slots: l2, name: "PortalGroup" });
|
|
1440
1453
|
};
|
|
1441
1454
|
} });
|
|
1442
|
-
var
|
|
1443
|
-
let
|
|
1444
|
-
function
|
|
1445
|
-
let t2 = f(
|
|
1455
|
+
var pl = ((e2) => (e2[e2.Open = 0] = "Open", e2[e2.Closed = 1] = "Closed", e2))(pl || {});
|
|
1456
|
+
let gl = Symbol("DialogContext");
|
|
1457
|
+
function ml(e2) {
|
|
1458
|
+
let t2 = f(gl, null);
|
|
1446
1459
|
if (null === t2) {
|
|
1447
1460
|
let t3 = new Error(`<${e2} /> is missing a parent <Dialog /> component.`);
|
|
1448
|
-
throw Error.captureStackTrace && Error.captureStackTrace(t3,
|
|
1461
|
+
throw Error.captureStackTrace && Error.captureStackTrace(t3, ml), t3;
|
|
1449
1462
|
}
|
|
1450
1463
|
return t2;
|
|
1451
1464
|
}
|
|
1452
|
-
let
|
|
1465
|
+
let fl = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", vl = k({ name: "Dialog", inheritAttrs: false, props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, open: { type: [Boolean, String], default: fl }, initialFocus: { type: Object, default: null }, id: { type: String, default: null }, role: { type: String, default: "dialog" } }, emits: { close: (e2) => true }, setup(e2, { emit: t2, attrs: l2, slots: n2, expose: a2 }) {
|
|
1453
1466
|
var o2, r2;
|
|
1454
1467
|
let i2 = null != (o2 = e2.id) ? o2 : `headlessui-dialog-${De()}`, d2 = s(false);
|
|
1455
1468
|
b(() => {
|
|
1456
1469
|
d2.value = true;
|
|
1457
1470
|
});
|
|
1458
|
-
let c2 = false, p2 = u(() => "dialog" === e2.role || "alertdialog" === e2.role ? e2.role : (c2 || (c2 = true, console.warn(`Invalid role [${p2}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)), "dialog")), g2 = s(0), m2 = ft(), y2 = u(() => e2.open ===
|
|
1459
|
-
if (a2({ el: w2, $el: w2 }), e2.open ===
|
|
1471
|
+
let c2 = false, p2 = u(() => "dialog" === e2.role || "alertdialog" === e2.role ? e2.role : (c2 || (c2 = true, console.warn(`Invalid role [${p2}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)), "dialog")), g2 = s(0), m2 = ft(), y2 = u(() => e2.open === fl && null !== m2 ? (m2.value & mt.Open) === mt.Open : e2.open), w2 = s(null), C2 = u(() => je(w2));
|
|
1472
|
+
if (a2({ el: w2, $el: w2 }), e2.open === fl && null === m2)
|
|
1460
1473
|
throw new Error("You forgot to provide an `open` prop to the `Dialog`.");
|
|
1461
1474
|
if ("boolean" != typeof y2.value)
|
|
1462
|
-
throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${y2.value ===
|
|
1463
|
-
let O2 = u(() => d2.value && y2.value ? 0 : 1), M2 = u(() => 0 === O2.value), D2 = u(() => g2.value > 1),
|
|
1464
|
-
let e3 = f(
|
|
1475
|
+
throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${y2.value === fl ? void 0 : e2.open}`);
|
|
1476
|
+
let O2 = u(() => d2.value && y2.value ? 0 : 1), M2 = u(() => 0 === O2.value), D2 = u(() => g2.value > 1), T2 = null !== f(gl, null), [E2, I2] = function() {
|
|
1477
|
+
let e3 = f(ul, null), t3 = s([]);
|
|
1465
1478
|
function l3(l4) {
|
|
1466
1479
|
let n4 = t3.value.indexOf(l4);
|
|
1467
1480
|
-1 !== n4 && t3.value.splice(n4, 1), e3 && e3.unregister(l4);
|
|
@@ -1469,7 +1482,7 @@ let gl = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", ml = k({ name: "Dialog", inheri
|
|
|
1469
1482
|
let n3 = { register: function(n4) {
|
|
1470
1483
|
return t3.value.push(n4), e3 && e3.register(n4), () => l3(n4);
|
|
1471
1484
|
}, unregister: l3, portals: t3 };
|
|
1472
|
-
return [t3, k({ name: "PortalWrapper", setup: (e4, { slots: t4 }) => (S(
|
|
1485
|
+
return [t3, k({ name: "PortalWrapper", setup: (e4, { slots: t4 }) => (S(ul, n3), () => {
|
|
1473
1486
|
var e5;
|
|
1474
1487
|
return null == (e5 = t4.default) ? void 0 : e5.call(t4);
|
|
1475
1488
|
}) })];
|
|
@@ -1484,32 +1497,32 @@ let gl = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", ml = k({ name: "Dialog", inheri
|
|
|
1484
1497
|
for (let e4 of t3.value)
|
|
1485
1498
|
i3.push(e4);
|
|
1486
1499
|
for (let e4 of null != (l4 = null == a3 ? void 0 : a3.querySelectorAll("html > *, body > *")) ? l4 : [])
|
|
1487
|
-
e4 !== document.body && e4 !== document.head && e4 instanceof HTMLElement && "headlessui-portal-root" !== e4.id && (e4.contains(
|
|
1500
|
+
e4 !== document.body && e4 !== document.head && e4 instanceof HTMLElement && "headlessui-portal-root" !== e4.id && (e4.contains(Te(n3)) || e4.contains(null == (r3 = null == (o4 = Te(n3)) ? void 0 : o4.getRootNode()) ? void 0 : r3.host) || i3.some((t4) => e4.contains(t4)) || i3.push(e4));
|
|
1488
1501
|
return i3;
|
|
1489
1502
|
}
|
|
1490
1503
|
return { resolveContainers: o3, contains: (e4) => o3().some((t4) => t4.contains(e4)), mainTreeNodeRef: n3, MainTreeNode: () => null != l3 ? null : x(pt, { features: ct.Hidden, ref: n3 }) };
|
|
1491
|
-
}({ portals:
|
|
1504
|
+
}({ portals: E2, defaultContainers: [u(() => {
|
|
1492
1505
|
var e3;
|
|
1493
1506
|
return null != (e3 = V2.panelRef.value) ? e3 : w2.value;
|
|
1494
|
-
})] }), R2 = u(() => D2.value ? "parent" : "leaf"), B2 = u(() => null !== m2 && (m2.value & mt.Closing) === mt.Closing), A2 = u(() => !
|
|
1507
|
+
})] }), R2 = u(() => D2.value ? "parent" : "leaf"), B2 = u(() => null !== m2 && (m2.value & mt.Closing) === mt.Closing), A2 = u(() => !T2 && !B2.value && M2.value), L2 = u(() => {
|
|
1495
1508
|
var e3, t3, l3;
|
|
1496
|
-
return null != (l3 = Array.from(null != (t3 = null == (e3 = C2.value) ? void 0 : e3.querySelectorAll("body > *")) ? t3 : []).find((e4) => "headlessui-portal-root" !== e4.id && (e4.contains(
|
|
1509
|
+
return null != (l3 = Array.from(null != (t3 = null == (e3 = C2.value) ? void 0 : e3.querySelectorAll("body > *")) ? t3 : []).find((e4) => "headlessui-portal-root" !== e4.id && (e4.contains(Te(P2)) && e4 instanceof HTMLElement))) ? l3 : null;
|
|
1497
1510
|
});
|
|
1498
1511
|
Zt(L2, A2);
|
|
1499
1512
|
let F2 = u(() => !!D2.value || M2.value), N2 = u(() => {
|
|
1500
1513
|
var e3, t3, l3;
|
|
1501
|
-
return null != (l3 = Array.from(null != (t3 = null == (e3 = C2.value) ? void 0 : e3.querySelectorAll("[data-headlessui-portal]")) ? t3 : []).find((e4) => e4.contains(
|
|
1514
|
+
return null != (l3 = Array.from(null != (t3 = null == (e3 = C2.value) ? void 0 : e3.querySelectorAll("[data-headlessui-portal]")) ? t3 : []).find((e4) => e4.contains(Te(P2)) && e4 instanceof HTMLElement)) ? l3 : null;
|
|
1502
1515
|
});
|
|
1503
1516
|
Zt(N2, F2), nl({ type: "Dialog", enabled: u(() => 0 === O2.value), element: w2, onUpdate: (e3, t3) => {
|
|
1504
1517
|
if ("Dialog" === t3)
|
|
1505
|
-
return
|
|
1518
|
+
return Ee(e3, { [ll.Add]: () => g2.value += 1, [ll.Remove]: () => g2.value -= 1 });
|
|
1506
1519
|
} });
|
|
1507
1520
|
let z2 = ol({ name: "DialogDescription", slot: u(() => ({ open: y2.value })) }), $2 = s(null), V2 = { titleId: $2, panelRef: s(null), dialogState: O2, setTitleId(e3) {
|
|
1508
1521
|
$2.value !== e3 && ($2.value = e3);
|
|
1509
1522
|
}, close() {
|
|
1510
1523
|
t2("close", false);
|
|
1511
1524
|
} };
|
|
1512
|
-
S(
|
|
1525
|
+
S(gl, V2);
|
|
1513
1526
|
let H2 = u(() => !(!M2.value || D2.value));
|
|
1514
1527
|
Ze(_2, (e3, t3) => {
|
|
1515
1528
|
e3.preventDefault(), V2.close(), v(() => null == t3 ? void 0 : t3.focus());
|
|
@@ -1518,14 +1531,14 @@ let gl = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", ml = k({ name: "Dialog", inheri
|
|
|
1518
1531
|
Nt(null == (r2 = C2.value) ? void 0 : r2.defaultView, "keydown", (e3) => {
|
|
1519
1532
|
Y2.value && (e3.defaultPrevented || e3.key === ht.Escape && (e3.preventDefault(), e3.stopPropagation(), V2.close()));
|
|
1520
1533
|
});
|
|
1521
|
-
let U2 = u(() => !(B2.value || 0 !== O2.value ||
|
|
1534
|
+
let U2 = u(() => !(B2.value || 0 !== O2.value || T2));
|
|
1522
1535
|
return Kt(C2, U2, (e3) => {
|
|
1523
1536
|
var t3;
|
|
1524
1537
|
return { containers: [...null != (t3 = e3.containers) ? t3 : [], _2] };
|
|
1525
1538
|
}), h((e3) => {
|
|
1526
1539
|
if (0 !== O2.value)
|
|
1527
1540
|
return;
|
|
1528
|
-
let t3 =
|
|
1541
|
+
let t3 = Te(w2);
|
|
1529
1542
|
if (!t3)
|
|
1530
1543
|
return;
|
|
1531
1544
|
let l3 = new ResizeObserver((e4) => {
|
|
@@ -1537,12 +1550,12 @@ let gl = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", ml = k({ name: "Dialog", inheri
|
|
|
1537
1550
|
l3.observe(t3), e3(() => l3.disconnect());
|
|
1538
1551
|
}), () => {
|
|
1539
1552
|
let { open: t3, initialFocus: a3, ...o3 } = e2, r3 = { ...l2, ref: w2, id: i2, role: p2.value, "aria-modal": 0 === O2.value || void 0, "aria-labelledby": $2.value, "aria-describedby": z2.value }, s2 = { open: 0 === O2.value };
|
|
1540
|
-
return x(el, { force: true }, () => [x(
|
|
1553
|
+
return x(el, { force: true }, () => [x(sl, () => x(cl, { target: w2.value }, () => x(el, { force: false }, () => x(Ht, { initialFocus: a3, containers: _2, features: M2.value ? Ee(R2.value, { parent: Ht.features.RestoreFocus, leaf: Ht.features.All & ~Ht.features.FocusLock }) : Ht.features.None }, () => x(I2, {}, () => ot({ ourProps: r3, theirProps: { ...o3, ...l2 }, slot: s2, attrs: l2, slots: n2, visible: 0 === O2.value, features: nt.RenderStrategy | nt.Static, name: "Dialog" })))))), x(j2)]);
|
|
1541
1554
|
};
|
|
1542
1555
|
} });
|
|
1543
1556
|
k({ name: "DialogOverlay", props: { as: { type: [Object, String], default: "div" }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2 }) {
|
|
1544
1557
|
var n2;
|
|
1545
|
-
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-dialog-overlay-${De()}`, o2 =
|
|
1558
|
+
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-dialog-overlay-${De()}`, o2 = ml("DialogOverlay");
|
|
1546
1559
|
function r2(e3) {
|
|
1547
1560
|
e3.target === e3.currentTarget && (e3.preventDefault(), e3.stopPropagation(), o2.close());
|
|
1548
1561
|
}
|
|
@@ -1552,18 +1565,18 @@ k({ name: "DialogOverlay", props: { as: { type: [Object, String], default: "div"
|
|
|
1552
1565
|
};
|
|
1553
1566
|
} }), k({ name: "DialogBackdrop", props: { as: { type: [Object, String], default: "div" }, id: { type: String, default: null } }, inheritAttrs: false, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1554
1567
|
var a2;
|
|
1555
|
-
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-dialog-backdrop-${De()}`, r2 =
|
|
1568
|
+
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-dialog-backdrop-${De()}`, r2 = ml("DialogBackdrop"), i2 = s(null);
|
|
1556
1569
|
return n2({ el: i2, $el: i2 }), b(() => {
|
|
1557
1570
|
if (null === r2.panelRef.value)
|
|
1558
1571
|
throw new Error("A <DialogBackdrop /> component is being used, but a <DialogPanel /> component is missing.");
|
|
1559
1572
|
}), () => {
|
|
1560
1573
|
let { ...n3 } = e2, a3 = { id: o2, ref: i2, "aria-hidden": true };
|
|
1561
|
-
return x(el, { force: true }, () => x(
|
|
1574
|
+
return x(el, { force: true }, () => x(sl, () => ot({ ourProps: a3, theirProps: { ...t2, ...n3 }, slot: { open: 0 === r2.dialogState.value }, attrs: t2, slots: l2, name: "DialogBackdrop" })));
|
|
1562
1575
|
};
|
|
1563
1576
|
} });
|
|
1564
|
-
let
|
|
1577
|
+
let hl = k({ name: "DialogPanel", props: { as: { type: [Object, String], default: "div" }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1565
1578
|
var a2;
|
|
1566
|
-
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-dialog-panel-${De()}`, r2 =
|
|
1579
|
+
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-dialog-panel-${De()}`, r2 = ml("DialogPanel");
|
|
1567
1580
|
function i2(e3) {
|
|
1568
1581
|
e3.stopPropagation();
|
|
1569
1582
|
}
|
|
@@ -1571,9 +1584,9 @@ let fl = k({ name: "DialogPanel", props: { as: { type: [Object, String], default
|
|
|
1571
1584
|
let { ...n3 } = e2;
|
|
1572
1585
|
return ot({ ourProps: { id: o2, ref: r2.panelRef, onClick: i2 }, theirProps: n3, slot: { open: 0 === r2.dialogState.value }, attrs: t2, slots: l2, name: "DialogPanel" });
|
|
1573
1586
|
};
|
|
1574
|
-
} }),
|
|
1587
|
+
} }), bl = k({ name: "DialogTitle", props: { as: { type: [Object, String], default: "h2" }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2 }) {
|
|
1575
1588
|
var n2;
|
|
1576
|
-
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-dialog-title-${De()}`, o2 =
|
|
1589
|
+
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-dialog-title-${De()}`, o2 = ml("DialogTitle");
|
|
1577
1590
|
return b(() => {
|
|
1578
1591
|
o2.setTitleId(a2), O(() => o2.setTitleId(null));
|
|
1579
1592
|
}), () => {
|
|
@@ -1581,33 +1594,33 @@ let fl = k({ name: "DialogPanel", props: { as: { type: [Object, String], default
|
|
|
1581
1594
|
return ot({ ourProps: { id: a2 }, theirProps: n3, slot: { open: 0 === o2.dialogState.value }, attrs: t2, slots: l2, name: "DialogTitle" });
|
|
1582
1595
|
};
|
|
1583
1596
|
} });
|
|
1584
|
-
var
|
|
1585
|
-
let
|
|
1586
|
-
function
|
|
1587
|
-
let t2 = f(
|
|
1597
|
+
var yl = ((e2) => (e2[e2.Open = 0] = "Open", e2[e2.Closed = 1] = "Closed", e2))(yl || {});
|
|
1598
|
+
let xl = Symbol("DisclosureContext");
|
|
1599
|
+
function wl(e2) {
|
|
1600
|
+
let t2 = f(xl, null);
|
|
1588
1601
|
if (null === t2) {
|
|
1589
1602
|
let t3 = new Error(`<${e2} /> is missing a parent <Disclosure /> component.`);
|
|
1590
|
-
throw Error.captureStackTrace && Error.captureStackTrace(t3,
|
|
1603
|
+
throw Error.captureStackTrace && Error.captureStackTrace(t3, wl), t3;
|
|
1591
1604
|
}
|
|
1592
1605
|
return t2;
|
|
1593
1606
|
}
|
|
1594
|
-
let
|
|
1595
|
-
let
|
|
1607
|
+
let kl = Symbol("DisclosurePanelContext");
|
|
1608
|
+
let Sl = k({ name: "Disclosure", props: { as: { type: [Object, String], default: "template" }, defaultOpen: { type: [Boolean], default: false } }, setup(e2, { slots: t2, attrs: l2 }) {
|
|
1596
1609
|
let n2 = s(e2.defaultOpen ? 0 : 1), a2 = s(null), o2 = s(null), r2 = { buttonId: s(`headlessui-disclosure-button-${De()}`), panelId: s(`headlessui-disclosure-panel-${De()}`), disclosureState: n2, panel: a2, button: o2, toggleDisclosure() {
|
|
1597
|
-
n2.value =
|
|
1610
|
+
n2.value = Ee(n2.value, { 0: 1, 1: 0 });
|
|
1598
1611
|
}, closeDisclosure() {
|
|
1599
1612
|
1 !== n2.value && (n2.value = 1);
|
|
1600
1613
|
}, close(e3) {
|
|
1601
1614
|
r2.closeDisclosure();
|
|
1602
|
-
let t3 = e3 ? e3 instanceof HTMLElement ? e3 : e3.value instanceof HTMLElement ?
|
|
1615
|
+
let t3 = e3 ? e3 instanceof HTMLElement ? e3 : e3.value instanceof HTMLElement ? Te(e3) : Te(r2.button) : Te(r2.button);
|
|
1603
1616
|
null == t3 || t3.focus();
|
|
1604
1617
|
} };
|
|
1605
|
-
return S(
|
|
1618
|
+
return S(xl, r2), vt(u(() => Ee(n2.value, { 0: mt.Open, 1: mt.Closed }))), () => {
|
|
1606
1619
|
let { defaultOpen: a3, ...o3 } = e2;
|
|
1607
1620
|
return ot({ theirProps: o3, ourProps: {}, slot: { open: 0 === n2.value, close: r2.close }, slots: t2, attrs: l2, name: "Disclosure" });
|
|
1608
1621
|
};
|
|
1609
|
-
} }),
|
|
1610
|
-
let a2 =
|
|
1622
|
+
} }), Cl = k({ name: "DisclosureButton", props: { as: { type: [Object, String], default: "button" }, disabled: { type: [Boolean], default: false }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1623
|
+
let a2 = wl("DisclosureButton"), o2 = f(kl, null), r2 = u(() => null !== o2 && o2.value === a2.panelId.value);
|
|
1611
1624
|
b(() => {
|
|
1612
1625
|
r2.value || null !== e2.id && (a2.buttonId.value = e2.id);
|
|
1613
1626
|
}), O(() => {
|
|
@@ -1620,7 +1633,7 @@ let wl = k({ name: "Disclosure", props: { as: { type: [Object, String], default:
|
|
|
1620
1633
|
let d2 = Qe(u(() => ({ as: e2.as, type: t2.type })), i2);
|
|
1621
1634
|
function c2() {
|
|
1622
1635
|
var t3;
|
|
1623
|
-
e2.disabled || (r2.value ? (a2.toggleDisclosure(), null == (t3 =
|
|
1636
|
+
e2.disabled || (r2.value ? (a2.toggleDisclosure(), null == (t3 = Te(a2.button)) || t3.focus()) : a2.toggleDisclosure());
|
|
1624
1637
|
}
|
|
1625
1638
|
function p2(t3) {
|
|
1626
1639
|
var l3;
|
|
@@ -1629,7 +1642,7 @@ let wl = k({ name: "Disclosure", props: { as: { type: [Object, String], default:
|
|
|
1629
1642
|
switch (t3.key) {
|
|
1630
1643
|
case ht.Space:
|
|
1631
1644
|
case ht.Enter:
|
|
1632
|
-
t3.preventDefault(), t3.stopPropagation(), a2.toggleDisclosure(), null == (l3 =
|
|
1645
|
+
t3.preventDefault(), t3.stopPropagation(), a2.toggleDisclosure(), null == (l3 = Te(a2.button)) || l3.focus();
|
|
1633
1646
|
}
|
|
1634
1647
|
else
|
|
1635
1648
|
switch (t3.key) {
|
|
@@ -1645,23 +1658,23 @@ let wl = k({ name: "Disclosure", props: { as: { type: [Object, String], default:
|
|
|
1645
1658
|
return () => {
|
|
1646
1659
|
var n3;
|
|
1647
1660
|
let o3 = { open: 0 === a2.disclosureState.value }, { id: s2, ...u2 } = e2;
|
|
1648
|
-
return ot({ ourProps: r2.value ? { ref: i2, type: d2.value, onClick: c2, onKeydown: p2 } : { id: null != (n3 = a2.buttonId.value) ? n3 : s2, ref: i2, type: d2.value, "aria-expanded": 0 === a2.disclosureState.value, "aria-controls": 0 === a2.disclosureState.value ||
|
|
1661
|
+
return ot({ ourProps: r2.value ? { ref: i2, type: d2.value, onClick: c2, onKeydown: p2 } : { id: null != (n3 = a2.buttonId.value) ? n3 : s2, ref: i2, type: d2.value, "aria-expanded": 0 === a2.disclosureState.value, "aria-controls": 0 === a2.disclosureState.value || Te(a2.panel) ? a2.panelId.value : void 0, disabled: !!e2.disabled || void 0, onClick: c2, onKeydown: p2, onKeyup: g2 }, theirProps: u2, slot: o3, attrs: t2, slots: l2, name: "DisclosureButton" });
|
|
1649
1662
|
};
|
|
1650
|
-
} }),
|
|
1651
|
-
let a2 =
|
|
1663
|
+
} }), Ol = k({ name: "DisclosurePanel", props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1664
|
+
let a2 = wl("DisclosurePanel");
|
|
1652
1665
|
b(() => {
|
|
1653
1666
|
null !== e2.id && (a2.panelId.value = e2.id);
|
|
1654
1667
|
}), O(() => {
|
|
1655
1668
|
a2.panelId.value = null;
|
|
1656
|
-
}), n2({ el: a2.panel, $el: a2.panel }), S(
|
|
1669
|
+
}), n2({ el: a2.panel, $el: a2.panel }), S(kl, a2.panelId);
|
|
1657
1670
|
let o2 = ft(), r2 = u(() => null !== o2 ? (o2.value & mt.Open) === mt.Open : 0 === a2.disclosureState.value);
|
|
1658
1671
|
return () => {
|
|
1659
1672
|
var n3;
|
|
1660
1673
|
let o3 = { open: 0 === a2.disclosureState.value, close: a2.close }, { id: i2, ...s2 } = e2;
|
|
1661
1674
|
return ot({ ourProps: { id: null != (n3 = a2.panelId.value) ? n3 : i2, ref: a2.panel }, theirProps: s2, slot: o3, attrs: t2, slots: l2, features: nt.RenderStrategy | nt.Static, visible: r2.value, name: "DisclosurePanel" });
|
|
1662
1675
|
};
|
|
1663
|
-
} }),
|
|
1664
|
-
function
|
|
1676
|
+
} }), Ml = /([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;
|
|
1677
|
+
function Dl(e2) {
|
|
1665
1678
|
var t2, l2;
|
|
1666
1679
|
let n2 = null != (t2 = e2.innerText) ? t2 : "", a2 = e2.cloneNode(true);
|
|
1667
1680
|
if (!(a2 instanceof HTMLElement))
|
|
@@ -1670,12 +1683,12 @@ function Ol(e2) {
|
|
|
1670
1683
|
for (let e3 of a2.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))
|
|
1671
1684
|
e3.remove(), o2 = true;
|
|
1672
1685
|
let r2 = o2 ? null != (l2 = a2.innerText) ? l2 : "" : n2;
|
|
1673
|
-
return
|
|
1686
|
+
return Ml.test(r2) && (r2 = r2.replace(Ml, "")), r2;
|
|
1674
1687
|
}
|
|
1675
|
-
function
|
|
1688
|
+
function Tl(e2) {
|
|
1676
1689
|
let t2 = s(""), l2 = s("");
|
|
1677
1690
|
return () => {
|
|
1678
|
-
let n2 =
|
|
1691
|
+
let n2 = Te(e2);
|
|
1679
1692
|
if (!n2)
|
|
1680
1693
|
return "";
|
|
1681
1694
|
let a2 = n2.innerText;
|
|
@@ -1691,32 +1704,32 @@ function Ml(e2) {
|
|
|
1691
1704
|
let t4 = document.getElementById(e5);
|
|
1692
1705
|
if (t4) {
|
|
1693
1706
|
let e6 = t4.getAttribute("aria-label");
|
|
1694
|
-
return "string" == typeof e6 ? e6.trim() :
|
|
1707
|
+
return "string" == typeof e6 ? e6.trim() : Dl(t4).trim();
|
|
1695
1708
|
}
|
|
1696
1709
|
return null;
|
|
1697
1710
|
}).filter(Boolean);
|
|
1698
1711
|
if (e4.length > 0)
|
|
1699
1712
|
return e4.join(", ");
|
|
1700
1713
|
}
|
|
1701
|
-
return
|
|
1714
|
+
return Dl(e3).trim();
|
|
1702
1715
|
}(n2).trim().toLowerCase();
|
|
1703
1716
|
return t2.value = a2, l2.value = o2, o2;
|
|
1704
1717
|
};
|
|
1705
1718
|
}
|
|
1706
|
-
var
|
|
1707
|
-
let
|
|
1708
|
-
function
|
|
1709
|
-
let t2 = f(
|
|
1719
|
+
var El = ((e2) => (e2[e2.Open = 0] = "Open", e2[e2.Closed = 1] = "Closed", e2))(El || {}), Il = ((e2) => (e2[e2.Pointer = 0] = "Pointer", e2[e2.Other = 1] = "Other", e2))(Il || {});
|
|
1720
|
+
let _l = Symbol("MenuContext");
|
|
1721
|
+
function Pl(e2) {
|
|
1722
|
+
let t2 = f(_l, null);
|
|
1710
1723
|
if (null === t2) {
|
|
1711
1724
|
let t3 = new Error(`<${e2} /> is missing a parent <Menu /> component.`);
|
|
1712
|
-
throw Error.captureStackTrace && Error.captureStackTrace(t3,
|
|
1725
|
+
throw Error.captureStackTrace && Error.captureStackTrace(t3, Pl), t3;
|
|
1713
1726
|
}
|
|
1714
1727
|
return t2;
|
|
1715
1728
|
}
|
|
1716
|
-
let
|
|
1729
|
+
let jl = k({ name: "Menu", props: { as: { type: [Object, String], default: "template" } }, setup(e2, { slots: t2, attrs: l2 }) {
|
|
1717
1730
|
let n2 = s(1), a2 = s(null), o2 = s(null), r2 = s([]), i2 = s(""), d2 = s(null), c2 = s(1);
|
|
1718
1731
|
function p2(e3 = (e4) => e4) {
|
|
1719
|
-
let t3 = null !== d2.value ? r2.value[d2.value] : null, l3 = Ue(e3(r2.value.slice()), (e4) =>
|
|
1732
|
+
let t3 = null !== d2.value ? r2.value[d2.value] : null, l3 = Ue(e3(r2.value.slice()), (e4) => Te(e4.dataRef.domRef)), n3 = t3 ? l3.indexOf(t3) : null;
|
|
1720
1733
|
return -1 === n3 && (n3 = null), { items: l3, activeItemIndex: n3 };
|
|
1721
1734
|
}
|
|
1722
1735
|
let g2 = { menuState: n2, buttonRef: a2, itemsRef: o2, items: r2, searchQuery: i2, activeItemIndex: d2, activationTrigger: c2, closeMenu: () => {
|
|
@@ -1743,14 +1756,14 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1743
1756
|
} };
|
|
1744
1757
|
return Ze([a2, o2], (e3, t3) => {
|
|
1745
1758
|
var l3;
|
|
1746
|
-
g2.closeMenu(), ze(t3, Ne.Loose) || (e3.preventDefault(), null == (l3 =
|
|
1747
|
-
}, u(() => 0 === n2.value)), S(
|
|
1759
|
+
g2.closeMenu(), ze(t3, Ne.Loose) || (e3.preventDefault(), null == (l3 = Te(a2)) || l3.focus());
|
|
1760
|
+
}, u(() => 0 === n2.value)), S(_l, g2), vt(u(() => Ee(n2.value, { 0: mt.Open, 1: mt.Closed }))), () => {
|
|
1748
1761
|
let a3 = { open: 0 === n2.value, close: g2.closeMenu };
|
|
1749
1762
|
return ot({ ourProps: {}, theirProps: e2, slot: a3, slots: t2, attrs: l2, name: "Menu" });
|
|
1750
1763
|
};
|
|
1751
|
-
} }),
|
|
1764
|
+
} }), Rl = k({ name: "MenuButton", props: { disabled: { type: Boolean, default: false }, as: { type: [Object, String], default: "button" }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1752
1765
|
var a2;
|
|
1753
|
-
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-button-${De()}`, r2 =
|
|
1766
|
+
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-button-${De()}`, r2 = Pl("MenuButton");
|
|
1754
1767
|
function i2(e3) {
|
|
1755
1768
|
switch (e3.key) {
|
|
1756
1769
|
case ht.Space:
|
|
@@ -1758,13 +1771,13 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1758
1771
|
case ht.ArrowDown:
|
|
1759
1772
|
e3.preventDefault(), e3.stopPropagation(), r2.openMenu(), v(() => {
|
|
1760
1773
|
var e4;
|
|
1761
|
-
null == (e4 =
|
|
1774
|
+
null == (e4 = Te(r2.itemsRef)) || e4.focus({ preventScroll: true }), r2.goToItem(yt.First);
|
|
1762
1775
|
});
|
|
1763
1776
|
break;
|
|
1764
1777
|
case ht.ArrowUp:
|
|
1765
1778
|
e3.preventDefault(), e3.stopPropagation(), r2.openMenu(), v(() => {
|
|
1766
1779
|
var e4;
|
|
1767
|
-
null == (e4 =
|
|
1780
|
+
null == (e4 = Te(r2.itemsRef)) || e4.focus({ preventScroll: true }), r2.goToItem(yt.Last);
|
|
1768
1781
|
});
|
|
1769
1782
|
}
|
|
1770
1783
|
}
|
|
@@ -1775,12 +1788,12 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1775
1788
|
function d2(t3) {
|
|
1776
1789
|
e2.disabled || (0 === r2.menuState.value ? (r2.closeMenu(), v(() => {
|
|
1777
1790
|
var e3;
|
|
1778
|
-
return null == (e3 =
|
|
1791
|
+
return null == (e3 = Te(r2.buttonRef)) ? void 0 : e3.focus({ preventScroll: true });
|
|
1779
1792
|
})) : (t3.preventDefault(), r2.openMenu(), function(e3) {
|
|
1780
1793
|
requestAnimationFrame(() => requestAnimationFrame(e3));
|
|
1781
1794
|
}(() => {
|
|
1782
1795
|
var e3;
|
|
1783
|
-
return null == (e3 =
|
|
1796
|
+
return null == (e3 = Te(r2.itemsRef)) ? void 0 : e3.focus({ preventScroll: true });
|
|
1784
1797
|
})));
|
|
1785
1798
|
}
|
|
1786
1799
|
n2({ el: r2.buttonRef, $el: r2.buttonRef });
|
|
@@ -1788,11 +1801,11 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1788
1801
|
return () => {
|
|
1789
1802
|
var n3;
|
|
1790
1803
|
let a3 = { open: 0 === r2.menuState.value }, { ...u2 } = e2;
|
|
1791
|
-
return ot({ ourProps: { ref: r2.buttonRef, id: o2, type: c2.value, "aria-haspopup": "menu", "aria-controls": null == (n3 =
|
|
1804
|
+
return ot({ ourProps: { ref: r2.buttonRef, id: o2, type: c2.value, "aria-haspopup": "menu", "aria-controls": null == (n3 = Te(r2.itemsRef)) ? void 0 : n3.id, "aria-expanded": 0 === r2.menuState.value, onKeydown: i2, onKeyup: s2, onClick: d2 }, theirProps: u2, slot: a3, attrs: t2, slots: l2, name: "MenuButton" });
|
|
1792
1805
|
};
|
|
1793
|
-
} }),
|
|
1806
|
+
} }), Bl = k({ name: "MenuItems", props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, id: { type: String, default: null } }, setup(e2, { attrs: t2, slots: l2, expose: n2 }) {
|
|
1794
1807
|
var a2;
|
|
1795
|
-
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-items-${De()}`, r2 =
|
|
1808
|
+
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-items-${De()}`, r2 = Pl("MenuItems"), i2 = s(null);
|
|
1796
1809
|
function d2(e3) {
|
|
1797
1810
|
var t3;
|
|
1798
1811
|
switch (i2.value && clearTimeout(i2.value), e3.key) {
|
|
@@ -1801,9 +1814,9 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1801
1814
|
return e3.preventDefault(), e3.stopPropagation(), r2.search(e3.key);
|
|
1802
1815
|
case ht.Enter:
|
|
1803
1816
|
if (e3.preventDefault(), e3.stopPropagation(), null !== r2.activeItemIndex.value) {
|
|
1804
|
-
null == (t3 =
|
|
1817
|
+
null == (t3 = Te(r2.items.value[r2.activeItemIndex.value].dataRef.domRef)) || t3.click();
|
|
1805
1818
|
}
|
|
1806
|
-
r2.closeMenu(), $e(
|
|
1819
|
+
r2.closeMenu(), $e(Te(r2.buttonRef));
|
|
1807
1820
|
break;
|
|
1808
1821
|
case ht.ArrowDown:
|
|
1809
1822
|
return e3.preventDefault(), e3.stopPropagation(), r2.goToItem(yt.Next);
|
|
@@ -1818,13 +1831,13 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1818
1831
|
case ht.Escape:
|
|
1819
1832
|
e3.preventDefault(), e3.stopPropagation(), r2.closeMenu(), v(() => {
|
|
1820
1833
|
var e4;
|
|
1821
|
-
return null == (e4 =
|
|
1834
|
+
return null == (e4 = Te(r2.buttonRef)) ? void 0 : e4.focus({ preventScroll: true });
|
|
1822
1835
|
});
|
|
1823
1836
|
break;
|
|
1824
1837
|
case ht.Tab:
|
|
1825
1838
|
e3.preventDefault(), e3.stopPropagation(), r2.closeMenu(), v(() => function(e4, t4) {
|
|
1826
1839
|
return qe(Fe(), t4, { relativeTo: e4 });
|
|
1827
|
-
}(
|
|
1840
|
+
}(Te(r2.buttonRef), e3.shiftKey ? Be.Previous : Be.Next));
|
|
1828
1841
|
break;
|
|
1829
1842
|
default:
|
|
1830
1843
|
1 === e3.key.length && (r2.search(e3.key), i2.value = setTimeout(() => r2.clearSearch(), 350));
|
|
@@ -1834,26 +1847,26 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1834
1847
|
if (e3.key === ht.Space)
|
|
1835
1848
|
e3.preventDefault();
|
|
1836
1849
|
}
|
|
1837
|
-
n2({ el: r2.itemsRef, $el: r2.itemsRef }), lt({ container: u(() =>
|
|
1850
|
+
n2({ el: r2.itemsRef, $el: r2.itemsRef }), lt({ container: u(() => Te(r2.itemsRef)), enabled: u(() => 0 === r2.menuState.value), accept: (e3) => "menuitem" === e3.getAttribute("role") ? NodeFilter.FILTER_REJECT : e3.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT, walk(e3) {
|
|
1838
1851
|
e3.setAttribute("role", "none");
|
|
1839
1852
|
} });
|
|
1840
1853
|
let p2 = ft(), g2 = u(() => null !== p2 ? (p2.value & mt.Open) === mt.Open : 0 === r2.menuState.value);
|
|
1841
1854
|
return () => {
|
|
1842
1855
|
var n3, a3;
|
|
1843
1856
|
let i3 = { open: 0 === r2.menuState.value }, { ...s2 } = e2;
|
|
1844
|
-
return ot({ ourProps: { "aria-activedescendant": null === r2.activeItemIndex.value || null == (n3 = r2.items.value[r2.activeItemIndex.value]) ? void 0 : n3.id, "aria-labelledby": null == (a3 =
|
|
1857
|
+
return ot({ ourProps: { "aria-activedescendant": null === r2.activeItemIndex.value || null == (n3 = r2.items.value[r2.activeItemIndex.value]) ? void 0 : n3.id, "aria-labelledby": null == (a3 = Te(r2.buttonRef)) ? void 0 : a3.id, id: o2, onKeydown: d2, onKeyup: c2, role: "menu", tabIndex: 0, ref: r2.itemsRef }, theirProps: s2, slot: i3, attrs: t2, slots: l2, features: nt.RenderStrategy | nt.Static, visible: g2.value, name: "MenuItems" });
|
|
1845
1858
|
};
|
|
1846
|
-
} }),
|
|
1859
|
+
} }), Al = k({ name: "MenuItem", inheritAttrs: false, props: { as: { type: [Object, String], default: "template" }, disabled: { type: Boolean, default: false }, id: { type: String, default: null } }, setup(e2, { slots: t2, attrs: l2, expose: n2 }) {
|
|
1847
1860
|
var a2;
|
|
1848
|
-
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-item-${De()}`, r2 =
|
|
1861
|
+
let o2 = null != (a2 = e2.id) ? a2 : `headlessui-menu-item-${De()}`, r2 = Pl("MenuItem"), i2 = s(null);
|
|
1849
1862
|
n2({ el: i2, $el: i2 });
|
|
1850
|
-
let d2 = u(() => null !== r2.activeItemIndex.value && r2.items.value[r2.activeItemIndex.value].id === o2), c2 =
|
|
1863
|
+
let d2 = u(() => null !== r2.activeItemIndex.value && r2.items.value[r2.activeItemIndex.value].id === o2), c2 = Tl(i2), p2 = u(() => ({ disabled: e2.disabled, get textValue() {
|
|
1851
1864
|
return c2();
|
|
1852
1865
|
}, domRef: i2 }));
|
|
1853
1866
|
function g2(t3) {
|
|
1854
1867
|
if (e2.disabled)
|
|
1855
1868
|
return t3.preventDefault();
|
|
1856
|
-
r2.closeMenu(), $e(
|
|
1869
|
+
r2.closeMenu(), $e(Te(r2.buttonRef));
|
|
1857
1870
|
}
|
|
1858
1871
|
function m2() {
|
|
1859
1872
|
if (e2.disabled)
|
|
@@ -1863,7 +1876,7 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1863
1876
|
b(() => r2.registerItem(o2, p2)), O(() => r2.unregisterItem(o2)), h(() => {
|
|
1864
1877
|
0 === r2.menuState.value && d2.value && 0 !== r2.activationTrigger.value && v(() => {
|
|
1865
1878
|
var e3, t3;
|
|
1866
|
-
return null == (t3 = null == (e3 =
|
|
1879
|
+
return null == (t3 = null == (e3 = Te(i2)) ? void 0 : e3.scrollIntoView) ? void 0 : t3.call(e3, { block: "nearest" });
|
|
1867
1880
|
});
|
|
1868
1881
|
});
|
|
1869
1882
|
let f2 = tt();
|
|
@@ -1880,26 +1893,26 @@ let _l = k({ name: "Menu", props: { as: { type: [Object, String], default: "temp
|
|
|
1880
1893
|
let { disabled: n3, ...a3 } = e2, s2 = { active: d2.value, disabled: n3, close: r2.closeMenu };
|
|
1881
1894
|
return ot({ ourProps: { id: o2, ref: i2, role: "menuitem", tabIndex: true === n3 ? void 0 : -1, "aria-disabled": true === n3 || void 0, onClick: g2, onFocus: m2, onPointerenter: y2, onMouseenter: y2, onPointermove: x2, onMousemove: x2, onPointerleave: w2, onMouseleave: w2 }, theirProps: { ...l2, ...a3 }, slot: s2, attrs: l2, slots: t2, name: "MenuItem" });
|
|
1882
1895
|
};
|
|
1883
|
-
} }),
|
|
1884
|
-
function
|
|
1885
|
-
let e2 = f(
|
|
1896
|
+
} }), Ll = Symbol("LabelContext");
|
|
1897
|
+
function Fl() {
|
|
1898
|
+
let e2 = f(Ll, null);
|
|
1886
1899
|
if (null === e2) {
|
|
1887
1900
|
let e3 = new Error("You used a <Label /> component, but it is not inside a parent.");
|
|
1888
|
-
throw Error.captureStackTrace && Error.captureStackTrace(e3,
|
|
1901
|
+
throw Error.captureStackTrace && Error.captureStackTrace(e3, Fl), e3;
|
|
1889
1902
|
}
|
|
1890
1903
|
return e2;
|
|
1891
1904
|
}
|
|
1892
|
-
let
|
|
1905
|
+
let Nl = k({ name: "Label", props: { as: { type: [Object, String], default: "label" }, passive: { type: [Boolean], default: false }, id: { type: String, default: null } }, setup(e2, { slots: t2, attrs: l2 }) {
|
|
1893
1906
|
var n2;
|
|
1894
|
-
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-label-${De()}`, o2 =
|
|
1907
|
+
let a2 = null != (n2 = e2.id) ? n2 : `headlessui-label-${De()}`, o2 = Fl();
|
|
1895
1908
|
return b(() => O(o2.register(a2))), () => {
|
|
1896
1909
|
let { name: n3 = "Label", slot: r2 = {}, props: i2 = {} } = o2, { passive: s2, ...u2 } = e2, c2 = { ...Object.entries(i2).reduce((e3, [t3, l3]) => Object.assign(e3, { [t3]: d(l3) }), {}), id: a2 };
|
|
1897
1910
|
return s2 && (delete c2.onClick, delete c2.htmlFor, delete u2.onClick), ot({ ourProps: c2, theirProps: u2, slot: r2, attrs: l2, slots: t2, name: n3 });
|
|
1898
1911
|
};
|
|
1899
|
-
} }),
|
|
1912
|
+
} }), zl = Symbol("GroupContext"), $l = k({ name: "SwitchGroup", props: { as: { type: [Object, String], default: "template" } }, setup(e2, { slots: t2, attrs: l2 }) {
|
|
1900
1913
|
let n2 = s(null), a2 = function({ slot: e3 = {}, name: t3 = "Label", props: l3 = {} } = {}) {
|
|
1901
1914
|
let n3 = s([]);
|
|
1902
|
-
return S(
|
|
1915
|
+
return S(Ll, { register: function(e4) {
|
|
1903
1916
|
return n3.value.push(e4), () => {
|
|
1904
1917
|
let t4 = n3.value.indexOf(e4);
|
|
1905
1918
|
-1 !== t4 && n3.value.splice(t4, 1);
|
|
@@ -1911,10 +1924,10 @@ let Ll = k({ name: "Label", props: { as: { type: [Object, String], default: "lab
|
|
|
1911
1924
|
}), onClick(e3) {
|
|
1912
1925
|
n2.value && ("LABEL" === e3.currentTarget.tagName && e3.preventDefault(), n2.value.click(), n2.value.focus({ preventScroll: true }));
|
|
1913
1926
|
} } }), o2 = ol({ name: "SwitchDescription" });
|
|
1914
|
-
return S(
|
|
1915
|
-
} }),
|
|
1927
|
+
return S(zl, { switchRef: n2, labelledby: a2, describedby: o2 }), () => ot({ theirProps: e2, ourProps: {}, slot: {}, slots: t2, attrs: l2, name: "SwitchGroup" });
|
|
1928
|
+
} }), Vl = k({ name: "Switch", emits: { "update:modelValue": (e2) => true }, props: { as: { type: [Object, String], default: "button" }, modelValue: { type: Boolean, default: void 0 }, defaultChecked: { type: Boolean, optional: true }, form: { type: String, optional: true }, name: { type: String, optional: true }, value: { type: String, optional: true }, id: { type: String, default: null }, disabled: { type: Boolean, default: false }, tabIndex: { type: Number, default: 0 } }, inheritAttrs: false, setup(e2, { emit: t2, attrs: l2, slots: n2, expose: a2 }) {
|
|
1916
1929
|
var o2;
|
|
1917
|
-
let r2 = null != (o2 = e2.id) ? o2 : `headlessui-switch-${De()}`, i2 = f(
|
|
1930
|
+
let r2 = null != (o2 = e2.id) ? o2 : `headlessui-switch-${De()}`, i2 = f(zl, null), [d2, c2] = Ce(u(() => e2.modelValue), (e3) => t2("update:modelValue", e3), u(() => e2.defaultChecked));
|
|
1918
1931
|
function g2() {
|
|
1919
1932
|
c2(!d2.value);
|
|
1920
1933
|
}
|
|
@@ -1940,7 +1953,7 @@ let Ll = k({ name: "Label", props: { as: { type: [Object, String], default: "lab
|
|
|
1940
1953
|
a2({ el: v2, $el: v2 });
|
|
1941
1954
|
let C2 = u(() => {
|
|
1942
1955
|
var e3, t3;
|
|
1943
|
-
return null == (t3 = null == (e3 =
|
|
1956
|
+
return null == (t3 = null == (e3 = Te(v2)) ? void 0 : e3.closest) ? void 0 : t3.call(e3, "form");
|
|
1944
1957
|
});
|
|
1945
1958
|
return b(() => {
|
|
1946
1959
|
p([C2], () => {
|
|
@@ -1957,15 +1970,15 @@ let Ll = k({ name: "Label", props: { as: { type: [Object, String], default: "lab
|
|
|
1957
1970
|
let { name: t3, value: a3, form: o3, tabIndex: s2, ...u2 } = e2, c3 = { checked: d2.value }, p2 = { id: r2, ref: v2, role: "switch", type: h2.value, tabIndex: -1 === s2 ? 0 : s2, "aria-checked": d2.value, "aria-labelledby": null == i2 ? void 0 : i2.labelledby.value, "aria-describedby": null == i2 ? void 0 : i2.describedby.value, onClick: y2, onKeyup: k2, onKeypress: S2 };
|
|
1958
1971
|
return x(w, [null != t3 && null != d2.value ? x(pt, ut({ features: ct.Hidden, as: "input", type: "checkbox", hidden: true, readOnly: true, checked: d2.value, form: o3, disabled: u2.disabled, name: t3, value: a3 })) : null, ot({ ourProps: p2, theirProps: { ...l2, ...dt(u2, ["modelValue", "defaultChecked"]) }, slot: c3, attrs: l2, slots: n2, name: "Switch" })]);
|
|
1959
1972
|
};
|
|
1960
|
-
} }),
|
|
1961
|
-
function
|
|
1973
|
+
} }), Hl = Nl;
|
|
1974
|
+
function Yl(e2, ...t2) {
|
|
1962
1975
|
e2 && t2.length > 0 && e2.classList.add(...t2);
|
|
1963
1976
|
}
|
|
1964
|
-
function
|
|
1977
|
+
function Ul(e2, ...t2) {
|
|
1965
1978
|
e2 && t2.length > 0 && e2.classList.remove(...t2);
|
|
1966
1979
|
}
|
|
1967
|
-
var
|
|
1968
|
-
function
|
|
1980
|
+
var ql = ((e2) => (e2.Finished = "finished", e2.Cancelled = "cancelled", e2))(ql || {});
|
|
1981
|
+
function Wl(e2, t2, l2, n2, a2, o2) {
|
|
1969
1982
|
let r2 = kt(), i2 = void 0 !== o2 ? /* @__PURE__ */ function(e3) {
|
|
1970
1983
|
let t3 = { called: false };
|
|
1971
1984
|
return (...l3) => {
|
|
@@ -1974,8 +1987,8 @@ function Ul(e2, t2, l2, n2, a2, o2) {
|
|
|
1974
1987
|
};
|
|
1975
1988
|
}(o2) : () => {
|
|
1976
1989
|
};
|
|
1977
|
-
return
|
|
1978
|
-
|
|
1990
|
+
return Ul(e2, ...a2), Yl(e2, ...t2, ...l2), r2.nextFrame(() => {
|
|
1991
|
+
Ul(e2, ...l2), Yl(e2, ...n2), r2.add(function(e3, t3) {
|
|
1979
1992
|
let l3 = kt();
|
|
1980
1993
|
if (!e3)
|
|
1981
1994
|
return l3.dispose;
|
|
@@ -1984,34 +1997,34 @@ function Ul(e2, t2, l2, n2, a2, o2) {
|
|
|
1984
1997
|
return t4;
|
|
1985
1998
|
});
|
|
1986
1999
|
return 0 !== o3 ? l3.setTimeout(() => t3("finished"), o3 + r3) : t3("finished"), l3.add(() => t3("cancelled")), l3.dispose;
|
|
1987
|
-
}(e2, (l3) => (
|
|
1988
|
-
}), r2.add(() =>
|
|
2000
|
+
}(e2, (l3) => (Ul(e2, ...n2, ...t2), Yl(e2, ...a2), i2(l3))));
|
|
2001
|
+
}), r2.add(() => Ul(e2, ...t2, ...l2, ...n2, ...a2)), r2.add(() => i2("cancelled")), r2.dispose;
|
|
1989
2002
|
}
|
|
1990
|
-
function
|
|
2003
|
+
function Kl(e2 = "") {
|
|
1991
2004
|
return e2.split(/\s+/).filter((e3) => e3.length > 1);
|
|
1992
2005
|
}
|
|
1993
|
-
let
|
|
1994
|
-
var
|
|
1995
|
-
let
|
|
1996
|
-
function
|
|
1997
|
-
return "children" in e2 ?
|
|
2006
|
+
let Jl = Symbol("TransitionContext");
|
|
2007
|
+
var Gl = ((e2) => (e2.Visible = "visible", e2.Hidden = "hidden", e2))(Gl || {});
|
|
2008
|
+
let Zl = Symbol("NestingContext");
|
|
2009
|
+
function Xl(e2) {
|
|
2010
|
+
return "children" in e2 ? Xl(e2.children) : e2.value.filter(({ state: e3 }) => "visible" === e3).length > 0;
|
|
1998
2011
|
}
|
|
1999
|
-
function
|
|
2012
|
+
function Ql(e2) {
|
|
2000
2013
|
let t2 = s([]), l2 = s(false);
|
|
2001
2014
|
function n2(n3, a2 = at.Hidden) {
|
|
2002
2015
|
let o2 = t2.value.findIndex(({ id: e3 }) => e3 === n3);
|
|
2003
|
-
-1 !== o2 && (
|
|
2016
|
+
-1 !== o2 && (Ee(a2, { [at.Unmount]() {
|
|
2004
2017
|
t2.value.splice(o2, 1);
|
|
2005
2018
|
}, [at.Hidden]() {
|
|
2006
2019
|
t2.value[o2].state = "hidden";
|
|
2007
|
-
} }), !
|
|
2020
|
+
} }), !Xl(t2) && l2.value && (null == e2 || e2()));
|
|
2008
2021
|
}
|
|
2009
2022
|
return b(() => l2.value = true), O(() => l2.value = false), { children: t2, register: function(e3) {
|
|
2010
2023
|
let l3 = t2.value.find(({ id: t3 }) => t3 === e3);
|
|
2011
2024
|
return l3 ? "visible" !== l3.state && (l3.state = "visible") : t2.value.push({ id: e3, state: "visible" }), () => n2(e3, at.Unmount);
|
|
2012
2025
|
}, unregister: n2 };
|
|
2013
2026
|
}
|
|
2014
|
-
let
|
|
2027
|
+
let en = nt.RenderStrategy, tn = k({ props: { as: { type: [Object, String], default: "div" }, show: { type: [Boolean], default: null }, unmount: { type: [Boolean], default: true }, appear: { type: [Boolean], default: false }, enter: { type: [String], default: "" }, enterFrom: { type: [String], default: "" }, enterTo: { type: [String], default: "" }, entered: { type: [String], default: "" }, leave: { type: [String], default: "" }, leaveFrom: { type: [String], default: "" }, leaveTo: { type: [String], default: "" } }, emits: { beforeEnter: () => true, afterEnter: () => true, beforeLeave: () => true, afterLeave: () => true }, setup(e2, { emit: t2, attrs: l2, slots: a2, expose: o2 }) {
|
|
2015
2028
|
let r2 = s(0);
|
|
2016
2029
|
function i2() {
|
|
2017
2030
|
r2.value |= mt.Opening, t2("beforeEnter");
|
|
@@ -2025,38 +2038,38 @@ let Xl = nt.RenderStrategy, Ql = k({ props: { as: { type: [Object, String], defa
|
|
|
2025
2038
|
function g2() {
|
|
2026
2039
|
r2.value &= ~mt.Closing, t2("afterLeave");
|
|
2027
2040
|
}
|
|
2028
|
-
if (null === f(
|
|
2029
|
-
return () => x(
|
|
2041
|
+
if (null === f(Jl, null) && null !== ft())
|
|
2042
|
+
return () => x(nn, { ...e2, onBeforeEnter: i2, onAfterEnter: d2, onBeforeLeave: c2, onAfterLeave: g2 }, a2);
|
|
2030
2043
|
let m2 = s(null), v2 = u(() => e2.unmount ? at.Unmount : at.Hidden);
|
|
2031
2044
|
o2({ el: m2, $el: m2 });
|
|
2032
2045
|
let { show: y2, appear: w2 } = function() {
|
|
2033
|
-
let e3 = f(
|
|
2046
|
+
let e3 = f(Jl, null);
|
|
2034
2047
|
if (null === e3)
|
|
2035
2048
|
throw new Error("A <TransitionChild /> is used but it is missing a parent <TransitionRoot />.");
|
|
2036
2049
|
return e3;
|
|
2037
2050
|
}(), { register: k2, unregister: C2 } = function() {
|
|
2038
|
-
let e3 = f(
|
|
2051
|
+
let e3 = f(Zl, null);
|
|
2039
2052
|
if (null === e3)
|
|
2040
2053
|
throw new Error("A <TransitionChild /> is used but it is missing a parent <TransitionRoot />.");
|
|
2041
2054
|
return e3;
|
|
2042
|
-
}(), M2 = s(y2.value ? "visible" : "hidden"), D2 = { value: true },
|
|
2043
|
-
!
|
|
2055
|
+
}(), M2 = s(y2.value ? "visible" : "hidden"), D2 = { value: true }, T2 = De(), E2 = { value: false }, I2 = Ql(() => {
|
|
2056
|
+
!E2.value && "hidden" !== M2.value && (M2.value = "hidden", C2(T2), g2());
|
|
2044
2057
|
});
|
|
2045
2058
|
b(() => {
|
|
2046
|
-
let e3 = k2(
|
|
2059
|
+
let e3 = k2(T2);
|
|
2047
2060
|
O(e3);
|
|
2048
2061
|
}), h(() => {
|
|
2049
|
-
if (v2.value === at.Hidden &&
|
|
2062
|
+
if (v2.value === at.Hidden && T2) {
|
|
2050
2063
|
if (y2.value && "visible" !== M2.value)
|
|
2051
2064
|
return void (M2.value = "visible");
|
|
2052
|
-
|
|
2065
|
+
Ee(M2.value, { hidden: () => C2(T2), visible: () => k2(T2) });
|
|
2053
2066
|
}
|
|
2054
2067
|
});
|
|
2055
|
-
let _2 =
|
|
2068
|
+
let _2 = Kl(e2.enter), P2 = Kl(e2.enterFrom), j2 = Kl(e2.enterTo), R2 = Kl(e2.entered), B2 = Kl(e2.leave), A2 = Kl(e2.leaveFrom), L2 = Kl(e2.leaveTo);
|
|
2056
2069
|
return b(() => {
|
|
2057
2070
|
h(() => {
|
|
2058
2071
|
if ("visible" === M2.value) {
|
|
2059
|
-
let e3 =
|
|
2072
|
+
let e3 = Te(m2);
|
|
2060
2073
|
if (e3 instanceof Comment && "" === e3.data)
|
|
2061
2074
|
throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?");
|
|
2062
2075
|
}
|
|
@@ -2064,105 +2077,105 @@ let Xl = nt.RenderStrategy, Ql = k({ props: { as: { type: [Object, String], defa
|
|
|
2064
2077
|
}), b(() => {
|
|
2065
2078
|
p([y2], (e3, t3, l3) => {
|
|
2066
2079
|
(function(e4) {
|
|
2067
|
-
let t4 = D2.value && !w2.value, l4 =
|
|
2068
|
-
!l4 || !(l4 instanceof HTMLElement) || t4 || (
|
|
2069
|
-
|
|
2070
|
-
}) :
|
|
2071
|
-
|
|
2080
|
+
let t4 = D2.value && !w2.value, l4 = Te(m2);
|
|
2081
|
+
!l4 || !(l4 instanceof HTMLElement) || t4 || (E2.value = true, y2.value && i2(), y2.value || c2(), e4(y2.value ? Wl(l4, _2, P2, j2, R2, (e5) => {
|
|
2082
|
+
E2.value = false, e5 === ql.Finished && d2();
|
|
2083
|
+
}) : Wl(l4, B2, A2, L2, R2, (e5) => {
|
|
2084
|
+
E2.value = false, e5 === ql.Finished && (Xl(I2) || (M2.value = "hidden", C2(T2), g2()));
|
|
2072
2085
|
})));
|
|
2073
2086
|
})(l3), D2.value = false;
|
|
2074
2087
|
}, { immediate: true });
|
|
2075
|
-
}), S(
|
|
2088
|
+
}), S(Zl, I2), vt(u(() => Ee(M2.value, { visible: mt.Open, hidden: mt.Closed }) | r2.value)), () => {
|
|
2076
2089
|
let { appear: t3, show: o3, enter: r3, enterFrom: i3, enterTo: s2, entered: u2, leave: d3, leaveFrom: c3, leaveTo: p2, ...g3 } = e2, f2 = { ref: m2 };
|
|
2077
|
-
return ot({ theirProps: { ...g3, ...w2.value && y2.value && Pe.isServer ? { class: n([l2.class, g3.class, ..._2, ...P2]) } : {} }, ourProps: f2, slot: {}, slots: a2, attrs: l2, features:
|
|
2090
|
+
return ot({ theirProps: { ...g3, ...w2.value && y2.value && Pe.isServer ? { class: n([l2.class, g3.class, ..._2, ...P2]) } : {} }, ourProps: f2, slot: {}, slots: a2, attrs: l2, features: en, visible: "visible" === M2.value, name: "TransitionChild" });
|
|
2078
2091
|
};
|
|
2079
|
-
} }),
|
|
2092
|
+
} }), ln = tn, nn = k({ inheritAttrs: false, props: { as: { type: [Object, String], default: "div" }, show: { type: [Boolean], default: null }, unmount: { type: [Boolean], default: true }, appear: { type: [Boolean], default: false }, enter: { type: [String], default: "" }, enterFrom: { type: [String], default: "" }, enterTo: { type: [String], default: "" }, entered: { type: [String], default: "" }, leave: { type: [String], default: "" }, leaveFrom: { type: [String], default: "" }, leaveTo: { type: [String], default: "" } }, emits: { beforeEnter: () => true, afterEnter: () => true, beforeLeave: () => true, afterLeave: () => true }, setup(e2, { emit: t2, attrs: l2, slots: n2 }) {
|
|
2080
2093
|
let a2 = ft(), o2 = u(() => null === e2.show && null !== a2 ? (a2.value & mt.Open) === mt.Open : e2.show);
|
|
2081
2094
|
h(() => {
|
|
2082
2095
|
if (![true, false].includes(o2.value))
|
|
2083
2096
|
throw new Error('A <Transition /> is used but it is missing a `:show="true | false"` prop.');
|
|
2084
2097
|
});
|
|
2085
|
-
let r2 = s(o2.value ? "visible" : "hidden"), i2 =
|
|
2098
|
+
let r2 = s(o2.value ? "visible" : "hidden"), i2 = Ql(() => {
|
|
2086
2099
|
r2.value = "hidden";
|
|
2087
2100
|
}), d2 = s(true), c2 = { show: o2, appear: u(() => e2.appear || !d2.value) };
|
|
2088
2101
|
return b(() => {
|
|
2089
2102
|
h(() => {
|
|
2090
|
-
d2.value = false, o2.value ? r2.value = "visible" :
|
|
2103
|
+
d2.value = false, o2.value ? r2.value = "visible" : Xl(i2) || (r2.value = "hidden");
|
|
2091
2104
|
});
|
|
2092
|
-
}), S(
|
|
2105
|
+
}), S(Zl, i2), S(Jl, c2), () => {
|
|
2093
2106
|
let a3 = dt(e2, ["show", "appear", "unmount", "onBeforeEnter", "onBeforeLeave", "onAfterEnter", "onAfterLeave"]), o3 = { unmount: e2.unmount };
|
|
2094
|
-
return ot({ ourProps: { ...o3, as: "template" }, theirProps: {}, slot: {}, slots: { ...n2, default: () => [x(
|
|
2107
|
+
return ot({ ourProps: { ...o3, as: "template" }, theirProps: {}, slot: {}, slots: { ...n2, default: () => [x(ln, { onBeforeEnter: () => t2("beforeEnter"), onAfterEnter: () => t2("afterEnter"), onBeforeLeave: () => t2("beforeLeave"), onAfterLeave: () => t2("afterLeave"), ...l2, ...o3, ...a3 }, n2.default)] }, attrs: {}, features: en, visible: "visible" === r2.value, name: "Transition" });
|
|
2095
2108
|
};
|
|
2096
2109
|
} });
|
|
2097
|
-
function
|
|
2110
|
+
function an(t2, l2) {
|
|
2098
2111
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M19.5 13.5 12 21m0 0-7.5-7.5M12 21V3" })]);
|
|
2099
2112
|
}
|
|
2100
|
-
function
|
|
2113
|
+
function on(t2, l2) {
|
|
2101
2114
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M4.5 10.5 12 3m0 0 7.5 7.5M12 3v18" })]);
|
|
2102
2115
|
}
|
|
2103
|
-
function
|
|
2116
|
+
function rn(t2, l2) {
|
|
2104
2117
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M3.75 5.25h16.5m-16.5 4.5h16.5m-16.5 4.5h16.5m-16.5 4.5h16.5" })]);
|
|
2105
2118
|
}
|
|
2106
|
-
function
|
|
2119
|
+
function sn(t2, l2) {
|
|
2107
2120
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z" })]);
|
|
2108
2121
|
}
|
|
2109
|
-
function
|
|
2122
|
+
function un(t2, l2) {
|
|
2110
2123
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m4.5 12.75 6 6 9-13.5" })]);
|
|
2111
2124
|
}
|
|
2112
|
-
function
|
|
2125
|
+
function dn(t2, l2) {
|
|
2113
2126
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m19.5 8.25-7.5 7.5-7.5-7.5" })]);
|
|
2114
2127
|
}
|
|
2115
|
-
function
|
|
2128
|
+
function cn(t2, l2) {
|
|
2116
2129
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M15.75 19.5 8.25 12l7.5-7.5" })]);
|
|
2117
2130
|
}
|
|
2118
|
-
function
|
|
2131
|
+
function pn(t2, l2) {
|
|
2119
2132
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m8.25 4.5 7.5 7.5-7.5 7.5" })]);
|
|
2120
2133
|
}
|
|
2121
|
-
function
|
|
2134
|
+
function gn(t2, l2) {
|
|
2122
2135
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M8.25 15 12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9" })]);
|
|
2123
2136
|
}
|
|
2124
|
-
function
|
|
2137
|
+
function mn(t2, l2) {
|
|
2125
2138
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m4.5 15.75 7.5-7.5 7.5 7.5" })]);
|
|
2126
2139
|
}
|
|
2127
|
-
function
|
|
2140
|
+
function fn(t2, l2) {
|
|
2128
2141
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126ZM12 15.75h.007v.008H12v-.008Z" })]);
|
|
2129
2142
|
}
|
|
2130
|
-
function
|
|
2143
|
+
function vn(t2, l2) {
|
|
2131
2144
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M10.05 4.575a1.575 1.575 0 1 0-3.15 0v3m3.15-3v-1.5a1.575 1.575 0 0 1 3.15 0v1.5m-3.15 0 .075 5.925m3.075.75V4.575m0 0a1.575 1.575 0 0 1 3.15 0V15M6.9 7.575a1.575 1.575 0 1 0-3.15 0v8.175a6.75 6.75 0 0 0 6.75 6.75h2.018a5.25 5.25 0 0 0 3.712-1.538l1.732-1.732a5.25 5.25 0 0 0 1.538-3.712l.003-2.024a.668.668 0 0 1 .198-.471 1.575 1.575 0 1 0-2.228-2.228 3.818 3.818 0 0 0-1.12 2.687M6.9 7.575V12m6.27 4.318A4.49 4.49 0 0 1 16.35 15m.002 0h-.002" })]);
|
|
2132
2145
|
}
|
|
2133
|
-
function
|
|
2146
|
+
function hn(t2, l2) {
|
|
2134
2147
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m2.25 12 8.954-8.955c.44-.439 1.152-.439 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25" })]);
|
|
2135
2148
|
}
|
|
2136
|
-
function
|
|
2149
|
+
function bn(t2, l2) {
|
|
2137
2150
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z" })]);
|
|
2138
2151
|
}
|
|
2139
|
-
function
|
|
2152
|
+
function yn(t2, l2) {
|
|
2140
2153
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M9.879 7.519c1.171-1.025 3.071-1.025 4.242 0 1.172 1.025 1.172 2.687 0 3.712-.203.179-.43.326-.67.442-.745.361-1.45.999-1.45 1.827v.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9 5.25h.008v.008H12v-.008Z" })]);
|
|
2141
2154
|
}
|
|
2142
|
-
function
|
|
2155
|
+
function xn(t2, l2) {
|
|
2143
2156
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0" })]);
|
|
2144
2157
|
}
|
|
2145
|
-
function
|
|
2158
|
+
function wn(t2, l2) {
|
|
2146
2159
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "m9.75 9.75 4.5 4.5m0-4.5-4.5 4.5M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z" })]);
|
|
2147
2160
|
}
|
|
2148
|
-
function
|
|
2161
|
+
function kn(t2, l2) {
|
|
2149
2162
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M6 18 18 6M6 6l12 12" })]);
|
|
2150
2163
|
}
|
|
2151
|
-
const
|
|
2164
|
+
const Sn = { class: "py-1" }, Cn = ["onClick"], On = { key: 1, class: "animate-pulse px-4 py-2 bg-gray-200 rounded-md flex inline-flex items-center relative inline-block text-left" }, Mn = i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-28" }, null, -1), Dn = { name: "uiDropdown" }, Tn = Object.assign(Dn, { props: { items: { type: Array, required: true }, position: { type: String, default: "left" }, disabled: Boolean, label: String, loading: { type: Boolean, default: true } }, emits: ["optionSelected"], setup(l2, { emit: r2 }) {
|
|
2152
2165
|
const s2 = r2, c2 = l2, p2 = u(() => {
|
|
2153
2166
|
let e2 = c2.items.find((e3) => true === e3.active);
|
|
2154
2167
|
return e2 ? e2.name : c2.label;
|
|
2155
2168
|
});
|
|
2156
|
-
return (r3, u2) => l2.loading ? (e(), a("div",
|
|
2169
|
+
return (r3, u2) => l2.loading ? (e(), a("div", On, [Mn, o(d(dn), { "aria-hidden": "true", class: "-mr-1 ml-2 h-5 w-5 text-gray-200 dark:text-gray-300" })])) : (e(), t(d(jl), { key: 0, as: "div", class: n(["relative inline-block text-left", { "opacity-25": l2.disabled }]) }, { default: E(() => [i("div", null, [o(d(Rl), { class: "inline-flex justify-between w-full rounded-md border border-gray-300 shadow-sm px-4 py-2 bg-white text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-offset-gray-100 focus:ring-indigo-500" }, { default: E(() => [I(_(p2.value) + " ", 1), o(d(dn), { "aria-hidden": "true", class: "-mr-1 ml-2 h-5 w-5" })]), _: 1 })]), o(P, { "enter-active-class": "transition ease-out duration-100", "enter-from-class": "transform opacity-0 scale-95", "enter-to-class": "transform opacity-100 scale-100", "leave-active-class": "transition ease-in duration-75", "leave-from-class": "transform opacity-100 scale-100", "leave-to-class": "transform opacity-0 scale-95" }, { default: E(() => [l2.disabled ? R("", true) : (e(), t(d(Bl), { key: 0, class: n([{ "right-0": "right" === l2.position, "left-0": "left" === l2.position }, "origin-top-right absolute mt-2 w-56 rounded-md shadow-lg bg-white ring-1 ring-black ring-opacity-5 focus:outline-none z-10"]) }, { default: E(() => [i("div", Sn, [(e(true), a(w, null, j(l2.items, (l3, a2) => (e(), t(d(Al), { key: a2 }, { default: E(() => [i("a", { onClick: (e2) => ((e3) => {
|
|
2157
2170
|
c2.disabled || s2("optionSelected", e3.value);
|
|
2158
|
-
})(l3), class: n([l3.active ? "bg-gray-100 text-gray-900" : "text-gray-700", "block px-4 py-2 text-sm cursor-pointer"]) }, _(l3.name), 11,
|
|
2159
|
-
} }),
|
|
2171
|
+
})(l3), class: n([l3.active ? "bg-gray-100 text-gray-900" : "text-gray-700", "block px-4 py-2 text-sm cursor-pointer"]) }, _(l3.name), 11, Cn)]), _: 2 }, 1024))), 128))])]), _: 1 }, 8, ["class"]))]), _: 1 })]), _: 1 }, 8, ["class"]));
|
|
2172
|
+
} }), En = { key: 0 }, In = { class: "flex justify-between" }, _n = { key: 0, class: "block text-sm font-medium text-gray-700" }, Pn = { key: 1, class: "text-[10px] text-gray-500 uppercase justify-self-end" }, jn = ["disabled", "name", "placeholder", "type"], Rn = { key: 2, class: "absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none" }, Bn = { key: 1, class: "animate-pulse" }, An = { key: 0, class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-2/3 md:w-1/4 mb-1.5" }, Ln = i("div", { class: "animate-pulse px-4 py-3.5 bg-gray-200 rounded-md flex inline-flex items-center relative inline-block text-left w-full" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-28" })], -1), Fn = { name: "uiInput" }, Nn = Object.assign(Fn, { props: { label: String, type: { type: String, default: "text" }, name: String, placeholder: { type: String, default: "..." }, icon: { type: Function, default: () => {
|
|
2160
2173
|
} }, disabled: Boolean, color: { type: String, default: "gray" }, value: { type: String, default: "" }, error: String, optional: String, addOn: String, rightAddOn: String, loading: { type: Boolean, default: true } }, emits: ["inputChanged", "rightAddOnClicked", "addOnClicked"], setup(t2, { emit: l2 }) {
|
|
2161
2174
|
const r2 = l2, u2 = t2, c2 = s(u2.value);
|
|
2162
2175
|
return p(() => u2.value, (e2) => {
|
|
2163
2176
|
c2.value = e2, r2("inputChanged", { name: u2.name, value: c2.value });
|
|
2164
|
-
}), (l3, r3) => t2.loading ? (e(), a("div",
|
|
2165
|
-
} }),
|
|
2177
|
+
}), (l3, r3) => t2.loading ? (e(), a("div", Bn, [void 0 !== t2.label ? (e(), a("div", An)) : R("", true), Ln])) : (e(), a("div", En, [i("div", In, [t2.label ? (e(), a("label", _n, _(t2.label), 1)) : R("", true), t2.optional ? (e(), a("span", Pn, _(t2.optional), 1)) : R("", true)]), i("div", { class: n([{ "mt-1": t2.label }, "relative flex"]) }, [t2.addOn ? (e(), a("span", { key: 0, onClick: r3[0] || (r3[0] = (e2) => l3.$emit("addOnClicked")), class: "inline-flex items-center px-3 rounded-l-md border border-r-0 border-gray-300 bg-gray-50 text-gray-500 sm:text-sm cursor-pointer" }, _(t2.addOn), 1)) : R("", true), B(i("input", { "onUpdate:modelValue": r3[1] || (r3[1] = (e2) => c2.value = e2), class: n([{ "border-gray-300": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "border-red-400": "danger" === t2.color, "border-yellow-400": "warning" === t2.color, "border-green-400": "success" === t2.color, "bg-gray-100": t2.disabled, "text-black": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "text-red-400": "danger" === t2.color, "text-yellow-400": "warning" === t2.color, "text-green-400": "success" === t2.color, "rounded-md": !t2.addOn || !t2.rightAddOn, "rounded-r-md": t2.addOn, "rounded-l-none": t2.addOn, "rounded-l-md": t2.rightAddOn, "rounded-r-none": t2.rightAddOn }, "shadow-sm focus:ring-indigo-500 focus:border-indigo-500 block w-full sm:text-sm border-gray-300 placeholder-gray-300"]), disabled: t2.disabled, name: t2.name, placeholder: t2.placeholder, type: t2.type, onInput: r3[2] || (r3[2] = (e2) => l3.$emit("inputChanged", { value: e2.target.value, name: e2.target.name })) }, null, 42, jn), [[A, c2.value]]), t2.rightAddOn ? (e(), a("span", { key: 1, onClick: r3[3] || (r3[3] = (e2) => l3.$emit("rightAddOnClicked")), class: "inline-flex items-center px-3 rounded-r-md border border-l-0 border-gray-300 bg-gray-50 hover:bg-gray-200 text-gray-500 sm:text-sm cursor-pointer" }, _(t2.rightAddOn), 1)) : R("", true), t2.icon ? (e(), a("div", Rn, [o(J, { icon: t2.icon, color: t2.color, loading: t2.loading }, null, 8, ["icon", "color", "loading"]), B(o(J, { icon: d(un), color: "green", loading: t2.loading }, null, 8, ["icon", "loading"]), [[L, "success" === t2.color]]), B(o(J, { icon: d(fn), color: "yellow", loading: t2.loading }, null, 8, ["icon", "loading"]), [[L, "warning" === t2.color]]), B(o(J, { icon: d(kn), color: "red", loading: t2.loading }, null, 8, ["icon", "loading"]), [[L, "danger" === t2.color]])])) : R("", true)], 2), B(i("p", { class: n([{ "text-gray-400": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "text-red-400": "danger" === t2.color, "text-yellow-400": "warning" === t2.color, "text-green-400": "success" === t2.color }, "mt-2 text-xs flex flex-row items-center"]) }, _(t2.error), 3), [[L, t2.error]])]));
|
|
2178
|
+
} }), zn = { key: 0 }, $n = { class: "flex justify-between" }, Vn = { key: 0, class: "block text-sm font-medium text-gray-700" }, Hn = { key: 1, class: "text-[10px] text-gray-500 uppercase" }, Yn = { class: "space-y-1 flex flex-col items-center justify-center" }, Un = { class: "flex text-sm text-gray-600 flex flex-col sm:flex-row text-center" }, qn = { for: "file-upload", class: "relative cursor-pointer rounded-md font-medium text-indigo-600 focus-within:outline-none focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2 hover:text-indigo-500" }, Wn = ["accept"], Kn = { class: "pl-1" }, Jn = { class: "text-xs text-gray-500 pb-4" }, Gn = { class: "mt-2 text-xs flex flex-row items-center text-red-300" }, Zn = { key: 1, class: "animate-pulse" }, Xn = [i("div", { class: "flex justify-center items-center flex-col rounded-md border-2 border-dashed px-6 pt-5 pb-6 border-gray-200" }, [i("div", { class: "rounded-full h-20 w-20 bg-gray-200 mb-4" }), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full md:w-1/3 mb-3" }), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full md:w-1/4 mb-3" })], -1)], Qn = { name: "uiInputFile" }, ea = Object.assign(Qn, { props: { name: String, label: String, optional: String, placeholder: String, dragAndDrop: String, fileTypesAndSizes: String, error: String, accept: String, icon: { type: Function, default: function(t2, l2) {
|
|
2166
2179
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M7.5 7.5h-.75A2.25 2.25 0 0 0 4.5 9.75v7.5a2.25 2.25 0 0 0 2.25 2.25h7.5a2.25 2.25 0 0 0 2.25-2.25v-7.5a2.25 2.25 0 0 0-2.25-2.25h-.75m0-3-3-3m0 0-3 3m3-3v11.25m6-2.25h.75a2.25 2.25 0 0 1 2.25 2.25v7.5a2.25 2.25 0 0 1-2.25 2.25h-7.5a2.25 2.25 0 0 1-2.25-2.25v-.75" })]);
|
|
2167
2180
|
} }, loading: { type: Boolean, default: true } }, emits: ["filesUploaded"], setup(t2, { emit: l2 }) {
|
|
2168
2181
|
const r2 = s(""), u2 = l2, c2 = t2, p2 = (e2) => {
|
|
@@ -2171,42 +2184,42 @@ const wn = { class: "py-1" }, kn = ["onClick"], Sn = { key: 1, class: "animate-p
|
|
|
2171
2184
|
}, g2 = (e2) => {
|
|
2172
2185
|
u2("filesUploaded", e2.target.files), c2.filename = e2.target.files[0].name;
|
|
2173
2186
|
};
|
|
2174
|
-
return (l3, s2) => t2.loading ? (e(), a("div",
|
|
2175
|
-
}, ["prevent"])), onDrop: F(p2, ["prevent"]) }, [i("div",
|
|
2176
|
-
} }),
|
|
2187
|
+
return (l3, s2) => t2.loading ? (e(), a("div", Zn, Xn)) : (e(), a("div", zn, [i("div", $n, [t2.label ? (e(), a("label", Vn, _(t2.label), 1)) : R("", true), t2.optional ? (e(), a("span", Hn, _(t2.optional), 1)) : R("", true)]), i("div", { class: n([[{ "mt-1": t2.label }, { "border-gray-300 hover:border-gray-400": !t2.error }, { "border-red-300 hover:border-red-400": t2.error }], "dropArea flex justify-center rounded-md border-2 border-dashed px-6 pt-5 pb-6"]), onDragover: s2[0] || (s2[0] = F(() => {
|
|
2188
|
+
}, ["prevent"])), onDrop: F(p2, ["prevent"]) }, [i("div", Yn, [o(J, { icon: t2.icon, size: "massive", color: "gray", "aria-hidden": "true", class: "mb-4", loading: t2.loading }, null, 8, ["icon", "loading"]), i("div", Un, [i("label", qn, [i("span", null, _(t2.placeholder), 1), i("input", { id: "file-upload", name: "file-upload", type: "file", class: "sr-only", accept: t2.accept, onChange: g2 }, null, 40, Wn)]), i("p", Kn, _(t2.dragAndDrop), 1)]), i("p", Jn, _(t2.fileTypesAndSizes), 1), B(i("p", { class: "font-bold text-xs uppercase block p-2 bg-gray-200 rounded" }, _(r2.value), 513), [[L, "" !== r2.value]])])], 34), B(i("p", Gn, [o(J, { icon: d(wn), color: "red", class: "mr-2", loading: t2.loading }, null, 8, ["icon", "loading"]), I(_(t2.error), 1)], 512), [[L, t2.error]])]));
|
|
2189
|
+
} }), ta = { class: "relative mt-1" }, la = { key: 1, class: "animate-pulse px-4 py-2.5 bg-gray-200 rounded-md flex justify-between items-center w-full" }, na = i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2" }, null, -1), aa = { name: "uiSelect" }, oa = Object.assign(aa, { props: { items: { type: Array, required: true }, label: String, error: String, color: String, select: Object, loading: { type: Boolean, default: true }, disabled: { type: Boolean, default: false } }, emits: ["selectChanged"], setup(l2, { emit: r2 }) {
|
|
2177
2190
|
const c2 = s(""), p2 = r2, g2 = l2, m2 = u(() => "" === c2.value ? g2.items : g2.items.filter((e2) => e2.name.toLowerCase().includes(c2.value.toLowerCase()))), f2 = u(() => g2.select);
|
|
2178
|
-
return (r3, s2) => l2.loading ? (e(), a("div",
|
|
2179
|
-
} }),
|
|
2191
|
+
return (r3, s2) => l2.loading ? (e(), a("div", la, [na, o(d(gn), { "aria-hidden": "true", class: "-mr-1 ml-2 h-5 w-5 text-gray-300 dark:text-gray-400" })])) : (e(), t(d(jt), { key: 0, modelValue: f2.value, "onUpdate:modelValue": [s2[1] || (s2[1] = (e2) => f2.value = e2), s2[2] || (s2[2] = (e2) => p2("selectChanged", e2))], disabled: l2.disabled, as: "div" }, { default: E(() => [o(d(Rt), { class: "block text-sm font-medium" }, { default: E(() => [I(_(l2.label), 1)]), _: 1 }), i("div", ta, [o(d(At), { "display-value": (e2) => e2 == null ? void 0 : e2.name, class: n([{ "border-gray-300": "danger" !== l2.color || "warning" !== l2.color || "success" !== l2.color, "border-red-400": "danger" === l2.color, "border-yellow-400": "warning" === l2.color, "border-green-400": "success" === l2.color, "bg-gray-100": l2.disabled, "bg-white": !l2.disabled, "text-black": "danger" !== l2.color || "warning" !== l2.color || "success" !== l2.color, "text-gray-300": l2.disabled, "text-red-400": "danger" === l2.color, "text-yellow-400": "warning" === l2.color, "text-green-400": "success" === l2.color }, "w-full rounded-md border py-2 pl-3 pr-10 shadow-sm focus:border-indigo-500 focus:outline-none focus:ring-1 focus:ring-indigo-500 sm:text-sm"]), onChange: s2[0] || (s2[0] = (e2) => c2.value = e2.target.value) }, null, 8, ["display-value", "class"]), o(d(Bt), { class: "absolute inset-y-0 right-0 flex items-center rounded-r-md px-2 focus:outline-none" }, { default: E(() => [o(d(gn), { "aria-hidden": "true", class: "h-5 w-5 text-gray-400" })]), _: 1 }), m2.value.length > 0 ? (e(), t(d(Lt), { key: 0, class: "absolute z-10 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm" }, { default: E(() => [(e(true), a(w, null, j(m2.value, (l3) => (e(), t(d(Ft), { key: l3.id, value: l3, as: "template" }, { default: E(({ active: t2, selected: r4 }) => [i("li", { class: n(["relative cursor-default select-none py-2 pl-3 pr-9", t2 ? "bg-indigo-600 text-white" : "text-gray-900"]) }, [i("span", { class: n(["block truncate", r4 && "font-semibold"]) }, _(l3.name), 3), r4 ? (e(), a("span", { key: 0, class: n(["absolute inset-y-0 right-0 flex items-center pr-4", t2 ? "text-white" : "text-indigo-600"]) }, [o(d(un), { "aria-hidden": "true", class: "h-5 w-5", loading: true })], 2)) : R("", true)], 2)]), _: 2 }, 1032, ["value"]))), 128))]), _: 1 })) : R("", true)]), B(i("p", { class: n([{ "text-gray-400": "danger" !== l2.color || "warning" !== l2.color || "success" !== l2.color, "text-red-400": "danger" === l2.color, "text-yellow-400": "warning" === l2.color, "text-green-400": "success" === l2.color }, "mt-2 text-xs flex flex-row items-center"]) }, _(l2.error), 3), [[L, l2.error]])]), _: 1 }, 8, ["modelValue", "disabled"]));
|
|
2192
|
+
} }), ra = { key: 1, class: "inline-flex items-center px-3 py-2.5 rounded text-xs font-medium leading-none animate-pulse bg-gray-200" }, ia = [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-12" }, null, -1)], sa = { name: "uiTag" }, ua = Object.assign(sa, { props: { color: { type: String, default: "primary" }, loading: { type: Boolean, default: true } }, setup: (t2) => (l2, o2) => t2.loading ? (e(), a("div", ra, ia)) : (e(), a("span", { key: 0, class: n([{ "bg-indigo-100 text-indigo-800 border border-indigo-200": "primary" === t2.color, "bg-red-100 text-red-800 border border-red-200": "danger" === t2.color, "bg-yellow-100 text-yellow-800 border border-yellow-200": "warning" === t2.color, "bg-green-100 text-green-800 border border-green-200": "success" === t2.color, "bg-black text-white border border-black": "black" === t2.color, "text-black border border-gray-200 bg-white": "white" === t2.color }, "inline-flex items-center px-3 py-2 rounded text-xs font-medium leading-none"]) }, [r(l2.$slots, "default")], 2)) }), da = { key: 0 }, ca = { key: 0, class: "block text-sm font-medium text-gray-700" }, pa = ["disabled", "placeholder"], ga = { key: 1, class: "animate-pulse" }, ma = [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-2/3 md:w-1/4 mb-1.5" }, null, -1), i("div", { class: "h-24 bg-gray-200 rounded-lg flex inline-flex items-center relative inline-block text-left w-full" }, null, -1)], fa = { name: "uiTextArea" }, va = Object.assign(fa, { props: { label: String, placeholder: { type: String, default: "..." }, value: String, color: String, disabled: { type: Boolean, default: false }, error: String, loading: { type: Boolean, default: true } }, emits: ["inputChanged"], setup(t2, { emit: l2 }) {
|
|
2180
2193
|
const r2 = l2, u2 = t2, c2 = (e2) => {
|
|
2181
2194
|
r2("inputChanged", e2.target.value);
|
|
2182
2195
|
}, g2 = s(u2.value);
|
|
2183
2196
|
return p(() => u2.value, (e2) => {
|
|
2184
2197
|
g2.value = e2, r2("inputChanged", e2);
|
|
2185
|
-
}), (l3, r3) => t2.loading ? (e(), a("div",
|
|
2186
|
-
} }),
|
|
2198
|
+
}), (l3, r3) => t2.loading ? (e(), a("div", ga, ma)) : (e(), a("div", da, [t2.label ? (e(), a("label", ca, _(t2.label), 1)) : R("", true), i("div", { class: n({ "mt-1": t2.label }) }, [B(i("textarea", { disabled: t2.disabled, rows: "4", "onUpdate:modelValue": r3[0] || (r3[0] = (e2) => g2.value = e2), placeholder: t2.placeholder, class: n(["shadow-sm focus:ring-indigo-500 focus:border-indigo-500 block w-full sm:text-sm rounded-md", { "border-gray-300": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "border-red-300": "danger" === t2.color, "border-yellow-400": "warning" === t2.color, "border-green-400": "success" === t2.color, "bg-gray-100": t2.disabled, "text-black": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "text-red-300": "danger" === t2.color, "text-yellow-400": "warning" === t2.color, "text-green-400": "success" === t2.color }]), onChange: c2 }, null, 42, pa), [[N, g2.value]])], 2), B(i("p", { class: n([{ "text-gray-300": "danger" !== t2.color || "warning" !== t2.color || "success" !== t2.color, "text-red-300": "danger" === t2.color, "text-yellow-400": "warning" === t2.color, "text-green-400": "success" === t2.color }, "mt-2 text-xs flex flex-row items-center"]) }, [o(J, { icon: d(wn), color: "red", class: "mr-2" }, null, 8, ["icon"]), I(_(t2.error), 1)], 2), [[L, t2.error]])]));
|
|
2199
|
+
} }), ha = { class: "text-sm font-medium text-gray-900" }, ba = { key: 0, class: "text-sm text-gray-500 ml-2" }, ya = { key: 1, class: "animate-pulse flex items-center" }, xa = [i("div", { class: "relative bg-gray-200 rounded-full w-12 h-6 p-1 flex items-center" }, [i("div", { class: "rounded-full bg-gray-300 dark:bg-gray-400 h-4 w-4" })], -1), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-16 ml-2" }, null, -1)], wa = { name: "uiToggle" }, ka = Object.assign(wa, { props: { item: { type: Object, required: true }, checked: { type: Boolean, default: false }, disabled: { type: Boolean, default: false }, loading: { type: Boolean, default: true } }, setup(l2) {
|
|
2187
2200
|
const r2 = s(l2.checked);
|
|
2188
|
-
return (s2, u2) => l2.loading ? (e(), a("div",
|
|
2189
|
-
} }),
|
|
2201
|
+
return (s2, u2) => l2.loading ? (e(), a("div", ya, xa)) : (e(), t(d($l), { key: 0, as: "div", class: "flex items-center relative" }, { default: E(() => [o(d(Vl), { disabled: l2.disabled, onClick: u2[0] || (u2[0] = (e2) => s2.$emit("toggleChanged", { item: l2.item, active: !r2.value })), modelValue: r2.value, "onUpdate:modelValue": u2[1] || (u2[1] = (e2) => r2.value = e2), class: n([r2.value ? "bg-indigo-600" : "bg-gray-200", "relative inline-flex h-6 w-11 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2"]) }, { default: E(() => [i("span", { "aria-hidden": "true", class: n([r2.value ? "translate-x-5" : "translate-x-0", l2.disabled ? "bg-gray-300" : "", "pointer-events-none inline-block h-5 w-5 transform rounded-full bg-white shadow ring-0 transition duration-200 ease-in-out"]) }, null, 2)]), _: 1 }, 8, ["disabled", "modelValue", "class"]), o(d(Hl), { as: "span", class: "ml-3" }, { default: E(() => [i("span", ha, _(l2.item.title), 1), l2.item.subtitle ? (e(), a("span", ba, _(l2.item.subtitle), 1)) : R("", true)]), _: 1 }), l2.item.action ? (e(), a("span", { key: 0, class: "cursor-pointer text-indigo-600 hover:text-indigo-400 uppercase text-xs absolute right-0 bottom-0.5", onClick: u2[2] || (u2[2] = (e2) => s2.$emit("actionClicked", l2.item)) }, _(l2.item.action), 1)) : R("", true)]), _: 1 }));
|
|
2202
|
+
} }), Sa = { key: 0, class: "flex flex-col" }, Ca = { class: "flex" }, Oa = { class: "flex-shrink-0" }, Ma = { class: "ml-3" }, Da = { class: "mt-4" }, Ta = { class: "-mx-2 -my-1.5 flex" }, Ea = ["onClick"], Ia = { key: 1, class: "flex flex-col animate-pulse" }, _a = [z('<div class="p-4 border-l-4 bg-gray-100 border-gray-400 rounded"><div class="flex"><div class="flex-shrink-0"><div class="h-6 w-6 animate-pulse rounded-full bg-gray-200 dark:bg-gray-300"></div></div><div class="ml-3 w-full"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-2/3 mb-2"></div><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full mb-2"></div><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-3/5"></div></div></div></div>', 1)], Pa = { name: "uiAlert" }, ja = Object.assign(Pa, { props: { actions: { type: Array }, title: { type: String }, type: { type: String, default: "info" }, loading: { type: Boolean, default: true } }, setup: (l2) => (o2, s2) => l2.loading ? (e(), a("div", Ia, _a)) : (e(), a("div", Sa, [i("div", { class: n([{ "bg-indigo-50 border-indigo-400": "info" === l2.type, "bg-red-50 border-red-400": "danger" === l2.type, "bg-yellow-50 border-yellow-400": "warning" === l2.type, "bg-green-50 border-green-400": "success" === l2.type }, "p-4 border-l-4 rounded"]) }, [i("div", Ca, [i("div", Oa, ["info" === l2.type ? (e(), t(d(bn), { key: 0, class: "h-8 w-8 text-indigo-400", "aria-hidden": "true" })) : R("", true), "danger" === l2.type ? (e(), t(d(wn), { key: 1, class: "h-8 w-8 text-red-400", "aria-hidden": "true" })) : R("", true), "warning" === l2.type ? (e(), t(d(fn), { key: 2, class: "h-8 w-8 text-yellow-400", "aria-hidden": "true" })) : R("", true), "success" === l2.type ? (e(), t(d(sn), { key: 3, class: "h-8 w-8 text-green-400", "aria-hidden": "true" })) : R("", true)]), i("div", Ma, [i("h3", { class: n([{ "text-red-800": "danger" === l2.type, "text-yellow-800": "warning" === l2.type, "text-green-800": "success" === l2.type }, "text-sm font-medium"]) }, _(l2.title), 3), i("div", { class: n([{ "text-red-700": "danger" === l2.type, "text-yellow-700": "warning" === l2.type, "text-green-700": "success" === l2.type }, "mt-2 text-sm"]) }, [r(o2.$slots, "default")], 2), i("div", Da, [i("div", Ta, [(e(true), a(w, null, j(l2.actions, (t2, r2) => (e(), a("button", { onClick: (e2) => o2.$emit("alertEvent", t2.event), type: "button", key: r2, class: n([{ "bg-green-50 text-green-800 hover:bg-green-100 focus:ring-green-600 focus:ring-offset-green-50": "success" === l2.type, "bg-indigo-50 text-indigo-800 hover:bg-indigo-100 focus:ring-indigo-600 focus:ring-offset-indigo-50": "info" === l2.type, "bg-red-50 text-red-800 hover:bg-red-100 focus:ring-red-600 focus:ring-offset-red-50": "danger" === l2.type, "bg-yellow-50 text-yellow-800 hover:bg-yellow-100 focus:ring-yellow-600 focus:ring-offset-yellow-50": "warning" === l2.type }, "px-2 py-1.5 text-sm font-medium rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2"]) }, _(t2.name), 11, Ea))), 128))])])])])], 2)])) }), Ra = { key: 0, class: "inline-flex", "aria-label": "Breadcrumb" }, Ba = { role: "list", class: "flex items-center space-x-4 text-xs" }, Aa = { key: 0 }, La = ["onClick"], Fa = { key: 1, class: "flex items-center" }, Na = ["onClick", "aria-current"], za = { key: 1, class: "flex flex-row items-center animate-pulse" }, $a = [i("div", { class: "animate-pulse rounded-full bg-gray-200 dark:bg-gray-300 h-4 w-4 mr-4" }, null, -1), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/5 mr-4" }, null, -1), i("div", { class: "animate-pulse rounded-full bg-gray-200 dark:bg-gray-300 h-4 w-4 mr-4" }, null, -1), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/5" }, null, -1)], Va = { name: "uiBreadcrumbs" }, Ha = Object.assign(Va, { props: { pages: { type: Array, required: true }, loading: { type: Boolean, default: true } }, setup: (t2) => (l2, r2) => t2.loading ? (e(), a("div", za, $a)) : (e(), a("nav", Ra, [i("ol", Ba, [(e(true), a(w, null, j(t2.pages, (t3, r3) => (e(), a("li", { key: r3 }, [0 === r3 ? (e(), a("div", Aa, [i("p", { onClick: (e2) => l2.$emit("breadCrumbClicked", t3.routeName), class: "flex flex-row items-center justify-center text-indigo-600 hover:text-indigo-800 cursor-pointer" }, [o(d(hn), { class: "flex-shrink-0 h-3 w-3 text-gray-400 mr-4", "aria-hidden": "true" }), i("span", null, _(t3.name), 1)], 8, La)])) : (e(), a("div", Fa, [o(d(pn), { class: "flex-shrink-0 h-3 w-3 text-gray-400", "aria-hidden": "true" }), i("span", { onClick: (e2) => l2.$emit("breadCrumbClicked", t3.routeName), class: n(["cursor-pointer ml-4 text-xs text-gray-400 hover:text-gray-500", { "text-indigo-600 hover:text-indigo-800": !t3.current }]), "aria-current": t3.current ? "page" : "" }, _(t3.name), 11, Na)]))]))), 128))])])) }), Ya = { class: "flex items-center flex-col sm:flex-row justify-center sm:justify-start" }, Ua = ["src"], qa = { class: "font-bold text-center sm:text-left" }, Wa = { class: "mt-1 text-xs text-center sm:text-left" }, Ka = { key: 0, class: "flex flex-wrap mt-4 justify-center sm:justify-start" }, Ja = { key: 1, class: "rounded-lg bg-white shadow p-6 cursor-pointer animate-pulse" }, Ga = [z('<div class="flex items-center flex-col sm:flex-row justify-center sm:justify-start w-full"><div class="w-16 h-16 rounded-full bg-gray-200 flex self-center"></div><div class="w-full ml-4"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full mt-4 sm:mt-0 sm:w-16 mb-2"></div><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full sm:w-32"></div></div></div>', 1)], Za = { name: "uiCard" }, Xa = Object.assign(Za, { props: { id: { type: String, required: true }, name: { type: String, required: true }, type: String, tags: Array, logo: String, loading: { type: Boolean, default: true } }, setup: (l2) => (n2, o2) => {
|
|
2190
2203
|
var _a2;
|
|
2191
|
-
return l2.loading ? (e(), a("div",
|
|
2192
|
-
} }),
|
|
2204
|
+
return l2.loading ? (e(), a("div", Ja, Ga)) : (e(), a("div", { key: 0, class: "rounded-lg bg-white shadow p-6 cursor-pointer", onClick: o2[0] || (o2[0] = (e2) => n2.$emit("cardSelected", { id: l2.id, name: l2.name, type: l2.type, tags: l2.tags })) }, [i("div", Ya, [i("img", { class: "w-16 h-16 rounded-full mb-4 sm:mb-0 sm:mr-4", src: l2.logo }, null, 8, Ua), i("div", null, [i("h4", qa, _(l2.name), 1), i("p", Wa, _(l2.type), 1)])]), ((_a2 = l2.tags) == null ? void 0 : _a2.length) > 0 ? (e(), a("div", Ka, [(e(true), a(w, null, j(l2.tags, (n3) => (e(), t(ua, { class: "mb-1 mr-1", key: n3.name, color: n3.color, loading: l2.loading }, { default: E(() => [I(_(n3.name), 1)]), _: 2 }, 1032, ["color", "loading"]))), 128))])) : R("", true)]));
|
|
2205
|
+
} }), Qa = { name: "uiFilter" }, eo = Object.assign(Qa, { props: { position: { type: String, default: "left" }, items: { type: Array, required: true }, label: { type: String, required: true }, loading: { type: Boolean, default: true } }, emits: ["filterSelected"], setup(l2, { emit: n2 }) {
|
|
2193
2206
|
const a2 = n2, o2 = s(l2.items);
|
|
2194
|
-
return (n3, r2) => (e(), t(
|
|
2207
|
+
return (n3, r2) => (e(), t(Tn, { loading: l2.loading, onOptionSelected: r2[0] || (r2[0] = (e2) => ((e3) => {
|
|
2195
2208
|
o2.value.forEach((t2) => {
|
|
2196
2209
|
t2.value !== e3 ? t2.active = false : t2.active = true;
|
|
2197
2210
|
}), a2("filterSelected", e3);
|
|
2198
2211
|
})(e2)), position: l2.position, items: o2.value, label: l2.label }, null, 8, ["loading", "position", "items", "label"]));
|
|
2199
|
-
} }),
|
|
2212
|
+
} }), to = i("div", { class: "fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" }, null, -1), lo = { class: "fixed inset-0 z-10 overflow-y-auto" }, no = { class: "flex min-h-full items-end justify-center p-4 text-center sm:items-center sm:p-0" }, ao = { class: "absolute top-0 right-0 hidden pt-4 pr-4 sm:block" }, oo = i("span", { class: "sr-only" }, "X", -1), ro = { class: "sm:flex sm:items-start" }, io = { class: "mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left sm:mr-4 sm:w-10/12 break-words" }, so = { class: "mt-4 text-gray-500 text-sm" }, uo = { key: 0, class: "mt-8" }, co = ["onClick"], po = { name: "uiModal" }, go = Object.assign(po, { props: { title: String, actions: Object, modalName: String, open: { type: Boolean, default: false }, type: { type: String, default: "default" }, loading: { type: Boolean, default: false } }, emits: ["modalAction"], setup(l2, { emit: s2 }) {
|
|
2200
2213
|
const u2 = l2, c2 = s2, p2 = (e2) => {
|
|
2201
2214
|
c2("modalAction", { modal: u2.modalName, action: e2 });
|
|
2202
2215
|
};
|
|
2203
|
-
return (s3, u3) => (e(), t(d(
|
|
2204
|
-
} }),
|
|
2216
|
+
return (s3, u3) => (e(), t(d(nn), { as: "template", show: l2.open }, { default: E(() => [o(d(vl), { as: "div", class: "relative z-10", onClose: u3[1] || (u3[1] = (e2) => p2("close")) }, { default: E(() => [o(d(tn), { as: "template", enter: "ease-out duration-300", "enter-from": "opacity-0", "enter-to": "opacity-100", leave: "ease-in duration-200", "leave-from": "opacity-100", "leave-to": "opacity-0" }, { default: E(() => [to]), _: 1 }), i("div", lo, [i("div", no, [o(d(tn), { as: "template", enter: "ease-out duration-300", "enter-from": "opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95", "enter-to": "opacity-100 translate-y-0 sm:scale-100", leave: "ease-in duration-200", "leave-from": "opacity-100 translate-y-0 sm:scale-100", "leave-to": "opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95" }, { default: E(() => [o(d(hl), { class: "relative transform rounded-lg bg-white px-4 pb-4 pt-5 text-left shadow-xl transition-all sm:my-8 w-9/12 sm:w-full sm:max-w-lg sm:p-6" }, { default: E(() => [i("div", ao, [i("button", { type: "button", class: "rounded-md bg-white text-gray-400 hover:text-gray-500 focus:outline-none", onClick: u3[0] || (u3[0] = (e2) => p2("close")) }, [oo, o(J, { icon: d(kn), "aria-hidden": "true", loading: l2.loading }, null, 8, ["icon", "loading"])])]), i("div", ro, [i("div", { class: n(["mx-auto flex h-12 w-12 flex-shrink-0 items-center justify-center rounded-full sm:mx-0 sm:h-10 sm:w-10", { "bg-red-100": "danger" === l2.type, "bg-green-100": "success" === l2.type, "bg-indigo-100": "default" === l2.type, "bg-yellow-100": "warning" === l2.type }]) }, [B(o(d(kn), { class: "h-6 w-6 text-red-600", "aria-hidden": "true" }, null, 512), [[L, "danger" === l2.type]]), B(o(d(un), { class: "h-6 w-6 text-green-600", "aria-hidden": "true" }, null, 512), [[L, "success" === l2.type]]), B(o(d(fn), { class: "h-6 w-6 text-yellow-600", "aria-hidden": "true" }, null, 512), [[L, "warning" === l2.type]]), B(o(d(vn), { class: "h-6 w-6 text-indigo-600", "aria-hidden": "true" }, null, 512), [[L, "default" === l2.type]])], 2), i("div", io, [o(d(bl), { as: "h3", class: "text-lg font-medium leading-6 text-gray-900" }, { default: E(() => [I(_(l2.title), 1)]), _: 1 }), i("div", so, [r(s3.$slots, "default")]), l2.actions ? (e(), a("div", uo, [(e(true), a(w, null, j(l2.actions, (t2, l3) => (e(), a("button", { key: l3, type: "button", class: "inline-flex w-full justify-center rounded-md border border-transparent bg-indigo-600 px-4 py-2 text-base font-medium text-white shadow-sm hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2 mb-2 sm:mb-0 mr-2 sm:w-auto sm:text-sm", onClick: (e2) => p2(t2.value) }, _(t2.name), 9, co))), 128))])) : R("", true)])])]), _: 3 })]), _: 3 })])])]), _: 3 })]), _: 3 }, 8, ["show"]));
|
|
2217
|
+
} }), mo = { class: "w-full flex flex-col items-center space-y-4 sm:items-end" }, fo = { key: 0, class: "max-w-sm w-full bg-white shadow-lg rounded-lg pointer-events-auto ring-1 ring-black ring-opacity-5 overflow-hidden" }, vo = { class: "p-4" }, ho = { class: "flex items-start" }, bo = { class: "flex-shrink-0 mt-0.5" }, yo = { class: "ml-3 w-0 flex-1 pt-0.5" }, xo = { class: "font-medium text-gray-900" }, wo = { class: "mt-1 text-sm text-gray-500" }, ko = { class: "ml-4 flex-shrink-0 flex" }, So = i("span", { class: "sr-only" }, "Close", -1), Co = { name: "uiNotification" }, Oo = Object.assign(Co, { props: { show: Boolean, type: { type: String, default: "info" }, title: String, message: String, fixed: { type: Boolean, default: true } }, setup(t2) {
|
|
2205
2218
|
const l2 = t2, r2 = u(() => l2.show);
|
|
2206
|
-
return (l3, s2) => (e(), a("div", { "aria-live": "assertive", class: n([{ fixed: t2.fixed }, "inset-0 flex items-end px-4 py-6 pointer-events-none sm:p-6 sm:items-start"]) }, [i("div",
|
|
2207
|
-
} }),
|
|
2219
|
+
return (l3, s2) => (e(), a("div", { "aria-live": "assertive", class: n([{ fixed: t2.fixed }, "inset-0 flex items-end px-4 py-6 pointer-events-none sm:p-6 sm:items-start"]) }, [i("div", mo, [o(P, { "enter-active-class": "transform ease-out duration-300 transition", "enter-from-class": "translate-y-2 opacity-0 sm:translate-y-0 sm:translate-x-2", "enter-to-class": "translate-y-0 opacity-100 sm:translate-x-0", "leave-active-class": "transition ease-in duration-100", "leave-from-class": "opacity-100", "leave-to-class": "opacity-0" }, { default: E(() => [r2.value ? (e(), a("div", fo, [i("div", vo, [i("div", ho, [i("div", bo, [B(o(d(sn), { "aria-hidden": "true", class: "h-6 w-6 text-green-400" }, null, 512), [[L, "success" === t2.type]]), B(o(d(wn), { "aria-hidden": "true", class: "h-6 w-6 text-red-400" }, null, 512), [[L, "danger" === t2.type]]), B(o(d(fn), { "aria-hidden": "true", class: "h-6 w-6 text-yellow-400" }, null, 512), [[L, "warning" === t2.type]]), B(o(d(bn), { "aria-hidden": "true", class: "h-6 w-6 text-indigo-600" }, null, 512), [[L, "info" === t2.type]])]), i("div", yo, [i("p", xo, _(t2.title), 1), i("p", wo, _(t2.message), 1)]), i("div", ko, [i("button", { class: "bg-white rounded-md inline-flex text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500", type: "button", onClick: s2[0] || (s2[0] = (e2) => l3.$emit("closeNotification")) }, [So, o(d(kn), { "aria-hidden": "true", class: "h-5 w-5" })])])])])])) : R("", true)]), _: 1 })])], 2));
|
|
2220
|
+
} }), Mo = { key: 0, role: "list", class: "divide-y divide-gray-100" }, Do = { class: "min-w-0" }, To = { class: "flex items-start gap-x-3" }, Eo = { class: "text-sm font-semibold leading-6 text-gray-900" }, Io = { class: "mt-1 flex items-center gap-x-2 text-xs leading-5 text-gray-500" }, _o = { class: "truncate" }, Po = { class: "flex flex-none items-center gap-x-4" }, jo = ["href"], Ro = { class: "sr-only" }, Bo = { key: 1, class: "divide-y divide-gray-100 animate-pulse" }, Ao = [z('<div class="min-w-0 w-full"><div class="flex items-start gap-x-3"><p class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2"></p></div></div><div class="flex flex-none items-center gap-x-4"><div class="hidden rounded-md bg-gray-200 px-2.5 py-1.5 text-sm font-semibold text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 hover:bg-gray-50 sm:block"><p class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-10"></p></div></div>', 2)], Lo = { name: "uiTaskList" }, Fo = Object.assign(Lo, { props: { tasks: { type: Array, required: true }, loading: { type: Boolean, default: true } }, setup: (t2) => (l2, o2) => t2.loading ? (e(), a("ul", Bo, [(e(true), a(w, null, j(t2.tasks, (t3) => (e(), a("li", { key: t3.id, class: "flex items-center justify-between gap-x-6 py-5" }, Ao))), 128))])) : (e(), a("ul", Mo, [(e(true), a(w, null, j(t2.tasks, (t3) => (e(), a("li", { key: t3.id, class: "flex items-center justify-between gap-x-6 py-5" }, [i("div", Do, [i("div", To, [i("p", Eo, _(t3.name), 1), i("p", { class: n([{ "text-green-700 bg-green-50 ring-green-600/20": "Complete" === t3.status, "text-gray-600 bg-gray-50 ring-gray-500/10": "In progress" === t3.status, "text-yellow-800 bg-yellow-50 ring-yellow-600/20": "Incomplete" === t3.status }, "rounded-md whitespace-nowrap mt-0.5 px-1.5 py-0.5 text-xs font-medium ring-1 ring-inset"]) }, _(t3.statusLiteral), 3)]), i("div", Io, [i("p", _o, _(t3.description), 1)])]), i("div", Po, [i("a", { href: t3.href, class: "hidden rounded-md bg-white px-2.5 py-1.5 text-sm font-semibold text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 hover:bg-gray-50 sm:block" }, [I(_(t3.action), 1), i("span", Ro, ", " + _(t3.name), 1)], 8, jo)])]))), 128))])) });
|
|
2208
2221
|
"undefined" != typeof globalThis ? globalThis : "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof self && self;
|
|
2209
|
-
function
|
|
2222
|
+
function No(e2) {
|
|
2210
2223
|
return e2 && e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
|
|
2211
2224
|
}
|
|
2212
2225
|
!function(e2) {
|
|
@@ -2242,42 +2255,42 @@ function Lo(e2) {
|
|
|
2242
2255
|
} };
|
|
2243
2256
|
l2.default.locale(n2, null, true);
|
|
2244
2257
|
}(Y);
|
|
2245
|
-
const
|
|
2258
|
+
const zo = (e2, t2) => {
|
|
2246
2259
|
const l2 = e2.__vccOpts || e2;
|
|
2247
2260
|
for (const [e3, n2] of t2)
|
|
2248
2261
|
l2[e3] = n2;
|
|
2249
2262
|
return l2;
|
|
2250
|
-
},
|
|
2251
|
-
const
|
|
2263
|
+
}, $o = { class: "dateSelector flex items-center text-white flex-row" }, Vo = { class: "pagination flex items-center my-1 md:my-0" }, Ho = { class: "date mx-4 font-bold text-center text-indigo-600 select-none uppercase" }, Yo = { class: "pagination flex items-center my-1 sm:my-0" };
|
|
2264
|
+
const Uo = zo({ name: "dateSelector", components: { ChevronLeftIcon: cn, ChevronRightIcon: pn }, computed: { currentDate() {
|
|
2252
2265
|
return Y(this.selectedDate).locale("es").format("DD MMM. YYYY");
|
|
2253
2266
|
} }, props: { selectedDate: { type: Object, required: true } }, methods: { selectDate(e2, t2) {
|
|
2254
2267
|
let l2;
|
|
2255
2268
|
"previous" === t2 && ("day" === e2 && (l2 = Y(this.selectedDate).subtract(1, "day")), "month" === e2 && (l2 = Y(this.selectedDate).subtract(1, "month")), "year" === e2 && (l2 = Y(this.selectedDate).subtract(1, "year"))), "next" === t2 && ("day" === e2 && (l2 = Y(this.selectedDate).add(1, "day")), "month" === e2 && (l2 = Y(this.selectedDate).add(1, "month")), "year" === e2 && (l2 = Y(this.selectedDate).add(1, "year"))), this.$emit("dateSelected", l2);
|
|
2256
2269
|
} } }, [["render", function(t2, l2, n2, r2, s2, u2) {
|
|
2257
2270
|
const d2 = $("ChevronLeftIcon"), c2 = $("ChevronRightIcon");
|
|
2258
|
-
return e(), a("div",
|
|
2259
|
-
}]]),
|
|
2260
|
-
const
|
|
2261
|
-
return e(), a("div",
|
|
2271
|
+
return e(), a("div", $o, [i("div", Vo, [i("div", { class: "previousYear flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[0] || (l2[0] = (e2) => u2.selectDate("year", "previous")) }, [o(d2, { class: "h-4" }), o(d2, { class: "h-4 -ml-3" }), o(d2, { class: "h-4 -ml-3" })]), i("div", { class: "previousMonth flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[1] || (l2[1] = (e2) => u2.selectDate("month", "previous")) }, [o(d2, { class: "h-4" }), o(d2, { class: "h-4 -ml-3" })]), i("div", { class: "previousDay flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[2] || (l2[2] = (e2) => u2.selectDate("day", "previous")) }, [o(d2, { class: "h-4" })])]), i("div", Ho, _(u2.currentDate), 1), i("div", Yo, [i("div", { class: "previousDay flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[3] || (l2[3] = (e2) => u2.selectDate("day", "next")) }, [o(c2, { class: "h-4" })]), i("div", { class: "previousMonth flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[4] || (l2[4] = (e2) => u2.selectDate("month", "next")) }, [o(c2, { class: "h-4" }), o(c2, { class: "h-4 -ml-3" })]), i("div", { class: "previousYear flex items-center cursor-pointer bg-indigo-600 p-1 rounded mx-0.5 hover:bg-indigo-800 shadow-sm", onClick: l2[5] || (l2[5] = (e2) => u2.selectDate("year", "next")) }, [o(c2, { class: "h-4" }), o(c2, { class: "h-4 -ml-3" }), o(c2, { class: "h-4 -ml-3" })])])]);
|
|
2272
|
+
}]]), qo = { name: "SkeletonTable" }, Wo = { class: "px-4 sm:px-6 lg:px-8 animate-pulse" }, Ko = { class: "flow-root" }, Jo = { class: "-mx-4 -my-2 overflow-x-auto sm:-mx-6 lg:-mx-8" }, Go = { class: "inline-block min-w-full py-2 align-middle px-1" }, Zo = { class: "overflow-hidden shadow ring-1 ring-black ring-opacity-5 sm:rounded-lg" }, Xo = { class: "min-w-full divide-y divide-gray-300" }, Qo = i("thead", { class: "bg-gray-50" }, [i("tr", null, [i("th", { scope: "col", class: "py-3.5 pl-4 pr-3 text-left text-sm font-semibold text-gray-900 sm:pl-6" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })]), i("th", { scope: "col", class: "px-3 py-3.5 text-left text-sm font-semibold text-gray-900" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })]), i("th", { scope: "col", class: "px-3 py-3.5 text-left text-sm font-semibold text-gray-900" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })]), i("th", { scope: "col", class: "px-3 py-3.5 text-left text-sm font-semibold text-gray-900" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })]), i("th", { scope: "col", class: "relative py-3.5 pl-3 pr-4 sm:pr-6" }, [i("span", { class: "sr-only" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })])])])], -1), er = { class: "divide-y divide-gray-200 bg-white" }, tr = [i("td", { class: "whitespace-nowrap py-4 pl-4 pr-3 text-sm font-medium text-gray-900 sm:pl-6" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })], -1), i("td", { class: "whitespace-nowrap px-3 py-4 text-sm text-gray-500" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })], -1), i("td", { class: "whitespace-nowrap px-3 py-4 text-sm text-gray-500" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })], -1), i("td", { class: "whitespace-nowrap px-3 py-4 text-sm text-gray-500" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })], -1), i("td", { class: "relative whitespace-nowrap py-4 pl-3 pr-4 text-right text-sm font-medium sm:pr-6" }, [i("a", { href: "#", class: "text-indigo-600 hover:text-indigo-900" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" }), i("span", { class: "sr-only" }, [I(", {"), i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-6" })])])], -1)];
|
|
2273
|
+
const lr = zo(qo, [["render", function(t2, l2, n2, o2, r2, s2) {
|
|
2274
|
+
return e(), a("div", Wo, [i("div", Ko, [i("div", Jo, [i("div", Go, [i("div", Zo, [i("table", Xo, [Qo, i("tbody", er, [(e(), a(w, null, j(10, (e2) => i("tr", { key: e2 }, tr)), 64))])])])])])])]);
|
|
2262
2275
|
}]]);
|
|
2263
|
-
var
|
|
2264
|
-
|
|
2276
|
+
var nr = { exports: {} };
|
|
2277
|
+
nr.exports = function(e2, t2, l2) {
|
|
2265
2278
|
t2.prototype.isToday = function() {
|
|
2266
2279
|
var e3 = "YYYY-MM-DD", t3 = l2();
|
|
2267
2280
|
return this.format(e3) === t3.format(e3);
|
|
2268
2281
|
};
|
|
2269
2282
|
};
|
|
2270
|
-
const
|
|
2271
|
-
const
|
|
2272
|
-
return Y.extend(
|
|
2283
|
+
const ar = No(nr.exports), or = { class: "text-xs" }, rr = { class: "font-bold text-lg" }, ir = { class: "text-xs font-medium" };
|
|
2284
|
+
const sr = zo({ name: "calendarDay", props: { day: Object }, computed: { currentDay() {
|
|
2285
|
+
return Y.extend(ar), { dayName: Y(this.day).locale("es").format("ddd"), day: Y(this.day).locale("es").format("DD"), month: Y(this.day).locale("es").format("MMM."), isWeekend: 6 == Y(this.day).format("d") || 0 == Y(this.day).format("d"), isToday: Y(this.day).isToday() };
|
|
2273
2286
|
} } }, [["render", function(t2, l2, o2, r2, s2, u2) {
|
|
2274
|
-
return e(), a("div", { class: n(["day select-none text-center", { "bg-indigo-200 text-white": u2.currentDay.isWeekend, "bg-[#0ff] text-white": u2.currentDay.isToday }]) }, [i("p",
|
|
2275
|
-
}]]),
|
|
2287
|
+
return e(), a("div", { class: n(["day select-none text-center", { "bg-indigo-200 text-white": u2.currentDay.isWeekend, "bg-[#0ff] text-white": u2.currentDay.isToday }]) }, [i("p", or, _(u2.currentDay.dayName), 1), i("p", rr, _(u2.currentDay.day), 1), i("p", ir, _(u2.currentDay.month), 1)], 2);
|
|
2288
|
+
}]]), ur = { name: "dayPrice", props: { currency: String, price: Object, basePrice: Number, isBasePrice: { type: Boolean, default: false } }, computed: { currentDay() {
|
|
2276
2289
|
return { isWeekend: 6 == Y(this.price.date).format("d") || 0 == Y(this.price.date).format("d"), price: this.price.price };
|
|
2277
|
-
} } },
|
|
2278
|
-
const
|
|
2279
|
-
return e(), a("div",
|
|
2280
|
-
}]]), uiButton: ee, SkeletonTable:
|
|
2290
|
+
} } }, dr = { class: "priceDay" };
|
|
2291
|
+
const cr = { name: "uiPriceCalendar", data: () => ({ today: /* @__PURE__ */ new Date(), date: /* @__PURE__ */ new Date(), selectedRooms: [], showBasePricesModal: false, showDays: 14 }), props: { type: String, category: { type: Object, required: true }, rooms: { type: Array, required: true }, currency: Object, actions: Array, loading: { type: Boolean, default: true }, literals: { type: Object, required: true } }, components: { DateSelector: Uo, Day: sr, Price: zo(ur, [["render", function(t2, l2, o2, r2, s2, u2) {
|
|
2292
|
+
return e(), a("div", dr, [i("div", { class: n([{ "bg-indigo-200 text-white": u2.currentDay.isWeekend, "bg-green-300 text-white": o2.price.price > o2.basePrice, "bg-yellow-300 text-white": o2.price.price < o2.basePrice }, "select-none text-center rounded-lg p-1"]) }, _(u2.currentDay.price) + _(o2.currency), 3)]);
|
|
2293
|
+
}]]), uiButton: ee, SkeletonTable: lr }, computed: { days() {
|
|
2281
2294
|
let e2 = [];
|
|
2282
2295
|
for (let t2 = 0; t2 < this.showDays; t2++)
|
|
2283
2296
|
e2.push(Y(this.date).add(t2, "day"));
|
|
@@ -2299,44 +2312,44 @@ const ur = { name: "uiPriceCalendar", data: () => ({ today: /* @__PURE__ */ new
|
|
|
2299
2312
|
this.$emit("tableAction", e2);
|
|
2300
2313
|
}, changeRoomPrice(e2) {
|
|
2301
2314
|
this.$emit("changeRoomPrice", e2);
|
|
2302
|
-
} } },
|
|
2303
|
-
const
|
|
2315
|
+
} } }, pr = { key: 0, class: "px-4 sm:px-6 lg:px-8" }, gr = { class: "flow-root" }, mr = { class: "overflow-x-auto sm:-mx-6 lg:-mx-8 shadow ring-1 ring-black ring-opacity-5 sm:rounded-lg" }, fr = { class: "inline-block min-w-full align-middle" }, vr = { class: "min-w-full text-sm" }, hr = { class: "bg-white" }, br = { colspan: "6", scope: "colgroup", class: "bg-gray-50 py-2 pl-4 pr-3 text-left text-sm font-semibold text-gray-900 sm:pl-3" }, yr = { colspan: "20", scope: "colgroup", class: "bg-gray-200 py-2 pl-4 pr-3 text-left font-semibold text-gray-900" }, xr = { key: 0 }, wr = { colspan: "6", class: "pl-4" }, kr = { key: 1 }, Sr = { colspan: "6", class: "pl-4" }, Cr = { key: 2 }, Or = { colspan: "6", class: "pl-4" }, Mr = { colspan: "20", scope: "colgroup", class: "bg-gray-200 py-2 pl-4 pr-3 text-left font-semibold text-gray-900 relative" }, Dr = { key: 0, class: "absolute top-0 left-12 flex h-12 items-center space-x-3 sm:left-48 bg-white shadow rounded px-4 py-1 z-10" }, Tr = ["onClick"], Er = { colspan: "2", scope: "colgroup", class: "relative bg-gray-100 py-3.5 pl-4 pr-3 text-left font-semibold text-gray-900" }, Ir = ["checked", "indeterminate"], _r = { class: "pl-6" }, Pr = { colspan: "2", scope: "colgroup", class: "bg-gray-100 py-2 pl-4 pr-3 text-left font-semibold text-gray-900" }, jr = { colspan: "2", scope: "colgroup", class: "bg-gray-100 py-2 pl-4 pr-3 text-left font-semibold text-gray-900" }, Rr = i("th", { colspan: "14", scope: "colgroup", class: "bg-gray-100 py-2 pl-4 pr-3 text-left font-semibold text-gray-900" }, null, -1), Br = { colspan: "2", class: "relative py-3.5 pl-4 pr-3 text-left text-sm font-semibold text-gray-900 sm:pl-6" }, Ar = { key: 0, class: "absolute inset-y-0 left-0 w-0.5 bg-indigo-600" }, Lr = ["value"], Fr = { class: "pl-6" }, Nr = { colspan: "2", class: "pl-4" }, zr = { colspan: "2", class: "pl-4" };
|
|
2316
|
+
const $r = zo(cr, [["render", function(l2, r2, s2, u2, d2, c2) {
|
|
2304
2317
|
var _a2, _b;
|
|
2305
2318
|
const p2 = $("DateSelector"), g2 = $("Day"), m2 = $("uiButton"), f2 = $("Price"), v2 = $("SkeletonTable");
|
|
2306
|
-
return s2.loading ? (e(), t(v2, { key: 1 })) : (e(), a("div",
|
|
2307
|
-
}]]),
|
|
2319
|
+
return s2.loading ? (e(), t(v2, { key: 1 })) : (e(), a("div", pr, [i("div", gr, [i("div", mr, [i("div", fr, [i("table", vr, [i("tbody", hr, [i("tr", null, [i("th", br, [o(p2, { selectedDate: l2.date, onDateSelected: r2[0] || (r2[0] = (e2) => c2.changeDate(e2)) }, null, 8, ["selectedDate"])]), (e(true), a(w, null, j(c2.days, (t2, l3) => (e(), a("th", { scope: "col", key: l3, class: "text-sm font-semibold text-gray-900 p-0" }, [o(g2, { class: "border-l border-gray-200 px-6 py-3", day: t2 }, null, 8, ["day"])]))), 128))]), i("tr", null, [i("th", yr, [i("span", null, _(s2.literals.category) + " " + _(s2.category.name), 1), o(m2, { loading: s2.loading, class: "ml-4", size: "small", onClick: c2.changeCategoryBulkPrices }, { default: E(() => [I(_(s2.literals.changeInBulk), 1)]), _: 1 }, 8, ["loading", "onClick"])])]), "discounts" === s2.type ? (e(), a("tr", xr, [i("td", wr, _(s2.literals.pricesDiscount), 1), (e(true), a(w, null, j(s2.category.selectionPrices, (t2, l3) => (e(), a("td", { key: l3, class: "p-0" }, [o(f2, { onClick: (e2) => c2.changeCategorySelectionPrice(t2), class: "border-l border-gray-200 px-6 py-3 text-indigo-600 hover:text-indigo-400 font-bold cursor-pointer", price: t2, currency: s2.currency.symbol, isBasePrice: true }, null, 8, ["onClick", "price", "currency"])]))), 128))])) : R("", true), "prices" === s2.type ? (e(), a("tr", kr, [i("td", Sr, _(s2.literals.pricesSelection), 1), (e(true), a(w, null, j(s2.category.selectionPrices, (t2, l3) => (e(), a("td", { key: l3, class: "p-0" }, [o(f2, { onClick: (e2) => c2.changeCategorySelectionPrice(t2), class: "border-l border-gray-200 px-6 py-3 text-indigo-600 hover:text-indigo-400 font-bold cursor-pointer", price: t2, currency: s2.currency.symbol, isBasePrice: true }, null, 8, ["onClick", "price", "currency"])]))), 128))])) : R("", true), "prices" === s2.type ? (e(), a("tr", Cr, [i("td", Or, _(s2.literals.pricesUpgrade), 1), (e(true), a(w, null, j(s2.category.upgradePrices, (t2, l3) => (e(), a("td", { key: l3, class: "p-0" }, [o(f2, { onClick: (e2) => c2.changeCategoryUpgradePrice(t2), class: "border-l border-gray-200 px-6 py-3 text-indigo-600 hover:text-indigo-400 font-bold cursor-pointer bg-gray-100", price: t2, currency: s2.currency.symbol, isBasePrice: true }, null, 8, ["onClick", "price", "currency"])]))), 128))])) : R("", true), i("tr", null, [i("th", Mr, [((_a2 = l2.selectedRooms) == null ? void 0 : _a2.length) > 0 && ((_b = s2.actions) == null ? void 0 : _b.length) > 0 ? (e(), a("div", Dr, [(e(true), a(w, null, j(s2.actions, (t2, n2) => (e(), a("button", { onClick: (e2) => c2.tableAction({ action: t2.id, items: l2.selectedRooms }), key: n2, type: "button", class: "inline-flex items-center rounded bg-indigo-600 hover:bg-indigo-800 px-2.5 py-1.5 text-xs font-medium text-white shadow-sm disabled:cursor-not-allowed disabled:opacity-30" }, _(t2.name), 9, Tr))), 128))])) : R("", true), i("span", null, _(s2.literals.pricesSelection), 1)])]), i("tr", null, [i("th", Er, [i("input", { type: "checkbox", class: "absolute left-4 top-1/2 -mt-2 h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-600", checked: c2.indeterminate || l2.selectedRooms.length === s2.rooms.length, indeterminate: c2.indeterminate, onChange: r2[1] || (r2[1] = (e2) => l2.selectedRooms = e2.target.checked ? s2.rooms.map((e3) => e3.name) : []) }, null, 40, Ir), i("span", _r, _(s2.literals.room), 1)]), i("th", Pr, _(s2.literals.building), 1), i("th", jr, _(s2.literals.floor), 1), Rr]), (e(true), a(w, null, j(s2.rooms, (t2) => (e(), a("tr", { key: t2.name, class: n([{ "even:bg-gray-100": "prices" === s2.type, "odd:bg-gray-100": "discounts" === s2.type }]) }, [i("td", Br, [l2.selectedRooms.includes(t2.name) ? (e(), a("div", Ar)) : R("", true), B(i("input", { type: "checkbox", class: "absolute left-4 top-1/2 -mt-2 h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-600", value: t2.name, "onUpdate:modelValue": r2[2] || (r2[2] = (e2) => l2.selectedRooms = e2) }, null, 8, Lr), [[V, l2.selectedRooms]]), i("span", Fr, _(t2.name), 1)]), i("td", Nr, _(t2.building), 1), i("td", zr, _(t2.floor), 1), (e(true), a(w, null, j(t2.selectionPrices, (t3, l3) => (e(), a("td", { class: "p-0", key: l3 }, [o(f2, { onClick: (e2) => c2.changeRoomPrice(t3), class: "border-l border-gray-200 px-6 py-3 text-indigo-600 hover:text-indigo-400 cursor-pointer", price: t3, currency: s2.currency.symbol, basePrice: c2.getSelectionBasePrice(t3) }, null, 8, ["onClick", "price", "currency", "basePrice"])]))), 128))], 2))), 128))])])])])])]));
|
|
2320
|
+
}]]), Vr = { class: "chart-selector flex flex-row items-center justify-center" }, Hr = { name: "rangeSelector" }, Yr = Object.assign(Hr, { props: { range: { type: String } }, emits: ["rangeSelected"], setup(t2, { emit: l2 }) {
|
|
2308
2321
|
const o2 = l2, r2 = t2;
|
|
2309
2322
|
let s2 = u(() => r2.range);
|
|
2310
2323
|
const c2 = (e2) => {
|
|
2311
2324
|
s2.value = e2, o2("rangeSelected", e2);
|
|
2312
2325
|
};
|
|
2313
|
-
return (t3, l3) => (e(), a("ul",
|
|
2314
|
-
} }),
|
|
2326
|
+
return (t3, l3) => (e(), a("ul", Vr, [i("li", { class: n({ selected: "24h" === d(s2) }), onClick: l3[0] || (l3[0] = (e2) => c2("24h")) }, " 24H ", 2), i("li", { class: n({ selected: "7d" === d(s2) }), onClick: l3[1] || (l3[1] = (e2) => c2("7d")) }, "7D", 2), i("li", { class: n({ selected: "1m" === d(s2) }), onClick: l3[2] || (l3[2] = (e2) => c2("1m")) }, "1M", 2), i("li", { class: n({ selected: "3m" === d(s2) }), onClick: l3[3] || (l3[3] = (e2) => c2("3m")) }, "3M", 2)]));
|
|
2327
|
+
} }), Ur = { class: "chart-header flex flex-row justify-between" }, qr = { class: "text-sm font-medium text-gray-500 truncate" }, Wr = { class: "chart-content" }, Kr = { class: "h-full w-full flex items-center justify-center flex-col" }, Jr = i("p", { class: "text-xs uppercase text-gray-300 font-bold" }, "No data", -1), Gr = { class: "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow h-80" }, Zr = [i("div", { role: "status", class: "w-full animate-pulse h-full flex flex-col" }, [i("div", { class: "h-2.5 w-36 bg-gray-200 rounded-full mb-2.5" }), i("div", { class: "w-48 h-2 mb-6 bg-gray-200 rounded-full" }), i("div", { class: "flex flex-row justify-between items-baseline grow gap-x-1" }, [i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" })])], -1)], Xr = { name: "uiChart" }, Qr = Object.assign(Xr, { props: { title: String, id: { type: String, default: "noChartId" }, type: { type: String, default: "area" }, series: { type: Array, required: true }, options: { type: Object, required: true }, loading: { type: Boolean, default: true }, empty: { type: Boolean, default: false }, range: { type: String, default: "24h" }, horizontal: { type: Boolean, default: false }, stacked: { type: Boolean, default: false }, height: { type: Number, default: 320 }, annotations: { type: Object } }, emits: ["selectedRange", "chartUpdated", "dataPointSelection"], setup(t2, { emit: l2 }) {
|
|
2315
2328
|
const r2 = l2, s2 = t2;
|
|
2316
2329
|
let c2 = { chart: { toolbar: { show: false }, zoom: { enabled: false } }, colors: ["#715aff", "#00ffff", "#aba9ba"], stroke: { show: true, curve: "stepline", lineCap: "butt", width: 1, dashArray: 0 }, dataLabels: { enabled: true }, markers: { strokeWidth: 0, size: 4, hover: { size: 8 } } };
|
|
2317
2330
|
s2.annotations && (c2.annotations = { yaxis: [{ y: s2.annotations.high, borderColor: "#4f46e5", label: { borderColor: "#4f46e5", style: { color: "#fff", background: "#4f46e5" }, text: s2.annotations.text } }] }), "area" === s2.type && (c2.tooltip = { intersect: true, shared: false });
|
|
2318
2331
|
const p2 = u(() => s2.series), g2 = u(() => (c2.chart.stacked = s2.stacked, { ...c2, ...s2.options, plotOptions: { bar: { horizontal: s2.horizontal } } })), m2 = () => r2("chartUpdated"), f2 = (e2, t3, l3) => {
|
|
2319
2332
|
r2("dataPointSelection", { id: s2.id, chartContext: t3, config: l3, event: e2 });
|
|
2320
2333
|
};
|
|
2321
|
-
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div",
|
|
2322
|
-
} }),
|
|
2323
|
-
const
|
|
2324
|
-
return e(), a("footer",
|
|
2325
|
-
}]]),
|
|
2334
|
+
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div", Ur, [i("div", qr, _(t2.title), 1), o(Yr, { range: t2.range, onRangeSelected: r3[0] || (r3[0] = (e2) => l3.$emit("selectedRange", { range: e2, chartId: t2.id })) }, null, 8, ["range"])]), B(i("div", Wr, [o(d(U), { type: t2.type, series: p2.value, width: "100%", height: t2.height, options: g2.value, onUpdated: m2, onMounted: m2, onDataPointSelection: f2 }, null, 8, ["type", "series", "height", "options"])], 512), [[L, !t2.empty]]), B(i("div", Kr, [o(J, { icon: d(fn), color: "gray", loading: false, size: "huge" }, null, 8, ["icon"]), Jr], 512), [[L, t2.empty]])], 2), [[L, !t2.loading]]), B(i("div", Gr, Zr, 512), [[L, t2.loading]])], 64));
|
|
2335
|
+
} }), ei = { name: "uiFooter" }, ti = { class: "bg-white" }, li = [i("div", { class: "mx-auto py-6 px-4 sm:px-6 md:flex md:items-center md:justify-between lg:px-8" }, [i("div", { class: "mt-8 md:mt-0 md:order-1" }, [i("p", { class: "text-center text-base text-gray-400" }, "© Made by Hotelinking.")])], -1)];
|
|
2336
|
+
const ni = zo(ei, [["render", function(t2, l2, n2, o2, r2, i2) {
|
|
2337
|
+
return e(), a("footer", ti, li);
|
|
2338
|
+
}]]), ai = i("div", { class: "spinner h-12 w-12 mb-6" }, [i("img", { src: "https://images.hotelinking.com/ui/loader.gif", alt: "loading animation" })], -1), oi = { name: "uiLoadScreen" }, ri = Object.assign(oi, { props: { title: String, message: String, fixed: { type: Boolean, default: true } }, setup: (t2) => (l2, o2) => (e(), a("div", { class: n([{ fixed: t2.fixed }, "load-screen h-full w-full top-0 left-0 z-50 flex flex-col items-center justify-center bg-gray-50"]) }, [ai, B(i("h2", { class: "text-xs font-bold text-center uppercase mb-2" }, _(t2.title), 513), [[L, t2.title]]), B(i("p", { class: "text-xs text-center uppercase md:w-1/4" }, _(t2.message), 513), [[L, t2.message]])], 2)) }), ii = { key: 0, class: "py-6 flex items-center justify-between" }, si = { class: "flex-1 flex justify-between sm:hidden" }, ui = { href: "#", class: "relative inline-flex items-center px-4 py-2 border border-gray-300 text-sm font-medium rounded-md text-gray-700 bg-white hover:bg-gray-50" }, di = { href: "#", class: "ml-3 relative inline-flex items-center px-4 py-2 border border-gray-300 text-sm font-medium rounded-md text-gray-700 bg-white hover:bg-gray-50" }, ci = { class: "hidden sm:flex-1 sm:flex sm:items-center sm:justify-between" }, pi = { class: "text-sm text-gray-700" }, gi = { class: "font-bold" }, mi = { class: "font-bold" }, fi = { class: "relative z-0 inline-flex rounded-md shadow-sm -space-x-px", "aria-label": "Pagination" }, vi = { class: "sr-only" }, hi = ["onClick"], bi = { class: "sr-only" }, yi = { key: 1, class: "py-6 flex flex-row justify-between items-center animate-pulse" }, xi = [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/5" }, null, -1), i("div", { class: "h-10 w-32 bg-gray-200 rounded dark:bg-gray-300" }, null, -1)], wi = { name: "uiPagination" }, ki = Object.assign(wi, { props: { current: { type: Number, requires: true }, total: { type: Number, requires: true }, loading: { type: Boolean, default: true } }, emits: ["changePage"], setup(t2, { emit: l2 }) {
|
|
2326
2339
|
const c2 = l2, p2 = t2, g2 = s(3), m2 = u(() => Math.max(1, Number(p2.current) - Number(g2.value))), f2 = u(() => Math.min(Number(p2.current) + Number(g2.value), Number(p2.total))), v2 = u(() => {
|
|
2327
2340
|
let e2 = [];
|
|
2328
2341
|
for (let t3 = Number(m2.value); t3 <= Number(f2.value); t3++)
|
|
2329
2342
|
e2.push(t3);
|
|
2330
2343
|
return e2;
|
|
2331
2344
|
});
|
|
2332
|
-
return (l3, s2) => t2.loading ? (e(), a("div",
|
|
2333
|
-
} }),
|
|
2345
|
+
return (l3, s2) => t2.loading ? (e(), a("div", yi, xi)) : (e(), a("div", ii, [i("div", si, [i("a", ui, [r(l3.$slots, "previous")]), i("a", di, [r(l3.$slots, "next")])]), i("div", ci, [i("div", null, [i("p", pi, [r(l3.$slots, "showing"), I(), i("span", gi, _(t2.current + " "), 1), r(l3.$slots, "of"), I(), i("span", mi, _(t2.total), 1)])]), i("div", null, [i("nav", fi, [B(i("button", { onClick: s2[0] || (s2[0] = (e2) => c2("changePage", t2.current - 1)), class: "relative inline-flex items-center px-2 py-2 rounded-l-md border border-gray-300 bg-white text-sm font-medium text-gray-500 hover:bg-gray-50" }, [i("span", vi, [r(l3.$slots, "previous")]), o(d(cn), { class: "h-5 w-5", "aria-hidden": "true" })], 512), [[L, 1 !== t2.current]]), (e(true), a(w, null, j(v2.value, (l4) => (e(), a("button", { onClick: (e2) => c2("changePage", l4), key: l4, "aria-current": "page", class: n([[l4 === t2.current ? "z-10 bg-indigo-50 border-indigo-500 text-indigo-600" : "bg-white border-gray-300 text-gray-500 hover:bg-gray-50"], "relative inline-flex items-center px-4 py-2 border text-sm font-medium"]) }, _(l4), 11, hi))), 128)), B(i("button", { onClick: s2[1] || (s2[1] = (e2) => c2("changePage", t2.current + 1)), class: "relative inline-flex items-center px-2 py-2 rounded-r-md border border-gray-300 bg-white text-sm font-medium text-gray-500 hover:bg-gray-50" }, [i("span", bi, [r(l3.$slots, "next")]), o(d(pn), { class: "h-5 w-5", "aria-hidden": "true" })], 512), [[L, t2.current !== t2.total]])])])])]));
|
|
2346
|
+
} }), Si = { class: "hidden md:flex md:flex-col sticky md:inset-y-0" }, Ci = { class: "flex flex-col flex-grow overflow-y-auto" }, Oi = { class: "grow flex flex-col" }, Mi = { class: "flex-1 space-y-1", "aria-label": "Sidebar" }, Di = { key: 0 }, Ti = ["onClick"], Ei = { key: 0, class: "text-left" }, Ii = { key: 0, class: "flex-1 text-left" }, _i = { key: 1, class: "flex-1" }, Pi = [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2" }, null, -1)], ji = { key: 0, class: "align-left" }, Ri = { key: 1, class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2" }, Bi = { class: "h-12 flex flex-row items-center" }, Ai = [i("div", { class: "w-6 h-6 animate-pulse bg-gray-200 rounded-full dark:bg-gray-300 mr-4" }, null, -1), i("div", { class: "h-3 animate-pulse bg-gray-200 rounded-full dark:bg-gray-300 grow" }, null, -1)], Li = { name: "uiSidebar" }, Fi = Object.assign(Li, { props: { navigation: { type: Array, required: true }, loading: { type: Boolean, default: true } }, emits: ["sideBarClick"], setup(l2, { emit: r2 }) {
|
|
2334
2347
|
const s2 = r2;
|
|
2335
|
-
return (r3, u2) => (e(), a("div",
|
|
2336
|
-
} }),
|
|
2348
|
+
return (r3, u2) => (e(), a("div", Si, [i("div", Ci, [i("div", Oi, [i("nav", Mi, [l2.loading ? (e(), a(w, { key: 1 }, j(5, (e2) => i("div", Bi, Ai)), 64)) : (e(true), a(w, { key: 0 }, j(l2.navigation, (r4) => (e(), a(w, { key: r4.name }, [r4.children ? (e(), t(d(Sl), { key: 1, as: "div", class: "space-y-1" }, { default: E(({ open: i2 }) => [o(d(Cl), { class: n([r4.current ? "bg-indigo-600 text-white" : "text-gray-600 hover:bg-gray-50 hover:text-gray-900", "group w-full flex items-center pl-2 pr-1 py-2 text-left text-sm font-medium rounded-md focus:outline-none"]) }, { default: E(() => [o(J, { loading: l2.loading, icon: r4.icon, class: n([r4.current ? "text-white" : "text-gray-400 group-hover:text-gray-500", "mr-3 flex-shrink-0 h-6 w-6"]), "aria-hidden": "true" }, null, 8, ["loading", "icon", "class"]), l2.loading ? (e(), a("div", _i, Pi)) : (e(), a("span", Ii, _(r4.name), 1)), o(d(pn), { class: n([i2 ? "text-gray-400 rotate-90" : "text-gray-400", "ml-3 flex-shrink-0 h-3 w-3 transform group-hover:text-gray-400 transition-colors ease-in-out duration-150"]) }, null, 8, ["class"])]), _: 2 }, 1032, ["class"]), o(d(Ol), { class: "space-y-1" }, { default: E(() => [(e(true), a(w, null, j(r4.children, (o2) => (e(), t(d(Cl), { onClick: (e2) => s2("sideBarClick", o2.id), key: o2.name, class: n([o2.current ? "bg-gray-200" : "hover:text-gray-900 hover:bg-gray-100", "group text-gray-600 w-full flex items-center text-left pl-11 pr-2 py-2 text-sm font-medium rounded-md"]) }, { default: E(() => [l2.loading ? (e(), a("div", Ri)) : (e(), a("span", ji, _(o2.name), 1))]), _: 2 }, 1032, ["onClick", "class"]))), 128))]), _: 2 }, 1024)]), _: 2 }, 1024)) : (e(), a("div", Di, [i("button", { onClick: (e2) => s2("sideBarClick", r4.id), class: n([r4.current ? "bg-indigo-600 text-white" : "text-gray-600 hover:bg-gray-50 hover:text-gray-900", "group w-full flex items-center pl-2 py-2 text-sm font-medium rounded-md"]) }, [o(J, { loading: l2.loading, icon: r4.icon, class: n([r4.current ? "text-white" : "text-gray-400 group-hover:text-gray-500", "mr-3 flex-shrink-0 h-6 w-6"]), "aria-hidden": "true" }, null, 8, ["loading", "icon", "class"]), l2.loading ? R("", true) : (e(), a("span", Ei, _(r4.name), 1))], 10, Ti)]))], 64))), 128))])])])]));
|
|
2349
|
+
} }), Ni = { key: 0 }, zi = { class: "ml-16 text-sm font-medium text-gray-500 truncate" }, $i = { class: "ml-16 flex items-baseline pb-5" }, Vi = { class: "text-2xl font-semibold text-gray-900" }, Hi = { key: 0, class: "text-black ml-2 flex items-baseline text-sm font-semibold" }, Yi = { class: "absolute bottom-0 inset-x-0 bg-gray-50 px-4 py-4 sm:px-6" }, Ui = { class: "text-sm" }, qi = { key: 1 }, Wi = { class: "relative bg-white pt-5 px-4 sm:pt-6 sm:px-6 shadow rounded-lg overflow-hidden h-full pb-6" }, Ki = { class: "absolute bg-gray-200 rounded-md p-3 animate-pulse" }, Ji = i("div", { class: "ml-16" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2 mb-4 animate-pulse" })], -1), Gi = i("div", { class: "ml-16" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/2 animate-pulse" })], -1), Zi = { name: "uiStats" }, Xi = Object.assign(Zi, { props: { item: { type: Object, required: true }, loading: { type: Boolean, default: true } }, emits: ["statClick"], setup(l2, { emit: r2 }) {
|
|
2337
2350
|
const s2 = r2;
|
|
2338
|
-
return (r3, u2) => l2.loading ? (e(), a("div",
|
|
2339
|
-
} }),
|
|
2351
|
+
return (r3, u2) => l2.loading ? (e(), a("div", qi, [i("div", Wi, [i("dt", null, [i("div", Ki, [o(J, { loading: l2.loading, icon: l2.item.icon, class: "h-6 w-6 text-white", "aria-hidden": "true" }, null, 8, ["loading", "icon"])]), Ji, Gi])])])) : (e(), a("div", Ni, [i("div", { class: n(["relative bg-white pt-5 px-4 sm:pt-6 sm:px-6 shadow rounded-lg overflow-hidden h-full", { "pb-12": l2.item.showFooter }]) }, [i("dt", null, [i("div", { class: n(["absolute rounded-md p-3", { "bg-indigo-500": !l2.item.color, "bg-green-500": "success" === l2.item.color, "bg-red-500": "danger" === l2.item.color, "bg-yellow-500": "warning" === l2.item.color }]) }, [o(J, { icon: l2.item.icon, class: "h-6 w-6 text-white", "aria-hidden": "true", loading: l2.loading }, null, 8, ["icon", "loading"])], 2), i("p", zi, _(l2.item.name), 1)]), i("dd", $i, [i("p", Vi, _(l2.item.stat), 1), l2.item.explanation ? (e(), a("p", Hi, _(l2.item.explanation), 1)) : R("", true), l2.item.changeType ? (e(), a("p", { key: 1, class: n([{ "text-green-600": "increase" === l2.item.changeType, "text-red-600": "decrease" === l2.item.changeType, "text-black": "neutral" === l2.item.changeType }, "ml-2 flex items-baseline text-sm font-semibold"]) }, ["increase" === l2.item.changeType ? (e(), t(d(on), { key: 0, class: "self-center flex-shrink-0 h-3 w-3 text-green-500", "aria-hidden": "true" })) : R("", true), "decrease" === l2.item.changeType ? (e(), t(d(an), { key: 1, class: "self-center flex-shrink-0 h-3 w-3 text-red-500", "aria-hidden": "true" })) : R("", true), I(" " + _(l2.item.change), 1)], 2)) : R("", true), B(i("div", Yi, [i("div", Ui, [i("span", { onClick: u2[0] || (u2[0] = (e2) => s2("statClick", l2.item.id)), class: "font-medium text-indigo-600 hover:text-indigo-500 cursor-pointer" }, _(l2.item.actionText), 1)])], 512), [[L, l2.item.showFooter]])])], 2)]));
|
|
2352
|
+
} }), Qi = { key: 0, class: "overflow-hidden bg-white shadow sm:rounded-lg" }, es = { class: "px-4 py-5 sm:px-6" }, ts = { class: "text-lg font-medium leading-6 text-gray-900" }, ls = { class: "mt-1 max-w-2xl text-sm text-gray-500" }, ns = { class: "border-t border-gray-200" }, as = { class: "text-sm font-medium text-gray-500" }, os = { key: 0, class: "mt-1 text-sm text-gray-900 sm:col-span-2 sm:mt-0 break-normal" }, rs = { key: 1, class: "mt-1 text-sm text-gray-900 sm:col-span-2 sm:mt-0 break-normal" }, is = ["onClick"], ss = { key: 3, class: "mt-1 text-sm text-gray-900 sm:col-span-2 sm:mt-0 break-words" }, us = { key: 1, class: "overflow-hidden bg-white shadow sm:rounded-lg" }, ds = z('<div class="px-4 py-5 sm:px-6 animate-pulse"><h3 class="text-lg font-medium leading-6 text-gray-900"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/4"></div></h3><p class="mt-1 max-w-2xl text-sm text-gray-500"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-2/5"></div></p></div>', 1), cs = { class: "border-t border-gray-200" }, ps = [i("dt", { class: "text-sm font-medium text-gray-500" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-12" })], -1), i("dd", { class: "mt-1 text-sm text-gray-900 sm:col-span-2 sm:mt-0 break-words" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-12" })], -1)], gs = { name: "uiStripedCard" }, ms = Object.assign(gs, { props: { title: String, subtitle: String, items: Object, loading: { type: Boolean, default: true } }, emits: ["itemClicked"], setup: (l2, { emit: r2 }) => (r3, s2) => l2.loading ? (e(), a("div", us, [ds, i("div", cs, [i("dl", null, [(e(), a(w, null, j(5, (e2) => i("div", { key: e2, class: n(["px-4 py-5 sm:grid sm:grid-cols-3 sm:gap-4 sm:px-6", [e2 % 2 == 0 ? "bg-gray-50" : "bg-white"]]) }, ps, 2)), 64))])])])) : (e(), a("div", Qi, [i("div", es, [i("h3", ts, _(l2.title), 1), i("p", ls, _(l2.subtitle), 1)]), i("div", ns, [i("dl", null, [(e(true), a(w, null, j(l2.items, (s3, u2) => (e(), a("div", { key: u2, class: n(["px-4 py-5 sm:grid sm:grid-cols-3 sm:gap-4 sm:px-6", [u2 % 2 == 0 ? "bg-gray-50" : "bg-white"]]) }, [i("dt", as, _(s3.title), 1), "tag" === s3.type ? (e(), a("dd", os, [o(ua, { color: s3.color }, { default: E(() => [I(_(s3.text), 1)]), _: 2 }, 1032, ["color"])])) : "tags" === s3.type ? (e(), a("dd", rs, [(e(true), a(w, null, j(s3.tags, (n2, a2) => (e(), t(ua, { loading: l2.loading, key: a2, color: n2.color, class: "mr-2 mb-2" }, { default: E(() => [I(_(n2.text), 1)]), _: 2 }, 1032, ["loading", "color"]))), 128))])) : "link" === s3.type ? (e(), a("dd", { key: 2, class: "mt-1 text-sm text-indigo-600 hover:text-indigo-400 sm:col-span-2 sm:mt-0 cursor-pointer", onClick: (e2) => r3.$emit("itemClicked", s3.emits) }, _(s3.text), 9, is)) : (e(), a("dd", ss, _(s3.text), 1))], 2))), 128))])])])) }), fs = { class: "absolute top-10 bg-indigo-600 text-white text-xs p-2 rounded z-10 font-light w-60 flex flex-row items-start" }, vs = i("svg", { class: "absolute -top-3 left-0", xmlns: "http://www.w3.org/2000/svg", width: "27.687", height: "26.954", viewBox: "0 0 27.687 26.954" }, [i("path", { id: "Polígono_1", "data-name": "Polígono 1", d: "M10.5,0,21,19H0Z", transform: "translate(0 10.5) rotate(-30)", fill: "#4f46e5" })], -1), hs = { class: "ml-2" }, bs = { __name: "tooltip", props: { tip: { type: String, required: true } }, setup: (t2) => (l2, n2) => (e(), a("div", fs, [vs, i("div", null, [o(J, { icon: d(yn), loading: false, color: "white", size: "big" }, null, 8, ["icon"])]), i("span", hs, _(t2.tip), 1)])) }, ys = { key: 0 }, xs = { class: "flex flex-col" }, ws = { class: "-my-2 overflow-x-auto" }, ks = { class: "inline-block min-w-full py-2 align-middle px-1" }, Ss = { class: "relative overflow-hidden shadow ring-1 ring-black ring-opacity-5 md:rounded-lg" }, Cs = { key: 0, class: "absolute top-0 left-12 flex h-12 items-center space-x-3 sm:left-16 bg-white shadow rounded px-4 py-1 z-10" }, Os = ["onClick"], Ms = { class: "min-w-full table-fixed divide-y divide-gray-300" }, Ds = { class: "bg-gray-50" }, Ts = ["checked", "indeterminate"], Es = ["onMouseover", "onMouseleave"], Is = ["onClick"], _s = { key: 2, class: "group flex items-center uppercase text-xs" }, Ps = { class: "divide-y divide-gray-200 bg-white" }, js = { key: 0, class: "absolute inset-y-0 left-0 w-0.5 bg-indigo-600" }, Rs = ["value"], Bs = ["onClick"], As = ["href"], Ls = { key: 3 }, Fs = { name: "uiTable" }, Ns = Object.assign(Fs, { props: { header: { type: Array, required: true }, items: { type: Array, required: true }, orderedBy: String, orderDirection: { type: String, default: "asc" }, actions: Array, loading: { type: Boolean, default: true } }, emits: ["tableAction", "orderBy"], setup(l2, { emit: r2 }) {
|
|
2340
2353
|
let c2 = s([]);
|
|
2341
2354
|
s(false);
|
|
2342
2355
|
let p2 = s(void 0);
|
|
@@ -2345,65 +2358,65 @@ const ti = Fo(Xr, [["render", function(t2, l2, n2, o2, r2, i2) {
|
|
|
2345
2358
|
};
|
|
2346
2359
|
return (r3, s2) => {
|
|
2347
2360
|
var _a2, _b;
|
|
2348
|
-
return l2.loading ? (e(), t(
|
|
2361
|
+
return l2.loading ? (e(), t(lr, { key: 1 })) : (e(), a("div", ys, [i("div", xs, [i("div", ws, [i("div", ks, [i("div", Ss, [((_a2 = d(c2)) == null ? void 0 : _a2.length) > 0 && ((_b = l2.actions) == null ? void 0 : _b.length) > 0 ? (e(), a("div", Cs, [(e(true), a(w, null, j(l2.actions, (t2, l3) => (e(), a("button", { onClick: (e2) => g2("tableAction", { action: t2.id, items: d(c2) }), key: l3, type: "button", class: "inline-flex items-center rounded bg-indigo-600 hover:bg-indigo-800 px-2.5 py-1.5 text-xs font-medium text-white shadow-sm disabled:cursor-not-allowed disabled:opacity-30" }, _(t2.name), 9, Os))), 128))])) : R("", true), i("table", Ms, [i("thead", Ds, [i("tr", null, [i("th", { scope: "col", class: n([l2.actions ? "px-6 sm:px-8" : "px-3", "relative"]) }, [l2.actions ? (e(), a("input", { key: 0, checked: f2.value || d(c2).length === l2.items.length, indeterminate: f2.value, class: "absolute left-4 top-1/2 -mt-2 h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-500", type: "checkbox", onChange: s2[0] || (s2[0] = (e2) => H(c2) ? c2.value = e2.target.checked ? l2.items.map((e3) => e3.id) : [] : c2 = e2.target.checked ? l2.items.map((e3) => e3.id) : []) }, null, 40, Ts)) : R("", true)], 2), (e(true), a(w, null, j(l2.header, (r4, s3) => (e(), a("th", { key: s3, class: "py-3.5 pr-3 text-left font-semibold text-gray-900 flex-wrap relative", scope: "col", onMouseover: (e2) => v2(r4.name, true), onMouseleave: (e2) => v2(r4.name, false) }, [r4.tooltip ? B((e(), t(bs, { key: 0, tip: r4.tooltip }, null, 8, ["tip"])), [[L, d(p2) === r4.name]]) : R("", true), r4.value ? (e(), a("button", { key: 1, class: "group flex items-center uppercase text-xs relative", onClick: (e2) => g2("orderBy", { value: r4.value, orderDirection: "asc" === l2.orderDirection ? "desc" : "asc" }) }, [i("span", null, _(r4.name), 1), i("span", { class: n([[r4.value === l2.orderedBy ? "bg-indigo-600 text-white group-hover:bg-gray-300" : "text-gray-400 group-hover:visible group-focus:visible"], "ml-2 flex-none rounded group-hover:bg-indigo-200 group-hover:text-white"]) }, [o(J, { icon: "asc" === l2.orderDirection ? d(dn) : d(mn), loading: l2.loading, color: r4.value === l2.orderedBy ? "white" : "primary" }, null, 8, ["icon", "loading", "color"])], 2)], 8, Is)) : (e(), a("p", _s, [i("span", null, _(r4.name), 1)]))], 40, Es))), 128))])]), i("tbody", Ps, [(e(true), a(w, null, j(l2.items, (o2, r4) => {
|
|
2349
2362
|
var _a3, _b2;
|
|
2350
|
-
return e(), a("tr", { key: o2.id, class: n([d(c2).includes(o2.id) && "bg-gray-50", r4 % 2 == 0 ? void 0 : "bg-gray-50"]) }, [i("td", { class: n([((_a3 = l2.actions) == null ? void 0 : _a3.length) > 0 ? "w-2" : "w-0", "relative"]) }, [d(c2).includes(o2.id) ? (e(), a("div",
|
|
2363
|
+
return e(), a("tr", { key: o2.id, class: n([d(c2).includes(o2.id) && "bg-gray-50", r4 % 2 == 0 ? void 0 : "bg-gray-50"]) }, [i("td", { class: n([((_a3 = l2.actions) == null ? void 0 : _a3.length) > 0 ? "w-2" : "w-0", "relative"]) }, [d(c2).includes(o2.id) ? (e(), a("div", js)) : R("", true), ((_b2 = l2.actions) == null ? void 0 : _b2.length) > 0 ? B((e(), a("input", { key: 1, "onUpdate:modelValue": s2[1] || (s2[1] = (e2) => H(c2) ? c2.value = e2 : c2 = e2), value: o2.id, class: "absolute left-4 top-1/2 -mt-2 h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-500 flex-wrap", type: "checkbox" }, null, 8, Rs)), [[V, d(c2)]]) : R("", true)], 2), (e(true), a(w, null, j(o2.row, (r5, i2) => (e(), a("td", { key: i2, class: n(["whitespace-nowrap py-4 pr-3 text-sm", d(c2).includes(o2.id) ? "text-indigo-600" : "text-gray-900"]) }, ["object" == typeof r5 && "tag" === r5.type ? (e(), t(ua, { key: 0, loading: l2.loading, color: r5.color }, { default: E(() => [I(_(r5.content), 1)]), _: 2 }, 1032, ["loading", "color"])) : "object" == typeof r5 && "link" === r5.type ? (e(), a("span", { key: 1, class: "text-indigo-600 hover:text-indigo-400 cursor-pointer", onClick: (e2) => g2(r5.emits, { id: o2.id, data: (o2 == null ? void 0 : o2.emitWith) || null }) }, _(r5.content), 9, Bs)) : "object" == typeof r5 && "href" === r5.type ? (e(), a("a", { key: 2, class: "text-indigo-600 hover:text-indigo-400 cursor-pointer", href: r5.href, target: "_blank" }, _(r5.content), 9, As)) : (e(), a("span", Ls, _(r5), 1))], 2))), 128))], 2);
|
|
2351
2364
|
}), 128))])])])])])])]));
|
|
2352
2365
|
};
|
|
2353
|
-
} }),
|
|
2366
|
+
} }), zs = { class: "lg:hidden" }, $s = ["value"], Vs = { class: "hidden lg:block" }, Hs = { class: "border-b border-gray-200" }, Ys = { class: "-mb-px flex space-x-8", "aria-label": "Tabs" }, Us = ["onClick", "aria-current"], qs = { name: "uiTabs" }, Ws = Object.assign(qs, { props: { tabs: Array }, emits: ["tabClicked"], setup(t2, { emit: l2 }) {
|
|
2354
2367
|
const o2 = l2;
|
|
2355
|
-
return (l3, r2) => (e(), a("div", null, [i("div",
|
|
2368
|
+
return (l3, r2) => (e(), a("div", null, [i("div", zs, [i("select", { onChange: r2[0] || (r2[0] = (e2) => {
|
|
2356
2369
|
o2("tabClicked", e2.target.value);
|
|
2357
|
-
}), id: "tabs", name: "tabs", class: "block w-full rounded-md border-gray-300 py-2 pl-3 pr-10 text-base focus:border-indigo-500 focus:outline-none focus:ring-indigo-500 sm:text-sm" }, [(e(true), a(w, null, j(t2.tabs, (t3) => (e(), a("option", { value: t3.id, key: t3.name }, _(t3.name), 9,
|
|
2358
|
-
} }),
|
|
2370
|
+
}), id: "tabs", name: "tabs", class: "block w-full rounded-md border-gray-300 py-2 pl-3 pr-10 text-base focus:border-indigo-500 focus:outline-none focus:ring-indigo-500 sm:text-sm" }, [(e(true), a(w, null, j(t2.tabs, (t3) => (e(), a("option", { value: t3.id, key: t3.name }, _(t3.name), 9, $s))), 128))], 32)]), i("div", Vs, [i("div", Hs, [i("nav", Ys, [(e(true), a(w, null, j(t2.tabs, (t3) => (e(), a("a", { key: t3.name, onClick: (e2) => o2("tabClicked", t3.id), class: n([t3.current ? "border-indigo-500 text-indigo-600" : "border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-200", "whitespace-nowrap flex py-4 px-1 border-b-2 font-medium text-sm cursor-pointer"]), "aria-current": t3.current ? "page" : void 0 }, [I(_(t3.name) + " ", 1), t3.count ? (e(), a("span", { key: 0, class: n([t3.current ? "bg-indigo-100 text-indigo-600" : "bg-gray-100 text-gray-900", "hidden ml-3 py-0.5 px-2.5 rounded-full text-xs font-medium md:inline-block"]) }, _(t3.count), 3)) : R("", true)], 10, Us))), 128))])])])]));
|
|
2371
|
+
} }), Ks = { key: 0, class: "bg-white overflow-hidden shadow rounded-lg" }, Js = { class: "px-4 py-5 sm:px-6" }, Gs = { class: "text-xl font-bold" }, Zs = { class: "px-4 py-5 sm:p-6" }, Xs = { class: "flow-root" }, Qs = { class: "-mb-8", role: "list" }, eu = { class: "relative pb-8" }, tu = { key: 0, class: "absolute left-4 top-4 -ml-px h-full w-0.5 bg-gray-200", "aria-hidden": "true" }, lu = { class: "relative flex space-x-3" }, nu = { class: "min-w-0 flex-1 pt-1.5 flex justify-between space-x-4 items-center" }, au = { class: "text-sm text-gray-500" }, ou = ["onClick"], ru = { class: "text-right text-sm whitespace-nowrap text-gray-500" }, iu = ["datetime"], su = { class: "bg-gray-50 px-4 py-4 sm:px-6 z-10" }, uu = { class: "text-sm" }, du = { class: "h-full w-full flex items-center justify-center flex-col mb-5" }, cu = i("p", { class: "text-xs uppercase text-gray-300 font-bold" }, "No data", -1), pu = { key: 1, class: "bg-white overflow-hidden shadow rounded-lg" }, gu = i("div", { class: "px-4 py-5 sm:px-6 animate-pulse" }, [i("h1", { class: "text-xl font-bold" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/4" })])], -1), mu = { class: "px-4 py-5 sm:p-6 animate-pulse" }, fu = { class: "flow-root" }, vu = { class: "-mb-8", role: "list" }, hu = { class: "relative pb-8" }, bu = { key: 0, class: "absolute left-4 top-4 -ml-px h-full w-0.5 bg-gray-200", "aria-hidden": "true" }, yu = z('<div class="relative flex space-x-3"><div><span class="h-8 w-8 rounded-full bg-gray-300 flex items-center justify-center ring-4 ring-white"></span></div><div class="min-w-0 flex-1 pt-1.5 flex justify-between space-x-4 items-center"><div><p class="text-sm text-gray-500 flex-1"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-full"></div></p></div><div class="text-right text-sm whitespace-nowrap text-gray-500 flex-1"><div class="h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/4"></div></div></div></div>', 1), xu = i("div", { class: "bg-gray-50 px-4 py-4 sm:px-6 z-10 animate-pulse" }, [i("div", { class: "text-sm" }, [i("div", { class: "h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-1/4" })])], -1), wu = { name: "uiTimeline" }, ku = Object.assign(wu, { props: { name: { type: String, required: true }, timeline: { type: Object }, loading: { type: Boolean, default: true }, empty: { type: Boolean, default: false } }, setup: (t2) => (l2, r2) => {
|
|
2359
2372
|
const s2 = $("uiIcon");
|
|
2360
|
-
return t2.loading ? (e(), a("div",
|
|
2361
|
-
} }),
|
|
2373
|
+
return t2.loading ? (e(), a("div", pu, [gu, i("div", mu, [i("div", fu, [i("ul", vu, [(e(), a(w, null, j(10, (t3) => i("li", { key: l2.index }, [i("div", hu, [10 !== t3 ? (e(), a("span", bu)) : R("", true), yu])])), 64))])])]), xu])) : (e(), a("div", Ks, [i("div", Js, [i("h1", Gs, _(t2.name), 1)]), B(i("div", Zs, [i("div", Xs, [i("ul", Qs, [(e(true), a(w, null, j(t2.timeline.items, (r3, u2) => (e(), a("li", { key: u2 }, [i("div", eu, [u2 !== t2.timeline.items.length - 1 ? (e(), a("span", tu)) : R("", true), i("div", lu, [i("div", null, [i("span", { class: n([r3.iconBackground, "h-8 w-8 rounded-full flex items-center justify-center ring-4 ring-white"]) }, [o(s2, { loading: t2.loading, icon: r3.icon, "aria-hidden": "true", class: "h-5 w-5 text-white", color: "white" }, null, 8, ["loading", "icon"])], 2)]), i("div", nu, [i("div", null, [i("p", au, [i("a", { onClick: (e2) => l2.$emit("timelineEventClicked", r3.linkId), class: "font-medium text-indigo-600 hover:text-indigo-800 cursor-pointer" }, _(r3.target), 9, ou), I(" " + _(r3.content), 1)])]), i("div", ru, [i("time", { datetime: r3.datetime }, _(r3.date), 9, iu)])])])])]))), 128))])])], 512), [[L, !t2.empty]]), B(i("div", su, [i("div", uu, [i("a", { class: "cursor-pointer font-medium text-indigo-600 hover:text-indigo-500", onClick: r2[0] || (r2[0] = (e2) => l2.$emit("timelineFooterClicked", t2.timeline.id)) }, _(t2.timeline.footerText), 1)])], 512), [[L, !t2.empty]]), B(i("div", du, [o(J, { icon: d(fn), color: "gray", loading: false, size: "huge" }, null, 8, ["icon"]), cu], 512), [[L, t2.empty]])]));
|
|
2374
|
+
} }), Su = { name: "uiTopbar", props: ["navigation", "logo", "profileMenu", "brand", "accountLogo", "alerted"], components: { Disclosure: Sl, DisclosureButton: Cl, DisclosurePanel: Ol, Menu: jl, MenuButton: Rl, MenuItem: Al, MenuItems: Bl, Bars3Icon: function(t2, l2) {
|
|
2362
2375
|
return e(), a("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", "aria-hidden": "true", "data-slot": "icon" }, [i("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5" })]);
|
|
2363
|
-
}, XMarkIcon:
|
|
2364
|
-
const
|
|
2376
|
+
}, XMarkIcon: kn } }, Cu = { class: "mx-auto px-6 lg:px-8" }, Ou = { class: "flex justify-between h-20" }, Mu = { class: "flex" }, Du = { class: "-ml-2 mr-2 flex items-center lg:hidden" }, Tu = i("span", { class: "sr-only" }, "Open main menu", -1), Eu = ["src"], Iu = { class: "flex items-center" }, _u = { class: "lg:ml-4 lg:flex-shrink-0 lg:flex lg:items-center hidden" }, Pu = { class: "redCircle flex items-center justify-center h-4 w-4 bg-red-500 rounded-full absolute -top-0 -left-1" }, ju = [i("span", { class: "animate-ping absolute inline-flex h-4 w-4 bg-red-500 rounded-full opacity-75" }, null, -1)], Ru = ["src"], Bu = ["onClick"], Au = { class: "pt-2 pb-3 space-y-1" }, Lu = ["onClick"], Fu = { class: "pt-4 pb-3 border-t border-gray-200" }, Nu = { class: "flex items-center px-4 sm:px-6" }, zu = { class: "flex-shrink-0" }, $u = ["src"], Vu = { key: 0, class: "ml-3" }, Hu = { class: "text-base font-medium text-gray-800" }, Yu = { class: "text-sm font-medium text-gray-500" }, Uu = { class: "mt-3 space-y-1" }, qu = ["onClick"];
|
|
2377
|
+
const Wu = zo(Su, [["render", function(l2, r2, s2, u2, d2, c2) {
|
|
2365
2378
|
const p2 = $("Bars3Icon"), g2 = $("XMarkIcon"), m2 = $("DisclosureButton"), f2 = $("MenuButton"), v2 = $("MenuItem"), h2 = $("MenuItems"), b2 = $("Menu"), y2 = $("DisclosurePanel"), x2 = $("Disclosure");
|
|
2366
|
-
return e(), t(x2, { as: "nav", class: "bg-white shadow z-10" }, { default:
|
|
2367
|
-
}]]),
|
|
2379
|
+
return e(), t(x2, { as: "nav", class: "bg-white shadow z-10" }, { default: E(({ open: u3 }) => [i("div", Cu, [i("div", Ou, [i("div", Mu, [i("div", Du, [o(m2, { class: "inline-flex items-center justify-center p-2 rounded-md text-gray-400 hover:text-gray-500 hover:bg-gray-100 focus:outline-none focus:ring-2 focus:ring-inset focus:ring-indigo-500" }, { default: E(() => [Tu, u3 ? (e(), t(g2, { key: 1, class: "block h-6 w-6", "aria-hidden": "true" })) : (e(), t(p2, { key: 0, class: "block h-6 w-6", "aria-hidden": "true" }))]), _: 2 }, 1024)]), i("div", { class: "flex-shrink-0 flex items-center cursor-pointer", onClick: r2[0] || (r2[0] = (e2) => l2.$emit("topBarClick", "logo")) }, [i("img", { class: "h-10", src: s2.logo, alt: "Hotelinking suite product logo" }, null, 8, Eu)])]), i("div", Iu, [i("div", _u, [o(b2, { as: "div", class: "ml-3 relative" }, { default: E(() => [i("div", null, [B(o(f2, { class: "bg-white rounded-full flex text-sm focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 relative" }, { default: E(() => [B(i("div", Pu, ju, 512), [[L, s2.alerted]]), i("img", { class: "h-10 w-10 rounded-full", src: s2.accountLogo }, null, 8, Ru)]), _: 1 }, 512), [[L, s2.accountLogo]])]), o(P, { "enter-active-class": "transition ease-out duration-200", "enter-from-class": "transform opacity-0 scale-95", "enter-to-class": "transform opacity-100 scale-100", "leave-active-class": "transition ease-in duration-75", "leave-from-class": "transform opacity-100 scale-100", "leave-to-class": "transform opacity-0 scale-95" }, { default: E(() => [o(h2, { class: "origin-top-right absolute right-0 mt-2 w-48 rounded-md shadow-lg py-1 bg-white ring-1 ring-black ring-opacity-5 focus:outline-none" }, { default: E(() => [(e(true), a(w, null, j(s2.profileMenu, (a2) => (e(), t(v2, { key: a2.name }, { default: E(({ active: e2 }) => [i("p", { onClick: (e3) => l2.$emit("topBarClick", a2.id), class: n(["cursor-pointer", [e2 ? "bg-gray-100" : "", "block px-4 py-2 text-sm text-gray-700"]]) }, _(a2.name), 11, Bu)]), _: 2 }, 1024))), 128))]), _: 1 })]), _: 1 })]), _: 1 })])])])]), o(y2, { class: "lg:hidden" }, { default: E(() => [i("div", Au, [(e(true), a(w, null, j(s2.navigation, (a2) => (e(), t(m2, { as: "template", key: a2.name, class: n(["block pl-3 pr-4 py-2 border-l-4 text-base font-medium sm:pl-5 sm:pr-6", { "bg-indigo-50 border-indigo-500 text-indigo-700": a2.current && true === a2.current, "border-transparent text-gray-500 hover:bg-gray-50 hover:border-gray-300 hover:text-gray-700": !a2.current }]) }, { default: E(() => [i("p", { onClick: (e2) => l2.$emit("topBarClick", a2.id) }, _(a2.name), 9, Lu)]), _: 2 }, 1032, ["class"]))), 128))]), i("div", Fu, [i("div", Nu, [i("div", zu, [i("img", { class: "h-10 w-10 rounded-full", src: s2.accountLogo }, null, 8, $u)]), s2.brand ? (e(), a("div", Vu, [i("div", Hu, _(s2.brand.title), 1), i("div", Yu, _(s2.brand.subtitle), 1)])) : R("", true)]), i("div", Uu, [(e(true), a(w, null, j(s2.profileMenu, (n2) => (e(), t(m2, { as: "template", key: n2.name, class: "block px-4 py-2 text-base font-medium text-gray-500 hover:text-gray-800 hover:bg-gray-100 sm:px-6" }, { default: E(() => [i("p", { onClick: (e2) => l2.$emit("topBarClick", n2.id) }, _(n2.name), 9, qu)]), _: 2 }, 1024))), 128))])])]), _: 1 })]), _: 1 });
|
|
2380
|
+
}]]), Ku = { chart: { type: "bar", toolbar: { show: false }, zoom: { enabled: false } }, colors: ["#715aff"], dataLabels: { enabled: true, formatter: function(e2, t2) {
|
|
2368
2381
|
return t2.w.globals.labels[t2.dataPointIndex] + ": " + e2;
|
|
2369
|
-
} }, markers: { strokeWidth: 0, size: 4, hover: { size: 8 } }, plotOptions: { bar: { borderRadius: 0, horizontal: true, barHeight: "80%", isFunnel: true } } },
|
|
2370
|
-
const r2 = l2, s2 = t2, c2 = u(() => ({ ...s2.options, ...
|
|
2382
|
+
} }, markers: { strokeWidth: 0, size: 4, hover: { size: 8 } }, plotOptions: { bar: { borderRadius: 0, horizontal: true, barHeight: "80%", isFunnel: true } } }, Ju = { class: "chart-header flex flex-row justify-between" }, Gu = { class: "text-sm font-medium text-gray-500 truncate" }, Zu = { class: "chart-content" }, Xu = { class: "h-full w-full flex items-center justify-center flex-col" }, Qu = i("p", { class: "text-xs uppercase text-gray-300 font-bold" }, "No data", -1), ed = { class: "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow h-80" }, td = [i("div", { role: "status", class: "w-full animate-pulse h-full flex flex-col" }, [i("div", { class: "h-2.5 w-36 bg-gray-200 rounded-full mb-2.5" }), i("div", { class: "w-48 h-2 mb-6 bg-gray-200 rounded-full" }), i("div", { class: "flex flex-row justify-between items-baseline grow gap-x-1" }, [i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" })])], -1)], ld = { name: "uiChart" }, nd = Object.assign(ld, { props: { title: String, id: { type: String, default: "noChartId" }, series: { type: Object, required: true }, options: { type: Object, required: true }, loading: { type: Boolean, default: true }, empty: { type: Boolean, default: false }, range: { type: String, default: "24h" }, height: { type: Number, default: 320 } }, emits: ["selectedRange", "chartUpdated", "dataPointSelection"], setup(t2, { emit: l2 }) {
|
|
2383
|
+
const r2 = l2, s2 = t2, c2 = u(() => ({ ...s2.options, ...Ku })), p2 = u(() => s2.series), g2 = () => r2("chartUpdated"), m2 = (e2, t3, l3) => {
|
|
2371
2384
|
r2("dataPointSelection", { id: s2.id, chartContext: t3, config: l3, event: e2 });
|
|
2372
2385
|
};
|
|
2373
|
-
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div",
|
|
2374
|
-
} }),
|
|
2386
|
+
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div", Ju, [i("div", Gu, _(t2.title), 1), o(Yr, { range: t2.range, onRangeSelected: r3[0] || (r3[0] = (e2) => l3.$emit("selectedRange", { range: e2, chartId: t2.id })) }, null, 8, ["range"])]), B(i("div", Zu, [o(d(U), { type: l3.bar, series: p2.value, width: "100%", height: t2.height, options: c2.value, onUpdated: g2, onMounted: g2, onDataPointSelection: m2 }, null, 8, ["type", "series", "height", "options"])], 512), [[L, !t2.empty]]), B(i("div", Xu, [o(J, { icon: d(fn), color: "gray", loading: false, size: "huge" }, null, 8, ["icon"]), Qu], 512), [[L, t2.empty]])], 2), [[L, !t2.loading]]), B(i("div", ed, td, 512), [[L, t2.loading]])], 64));
|
|
2387
|
+
} }), ad = { class: "w-full flex flex-col items-center justify-center p-10 grow" }, od = { class: "text-2xl mt-4 font-bold" }, rd = { class: "buttons flex flex-row items-center justify-center mt-8 gap-x-1" }, id = { __name: "uiNoResults", props: { title: { type: String, required: true }, message: { type: String, required: true }, actions: { type: Array } }, emits: ["action"], setup: (l2, { emit: n2 }) => (n3, r2) => (e(), a("div", ad, [o(J, { loading: false, icon: d(fn), size: "massive", color: "gray" }, null, 8, ["icon"]), i("h2", od, _(l2.title), 1), i("p", null, _(l2.message), 1), i("div", rd, [(e(true), a(w, null, j(l2.actions, (l3, a2) => (e(), t(ee, { key: a2, loading: false, onClick: (e2) => n3.$emit("action", l3.action) }, { default: E(() => [I(_(l3.text), 1)]), _: 2 }, 1032, ["onClick"]))), 128))])])) }, sd = i("div", { class: "fixed inset-0" }, null, -1), ud = { class: "fixed inset-0 overflow-hidden" }, dd = { class: "absolute inset-0 overflow-hidden" }, cd = { class: "pointer-events-none fixed inset-y-0 right-0 flex max-w-full pl-10" }, pd = { class: "flex h-full flex-col overflow-y-scroll bg-white shadow-xl" }, gd = { class: "bg-indigo-700 px-4 py-6 sm:px-6" }, md = { class: "flex items-center justify-between" }, fd = { class: "ml-3 flex h-7 items-center" }, vd = i("span", { class: "absolute -inset-2.5" }, null, -1), hd = i("span", { class: "sr-only" }, "Close panel", -1), bd = { class: "mt-1" }, yd = { class: "text-sm text-indigo-300" }, xd = { class: "relative flex-1 px-4 py-6 sm:px-6" }, wd = { name: "uiRightSidebar" }, kd = Object.assign(wd, { props: { title: { type: String, required: true }, description: { type: String }, open: { type: Boolean, default: false } }, emits: ["closeRightBar"], setup(l2, { emit: n2 }) {
|
|
2375
2388
|
const a2 = n2;
|
|
2376
|
-
return (n3, s2) => (e(), t(d(
|
|
2377
|
-
} }),
|
|
2389
|
+
return (n3, s2) => (e(), t(d(nn), { as: "template", show: l2.open }, { default: E(() => [o(d(vl), { as: "div", class: "relative z-10", onClose: s2[1] || (s2[1] = (e2) => a2("closeRightBar")) }, { default: E(() => [sd, i("div", ud, [i("div", dd, [i("div", cd, [o(d(tn), { as: "template", enter: "transform transition ease-in-out duration-500 sm:duration-700", "enter-from": "translate-x-full", "enter-to": "translate-x-0", leave: "transform transition ease-in-out duration-500 sm:duration-700", "leave-from": "translate-x-0", "leave-to": "translate-x-full" }, { default: E(() => [o(d(hl), { class: "pointer-events-auto w-screen max-w-md" }, { default: E(() => [i("div", pd, [i("div", gd, [i("div", md, [o(d(bl), { class: "text-base font-semibold leading-6 text-white" }, { default: E(() => [I(_(l2.title), 1)]), _: 1 }), i("div", fd, [i("button", { type: "button", class: "relative rounded-md bg-indigo-700 text-indigo-200 hover:text-white outline-none", onClick: s2[0] || (s2[0] = (e2) => a2("closeRightBar")) }, [vd, hd, o(d(kn), { class: "h-6 w-6 ring-0", "aria-hidden": "true" })])])]), i("div", bd, [i("p", yd, _(l2.description), 1)])]), i("div", xd, [r(n3.$slots, "default")])])]), _: 3 })]), _: 3 })])])])]), _: 3 })]), _: 3 }, 8, ["show"]));
|
|
2390
|
+
} }), Sd = { class: "uiGallery" }, Cd = { key: 1, role: "list", class: "grid grid-cols-2 gap-x-4 gap-y-8 sm:grid-cols-3 sm:gap-x-4 lg:grid-cols-6" }, Od = { class: "group aspect-h-7 aspect-w-10 block w-full overflow-hidden rounded-lg bg-gray-100 focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2 focus-within:ring-offset-gray-100" }, Md = ["src"], Dd = ["onClick"], Td = { class: "pointer-events-none mt-2 block truncate text-sm font-medium text-gray-900" }, Ed = { class: "flex items-center justify-between" }, Id = { class: "pointer-events-none block text-sm font-medium text-gray-500" }, _d = { key: 2, role: "list", class: "grid grid-cols-2 gap-x-4 gap-y-8 sm:grid-cols-3 sm:gap-x-4 lg:grid-cols-6" }, Pd = [i("div", { class: "group aspect-h-7 aspect-w-10 block w-full overflow-hidden rounded-lg bg-gray-200 animate-pulse dark:bg-gray-200 focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2 focus-within:ring-offset-gray-100" }, null, -1), i("p", { class: "animate-pulse h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-28 mt-4" }, null, -1), i("p", { class: "animate-pulse h-2.5 bg-gray-200 rounded-full dark:bg-gray-300 w-14 mt-2" }, null, -1)], jd = { name: "uiGallery" }, Rd = Object.assign(jd, { props: { galleryId: String, gallery: Array, loading: Boolean, literals: Object }, setup(l2, { emit: n2 }) {
|
|
2378
2391
|
const r2 = n2, u2 = s(false);
|
|
2379
|
-
return (n3, s2) => (e(), a("div",
|
|
2392
|
+
return (n3, s2) => (e(), a("div", Sd, [l2.loading ? R("", true) : (e(), t(go, { key: 0, open: u2.value, modalName: "deleteAllImagesModal", title: l2.literals.modalTitle, type: "warning", actions: [{ value: "close", name: l2.literals.closeAction }, { value: `deleteGallery_${l2.galleryId}`, name: l2.literals.deleteAction }], onModalAction: s2[0] || (s2[0] = (e2) => {
|
|
2380
2393
|
var t2;
|
|
2381
2394
|
"close" !== (t2 = e2).action ? r2("modalAction", t2) : u2.value = false;
|
|
2382
|
-
}) }, { default:
|
|
2383
|
-
} }),
|
|
2395
|
+
}) }, { default: E(() => [i("p", null, _(l2.literals.modalText), 1)]), _: 1 }, 8, ["open", "title", "actions"])), l2.loading ? (e(), a("ul", _d, [(e(), a(w, null, j(4, (e2) => i("li", null, Pd)), 64))])) : (e(), a("ul", Cd, [(e(true), a(w, null, j(l2.gallery, (t2) => (e(), a("li", { key: t2.source, class: "relative" }, [i("div", Od, [i("img", { src: t2.source, alt: "", class: "pointer-events-none object-cover group-hover:opacity-75" }, null, 8, Md), i("button", { type: "button", class: "absolute inset-0 focus:outline-none", onClick: (e2) => n3.$emit("imgClicked", t2) }, null, 8, Dd)]), i("p", Td, _(t2.title), 1), i("div", Ed, [i("p", Id, _(t2.size), 1), o(J, { class: "cursor-pointer", icon: d(xn), color: "red", loading: false, onClick: (e2) => r2("deleteImage", t2) }, null, 8, ["icon", "onClick"])])]))), 128))])), l2.gallery.length > 0 && !l2.loading ? (e(), t(ee, { key: 3, onClick: s2[1] || (s2[1] = (e2) => u2.value = true), class: "mt-8", loading: false, color: "red", size: "small" }, { default: E(() => [I(_(l2.literals.deleteAllImages), 1)]), _: 1 })) : R("", true)]));
|
|
2396
|
+
} }), Bd = { class: "cursor-move mb-1 relative flex items-center space-x-3 rounded-lg border border-gray-300 bg-white p-4 shadow-sm focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2 hover:border-gray-400" }, Ad = { class: "flex flex-row items-center w-full" }, Ld = { class: "content text-sm grow" }, Fd = { class: "font-bold" }, Nd = { key: 0 }, zd = { class: "font-bold text-gray-400" }, $d = { key: 1, class: "animate-pulse" }, Vd = [z('<div class="h-16 mb-1 relative flex items-center space-x-3 rounded-lg bg-gray-200 dark:bg-gray-300 p-4 shadow-sm"></div><div class="h-16 mb-1 relative flex items-center space-x-3 rounded-lg bg-gray-200 dark:bg-gray-300 p-4 shadow-sm"></div><div class="h-16 mb-1 relative flex items-center space-x-3 rounded-lg bg-gray-200 dark:bg-gray-300 p-4 shadow-sm"></div><div class="h-16 mb-1 relative flex items-center space-x-3 rounded-lg bg-gray-200 dark:bg-gray-300 p-4 shadow-sm"></div><div class="h-16 relative flex items-center space-x-3 rounded-lg bg-gray-200 dark:bg-gray-300 p-4 shadow-sm"></div>', 5)], Hd = { name: "uiDragAndDrop" }, Yd = Object.assign(Hd, { props: { elements: { type: Array, required: true }, loading: true }, setup(l2) {
|
|
2384
2397
|
const n2 = l2;
|
|
2385
2398
|
let r2 = s(n2.elements);
|
|
2386
2399
|
return p(() => n2.elements, (e2) => {
|
|
2387
2400
|
r2.value = e2;
|
|
2388
|
-
}), (n3, s2) => l2.loading ? (e(), a("div",
|
|
2389
|
-
} }),
|
|
2401
|
+
}), (n3, s2) => l2.loading ? (e(), a("div", $d, Vd)) : (e(), t(d(q), { key: 0, modelValue: d(r2), "onUpdate:modelValue": s2[0] || (s2[0] = (e2) => H(r2) ? r2.value = e2 : r2 = e2) }, { item: E(({ item: t2 }) => [i("div", Bd, [i("div", Ad, [o(J, { icon: d(rn), loading: false, color: "gray", class: "mr-4", size: "big" }, null, 8, ["icon"]), i("div", Ld, [i("p", Fd, _(t2.name), 1), t2.description ? (e(), a("p", Nd, _(t2.description), 1)) : R("", true)]), i("div", zd, _(d(r2).indexOf(t2) + 1), 1)])])]), _: 1 }, 8, ["modelValue"]));
|
|
2402
|
+
} }), Ud = { class: "chart-header flex flex-row justify-between" }, qd = { class: "text-sm font-medium text-gray-500 truncate" }, Wd = { class: "chart-content" }, Kd = { class: "h-full w-full flex items-center justify-center flex-col" }, Jd = i("p", { class: "text-xs uppercase text-gray-300 font-bold" }, "No data", -1), Gd = { class: "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow h-80" }, Zd = [i("div", { role: "status", class: "w-full animate-pulse h-full flex flex-col" }, [i("div", { class: "h-2.5 w-36 bg-gray-200 rounded-full mb-2.5" }), i("div", { class: "w-48 h-2 mb-6 bg-gray-200 rounded-full" }), i("div", { class: "flex flex-row justify-between items-baseline grow gap-x-1" }, [i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-4/5" }), i("div", { class: "w-full bg-gray-200 rounded h-full" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" }), i("div", { class: "w-full bg-gray-200 rounded h-1/3" }), i("div", { class: "w-full bg-gray-200 rounded h-1/2" })])], -1)], Xd = { name: "uiCircleChart" }, Qd = Object.assign(Xd, { props: { title: String, id: { type: String, default: "noChartId" }, series: { type: Array, required: true }, labels: { type: Array, required: true }, loading: { type: Boolean, default: true }, empty: { type: Boolean, default: false }, range: { type: String, default: "24h" }, height: { type: Number, default: 320 } }, emits: ["selectedRange", "chartUpdated", "dataPointSelection"], setup(t2, { emit: l2 }) {
|
|
2390
2403
|
const r2 = l2, s2 = t2;
|
|
2391
2404
|
let c2 = { labels: s2.labels, chart: { toolbar: { show: false }, zoom: { enabled: false } }, colors: ["#715aff", "#00ffff", "#aba9ba"], stroke: { show: true, curve: "stepline", lineCap: "butt", width: 1, dashArray: 0 }, dataLabels: { enabled: true, dropShadow: { enabled: false } } };
|
|
2392
2405
|
const p2 = u(() => s2.series), g2 = u(() => ({ ...c2, ...s2.options })), m2 = () => r2("chartUpdated"), f2 = (e2, t3, l3) => {
|
|
2393
2406
|
r2("dataPointSelection", { id: s2.id, chartContext: t3, config: l3, event: e2 });
|
|
2394
2407
|
};
|
|
2395
|
-
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div",
|
|
2396
|
-
} }),
|
|
2408
|
+
return (l3, r3) => (e(), a(w, null, [B(i("div", { class: n(["h-[" + t2.height + "px]", "card chart apex-chart px-4 py-5 bg-white shadow rounded-lg overflow-hidden sm:p-6 flex grow"]) }, [i("div", Ud, [i("div", qd, _(t2.title), 1), o(Yr, { range: t2.range, onRangeSelected: r3[0] || (r3[0] = (e2) => l3.$emit("selectedRange", { range: e2, chartId: t2.id })) }, null, 8, ["range"])]), B(i("div", Wd, [o(d(U), { class: "flex items-center justify-center", type: "donut", series: p2.value, options: g2.value, height: t2.height, onUpdated: m2, onMounted: m2, onDataPointSelection: f2 }, null, 8, ["series", "options", "height"])], 512), [[L, !t2.empty]]), B(i("div", Kd, [o(J, { icon: d(fn), color: "gray", loading: false, size: "huge" }, null, 8, ["icon"]), Jd], 512), [[L, t2.empty]])], 2), [[L, !t2.loading]]), B(i("div", Gd, Zd, 512), [[L, t2.loading]])], 64));
|
|
2409
|
+
} }), ec = { class: "flex flex-col lg:flex-row w-full gap-y-4 gap-x-2" }, tc = { name: "uiDateRange" }, lc = Object.assign(tc, { props: { id: { type: String, required: true }, loading: { type: Boolean, default: true }, literals: { type: Object, required: true }, color: String, values: { type: Object, default: () => ({ from: "", to: "" }) }, error: String, disabled: Boolean, label: String }, setup(t2) {
|
|
2397
2410
|
let l2 = C({ from: void 0, to: void 0 });
|
|
2398
|
-
return (r2, i2) => (e(), a("div",
|
|
2399
|
-
} }),
|
|
2411
|
+
return (r2, i2) => (e(), a("div", ec, [o(Nn, { type: "date", loading: t2.loading, addOn: t2.literals.from, name: `dateFrom_${t2.id}`, color: t2.color, value: t2.values.from, error: t2.error, disabled: t2.disabled, label: t2.label, onInputChanged: i2[0] || (i2[0] = (e2) => d(l2).from = e2.value) }, null, 8, ["loading", "addOn", "name", "color", "value", "error", "disabled", "label"]), o(Nn, { class: n([{ "mt-6": t2.label && !t2.loading }, { "mt-4": t2.loading }]), type: "date", loading: t2.loading, addOn: t2.literals.to, name: `dateTo_${t2.id}`, color: t2.color, value: t2.values.to, error: t2.error, disabled: t2.disabled, onInputChanged: i2[1] || (i2[1] = (e2) => d(l2).to = e2.value) }, null, 8, ["class", "loading", "addOn", "name", "color", "value", "error", "disabled"]), o(ee, { disabled: t2.disabled, color: "primary", loading: t2.loading, class: n([{ "mt-6": t2.label && !t2.loading, "mt-4": t2.label && t2.loading }, "h-10"]), onClick: i2[2] || (i2[2] = (e2) => r2.$emit("uiDateRangeButtonClicked", d(l2))) }, { default: E(() => [I(_(t2.literals.search), 1)]), _: 1 }, 8, ["disabled", "loading", "class"])]));
|
|
2412
|
+
} }), nc = { class: "flex justify-between items-center" }, ac = { key: 0, class: "block text-sm font-medium text-gray-700" }, oc = { key: 1, class: "text-[10px] text-gray-500 uppercase justify-self-end" }, rc = { key: 1, class: "h-2 animate-pulse bg-gray-200 rounded-full dark:bg-gray-300 w-full" }, ic = { name: "uiRangeSlider" }, sc = Object.assign(ic, { props: { loading: { type: Boolean, default: true }, disabled: { type: Boolean, default: false }, min: Number, max: Number, sliderValue: [Array, Number], label: String, optional: String }, emits: ["sliderUpdated"], setup(l2, { emit: o2 }) {
|
|
2400
2413
|
const r2 = o2, u2 = s(l2.sliderValue);
|
|
2401
|
-
return (o3, s2) => (e(), a("div", null, [i("div",
|
|
2402
|
-
} }),
|
|
2403
|
-
Object.keys(
|
|
2404
|
-
e2.component(t2,
|
|
2414
|
+
return (o3, s2) => (e(), a("div", null, [i("div", nc, [l2.label ? (e(), a("label", ac, _(l2.label), 1)) : R("", true), l2.optional ? (e(), a("span", oc, _(l2.optional), 1)) : R("", true)]), i("div", { class: n([{ "mt-1": l2.label }, "pt-16 px-6 pb-6 bg-gray-50 border border-gray-300 rounded-lg shadow-sm"]) }, [l2.loading ? (e(), a("p", rc)) : (e(), t(d(W), { key: 0, modelValue: u2.value, "onUpdate:modelValue": s2[0] || (s2[0] = (e2) => u2.value = e2), min: l2.min, max: l2.max, disabled: l2.disabled, onChange: s2[1] || (s2[1] = (e2) => r2("sliderUpdated", e2)), classes: { base: "w-full h-full relative z-1 bg-gray-300 rounded", tooltip: "absolute block text-sm font-semibold whitespace-nowrap py-1 px-1.5 min-w-5 text-center text-white rounded border border-indigo-600 bg-indigo-600 transform h:-translate-x-1/2 h:left-1/2 v:-translate-y-1/2 v:top-1/2 slider-disabled:bg-gray-400 slider-disabled:border-gray-400 merge-h:translate-x-1/2 merge-h:left-auto merge-v:-translate-x-4 merge-v:top-auto tt-focus:hidden tt-focused:block tt-drag:hidden tt-dragging:block" } }, null, 8, ["modelValue", "min", "max", "disabled"]))], 2)]));
|
|
2415
|
+
} }), uc = { class: "mt-1 mb-8 text-sm text-gray-500" }, dc = { name: "uiSectionTitle" }, cc = { uiButton: ee, uiIcon: J, uiCheckbox: ue, uiDropdown: Tn, uiInput: Nn, uiInputFile: ea, uiSelect: oa, uiTag: ua, uiTextArea: va, uiToggle: ka, uiAlert: ja, uiBreadcrumbs: Ha, uiCard: Xa, uiFilter: eo, uiModal: go, uiNotification: Oo, uiTaskList: Fo, uiPriceCalendar: $r, uiChart: Qr, uiFooter: ni, uiLoadingScreen: ri, uiPagination: ki, uiSidebar: Fi, uiStats: Xi, uiStripedCard: ms, uiTable: Ns, uiTabs: Ws, uiTimeline: ku, uiTopbar: Wu, uiFunnelChartV2: nd, uiNoResults: id, uiRightSidebar: kd, uiGallery: Rd, uiDragAndDrop: Yd, uiCircleChart: Qd, uiDateRange: lc, uiRangeSlider: sc, uiSectionTitle: Object.assign(dc, { props: { title: { type: String, required: true }, description: { type: String, default: void 0 } }, setup: (t2) => (l2, o2) => (e(), a(w, null, [i("h3", { class: n(["text-lg font-medium leading-6 text-gray-900", { "mb-8": void 0 === t2.description }]) }, _(t2.title), 3), i("p", uc, _(t2.description), 1)], 64)) }) }, pc = { install(e2) {
|
|
2416
|
+
Object.keys(cc).forEach((t2) => {
|
|
2417
|
+
e2.component(t2, cc[t2]);
|
|
2405
2418
|
});
|
|
2406
2419
|
} };
|
|
2407
2420
|
export {
|
|
2408
|
-
|
|
2421
|
+
pc as default
|
|
2409
2422
|
};
|