@poveste/controls 0.15.0 → 0.16.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/index.es.js CHANGED
@@ -1,22 +1,1677 @@
1
- import { t as e } from "./HstWrapper-C557fRoN.es.js";
2
- import { Fragment as t, computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, defineAsyncComponent as l, defineComponent as u, mergeProps as d, normalizeClass as f, normalizeStyle as p, onUnmounted as m, openBlock as h, ref as g, renderList as _, renderSlot as v, toDisplayString as y, unref as b, vModelText as x, watch as S, withCtx as C, withDirectives as w, withKeys as T, withModifiers as E } from "@poveste/vendors/vue";
3
- import { Dropdown as ee, VTooltip as D } from "@poveste/vendors/floating-vue";
4
- import { Icon as O } from "@poveste/vendors/iconify";
5
- import { useClipboard as te, useLiveAnnouncer as ne } from "@poveste/vendors/vue-use";
6
- //#endregion
7
- //#region src/components/button/HstButton.vue
8
- var k = /* @__PURE__ */ u({
1
+ import { C as e, D as t, O as n, _ as r, a as i, b as a, k as o, m as s, n as c, r as l, t as u, u as d, v as f } from "./HstWrapper-Bm5H3_to.es.js";
2
+ import { a as p, i as m, n as h, o as g, r as _, s as v, t as y } from "./PopoverTrigger-BVAfE9fE.es.js";
3
+ import { n as ee, r as b, t as x } from "./VisuallyHiddenInput-0it-_FH2.es.js";
4
+ import { t as te } from "./useKbd-DQM4Oqri.es.js";
5
+ import { Fragment as S, computed as C, createBlock as w, createCommentVNode as T, createElementBlock as E, createElementVNode as D, createTextVNode as O, createVNode as k, defineAsyncComponent as A, defineComponent as j, getCurrentInstance as ne, guardReactiveProps as M, mergeProps as N, nextTick as P, normalizeClass as F, normalizeProps as I, normalizeStyle as L, onBeforeMount as re, onMounted as ie, onUnmounted as R, openBlock as z, ref as B, renderList as V, renderSlot as H, resolveDynamicComponent as U, shallowRef as ae, toDisplayString as W, toRefs as G, unref as K, useAttrs as oe, vModelText as se, watch as ce, withCtx as q, withDirectives as J, withKeys as Y, withMemo as le, withModifiers as X } from "@poveste/vendors/vue";
6
+ import { createEventHook as ue, useClipboard as de, useEventListener as fe, useLiveAnnouncer as pe, useVModel as Z } from "@poveste/vendors/vue-use";
7
+ import { Icon as me } from "@poveste/vendors/iconify";
8
+ //#region src/components/button/HstButton.vue?vue&type=script&setup=true&lang.ts
9
+ var he = ["data-color"], ge = /* @__PURE__ */ j({
9
10
  name: "HstButton",
10
11
  props: { color: {} },
11
12
  setup(e) {
12
- let t = {
13
- default: "bg-gray-200 dark:bg-gray-750 text-gray-900 dark:text-gray-100 hover:bg-primary-200 dark:hover:bg-primary-900",
14
- primary: "bg-primary-500 hover:bg-primary-600 text-white dark:text-black",
15
- flat: "bg-transparent hover:bg-gray-500/20 text-gray-900 dark:text-gray-100"
16
- };
17
- return (n, r) => (h(), a("button", { class: f(["poveste-button cursor-pointer rounded-sm border-none", t[e.color ?? "default"]]) }, [v(n.$slots, "default")], 2));
18
- }
19
- }), re = { class: "flex gap-px border border-solid border-black/25 dark:border-white/25 rounded-sm p-px" }, ie = /* @__PURE__ */ u({
13
+ return (t, n) => (z(), E("button", {
14
+ class: "poveste-button",
15
+ "data-slot": "button",
16
+ "data-color": e.color ?? "default"
17
+ }, [H(t.$slots, "default")], 8, he));
18
+ }
19
+ });
20
+ //#endregion
21
+ //#region ../../node_modules/.pnpm/ohash@2.0.11/node_modules/ohash/dist/shared/ohash.D__AXeF1.mjs
22
+ function _e(e) {
23
+ return typeof e == "string" ? `'${e}'` : new ve().serialize(e);
24
+ }
25
+ var ve = /*@__PURE__*/ function() {
26
+ class e {
27
+ #e = /* @__PURE__ */ new Map();
28
+ compare(e, t) {
29
+ let n = typeof e, r = typeof t;
30
+ return n === "string" && r === "string" ? e.localeCompare(t) : n === "number" && r === "number" ? e - t : String.prototype.localeCompare.call(this.serialize(e, !0), this.serialize(t, !0));
31
+ }
32
+ serialize(e, t) {
33
+ if (e === null) return "null";
34
+ switch (typeof e) {
35
+ case "string": return t ? e : `'${e}'`;
36
+ case "bigint": return `${e}n`;
37
+ case "object": return this.$object(e);
38
+ case "function": return this.$function(e);
39
+ }
40
+ return String(e);
41
+ }
42
+ serializeObject(e) {
43
+ let t = Object.prototype.toString.call(e);
44
+ if (t !== "[object Object]") return this.serializeBuiltInType(t.length < 10 ? `unknown:${t}` : t.slice(8, -1), e);
45
+ let n = e.constructor, r = n === Object || n === void 0 ? "" : n.name;
46
+ if (r !== "" && globalThis[r] === n) return this.serializeBuiltInType(r, e);
47
+ if (typeof e.toJSON == "function") {
48
+ let t = e.toJSON();
49
+ return r + (typeof t == "object" && t ? this.$object(t) : `(${this.serialize(t)})`);
50
+ }
51
+ return this.serializeObjectEntries(r, Object.entries(e));
52
+ }
53
+ serializeBuiltInType(e, t) {
54
+ let n = this["$" + e];
55
+ if (n) return n.call(this, t);
56
+ if (typeof t?.entries == "function") return this.serializeObjectEntries(e, t.entries());
57
+ throw Error(`Cannot serialize ${e}`);
58
+ }
59
+ serializeObjectEntries(e, t) {
60
+ let n = Array.from(t).sort((e, t) => this.compare(e[0], t[0])), r = `${e}{`;
61
+ for (let e = 0; e < n.length; e++) {
62
+ let [t, i] = n[e];
63
+ r += `${this.serialize(t, !0)}:${this.serialize(i)}`, e < n.length - 1 && (r += ",");
64
+ }
65
+ return r + "}";
66
+ }
67
+ $object(e) {
68
+ let t = this.#e.get(e);
69
+ return t === void 0 && (this.#e.set(e, `#${this.#e.size}`), t = this.serializeObject(e), this.#e.set(e, t)), t;
70
+ }
71
+ $function(e) {
72
+ let t = Function.prototype.toString.call(e);
73
+ return t.slice(-15) === "[native code] }" ? `${e.name || ""}()[native]` : `${e.name}(${e.length})${t.replace(/\s*\n\s*/g, "")}`;
74
+ }
75
+ $Array(e) {
76
+ let t = "[";
77
+ for (let n = 0; n < e.length; n++) t += this.serialize(e[n]), n < e.length - 1 && (t += ",");
78
+ return t + "]";
79
+ }
80
+ $Date(e) {
81
+ try {
82
+ return `Date(${e.toISOString()})`;
83
+ } catch {
84
+ return "Date(null)";
85
+ }
86
+ }
87
+ $ArrayBuffer(e) {
88
+ return `ArrayBuffer[${new Uint8Array(e).join(",")}]`;
89
+ }
90
+ $Set(e) {
91
+ return `Set${this.$Array(Array.from(e).sort((e, t) => this.compare(e, t)))}`;
92
+ }
93
+ $Map(e) {
94
+ return this.serializeObjectEntries("Map", e.entries());
95
+ }
96
+ }
97
+ for (let t of [
98
+ "Error",
99
+ "RegExp",
100
+ "URL"
101
+ ]) e.prototype["$" + t] = function(e) {
102
+ return `${t}(${e})`;
103
+ };
104
+ for (let t of [
105
+ "Int8Array",
106
+ "Uint8Array",
107
+ "Uint8ClampedArray",
108
+ "Int16Array",
109
+ "Uint16Array",
110
+ "Int32Array",
111
+ "Uint32Array",
112
+ "Float32Array",
113
+ "Float64Array"
114
+ ]) e.prototype["$" + t] = function(e) {
115
+ return `${t}[${e.join(",")}]`;
116
+ };
117
+ for (let t of ["BigInt64Array", "BigUint64Array"]) e.prototype["$" + t] = function(e) {
118
+ return `${t}[${e.join("n,")}${e.length > 0 ? "n" : ""}]`;
119
+ };
120
+ return e;
121
+ }();
122
+ function Q(e, t) {
123
+ return e === t || _e(e) === _e(t);
124
+ }
125
+ //#endregion
126
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/shared/arrays.js
127
+ function ye(e, t, n) {
128
+ let r = e.findIndex((e) => Q(e, t)), i = e.findIndex((e) => Q(e, n));
129
+ if (r === -1 || i === -1) return [];
130
+ let [a, o] = [r, i].sort((e, t) => e - t);
131
+ return e.slice(a, o + 1);
132
+ }
133
+ //#endregion
134
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/shared/isValueEqualOrExist.js
135
+ function be(e, n) {
136
+ return t(e) ? !1 : Array.isArray(e) ? e.some((e) => Q(e, n)) : Q(e, n);
137
+ }
138
+ //#endregion
139
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useForwardScopeId.js
140
+ function xe() {
141
+ let e = ne()?.vnode?.scopeId;
142
+ return e ? { [e]: "" } : {};
143
+ }
144
+ //#endregion
145
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useTypeahead.js
146
+ function Se(t) {
147
+ let n = e("", 1e3);
148
+ return {
149
+ search: n,
150
+ handleTypeaheadSearch: (e, r) => {
151
+ if (n.value += e, t) t(e);
152
+ else {
153
+ let e = v(), t = r.map((e) => ({
154
+ ...e,
155
+ textValue: e.value?.textValue ?? e.ref.textContent?.trim() ?? ""
156
+ })), i = t.find((t) => t.ref === e), a = we(t.map((e) => e.textValue), n.value, i?.textValue), o = t.find((e) => e.textValue === a);
157
+ return o && o.ref.focus(), o?.ref;
158
+ }
159
+ },
160
+ resetTypeahead: () => {
161
+ n.value = "";
162
+ }
163
+ };
164
+ }
165
+ function Ce(e, t) {
166
+ return e.map((n, r) => e[(t + r) % e.length]);
167
+ }
168
+ function we(e, t, n) {
169
+ let r = t.length > 1 && Array.from(t).every((e) => e === t[0]) ? t[0] : t, i = n ? e.indexOf(n) : -1, a = Ce(e, Math.max(i, 0));
170
+ r.length === 1 && (a = a.filter((e) => e !== n));
171
+ let o = a.find((e) => e.toLowerCase().startsWith(r.toLowerCase()));
172
+ return o === n ? void 0 : o;
173
+ }
174
+ //#endregion
175
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useSingleOrMultipleValue.js
176
+ function Te({ type: e, defaultValue: t, modelValue: n }) {
177
+ let r = n || t;
178
+ return n !== void 0 || t !== void 0 ? Array.isArray(r) ? "multiple" : "single" : e ?? "single";
179
+ }
180
+ function Ee({ type: e, defaultValue: t, modelValue: n }) {
181
+ return e || Te({
182
+ type: e,
183
+ defaultValue: t,
184
+ modelValue: n
185
+ });
186
+ }
187
+ function De({ type: e, defaultValue: t }) {
188
+ return t === void 0 ? e === "single" ? void 0 : [] : t;
189
+ }
190
+ function Oe(e, t) {
191
+ let n = C(() => Ee(e)), r = Z(e, "modelValue", t, {
192
+ defaultValue: De(e),
193
+ passive: e.modelValue === void 0,
194
+ deep: !0
195
+ });
196
+ function i(e) {
197
+ if (n.value === "single") r.value = Q(e, r.value) ? void 0 : e;
198
+ else {
199
+ let t = Array.isArray(r.value) ? [...r.value || []] : [r.value].filter(Boolean);
200
+ if (be(t, e)) {
201
+ let n = t.findIndex((t) => Q(t, e));
202
+ t.splice(n, 1);
203
+ } else t.push(e);
204
+ r.value = t;
205
+ }
206
+ }
207
+ return {
208
+ modelValue: r,
209
+ changeModelValue: i,
210
+ isSingle: C(() => n.value === "single")
211
+ };
212
+ }
213
+ //#endregion
214
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/Listbox/utils.js
215
+ function ke(e, t, n) {
216
+ return e === void 0 ? !1 : Array.isArray(e) ? e.some((e) => Ae(e, t, n)) : Ae(e, t, n);
217
+ }
218
+ function Ae(e, t, n) {
219
+ return e === void 0 || t === void 0 ? !1 : typeof e == "string" ? e === t : typeof n == "function" ? n(e, t) : typeof n == "string" ? e?.[n] === t?.[n] : Q(e, t);
220
+ }
221
+ //#endregion
222
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/RovingFocus/utils.js
223
+ var je = "rovingFocusGroup.onEntryFocus", Me = {
224
+ bubbles: !1,
225
+ cancelable: !0
226
+ }, Ne = {
227
+ ArrowLeft: "prev",
228
+ ArrowUp: "prev",
229
+ ArrowRight: "next",
230
+ ArrowDown: "next",
231
+ PageUp: "first",
232
+ Home: "first",
233
+ PageDown: "last",
234
+ End: "last"
235
+ };
236
+ function Pe(e, t) {
237
+ return t === "rtl" ? e === "ArrowLeft" ? "ArrowRight" : e === "ArrowRight" ? "ArrowLeft" : e : e;
238
+ }
239
+ function Fe(e, t, n) {
240
+ let r = Pe(e.key, n);
241
+ if (!(t === "vertical" && ["ArrowLeft", "ArrowRight"].includes(r)) && !(t === "horizontal" && ["ArrowUp", "ArrowDown"].includes(r))) return Ne[r];
242
+ }
243
+ function Ie(e, t = !1) {
244
+ let n = v();
245
+ for (let r of e) if (r === n || (r.focus({ preventScroll: t }), v() !== n)) return;
246
+ }
247
+ function Le(e, t) {
248
+ return e.map((n, r) => e[(t + r) % e.length]);
249
+ }
250
+ //#endregion
251
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/Listbox/ListboxRoot.js
252
+ var [Re, ze] = /*#__PURE__*/ o("ListboxRoot"), [Be, Ve] = /*#__PURE__*/ o("ListboxHighlightScroll"), He = /* @__PURE__ */ j({
253
+ __name: "ListboxRoot",
254
+ props: {
255
+ modelValue: {
256
+ type: null,
257
+ required: !1
258
+ },
259
+ defaultValue: {
260
+ type: null,
261
+ required: !1
262
+ },
263
+ multiple: {
264
+ type: Boolean,
265
+ required: !1
266
+ },
267
+ orientation: {
268
+ type: String,
269
+ required: !1,
270
+ default: "vertical"
271
+ },
272
+ dir: {
273
+ type: String,
274
+ required: !1
275
+ },
276
+ disabled: {
277
+ type: Boolean,
278
+ required: !1
279
+ },
280
+ selectionBehavior: {
281
+ type: String,
282
+ required: !1,
283
+ default: "toggle"
284
+ },
285
+ highlightOnHover: {
286
+ type: Boolean,
287
+ required: !1
288
+ },
289
+ by: {
290
+ type: [String, Function],
291
+ required: !1
292
+ },
293
+ asChild: {
294
+ type: Boolean,
295
+ required: !1
296
+ },
297
+ as: {
298
+ type: null,
299
+ required: !1
300
+ },
301
+ name: {
302
+ type: String,
303
+ required: !1
304
+ },
305
+ required: {
306
+ type: Boolean,
307
+ required: !1
308
+ }
309
+ },
310
+ emits: [
311
+ "update:modelValue",
312
+ "highlight",
313
+ "entryFocus",
314
+ "leave"
315
+ ],
316
+ setup(e, { expose: t, emit: n }) {
317
+ let r = e, i = n, { multiple: o, highlightOnHover: s, orientation: c, disabled: l, selectionBehavior: u, dir: p } = G(r), { getItems: m, getItem: h } = ee({ isProvider: !0 }), { handleTypeaheadSearch: _ } = Se(), { primitiveElement: v, currentElement: y } = g(), S = te(), C = f(p), E = Be(null);
318
+ Ve({
319
+ suppressHighlightScroll: B(!1),
320
+ onHighlightScrollRequest: () => {}
321
+ });
322
+ let D = b(y), O = B(), k = B(!1), A = B(!0), j = Z(r, "modelValue", i, {
323
+ defaultValue: r.defaultValue ?? (o.value ? [] : void 0),
324
+ passive: r.modelValue === void 0,
325
+ deep: !0
326
+ });
327
+ function ne(e) {
328
+ if (k.value = !0, r.multiple) {
329
+ let t = Array.isArray(j.value) ? [...j.value] : [], n = t.findIndex((t) => Ae(t, e, r.by));
330
+ r.selectionBehavior === "toggle" ? (n === -1 ? t.push(e) : t.splice(n, 1), j.value = t) : (j.value = [e], O.value = e);
331
+ } else r.selectionBehavior === "toggle" && Ae(j.value, e, r.by) ? j.value = void 0 : j.value = e;
332
+ setTimeout(() => {
333
+ k.value = !1;
334
+ }, 1);
335
+ }
336
+ let M = B(null), N = B(null), F = B(!1), I = B(!1), L = ue(), re = ue(), ie = ue();
337
+ function R() {
338
+ return m().map((e) => e.ref).filter((e) => e.dataset.disabled !== "");
339
+ }
340
+ function V(e, t = !0, n) {
341
+ if (!e) return;
342
+ M.value = e;
343
+ let r = E?.suppressHighlightScroll.value ?? !1;
344
+ (n ?? A.value) && (r ? M.value.focus({ preventScroll: !0 }) : M.value.focus()), r ? E?.onHighlightScrollRequest(t ? () => {
345
+ let e = M.value;
346
+ e?.isConnected && e.scrollIntoView({ block: "nearest" });
347
+ } : void 0) : t && M.value.scrollIntoView({ block: "nearest" });
348
+ let a = h(e);
349
+ i("highlight", a);
350
+ }
351
+ function U(e) {
352
+ if (F.value) ie.trigger(e);
353
+ else {
354
+ let t = m().find((t) => Ae(t.value, e, r.by));
355
+ t && (M.value = t.ref, V(t.ref));
356
+ }
357
+ }
358
+ function ae(e) {
359
+ if (M.value && M.value.isConnected) {
360
+ if (e.ctrlKey || e.metaKey || e.altKey) return;
361
+ e.preventDefault(), e.stopPropagation(), I.value || M.value.click();
362
+ }
363
+ }
364
+ function W(e) {
365
+ if (A.value) {
366
+ if (k.value = !0, F.value) re.trigger(e);
367
+ else {
368
+ let t = e.altKey || e.ctrlKey || e.metaKey;
369
+ if (t && e.key === "a" && o.value) {
370
+ let t = m(), n = t.map((e) => e.value);
371
+ j.value = [...n], e.preventDefault();
372
+ let r = t.at(-1);
373
+ r && V(r.ref);
374
+ } else if (!t) {
375
+ let t = _(e.key, m());
376
+ t && V(t);
377
+ }
378
+ }
379
+ setTimeout(() => {
380
+ k.value = !1;
381
+ }, 1);
382
+ }
383
+ }
384
+ function oe() {
385
+ I.value = !0;
386
+ }
387
+ function se() {
388
+ P(() => {
389
+ I.value = !1;
390
+ });
391
+ }
392
+ function J() {
393
+ P(() => {
394
+ X(new KeyboardEvent("keydown", { key: "PageUp" }));
395
+ });
396
+ }
397
+ function Y(e) {
398
+ let t = M.value;
399
+ t?.isConnected && (N.value = t), M.value = null, i("leave", e);
400
+ }
401
+ function le(e) {
402
+ let t = new CustomEvent("listbox.entryFocus", {
403
+ bubbles: !1,
404
+ cancelable: !0
405
+ });
406
+ if (e.currentTarget?.dispatchEvent(t), i("entryFocus", t), !t.defaultPrevented) {
407
+ if (N.value) V(N.value);
408
+ else {
409
+ let e = R()?.[0];
410
+ V(e);
411
+ }
412
+ }
413
+ }
414
+ function X(e) {
415
+ let t = Fe(e, c.value, C.value);
416
+ if (!t) return;
417
+ let n = R();
418
+ if (M.value) {
419
+ if (t === "last") n.reverse();
420
+ else if (t === "prev" || t === "next") {
421
+ t === "prev" && n.reverse();
422
+ let e = n.indexOf(M.value);
423
+ n = n.slice(e + 1);
424
+ }
425
+ de(e, n[0]);
426
+ }
427
+ if (n.length) {
428
+ let e = !M.value && t === "prev" ? n.length - 1 : 0;
429
+ V(n[e]);
430
+ }
431
+ if (F.value) return re.trigger(e);
432
+ }
433
+ function de(e, t) {
434
+ if (!F.value && r.selectionBehavior === "replace" && o.value && Array.isArray(j.value) && (!e.altKey && !e.ctrlKey && !e.metaKey || e.shiftKey) && e.shiftKey) {
435
+ let n = m().filter((e) => e.ref.dataset.disabled !== ""), r = n.find((e) => e.ref === t)?.value;
436
+ if (e.key === S.END ? r = n.at(-1)?.value : e.key === S.HOME && (r = n[0]?.value), !r || !O.value) return;
437
+ let i = ye(n.map((e) => e.value), O.value, r);
438
+ j.value = i;
439
+ }
440
+ }
441
+ async function fe(e, t = !0) {
442
+ if (a) {
443
+ if (await P(), F.value) L.trigger({
444
+ event: e,
445
+ scroll: t
446
+ });
447
+ else {
448
+ let e = R(), n = e.find((e) => e.dataset.state === "checked"), r = t ? void 0 : !1;
449
+ n ? V(n, t, r) : e.length && V(e[0], t, r);
450
+ }
451
+ }
452
+ }
453
+ let pe = !1;
454
+ return ce(j, () => {
455
+ if (!k.value) {
456
+ let e = pe;
457
+ pe = !0, P(() => {
458
+ fe(void 0, e);
459
+ });
460
+ }
461
+ }, {
462
+ immediate: !0,
463
+ deep: !0
464
+ }), t({
465
+ highlightedElement: M,
466
+ highlightItem: U,
467
+ highlightFirstItem: J,
468
+ highlightSelected: fe,
469
+ getItems: m
470
+ }), ze({
471
+ modelValue: j,
472
+ onValueChange: ne,
473
+ multiple: o,
474
+ orientation: c,
475
+ dir: C,
476
+ disabled: l,
477
+ highlightOnHover: s,
478
+ highlightedElement: M,
479
+ isVirtual: F,
480
+ virtualFocusHook: L,
481
+ virtualKeydownHook: re,
482
+ virtualHighlightHook: ie,
483
+ by: r.by,
484
+ firstValue: O,
485
+ selectionBehavior: u,
486
+ focusable: A,
487
+ onLeave: Y,
488
+ onEnter: le,
489
+ changeHighlight: V,
490
+ onKeydownEnter: ae,
491
+ onKeydownNavigation: X,
492
+ onKeydownTypeAhead: W,
493
+ onCompositionStart: oe,
494
+ onCompositionEnd: se,
495
+ highlightFirstItem: J
496
+ }), (e, t) => (z(), w(K(d), {
497
+ ref_key: "primitiveElement",
498
+ ref: v,
499
+ as: e.as,
500
+ "as-child": e.asChild,
501
+ dir: K(C),
502
+ "data-disabled": K(l) ? "" : void 0,
503
+ onPointerleave: Y,
504
+ onFocusout: t[0] ||= async (e) => {
505
+ let t = e.relatedTarget || e.target;
506
+ await P(), M.value && K(y) && !K(y).contains(t) && Y(e);
507
+ }
508
+ }, {
509
+ default: q(() => [H(e.$slots, "default", { modelValue: K(j) }), K(D) && e.name ? (z(), w(K(x), {
510
+ key: 0,
511
+ name: e.name,
512
+ value: K(j),
513
+ disabled: K(l),
514
+ required: e.required
515
+ }, null, 8, [
516
+ "name",
517
+ "value",
518
+ "disabled",
519
+ "required"
520
+ ])) : T("v-if", !0)]),
521
+ _: 3
522
+ }, 8, [
523
+ "as",
524
+ "as-child",
525
+ "dir",
526
+ "data-disabled"
527
+ ]));
528
+ }
529
+ }), Ue = /* @__PURE__ */ j({
530
+ __name: "ListboxContent",
531
+ props: {
532
+ asChild: {
533
+ type: Boolean,
534
+ required: !1
535
+ },
536
+ as: {
537
+ type: null,
538
+ required: !1
539
+ }
540
+ },
541
+ setup(t) {
542
+ let { CollectionSlot: n } = ee(), r = Re(), i = e(!1, 10);
543
+ return (e, t) => (z(), w(K(n), null, {
544
+ default: q(() => [k(K(d), {
545
+ role: "listbox",
546
+ as: e.as,
547
+ "as-child": e.asChild,
548
+ tabindex: K(r).focusable.value ? K(r).highlightedElement.value ? "-1" : "0" : "-1",
549
+ "aria-orientation": K(r).orientation.value,
550
+ "aria-multiselectable": !!K(r).multiple.value,
551
+ "data-orientation": K(r).orientation.value,
552
+ onMousedown: t[0] ||= X((e) => i.value = !0, ["left"]),
553
+ onFocus: t[1] ||= (e) => {
554
+ K(i) || K(r).onEnter(e);
555
+ },
556
+ onKeydown: [
557
+ t[2] ||= Y((e) => {
558
+ (K(r).orientation.value !== "vertical" || e.key !== "ArrowLeft" && e.key !== "ArrowRight") && (K(r).orientation.value !== "horizontal" || e.key !== "ArrowUp" && e.key !== "ArrowDown") && (e.preventDefault(), K(r).focusable.value && K(r).onKeydownNavigation(e));
559
+ }, [
560
+ "down",
561
+ "up",
562
+ "left",
563
+ "right",
564
+ "home",
565
+ "end"
566
+ ]),
567
+ Y(K(r).onKeydownEnter, ["enter"]),
568
+ K(r).onKeydownTypeAhead
569
+ ]
570
+ }, {
571
+ default: q(() => [H(e.$slots, "default")]),
572
+ _: 3
573
+ }, 8, [
574
+ "as",
575
+ "as-child",
576
+ "tabindex",
577
+ "aria-orientation",
578
+ "aria-multiselectable",
579
+ "data-orientation",
580
+ "onKeydown"
581
+ ])]),
582
+ _: 3
583
+ }));
584
+ }
585
+ }), We = "listbox.select", [Ge, Ke] = /*#__PURE__*/ o("ListboxItem"), qe = /* @__PURE__ */ j({
586
+ __name: "ListboxItem",
587
+ props: {
588
+ value: {
589
+ type: null,
590
+ required: !0
591
+ },
592
+ disabled: {
593
+ type: Boolean,
594
+ required: !1
595
+ },
596
+ asChild: {
597
+ type: Boolean,
598
+ required: !1
599
+ },
600
+ as: {
601
+ type: null,
602
+ required: !1,
603
+ default: "div"
604
+ }
605
+ },
606
+ emits: ["select"],
607
+ setup(e, { emit: t }) {
608
+ let i = e, a = t, o = s(void 0, "reka-listbox-item"), { CollectionItem: c } = ee(), { forwardRef: l, currentElement: u } = r(), f = Re(), p = C(() => u.value != null && u.value === f.highlightedElement.value), m = C(() => ke(f.modelValue.value, i.value, f.by)), h = C(() => f.disabled.value || i.disabled);
609
+ async function g(e) {
610
+ a("select", e), !e?.defaultPrevented && !h.value && e && (f.onValueChange(i.value), f.changeHighlight(u.value));
611
+ }
612
+ function _(e) {
613
+ let t = {
614
+ originalEvent: e,
615
+ value: i.value
616
+ };
617
+ n(We, g, t);
618
+ }
619
+ return Ke({ isSelected: m }), (e, t) => (z(), w(K(c), { value: e.value }, {
620
+ default: q(() => [le([
621
+ p.value,
622
+ m.value,
623
+ h.value,
624
+ K(f).focusable.value,
625
+ ...Object.entries(e.$attrs).flat()
626
+ ], () => k(K(d), N({ id: K(o) }, e.$attrs, {
627
+ ref: K(l),
628
+ role: "option",
629
+ tabindex: K(f).focusable.value ? p.value ? "0" : "-1" : -1,
630
+ "aria-selected": m.value,
631
+ as: e.as,
632
+ "as-child": e.asChild,
633
+ disabled: h.value ? "" : void 0,
634
+ "data-disabled": h.value ? "" : void 0,
635
+ "data-highlighted": p.value ? "" : void 0,
636
+ "data-state": m.value ? "checked" : "unchecked",
637
+ onClick: _,
638
+ onKeydown: Y(X(_, ["prevent"]), ["space"]),
639
+ onPointermove: t[0] ||= () => {
640
+ K(f).highlightedElement.value !== K(u) && K(f).highlightOnHover.value && K(f).changeHighlight(K(u), !1, !1);
641
+ }
642
+ }), {
643
+ default: q(() => [H(e.$slots, "default")]),
644
+ _: 3
645
+ }, 16, [
646
+ "id",
647
+ "tabindex",
648
+ "aria-selected",
649
+ "as",
650
+ "as-child",
651
+ "disabled",
652
+ "data-disabled",
653
+ "data-highlighted",
654
+ "data-state",
655
+ "onKeydown"
656
+ ]), t, 1)]),
657
+ _: 3
658
+ }, 8, ["value"]));
659
+ }
660
+ }), [Je, Ye] = /*#__PURE__*/ o("RovingFocusGroup"), Xe = /* @__PURE__ */ j({
661
+ __name: "RovingFocusGroup",
662
+ props: {
663
+ orientation: {
664
+ type: String,
665
+ required: !1,
666
+ default: void 0
667
+ },
668
+ dir: {
669
+ type: String,
670
+ required: !1
671
+ },
672
+ loop: {
673
+ type: Boolean,
674
+ required: !1,
675
+ default: !1
676
+ },
677
+ currentTabStopId: {
678
+ type: [String, null],
679
+ required: !1
680
+ },
681
+ defaultCurrentTabStopId: {
682
+ type: String,
683
+ required: !1
684
+ },
685
+ preventScrollOnEntryFocus: {
686
+ type: Boolean,
687
+ required: !1,
688
+ default: !1
689
+ },
690
+ asChild: {
691
+ type: Boolean,
692
+ required: !1
693
+ },
694
+ as: {
695
+ type: null,
696
+ required: !1
697
+ }
698
+ },
699
+ emits: ["entryFocus", "update:currentTabStopId"],
700
+ setup(e, { expose: t, emit: n }) {
701
+ let r = e, i = n, { loop: a, orientation: o, dir: s } = G(r), c = f(s), l = Z(r, "currentTabStopId", i, {
702
+ defaultValue: r.defaultCurrentTabStopId,
703
+ passive: r.currentTabStopId === void 0
704
+ }), u = B(!1), p = B(!1), m = B(0), { getItems: h, CollectionSlot: g } = ee({ isProvider: !0 });
705
+ function _(e) {
706
+ let t = !p.value;
707
+ if (e.currentTarget && e.target === e.currentTarget && t && !u.value) {
708
+ let t = new CustomEvent(je, Me);
709
+ if (e.currentTarget.dispatchEvent(t), i("entryFocus", t), !t.defaultPrevented) {
710
+ let e = h().map((e) => e.ref).filter((e) => e.dataset.disabled !== "");
711
+ Ie([
712
+ e.find((e) => e.getAttribute("data-active") === ""),
713
+ e.find((e) => e.getAttribute("data-highlighted") === ""),
714
+ e.find((e) => e.id === l.value),
715
+ ...e
716
+ ].filter(Boolean), r.preventScrollOnEntryFocus);
717
+ }
718
+ }
719
+ p.value = !1;
720
+ }
721
+ function v() {
722
+ setTimeout(() => {
723
+ p.value = !1;
724
+ }, 1);
725
+ }
726
+ return t({ getItems: h }), Ye({
727
+ loop: a,
728
+ dir: c,
729
+ orientation: o,
730
+ currentTabStopId: l,
731
+ onItemFocus: (e) => {
732
+ l.value = e;
733
+ },
734
+ onItemShiftTab: () => {
735
+ u.value = !0;
736
+ },
737
+ onFocusableItemAdd: () => {
738
+ m.value++;
739
+ },
740
+ onFocusableItemRemove: () => {
741
+ m.value--;
742
+ }
743
+ }), (e, t) => (z(), w(K(g), null, {
744
+ default: q(() => [k(K(d), {
745
+ tabindex: u.value || m.value === 0 ? -1 : 0,
746
+ "data-orientation": K(o),
747
+ as: e.as,
748
+ "as-child": e.asChild,
749
+ dir: K(c),
750
+ style: { outline: "none" },
751
+ onMousedown: t[0] ||= (e) => p.value = !0,
752
+ onMouseup: v,
753
+ onFocus: _,
754
+ onBlur: t[1] ||= (e) => u.value = !1
755
+ }, {
756
+ default: q(() => [H(e.$slots, "default")]),
757
+ _: 3
758
+ }, 8, [
759
+ "tabindex",
760
+ "data-orientation",
761
+ "as",
762
+ "as-child",
763
+ "dir"
764
+ ])]),
765
+ _: 3
766
+ }));
767
+ }
768
+ }), Ze = /* @__PURE__ */ j({
769
+ __name: "RovingFocusItem",
770
+ props: {
771
+ tabStopId: {
772
+ type: String,
773
+ required: !1
774
+ },
775
+ focusable: {
776
+ type: Boolean,
777
+ required: !1,
778
+ default: !0
779
+ },
780
+ active: {
781
+ type: Boolean,
782
+ required: !1
783
+ },
784
+ allowShiftKey: {
785
+ type: Boolean,
786
+ required: !1
787
+ },
788
+ asChild: {
789
+ type: Boolean,
790
+ required: !1
791
+ },
792
+ as: {
793
+ type: null,
794
+ required: !1,
795
+ default: "span"
796
+ }
797
+ },
798
+ setup(e) {
799
+ let t = e, n = Je(), r = s(), i = C(() => t.tabStopId || r), a = C(() => n.currentTabStopId.value === i.value), { getItems: o, CollectionItem: c } = ee();
800
+ ie(() => {
801
+ t.focusable && n.onFocusableItemAdd();
802
+ }), R(() => {
803
+ t.focusable && n.onFocusableItemRemove();
804
+ }), ce(() => t.focusable, (e, t) => {
805
+ e !== t && (e ? n.onFocusableItemAdd() : n.onFocusableItemRemove());
806
+ });
807
+ function l(e) {
808
+ if (e.key === "Tab" && e.shiftKey) {
809
+ n.onItemShiftTab();
810
+ return;
811
+ }
812
+ if (e.target !== e.currentTarget) return;
813
+ let r = Fe(e, n.orientation.value, n.dir.value);
814
+ if (r !== void 0) {
815
+ if (e.metaKey || e.ctrlKey || e.altKey || !t.allowShiftKey && e.shiftKey) return;
816
+ e.preventDefault();
817
+ let i = [...o().map((e) => e.ref).filter((e) => e.dataset.disabled !== "")];
818
+ if (r === "last") i.reverse();
819
+ else if (r === "prev" || r === "next") {
820
+ r === "prev" && i.reverse();
821
+ let t = i.indexOf(e.currentTarget);
822
+ i = n.loop.value ? Le(i, t + 1) : i.slice(t + 1);
823
+ }
824
+ P(() => Ie(i));
825
+ }
826
+ }
827
+ return (e, t) => (z(), w(K(c), null, {
828
+ default: q(() => [k(K(d), {
829
+ tabindex: a.value ? 0 : -1,
830
+ "data-orientation": K(n).orientation.value,
831
+ "data-active": e.active ? "" : void 0,
832
+ "data-disabled": e.focusable ? void 0 : "",
833
+ as: e.as,
834
+ "as-child": e.asChild,
835
+ onMousedown: t[0] ||= (t) => {
836
+ e.focusable ? K(n).onItemFocus(i.value) : t.preventDefault();
837
+ },
838
+ onFocus: t[1] ||= (e) => K(n).onItemFocus(i.value),
839
+ onKeydown: l
840
+ }, {
841
+ default: q(() => [H(e.$slots, "default")]),
842
+ _: 3
843
+ }, 8, [
844
+ "tabindex",
845
+ "data-orientation",
846
+ "data-active",
847
+ "data-disabled",
848
+ "as",
849
+ "as-child"
850
+ ])]),
851
+ _: 3
852
+ }));
853
+ }
854
+ }), [Qe, $e] = /*#__PURE__*/ o("CheckboxGroupRoot"), et = /* @__PURE__ */ j({
855
+ __name: "CheckboxGroupRoot",
856
+ props: {
857
+ defaultValue: {
858
+ type: Array,
859
+ required: !1
860
+ },
861
+ modelValue: {
862
+ type: Array,
863
+ required: !1
864
+ },
865
+ rovingFocus: {
866
+ type: Boolean,
867
+ required: !1,
868
+ default: !0
869
+ },
870
+ disabled: {
871
+ type: Boolean,
872
+ required: !1
873
+ },
874
+ as: {
875
+ type: null,
876
+ required: !1
877
+ },
878
+ asChild: {
879
+ type: Boolean,
880
+ required: !1
881
+ },
882
+ dir: {
883
+ type: String,
884
+ required: !1
885
+ },
886
+ orientation: {
887
+ type: String,
888
+ required: !1
889
+ },
890
+ loop: {
891
+ type: Boolean,
892
+ required: !1
893
+ },
894
+ name: {
895
+ type: String,
896
+ required: !1
897
+ },
898
+ required: {
899
+ type: Boolean,
900
+ required: !1
901
+ }
902
+ },
903
+ emits: ["update:modelValue"],
904
+ setup(e, { emit: t }) {
905
+ let n = e, r = t, { disabled: i, rovingFocus: a, dir: o } = G(n), s = f(o), { primitiveElement: c, currentElement: l } = g(), u = b(l), p = Z(n, "modelValue", r, {
906
+ defaultValue: n.defaultValue ?? [],
907
+ passive: n.modelValue === void 0
908
+ }), m = C(() => a.value ? {
909
+ loop: n.loop,
910
+ dir: s.value,
911
+ orientation: n.orientation
912
+ } : {});
913
+ return $e({
914
+ modelValue: p,
915
+ rovingFocus: a,
916
+ disabled: i
917
+ }), (e, t) => (z(), w(U(K(a) ? K(Xe) : K(d)), N({
918
+ ref_key: "primitiveElement",
919
+ ref: c,
920
+ as: e.as,
921
+ "as-child": e.asChild
922
+ }, m.value), {
923
+ default: q(() => [H(e.$slots, "default"), K(u) && e.name ? (z(), w(K(x), {
924
+ key: 0,
925
+ name: e.name,
926
+ value: K(p),
927
+ required: e.required
928
+ }, null, 8, [
929
+ "name",
930
+ "value",
931
+ "required"
932
+ ])) : T("v-if", !0)]),
933
+ _: 3
934
+ }, 16, ["as", "as-child"]));
935
+ }
936
+ });
937
+ //#endregion
938
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/Checkbox/utils.js
939
+ function tt(e) {
940
+ return e === "indeterminate";
941
+ }
942
+ function nt(e) {
943
+ return tt(e) ? "indeterminate" : e ? "checked" : "unchecked";
944
+ }
945
+ //#endregion
946
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/Checkbox/CheckboxRoot.js
947
+ var [rt, it] = /*#__PURE__*/ o("CheckboxRoot"), at = /* @__PURE__ */ j({
948
+ inheritAttrs: !1,
949
+ __name: "CheckboxRoot",
950
+ props: {
951
+ defaultValue: {
952
+ type: null,
953
+ required: !1
954
+ },
955
+ modelValue: {
956
+ type: null,
957
+ required: !1,
958
+ default: void 0
959
+ },
960
+ disabled: {
961
+ type: Boolean,
962
+ required: !1
963
+ },
964
+ value: {
965
+ type: null,
966
+ required: !1,
967
+ default: "on"
968
+ },
969
+ id: {
970
+ type: String,
971
+ required: !1
972
+ },
973
+ trueValue: {
974
+ type: null,
975
+ required: !1,
976
+ default: () => !0
977
+ },
978
+ falseValue: {
979
+ type: null,
980
+ required: !1,
981
+ default: () => !1
982
+ },
983
+ asChild: {
984
+ type: Boolean,
985
+ required: !1
986
+ },
987
+ as: {
988
+ type: null,
989
+ required: !1,
990
+ default: "button"
991
+ },
992
+ name: {
993
+ type: String,
994
+ required: !1
995
+ },
996
+ required: {
997
+ type: Boolean,
998
+ required: !1
999
+ }
1000
+ },
1001
+ emits: ["update:modelValue"],
1002
+ setup(e, { emit: n }) {
1003
+ let i = e, a = n, { forwardRef: o, currentElement: s } = r(), c = Qe(null), l = Z(i, "modelValue", a, {
1004
+ defaultValue: i.defaultValue ?? i.falseValue,
1005
+ passive: i.modelValue === void 0
1006
+ }), u = C(() => c?.disabled.value || i.disabled), f = C(() => Q(l.value, i.trueValue)), p = C(() => t(c?.modelValue.value) ? l.value === "indeterminate" ? "indeterminate" : f.value : be(c.modelValue.value, i.value));
1007
+ function m() {
1008
+ if (t(c?.modelValue.value)) l.value === "indeterminate" ? l.value = i.trueValue : l.value = f.value ? i.falseValue : i.trueValue;
1009
+ else {
1010
+ let e = [...c.modelValue.value || []];
1011
+ if (be(e, i.value)) {
1012
+ let t = e.findIndex((e) => Q(e, i.value));
1013
+ e.splice(t, 1);
1014
+ } else e.push(i.value);
1015
+ c.modelValue.value = e;
1016
+ }
1017
+ }
1018
+ let h = b(s), g = xe(), _ = oe(), v = C(() => {
1019
+ if (!_["aria-label"]) return i.id && s.value ? document.querySelector(`[for="${i.id}"]`)?.innerText : void 0;
1020
+ });
1021
+ return it({
1022
+ disabled: u,
1023
+ state: p
1024
+ }), (e, t) => (z(), E(S, null, [(z(), w(U(K(c)?.rovingFocus.value ? K(Ze) : K(d)), N({
1025
+ ...e.$attrs,
1026
+ ...K(g)
1027
+ }, {
1028
+ id: e.id,
1029
+ ref: K(o),
1030
+ role: "checkbox",
1031
+ "as-child": e.asChild,
1032
+ as: e.as,
1033
+ type: e.as === "button" ? "button" : void 0,
1034
+ "aria-checked": K(tt)(p.value) ? "mixed" : p.value,
1035
+ "aria-required": e.required,
1036
+ "aria-label": e.$attrs["aria-label"] || v.value,
1037
+ "data-state": K(nt)(p.value),
1038
+ "data-disabled": u.value ? "" : void 0,
1039
+ disabled: u.value,
1040
+ focusable: K(c)?.rovingFocus.value ? !u.value : void 0,
1041
+ onKeydown: Y(X(() => {}, ["prevent"]), ["enter"]),
1042
+ onClick: m
1043
+ }), {
1044
+ default: q(() => [H(e.$slots, "default", {
1045
+ modelValue: K(l),
1046
+ state: p.value
1047
+ })]),
1048
+ _: 3
1049
+ }, 16, [
1050
+ "id",
1051
+ "as-child",
1052
+ "as",
1053
+ "type",
1054
+ "aria-checked",
1055
+ "aria-required",
1056
+ "aria-label",
1057
+ "data-state",
1058
+ "data-disabled",
1059
+ "disabled",
1060
+ "focusable",
1061
+ "onKeydown"
1062
+ ])), K(h) && e.name && !K(c) ? (z(), w(K(x), N({
1063
+ key: 0,
1064
+ type: "checkbox",
1065
+ checked: !!p.value,
1066
+ name: e.name,
1067
+ value: e.value,
1068
+ disabled: u.value,
1069
+ required: e.required
1070
+ }, K(g)), null, 16, [
1071
+ "checked",
1072
+ "name",
1073
+ "value",
1074
+ "disabled",
1075
+ "required"
1076
+ ])) : T("v-if", !0)], 64));
1077
+ }
1078
+ }), ot = /* @__PURE__ */ j({
1079
+ __name: "PopoverAnchor",
1080
+ props: {
1081
+ reference: {
1082
+ type: null,
1083
+ required: !1
1084
+ },
1085
+ asChild: {
1086
+ type: Boolean,
1087
+ required: !1
1088
+ },
1089
+ as: {
1090
+ type: null,
1091
+ required: !1
1092
+ }
1093
+ },
1094
+ setup(e) {
1095
+ let t = e;
1096
+ r();
1097
+ let n = p();
1098
+ return re(() => {
1099
+ n.hasCustomAnchor.value = !0;
1100
+ }), R(() => {
1101
+ n.hasCustomAnchor.value = !1;
1102
+ }), (e, n) => (z(), w(K(i), I(M(t)), {
1103
+ default: q(() => [H(e.$slots, "default")]),
1104
+ _: 3
1105
+ }, 16));
1106
+ }
1107
+ }), st = /* @__PURE__ */ j({
1108
+ __name: "Label",
1109
+ props: {
1110
+ for: {
1111
+ type: String,
1112
+ required: !1
1113
+ },
1114
+ asChild: {
1115
+ type: Boolean,
1116
+ required: !1
1117
+ },
1118
+ as: {
1119
+ type: null,
1120
+ required: !1,
1121
+ default: "label"
1122
+ }
1123
+ },
1124
+ setup(e) {
1125
+ let t = e;
1126
+ return r(), (e, n) => (z(), w(K(d), N(t, { onMousedown: n[0] ||= (e) => {
1127
+ !e.defaultPrevented && e.detail > 1 && e.preventDefault();
1128
+ } }), {
1129
+ default: q(() => [H(e.$slots, "default")]),
1130
+ _: 3
1131
+ }, 16));
1132
+ }
1133
+ }), ct = "radio.select";
1134
+ function lt(e, t, r) {
1135
+ n(ct, r, {
1136
+ originalEvent: e,
1137
+ value: t
1138
+ });
1139
+ }
1140
+ //#endregion
1141
+ //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.43_typescript@6.0.3_/node_modules/reka-ui/dist/RadioGroup/Radio.js
1142
+ var ut = /* @__PURE__ */ j({
1143
+ inheritAttrs: !1,
1144
+ __name: "Radio",
1145
+ props: {
1146
+ id: {
1147
+ type: String,
1148
+ required: !1
1149
+ },
1150
+ value: {
1151
+ type: null,
1152
+ required: !1
1153
+ },
1154
+ disabled: {
1155
+ type: Boolean,
1156
+ required: !1,
1157
+ default: !1
1158
+ },
1159
+ checked: {
1160
+ type: Boolean,
1161
+ required: !1,
1162
+ default: void 0
1163
+ },
1164
+ asChild: {
1165
+ type: Boolean,
1166
+ required: !1
1167
+ },
1168
+ as: {
1169
+ type: null,
1170
+ required: !1,
1171
+ default: "button"
1172
+ },
1173
+ name: {
1174
+ type: String,
1175
+ required: !1
1176
+ },
1177
+ required: {
1178
+ type: Boolean,
1179
+ required: !1
1180
+ }
1181
+ },
1182
+ emits: ["update:checked", "select"],
1183
+ setup(e, { emit: t }) {
1184
+ let n = e, i = t, a = Z(n, "checked", i, { passive: n.checked === void 0 }), { value: o } = G(n), { forwardRef: s, currentElement: c } = r(), l = b(c), u = xe(), f = C(() => n.id && c.value ? document.querySelector(`[for="${n.id}"]`)?.innerText : void 0);
1185
+ function p(e) {
1186
+ n.disabled || lt(e, n.value, (e) => {
1187
+ i("select", e), !e?.defaultPrevented && (a.value = !0, l.value && e.stopPropagation());
1188
+ });
1189
+ }
1190
+ return (e, t) => (z(), E(S, null, [k(K(d), N({
1191
+ id: e.id,
1192
+ ref: K(s),
1193
+ role: "radio",
1194
+ type: e.as === "button" ? "button" : void 0,
1195
+ as: e.as,
1196
+ "aria-checked": K(a) ?? !1,
1197
+ "aria-label": f.value,
1198
+ "as-child": e.asChild,
1199
+ disabled: e.disabled ? "" : void 0,
1200
+ "data-state": K(a) ? "checked" : "unchecked",
1201
+ "data-disabled": e.disabled ? "" : void 0,
1202
+ value: K(o),
1203
+ required: e.required,
1204
+ name: e.name
1205
+ }, {
1206
+ ...K(u),
1207
+ ...e.$attrs
1208
+ }, { onClick: X(p, ["stop"]) }), {
1209
+ default: q(() => [H(e.$slots, "default", { checked: K(a) })]),
1210
+ _: 3
1211
+ }, 16, [
1212
+ "id",
1213
+ "type",
1214
+ "as",
1215
+ "aria-checked",
1216
+ "aria-label",
1217
+ "as-child",
1218
+ "disabled",
1219
+ "data-state",
1220
+ "data-disabled",
1221
+ "value",
1222
+ "required",
1223
+ "name"
1224
+ ]), K(l) && e.name ? (z(), w(K(x), N({
1225
+ key: 0,
1226
+ type: "radio",
1227
+ tabindex: "-1",
1228
+ value: K(o),
1229
+ checked: !!K(a),
1230
+ name: e.name,
1231
+ disabled: e.disabled,
1232
+ required: e.required
1233
+ }, K(u)), null, 16, [
1234
+ "value",
1235
+ "checked",
1236
+ "name",
1237
+ "disabled",
1238
+ "required"
1239
+ ])) : T("v-if", !0)], 64));
1240
+ }
1241
+ }), [dt, ft] = /*#__PURE__*/ o("RadioGroupRoot"), pt = /* @__PURE__ */ j({
1242
+ __name: "RadioGroupRoot",
1243
+ props: {
1244
+ modelValue: {
1245
+ type: null,
1246
+ required: !1
1247
+ },
1248
+ defaultValue: {
1249
+ type: null,
1250
+ required: !1
1251
+ },
1252
+ disabled: {
1253
+ type: Boolean,
1254
+ required: !1,
1255
+ default: !1
1256
+ },
1257
+ orientation: {
1258
+ type: String,
1259
+ required: !1,
1260
+ default: void 0
1261
+ },
1262
+ dir: {
1263
+ type: String,
1264
+ required: !1
1265
+ },
1266
+ loop: {
1267
+ type: Boolean,
1268
+ required: !1,
1269
+ default: !0
1270
+ },
1271
+ asChild: {
1272
+ type: Boolean,
1273
+ required: !1
1274
+ },
1275
+ as: {
1276
+ type: null,
1277
+ required: !1
1278
+ },
1279
+ name: {
1280
+ type: String,
1281
+ required: !1
1282
+ },
1283
+ required: {
1284
+ type: Boolean,
1285
+ required: !1,
1286
+ default: !1
1287
+ }
1288
+ },
1289
+ emits: ["update:modelValue"],
1290
+ setup(e, { emit: t }) {
1291
+ let n = e, i = t, { forwardRef: a, currentElement: o } = r(), s = Z(n, "modelValue", i, {
1292
+ defaultValue: n.defaultValue,
1293
+ passive: n.modelValue === void 0
1294
+ }), { disabled: c, loop: l, orientation: u, name: p, required: m, dir: h } = G(n), g = f(h), _ = b(o);
1295
+ return ft({
1296
+ modelValue: s,
1297
+ changeModelValue: (e) => {
1298
+ s.value = e;
1299
+ },
1300
+ disabled: c,
1301
+ loop: l,
1302
+ orientation: u,
1303
+ name: p?.value,
1304
+ required: m
1305
+ }), (e, t) => (z(), w(K(Xe), {
1306
+ "as-child": "",
1307
+ orientation: K(u),
1308
+ dir: K(g),
1309
+ loop: K(l)
1310
+ }, {
1311
+ default: q(() => [k(K(d), {
1312
+ ref: K(a),
1313
+ role: "radiogroup",
1314
+ "data-disabled": K(c) ? "" : void 0,
1315
+ "as-child": e.asChild,
1316
+ as: e.as,
1317
+ "aria-orientation": K(u),
1318
+ "aria-required": K(m),
1319
+ dir: K(g)
1320
+ }, {
1321
+ default: q(() => [H(e.$slots, "default", { modelValue: K(s) }), K(_) && K(p) ? (z(), w(K(x), {
1322
+ key: 0,
1323
+ required: K(m),
1324
+ disabled: K(c),
1325
+ value: K(s),
1326
+ name: K(p)
1327
+ }, null, 8, [
1328
+ "required",
1329
+ "disabled",
1330
+ "value",
1331
+ "name"
1332
+ ])) : T("v-if", !0)]),
1333
+ _: 3
1334
+ }, 8, [
1335
+ "data-disabled",
1336
+ "as-child",
1337
+ "as",
1338
+ "aria-orientation",
1339
+ "aria-required",
1340
+ "dir"
1341
+ ])]),
1342
+ _: 3
1343
+ }, 8, [
1344
+ "orientation",
1345
+ "dir",
1346
+ "loop"
1347
+ ]));
1348
+ }
1349
+ }), [mt, ht] = /*#__PURE__*/ o("RadioGroupItem"), gt = /* @__PURE__ */ j({
1350
+ inheritAttrs: !1,
1351
+ __name: "RadioGroupItem",
1352
+ props: {
1353
+ id: {
1354
+ type: String,
1355
+ required: !1
1356
+ },
1357
+ value: {
1358
+ type: null,
1359
+ required: !1
1360
+ },
1361
+ disabled: {
1362
+ type: Boolean,
1363
+ required: !1,
1364
+ default: !1
1365
+ },
1366
+ asChild: {
1367
+ type: Boolean,
1368
+ required: !1
1369
+ },
1370
+ as: {
1371
+ type: null,
1372
+ required: !1,
1373
+ default: "button"
1374
+ },
1375
+ name: {
1376
+ type: String,
1377
+ required: !1
1378
+ },
1379
+ required: {
1380
+ type: Boolean,
1381
+ required: !1
1382
+ }
1383
+ },
1384
+ emits: ["select"],
1385
+ setup(e, { emit: t }) {
1386
+ let n = e, i = t, { forwardRef: a, currentElement: o } = r(), s = dt(), c = C(() => s.disabled.value || n.disabled), l = C(() => s.required.value || n.required), u = C(() => Q(s.modelValue?.value, n.value));
1387
+ ht({
1388
+ disabled: c,
1389
+ checked: u
1390
+ });
1391
+ let d = B(!1), f = [
1392
+ "ArrowUp",
1393
+ "ArrowDown",
1394
+ "ArrowLeft",
1395
+ "ArrowRight"
1396
+ ];
1397
+ fe("keydown", (e) => {
1398
+ f.includes(e.key) && (d.value = !0);
1399
+ }), fe("keyup", () => {
1400
+ d.value = !1;
1401
+ });
1402
+ function p() {
1403
+ setTimeout(() => {
1404
+ d.value && o.value?.click();
1405
+ }, 0);
1406
+ }
1407
+ let m = xe();
1408
+ return (e, t) => (z(), w(K(Ze), {
1409
+ checked: u.value,
1410
+ disabled: c.value,
1411
+ "as-child": "",
1412
+ focusable: !c.value,
1413
+ active: u.value
1414
+ }, {
1415
+ default: q(() => [k(ut, N({
1416
+ ...K(m),
1417
+ ...e.$attrs,
1418
+ ...n
1419
+ }, {
1420
+ ref: K(a),
1421
+ checked: u.value,
1422
+ required: l.value,
1423
+ disabled: c.value,
1424
+ "onUpdate:checked": t[0] ||= (t) => K(s).changeModelValue(e.value),
1425
+ onSelect: t[1] ||= (e) => i("select", e),
1426
+ onKeydown: t[2] ||= Y(X(() => {}, ["prevent"]), ["enter"]),
1427
+ onFocus: p
1428
+ }), {
1429
+ default: q(() => [H(e.$slots, "default", {
1430
+ checked: u.value,
1431
+ required: l.value,
1432
+ disabled: c.value
1433
+ })]),
1434
+ _: 3
1435
+ }, 16, [
1436
+ "checked",
1437
+ "required",
1438
+ "disabled"
1439
+ ])]),
1440
+ _: 3
1441
+ }, 8, [
1442
+ "checked",
1443
+ "disabled",
1444
+ "focusable",
1445
+ "active"
1446
+ ]));
1447
+ }
1448
+ }), [_t, vt] = /*#__PURE__*/ o("ToggleGroupRoot"), yt = /* @__PURE__ */ j({
1449
+ __name: "ToggleGroupRoot",
1450
+ props: {
1451
+ rovingFocus: {
1452
+ type: Boolean,
1453
+ required: !1,
1454
+ default: !0
1455
+ },
1456
+ disabled: {
1457
+ type: Boolean,
1458
+ required: !1,
1459
+ default: !1
1460
+ },
1461
+ orientation: {
1462
+ type: String,
1463
+ required: !1
1464
+ },
1465
+ dir: {
1466
+ type: String,
1467
+ required: !1
1468
+ },
1469
+ loop: {
1470
+ type: Boolean,
1471
+ required: !1,
1472
+ default: !0
1473
+ },
1474
+ asChild: {
1475
+ type: Boolean,
1476
+ required: !1
1477
+ },
1478
+ as: {
1479
+ type: null,
1480
+ required: !1
1481
+ },
1482
+ name: {
1483
+ type: String,
1484
+ required: !1
1485
+ },
1486
+ required: {
1487
+ type: Boolean,
1488
+ required: !1
1489
+ },
1490
+ type: {
1491
+ type: String,
1492
+ required: !1
1493
+ },
1494
+ modelValue: {
1495
+ type: null,
1496
+ required: !1
1497
+ },
1498
+ defaultValue: {
1499
+ type: null,
1500
+ required: !1
1501
+ }
1502
+ },
1503
+ emits: ["update:modelValue"],
1504
+ setup(e, { emit: t }) {
1505
+ let n = e, i = t, { loop: a, rovingFocus: o, disabled: s, dir: c } = G(n), l = f(c), { forwardRef: u, currentElement: p } = r(), { modelValue: m, changeModelValue: h, isSingle: g } = Oe(n, i), _ = b(p);
1506
+ return vt({
1507
+ isSingle: g,
1508
+ modelValue: m,
1509
+ changeModelValue: h,
1510
+ dir: l,
1511
+ orientation: n.orientation,
1512
+ loop: a,
1513
+ rovingFocus: o,
1514
+ disabled: s
1515
+ }), (e, t) => (z(), w(U(K(o) ? K(Xe) : K(d)), {
1516
+ "as-child": "",
1517
+ orientation: K(o) ? e.orientation : void 0,
1518
+ dir: K(l),
1519
+ loop: K(o) ? K(a) : void 0
1520
+ }, {
1521
+ default: q(() => [k(K(d), {
1522
+ ref: K(u),
1523
+ role: "group",
1524
+ "as-child": e.asChild,
1525
+ as: e.as
1526
+ }, {
1527
+ default: q(() => [H(e.$slots, "default", { modelValue: K(m) }), K(_) && e.name ? (z(), w(x, {
1528
+ key: 0,
1529
+ name: e.name,
1530
+ required: e.required,
1531
+ value: K(m)
1532
+ }, null, 8, [
1533
+ "name",
1534
+ "required",
1535
+ "value"
1536
+ ])) : T("v-if", !0)]),
1537
+ _: 3
1538
+ }, 8, ["as-child", "as"])]),
1539
+ _: 3
1540
+ }, 8, [
1541
+ "orientation",
1542
+ "dir",
1543
+ "loop"
1544
+ ]));
1545
+ }
1546
+ }), bt = /* @__PURE__ */ j({
1547
+ inheritAttrs: !1,
1548
+ __name: "Toggle",
1549
+ props: {
1550
+ defaultValue: {
1551
+ type: Boolean,
1552
+ required: !1
1553
+ },
1554
+ modelValue: {
1555
+ type: [Boolean, null],
1556
+ required: !1,
1557
+ default: void 0
1558
+ },
1559
+ disabled: {
1560
+ type: Boolean,
1561
+ required: !1,
1562
+ default: !1
1563
+ },
1564
+ asChild: {
1565
+ type: Boolean,
1566
+ required: !1
1567
+ },
1568
+ as: {
1569
+ type: null,
1570
+ required: !1,
1571
+ default: "button"
1572
+ },
1573
+ name: {
1574
+ type: String,
1575
+ required: !1
1576
+ },
1577
+ required: {
1578
+ type: Boolean,
1579
+ required: !1
1580
+ }
1581
+ },
1582
+ emits: ["update:modelValue"],
1583
+ setup(e, { emit: t }) {
1584
+ let n = e, i = t, { forwardRef: a, currentElement: o } = r(), s = xe(), c = _t(null), l = Z(n, "modelValue", i, {
1585
+ defaultValue: n.defaultValue,
1586
+ passive: n.modelValue === void 0
1587
+ });
1588
+ function u() {
1589
+ l.value = !l.value;
1590
+ }
1591
+ let f = C(() => l.value ? "on" : "off"), p = b(o);
1592
+ return (e, t) => (z(), E(S, null, [k(K(d), N({
1593
+ ref: K(a),
1594
+ type: e.as === "button" ? "button" : void 0,
1595
+ "as-child": n.asChild,
1596
+ as: e.as,
1597
+ "aria-pressed": K(l),
1598
+ "data-state": f.value,
1599
+ "data-disabled": e.disabled ? "" : void 0,
1600
+ disabled: e.disabled
1601
+ }, {
1602
+ ...K(s),
1603
+ ...e.$attrs
1604
+ }, { onClick: u }), {
1605
+ default: q(() => [H(e.$slots, "default", {
1606
+ modelValue: K(l),
1607
+ disabled: e.disabled,
1608
+ pressed: K(l),
1609
+ state: f.value
1610
+ })]),
1611
+ _: 3
1612
+ }, 16, [
1613
+ "type",
1614
+ "as-child",
1615
+ "as",
1616
+ "aria-pressed",
1617
+ "data-state",
1618
+ "data-disabled",
1619
+ "disabled"
1620
+ ]), K(p) && e.name && !K(c) ? (z(), w(x, N({
1621
+ key: 0,
1622
+ type: "checkbox",
1623
+ name: e.name,
1624
+ value: K(l),
1625
+ required: e.required
1626
+ }, K(s)), null, 16, [
1627
+ "name",
1628
+ "value",
1629
+ "required"
1630
+ ])) : T("v-if", !0)], 64));
1631
+ }
1632
+ }), xt = /* @__PURE__ */ j({
1633
+ __name: "ToggleGroupItem",
1634
+ props: {
1635
+ value: {
1636
+ type: null,
1637
+ required: !0
1638
+ },
1639
+ disabled: {
1640
+ type: Boolean,
1641
+ required: !1
1642
+ },
1643
+ asChild: {
1644
+ type: Boolean,
1645
+ required: !1
1646
+ },
1647
+ as: {
1648
+ type: null,
1649
+ required: !1,
1650
+ default: "button"
1651
+ }
1652
+ },
1653
+ setup(e) {
1654
+ let t = e, n = _t(), i = C(() => n.disabled?.value || t.disabled), a = C(() => be(n.modelValue.value, t.value)), { forwardRef: o } = r(), s = xe();
1655
+ return (e, r) => (z(), w(U(K(n).rovingFocus.value ? K(Ze) : K(d)), N({ "as-child": "" }, K(n).rovingFocus.value ? {
1656
+ focusable: !i.value,
1657
+ active: a.value
1658
+ } : {}), {
1659
+ default: q(() => [k(K(bt), N({
1660
+ ...K(s),
1661
+ ...t
1662
+ }, {
1663
+ ref: K(o),
1664
+ disabled: i.value,
1665
+ "model-value": a.value,
1666
+ "onUpdate:modelValue": r[0] ||= (t) => K(n).changeModelValue(e.value)
1667
+ }), {
1668
+ default: q((t) => [H(e.$slots, "default", I(M(t)))]),
1669
+ _: 3
1670
+ }, 16, ["disabled", "model-value"])]),
1671
+ _: 3
1672
+ }, 16));
1673
+ }
1674
+ }), St = /* @__PURE__ */ j({
20
1675
  name: "HstButtonGroup",
21
1676
  props: {
22
1677
  title: {},
@@ -24,43 +1679,81 @@ var k = /* @__PURE__ */ u({
24
1679
  options: {}
25
1680
  },
26
1681
  emits: ["update:modelValue"],
27
- setup(i, { emit: c }) {
28
- let l = i, u = c, d = n(() => Array.isArray(l.options) ? l.options.map((e) => typeof e == "string" || typeof e == "number" ? {
1682
+ setup(e, { emit: t }) {
1683
+ let n = e, r = t, i = C(() => Array.isArray(n.options) ? n.options.map((e) => typeof e == "string" || typeof e == "number" ? {
29
1684
  value: e,
30
1685
  label: String(e)
31
- } : e) : Object.entries(l.options).map(([e, t]) => ({
1686
+ } : e) : Object.entries(n.options).map(([e, t]) => ({
32
1687
  value: e,
33
1688
  label: String(t)
34
1689
  })));
35
- function f(e) {
36
- u("update:modelValue", e);
1690
+ function a(e) {
1691
+ e != null && r("update:modelValue", e);
37
1692
  }
38
- return (n, c) => (h(), r(e, {
1693
+ return (t, n) => (z(), w(u, {
39
1694
  tag: "div",
40
- role: "group",
41
- title: i.title,
42
- class: "poveste-button-group flex-nowrap items-center"
1695
+ title: e.title,
1696
+ class: "poveste-button-group"
43
1697
  }, {
44
- actions: C(() => [v(n.$slots, "actions")]),
45
- default: C(() => [o("div", re, [(h(!0), a(t, null, _(d.value, ({ label: e, value: t }) => (h(), r(k, {
46
- key: t,
47
- class: "px-1 h-[22px] flex-1 rounded-[3px]!",
48
- color: t === i.modelValue ? "primary" : "flat",
49
- rounded: !1,
50
- onClick: (e) => f(t)
1698
+ actions: q(() => [H(t.$slots, "actions")]),
1699
+ default: q(() => [k(K(yt), {
1700
+ type: "single",
1701
+ class: "poveste-button-group-options",
1702
+ "data-slot": "options",
1703
+ "model-value": e.modelValue ?? null,
1704
+ "onUpdate:modelValue": a
51
1705
  }, {
52
- default: C(() => [s(y(e), 1)]),
53
- _: 2
54
- }, 1032, ["color", "onClick"]))), 128))])]),
1706
+ default: q(() => [(z(!0), E(S, null, V(i.value, ({ label: e, value: t }) => (z(), w(K(xt), {
1707
+ key: t,
1708
+ "as-child": "",
1709
+ value: t
1710
+ }, {
1711
+ default: q(() => [k(ge, {
1712
+ class: "poveste-button-group-option",
1713
+ "data-slot": "option"
1714
+ }, {
1715
+ default: q(() => [O(W(e), 1)]),
1716
+ _: 2
1717
+ }, 1024)]),
1718
+ _: 2
1719
+ }, 1032, ["value"]))), 128))]),
1720
+ _: 1
1721
+ }, 8, ["model-value"])]),
55
1722
  _: 3
56
1723
  }, 8, ["title"]));
57
1724
  }
58
- }), ae = {
1725
+ }), Ct = {
1726
+ class: "poveste-checkbox-visual",
1727
+ "data-slot": "visual"
1728
+ }, wt = {
59
1729
  width: "16",
60
1730
  height: "16",
61
1731
  viewBox: "0 0 24 24",
62
- class: "relative z-10"
63
- }, oe = ["stroke-dasharray", "stroke-dashoffset"], A = /* @__PURE__ */ u({
1732
+ class: "poveste-checkbox-visual-check",
1733
+ "data-slot": "visual-check"
1734
+ }, Tt = ["stroke-dasharray", "stroke-dashoffset"], Et = /* @__PURE__ */ j({
1735
+ name: "CheckboxVisual",
1736
+ props: { modelValue: { type: Boolean } },
1737
+ setup(e) {
1738
+ let t = e, n = B(), r = B(0), i = C(() => +!!t.modelValue), a = C(() => (1 - i.value) * r.value), o = B(!1);
1739
+ return ce(() => t.modelValue, () => {
1740
+ o.value = !0;
1741
+ }), ce(n, () => {
1742
+ r.value = n.value?.getTotalLength?.() ?? 21.21;
1743
+ }), (e, t) => (z(), E("span", Ct, [t[0] ||= D("span", {
1744
+ class: "poveste-checkbox-visual-box",
1745
+ "data-slot": "visual-box"
1746
+ }, null, -1), (z(), E("svg", wt, [D("path", {
1747
+ ref_key: "path",
1748
+ ref: n,
1749
+ d: "m 4 12 l 5 5 l 10 -10",
1750
+ fill: "none",
1751
+ class: F(o.value ? "poveste-checkbox-visual-animated" : void 0),
1752
+ "stroke-dasharray": r.value,
1753
+ "stroke-dashoffset": a.value
1754
+ }, null, 10, Tt)]))]));
1755
+ }
1756
+ }), Dt = ["data-checked"], Ot = /* @__PURE__ */ j({
64
1757
  name: "HstSimpleCheckbox",
65
1758
  props: {
66
1759
  modelValue: { type: Boolean },
@@ -68,30 +1761,25 @@ var k = /* @__PURE__ */ u({
68
1761
  },
69
1762
  emits: { "update:modelValue": (e) => !0 },
70
1763
  setup(e, { emit: t }) {
71
- let r = e, i = t;
72
- function s() {
73
- r.withToggle && i("update:modelValue", !r.modelValue);
74
- }
75
- S(() => r.modelValue, () => {
76
- p.value = !0;
77
- });
78
- let c = g(), l = g(0), u = n(() => +!!r.modelValue), d = n(() => (1 - u.value) * l.value), p = g(!1);
79
- return S(c, () => {
80
- l.value = c.value?.getTotalLength?.() ?? 21.21;
81
- }), (t, n) => (h(), a("div", {
82
- class: f(["poveste-simple-checkbox group text-white w-[16px] h-[16px] relative", { "cursor-pointer": e.withToggle }]),
83
- onClick: s
84
- }, [o("div", { class: f(["border border-solid group-active:bg-gray-500/20 rounded-sm box-border absolute inset-0 transition-border duration-150 ease-out group-hover:border-primary-500 group-hover:dark:border-primary-500", [e.modelValue ? "border-primary-500 border-8" : "border-black/25 dark:border-white/25 delay-150"]]) }, null, 2), (h(), a("svg", ae, [o("path", {
85
- ref_key: "path",
86
- ref: c,
87
- d: "m 4 12 l 5 5 l 10 -10",
88
- fill: "none",
89
- class: f(["stroke-white stroke-2 duration-200 ease-in-out", [p.value ? "transition-all" : "transition-none", { "delay-150": e.modelValue }]]),
90
- "stroke-dasharray": l.value,
91
- "stroke-dashoffset": d.value
92
- }, null, 10, oe)]))], 2));
1764
+ let n = t;
1765
+ return (t, r) => e.withToggle ? (z(), w(K(at), {
1766
+ key: 0,
1767
+ "model-value": e.modelValue ?? !1,
1768
+ class: "poveste-simple-checkbox poveste-simple-checkbox-interactive",
1769
+ "data-slot": "box",
1770
+ "data-checked": e.modelValue ? "" : void 0,
1771
+ "onUpdate:modelValue": r[0] ||= (e) => n("update:modelValue", e === !0)
1772
+ }, {
1773
+ default: q(() => [k(Et, { "model-value": e.modelValue }, null, 8, ["model-value"])]),
1774
+ _: 1
1775
+ }, 8, ["model-value", "data-checked"])) : (z(), E("span", {
1776
+ key: 1,
1777
+ class: "poveste-simple-checkbox",
1778
+ "data-slot": "box",
1779
+ "data-checked": e.modelValue ? "" : void 0
1780
+ }, [k(Et, { "model-value": e.modelValue }, null, 8, ["model-value"])], 8, Dt));
93
1781
  }
94
- }), se = /* @__PURE__ */ u({
1782
+ }), kt = /* @__PURE__ */ j({
95
1783
  name: "HstCheckbox",
96
1784
  props: {
97
1785
  modelValue: { type: [
@@ -102,36 +1790,32 @@ var k = /* @__PURE__ */ u({
102
1790
  title: {}
103
1791
  },
104
1792
  emits: { "update:modelValue": (e) => !0 },
105
- setup(t, { emit: i }) {
106
- let a = t, o = i;
107
- function s() {
108
- if (typeof a.modelValue == "string") {
109
- o("update:modelValue", a.modelValue === "false" ? "true" : "false");
110
- return;
111
- }
112
- o("update:modelValue", !a.modelValue);
113
- }
114
- let l = n(() => typeof a.modelValue == "string" ? a.modelValue !== "false" : a.modelValue ?? void 0);
115
- return (n, i) => (h(), r(e, {
116
- tag: "div",
117
- role: "checkbox",
118
- tabindex: "0",
119
- "aria-checked": l.value,
120
- class: "poveste-checkbox cursor-pointer items-center",
121
- title: t.title,
122
- onClick: i[0] ||= (e) => s(),
123
- onKeydown: [i[1] ||= T(E((e) => s(), ["prevent"]), ["enter"]), i[2] ||= T(E((e) => s(), ["prevent"]), ["space"])]
1793
+ setup(e, { emit: t }) {
1794
+ let n = e, r = t, i = C(() => typeof n.modelValue == "string"), a = C(() => typeof n.modelValue == "string" ? n.modelValue !== "false" : n.modelValue ?? void 0);
1795
+ return (t, n) => (z(), w(u, {
1796
+ class: "poveste-checkbox",
1797
+ title: e.title
124
1798
  }, {
125
- actions: C(() => [v(n.$slots, "actions")]),
126
- default: C(() => [c(A, { "model-value": l.value }, null, 8, ["model-value"])]),
1799
+ actions: q(() => [H(t.$slots, "actions")]),
1800
+ default: q(() => [k(K(at), {
1801
+ "model-value": i.value ? String(a.value) : a.value,
1802
+ "true-value": !i.value || "true",
1803
+ "false-value": i.value ? "false" : !1,
1804
+ class: "poveste-checkbox-box",
1805
+ "data-slot": "control",
1806
+ "onUpdate:modelValue": n[0] ||= (e) => r("update:modelValue", e)
1807
+ }, {
1808
+ default: q(() => [k(Ot, { "model-value": a.value }, null, 8, ["model-value"])]),
1809
+ _: 1
1810
+ }, 8, [
1811
+ "model-value",
1812
+ "true-value",
1813
+ "false-value"
1814
+ ])]),
127
1815
  _: 3
128
- }, 8, ["aria-checked", "title"]));
1816
+ }, 8, ["title"]));
129
1817
  }
130
- }), ce = { class: "-my-1" }, le = [
131
- "for",
132
- "onKeydown",
133
- "onClick"
134
- ], ue = /* @__PURE__ */ u({
1818
+ }), At = /* @__PURE__ */ j({
135
1819
  name: "HstCheckboxList",
136
1820
  props: {
137
1821
  title: {},
@@ -139,29 +1823,38 @@ var k = /* @__PURE__ */ u({
139
1823
  options: {}
140
1824
  },
141
1825
  emits: ["update:modelValue"],
142
- setup(i, { emit: l }) {
143
- let u = i, d = l, m = n(() => Array.isArray(u.options) ? Object.fromEntries(u.options.map((e) => typeof e == "string" ? [e, e] : [e.value, e.label])) : u.options);
144
- function g(e) {
145
- u.modelValue.includes(e) ? d("update:modelValue", u.modelValue.filter((t) => t !== e)) : d("update:modelValue", [...u.modelValue, e]);
146
- }
147
- return (n, l) => (h(), r(e, {
148
- role: "group",
149
- title: i.title,
150
- class: f(["poveste-checkbox-list cursor-text", n.$attrs.class]),
151
- style: p(n.$attrs.style)
1826
+ setup(e, { emit: t }) {
1827
+ let n = e, r = t, i = C(() => Array.isArray(n.options) ? Object.fromEntries(n.options.map((e) => typeof e == "string" ? [e, e] : [e.value, e.label])) : n.options);
1828
+ return (t, n) => (z(), w(u, {
1829
+ tag: "div",
1830
+ title: e.title,
1831
+ class: F(["poveste-checkbox-list", t.$attrs.class]),
1832
+ style: L(t.$attrs.style)
152
1833
  }, {
153
- actions: C(() => [v(n.$slots, "actions")]),
154
- default: C(() => [o("div", ce, [(h(!0), a(t, null, _(m.value, (e, t) => (h(), a("label", {
155
- key: t,
156
- tabindex: "0",
157
- for: `${t}-radio`,
158
- class: "cursor-pointer flex items-center relative py-1 group",
159
- onKeydown: [T(E((e) => g(t), ["prevent"]), ["enter"]), T(E((e) => g(t), ["prevent"]), ["space"])],
160
- onClick: (e) => g(t)
161
- }, [c(A, {
162
- "model-value": i.modelValue.includes(t),
163
- class: "mr-2"
164
- }, null, 8, ["model-value"]), s(" " + y(e), 1)], 40, le))), 128))])]),
1834
+ actions: q(() => [H(t.$slots, "actions")]),
1835
+ default: q(() => [k(K(et), {
1836
+ "model-value": e.modelValue,
1837
+ class: "poveste-checkbox-list-options",
1838
+ "data-slot": "options",
1839
+ "onUpdate:modelValue": n[0] ||= (e) => r("update:modelValue", e)
1840
+ }, {
1841
+ default: q(() => [(z(!0), E(S, null, V(i.value, (t, n) => (z(), w(K(st), {
1842
+ key: n,
1843
+ class: "poveste-checkbox-list-option",
1844
+ "data-slot": "option"
1845
+ }, {
1846
+ default: q(() => [k(K(at), {
1847
+ value: n,
1848
+ class: "poveste-checkbox-list-box",
1849
+ "data-slot": "control"
1850
+ }, {
1851
+ default: q(() => [k(Ot, { "model-value": e.modelValue.includes(n) }, null, 8, ["model-value"])]),
1852
+ _: 2
1853
+ }, 1032, ["value"]), O(" " + W(t), 1)]),
1854
+ _: 2
1855
+ }, 1024))), 128))]),
1856
+ _: 1
1857
+ }, 8, ["model-value"])]),
165
1858
  _: 3
166
1859
  }, 8, [
167
1860
  "title",
@@ -169,7 +1862,7 @@ var k = /* @__PURE__ */ u({
169
1862
  "style"
170
1863
  ]));
171
1864
  }
172
- }), de = { class: "flex flex-row gap-1" }, fe = ["value"], pe = /* @__PURE__ */ u({
1865
+ }), jt = { class: "flex flex-row gap-1" }, Mt = ["value"], Nt = /* @__PURE__ */ j({
173
1866
  name: "HstColorSelect",
174
1867
  inheritAttrs: !1,
175
1868
  props: {
@@ -177,14 +1870,14 @@ var k = /* @__PURE__ */ u({
177
1870
  modelValue: {}
178
1871
  },
179
1872
  emits: { "update:modelValue": (e) => !0 },
180
- setup(t, { emit: i }) {
181
- let a = t, s = i, c = n({
182
- get: () => a.modelValue,
1873
+ setup(e, { emit: t }) {
1874
+ let n = e, r = t, i = C({
1875
+ get: () => n.modelValue,
183
1876
  set: (e) => {
184
- s("update:modelValue", e);
1877
+ r("update:modelValue", e);
185
1878
  }
186
1879
  });
187
- function l(e, t = 15) {
1880
+ function a(e, t = 15) {
188
1881
  let n = !1, r = null, i = () => {
189
1882
  r == null ? n = !1 : (e(...r), r = null, setTimeout(i, t));
190
1883
  };
@@ -196,31 +1889,31 @@ var k = /* @__PURE__ */ u({
196
1889
  e(...a), n = !0, setTimeout(i, t);
197
1890
  };
198
1891
  }
199
- let u = l((e) => {
200
- s("update:modelValue", e);
1892
+ let o = a((e) => {
1893
+ r("update:modelValue", e);
201
1894
  });
202
- function m(e) {
203
- u(e);
1895
+ function s(e) {
1896
+ o(e);
204
1897
  }
205
- return (n, i) => (h(), r(e, {
206
- title: t.title,
207
- class: f(["poveste-select cursor-text items-center", n.$attrs.class]),
208
- style: p(n.$attrs.style)
1898
+ return (t, n) => (z(), w(u, {
1899
+ title: e.title,
1900
+ class: F(["poveste-select cursor-text items-center", t.$attrs.class]),
1901
+ style: L(t.$attrs.style)
209
1902
  }, {
210
- actions: C(() => [v(n.$slots, "actions")]),
211
- default: C(() => [o("div", de, [w(o("input", d({
212
- ...n.$attrs,
1903
+ actions: q(() => [H(t.$slots, "actions")]),
1904
+ default: q(() => [D("div", jt, [J(D("input", N({
1905
+ ...t.$attrs,
213
1906
  class: null,
214
1907
  style: null
215
1908
  }, {
216
- "onUpdate:modelValue": i[0] ||= (e) => c.value = e,
1909
+ "onUpdate:modelValue": n[0] ||= (e) => i.value = e,
217
1910
  type: "text",
218
1911
  class: "text-inherit bg-transparent w-full outline-none px-2 py-1 -my-1 border border-solid border-black/25 dark:border-white/25 focus:border-primary-500 dark:focus:border-primary-500 rounded-sm"
219
- }), null, 16), [[x, c.value]]), o("input", {
1912
+ }), null, 16), [[se, i.value]]), D("input", {
220
1913
  type: "color",
221
- value: t.modelValue,
222
- onInput: i[1] ||= ((e) => m(e.target.value))
223
- }, null, 40, fe)])]),
1914
+ value: e.modelValue,
1915
+ onInput: n[1] ||= ((e) => s(e.target.value))
1916
+ }, null, 40, Mt)])]),
224
1917
  _: 3
225
1918
  }, 8, [
226
1919
  "title",
@@ -228,35 +1921,36 @@ var k = /* @__PURE__ */ u({
228
1921
  "style"
229
1922
  ]));
230
1923
  }
231
- }), j = /* @__PURE__ */ u({
1924
+ }), $ = /* @__PURE__ */ j({
232
1925
  name: "HstCopyIcon",
233
1926
  props: { content: { type: [String, Function] } },
234
1927
  setup(e) {
235
- let t = e, { copy: n, copied: r } = te(), { polite: i } = ne();
236
- async function o() {
1928
+ let t = e, { copy: n, copied: r } = de(), { polite: i } = pe();
1929
+ async function a() {
237
1930
  let e = typeof t.content == "function" ? await t.content() : t.content;
238
1931
  await n(e), r.value && i("Copied");
239
1932
  }
240
- return (e, t) => w((h(), a("button", {
241
- type: "button",
242
- "aria-label": "Copy",
243
- class: "flex p-0 bg-transparent border-0 text-inherit opacity-50 hover:opacity-100 focus-visible:opacity-100 hover:text-primary-500 cursor-pointer",
244
- onClick: t[0] ||= (e) => o()
245
- }, [c(b(O), {
246
- icon: "carbon:copy-file",
247
- class: "w-4 h-4"
248
- })])), [[b(D), {
1933
+ return (e, t) => (z(), w(c, {
249
1934
  content: "Copied!",
250
- triggers: [],
251
- shown: b(r),
252
- distance: 12,
253
- delay: 0
254
- }]]);
1935
+ open: K(r),
1936
+ offset: 12
1937
+ }, {
1938
+ default: q(() => [D("button", {
1939
+ type: "button",
1940
+ "aria-label": "Copy",
1941
+ class: "flex p-0 bg-transparent border-0 text-inherit opacity-50 hover:opacity-100 focus-visible:opacity-100 hover:text-primary-500 cursor-pointer",
1942
+ onClick: t[0] ||= (e) => a()
1943
+ }, [k(K(me), {
1944
+ icon: "carbon:copy-file",
1945
+ class: "w-4 h-4"
1946
+ })])]),
1947
+ _: 1
1948
+ }, 8, ["open"]));
255
1949
  }
256
- }), me = {
1950
+ }), Pt = {
257
1951
  key: 0,
258
1952
  class: "poveste-color-shades grid gap-4 grid-cols-[repeat(auto-fill,minmax(200px,1fr))] m-4"
259
- }, he = ["onMouseenter"], ge = { class: "flex gap-1" }, _e = { class: "my-0 truncate shrink" }, M = { class: "flex gap-1" }, N = { class: "my-0 opacity-50 truncate shrink" }, P = /* @__PURE__ */ u({
1953
+ }, Ft = ["onMouseenter"], It = { class: "flex gap-1" }, Lt = { class: "my-0 truncate shrink" }, Rt = { class: "flex gap-1" }, zt = { class: "my-0 opacity-50 truncate shrink" }, Bt = /* @__PURE__ */ j({
260
1954
  name: "HstColorShades",
261
1955
  props: {
262
1956
  shades: {},
@@ -264,50 +1958,56 @@ var k = /* @__PURE__ */ u({
264
1958
  search: {}
265
1959
  },
266
1960
  setup(e) {
267
- let c = e;
268
- function l(e, t = "") {
269
- return Object.entries(e).reduce((e, [n, r]) => {
270
- let i = t ? n === "DEFAULT" ? t : `${t}-${n}` : n, a = typeof r == "object" ? l(r, i) : { [i]: r };
1961
+ let t = e;
1962
+ function n(e, t = "") {
1963
+ return Object.entries(e).reduce((e, [r, i]) => {
1964
+ let a = t ? r === "DEFAULT" ? t : `${t}-${r}` : r, o = typeof i == "object" ? n(i, a) : { [a]: i };
271
1965
  return {
272
1966
  ...e,
273
- ...a
1967
+ ...o
274
1968
  };
275
1969
  }, {});
276
1970
  }
277
- let u = n(() => {
278
- let e = c.shades, t = c.getName, n = l(e);
279
- return Object.entries(n).map(([e, n]) => ({
1971
+ let r = C(() => {
1972
+ let e = t.shades, r = t.getName, i = n(e);
1973
+ return Object.entries(i).map(([e, t]) => ({
280
1974
  key: e,
281
- color: n,
282
- name: t ? t(e, n) : e
1975
+ color: t,
1976
+ name: r ? r(e, t) : e
283
1977
  }));
284
- }), d = n(() => {
285
- let e = u.value;
286
- if (c.search) {
287
- let t = new RegExp(c.search, "i");
288
- e = e.filter(({ name: e }) => t.test(e));
1978
+ }), i = C(() => {
1979
+ let e = r.value;
1980
+ if (t.search) {
1981
+ let n = new RegExp(t.search, "i");
1982
+ e = e.filter(({ name: e }) => n.test(e));
289
1983
  }
290
1984
  return e;
291
- }), f = g(null);
292
- return (e, n) => d.value.length ? (h(), a("div", me, [(h(!0), a(t, null, _(d.value, (t) => (h(), a("div", {
293
- key: t.key,
1985
+ }), a = B(null);
1986
+ return (e, t) => i.value.length ? (z(), E("div", Pt, [(z(!0), E(S, null, V(i.value, (n) => (z(), E("div", {
1987
+ key: n.key,
294
1988
  class: "flex flex-col gap-2",
295
- onMouseenter: (e) => f.value = t.key,
296
- onMouseleave: n[0] ||= (e) => f.value = null
297
- }, [v(e.$slots, "default", { color: t.color }, () => [o("div", {
1989
+ onMouseenter: (e) => a.value = n.key,
1990
+ onMouseleave: t[0] ||= (e) => a.value = null
1991
+ }, [H(e.$slots, "default", { color: n.color }, () => [D("div", {
298
1992
  class: "rounded-full w-16 h-16",
299
- style: p({ backgroundColor: t.color })
300
- }, null, 4)]), o("div", null, [o("div", ge, [w((h(), a("pre", _e, [s(y(t.name), 1)])), [[b(D), t.name.length > 23 ? t.name : ""]]), f.value === t.key ? (h(), r(j, {
1993
+ style: L({ backgroundColor: n.color })
1994
+ }, null, 4)]), D("div", null, [D("div", It, [k(c, { content: n.name.length > 23 ? n.name : "" }, {
1995
+ default: q(() => [D("pre", Lt, W(n.name), 1)]),
1996
+ _: 2
1997
+ }, 1032, ["content"]), a.value === n.key ? (z(), w($, {
301
1998
  key: 0,
302
- content: t.name,
1999
+ content: n.name,
303
2000
  class: "flex-none"
304
- }, null, 8, ["content"])) : i("", !0)]), o("div", M, [w((h(), a("pre", N, [s(y(t.color), 1)])), [[b(D), t.color.length > 23 ? t.color : ""]]), f.value === t.key ? (h(), r(j, {
2001
+ }, null, 8, ["content"])) : T("", !0)]), D("div", Rt, [k(c, { content: n.color.length > 23 ? n.color : "" }, {
2002
+ default: q(() => [D("pre", zt, W(n.color), 1)]),
2003
+ _: 2
2004
+ }, 1032, ["content"]), a.value === n.key ? (z(), w($, {
305
2005
  key: 0,
306
- content: t.color,
2006
+ content: n.color,
307
2007
  class: "flex-none"
308
- }, null, 8, ["content"])) : i("", !0)])])], 40, he))), 128))])) : i("", !0);
2008
+ }, null, 8, ["content"])) : T("", !0)])])], 40, Ft))), 128))])) : T("", !0);
309
2009
  }
310
- }), F = ["onMouseenter"], I = { class: "flex gap-1" }, ve = { class: "my-0 truncate shrink" }, ye = { class: "flex gap-1" }, be = { class: "my-0 opacity-50 truncate shrink" }, xe = /* @__PURE__ */ u({
2010
+ }), Vt = ["onMouseenter"], Ht = { class: "flex gap-1" }, Ut = { class: "my-0 truncate shrink" }, Wt = { class: "flex gap-1" }, Gt = { class: "my-0 opacity-50 truncate shrink" }, Kt = /* @__PURE__ */ j({
311
2011
  name: "HstTokenGrid",
312
2012
  props: {
313
2013
  tokens: {},
@@ -315,63 +2015,72 @@ var k = /* @__PURE__ */ u({
315
2015
  getName: {}
316
2016
  },
317
2017
  setup(e) {
318
- let c = e, l = n(() => {
319
- let e = c.tokens, t = c.getName;
320
- return Object.entries(e).map(([e, n]) => ({
2018
+ let t = e, n = C(() => {
2019
+ let e = t.tokens, n = t.getName;
2020
+ return Object.entries(e).map(([e, t]) => ({
321
2021
  key: e,
322
- name: t ? t(e, n) : e,
323
- value: typeof n == "number" ? n.toString() : n
2022
+ name: n ? n(e, t) : e,
2023
+ value: typeof t == "number" ? t.toString() : t
324
2024
  }));
325
- }), u = n(() => `${c.colSize}px`), d = g(null);
326
- return (n, c) => (h(), a("div", {
2025
+ }), r = C(() => `${t.colSize}px`), i = B(null);
2026
+ function a(e, t) {
2027
+ return typeof e != "string" && !Array.isArray(e) ? "" : e.length > t ? String(e) : "";
2028
+ }
2029
+ return (t, o) => (z(), E("div", {
327
2030
  class: "poveste-token-grid bind-col-size grid gap-4 m-4",
328
- style: p({ "--poveste-col-size": u.value })
329
- }, [(h(!0), a(t, null, _(l.value, (t) => (h(), a("div", {
330
- key: t.key,
2031
+ style: L({ "--poveste-col-size": r.value })
2032
+ }, [(z(!0), E(S, null, V(n.value, (n) => (z(), E("div", {
2033
+ key: n.key,
331
2034
  class: "flex flex-col gap-2",
332
- onMouseenter: (e) => d.value = t.key,
333
- onMouseleave: c[0] ||= (e) => d.value = null
334
- }, [v(n.$slots, "default", { token: t }), o("div", null, [o("div", I, [w((h(), a("pre", ve, [s(y(t.name), 1)])), [[b(D), t.name.length > e.colSize / 8 ? t.name : ""]]), d.value === t.key ? (h(), r(j, {
2035
+ onMouseenter: (e) => i.value = n.key,
2036
+ onMouseleave: o[0] ||= (e) => i.value = null
2037
+ }, [H(t.$slots, "default", { token: n }), D("div", null, [D("div", Ht, [k(c, { content: n.name.length > e.colSize / 8 ? n.name : "" }, {
2038
+ default: q(() => [D("pre", Ut, W(n.name), 1)]),
2039
+ _: 2
2040
+ }, 1032, ["content"]), i.value === n.key ? (z(), w($, {
335
2041
  key: 0,
336
- content: t.name,
2042
+ content: n.name,
337
2043
  class: "flex-none"
338
- }, null, 8, ["content"])) : i("", !0)]), o("div", ye, [w((h(), a("pre", be, [s(y(t.value), 1)])), [[b(D), t.value.length > e.colSize / 8 ? t.value : ""]]), d.value === t.key ? (h(), r(j, {
2044
+ }, null, 8, ["content"])) : T("", !0)]), D("div", Wt, [k(c, { content: a(n.value, e.colSize / 8) }, {
2045
+ default: q(() => [D("pre", Gt, W(n.value), 1)]),
2046
+ _: 2
2047
+ }, 1032, ["content"]), i.value === n.key ? (z(), w($, {
339
2048
  key: 0,
340
- content: typeof t.value == "string" ? t.value : JSON.stringify(t.value),
2049
+ content: typeof n.value == "string" ? n.value : JSON.stringify(n.value),
341
2050
  class: "flex-none"
342
- }, null, 8, ["content"])) : i("", !0)])])], 40, F))), 128))], 4));
2051
+ }, null, 8, ["content"])) : T("", !0)])])], 40, Vt))), 128))], 4));
343
2052
  }
344
- }), Se = ["onMouseenter"], Ce = { class: "mx-4" }, we = { class: "flex gap-1" }, Te = { class: "my-0 truncate shrink" }, Ee = { class: "flex gap-1" }, De = { class: "my-0 opacity-50 truncate shrink" }, Oe = /* @__PURE__ */ u({
2053
+ }), qt = ["onMouseenter"], Jt = { class: "mx-4" }, Yt = { class: "flex gap-1" }, Xt = { class: "my-0 truncate shrink" }, Zt = { class: "flex gap-1" }, Qt = { class: "my-0 opacity-50 truncate shrink" }, $t = /* @__PURE__ */ j({
345
2054
  name: "HstTokenList",
346
2055
  props: {
347
2056
  tokens: {},
348
2057
  getName: { type: Function }
349
2058
  },
350
2059
  setup(e) {
351
- let s = e, c = n(() => {
352
- let e = s.tokens, t = s.getName;
353
- return Object.entries(e).map(([e, n]) => ({
2060
+ let t = e, n = C(() => {
2061
+ let e = t.tokens, n = t.getName;
2062
+ return Object.entries(e).map(([e, t]) => ({
354
2063
  key: e,
355
- name: t ? t(e, n) : e,
356
- value: typeof n == "number" ? n.toString() : n
2064
+ name: n ? n(e, t) : e,
2065
+ value: typeof t == "number" ? t.toString() : t
357
2066
  }));
358
- }), l = g(null);
359
- return (e, n) => (h(!0), a(t, null, _(c.value, (t) => (h(), a("div", {
360
- key: t.key,
2067
+ }), r = B(null);
2068
+ return (e, t) => (z(!0), E(S, null, V(n.value, (n) => (z(), E("div", {
2069
+ key: n.key,
361
2070
  class: "poveste-token-list flex flex-col gap-2 my-8",
362
- onMouseenter: (e) => l.value = t.key,
363
- onMouseleave: n[0] ||= (e) => l.value = null
364
- }, [v(e.$slots, "default", { token: t }), o("div", Ce, [o("div", we, [o("pre", Te, y(t.name), 1), l.value === t.key ? (h(), r(j, {
2071
+ onMouseenter: (e) => r.value = n.key,
2072
+ onMouseleave: t[0] ||= (e) => r.value = null
2073
+ }, [H(e.$slots, "default", { token: n }), D("div", Jt, [D("div", Yt, [D("pre", Xt, W(n.name), 1), r.value === n.key ? (z(), w($, {
365
2074
  key: 0,
366
- content: t.name,
2075
+ content: n.name,
367
2076
  class: "flex-none"
368
- }, null, 8, ["content"])) : i("", !0)]), o("div", Ee, [o("pre", De, y(t.value), 1), l.value === t.key ? (h(), r(j, {
2077
+ }, null, 8, ["content"])) : T("", !0)]), D("div", Zt, [D("pre", Qt, W(n.value), 1), r.value === n.key ? (z(), w($, {
369
2078
  key: 0,
370
- content: typeof t.value == "string" ? t.value : JSON.stringify(t.value),
2079
+ content: typeof n.value == "string" ? n.value : JSON.stringify(n.value),
371
2080
  class: "flex-none"
372
- }, null, 8, ["content"])) : i("", !0)])])], 40, Se))), 128));
2081
+ }, null, 8, ["content"])) : T("", !0)])])], 40, qt))), 128));
373
2082
  }
374
- }), L = /* @__PURE__ */ u({
2083
+ }), en = /* @__PURE__ */ j({
375
2084
  name: "HstNumber",
376
2085
  inheritAttrs: !1,
377
2086
  props: {
@@ -379,51 +2088,53 @@ var k = /* @__PURE__ */ u({
379
2088
  modelValue: {}
380
2089
  },
381
2090
  emits: { "update:modelValue": (e) => !0 },
382
- setup(t, { emit: i }) {
383
- let a = t, s = i, c = n({
384
- get: () => a.modelValue,
2091
+ setup(e, { emit: t }) {
2092
+ let n = e, r = t, i = C({
2093
+ get: () => n.modelValue,
385
2094
  set: (e) => {
386
- s("update:modelValue", e);
2095
+ r("update:modelValue", e);
387
2096
  }
388
- }), l = g();
389
- function u() {
390
- l.value?.focus(), l.value?.select();
391
- }
392
- let _ = g(!1), y, b;
393
- function S(e) {
394
- _.value = !0, y = e.clientX, b = c.value ?? 0, window.addEventListener("mousemove", T), window.addEventListener("mouseup", E);
395
- }
396
- function T(e) {
397
- let t = Number.parseFloat(l.value?.step ?? "");
398
- Number.isNaN(t) && (t = 1), c.value = b + Math.round((e.clientX - y) / 10 / t) * t;
399
- }
400
- function E() {
401
- _.value = !1, window.removeEventListener("mousemove", T), window.removeEventListener("mouseup", E);
402
- }
403
- return m(() => {
404
- E();
405
- }), (n, i) => (h(), r(e, {
406
- class: f(["poveste-number cursor-ew-resize items-center", [n.$attrs.class, { "select-none": _.value }]]),
407
- title: t.title,
408
- style: p(n.$attrs.style),
409
- onClick: u,
410
- onMousedown: S
2097
+ }), a = B();
2098
+ function o() {
2099
+ a.value?.focus(), a.value?.select();
2100
+ }
2101
+ let s = B(!1), c, l;
2102
+ function d(e) {
2103
+ s.value = !0, c = e.clientX, l = i.value ?? 0, window.addEventListener("mousemove", f), window.addEventListener("mouseup", p);
2104
+ }
2105
+ function f(e) {
2106
+ let t = Number.parseFloat(a.value?.step ?? "");
2107
+ Number.isNaN(t) && (t = 1), i.value = l + Math.round((e.clientX - c) / 10 / t) * t;
2108
+ }
2109
+ function p() {
2110
+ s.value = !1, window.removeEventListener("mousemove", f), window.removeEventListener("mouseup", p);
2111
+ }
2112
+ return R(() => {
2113
+ p();
2114
+ }), (t, n) => (z(), w(u, {
2115
+ class: F(["poveste-number", t.$attrs.class]),
2116
+ title: e.title,
2117
+ style: L(t.$attrs.style),
2118
+ "data-dragging": s.value ? "" : void 0,
2119
+ onClick: o,
2120
+ onMousedown: d
411
2121
  }, {
412
- actions: C(() => [v(n.$slots, "actions")]),
413
- default: C(() => [w(o("input", d({
2122
+ actions: q(() => [H(t.$slots, "actions")]),
2123
+ default: q(() => [J(D("input", N({
414
2124
  ref_key: "input",
415
- ref: l
2125
+ ref: a
416
2126
  }, {
417
- ...n.$attrs,
2127
+ ...t.$attrs,
418
2128
  class: null,
419
2129
  style: null
420
2130
  }, {
421
- "onUpdate:modelValue": i[0] ||= (e) => c.value = e,
2131
+ "onUpdate:modelValue": n[0] ||= (e) => i.value = e,
422
2132
  type: "number",
423
- class: [{ "select-none": _.value }, "text-inherit bg-transparent w-full outline-none pl-2 py-1 -my-1 border border-solid border-black/25 dark:border-white/25 focus:border-primary-500 dark:focus:border-primary-500 rounded-sm cursor-ew-resize box-border"]
2133
+ class: "poveste-number-input",
2134
+ "data-slot": "control"
424
2135
  }), null, 16), [[
425
- x,
426
- c.value,
2136
+ se,
2137
+ i.value,
427
2138
  void 0,
428
2139
  { number: !0 }
429
2140
  ]])]),
@@ -431,16 +2142,11 @@ var k = /* @__PURE__ */ u({
431
2142
  }, 8, [
432
2143
  "title",
433
2144
  "class",
434
- "style"
2145
+ "style",
2146
+ "data-dragging"
435
2147
  ]));
436
2148
  }
437
- }), ke = { class: "-my-1" }, Ae = [
438
- "id",
439
- "name",
440
- "value",
441
- "checked",
442
- "onChange"
443
- ], je = ["for", "onKeydown"], Me = /* @__PURE__ */ u({
2149
+ }), tn = /* @__PURE__ */ j({
444
2150
  name: "HstRadio",
445
2151
  props: {
446
2152
  title: {},
@@ -448,45 +2154,41 @@ var k = /* @__PURE__ */ u({
448
2154
  options: {}
449
2155
  },
450
2156
  emits: ["update:modelValue"],
451
- setup(i, { emit: c }) {
452
- let l = i, u = c, d = n(() => Array.isArray(l.options) ? Object.fromEntries(l.options.map((e) => typeof e == "string" ? [e, e] : [e.value, e.label])) : l.options);
453
- function m(e) {
454
- u("update:modelValue", e), b.value = !0;
455
- }
456
- let b = g(!1);
457
- return (n, c) => (h(), r(e, {
458
- role: "group",
459
- title: i.title,
460
- class: f(["poveste-radio cursor-text", n.$attrs.class]),
461
- style: p(n.$attrs.style)
2157
+ setup(e, { emit: t }) {
2158
+ let n = e, r = t, i = C(() => Array.isArray(n.options) ? Object.fromEntries(n.options.map((e) => typeof e == "string" ? [e, e] : [e.value, e.label])) : n.options);
2159
+ return (t, n) => (z(), w(u, {
2160
+ tag: "div",
2161
+ title: e.title,
2162
+ class: F(["poveste-radio", t.$attrs.class]),
2163
+ style: L(t.$attrs.style)
462
2164
  }, {
463
- actions: C(() => [v(n.$slots, "actions")]),
464
- default: C(() => [o("div", ke, [(h(!0), a(t, null, _(d.value, (e, n) => (h(), a(t, { key: n }, [o("input", {
465
- id: `${n}-radio_${i.title}`,
466
- type: "radio",
467
- name: `${n}-radio_${i.title}`,
468
- value: n,
469
- checked: n === i.modelValue,
470
- class: "hidden!",
471
- onChange: (e) => m(n)
472
- }, null, 40, Ae), o("label", {
473
- tabindex: "0",
474
- for: `${n}-radio_${i.title}`,
475
- class: "cursor-pointer flex items-center relative py-1 group",
476
- onKeydown: [T(E((e) => m(n), ["prevent"]), ["enter"]), T(E((e) => m(n), ["prevent"]), ["space"])]
477
- }, [(h(), a("svg", {
478
- width: "16",
479
- height: "16",
480
- viewBox: "-12 -12 24 24",
481
- class: f(["relative z-10 border border-solid text-inherit rounded-full box-border inset-0 transition-border duration-150 ease-out mr-2 group-hover:border-primary-500", [i.modelValue === n ? "border-primary-500" : "border-black/25 dark:border-white/25"]])
482
- }, [o("circle", {
483
- r: "7",
484
- class: f(["will-change-transform", [
485
- b.value ? "transition-all" : "transition-none",
486
- { "delay-150": i.modelValue === n },
487
- i.modelValue === n ? "fill-primary-500" : "fill-transparent scale-0"
488
- ]])
489
- }, null, 2)], 2)), s(" " + y(e), 1)], 40, je)], 64))), 128))])]),
2165
+ actions: q(() => [H(t.$slots, "actions")]),
2166
+ default: q(() => [k(K(pt), {
2167
+ "model-value": e.modelValue ?? null,
2168
+ class: "poveste-radio-options",
2169
+ "data-slot": "options",
2170
+ "onUpdate:modelValue": n[0] ||= (e) => r("update:modelValue", e)
2171
+ }, {
2172
+ default: q(() => [(z(!0), E(S, null, V(i.value, (e, t) => (z(), w(K(st), {
2173
+ key: t,
2174
+ class: "poveste-radio-option",
2175
+ "data-slot": "option"
2176
+ }, {
2177
+ default: q(() => [k(K(gt), {
2178
+ value: t,
2179
+ class: "poveste-radio-box",
2180
+ "data-slot": "control"
2181
+ }, {
2182
+ default: q(() => [...n[1] ||= [D("span", {
2183
+ class: "poveste-radio-dot",
2184
+ "data-slot": "dot"
2185
+ }, null, -1)]]),
2186
+ _: 1
2187
+ }, 8, ["value"]), O(" " + W(e), 1)]),
2188
+ _: 2
2189
+ }, 1024))), 128))]),
2190
+ _: 1
2191
+ }, 8, ["model-value"])]),
490
2192
  _: 3
491
2193
  }, 8, [
492
2194
  "title",
@@ -494,39 +2196,82 @@ var k = /* @__PURE__ */ u({
494
2196
  "style"
495
2197
  ]));
496
2198
  }
497
- }), Ne = { class: "cursor-pointer w-full outline-none px-2 h-[27px] -my-1 border border-solid border-black/25 dark:border-white/25 hover:border-primary-500 dark:hover:border-primary-500 rounded-sm flex gap-2 items-center leading-normal" }, Pe = { class: "flex-1 truncate" }, Fe = { class: "flex flex-col bg-gray-50 dark:bg-gray-700" }, Ie = ["onClick"], Le = /* @__PURE__ */ u({
2199
+ }), nn = {
2200
+ type: "button",
2201
+ class: "poveste-select-trigger",
2202
+ "data-slot": "trigger"
2203
+ }, rn = {
2204
+ class: "poveste-select-label",
2205
+ "data-slot": "value"
2206
+ }, an = /* @__PURE__ */ j({
498
2207
  name: "CustomSelect",
499
2208
  props: {
500
2209
  modelValue: {},
501
2210
  options: {}
502
2211
  },
503
2212
  emits: ["update:modelValue"],
504
- setup(e, { emit: i }) {
505
- let l = e, u = i, f = n(() => Array.isArray(l.options) ? l.options.map((e) => typeof e == "string" || typeof e == "number" ? [e, String(e)] : [e.value, e.label]) : Object.entries(l.options)), p = n(() => f.value.find(([e]) => e === l.modelValue)?.[1]);
506
- function m(e, t) {
507
- u("update:modelValue", e), t();
508
- }
509
- return (e, n) => (h(), r(b(ee), {
510
- "auto-size": "",
511
- "auto-boundary-max-size": ""
2213
+ setup(e, { emit: t }) {
2214
+ let n = e, r = t, i = B(!1), a = ae();
2215
+ ie(() => {
2216
+ a.value = l();
2217
+ });
2218
+ let o = C(() => Array.isArray(n.options) ? n.options.map((e) => typeof e == "string" || typeof e == "number" ? [e, String(e)] : [e.value, e.label]) : Object.entries(n.options)), s = C(() => o.value.find(([e]) => e === n.modelValue)?.[1]);
2219
+ function c(e) {
2220
+ e != null && (r("update:modelValue", e), i.value = !1);
2221
+ }
2222
+ return (t, n) => (z(), w(K(m), {
2223
+ open: i.value,
2224
+ "onUpdate:open": n[0] ||= (e) => i.value = e
512
2225
  }, {
513
- popper: C(({ hide: n }) => [o("div", Fe, [(h(!0), a(t, null, _(f.value, ([t, r]) => (h(), a("div", d({ ref_for: !0 }, {
514
- ...e.$attrs,
515
- class: null,
516
- style: null
2226
+ default: q(() => [k(K(y), { "as-child": "" }, {
2227
+ default: q(() => [D("button", nn, [D("span", rn, [H(t.$slots, "default", { label: s.value }, () => [O(W(s.value), 1)])]), k(K(me), {
2228
+ icon: "carbon:chevron-sort",
2229
+ class: "poveste-select-chevron"
2230
+ })])]),
2231
+ _: 3
2232
+ }), a.value ? (z(), w(K(h), {
2233
+ key: 0,
2234
+ to: a.value
517
2235
  }, {
518
- key: r,
519
- class: ["px-2 py-1 cursor-pointer hover:bg-primary-100 dark:hover:bg-primary-700", { "bg-primary-200 dark:bg-primary-800": l.modelValue === t }],
520
- onClick: (e) => m(t, n)
521
- }), y(r), 17, Ie))), 128))])]),
522
- default: C(() => [o("div", Ne, [o("div", Pe, [v(e.$slots, "default", { label: p.value }, () => [s(y(p.value), 1)])]), c(b(O), {
523
- icon: "carbon:chevron-sort",
524
- class: "w-4 h-4 flex-none ml-auto"
525
- })])]),
2236
+ default: q(() => [k(K(_), {
2237
+ class: "poveste-select-popper",
2238
+ align: "start",
2239
+ "side-offset": 6,
2240
+ "collision-padding": 8
2241
+ }, {
2242
+ default: q(() => [k(K(He), {
2243
+ class: "poveste-select-options",
2244
+ "data-slot": "options",
2245
+ "selection-behavior": "replace",
2246
+ "highlight-on-hover": "",
2247
+ "model-value": e.modelValue,
2248
+ "onUpdate:modelValue": c
2249
+ }, {
2250
+ default: q(() => [k(K(Ue), {
2251
+ class: "poveste-select-list",
2252
+ "data-slot": "listbox"
2253
+ }, {
2254
+ default: q(() => [(z(!0), E(S, null, V(o.value, ([e, t]) => (z(), w(K(qe), {
2255
+ key: t,
2256
+ class: "poveste-select-option",
2257
+ "data-slot": "option",
2258
+ value: e
2259
+ }, {
2260
+ default: q(() => [O(W(t), 1)]),
2261
+ _: 2
2262
+ }, 1032, ["value"]))), 128))]),
2263
+ _: 1
2264
+ })]),
2265
+ _: 1
2266
+ }, 8, ["model-value"])]),
2267
+ _: 1
2268
+ })]),
2269
+ _: 1
2270
+ }, 8, ["to"])) : T("", !0)]),
526
2271
  _: 3
527
- }));
2272
+ }, 8, ["open"]));
528
2273
  }
529
- }), Re = /* @__PURE__ */ u({
2274
+ }), on = /* @__PURE__ */ j({
530
2275
  name: "HstSelect",
531
2276
  props: {
532
2277
  title: {},
@@ -534,18 +2279,19 @@ var k = /* @__PURE__ */ u({
534
2279
  options: {}
535
2280
  },
536
2281
  emits: ["update:modelValue"],
537
- setup(t, { emit: n }) {
538
- let i = n;
539
- return (n, a) => (h(), r(e, {
540
- title: t.title,
541
- class: f(["poveste-select cursor-text items-center", n.$attrs.class]),
542
- style: p(n.$attrs.style)
2282
+ setup(e, { emit: t }) {
2283
+ let n = t;
2284
+ return (t, r) => (z(), w(u, {
2285
+ title: e.title,
2286
+ class: F(["poveste-select", t.$attrs.class]),
2287
+ "data-slot": "control",
2288
+ style: L(t.$attrs.style)
543
2289
  }, {
544
- actions: C(() => [v(n.$slots, "actions")]),
545
- default: C(() => [c(Le, {
546
- options: t.options,
547
- "model-value": t.modelValue,
548
- "onUpdate:modelValue": a[0] ||= (e) => i("update:modelValue", e)
2290
+ actions: q(() => [H(t.$slots, "actions")]),
2291
+ default: q(() => [k(an, {
2292
+ options: e.options,
2293
+ "model-value": e.modelValue,
2294
+ "onUpdate:modelValue": r[0] ||= (e) => n("update:modelValue", e)
549
2295
  }, null, 8, ["options", "model-value"])]),
550
2296
  _: 3
551
2297
  }, 8, [
@@ -554,7 +2300,10 @@ var k = /* @__PURE__ */ u({
554
2300
  "style"
555
2301
  ]));
556
2302
  }
557
- }), ze = { class: "relative w-full flex items-center" }, Be = /* @__PURE__ */ u({
2303
+ }), sn = {
2304
+ class: "poveste-slider-field",
2305
+ "data-slot": "field"
2306
+ }, cn = /* @__PURE__ */ j({
558
2307
  name: "HstSlider",
559
2308
  inheritAttrs: !1,
560
2309
  props: {
@@ -564,51 +2313,55 @@ var k = /* @__PURE__ */ u({
564
2313
  max: {}
565
2314
  },
566
2315
  emits: { "update:modelValue": (e) => !0 },
567
- setup(t, { emit: s }) {
568
- let c = t, l = s, u = g(!1), m = g(null), _ = n({
569
- get: () => c.modelValue,
2316
+ setup(e, { emit: t }) {
2317
+ let n = e, r = t, i = B(!1), a = C({
2318
+ get: () => n.modelValue,
570
2319
  set: (e) => {
571
- l("update:modelValue", e);
2320
+ r("update:modelValue", e);
572
2321
  }
573
- }), v = n(() => ((c.modelValue ?? c.min) - c.min) / (c.max - c.min)), y = n(() => m.value ? { left: `${8 + (m.value.clientWidth - 16) * v.value}px` } : {});
574
- return (n, s) => (h(), r(e, {
575
- class: f(["poveste-slider items-center", n.$attrs.class]),
576
- title: t.title,
577
- style: p(n.$attrs.style)
2322
+ }), o = C(() => ((n.modelValue ?? n.min) - n.min) / (n.max - n.min)), s = C(() => ({ "--_poveste-slider-fraction": String(o.value) }));
2323
+ return (t, n) => (z(), w(u, {
2324
+ class: F(["poveste-slider", t.$attrs.class]),
2325
+ title: e.title,
2326
+ style: L(t.$attrs.style)
578
2327
  }, {
579
- default: C(() => [o("div", ze, [
580
- s[3] ||= o("div", { class: "absolute inset-0 flex items-center" }, [o("div", { class: "border border-black/25 dark:border-white/25 h-1 w-full rounded-full" })], -1),
581
- w(o("input", d({
582
- ref_key: "input",
583
- ref: m,
584
- "onUpdate:modelValue": s[0] ||= (e) => _.value = e,
585
- class: "range-input appearance-none border-0 bg-transparent cursor-pointer relative w-full m-0 text-gray-700",
2328
+ default: q(() => [D("div", sn, [
2329
+ n[3] ||= D("div", { class: "poveste-slider-track-area" }, [D("div", {
2330
+ class: "poveste-slider-track",
2331
+ "data-slot": "track"
2332
+ })], -1),
2333
+ J(D("input", N({
2334
+ "onUpdate:modelValue": n[0] ||= (e) => a.value = e,
2335
+ class: "poveste-slider-input",
2336
+ "data-slot": "control",
586
2337
  type: "range"
587
2338
  }, {
588
- ...n.$attrs,
2339
+ ...t.$attrs,
589
2340
  class: null,
590
2341
  style: null,
591
- min: t.min,
592
- max: t.max
2342
+ min: e.min,
2343
+ max: e.max
593
2344
  }, {
594
- onMouseover: s[1] ||= (e) => u.value = !0,
595
- onMouseleave: s[2] ||= (e) => u.value = !1
2345
+ onMouseover: n[1] ||= (e) => i.value = !0,
2346
+ onMouseleave: n[2] ||= (e) => i.value = !1
596
2347
  }), null, 16), [[
597
- x,
598
- _.value,
2348
+ se,
2349
+ a.value,
599
2350
  void 0,
600
2351
  { number: !0 }
601
2352
  ]]),
602
- u.value ? w((h(), a("div", {
2353
+ i.value ? (z(), w(c, {
603
2354
  key: 0,
604
- class: "absolute",
605
- style: p(y.value)
606
- }, null, 4)), [[b(D), {
607
- content: String(t.modelValue ?? ""),
608
- shown: !0,
609
- distance: 16,
610
- delay: 0
611
- }]]) : i("", !0)
2355
+ content: String(e.modelValue ?? ""),
2356
+ open: !0,
2357
+ offset: 16
2358
+ }, {
2359
+ default: q(() => [D("div", {
2360
+ class: "poveste-slider-tooltip-anchor",
2361
+ style: L(s.value)
2362
+ }, null, 4)]),
2363
+ _: 1
2364
+ }, 8, ["content"])) : T("", !0)
612
2365
  ])]),
613
2366
  _: 1
614
2367
  }, 8, [
@@ -617,35 +2370,37 @@ var k = /* @__PURE__ */ u({
617
2370
  "style"
618
2371
  ]));
619
2372
  }
620
- }), Ve = ["value"], He = /* @__PURE__ */ u({
2373
+ }), ln = ["value"], un = /* @__PURE__ */ j({
621
2374
  name: "HstText",
2375
+ inheritAttrs: !1,
622
2376
  props: {
623
2377
  title: {},
624
2378
  modelValue: {}
625
2379
  },
626
2380
  emits: { "update:modelValue": (e) => !0 },
627
- setup(t, { emit: n }) {
628
- let i = n, a = g();
629
- return (n, s) => (h(), r(e, {
630
- title: t.title,
631
- class: f(["poveste-text cursor-text items-center", n.$attrs.class]),
632
- style: p(n.$attrs.style),
633
- onClick: s[1] ||= (e) => a.value?.focus()
2381
+ setup(e, { emit: t }) {
2382
+ let n = t, r = B();
2383
+ return (t, i) => (z(), w(u, {
2384
+ title: e.title,
2385
+ class: F(["poveste-text", t.$attrs.class]),
2386
+ style: L(t.$attrs.style),
2387
+ onClick: i[1] ||= (e) => r.value?.focus()
634
2388
  }, {
635
- actions: C(() => [v(n.$slots, "actions")]),
636
- default: C(() => [o("input", d({
2389
+ actions: q(() => [H(t.$slots, "actions")]),
2390
+ default: q(() => [D("input", N({
637
2391
  ref_key: "input",
638
- ref: a
2392
+ ref: r
639
2393
  }, {
640
- ...n.$attrs,
2394
+ ...t.$attrs,
641
2395
  class: null,
642
2396
  style: null
643
2397
  }, {
644
2398
  type: "text",
645
- value: t.modelValue,
646
- class: "text-inherit bg-transparent w-full outline-none px-2 py-1 -my-1 border border-solid border-black/25 dark:border-white/25 focus:border-primary-500 dark:focus:border-primary-500 rounded-sm",
647
- onInput: s[0] ||= (e) => i("update:modelValue", e.target.value)
648
- }), null, 16, Ve)]),
2399
+ class: "poveste-text-input",
2400
+ "data-slot": "control",
2401
+ value: e.modelValue,
2402
+ onInput: i[0] ||= (e) => n("update:modelValue", e.target.value)
2403
+ }), null, 16, ln)]),
649
2404
  _: 3
650
2405
  }, 8, [
651
2406
  "title",
@@ -653,7 +2408,7 @@ var k = /* @__PURE__ */ u({
653
2408
  "style"
654
2409
  ]));
655
2410
  }
656
- }), Ue = ["value"], We = /* @__PURE__ */ u({
2411
+ }), dn = ["value"], fn = /* @__PURE__ */ j({
657
2412
  name: "HstTextarea",
658
2413
  inheritAttrs: !1,
659
2414
  props: {
@@ -661,27 +2416,28 @@ var k = /* @__PURE__ */ u({
661
2416
  modelValue: {}
662
2417
  },
663
2418
  emits: { "update:modelValue": (e) => !0 },
664
- setup(t, { emit: n }) {
665
- let i = n, a = g();
666
- return (n, s) => (h(), r(e, {
667
- title: t.title,
668
- class: f(["poveste-textarea cursor-text", n.$attrs.class]),
669
- style: p(n.$attrs.style),
670
- onClick: s[1] ||= (e) => a.value?.focus()
2419
+ setup(e, { emit: t }) {
2420
+ let n = t, r = B();
2421
+ return (t, i) => (z(), w(u, {
2422
+ title: e.title,
2423
+ class: F(["poveste-textarea", t.$attrs.class]),
2424
+ style: L(t.$attrs.style),
2425
+ onClick: i[1] ||= (e) => r.value?.focus()
671
2426
  }, {
672
- actions: C(() => [v(n.$slots, "actions")]),
673
- default: C(() => [o("textarea", d({
2427
+ actions: q(() => [H(t.$slots, "actions")]),
2428
+ default: q(() => [D("textarea", N({
674
2429
  ref_key: "input",
675
- ref: a
2430
+ ref: r
676
2431
  }, {
677
- ...n.$attrs,
2432
+ ...t.$attrs,
678
2433
  class: null,
679
2434
  style: null
680
2435
  }, {
681
- value: t.modelValue,
682
- class: "text-inherit bg-transparent w-full outline-none px-2 py-1 -my-1 border border-solid border-black/25 dark:border-white/25 focus:border-primary-500 dark:focus:border-primary-500 rounded-sm box-border resize-y min-h-[26px]",
683
- onInput: s[0] ||= (e) => i("update:modelValue", e.target.value)
684
- }), null, 16, Ue)]),
2436
+ class: "poveste-textarea-input",
2437
+ "data-slot": "control",
2438
+ value: e.modelValue,
2439
+ onInput: i[0] ||= (e) => n("update:modelValue", e.target.value)
2440
+ }), null, 16, dn)]),
685
2441
  _: 3
686
2442
  }, 8, [
687
2443
  "title",
@@ -689,26 +2445,34 @@ var k = /* @__PURE__ */ u({
689
2445
  "style"
690
2446
  ]));
691
2447
  }
692
- }), R = k, z = ie, B = se, V = ue, H = He, U = L, W = Be, G = We, K = Re, q = P, J = Oe, Y = xe, X = j, Z = Me, Q = Object.assign(l(() => import("./HstJson-3DiXqRjL.es.js")), {
2448
+ }), pn = ge, mn = St, hn = kt, gn = At, _n = un, vn = en, yn = cn, bn = fn, xn = on, Sn = Bt, Cn = $t, wn = Kt, Tn = $, En = c, Dn = tn, On = Object.assign(A(() => import("./HstJson-D83KEa9o.es.js")), {
693
2449
  name: "HstJson",
694
2450
  emits: ["update:modelValue"]
695
- }), $ = pe, Ge = {
696
- HstButton: R,
697
- HstButtonGroup: z,
698
- HstCheckbox: B,
699
- HstCheckboxList: V,
700
- HstText: H,
701
- HstNumber: U,
702
- HstSlider: W,
703
- HstTextarea: G,
704
- HstSelect: K,
705
- HstRadio: Z,
706
- HstJson: Q,
707
- HstColorShades: q,
708
- HstTokenList: J,
709
- HstTokenGrid: Y,
710
- HstCopyIcon: X,
711
- HstColorSelect: $
2451
+ }), kn = Object.assign(A(() => import("./HstDate-Ct5Jp_ZD.es.js")), {
2452
+ name: "HstDate",
2453
+ emits: ["update:modelValue"]
2454
+ }), An = Object.assign(A(() => import("./HstColor-DHgxKTkm.es.js")), {
2455
+ name: "HstColor",
2456
+ emits: ["update:modelValue"]
2457
+ }), jn = Nt, Mn = {
2458
+ HstButton: pn,
2459
+ HstButtonGroup: mn,
2460
+ HstCheckbox: hn,
2461
+ HstCheckboxList: gn,
2462
+ HstText: _n,
2463
+ HstNumber: vn,
2464
+ HstSlider: yn,
2465
+ HstTextarea: bn,
2466
+ HstSelect: xn,
2467
+ HstRadio: Dn,
2468
+ HstColor: An,
2469
+ HstDate: kn,
2470
+ HstJson: On,
2471
+ HstColorShades: Sn,
2472
+ HstTokenList: Cn,
2473
+ HstTokenGrid: wn,
2474
+ HstCopyIcon: Tn,
2475
+ HstColorSelect: jn
712
2476
  };
713
2477
  //#endregion
714
- export { R as HstButton, z as HstButtonGroup, B as HstCheckbox, V as HstCheckboxList, $ as HstColorSelect, q as HstColorShades, X as HstCopyIcon, Q as HstJson, U as HstNumber, Z as HstRadio, K as HstSelect, W as HstSlider, H as HstText, G as HstTextarea, Y as HstTokenGrid, J as HstTokenList, Ge as components };
2478
+ export { pn as HstButton, mn as HstButtonGroup, hn as HstCheckbox, gn as HstCheckboxList, An as HstColor, jn as HstColorSelect, Sn as HstColorShades, Tn as HstCopyIcon, kn as HstDate, On as HstJson, vn as HstNumber, Dn as HstRadio, xn as HstSelect, yn as HstSlider, _n as HstText, bn as HstTextarea, wn as HstTokenGrid, Cn as HstTokenList, En as HstTooltip, ot as PopoverAnchor, _ as PopoverContent, h as PopoverPortal, m as PopoverRoot, y as PopoverTrigger, Mn as components, l as portalTarget };