@vmscloud/moz-ui-components-core 0.1.49 → 0.1.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/chip/chip.core.d.ts +7 -0
- package/dist/index.cjs +6 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +468 -457
- package/dist/index.js.map +1 -1
- package/dist/styles/default/chip.css +3 -0
- package/dist/styles/default/index.css +3 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var Ko = Object.defineProperty;
|
|
2
2
|
var Go = (e, t, o) => t in e ? Ko(e, t, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[t] = o;
|
|
3
3
|
var De = (e, t, o) => Go(e, typeof t != "symbol" ? t + "" : t, o);
|
|
4
|
-
import { render as yt, nothing as b, html as
|
|
4
|
+
import { render as yt, nothing as b, html as c, noChange as Yo } from "lit-html";
|
|
5
5
|
import { directive as Zo, Directive as jo, PartType as Xo } from "lit-html/directive.js";
|
|
6
6
|
import { styleMap as oe } from "lit-html/directives/style-map.js";
|
|
7
7
|
import { clsx as Qo } from "clsx";
|
|
@@ -141,8 +141,8 @@ class rs {
|
|
|
141
141
|
return (m = (s = h.handle).update) == null || m.call(s, n), !0;
|
|
142
142
|
h.handle.dispose(), this.mounted.delete(t);
|
|
143
143
|
}
|
|
144
|
-
const
|
|
145
|
-
return this.mounted.set(t, { el: l, handle:
|
|
144
|
+
const d = i(l, n);
|
|
145
|
+
return this.mounted.set(t, { el: l, handle: d }), !0;
|
|
146
146
|
}
|
|
147
147
|
/** 특정 slot 인스턴스 정리 */
|
|
148
148
|
clear(t) {
|
|
@@ -2171,10 +2171,10 @@ const Jt = {
|
|
|
2171
2171
|
function be(e) {
|
|
2172
2172
|
return (t, o, l, n) => {
|
|
2173
2173
|
var re;
|
|
2174
|
-
const i = e.portal ? new Ot() : null, h = i ? i.open() : t,
|
|
2174
|
+
const i = e.portal ? new Ot() : null, h = i ? i.open() : t, d = new rs();
|
|
2175
2175
|
if (n != null && n.slots)
|
|
2176
|
-
for (const [ee, K] of Object.entries(n.slots))
|
|
2177
|
-
n != null && n.slotResolver &&
|
|
2176
|
+
for (const [ee, K] of Object.entries(n.slots)) d.register(ee, K);
|
|
2177
|
+
n != null && n.slotResolver && d.setResolver(n.slotResolver);
|
|
2178
2178
|
const s = new Set(Object.keys(o)), m = n != null && n.providedKeys ? new Set(n.providedKeys) : null, r = (ee) => {
|
|
2179
2179
|
const K = e.defaults;
|
|
2180
2180
|
if (!K) return ee;
|
|
@@ -2191,7 +2191,7 @@ function be(e) {
|
|
|
2191
2191
|
return p;
|
|
2192
2192
|
},
|
|
2193
2193
|
emit: l,
|
|
2194
|
-
slots:
|
|
2194
|
+
slots: d,
|
|
2195
2195
|
requestUpdate: () => W.requestUpdate(),
|
|
2196
2196
|
onCleanup: (ee) => $.push(ee),
|
|
2197
2197
|
px: (ee) => ze(ee),
|
|
@@ -2201,11 +2201,11 @@ function be(e) {
|
|
|
2201
2201
|
validator: v,
|
|
2202
2202
|
controlled: (ee) => m ? m.has(ee) : s.has(ee),
|
|
2203
2203
|
slot(ee, K) {
|
|
2204
|
-
if (!
|
|
2204
|
+
if (!d.has(ee)) return b;
|
|
2205
2205
|
const D = y.get(ee) ?? 0;
|
|
2206
2206
|
y.set(ee, D + 1);
|
|
2207
2207
|
const G = `${ee}#${D}`;
|
|
2208
|
-
return F.set(G, { name: ee, scope: K }),
|
|
2208
|
+
return F.set(G, { name: ee, scope: K }), c`<span data-moz-slot=${ee} data-moz-slot-id=${G}></span>`;
|
|
2209
2209
|
}
|
|
2210
2210
|
}, z = e.setup(E);
|
|
2211
2211
|
class X extends ns {
|
|
@@ -2221,10 +2221,10 @@ function be(e) {
|
|
|
2221
2221
|
}
|
|
2222
2222
|
for (const [D, { name: G, scope: se }] of F) {
|
|
2223
2223
|
let ie = this.container.querySelector(`[data-moz-slot-id="${D}"]`);
|
|
2224
|
-
!ie && K && (ie = K.querySelector(`[data-moz-slot-id="${D}"]`)), ie &&
|
|
2224
|
+
!ie && K && (ie = K.querySelector(`[data-moz-slot-id="${D}"]`)), ie && d.fill(D, G, ie, se);
|
|
2225
2225
|
}
|
|
2226
2226
|
for (const D of S)
|
|
2227
|
-
F.has(D) ||
|
|
2227
|
+
F.has(D) || d.clear(D);
|
|
2228
2228
|
S = new Set(F.keys());
|
|
2229
2229
|
}
|
|
2230
2230
|
/** microtask 배치를 건너뛰고 즉시 렌더 (`update({ sync: true })` 전용) */
|
|
@@ -2237,7 +2237,7 @@ function be(e) {
|
|
|
2237
2237
|
K();
|
|
2238
2238
|
} catch {
|
|
2239
2239
|
}
|
|
2240
|
-
|
|
2240
|
+
d.destroy();
|
|
2241
2241
|
}
|
|
2242
2242
|
}
|
|
2243
2243
|
const W = new X(h);
|
|
@@ -2279,16 +2279,16 @@ class as extends jo {
|
|
|
2279
2279
|
for (const h of this.prevKeys)
|
|
2280
2280
|
if (!(h in i))
|
|
2281
2281
|
if (this.isEventKey(h)) {
|
|
2282
|
-
const
|
|
2283
|
-
|
|
2282
|
+
const d = this.listeners.get(h);
|
|
2283
|
+
d && n.removeEventListener(this.eventName(h), d), this.listeners.delete(h);
|
|
2284
2284
|
} else
|
|
2285
2285
|
n.removeAttribute(h);
|
|
2286
|
-
for (const [h,
|
|
2286
|
+
for (const [h, d] of Object.entries(i))
|
|
2287
2287
|
if (!(h === "class" || h === "style" || h === "key" || h === "ref"))
|
|
2288
|
-
if (this.isEventKey(h) && typeof
|
|
2288
|
+
if (this.isEventKey(h) && typeof d == "function") {
|
|
2289
2289
|
const s = this.eventName(h), m = this.listeners.get(h);
|
|
2290
|
-
m && n.removeEventListener(s, m), n.addEventListener(s,
|
|
2291
|
-
} else
|
|
2290
|
+
m && n.removeEventListener(s, m), n.addEventListener(s, d), this.listeners.set(h, d);
|
|
2291
|
+
} else d == null ? n.removeAttribute(h) : h.startsWith("aria-") ? n.setAttribute(h, String(d)) : d === !1 ? n.removeAttribute(h) : d === !0 ? n.setAttribute(h, "") : n.setAttribute(h, String(d));
|
|
2292
2292
|
return this.prevKeys = Object.keys(i), Yo;
|
|
2293
2293
|
}
|
|
2294
2294
|
isEventKey(o) {
|
|
@@ -2311,13 +2311,13 @@ function Tr() {
|
|
|
2311
2311
|
return { addValidator: (i) => {
|
|
2312
2312
|
e.push(i);
|
|
2313
2313
|
}, removeValidator: (i) => {
|
|
2314
|
-
const h = e.findIndex((
|
|
2314
|
+
const h = e.findIndex((d) => d.validate === i.validate);
|
|
2315
2315
|
h >= 0 && e.splice(h, 1);
|
|
2316
2316
|
}, validate: async (i = "save") => (await Promise.all(
|
|
2317
2317
|
e.map(
|
|
2318
|
-
(
|
|
2318
|
+
(d) => d.validate(i).then((s) => s === void 0 ? !0 : s)
|
|
2319
2319
|
)
|
|
2320
|
-
)).every((
|
|
2320
|
+
)).every((d) => d), initValidator: () => {
|
|
2321
2321
|
var i;
|
|
2322
2322
|
for (const h of e)
|
|
2323
2323
|
(i = h == null ? void 0 : h.initValidator) == null || i.call(h);
|
|
@@ -2352,7 +2352,7 @@ class zt {
|
|
|
2352
2352
|
calcPosition() {
|
|
2353
2353
|
const t = this.opts.anchor(), o = this.opts.panel();
|
|
2354
2354
|
if (!t || !o) return;
|
|
2355
|
-
const l = t.getBoundingClientRect(), n = this.opts.maxHeight ? this.opts.maxHeight() : 250, i = window.innerHeight - l.bottom, h = l.top,
|
|
2355
|
+
const l = t.getBoundingClientRect(), n = this.opts.maxHeight ? this.opts.maxHeight() : 250, i = window.innerHeight - l.bottom, h = l.top, d = i < n && h >= n;
|
|
2356
2356
|
let s = l.left;
|
|
2357
2357
|
const m = o.clientWidth;
|
|
2358
2358
|
l.left + m > document.body.clientWidth && (s -= m - l.width);
|
|
@@ -2361,7 +2361,7 @@ class zt {
|
|
|
2361
2361
|
const u = this.opts.listWidth();
|
|
2362
2362
|
u && (typeof u != "number" || u > 0) && (r = typeof u == "number" ? `${u}px` : u, p = !0);
|
|
2363
2363
|
}
|
|
2364
|
-
o.style.position = "fixed", o.style.left = `${s}px`, this.opts.useMinWidth ? (o.style.minWidth = `${l.width}px`, p && (o.style.width = String(r))) : p ? o.style.width = String(r) : o.style.width = `${l.width}px`,
|
|
2364
|
+
o.style.position = "fixed", o.style.left = `${s}px`, this.opts.useMinWidth ? (o.style.minWidth = `${l.width}px`, p && (o.style.width = String(r))) : p ? o.style.width = String(r) : o.style.width = `${l.width}px`, d ? (o.style.bottom = `${window.innerHeight - l.top}px`, o.style.top = "auto") : (o.style.top = `${l.bottom}px`, o.style.bottom = "auto");
|
|
2365
2365
|
}
|
|
2366
2366
|
onScroll(t) {
|
|
2367
2367
|
const o = t.target;
|
|
@@ -2377,10 +2377,10 @@ class zt {
|
|
|
2377
2377
|
this.calcPosition();
|
|
2378
2378
|
}
|
|
2379
2379
|
onOutsideClick(t) {
|
|
2380
|
-
var l, n, i, h,
|
|
2380
|
+
var l, n, i, h, d;
|
|
2381
2381
|
if (this.opts.closeOnOutsideClick === !1) return;
|
|
2382
2382
|
const o = t.target;
|
|
2383
|
-
(i = (n = (l = this.opts).container) == null ? void 0 : n.call(l)) != null && i.contains(o) || (h = this.opts.panel()) != null && h.contains(o) || (
|
|
2383
|
+
(i = (n = (l = this.opts).container) == null ? void 0 : n.call(l)) != null && i.contains(o) || (h = this.opts.panel()) != null && h.contains(o) || (d = this.opts.anchor()) != null && d.contains(o) || this.opts.requestClose();
|
|
2384
2384
|
}
|
|
2385
2385
|
}
|
|
2386
2386
|
const et = [];
|
|
@@ -2426,7 +2426,7 @@ function Mr() {
|
|
|
2426
2426
|
}
|
|
2427
2427
|
function yo(e = {}) {
|
|
2428
2428
|
const { circleClass: t = "", progressClass: o = "" } = e;
|
|
2429
|
-
return
|
|
2429
|
+
return c`<svg
|
|
2430
2430
|
aria-hidden="true"
|
|
2431
2431
|
role="status"
|
|
2432
2432
|
class="moz-circle-loader"
|
|
@@ -2473,11 +2473,11 @@ function bt(e, t = {}) {
|
|
|
2473
2473
|
minWidth: n,
|
|
2474
2474
|
"--moz-btn-loading-width": i,
|
|
2475
2475
|
...Pe(e.style)
|
|
2476
|
-
},
|
|
2476
|
+
}, d = (s) => {
|
|
2477
2477
|
var m;
|
|
2478
2478
|
o || (m = t.onClick) == null || m.call(t, s);
|
|
2479
2479
|
};
|
|
2480
|
-
return
|
|
2480
|
+
return c`
|
|
2481
2481
|
<button
|
|
2482
2482
|
type=${e.nativeType ?? "button"}
|
|
2483
2483
|
class=${A(
|
|
@@ -2488,13 +2488,13 @@ function bt(e, t = {}) {
|
|
|
2488
2488
|
)}
|
|
2489
2489
|
style=${oe(h)}
|
|
2490
2490
|
?disabled=${o}
|
|
2491
|
-
@click=${
|
|
2491
|
+
@click=${d}
|
|
2492
2492
|
${pe(t.rest ?? {})}
|
|
2493
2493
|
>
|
|
2494
|
-
${e.loading ?
|
|
2494
|
+
${e.loading ? c`<span class="spinner" data-part="spinner"
|
|
2495
2495
|
>${yo({ circleClass: "fill-accent-50", progressClass: "fill-accent-400" })}</span
|
|
2496
2496
|
>` : t.icon ?? b}
|
|
2497
|
-
${e.text || t.content != null ?
|
|
2497
|
+
${e.text || t.content != null ? c`<span class=${A("text", { "has-icon-text": l })} data-part="label"
|
|
2498
2498
|
>${e.text ?? ""}${t.content ?? b}</span
|
|
2499
2499
|
>` : b}
|
|
2500
2500
|
</button>
|
|
@@ -2518,16 +2518,16 @@ const fs = be({
|
|
|
2518
2518
|
render() {
|
|
2519
2519
|
const n = e.props;
|
|
2520
2520
|
n.loading !== o && (o = n.loading, t = !!n.loading);
|
|
2521
|
-
const i = e.slots.has("icon"), h = !!n.disabled || t,
|
|
2521
|
+
const i = e.slots.has("icon"), h = !!n.disabled || t, d = n.width == null ? void 0 : typeof n.width == "number" ? `${e.px(n.width)}rem` : n.width, s = n.width == null ? void 0 : typeof n.width == "number" ? `${n.width}px` : n.width, m = {};
|
|
2522
2522
|
for (const p of Object.keys(n))
|
|
2523
2523
|
hs.has(p) || (m[p] = n[p]);
|
|
2524
2524
|
const r = {
|
|
2525
|
-
width:
|
|
2526
|
-
minWidth:
|
|
2525
|
+
width: d,
|
|
2526
|
+
minWidth: d,
|
|
2527
2527
|
"--moz-btn-loading-width": s,
|
|
2528
2528
|
...Pe(n.style)
|
|
2529
2529
|
};
|
|
2530
|
-
return
|
|
2530
|
+
return c`
|
|
2531
2531
|
<button
|
|
2532
2532
|
type=${n.nativeType ?? "button"}
|
|
2533
2533
|
class=${A(
|
|
@@ -2545,10 +2545,10 @@ const fs = be({
|
|
|
2545
2545
|
@click=${l}
|
|
2546
2546
|
${pe(m)}
|
|
2547
2547
|
>
|
|
2548
|
-
${t ?
|
|
2548
|
+
${t ? c`<span class="spinner" data-part="spinner"
|
|
2549
2549
|
>${yo({ circleClass: "fill-accent-50", progressClass: "fill-accent-400" })}</span
|
|
2550
2550
|
>` : e.slot("icon", { disabled: h })}
|
|
2551
|
-
${n.text || e.slots.has("default") ?
|
|
2551
|
+
${n.text || e.slots.has("default") ? c`<span class=${A("text", { "has-icon-text": i })} data-part="label"
|
|
2552
2552
|
>${n.text ?? ""}${e.slot("default", { disabled: h })}</span
|
|
2553
2553
|
>` : b}
|
|
2554
2554
|
</button>
|
|
@@ -2568,8 +2568,8 @@ function So(e, t) {
|
|
|
2568
2568
|
return A("moz-label", { disabled: !!e.disabled, "read-only": !!e.isReadOnly }, t, e.class);
|
|
2569
2569
|
}
|
|
2570
2570
|
function Oe(e, t, o) {
|
|
2571
|
-
return
|
|
2572
|
-
>${t}${e.required ?
|
|
2571
|
+
return c`<label class=${So(e, o)} for=${Te(e.for)}
|
|
2572
|
+
>${t}${e.required ? c`<span class="require-mark">*</span>` : b}</label
|
|
2573
2573
|
>`;
|
|
2574
2574
|
}
|
|
2575
2575
|
const vs = be({
|
|
@@ -2578,12 +2578,12 @@ const vs = be({
|
|
|
2578
2578
|
return {
|
|
2579
2579
|
render() {
|
|
2580
2580
|
const t = e.props, o = we(t, gs);
|
|
2581
|
-
return
|
|
2581
|
+
return c`<label
|
|
2582
2582
|
class=${So(t)}
|
|
2583
2583
|
for=${Te(t.for)}
|
|
2584
2584
|
style=${oe(Pe(t.style))}
|
|
2585
2585
|
${pe(o)}
|
|
2586
|
-
>${e.slot("default")}${t.required ?
|
|
2586
|
+
>${e.slot("default")}${t.required ? c`<span class="require-mark">*</span>` : b}</label
|
|
2587
2587
|
>`;
|
|
2588
2588
|
}
|
|
2589
2589
|
};
|
|
@@ -2608,7 +2608,7 @@ const vs = be({
|
|
|
2608
2608
|
]);
|
|
2609
2609
|
function Nt(e) {
|
|
2610
2610
|
const t = !!e.model;
|
|
2611
|
-
return
|
|
2611
|
+
return c`
|
|
2612
2612
|
<div
|
|
2613
2613
|
data-part="root"
|
|
2614
2614
|
class=${A(e.class)}
|
|
@@ -2680,7 +2680,7 @@ const bs = be({
|
|
|
2680
2680
|
expose: !1
|
|
2681
2681
|
};
|
|
2682
2682
|
function ko(e = "") {
|
|
2683
|
-
return
|
|
2683
|
+
return c`<svg class=${e} xmlns="http://www.w3.org/2000/svg" width="10" height="10" viewBox="0 0 10 10" fill="none">
|
|
2684
2684
|
<path
|
|
2685
2685
|
fill-rule="evenodd"
|
|
2686
2686
|
clip-rule="evenodd"
|
|
@@ -2690,7 +2690,7 @@ function ko(e = "") {
|
|
|
2690
2690
|
</svg>`;
|
|
2691
2691
|
}
|
|
2692
2692
|
function Eo(e = "var(--moz-color-text-subtle)", t = "") {
|
|
2693
|
-
return
|
|
2693
|
+
return c`<svg class=${t} width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2694
2694
|
<path
|
|
2695
2695
|
d="M8 1.5L10.163 5.875L15 6.575L11.5 9.975L12.326 14.775L8 12.5L3.674 14.775L4.5 9.975L1 6.575L5.837 5.875L8 1.5Z"
|
|
2696
2696
|
stroke=${e}
|
|
@@ -2701,7 +2701,7 @@ function Eo(e = "var(--moz-color-text-subtle)", t = "") {
|
|
|
2701
2701
|
</svg>`;
|
|
2702
2702
|
}
|
|
2703
2703
|
function xo(e = "var(--moz-color-accent)", t = "") {
|
|
2704
|
-
return
|
|
2704
|
+
return c`<svg class=${t} width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2705
2705
|
<path
|
|
2706
2706
|
d="M8 1.5L10.163 5.875L15 6.575L11.5 9.975L12.326 14.775L8 12.5L3.674 14.775L4.5 9.975L1 6.575L5.837 5.875L8 1.5Z"
|
|
2707
2707
|
fill=${e}
|
|
@@ -2714,10 +2714,10 @@ function xo(e = "var(--moz-color-accent)", t = "") {
|
|
|
2714
2714
|
}
|
|
2715
2715
|
const eo = /* @__PURE__ */ new Set(["itemSource", "items", "listClass", "showFavorite", "modelValue", "class", "style"]);
|
|
2716
2716
|
function Po(e) {
|
|
2717
|
-
const t = e.itemSource ?? [], o = !!e.favorite, l = e.showFavorite ? e.favoriteSlot != null ? e.favoriteSlot :
|
|
2717
|
+
const t = e.itemSource ?? [], o = !!e.favorite, l = e.showFavorite ? e.favoriteSlot != null ? e.favoriteSlot : c`<button type="button" class="favorite-icon" @click=${e.onFavClick}>
|
|
2718
2718
|
${o ? xo(void 0, "favorite-filled") : Eo(void 0, "empty")}
|
|
2719
2719
|
</button>` : b;
|
|
2720
|
-
return
|
|
2720
|
+
return c`
|
|
2721
2721
|
<div
|
|
2722
2722
|
role="navigation"
|
|
2723
2723
|
aria-label=${e.ariaLabel ?? "breadcrumb"}
|
|
@@ -2727,7 +2727,7 @@ function Po(e) {
|
|
|
2727
2727
|
>
|
|
2728
2728
|
<div class="menu-item">
|
|
2729
2729
|
${t.map(
|
|
2730
|
-
(n, i) => t.length - 1 === i ?
|
|
2730
|
+
(n, i) => t.length - 1 === i ? c`<div class="current-item" aria-current="page">${n}</div>` : c`<div>${n}</div>${ko("separator")}`
|
|
2731
2731
|
)}
|
|
2732
2732
|
</div>
|
|
2733
2733
|
${l}${e.titleSlot ?? b}
|
|
@@ -2739,12 +2739,12 @@ const Cs = be({
|
|
|
2739
2739
|
defaults: { showFavorite: !0, modelValue: !0, itemSource: [] },
|
|
2740
2740
|
setup(e) {
|
|
2741
2741
|
const t = () => e.emit("click", !!e.props.modelValue), o = (l) => {
|
|
2742
|
-
const n = e.props, i = !!n.modelValue, h = n.showFavorite ? e.slots.has("favorite") ? e.slot("favorite") :
|
|
2742
|
+
const n = e.props, i = !!n.modelValue, h = n.showFavorite ? e.slots.has("favorite") ? e.slot("favorite") : c`<button type="button" class="favorite-icon" @click=${t}>
|
|
2743
2743
|
${i ? xo(void 0, "favorite-filled") : Eo(void 0, "empty")}
|
|
2744
|
-
</button>` : b,
|
|
2744
|
+
</button>` : b, d = () => c`<li role="presentation" aria-hidden="true" class="moz-bread-crumb-separator">
|
|
2745
2745
|
${e.slots.has("separator") ? e.slot("separator") : ko("separator")}
|
|
2746
2746
|
</li>`;
|
|
2747
|
-
return
|
|
2747
|
+
return c`
|
|
2748
2748
|
<nav
|
|
2749
2749
|
aria-label=${e.locale.BreadCrumb.navigation}
|
|
2750
2750
|
class=${A("moz-bread-crumb", "moz-bread-crumb-items", n.class)}
|
|
@@ -2753,11 +2753,11 @@ const Cs = be({
|
|
|
2753
2753
|
>
|
|
2754
2754
|
<ol class=${A("moz-bread-crumb-list", n.listClass)}>
|
|
2755
2755
|
${l.map(
|
|
2756
|
-
(s, m) =>
|
|
2756
|
+
(s, m) => c`
|
|
2757
2757
|
<li class="moz-bread-crumb-item" aria-current=${s.current ? "page" : b}>
|
|
2758
2758
|
${e.slot(`item-${s.key}`)}
|
|
2759
2759
|
</li>
|
|
2760
|
-
${m < l.length - 1 ?
|
|
2760
|
+
${m < l.length - 1 ? d() : b}
|
|
2761
2761
|
`
|
|
2762
2762
|
)}
|
|
2763
2763
|
</ol>
|
|
@@ -2867,29 +2867,29 @@ const Cs = be({
|
|
|
2867
2867
|
render() {
|
|
2868
2868
|
const l = e.props, n = we(l, Es);
|
|
2869
2869
|
if (l.composed)
|
|
2870
|
-
return
|
|
2870
|
+
return c`
|
|
2871
2871
|
<div
|
|
2872
2872
|
class=${A("empty-container", "empty-composed", l.class)}
|
|
2873
2873
|
style=${oe(Pe(l.style))}
|
|
2874
2874
|
${pe(n)}
|
|
2875
2875
|
>
|
|
2876
|
-
${e.slots.has("icon") ?
|
|
2877
|
-
${e.slots.has("heading") ?
|
|
2878
|
-
${e.slots.has("description") ?
|
|
2879
|
-
${e.slots.has("actions") ?
|
|
2880
|
-
${e.slots.has("customState") ?
|
|
2876
|
+
${e.slots.has("icon") ? c`<div class="empty-icon">${e.slot("icon")}</div>` : b}
|
|
2877
|
+
${e.slots.has("heading") ? c`<div class="empty-heading-slot">${e.slot("heading")}</div>` : b}
|
|
2878
|
+
${e.slots.has("description") ? c`<div class="empty-description">${e.slot("description")}</div>` : b}
|
|
2879
|
+
${e.slots.has("actions") ? c`<div class="empty-actions">${e.slot("actions")}</div>` : b}
|
|
2880
|
+
${e.slots.has("customState") ? c`<div class="empty-content">${e.slot("customState")}</div>` : b}
|
|
2881
2881
|
</div>
|
|
2882
2882
|
`;
|
|
2883
2883
|
const i = o();
|
|
2884
2884
|
if (!i) return b;
|
|
2885
|
-
const h = xs[i] || Lo,
|
|
2886
|
-
return
|
|
2885
|
+
const h = xs[i] || Lo, d = typeof l.headerMsg == "string" ? l.headerMsg : t(Ps[i] || "customEmptyHeader"), s = typeof l.contentMsg == "string" ? l.contentMsg : t(Ls[i] || "customEmptyContent"), m = e.slots.has("icon") ? c`<div class="empty-icon">${e.slot("icon")}</div>` : l.useImg ? c`<img src=${h} alt="Empty state" class="empty-img" />` : b;
|
|
2886
|
+
return c`
|
|
2887
2887
|
<div class=${A("empty-container", l.class)} style=${oe(Pe(l.style))} ${pe(n)}>
|
|
2888
2888
|
${m}
|
|
2889
|
-
<div class="empty-heading">${
|
|
2889
|
+
<div class="empty-heading">${d}</div>
|
|
2890
2890
|
<div class="empty-content"><span>${wo(s)}</span></div>
|
|
2891
2891
|
<div class="empty-content">${e.slot("customState")}</div>
|
|
2892
|
-
${e.slots.has("actions") ?
|
|
2892
|
+
${e.slots.has("actions") ? c`<div class="empty-actions">${e.slot("actions")}</div>` : b}
|
|
2893
2893
|
</div>
|
|
2894
2894
|
`;
|
|
2895
2895
|
}
|
|
@@ -2918,7 +2918,7 @@ const Cs = be({
|
|
|
2918
2918
|
expose: !1
|
|
2919
2919
|
};
|
|
2920
2920
|
function To(e = "var(--moz-color-border)", t = !1, o = "") {
|
|
2921
|
-
return
|
|
2921
|
+
return c`<svg class=${o} data-icon="unchecked" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2922
2922
|
<path
|
|
2923
2923
|
d="M10 0H2C0.89543 0 0 0.89543 0 2V10C0 11.1046 0.89543 12 2 12H10C11.1046 12 12 11.1046 12 10V2C12 0.89543 11.1046 0 10 0Z"
|
|
2924
2924
|
fill=${t ? "var(--moz-color-surface-subtle)" : "var(--moz-color-surface)"}
|
|
@@ -2930,7 +2930,7 @@ function To(e = "var(--moz-color-border)", t = !1, o = "") {
|
|
|
2930
2930
|
</svg>`;
|
|
2931
2931
|
}
|
|
2932
2932
|
function zo(e = "var(--moz-color-accent)", t = !1, o = "") {
|
|
2933
|
-
return
|
|
2933
|
+
return c`<svg class=${o} data-icon="checked" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2934
2934
|
<path
|
|
2935
2935
|
d="M10 12H2C1.46957 12 0.960859 11.7893 0.585786 11.4142C0.210714 11.0391 0 10.5304 0 10V2C0 1.46957 0.210714 0.960859 0.585786 0.585786C0.960859 0.210714 1.46957 0 2 0L10 0C10.5304 0 11.0391 0.210714 11.4142 0.585786C11.7893 0.960859 12 1.46957 12 2V10C12 10.5304 11.7893 11.0391 11.4142 11.4142C11.0391 11.7893 10.5304 12 10 12ZM2.276 5.472C2.18827 5.47227 2.10149 5.49011 2.02077 5.52446C1.94005 5.5588 1.86702 5.60897 1.806 5.672C1.68191 5.79695 1.61227 5.9659 1.61227 6.142C1.61227 6.3181 1.68191 6.48705 1.806 6.612L4.2 9C4.32469 9.12457 4.49374 9.19455 4.67 9.19455C4.84626 9.19455 5.01531 9.12457 5.14 9L10.194 3.94C10.2557 3.87821 10.3047 3.80487 10.338 3.72417C10.3714 3.64347 10.3886 3.55698 10.3885 3.46965C10.3885 3.38231 10.3712 3.29584 10.3378 3.21518C10.3043 3.13451 10.2553 3.06122 10.1935 2.9995C10.1317 2.93778 10.0584 2.88883 9.97767 2.85545C9.89697 2.82208 9.81048 2.80492 9.72315 2.80497C9.63581 2.80501 9.54934 2.82226 9.46868 2.85572C9.38801 2.88919 9.31472 2.93821 9.253 3L4.667 7.587L2.747 5.667C2.68531 5.60494 2.61191 5.55574 2.53105 5.52227C2.4502 5.48879 2.36351 5.47171 2.276 5.472Z"
|
|
2936
2936
|
fill=${t ? "var(--moz-color-text-muted)" : e}
|
|
@@ -2938,7 +2938,7 @@ function zo(e = "var(--moz-color-accent)", t = !1, o = "") {
|
|
|
2938
2938
|
</svg>`;
|
|
2939
2939
|
}
|
|
2940
2940
|
function Mo(e = "var(--moz-color-accent)", t = !1, o = "") {
|
|
2941
|
-
return
|
|
2941
|
+
return c`<svg class=${o} data-icon="indeterminate" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2942
2942
|
<rect width="12" height="12" rx="2" fill=${t ? "var(--moz-color-text-muted)" : e}></rect>
|
|
2943
2943
|
<path d="M3 6H9" stroke="var(--moz-color-on-accent)" stroke-width="2" stroke-linecap="round"></path>
|
|
2944
2944
|
</svg>`;
|
|
@@ -2959,7 +2959,7 @@ function Ft(e = {}) {
|
|
|
2959
2959
|
var i;
|
|
2960
2960
|
o || (i = e.onChange) == null || i.call(e, !t);
|
|
2961
2961
|
};
|
|
2962
|
-
return
|
|
2962
|
+
return c`
|
|
2963
2963
|
<div
|
|
2964
2964
|
class=${A(
|
|
2965
2965
|
"moz-checkbox",
|
|
@@ -3005,7 +3005,7 @@ const Ms = be({
|
|
|
3005
3005
|
var v;
|
|
3006
3006
|
const u = e.props;
|
|
3007
3007
|
u.disabled || u.readonly || (p.preventDefault(), p.stopPropagation(), n(), (v = p.currentTarget.querySelector("input")) == null || v.focus());
|
|
3008
|
-
}, h = (p) => p.stopPropagation(),
|
|
3008
|
+
}, h = (p) => p.stopPropagation(), d = (p) => {
|
|
3009
3009
|
const u = e.props, v = p.target;
|
|
3010
3010
|
if (u.readonly) {
|
|
3011
3011
|
v.checked = l();
|
|
@@ -3024,7 +3024,7 @@ const Ms = be({
|
|
|
3024
3024
|
return {
|
|
3025
3025
|
render() {
|
|
3026
3026
|
const p = e.props, u = p.fieldId || t, v = l(), $ = we(p, zs);
|
|
3027
|
-
return
|
|
3027
|
+
return c`
|
|
3028
3028
|
<div
|
|
3029
3029
|
class=${A("moz-checkbox", {
|
|
3030
3030
|
"cursor-pointer": !p.disabled && !p.readonly,
|
|
@@ -3048,7 +3048,7 @@ const Ms = be({
|
|
|
3048
3048
|
?disabled=${!!p.disabled}
|
|
3049
3049
|
tabindex=${p.disabled ? -1 : 0}
|
|
3050
3050
|
@click=${h}
|
|
3051
|
-
@change=${
|
|
3051
|
+
@change=${d}
|
|
3052
3052
|
@focus=${m}
|
|
3053
3053
|
@blur=${r}
|
|
3054
3054
|
@keydown=${s}
|
|
@@ -3127,13 +3127,13 @@ const Ms = be({
|
|
|
3127
3127
|
"last-v": r.variant === "boxed" && r.direction === "vertical" && s === p.length - 1,
|
|
3128
3128
|
disabled: m
|
|
3129
3129
|
});
|
|
3130
|
-
},
|
|
3130
|
+
}, d = (s) => {
|
|
3131
3131
|
const m = e.props;
|
|
3132
3132
|
return m.variant !== "boxed" || s === 0 ? {} : m.direction === "horizontal" ? { marginInlineStart: "-1px" } : { marginBlockStart: "-1px" };
|
|
3133
3133
|
};
|
|
3134
3134
|
return {
|
|
3135
3135
|
render() {
|
|
3136
|
-
const s = e.props, m = s.itemsSource ?? [], r = s.valueExpr ?? "value", p = s.displayExpr ?? "label", u = !!s.disabled, v = s.modelValue, $ = s.value !== void 0 && m.length === 0, F = !$ && s.variant === "segment", S = we(s, As), y = () =>
|
|
3136
|
+
const s = e.props, m = s.itemsSource ?? [], r = s.valueExpr ?? "value", p = s.displayExpr ?? "label", u = !!s.disabled, v = s.modelValue, $ = s.value !== void 0 && m.length === 0, F = !$ && s.variant === "segment", S = we(s, As), y = () => c`
|
|
3137
3137
|
<div class="radio-container">
|
|
3138
3138
|
<div class="radio">
|
|
3139
3139
|
<label for=${t} class=${A("label-container", { disabled: u })}>
|
|
@@ -3160,7 +3160,7 @@ const Ms = be({
|
|
|
3160
3160
|
})}
|
|
3161
3161
|
></span>
|
|
3162
3162
|
</div>
|
|
3163
|
-
${s.text ?
|
|
3163
|
+
${s.text ? c`<span class="radio-label-text">${s.text}</span>` : b}
|
|
3164
3164
|
</label>
|
|
3165
3165
|
</div>
|
|
3166
3166
|
</div>
|
|
@@ -3213,7 +3213,7 @@ const Ms = be({
|
|
|
3213
3213
|
break;
|
|
3214
3214
|
}
|
|
3215
3215
|
}, Q = !!s.iconOnly, U = e.slots.has("item-icon"), x = !Q && e.slots.has("item-badge");
|
|
3216
|
-
return
|
|
3216
|
+
return c`
|
|
3217
3217
|
<div
|
|
3218
3218
|
class=${A("radio-container", {
|
|
3219
3219
|
segment: !0,
|
|
@@ -3227,7 +3227,7 @@ const Ms = be({
|
|
|
3227
3227
|
>
|
|
3228
3228
|
${m.map((M, _) => {
|
|
3229
3229
|
const k = W(M), T = i(M), V = String(M[p] ?? ""), B = V || String(M[r] ?? ""), f = { item: M, index: _, active: k, disabled: T };
|
|
3230
|
-
return
|
|
3230
|
+
return c`
|
|
3231
3231
|
<button
|
|
3232
3232
|
type="button"
|
|
3233
3233
|
role="radio"
|
|
@@ -3242,15 +3242,15 @@ const Ms = be({
|
|
|
3242
3242
|
T || e.emit("update:modelValue", M[r] ?? "");
|
|
3243
3243
|
}}
|
|
3244
3244
|
>
|
|
3245
|
-
${U ?
|
|
3245
|
+
${U ? c`<span class="segment-icon">${e.slot("item-icon", f)}</span>` : b}
|
|
3246
3246
|
${Q ? b : V}
|
|
3247
|
-
${x ?
|
|
3247
|
+
${x ? c`<span class="segment-badge">${e.slot("item-badge", f)}</span>` : b}
|
|
3248
3248
|
</button>
|
|
3249
3249
|
`;
|
|
3250
3250
|
})}
|
|
3251
3251
|
</div>
|
|
3252
3252
|
`;
|
|
3253
|
-
}, E = () =>
|
|
3253
|
+
}, E = () => c`
|
|
3254
3254
|
<div
|
|
3255
3255
|
class=${A("radio-container", {
|
|
3256
3256
|
"disabled-container": u,
|
|
@@ -3260,12 +3260,12 @@ const Ms = be({
|
|
|
3260
3260
|
>
|
|
3261
3261
|
${m.map((W, te) => {
|
|
3262
3262
|
const re = i(W);
|
|
3263
|
-
return
|
|
3263
|
+
return c`
|
|
3264
3264
|
<div class="radio">
|
|
3265
3265
|
<label
|
|
3266
3266
|
for=${`${t}_${te}`}
|
|
3267
3267
|
class=${h(te, re)}
|
|
3268
|
-
style=${oe(
|
|
3268
|
+
style=${oe(d(te))}
|
|
3269
3269
|
>
|
|
3270
3270
|
<div class="radio-icon-wrapper">
|
|
3271
3271
|
<input
|
|
@@ -3295,7 +3295,7 @@ const Ms = be({
|
|
|
3295
3295
|
})}
|
|
3296
3296
|
</div>
|
|
3297
3297
|
`, z = "aria-label" in S || "aria-labelledby" in S, X = F && !z && s.label ? s.label : b;
|
|
3298
|
-
return
|
|
3298
|
+
return c`
|
|
3299
3299
|
<div
|
|
3300
3300
|
class=${A("moz-radio-buttons", { "label-position-left": s.labelPosition === "left" }, s.class)}
|
|
3301
3301
|
style=${oe(Pe(s.style))}
|
|
@@ -3338,7 +3338,7 @@ const Ms = be({
|
|
|
3338
3338
|
expose: !1
|
|
3339
3339
|
};
|
|
3340
3340
|
function Vo(e = "var(--moz-color-text-subtle)") {
|
|
3341
|
-
return
|
|
3341
|
+
return c`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3342
3342
|
<g>
|
|
3343
3343
|
<path
|
|
3344
3344
|
d="M0 6C0 4.81331 0.351894 3.65328 1.01118 2.66658C1.67047 1.67989 2.60754 0.910851 3.7039 0.456726C4.80026 0.00259972 6.00666 -0.11622 7.17054 0.115291C8.33443 0.346802 9.40353 0.918247 10.2426 1.75736C11.0818 2.59648 11.6532 3.66558 11.8847 4.82946C12.1162 5.99335 11.9974 7.19975 11.5433 8.2961C11.0892 9.39246 10.3201 10.3295 9.33342 10.9888C8.34673 11.6481 7.18669 12 6 12C4.40927 11.9981 2.88422 11.3654 1.75941 10.2406C0.634589 9.11578 0.00185261 7.59073 0 6ZM1.26 6C1.26 6.93773 1.53808 7.85439 2.05907 8.63407C2.58006 9.41374 3.32057 10.0214 4.18693 10.3802C5.05329 10.739 6.0066 10.8328 6.92629 10.6498C7.84598 10.4668 8.69075 10.0152 9.35375 9.35204C10.0167 8.6889 10.4682 7.84404 10.651 6.92431C10.8338 6.00458 10.7398 5.05129 10.3808 4.18501C10.0218 3.31872 9.41402 2.57835 8.63423 2.05752C7.85445 1.53669 6.93772 1.2588 6 1.259C4.74319 1.26059 3.53832 1.76063 2.64971 2.64942C1.76111 3.53822 1.26132 4.74319 1.26 6ZM5.743 9.7C5.5867 9.7 5.43678 9.63798 5.32616 9.52755C5.21554 9.41712 5.15326 9.26731 5.153 9.111V5.569C5.153 5.41243 5.21513 5.26226 5.32575 5.15146C5.43636 5.04065 5.58643 4.97827 5.743 4.978H6.163C6.31949 4.97853 6.4694 5.041 6.57996 5.15175C6.69052 5.2625 6.75274 5.41251 6.753 5.569V9.11C6.75247 9.26623 6.69011 9.41588 6.57955 9.52626C6.46899 9.63663 6.31922 9.69874 6.163 9.699L5.743 9.7ZM5.743 4.366C5.58652 4.366 5.43645 4.30384 5.32581 4.1932C5.21516 4.08255 5.153 3.93248 5.153 3.776V3.356C5.153 3.19943 5.21513 3.04926 5.32575 2.93846C5.43636 2.82765 5.58643 2.76527 5.743 2.765H6.163C6.31949 2.76553 6.4694 2.828 6.57996 2.93875C6.69052 3.04949 6.75274 3.19951 6.753 3.356V3.776C6.75274 3.9324 6.69049 4.08231 6.5799 4.1929C6.46931 4.30349 6.3194 4.36574 6.163 4.366H5.743Z"
|
|
@@ -3400,7 +3400,7 @@ const qs = /* @__PURE__ */ new Set([
|
|
|
3400
3400
|
t.save = "", t.blur = "", e.emit("update:modelValue", p), n(p, "change");
|
|
3401
3401
|
}, h = () => {
|
|
3402
3402
|
t.save = "", o = !0, e.requestUpdate();
|
|
3403
|
-
},
|
|
3403
|
+
}, d = (r) => {
|
|
3404
3404
|
const p = r.target.value;
|
|
3405
3405
|
n(p, "blur"), o = !1, e.requestUpdate();
|
|
3406
3406
|
}, s = (r) => {
|
|
@@ -3420,7 +3420,7 @@ const qs = /* @__PURE__ */ new Set([
|
|
|
3420
3420
|
},
|
|
3421
3421
|
render() {
|
|
3422
3422
|
const r = e.props, p = String(r.modelValue ?? ""), u = t.save || t.blur || t.change, v = !!r.useInvalidV2, $ = r.width ? typeof r.width == "number" ? `${r.width}px` : r.width : "100%", F = we(r, qs);
|
|
3423
|
-
return
|
|
3423
|
+
return c`
|
|
3424
3424
|
<div
|
|
3425
3425
|
class=${A("moz-input-wrapper", { "is-invalid": u !== "" }, r.class)}
|
|
3426
3426
|
style="width:${$}"
|
|
@@ -3444,12 +3444,12 @@ const qs = /* @__PURE__ */ new Set([
|
|
|
3444
3444
|
@input=${i}
|
|
3445
3445
|
@keypress=${s}
|
|
3446
3446
|
@focus=${h}
|
|
3447
|
-
@blur=${
|
|
3447
|
+
@blur=${d}
|
|
3448
3448
|
/>
|
|
3449
|
-
${v && u !== "" && !o ?
|
|
3450
|
-
${e.slots.has("invalidTooltip") ? e.slot("invalidTooltip", { message: u }) :
|
|
3449
|
+
${v && u !== "" && !o ? c`<div class="moz-input-invalid-icon-v2">
|
|
3450
|
+
${e.slots.has("invalidTooltip") ? e.slot("invalidTooltip", { message: u }) : c`<div title=${u}>${Vo("var(--moz-color-danger)")}</div>`}
|
|
3451
3451
|
</div>` : b}
|
|
3452
|
-
${!v && u !== "" && !o ?
|
|
3452
|
+
${!v && u !== "" && !o ? c`<span class=${A("moz-input-invalid-message", `position-${r.messagePosition}`)}
|
|
3453
3453
|
>${u}</span
|
|
3454
3454
|
>` : b}
|
|
3455
3455
|
</div>
|
|
@@ -3482,7 +3482,7 @@ const qs = /* @__PURE__ */ new Set([
|
|
|
3482
3482
|
expose: !1
|
|
3483
3483
|
};
|
|
3484
3484
|
function Is() {
|
|
3485
|
-
return
|
|
3485
|
+
return c`<svg data-icon="password-hidden" width="18" height="18" viewBox="0 0 18 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3486
3486
|
<path d="M1.5 1.5L16.5 14.5" stroke="var(--moz-color-text-secondary)" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3487
3487
|
<path
|
|
3488
3488
|
d="M7.5 8C7.5 7.17157 8.17157 6.5 9 6.5C9.82843 6.5 10.5 7.17157 10.5 8C10.5 8.82843 9.82843 9.5 9 9.5C8.17157 9.5 7.5 8.82843 7.5 8Z"
|
|
@@ -3499,7 +3499,7 @@ function Is() {
|
|
|
3499
3499
|
</svg>`;
|
|
3500
3500
|
}
|
|
3501
3501
|
function Rs() {
|
|
3502
|
-
return
|
|
3502
|
+
return c`<svg data-icon="password-visible" width="18" height="18" viewBox="0 0 18 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3503
3503
|
<path
|
|
3504
3504
|
d="M7.5 6C7.5 5.17157 8.17157 4.5 9 4.5C9.82843 4.5 10.5 5.17157 10.5 6C10.5 6.82843 9.82843 7.5 9 7.5C8.17157 7.5 7.5 6.82843 7.5 6Z"
|
|
3505
3505
|
stroke="var(--moz-color-text-secondary)"
|
|
@@ -3553,7 +3553,7 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3553
3553
|
}, h = (u) => {
|
|
3554
3554
|
const v = u.target.value;
|
|
3555
3555
|
t.save = "", t.blur = "", e.emit("update:modelValue", v), i(v, "change");
|
|
3556
|
-
},
|
|
3556
|
+
}, d = () => {
|
|
3557
3557
|
t.save = "", o = !0, e.requestUpdate();
|
|
3558
3558
|
}, s = (u) => {
|
|
3559
3559
|
i(u.target.value, "blur"), o = !1, e.requestUpdate();
|
|
@@ -3576,7 +3576,7 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3576
3576
|
const u = e.props;
|
|
3577
3577
|
u.disabled && (l = !1);
|
|
3578
3578
|
const v = String(u.modelValue ?? ""), $ = t.save || t.blur || t.change, F = !!u.useInvalidV2, S = u.width ? typeof u.width == "number" ? `${u.width}px` : u.width : "100%", y = we(u, Bs);
|
|
3579
|
-
return
|
|
3579
|
+
return c`
|
|
3580
3580
|
<div
|
|
3581
3581
|
class=${A("moz-password-input-container", { "is-invalid": $ !== "", disabled: u.disabled }, u.class)}
|
|
3582
3582
|
>
|
|
@@ -3599,7 +3599,7 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3599
3599
|
${pe(y)}
|
|
3600
3600
|
@input=${h}
|
|
3601
3601
|
@keypress=${m}
|
|
3602
|
-
@focus=${
|
|
3602
|
+
@focus=${d}
|
|
3603
3603
|
@blur=${s}
|
|
3604
3604
|
/>
|
|
3605
3605
|
<button
|
|
@@ -3615,10 +3615,10 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3615
3615
|
>
|
|
3616
3616
|
${l ? Is() : Rs()}
|
|
3617
3617
|
</button>
|
|
3618
|
-
${F && $ !== "" && !o ?
|
|
3619
|
-
${e.slots.has("invalidTooltip") ? e.slot("invalidTooltip", { message: $ }) :
|
|
3618
|
+
${F && $ !== "" && !o ? c`<div class="moz-input-invalid-icon-v2">
|
|
3619
|
+
${e.slots.has("invalidTooltip") ? e.slot("invalidTooltip", { message: $ }) : c`<div title=${$}>${Vo("var(--moz-color-danger)")}</div>`}
|
|
3620
3620
|
</div>` : b}
|
|
3621
|
-
${!F && $ !== "" && !o ?
|
|
3621
|
+
${!F && $ !== "" && !o ? c`<span class=${A("moz-input-invalid-message", `position-${u.messagePosition}`)}
|
|
3622
3622
|
>${$}</span
|
|
3623
3623
|
>` : b}
|
|
3624
3624
|
</div>
|
|
@@ -3703,15 +3703,15 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3703
3703
|
l(s.target.value, "blur");
|
|
3704
3704
|
}, h = () => {
|
|
3705
3705
|
t.save = "", e.requestUpdate();
|
|
3706
|
-
},
|
|
3706
|
+
}, d = {
|
|
3707
3707
|
validate: (s = "save") => l(String(e.props.modelValue ?? ""), s),
|
|
3708
3708
|
initValidator: () => {
|
|
3709
3709
|
t.change = t.blur = t.save = "", e.requestUpdate();
|
|
3710
3710
|
}
|
|
3711
3711
|
};
|
|
3712
|
-
return e.validator && (e.validator.addValidator(
|
|
3712
|
+
return e.validator && (e.validator.addValidator(d), e.onCleanup(() => {
|
|
3713
3713
|
var s;
|
|
3714
|
-
return (s = e.validator) == null ? void 0 : s.removeValidator(
|
|
3714
|
+
return (s = e.validator) == null ? void 0 : s.removeValidator(d);
|
|
3715
3715
|
})), {
|
|
3716
3716
|
onMounted: (s) => {
|
|
3717
3717
|
var m;
|
|
@@ -3719,7 +3719,7 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3719
3719
|
},
|
|
3720
3720
|
render() {
|
|
3721
3721
|
const s = e.props, m = String(s.modelValue ?? ""), r = t.save || t.blur || t.change, p = s.width ? typeof s.width == "number" ? `${ze(s.width)}rem` : s.width : "100%", u = `${ze(s.height ?? 80)}rem`, v = s.resize ?? "none", $ = v === "none" ? `height:${u}` : `min-height:${u}`, F = m.length, S = we(s, Ns);
|
|
3722
|
-
return
|
|
3722
|
+
return c`
|
|
3723
3723
|
<div
|
|
3724
3724
|
class=${A("moz-textarea-wrapper", { disabled: s.disabled }, s.class)}
|
|
3725
3725
|
style="width:${p};${$}"
|
|
@@ -3745,10 +3745,10 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3745
3745
|
@blur=${i}
|
|
3746
3746
|
@focus=${h}
|
|
3747
3747
|
></textarea>
|
|
3748
|
-
${s.maxLength ?
|
|
3748
|
+
${s.maxLength ? c`<div class="char-counter"><span>${F}</span><span>/</span><span>${s.maxLength}</span></div>` : b}
|
|
3749
3749
|
</div>
|
|
3750
3750
|
</div>
|
|
3751
|
-
${r !== "" ?
|
|
3751
|
+
${r !== "" ? c`<span class="moz-textarea-invalid-message">${r}</span>` : b}
|
|
3752
3752
|
</div>
|
|
3753
3753
|
`;
|
|
3754
3754
|
}
|
|
@@ -3776,22 +3776,22 @@ const Bs = /* @__PURE__ */ new Set([
|
|
|
3776
3776
|
expose: !1
|
|
3777
3777
|
};
|
|
3778
3778
|
function _s(e = "var(--moz-color-on-accent)", t = !1) {
|
|
3779
|
-
return
|
|
3779
|
+
return c`<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3780
3780
|
<path d="M7 1V13M1 7H13" stroke=${t ? "var(--moz-color-text-muted)" : e} stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3781
3781
|
</svg>`;
|
|
3782
3782
|
}
|
|
3783
3783
|
function Ws(e = "var(--moz-color-on-accent)", t = !1) {
|
|
3784
|
-
return
|
|
3784
|
+
return c`<svg width="14" height="2" viewBox="0 0 14 2" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3785
3785
|
<path d="M1 1H13" stroke=${t ? "var(--moz-color-text-muted)" : e} stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3786
3786
|
</svg>`;
|
|
3787
3787
|
}
|
|
3788
3788
|
function Ks(e = !1) {
|
|
3789
|
-
return
|
|
3789
|
+
return c`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3790
3790
|
<path d="M9.50097 7.73588L5.95565 4.27686L2.49904 7.73588" stroke=${e ? "var(--moz-color-text-muted)" : "var(--moz-color-text-subtle)"} stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3791
3791
|
</svg>`;
|
|
3792
3792
|
}
|
|
3793
3793
|
function Gs(e = !1) {
|
|
3794
|
-
return
|
|
3794
|
+
return c`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3795
3795
|
<path d="M2.49901 4.27686L6.04435 7.73588L9.50099 4.27686" stroke=${e ? "var(--moz-color-text-muted)" : "var(--moz-color-text-subtle)"} stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3796
3796
|
</svg>`;
|
|
3797
3797
|
}
|
|
@@ -3824,32 +3824,32 @@ const Ys = /* @__PURE__ */ new Set([
|
|
|
3824
3824
|
},
|
|
3825
3825
|
setup(e) {
|
|
3826
3826
|
const t = () => {
|
|
3827
|
-
const
|
|
3828
|
-
if (
|
|
3829
|
-
const s =
|
|
3830
|
-
|
|
3827
|
+
const d = e.props;
|
|
3828
|
+
if (d.disabled || d.modelValue === void 0) return;
|
|
3829
|
+
const s = d.modelValue + d.step;
|
|
3830
|
+
d.max !== void 0 && d.max !== null && s > d.max || (e.emit("update:modelValue", s), e.emit("change", s));
|
|
3831
3831
|
}, o = () => {
|
|
3832
|
-
const
|
|
3833
|
-
if (
|
|
3834
|
-
const s =
|
|
3835
|
-
|
|
3836
|
-
}, l = (
|
|
3832
|
+
const d = e.props;
|
|
3833
|
+
if (d.disabled || d.modelValue === void 0) return;
|
|
3834
|
+
const s = d.modelValue - d.step;
|
|
3835
|
+
d.min !== void 0 && d.min !== null && s < d.min || (e.emit("update:modelValue", s), e.emit("change", s));
|
|
3836
|
+
}, l = (d) => {
|
|
3837
3837
|
const s = e.props;
|
|
3838
|
-
if (s.disabled || s.nullable ||
|
|
3839
|
-
const m =
|
|
3840
|
-
(v && r === 0 && p === u.length || !v && u.length === 1) &&
|
|
3841
|
-
}, n = (
|
|
3838
|
+
if (s.disabled || s.nullable || d.key !== "Backspace" && d.key !== "Delete" || s.min === -Number.MAX_VALUE || Number(s.modelValue) !== Number(s.min)) return;
|
|
3839
|
+
const m = d.target, r = m.selectionStart ?? 0, p = m.selectionEnd ?? 0, u = m.value, v = r !== p;
|
|
3840
|
+
(v && r === 0 && p === u.length || !v && u.length === 1) && d.preventDefault();
|
|
3841
|
+
}, n = (d) => {
|
|
3842
3842
|
const s = e.props;
|
|
3843
3843
|
if (s.disabled || s.nullable) return;
|
|
3844
|
-
const m =
|
|
3844
|
+
const m = d.target;
|
|
3845
3845
|
if (m.value === "") {
|
|
3846
3846
|
const r = s.min !== -Number.MAX_VALUE ? s.min : 0;
|
|
3847
3847
|
e.emit("update:modelValue", r), m.value = String(r), e.emit("change", r);
|
|
3848
3848
|
}
|
|
3849
|
-
}, i = (
|
|
3849
|
+
}, i = (d) => {
|
|
3850
3850
|
const s = e.props;
|
|
3851
3851
|
if (s.disabled) return;
|
|
3852
|
-
const m =
|
|
3852
|
+
const m = d.target;
|
|
3853
3853
|
if (!m && !s.nullable) {
|
|
3854
3854
|
e.emit("update:modelValue", 0), e.emit("change", 0);
|
|
3855
3855
|
return;
|
|
@@ -3858,16 +3858,16 @@ const Ys = /* @__PURE__ */ new Set([
|
|
|
3858
3858
|
Number(m.value) < s.min && (m.value = String(s.min)), Number(m.value) > s.max && (m.value = String(s.max));
|
|
3859
3859
|
const r = +m.value.replace(/,/g, "");
|
|
3860
3860
|
e.emit("update:modelValue", r), e.emit("change", r);
|
|
3861
|
-
}, h = (
|
|
3862
|
-
|
|
3861
|
+
}, h = (d) => {
|
|
3862
|
+
d.key === "Enter" && e.emit("enter", d);
|
|
3863
3863
|
};
|
|
3864
3864
|
return {
|
|
3865
|
-
onMounted: (
|
|
3865
|
+
onMounted: (d) => e.emit("mounted", (d == null ? void 0 : d.querySelector("input")) ?? null),
|
|
3866
3866
|
render() {
|
|
3867
|
-
const
|
|
3868
|
-
<div class=${A("moz-number-input", { "input-border":
|
|
3867
|
+
const d = e.props, s = d.modelValue, m = !!d.disabled, r = d.min, p = d.max, u = typeof d.width == "number" ? `${ze(d.width)}rem` : d.width, v = we(d, Ys), $ = (S) => A("moz-button", "moz-icon-button", "moz-icon-accent-button", "num-change-btn", S), F = c`
|
|
3868
|
+
<div class=${A("moz-number-input", { "input-border": d.shortMode })}>
|
|
3869
3869
|
<input
|
|
3870
|
-
name=${Te(
|
|
3870
|
+
name=${Te(d.name)}
|
|
3871
3871
|
?disabled=${m}
|
|
3872
3872
|
.value=${kt(String(s ?? ""))}
|
|
3873
3873
|
${pe(v)}
|
|
@@ -3879,21 +3879,21 @@ const Ys = /* @__PURE__ */ new Set([
|
|
|
3879
3879
|
type="number"
|
|
3880
3880
|
/>
|
|
3881
3881
|
<div class="moz-number-input-btn">
|
|
3882
|
-
${
|
|
3882
|
+
${d.shortMode ? c`
|
|
3883
3883
|
<button type="button" aria-label=${e.locale.NumberInput.increase} class="moz-number-input-btn-icon" @click=${t}>${Ks(m)}</button>
|
|
3884
3884
|
<button type="button" aria-label=${e.locale.NumberInput.decrease} class="moz-number-input-btn-icon" @click=${o}>${Gs(m)}</button>
|
|
3885
3885
|
` : b}
|
|
3886
3886
|
</div>
|
|
3887
3887
|
</div>
|
|
3888
3888
|
`;
|
|
3889
|
-
return
|
|
3890
|
-
<div class=${A("moz-number-input-container", { disabled: m },
|
|
3891
|
-
${
|
|
3889
|
+
return c`
|
|
3890
|
+
<div class=${A("moz-number-input-container", { disabled: m }, d.class)}>
|
|
3891
|
+
${d.label ? Oe(
|
|
3892
3892
|
{ disabled: m },
|
|
3893
|
-
|
|
3893
|
+
c`${d.label}${d.required ? c`<span class="require-mark">*</span>` : b}`
|
|
3894
3894
|
) : b}
|
|
3895
3895
|
<div class="moz-number-input-wrapper" style="width:${u}">
|
|
3896
|
-
${
|
|
3896
|
+
${d.shortMode ? b : c`<button
|
|
3897
3897
|
type="button"
|
|
3898
3898
|
aria-label=${e.locale.NumberInput.decrease}
|
|
3899
3899
|
class=${$({ disabled: m || r >= s, "min-disabled": r >= s })}
|
|
@@ -3904,7 +3904,7 @@ const Ys = /* @__PURE__ */ new Set([
|
|
|
3904
3904
|
${Ws("var(--moz-color-on-accent)", m || r >= s)}
|
|
3905
3905
|
</button>`}
|
|
3906
3906
|
${F}
|
|
3907
|
-
${
|
|
3907
|
+
${d.shortMode ? b : c`<button
|
|
3908
3908
|
type="button"
|
|
3909
3909
|
aria-label=${e.locale.NumberInput.increase}
|
|
3910
3910
|
class=${$({ disabled: m || p <= s, "max-disabled": p <= s })}
|
|
@@ -3929,7 +3929,7 @@ const Ys = /* @__PURE__ */ new Set([
|
|
|
3929
3929
|
expose: !1
|
|
3930
3930
|
};
|
|
3931
3931
|
function js(e = "var(--moz-color-text-subtle)") {
|
|
3932
|
-
return
|
|
3932
|
+
return c`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3933
3933
|
<path d="M9 3L3 9M3 3L9 9" stroke=${e} stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
3934
3934
|
</svg>`;
|
|
3935
3935
|
}
|
|
@@ -3957,7 +3957,7 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
3957
3957
|
++y < 20 && n(q);
|
|
3958
3958
|
};
|
|
3959
3959
|
n(q);
|
|
3960
|
-
},
|
|
3960
|
+
}, d = (s) => {
|
|
3961
3961
|
const m = e.props;
|
|
3962
3962
|
if (m.modelValue === s) {
|
|
3963
3963
|
const r = (m.itemSource ?? []).filter((p) => p.id !== s);
|
|
@@ -3980,7 +3980,7 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
3980
3980
|
justifyContent: s.closeAble || s.vertical ? "space-between" : "center",
|
|
3981
3981
|
alignItems: s.vertical ? "center" : "normal"
|
|
3982
3982
|
});
|
|
3983
|
-
return
|
|
3983
|
+
return c`
|
|
3984
3984
|
<div
|
|
3985
3985
|
class=${A("moz-tabs-container", { vertical: s.vertical }, s.class)}
|
|
3986
3986
|
style=${oe(Pe(s.style))}
|
|
@@ -3993,7 +3993,7 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
3993
3993
|
>
|
|
3994
3994
|
${m.map((v) => {
|
|
3995
3995
|
const $ = r === v.id;
|
|
3996
|
-
return
|
|
3996
|
+
return c`
|
|
3997
3997
|
<div
|
|
3998
3998
|
class=${A("moz-tab", { "current-tab": $, vertical: s.vertical, closeable: s.closeAble })}
|
|
3999
3999
|
style=${u}
|
|
@@ -4008,12 +4008,12 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
4008
4008
|
}}
|
|
4009
4009
|
@keydown=${(F) => h(F, v.id)}
|
|
4010
4010
|
>
|
|
4011
|
-
${e.slots.has(`${v.id}-tab`) ? e.slot(`${v.id}-tab`, { text: v.text, active: $ }) :
|
|
4012
|
-
${s.closeAble ?
|
|
4011
|
+
${e.slots.has(`${v.id}-tab`) ? e.slot(`${v.id}-tab`, { text: v.text, active: $ }) : c`<p class=${A("tab-label", { active: $ })}>${v.text}</p>`}
|
|
4012
|
+
${s.closeAble ? c`<button type="button"
|
|
4013
4013
|
class="tab-close-btn"
|
|
4014
4014
|
aria-label=${e.locale.Tab.closeTab.replace("{label}", v.text ?? "")}
|
|
4015
4015
|
@click=${(F) => {
|
|
4016
|
-
F.stopPropagation(),
|
|
4016
|
+
F.stopPropagation(), d(v.id);
|
|
4017
4017
|
}}
|
|
4018
4018
|
>
|
|
4019
4019
|
${js()}
|
|
@@ -4024,7 +4024,7 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
4024
4024
|
</div>
|
|
4025
4025
|
<div class="moz-tab-body">
|
|
4026
4026
|
${m.map(
|
|
4027
|
-
(v) =>
|
|
4027
|
+
(v) => c`
|
|
4028
4028
|
<div
|
|
4029
4029
|
class=${A("tab-panel", { active: r === v.id })}
|
|
4030
4030
|
id=${l(v.id)}
|
|
@@ -4067,12 +4067,12 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
4067
4067
|
window.removeEventListener("mousemove", n), window.removeEventListener("mouseup", i), l == null || l.focus();
|
|
4068
4068
|
}, h = (p) => {
|
|
4069
4069
|
e.props.disabled || (p.preventDefault(), l = p.currentTarget, o = l.querySelector(".moz-slider"), n(p), window.addEventListener("mousemove", n), window.addEventListener("mouseup", i));
|
|
4070
|
-
},
|
|
4070
|
+
}, d = (p) => {
|
|
4071
4071
|
const u = e.props;
|
|
4072
4072
|
let v = u.modelValue ?? 0;
|
|
4073
4073
|
p === "-" ? v -= u.step : v += u.step, v > u.max ? v = u.max : v < u.min && (v = u.min), e.emit("update:modelValue", v), e.emit("change");
|
|
4074
4074
|
}, s = (p) => {
|
|
4075
|
-
p.key === "ArrowLeft" || p.keyCode === 37 ?
|
|
4075
|
+
p.key === "ArrowLeft" || p.keyCode === 37 ? d("-") : (p.key === "ArrowRight" || p.keyCode === 39) && d("+");
|
|
4076
4076
|
}, m = () => {
|
|
4077
4077
|
t = !0, e.requestUpdate();
|
|
4078
4078
|
}, r = () => {
|
|
@@ -4083,7 +4083,7 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
4083
4083
|
}), {
|
|
4084
4084
|
render() {
|
|
4085
4085
|
const p = e.props, u = p.modelValue ?? 0, v = !!p.disabled, $ = p.min, F = p.max, S = typeof p.width == "number" ? `${ze(p.width)}rem` : p.width, y = typeof p.width == "number" ? p.width : Number.isNaN(parseFloat(String(p.width))) ? 150 : parseFloat(String(p.width)), E = (u - $) / (F - $) * (y - 18), z = E < 0 ? 0 : E, X = we(p, Js);
|
|
4086
|
-
return
|
|
4086
|
+
return c`
|
|
4087
4087
|
<div class=${A("moz-slider-wrapper", p.class)} style=${oe(Pe(p.style))} ${pe(X)}>
|
|
4088
4088
|
${p.label ? Oe({ for: p.id }, p.label) : b}
|
|
4089
4089
|
<div
|
|
@@ -4123,12 +4123,12 @@ const Xs = /* @__PURE__ */ new Set(["itemSource", "vertical", "tabWidth", "maxTa
|
|
|
4123
4123
|
expose: !1
|
|
4124
4124
|
};
|
|
4125
4125
|
function tl(e = "var(--moz-color-text-subtle)") {
|
|
4126
|
-
return
|
|
4126
|
+
return c`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4127
4127
|
<path d="M3 4.5L6 7.5L9 4.5" stroke=${e} stroke-linecap="round" stroke-linejoin="round"></path>
|
|
4128
4128
|
</svg>`;
|
|
4129
4129
|
}
|
|
4130
4130
|
function ol(e = "var(--moz-color-text-subtle)") {
|
|
4131
|
-
return
|
|
4131
|
+
return c`<svg width="10" height="10" viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4132
4132
|
<path
|
|
4133
4133
|
fill-rule="evenodd"
|
|
4134
4134
|
clip-rule="evenodd"
|
|
@@ -4138,7 +4138,7 @@ function ol(e = "var(--moz-color-text-subtle)") {
|
|
|
4138
4138
|
</svg>`;
|
|
4139
4139
|
}
|
|
4140
4140
|
function sl(e = "var(--moz-color-text-subtle)") {
|
|
4141
|
-
return
|
|
4141
|
+
return c`<svg width="10" height="10" viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4142
4142
|
<path
|
|
4143
4143
|
fill-rule="evenodd"
|
|
4144
4144
|
clip-rule="evenodd"
|
|
@@ -4148,7 +4148,7 @@ function sl(e = "var(--moz-color-text-subtle)") {
|
|
|
4148
4148
|
</svg>`;
|
|
4149
4149
|
}
|
|
4150
4150
|
function ll(e = "var(--moz-color-text-subtle)") {
|
|
4151
|
-
return
|
|
4151
|
+
return c`<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4152
4152
|
<path
|
|
4153
4153
|
d="M11.5 2.7H2.50001C1.78204 2.7 1.20001 3.28203 1.20001 4V12C1.20001 12.718 1.78204 13.3 2.50001 13.3H11.5C12.218 13.3 12.8 12.718 12.8 12V4C12.8 3.28203 12.218 2.7 11.5 2.7Z"
|
|
4154
4154
|
stroke=${e}
|
|
@@ -4168,7 +4168,7 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4168
4168
|
defaults: { rowHeight: 36, exceptWeeks: [], min: null, max: null },
|
|
4169
4169
|
setup(e) {
|
|
4170
4170
|
let t = e.props.modelValue ? Le(e.props.modelValue) : Le(), o = e.props.modelValue, l = !0, n = !1, i = !1, h = -1;
|
|
4171
|
-
const
|
|
4171
|
+
const d = (E) => {
|
|
4172
4172
|
const z = e.props;
|
|
4173
4173
|
return !!z.min && E.isBefore(z.min, "day") || !!z.max && E.isAfter(z.max, "day");
|
|
4174
4174
|
}, s = (E) => {
|
|
@@ -4192,7 +4192,7 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4192
4192
|
}, S = (E) => {
|
|
4193
4193
|
m(E) || (t = t.set("month", E.month()), l = !0, n = !1, i = !1, e.requestUpdate());
|
|
4194
4194
|
}, y = (E) => {
|
|
4195
|
-
|
|
4195
|
+
d(E) || e.emit("update:modelValue", Le(E));
|
|
4196
4196
|
}, q = () => y(Le());
|
|
4197
4197
|
return {
|
|
4198
4198
|
render() {
|
|
@@ -4211,7 +4211,7 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4211
4211
|
const se = (T, V) => {
|
|
4212
4212
|
const B = T.add(V, "d");
|
|
4213
4213
|
return t.format("YYYYMMDD") !== B.format("YYYYMMDD") ? t.format("MM") === B.format("MM") ? "" : "moz-calendar-column-otherMonth" : "";
|
|
4214
|
-
}, ie = E.modelValue ? Le(E.modelValue).format("YYYYMMDD") : "", Q = (T, V, B) =>
|
|
4214
|
+
}, ie = E.modelValue ? Le(E.modelValue).format("YYYYMMDD") : "", Q = (T, V, B) => c`<button
|
|
4215
4215
|
type="button"
|
|
4216
4216
|
aria-label=${B}
|
|
4217
4217
|
class="moz-button moz-icon-button"
|
|
@@ -4219,15 +4219,15 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4219
4219
|
@click=${V}
|
|
4220
4220
|
>
|
|
4221
4221
|
${T}
|
|
4222
|
-
</button>`, U =
|
|
4222
|
+
</button>`, U = c`
|
|
4223
4223
|
<div class="moz-calendar-header">
|
|
4224
4224
|
<div class="moz-calendar-select">
|
|
4225
|
-
${X ?
|
|
4225
|
+
${X ? c`
|
|
4226
4226
|
<div class="moz-calendar-select__text" @click=${v}>
|
|
4227
4227
|
${new Intl.DateTimeFormat(Le().locale(), { year: "numeric" }).format(t.toDate())}
|
|
4228
4228
|
</div>
|
|
4229
4229
|
<div class="moz-calendar-select__text" @click=${$}>${t.format("MMMM")}</div>
|
|
4230
|
-
` :
|
|
4230
|
+
` : c`
|
|
4231
4231
|
<div class="moz-calendar-select__text" @click=${$}>${t.format("MMMM")}</div>
|
|
4232
4232
|
<div class="moz-calendar-select__text" @click=${v}>${t.format("YYYY")}</div>
|
|
4233
4233
|
`}
|
|
@@ -4242,10 +4242,10 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4242
4242
|
)}${Q(sl(), p, "다음 달")}
|
|
4243
4243
|
</div>
|
|
4244
4244
|
</div>
|
|
4245
|
-
`, x =
|
|
4245
|
+
`, x = c`
|
|
4246
4246
|
<div class="moz-calendar-row">
|
|
4247
4247
|
${K.map(
|
|
4248
|
-
(T) =>
|
|
4248
|
+
(T) => c`<div
|
|
4249
4249
|
class="moz-calendar-column moz-calendar-column-day"
|
|
4250
4250
|
style="width: ${100 / K.length}%; height: ${ze(z)}rem;"
|
|
4251
4251
|
>
|
|
@@ -4254,15 +4254,15 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4254
4254
|
)}
|
|
4255
4255
|
</div>
|
|
4256
4256
|
${D.map(
|
|
4257
|
-
(T) =>
|
|
4257
|
+
(T) => c`<div class="moz-calendar-row">
|
|
4258
4258
|
${K.map((V) => {
|
|
4259
4259
|
const B = T.add(V, "d");
|
|
4260
|
-
return
|
|
4260
|
+
return c`<div
|
|
4261
4261
|
class=${A(
|
|
4262
4262
|
"moz-calendar-column",
|
|
4263
4263
|
se(T, V),
|
|
4264
4264
|
ie === B.format("YYYYMMDD") ? "moz-calendar-selected" : "",
|
|
4265
|
-
|
|
4265
|
+
d(B) ? "date-disable" : "moz-calendar-column--hoverable"
|
|
4266
4266
|
)}
|
|
4267
4267
|
style="width: ${100 / K.length}%; height: ${ze(z)}rem"
|
|
4268
4268
|
@click=${() => y(B)}
|
|
@@ -4280,12 +4280,12 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4280
4280
|
do
|
|
4281
4281
|
T.push(B), B = B.add(1, "y");
|
|
4282
4282
|
while (B.diff(V) <= 0);
|
|
4283
|
-
M =
|
|
4283
|
+
M = c`<div
|
|
4284
4284
|
class="moz-calendar-row moz-calendar-row--wrap"
|
|
4285
4285
|
style="max-height: ${ze(z * D.length)}rem"
|
|
4286
4286
|
>
|
|
4287
4287
|
${T.map(
|
|
4288
|
-
(f) =>
|
|
4288
|
+
(f) => c`<div
|
|
4289
4289
|
class=${A(
|
|
4290
4290
|
"moz-calendar-column",
|
|
4291
4291
|
t.format("YYYY") === f.format("YYYY") ? "moz-calendar-selected" : "",
|
|
@@ -4306,9 +4306,9 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4306
4306
|
do
|
|
4307
4307
|
T.push(B), B = B.add(1, "M");
|
|
4308
4308
|
while (B.diff(V) <= 0);
|
|
4309
|
-
_ =
|
|
4309
|
+
_ = c`<div class="moz-calendar-row moz-calendar-row--wrap">
|
|
4310
4310
|
${T.map(
|
|
4311
|
-
(f) =>
|
|
4311
|
+
(f) => c`<div
|
|
4312
4312
|
class=${A(
|
|
4313
4313
|
"moz-calendar-column",
|
|
4314
4314
|
t.format("YYYYMM") === f.format("YYYYMM") ? "moz-calendar-selected" : "",
|
|
@@ -4323,7 +4323,7 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4323
4323
|
</div>`;
|
|
4324
4324
|
}
|
|
4325
4325
|
const k = we(E, nl);
|
|
4326
|
-
return
|
|
4326
|
+
return c`
|
|
4327
4327
|
<div class=${A("moz-calendar-container", E.class)} ${pe(k)}>
|
|
4328
4328
|
${U}${l ? x : b}${M}${_}
|
|
4329
4329
|
</div>
|
|
@@ -4340,17 +4340,17 @@ const nl = /* @__PURE__ */ new Set(["rowHeight", "exceptWeeks", "min", "max", "m
|
|
|
4340
4340
|
expose: !1
|
|
4341
4341
|
};
|
|
4342
4342
|
function il(e = "var(--moz-color-on-accent)", t = "14", o = !1) {
|
|
4343
|
-
return
|
|
4343
|
+
return c`<svg width=${t} height=${t} viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4344
4344
|
<path d="M8.5 3.5L5.5 7L8.5 10.5" stroke=${o ? "var(--moz-color-text-muted)" : e} stroke-width="1.2" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
4345
4345
|
</svg>`;
|
|
4346
4346
|
}
|
|
4347
4347
|
function al(e = "var(--moz-color-on-accent)", t = "14", o = !1) {
|
|
4348
|
-
return
|
|
4348
|
+
return c`<svg width=${t} height=${t} viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4349
4349
|
<path d="M5.5 3.5L8.5 7L5.5 10.5" stroke=${o ? "var(--moz-color-text-muted)" : e} stroke-width="1.2" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
4350
4350
|
</svg>`;
|
|
4351
4351
|
}
|
|
4352
4352
|
function cl(e = "var(--moz-color-text-subtle)", t = "") {
|
|
4353
|
-
return
|
|
4353
|
+
return c`<svg class=${t} width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4354
4354
|
<path
|
|
4355
4355
|
d="M12 2.70001H3.00001C2.28204 2.70001 1.70001 3.28204 1.70001 4.00001V12C1.70001 12.718 2.28204 13.3 3.00001 13.3H12C12.718 13.3 13.3 12.718 13.3 12V4.00001C13.3 3.28204 12.718 2.70001 12 2.70001Z"
|
|
4356
4356
|
stroke=${e}
|
|
@@ -4383,12 +4383,12 @@ const dl = "YYYY-MM-DD", ul = /* @__PURE__ */ new Set([
|
|
|
4383
4383
|
defaults: { label: "", width: 200, required: !1, disabled: !1, readonly: !1, showSpin: !1, min: null, max: null },
|
|
4384
4384
|
setup(e) {
|
|
4385
4385
|
let t = !1, o = 270, l = e.props.modelValue, n = null, i = null;
|
|
4386
|
-
const h = new Ot(),
|
|
4386
|
+
const h = new Ot(), d = (S) => {
|
|
4387
4387
|
const y = e.props.modelValue;
|
|
4388
4388
|
let q;
|
|
4389
4389
|
S && y instanceof Date ? q = Le(S).toDate() : S && Le.isDayjs(y) || !y && S ? q = Le(S) : q = void 0, e.emit("update:modelValue", q);
|
|
4390
4390
|
}, s = ((S, ...y) => {
|
|
4391
|
-
S === "update:modelValue" ?
|
|
4391
|
+
S === "update:modelValue" ? d(y[0]) : S === "setMaxHeight" && (o = y[0], m.calcPosition());
|
|
4392
4392
|
}), m = new zt({
|
|
4393
4393
|
anchor: () => n == null ? void 0 : n.querySelector(".moz-date-input-wrapper"),
|
|
4394
4394
|
panel: () => h.element,
|
|
@@ -4412,12 +4412,12 @@ const dl = "YYYY-MM-DD", ul = /* @__PURE__ */ new Set([
|
|
|
4412
4412
|
const S = e.props;
|
|
4413
4413
|
S.disabled || S.readonly || (t = !t, t ? ((y = n == null ? void 0 : n.querySelector("input")) == null || y.focus(), r()) : p(), e.requestUpdate());
|
|
4414
4414
|
}, v = () => {
|
|
4415
|
-
e.props.modelValue &&
|
|
4415
|
+
e.props.modelValue && d(Le(e.props.modelValue).subtract(1, "d"));
|
|
4416
4416
|
}, $ = () => {
|
|
4417
|
-
e.props.modelValue &&
|
|
4417
|
+
e.props.modelValue && d(Le(e.props.modelValue).add(1, "d"));
|
|
4418
4418
|
}, F = (S) => {
|
|
4419
4419
|
const y = S.target, q = e.props.modelValue;
|
|
4420
|
-
q ? Le.isDayjs(q) && Le(y.value).isValid() ?
|
|
4420
|
+
q ? Le.isDayjs(q) && Le(y.value).isValid() ? d(Le(y.value)) : q instanceof Date && !Number.isNaN(Date.parse(y.value)) ? d(new Date(y.value)) : d(void 0) : d(Le(y.value));
|
|
4421
4421
|
};
|
|
4422
4422
|
return e.onCleanup(() => {
|
|
4423
4423
|
m.destroy(), i == null || i.destroy(), h.close();
|
|
@@ -4432,7 +4432,7 @@ const dl = "YYYY-MM-DD", ul = /* @__PURE__ */ new Set([
|
|
|
4432
4432
|
const re = S.modelValue;
|
|
4433
4433
|
queueMicrotask(() => e.emit("change", re)), i && i.update({ modelValue: S.modelValue });
|
|
4434
4434
|
}
|
|
4435
|
-
const y = S.format || dl, q = typeof S.width == "number" ? `${ze(S.width)}rem` : S.width, E = S.modelValue ? Le(S.modelValue).format(y) : "", z = !!S.min && Le(E).isSameOrBefore(Le(S.min), "day"), X = !!S.max && Le(E).isSameOrAfter(Le(S.max), "day"), W = we(S, ul), te = (re, ee, K, D) =>
|
|
4435
|
+
const y = S.format || dl, q = typeof S.width == "number" ? `${ze(S.width)}rem` : S.width, E = S.modelValue ? Le(S.modelValue).format(y) : "", z = !!S.min && Le(E).isSameOrBefore(Le(S.min), "day"), X = !!S.max && Le(E).isSameOrAfter(Le(S.max), "day"), W = we(S, ul), te = (re, ee, K, D) => c`<button
|
|
4436
4436
|
type="button"
|
|
4437
4437
|
aria-label=${ee === "left" ? e.locale.DateInput.prevDate : e.locale.DateInput.nextDate}
|
|
4438
4438
|
class=${A(
|
|
@@ -4449,14 +4449,14 @@ const dl = "YYYY-MM-DD", ul = /* @__PURE__ */ new Set([
|
|
|
4449
4449
|
>
|
|
4450
4450
|
${re}
|
|
4451
4451
|
</button>`;
|
|
4452
|
-
return
|
|
4452
|
+
return c`
|
|
4453
4453
|
<div
|
|
4454
4454
|
class=${A("moz-date-input-container", { disabled: S.disabled }, S.class)}
|
|
4455
4455
|
style=${oe({ ...Pe(S.style), width: q })}
|
|
4456
4456
|
>
|
|
4457
4457
|
${S.label ? Oe(
|
|
4458
4458
|
{ disabled: S.disabled },
|
|
4459
|
-
|
|
4459
|
+
c`${S.label}${S.required ? c`<span class="require-mark">*</span>` : b}`
|
|
4460
4460
|
) : b}
|
|
4461
4461
|
<div class="moz-date-input-wrapper" style="width:${q}">
|
|
4462
4462
|
${S.showSpin ? te(
|
|
@@ -4482,7 +4482,7 @@ const dl = "YYYY-MM-DD", ul = /* @__PURE__ */ new Set([
|
|
|
4482
4482
|
${pe(W)}
|
|
4483
4483
|
@change=${F}
|
|
4484
4484
|
/>
|
|
4485
|
-
${S.readonly ? b :
|
|
4485
|
+
${S.readonly ? b : c`<div class="moz-date-input__icon-container">
|
|
4486
4486
|
${cl(
|
|
4487
4487
|
"currentColor",
|
|
4488
4488
|
A("moz-date-input__icon", { "moz-date-input__icon--disabled": S.disabled })
|
|
@@ -4523,16 +4523,16 @@ function ut(e) {
|
|
|
4523
4523
|
}
|
|
4524
4524
|
function ml(e = "10", t = "var(--moz-color-text-muted)", o = !1, l = !1, n = "") {
|
|
4525
4525
|
const i = ut(e), h = n || b;
|
|
4526
|
-
return i.width <= 10 ?
|
|
4526
|
+
return i.width <= 10 ? c`<svg class=${h} width=${i.width} height=${i.height} viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4527
4527
|
<path d="M8.5 1.5L1.49999 8.50001" stroke=${t} stroke-width="1.75" stroke-linecap="round"></path>
|
|
4528
4528
|
<path d="M1.5 1.5L8.50001 8.50001" stroke=${t} stroke-width="1.75" stroke-linecap="round"></path>
|
|
4529
|
-
</svg>` : i.width <= 13 && i.width >= 11 && !l ?
|
|
4529
|
+
</svg>` : i.width <= 13 && i.width >= 11 && !l ? c`<svg class=${h} width=${i.width} height=${i.height} viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4530
4530
|
<path d="M1.71436 1.71428L10.8069 10.7926" stroke=${t} stroke-width="2" stroke-linecap="round"></path>
|
|
4531
4531
|
<path d="M10.8069 1.71428L1.71436 10.7926" stroke=${t} stroke-width="2" stroke-linecap="round"></path>
|
|
4532
|
-
</svg>` : i.width <= 13 && i.width >= 11 && l ?
|
|
4532
|
+
</svg>` : i.width <= 13 && i.width >= 11 && l ? c`<svg class=${h} width=${i.width} height=${i.height} viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4533
4533
|
<path d="M10.2 1.7998L1.79994 10.1998" stroke=${t} stroke-width="1.6" stroke-linecap="round"></path>
|
|
4534
4534
|
<path d="M1.79993 1.7998L10.1999 10.1998" stroke=${t} stroke-width="1.6" stroke-linecap="round"></path>
|
|
4535
|
-
</svg>` :
|
|
4535
|
+
</svg>` : c`<svg class=${h} width=${i.width} height=${i.height} viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4536
4536
|
<g>
|
|
4537
4537
|
<g>
|
|
4538
4538
|
<path
|
|
@@ -4553,7 +4553,7 @@ function ml(e = "10", t = "var(--moz-color-text-muted)", o = !1, l = !1, n = "")
|
|
|
4553
4553
|
}
|
|
4554
4554
|
function hl(e = "30", t = "var(--moz-color-danger)", o = "") {
|
|
4555
4555
|
const l = ut(e);
|
|
4556
|
-
return
|
|
4556
|
+
return c`<svg class=${o || b} width=${l.width} height=${l.height} viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4557
4557
|
<mask id="mask0_6027_4458" style="mask-type: luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="30" height="30">
|
|
4558
4558
|
<g><path d="M30 0H0V30H30V0Z" fill="#FFF"></path></g>
|
|
4559
4559
|
</mask>
|
|
@@ -4569,7 +4569,7 @@ function hl(e = "30", t = "var(--moz-color-danger)", o = "") {
|
|
|
4569
4569
|
}
|
|
4570
4570
|
function fl(e = "30", t = "var(--moz-color-accent)", o = "") {
|
|
4571
4571
|
const l = ut(e);
|
|
4572
|
-
return
|
|
4572
|
+
return c`<svg class=${o || b} width=${l.width} height=${l.height} viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4573
4573
|
<g>
|
|
4574
4574
|
<path
|
|
4575
4575
|
fill-rule="evenodd"
|
|
@@ -4582,7 +4582,7 @@ function fl(e = "30", t = "var(--moz-color-accent)", o = "") {
|
|
|
4582
4582
|
}
|
|
4583
4583
|
function gl(e = "30", t = "var(--moz-color-success)", o = "") {
|
|
4584
4584
|
const l = ut(e);
|
|
4585
|
-
return
|
|
4585
|
+
return c`<svg class=${o || b} width=${l.width} height=${l.height} viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4586
4586
|
<g>
|
|
4587
4587
|
<path
|
|
4588
4588
|
fill-rule="evenodd"
|
|
@@ -4595,7 +4595,7 @@ function gl(e = "30", t = "var(--moz-color-success)", o = "") {
|
|
|
4595
4595
|
}
|
|
4596
4596
|
function vl(e = "30", t = "var(--moz-color-warning)", o = "") {
|
|
4597
4597
|
const l = ut(e);
|
|
4598
|
-
return
|
|
4598
|
+
return c`<svg class=${o || b} width=${l.width} height=${l.height} viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4599
4599
|
<mask id="mask0_6027_4463" style="mask-type: luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="30" height="30">
|
|
4600
4600
|
<g><path d="M30 0H0V30H30V0Z" fill="#FFF"></path></g>
|
|
4601
4601
|
</mask>
|
|
@@ -4691,11 +4691,11 @@ const bl = () => {
|
|
|
4691
4691
|
},
|
|
4692
4692
|
setup(e) {
|
|
4693
4693
|
const t = ve(), o = ve(), l = tt("moz-popup-title-"), n = tt("moz-popup-desc-");
|
|
4694
|
-
let i = null, h = e.props.visible ?? !1,
|
|
4694
|
+
let i = null, h = e.props.visible ?? !1, d = e.props.width, s = e.props.height;
|
|
4695
4695
|
const m = () => e.controlled("visible") ? !!e.props.visible : h, r = (C) => {
|
|
4696
4696
|
e.controlled("visible") || (h = C), e.emit("update:visible", C), e.requestUpdate();
|
|
4697
|
-
}, p = () => e.controlled("width") ? e.props.width :
|
|
4698
|
-
e.controlled("width") || (
|
|
4697
|
+
}, p = () => e.controlled("width") ? e.props.width : d, u = (C) => {
|
|
4698
|
+
e.controlled("width") || (d = C), e.emit("update:width", C), e.requestUpdate();
|
|
4699
4699
|
}, v = () => e.controlled("height") ? e.props.height : s, $ = (C) => {
|
|
4700
4700
|
e.controlled("height") || (s = C), e.emit("update:height", C), e.requestUpdate();
|
|
4701
4701
|
};
|
|
@@ -4865,10 +4865,10 @@ const bl = () => {
|
|
|
4865
4865
|
...xe ? { width: `${ze(xe)}rem` } : {},
|
|
4866
4866
|
...Me ? { height: `${ze(Me)}rem` } : {},
|
|
4867
4867
|
...We ? {} : { left: `${ze(F)}rem`, top: `${ze(S)}rem` }
|
|
4868
|
-
}, ot = !!C.draggable && !We, Qe = !!C.resizeable && !Fe, Ze = typeof C.contentsPadding == "number" ? `${ze(C.contentsPadding)}rem` : C.contentsPadding, g = ke(), O = we(C, wl), R = e.slots.has("title") ? e.slot("title") :
|
|
4868
|
+
}, ot = !!C.draggable && !We, Qe = !!C.resizeable && !Fe, Ze = typeof C.contentsPadding == "number" ? `${ze(C.contentsPadding)}rem` : C.contentsPadding, g = ke(), O = we(C, wl), R = e.slots.has("title") ? e.slot("title") : c`<span class="truncate">${C.title}</span>`, J = e.slots.has("description"), le = e.slots.has("default") ? e.slot("default") : c`<div class="moz-dialog-body">
|
|
4869
4869
|
${$e(C.dialogIcon)}
|
|
4870
4870
|
<div class="dialog-message">${C.dialogMessage != null ? wo(C.dialogMessage) : b}</div>
|
|
4871
|
-
</div>`, me = e.slots.has("footer") ? e.slot("footer", { onConfirm: f, onCancel: V }) :
|
|
4871
|
+
</div>`, me = e.slots.has("footer") ? e.slot("footer", { onConfirm: f, onCancel: V }) : c`
|
|
4872
4872
|
${g.positive ? bt(
|
|
4873
4873
|
{
|
|
4874
4874
|
class: "preset-btn",
|
|
@@ -4883,7 +4883,7 @@ const bl = () => {
|
|
|
4883
4883
|
{ onClick: V, content: g.negative }
|
|
4884
4884
|
) : b}
|
|
4885
4885
|
`;
|
|
4886
|
-
return
|
|
4886
|
+
return c`
|
|
4887
4887
|
<div
|
|
4888
4888
|
class=${A(
|
|
4889
4889
|
"moz-popup-container",
|
|
@@ -4893,7 +4893,7 @@ const bl = () => {
|
|
|
4893
4893
|
)}
|
|
4894
4894
|
style=${Te(Ee ? "display: none;" : void 0)}
|
|
4895
4895
|
>
|
|
4896
|
-
${C.showBackdrop === !1 ? b :
|
|
4896
|
+
${C.showBackdrop === !1 ? b : c`<div class="moz-popup-backdrop" aria-hidden="true" @click=${Y}></div>`}
|
|
4897
4897
|
<div
|
|
4898
4898
|
class=${A("moz-popup", C.dialogClass)}
|
|
4899
4899
|
role="dialog"
|
|
@@ -4905,7 +4905,7 @@ const bl = () => {
|
|
|
4905
4905
|
${ne(t)}
|
|
4906
4906
|
${pe(O)}
|
|
4907
4907
|
>
|
|
4908
|
-
${C.showHeader === !1 ? b :
|
|
4908
|
+
${C.showHeader === !1 ? b : c`<div
|
|
4909
4909
|
id=${l}
|
|
4910
4910
|
class=${A("moz-popup-title", { draggable: ot })}
|
|
4911
4911
|
@mousedown=${Z}
|
|
@@ -4917,12 +4917,12 @@ const bl = () => {
|
|
|
4917
4917
|
{ onClick: V, icon: ml("14", "var(--moz-color-text-subtle)") }
|
|
4918
4918
|
) : b}
|
|
4919
4919
|
</div>`}
|
|
4920
|
-
${J ?
|
|
4920
|
+
${J ? c`<div id=${n} class="moz-popup-description">${e.slot("description")}</div>` : b}
|
|
4921
4921
|
<div class="moz-popup-body" style=${oe({ padding: Ze })} ${ne(o)}>${le}</div>
|
|
4922
|
-
${C.preset !== "no-footer" ?
|
|
4922
|
+
${C.preset !== "no-footer" ? c`<div class=${A("moz-popup-footer", { "with-border": C.showFooterBorder })}>
|
|
4923
4923
|
${me}
|
|
4924
4924
|
</div>` : b}
|
|
4925
|
-
${Qe ?
|
|
4925
|
+
${Qe ? c`<div class="resize-handler" @mousedown=${ae}></div>` : b}
|
|
4926
4926
|
</div>
|
|
4927
4927
|
</div>
|
|
4928
4928
|
`;
|
|
@@ -5011,7 +5011,7 @@ function Vt(e, t = 12) {
|
|
|
5011
5011
|
}
|
|
5012
5012
|
function Wt(e = "12", t = "var(--moz-color-text-subtle)", o = !1, l = "") {
|
|
5013
5013
|
const n = Vt(e), i = o ? "var(--moz-color-text-muted)" : t;
|
|
5014
|
-
return
|
|
5014
|
+
return c`<svg class=${l || b} xmlns="http://www.w3.org/2000/svg" width=${n.width} height=${n.height} viewBox="0 0 16 16">
|
|
5015
5015
|
<g style=${`fill: ${i}`}>
|
|
5016
5016
|
<path
|
|
5017
5017
|
d="M836.533 699.734h-.022a.928.928 0 0 1-.716-.336l-3.779-4.535a.926.926 0 0 1-.212-.68.93.93 0 0 1 1.643-.512l3.026 3.63 6.096-8.128a.922.922 0 0 1 .745-.373c.202 0 .396.064.559.186.199.15.328.367.363.614a.925.925 0 0 1-.177.69l-6.803 9.071a.928.928 0 0 1-.721.373h-.002z"
|
|
@@ -5028,7 +5028,7 @@ function Wt(e = "12", t = "var(--moz-color-text-subtle)", o = !1, l = "") {
|
|
|
5028
5028
|
}
|
|
5029
5029
|
function Kt(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5030
5030
|
const l = Vt(e, 14);
|
|
5031
|
-
return
|
|
5031
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5032
5032
|
<path
|
|
5033
5033
|
fill-rule="evenodd"
|
|
5034
5034
|
clip-rule="evenodd"
|
|
@@ -5039,7 +5039,7 @@ function Kt(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
|
5039
5039
|
}
|
|
5040
5040
|
function Gt(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5041
5041
|
const l = Vt(e, 14);
|
|
5042
|
-
return
|
|
5042
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5043
5043
|
<path
|
|
5044
5044
|
fill-rule="evenodd"
|
|
5045
5045
|
clip-rule="evenodd"
|
|
@@ -5050,12 +5050,12 @@ function Gt(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
|
5050
5050
|
}
|
|
5051
5051
|
function Yt(e = "12", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5052
5052
|
const l = Vt(e), n = o ? "var(--moz-color-text-muted)" : t;
|
|
5053
|
-
return l.width <= 13 ?
|
|
5053
|
+
return l.width <= 13 ? c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 12 12" fill="none">
|
|
5054
5054
|
<path
|
|
5055
5055
|
d="M10.293 11.375L7.71099 8.79103C6.76581 9.4655 5.60162 9.76002 4.44941 9.61616C3.29719 9.4723 2.24116 8.90058 1.49082 8.01442C0.740489 7.12825 0.350682 5.99242 0.398745 4.83225C0.446808 3.67209 0.929227 2.57239 1.75029 1.75133C2.57135 0.930264 3.67106 0.447845 4.83122 0.399783C5.99138 0.35172 7.12722 0.741526 8.01338 1.49186C8.89954 2.2422 9.47126 3.29823 9.61512 4.45044C9.75898 5.60265 9.46446 6.76684 8.78999 7.71203L11.373 10.294C11.5163 10.4374 11.5969 10.6318 11.5969 10.8345C11.5969 11.0373 11.5163 11.2317 11.373 11.375C11.2296 11.5184 11.0352 11.5989 10.8325 11.5989C10.6298 11.5989 10.4363 11.5184 10.293 11.375ZM1.92899 5.02703C1.92899 5.64015 2.1108 6.2395 2.45144 6.7493C2.79207 7.25909 3.27622 7.65642 3.84267 7.89106C4.40912 8.12569 5.03243 8.18708 5.63377 8.06746C6.23511 7.94785 6.78748 7.6526 7.22102 7.21906C7.65457 6.78552 7.94981 6.23315 8.06943 5.63181C8.18904 5.03047 8.12765 4.40716 7.89302 3.84071C7.65839 3.27426 7.26105 2.79011 6.75126 2.44947C6.24147 2.10884 5.64211 1.92703 5.02899 1.92703C4.20682 1.92703 3.41832 2.25364 2.83696 2.835C2.2556 3.41636 1.92899 4.20486 1.92899 5.02703Z"
|
|
5056
5056
|
fill=${n}
|
|
5057
5057
|
></path>
|
|
5058
|
-
</svg>` :
|
|
5058
|
+
</svg>` : c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5059
5059
|
<path
|
|
5060
5060
|
d="M5.84944 0.402344C2.83893 0.402344 0.398438 2.84284 0.398438 5.85334C0.398438 8.86385 2.83893 11.3043 5.84944 11.3043C7.0308 11.3043 8.12438 10.9285 9.01716 10.29L12.0619 13.3347C12.4134 13.6862 12.9832 13.6862 13.3347 13.3347C13.6862 12.9832 13.6862 12.4134 13.3347 12.0619L10.2893 9.01651C10.9259 8.12457 11.3004 7.03269 11.3004 5.85334C11.3004 2.84284 8.85994 0.402344 5.84944 0.402344ZM2.19844 5.85334C2.19844 3.83695 3.83305 2.20234 5.84944 2.20234C7.86583 2.20234 9.50044 3.83695 9.50044 5.85334C9.50044 7.86974 7.86583 9.50434 5.84944 9.50434C3.83305 9.50434 2.19844 7.86974 2.19844 5.85334Z"
|
|
5061
5061
|
fill=${n}
|
|
@@ -5110,7 +5110,7 @@ const xl = be({
|
|
|
5110
5110
|
},
|
|
5111
5111
|
setup(e) {
|
|
5112
5112
|
const t = ve(), o = ve(), l = ve(), n = ve(), i = ve(), h = ve();
|
|
5113
|
-
let
|
|
5113
|
+
let d = null, s = e.props.modelValue ?? null;
|
|
5114
5114
|
const m = () => e.controlled("modelValue") ? e.props.modelValue ?? null : s, r = (a) => {
|
|
5115
5115
|
e.controlled("modelValue") || (s = a), e.emit("update:modelValue", a), e.requestUpdate();
|
|
5116
5116
|
};
|
|
@@ -5119,7 +5119,7 @@ const xl = be({
|
|
|
5119
5119
|
let F = m();
|
|
5120
5120
|
const S = () => e.props.keyProp || "id", y = new Et({
|
|
5121
5121
|
count: 0,
|
|
5122
|
-
getScrollElement: () =>
|
|
5122
|
+
getScrollElement: () => d,
|
|
5123
5123
|
estimateSize: () => mt,
|
|
5124
5124
|
measureElement: (a) => a.getBoundingClientRect().height,
|
|
5125
5125
|
overscan: 5,
|
|
@@ -5132,7 +5132,7 @@ const xl = be({
|
|
|
5132
5132
|
U == null || U.release(), U = null;
|
|
5133
5133
|
}), e.onCleanup(y._didMount());
|
|
5134
5134
|
const q = (a) => {
|
|
5135
|
-
|
|
5135
|
+
d = a ?? null, a && (y._willUpdate(), e.requestUpdate());
|
|
5136
5136
|
}, E = (a) => e.props.itemsSource ? e.props.itemsSource.find((Z) => Z[S()] === a) ?? null : null, z = (a) => a ? typeof e.props.displayProp == "function" ? e.props.displayProp(a) : typeof a == "object" ? a[e.props.displayProp] : String(a) : "", X = () => {
|
|
5137
5137
|
const a = m();
|
|
5138
5138
|
if (!a && isNaN(Number(a))) return null;
|
|
@@ -5182,7 +5182,7 @@ const xl = be({
|
|
|
5182
5182
|
container: () => t.value ?? null,
|
|
5183
5183
|
useMinWidth: !0,
|
|
5184
5184
|
listWidth: () => e.props.listWidth,
|
|
5185
|
-
ignoreScrollTargets: (a) => a ===
|
|
5185
|
+
ignoreScrollTargets: (a) => a === d,
|
|
5186
5186
|
requestClose: () => {
|
|
5187
5187
|
p && x(!1);
|
|
5188
5188
|
}
|
|
@@ -5199,9 +5199,9 @@ const xl = be({
|
|
|
5199
5199
|
p !== a && (p = a, e.requestUpdate(), a ? (U = Mt(), se.open(), $.save = "", window.addEventListener("keydown", ie), queueMicrotask(() => {
|
|
5200
5200
|
var Z;
|
|
5201
5201
|
const L = m();
|
|
5202
|
-
if (L &&
|
|
5202
|
+
if (L && d) {
|
|
5203
5203
|
const ae = (e.props.itemsSource ?? []).findIndex((ue) => ue[S()] === L);
|
|
5204
|
-
|
|
5204
|
+
d.scrollTop = Q(ae);
|
|
5205
5205
|
}
|
|
5206
5206
|
h.value ? h.value.focus() : (Z = i.value) == null || Z.focus();
|
|
5207
5207
|
})) : (U == null || U.release(), U = null, se.close(), e.emit("close"), K(m(), "blur"), window.removeEventListener("keydown", ie), u = "", e.emit("close"), queueMicrotask(() => {
|
|
@@ -5217,7 +5217,7 @@ const xl = be({
|
|
|
5217
5217
|
}, k = kl((a) => {
|
|
5218
5218
|
u = a.target.value, e.requestUpdate(), queueMicrotask(() => {
|
|
5219
5219
|
const L = W().length;
|
|
5220
|
-
y.setOptions({ ...y.options, count: L }), y.measure(),
|
|
5220
|
+
y.setOptions({ ...y.options, count: L }), y.measure(), d && (d.scrollTop = 0, y.scrollToIndex(0), y.measure());
|
|
5221
5221
|
});
|
|
5222
5222
|
}, 300), T = (a) => {
|
|
5223
5223
|
var L;
|
|
@@ -5233,7 +5233,7 @@ const xl = be({
|
|
|
5233
5233
|
const ae = Z[0], ue = Z[Z.length - 1];
|
|
5234
5234
|
(a.target === ae || a.target === ue) && i.value && (a.target === ae && a.shiftKey ? (a.stopPropagation(), a.preventDefault(), ($e = i.value) == null || $e.focus()) : a.target === ue && !a.shiftKey && (a.stopPropagation(), a.preventDefault(), (C = i.value) == null || C.focus()));
|
|
5235
5235
|
}, B = (a) => {
|
|
5236
|
-
|
|
5236
|
+
d && (a.shiftKey ? d.scrollTop -= 24 : d.scrollTop += 24);
|
|
5237
5237
|
}, f = () => {
|
|
5238
5238
|
var L;
|
|
5239
5239
|
const a = Array.from(((L = l.value) == null ? void 0 : L.querySelectorAll('[tabindex="0"]')) ?? []);
|
|
@@ -5312,7 +5312,7 @@ const xl = be({
|
|
|
5312
5312
|
);
|
|
5313
5313
|
});
|
|
5314
5314
|
}
|
|
5315
|
-
const Z = typeof a.width == "number" ? `${ze(a.width)}rem` : a.width, ae = we(a, Sl), { aria: ue, dom: ke } = dt(ae), $e = e.slots.has("icon") ? e.slot("icon", { isOpen: p }) : p ? Gt("14", "var(--moz-color-accent)") : Kt("14", "var(--moz-color-text-subtle)", a.disabled), C =
|
|
5315
|
+
const Z = typeof a.width == "number" ? `${ze(a.width)}rem` : a.width, ae = we(a, Sl), { aria: ue, dom: ke } = dt(ae), $e = e.slots.has("icon") ? e.slot("icon", { isOpen: p }) : p ? Gt("14", "var(--moz-color-accent)") : Kt("14", "var(--moz-color-text-subtle)", a.disabled), C = c`<button
|
|
5316
5316
|
type="button"
|
|
5317
5317
|
class="icon-container"
|
|
5318
5318
|
${pe(ue)}
|
|
@@ -5326,7 +5326,7 @@ const xl = be({
|
|
|
5326
5326
|
?disabled=${!!a.disabled}
|
|
5327
5327
|
>
|
|
5328
5328
|
${$e}
|
|
5329
|
-
</button>`, I = e.slots.has("input-container") ?
|
|
5329
|
+
</button>`, I = e.slots.has("input-container") ? c`<div
|
|
5330
5330
|
class="moz-input-container select-input-container"
|
|
5331
5331
|
style=${oe({ width: Z })}
|
|
5332
5332
|
@click=${M}
|
|
@@ -5338,7 +5338,7 @@ const xl = be({
|
|
|
5338
5338
|
${e.slot("input-container", { text: X(), item: L })}
|
|
5339
5339
|
</div>
|
|
5340
5340
|
${C}
|
|
5341
|
-
</div>` :
|
|
5341
|
+
</div>` : c`<div
|
|
5342
5342
|
class="moz-input-container select-input-container"
|
|
5343
5343
|
style=${oe({ width: Z })}
|
|
5344
5344
|
@click=${M}
|
|
@@ -5357,7 +5357,7 @@ const xl = be({
|
|
|
5357
5357
|
${e.slot("input")}
|
|
5358
5358
|
${C}
|
|
5359
5359
|
</div>`;
|
|
5360
|
-
return
|
|
5360
|
+
return c`
|
|
5361
5361
|
<div
|
|
5362
5362
|
class=${A(
|
|
5363
5363
|
"moz-select",
|
|
@@ -5379,7 +5379,7 @@ const xl = be({
|
|
|
5379
5379
|
${I}
|
|
5380
5380
|
</div>
|
|
5381
5381
|
|
|
5382
|
-
${re() !== "" ?
|
|
5382
|
+
${re() !== "" ? c`<span class="moz-input-invalid-message">${re()}</span>` : b}
|
|
5383
5383
|
</div>
|
|
5384
5384
|
`;
|
|
5385
5385
|
},
|
|
@@ -5392,18 +5392,18 @@ const xl = be({
|
|
|
5392
5392
|
y.getVirtualItems(),
|
|
5393
5393
|
ae.length,
|
|
5394
5394
|
mt,
|
|
5395
|
-
|
|
5395
|
+
d
|
|
5396
5396
|
), ke = y.getTotalSize(), $e = ue.map((C) => {
|
|
5397
5397
|
if (C.index >= ae.length) return null;
|
|
5398
5398
|
const I = ae[C.index];
|
|
5399
5399
|
return I ? { index: C.index, value: I, size: C.size, start: C.start } : null;
|
|
5400
5400
|
}).filter((C) => C !== null);
|
|
5401
|
-
return
|
|
5401
|
+
return c`<div
|
|
5402
5402
|
class=${A("list-box", { "no-label": !a.label })}
|
|
5403
5403
|
@keydown=${_e}
|
|
5404
5404
|
${ne(l)}
|
|
5405
5405
|
>
|
|
5406
|
-
${a.useFilter ?
|
|
5406
|
+
${a.useFilter ? c`<div class="filter-input">
|
|
5407
5407
|
<input
|
|
5408
5408
|
${ne(h)}
|
|
5409
5409
|
@mousedown=${(C) => C.stopPropagation()}
|
|
@@ -5422,7 +5422,7 @@ const xl = be({
|
|
|
5422
5422
|
<div class="inner-container" style=${oe({ height: `${ke}px` })} ${ne(n)}>
|
|
5423
5423
|
${$e.map(({ index: C, value: I, start: ye }) => {
|
|
5424
5424
|
const Ee = a.useObjBinding ? I && L && I[Z] === L[Z] : I[Z] === L;
|
|
5425
|
-
return
|
|
5425
|
+
return c`<div
|
|
5426
5426
|
data-index=${C}
|
|
5427
5427
|
role="option"
|
|
5428
5428
|
aria-selected=${Ee ? "true" : "false"}
|
|
@@ -5440,9 +5440,9 @@ const xl = be({
|
|
|
5440
5440
|
item: I,
|
|
5441
5441
|
index: C,
|
|
5442
5442
|
highlightText: te(z(I))
|
|
5443
|
-
}) :
|
|
5443
|
+
}) : c`<div class="highlight-container" title=${z(I)}>
|
|
5444
5444
|
${te(z(I)).map(
|
|
5445
|
-
(xe) =>
|
|
5445
|
+
(xe) => c`<span class=${A({ highlight: xe.highlight })}>${xe.part}</span>`
|
|
5446
5446
|
)}
|
|
5447
5447
|
</div>`}
|
|
5448
5448
|
${Ee ? Wt("12", "var(--moz-color-accent)", !1, "icon-check") : b}
|
|
@@ -5450,7 +5450,7 @@ const xl = be({
|
|
|
5450
5450
|
})}
|
|
5451
5451
|
</div>
|
|
5452
5452
|
|
|
5453
|
-
${!ae || ae.length <= 0 ?
|
|
5453
|
+
${!ae || ae.length <= 0 ? c`<div class="list-box-item loading not-hover">
|
|
5454
5454
|
${e.slots.has("empty") ? e.slot("empty") : a.emptyText ?? e.locale.Select.emptyText}
|
|
5455
5455
|
</div>` : b}
|
|
5456
5456
|
</div>
|
|
@@ -5498,7 +5498,7 @@ function Zt(e, t = 12) {
|
|
|
5498
5498
|
}
|
|
5499
5499
|
function Pl(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5500
5500
|
const l = Zt(e, 14);
|
|
5501
|
-
return
|
|
5501
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5502
5502
|
<path
|
|
5503
5503
|
fill-rule="evenodd"
|
|
5504
5504
|
clip-rule="evenodd"
|
|
@@ -5509,7 +5509,7 @@ function Pl(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
|
5509
5509
|
}
|
|
5510
5510
|
function Ll(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5511
5511
|
const l = Zt(e, 14);
|
|
5512
|
-
return
|
|
5512
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5513
5513
|
<path
|
|
5514
5514
|
fill-rule="evenodd"
|
|
5515
5515
|
clip-rule="evenodd"
|
|
@@ -5520,12 +5520,12 @@ function Ll(e = "14", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
|
5520
5520
|
}
|
|
5521
5521
|
function Tl(e = "12", t = "var(--moz-color-text-subtle)", o = !1) {
|
|
5522
5522
|
const l = Zt(e), n = o ? "var(--moz-color-text-muted)" : t;
|
|
5523
|
-
return l.width <= 13 ?
|
|
5523
|
+
return l.width <= 13 ? c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 12 12" fill="none">
|
|
5524
5524
|
<path
|
|
5525
5525
|
d="M10.293 11.375L7.71099 8.79103C6.76581 9.4655 5.60162 9.76002 4.44941 9.61616C3.29719 9.4723 2.24116 8.90058 1.49082 8.01442C0.740489 7.12825 0.350682 5.99242 0.398745 4.83225C0.446808 3.67209 0.929227 2.57239 1.75029 1.75133C2.57135 0.930264 3.67106 0.447845 4.83122 0.399783C5.99138 0.35172 7.12722 0.741526 8.01338 1.49186C8.89954 2.2422 9.47126 3.29823 9.61512 4.45044C9.75898 5.60265 9.46446 6.76684 8.78999 7.71203L11.373 10.294C11.5163 10.4374 11.5969 10.6318 11.5969 10.8345C11.5969 11.0373 11.5163 11.2317 11.373 11.375C11.2296 11.5184 11.0352 11.5989 10.8325 11.5989C10.6298 11.5989 10.4363 11.5184 10.293 11.375ZM1.92899 5.02703C1.92899 5.64015 2.1108 6.2395 2.45144 6.7493C2.79207 7.25909 3.27622 7.65642 3.84267 7.89106C4.40912 8.12569 5.03243 8.18708 5.63377 8.06746C6.23511 7.94785 6.78748 7.6526 7.22102 7.21906C7.65457 6.78552 7.94981 6.23315 8.06943 5.63181C8.18904 5.03047 8.12765 4.40716 7.89302 3.84071C7.65839 3.27426 7.26105 2.79011 6.75126 2.44947C6.24147 2.10884 5.64211 1.92703 5.02899 1.92703C4.20682 1.92703 3.41832 2.25364 2.83696 2.835C2.2556 3.41636 1.92899 4.20486 1.92899 5.02703Z"
|
|
5526
5526
|
fill=${n}
|
|
5527
5527
|
></path>
|
|
5528
|
-
</svg>` :
|
|
5528
|
+
</svg>` : c`<svg xmlns="http://www.w3.org/2000/svg" width=${l.width} height=${l.height} viewBox="0 0 14 14" fill="none">
|
|
5529
5529
|
<path
|
|
5530
5530
|
d="M5.84944 0.402344C2.83893 0.402344 0.398438 2.84284 0.398438 5.85334C0.398438 8.86385 2.83893 11.3043 5.84944 11.3043C7.0308 11.3043 8.12438 10.9285 9.01716 10.29L12.0619 13.3347C12.4134 13.6862 12.9832 13.6862 13.3347 13.3347C13.6862 12.9832 13.6862 12.4134 13.3347 12.0619L10.2893 9.01651C10.9259 8.12457 11.3004 7.03269 11.3004 5.85334C11.3004 2.84284 8.85994 0.402344 5.84944 0.402344ZM2.19844 5.85334C2.19844 3.83695 3.83305 2.20234 5.84944 2.20234C7.86583 2.20234 9.50044 3.83695 9.50044 5.85334C9.50044 7.86974 7.86583 9.50434 5.84944 9.50434C3.83305 9.50434 2.19844 7.86974 2.19844 5.85334Z"
|
|
5531
5531
|
fill=${n}
|
|
@@ -5595,7 +5595,7 @@ const Vl = be({
|
|
|
5595
5595
|
setup(e) {
|
|
5596
5596
|
const t = ve(), o = ve(), l = ve(), n = ve(), i = ve();
|
|
5597
5597
|
let h = null;
|
|
5598
|
-
const
|
|
5598
|
+
const d = () => e.props.keyProp || "id", s = () => e.props.disabledProp || "disabled";
|
|
5599
5599
|
let m = e.props.modelValue ?? null;
|
|
5600
5600
|
const r = () => {
|
|
5601
5601
|
const g = e.controlled("modelValue") ? e.props.modelValue : m;
|
|
@@ -5633,7 +5633,7 @@ const Vl = be({
|
|
|
5633
5633
|
h = g ?? null, g && (W._willUpdate(), e.requestUpdate());
|
|
5634
5634
|
}, re = (g) => typeof e.props.displayProp == "function" ? e.props.displayProp(g) : typeof g == "object" ? g[e.props.displayProp] ?? "" : g, ee = () => {
|
|
5635
5635
|
const g = /* @__PURE__ */ new Map();
|
|
5636
|
-
return (e.props.itemsSource ?? []).forEach((O) => g.set(O[
|
|
5636
|
+
return (e.props.itemsSource ?? []).forEach((O) => g.set(O[d()], O)), g;
|
|
5637
5637
|
}, K = () => {
|
|
5638
5638
|
if (e.props.filterMode === "remote" || !$) return e.props.itemsSource ?? [];
|
|
5639
5639
|
const g = $.toLowerCase();
|
|
@@ -5642,12 +5642,12 @@ const Vl = be({
|
|
|
5642
5642
|
if (!$) return [{ part: g, highlight: !1 }];
|
|
5643
5643
|
const O = Ml($), R = new RegExp(`(${O})`, "gi");
|
|
5644
5644
|
return g.split(R).map((J) => ({ part: J, highlight: $.toLowerCase() === J.toLowerCase() }));
|
|
5645
|
-
}, G = (g) => new Set(r()).has(g[
|
|
5645
|
+
}, G = (g) => new Set(r()).has(g[d()]), se = (g) => q.some((O) => it(O.item, g)), ie = () => {
|
|
5646
5646
|
const g = r(), O = K();
|
|
5647
5647
|
if (g.length < O.length || g.length === 0 || O.length === 0) return !1;
|
|
5648
5648
|
const R = new Set(g);
|
|
5649
|
-
return O.every((J) => R.has(J[
|
|
5650
|
-
}, Q = () => new Set(K().map((g) => g[
|
|
5649
|
+
return O.every((J) => R.has(J[d()]));
|
|
5650
|
+
}, Q = () => new Set(K().map((g) => g[d()])), U = () => new Set(r()), x = () => {
|
|
5651
5651
|
const g = Q(), O = U();
|
|
5652
5652
|
return !g.size || !O.size || O.size < g.size ? !1 : Array.from(g).every((R) => O.has(R));
|
|
5653
5653
|
}, M = () => E.save || E.blur || E.change, _ = () => {
|
|
@@ -5693,7 +5693,7 @@ const Vl = be({
|
|
|
5693
5693
|
J,
|
|
5694
5694
|
J.map((le) => O.get(le)).filter(Boolean)
|
|
5695
5695
|
), k(J, "change"));
|
|
5696
|
-
}, f = (g, O) => g.filter((R) => G(R) !== O).map((R) => R[
|
|
5696
|
+
}, f = (g, O) => g.filter((R) => G(R) !== O).map((R) => R[d()]), H = (g, O, R) => {
|
|
5697
5697
|
if (R.shiftKey && q.length > 0) {
|
|
5698
5698
|
const J = q[0], le = Math.min(J.index, O), me = Math.max(J.index, O);
|
|
5699
5699
|
q = K().slice(le, me + 1).map((ge, Se) => ({ item: ge, index: le + Se }));
|
|
@@ -5705,27 +5705,27 @@ const Vl = be({
|
|
|
5705
5705
|
g ? J = [...J, ...R] : J = J.filter((le) => !R.some((me) => le === me)), B(J);
|
|
5706
5706
|
}, j = (g, O, R) => {
|
|
5707
5707
|
if (g[s()] === !0) return;
|
|
5708
|
-
const J = q.some((me) => me.item[
|
|
5708
|
+
const J = q.some((me) => me.item[d()] === g[d()]);
|
|
5709
5709
|
(q.length <= 1 || !J) && H(g, O, { shiftKey: !1, ctrlKey: !1 });
|
|
5710
|
-
const le = r().some((me) => me === g[
|
|
5710
|
+
const le = r().some((me) => me === g[d()]);
|
|
5711
5711
|
Y(!le), R.stopPropagation();
|
|
5712
5712
|
}, Ce = (g, O, R) => {
|
|
5713
5713
|
g[s()] !== !0 && (!R.ctrlKey && !R.shiftKey && q.length <= 1 && j(g, O, R), H(g, O, R), e.requestUpdate());
|
|
5714
5714
|
}, qe = (g, O, R) => {
|
|
5715
5715
|
if (g[s()] === !0) return;
|
|
5716
|
-
const J = r(), le = U().size !== 0 && J.every((me) => me === g[
|
|
5717
|
-
B(le ? [] : [g[
|
|
5716
|
+
const J = r(), le = U().size !== 0 && J.every((me) => me === g[d()]);
|
|
5717
|
+
B(le ? [] : [g[d()]]), H(g, O, R), R.stopPropagation();
|
|
5718
5718
|
}, _e = (g) => {
|
|
5719
5719
|
g.stopPropagation();
|
|
5720
5720
|
const O = Q().size === U().size && [...Q()].every((R) => U().has(R));
|
|
5721
5721
|
if (ie() && O) {
|
|
5722
5722
|
const R = new Set(
|
|
5723
|
-
(e.props.itemsSource ?? []).filter((J) => J[s()] === !0).map((J) => J[
|
|
5723
|
+
(e.props.itemsSource ?? []).filter((J) => J[s()] === !0).map((J) => J[d()])
|
|
5724
5724
|
);
|
|
5725
5725
|
B(Array.from(R));
|
|
5726
5726
|
} else {
|
|
5727
5727
|
const R = new Set(
|
|
5728
|
-
K().filter((J) => J[s()] !== !0).map((J) => J[
|
|
5728
|
+
K().filter((J) => J[s()] !== !0).map((J) => J[d()])
|
|
5729
5729
|
);
|
|
5730
5730
|
B(Array.from(R));
|
|
5731
5731
|
}
|
|
@@ -5789,11 +5789,11 @@ const Vl = be({
|
|
|
5789
5789
|
else if (C == null || C.release(), C = null, $ = "", i.value && (i.value.value = ""), document.body.removeEventListener("scroll", ue, { capture: !0 }), document.removeEventListener("click", ke, { capture: !0 }), k(r(), "blur"), window.removeEventListener("keydown", $e), O && !g) {
|
|
5790
5790
|
const R = r();
|
|
5791
5791
|
if (e.props.selectAllWhenEmpty && (!R || R.length === 0)) {
|
|
5792
|
-
const J = (e.props.itemsSource ?? []).filter((le) => le[s()] !== !0).map((le) => le[
|
|
5792
|
+
const J = (e.props.itemsSource ?? []).filter((le) => le[s()] !== !0).map((le) => le[d()]);
|
|
5793
5793
|
J.length > 0 && (p(J), e.emit(
|
|
5794
5794
|
"change",
|
|
5795
5795
|
J,
|
|
5796
|
-
(e.props.itemsSource ?? []).filter((le) => J.includes(le[
|
|
5796
|
+
(e.props.itemsSource ?? []).filter((le) => J.includes(le[d()]))
|
|
5797
5797
|
));
|
|
5798
5798
|
}
|
|
5799
5799
|
e.emit("close");
|
|
@@ -5838,9 +5838,9 @@ const Vl = be({
|
|
|
5838
5838
|
} });
|
|
5839
5839
|
}, Qe = (g, O) => {
|
|
5840
5840
|
if (q = [], e.props.preserveMissingValues || JSON.stringify(g) === JSON.stringify(O)) return;
|
|
5841
|
-
const R = new Set(g.map((le) => le[
|
|
5841
|
+
const R = new Set(g.map((le) => le[d()])), J = r();
|
|
5842
5842
|
if (e.props.autoSelectNewItems && O) {
|
|
5843
|
-
const le = new Set(O.map((ge) => ge[
|
|
5843
|
+
const le = new Set(O.map((ge) => ge[d()])), me = g.filter((ge) => !le.has(ge[d()])).map((ge) => ge[d()]);
|
|
5844
5844
|
if (me.length > 0) {
|
|
5845
5845
|
const ge = J.filter((Se) => R.has(Se));
|
|
5846
5846
|
p([.../* @__PURE__ */ new Set([...ge, ...me])]);
|
|
@@ -5852,7 +5852,7 @@ const Vl = be({
|
|
|
5852
5852
|
p(le);
|
|
5853
5853
|
}
|
|
5854
5854
|
}, Ze = () => {
|
|
5855
|
-
const g = e.props, O =
|
|
5855
|
+
const g = e.props, O = d(), R = g.loading ? [] : K();
|
|
5856
5856
|
W.options.count !== R.length && W.setOptions({ ...W.options, count: R.length }), W._willUpdate();
|
|
5857
5857
|
const J = new Set(r()), le = Tt(
|
|
5858
5858
|
W.getVirtualItems(),
|
|
@@ -5872,13 +5872,13 @@ const Vl = be({
|
|
|
5872
5872
|
isFocused: se(Ve)
|
|
5873
5873
|
} : null;
|
|
5874
5874
|
}).filter((Se) => Se !== null), me = W.getTotalSize(), ge = $ ? e.locale.MultiSelect.selectFiltered : e.locale.MultiSelect.selectAll;
|
|
5875
|
-
return
|
|
5875
|
+
return c`<div
|
|
5876
5876
|
class=${A("list-box", { "no-label": !g.label, "show-top": S, "moz-multiselect-inline-list": !!g.inline }, g.class)}
|
|
5877
5877
|
style=${oe(g.inline ? { "--moz-multiselect-list-height": `${g.listBoxHeight ?? 224}px` } : y)}
|
|
5878
5878
|
@keydown=${Me}
|
|
5879
5879
|
${ne(l)}
|
|
5880
5880
|
>
|
|
5881
|
-
${g.useFilter ?
|
|
5881
|
+
${g.useFilter ? c`<div class="filter-input">
|
|
5882
5882
|
<input
|
|
5883
5883
|
placeholder=${g.searchPlaceholder ?? e.locale.MultiSelect.search}
|
|
5884
5884
|
aria-label=${g.searchPlaceholder ?? e.locale.MultiSelect.search}
|
|
@@ -5889,7 +5889,7 @@ const Vl = be({
|
|
|
5889
5889
|
/>
|
|
5890
5890
|
<div class="search-icon">${Tl("12", "var(--moz-color-text-subtle)")}</div>
|
|
5891
5891
|
</div>` : b}
|
|
5892
|
-
${g.useSelectAll && (g.itemsSource ?? []).length > 0 && R.length > 0 ?
|
|
5892
|
+
${g.useSelectAll && (g.itemsSource ?? []).length > 0 && R.length > 0 ? c`<div
|
|
5893
5893
|
class=${A("list-box-item multi-select-item multi-select-all", { "is-scrolled": F })}
|
|
5894
5894
|
role="button"
|
|
5895
5895
|
tabindex=${g.disabled || g.readonly || g.loading ? "-1" : "0"}
|
|
@@ -5910,7 +5910,7 @@ const Vl = be({
|
|
|
5910
5910
|
<div class="highlight-container">
|
|
5911
5911
|
<span title=${ge}>${ge}</span>
|
|
5912
5912
|
</div>
|
|
5913
|
-
${g.useSpecificSelect && $ && R.length > 0 ?
|
|
5913
|
+
${g.useSpecificSelect && $ && R.length > 0 ? c`<button type="button" class="item-only" @click=${_e}>
|
|
5914
5914
|
${e.locale.MultiSelect.specificResults}
|
|
5915
5915
|
</button>` : b}
|
|
5916
5916
|
</div>` : b}
|
|
@@ -5926,7 +5926,7 @@ const Vl = be({
|
|
|
5926
5926
|
${ne(te)}
|
|
5927
5927
|
>
|
|
5928
5928
|
<div class="inner-container" style=${oe({ height: `${me}px` })}>
|
|
5929
|
-
${le.map(({ index: Se, value: Ve, start: Ke, size: Je, isSelected: rt, isDisabled: st, isFocused: At }) =>
|
|
5929
|
+
${le.map(({ index: Se, value: Ve, start: Ke, size: Je, isSelected: rt, isDisabled: st, isFocused: At }) => c`<div
|
|
5930
5930
|
class=${A("list-box-item multi-select-item virtual-row", {
|
|
5931
5931
|
"list-selected": rt,
|
|
5932
5932
|
"moz-multi-focus": At
|
|
@@ -5948,17 +5948,17 @@ const Vl = be({
|
|
|
5948
5948
|
?disabled=${st}
|
|
5949
5949
|
@click=${(Ye) => j(Ve, Se, Ye)}
|
|
5950
5950
|
/>
|
|
5951
|
-
${e.slots.has("list-item") ? e.slot("list-item", { text: re(Ve), item: Ve }) :
|
|
5951
|
+
${e.slots.has("list-item") ? e.slot("list-item", { text: re(Ve), item: Ve }) : c`<div class="highlight-container" title=${re(Ve)}>
|
|
5952
5952
|
${D(re(Ve)).map(
|
|
5953
|
-
(Ye) =>
|
|
5953
|
+
(Ye) => c`<span class=${A("text-part", { highlight: Ye.highlight })}>${Ye.part}</span>`
|
|
5954
5954
|
)}
|
|
5955
5955
|
</div>`}
|
|
5956
|
-
${g.useSpecificSelect && !st ?
|
|
5956
|
+
${g.useSpecificSelect && !st ? c`<button type="button" class="item-only" @click=${(Ye) => qe(Ve, Se, Ye)}>
|
|
5957
5957
|
${e.locale.MultiSelect.specificSelect}
|
|
5958
5958
|
</button>` : b}
|
|
5959
5959
|
</div>`)}
|
|
5960
5960
|
</div>
|
|
5961
|
-
${R.length <= 0 ?
|
|
5961
|
+
${R.length <= 0 ? c`<div class="list-box-item loading not-hover">
|
|
5962
5962
|
${g.loading ? g.loadingText ?? "Loading…" : e.slots.has("empty") ? e.slot("empty") : e.locale.MultiSelect.noData}
|
|
5963
5963
|
</div>` : b}
|
|
5964
5964
|
</div>
|
|
@@ -5974,11 +5974,11 @@ const Vl = be({
|
|
|
5974
5974
|
}
|
|
5975
5975
|
const O = typeof g.width == "number" ? `${ze(g.width)}rem` : g.width, R = we(g, zl), { aria: J, dom: le } = dt(R);
|
|
5976
5976
|
if (g.inline)
|
|
5977
|
-
return
|
|
5977
|
+
return c`<div class="moz-multi-select moz-multi-select-inline"
|
|
5978
5978
|
style=${oe({ width: O, ...Pe(g.style) })}
|
|
5979
5979
|
${ne(t)}>${Ze()}</div>`;
|
|
5980
5980
|
const me = e.slots.has("icon") ? e.slot("icon", { isOpen: u }) : u ? Ll("14", "var(--moz-color-accent)") : Pl("14", g.disabled ? "var(--moz-color-text-muted)" : "var(--moz-color-text-subtle)");
|
|
5981
|
-
return
|
|
5981
|
+
return c`
|
|
5982
5982
|
<div
|
|
5983
5983
|
class=${A("moz-multi-select", {
|
|
5984
5984
|
"is-invalid": M() !== "",
|
|
@@ -5991,7 +5991,7 @@ const Vl = be({
|
|
|
5991
5991
|
<div class="input-wrapper">
|
|
5992
5992
|
${g.label ? Oe(
|
|
5993
5993
|
{},
|
|
5994
|
-
|
|
5994
|
+
c`${g.label}${g.required ? c`<span class="require-mark">*</span>` : b}`
|
|
5995
5995
|
) : b}
|
|
5996
5996
|
<div class="moz-input-container" @click=${We} ${ne(o)}>
|
|
5997
5997
|
<input
|
|
@@ -6019,7 +6019,7 @@ const Vl = be({
|
|
|
6019
6019
|
</div>
|
|
6020
6020
|
</div>
|
|
6021
6021
|
|
|
6022
|
-
${M() !== "" ?
|
|
6022
|
+
${M() !== "" ? c`<span class="moz-input-invalid-message">${M()}</span>` : b}
|
|
6023
6023
|
</div>
|
|
6024
6024
|
`;
|
|
6025
6025
|
},
|
|
@@ -6077,7 +6077,7 @@ function qo(e, t = 14) {
|
|
|
6077
6077
|
}
|
|
6078
6078
|
function Al(e = "14", t = "var(--moz-color-text-subtle)") {
|
|
6079
6079
|
const o = qo(e, 14);
|
|
6080
|
-
return
|
|
6080
|
+
return c`<svg width=${o.width} height=${o.height} viewBox="0 0 14 15" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
6081
6081
|
<g clip-path="url(#clip0_4513_575)">
|
|
6082
6082
|
<path
|
|
6083
6083
|
fill-rule="evenodd"
|
|
@@ -6095,7 +6095,7 @@ function Al(e = "14", t = "var(--moz-color-text-subtle)") {
|
|
|
6095
6095
|
}
|
|
6096
6096
|
function oo(e = "12", t = "var(--moz-color-text-subtle)", o = !1, l = "") {
|
|
6097
6097
|
const n = qo(e, 12), i = o ? "var(--moz-color-text-muted)" : t;
|
|
6098
|
-
return
|
|
6098
|
+
return c`<svg class=${l || b} xmlns="http://www.w3.org/2000/svg" width=${n.width} height=${n.height} viewBox="0 0 16 16">
|
|
6099
6099
|
<g style=${`fill: ${i}`}>
|
|
6100
6100
|
<path
|
|
6101
6101
|
d="M836.533 699.734h-.022a.928.928 0 0 1-.716-.336l-3.779-4.535a.926.926 0 0 1-.212-.68.93.93 0 0 1 1.643-.512l3.026 3.63 6.096-8.128a.922.922 0 0 1 .745-.373c.202 0 .396.064.559.186.199.15.328.367.363.614a.925.925 0 0 1-.177.69l-6.803 9.071a.928.928 0 0 1-.721.373h-.002z"
|
|
@@ -6126,7 +6126,7 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6126
6126
|
defaults: { width: "160px", modelValue: "09:00", label: "", disabled: !1, required: !1 },
|
|
6127
6127
|
setup(e) {
|
|
6128
6128
|
const t = ve(), o = ve(), l = ve(), n = ve(), i = ve(), h = ve();
|
|
6129
|
-
let
|
|
6129
|
+
let d = !1, s = 9, m = 0, r = "", p = "";
|
|
6130
6130
|
const u = (D) => {
|
|
6131
6131
|
if (D && D.includes(":")) {
|
|
6132
6132
|
const [G, se] = D.split(":").map(Number);
|
|
@@ -6142,14 +6142,14 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6142
6142
|
container: () => t.value ?? null,
|
|
6143
6143
|
listWidth: () => "160px",
|
|
6144
6144
|
requestClose: () => {
|
|
6145
|
-
|
|
6145
|
+
d && y(!1);
|
|
6146
6146
|
}
|
|
6147
6147
|
});
|
|
6148
6148
|
e.onCleanup(() => F.destroy());
|
|
6149
6149
|
const S = () => {
|
|
6150
6150
|
i.value && (i.value.scrollTop = s * 24 - 72), h.value && (h.value.scrollTop = m * 24 - 72);
|
|
6151
6151
|
}, y = (D) => {
|
|
6152
|
-
|
|
6152
|
+
d !== D && (d = D, e.requestUpdate(), D ? (F.open(), queueMicrotask(S)) : F.close());
|
|
6153
6153
|
}, q = () => {
|
|
6154
6154
|
const D = `${s.toString().padStart(2, "0")}:${m.toString().padStart(2, "0")}`;
|
|
6155
6155
|
r = D, p = D, e.emit("update:modelValue", D), e.requestUpdate();
|
|
@@ -6222,10 +6222,10 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6222
6222
|
!isNaN(x) && !isNaN(M) && x >= 0 && x <= 23 && M >= 0 && M <= 59 && U !== D.modelValue && (s = x, m = M, queueMicrotask(() => e.emit("update:modelValue", U)));
|
|
6223
6223
|
}
|
|
6224
6224
|
}
|
|
6225
|
-
const G = D.disabled ? "var(--moz-color-text-muted)" :
|
|
6225
|
+
const G = D.disabled ? "var(--moz-color-text-muted)" : d ? "var(--moz-color-accent)" : "var(--moz-color-text-subtle)", se = we(D, Dl), ie = "__:__", Q = [];
|
|
6226
6226
|
for (let U = 0; U < ie.length; U++)
|
|
6227
6227
|
U < r.length ? Q.push({ char: r[U], isInput: !0 }) : Q.push({ char: ie[U], isInput: !1 });
|
|
6228
|
-
return
|
|
6228
|
+
return c`
|
|
6229
6229
|
<div
|
|
6230
6230
|
class=${A("custom-time-picker", D.class, { "custom-time-picker--has-class": !!D.class })}
|
|
6231
6231
|
style=${oe({ width: D.width, ...Pe(D.style) })}
|
|
@@ -6236,7 +6236,7 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6236
6236
|
<div
|
|
6237
6237
|
class=${A("time-input-wrapper", {
|
|
6238
6238
|
"time-input-wrapper--disabled": D.disabled,
|
|
6239
|
-
"time-input-wrapper--open":
|
|
6239
|
+
"time-input-wrapper--open": d && !D.disabled
|
|
6240
6240
|
})}
|
|
6241
6241
|
${ne(o)}
|
|
6242
6242
|
>
|
|
@@ -6251,7 +6251,7 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6251
6251
|
@click=${() => y(!0)}
|
|
6252
6252
|
class=${A("time-input", {
|
|
6253
6253
|
"time-input--disabled": D.disabled,
|
|
6254
|
-
"time-input--open":
|
|
6254
|
+
"time-input--open": d
|
|
6255
6255
|
})}
|
|
6256
6256
|
?disabled=${!!D.disabled}
|
|
6257
6257
|
maxlength="5"
|
|
@@ -6259,7 +6259,7 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6259
6259
|
/>
|
|
6260
6260
|
<div class="time-mask">
|
|
6261
6261
|
${Q.map(
|
|
6262
|
-
(U) =>
|
|
6262
|
+
(U) => c`<span
|
|
6263
6263
|
class=${A({
|
|
6264
6264
|
"mask-input": U.isInput && !D.disabled,
|
|
6265
6265
|
"mask-placeholder": !U.isInput,
|
|
@@ -6278,16 +6278,16 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6278
6278
|
`;
|
|
6279
6279
|
},
|
|
6280
6280
|
renderPortal() {
|
|
6281
|
-
if (!
|
|
6281
|
+
if (!d) return b;
|
|
6282
6282
|
const D = e.props;
|
|
6283
|
-
return
|
|
6283
|
+
return c`<div class="time-picker-dropdown" ${ne(n)}>
|
|
6284
6284
|
<div class="time-picker-content">
|
|
6285
6285
|
<div class="time-column">
|
|
6286
6286
|
<div class="time-label">${D.hourLabel ?? e.locale.TimePicker.hour}</div>
|
|
6287
6287
|
<div class="time-list">
|
|
6288
6288
|
<div class="time-option-wrapper" ${ne(i)}>
|
|
6289
6289
|
${ql.map(
|
|
6290
|
-
(G) =>
|
|
6290
|
+
(G) => c`<div @click=${() => E(G)} class="time-option">
|
|
6291
6291
|
<div class="time-option-text">${G.toString().padStart(2, "0")}</div>
|
|
6292
6292
|
${s === G ? oo("12", "var(--moz-color-accent)", !1, "check-icon") : b}
|
|
6293
6293
|
</div>`
|
|
@@ -6300,7 +6300,7 @@ const Dl = /* @__PURE__ */ new Set([
|
|
|
6300
6300
|
<div class="time-list">
|
|
6301
6301
|
<div class="time-option-wrapper" ${ne(h)}>
|
|
6302
6302
|
${Fl.map(
|
|
6303
|
-
(G) =>
|
|
6303
|
+
(G) => c`<div @click=${() => z(G)} class="time-option">
|
|
6304
6304
|
<div class="time-option-text">${G.toString().padStart(2, "0")}</div>
|
|
6305
6305
|
${m === G ? oo("12", "var(--moz-color-accent)", !1, "check-icon") : b}
|
|
6306
6306
|
</div>`
|
|
@@ -6337,13 +6337,13 @@ function Rl(e, t = 12) {
|
|
|
6337
6337
|
}[e] ?? { width: t, height: t };
|
|
6338
6338
|
}
|
|
6339
6339
|
function Ut(e = "var(--moz-color-text-subtle)", t = "") {
|
|
6340
|
-
return
|
|
6340
|
+
return c`<svg class=${t} width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
6341
6341
|
<path d="M9 3L3 9M3 3L9 9" stroke=${e} stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
6342
6342
|
</svg>`;
|
|
6343
6343
|
}
|
|
6344
6344
|
function so(e = "12", t = "var(--moz-color-text-subtle)", o = !1, l = "") {
|
|
6345
6345
|
const n = Rl(e, 12), i = o ? "var(--moz-color-text-muted)" : t;
|
|
6346
|
-
return
|
|
6346
|
+
return c`<svg class=${l} xmlns="http://www.w3.org/2000/svg" width=${n.width} height=${n.height} viewBox="0 0 12 12">
|
|
6347
6347
|
<g transform="translate(-0.005)">
|
|
6348
6348
|
<path
|
|
6349
6349
|
d="M2.311,12.843a1.028,1.028,0,0,1-.291-.933L2.53,9.262a1.029,1.029,0,0,1,.279-.528L9.241,2.186a1.036,1.036,0,0,1,1.45-.021l2.151,2.071A1.03,1.03,0,0,1,12.861,5.7L6.432,12.246a1.024,1.024,0,0,1-.518.283l-2.665.58a.957.957,0,0,1-.22.024,1.027,1.027,0,0,1-.718-.291M3.652,9.515,3.183,11.95l2.456-.535L10.132,6.84,8.147,4.934Zm7.285-3.494,1.021-1.036L9.979,3.079,8.957,4.114Z"
|
|
@@ -6397,7 +6397,7 @@ const Ol = be({
|
|
|
6397
6397
|
},
|
|
6398
6398
|
setup(e) {
|
|
6399
6399
|
const t = ve(), o = ve();
|
|
6400
|
-
let l = null, n = [], i = !1, h = !1,
|
|
6400
|
+
let l = null, n = [], i = !1, h = !1, d = "", s = !1, m = {};
|
|
6401
6401
|
const r = () => e.props, p = (f) => r().pattern ? new RegExp(`${r().pattern}`).test(f) : !0, u = () => n.map((f, H) => ({ ...f, idx: H })).filter((f) => f.isSelected !== -1).sort((f, H) => f.isSelected - H.isSelected), v = () => u().map((f) => f.value), $ = () => !u().some((f) => !f.isValid), F = (f, H) => {
|
|
6402
6402
|
const Y = r().limitItemLength;
|
|
6403
6403
|
(!H || H && Y && u().length < Y || H && !Y) && (H && n[f].isSelected === -1 || !H) && (n[f].isSelected = H ? Date.now() : -1);
|
|
@@ -6450,7 +6450,7 @@ const Ol = be({
|
|
|
6450
6450
|
}, e.requestUpdate();
|
|
6451
6451
|
}, ee = (f) => {
|
|
6452
6452
|
const H = f.target, Y = () => {
|
|
6453
|
-
|
|
6453
|
+
d && r().pushOnBlur && S(d, !0) && e.emit("modelChange", v()), d = "", h = !1, i = !1;
|
|
6454
6454
|
};
|
|
6455
6455
|
H.className && Array.from(String(H.className).split(" ")).includes("tag-input-not-close") || Y(), U(""), window.removeEventListener("mousedown", ee), e.requestUpdate();
|
|
6456
6456
|
}, K = () => {
|
|
@@ -6467,7 +6467,7 @@ const Ol = be({
|
|
|
6467
6467
|
}, se = () => {
|
|
6468
6468
|
h = !0, K(), setTimeout(() => l == null ? void 0 : l.focus(), 0);
|
|
6469
6469
|
}, ie = (f) => {
|
|
6470
|
-
if (f.key === "Enter" &&
|
|
6470
|
+
if (f.key === "Enter" && d === "" && e.emit("onEnterEmpty", v()), (f.key === "Enter" || f.key === "Tab" && r().pushOnBlur) && d !== "" && (S(d, !0) && (e.emit("modelChange", v()), d = ""), e.requestUpdate()), f.key === "Tab" && (i = !1, h = !1, e.requestUpdate()), f.key === "Backspace") {
|
|
6471
6471
|
const H = f.target, Y = u();
|
|
6472
6472
|
H.selectionStart === 0 && Y.length > 0 && (F(Y[Y.length - 1].idx, !1), e.requestUpdate());
|
|
6473
6473
|
}
|
|
@@ -6489,7 +6489,7 @@ const Ol = be({
|
|
|
6489
6489
|
f.style.width = "1px", f.style.width = `${f.scrollWidth}px`;
|
|
6490
6490
|
}, V = (f) => {
|
|
6491
6491
|
const H = r().limitTextLength;
|
|
6492
|
-
return
|
|
6492
|
+
return c`<input
|
|
6493
6493
|
class="moz-auto-input tag-input-common tag-input-add"
|
|
6494
6494
|
.value=${f.value}
|
|
6495
6495
|
style="width:1px"
|
|
@@ -6516,7 +6516,7 @@ const Ol = be({
|
|
|
6516
6516
|
return (Y = f.onBlur) == null ? void 0 : Y.call(f);
|
|
6517
6517
|
}}
|
|
6518
6518
|
/>`;
|
|
6519
|
-
}, B = (f, H, Y) =>
|
|
6519
|
+
}, B = (f, H, Y) => c`<div class="tag-input-controller" style=${oe({ display: f.isSelected !== -1 ? "" : "none" })}>
|
|
6520
6520
|
<div
|
|
6521
6521
|
class=${A("tag-input-item", { invalid: !f.isValid })}
|
|
6522
6522
|
data-isValid=${String(f.isValid)}
|
|
@@ -6531,9 +6531,9 @@ const Ol = be({
|
|
|
6531
6531
|
onKeydown: (j) => x(j, f.idx),
|
|
6532
6532
|
onKeyup: (j) => M(j),
|
|
6533
6533
|
onBlur: () => _(f.idx)
|
|
6534
|
-
}) :
|
|
6534
|
+
}) : c`<span class="tag-input-preview tag-input-common">${f.value}</span>`}
|
|
6535
6535
|
<div class="tag-input-btn-wrapper">
|
|
6536
|
-
${r().simplify && !f.isEditing && !r().disableUpdate ?
|
|
6536
|
+
${r().simplify && !f.isEditing && !r().disableUpdate ? c`<span
|
|
6537
6537
|
class="tag-input-button cursor-pointer"
|
|
6538
6538
|
role="button"
|
|
6539
6539
|
tabindex="0"
|
|
@@ -6572,9 +6572,9 @@ const Ol = be({
|
|
|
6572
6572
|
queueMicrotask(() => e.emit("update:modelValue", j));
|
|
6573
6573
|
}
|
|
6574
6574
|
const Y = we(f, Bl);
|
|
6575
|
-
return
|
|
6575
|
+
return c`
|
|
6576
6576
|
<div class=${A("moz-tag-input-wrapper", f.class)} ${pe(Y)}>
|
|
6577
|
-
${f.label ?
|
|
6577
|
+
${f.label ? c`<label class=${A("tag-input-label", { required: f.required })}>${f.label}</label>` : b}
|
|
6578
6578
|
<div class="tag-input-grid">
|
|
6579
6579
|
<div
|
|
6580
6580
|
class="tag-input-not-close tag-input-row scrollbar-none"
|
|
@@ -6586,9 +6586,9 @@ const Ol = be({
|
|
|
6586
6586
|
>
|
|
6587
6587
|
${e.slot("left")}
|
|
6588
6588
|
${u().map((j, Ce) => B(j, Ce, !1))}
|
|
6589
|
-
${h ?
|
|
6590
|
-
${f.limitItemLength && h ?
|
|
6591
|
-
${h ? b :
|
|
6589
|
+
${h ? c`<span class="tag-input-preview tag-input-common" @click=${se}>${d}</span>` : b}
|
|
6590
|
+
${f.limitItemLength && h ? c`<div class="tag-input-counter">${u().length} / ${f.limitItemLength}</div>` : b}
|
|
6591
|
+
${h ? b : c`<span class="tag-input-add-to">${f.addButtonLabel ? f.addButtonLabel : e.locale.TagInput.add} </span>`}
|
|
6592
6592
|
<div class="flex-1"></div>
|
|
6593
6593
|
${e.slot("right")}
|
|
6594
6594
|
</div>
|
|
@@ -6599,7 +6599,7 @@ const Ol = be({
|
|
|
6599
6599
|
renderPortal() {
|
|
6600
6600
|
if (!i) return b;
|
|
6601
6601
|
const f = e.props;
|
|
6602
|
-
return
|
|
6602
|
+
return c`<div class="absolute z-1501" style=${oe(m)}>
|
|
6603
6603
|
<div
|
|
6604
6604
|
class="tag-input-placeholder-float tag-input-not-close scrollbar-none shown"
|
|
6605
6605
|
@mousedown=${(H) => {
|
|
@@ -6609,9 +6609,9 @@ const Ol = be({
|
|
|
6609
6609
|
>
|
|
6610
6610
|
${u().map((H, Y) => B(H, Y, !0))}
|
|
6611
6611
|
${h ? V({
|
|
6612
|
-
value:
|
|
6612
|
+
value: d,
|
|
6613
6613
|
setValue: (H) => {
|
|
6614
|
-
|
|
6614
|
+
d = H, e.requestUpdate();
|
|
6615
6615
|
},
|
|
6616
6616
|
onKeydown: ie,
|
|
6617
6617
|
onKeyup: () => {
|
|
@@ -6623,22 +6623,22 @@ const Ol = be({
|
|
|
6623
6623
|
l = H;
|
|
6624
6624
|
}
|
|
6625
6625
|
}) : b}
|
|
6626
|
-
${s ?
|
|
6626
|
+
${s ? c`<div class="tag-input-loading">
|
|
6627
6627
|
<div class="tag-input-loading-ball-1"></div>
|
|
6628
6628
|
<div class="tag-input-loading-ball-2"></div>
|
|
6629
6629
|
<div class="tag-input-loading-ball-3"></div>
|
|
6630
6630
|
</div>` : b}
|
|
6631
|
-
${f.limitItemLength && h ?
|
|
6631
|
+
${f.limitItemLength && h ? c`<div class="tag-input-counter" @click=${se}>
|
|
6632
6632
|
${u().length} / ${f.limitItemLength}
|
|
6633
6633
|
</div>` : b}
|
|
6634
|
-
${h ? b :
|
|
6634
|
+
${h ? b : c`<span class="tag-input-add-to flex-1">${f.addButtonLabel ? f.addButtonLabel : ""} </span>`}
|
|
6635
6635
|
</div>
|
|
6636
|
-
${f.simplify ? b :
|
|
6636
|
+
${f.simplify ? b : c`<div class="tag-input-dropdown-outer-wrapper" @mousedown=${(H) => H.stopPropagation()}>
|
|
6637
6637
|
<div class=${A("tag-input-dropdown-wrapper", { "expand-top": f.isExpandTop })}>
|
|
6638
6638
|
<div class="tag-input-dropdown-inner-wrapper">
|
|
6639
6639
|
<div class="tag-input-dropdown-title"></div>
|
|
6640
6640
|
${n.map(
|
|
6641
|
-
(H, Y) =>
|
|
6641
|
+
(H, Y) => c`<div class="dropdown-tag-input-item-wrapper tag-input-controller">
|
|
6642
6642
|
<div
|
|
6643
6643
|
class=${A("tag-input-item tag-item-limit-width", { invalid: !H.isValid })}
|
|
6644
6644
|
data-isValid=${String(H.isValid)}
|
|
@@ -6653,17 +6653,17 @@ const Ol = be({
|
|
|
6653
6653
|
onKeydown: (j) => x(j, Y),
|
|
6654
6654
|
onKeyup: (j) => M(j),
|
|
6655
6655
|
onBlur: () => _(Y)
|
|
6656
|
-
}) :
|
|
6656
|
+
}) : c`<span class="tag-input-preview tag-input-common">
|
|
6657
6657
|
<span>${H.value}</span>
|
|
6658
6658
|
<div class="tag-input-btn-wrapper">
|
|
6659
|
-
${!H.isEditing && !f.disableUpdate ?
|
|
6659
|
+
${!H.isEditing && !f.disableUpdate ? c`<span
|
|
6660
6660
|
class="tag-input-button cursor-pointer"
|
|
6661
6661
|
@click=${(j) => {
|
|
6662
6662
|
j.stopPropagation(), G(Y);
|
|
6663
6663
|
}}
|
|
6664
6664
|
>${so("10")}</span
|
|
6665
6665
|
>` : b}
|
|
6666
|
-
${f.disableDelete ? b :
|
|
6666
|
+
${f.disableDelete ? b : c`<span
|
|
6667
6667
|
class="tag-input-button cursor-pointer"
|
|
6668
6668
|
@click=${(j) => {
|
|
6669
6669
|
j.stopPropagation(), y(Y), e.requestUpdate();
|
|
@@ -6728,13 +6728,13 @@ const _l = 500, Wl = be({
|
|
|
6728
6728
|
setup(e) {
|
|
6729
6729
|
let t = null, o = null;
|
|
6730
6730
|
const l = ve();
|
|
6731
|
-
let n = !1, i = !1, h = !1,
|
|
6731
|
+
let n = !1, i = !1, h = !1, d = !1, s = null, m = !1, r = !1, p = !1, u = !1;
|
|
6732
6732
|
const v = /* @__PURE__ */ new Map(), $ = /* @__PURE__ */ new Map(), F = /* @__PURE__ */ new Map(), S = /* @__PURE__ */ new Map(), y = () => {
|
|
6733
6733
|
n && i && (s || e.props.itemSource) && o && !u && (u = !0, e.emit("open", { target: o }));
|
|
6734
6734
|
}, q = (x) => {
|
|
6735
6735
|
const M = h !== x;
|
|
6736
6736
|
h = x, e.requestUpdate(), M && !x && setTimeout(() => {
|
|
6737
|
-
n = !1,
|
|
6737
|
+
n = !1, d = !1, u = !1, e.emit("close", { target: o }), e.requestUpdate();
|
|
6738
6738
|
}, 50);
|
|
6739
6739
|
}, E = (x) => {
|
|
6740
6740
|
const M = n !== x;
|
|
@@ -6765,7 +6765,7 @@ const _l = 500, Wl = be({
|
|
|
6765
6765
|
const _ = M.getBoundingClientRect(), k = l.value.getBoundingClientRect();
|
|
6766
6766
|
m = _.left + M.clientWidth < k.left + o.clientWidth, r = _.left + M.clientWidth < k.left + o.clientWidth * 2, p = _.top + M.clientHeight < k.top + o.clientHeight, x.useTeleport ? (o.style.left = `${k.left}px`, o.style.top = `${k.top}px`) : (o.style.left = `${l.value.offsetLeft}px`, o.style.top = `${l.value.offsetTop}px`), e.requestUpdate();
|
|
6767
6767
|
}, ee = (x) => {
|
|
6768
|
-
|
|
6768
|
+
d || (o && t && (e.props.fixPosition ? re() : (m = t.clientWidth < x.clientX + o.clientWidth, r = t.clientWidth < x.clientX + o.clientWidth * 2, p = t.clientHeight < x.clientY + o.clientHeight, o.style.left = `${x.clientX}px`, o.style.top = `${x.clientY}px`)), t && (t.style.pointerEvents = "none"), window.addEventListener("mousedown", z), window.addEventListener("resize", X), d = !0, e.requestUpdate());
|
|
6769
6769
|
};
|
|
6770
6770
|
e.onCleanup(() => {
|
|
6771
6771
|
window.removeEventListener("mousedown", z), window.removeEventListener("resize", X);
|
|
@@ -6785,7 +6785,7 @@ const _l = 500, Wl = be({
|
|
|
6785
6785
|
x.function ? (x.function(), X()) : x.children && (D(M, x), v.set(M, !0), e.requestUpdate());
|
|
6786
6786
|
}, se = (x) => typeof x.disabled == "function" ? x.disabled() : !!x.disabled, ie = (x, M, _, k) => {
|
|
6787
6787
|
const T = v.get(k) ?? !1, V = $.get(k) ?? !1, B = K(k);
|
|
6788
|
-
return
|
|
6788
|
+
return c`<div
|
|
6789
6789
|
class=${A({
|
|
6790
6790
|
"context-menu-item-enable-hover": !("hover" in x) || x.hover,
|
|
6791
6791
|
"context-menu-item-wrapper": !0,
|
|
@@ -6809,7 +6809,7 @@ const _l = 500, Wl = be({
|
|
|
6809
6809
|
>
|
|
6810
6810
|
${x.children ? U(x.children, M + 1, _, k) : b}
|
|
6811
6811
|
</div>
|
|
6812
|
-
${x.template ?
|
|
6812
|
+
${x.template ? c`<div
|
|
6813
6813
|
class=${`context-menu-item-${x.template}`}
|
|
6814
6814
|
@mouseup=${() => {
|
|
6815
6815
|
var f;
|
|
@@ -6817,7 +6817,7 @@ const _l = 500, Wl = be({
|
|
|
6817
6817
|
}}
|
|
6818
6818
|
>
|
|
6819
6819
|
${Q(x)}
|
|
6820
|
-
</div>` :
|
|
6820
|
+
</div>` : c`<div
|
|
6821
6821
|
class="context-menu-item"
|
|
6822
6822
|
role="menuitem"
|
|
6823
6823
|
tabindex="-1"
|
|
@@ -6826,15 +6826,15 @@ const _l = 500, Wl = be({
|
|
|
6826
6826
|
@click=${() => G(x, k)}
|
|
6827
6827
|
>
|
|
6828
6828
|
<div class="context-menu-item-left">${x.text}</div>
|
|
6829
|
-
${x.children ?
|
|
6829
|
+
${x.children ? c`<div class="context-menu-item-right"></div>` : b}
|
|
6830
6830
|
</div>`}
|
|
6831
6831
|
</div>`;
|
|
6832
6832
|
}, Q = (x) => {
|
|
6833
6833
|
const M = x.template, _ = M.includes("[col-padding]") ? "col-padding" : M.includes("[row-padding]") ? "row-padding" : M.includes("[padding]") ? "padding" : null, k = e.slots.has(M) ? e.slot(M, { props: { ...x } }) : b;
|
|
6834
|
-
return _ ?
|
|
6834
|
+
return _ ? c`<div class="context-menu-item-template" data-layout=${_}>${k}</div>` : c`${k}`;
|
|
6835
6835
|
}, U = (x, M, _, k) => {
|
|
6836
6836
|
const T = M === 0;
|
|
6837
|
-
return
|
|
6837
|
+
return c`<div
|
|
6838
6838
|
role=${T ? "menu" : "group"}
|
|
6839
6839
|
class=${A("context-menu-content-wrapper", T ? e.props.class : void 0)}
|
|
6840
6840
|
data-noPadding=${String(!!e.props.noPadding)}
|
|
@@ -6843,8 +6843,8 @@ const _l = 500, Wl = be({
|
|
|
6843
6843
|
>
|
|
6844
6844
|
${x.map((V, B) => {
|
|
6845
6845
|
const f = `${k}/${M}-${B}`;
|
|
6846
|
-
return
|
|
6847
|
-
${V.separator ?
|
|
6846
|
+
return c`<div class="context-menu-item-outer-wrapper" style=${oe({ display: V != null && V.hidden ? "none" : "" })}>
|
|
6847
|
+
${V.separator ? c`<div class="context-menu-separator"></div>` : ie(V, M, _, f)}
|
|
6848
6848
|
</div>`;
|
|
6849
6849
|
})}
|
|
6850
6850
|
</div>`;
|
|
@@ -6858,7 +6858,7 @@ const _l = 500, Wl = be({
|
|
|
6858
6858
|
},
|
|
6859
6859
|
render() {
|
|
6860
6860
|
const x = e.props;
|
|
6861
|
-
return x.fixPosition ?
|
|
6861
|
+
return x.fixPosition ? c`<div
|
|
6862
6862
|
class="context-menu-fixed-position-space"
|
|
6863
6863
|
style=${oe({
|
|
6864
6864
|
left: typeof x.fixPosition.left == "string" ? x.fixPosition.left : `${x.fixPosition.left}px`,
|
|
@@ -6871,7 +6871,7 @@ const _l = 500, Wl = be({
|
|
|
6871
6871
|
const x = e.props, M = s || x.itemSource;
|
|
6872
6872
|
if (!n || !M) return b;
|
|
6873
6873
|
const _ = x.transition, k = x.direction;
|
|
6874
|
-
return
|
|
6874
|
+
return c`
|
|
6875
6875
|
<div
|
|
6876
6876
|
class="context-menu-wrapper"
|
|
6877
6877
|
@mouseenter=${ee}
|
|
@@ -6974,7 +6974,7 @@ const Jl = be({
|
|
|
6974
6974
|
},
|
|
6975
6975
|
setup(e) {
|
|
6976
6976
|
const t = ve(), o = ve(), l = ve(), n = ve(), i = ve(), h = ve();
|
|
6977
|
-
let
|
|
6977
|
+
let d = null, s = e.props.modelValue ?? null;
|
|
6978
6978
|
const m = () => e.controlled("modelValue") ? e.props.modelValue ?? null : s, r = (a) => {
|
|
6979
6979
|
e.controlled("modelValue") || (s = a), e.emit("update:modelValue", a), e.requestUpdate();
|
|
6980
6980
|
};
|
|
@@ -6983,7 +6983,7 @@ const Jl = be({
|
|
|
6983
6983
|
let F = m();
|
|
6984
6984
|
const S = () => e.props.keyProp || "id", y = () => e.props.displayProps ?? ["text"], q = new Et({
|
|
6985
6985
|
count: 0,
|
|
6986
|
-
getScrollElement: () =>
|
|
6986
|
+
getScrollElement: () => d,
|
|
6987
6987
|
estimateSize: () => ht,
|
|
6988
6988
|
measureElement: (a) => a.getBoundingClientRect().height,
|
|
6989
6989
|
overscan: 5,
|
|
@@ -6996,7 +6996,7 @@ const Jl = be({
|
|
|
6996
6996
|
V == null || V.release(), V = null;
|
|
6997
6997
|
}), e.onCleanup(q._didMount());
|
|
6998
6998
|
const E = (a) => {
|
|
6999
|
-
|
|
6999
|
+
d = a ?? null, a && (q._willUpdate(), e.requestUpdate());
|
|
7000
7000
|
}, z = (a) => {
|
|
7001
7001
|
const L = m();
|
|
7002
7002
|
return L == null ? !1 : e.props.useObjKeyProp ? typeof L != "object" ? !1 : y().every((Z) => a[Z] === L[Z]) : a[S()] === L;
|
|
@@ -7060,7 +7060,7 @@ const Jl = be({
|
|
|
7060
7060
|
container: () => t.value ?? null,
|
|
7061
7061
|
useMinWidth: !0,
|
|
7062
7062
|
listWidth: () => e.props.listWidth,
|
|
7063
|
-
ignoreScrollTargets: (a) => a ===
|
|
7063
|
+
ignoreScrollTargets: (a) => a === d,
|
|
7064
7064
|
requestClose: () => {
|
|
7065
7065
|
p && B(!1);
|
|
7066
7066
|
}
|
|
@@ -7078,7 +7078,7 @@ const Jl = be({
|
|
|
7078
7078
|
var Z;
|
|
7079
7079
|
if (m() != null) {
|
|
7080
7080
|
const ae = D().findIndex((ue) => z(ue));
|
|
7081
|
-
ae >= 0 && (v = ae,
|
|
7081
|
+
ae >= 0 && (v = ae, d && (d.scrollTop = T(ae)), e.requestUpdate());
|
|
7082
7082
|
}
|
|
7083
7083
|
h.value ? h.value.focus() : (Z = i.value) == null || Z.focus();
|
|
7084
7084
|
})) : (V == null || V.release(), V = null, _.close(), e.emit("close"), U(se(), "blur"), v = -1, window.removeEventListener("keydown", k), u = "", e.emit("close"), queueMicrotask(() => {
|
|
@@ -7112,7 +7112,7 @@ const Jl = be({
|
|
|
7112
7112
|
u = a.target.value;
|
|
7113
7113
|
const L = D().length;
|
|
7114
7114
|
v = L > 0 ? 0 : -1, e.requestUpdate(), queueMicrotask(() => {
|
|
7115
|
-
q.setOptions({ ...q.options, count: L }), q.measure(),
|
|
7115
|
+
q.setOptions({ ...q.options, count: L }), q.measure(), d && (d.scrollTop = 0, q.scrollToIndex(0), q.measure());
|
|
7116
7116
|
});
|
|
7117
7117
|
}, 300);
|
|
7118
7118
|
return {
|
|
@@ -7129,7 +7129,7 @@ const Jl = be({
|
|
|
7129
7129
|
});
|
|
7130
7130
|
}
|
|
7131
7131
|
const Z = we(a, jl), { aria: ae, dom: ue } = dt(Z);
|
|
7132
|
-
return
|
|
7132
|
+
return c`
|
|
7133
7133
|
<div
|
|
7134
7134
|
class=${A("moz-table-select", {
|
|
7135
7135
|
"is-invalid": ie() !== "",
|
|
@@ -7171,7 +7171,7 @@ const Jl = be({
|
|
|
7171
7171
|
</button>
|
|
7172
7172
|
</div>
|
|
7173
7173
|
</div>
|
|
7174
|
-
${ie() !== "" ?
|
|
7174
|
+
${ie() !== "" ? c`<span class="moz-input-invalid-message">${ie()}</span>` : b}
|
|
7175
7175
|
</div>
|
|
7176
7176
|
`;
|
|
7177
7177
|
},
|
|
@@ -7183,19 +7183,19 @@ const Jl = be({
|
|
|
7183
7183
|
q.getVirtualItems(),
|
|
7184
7184
|
Z.length,
|
|
7185
7185
|
ht,
|
|
7186
|
-
|
|
7186
|
+
d
|
|
7187
7187
|
).map((C) => {
|
|
7188
7188
|
if (C.index >= Z.length) return null;
|
|
7189
7189
|
const I = Z[C.index];
|
|
7190
7190
|
return I ? { index: C.index, value: I, start: C.start } : null;
|
|
7191
7191
|
}).filter((C) => C !== null), $e = a.listWidth ? typeof a.listWidth == "number" ? `${a.listWidth}px` : a.listWidth : void 0;
|
|
7192
|
-
return
|
|
7192
|
+
return c`<div
|
|
7193
7193
|
class=${A("table-list-box", { "no-label": !a.label }, a.class)}
|
|
7194
7194
|
style=${oe({ width: $e })}
|
|
7195
7195
|
@keydown=${_e}
|
|
7196
7196
|
${ne(l)}
|
|
7197
7197
|
>
|
|
7198
|
-
${a.useFilter ?
|
|
7198
|
+
${a.useFilter ? c`<div class="filter-input">
|
|
7199
7199
|
<div class="search-icon">${Yt("12", "var(--moz-color-text-subtle)")}</div>
|
|
7200
7200
|
<input
|
|
7201
7201
|
${ne(h)}
|
|
@@ -7205,9 +7205,9 @@ const Jl = be({
|
|
|
7205
7205
|
class="filter-input__field"
|
|
7206
7206
|
/>
|
|
7207
7207
|
</div>` : b}
|
|
7208
|
-
${ae ?
|
|
7208
|
+
${ae ? c`<div class="table-header">
|
|
7209
7209
|
${L.map(
|
|
7210
|
-
(C, I) =>
|
|
7210
|
+
(C, I) => c`<div
|
|
7211
7211
|
class="table-header-cell"
|
|
7212
7212
|
style=${oe({ width: K(I), minWidth: K(I), maxWidth: K(I) })}
|
|
7213
7213
|
>
|
|
@@ -7226,7 +7226,7 @@ const Jl = be({
|
|
|
7226
7226
|
<div class="inner-container" style=${oe({ height: `${ue}px` })} ${ne(n)}>
|
|
7227
7227
|
${ke.map(({ index: C, value: I, start: ye }) => {
|
|
7228
7228
|
const Ee = z(I);
|
|
7229
|
-
return
|
|
7229
|
+
return c`<div
|
|
7230
7230
|
data-index=${C}
|
|
7231
7231
|
${ne((xe) => {
|
|
7232
7232
|
xe && q.measureElement(xe);
|
|
@@ -7240,13 +7240,13 @@ const Jl = be({
|
|
|
7240
7240
|
tabindex="0"
|
|
7241
7241
|
>
|
|
7242
7242
|
${L.map(
|
|
7243
|
-
(xe, Me) =>
|
|
7243
|
+
(xe, Me) => c`<div
|
|
7244
7244
|
class="table-cell"
|
|
7245
7245
|
style=${oe({ width: K(Me), minWidth: K(Me), maxWidth: K(Me) })}
|
|
7246
7246
|
title=${String(I[xe] ?? "")}
|
|
7247
7247
|
>
|
|
7248
7248
|
${G(String(I[xe] ?? "")).map(
|
|
7249
|
-
(Fe) =>
|
|
7249
|
+
(Fe) => c`<span class=${A({ highlight: Fe.highlight })}>${Fe.part}</span>`
|
|
7250
7250
|
)}
|
|
7251
7251
|
</div>`
|
|
7252
7252
|
)}
|
|
@@ -7254,7 +7254,7 @@ const Jl = be({
|
|
|
7254
7254
|
</div>`;
|
|
7255
7255
|
})}
|
|
7256
7256
|
</div>
|
|
7257
|
-
${!Z || Z.length <= 0 ?
|
|
7257
|
+
${!Z || Z.length <= 0 ? c`<div class="empty-row table-row">
|
|
7258
7258
|
${e.slots.has("empty") ? e.slot("empty") : a.emptyText ?? e.locale.TableSelect.emptyText}
|
|
7259
7259
|
</div>` : b}
|
|
7260
7260
|
</div>
|
|
@@ -7291,7 +7291,7 @@ const Jl = be({
|
|
|
7291
7291
|
expose: !0
|
|
7292
7292
|
};
|
|
7293
7293
|
function en(e = "var(--moz-color-text-subtle)", t = 12) {
|
|
7294
|
-
return
|
|
7294
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 12 12" fill="none">
|
|
7295
7295
|
<path
|
|
7296
7296
|
d="M2.49902 4.27679L6.04436 7.73581L9.501 4.27679"
|
|
7297
7297
|
stroke=${e}
|
|
@@ -7302,7 +7302,7 @@ function en(e = "var(--moz-color-text-subtle)", t = 12) {
|
|
|
7302
7302
|
</svg>`;
|
|
7303
7303
|
}
|
|
7304
7304
|
function tn(e = "var(--moz-color-text-subtle)", t = 12) {
|
|
7305
|
-
return
|
|
7305
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 12 12" fill="none">
|
|
7306
7306
|
<path
|
|
7307
7307
|
d="M9.50095 7.73636L5.95563 4.27734L2.49902 7.73636"
|
|
7308
7308
|
stroke=${e}
|
|
@@ -7313,7 +7313,7 @@ function tn(e = "var(--moz-color-text-subtle)", t = 12) {
|
|
|
7313
7313
|
</svg>`;
|
|
7314
7314
|
}
|
|
7315
7315
|
function on(e = "var(--moz-color-text-subtle)", t = 12, o = "") {
|
|
7316
|
-
return
|
|
7316
|
+
return c`<svg class=${o} width=${t} height=${t} viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
7317
7317
|
<path d="M1.71436 7.07145L3.00007 6.00002L1.71436 4.92859" stroke=${e} stroke-linecap="round" stroke-linejoin="round"></path>
|
|
7318
7318
|
<path d="M5.14307 4.71423H10.2859" stroke=${e} stroke-width="1.3" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
7319
7319
|
<path d="M1.71436 2.14282L10.2858 2.14282" stroke=${e} stroke-width="1.3" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
@@ -7322,7 +7322,7 @@ function on(e = "var(--moz-color-text-subtle)", t = 12, o = "") {
|
|
|
7322
7322
|
</svg>`;
|
|
7323
7323
|
}
|
|
7324
7324
|
function sn(e = "var(--moz-color-text-subtle)", t = 12, o = "") {
|
|
7325
|
-
return
|
|
7325
|
+
return c`<svg class=${o} width=${t} height=${t} viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
7326
7326
|
<path d="M0.856934 4.92852L2.14265 4.07138L0.856934 3.21423" fill=${e}></path>
|
|
7327
7327
|
<path d="M0.856934 4.92852L2.14265 4.07138L0.856934 3.21423V4.92852Z" stroke=${e} stroke-linecap="round" stroke-linejoin="round"></path>
|
|
7328
7328
|
<path d="M0.856934 8.7857L2.14265 7.92855L0.856934 7.07141" fill=${e}></path>
|
|
@@ -7364,10 +7364,10 @@ function nn(e) {
|
|
|
7364
7364
|
["depth2", []]
|
|
7365
7365
|
]), o = /* @__PURE__ */ new Map(), l = /* @__PURE__ */ new Map();
|
|
7366
7366
|
e.forEach((h) => {
|
|
7367
|
-
const
|
|
7368
|
-
if (!o.get(
|
|
7369
|
-
const s = { code:
|
|
7370
|
-
o.set(
|
|
7367
|
+
const d = h.categoryLv1ID;
|
|
7368
|
+
if (!o.get(d)) {
|
|
7369
|
+
const s = { code: d, name: h.categoryLv1Label ?? d };
|
|
7370
|
+
o.set(d, s), ft(t, "depth0").push(s);
|
|
7371
7371
|
}
|
|
7372
7372
|
if (!h.categoryLv2ID || h.categoryLv2ID.trim() === "")
|
|
7373
7373
|
ft(t, "depth1").push({ ...h, parent: h.categoryLv1ID });
|
|
@@ -7385,16 +7385,16 @@ function nn(e) {
|
|
|
7385
7385
|
ft(t, "depth2").push({ ...h, parent: h.categoryLv2ID });
|
|
7386
7386
|
}
|
|
7387
7387
|
});
|
|
7388
|
-
function n(h,
|
|
7389
|
-
const r = `depth${
|
|
7390
|
-
if (
|
|
7388
|
+
function n(h, d, s, m) {
|
|
7389
|
+
const r = `depth${d}`, p = `depth${d + 1}`, u = s.get(p), v = { ...h, depth: d };
|
|
7390
|
+
if (d !== 0 && (v.isHidden = !1), u && u.length > 0) {
|
|
7391
7391
|
const $ = m[r], F = m[p], S = u.filter(
|
|
7392
7392
|
(q) => q[F] === (h.isSubCategory ? h.code : h[$])
|
|
7393
7393
|
);
|
|
7394
7394
|
v.isExpanded = !0;
|
|
7395
7395
|
const y = [v];
|
|
7396
7396
|
return S.forEach((q) => {
|
|
7397
|
-
y.push(...n(q,
|
|
7397
|
+
y.push(...n(q, d + 1, s, m));
|
|
7398
7398
|
}), y;
|
|
7399
7399
|
}
|
|
7400
7400
|
return [v];
|
|
@@ -7503,7 +7503,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7503
7503
|
setup(e) {
|
|
7504
7504
|
const t = ve(), o = ve(), l = ve(), n = ve(), i = ve();
|
|
7505
7505
|
let h = null;
|
|
7506
|
-
const
|
|
7506
|
+
const d = (e.props.treeLevels ?? 1) - 1, s = d, m = () => !!e.props.useMultiSelect, r = () => e.props.disabledProp || "disabled", p = () => e.props.treeProps ?? io;
|
|
7507
7507
|
let u = e.props.modelValue ?? (m() ? [] : "");
|
|
7508
7508
|
const v = () => e.controlled("modelValue") ? e.props.modelValue ?? [] : u, $ = () => {
|
|
7509
7509
|
const w = v();
|
|
@@ -7553,7 +7553,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7553
7553
|
const P = /* @__PURE__ */ new Set(), N = M(), de = V();
|
|
7554
7554
|
w.filter((he) => {
|
|
7555
7555
|
if (Ce(he, de)) return !0;
|
|
7556
|
-
if (m() && !Ge(
|
|
7556
|
+
if (m() && !Ge(d, he.depth)) {
|
|
7557
7557
|
const fe = Ct(Q, he);
|
|
7558
7558
|
if (fe.length > 0 && fe.some((Ae) => de.has(Ae.code))) return !0;
|
|
7559
7559
|
}
|
|
@@ -7569,7 +7569,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7569
7569
|
const w = f();
|
|
7570
7570
|
return B().filter((P) => !w.includes(P));
|
|
7571
7571
|
}, Y = () => new Set(H().map((w) => w.code)), j = () => rn(H()), Ce = (w, P) => m() ? Ge(s, w.depth) ? P.has(w.code) : re.has(w.code) || ee.has(w.code) : v() === w.code, qe = (w) => {
|
|
7572
|
-
if (Ge(
|
|
7572
|
+
if (Ge(d, w.depth)) return !0;
|
|
7573
7573
|
const P = Ct(B(), w);
|
|
7574
7574
|
return P.length === 0 ? !0 : ao(gt(P), V());
|
|
7575
7575
|
}, _e = () => {
|
|
@@ -7630,7 +7630,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7630
7630
|
W = B().slice(ce, he + 1).map((fe, Ae) => ({ item: fe, index: ce + Ae }));
|
|
7631
7631
|
} else N.ctrlKey ? W.push({ item: w, index: P }) : W = [{ item: w, index: P }];
|
|
7632
7632
|
}, xe = (w, P) => {
|
|
7633
|
-
if (!Ge(
|
|
7633
|
+
if (!Ge(d, w.depth)) {
|
|
7634
7634
|
const { childDepthList: N } = It(B(), w);
|
|
7635
7635
|
if (P) {
|
|
7636
7636
|
const de = gt(N);
|
|
@@ -7643,12 +7643,12 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7643
7643
|
}, Me = (w, P) => {
|
|
7644
7644
|
const de = W.map((fe) => fe.item).filter((fe) => fe.depth === s), ce = C(de, w);
|
|
7645
7645
|
let he = [];
|
|
7646
|
-
if (P.depth !==
|
|
7646
|
+
if (P.depth !== d) {
|
|
7647
7647
|
const { childDepthList: fe } = It(B(), P), Ae = gt(fe);
|
|
7648
7648
|
he = $().filter((Ne) => !Ae.has(Ne));
|
|
7649
7649
|
} else
|
|
7650
7650
|
he = $();
|
|
7651
|
-
w ? P.depth ===
|
|
7651
|
+
w ? P.depth === d ? he = [...he, ...ce] : co(K, B(), P, s) : (vt(K), he = he.filter((fe) => !ce.some((Ae) => fe === Ae))), I(he);
|
|
7652
7652
|
}, Fe = (w, P, N, de) => {
|
|
7653
7653
|
const ce = W.some((he) => he.item.code === w.code);
|
|
7654
7654
|
(W.length <= 1 || !ce) && Ee(w, P, { shiftKey: !1, ctrlKey: !1 }), Me(!de, w), xe(w, de), e.requestUpdate();
|
|
@@ -7658,7 +7658,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7658
7658
|
if (w[r()] === !0) return;
|
|
7659
7659
|
let de = [], ce = !1;
|
|
7660
7660
|
const he = w.code;
|
|
7661
|
-
if (Ge(
|
|
7661
|
+
if (Ge(d, w.depth))
|
|
7662
7662
|
ce = $().length === 1 && $()[0] === he, ce || (de = [he]), vt(K);
|
|
7663
7663
|
else {
|
|
7664
7664
|
const { childDepthList: fe } = It(B(), w), Ae = gt(fe);
|
|
@@ -7740,7 +7740,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7740
7740
|
getScrollElement: () => h,
|
|
7741
7741
|
estimateSize: (w) => {
|
|
7742
7742
|
const P = B()[w];
|
|
7743
|
-
return P != null && P.isHidden ? 0 : se() && P && Ge(
|
|
7743
|
+
return P != null && P.isHidden ? 0 : se() && P && Ge(d, P.depth) ? G : D;
|
|
7744
7744
|
},
|
|
7745
7745
|
measureElement: (w) => w.getBoundingClientRect().height,
|
|
7746
7746
|
overscan: 3,
|
|
@@ -7753,9 +7753,9 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7753
7753
|
const No = (w) => {
|
|
7754
7754
|
h = w ?? null, w && (Ie._willUpdate(), e.requestUpdate());
|
|
7755
7755
|
}, Uo = (w, P) => {
|
|
7756
|
-
w && P ===
|
|
7756
|
+
w && P === d && (G = w.getBoundingClientRect().height);
|
|
7757
7757
|
}, _o = (w) => w.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), jt = (w, P) => {
|
|
7758
|
-
if (!y || !Ge(
|
|
7758
|
+
if (!y || !Ge(d, P)) return [{ part: w, highlight: !1 }];
|
|
7759
7759
|
const N = new RegExp(`(${_o(y)})`, "gi");
|
|
7760
7760
|
return w.split(N).map((de) => ({ part: de, highlight: y.toLowerCase() === de.toLowerCase() }));
|
|
7761
7761
|
};
|
|
@@ -7763,14 +7763,14 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7763
7763
|
const Wo = (w) => {
|
|
7764
7764
|
const { index: P, item: N, start: de, isSelected: ce, isIndeterminate: he, isDisabled: fe, isFocused: Ae } = w;
|
|
7765
7765
|
if (N.isHidden) return b;
|
|
7766
|
-
const Ne = e.props, Re = N.depth, Ue = Ge(
|
|
7767
|
-
Re !==
|
|
7766
|
+
const Ne = e.props, Re = N.depth, Ue = Ge(d, Re), je = m(), nt = (Be) => {
|
|
7767
|
+
Re !== d ? Ze(N, Be) : ot(N.code);
|
|
7768
7768
|
}, pt = (Be) => {
|
|
7769
7769
|
je ? We(N, P, Be, ce && qe(N)) : nt(Be);
|
|
7770
7770
|
}, Dt = () => {
|
|
7771
7771
|
Fe(N, P, {}, ce && qe(N));
|
|
7772
7772
|
}, qt = Ue ? "하나만" : "그룹만";
|
|
7773
|
-
return
|
|
7773
|
+
return c`<div
|
|
7774
7774
|
data-index=${P}
|
|
7775
7775
|
${ne((Be) => {
|
|
7776
7776
|
Be && (Ie.measureElement(Be), Uo(Be, Re));
|
|
@@ -7796,7 +7796,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7796
7796
|
}}
|
|
7797
7797
|
></div>
|
|
7798
7798
|
<div class="item-content" @click=${pt}>
|
|
7799
|
-
${Ue ? b :
|
|
7799
|
+
${Ue ? b : c`<button
|
|
7800
7800
|
type="button"
|
|
7801
7801
|
class="icon-container"
|
|
7802
7802
|
aria-expanded=${N.isExpanded ? "true" : "false"}
|
|
@@ -7816,12 +7816,12 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7816
7816
|
text: { text: _(N), depth: Re },
|
|
7817
7817
|
item: N,
|
|
7818
7818
|
highlightText: jt(_(N), Re)
|
|
7819
|
-
}) :
|
|
7820
|
-
(Be) =>
|
|
7819
|
+
}) : c`${jt(_(N), Re).map(
|
|
7820
|
+
(Be) => c`<span class=${A({ highlight: Be.highlight })}>${Be.part}</span>`
|
|
7821
7821
|
)}`}
|
|
7822
7822
|
</div>
|
|
7823
7823
|
${!je && ce && Ue ? Wt("12", "var(--moz-color-accent)", !1, "icon-check") : b}
|
|
7824
|
-
${je && Ne.useSpecificSelect && !fe ?
|
|
7824
|
+
${je && Ne.useSpecificSelect && !fe ? c`<button type="button" class="item-only item-only-btn" @click=${(Be) => Xe(N, P, Be)}>
|
|
7825
7825
|
${qt}
|
|
7826
7826
|
</button>` : b}
|
|
7827
7827
|
</div>
|
|
@@ -7835,7 +7835,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7835
7835
|
const P = v();
|
|
7836
7836
|
P !== Xt && (Xt = P, typeof P != "string" && ye($()));
|
|
7837
7837
|
const N = typeof w.width == "number" ? `${ze(w.width)}rem` : w.width, de = e.slots.has("icon") ? e.slot("icon", { isOpen: S }) : S ? Gt("14", "var(--moz-color-accent)") : Kt("14", "var(--moz-color-text-subtle)", w.disabled), ce = we(w, cn), { aria: he, dom: fe } = dt(ce);
|
|
7838
|
-
return
|
|
7838
|
+
return c`
|
|
7839
7839
|
<div
|
|
7840
7840
|
${pe(fe)}
|
|
7841
7841
|
class=${A(
|
|
@@ -7852,7 +7852,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7852
7852
|
${ne(t)}
|
|
7853
7853
|
>
|
|
7854
7854
|
<div class="input-wrapper">
|
|
7855
|
-
${w.label ? Oe({},
|
|
7855
|
+
${w.label ? Oe({}, c`${w.label}${w.required ? c`<span class="require-mark">*</span>` : b}`) : b}
|
|
7856
7856
|
<div class="moz-input-container" @click=${rt} ${ne(o)}>
|
|
7857
7857
|
<input .value=${L()} autocomplete="off" readonly tabindex="-1" />
|
|
7858
7858
|
<button
|
|
@@ -7870,7 +7870,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7870
7870
|
</button>
|
|
7871
7871
|
</div>
|
|
7872
7872
|
</div>
|
|
7873
|
-
${Z() !== "" ?
|
|
7873
|
+
${Z() !== "" ? c`<span class="moz-input-invalid-message">${Z()}</span>` : b}
|
|
7874
7874
|
</div>
|
|
7875
7875
|
`;
|
|
7876
7876
|
},
|
|
@@ -7888,7 +7888,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7888
7888
|
const Re = P[Ne.index];
|
|
7889
7889
|
if (!Re) return null;
|
|
7890
7890
|
let Ue = Ce(Re, de), je = !1;
|
|
7891
|
-
if (m() && !Ge(
|
|
7891
|
+
if (m() && !Ge(d, Re.depth)) {
|
|
7892
7892
|
const nt = Ct(Q, Re);
|
|
7893
7893
|
if (nt.length > 0) {
|
|
7894
7894
|
const pt = nt.reduce((Dt, qt) => Dt + (de.has(qt.code) ? 1 : 0), 0);
|
|
@@ -7907,13 +7907,13 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7907
7907
|
}).filter(
|
|
7908
7908
|
(Ne) => Ne !== null
|
|
7909
7909
|
), he = y ? e.locale.TreeSelect.selectFiltered : e.locale.TreeSelect.selectAll, fe = v(), Ae = Array.isArray(fe) ? fe.length : fe ? 1 : 0;
|
|
7910
|
-
return
|
|
7910
|
+
return c`<div
|
|
7911
7911
|
class=${A("list-box", { "no-label": !w.label, "show-top": E })}
|
|
7912
7912
|
style=${oe(X)}
|
|
7913
7913
|
${ne(l)}
|
|
7914
7914
|
>
|
|
7915
7915
|
<div class="filter-input-wrapper">
|
|
7916
|
-
${w.useFilter ?
|
|
7916
|
+
${w.useFilter ? c`<div class="filter-input">
|
|
7917
7917
|
<div class="search-icon">${Yt("12", "var(--moz-color-text-subtle)")}</div>
|
|
7918
7918
|
<input placeholder=${e.locale.TreeSelect.search} @input=${At} ${ne(i)} />
|
|
7919
7919
|
</div>` : b}
|
|
@@ -7923,24 +7923,24 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7923
7923
|
</div>
|
|
7924
7924
|
</div>
|
|
7925
7925
|
|
|
7926
|
-
${a() && ie.length > 0 && P.length > 0 ?
|
|
7926
|
+
${a() && ie.length > 0 && P.length > 0 ? c`<div class=${A("list-box-item multi-select-item multi-select-all", { "is-scrolled": q })} @click=${R}>
|
|
7927
7927
|
<div class="select-all-content">
|
|
7928
7928
|
${Ft({ indeterminate: Ae > 0 && _e() === !1, checked: He() })}
|
|
7929
7929
|
<div><span title=${he}>${he}</span></div>
|
|
7930
7930
|
</div>
|
|
7931
|
-
${y && P.length > 0 ?
|
|
7931
|
+
${y && P.length > 0 ? c`<button type="button" class="item-only" @click=${O}>${e.locale.TreeSelect.specificResults}</button>` : b}
|
|
7932
7932
|
</div>` : b}
|
|
7933
7933
|
|
|
7934
7934
|
<div class="list-box-container" @scroll=${J} ${ne(No)}>
|
|
7935
7935
|
<div class="inner-container" style=${oe({ height: `${N}px` })}>
|
|
7936
7936
|
${ce.map((Ne) => Wo(Ne))}
|
|
7937
7937
|
</div>
|
|
7938
|
-
${P.length <= 0 ?
|
|
7938
|
+
${P.length <= 0 ? c`<div class="list-box-item loading not-hover">
|
|
7939
7939
|
${e.slots.has("empty") ? e.slot("empty") : e.locale.TreeSelect.noData}
|
|
7940
7940
|
</div>` : b}
|
|
7941
7941
|
</div>
|
|
7942
7942
|
|
|
7943
|
-
${m() ?
|
|
7943
|
+
${m() ? c`<div class="list-footer">
|
|
7944
7944
|
<label class="footer-checkbox">
|
|
7945
7945
|
${Ft({ checked: z, onChange: Ye, class: "moz-checkbox" })}
|
|
7946
7946
|
<span>${e.locale.TreeSelect.showSelectedOnly}</span>
|
|
@@ -7988,9 +7988,9 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
7988
7988
|
setup(e) {
|
|
7989
7989
|
let t = null, o = null;
|
|
7990
7990
|
const l = [], n = [], i = [], h = [];
|
|
7991
|
-
let
|
|
7991
|
+
let d = [], s = !1, m = 0, r = 0, p = -1, u = -1, v = -1, $ = null, F = null, S = 0;
|
|
7992
7992
|
const y = () => !!e.props.horizontal, q = () => e.props.panes ?? [], E = () => {
|
|
7993
|
-
|
|
7993
|
+
d = q().map((U) => U.hidden ? "0" : U.size != null ? String(U.size) : "1fr");
|
|
7994
7994
|
};
|
|
7995
7995
|
E();
|
|
7996
7996
|
const z = (U) => y() ? U.clientHeight : U.clientWidth, X = () => z(i[u]), W = () => z(h[u]), te = () => z(i[v]), re = () => z(h[v]), ee = (U) => {
|
|
@@ -8017,25 +8017,25 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
8017
8017
|
}
|
|
8018
8018
|
if (!(r > te() && r < re() || r < te() && $ === 0 || r > te() && $ === 1)) {
|
|
8019
8019
|
if (r < te()) {
|
|
8020
|
-
if (v + 1 >=
|
|
8020
|
+
if (v + 1 >= d.length) {
|
|
8021
8021
|
S += y() ? U.movementY : U.movementX;
|
|
8022
8022
|
return;
|
|
8023
8023
|
}
|
|
8024
|
-
v = v + 1 <
|
|
8024
|
+
v = v + 1 < d.length ? v + 1 : d.length - 1;
|
|
8025
8025
|
} else if (r > re()) {
|
|
8026
|
-
if (v + 1 >=
|
|
8026
|
+
if (v + 1 >= d.length) {
|
|
8027
8027
|
S += y() ? U.movementY : U.movementX;
|
|
8028
8028
|
return;
|
|
8029
8029
|
}
|
|
8030
|
-
v = v + 1 <
|
|
8030
|
+
v = v + 1 < d.length ? v + 1 : d.length - 1;
|
|
8031
8031
|
}
|
|
8032
8032
|
}
|
|
8033
8033
|
if ($ === 0 && S > 0 || $ === 1 && S < 0 || $ === 0 && r > re() || $ === 1 && r < te() || $ === 0 && m < X() || $ === 1 && m > W())
|
|
8034
8034
|
return;
|
|
8035
8035
|
const T = t[y() ? "clientHeight" : "clientWidth"], V = k(u) + x;
|
|
8036
|
-
|
|
8036
|
+
d[u] = `clamp(${X()}px, ${V / T * 100}%, ${W()}px)`, d[v] = "1fr", e.requestUpdate(), queueMicrotask(() => {
|
|
8037
8037
|
const B = k(v);
|
|
8038
|
-
|
|
8038
|
+
d[v] = `clamp(${te()}px, ${B / T * 100}%, ${re()}px)`, e.requestUpdate();
|
|
8039
8039
|
});
|
|
8040
8040
|
}, K = () => {
|
|
8041
8041
|
p = -1, u = -1, v = -1, s = !1, S = 0, document.removeEventListener("mousemove", ee), document.removeEventListener("mouseup", K), e.requestUpdate();
|
|
@@ -8062,13 +8062,13 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
8062
8062
|
E(), e.requestUpdate();
|
|
8063
8063
|
}));
|
|
8064
8064
|
const x = y() ? "gridTemplateRows" : "gridTemplateColumns", M = U.length - 1, _ = we(e.props, un);
|
|
8065
|
-
return
|
|
8065
|
+
return c`
|
|
8066
8066
|
<div
|
|
8067
8067
|
${pe(_)}
|
|
8068
8068
|
class=${A("splitter", e.props.class)}
|
|
8069
8069
|
style=${oe({
|
|
8070
8070
|
display: "grid",
|
|
8071
|
-
[x]:
|
|
8071
|
+
[x]: d.join(" "),
|
|
8072
8072
|
width: "100%",
|
|
8073
8073
|
height: "100%",
|
|
8074
8074
|
overflow: "hidden",
|
|
@@ -8079,15 +8079,15 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
8079
8079
|
})}
|
|
8080
8080
|
>
|
|
8081
8081
|
${U.map((k, T) => {
|
|
8082
|
-
const V = T === M ? "100%" :
|
|
8083
|
-
return
|
|
8082
|
+
const V = T === M ? "100%" : d[T + 1] !== "0" ? "calc(100% - 10px) 10px" : "100%";
|
|
8083
|
+
return c`<div
|
|
8084
8084
|
style=${oe({ display: "grid", [x]: V, overflow: "hidden" })}
|
|
8085
8085
|
${ne((B) => {
|
|
8086
8086
|
l[T] = B ?? null;
|
|
8087
8087
|
})}
|
|
8088
8088
|
>
|
|
8089
8089
|
<div style="width: 100%; height: 100%; overflow: hidden">${e.slot(`pane-${T}`)}</div>
|
|
8090
|
-
${T !== M &&
|
|
8090
|
+
${T !== M && d[T + 1] !== "0" ? c`<div
|
|
8091
8091
|
class=${y() ? "resizer resizer-horizontal" : "resizer resizer-vertical"}
|
|
8092
8092
|
role="separator"
|
|
8093
8093
|
aria-orientation=${y() ? "horizontal" : "vertical"}
|
|
@@ -8109,7 +8109,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
8109
8109
|
>
|
|
8110
8110
|
${U.map((k, T) => {
|
|
8111
8111
|
const V = po(k.minSize, "10px"), B = po(k.maxSize, "100%");
|
|
8112
|
-
return
|
|
8112
|
+
return c`<div
|
|
8113
8113
|
class="size-calculator min-size"
|
|
8114
8114
|
style=${oe({ width: V, height: V })}
|
|
8115
8115
|
${ne((f) => {
|
|
@@ -8141,7 +8141,7 @@ const cn = /* @__PURE__ */ new Set([
|
|
|
8141
8141
|
expose: !1
|
|
8142
8142
|
};
|
|
8143
8143
|
function mn(e = "currentColor", t = 14) {
|
|
8144
|
-
return
|
|
8144
|
+
return c`<svg width=${t} height=${t} viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
8145
8145
|
<path
|
|
8146
8146
|
d="M12.25 12.25V3.8436L10.163 1.75H1.75V12.25H12.25ZM12.4448 14H1.55615C0.7002 14 0 13.3001 0 12.4446V1.55617C0 0.70013 0.69238 0 1.55615 0H10.2432C10.6558 0 11.0522 0.16353 11.3481 0.46009L13.5415 2.66039C13.8364 2.94828 14 3.34501 14 3.75673V12.4446C14 13.3001 13.3003 14 12.4448 14Z"
|
|
8147
8147
|
fill=${e}
|
|
@@ -8159,7 +8159,7 @@ function mn(e = "currentColor", t = 14) {
|
|
|
8159
8159
|
</svg>`;
|
|
8160
8160
|
}
|
|
8161
8161
|
function hn(e = "currentColor", t = 14) {
|
|
8162
|
-
return
|
|
8162
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 14 14" fill="none">
|
|
8163
8163
|
<g clip-path="url(#clip0_16945_2363)">
|
|
8164
8164
|
<path
|
|
8165
8165
|
d="M10.8 5.2998H3.2C2.8134 5.2998 2.5 5.61321 2.5 5.9998V12.3998C2.5 12.7864 2.8134 13.0998 3.2 13.0998H10.8C11.1866 13.0998 11.5 12.7864 11.5 12.3998V5.9998C11.5 5.61321 11.1866 5.2998 10.8 5.2998Z"
|
|
@@ -8178,7 +8178,7 @@ function hn(e = "currentColor", t = 14) {
|
|
|
8178
8178
|
</svg>`;
|
|
8179
8179
|
}
|
|
8180
8180
|
function fn(e = "currentColor", t = 14) {
|
|
8181
|
-
return
|
|
8181
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 14 14">
|
|
8182
8182
|
<path d="M0,0H14V14H0Z" fill="none"></path>
|
|
8183
8183
|
<line
|
|
8184
8184
|
y2="10"
|
|
@@ -8199,7 +8199,7 @@ function fn(e = "currentColor", t = 14) {
|
|
|
8199
8199
|
</svg>`;
|
|
8200
8200
|
}
|
|
8201
8201
|
function gn(e = "currentColor", t = 14) {
|
|
8202
|
-
return
|
|
8202
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 14 14" fill="none">
|
|
8203
8203
|
<path
|
|
8204
8204
|
d="M5.84944 0.402344C2.83893 0.402344 0.398438 2.84284 0.398438 5.85334C0.398438 8.86385 2.83893 11.3043 5.84944 11.3043C7.0308 11.3043 8.12438 10.9285 9.01716 10.29L12.0619 13.3347C12.4134 13.6862 12.9832 13.6862 13.3347 13.3347C13.6862 12.9832 13.6862 12.4134 13.3347 12.0619L10.2893 9.01651C10.9259 8.12457 11.3004 7.03269 11.3004 5.85334C11.3004 2.84284 8.85994 0.402344 5.84944 0.402344ZM2.19844 5.85334C2.19844 3.83695 3.83305 2.20234 5.84944 2.20234C7.86583 2.20234 9.50044 3.83695 9.50044 5.85334C9.50044 7.86974 7.86583 9.50434 5.84944 9.50434C3.83305 9.50434 2.19844 7.86974 2.19844 5.85334Z"
|
|
8205
8205
|
fill=${e}
|
|
@@ -8207,7 +8207,7 @@ function gn(e = "currentColor", t = 14) {
|
|
|
8207
8207
|
</svg>`;
|
|
8208
8208
|
}
|
|
8209
8209
|
function vn(e = "currentColor", t = 14) {
|
|
8210
|
-
return
|
|
8210
|
+
return c`<svg xmlns="http://www.w3.org/2000/svg" width=${t} height=${t} viewBox="0 0 14 14" fill="none">
|
|
8211
8211
|
<path
|
|
8212
8212
|
d="M12.7988 6.23621C12.6596 5.99307 12.4571 5.79178 12.2126 5.65358L4.31964 1.20161C4.08323 1.06797 3.81572 0.998459 3.54385 1.00003C3.27199 1.00159 3.00531 1.07419 2.77047 1.21055C2.53563 1.3469 2.34088 1.54224 2.20567 1.77703C2.07046 2.01181 1.99953 2.27781 2 2.54843V11.4524C1.99975 11.7229 2.07082 11.9888 2.20609 12.2234C2.34136 12.4581 2.53611 12.6533 2.77089 12.7895C3.00567 12.9258 3.27225 12.9984 3.54402 13C3.81579 13.0016 4.08324 12.9322 4.31964 12.7987L12.2117 8.3472C12.5703 8.14432 12.8334 7.80821 12.9435 7.4125C13.0536 7.0168 13.0015 6.59379 12.7988 6.23621Z"
|
|
8213
8213
|
fill=${e}
|
|
@@ -8250,7 +8250,7 @@ function Cn(e) {
|
|
|
8250
8250
|
case "IconPlay":
|
|
8251
8251
|
return vn();
|
|
8252
8252
|
default:
|
|
8253
|
-
return
|
|
8253
|
+
return c``;
|
|
8254
8254
|
}
|
|
8255
8255
|
}
|
|
8256
8256
|
const yn = be({
|
|
@@ -8262,7 +8262,7 @@ const yn = be({
|
|
|
8262
8262
|
let t = !!e.props.showFilterButton, o = !1;
|
|
8263
8263
|
const l = () => e.controlled("customQueryParamsPanel") ? !!e.props.customQueryParamsPanel : o;
|
|
8264
8264
|
let n = null, i = !1;
|
|
8265
|
-
const h = tt("switch_"),
|
|
8265
|
+
const h = tt("switch_"), d = tt("switch_"), s = (u) => {
|
|
8266
8266
|
t = u.target.checked, e.requestUpdate();
|
|
8267
8267
|
}, m = (u) => {
|
|
8268
8268
|
const v = u.target.checked;
|
|
@@ -8274,7 +8274,7 @@ const yn = be({
|
|
|
8274
8274
|
},
|
|
8275
8275
|
getPortalContainer: () => n,
|
|
8276
8276
|
renderPortal() {
|
|
8277
|
-
return !i || !e.slots.has("custom-filter") ? b :
|
|
8277
|
+
return !i || !e.slots.has("custom-filter") ? b : c`<div style=${oe({ display: l() ? void 0 : "none" })}>
|
|
8278
8278
|
${e.slot("custom-filter")}
|
|
8279
8279
|
</div>`;
|
|
8280
8280
|
},
|
|
@@ -8283,7 +8283,7 @@ const yn = be({
|
|
|
8283
8283
|
const z = bn(E), X = !!S && E.action !== S.action || !!E.disabled;
|
|
8284
8284
|
return { ...E, icon: z, disabled: X };
|
|
8285
8285
|
}), q = we(u, wn);
|
|
8286
|
-
return
|
|
8286
|
+
return c`
|
|
8287
8287
|
<div
|
|
8288
8288
|
class=${A("moz-controller-root", u.class)}
|
|
8289
8289
|
style=${oe(Pe(u.containerStyle))}
|
|
@@ -8302,14 +8302,14 @@ const yn = be({
|
|
|
8302
8302
|
onChange: s
|
|
8303
8303
|
}) : b}
|
|
8304
8304
|
${u.showFilterButton && v ? Nt({
|
|
8305
|
-
id:
|
|
8305
|
+
id: d,
|
|
8306
8306
|
model: l(),
|
|
8307
8307
|
label: "조회 조건",
|
|
8308
8308
|
onChange: m
|
|
8309
8309
|
}) : b}
|
|
8310
|
-
${u.showFilterButton ?
|
|
8310
|
+
${u.showFilterButton ? c`<div class="spacer between-buttons" style="margin: 0 6px"></div>` : b}
|
|
8311
8311
|
${e.slot("action")}
|
|
8312
|
-
${$ && y.length > 0 ?
|
|
8312
|
+
${$ && y.length > 0 ? c`<div class="spacer between-buttons"></div>` : b}
|
|
8313
8313
|
${y.map(
|
|
8314
8314
|
(E) => bt(
|
|
8315
8315
|
{
|
|
@@ -8332,7 +8332,7 @@ const yn = be({
|
|
|
8332
8332
|
</div>
|
|
8333
8333
|
</div>
|
|
8334
8334
|
|
|
8335
|
-
${t && !v ?
|
|
8335
|
+
${t && !v ? c`<div
|
|
8336
8336
|
class="moz-horizontal-filter moz-controller-filter"
|
|
8337
8337
|
style=${oe(Pe(u.filterStyle))}
|
|
8338
8338
|
>
|
|
@@ -8387,7 +8387,7 @@ class $n {
|
|
|
8387
8387
|
}
|
|
8388
8388
|
}
|
|
8389
8389
|
function Sn(e = "var(--moz-color-on-accent)") {
|
|
8390
|
-
return
|
|
8390
|
+
return c`<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
8391
8391
|
<path
|
|
8392
8392
|
fill-rule="evenodd"
|
|
8393
8393
|
clip-rule="evenodd"
|
|
@@ -8397,7 +8397,7 @@ function Sn(e = "var(--moz-color-on-accent)") {
|
|
|
8397
8397
|
</svg>`;
|
|
8398
8398
|
}
|
|
8399
8399
|
function kn(e = "var(--moz-color-on-accent)") {
|
|
8400
|
-
return
|
|
8400
|
+
return c`<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
8401
8401
|
<mask id="mask0_6027_4458" style="mask-type: luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="30" height="30">
|
|
8402
8402
|
<path d="M30 0H0V30H30V0Z" fill="#FFF"></path>
|
|
8403
8403
|
</mask>
|
|
@@ -8410,7 +8410,7 @@ function kn(e = "var(--moz-color-on-accent)") {
|
|
|
8410
8410
|
</svg>`;
|
|
8411
8411
|
}
|
|
8412
8412
|
function En(e = "var(--moz-color-on-accent)") {
|
|
8413
|
-
return
|
|
8413
|
+
return c`<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
8414
8414
|
<path
|
|
8415
8415
|
fill-rule="evenodd"
|
|
8416
8416
|
clip-rule="evenodd"
|
|
@@ -8420,7 +8420,7 @@ function En(e = "var(--moz-color-on-accent)") {
|
|
|
8420
8420
|
</svg>`;
|
|
8421
8421
|
}
|
|
8422
8422
|
function xn(e = "var(--moz-color-on-accent)") {
|
|
8423
|
-
return
|
|
8423
|
+
return c`<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
8424
8424
|
<mask id="mask0_6027_4463" style="mask-type: luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="30" height="30">
|
|
8425
8425
|
<path d="M30 0H0V30H30V0Z" fill="#FFF"></path>
|
|
8426
8426
|
</mask>
|
|
@@ -8432,7 +8432,7 @@ function xn(e = "var(--moz-color-on-accent)") {
|
|
|
8432
8432
|
</g>
|
|
8433
8433
|
</svg>`;
|
|
8434
8434
|
}
|
|
8435
|
-
const Pn = () =>
|
|
8435
|
+
const Pn = () => c`
|
|
8436
8436
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
|
|
8437
8437
|
<path d="M18 6 6 18M6 6l12 12" />
|
|
8438
8438
|
</svg>
|
|
@@ -8495,7 +8495,7 @@ const Ho = be({
|
|
|
8495
8495
|
},
|
|
8496
8496
|
setup(e) {
|
|
8497
8497
|
let t = !1, o = !1, l = null, n = null, i = null, h = 100;
|
|
8498
|
-
const
|
|
8498
|
+
const d = () => {
|
|
8499
8499
|
let y = document.querySelector(".toast--top"), q = document.querySelector(".toast--bottom");
|
|
8500
8500
|
y && q || (y || (y = document.createElement("div"), y.className = "toast--top moz-toast-body moz-toast-body--top", document.body.appendChild(y)), q || (q = document.createElement("div"), q.className = "toast--bottom moz-toast-body moz-toast-body--bottom", document.body.appendChild(q)));
|
|
8501
8501
|
}, s = () => {
|
|
@@ -8524,12 +8524,12 @@ const Ho = be({
|
|
|
8524
8524
|
}, v = () => {
|
|
8525
8525
|
e.props.dismissible && r();
|
|
8526
8526
|
};
|
|
8527
|
-
e.props.inline ||
|
|
8527
|
+
e.props.inline || d(), e.onCleanup(() => {
|
|
8528
8528
|
l && l.stop(), n && clearTimeout(n), m();
|
|
8529
8529
|
});
|
|
8530
8530
|
const $ = () => {
|
|
8531
8531
|
const y = e.props, q = y.duration ?? 0;
|
|
8532
|
-
return
|
|
8532
|
+
return c`
|
|
8533
8533
|
<div
|
|
8534
8534
|
data-testid="toast-container"
|
|
8535
8535
|
${pe(we(y, mo))}
|
|
@@ -8541,23 +8541,23 @@ const Ho = be({
|
|
|
8541
8541
|
@mouseenter=${() => u(!0)}
|
|
8542
8542
|
@mouseleave=${() => u(!1)}
|
|
8543
8543
|
>
|
|
8544
|
-
${y.showProgress && q > 0 ?
|
|
8544
|
+
${y.showProgress && q > 0 ? c`<div class="moz-toast-progress" aria-hidden="true">
|
|
8545
8545
|
<div class=${A("moz-toast-progress-bar", y.progressClass)} style=${`width: ${h}%`}></div>
|
|
8546
8546
|
</div>` : b}
|
|
8547
|
-
${e.slots.has("icon") ?
|
|
8547
|
+
${e.slots.has("icon") ? c`<div class="moz-toast-icon">${e.slot("icon")}</div>` : b}
|
|
8548
8548
|
<div class="moz-toast-content">
|
|
8549
|
-
${e.slots.has("heading") ?
|
|
8550
|
-
${e.slots.has("description") ?
|
|
8551
|
-
${e.slots.has("actions") ?
|
|
8549
|
+
${e.slots.has("heading") ? c`<div class="moz-toast-heading">${e.slot("heading")}</div>` : b}
|
|
8550
|
+
${e.slots.has("description") ? c`<div class="moz-toast-description">${e.slot("description")}</div>` : b}
|
|
8551
|
+
${e.slots.has("actions") ? c`<div class="moz-toast-actions">${e.slot("actions")}</div>` : b}
|
|
8552
8552
|
</div>
|
|
8553
|
-
${y.dismissible ?
|
|
8553
|
+
${y.dismissible ? c`<button type="button" class="moz-toast-close" aria-label=${e.locale.Toast.close} @click=${r}>
|
|
8554
8554
|
${Pn()}
|
|
8555
8555
|
</button>` : b}
|
|
8556
8556
|
</div>
|
|
8557
8557
|
`;
|
|
8558
8558
|
}, F = () => {
|
|
8559
8559
|
const y = e.props;
|
|
8560
|
-
return
|
|
8560
|
+
return c`
|
|
8561
8561
|
<div
|
|
8562
8562
|
data-testid="toast-container"
|
|
8563
8563
|
${pe(we(y, mo))}
|
|
@@ -8673,13 +8673,13 @@ function Rt(e, t, o) {
|
|
|
8673
8673
|
return o < t ? t : Math.min(Math.max(e, t), o);
|
|
8674
8674
|
}
|
|
8675
8675
|
function Oo(e, t, o, l) {
|
|
8676
|
-
const { align: n, sideOffset: i, collisionPadding: h } = l,
|
|
8676
|
+
const { align: n, sideOffset: i, collisionPadding: h } = l, d = l.arrowSize ?? 0;
|
|
8677
8677
|
let s = l.side;
|
|
8678
8678
|
!go(s, e, t, o, i, h) && go(fo[s], e, t, o, i, h) && (s = fo[s]);
|
|
8679
8679
|
const m = s === "top" || s === "bottom";
|
|
8680
8680
|
let r, p;
|
|
8681
8681
|
s === "top" ? (p = e.top - t.height - i, r = wt(n, e.left, e.width, t.width)) : s === "bottom" ? (p = e.top + e.height + i, r = wt(n, e.left, e.width, t.width)) : s === "left" ? (r = e.left - t.width - i, p = wt(n, e.top, e.height, t.height)) : (r = e.left + e.width + i, p = wt(n, e.top, e.height, t.height)), m ? r = Rt(r, h, o.width - t.width - h) : p = Rt(p, h, o.height - t.height - h);
|
|
8682
|
-
const u = m ? e.left + e.width / 2 : e.top + e.height / 2, v = m ? r : p, $ = m ? t.width : t.height, F = Rt(u - v,
|
|
8682
|
+
const u = m ? e.left + e.width / 2 : e.top + e.height / 2, v = m ? r : p, $ = m ? t.width : t.height, F = Rt(u - v, d * 2, $ - d * 2), S = {
|
|
8683
8683
|
top: e.top - i - h,
|
|
8684
8684
|
bottom: o.height - (e.top + e.height) - i - h,
|
|
8685
8685
|
left: o.height - h * 2,
|
|
@@ -8732,11 +8732,11 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8732
8732
|
}
|
|
8733
8733
|
);
|
|
8734
8734
|
o !== null && n && o.side === r.side && o.x === r.x && o.y === r.y && o.arrowOffset === r.arrowOffset || (o = r, n = !0, e.requestUpdate(), l !== r.side && (l = r.side, e.emit("placed", r.side)));
|
|
8735
|
-
},
|
|
8735
|
+
}, d = () => {
|
|
8736
8736
|
i() && h();
|
|
8737
8737
|
};
|
|
8738
|
-
return typeof window < "u" && (window.addEventListener("scroll",
|
|
8739
|
-
window.removeEventListener("scroll",
|
|
8738
|
+
return typeof window < "u" && (window.addEventListener("scroll", d, { capture: !0, passive: !0 }), window.addEventListener("resize", d, { passive: !0 }), e.onCleanup(() => {
|
|
8739
|
+
window.removeEventListener("scroll", d, !0), window.removeEventListener("resize", d);
|
|
8740
8740
|
})), {
|
|
8741
8741
|
render() {
|
|
8742
8742
|
return b;
|
|
@@ -8747,7 +8747,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8747
8747
|
return o = null, l = null, n = !1, b;
|
|
8748
8748
|
qn(h);
|
|
8749
8749
|
const m = (o == null ? void 0 : o.side) ?? s.side ?? "top", r = we(s, An), p = m === "top" || m === "bottom" ? "left" : "top";
|
|
8750
|
-
return
|
|
8750
|
+
return c`
|
|
8751
8751
|
<div
|
|
8752
8752
|
${ne(t)}
|
|
8753
8753
|
class=${A("moz-tooltip", s.class)}
|
|
@@ -8767,7 +8767,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8767
8767
|
})}
|
|
8768
8768
|
${pe(r)}
|
|
8769
8769
|
>
|
|
8770
|
-
${s.arrow ?
|
|
8770
|
+
${s.arrow ? c`<span
|
|
8771
8771
|
class="moz-tooltip-arrow"
|
|
8772
8772
|
data-side=${m}
|
|
8773
8773
|
style=${oe({ [p]: `${(o == null ? void 0 : o.arrowOffset) ?? 0}px` })}
|
|
@@ -8820,7 +8820,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8820
8820
|
},
|
|
8821
8821
|
setup(e) {
|
|
8822
8822
|
const t = ve();
|
|
8823
|
-
let o = null, l = null, n = !1, i = !1, h = null,
|
|
8823
|
+
let o = null, l = null, n = !1, i = !1, h = null, d = null;
|
|
8824
8824
|
const s = () => !!e.props.open && !!e.props.anchor, m = () => {
|
|
8825
8825
|
const E = t.value;
|
|
8826
8826
|
return E ? Array.from(E.querySelectorAll(Rn)).filter(
|
|
@@ -8861,7 +8861,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8861
8861
|
const X = z[0], W = z[z.length - 1], te = document.activeElement;
|
|
8862
8862
|
E.shiftKey && (te === X || te === t.value) ? (E.preventDefault(), W.focus()) : !E.shiftKey && te === W && (E.preventDefault(), X.focus());
|
|
8863
8863
|
}, S = () => {
|
|
8864
|
-
|
|
8864
|
+
d = document.activeElement ?? null, h = Co(v), document.addEventListener("pointerdown", $, !0), vo(() => {
|
|
8865
8865
|
var z;
|
|
8866
8866
|
if (!s()) return;
|
|
8867
8867
|
const E = p("moz.openAutoFocus");
|
|
@@ -8872,8 +8872,8 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8872
8872
|
h == null || h.release(), h = null, document.removeEventListener("pointerdown", $, !0), o = null, l = null, n = !1;
|
|
8873
8873
|
const E = p("moz.closeAutoFocus");
|
|
8874
8874
|
e.emit("closeAutoFocus", E);
|
|
8875
|
-
const z =
|
|
8876
|
-
|
|
8875
|
+
const z = d ?? e.props.anchor;
|
|
8876
|
+
d = null, E.defaultPrevented || (X = z == null ? void 0 : z.focus) == null || X.call(z);
|
|
8877
8877
|
}, q = () => {
|
|
8878
8878
|
s() && r();
|
|
8879
8879
|
};
|
|
@@ -8889,7 +8889,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8889
8889
|
if (z !== i && (i = z, z ? S() : y()), !z) return b;
|
|
8890
8890
|
vo(r);
|
|
8891
8891
|
const X = (o == null ? void 0 : o.side) ?? E.side ?? "bottom", W = we(E, In), te = ((re = E.anchor) == null ? void 0 : re.offsetWidth) ?? 0;
|
|
8892
|
-
return
|
|
8892
|
+
return c`
|
|
8893
8893
|
<div
|
|
8894
8894
|
${ne(t)}
|
|
8895
8895
|
class=${A("moz-popover", E.class)}
|
|
@@ -8966,14 +8966,14 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8966
8966
|
setup(e) {
|
|
8967
8967
|
let t = null, o = null, l = -1;
|
|
8968
8968
|
const n = () => {
|
|
8969
|
-
const
|
|
8970
|
-
if (!
|
|
8971
|
-
const s =
|
|
8972
|
-
|
|
8969
|
+
const d = t;
|
|
8970
|
+
if (!d) return;
|
|
8971
|
+
const s = d.scrollHeight;
|
|
8972
|
+
d.style.setProperty(On, `${s}px`), s !== l && (l = s, e.emit("heightChange", s));
|
|
8973
8973
|
}, i = () => {
|
|
8974
8974
|
o == null || o.disconnect(), o = null;
|
|
8975
|
-
}, h = (
|
|
8976
|
-
if (t =
|
|
8975
|
+
}, h = (d) => {
|
|
8976
|
+
if (t = d ?? null, !t) {
|
|
8977
8977
|
i(), l = -1;
|
|
8978
8978
|
return;
|
|
8979
8979
|
}
|
|
@@ -8981,17 +8981,17 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
8981
8981
|
};
|
|
8982
8982
|
return e.onCleanup(i), {
|
|
8983
8983
|
render() {
|
|
8984
|
-
const
|
|
8985
|
-
if (!s && !
|
|
8986
|
-
const m = we(
|
|
8987
|
-
return
|
|
8984
|
+
const d = e.props, s = !!d.open;
|
|
8985
|
+
if (!s && !d.forceMount) return b;
|
|
8986
|
+
const m = we(d, Hn);
|
|
8987
|
+
return c`<div
|
|
8988
8988
|
${ne(h)}
|
|
8989
|
-
class=${A("moz-collapsible-content",
|
|
8990
|
-
id=${Te(
|
|
8989
|
+
class=${A("moz-collapsible-content", d.class)}
|
|
8990
|
+
id=${Te(d.contentId)}
|
|
8991
8991
|
data-state=${s ? "open" : "closed"}
|
|
8992
|
-
data-disabled=${
|
|
8992
|
+
data-disabled=${d.disabled ? "" : b}
|
|
8993
8993
|
?hidden=${!s}
|
|
8994
|
-
style=${oe(Pe(
|
|
8994
|
+
style=${oe(Pe(d.style))}
|
|
8995
8995
|
${pe(m)}
|
|
8996
8996
|
>
|
|
8997
8997
|
${e.slot("content")}
|
|
@@ -9015,7 +9015,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9015
9015
|
let t = "idle", o, l = !0, n, i;
|
|
9016
9016
|
const h = (r) => {
|
|
9017
9017
|
t !== r && (t = r, e.emit("loadingStatusChange", r), e.requestUpdate());
|
|
9018
|
-
},
|
|
9018
|
+
}, d = () => {
|
|
9019
9019
|
i && (i.onload = null, i.onerror = null, i = void 0);
|
|
9020
9020
|
}, s = (r) => {
|
|
9021
9021
|
if (n !== void 0 && clearTimeout(n), n = void 0, !r || r <= 0) {
|
|
@@ -9028,7 +9028,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9028
9028
|
}, m = () => {
|
|
9029
9029
|
const r = e.props.src;
|
|
9030
9030
|
if (r === o) return;
|
|
9031
|
-
if (o = r,
|
|
9031
|
+
if (o = r, d(), s(e.props.delayMs), !r) {
|
|
9032
9032
|
h("idle");
|
|
9033
9033
|
return;
|
|
9034
9034
|
}
|
|
@@ -9041,23 +9041,23 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9041
9041
|
}, p.src = r;
|
|
9042
9042
|
};
|
|
9043
9043
|
return e.onCleanup(() => {
|
|
9044
|
-
|
|
9044
|
+
d(), n !== void 0 && clearTimeout(n);
|
|
9045
9045
|
}), {
|
|
9046
9046
|
render() {
|
|
9047
9047
|
m();
|
|
9048
9048
|
const r = e.props, p = we(r, Un), u = t === "loaded", v = !u && l;
|
|
9049
|
-
return
|
|
9049
|
+
return c`<span
|
|
9050
9050
|
class=${A("moz-avatar", r.class)}
|
|
9051
9051
|
data-status=${t}
|
|
9052
9052
|
style=${oe(Pe(r.style))}
|
|
9053
9053
|
${pe(p)}
|
|
9054
9054
|
>
|
|
9055
|
-
${u ?
|
|
9055
|
+
${u ? c`<img
|
|
9056
9056
|
class=${A("moz-avatar-image", r.imageClass)}
|
|
9057
9057
|
src=${Te(r.src)}
|
|
9058
9058
|
alt=${Te(r.alt)}
|
|
9059
9059
|
/>` : b}
|
|
9060
|
-
${v ?
|
|
9060
|
+
${v ? c`<span class=${A("moz-avatar-fallback", r.fallbackClass)}>${e.slot("fallback")}</span>` : b}
|
|
9061
9061
|
</span>`;
|
|
9062
9062
|
},
|
|
9063
9063
|
api: {
|
|
@@ -9078,7 +9078,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9078
9078
|
name: "moz-scroll-area",
|
|
9079
9079
|
defaults: { orientation: "vertical", scrollbarVisibility: "always" },
|
|
9080
9080
|
setup(e) {
|
|
9081
|
-
let t = null, o = null, l = null, n = null, i = null, h = !1,
|
|
9081
|
+
let t = null, o = null, l = null, n = null, i = null, h = !1, d = !1, s = null, m = null, r = null, p = null, u = null, v = !1, $ = !1, F = null, S = null;
|
|
9082
9082
|
const y = (k) => !!k && "nodeType" in k && (!!(r != null && r.contains(k)) || !!(p != null && p.contains(k))), q = () => y((r == null ? void 0 : r.ownerDocument.activeElement) ?? null), E = () => {
|
|
9083
9083
|
const k = q();
|
|
9084
9084
|
k !== $ && ($ = k, e.requestUpdate());
|
|
@@ -9118,7 +9118,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9118
9118
|
return V ? (Y.style.height = `${qe}px`, Y.style.transform = `translateY(${L}px)`) : (Y.style.width = `${qe}px`, Y.style.transform = `translateX(${L}px)`), !0;
|
|
9119
9119
|
}, ie = () => {
|
|
9120
9120
|
const k = se("vertical"), T = se("horizontal");
|
|
9121
|
-
k === h && T ===
|
|
9121
|
+
k === h && T === d || (h = k, d = T, e.requestUpdate());
|
|
9122
9122
|
}, Q = () => {
|
|
9123
9123
|
const k = t;
|
|
9124
9124
|
k && (ie(), e.emit("scroll", { scrollTop: k.scrollTop, scrollLeft: k.scrollLeft }));
|
|
@@ -9178,7 +9178,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9178
9178
|
}, f = (H) => {
|
|
9179
9179
|
V ? o = H ?? null : l = H ?? null, H && ie();
|
|
9180
9180
|
};
|
|
9181
|
-
return
|
|
9181
|
+
return c`<div
|
|
9182
9182
|
class=${A("moz-scroll-area-scrollbar", e.props.scrollbarClass)}
|
|
9183
9183
|
data-orientation=${k}
|
|
9184
9184
|
?hidden=${!T}
|
|
@@ -9195,7 +9195,7 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9195
9195
|
render() {
|
|
9196
9196
|
x(), D();
|
|
9197
9197
|
const k = e.props, T = we(k, Wn), V = G("vertical") && G("horizontal");
|
|
9198
|
-
return
|
|
9198
|
+
return c`<div
|
|
9199
9199
|
class=${A("moz-scroll-area-bars", k.class)}
|
|
9200
9200
|
data-orientation=${k.orientation ?? "vertical"}
|
|
9201
9201
|
data-state=${k.scrollbarVisibility !== "hover" || v || $ || F ? "visible" : "hidden"}
|
|
@@ -9208,8 +9208,8 @@ const Vn = Oo, An = /* @__PURE__ */ new Set([
|
|
|
9208
9208
|
${pe(T)}
|
|
9209
9209
|
>
|
|
9210
9210
|
${G("vertical") ? _("vertical", h) : b}
|
|
9211
|
-
${G("horizontal") ? _("horizontal",
|
|
9212
|
-
${V && h &&
|
|
9211
|
+
${G("horizontal") ? _("horizontal", d) : b}
|
|
9212
|
+
${V && h && d ? c`<div class="moz-scroll-area-corner"></div>` : b}
|
|
9213
9213
|
</div>`;
|
|
9214
9214
|
}
|
|
9215
9215
|
};
|
|
@@ -9234,13 +9234,13 @@ const Qn = be({
|
|
|
9234
9234
|
return {
|
|
9235
9235
|
render() {
|
|
9236
9236
|
const t = e.props, o = we(t, Xn), l = Bt(Yn, t.tone, "neutral"), n = Bt(Zn, t.appearance, "soft"), i = Bt(jn, t.size, "md"), h = e.slots.has("default") ? e.slot("default") : t.text ?? b;
|
|
9237
|
-
return
|
|
9237
|
+
return c`<span
|
|
9238
9238
|
class=${A("moz-badge", `size-${i}`, t.class)}
|
|
9239
9239
|
data-tone=${l}
|
|
9240
9240
|
data-appearance=${n}
|
|
9241
9241
|
style=${oe(Pe(t.style))}
|
|
9242
9242
|
${pe(o)}
|
|
9243
|
-
>${t.dot ?
|
|
9243
|
+
>${t.dot ? c`<span class="moz-badge-dot"></span>` : b}${h}</span
|
|
9244
9244
|
>`;
|
|
9245
9245
|
}
|
|
9246
9246
|
};
|
|
@@ -9262,6 +9262,7 @@ const Qn = be({
|
|
|
9262
9262
|
"selected",
|
|
9263
9263
|
"disabled",
|
|
9264
9264
|
"removable",
|
|
9265
|
+
"labelInteractive",
|
|
9265
9266
|
"removeLabel",
|
|
9266
9267
|
"text",
|
|
9267
9268
|
"class",
|
|
@@ -9272,7 +9273,15 @@ function Ht(e, t, o) {
|
|
|
9272
9273
|
}
|
|
9273
9274
|
const sr = be({
|
|
9274
9275
|
name: "moz-chip",
|
|
9275
|
-
defaults: {
|
|
9276
|
+
defaults: {
|
|
9277
|
+
tone: "accent",
|
|
9278
|
+
appearance: "outline",
|
|
9279
|
+
size: "md",
|
|
9280
|
+
selected: !1,
|
|
9281
|
+
disabled: !1,
|
|
9282
|
+
removable: !1,
|
|
9283
|
+
labelInteractive: !0
|
|
9284
|
+
},
|
|
9276
9285
|
setup(e) {
|
|
9277
9286
|
const t = (l) => {
|
|
9278
9287
|
e.props.disabled || e.emit("click", l);
|
|
@@ -9281,17 +9290,18 @@ const sr = be({
|
|
|
9281
9290
|
};
|
|
9282
9291
|
return {
|
|
9283
9292
|
render() {
|
|
9284
|
-
const l = e.props, n = we(l, or), i = Ht(Jn, l.tone, "accent"), h = Ht(er, l.appearance, "outline"),
|
|
9285
|
-
if (l.removable)
|
|
9286
|
-
|
|
9287
|
-
|
|
9293
|
+
const l = e.props, n = we(l, or), i = Ht(Jn, l.tone, "accent"), h = Ht(er, l.appearance, "outline"), d = Ht(tr, l.size, "md"), s = !!l.disabled, m = e.slots.has("icon") ? c`<span class="moz-chip-icon">${e.slot("icon")}</span>` : b, r = e.slots.has("default") ? e.slot("default") : l.text ?? b;
|
|
9294
|
+
if (l.removable) {
|
|
9295
|
+
const v = l.labelInteractive !== !1 ? c`<button type="button" class="moz-chip-label" ?disabled=${s} @click=${t}
|
|
9296
|
+
>${m}${r}</button
|
|
9297
|
+
>` : c`<span class="moz-chip-label">${m}${r}</span>`;
|
|
9298
|
+
return c`<span
|
|
9299
|
+
class=${A("moz-chip", "removable", `size-${d}`, { disabled: s }, l.class)}
|
|
9288
9300
|
data-tone=${i}
|
|
9289
9301
|
data-appearance=${h}
|
|
9290
9302
|
style=${oe(Pe(l.style))}
|
|
9291
9303
|
${pe(n)}
|
|
9292
|
-
|
|
9293
|
-
>${m}${r}</button
|
|
9294
|
-
><button
|
|
9304
|
+
>${v}<button
|
|
9295
9305
|
type="button"
|
|
9296
9306
|
class="moz-chip-remove"
|
|
9297
9307
|
aria-label=${l.removeLabel || e.locale.Chip.remove}
|
|
@@ -9300,10 +9310,11 @@ const sr = be({
|
|
|
9300
9310
|
>${Ut("currentColor")}</button
|
|
9301
9311
|
></span
|
|
9302
9312
|
>`;
|
|
9313
|
+
}
|
|
9303
9314
|
const p = !!l.selected;
|
|
9304
|
-
return
|
|
9315
|
+
return c`<button
|
|
9305
9316
|
type="button"
|
|
9306
|
-
class=${A("moz-chip", `size-${
|
|
9317
|
+
class=${A("moz-chip", `size-${d}`, { "is-selected": p, disabled: s }, l.class)}
|
|
9307
9318
|
data-tone=${i}
|
|
9308
9319
|
data-appearance=${h}
|
|
9309
9320
|
aria-pressed=${p ? "true" : "false"}
|
|
@@ -9319,7 +9330,7 @@ const sr = be({
|
|
|
9319
9330
|
}), ui = {
|
|
9320
9331
|
name: "MozChip",
|
|
9321
9332
|
core: sr,
|
|
9322
|
-
props: ["tone", "appearance", "size", "selected", "disabled", "removable", "removeLabel", "text"],
|
|
9333
|
+
props: ["tone", "appearance", "size", "selected", "disabled", "removable", "labelInteractive", "removeLabel", "text"],
|
|
9323
9334
|
emits: ["click", "remove"],
|
|
9324
9335
|
slots: ["icon", "default"],
|
|
9325
9336
|
expose: !1,
|