@tempots/beatui 1.7.5 → 1.9.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/dist/{ar-Wr6gMs-M.cjs → ar-CEzAem0F.cjs} +1 -1
- package/dist/{ar-fdUqbCvM.js → ar-CQieaqsq.js} +1 -1
- package/dist/auth/index.cjs.js +1 -1
- package/dist/auth/index.es.js +1 -1
- package/dist/auth-divider-B8yr-E_b.cjs +1 -0
- package/dist/{auth-divider-D9KnNeyF.js → auth-divider-Byh5BWLc.js} +91 -88
- package/dist/better-auth/index.cjs.js +1 -1
- package/dist/better-auth/index.es.js +27 -26
- package/dist/card-BkA7Wvbh.cjs +1 -0
- package/dist/card-DX1DwGbL.js +62 -0
- package/dist/{colors-C2sgnzFH.js → colors-CyMhfbJi.js} +64 -58
- package/dist/{colors-DPCHjRMj.cjs → colors-IXZF9U-s.cjs} +1 -1
- package/dist/control-hqEuMzyI.js +343 -0
- package/dist/control-muup9GF1.cjs +1 -0
- package/dist/custom-validation-BA9iJWl_.cjs +1 -0
- package/dist/custom-validation-BOBoUwHY.js +181 -0
- package/dist/{de-C5-k5Eov.js → de-CBIwvkAH.js} +1 -1
- package/dist/{de-DZqdSEta.cjs → de-DdfxrlT3.cjs} +1 -1
- package/dist/deep-merge-8fwp1z4X.js +1346 -0
- package/dist/deep-merge-VDGE_HQD.cjs +1 -0
- package/dist/duration-input-DmsljXl3.cjs +1 -0
- package/dist/{duration-input-D4V_PHIg.js → duration-input-ZQlcqdXU.js} +32 -31
- package/dist/{editor-toolbar-group-FpOHrmtx.js → editor-toolbar-group-BNTBMJCe.js} +2 -2
- package/dist/{editor-toolbar-group-C_ft_T8D.cjs → editor-toolbar-group-DiMzqYgz.cjs} +1 -1
- package/dist/{es-h6jmoF4X.js → es--9HaEj2D.js} +1 -1
- package/dist/{es-CJgYfRap.cjs → es-DSdljxFJ.cjs} +1 -1
- package/dist/{fa-BuxK837l.js → fa-1Z-akcW7.js} +1 -1
- package/dist/{fa-BQ5PzwNY.cjs → fa-BolmeWRT.cjs} +1 -1
- package/dist/flyout-CuKFh_T7.js +151 -0
- package/dist/flyout-DC_tKaTG.cjs +1 -0
- package/dist/{fr-Bv3TG44U.cjs → fr-CODgUuoZ.cjs} +1 -1
- package/dist/{fr-BwILQ9G2.js → fr-DhHM9rou.js} +1 -1
- package/dist/{he-yC9Sc7JD.js → he-CBamXbGJ.js} +1 -1
- package/dist/{he-5LbvgMCC.cjs → he-Juw-dr28.cjs} +1 -1
- package/dist/{hi-Da7rcCpP.js → hi-DvvcX-Ra.js} +1 -1
- package/dist/{hi-YWhWcG_L.cjs → hi-R749jeg-.cjs} +1 -1
- package/dist/{index-CvU9E9wd.js → index-BfQaT5Jy.js} +104 -104
- package/dist/{index-XogEKwdt.cjs → index-Dv7nPuwA.cjs} +1 -1
- package/dist/index.cjs.js +4 -4
- package/dist/index.es.js +6713 -9831
- package/dist/{input-container-CyOgiiQD.cjs → input-container-BaWQLWB6.cjs} +1 -1
- package/dist/{input-container-8JFB11xN.js → input-container-DCS5oJ4S.js} +4 -4
- package/dist/{it-BxOIJE45.cjs → it-DT5oRZDH.cjs} +1 -1
- package/dist/{it-Yeklau78.js → it-aV6i8Qxz.js} +1 -1
- package/dist/{ja-Dxj9Q5Yd.js → ja-CuLhGnJX.js} +1 -1
- package/dist/{ja-CNhjK06P.cjs → ja-CwKaCYLB.cjs} +1 -1
- package/dist/json-schema/index.cjs.js +1 -1
- package/dist/json-schema/index.es.js +83 -79
- package/dist/json-schema-display/index.cjs.js +1 -1
- package/dist/json-schema-display/index.es.js +2 -2
- package/dist/json-structure/index.cjs.js +1 -1
- package/dist/json-structure/index.es.js +74 -72
- package/dist/{ko-DgkqcXTs.cjs → ko-Bucro9ID.cjs} +1 -1
- package/dist/{ko-gn_MsegK.js → ko-D-66BsEX.js} +1 -1
- package/dist/lexical/index.cjs.js +1 -1
- package/dist/lexical/index.es.js +5 -5
- package/dist/menu-BFLFKceF.cjs +1 -0
- package/dist/menu-BO6zqyfq.js +220 -0
- package/dist/modal-6Mq3vS5r.js +309 -0
- package/dist/modal-d77-TMc4.cjs +1 -0
- package/dist/{nl-vHNFtXXb.js → nl-CAny6wvm.js} +1 -1
- package/dist/{nl-Dy9lmbBO.cjs → nl-D7vHpehb.cjs} +1 -1
- package/dist/notice-BNGx86Yg.js +110 -0
- package/dist/notice-iF6zBMq9.cjs +1 -0
- package/dist/{oneof-branch-detection-Q_jxvJIA.js → oneof-branch-detection-Bm17RhC2.js} +27 -26
- package/dist/oneof-branch-detection-DZ4MrfBp.cjs +1 -0
- package/dist/openui/index.cjs.js +9 -0
- package/dist/openui/index.es.js +2174 -0
- package/dist/password-input-Bipt7Wsu.cjs +1 -0
- package/dist/password-input-mkRmrEPq.js +105 -0
- package/dist/{pl-BtYbtsmG.cjs → pl-CSiXoOKT.cjs} +1 -1
- package/dist/{pl-C0UdHla0.js → pl-rmZLgQ_V.js} +1 -1
- package/dist/prosemirror/index.cjs.js +1 -1
- package/dist/prosemirror/index.es.js +4 -4
- package/dist/{pt-CtNmqQ1X.cjs → pt-CJT-iq4y.cjs} +1 -1
- package/dist/{pt-DGKtfN0d.js → pt-DHnajqAi.js} +1 -1
- package/dist/{ru-CpXYLt-v.js → ru-C_E8OZNE.js} +1 -1
- package/dist/{ru-BaL_NPRU.cjs → ru-G3sr_ctV.cjs} +1 -1
- package/dist/slider-input-SLguFA0d.cjs +1 -0
- package/dist/slider-input-VYAMm7pE.js +285 -0
- package/dist/stepper-24p16Zsv.cjs +1 -0
- package/dist/stepper-TlzbfYWa.js +3222 -0
- package/dist/tailwind/preset.cjs.js +1 -1
- package/dist/tailwind/preset.es.js +38 -40
- package/dist/tailwind/vite-plugin.cjs.js +14 -12
- package/dist/tailwind/vite-plugin.es.js +317 -246
- package/dist/text-area-BdemKQ_w.cjs +1 -0
- package/dist/text-area-Br83-_PQ.js +431 -0
- package/dist/{text-input-NJypZSnE.js → text-input-ByuxdX8w.js} +5 -5
- package/dist/{text-input-DS5zlXb2.cjs → text-input-MjlUC_9u.cjs} +1 -1
- package/dist/{toolbar-BF2L6WKC.js → toolbar-CEBTTjHh.js} +1 -1
- package/dist/{toolbar-BBwfe8U9.cjs → toolbar-DWawYFFX.cjs} +1 -1
- package/dist/{tr-DwOd87oB.cjs → tr-DcxLHHTC.cjs} +1 -1
- package/dist/{tr-DIFZDFW_.js → tr-bVXwloKC.js} +1 -1
- package/dist/{translations-EwEmHe3v.cjs → translations-D3xqZUTA.cjs} +1 -1
- package/dist/{translations-BCMP-h52.js → translations-DU9wTV1y.js} +20 -19
- package/dist/{translations-5cXBrENb.js → translations-RT_UN8ny.js} +1 -1
- package/dist/{translations-BqWc0ZHz.cjs → translations-qljG2Chq.cjs} +1 -1
- package/dist/types/components/navigation/stepper.d.ts +4 -4
- package/dist/types/openui/index.d.ts +28 -0
- package/dist/types/openui/library/define-component.d.ts +15 -0
- package/dist/types/openui/library/library.d.ts +7 -0
- package/dist/types/openui/library/prompt-generator.d.ts +5 -0
- package/dist/types/openui/library/types.d.ts +33 -0
- package/dist/types/openui/parser/parser.d.ts +8 -0
- package/dist/types/openui/parser/streaming-parser.d.ts +14 -0
- package/dist/types/openui/parser/tokenizer.d.ts +9 -0
- package/dist/types/openui/parser/types.d.ts +46 -0
- package/dist/types/openui/registry/button.d.ts +148 -0
- package/dist/types/openui/registry/data.d.ts +177 -0
- package/dist/types/openui/registry/form.d.ts +65 -0
- package/dist/types/openui/registry/format.d.ts +67 -0
- package/dist/types/openui/registry/index.d.ts +9 -0
- package/dist/types/openui/registry/layout.d.ts +45 -0
- package/dist/types/openui/registry/navigation.d.ts +149 -0
- package/dist/types/openui/registry/overlay.d.ts +56 -0
- package/dist/types/openui/registry/typography.d.ts +17 -0
- package/dist/types/openui/renderer/action-context.d.ts +24 -0
- package/dist/types/openui/renderer/node-resolver.d.ts +9 -0
- package/dist/types/openui/renderer/openui-renderer.d.ts +32 -0
- package/dist/types/openui/renderer/skeleton.d.ts +2 -0
- package/dist/types/openui/streaming/from-fetch.d.ts +7 -0
- package/dist/types/openui/streaming/from-sse.d.ts +7 -0
- package/dist/types/openui/streaming/from-websocket.d.ts +10 -0
- package/dist/types/openui/streaming/types.d.ts +5 -0
- package/dist/types/tailwind/preset.d.ts +25 -4
- package/dist/types/tailwind/vite-plugin.d.ts +17 -5
- package/dist/types/tokens/colors.d.ts +87 -9
- package/dist/types/tokens/index.d.ts +7 -6
- package/dist/{ur-DBst-TXc.js → ur-Dls2qb4V.js} +1 -1
- package/dist/{ur-D9nLchps.cjs → ur-IRQoHh1E.cjs} +1 -1
- package/dist/use-form-BZ8vDYOv.cjs +2 -0
- package/dist/use-form-DsCzINfm.js +750 -0
- package/dist/utils-D3-NApSw.cjs +1 -0
- package/dist/utils-Nbh7yQ73.js +105 -0
- package/dist/{vi-Dg1aiMr5.cjs → vi-Bi9SvVCP.cjs} +1 -1
- package/dist/{vi-DQOJp32U.js → vi-C3mTzj50.js} +1 -1
- package/dist/widget-customization-BV6XB2v_.cjs +1 -0
- package/dist/widget-customization-Bso45ONQ.js +1198 -0
- package/dist/{zh-DPK4HXl2.js → zh-B4JRJBt2.js} +1 -1
- package/dist/{zh-tbwSTbmn.cjs → zh-BMU5rYu1.cjs} +1 -1
- package/package.json +31 -20
- package/dist/auth-divider-CjcrgXmq.cjs +0 -1
- package/dist/custom-validation-7por5nJN.js +0 -488
- package/dist/custom-validation-CLscGHY4.cjs +0 -1
- package/dist/deep-merge-D90SW1Ci.cjs +0 -1
- package/dist/deep-merge-DT2H9AGq.js +0 -1765
- package/dist/duration-input-4AQnQpyo.cjs +0 -1
- package/dist/menu-B60Q9j3-.cjs +0 -1
- package/dist/menu-BkqFGcXg.js +0 -366
- package/dist/notice-CQGJyZ8o.js +0 -211
- package/dist/notice-p2IqXS5-.cjs +0 -1
- package/dist/oneof-branch-detection-xDDDdYRk.cjs +0 -1
- package/dist/use-form-8NnZ-KHk.js +0 -1090
- package/dist/use-form-Dcra7GeE.cjs +0 -2
- package/dist/utils-DmEuG3Np.cjs +0 -1
- package/dist/utils-vUtP6iPG.js +0 -165
- package/dist/widget-customization-BIBva3f-.js +0 -1458
- package/dist/widget-customization-pqmtsraC.cjs +0 -1
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
import { WithElement as S, OnDispose as W, WithBrowserCtx as M, Value as q, render as z, html as g, dataAttr as A, attr as r, computedOf as _, Use as D, prop as P, aria as w, on as U, When as L, Fragment as H, coalesce as $ } from "@tempots/dom";
|
|
2
|
+
import { u as K } from "./use-animated-toggle-C3asw_Sg.js";
|
|
3
|
+
import { delayedAnimationFrame as j } from "@tempots/std";
|
|
4
|
+
import { s as R } from "./session-id-3KiilioY.js";
|
|
5
|
+
import { B as x } from "./translations-DU9wTV1y.js";
|
|
6
|
+
import { C as V } from "./control-hqEuMzyI.js";
|
|
7
|
+
import { B as O } from "./input-container-DCS5oJ4S.js";
|
|
8
|
+
const G = [
|
|
9
|
+
"a[href]",
|
|
10
|
+
"button:not([disabled])",
|
|
11
|
+
"input:not([disabled])",
|
|
12
|
+
"select:not([disabled])",
|
|
13
|
+
"textarea:not([disabled])",
|
|
14
|
+
'[tabindex]:not([tabindex="-1"])',
|
|
15
|
+
'[contenteditable="true"]',
|
|
16
|
+
"audio[controls]",
|
|
17
|
+
"video[controls]",
|
|
18
|
+
"details > summary:first-of-type",
|
|
19
|
+
"details[open]"
|
|
20
|
+
].join(", ");
|
|
21
|
+
function J(c) {
|
|
22
|
+
return Array.from(c.querySelectorAll(G)).filter(
|
|
23
|
+
(n) => {
|
|
24
|
+
const s = n;
|
|
25
|
+
return s.offsetWidth > 0 && s.offsetHeight > 0 && !s.hasAttribute("inert") && window.getComputedStyle(s).visibility !== "hidden";
|
|
26
|
+
}
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
function B(c = {}) {
|
|
30
|
+
const {
|
|
31
|
+
active: n = !0,
|
|
32
|
+
escapeDeactivates: s = !0,
|
|
33
|
+
onEscape: y,
|
|
34
|
+
initialFocus: f,
|
|
35
|
+
returnFocus: i,
|
|
36
|
+
clickOutsideDeactivates: p = !1,
|
|
37
|
+
onClickOutside: b
|
|
38
|
+
} = c;
|
|
39
|
+
return S((h) => {
|
|
40
|
+
let u = n, a = null, o = [], m = null, d = null, l = null;
|
|
41
|
+
typeof document < "u" && (a = document.activeElement);
|
|
42
|
+
const C = () => {
|
|
43
|
+
o = J(h);
|
|
44
|
+
}, k = (e) => {
|
|
45
|
+
if (u) {
|
|
46
|
+
if (s && e.key === "Escape") {
|
|
47
|
+
e.preventDefault(), y?.();
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
if (e.key === "Tab") {
|
|
51
|
+
if (C(), o.length === 0) {
|
|
52
|
+
e.preventDefault();
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
const t = o.indexOf(
|
|
56
|
+
document.activeElement
|
|
57
|
+
);
|
|
58
|
+
e.shiftKey ? t <= 0 && (e.preventDefault(), o[o.length - 1]?.focus()) : t >= o.length - 1 && (e.preventDefault(), o[0]?.focus());
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}, v = (e) => {
|
|
62
|
+
if (!u || !p) return;
|
|
63
|
+
const t = e.target;
|
|
64
|
+
h.contains(t) || b?.();
|
|
65
|
+
}, F = () => {
|
|
66
|
+
if (!u) return;
|
|
67
|
+
C();
|
|
68
|
+
let e = null;
|
|
69
|
+
typeof f == "function" ? e = f() : f ? e = f : o.length > 0 && (e = o[0]), e && (d = setTimeout(() => {
|
|
70
|
+
d = null, e?.focus();
|
|
71
|
+
}, 50)), document.addEventListener("keydown", k, !0), p && document.addEventListener("click", v, !0);
|
|
72
|
+
}, T = () => {
|
|
73
|
+
u = !1, document.removeEventListener("keydown", k, !0), document.removeEventListener("click", v, !0);
|
|
74
|
+
let e = null;
|
|
75
|
+
typeof i == "function" ? e = i() : i ? e = i : a && (e = a), e && document.body.contains(e) && (l = setTimeout(() => {
|
|
76
|
+
l = null, e?.focus();
|
|
77
|
+
}, 0));
|
|
78
|
+
};
|
|
79
|
+
return m = setTimeout(() => {
|
|
80
|
+
m = null, F();
|
|
81
|
+
}, 0), W(() => {
|
|
82
|
+
m != null && clearTimeout(m), d != null && clearTimeout(d), l != null && clearTimeout(l), T();
|
|
83
|
+
});
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
function se(c = {}) {
|
|
87
|
+
return {
|
|
88
|
+
activate: () => B({ ...c, active: !0 }),
|
|
89
|
+
deactivate: () => B({ ...c, active: !1 })
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
function N(c) {
|
|
93
|
+
return M((n) => {
|
|
94
|
+
const s = [], y = () => s.forEach((i) => i());
|
|
95
|
+
return c(({
|
|
96
|
+
effect: i = "opaque",
|
|
97
|
+
mode: p = "capturing",
|
|
98
|
+
onClickOutside: b,
|
|
99
|
+
onEscape: h,
|
|
100
|
+
content: u,
|
|
101
|
+
container: a = "body"
|
|
102
|
+
}) => {
|
|
103
|
+
a === "body" && (n = n.makePortal("body"));
|
|
104
|
+
const o = K();
|
|
105
|
+
o.listenOnClosed(y);
|
|
106
|
+
let m = () => {
|
|
107
|
+
}, d = () => {
|
|
108
|
+
};
|
|
109
|
+
const l = (e) => {
|
|
110
|
+
e.key === "Escape" && (h?.(), o.close());
|
|
111
|
+
}, C = () => {
|
|
112
|
+
b?.(), o.close();
|
|
113
|
+
}, k = (e) => {
|
|
114
|
+
m(), d(), e === "capturing" ? (document.addEventListener("keydown", l), m = () => document.removeEventListener("keydown", l), n.element.addEventListener("mousedown", C), d = () => n.element.removeEventListener("mousedown", C)) : (m = () => {
|
|
115
|
+
}, d = () => {
|
|
116
|
+
});
|
|
117
|
+
}, v = q.on(p, k);
|
|
118
|
+
s.push(v), s.push(() => {
|
|
119
|
+
o.dispose(), m(), d();
|
|
120
|
+
});
|
|
121
|
+
const T = z((() => {
|
|
122
|
+
const e = /* @__PURE__ */ new Set();
|
|
123
|
+
for (const t of n.element.querySelectorAll(
|
|
124
|
+
":scope > :not([data-overlay])"
|
|
125
|
+
))
|
|
126
|
+
t.hasAttribute("inert") ? e.add(t) : t.setAttribute("inert", "");
|
|
127
|
+
return s.push(() => {
|
|
128
|
+
for (const t of n.element.querySelectorAll(
|
|
129
|
+
":scope > :not([data-overlay])"
|
|
130
|
+
))
|
|
131
|
+
e.has(t) || t.removeAttribute("inert");
|
|
132
|
+
e.clear();
|
|
133
|
+
}), document.activeElement?.blur?.(), g.div(
|
|
134
|
+
S((t) => o.setElement(t)),
|
|
135
|
+
A("status", o.status.map(String)),
|
|
136
|
+
A("overlay", "true"),
|
|
137
|
+
r.class(
|
|
138
|
+
_(
|
|
139
|
+
i ?? "opaque",
|
|
140
|
+
p
|
|
141
|
+
)(
|
|
142
|
+
(t, E) => `bc-overlay bc-overlay--container-${a} bc-overlay--effect-${t} bc-overlay--mode-${E}`
|
|
143
|
+
)
|
|
144
|
+
),
|
|
145
|
+
u
|
|
146
|
+
);
|
|
147
|
+
})(), n.element, {
|
|
148
|
+
disposeWithParent: !0,
|
|
149
|
+
clear: !1,
|
|
150
|
+
providers: n.providers
|
|
151
|
+
});
|
|
152
|
+
s.push(T), j(() => o.open());
|
|
153
|
+
}, y);
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
function Q(c, n) {
|
|
157
|
+
const {
|
|
158
|
+
size: s = "md",
|
|
159
|
+
dismissable: y = !0,
|
|
160
|
+
showCloseButton: f = !0,
|
|
161
|
+
onClose: i,
|
|
162
|
+
overlayEffect: p = "opaque",
|
|
163
|
+
container: b = "body",
|
|
164
|
+
position: h = "center"
|
|
165
|
+
} = c;
|
|
166
|
+
return N((u, a) => {
|
|
167
|
+
let o = () => {
|
|
168
|
+
};
|
|
169
|
+
return n((l) => {
|
|
170
|
+
o = a;
|
|
171
|
+
const C = P("capturing");
|
|
172
|
+
q.on(y, (t) => {
|
|
173
|
+
C.set(t ? "capturing" : "non-capturing");
|
|
174
|
+
});
|
|
175
|
+
const k = _(
|
|
176
|
+
l.header != null,
|
|
177
|
+
f
|
|
178
|
+
)((t, E) => t || E), v = R("modal"), F = `${v}-header`, T = `${v}-body`, e = g.div(
|
|
179
|
+
r.class(
|
|
180
|
+
_(
|
|
181
|
+
s,
|
|
182
|
+
h
|
|
183
|
+
)(
|
|
184
|
+
(t, E) => `bc-modal bc-modal--size-${t} bc-modal--container-${b} bc-modal--position-${E}`
|
|
185
|
+
)
|
|
186
|
+
),
|
|
187
|
+
// Essential ARIA attributes for modal dialog
|
|
188
|
+
r.role("dialog"),
|
|
189
|
+
w.modal(!0),
|
|
190
|
+
...l.header ? [w.labelledby(F)] : [],
|
|
191
|
+
w.describedby(T),
|
|
192
|
+
r.tabindex(-1),
|
|
193
|
+
// Make modal focusable for initial focus
|
|
194
|
+
r.id(v),
|
|
195
|
+
A("focus-trap", "true"),
|
|
196
|
+
// Mark as focus trap container
|
|
197
|
+
U.mousedown((t) => t.stopPropagation()),
|
|
198
|
+
// Prevent overlay click-outside when clicking modal content
|
|
199
|
+
// Focus trap implementation
|
|
200
|
+
B({
|
|
201
|
+
escapeDeactivates: !1,
|
|
202
|
+
// Let Overlay handle escape key
|
|
203
|
+
initialFocus: () => {
|
|
204
|
+
const t = document.getElementById(v);
|
|
205
|
+
if (!t) return null;
|
|
206
|
+
const E = t.querySelector(
|
|
207
|
+
'[aria-label="Close modal"]'
|
|
208
|
+
);
|
|
209
|
+
if (E) return E;
|
|
210
|
+
const I = t.querySelector(
|
|
211
|
+
'button, input, select, textarea, [tabindex]:not([tabindex="-1"])'
|
|
212
|
+
);
|
|
213
|
+
return I || t;
|
|
214
|
+
}
|
|
215
|
+
}),
|
|
216
|
+
// Modal content container
|
|
217
|
+
g.div(
|
|
218
|
+
r.class("bc-modal__content"),
|
|
219
|
+
// Header section
|
|
220
|
+
L(
|
|
221
|
+
k,
|
|
222
|
+
() => g.div(
|
|
223
|
+
r.class("bc-modal__header"),
|
|
224
|
+
g.div(
|
|
225
|
+
r.class("bc-modal__title"),
|
|
226
|
+
...l.header ? [r.id(F)] : [],
|
|
227
|
+
l.header
|
|
228
|
+
),
|
|
229
|
+
L(
|
|
230
|
+
f,
|
|
231
|
+
() => D(
|
|
232
|
+
x,
|
|
233
|
+
(t) => V({
|
|
234
|
+
size: "sm",
|
|
235
|
+
label: t.$.closeModal,
|
|
236
|
+
onClick: () => {
|
|
237
|
+
o(), a();
|
|
238
|
+
}
|
|
239
|
+
})
|
|
240
|
+
)
|
|
241
|
+
)
|
|
242
|
+
)
|
|
243
|
+
),
|
|
244
|
+
// Body section
|
|
245
|
+
g.div(r.class("bc-modal__body"), r.id(T), l.body),
|
|
246
|
+
// Footer section
|
|
247
|
+
l.footer && g.div(r.class("bc-modal__footer"), l.footer)
|
|
248
|
+
)
|
|
249
|
+
);
|
|
250
|
+
u({
|
|
251
|
+
mode: C,
|
|
252
|
+
effect: p ?? "opaque",
|
|
253
|
+
container: b,
|
|
254
|
+
content: e,
|
|
255
|
+
onClickOutside: () => {
|
|
256
|
+
i?.(), a();
|
|
257
|
+
},
|
|
258
|
+
onEscape: () => {
|
|
259
|
+
i?.(), a();
|
|
260
|
+
}
|
|
261
|
+
});
|
|
262
|
+
}, () => {
|
|
263
|
+
o(), a();
|
|
264
|
+
});
|
|
265
|
+
});
|
|
266
|
+
}
|
|
267
|
+
function le(c, n) {
|
|
268
|
+
const { confirmText: s, cancelText: y, onConfirm: f, onCancel: i, ...p } = c;
|
|
269
|
+
return D(
|
|
270
|
+
x,
|
|
271
|
+
(b) => Q({ showCloseButton: !1, ...p }, (h, u) => {
|
|
272
|
+
const a = () => {
|
|
273
|
+
f?.(), u();
|
|
274
|
+
}, o = () => {
|
|
275
|
+
i?.(), u();
|
|
276
|
+
};
|
|
277
|
+
return n((d) => {
|
|
278
|
+
h({
|
|
279
|
+
body: d,
|
|
280
|
+
footer: H(
|
|
281
|
+
r.class("bc-modal__actions"),
|
|
282
|
+
O(
|
|
283
|
+
{
|
|
284
|
+
variant: "outline",
|
|
285
|
+
onClick: o
|
|
286
|
+
},
|
|
287
|
+
$(y, b.$.cancel)
|
|
288
|
+
),
|
|
289
|
+
O(
|
|
290
|
+
{
|
|
291
|
+
color: "primary",
|
|
292
|
+
variant: "filled",
|
|
293
|
+
onClick: a
|
|
294
|
+
},
|
|
295
|
+
$(s, b.$.confirm)
|
|
296
|
+
)
|
|
297
|
+
)
|
|
298
|
+
});
|
|
299
|
+
}, u);
|
|
300
|
+
})
|
|
301
|
+
);
|
|
302
|
+
}
|
|
303
|
+
export {
|
|
304
|
+
le as C,
|
|
305
|
+
B as F,
|
|
306
|
+
Q as M,
|
|
307
|
+
N as O,
|
|
308
|
+
se as u
|
|
309
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("@tempots/dom"),O=require("./use-animated-toggle-cKcuItmz.cjs"),B=require("@tempots/std"),L=require("./session-id-B5lJMzbB.cjs"),w=require("./translations-D3xqZUTA.cjs"),$=require("./control-muup9GF1.cjs"),A=require("./input-container-BaWQLWB6.cjs"),S=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]',"audio[controls]","video[controls]","details > summary:first-of-type","details[open]"].join(", ");function D(c){return Array.from(c.querySelectorAll(S)).filter(a=>{const s=a;return s.offsetWidth>0&&s.offsetHeight>0&&!s.hasAttribute("inert")&&window.getComputedStyle(s).visibility!=="hidden"})}function F(c={}){const{active:a=!0,escapeDeactivates:s=!0,onEscape:v,initialFocus:f,returnFocus:i,clickOutsideDeactivates:p=!1,onClickOutside:b}=c;return e.WithElement(y=>{let u=a,r=null,n=[],m=null,d=null,l=null;typeof document<"u"&&(r=document.activeElement);const E=()=>{n=D(y)},g=t=>{if(u){if(s&&t.key==="Escape"){t.preventDefault(),v?.();return}if(t.key==="Tab"){if(E(),n.length===0){t.preventDefault();return}const o=n.indexOf(document.activeElement);t.shiftKey?o<=0&&(t.preventDefault(),n[n.length-1]?.focus()):o>=n.length-1&&(t.preventDefault(),n[0]?.focus())}}},h=t=>{if(!u||!p)return;const o=t.target;y.contains(o)||b?.()},T=()=>{if(!u)return;E();let t=null;typeof f=="function"?t=f():f?t=f:n.length>0&&(t=n[0]),t&&(d=setTimeout(()=>{d=null,t?.focus()},50)),document.addEventListener("keydown",g,!0),p&&document.addEventListener("click",h,!0)},k=()=>{u=!1,document.removeEventListener("keydown",g,!0),document.removeEventListener("click",h,!0);let t=null;typeof i=="function"?t=i():i?t=i:r&&(t=r),t&&document.body.contains(t)&&(l=setTimeout(()=>{l=null,t?.focus()},0))};return m=setTimeout(()=>{m=null,T()},0),e.OnDispose(()=>{m!=null&&clearTimeout(m),d!=null&&clearTimeout(d),l!=null&&clearTimeout(l),k()})})}function W(c={}){return{activate:()=>F({...c,active:!0}),deactivate:()=>F({...c,active:!1})}}function I(c){return e.WithBrowserCtx(a=>{const s=[],v=()=>s.forEach(i=>i());return c(({effect:i="opaque",mode:p="capturing",onClickOutside:b,onEscape:y,content:u,container:r="body"})=>{r==="body"&&(a=a.makePortal("body"));const n=O.useAnimatedElementToggle();n.listenOnClosed(v);let m=()=>{},d=()=>{};const l=t=>{t.key==="Escape"&&(y?.(),n.close())},E=()=>{b?.(),n.close()},g=t=>{m(),d(),t==="capturing"?(document.addEventListener("keydown",l),m=()=>document.removeEventListener("keydown",l),a.element.addEventListener("mousedown",E),d=()=>a.element.removeEventListener("mousedown",E)):(m=()=>{},d=()=>{})},h=e.Value.on(p,g);s.push(h),s.push(()=>{n.dispose(),m(),d()});const T=()=>{const t=new Set;for(const o of a.element.querySelectorAll(":scope > :not([data-overlay])"))o.hasAttribute("inert")?t.add(o):o.setAttribute("inert","");return s.push(()=>{for(const o of a.element.querySelectorAll(":scope > :not([data-overlay])"))t.has(o)||o.removeAttribute("inert");t.clear()}),document.activeElement?.blur?.(),e.html.div(e.WithElement(o=>n.setElement(o)),e.dataAttr("status",n.status.map(String)),e.dataAttr("overlay","true"),e.attr.class(e.computedOf(i??"opaque",p)((o,C)=>`bc-overlay bc-overlay--container-${r} bc-overlay--effect-${o} bc-overlay--mode-${C}`)),u)},k=e.render(T(),a.element,{disposeWithParent:!0,clear:!1,providers:a.providers});s.push(k),B.delayedAnimationFrame(()=>n.open())},v)})}function _(c,a){const{size:s="md",dismissable:v=!0,showCloseButton:f=!0,onClose:i,overlayEffect:p="opaque",container:b="body",position:y="center"}=c;return I((u,r)=>{let n=()=>{};return a(l=>{n=r;const E=e.prop("capturing");e.Value.on(v,o=>{E.set(o?"capturing":"non-capturing")});const g=e.computedOf(l.header!=null,f)((o,C)=>o||C),h=L.sessionId("modal"),T=`${h}-header`,k=`${h}-body`,t=e.html.div(e.attr.class(e.computedOf(s,y)((o,C)=>`bc-modal bc-modal--size-${o} bc-modal--container-${b} bc-modal--position-${C}`)),e.attr.role("dialog"),e.aria.modal(!0),...l.header?[e.aria.labelledby(T)]:[],e.aria.describedby(k),e.attr.tabindex(-1),e.attr.id(h),e.dataAttr("focus-trap","true"),e.on.mousedown(o=>o.stopPropagation()),F({escapeDeactivates:!1,initialFocus:()=>{const o=document.getElementById(h);if(!o)return null;const C=o.querySelector('[aria-label="Close modal"]');if(C)return C;const q=o.querySelector('button, input, select, textarea, [tabindex]:not([tabindex="-1"])');return q||o}}),e.html.div(e.attr.class("bc-modal__content"),e.When(g,()=>e.html.div(e.attr.class("bc-modal__header"),e.html.div(e.attr.class("bc-modal__title"),...l.header?[e.attr.id(T)]:[],l.header),e.When(f,()=>e.Use(w.BeatUII18n,o=>$.CloseButton({size:"sm",label:o.$.closeModal,onClick:()=>{n(),r()}}))))),e.html.div(e.attr.class("bc-modal__body"),e.attr.id(k),l.body),l.footer&&e.html.div(e.attr.class("bc-modal__footer"),l.footer)));u({mode:E,effect:p??"opaque",container:b,content:t,onClickOutside:()=>{i?.(),r()},onEscape:()=>{i?.(),r()}})},()=>{n(),r()})})}function x(c,a){const{confirmText:s,cancelText:v,onConfirm:f,onCancel:i,...p}=c;return e.Use(w.BeatUII18n,b=>_({showCloseButton:!1,...p},(y,u)=>{const r=()=>{f?.(),u()},n=()=>{i?.(),u()};return a(d=>{y({body:d,footer:e.Fragment(e.attr.class("bc-modal__actions"),A.Button({variant:"outline",onClick:n},e.coalesce(v,b.$.cancel)),A.Button({color:"primary",variant:"filled",onClick:r},e.coalesce(s,b.$.confirm)))})},u)}))}exports.ConfirmModal=x;exports.FocusTrap=F;exports.Modal=_;exports.Overlay=I;exports.useFocusTrap=W;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./translations-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./translations-D3xqZUTA.cjs"),r={loadingExtended:"Laden, even geduld",loadingShort:"Laden...",locale:"Landinstelling",iconDescription:"Pictogram",loadingIcon:"Laadpictogram",failedToLoadIcon:"Pictogram laden mislukt",editLabel:"Bewerken",selectOne:"Selecteer een",selectNone:"Geen",selectMany:"Selecteer meerdere",noResults:"Geen resultaten",passwordPlaceholderText:"Geheim wachtwoord",togglePasswordVisibility:"Wachtwoord zichtbaarheid wisselen",toggleMenu:"Menu wisselen",toggleAside:"Zijpaneel wisselen",mainNavigation:"Hoofdnavigatie",sidebar:"Zijbalk",closeDrawer:"Lade sluiten",closeModal:"Modaal sluiten",confirm:"Bevestigen",cancel:"Annuleren",addLabel:"Toevoegen",removeItem:"Item verwijderen",currentLocale:"Nederlands",ar:"Arabisch",de:"Duits",en:"Engels",es:"Spaans",fr:"Frans",hi:"Hindi",it:"Italiaans",ja:"Japans",ko:"Koreaans",nl:"Nederlands",pl:"Pools",pt:"Portugees",ru:"Russisch",tr:"Turks",vi:"Vietnamees",zh:"Chinees",he:"Hebreeuws",fa:"Perzisch",ur:"Urdu",emailPlaceholderText:"Voer je e-mail in",incrementValue:"Waarde verhogen",decrementValue:"Waarde verlagen",dropZoneInstructions:e=>e?"Klik om te kiezen of sleep bestanden hierheen, of druk op Enter of Spatie om bestandskiezer te openen":"Sleep bestanden hierheen",fileSizeUnits:["Bytes","KB","MB","GB","TB"],removeFile:"Bestand verwijderen",clearAllFiles:"Alle bestanden wissen",clearValue:"Waarde wissen",dateRangeStart:"Start",dateRangeEnd:"End",dateRangeNoLimit:"No limit",dateRangeSelectDate:"Select date",unknownType:"Onbekend type",filesInputInstructions:(e,n,t)=>{let a=e==null||e>1?"Klik om te kiezen of sleep bestanden hierheen":"Klik om te kiezen of sleep een bestand hierheen";if(e||n){const l=[];if(e!=null&&e>1&&l.push(`tot ${e} bestanden`),n&&t){const o=i.formatFileSize(n,{units:t});l.push(`max ${o} elk`)}l.length>0&&(a+=` (${l.join(", ")})`)}return a},paginationLabel:"Paginering",paginationRange:(e,n,t,a)=>a>t?`Rijen ${e} tot ${n} van ${t} van ${a}`:`Rijen ${e} tot ${n} van ${t}`,firstPage:"Eerste pagina",previousPage:"Vorige pagina",nextPage:"Volgende pagina",lastPage:"Laatste pagina",breadcrumbs:"Kruimelpad",commandPalette:"Opdrachtenpalet",typeACommand:"Typ een opdracht...",noResultsFound:"Geen resultaten gevonden",noMatchingCommands:"Geen overeenkomende opdrachten",appearanceSystem:"Systeem",appearanceLight:"Licht",appearanceDark:"Donker",ok:"OK",changeTypeConfirmation:"Het wijzigen van het type wist de huidige waarde. Doorgaan?",notifications:"Meldingen",markAllAsRead:"Alles als gelezen markeren",noNotifications:"Geen meldingen",schemaConflictsDetected:"Schemaconflicten gedetecteerd",schemaViolationsDetected:"Schemaschendingen gedetecteerd",properties:"Eigenschappen",uploading:"Uploaden...",dropFilesOrBrowse:"Sleep bestanden hierheen of klik om te bladeren",acceptedTypes:e=>`Toegestane typen: ${e}`,enterUrlPrompt:"Voer URL in:",exceeded:"(overschreden)",pdfPreview:"PDF-voorbeeld",lexical:{fontFamily:"Lettertype",fontSize:"Lettergrootte",lineHeight:"Regelhoogte",fontColor:"Letterkleur",highlightColor:"Markeringskleur",backgroundColor:"Achtergrondkleur",bold:"Vet",italic:"Cursief",underline:"Onderstrepen",strikethrough:"Doorhalen",code:"Code",clearFormatting:"Opmaak wissen",normal:"Normaal",heading:e=>`Kop ${e}`,bulletList:"Opsommingstekens",orderedList:"Genummerde lijst",checkList:"Controlelijst",indent:"Inspringen",outdent:"Uitspringen",blockquote:"Citaat",codeBlock:"Codeblok",horizontalRule:"Horizontale lijn",insertTable:"Tabel invoegen",link:"Link",undo:"Ongedaan maken",redo:"Opnieuw",cut:"Knippen",copy:"Kopiëren",paste:"Plakken",defaultOption:"Standaard",slashCommands:"Schuine-streepopdrachten",noCommandsFound:"Geen opdrachten gevonden",changeBlockType:"Bloktype wijzigen",blockTypes:"Bloktypen",enterUrl:"Voer URL in:",tableActions:"Table actions",insertRowAbove:"Insert row above",insertRowBelow:"Insert row below",insertColumnLeft:"Insert column left",insertColumnRight:"Insert column right",deleteRow:"Delete row",deleteColumn:"Delete column",deleteTable:"Delete table"},dataTable:{sortAscending:"Oplopend sorteren",sortDescending:"Aflopend sorteren",clearSort:"Sortering wissen",filterPlaceholder:"Filteren...",clearFilter:"Filter wissen",selectAll:"Alles selecteren",deselectAll:"Alles deselecteren",selectedCount:e=>`${e} geselecteerd`,resetAll:"Alles resetten",noResults:"Geen resultaten gevonden",loading:"Laden...",filterPanelAddCondition:"Voorwaarde toevoegen",filterPanelApply:"Toepassen",filterPanelClear:"Filters wissen",filterPanelAnd:"EN",filterPanelOr:"OF",filterPanelContains:"Bevat",filterPanelNotContains:"Bevat niet",filterPanelEquals:"Is gelijk aan",filterPanelNotEquals:"Is niet gelijk aan",filterPanelStartsWith:"Begint met",filterPanelEndsWith:"Eindigt met",filterPanelIsNull:"Is leeg",filterPanelIsNotNull:"Is niet leeg",filterPanelGt:"Groter dan",filterPanelGte:"Groter of gelijk",filterPanelLt:"Kleiner dan",filterPanelLte:"Kleiner of gelijk",filterPanelBetween:"Tussen",filterPanelValuePlaceholder:"Waarde...",sortMultiHint:"Houd Shift ingedrukt om meerdere kolommen te sorteren",columnVisibility:"Kolommen",showAllColumns:"Alles weergeven",menuSortAsc:"Oplopend sorteren",menuSortDesc:"Aflopend sorteren",menuClearSort:"Sortering wissen",menuHideColumn:"Kolom verbergen",menuChooseColumns:"Kolommen kiezen",menuResetColumns:"Kolommen herstellen",menuFilter:"Filteren",rowCount:(e,n)=>`Rijen: ${e} Totaal rijen: ${n}`,filterTagsPlaceholder:"Waarden selecteren...",groupCount:e=>`${e} items`,collapseGroup:"Groep inklappen",expandGroup:"Groep uitklappen",describeFilter:{textContains:(e,n)=>`${e} bevat "${n}"`,textNotContains:(e,n)=>`${e} bevat niet "${n}"`,textEquals:(e,n)=>`${e} is gelijk aan "${n}"`,textNotEquals:(e,n)=>`${e} is niet gelijk aan "${n}"`,textStartsWith:(e,n)=>`${e} begint met "${n}"`,textEndsWith:(e,n)=>`${e} eindigt met "${n}"`,compareEq:(e,n)=>`${e} = ${n}`,compareNeq:(e,n)=>`${e} ≠ ${n}`,compareGt:(e,n)=>`${e} > ${n}`,compareGte:(e,n)=>`${e} ≥ ${n}`,compareLt:(e,n)=>`${e} < ${n}`,compareLte:(e,n)=>`${e} ≤ ${n}`,rangeBetween:(e,n,t)=>`${e} tussen ${n} en ${t}`,rangeGte:(e,n)=>`${e} ≥ ${n}`,rangeLte:(e,n)=>`${e} ≤ ${n}`,setIn:(e,n)=>`${e} in [${n}]`,setNotIn:(e,n)=>`${e} niet in [${n}]`,booleanIs:(e,n)=>`${e} is ${n}`,isNull:e=>`${e} is leeg`,isNotNull:e=>`${e} is niet leeg`,compositeAnd:e=>e.join(" EN "),compositeOr:e=>e.join(" OF ")}},prosemirror:{bold:"Bold",italic:"Italic",code:"Code",link:"Link",removeLink:"Remove Link",heading:e=>`Heading ${e}`,bulletList:"Bullet List",orderedList:"Ordered List",blockquote:"Blockquote",codeBlock:"Code Block",horizontalRule:"Horizontal Rule",linkUrlPlaceholder:"https://example.com"},carousel:{label:"Carrousel",previousSlide:"Vorige dia",nextSlide:"Volgende dia",slideNavigation:"Dia-navigatie",slideOfTotal:(e,n)=>`Dia ${e} van ${n}`,goToSlide:e=>`Ga naar dia ${e}`},datePicker:{label:"Datumkiezer",previousYear:"Vorig jaar",previousMonth:"Vorige maand",selectMonth:"Maand selecteren",selectYear:"Jaar selecteren",nextMonth:"Volgende maand",nextYear:"Volgend jaar",previousYears:e=>`Vorige ${e} jaar`,nextYears:e=>`Volgende ${e} jaar`,dateRangePickerLabel:"Datumbereikkiezer",monthNames:["Januari","Februari","Maart","April","Mei","Juni","Juli","Augustus","September","Oktober","November","December"],shortMonthNames:["Jan","Feb","Mrt","Apr","Mei","Jun","Jul","Aug","Sep","Okt","Nov","Dec"],dayNames:["Zo","Ma","Di","Wo","Do","Vr","Za"]},timePicker:{label:"Tijdkiezer",hoursLabel:"HH",minutesLabel:"MM",secondsLabel:"SS",selectHours:"Uren selecteren",selectMinutes:"Minuten selecteren",selectSeconds:"Seconden selecteren",selectPeriod:"AM/PM selecteren",nowLabel:"Nu"},timeSelectTime:"Tijd selecteren",dateTimeSelectDateTime:"Datum en tijd selecteren",colorPicker:{hue:"Tint",saturation:"Verzadiging",lightness:"Helderheid",alpha:"Alpha",red:"Rood",green:"Groen",blue:"Blauw",hex:"Hex",whiteness:"Witheid",blackness:"Zwartheid",chroma:"Chroma"},spotlight:{placeholder:"Zoeken...",noResults:"Geen resultaten gevonden",recentItems:"Recent",close:"Sluiten"},virtualList:{listLabel:"Scrollbare lijst"},stepper:{step:"Stap",stepOfTotal:(e,n)=>`Stap ${e} van ${n}`,completed:"Voltooid",next:"Volgende",previous:"Vorige",complete:"Voltooien"},sortableList:{dragHandle:"Sleep om te herordenen"},transferList:{available:"Beschikbaar",selected:"Geselecteerd",moveRight:"Naar geselecteerd verplaatsen",moveLeft:"Naar beschikbaar verplaatsen",moveAllRight:"Alles naar geselecteerd",moveAllLeft:"Alles naar beschikbaar",searchAvailable:"Beschikbare items doorzoeken…",searchSelected:"Geselecteerde items doorzoeken…"},copyButton:{copied:"Gekopieerd!",copyToClipboard:"Kopiëren naar klembord"},numberStepper:{increment:"Verhogen",decrement:"Verlagen",value:"Waarde"},statCard:{trendUp:"Stijgend",trendDown:"Dalend",trendFlat:"Geen verandering"},otpInputLabel:"Eenmalig wachtwoord invoer",otpDigitLabel:(e,n)=>`Cijfer ${e} van ${n}`,scrollableGridView:"Scrollbaar rasteroverzicht",onboardingTour:{label:"Begeleide rondleiding",stepIndicator:(e,n)=>`Stap ${e} van ${n}`,skip:"Overslaan",previous:"Vorige",next:"Volgende",finish:"Voltooien"},searchPlaceholder:"Zoeken",pdfPageViewer:{loading:"PDF laden...",loadFailed:"PDF laden mislukt",invalidPdf:"Ongeldig PDF-bestand",pageOutOfRange:(e,n)=>`Pagina ${e} valt buiten bereik (1-${n})`,renderFailed:"PDF-pagina weergeven mislukt"}};exports.default=r;exports.nl=r;
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { prop as C, When as g, Value as o, computedOf as f, Use as N, html as a, attr as i, Unless as T, Ensure as U } from "@tempots/dom";
|
|
2
|
+
import { B as $, I as k } from "./translations-DU9wTV1y.js";
|
|
3
|
+
import { C as z } from "./control-hqEuMzyI.js";
|
|
4
|
+
function V(n) {
|
|
5
|
+
switch (n) {
|
|
6
|
+
case "success":
|
|
7
|
+
return "material-symbols:check-circle-outline";
|
|
8
|
+
case "warning":
|
|
9
|
+
return "material-symbols:warning-outline";
|
|
10
|
+
case "danger":
|
|
11
|
+
return "material-symbols:error-outline";
|
|
12
|
+
default:
|
|
13
|
+
return "material-symbols:info-outline";
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
function j(n) {
|
|
17
|
+
switch (n) {
|
|
18
|
+
case "success":
|
|
19
|
+
return "success";
|
|
20
|
+
case "warning":
|
|
21
|
+
return "warning";
|
|
22
|
+
case "danger":
|
|
23
|
+
return "danger";
|
|
24
|
+
default:
|
|
25
|
+
return "info";
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
function D(n, l, u, c) {
|
|
29
|
+
const t = [
|
|
30
|
+
"bc-notice",
|
|
31
|
+
`bc-notice--${n}`,
|
|
32
|
+
`bc-notice--tone-${l}`
|
|
33
|
+
];
|
|
34
|
+
return u && t.push("bc-notice--dismissible"), c && c.length > 0 && t.push(c), t.join(" ");
|
|
35
|
+
}
|
|
36
|
+
function R({
|
|
37
|
+
variant: n = "info",
|
|
38
|
+
tone: l = "subtle",
|
|
39
|
+
role: u,
|
|
40
|
+
title: c,
|
|
41
|
+
icon: t,
|
|
42
|
+
closable: v = !1,
|
|
43
|
+
onClose: b,
|
|
44
|
+
class: h
|
|
45
|
+
}, ..._) {
|
|
46
|
+
const d = C(!0);
|
|
47
|
+
return g(d, () => {
|
|
48
|
+
const p = o.map(
|
|
49
|
+
v,
|
|
50
|
+
(s) => !!s || b != null
|
|
51
|
+
), r = o.map(n, (s) => s ?? "info"), w = o.map(l, (s) => s ?? "subtle"), y = f(
|
|
52
|
+
u,
|
|
53
|
+
r
|
|
54
|
+
)(
|
|
55
|
+
(s, e) => s ?? (e === "danger" ? "alert" : "status")
|
|
56
|
+
);
|
|
57
|
+
return N(
|
|
58
|
+
$,
|
|
59
|
+
(s) => a.div(
|
|
60
|
+
i.class(
|
|
61
|
+
f(
|
|
62
|
+
r,
|
|
63
|
+
w,
|
|
64
|
+
p,
|
|
65
|
+
h
|
|
66
|
+
)((e, m, I, B) => D(e, m, I, B))
|
|
67
|
+
),
|
|
68
|
+
// Accessibility role mapping (always defined)
|
|
69
|
+
i.role(o.map(y, (e) => e)),
|
|
70
|
+
T(
|
|
71
|
+
o.map(t, (e) => e === !1),
|
|
72
|
+
() => a.div(
|
|
73
|
+
i.class("bc-notice__icon"),
|
|
74
|
+
k({
|
|
75
|
+
icon: f(
|
|
76
|
+
t,
|
|
77
|
+
r
|
|
78
|
+
)(
|
|
79
|
+
(e, m) => e === void 0 ? V(m) : String(e)
|
|
80
|
+
),
|
|
81
|
+
size: "md",
|
|
82
|
+
color: o.map(r, j)
|
|
83
|
+
})
|
|
84
|
+
)
|
|
85
|
+
),
|
|
86
|
+
a.div(
|
|
87
|
+
i.class("bc-notice__body"),
|
|
88
|
+
U(
|
|
89
|
+
c,
|
|
90
|
+
(e) => a.div(i.class("bc-notice__title"), e)
|
|
91
|
+
),
|
|
92
|
+
a.div(i.class("bc-notice__content"), ..._)
|
|
93
|
+
),
|
|
94
|
+
g(
|
|
95
|
+
p,
|
|
96
|
+
() => z({
|
|
97
|
+
size: "xs",
|
|
98
|
+
label: s.$.closeModal,
|
|
99
|
+
onClick: () => {
|
|
100
|
+
d.set(!1), b?.();
|
|
101
|
+
}
|
|
102
|
+
})
|
|
103
|
+
)
|
|
104
|
+
)
|
|
105
|
+
);
|
|
106
|
+
});
|
|
107
|
+
}
|
|
108
|
+
export {
|
|
109
|
+
R as N
|
|
110
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("@tempots/dom"),f=require("./translations-D3xqZUTA.cjs"),w=require("./control-muup9GF1.cjs");function y(s){switch(s){case"success":return"material-symbols:check-circle-outline";case"warning":return"material-symbols:warning-outline";case"danger":return"material-symbols:error-outline";default:return"material-symbols:info-outline"}}function I(s){switch(s){case"success":return"success";case"warning":return"warning";case"danger":return"danger";default:return"info"}}function q(s,i,r,a){const c=["bc-notice",`bc-notice--${s}`,`bc-notice--tone-${i}`];return r&&c.push("bc-notice--dismissible"),a&&a.length>0&&c.push(a),c.join(" ")}function B({variant:s="info",tone:i="subtle",role:r,title:a,icon:c,closable:b=!1,onClose:u,class:h},...p){const m=e.prop(!0);return e.When(m,()=>{const d=e.Value.map(b,n=>!!n||u!=null),o=e.Value.map(s,n=>n??"info"),g=e.Value.map(i,n=>n??"subtle"),v=e.computedOf(r,o)((n,t)=>n??(t==="danger"?"alert":"status"));return e.Use(f.BeatUII18n,n=>e.html.div(e.attr.class(e.computedOf(o,g,d,h)((t,l,_,V)=>q(t,l,_,V))),e.attr.role(e.Value.map(v,t=>t)),e.Unless(e.Value.map(c,t=>t===!1),()=>e.html.div(e.attr.class("bc-notice__icon"),f.Icon({icon:e.computedOf(c,o)((t,l)=>t===void 0?y(l):String(t)),size:"md",color:e.Value.map(o,I)}))),e.html.div(e.attr.class("bc-notice__body"),e.Ensure(a,t=>e.html.div(e.attr.class("bc-notice__title"),t)),e.html.div(e.attr.class("bc-notice__content"),...p)),e.When(d,()=>w.CloseButton({size:"xs",label:n.$.closeModal,onClick:()=>{m.set(!1),u?.()}}))))})}exports.Notice=B;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { Validation as z, upperCaseFirst as B, humanize as W } from "@tempots/std";
|
|
2
2
|
import { attr as c, prop as _, html as h, computedOf as g, aria as F, on as w } from "@tempots/dom";
|
|
3
|
-
import {
|
|
3
|
+
import { C as H } from "./card-DX1DwGbL.js";
|
|
4
|
+
import { g as J } from "./utils-Nbh7yQ73.js";
|
|
4
5
|
import { S as y, L as K } from "./stack-BLMteGTn.js";
|
|
5
|
-
import { d as V, I as x } from "./translations-
|
|
6
|
+
import { d as V, I as x } from "./translations-DU9wTV1y.js";
|
|
6
7
|
import U from "ajv";
|
|
7
8
|
import G from "ajv/dist/2019";
|
|
8
9
|
import X from "ajv/dist/2020";
|
|
@@ -41,7 +42,7 @@ function N(t) {
|
|
|
41
42
|
return i.message = Z(n), e;
|
|
42
43
|
}, {});
|
|
43
44
|
}
|
|
44
|
-
function
|
|
45
|
+
function xe(t) {
|
|
45
46
|
const e = N(t);
|
|
46
47
|
return z.invalid(e);
|
|
47
48
|
}
|
|
@@ -57,13 +58,13 @@ function ee(t) {
|
|
|
57
58
|
t.addKeyword(e);
|
|
58
59
|
}
|
|
59
60
|
let A = /* @__PURE__ */ new WeakMap();
|
|
60
|
-
function
|
|
61
|
+
function Me() {
|
|
61
62
|
A = /* @__PURE__ */ new WeakMap();
|
|
62
63
|
}
|
|
63
|
-
function
|
|
64
|
+
function Ee(t) {
|
|
64
65
|
A.delete(t);
|
|
65
66
|
}
|
|
66
|
-
function
|
|
67
|
+
function Te() {
|
|
67
68
|
return {
|
|
68
69
|
ajvInstances: 0
|
|
69
70
|
// WeakMap doesn't expose size for privacy/security
|
|
@@ -183,7 +184,7 @@ async function ie(t, e, n, r) {
|
|
|
183
184
|
}
|
|
184
185
|
return "refResolver reached iteration limit while resolving external $refs";
|
|
185
186
|
}
|
|
186
|
-
async function
|
|
187
|
+
async function qe(t, e) {
|
|
187
188
|
try {
|
|
188
189
|
const n = ne(t.$schema), r = e?.sanitizeAdditional === !1 ? !1 : e?.sanitizeAdditional ?? !1, i = (f) => typeof f == "string" && f.endsWith("#") ? f.slice(0, -1) : f ?? "", o = t.$id, s = i(o);
|
|
189
190
|
if (s !== "" && (/* @__PURE__ */ new Set([
|
|
@@ -341,7 +342,7 @@ function de(t, e, n) {
|
|
|
341
342
|
return;
|
|
342
343
|
} else return i.length === 1 ? i[0] : i;
|
|
343
344
|
}
|
|
344
|
-
function
|
|
345
|
+
function Ie(t, e = []) {
|
|
345
346
|
const n = [], r = {}, i = [], o = [], s = {};
|
|
346
347
|
for (const l of t) {
|
|
347
348
|
l.type != null && i.push(le(l.type)), Array.isArray(l.required) && o.push(...l.required), l.properties != null && ce(
|
|
@@ -624,7 +625,7 @@ function I(t, e) {
|
|
|
624
625
|
}
|
|
625
626
|
return r.set(e, s), s;
|
|
626
627
|
}
|
|
627
|
-
function
|
|
628
|
+
function De(t, e, n) {
|
|
628
629
|
let r = t;
|
|
629
630
|
const i = /* @__PURE__ */ new Set(), o = (s, a) => {
|
|
630
631
|
const { $ref: l, ...u } = a;
|
|
@@ -669,9 +670,9 @@ function Ie(t, e, n) {
|
|
|
669
670
|
}
|
|
670
671
|
return r;
|
|
671
672
|
}
|
|
672
|
-
function
|
|
673
|
+
function ze(t) {
|
|
673
674
|
if (typeof t.definition == "boolean") return;
|
|
674
|
-
const e =
|
|
675
|
+
const e = J(t.definition);
|
|
675
676
|
if (typeof e != "object") return;
|
|
676
677
|
const n = {};
|
|
677
678
|
return typeof e.format == "string" && ["fieldset", "tabs", "accordion", "group", "grid"].includes(e.format) && (n.format = e.format), Array.isArray(e.order) && (n.order = e.order.filter(
|
|
@@ -695,7 +696,7 @@ function me({
|
|
|
695
696
|
title: t,
|
|
696
697
|
children: e
|
|
697
698
|
}) {
|
|
698
|
-
return
|
|
699
|
+
return H(
|
|
699
700
|
{ variant: "outlined", size: "md" },
|
|
700
701
|
y(
|
|
701
702
|
c.class("bc-stack--gap-1"),
|
|
@@ -936,7 +937,7 @@ function C(t, e, n) {
|
|
|
936
937
|
}
|
|
937
938
|
return { orderedChildren: i, groupedChildren: o };
|
|
938
939
|
}
|
|
939
|
-
function
|
|
940
|
+
function Be(t, e, n, r = []) {
|
|
940
941
|
if (!t || !t.format) {
|
|
941
942
|
if (t?.order) {
|
|
942
943
|
const { orderedChildren: a } = C(
|
|
@@ -1035,7 +1036,7 @@ function L(t, e) {
|
|
|
1035
1036
|
function Oe(t) {
|
|
1036
1037
|
return t === null ? "null" : Array.isArray(t) ? "array" : typeof t == "object" ? "object" : typeof t == "string" ? "string" : typeof t == "number" ? Number.isInteger(t) ? "integer" : "number" : typeof t == "boolean" ? "boolean" : "unknown";
|
|
1037
1038
|
}
|
|
1038
|
-
function
|
|
1039
|
+
function We(t, e, n = `Option ${e + 1}`) {
|
|
1039
1040
|
if (typeof t == "boolean")
|
|
1040
1041
|
return t ? "Any Value" : "No Value";
|
|
1041
1042
|
if (t.title)
|
|
@@ -1050,28 +1051,28 @@ function Be(t, e, n = `Option ${e + 1}`) {
|
|
|
1050
1051
|
}
|
|
1051
1052
|
return "const" in t && typeof t.const == "string" ? t.const : t.type ? (Array.isArray(t.type) ? t.type : [t.type]).join(" | ") : n;
|
|
1052
1053
|
}
|
|
1053
|
-
function
|
|
1054
|
+
function Fe(t, e, n) {
|
|
1054
1055
|
const r = Ae(t, e, n);
|
|
1055
1056
|
return r.matchingBranch !== -1 ? r.matchingBranch : -1;
|
|
1056
1057
|
}
|
|
1057
1058
|
export {
|
|
1058
1059
|
T as S,
|
|
1059
|
-
|
|
1060
|
+
Be as a,
|
|
1060
1061
|
he as b,
|
|
1061
1062
|
te as c,
|
|
1062
1063
|
Ae as d,
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1064
|
+
We as e,
|
|
1065
|
+
Fe as f,
|
|
1066
|
+
ze as g,
|
|
1067
|
+
xe as h,
|
|
1068
|
+
qe as i,
|
|
1068
1069
|
N as j,
|
|
1069
1070
|
Z as k,
|
|
1070
1071
|
Y as l,
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1072
|
+
Ie as m,
|
|
1073
|
+
Me as n,
|
|
1074
|
+
Ee as o,
|
|
1075
|
+
Te as p,
|
|
1075
1076
|
M as q,
|
|
1076
|
-
|
|
1077
|
+
De as r
|
|
1077
1078
|
};
|