@wwtdev/bsds-components-vue3 2.1.3 → 2.1.5
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/lib/bsds-components.js +1644 -1112
- package/lib/components.css +1 -1
- package/package.json +2 -2
package/lib/bsds-components.js
CHANGED
|
@@ -1,132 +1,132 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
import { v4 as
|
|
3
|
-
import { BsIconCaretDown as
|
|
4
|
-
import { Chart as
|
|
5
|
-
const
|
|
1
|
+
import { computed as g, ref as I, onMounted as F, onUnmounted as _, shallowRef as Ze, watch as z, defineAsyncComponent as me, openBlock as s, createElementBlock as v, unref as f, createElementVNode as $, renderSlot as L, createBlock as O, resolveDynamicComponent as H, createCommentVNode as w, toDisplayString as A, createVNode as D, normalizeClass as Q, useAttrs as U, mergeProps as M, withCtx as P, Fragment as R, renderList as G, createTextVNode as W, withDirectives as ye, Transition as Ie, vShow as Be, provide as ee, inject as te, nextTick as oe, Teleport as Je, onBeforeMount as Qe, isRef as _e, useSlots as et } from "vue";
|
|
2
|
+
import { v4 as tt } from "uuid";
|
|
3
|
+
import { BsIconCaretDown as Ve, BsIconWarning as ge, BsIconClose as de, BsIconSearch as at, BsIconCaretLeftDouble as nt, BsIconCaretLeft as lt, BsIconCaretRight as ot, BsIconCaretRightDouble as it, BsIconActionEllipsis as rt, BsIconCircleExclamation as st, BsIconThumbsUpStroke as dt } from "@wwtdev/bsds-icons-vue3";
|
|
4
|
+
import { Chart as be, BarController as ut, BarElement as ct, CategoryScale as ft, LinearScale as vt, Legend as pt, Tooltip as ht } from "chart.js";
|
|
5
|
+
const Te = {
|
|
6
6
|
href: "a",
|
|
7
7
|
linkTo: "a",
|
|
8
8
|
onclick: "button",
|
|
9
9
|
onClick: "button",
|
|
10
10
|
type: "button"
|
|
11
11
|
};
|
|
12
|
-
function
|
|
13
|
-
const
|
|
14
|
-
const i =
|
|
15
|
-
return i ? (
|
|
16
|
-
}), o =
|
|
17
|
-
const i = { ...a, ...
|
|
12
|
+
function ue(e, a, t = "button") {
|
|
13
|
+
const l = bt(e, a, t), n = g(() => {
|
|
14
|
+
const i = l.value === "button", r = {};
|
|
15
|
+
return i ? (r.type = a.type || "button", r.autocomplete = "off", e.disabled && (r.disabled = !0)) : e.disabled && (r["aria-disabled"] = "true", r.tabindex = "-1"), r;
|
|
16
|
+
}), o = g(() => {
|
|
17
|
+
const i = { ...a, ...n.value };
|
|
18
18
|
return delete i.href, i;
|
|
19
|
-
}), u =
|
|
20
|
-
return { rootTag:
|
|
19
|
+
}), u = g(() => e.linkTo || e.href);
|
|
20
|
+
return { rootTag: l, attrsToBind: o, hrefUrl: u };
|
|
21
21
|
}
|
|
22
|
-
function
|
|
23
|
-
const
|
|
24
|
-
return I(
|
|
22
|
+
function bt(e, a, t) {
|
|
23
|
+
const l = Object.keys(Te).find((n) => gt(e, a, n));
|
|
24
|
+
return I(Te[l] || t);
|
|
25
25
|
}
|
|
26
|
-
function
|
|
26
|
+
function gt(e, a, t) {
|
|
27
27
|
return e[t] || a[t];
|
|
28
28
|
}
|
|
29
|
-
const
|
|
30
|
-
const t = (
|
|
31
|
-
e.some((
|
|
29
|
+
const mt = (e, a) => {
|
|
30
|
+
const t = (l) => {
|
|
31
|
+
e.some((n) => {
|
|
32
32
|
var o;
|
|
33
|
-
return (o =
|
|
34
|
-
}) || a(
|
|
33
|
+
return (o = n.value) == null ? void 0 : o.contains(l.target);
|
|
34
|
+
}) || a(l);
|
|
35
35
|
};
|
|
36
|
-
|
|
36
|
+
F(() => {
|
|
37
37
|
document.addEventListener("click", t);
|
|
38
|
-
}),
|
|
38
|
+
}), _(() => {
|
|
39
39
|
document.removeEventListener("click", t);
|
|
40
40
|
});
|
|
41
41
|
};
|
|
42
|
-
function
|
|
43
|
-
const a =
|
|
42
|
+
function ce(e) {
|
|
43
|
+
const a = g(() => e.linkTo || e.href || ""), t = g(() => {
|
|
44
44
|
var o, u;
|
|
45
45
|
return ((u = (o = a.value) == null ? void 0 : o.startsWith) == null ? void 0 : u.call(o, "/")) || !1;
|
|
46
|
-
}),
|
|
46
|
+
}), l = g(() => {
|
|
47
47
|
var o, u;
|
|
48
48
|
return t.value && ((o = e.router) == null ? void 0 : o.navigateTo) || ((u = e.router) == null ? void 0 : u.push) || null;
|
|
49
49
|
});
|
|
50
|
-
function
|
|
50
|
+
function n(o) {
|
|
51
51
|
if (e.disabled) {
|
|
52
52
|
o.preventDefault(), o.stopImmediatePropagation();
|
|
53
53
|
return;
|
|
54
54
|
}
|
|
55
|
-
if (!a.value || !
|
|
55
|
+
if (!a.value || !l.value)
|
|
56
56
|
return;
|
|
57
|
-
o.target.closest("a").href === `${window.location.origin}${a.value}` && (o.preventDefault(),
|
|
57
|
+
o.target.closest("a").href === `${window.location.origin}${a.value}` && (o.preventDefault(), l.value(a.value));
|
|
58
58
|
}
|
|
59
|
-
return { onLinkClick:
|
|
59
|
+
return { onLinkClick: n };
|
|
60
60
|
}
|
|
61
|
-
function
|
|
62
|
-
return e.split("-").map((
|
|
61
|
+
function xe(e) {
|
|
62
|
+
return e.split("-").map((l) => l.charAt(0).toUpperCase() + l.slice(1)).join("");
|
|
63
63
|
}
|
|
64
|
-
const
|
|
65
|
-
function t(
|
|
66
|
-
if (!
|
|
64
|
+
const se = (e, a) => {
|
|
65
|
+
function t(n) {
|
|
66
|
+
if (!n)
|
|
67
67
|
return null;
|
|
68
|
-
const o =
|
|
69
|
-
return
|
|
68
|
+
const o = n.startsWith("bs-") ? xe(n) : `BsIcon${xe(n)}`;
|
|
69
|
+
return me(async () => {
|
|
70
70
|
const { [o]: u } = await import("@wwtdev/bsds-icons-vue3");
|
|
71
71
|
return u;
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
|
-
const
|
|
75
|
-
return
|
|
74
|
+
const l = Ze();
|
|
75
|
+
return l.value = t(e[a]), z(() => e[a], async (n) => l.value = t(n)), { icon: l };
|
|
76
76
|
};
|
|
77
|
-
function
|
|
77
|
+
function K(e = 1) {
|
|
78
78
|
const a = [];
|
|
79
79
|
for (let t = 0; t < e; t++)
|
|
80
80
|
a.push(I(""));
|
|
81
|
-
return
|
|
82
|
-
a.forEach((t) => t.value =
|
|
81
|
+
return F(() => {
|
|
82
|
+
a.forEach((t) => t.value = `id-${tt()}`);
|
|
83
83
|
}), a;
|
|
84
84
|
}
|
|
85
|
-
const
|
|
86
|
-
const
|
|
87
|
-
e.includes(
|
|
85
|
+
const fe = (e, a, t = void 0) => {
|
|
86
|
+
const l = (n) => {
|
|
87
|
+
e.includes(n.key) && a(n);
|
|
88
88
|
};
|
|
89
|
-
|
|
90
|
-
((t == null ? void 0 : t.value) ?? document).addEventListener("keydown",
|
|
91
|
-
}),
|
|
92
|
-
((t == null ? void 0 : t.value) ?? document).removeEventListener("keydown",
|
|
89
|
+
F(() => {
|
|
90
|
+
((t == null ? void 0 : t.value) ?? document).addEventListener("keydown", l);
|
|
91
|
+
}), _(() => {
|
|
92
|
+
((t == null ? void 0 : t.value) ?? document).removeEventListener("keydown", l);
|
|
93
93
|
});
|
|
94
|
-
},
|
|
95
|
-
let
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}),
|
|
99
|
-
|
|
94
|
+
}, yt = (e, a, t) => {
|
|
95
|
+
let l = null;
|
|
96
|
+
F(() => {
|
|
97
|
+
l = new MutationObserver(a), l.observe(e.value, t);
|
|
98
|
+
}), _(() => {
|
|
99
|
+
l.disconnect();
|
|
100
100
|
});
|
|
101
101
|
};
|
|
102
|
-
function
|
|
103
|
-
var i,
|
|
104
|
-
const
|
|
105
|
-
|
|
102
|
+
function ae(e, a, t = []) {
|
|
103
|
+
var i, r;
|
|
104
|
+
const l = ((r = (i = e.passAttrs) == null ? void 0 : i.split) == null ? void 0 : r.call(i, ",")) || [], n = /* @__PURE__ */ new Set([...l, ...t]);
|
|
105
|
+
n.delete("");
|
|
106
106
|
const o = I({}), u = I({});
|
|
107
|
-
for (let
|
|
108
|
-
|
|
107
|
+
for (let d in a)
|
|
108
|
+
n.has(d) ? u.value[d] = a[d] : o.value[d] = a[d];
|
|
109
109
|
return {
|
|
110
110
|
toRoot: o,
|
|
111
111
|
toChild: u
|
|
112
112
|
};
|
|
113
113
|
}
|
|
114
|
-
const
|
|
114
|
+
const ve = (e) => {
|
|
115
115
|
const a = I(!1);
|
|
116
|
-
return
|
|
116
|
+
return F(() => {
|
|
117
117
|
a.value = e.enterControlled || e.preloaded ? e.enterTrigger : e.shown;
|
|
118
|
-
}),
|
|
118
|
+
}), z(() => e.shown, (t) => {
|
|
119
119
|
a.value = t;
|
|
120
|
-
}),
|
|
120
|
+
}), z(() => e.enterTrigger, (t) => {
|
|
121
121
|
a.value = t;
|
|
122
|
-
}),
|
|
122
|
+
}), z(() => e.leaveTrigger, (t) => {
|
|
123
123
|
t && (a.value = !1);
|
|
124
124
|
}), { transition: a };
|
|
125
|
-
},
|
|
125
|
+
}, Bt = ["id", "data-stacked"], $t = ["data-open"], St = ["aria-controls", "aria-expanded"], wt = {
|
|
126
126
|
key: 0,
|
|
127
127
|
"data-position": "start",
|
|
128
128
|
style: { display: "inline-flex" }
|
|
129
|
-
},
|
|
129
|
+
}, kt = ["id", "aria-level"], It = ["aria-labelledby", "data-open", "id"], Xn = {
|
|
130
130
|
__name: "BsAccordion",
|
|
131
131
|
props: {
|
|
132
132
|
controlled: { type: Boolean, default: !1 },
|
|
@@ -142,59 +142,59 @@ const de = (e) => {
|
|
|
142
142
|
},
|
|
143
143
|
emits: ["toggled"],
|
|
144
144
|
setup(e, { emit: a }) {
|
|
145
|
-
const t = e,
|
|
146
|
-
function
|
|
147
|
-
|
|
145
|
+
const t = e, l = a, n = I(null), o = I(!1), { icon: u } = se(t, "icon"), [i] = K(), r = g(() => i.value + "-content"), d = g(() => i.value + "-title"), c = g(() => t.openItemId && t.openItemId === i.value || t.openItem === !0), p = g(() => t.controlled ? c.value : o.value);
|
|
146
|
+
function h() {
|
|
147
|
+
l("toggled", i.value), t.controlled || (o.value = !o.value);
|
|
148
148
|
}
|
|
149
|
-
return (
|
|
150
|
-
id:
|
|
149
|
+
return (m, V) => (s(), v("div", {
|
|
150
|
+
id: f(i),
|
|
151
151
|
ref_key: "containerRef",
|
|
152
|
-
ref:
|
|
152
|
+
ref: n,
|
|
153
153
|
class: "bs-accordion",
|
|
154
154
|
"data-component": "bs-accordion",
|
|
155
155
|
"data-stacked": e.stacked
|
|
156
156
|
}, [
|
|
157
|
-
|
|
157
|
+
$("header", {
|
|
158
158
|
part: "header",
|
|
159
|
-
"data-open":
|
|
159
|
+
"data-open": p.value
|
|
160
160
|
}, [
|
|
161
|
-
|
|
162
|
-
"aria-controls":
|
|
163
|
-
"aria-expanded":
|
|
161
|
+
$("button", {
|
|
162
|
+
"aria-controls": r.value,
|
|
163
|
+
"aria-expanded": p.value,
|
|
164
164
|
type: "button",
|
|
165
|
-
onClick:
|
|
165
|
+
onClick: h
|
|
166
166
|
}, [
|
|
167
|
-
e.icon ||
|
|
168
|
-
|
|
169
|
-
e.icon ? (
|
|
167
|
+
e.icon || m.$slots.icon ? (s(), v("span", wt, [
|
|
168
|
+
L(m.$slots, "icon", {}, () => [
|
|
169
|
+
e.icon ? (s(), O(H(f(u) ? f(u) : "span"), { key: 0 })) : w("", !0)
|
|
170
170
|
])
|
|
171
|
-
])) :
|
|
172
|
-
|
|
173
|
-
id:
|
|
171
|
+
])) : w("", !0),
|
|
172
|
+
$("span", {
|
|
173
|
+
id: d.value,
|
|
174
174
|
"aria-level": e.headingLevel,
|
|
175
175
|
role: "heading"
|
|
176
|
-
},
|
|
177
|
-
|
|
176
|
+
}, A(e.headerText), 9, kt),
|
|
177
|
+
D(f(Ve), {
|
|
178
178
|
size: "md",
|
|
179
179
|
"data-position": "end"
|
|
180
180
|
})
|
|
181
|
-
], 8,
|
|
182
|
-
], 8,
|
|
183
|
-
|
|
184
|
-
"aria-labelledby":
|
|
181
|
+
], 8, St)
|
|
182
|
+
], 8, $t),
|
|
183
|
+
$("div", {
|
|
184
|
+
"aria-labelledby": d.value,
|
|
185
185
|
class: "bs-accordion-content",
|
|
186
|
-
"data-open":
|
|
187
|
-
id:
|
|
186
|
+
"data-open": p.value,
|
|
187
|
+
id: r.value,
|
|
188
188
|
part: "content",
|
|
189
189
|
role: "region"
|
|
190
190
|
}, [
|
|
191
|
-
|
|
192
|
-
|
|
191
|
+
$("div", null, [
|
|
192
|
+
L(m.$slots, "default")
|
|
193
193
|
])
|
|
194
|
-
], 8,
|
|
195
|
-
], 8,
|
|
194
|
+
], 8, It)
|
|
195
|
+
], 8, Bt));
|
|
196
196
|
}
|
|
197
|
-
},
|
|
197
|
+
}, Tt = ["data-badge-color", "data-count", "data-position", "data-show-zero", "data-variant", "aria-label"], xt = {
|
|
198
198
|
__name: "BsBadge",
|
|
199
199
|
props: {
|
|
200
200
|
/** Pass value to set `data-badge-color`. */
|
|
@@ -241,60 +241,60 @@ const de = (e) => {
|
|
|
241
241
|
}
|
|
242
242
|
},
|
|
243
243
|
setup(e) {
|
|
244
|
-
const a = e, t = I(null),
|
|
245
|
-
var
|
|
246
|
-
const o = ((
|
|
244
|
+
const a = e, t = I(null), l = g(() => a.count === 0 ? "0" : !a.count || a.dot ? null : a.count > a.countMax ? a.countMax + "+" : a.count.toString()), n = g(() => {
|
|
245
|
+
var r, d;
|
|
246
|
+
const o = ((d = (r = t.value) == null ? void 0 : r.textContent) == null ? void 0 : d.trim()) || "", u = l.value ? l.value + " " : "";
|
|
247
247
|
if (!u && !a.dot)
|
|
248
248
|
return o;
|
|
249
249
|
const i = a.count !== 1 ? "s" : "";
|
|
250
250
|
return `${o ? `${o}, ` : ""}${u}${a.label}${i}`;
|
|
251
251
|
});
|
|
252
|
-
return (o, u) => (
|
|
252
|
+
return (o, u) => (s(), v("span", {
|
|
253
253
|
ref_key: "hostRef",
|
|
254
254
|
ref: t,
|
|
255
|
-
class:
|
|
255
|
+
class: Q({ "bs-badge": e.dot || l.value }),
|
|
256
256
|
"data-badge-color": e.color,
|
|
257
257
|
"data-component": "bs-badge",
|
|
258
|
-
"data-count":
|
|
258
|
+
"data-count": l.value,
|
|
259
259
|
"data-position": e.position,
|
|
260
260
|
"data-show-zero": e.showZero,
|
|
261
261
|
"data-variant": e.variant,
|
|
262
|
-
"aria-label":
|
|
262
|
+
"aria-label": n.value
|
|
263
263
|
}, [
|
|
264
|
-
e.variant !== "notext" ?
|
|
265
|
-
], 10,
|
|
264
|
+
e.variant !== "notext" ? L(o.$slots, "default", { key: 0 }) : w("", !0)
|
|
265
|
+
], 10, Tt));
|
|
266
266
|
}
|
|
267
|
-
},
|
|
267
|
+
}, Ct = {
|
|
268
268
|
key: 0,
|
|
269
269
|
role: "alert",
|
|
270
270
|
class: "bs-banner"
|
|
271
|
-
},
|
|
271
|
+
}, At = { class: "bs-banner-content" }, Lt = { class: "bs-banner-warning-icon" }, Zn = {
|
|
272
272
|
__name: "BsBanner",
|
|
273
273
|
emits: ["dismiss"],
|
|
274
274
|
setup(e, { emit: a }) {
|
|
275
|
-
const t = a,
|
|
276
|
-
function
|
|
277
|
-
|
|
278
|
-
}
|
|
279
|
-
return (o, u) =>
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
275
|
+
const t = a, l = I(!1);
|
|
276
|
+
function n() {
|
|
277
|
+
l.value = !0, t("dismiss");
|
|
278
|
+
}
|
|
279
|
+
return (o, u) => l.value ? w("", !0) : (s(), v("div", Ct, [
|
|
280
|
+
$("div", At, [
|
|
281
|
+
$("div", Lt, [
|
|
282
|
+
D(f(ge), { size: "lg" })
|
|
283
283
|
]),
|
|
284
|
-
|
|
285
|
-
|
|
284
|
+
$("p", null, [
|
|
285
|
+
L(o.$slots, "default")
|
|
286
286
|
]),
|
|
287
|
-
|
|
287
|
+
$("button", {
|
|
288
288
|
type: "button",
|
|
289
289
|
title: "Close Banner",
|
|
290
|
-
onClick:
|
|
290
|
+
onClick: n
|
|
291
291
|
}, [
|
|
292
|
-
|
|
292
|
+
D(f(de))
|
|
293
293
|
])
|
|
294
294
|
])
|
|
295
295
|
]));
|
|
296
296
|
}
|
|
297
|
-
},
|
|
297
|
+
}, Vt = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
298
298
|
__name: "BsButton",
|
|
299
299
|
props: {
|
|
300
300
|
variant: { type: String },
|
|
@@ -308,23 +308,23 @@ const de = (e) => {
|
|
|
308
308
|
size: { type: String, validator: (e) => ["sm", "xs", "xxs"].includes(e) }
|
|
309
309
|
},
|
|
310
310
|
setup(e) {
|
|
311
|
-
const a = e, t =
|
|
312
|
-
return (i,
|
|
311
|
+
const a = e, t = U(), { rootTag: l, attrsToBind: n, hrefUrl: o } = ue(a, t), { onLinkClick: u } = ce(a);
|
|
312
|
+
return (i, r) => (s(), O(H(f(l)), M({
|
|
313
313
|
class: "bs-button",
|
|
314
314
|
"data-component": "bs-button",
|
|
315
315
|
"data-ghost": e.ghostBtn,
|
|
316
316
|
"data-size": e.size,
|
|
317
317
|
"data-text": e.textBtn,
|
|
318
318
|
"data-variant": e.variant,
|
|
319
|
-
".href":
|
|
320
|
-
},
|
|
321
|
-
default:
|
|
322
|
-
|
|
319
|
+
".href": f(o)
|
|
320
|
+
}, f(n), { onClick: f(u) }), {
|
|
321
|
+
default: P(() => [
|
|
322
|
+
L(i.$slots, "default")
|
|
323
323
|
]),
|
|
324
324
|
_: 3
|
|
325
325
|
}, 48, ["data-ghost", "data-size", "data-text", "data-variant", ".href", "onClick"]));
|
|
326
326
|
}
|
|
327
|
-
}),
|
|
327
|
+
}), Et = { "data-component": "bs-chart-table" }, Pt = ["summary"], Ot = ["colspan"], Dt = /* @__PURE__ */ $("th", { scope: "col" }, " Dataset ", -1), qt = { scope: "row" }, Mt = {
|
|
328
328
|
__name: "BsChartTable",
|
|
329
329
|
props: {
|
|
330
330
|
data: {
|
|
@@ -342,53 +342,53 @@ const de = (e) => {
|
|
|
342
342
|
},
|
|
343
343
|
setup(e) {
|
|
344
344
|
return (a, t) => {
|
|
345
|
-
var
|
|
346
|
-
return
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
colspan: ((
|
|
352
|
-
},
|
|
345
|
+
var l;
|
|
346
|
+
return s(), v("div", Et, [
|
|
347
|
+
$("table", { summary: e.tableTitle }, [
|
|
348
|
+
$("thead", null, [
|
|
349
|
+
$("tr", null, [
|
|
350
|
+
$("th", {
|
|
351
|
+
colspan: ((l = e.dataIdxLabels) == null ? void 0 : l.length) + 1
|
|
352
|
+
}, A(e.tableTitle), 9, Ot)
|
|
353
353
|
]),
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
(
|
|
357
|
-
key:
|
|
354
|
+
$("tr", null, [
|
|
355
|
+
Dt,
|
|
356
|
+
(s(!0), v(R, null, G(e.dataIdxLabels, (n) => (s(), v("th", {
|
|
357
|
+
key: n,
|
|
358
358
|
scope: "col"
|
|
359
|
-
},
|
|
359
|
+
}, A(n), 1))), 128))
|
|
360
360
|
])
|
|
361
361
|
]),
|
|
362
|
-
|
|
363
|
-
(
|
|
364
|
-
key:
|
|
362
|
+
$("tbody", null, [
|
|
363
|
+
(s(!0), v(R, null, G(e.data, (n) => (s(), v("tr", {
|
|
364
|
+
key: n.label
|
|
365
365
|
}, [
|
|
366
|
-
|
|
367
|
-
(
|
|
366
|
+
$("th", qt, A(n.label), 1),
|
|
367
|
+
(s(!0), v(R, null, G(n.data, (o, u) => (s(), v("td", {
|
|
368
368
|
key: `${o}${u}`
|
|
369
|
-
},
|
|
369
|
+
}, A(o), 1))), 128))
|
|
370
370
|
]))), 128))
|
|
371
371
|
])
|
|
372
|
-
], 8,
|
|
372
|
+
], 8, Pt)
|
|
373
373
|
]);
|
|
374
374
|
};
|
|
375
375
|
}
|
|
376
|
-
},
|
|
376
|
+
}, zt = (e) => ({
|
|
377
377
|
id: "htmlLegend",
|
|
378
378
|
afterUpdate(a) {
|
|
379
|
-
e.innerHTML = "", e.style.setProperty("--legend-padding", `${a.scales.x.left}px`), a.options.plugins.legend.labels.generateLabels(a).forEach((
|
|
380
|
-
const
|
|
381
|
-
|
|
382
|
-
const { type:
|
|
383
|
-
|
|
379
|
+
e.innerHTML = "", e.style.setProperty("--legend-padding", `${a.scales.x.left}px`), a.options.plugins.legend.labels.generateLabels(a).forEach((l) => {
|
|
380
|
+
const n = document.createElement("li");
|
|
381
|
+
n.onclick = () => {
|
|
382
|
+
const { type: r } = a.config._config;
|
|
383
|
+
r === "pie" || r === "doughnut" ? a.toggleDataVisibility(l.index) : a.setDatasetVisibility(l.datasetIndex, !a.isDatasetVisible(l.datasetIndex)), a.update();
|
|
384
384
|
};
|
|
385
385
|
const o = document.createElement("span");
|
|
386
|
-
o.style.setProperty("--item-box-fill",
|
|
387
|
-
const u = document.createTextNode(
|
|
388
|
-
i.style.setProperty("--item-text-color",
|
|
386
|
+
o.style.setProperty("--item-box-fill", l.fillStyle), o.style.setProperty("--item-box-stroke", l.strokeStyle);
|
|
387
|
+
const u = document.createTextNode(l.text), i = document.createElement("p");
|
|
388
|
+
i.style.setProperty("--item-text-color", l.fontColor), i.style.setProperty("--item-text-decoration", l.hidden ? "line-through" : "none"), i.appendChild(u), n.appendChild(o), n.appendChild(i), e.appendChild(n);
|
|
389
389
|
});
|
|
390
390
|
}
|
|
391
|
-
}),
|
|
391
|
+
}), Rt = ({ type: e, datasets: a, labels: t, tooltips: l }) => ({
|
|
392
392
|
type: e,
|
|
393
393
|
data: {
|
|
394
394
|
datasets: a,
|
|
@@ -401,13 +401,13 @@ const de = (e) => {
|
|
|
401
401
|
display: !1
|
|
402
402
|
},
|
|
403
403
|
tooltip: {
|
|
404
|
-
enabled:
|
|
404
|
+
enabled: l
|
|
405
405
|
}
|
|
406
406
|
},
|
|
407
407
|
responsive: !0
|
|
408
408
|
}
|
|
409
409
|
});
|
|
410
|
-
function
|
|
410
|
+
function Nt(e) {
|
|
411
411
|
const a = [
|
|
412
412
|
"rgba(209, 26, 111, 1)",
|
|
413
413
|
"rgba(130, 18, 196, 1)",
|
|
@@ -420,19 +420,19 @@ function Et(e) {
|
|
|
420
420
|
], t = a[e % a.length];
|
|
421
421
|
return e >= a.length ? t.replace("1)", "0.5)") : t;
|
|
422
422
|
}
|
|
423
|
-
function
|
|
424
|
-
let
|
|
423
|
+
function Ce(e, a, t) {
|
|
424
|
+
let l;
|
|
425
425
|
return function() {
|
|
426
|
-
let
|
|
427
|
-
clearTimeout(
|
|
428
|
-
|
|
426
|
+
let n = this, o = arguments;
|
|
427
|
+
clearTimeout(l), t && !l && e.apply(n, o), l = setTimeout(function() {
|
|
428
|
+
l = null, t || e.apply(n, o);
|
|
429
429
|
}, a);
|
|
430
430
|
};
|
|
431
431
|
}
|
|
432
|
-
const
|
|
432
|
+
const jt = {
|
|
433
433
|
class: "bs-chart-bar",
|
|
434
434
|
"data-component": "bs-chart-bar"
|
|
435
|
-
},
|
|
435
|
+
}, Wt = ["aria-label"], Ft = ["data-hidden"], Jn = {
|
|
436
436
|
__name: "BsChartBar",
|
|
437
437
|
props: {
|
|
438
438
|
chartTitle: {
|
|
@@ -486,16 +486,16 @@ const Dt = {
|
|
|
486
486
|
}
|
|
487
487
|
},
|
|
488
488
|
setup(e) {
|
|
489
|
-
const a = e, t = I(null),
|
|
490
|
-
let
|
|
491
|
-
const o =
|
|
489
|
+
const a = e, t = I(null), l = I(null);
|
|
490
|
+
let n;
|
|
491
|
+
const o = g(() => {
|
|
492
492
|
const c = {
|
|
493
493
|
datasets: u.value,
|
|
494
494
|
labels: a.dataIdxLabels,
|
|
495
495
|
type: "bar",
|
|
496
496
|
tooltips: a.showTooltips
|
|
497
|
-
},
|
|
498
|
-
return
|
|
497
|
+
}, p = Rt(c);
|
|
498
|
+
return p.plugins = [zt(l.value)], p.options.scales = {
|
|
499
499
|
x: {
|
|
500
500
|
grid: {
|
|
501
501
|
display: a.showXGrid
|
|
@@ -516,50 +516,50 @@ const Dt = {
|
|
|
516
516
|
text: a.yLabel
|
|
517
517
|
}
|
|
518
518
|
}
|
|
519
|
-
},
|
|
520
|
-
}), u =
|
|
519
|
+
}, p;
|
|
520
|
+
}), u = g(() => a.data.map((c, p) => ({
|
|
521
521
|
...c,
|
|
522
|
-
backgroundColor:
|
|
522
|
+
backgroundColor: Nt(p),
|
|
523
523
|
categoryPercentage: a.data.length > 1 ? 0.5 : 0.33
|
|
524
|
-
}))), i =
|
|
525
|
-
!
|
|
526
|
-
}, 100),
|
|
527
|
-
|
|
524
|
+
}))), i = g(() => a.chartTitle || `${a.yLabel} / ${a.xLabel}`), r = Ce(function(c, p) {
|
|
525
|
+
!n || c === p || (n.options = o.value.options, n.update());
|
|
526
|
+
}, 100), d = Ce(function() {
|
|
527
|
+
n && (n.data = o.value.data, n.update());
|
|
528
528
|
}, 100);
|
|
529
|
-
return
|
|
530
|
-
|
|
531
|
-
}),
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
529
|
+
return F(() => {
|
|
530
|
+
be.register(ut, ct, ft, vt, pt, ht), be.defaults.font.family = "'Roobert', sans-serif", n = new be(t.value, o.value);
|
|
531
|
+
}), z(() => a.showLegend, r), z(() => a.showTooltips, r), z(() => a.showXGrid, r), z(() => a.showYGrid, r), z(() => a.stacked, r), z(() => a.xLabel, r), z(() => a.yLabel, r), z(() => a.data, d), z(() => a.dataIdxLabels, d), (c, p) => (s(), v("div", jt, [
|
|
532
|
+
$("figure", null, [
|
|
533
|
+
$("div", null, [
|
|
534
|
+
$("canvas", {
|
|
535
535
|
"aria-label": i.value,
|
|
536
536
|
ref_key: "canvas",
|
|
537
537
|
ref: t,
|
|
538
538
|
role: "img"
|
|
539
|
-
}, null, 8,
|
|
539
|
+
}, null, 8, Wt)
|
|
540
540
|
]),
|
|
541
|
-
|
|
542
|
-
|
|
541
|
+
$("div", null, [
|
|
542
|
+
D(Mt, {
|
|
543
543
|
data: e.data,
|
|
544
544
|
"data-idx-labels": e.dataIdxLabels,
|
|
545
545
|
"table-title": i.value
|
|
546
546
|
}, null, 8, ["data", "data-idx-labels", "table-title"]),
|
|
547
|
-
|
|
547
|
+
$("figcaption", {
|
|
548
548
|
"data-hidden": !e.showLegend
|
|
549
549
|
}, [
|
|
550
|
-
|
|
550
|
+
$("ul", {
|
|
551
551
|
ref_key: "legendList",
|
|
552
|
-
ref:
|
|
552
|
+
ref: l
|
|
553
553
|
}, null, 512)
|
|
554
|
-
], 8,
|
|
554
|
+
], 8, Ft)
|
|
555
555
|
])
|
|
556
556
|
])
|
|
557
557
|
]));
|
|
558
558
|
}
|
|
559
|
-
},
|
|
559
|
+
}, Ut = ["data-disabled", "for"], Gt = /* @__PURE__ */ $("span", {
|
|
560
560
|
"data-required": "true",
|
|
561
561
|
"aria-hidden": "true"
|
|
562
|
-
}, " *", -1),
|
|
562
|
+
}, " *", -1), Ht = /* @__PURE__ */ $("span", { class: "visually-hidden" }, "required", -1), ne = {
|
|
563
563
|
__name: "BsLabel",
|
|
564
564
|
props: {
|
|
565
565
|
disabled: { type: Boolean, default: !1 },
|
|
@@ -568,22 +568,22 @@ const Dt = {
|
|
|
568
568
|
required: { type: Boolean, default: !1 }
|
|
569
569
|
},
|
|
570
570
|
setup(e) {
|
|
571
|
-
return (a, t) => (
|
|
572
|
-
class:
|
|
571
|
+
return (a, t) => (s(), v("label", {
|
|
572
|
+
class: Q(["bs-label", e.hide ? "visually-hidden" : ""]),
|
|
573
573
|
"data-component": "bs-label",
|
|
574
574
|
"data-disabled": e.disabled,
|
|
575
575
|
for: e.for
|
|
576
576
|
}, [
|
|
577
|
-
|
|
578
|
-
|
|
577
|
+
$("span", null, [
|
|
578
|
+
L(a.$slots, "default")
|
|
579
579
|
]),
|
|
580
|
-
e.required ? (
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
], 64)) :
|
|
584
|
-
], 10,
|
|
580
|
+
e.required ? (s(), v(R, { key: 0 }, [
|
|
581
|
+
Gt,
|
|
582
|
+
Ht
|
|
583
|
+
], 64)) : w("", !0)
|
|
584
|
+
], 10, Ut));
|
|
585
585
|
}
|
|
586
|
-
},
|
|
586
|
+
}, Kt = ["data-size"], Yt = ["checked", "data-error", "disabled", "id", "required", "value"], Ae = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
587
587
|
__name: "BsCheckbox",
|
|
588
588
|
props: {
|
|
589
589
|
/** Sets the label. */
|
|
@@ -641,54 +641,54 @@ const Dt = {
|
|
|
641
641
|
},
|
|
642
642
|
emits: ["update:modelValue"],
|
|
643
643
|
setup(e, { emit: a }) {
|
|
644
|
-
const t = e,
|
|
645
|
-
function
|
|
646
|
-
|
|
644
|
+
const t = e, l = a, n = U(), [o] = K(), { toChild: u, toRoot: i } = ae(t, n, ["aria-label", "name", "value"]), r = I(null), d = g(() => t.inputId || o.value), c = g(() => t.checked || h.value), p = g(() => Array.isArray(t.modelValue) && t.value), h = g(() => p.value && t.modelValue.includes(t.value) || typeof t.modelValue == "boolean" && t.modelValue);
|
|
645
|
+
function m() {
|
|
646
|
+
r.value && (r.value.indeterminate = t.checkedPartially && !c.value);
|
|
647
647
|
}
|
|
648
|
-
function
|
|
649
|
-
|
|
648
|
+
function V(E) {
|
|
649
|
+
l("update:modelValue", E);
|
|
650
650
|
}
|
|
651
|
-
function
|
|
651
|
+
function T(E) {
|
|
652
652
|
const y = [...t.modelValue];
|
|
653
|
-
|
|
653
|
+
E ? y.push(t.value) : y.splice(y.indexOf(t.value), 1), l("update:modelValue", y);
|
|
654
654
|
}
|
|
655
|
-
function
|
|
656
|
-
const { checked: y } =
|
|
657
|
-
|
|
655
|
+
function k(E) {
|
|
656
|
+
const { checked: y } = E.target;
|
|
657
|
+
p.value ? T(y) : V(y);
|
|
658
658
|
}
|
|
659
|
-
return
|
|
659
|
+
return z(c, m), z(() => t.checkedPartially, m), (E, y) => (s(), v("div", M({
|
|
660
660
|
class: "bs-boolean",
|
|
661
661
|
"data-component": "bs-checkbox",
|
|
662
662
|
"data-size": e.size
|
|
663
|
-
},
|
|
664
|
-
|
|
663
|
+
}, f(i)), [
|
|
664
|
+
$("input", M({
|
|
665
665
|
ref_key: "inputEl",
|
|
666
|
-
ref:
|
|
666
|
+
ref: r,
|
|
667
667
|
checked: c.value,
|
|
668
668
|
"data-error": e.error,
|
|
669
669
|
disabled: e.disabled,
|
|
670
|
-
id:
|
|
670
|
+
id: d.value,
|
|
671
671
|
required: e.required,
|
|
672
672
|
value: e.value || "on",
|
|
673
673
|
type: "checkbox",
|
|
674
|
-
onChange:
|
|
675
|
-
},
|
|
676
|
-
e.label ||
|
|
674
|
+
onChange: k
|
|
675
|
+
}, f(u)), null, 16, Yt),
|
|
676
|
+
e.label || E.$slots.label ? (s(), O(ne, {
|
|
677
677
|
key: 0,
|
|
678
|
-
for:
|
|
678
|
+
for: d.value,
|
|
679
679
|
disabled: e.disabled,
|
|
680
680
|
required: e.required
|
|
681
681
|
}, {
|
|
682
|
-
default:
|
|
683
|
-
|
|
684
|
-
|
|
682
|
+
default: P(() => [
|
|
683
|
+
L(E.$slots, "label", {}, () => [
|
|
684
|
+
W(A(e.label), 1)
|
|
685
685
|
])
|
|
686
686
|
]),
|
|
687
687
|
_: 3
|
|
688
|
-
}, 8, ["for", "disabled", "required"])) :
|
|
689
|
-
], 16,
|
|
688
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0)
|
|
689
|
+
], 16, Kt));
|
|
690
690
|
}
|
|
691
|
-
}),
|
|
691
|
+
}), Xt = { key: 0 }, Zt = { class: "bs-circle-button-icon" }, Jt = { key: 1 }, Qn = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
692
692
|
__name: "BsCircleButton",
|
|
693
693
|
props: {
|
|
694
694
|
disabled: {
|
|
@@ -734,32 +734,32 @@ const Dt = {
|
|
|
734
734
|
}
|
|
735
735
|
},
|
|
736
736
|
setup(e) {
|
|
737
|
-
const a = e, t =
|
|
737
|
+
const a = e, t = U(), { rootTag: l, attrsToBind: n, hrefUrl: o } = ue(a, t), { icon: u } = se(a, "icon"), { onLinkClick: i } = ce(a), r = g(() => a.textBtn ? {} : a.href ? { title: a.label } : { "aria-label": a.label }), d = g(() => {
|
|
738
738
|
if (a.hoverEffect)
|
|
739
739
|
return a.iconPosition;
|
|
740
|
-
}), c =
|
|
741
|
-
return (
|
|
740
|
+
}), c = g(() => a.textBtn && a.iconPosition !== "left"), p = g(() => a.textBtn && a.iconPosition === "left");
|
|
741
|
+
return (h, m) => (s(), O(H(f(l)), M({
|
|
742
742
|
class: "bs-circle-button",
|
|
743
743
|
"data-disabled": e.disabled,
|
|
744
|
-
"data-direction":
|
|
744
|
+
"data-direction": d.value,
|
|
745
745
|
"data-ghost": e.ghostBtn,
|
|
746
746
|
"data-size": e.size,
|
|
747
747
|
"data-text": e.textBtn,
|
|
748
|
-
".href":
|
|
749
|
-
}, { ...
|
|
750
|
-
default:
|
|
751
|
-
c.value ? (
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
(
|
|
748
|
+
".href": f(o)
|
|
749
|
+
}, { ...f(n), ...r.value }, { onClick: f(i) }), {
|
|
750
|
+
default: P(() => [
|
|
751
|
+
c.value ? (s(), v("span", Xt, A(e.label), 1)) : w("", !0),
|
|
752
|
+
$("span", Zt, [
|
|
753
|
+
L(h.$slots, "icon", {}, () => [
|
|
754
|
+
(s(), O(H(f(u)), { size: e.size }, null, 8, ["size"]))
|
|
755
755
|
])
|
|
756
756
|
]),
|
|
757
|
-
|
|
757
|
+
p.value ? (s(), v("span", Jt, A(e.label), 1)) : w("", !0)
|
|
758
758
|
]),
|
|
759
759
|
_: 3
|
|
760
760
|
}, 48, ["data-disabled", "data-direction", "data-ghost", "data-size", "data-text", ".href", "onClick"]));
|
|
761
761
|
}
|
|
762
|
-
}),
|
|
762
|
+
}), pe = {
|
|
763
763
|
__name: "BsTransition",
|
|
764
764
|
props: {
|
|
765
765
|
shown: {
|
|
@@ -802,72 +802,72 @@ const Dt = {
|
|
|
802
802
|
"leave-cancelled"
|
|
803
803
|
],
|
|
804
804
|
setup(e, { emit: a }) {
|
|
805
|
-
const t = e,
|
|
806
|
-
function o(
|
|
807
|
-
const { duration: c, enterClass:
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
}, c)),
|
|
805
|
+
const t = e, l = a, n = [];
|
|
806
|
+
function o(r, d) {
|
|
807
|
+
const { duration: c, enterClass: p, enterAttribute: h } = t;
|
|
808
|
+
n.push(setTimeout(() => {
|
|
809
|
+
p && r.classList.add(p), h && r.setAttribute(h, ""), n.push(setTimeout(() => {
|
|
810
|
+
d();
|
|
811
|
+
}, c)), l("enter", r);
|
|
812
812
|
}));
|
|
813
813
|
}
|
|
814
|
-
function u(
|
|
814
|
+
function u(r, d) {
|
|
815
815
|
const {
|
|
816
816
|
duration: c,
|
|
817
|
-
enterClass:
|
|
818
|
-
enterAttribute:
|
|
819
|
-
leaveClass:
|
|
820
|
-
leaveAttribute:
|
|
817
|
+
enterClass: p,
|
|
818
|
+
enterAttribute: h,
|
|
819
|
+
leaveClass: m,
|
|
820
|
+
leaveAttribute: V
|
|
821
821
|
} = t;
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
}, c)),
|
|
822
|
+
r.classList.remove(p), r.removeAttribute(h), m && r.classList.add(m), V && r.setAttribute(V, ""), n.push(setTimeout(() => {
|
|
823
|
+
d();
|
|
824
|
+
}, c)), l("leave", r);
|
|
825
825
|
}
|
|
826
|
-
function i(
|
|
827
|
-
const { leaveClass:
|
|
828
|
-
|
|
826
|
+
function i(r) {
|
|
827
|
+
const { leaveClass: d, leaveAttribute: c } = t;
|
|
828
|
+
r.classList.remove(d), r.removeAttribute(c), l("after-leave", r);
|
|
829
829
|
}
|
|
830
|
-
return
|
|
831
|
-
|
|
832
|
-
clearTimeout(
|
|
830
|
+
return _(() => {
|
|
831
|
+
n.forEach((r) => {
|
|
832
|
+
clearTimeout(r);
|
|
833
833
|
});
|
|
834
|
-
}), (
|
|
834
|
+
}), (r, d) => e.preloaded ? ye((s(), O(Ie, {
|
|
835
835
|
key: 0,
|
|
836
836
|
css: !1,
|
|
837
|
-
onBeforeEnter:
|
|
837
|
+
onBeforeEnter: d[0] || (d[0] = (c) => l("before-enter", c)),
|
|
838
838
|
onEnter: o,
|
|
839
|
-
onAfterEnter:
|
|
840
|
-
onEnterCancelled:
|
|
841
|
-
onBeforeLeave:
|
|
839
|
+
onAfterEnter: d[1] || (d[1] = (c) => l("after-enter", c)),
|
|
840
|
+
onEnterCancelled: d[2] || (d[2] = (c) => l("enter-cancelled", c)),
|
|
841
|
+
onBeforeLeave: d[3] || (d[3] = (c) => l("before-leave", c)),
|
|
842
842
|
onLeave: u,
|
|
843
843
|
onAfterLeave: i,
|
|
844
|
-
onLeaveCancelled:
|
|
844
|
+
onLeaveCancelled: d[4] || (d[4] = (c) => l("leave-cancelled", c))
|
|
845
845
|
}, {
|
|
846
|
-
default:
|
|
847
|
-
|
|
846
|
+
default: P(() => [
|
|
847
|
+
L(r.$slots, "default")
|
|
848
848
|
]),
|
|
849
849
|
_: 3
|
|
850
850
|
}, 512)), [
|
|
851
|
-
[
|
|
852
|
-
]) : (
|
|
851
|
+
[Be, e.shown]
|
|
852
|
+
]) : (s(), O(Ie, {
|
|
853
853
|
key: 1,
|
|
854
854
|
css: !1,
|
|
855
|
-
onBeforeEnter:
|
|
855
|
+
onBeforeEnter: d[5] || (d[5] = (c) => l("before-enter", c)),
|
|
856
856
|
onEnter: o,
|
|
857
|
-
onAfterEnter:
|
|
858
|
-
onEnterCancelled:
|
|
859
|
-
onBeforeLeave:
|
|
857
|
+
onAfterEnter: d[6] || (d[6] = (c) => l("after-enter", c)),
|
|
858
|
+
onEnterCancelled: d[7] || (d[7] = (c) => l("enter-cancelled", c)),
|
|
859
|
+
onBeforeLeave: d[8] || (d[8] = (c) => l("before-leave", c)),
|
|
860
860
|
onLeave: u,
|
|
861
861
|
onAfterLeave: i,
|
|
862
|
-
onLeaveCancelled:
|
|
862
|
+
onLeaveCancelled: d[9] || (d[9] = (c) => l("leave-cancelled", c))
|
|
863
863
|
}, {
|
|
864
|
-
default:
|
|
865
|
-
e.shown ?
|
|
864
|
+
default: P(() => [
|
|
865
|
+
e.shown ? L(r.$slots, "default", { key: 0 }) : w("", !0)
|
|
866
866
|
]),
|
|
867
867
|
_: 3
|
|
868
868
|
}));
|
|
869
869
|
}
|
|
870
|
-
},
|
|
870
|
+
}, Qt = ["data-width"], _t = { key: 0 }, ea = { key: 0 }, Le = {
|
|
871
871
|
__name: "BsDropdownInternal",
|
|
872
872
|
props: {
|
|
873
873
|
shown: {
|
|
@@ -915,90 +915,93 @@ const Dt = {
|
|
|
915
915
|
"after-leave"
|
|
916
916
|
],
|
|
917
917
|
setup(e, { emit: a }) {
|
|
918
|
-
const t = e,
|
|
918
|
+
const t = e, l = a, n = I(null);
|
|
919
919
|
let o = !1;
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
}), se(["Escape"], () => {
|
|
923
|
-
o && n("close");
|
|
920
|
+
const u = new Proxy({}, {
|
|
921
|
+
get: () => document.getElementById(t.anchorId)
|
|
924
922
|
});
|
|
925
|
-
|
|
926
|
-
|
|
923
|
+
mt([n, u], () => {
|
|
924
|
+
o && l("close");
|
|
925
|
+
}), fe(["Escape"], () => {
|
|
926
|
+
o && l("close");
|
|
927
|
+
});
|
|
928
|
+
function i() {
|
|
929
|
+
const V = (t.containerRef || document.getElementById(t.containerId)).getBoundingClientRect(), T = document.getElementById(t.anchorId).getBoundingClientRect(), k = n.value.getBoundingClientRect();
|
|
927
930
|
if (t.position === "top") {
|
|
928
|
-
const
|
|
929
|
-
|
|
931
|
+
const y = V.bottom - T.bottom;
|
|
932
|
+
n.value.style.setProperty("--dropdown-wscreen-top", "auto"), n.value.style.setProperty("--dropdown-wscreen-bottom", `${y + T.height + 8}px`);
|
|
930
933
|
} else {
|
|
931
|
-
const
|
|
932
|
-
|
|
934
|
+
const y = T.top - V.top;
|
|
935
|
+
n.value.style.setProperty("--dropdown-wscreen-top", `${y + T.height + 8}px`), n.value.style.setProperty("--dropdown-wscreen-bottom", "auto");
|
|
933
936
|
}
|
|
934
|
-
const
|
|
937
|
+
const E = T.left - V.left;
|
|
935
938
|
if (t.position === "center") {
|
|
936
|
-
const
|
|
937
|
-
|
|
939
|
+
const y = (T.width - k.width) / 2;
|
|
940
|
+
n.value.style.setProperty("--dropdown-wscreen-left", `${E + y}px`);
|
|
938
941
|
} else if (t.position === "right") {
|
|
939
|
-
const
|
|
940
|
-
|
|
942
|
+
const y = V.right - T.right;
|
|
943
|
+
n.value.style.setProperty("--dropdown-wscreen-left", "auto"), n.value.style.setProperty("--dropdown-wscreen-right", `${y}px`);
|
|
941
944
|
} else
|
|
942
|
-
|
|
945
|
+
n.value.style.setProperty("--dropdown-wscreen-left", `${E}px`);
|
|
943
946
|
}
|
|
944
|
-
function
|
|
947
|
+
function r() {
|
|
945
948
|
if (t.width === "toggle") {
|
|
946
|
-
const
|
|
947
|
-
|
|
949
|
+
const m = document.getElementById(t.anchorId).getBoundingClientRect();
|
|
950
|
+
n.value.style.setProperty("--dropdown-wscreen-width", `${m.width}px`);
|
|
948
951
|
} else
|
|
949
|
-
|
|
952
|
+
n.value.style.setProperty("--dropdown-wscreen-width", "");
|
|
950
953
|
}
|
|
951
|
-
function
|
|
952
|
-
|
|
953
|
-
}
|
|
954
|
-
function r() {
|
|
955
|
-
o = !0, n("after-enter");
|
|
954
|
+
function d() {
|
|
955
|
+
i(), r(), l("enter");
|
|
956
956
|
}
|
|
957
957
|
function c() {
|
|
958
|
-
o = !
|
|
958
|
+
o = !0, l("after-enter");
|
|
959
|
+
}
|
|
960
|
+
function p() {
|
|
961
|
+
o = !1, l("after-leave");
|
|
959
962
|
}
|
|
960
|
-
function
|
|
963
|
+
function h() {
|
|
961
964
|
return t.width === "toggle" ? void 0 : t.width;
|
|
962
965
|
}
|
|
963
|
-
return (
|
|
966
|
+
return (m, V) => (s(), O(f(pe), {
|
|
964
967
|
shown: e.shown,
|
|
965
968
|
preloaded: e.preloaded,
|
|
966
969
|
duration: 75,
|
|
967
970
|
"enter-attribute": "data-shown",
|
|
968
|
-
onAfterEnter:
|
|
969
|
-
onEnter:
|
|
970
|
-
onAfterLeave:
|
|
971
|
+
onAfterEnter: c,
|
|
972
|
+
onEnter: d,
|
|
973
|
+
onAfterLeave: p
|
|
971
974
|
}, {
|
|
972
|
-
default:
|
|
973
|
-
|
|
975
|
+
default: P(() => [
|
|
976
|
+
$("div", M({
|
|
974
977
|
ref_key: "dropdownRef",
|
|
975
|
-
ref:
|
|
978
|
+
ref: n,
|
|
976
979
|
class: "bs-dropdown",
|
|
977
|
-
"data-width":
|
|
978
|
-
},
|
|
979
|
-
e.helperText ? (
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
e.helperDescription ? (
|
|
980
|
+
"data-width": h()
|
|
981
|
+
}, m.$attrs), [
|
|
982
|
+
e.helperText ? (s(), v("header", _t, [
|
|
983
|
+
$("div", null, [
|
|
984
|
+
$("h3", null, A(e.helperText), 1),
|
|
985
|
+
e.helperDescription ? (s(), v("p", ea, A(e.helperDescription), 1)) : w("", !0)
|
|
983
986
|
]),
|
|
984
|
-
|
|
987
|
+
$("button", {
|
|
985
988
|
type: "button",
|
|
986
989
|
title: "close",
|
|
987
|
-
onClick:
|
|
990
|
+
onClick: V[0] || (V[0] = () => l("close"))
|
|
988
991
|
}, [
|
|
989
|
-
|
|
992
|
+
D(f(de))
|
|
990
993
|
])
|
|
991
|
-
])) :
|
|
992
|
-
|
|
993
|
-
], 16,
|
|
994
|
+
])) : w("", !0),
|
|
995
|
+
L(m.$slots, "default")
|
|
996
|
+
], 16, Qt)
|
|
994
997
|
]),
|
|
995
998
|
_: 3
|
|
996
999
|
}, 8, ["shown", "preloaded"]));
|
|
997
1000
|
}
|
|
998
|
-
},
|
|
1001
|
+
}, ta = {
|
|
999
1002
|
key: 0,
|
|
1000
1003
|
class: "bs-dropdown-backdrop"
|
|
1001
|
-
},
|
|
1004
|
+
}, Ee = {
|
|
1002
1005
|
__name: "BsDropdown",
|
|
1003
1006
|
props: {
|
|
1004
1007
|
shown: {
|
|
@@ -1078,59 +1081,67 @@ const Dt = {
|
|
|
1078
1081
|
"after-leave"
|
|
1079
1082
|
],
|
|
1080
1083
|
setup(e, { emit: a }) {
|
|
1081
|
-
const t = e,
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1084
|
+
const t = e, l = a, n = I(null), o = I(!1), { transition: u } = ve(t);
|
|
1085
|
+
ee("dropdownAfterEnter", o), ee("dropdownShown", u);
|
|
1086
|
+
const i = g(() => t.toggleId ? t.toggleId : t.anchorId), r = g(() => t.top ? "top" : t.center ? "center" : t.right ? "right" : t.position);
|
|
1087
|
+
function d() {
|
|
1088
|
+
o.value = !0, l("after-enter");
|
|
1089
|
+
}
|
|
1090
|
+
function c() {
|
|
1091
|
+
o.value = !1, l("after-leave");
|
|
1092
|
+
}
|
|
1093
|
+
return (p, h) => (s(), v(R, null, [
|
|
1094
|
+
f(u) ? (s(), v("div", ta)) : w("", !0),
|
|
1095
|
+
e.containerId ? (s(), O(f(Le), M({
|
|
1085
1096
|
key: 1,
|
|
1086
|
-
shown:
|
|
1097
|
+
shown: f(u),
|
|
1087
1098
|
preloaded: e.preloaded,
|
|
1088
|
-
"anchor-id":
|
|
1099
|
+
"anchor-id": i.value,
|
|
1089
1100
|
"container-id": e.containerId,
|
|
1090
1101
|
"helper-description": e.helperDescription,
|
|
1091
1102
|
"helper-text": e.helperText,
|
|
1092
|
-
position:
|
|
1103
|
+
position: r.value,
|
|
1093
1104
|
width: e.width
|
|
1094
|
-
},
|
|
1095
|
-
onClose:
|
|
1096
|
-
onAfterEnter:
|
|
1097
|
-
onEnter:
|
|
1098
|
-
onAfterLeave:
|
|
1105
|
+
}, p.$attrs, {
|
|
1106
|
+
onClose: h[0] || (h[0] = (m) => l("close")),
|
|
1107
|
+
onAfterEnter: d,
|
|
1108
|
+
onEnter: h[1] || (h[1] = (m) => l("enter")),
|
|
1109
|
+
onAfterLeave: c
|
|
1099
1110
|
}), {
|
|
1100
|
-
default:
|
|
1101
|
-
|
|
1111
|
+
default: P(() => [
|
|
1112
|
+
L(p.$slots, "default")
|
|
1102
1113
|
]),
|
|
1103
1114
|
_: 3
|
|
1104
|
-
}, 16, ["shown", "preloaded", "anchor-id", "container-id", "helper-description", "helper-text", "position", "width"])) : (
|
|
1115
|
+
}, 16, ["shown", "preloaded", "anchor-id", "container-id", "helper-description", "helper-text", "position", "width"])) : (s(), v("div", {
|
|
1105
1116
|
key: 2,
|
|
1106
1117
|
ref_key: "containerRef",
|
|
1107
|
-
ref:
|
|
1118
|
+
ref: n,
|
|
1108
1119
|
style: { position: "relative" }
|
|
1109
1120
|
}, [
|
|
1110
|
-
|
|
1111
|
-
shown:
|
|
1121
|
+
D(f(Le), M({
|
|
1122
|
+
shown: f(u),
|
|
1112
1123
|
preloaded: e.preloaded,
|
|
1113
|
-
"anchor-id":
|
|
1114
|
-
"container-ref":
|
|
1124
|
+
"anchor-id": i.value,
|
|
1125
|
+
"container-ref": n.value,
|
|
1115
1126
|
"helper-description": e.helperDescription,
|
|
1116
1127
|
"helper-text": e.helperText,
|
|
1117
|
-
position:
|
|
1128
|
+
position: r.value,
|
|
1118
1129
|
width: e.width
|
|
1119
|
-
},
|
|
1120
|
-
onClose:
|
|
1121
|
-
onAfterEnter:
|
|
1122
|
-
onEnter:
|
|
1123
|
-
onAfterLeave:
|
|
1130
|
+
}, p.$attrs, {
|
|
1131
|
+
onClose: h[2] || (h[2] = (m) => l("close")),
|
|
1132
|
+
onAfterEnter: d,
|
|
1133
|
+
onEnter: h[3] || (h[3] = (m) => l("enter")),
|
|
1134
|
+
onAfterLeave: c
|
|
1124
1135
|
}), {
|
|
1125
|
-
default:
|
|
1126
|
-
|
|
1136
|
+
default: P(() => [
|
|
1137
|
+
L(p.$slots, "default")
|
|
1127
1138
|
]),
|
|
1128
1139
|
_: 3
|
|
1129
1140
|
}, 16, ["shown", "preloaded", "anchor-id", "container-ref", "helper-description", "helper-text", "position", "width"])
|
|
1130
1141
|
], 512))
|
|
1131
1142
|
], 64));
|
|
1132
1143
|
}
|
|
1133
|
-
},
|
|
1144
|
+
}, aa = ["data-value", "data-variant", "id"], ie = {
|
|
1134
1145
|
__name: "BsDropdownOption",
|
|
1135
1146
|
props: {
|
|
1136
1147
|
value: {
|
|
@@ -1143,55 +1154,52 @@ const Dt = {
|
|
|
1143
1154
|
}
|
|
1144
1155
|
},
|
|
1145
1156
|
setup(e) {
|
|
1146
|
-
const a = e, t = I(null),
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
u(), (s = t.value.querySelector("a")) == null || s.click(), i.preventDefault();
|
|
1157
|
+
const a = e, t = I(null), l = te("optionsId"), n = te("handleSelect"), o = g(() => `${l}-option-${a.value}`);
|
|
1158
|
+
fe([" ", "Enter", "NumpadEnter"], (i) => {
|
|
1159
|
+
u(), i.preventDefault();
|
|
1150
1160
|
}, t);
|
|
1151
|
-
function u() {
|
|
1152
|
-
var
|
|
1153
|
-
|
|
1161
|
+
function u(i) {
|
|
1162
|
+
var r, d;
|
|
1163
|
+
n(o.value, a.value), (r = t.value.querySelector("a")) == null || r.click(), (d = i == null ? void 0 : i.stopPropagation) == null || d.call(i);
|
|
1154
1164
|
}
|
|
1155
|
-
return (i,
|
|
1156
|
-
"data-component": "bs-dropdown-option",
|
|
1157
|
-
"data-value": a.value,
|
|
1165
|
+
return (i, r) => (s(), v("li", {
|
|
1158
1166
|
ref_key: "optionRef",
|
|
1159
1167
|
ref: t,
|
|
1160
|
-
|
|
1168
|
+
"data-component": "bs-dropdown-option",
|
|
1169
|
+
"data-value": a.value,
|
|
1161
1170
|
"data-variant": e.variant || void 0,
|
|
1162
1171
|
id: o.value,
|
|
1172
|
+
role: "option",
|
|
1163
1173
|
tabIndex: -1,
|
|
1164
1174
|
onClick: u
|
|
1165
1175
|
}, [
|
|
1166
|
-
|
|
1167
|
-
], 8,
|
|
1176
|
+
L(i.$slots, "default")
|
|
1177
|
+
], 8, aa));
|
|
1168
1178
|
}
|
|
1169
|
-
},
|
|
1179
|
+
}, na = ["aria-activedescendant", "aria-label", "id"], $e = {
|
|
1170
1180
|
__name: "BsDropdownOptionList",
|
|
1171
1181
|
props: {
|
|
1172
1182
|
optionsId: {
|
|
1173
1183
|
type: String,
|
|
1174
1184
|
required: !0
|
|
1175
1185
|
},
|
|
1176
|
-
|
|
1177
|
-
* it is not even needed when using v-if (only for v-show).
|
|
1178
|
-
*/
|
|
1179
|
-
visible: {
|
|
1180
|
-
type: Boolean,
|
|
1181
|
-
default: void 0
|
|
1182
|
-
},
|
|
1183
|
-
shown: {
|
|
1186
|
+
focusOnShow: {
|
|
1184
1187
|
type: Boolean,
|
|
1185
1188
|
default: !0
|
|
1186
1189
|
},
|
|
1187
|
-
focusDelay: {
|
|
1188
|
-
type: Number,
|
|
1189
|
-
default: 75
|
|
1190
|
-
},
|
|
1191
1190
|
label: {
|
|
1192
1191
|
type: String,
|
|
1193
1192
|
default: void 0
|
|
1194
1193
|
},
|
|
1194
|
+
/* Internal use only - no need to document */
|
|
1195
|
+
multiselect: {
|
|
1196
|
+
type: Boolean,
|
|
1197
|
+
default: !1
|
|
1198
|
+
},
|
|
1199
|
+
preventTab: {
|
|
1200
|
+
type: Boolean,
|
|
1201
|
+
default: !0
|
|
1202
|
+
},
|
|
1195
1203
|
/** @Deprecated - Use modelValue (or v-model) instead */
|
|
1196
1204
|
selectedValue: {
|
|
1197
1205
|
type: [String, Number],
|
|
@@ -1203,97 +1211,242 @@ const Dt = {
|
|
|
1203
1211
|
}
|
|
1204
1212
|
},
|
|
1205
1213
|
emits: ["optselected", "update:modelValue", "close"],
|
|
1206
|
-
setup(e, {
|
|
1207
|
-
const
|
|
1208
|
-
let
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
function
|
|
1224
|
-
var
|
|
1225
|
-
c.value ? (
|
|
1226
|
-
(
|
|
1227
|
-
),
|
|
1228
|
-
var
|
|
1229
|
-
(
|
|
1230
|
-
},
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1214
|
+
setup(e, { expose: a, emit: t }) {
|
|
1215
|
+
const l = e, n = t, o = I(null), u = I(null), i = I(-1), r = I(null), d = te("dropdownAfterEnter"), c = te("dropdownShown");
|
|
1216
|
+
let p = -1;
|
|
1217
|
+
ee("handleSelect", y), ee("optionsId", l.optionsId), F(() => {
|
|
1218
|
+
m(), V(), document.addEventListener("keydown", k);
|
|
1219
|
+
}), _(() => {
|
|
1220
|
+
document.removeEventListener("keydown", k);
|
|
1221
|
+
}), z(d, (b) => {
|
|
1222
|
+
var S, x;
|
|
1223
|
+
b && p > -1 && (l.focusOnShow ? (S = r.value[p]) == null || S.focus() : (x = r.value[p]) == null || x.scrollIntoView({ block: "nearest" }));
|
|
1224
|
+
}), z(c, V);
|
|
1225
|
+
const h = g(() => l.modelValue || l.selectedValue);
|
|
1226
|
+
function m() {
|
|
1227
|
+
r.value = Array.from(
|
|
1228
|
+
o.value.querySelectorAll('[data-component="bs-dropdown-option"]')
|
|
1229
|
+
);
|
|
1230
|
+
}
|
|
1231
|
+
function V() {
|
|
1232
|
+
var b, S;
|
|
1233
|
+
c.value && !l.multiselect ? (p = r.value.findIndex(
|
|
1234
|
+
(x) => x.getAttribute("data-value") === String(h.value)
|
|
1235
|
+
), r.value.forEach((x) => {
|
|
1236
|
+
var N;
|
|
1237
|
+
return (N = x == null ? void 0 : x.setAttribute) == null ? void 0 : N.call(x, "aria-selected", "false");
|
|
1238
|
+
}), p > -1 && ((b = r.value[p]) == null || b.setAttribute("data-selected", ""), (S = r.value[p]) == null || S.setAttribute("aria-selected", "true"), i.value = p)) : (r.value.forEach((x) => {
|
|
1239
|
+
var N;
|
|
1240
|
+
return (N = x == null ? void 0 : x.removeAttribute) == null ? void 0 : N.call(x, "data-selected");
|
|
1241
|
+
}), r.value.forEach((x) => {
|
|
1242
|
+
var N;
|
|
1243
|
+
return (N = x == null ? void 0 : x.removeAttribute) == null ? void 0 : N.call(x, "aria-selected");
|
|
1244
|
+
}));
|
|
1245
|
+
}
|
|
1246
|
+
yt(
|
|
1247
|
+
o,
|
|
1234
1248
|
() => {
|
|
1235
|
-
|
|
1249
|
+
m();
|
|
1236
1250
|
},
|
|
1237
1251
|
{ childList: !0 }
|
|
1238
1252
|
);
|
|
1239
|
-
function
|
|
1240
|
-
var
|
|
1241
|
-
i > -1 && ((
|
|
1253
|
+
function T() {
|
|
1254
|
+
var b;
|
|
1255
|
+
i.value > -1 && ((b = r.value[i.value]) == null || b.blur());
|
|
1242
1256
|
}
|
|
1243
|
-
function
|
|
1257
|
+
function k(b) {
|
|
1244
1258
|
if (c.value)
|
|
1245
|
-
switch (
|
|
1259
|
+
switch (b.key) {
|
|
1246
1260
|
case "ArrowDown":
|
|
1247
|
-
|
|
1261
|
+
E("down"), b.preventDefault();
|
|
1248
1262
|
break;
|
|
1249
1263
|
case "ArrowUp":
|
|
1250
|
-
|
|
1264
|
+
E("up"), b.preventDefault();
|
|
1251
1265
|
break;
|
|
1252
1266
|
case "Home":
|
|
1253
|
-
|
|
1267
|
+
E("home"), b.preventDefault();
|
|
1254
1268
|
break;
|
|
1255
1269
|
case "End":
|
|
1256
|
-
|
|
1270
|
+
E("end"), b.preventDefault();
|
|
1257
1271
|
break;
|
|
1258
1272
|
case "Tab":
|
|
1259
|
-
|
|
1273
|
+
i.value = p, l.preventTab && b.preventDefault();
|
|
1260
1274
|
break;
|
|
1261
1275
|
}
|
|
1262
1276
|
}
|
|
1263
|
-
function
|
|
1264
|
-
let
|
|
1265
|
-
switch (
|
|
1277
|
+
function E(b) {
|
|
1278
|
+
let S;
|
|
1279
|
+
switch (b) {
|
|
1266
1280
|
case "up":
|
|
1267
|
-
|
|
1281
|
+
S = i.value - 1 < 0 ? r.value.length - 1 : i.value - 1;
|
|
1268
1282
|
break;
|
|
1269
1283
|
case "down":
|
|
1270
|
-
|
|
1284
|
+
S = (i.value + 1) % r.value.length;
|
|
1271
1285
|
break;
|
|
1272
1286
|
case "home":
|
|
1273
|
-
|
|
1287
|
+
S = 0;
|
|
1274
1288
|
break;
|
|
1275
1289
|
case "end":
|
|
1276
|
-
|
|
1290
|
+
S = r.value.length - 1;
|
|
1277
1291
|
break;
|
|
1278
1292
|
}
|
|
1279
|
-
|
|
1293
|
+
T(), r.value[S].focus(), u.value = r.value[S].id, i.value = S;
|
|
1280
1294
|
}
|
|
1281
|
-
function
|
|
1282
|
-
|
|
1295
|
+
function y(b, S) {
|
|
1296
|
+
u.value = b, T(), n("optselected", S), n("update:modelValue", S), n("close");
|
|
1283
1297
|
}
|
|
1284
|
-
return (
|
|
1298
|
+
return a({
|
|
1299
|
+
activeDescendantId: u,
|
|
1300
|
+
focusedIndex: i,
|
|
1301
|
+
optionEls: r,
|
|
1302
|
+
refreshOptions: m
|
|
1303
|
+
}), (b, S) => (s(), v("ul", {
|
|
1285
1304
|
ref_key: "optionsRef",
|
|
1286
|
-
ref:
|
|
1287
|
-
"aria-activedescendant":
|
|
1288
|
-
"aria-label":
|
|
1305
|
+
ref: o,
|
|
1306
|
+
"aria-activedescendant": u.value || void 0,
|
|
1307
|
+
"aria-label": l.label || void 0,
|
|
1289
1308
|
class: "bs-dropdown-options",
|
|
1290
|
-
id:
|
|
1309
|
+
id: l.optionsId,
|
|
1291
1310
|
role: "listbox"
|
|
1292
1311
|
}, [
|
|
1293
|
-
|
|
1294
|
-
], 8,
|
|
1312
|
+
L(b.$slots, "default")
|
|
1313
|
+
], 8, na));
|
|
1295
1314
|
}
|
|
1296
|
-
},
|
|
1315
|
+
}, la = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1316
|
+
__proto__: null,
|
|
1317
|
+
default: $e
|
|
1318
|
+
}, Symbol.toStringTag, { value: "Module" })), oa = ["for"], ia = { role: "separator" }, ra = /* @__PURE__ */ $("hr", null, null, -1), sa = [
|
|
1319
|
+
ra
|
|
1320
|
+
], da = ["for"], ua = {
|
|
1321
|
+
__name: "BsDropdownMultiselect",
|
|
1322
|
+
props: {
|
|
1323
|
+
label: {
|
|
1324
|
+
type: String
|
|
1325
|
+
},
|
|
1326
|
+
options: {
|
|
1327
|
+
type: Array,
|
|
1328
|
+
default: () => []
|
|
1329
|
+
},
|
|
1330
|
+
optionsId: {
|
|
1331
|
+
type: String,
|
|
1332
|
+
required: !0
|
|
1333
|
+
},
|
|
1334
|
+
selectedOptions: {
|
|
1335
|
+
type: Array,
|
|
1336
|
+
default: () => []
|
|
1337
|
+
},
|
|
1338
|
+
shown: {
|
|
1339
|
+
type: Boolean,
|
|
1340
|
+
default: !1
|
|
1341
|
+
}
|
|
1342
|
+
},
|
|
1343
|
+
emits: ["update:selectedOptions"],
|
|
1344
|
+
setup(e, { emit: a }) {
|
|
1345
|
+
const t = e, l = a;
|
|
1346
|
+
I(null), I(null);
|
|
1347
|
+
const n = I(null), o = I([]), u = I([]);
|
|
1348
|
+
let i = !1;
|
|
1349
|
+
z(
|
|
1350
|
+
() => t.selectedOptions,
|
|
1351
|
+
c,
|
|
1352
|
+
{ immediate: !0 }
|
|
1353
|
+
), z(() => t.shown, (m) => {
|
|
1354
|
+
m && oe(r);
|
|
1355
|
+
});
|
|
1356
|
+
function r() {
|
|
1357
|
+
var V, T;
|
|
1358
|
+
n.value && (n.value.refreshOptions(), n.value.activeDescendantId = (V = n.value.optionEls[0]) == null ? void 0 : V.id, n.value.focusedIndex = 0);
|
|
1359
|
+
const m = document.querySelector(`#${t.optionsId} [data-component="bs-dropdown-option"]`);
|
|
1360
|
+
(T = m == null ? void 0 : m.focus) == null || T.call(m, { preventScroll: !0 });
|
|
1361
|
+
}
|
|
1362
|
+
function d() {
|
|
1363
|
+
var m;
|
|
1364
|
+
if (n.value) {
|
|
1365
|
+
n.value.refreshOptions();
|
|
1366
|
+
const V = n.value.focusedIndex, T = n.value.optionEls[V];
|
|
1367
|
+
(m = T == null ? void 0 : T.focus) == null || m.call(T), n.value.activeDescendantId = T == null ? void 0 : T.id;
|
|
1368
|
+
}
|
|
1369
|
+
}
|
|
1370
|
+
function c(m = []) {
|
|
1371
|
+
const V = new Set(m), T = [], k = [];
|
|
1372
|
+
t.options.forEach((E) => V.has(E.value) ? T.push(E) : k.push(E)), o.value = T, oe(() => {
|
|
1373
|
+
u.value = k, oe(() => {
|
|
1374
|
+
i && d(), i = !1;
|
|
1375
|
+
});
|
|
1376
|
+
});
|
|
1377
|
+
}
|
|
1378
|
+
function p(m = []) {
|
|
1379
|
+
const V = new Set(m), T = [];
|
|
1380
|
+
return t.options.forEach((k) => {
|
|
1381
|
+
V.has(k.value) && T.push(k.value);
|
|
1382
|
+
}), T;
|
|
1383
|
+
}
|
|
1384
|
+
function h(m) {
|
|
1385
|
+
const V = t.selectedOptions.includes(m) ? t.selectedOptions.filter((T) => T !== m) : p([...t.selectedOptions, m]);
|
|
1386
|
+
i = !0, l("update:selectedOptions", V);
|
|
1387
|
+
}
|
|
1388
|
+
return (m, V) => (s(), O($e, {
|
|
1389
|
+
ref_key: "optlist",
|
|
1390
|
+
ref: n,
|
|
1391
|
+
"aria-multiselectable": "true",
|
|
1392
|
+
"data-component": "bs-dropdown-multiselect",
|
|
1393
|
+
label: e.label,
|
|
1394
|
+
multiselect: "",
|
|
1395
|
+
"options-id": e.optionsId,
|
|
1396
|
+
shown: e.shown,
|
|
1397
|
+
"onUpdate:modelValue": h
|
|
1398
|
+
}, {
|
|
1399
|
+
default: P(() => {
|
|
1400
|
+
var T;
|
|
1401
|
+
return [
|
|
1402
|
+
(s(!0), v(R, null, G(o.value, (k) => (s(), O(ie, {
|
|
1403
|
+
key: k.value,
|
|
1404
|
+
"aria-checked": e.shown ? "true" : void 0,
|
|
1405
|
+
variant: "2-col",
|
|
1406
|
+
value: k.value
|
|
1407
|
+
}, {
|
|
1408
|
+
default: P(() => [
|
|
1409
|
+
D(Ae, {
|
|
1410
|
+
"input-id": `${e.optionsId}-${k.value}-cb`,
|
|
1411
|
+
value: k.value,
|
|
1412
|
+
"model-value": e.selectedOptions
|
|
1413
|
+
}, null, 8, ["input-id", "value", "model-value"]),
|
|
1414
|
+
$("label", {
|
|
1415
|
+
for: `${e.optionsId}-${k.value}-cb`
|
|
1416
|
+
}, A(k.label), 9, oa)
|
|
1417
|
+
]),
|
|
1418
|
+
_: 2
|
|
1419
|
+
}, 1032, ["aria-checked", "value"]))), 128)),
|
|
1420
|
+
ye($("li", ia, sa, 512), [
|
|
1421
|
+
[Be, (T = o.value) == null ? void 0 : T.length]
|
|
1422
|
+
]),
|
|
1423
|
+
(s(!0), v(R, null, G(u.value, (k) => (s(), O(ie, {
|
|
1424
|
+
key: k.value,
|
|
1425
|
+
"aria-checked": e.shown ? "false" : void 0,
|
|
1426
|
+
variant: "2-col",
|
|
1427
|
+
value: k.value
|
|
1428
|
+
}, {
|
|
1429
|
+
default: P(() => [
|
|
1430
|
+
D(Ae, {
|
|
1431
|
+
"input-id": `${e.optionsId}-${k.value}-cb`,
|
|
1432
|
+
value: k.value,
|
|
1433
|
+
"model-value": e.selectedOptions
|
|
1434
|
+
}, null, 8, ["input-id", "value", "model-value"]),
|
|
1435
|
+
$("label", {
|
|
1436
|
+
for: `${e.optionsId}-${k.value}-cb`
|
|
1437
|
+
}, A(k.label), 9, da)
|
|
1438
|
+
]),
|
|
1439
|
+
_: 2
|
|
1440
|
+
}, 1032, ["aria-checked", "value"]))), 128))
|
|
1441
|
+
];
|
|
1442
|
+
}),
|
|
1443
|
+
_: 1
|
|
1444
|
+
}, 8, ["label", "options-id", "shown"]));
|
|
1445
|
+
}
|
|
1446
|
+
}, ca = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1447
|
+
__proto__: null,
|
|
1448
|
+
default: ua
|
|
1449
|
+
}, Symbol.toStringTag, { value: "Module" })), Pe = {
|
|
1297
1450
|
__name: "BsDropdownWithOptions",
|
|
1298
1451
|
props: {
|
|
1299
1452
|
// OPTION LIST PROPS
|
|
@@ -1301,6 +1454,14 @@ const Dt = {
|
|
|
1301
1454
|
type: String,
|
|
1302
1455
|
required: !0
|
|
1303
1456
|
},
|
|
1457
|
+
focusOnShow: {
|
|
1458
|
+
type: Boolean,
|
|
1459
|
+
default: !0
|
|
1460
|
+
},
|
|
1461
|
+
preventTab: {
|
|
1462
|
+
type: Boolean,
|
|
1463
|
+
default: !0
|
|
1464
|
+
},
|
|
1304
1465
|
label: {
|
|
1305
1466
|
type: String,
|
|
1306
1467
|
default: void 0
|
|
@@ -1393,17 +1554,17 @@ const Dt = {
|
|
|
1393
1554
|
"after-leave"
|
|
1394
1555
|
],
|
|
1395
1556
|
setup(e, { emit: a }) {
|
|
1396
|
-
const t = a,
|
|
1397
|
-
function
|
|
1398
|
-
|
|
1557
|
+
const t = a, l = I(!1);
|
|
1558
|
+
function n() {
|
|
1559
|
+
l.value = !0;
|
|
1399
1560
|
}
|
|
1400
1561
|
function o(i) {
|
|
1401
|
-
|
|
1562
|
+
l.value = !1, t("optselected", i), t("update:modelValue", i), t("close");
|
|
1402
1563
|
}
|
|
1403
1564
|
function u() {
|
|
1404
|
-
|
|
1565
|
+
l.value && (l.value = !1, t("close"));
|
|
1405
1566
|
}
|
|
1406
|
-
return (i,
|
|
1567
|
+
return (i, r) => (s(), O(f(Ee), {
|
|
1407
1568
|
shown: e.shown,
|
|
1408
1569
|
preloaded: e.preloaded,
|
|
1409
1570
|
"anchor-id": e.anchorId,
|
|
@@ -1420,69 +1581,32 @@ const Dt = {
|
|
|
1420
1581
|
top: e.top,
|
|
1421
1582
|
width: e.width,
|
|
1422
1583
|
onClose: u,
|
|
1423
|
-
onAfterEnter:
|
|
1424
|
-
onEnter:
|
|
1425
|
-
onAfterLeave:
|
|
1584
|
+
onAfterEnter: r[0] || (r[0] = (d) => t("after-enter")),
|
|
1585
|
+
onEnter: n,
|
|
1586
|
+
onAfterLeave: r[1] || (r[1] = (d) => t("after-leave"))
|
|
1426
1587
|
}, {
|
|
1427
|
-
default:
|
|
1428
|
-
|
|
1588
|
+
default: P(() => [
|
|
1589
|
+
D(f($e), {
|
|
1590
|
+
"focus-on-show": e.focusOnShow,
|
|
1429
1591
|
label: e.label,
|
|
1430
1592
|
"model-value": e.modelValue,
|
|
1431
1593
|
"options-id": e.optionsId,
|
|
1594
|
+
"prevent-tab": e.preventTab,
|
|
1432
1595
|
"selected-value": e.selectedValue,
|
|
1433
|
-
shown:
|
|
1596
|
+
shown: l.value,
|
|
1434
1597
|
"onUpdate:modelValue": o,
|
|
1435
1598
|
onClose: u
|
|
1436
1599
|
}, {
|
|
1437
|
-
default:
|
|
1438
|
-
|
|
1600
|
+
default: P(() => [
|
|
1601
|
+
L(i.$slots, "default")
|
|
1439
1602
|
]),
|
|
1440
1603
|
_: 3
|
|
1441
|
-
}, 8, ["label", "model-value", "options-id", "selected-value", "shown"])
|
|
1604
|
+
}, 8, ["focus-on-show", "label", "model-value", "options-id", "prevent-tab", "selected-value", "shown"])
|
|
1442
1605
|
]),
|
|
1443
1606
|
_: 3
|
|
1444
1607
|
}, 8, ["shown", "preloaded", "anchor-id", "center", "container-id", "enter-controlled", "enter-trigger", "helper-description", "helper-text", "leave-trigger", "position", "right", "toggle-id", "top", "width"]));
|
|
1445
1608
|
}
|
|
1446
|
-
},
|
|
1447
|
-
class: "bs-field-details",
|
|
1448
|
-
"data-component": "bs-field-details"
|
|
1449
|
-
}, aa = ["id", "data-error"], na = ["data-error"], he = {
|
|
1450
|
-
__name: "BsFieldDetails",
|
|
1451
|
-
props: {
|
|
1452
|
-
/** The number of characters that have been entered by the user. */
|
|
1453
|
-
charCount: Number,
|
|
1454
|
-
/** Pass value to show character count and set the maximum number of characters that are allowed to be submitted by the user. */
|
|
1455
|
-
charMax: Number,
|
|
1456
|
-
/** Applies error styles to the helper text. */
|
|
1457
|
-
error: {
|
|
1458
|
-
type: Boolean,
|
|
1459
|
-
default: !1
|
|
1460
|
-
},
|
|
1461
|
-
/** Pass error text. Will be shown if `error` is `true`. */
|
|
1462
|
-
errorMsg: String,
|
|
1463
|
-
/** Pass single helper text. */
|
|
1464
|
-
hint: String,
|
|
1465
|
-
/** Adds an id to associate a hint to an input. */
|
|
1466
|
-
hintId: String
|
|
1467
|
-
},
|
|
1468
|
-
setup(e) {
|
|
1469
|
-
const a = e, t = p(() => a.error && a.errorMsg || a.hint);
|
|
1470
|
-
return (n, l) => (d(), f("div", ta, [
|
|
1471
|
-
t.value ? (d(), f("span", {
|
|
1472
|
-
key: 0,
|
|
1473
|
-
id: e.hintId,
|
|
1474
|
-
class: "bs-hint",
|
|
1475
|
-
"data-error": e.error
|
|
1476
|
-
}, T(t.value), 9, aa)) : S("", !0),
|
|
1477
|
-
e.charMax ? (d(), f("span", {
|
|
1478
|
-
key: 1,
|
|
1479
|
-
"aria-description": "character count over character limit for the preceding text field",
|
|
1480
|
-
class: "bs-character-count",
|
|
1481
|
-
"data-error": a.charCount > a.charMax
|
|
1482
|
-
}, T(a.charCount || "0") + " / " + T(a.charMax), 9, na)) : S("", !0)
|
|
1483
|
-
]));
|
|
1484
|
-
}
|
|
1485
|
-
}, la = ["aria-controls", "aria-expanded", "data-open", "data-size", "disabled"], zn = {
|
|
1609
|
+
}, fa = ["aria-controls", "aria-expanded", "data-open", "data-size", "disabled"], va = {
|
|
1486
1610
|
__name: "BsFilterButton",
|
|
1487
1611
|
props: {
|
|
1488
1612
|
badgeCount: {
|
|
@@ -1511,8 +1635,8 @@ const Dt = {
|
|
|
1511
1635
|
}
|
|
1512
1636
|
},
|
|
1513
1637
|
setup(e) {
|
|
1514
|
-
const a = e, t =
|
|
1515
|
-
return (
|
|
1638
|
+
const a = e, t = g(() => a.badgeCount > 0);
|
|
1639
|
+
return (l, n) => (s(), v("button", {
|
|
1516
1640
|
class: "bs-filter-button",
|
|
1517
1641
|
"aria-controls": e.optionsId,
|
|
1518
1642
|
"aria-expanded": e.open,
|
|
@@ -1522,63 +1646,259 @@ const Dt = {
|
|
|
1522
1646
|
disabled: e.disabled,
|
|
1523
1647
|
type: "button"
|
|
1524
1648
|
}, [
|
|
1525
|
-
t.value ? (
|
|
1649
|
+
t.value ? (s(), O(xt, {
|
|
1526
1650
|
key: 0,
|
|
1527
1651
|
color: "blue",
|
|
1528
1652
|
count: e.badgeCount,
|
|
1529
1653
|
label: "active filter",
|
|
1530
1654
|
position: "left",
|
|
1531
1655
|
variant: "notext"
|
|
1532
|
-
}, null, 8, ["count"])) :
|
|
1533
|
-
|
|
1534
|
-
|
|
1656
|
+
}, null, 8, ["count"])) : w("", !0),
|
|
1657
|
+
L(l.$slots, "label", {}, () => [
|
|
1658
|
+
W(A(e.label), 1)
|
|
1535
1659
|
]),
|
|
1536
|
-
|
|
1537
|
-
], 8,
|
|
1660
|
+
D(f(Ve))
|
|
1661
|
+
], 8, fa));
|
|
1538
1662
|
}
|
|
1539
|
-
},
|
|
1663
|
+
}, pa = ["id"], _n = {
|
|
1664
|
+
__name: "BsDropdownWithToggle",
|
|
1665
|
+
props: {
|
|
1666
|
+
breakout: {
|
|
1667
|
+
type: Boolean,
|
|
1668
|
+
default: !1
|
|
1669
|
+
},
|
|
1670
|
+
disabled: {
|
|
1671
|
+
type: Boolean,
|
|
1672
|
+
default: !1
|
|
1673
|
+
},
|
|
1674
|
+
dropdownLabel: {
|
|
1675
|
+
type: String
|
|
1676
|
+
},
|
|
1677
|
+
dropdownPosition: {
|
|
1678
|
+
type: String,
|
|
1679
|
+
validator: (e) => ["top", "center", "right"].includes(e)
|
|
1680
|
+
},
|
|
1681
|
+
dropdownWidth: {
|
|
1682
|
+
type: String,
|
|
1683
|
+
validator: (e) => ["sm", "md", "lg", "content", "toggle"].includes(e)
|
|
1684
|
+
},
|
|
1685
|
+
helperText: {
|
|
1686
|
+
type: String
|
|
1687
|
+
},
|
|
1688
|
+
helperDescription: {
|
|
1689
|
+
type: String
|
|
1690
|
+
},
|
|
1691
|
+
multiselect: {
|
|
1692
|
+
type: Boolean,
|
|
1693
|
+
default: !1
|
|
1694
|
+
},
|
|
1695
|
+
open: {
|
|
1696
|
+
type: Boolean,
|
|
1697
|
+
default: !0
|
|
1698
|
+
},
|
|
1699
|
+
options: {
|
|
1700
|
+
type: Array,
|
|
1701
|
+
default: () => []
|
|
1702
|
+
},
|
|
1703
|
+
selectedOption: {
|
|
1704
|
+
type: [String, Number]
|
|
1705
|
+
},
|
|
1706
|
+
selectedOptions: {
|
|
1707
|
+
type: Array,
|
|
1708
|
+
default: () => []
|
|
1709
|
+
},
|
|
1710
|
+
toggleLabel: {
|
|
1711
|
+
type: String,
|
|
1712
|
+
default: "Filter"
|
|
1713
|
+
},
|
|
1714
|
+
toggleSize: {
|
|
1715
|
+
type: String,
|
|
1716
|
+
validator: (e) => ["sm", "xs"].includes(e)
|
|
1717
|
+
}
|
|
1718
|
+
},
|
|
1719
|
+
emits: ["update:selectedOptions", "update:selectedOption", "toggled", "close"],
|
|
1720
|
+
setup(e, { emit: a }) {
|
|
1721
|
+
const t = e, l = a, n = I(!1), o = I(!1), u = I(null), i = g(() => me(async () => await (t.multiselect ? Promise.resolve().then(() => ca) : Promise.resolve().then(() => la)))), [r, d, c] = K(3);
|
|
1722
|
+
z(o, (y) => {
|
|
1723
|
+
y && u.value.$el.blur();
|
|
1724
|
+
}), F(() => {
|
|
1725
|
+
k(), oe(() => n.value = !0);
|
|
1726
|
+
}), _(E);
|
|
1727
|
+
function p() {
|
|
1728
|
+
o.value = !1, l("close"), u.value.$el.focus();
|
|
1729
|
+
}
|
|
1730
|
+
function h() {
|
|
1731
|
+
o.value && p();
|
|
1732
|
+
}
|
|
1733
|
+
function m() {
|
|
1734
|
+
o.value = !0;
|
|
1735
|
+
}
|
|
1736
|
+
function V(y) {
|
|
1737
|
+
l("update:selectedOptions", y);
|
|
1738
|
+
}
|
|
1739
|
+
function T(y) {
|
|
1740
|
+
t.multiselect || (l("update:selectedOption", y), p());
|
|
1741
|
+
}
|
|
1742
|
+
function k() {
|
|
1743
|
+
if (t.breakout) {
|
|
1744
|
+
const y = document.querySelector("body"), b = document.createElement("div");
|
|
1745
|
+
b.id = d.value, b.style.position = "absolute", y.insertAdjacentElement("afterbegin", b);
|
|
1746
|
+
}
|
|
1747
|
+
}
|
|
1748
|
+
function E() {
|
|
1749
|
+
t.breakout && document.querySelector(`#${d.value}`).remove();
|
|
1750
|
+
}
|
|
1751
|
+
return (y, b) => (s(), v("div", {
|
|
1752
|
+
class: "bs-dropdown-with-toggle",
|
|
1753
|
+
id: e.breakout ? y.$attrs.id : y.$attrs.id || f(d)
|
|
1754
|
+
}, [
|
|
1755
|
+
D(va, {
|
|
1756
|
+
ref_key: "toggleRef",
|
|
1757
|
+
ref: u,
|
|
1758
|
+
disabled: e.disabled,
|
|
1759
|
+
id: f(r),
|
|
1760
|
+
open: e.open,
|
|
1761
|
+
"options-id": f(c),
|
|
1762
|
+
size: e.toggleSize,
|
|
1763
|
+
onClick: b[0] || (b[0] = (S) => y.$emit("toggled"))
|
|
1764
|
+
}, {
|
|
1765
|
+
label: P(() => [
|
|
1766
|
+
L(y.$slots, "toggle-label", {}, () => [
|
|
1767
|
+
W(A(e.toggleLabel), 1)
|
|
1768
|
+
])
|
|
1769
|
+
]),
|
|
1770
|
+
_: 3
|
|
1771
|
+
}, 8, ["disabled", "id", "open", "options-id", "size"]),
|
|
1772
|
+
n.value ? (s(), O(Je, {
|
|
1773
|
+
key: 0,
|
|
1774
|
+
disabled: !e.breakout,
|
|
1775
|
+
to: e.breakout ? `#${f(d)}` : void 0
|
|
1776
|
+
}, [
|
|
1777
|
+
D(Ee, {
|
|
1778
|
+
shown: e.open,
|
|
1779
|
+
"anchor-id": f(r),
|
|
1780
|
+
"container-id": e.breakout ? f(d) : y.$attrs.id || f(d),
|
|
1781
|
+
"helper-text": e.helperText,
|
|
1782
|
+
"helper-description": e.helperDescription,
|
|
1783
|
+
position: e.dropdownPosition,
|
|
1784
|
+
preloaded: "",
|
|
1785
|
+
width: e.dropdownWidth,
|
|
1786
|
+
onClose: h,
|
|
1787
|
+
onEnter: m
|
|
1788
|
+
}, {
|
|
1789
|
+
default: P(() => [
|
|
1790
|
+
D(f(i), {
|
|
1791
|
+
label: e.dropdownLabel,
|
|
1792
|
+
"model-value": e.selectedOption,
|
|
1793
|
+
options: e.options,
|
|
1794
|
+
"options-id": f(c),
|
|
1795
|
+
"selected-options": e.selectedOptions,
|
|
1796
|
+
shown: e.open,
|
|
1797
|
+
"onUpdate:modelValue": T,
|
|
1798
|
+
"onUpdate:selectedOptions": V,
|
|
1799
|
+
onClose: b[1] || (b[1] = (S) => e.multiselect ? void 0 : h())
|
|
1800
|
+
}, {
|
|
1801
|
+
default: P(() => [
|
|
1802
|
+
e.multiselect ? w("", !0) : (s(!0), v(R, { key: 0 }, G(e.options, (S) => (s(), O(ie, {
|
|
1803
|
+
key: S.value,
|
|
1804
|
+
value: S.value
|
|
1805
|
+
}, {
|
|
1806
|
+
default: P(() => [
|
|
1807
|
+
W(A(S.label), 1)
|
|
1808
|
+
]),
|
|
1809
|
+
_: 2
|
|
1810
|
+
}, 1032, ["value"]))), 128))
|
|
1811
|
+
]),
|
|
1812
|
+
_: 1
|
|
1813
|
+
}, 8, ["label", "model-value", "options", "options-id", "selected-options", "shown"])
|
|
1814
|
+
]),
|
|
1815
|
+
_: 1
|
|
1816
|
+
}, 8, ["shown", "anchor-id", "container-id", "helper-text", "helper-description", "position", "width"])
|
|
1817
|
+
], 8, ["disabled", "to"])) : w("", !0)
|
|
1818
|
+
], 8, pa));
|
|
1819
|
+
}
|
|
1820
|
+
}, ha = {
|
|
1821
|
+
class: "bs-field-details",
|
|
1822
|
+
"data-component": "bs-field-details"
|
|
1823
|
+
}, ba = ["id", "data-error"], ga = ["data-error"], Se = {
|
|
1824
|
+
__name: "BsFieldDetails",
|
|
1825
|
+
props: {
|
|
1826
|
+
/** The number of characters that have been entered by the user. */
|
|
1827
|
+
charCount: Number,
|
|
1828
|
+
/** Pass value to show character count and set the maximum number of characters that are allowed to be submitted by the user. */
|
|
1829
|
+
charMax: Number,
|
|
1830
|
+
/** Applies error styles to the helper text. */
|
|
1831
|
+
error: {
|
|
1832
|
+
type: Boolean,
|
|
1833
|
+
default: !1
|
|
1834
|
+
},
|
|
1835
|
+
/** Pass error text. Will be shown if `error` is `true`. */
|
|
1836
|
+
errorMsg: String,
|
|
1837
|
+
/** Pass single helper text. */
|
|
1838
|
+
hint: String,
|
|
1839
|
+
/** Adds an id to associate a hint to an input. */
|
|
1840
|
+
hintId: String
|
|
1841
|
+
},
|
|
1842
|
+
setup(e) {
|
|
1843
|
+
const a = e, t = g(() => a.error && a.errorMsg || a.hint);
|
|
1844
|
+
return (l, n) => (s(), v("div", ha, [
|
|
1845
|
+
t.value ? (s(), v("span", {
|
|
1846
|
+
key: 0,
|
|
1847
|
+
id: e.hintId,
|
|
1848
|
+
class: "bs-hint",
|
|
1849
|
+
"data-error": e.error
|
|
1850
|
+
}, A(t.value), 9, ba)) : w("", !0),
|
|
1851
|
+
e.charMax ? (s(), v("span", {
|
|
1852
|
+
key: 1,
|
|
1853
|
+
"aria-description": "character count over character limit for the preceding text field",
|
|
1854
|
+
class: "bs-character-count",
|
|
1855
|
+
"data-error": a.charCount > a.charMax
|
|
1856
|
+
}, A(a.charCount || "0") + " / " + A(a.charMax), 9, ga)) : w("", !0)
|
|
1857
|
+
]));
|
|
1858
|
+
}
|
|
1859
|
+
}, ma = ["view-box"], ya = ["id"], Ba = ["offset", "stop-color"], el = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1540
1860
|
__name: "BsIconGradientWrapper",
|
|
1541
1861
|
setup(e) {
|
|
1542
|
-
const a = I(null), t = I(null),
|
|
1862
|
+
const a = I(null), t = I(null), l = [
|
|
1543
1863
|
{ offset: 0.1326, color: "#EE282A" },
|
|
1544
1864
|
{ offset: 0.5466, color: "#1C0087" },
|
|
1545
1865
|
{ offset: 0.9715, color: "#0086EA" }
|
|
1546
|
-
], [
|
|
1547
|
-
return
|
|
1866
|
+
], [n] = K();
|
|
1867
|
+
return F(() => {
|
|
1548
1868
|
t.value = a.value.querySelector("svg").getAttribute("viewBox") || "0 0 0 0";
|
|
1549
|
-
}), (o, u) => (
|
|
1550
|
-
|
|
1869
|
+
}), (o, u) => (s(), v(R, null, [
|
|
1870
|
+
$("span", M({
|
|
1551
1871
|
ref_key: "svgWrapperRef",
|
|
1552
1872
|
ref: a,
|
|
1553
1873
|
class: "bs-icon-gradient-wrapper",
|
|
1554
|
-
style: `fill: url(#${
|
|
1874
|
+
style: `fill: url(#${f(n)});`
|
|
1555
1875
|
}, o.$attrs), [
|
|
1556
|
-
|
|
1876
|
+
L(o.$slots, "default")
|
|
1557
1877
|
], 16),
|
|
1558
|
-
(
|
|
1878
|
+
(s(), v("svg", {
|
|
1559
1879
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1560
1880
|
"view-box": t.value,
|
|
1561
1881
|
width: "0",
|
|
1562
1882
|
height: "0"
|
|
1563
1883
|
}, [
|
|
1564
|
-
|
|
1565
|
-
id:
|
|
1884
|
+
$("linearGradient", {
|
|
1885
|
+
id: f(n),
|
|
1566
1886
|
x1: "0",
|
|
1567
1887
|
y1: "0",
|
|
1568
1888
|
x2: "100%",
|
|
1569
1889
|
y2: "100%",
|
|
1570
1890
|
"gradient-units": "userSpaceOnUse"
|
|
1571
1891
|
}, [
|
|
1572
|
-
(
|
|
1892
|
+
(s(), v(R, null, G(l, (i) => $("stop", {
|
|
1573
1893
|
key: i.offset,
|
|
1574
1894
|
offset: i.offset,
|
|
1575
1895
|
"stop-color": i.color
|
|
1576
|
-
}, null, 8,
|
|
1577
|
-
], 8,
|
|
1578
|
-
], 8,
|
|
1896
|
+
}, null, 8, Ba)), 64))
|
|
1897
|
+
], 8, ya)
|
|
1898
|
+
], 8, ma))
|
|
1579
1899
|
], 64));
|
|
1580
1900
|
}
|
|
1581
|
-
}),
|
|
1901
|
+
}), $a = ["data-error", "id", "value"], Oe = {
|
|
1582
1902
|
__name: "BsInput",
|
|
1583
1903
|
props: {
|
|
1584
1904
|
error: {
|
|
@@ -1593,21 +1913,21 @@ const Dt = {
|
|
|
1593
1913
|
},
|
|
1594
1914
|
emits: ["update:modelValue"],
|
|
1595
1915
|
setup(e, { emit: a }) {
|
|
1596
|
-
const t = e,
|
|
1916
|
+
const t = e, l = a, n = U(), o = g(() => ({ [t.error ? "aria-errormessage" : "aria-describedby"]: t.hintId }));
|
|
1597
1917
|
function u(i) {
|
|
1598
|
-
const
|
|
1599
|
-
|
|
1918
|
+
const r = n.type === "number" ? parseInt(i.target.value) : i.target.value;
|
|
1919
|
+
l("update:modelValue", r);
|
|
1600
1920
|
}
|
|
1601
|
-
return (i,
|
|
1921
|
+
return (i, r) => (s(), v("input", M({
|
|
1602
1922
|
class: "bs-input",
|
|
1603
1923
|
"data-component": "bs-input",
|
|
1604
1924
|
"data-error": e.error,
|
|
1605
1925
|
id: i.$attrs.id || e.inputId,
|
|
1606
1926
|
value: e.value || e.modelValue,
|
|
1607
1927
|
onInput: u
|
|
1608
|
-
}, o.value), null, 16,
|
|
1928
|
+
}, o.value), null, 16, $a));
|
|
1609
1929
|
}
|
|
1610
|
-
},
|
|
1930
|
+
}, Sa = ["data-disabled", "data-error", "data-variant", "data-multifocus"], wa = {
|
|
1611
1931
|
__name: "BsInputAddon",
|
|
1612
1932
|
props: {
|
|
1613
1933
|
disabled: { type: Boolean, default: !1 },
|
|
@@ -1616,7 +1936,7 @@ const Dt = {
|
|
|
1616
1936
|
variant: { type: String, validator: (e) => e === "inner-bordered" }
|
|
1617
1937
|
},
|
|
1618
1938
|
setup(e) {
|
|
1619
|
-
return (a, t) => (
|
|
1939
|
+
return (a, t) => (s(), v("div", {
|
|
1620
1940
|
class: "bs-input-addon",
|
|
1621
1941
|
"data-component": "bs-input-addon",
|
|
1622
1942
|
"data-disabled": e.disabled,
|
|
@@ -1624,10 +1944,10 @@ const Dt = {
|
|
|
1624
1944
|
"data-variant": e.variant,
|
|
1625
1945
|
"data-multifocus": e.multifocus
|
|
1626
1946
|
}, [
|
|
1627
|
-
|
|
1628
|
-
], 8,
|
|
1947
|
+
L(a.$slots, "default")
|
|
1948
|
+
], 8, Sa));
|
|
1629
1949
|
}
|
|
1630
|
-
},
|
|
1950
|
+
}, tl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1631
1951
|
__name: "BsInputField",
|
|
1632
1952
|
props: {
|
|
1633
1953
|
/** Sets the disabled state on input, disabled styles on label. */
|
|
@@ -1674,7 +1994,7 @@ const Dt = {
|
|
|
1674
1994
|
},
|
|
1675
1995
|
emits: ["update:modelValue"],
|
|
1676
1996
|
setup(e, { emit: a }) {
|
|
1677
|
-
const t = e,
|
|
1997
|
+
const t = e, l = U(), [n, o] = K(2), { toChild: u, toRoot: i } = ae(t, l, [
|
|
1678
1998
|
"aria-label",
|
|
1679
1999
|
"autocomplete",
|
|
1680
2000
|
"max",
|
|
@@ -1682,46 +2002,46 @@ const Dt = {
|
|
|
1682
2002
|
"min",
|
|
1683
2003
|
"minlength",
|
|
1684
2004
|
"name"
|
|
1685
|
-
]),
|
|
1686
|
-
var
|
|
1687
|
-
return ((
|
|
2005
|
+
]), r = g(() => {
|
|
2006
|
+
var p, h;
|
|
2007
|
+
return ((h = (p = t.hints) == null ? void 0 : p.join) == null ? void 0 : h.call(p, `
|
|
1688
2008
|
`)) || t.hints;
|
|
1689
|
-
}),
|
|
1690
|
-
return (
|
|
1691
|
-
e.label ||
|
|
2009
|
+
}), d = g(() => t.error && t.errorMsg || t.hint || r.value || void 0), c = g(() => t.inputId || n.value);
|
|
2010
|
+
return (p, h) => (s(), v("div", M({ "data-component": "bs-input-field" }, f(i)), [
|
|
2011
|
+
e.label || p.$slots.label ? (s(), O(ne, {
|
|
1692
2012
|
key: 0,
|
|
1693
2013
|
for: c.value,
|
|
1694
2014
|
disabled: e.disabled,
|
|
1695
2015
|
required: e.required
|
|
1696
2016
|
}, {
|
|
1697
|
-
default:
|
|
1698
|
-
|
|
1699
|
-
|
|
2017
|
+
default: P(() => [
|
|
2018
|
+
L(p.$slots, "label", {}, () => [
|
|
2019
|
+
W(A(e.label), 1)
|
|
1700
2020
|
])
|
|
1701
2021
|
]),
|
|
1702
2022
|
_: 3
|
|
1703
|
-
}, 8, ["for", "disabled", "required"])) :
|
|
1704
|
-
|
|
2023
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0),
|
|
2024
|
+
D(Oe, M({
|
|
1705
2025
|
disabled: e.disabled,
|
|
1706
2026
|
error: e.error,
|
|
1707
|
-
"hint-id":
|
|
2027
|
+
"hint-id": f(o),
|
|
1708
2028
|
id: c.value,
|
|
1709
2029
|
placeholder: e.placeholder,
|
|
1710
2030
|
required: e.required,
|
|
1711
2031
|
type: e.type,
|
|
1712
2032
|
value: e.value || e.modelValue,
|
|
1713
|
-
"onUpdate:modelValue":
|
|
1714
|
-
},
|
|
1715
|
-
|
|
2033
|
+
"onUpdate:modelValue": h[0] || (h[0] = (m) => p.$emit("update:modelValue", m))
|
|
2034
|
+
}, f(u)), null, 16, ["disabled", "error", "hint-id", "id", "placeholder", "required", "type", "value"]),
|
|
2035
|
+
d.value ? (s(), O(Se, {
|
|
1716
2036
|
key: 1,
|
|
1717
2037
|
error: e.error,
|
|
1718
2038
|
"error-msg": e.errorMsg,
|
|
1719
|
-
hint: e.hint ||
|
|
1720
|
-
"hint-id":
|
|
1721
|
-
}, null, 8, ["error", "error-msg", "hint", "hint-id"])) :
|
|
2039
|
+
hint: e.hint || r.value,
|
|
2040
|
+
"hint-id": f(o)
|
|
2041
|
+
}, null, 8, ["error", "error-msg", "hint", "hint-id"])) : w("", !0)
|
|
1722
2042
|
], 16));
|
|
1723
2043
|
}
|
|
1724
|
-
}),
|
|
2044
|
+
}), ka = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1725
2045
|
__name: "BsInputSearch",
|
|
1726
2046
|
props: {
|
|
1727
2047
|
/** Sets the disabled state on input, disabled styles on label. */
|
|
@@ -1733,7 +2053,14 @@ const Dt = {
|
|
|
1733
2053
|
type: Boolean,
|
|
1734
2054
|
default: !1
|
|
1735
2055
|
},
|
|
1736
|
-
|
|
2056
|
+
hideSearchIcon: {
|
|
2057
|
+
type: Boolean,
|
|
2058
|
+
default: !1
|
|
2059
|
+
},
|
|
2060
|
+
inputId: {
|
|
2061
|
+
type: String,
|
|
2062
|
+
default: void 0
|
|
2063
|
+
},
|
|
1737
2064
|
modelValue: {
|
|
1738
2065
|
type: String,
|
|
1739
2066
|
default: ""
|
|
@@ -1759,48 +2086,235 @@ const Dt = {
|
|
|
1759
2086
|
},
|
|
1760
2087
|
emits: ["clear", "update:modelValue"],
|
|
1761
2088
|
setup(e, { emit: a }) {
|
|
1762
|
-
const t = e,
|
|
2089
|
+
const t = e, l = U(), { toChild: n, toRoot: o } = ae(t, l, [
|
|
1763
2090
|
"aria-label",
|
|
1764
2091
|
"autocomplete",
|
|
1765
2092
|
"maxlength",
|
|
1766
2093
|
"minlength",
|
|
1767
2094
|
"name"
|
|
1768
|
-
]), u =
|
|
1769
|
-
return (i,
|
|
2095
|
+
]), u = g(() => !t.disabled && !t.hideClear && t.variant !== "filter");
|
|
2096
|
+
return (i, r) => (s(), O(wa, M({
|
|
1770
2097
|
class: "bs-input-search",
|
|
1771
2098
|
"data-component": "bs-input-search",
|
|
1772
2099
|
"data-variant": e.variant,
|
|
1773
2100
|
disabled: e.disabled
|
|
1774
|
-
},
|
|
1775
|
-
default:
|
|
1776
|
-
|
|
1777
|
-
|
|
2101
|
+
}, f(o)), {
|
|
2102
|
+
default: P(() => [
|
|
2103
|
+
e.hideSearchIcon ? w("", !0) : (s(), O(f(at), { key: 0 })),
|
|
2104
|
+
D(Oe, M({
|
|
1778
2105
|
"data-autowidth": "",
|
|
1779
2106
|
disabled: e.disabled,
|
|
1780
2107
|
"input-id": e.inputId,
|
|
1781
2108
|
placeholder: e.placeholder,
|
|
1782
2109
|
value: e.value || e.modelValue,
|
|
1783
|
-
"onUpdate:modelValue":
|
|
1784
|
-
},
|
|
1785
|
-
|
|
1786
|
-
key: 0,
|
|
2110
|
+
"onUpdate:modelValue": r[0] || (r[0] = (d) => i.$emit("update:modelValue", d))
|
|
2111
|
+
}, f(n)), null, 16, ["disabled", "input-id", "placeholder", "value"]),
|
|
2112
|
+
ye($("button", {
|
|
1787
2113
|
title: "Clear",
|
|
1788
2114
|
type: "button",
|
|
1789
|
-
onClick:
|
|
2115
|
+
onClick: r[1] || (r[1] = (d) => i.$emit("clear"))
|
|
1790
2116
|
}, [
|
|
1791
|
-
|
|
1792
|
-
])
|
|
2117
|
+
D(f(de), { size: "sm" })
|
|
2118
|
+
], 512), [
|
|
2119
|
+
[Be, u.value]
|
|
2120
|
+
])
|
|
1793
2121
|
]),
|
|
1794
2122
|
_: 1
|
|
1795
2123
|
}, 16, ["data-variant", "disabled"]));
|
|
1796
2124
|
}
|
|
1797
|
-
}),
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
2125
|
+
}), De = (e, a) => {
|
|
2126
|
+
const t = e.__vccOpts || e;
|
|
2127
|
+
for (const [l, n] of a)
|
|
2128
|
+
t[l] = n;
|
|
2129
|
+
return t;
|
|
2130
|
+
}, Ia = { key: 0 }, Ta = ["innerHTML"], xa = { key: 1 }, Ca = {
|
|
2131
|
+
key: 0,
|
|
2132
|
+
class: "bs-empty-option"
|
|
2133
|
+
}, Aa = {
|
|
2134
|
+
__name: "BsInputTypeahead",
|
|
2135
|
+
props: {
|
|
2136
|
+
characterThreshold: {
|
|
2137
|
+
type: Number,
|
|
2138
|
+
default: 1
|
|
2139
|
+
},
|
|
2140
|
+
disabled: {
|
|
2141
|
+
type: Boolean,
|
|
2142
|
+
default: !1
|
|
2143
|
+
},
|
|
2144
|
+
filterType: {
|
|
2145
|
+
type: String,
|
|
2146
|
+
default: "starts-with",
|
|
2147
|
+
validator: (e) => ["includes", "starts-with"].includes(e)
|
|
2148
|
+
},
|
|
2149
|
+
hideSearchIcon: {
|
|
2150
|
+
type: Boolean,
|
|
2151
|
+
default: !1
|
|
2152
|
+
},
|
|
2153
|
+
inputValue: {
|
|
2154
|
+
type: String,
|
|
2155
|
+
default: ""
|
|
2156
|
+
},
|
|
2157
|
+
internalFiltering: {
|
|
2158
|
+
type: Boolean,
|
|
2159
|
+
default: !0
|
|
2160
|
+
},
|
|
2161
|
+
label: {
|
|
2162
|
+
type: String,
|
|
2163
|
+
default: ""
|
|
2164
|
+
},
|
|
2165
|
+
maxOptions: {
|
|
2166
|
+
type: Number,
|
|
2167
|
+
default: void 0
|
|
2168
|
+
},
|
|
2169
|
+
// [{ label: String, value: String, description: String, icon: String }] }
|
|
2170
|
+
options: {
|
|
2171
|
+
type: Array,
|
|
2172
|
+
required: !0
|
|
2173
|
+
},
|
|
2174
|
+
optionsValue: {
|
|
2175
|
+
type: [String, Number],
|
|
2176
|
+
default: ""
|
|
2177
|
+
},
|
|
2178
|
+
placeholder: {
|
|
2179
|
+
type: String,
|
|
2180
|
+
default: ""
|
|
2181
|
+
},
|
|
2182
|
+
required: {
|
|
2183
|
+
type: Boolean,
|
|
2184
|
+
default: !1
|
|
2185
|
+
},
|
|
2186
|
+
typeaheadId: {
|
|
2187
|
+
type: String,
|
|
2188
|
+
required: !0
|
|
2189
|
+
}
|
|
2190
|
+
},
|
|
2191
|
+
emits: ["update:inputValue", "update:optionsValue"],
|
|
2192
|
+
setup(e, { emit: a }) {
|
|
2193
|
+
const t = e, l = a, n = I(!1), o = I(!1), u = {};
|
|
2194
|
+
let i = [];
|
|
2195
|
+
Qe(() => {
|
|
2196
|
+
t.options.forEach((b) => {
|
|
2197
|
+
const { icon: S } = b;
|
|
2198
|
+
S && !u[S] && (u[S] = T(S));
|
|
2199
|
+
});
|
|
2200
|
+
}), z(() => t.inputValue, () => {
|
|
2201
|
+
o.value ? o.value = !1 : k();
|
|
2202
|
+
});
|
|
2203
|
+
const r = g(() => `${t.typeaheadId}-input-addon`), d = g(() => `${t.typeaheadId}-input`), c = g(() => `${t.typeaheadId}-options`), p = g(() => {
|
|
2204
|
+
if (n.value) {
|
|
2205
|
+
let b = t.options;
|
|
2206
|
+
const S = t.inputValue.toLowerCase(), x = t.filterType === "includes" ? "includes" : "startsWith";
|
|
2207
|
+
return b = h(b, S, x), b = b.slice(0, t.maxOptions), b = m(b, S, x), i = b, b;
|
|
2208
|
+
} else
|
|
2209
|
+
return i;
|
|
2210
|
+
});
|
|
2211
|
+
function h(b, S, x) {
|
|
2212
|
+
return t.internalFiltering ? b.filter((N) => N.label.toLowerCase()[x](S)) : b;
|
|
2213
|
+
}
|
|
2214
|
+
function m(b, S, x) {
|
|
2215
|
+
return b.map((N) => {
|
|
2216
|
+
let re = N.label;
|
|
2217
|
+
if (S !== "") {
|
|
2218
|
+
const Z = x === "includes" ? "gi" : "i", le = new RegExp(`(${S})`, Z);
|
|
2219
|
+
re = N.label.replace(le, '<span style="color: var(--bs-blue-base)">$1</span>');
|
|
2220
|
+
}
|
|
2221
|
+
return { ...N, labelHtml: re };
|
|
2222
|
+
});
|
|
2223
|
+
}
|
|
2224
|
+
function V(b) {
|
|
2225
|
+
let S = "";
|
|
2226
|
+
return b.icon && (S += " 2-col"), b.description && (S += " description"), S;
|
|
2227
|
+
}
|
|
2228
|
+
function T(b) {
|
|
2229
|
+
return me(async () => {
|
|
2230
|
+
const { [`BsIcon${b}`]: S } = await import("@wwtdev/bsds-icons-vue3");
|
|
2231
|
+
return S;
|
|
2232
|
+
});
|
|
2233
|
+
}
|
|
2234
|
+
function k() {
|
|
2235
|
+
t.inputValue.length >= t.characterThreshold ? n.value = !0 : n.value = !1;
|
|
2236
|
+
}
|
|
2237
|
+
function E() {
|
|
2238
|
+
l("update:inputValue", ""), l("update:optionsValue", ""), document.getElementById(d.value).focus();
|
|
2239
|
+
}
|
|
2240
|
+
function y(b) {
|
|
2241
|
+
o.value = !0, n.value = !1;
|
|
2242
|
+
const S = p.value.find((x) => x.value === b);
|
|
2243
|
+
l("update:inputValue", S.label), l("update:optionsValue", b);
|
|
2244
|
+
}
|
|
2245
|
+
return (b, S) => (s(), v(R, null, [
|
|
2246
|
+
e.label || b.$slots.label ? (s(), O(f(ne), {
|
|
2247
|
+
key: 0,
|
|
2248
|
+
for: d.value,
|
|
2249
|
+
disabled: e.disabled,
|
|
2250
|
+
required: e.required
|
|
2251
|
+
}, {
|
|
2252
|
+
default: P(() => [
|
|
2253
|
+
L(b.$slots, "label", {}, () => [
|
|
2254
|
+
W(A(e.label), 1)
|
|
2255
|
+
], !0)
|
|
2256
|
+
]),
|
|
2257
|
+
_: 3
|
|
2258
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0),
|
|
2259
|
+
D(f(ka), M({
|
|
2260
|
+
"aria-controls": c.value,
|
|
2261
|
+
"aria-expanded": n.value,
|
|
2262
|
+
"aria-haspopup": "listbox",
|
|
2263
|
+
autocomplete: "off",
|
|
2264
|
+
disabled: e.disabled,
|
|
2265
|
+
"hide-clear": e.inputValue === "",
|
|
2266
|
+
"hide-search-icon": e.hideSearchIcon,
|
|
2267
|
+
id: r.value,
|
|
2268
|
+
"input-id": d.value,
|
|
2269
|
+
placeholder: e.placeholder,
|
|
2270
|
+
value: e.inputValue
|
|
2271
|
+
}, b.$attrs, {
|
|
2272
|
+
onClear: E,
|
|
2273
|
+
onFocusin: k,
|
|
2274
|
+
"onUpdate:modelValue": S[0] || (S[0] = (x) => l("update:inputValue", x))
|
|
2275
|
+
}), null, 16, ["aria-controls", "aria-expanded", "disabled", "hide-clear", "hide-search-icon", "id", "input-id", "placeholder", "value"]),
|
|
2276
|
+
D(f(Pe), {
|
|
2277
|
+
"anchor-id": r.value,
|
|
2278
|
+
"focus-on-show": !1,
|
|
2279
|
+
"model-value": e.optionsValue,
|
|
2280
|
+
"options-id": c.value,
|
|
2281
|
+
preloaded: !0,
|
|
2282
|
+
"prevent-tab": !1,
|
|
2283
|
+
shown: n.value,
|
|
2284
|
+
width: "toggle",
|
|
2285
|
+
onClose: S[1] || (S[1] = (x) => n.value = !1),
|
|
2286
|
+
"onUpdate:modelValue": y
|
|
2287
|
+
}, {
|
|
2288
|
+
default: P(() => [
|
|
2289
|
+
(s(!0), v(R, null, G(p.value, (x) => (s(), O(f(ie), {
|
|
2290
|
+
key: x.value,
|
|
2291
|
+
value: x.value,
|
|
2292
|
+
variant: V(x)
|
|
2293
|
+
}, {
|
|
2294
|
+
default: P(() => [
|
|
2295
|
+
x.icon ? (s(), v("span", Ia, [
|
|
2296
|
+
(s(), O(H(u[x.icon])))
|
|
2297
|
+
])) : w("", !0),
|
|
2298
|
+
$("span", {
|
|
2299
|
+
innerHTML: x.labelHtml
|
|
2300
|
+
}, null, 8, Ta),
|
|
2301
|
+
x.description ? (s(), v("span", xa, A(x.description), 1)) : w("", !0)
|
|
2302
|
+
]),
|
|
2303
|
+
_: 2
|
|
2304
|
+
}, 1032, ["value", "variant"]))), 128)),
|
|
2305
|
+
p.value.length === 0 ? (s(), v("li", Ca, " No results found ")) : w("", !0)
|
|
2306
|
+
]),
|
|
2307
|
+
_: 1
|
|
2308
|
+
}, 8, ["anchor-id", "model-value", "options-id", "shown"])
|
|
2309
|
+
], 64));
|
|
2310
|
+
}
|
|
2311
|
+
}, al = /* @__PURE__ */ De(Aa, [["__scopeId", "data-v-730b56e5"]]), La = ["data-size", "data-variant"], Va = /* @__PURE__ */ $("span", null, null, -1), Ea = /* @__PURE__ */ $("span", null, null, -1), Pa = /* @__PURE__ */ $("span", null, null, -1), Oa = /* @__PURE__ */ $("span", null, null, -1), Da = /* @__PURE__ */ $("span", { class: "visually-hidden" }, "Loading", -1), qa = [
|
|
2312
|
+
Va,
|
|
2313
|
+
Ea,
|
|
2314
|
+
Pa,
|
|
2315
|
+
Oa,
|
|
2316
|
+
Da
|
|
2317
|
+
], nl = {
|
|
1804
2318
|
__name: "BsLoader",
|
|
1805
2319
|
props: {
|
|
1806
2320
|
size: {
|
|
@@ -1814,14 +2328,14 @@ const Dt = {
|
|
|
1814
2328
|
}
|
|
1815
2329
|
},
|
|
1816
2330
|
setup(e) {
|
|
1817
|
-
return (a, t) => (
|
|
2331
|
+
return (a, t) => (s(), v("span", {
|
|
1818
2332
|
class: "bs-loader",
|
|
1819
2333
|
"data-size": e.size,
|
|
1820
2334
|
"data-variant": e.variant,
|
|
1821
2335
|
role: "status"
|
|
1822
|
-
},
|
|
2336
|
+
}, qa, 8, La));
|
|
1823
2337
|
}
|
|
1824
|
-
},
|
|
2338
|
+
}, Ma = /* @__PURE__ */ $("div", { class: "bs-overlay" }, null, -1), za = {
|
|
1825
2339
|
__name: "BsOverlay",
|
|
1826
2340
|
props: {
|
|
1827
2341
|
shown: {
|
|
@@ -1850,31 +2364,35 @@ const Dt = {
|
|
|
1850
2364
|
},
|
|
1851
2365
|
emits: ["after-enter", "after-leave"],
|
|
1852
2366
|
setup(e, { emit: a }) {
|
|
1853
|
-
const t = e,
|
|
1854
|
-
return (o, u) => (
|
|
1855
|
-
shown:
|
|
2367
|
+
const t = e, l = a, { transition: n } = ve(t);
|
|
2368
|
+
return (o, u) => (s(), O(f(pe), {
|
|
2369
|
+
shown: f(n),
|
|
1856
2370
|
preloaded: e.preloaded,
|
|
1857
2371
|
duration: 75,
|
|
1858
2372
|
"enter-attribute": "data-shown",
|
|
1859
|
-
onAfterEnter: u[0] || (u[0] = (i) =>
|
|
1860
|
-
onAfterLeave: u[1] || (u[1] = (i) =>
|
|
2373
|
+
onAfterEnter: u[0] || (u[0] = (i) => l("after-enter")),
|
|
2374
|
+
onAfterLeave: u[1] || (u[1] = (i) => l("after-leave"))
|
|
1861
2375
|
}, {
|
|
1862
|
-
default:
|
|
1863
|
-
|
|
2376
|
+
default: P(() => [
|
|
2377
|
+
Ma
|
|
1864
2378
|
]),
|
|
1865
2379
|
_: 1
|
|
1866
2380
|
}, 8, ["shown", "preloaded"]));
|
|
1867
2381
|
}
|
|
1868
|
-
},
|
|
2382
|
+
}, Ra = ["id", "role"], Na = {
|
|
1869
2383
|
key: 0,
|
|
1870
|
-
class: "
|
|
1871
|
-
},
|
|
2384
|
+
class: "modal-title"
|
|
2385
|
+
}, ll = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1872
2386
|
__name: "BsModal",
|
|
1873
2387
|
props: {
|
|
1874
2388
|
modalId: {
|
|
1875
2389
|
type: String,
|
|
1876
2390
|
default: void 0
|
|
1877
2391
|
},
|
|
2392
|
+
title: {
|
|
2393
|
+
type: String,
|
|
2394
|
+
required: !1
|
|
2395
|
+
},
|
|
1878
2396
|
shown: {
|
|
1879
2397
|
type: Boolean,
|
|
1880
2398
|
default: !0
|
|
@@ -1907,67 +2425,83 @@ const Dt = {
|
|
|
1907
2425
|
default: !1
|
|
1908
2426
|
}
|
|
1909
2427
|
},
|
|
1910
|
-
emits: [
|
|
1911
|
-
"close",
|
|
1912
|
-
"after-enter",
|
|
1913
|
-
"after-leave"
|
|
1914
|
-
],
|
|
2428
|
+
emits: ["close", "after-enter", "after-leave"],
|
|
1915
2429
|
setup(e, { emit: a }) {
|
|
1916
|
-
const t = e,
|
|
2430
|
+
const t = e, l = a, { transition: n } = ve(t);
|
|
1917
2431
|
let o = !1;
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
}
|
|
1921
|
-
|
|
1922
|
-
|
|
2432
|
+
const u = I(null), i = (c) => {
|
|
2433
|
+
u.value && c.target.closest(".bs-overlay") && l("close", t.modalId);
|
|
2434
|
+
};
|
|
2435
|
+
F(() => {
|
|
2436
|
+
document.addEventListener("click", i);
|
|
2437
|
+
}), _(() => {
|
|
2438
|
+
document.removeEventListener("click", i);
|
|
2439
|
+
}), fe(["Escape"], () => {
|
|
2440
|
+
o && l("close", t.modalId);
|
|
2441
|
+
});
|
|
2442
|
+
const r = () => !t.title && t.closeButton, d = () => t.title && t.closeButton;
|
|
2443
|
+
return (c, p) => (s(), v(R, null, [
|
|
2444
|
+
D(za, {
|
|
2445
|
+
shown: f(n),
|
|
1923
2446
|
preloaded: e.preloaded,
|
|
1924
2447
|
"enter-controlled": e.enterControlled,
|
|
1925
2448
|
"enter-trigger": e.enterTrigger,
|
|
1926
2449
|
"leave-trigger": e.leaveTrigger
|
|
1927
2450
|
}, null, 8, ["shown", "preloaded", "enter-controlled", "enter-trigger", "leave-trigger"]),
|
|
1928
|
-
|
|
1929
|
-
shown:
|
|
2451
|
+
D(pe, {
|
|
2452
|
+
shown: f(n),
|
|
1930
2453
|
preloaded: e.preloaded,
|
|
1931
2454
|
duration: 75,
|
|
1932
2455
|
"enter-attribute": "data-shown",
|
|
1933
|
-
onEnter:
|
|
1934
|
-
onAfterEnter:
|
|
1935
|
-
onAfterLeave:
|
|
2456
|
+
onEnter: p[1] || (p[1] = (h) => _e(o) ? o.value = !0 : o = !0),
|
|
2457
|
+
onAfterEnter: p[2] || (p[2] = (h) => l("after-enter")),
|
|
2458
|
+
onAfterLeave: p[3] || (p[3] = (h) => l("after-leave"))
|
|
1936
2459
|
}, {
|
|
1937
|
-
default:
|
|
1938
|
-
|
|
2460
|
+
default: P(() => [
|
|
2461
|
+
$("div", M({
|
|
1939
2462
|
id: t.modalId,
|
|
1940
2463
|
class: "bs-modal",
|
|
1941
2464
|
role: e.alert ? "alertdialog" : "dialog",
|
|
1942
2465
|
"aria-modal": "true"
|
|
1943
|
-
},
|
|
1944
|
-
|
|
1945
|
-
|
|
2466
|
+
}, c.$attrs, {
|
|
2467
|
+
ref_key: "modalRef",
|
|
2468
|
+
ref: u
|
|
2469
|
+
}), [
|
|
2470
|
+
e.title || e.closeButton ? (s(), v("header", {
|
|
2471
|
+
key: 0,
|
|
2472
|
+
class: Q({
|
|
2473
|
+
"only-close-button-modal-header": r,
|
|
2474
|
+
"modal-header": d
|
|
2475
|
+
})
|
|
2476
|
+
}, [
|
|
2477
|
+
e.title ? (s(), v("h5", Na, A(e.title), 1)) : w("", !0),
|
|
2478
|
+
e.closeButton ? (s(), v("button", {
|
|
2479
|
+
key: 1,
|
|
1946
2480
|
type: "button",
|
|
1947
2481
|
title: "Close Modal",
|
|
1948
2482
|
"aria-label": "Close Modal",
|
|
1949
|
-
onClick:
|
|
2483
|
+
onClick: p[0] || (p[0] = (h) => l("close", e.modalId))
|
|
1950
2484
|
}, [
|
|
1951
|
-
|
|
1952
|
-
])
|
|
1953
|
-
])) :
|
|
1954
|
-
|
|
1955
|
-
], 16,
|
|
2485
|
+
D(f(de), { class: "close-button" })
|
|
2486
|
+
])) : w("", !0)
|
|
2487
|
+
], 2)) : w("", !0),
|
|
2488
|
+
L(c.$slots, "default")
|
|
2489
|
+
], 16, Ra)
|
|
1956
2490
|
]),
|
|
1957
2491
|
_: 3
|
|
1958
2492
|
}, 8, ["shown", "preloaded"])
|
|
1959
2493
|
], 64));
|
|
1960
2494
|
}
|
|
1961
|
-
}),
|
|
2495
|
+
}), ja = ["data-variant", "data-fixed"], Wa = {
|
|
1962
2496
|
key: 0,
|
|
1963
2497
|
class: "bs-pagination-carets"
|
|
1964
|
-
},
|
|
2498
|
+
}, Fa = ["title", "disabled"], Ua = { key: 0 }, Ga = ["title", "disabled"], Ha = { key: 0 }, Ka = {
|
|
1965
2499
|
key: 1,
|
|
1966
2500
|
class: "bs-pagination-page-numbers"
|
|
1967
|
-
},
|
|
2501
|
+
}, Ya = ["title", "data-selected", "onClick"], Xa = { key: 2 }, Za = { key: 3 }, Ja = /* @__PURE__ */ $("span", null, "Results Per Page:", -1), Qa = { class: "bs-pagination-results-numbers" }, _a = ["data-selected", "disabled", "onClick"], en = {
|
|
1968
2502
|
key: 5,
|
|
1969
2503
|
class: "bs-pagination-carets"
|
|
1970
|
-
},
|
|
2504
|
+
}, tn = ["title", "disabled"], an = { key: 0 }, nn = ["title", "disabled"], ln = { key: 0 }, ol = {
|
|
1971
2505
|
__name: "BsPagination",
|
|
1972
2506
|
props: {
|
|
1973
2507
|
// Used for all
|
|
@@ -2053,129 +2587,129 @@ const Dt = {
|
|
|
2053
2587
|
},
|
|
2054
2588
|
emits: ["selchange", "update:modelValue"],
|
|
2055
2589
|
setup(e, { emit: a }) {
|
|
2056
|
-
const t = e,
|
|
2057
|
-
|
|
2058
|
-
o.value ?
|
|
2590
|
+
const t = e, l = a, n = I(null);
|
|
2591
|
+
F(() => {
|
|
2592
|
+
o.value ? n.value = o.value : t.variant === "results" ? n.value = T.value[0] : n.value = 1;
|
|
2059
2593
|
});
|
|
2060
|
-
const o =
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
}),
|
|
2064
|
-
|
|
2065
|
-
}),
|
|
2066
|
-
|
|
2594
|
+
const o = g(() => t.modelValue || t.selection);
|
|
2595
|
+
z(() => t.selection, (k) => {
|
|
2596
|
+
n.value = k;
|
|
2597
|
+
}), z(() => t.modelValue, (k) => {
|
|
2598
|
+
n.value = k;
|
|
2599
|
+
}), z(n, (k, E) => {
|
|
2600
|
+
E !== null && (l("selchange", k), l("update:modelValue", k));
|
|
2067
2601
|
});
|
|
2068
|
-
const u =
|
|
2602
|
+
const u = g(() => {
|
|
2069
2603
|
if (t.variant === "group")
|
|
2070
2604
|
return Math.ceil(t.itemsCount / t.itemsPerGroup);
|
|
2071
2605
|
if (t.variant === "base")
|
|
2072
2606
|
return t.pageCount;
|
|
2073
|
-
}), i =
|
|
2074
|
-
function s() {
|
|
2075
|
-
l.value = 1;
|
|
2076
|
-
}
|
|
2607
|
+
}), i = g(() => t.variant === "base" ? t.centerDisplay === "text" ? "group" : void 0 : t.variant);
|
|
2077
2608
|
function r() {
|
|
2078
|
-
|
|
2609
|
+
n.value = 1;
|
|
2610
|
+
}
|
|
2611
|
+
function d() {
|
|
2612
|
+
n.value = Math.max(n.value - 1, 1);
|
|
2079
2613
|
}
|
|
2080
2614
|
function c() {
|
|
2081
|
-
|
|
2082
|
-
|
|
2615
|
+
n.value = Math.min(
|
|
2616
|
+
n.value + 1,
|
|
2083
2617
|
u.value
|
|
2084
2618
|
);
|
|
2085
2619
|
}
|
|
2086
|
-
function
|
|
2087
|
-
|
|
2620
|
+
function p() {
|
|
2621
|
+
n.value = u.value;
|
|
2088
2622
|
}
|
|
2089
|
-
const
|
|
2623
|
+
const h = g(() => {
|
|
2090
2624
|
if (t.pageCount <= t.pageRange)
|
|
2091
2625
|
return [...Array(t.pageCount + 1).keys()].slice(1);
|
|
2092
|
-
const
|
|
2093
|
-
let y =
|
|
2094
|
-
y < 1 && (
|
|
2095
|
-
for (let
|
|
2096
|
-
|
|
2097
|
-
return
|
|
2098
|
-
}),
|
|
2099
|
-
const
|
|
2100
|
-
return `${t.centerLabel ?? "Results"} ${
|
|
2101
|
-
}),
|
|
2102
|
-
return (
|
|
2626
|
+
const k = [1], E = (t.pageRange - 1) / 2;
|
|
2627
|
+
let y = n.value - E, b = n.value + E;
|
|
2628
|
+
y < 1 && (b += 1 - y, y = 1), b > t.pageCount && (y -= b - t.pageCount, b = t.pageCount), y = Math.max(y, 2), b = Math.min(b, t.pageCount - 1), y > 2 && k.push(t.breakText);
|
|
2629
|
+
for (let S = y; S <= b; S++)
|
|
2630
|
+
k.push(S);
|
|
2631
|
+
return b < t.pageCount - 1 && k.push(t.breakText), k.push(t.pageCount), k;
|
|
2632
|
+
}), m = g(() => `${t.centerLabel ?? "Page"} ${n.value} of ${u.value}`), V = g(() => {
|
|
2633
|
+
const k = (n.value - 1) * t.itemsPerGroup + 1, E = Math.min(k - 1 + t.itemsPerGroup, t.itemsCount);
|
|
2634
|
+
return `${t.centerLabel ?? "Results"} ${k} - ${E} of ${t.itemsCount}`;
|
|
2635
|
+
}), T = g(() => t.resultsIncrements.split(",").map((k) => parseInt(k)));
|
|
2636
|
+
return (k, E) => (s(), v("div", {
|
|
2103
2637
|
class: "bs-pagination",
|
|
2104
2638
|
"data-variant": i.value,
|
|
2105
2639
|
"data-fixed": t.fixed
|
|
2106
2640
|
}, [
|
|
2107
|
-
e.variant === "base" || e.variant === "group" ? (
|
|
2108
|
-
e.showFirstLastButtons ? (
|
|
2641
|
+
e.variant === "base" || e.variant === "group" ? (s(), v("div", Wa, [
|
|
2642
|
+
e.showFirstLastButtons ? (s(), v("button", {
|
|
2109
2643
|
key: 0,
|
|
2110
2644
|
type: "button",
|
|
2111
|
-
class:
|
|
2645
|
+
class: Q(e.firstPageText ? "bs-pagination-word-caret" : void 0),
|
|
2112
2646
|
title: e.firstPageText,
|
|
2113
|
-
disabled:
|
|
2114
|
-
onClick:
|
|
2647
|
+
disabled: n.value === 1,
|
|
2648
|
+
onClick: r
|
|
2115
2649
|
}, [
|
|
2116
|
-
|
|
2117
|
-
e.firstPageText ? (
|
|
2118
|
-
], 10,
|
|
2119
|
-
|
|
2650
|
+
D(f(nt)),
|
|
2651
|
+
e.firstPageText ? (s(), v("span", Ua, A(e.firstPageText), 1)) : w("", !0)
|
|
2652
|
+
], 10, Fa)) : w("", !0),
|
|
2653
|
+
$("button", {
|
|
2120
2654
|
type: "button",
|
|
2121
|
-
class:
|
|
2655
|
+
class: Q(e.prevPageText ? "bs-pagination-word-caret" : void 0),
|
|
2122
2656
|
title: e.prevPageText,
|
|
2123
|
-
disabled:
|
|
2124
|
-
onClick:
|
|
2657
|
+
disabled: n.value === 1,
|
|
2658
|
+
onClick: d
|
|
2125
2659
|
}, [
|
|
2126
|
-
|
|
2127
|
-
e.prevPageText ? (
|
|
2128
|
-
], 10,
|
|
2129
|
-
])) :
|
|
2130
|
-
e.variant === "base" && e.centerDisplay === "numbers" ? (
|
|
2131
|
-
(
|
|
2660
|
+
D(f(lt)),
|
|
2661
|
+
e.prevPageText ? (s(), v("span", Ha, A(e.prevPageText), 1)) : w("", !0)
|
|
2662
|
+
], 10, Ga)
|
|
2663
|
+
])) : w("", !0),
|
|
2664
|
+
e.variant === "base" && e.centerDisplay === "numbers" ? (s(), v("div", Ka, [
|
|
2665
|
+
(s(!0), v(R, null, G(h.value, (y) => (s(), v("button", {
|
|
2132
2666
|
key: `page-${y}-button`,
|
|
2133
2667
|
type: "button",
|
|
2134
2668
|
title: `Page ${y}`,
|
|
2135
|
-
"data-selected": y ===
|
|
2136
|
-
onClick: (
|
|
2137
|
-
},
|
|
2138
|
-
])) :
|
|
2139
|
-
t.variant === "base" && t.centerDisplay === "text" ? (
|
|
2140
|
-
t.variant === "group" ? (
|
|
2141
|
-
t.variant === "results" ? (
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
(
|
|
2669
|
+
"data-selected": y === n.value,
|
|
2670
|
+
onClick: (b) => n.value = y
|
|
2671
|
+
}, A(y), 9, Ya))), 128))
|
|
2672
|
+
])) : w("", !0),
|
|
2673
|
+
t.variant === "base" && t.centerDisplay === "text" ? (s(), v("span", Xa, A(m.value), 1)) : w("", !0),
|
|
2674
|
+
t.variant === "group" ? (s(), v("span", Za, A(V.value), 1)) : w("", !0),
|
|
2675
|
+
t.variant === "results" ? (s(), v(R, { key: 4 }, [
|
|
2676
|
+
Ja,
|
|
2677
|
+
$("div", Qa, [
|
|
2678
|
+
(s(!0), v(R, null, G(T.value, (y) => (s(), v("button", {
|
|
2145
2679
|
type: "button",
|
|
2146
2680
|
key: `results-${y}`,
|
|
2147
|
-
"data-selected": y ===
|
|
2148
|
-
disabled:
|
|
2149
|
-
onClick: (
|
|
2150
|
-
},
|
|
2681
|
+
"data-selected": y === n.value,
|
|
2682
|
+
disabled: n.value === y,
|
|
2683
|
+
onClick: (b) => n.value = y
|
|
2684
|
+
}, A(y), 9, _a))), 128))
|
|
2151
2685
|
])
|
|
2152
|
-
], 64)) :
|
|
2153
|
-
e.variant === "base" || e.variant === "group" ? (
|
|
2154
|
-
|
|
2686
|
+
], 64)) : w("", !0),
|
|
2687
|
+
e.variant === "base" || e.variant === "group" ? (s(), v("div", en, [
|
|
2688
|
+
$("button", {
|
|
2155
2689
|
type: "button",
|
|
2156
|
-
class:
|
|
2690
|
+
class: Q(e.nextPageText ? "bs-pagination-word-caret" : void 0),
|
|
2157
2691
|
title: e.nextPageText,
|
|
2158
|
-
disabled:
|
|
2692
|
+
disabled: n.value === u.value,
|
|
2159
2693
|
onClick: c
|
|
2160
2694
|
}, [
|
|
2161
|
-
e.nextPageText ? (
|
|
2162
|
-
|
|
2163
|
-
], 10,
|
|
2164
|
-
e.showFirstLastButtons ? (
|
|
2695
|
+
e.nextPageText ? (s(), v("span", an, A(e.nextPageText), 1)) : w("", !0),
|
|
2696
|
+
D(f(ot))
|
|
2697
|
+
], 10, tn),
|
|
2698
|
+
e.showFirstLastButtons ? (s(), v("button", {
|
|
2165
2699
|
key: 0,
|
|
2166
2700
|
type: "button",
|
|
2167
|
-
class:
|
|
2701
|
+
class: Q(e.lastPageText ? "bs-pagination-word-caret" : void 0),
|
|
2168
2702
|
title: e.lastPageText,
|
|
2169
|
-
disabled:
|
|
2170
|
-
onClick:
|
|
2703
|
+
disabled: n.value === u.value,
|
|
2704
|
+
onClick: p
|
|
2171
2705
|
}, [
|
|
2172
|
-
e.lastPageText ? (
|
|
2173
|
-
|
|
2174
|
-
], 10,
|
|
2175
|
-
])) :
|
|
2176
|
-
], 8,
|
|
2706
|
+
e.lastPageText ? (s(), v("span", ln, A(e.lastPageText), 1)) : w("", !0),
|
|
2707
|
+
D(f(it))
|
|
2708
|
+
], 10, nn)) : w("", !0)
|
|
2709
|
+
])) : w("", !0)
|
|
2710
|
+
], 8, ja));
|
|
2177
2711
|
}
|
|
2178
|
-
},
|
|
2712
|
+
}, on = ["data-truncate"], il = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2179
2713
|
__name: "BsPill",
|
|
2180
2714
|
props: {
|
|
2181
2715
|
active: { type: Boolean, default: !1 },
|
|
@@ -2199,35 +2733,35 @@ const Dt = {
|
|
|
2199
2733
|
}
|
|
2200
2734
|
},
|
|
2201
2735
|
setup(e) {
|
|
2202
|
-
const a = e, { onLinkClick: t } =
|
|
2203
|
-
return (i,
|
|
2736
|
+
const a = e, { onLinkClick: t } = ce(a), l = U(), { rootTag: n, attrsToBind: o, hrefUrl: u } = ue(a, l, "span");
|
|
2737
|
+
return (i, r) => (s(), O(H(f(n)), M({
|
|
2204
2738
|
class: "bs-pill",
|
|
2205
2739
|
"data-active": e.active,
|
|
2206
2740
|
"data-component": "bs-pill",
|
|
2207
2741
|
"data-status": e.status || void 0,
|
|
2208
2742
|
"data-variant": e.variant || void 0,
|
|
2209
2743
|
disabled: e.disabled,
|
|
2210
|
-
".href":
|
|
2211
|
-
},
|
|
2212
|
-
default:
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
], 8,
|
|
2744
|
+
".href": f(u)
|
|
2745
|
+
}, f(o), { onClick: f(t) }), {
|
|
2746
|
+
default: P(() => [
|
|
2747
|
+
$("span", { "data-truncate": e.truncate }, [
|
|
2748
|
+
L(i.$slots, "default")
|
|
2749
|
+
], 8, on)
|
|
2216
2750
|
]),
|
|
2217
2751
|
_: 3
|
|
2218
2752
|
}, 48, ["data-active", "data-status", "data-variant", "disabled", ".href", "onClick"]));
|
|
2219
2753
|
}
|
|
2220
|
-
}),
|
|
2754
|
+
}), rn = { class: "bs-profile-details" }, sn = {
|
|
2221
2755
|
class: "bs-profile-name",
|
|
2222
2756
|
"data-size": "sm",
|
|
2223
2757
|
"data-weight": "bold"
|
|
2224
|
-
},
|
|
2758
|
+
}, dn = {
|
|
2225
2759
|
key: 1,
|
|
2226
2760
|
"data-weight": "bold"
|
|
2227
|
-
},
|
|
2761
|
+
}, un = { key: 2 }, cn = { key: 3 }, fn = {
|
|
2228
2762
|
key: 4,
|
|
2229
2763
|
"data-icon": "true"
|
|
2230
|
-
},
|
|
2764
|
+
}, vn = {
|
|
2231
2765
|
__name: "BsProfileDetails",
|
|
2232
2766
|
props: {
|
|
2233
2767
|
profileName: {
|
|
@@ -2244,40 +2778,40 @@ const Dt = {
|
|
|
2244
2778
|
},
|
|
2245
2779
|
emits: ["action-toggled"],
|
|
2246
2780
|
setup(e, { emit: a }) {
|
|
2247
|
-
const t = e,
|
|
2781
|
+
const t = e, l = a, { icon: n } = se(t, "actionIcon"), { icon: o } = se(t, "miscMetaIcon");
|
|
2248
2782
|
function u(i) {
|
|
2249
|
-
i.target.tagName === "BUTTON" && (i.preventDefault(), i.stopImmediatePropagation(),
|
|
2783
|
+
i.target.tagName === "BUTTON" && (i.preventDefault(), i.stopImmediatePropagation(), l("action-toggled"));
|
|
2250
2784
|
}
|
|
2251
|
-
return (i,
|
|
2252
|
-
e.action || i.$slots.action ? (
|
|
2785
|
+
return (i, r) => (s(), v("div", rn, [
|
|
2786
|
+
e.action || i.$slots.action ? (s(), v("button", {
|
|
2253
2787
|
key: 0,
|
|
2254
2788
|
"data-icon": "true",
|
|
2255
2789
|
onClick: u
|
|
2256
2790
|
}, [
|
|
2257
|
-
|
|
2258
|
-
e.actionIcon ? (
|
|
2791
|
+
L(i.$slots, "action", {}, () => [
|
|
2792
|
+
e.actionIcon ? (s(), O(H(f(n) ? f(n) : "span"), {
|
|
2259
2793
|
key: 0,
|
|
2260
2794
|
class: "bs-icon"
|
|
2261
|
-
})) :
|
|
2262
|
-
|
|
2795
|
+
})) : w("", !0),
|
|
2796
|
+
W(" " + A(e.action), 1)
|
|
2263
2797
|
])
|
|
2264
|
-
])) :
|
|
2265
|
-
|
|
2266
|
-
e.company ? (
|
|
2267
|
-
e.jobTitle ? (
|
|
2268
|
-
e.email ? (
|
|
2269
|
-
e.miscMeta || i.$slots.misc ? (
|
|
2270
|
-
|
|
2271
|
-
e.miscMetaIcon ? (
|
|
2798
|
+
])) : w("", !0),
|
|
2799
|
+
$("span", sn, A(e.profileName), 1),
|
|
2800
|
+
e.company ? (s(), v("span", dn, A(e.company), 1)) : w("", !0),
|
|
2801
|
+
e.jobTitle ? (s(), v("span", un, A(e.jobTitle), 1)) : w("", !0),
|
|
2802
|
+
e.email ? (s(), v("span", cn, A(e.email), 1)) : w("", !0),
|
|
2803
|
+
e.miscMeta || i.$slots.misc ? (s(), v("span", fn, [
|
|
2804
|
+
L(i.$slots, "misc", {}, () => [
|
|
2805
|
+
e.miscMetaIcon ? (s(), O(H(f(o) ? f(o) : "span"), {
|
|
2272
2806
|
key: 0,
|
|
2273
2807
|
class: "bs-icon"
|
|
2274
|
-
})) :
|
|
2275
|
-
|
|
2808
|
+
})) : w("", !0),
|
|
2809
|
+
W(" " + A(e.miscMeta), 1)
|
|
2276
2810
|
])
|
|
2277
|
-
])) :
|
|
2811
|
+
])) : w("", !0)
|
|
2278
2812
|
]));
|
|
2279
2813
|
}
|
|
2280
|
-
},
|
|
2814
|
+
}, pn = ["data-img-size", "data-initials", "data-no-img"], hn = ["src", "alt"], bn = {
|
|
2281
2815
|
__name: "BsProfileImg",
|
|
2282
2816
|
props: {
|
|
2283
2817
|
src: String,
|
|
@@ -2292,22 +2826,22 @@ const Dt = {
|
|
|
2292
2826
|
}
|
|
2293
2827
|
},
|
|
2294
2828
|
setup(e) {
|
|
2295
|
-
const a = e, t = I(!1),
|
|
2296
|
-
return
|
|
2829
|
+
const a = e, t = I(!1), l = I(!!a.src);
|
|
2830
|
+
return F(() => t.value = !0), (n, o) => (s(), v("div", {
|
|
2297
2831
|
class: "bs-profile-img",
|
|
2298
2832
|
"data-img-size": e.size,
|
|
2299
2833
|
"data-initials": e.initials,
|
|
2300
|
-
"data-no-img": !
|
|
2834
|
+
"data-no-img": !l.value
|
|
2301
2835
|
}, [
|
|
2302
|
-
|
|
2836
|
+
l.value && t.value ? (s(), v("img", {
|
|
2303
2837
|
key: 0,
|
|
2304
2838
|
src: e.src,
|
|
2305
2839
|
alt: e.profileName,
|
|
2306
|
-
onError: o[0] || (o[0] = (u) =>
|
|
2307
|
-
}, null, 40,
|
|
2308
|
-
], 8,
|
|
2840
|
+
onError: o[0] || (o[0] = (u) => l.value = !1)
|
|
2841
|
+
}, null, 40, hn)) : w("", !0)
|
|
2842
|
+
], 8, pn));
|
|
2309
2843
|
}
|
|
2310
|
-
},
|
|
2844
|
+
}, rl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2311
2845
|
__name: "BsProfile",
|
|
2312
2846
|
props: {
|
|
2313
2847
|
layout: {
|
|
@@ -2337,20 +2871,20 @@ const Dt = {
|
|
|
2337
2871
|
},
|
|
2338
2872
|
emits: ["action-toggled"],
|
|
2339
2873
|
setup(e, { emit: a }) {
|
|
2340
|
-
const t = e,
|
|
2341
|
-
return (
|
|
2874
|
+
const t = e, l = a, n = U(), { onLinkClick: o } = ce(t), { rootTag: u, attrsToBind: i, hrefUrl: r } = ue(t, n, "div");
|
|
2875
|
+
return (d, c) => (s(), O(H(f(u)), M({
|
|
2342
2876
|
class: "bs-profile",
|
|
2343
|
-
".href":
|
|
2877
|
+
".href": f(r),
|
|
2344
2878
|
"data-layout": e.layout
|
|
2345
|
-
},
|
|
2346
|
-
default:
|
|
2347
|
-
|
|
2879
|
+
}, f(i), { onClick: f(o) }), {
|
|
2880
|
+
default: P(() => [
|
|
2881
|
+
D(bn, {
|
|
2348
2882
|
src: e.imageSrc,
|
|
2349
2883
|
size: e.imageSize,
|
|
2350
2884
|
initials: e.initials,
|
|
2351
2885
|
"profile-name": e.profileName
|
|
2352
2886
|
}, null, 8, ["src", "size", "initials", "profile-name"]),
|
|
2353
|
-
|
|
2887
|
+
D(vn, {
|
|
2354
2888
|
"profile-name": e.profileName,
|
|
2355
2889
|
company: e.company,
|
|
2356
2890
|
"job-title": e.jobTitle,
|
|
@@ -2359,13 +2893,13 @@ const Dt = {
|
|
|
2359
2893
|
"action-icon": e.actionIcon,
|
|
2360
2894
|
"misc-meta": e.miscMeta,
|
|
2361
2895
|
"misc-meta-icon": e.miscMetaIcon,
|
|
2362
|
-
onActionToggled: c[0] || (c[0] = (
|
|
2896
|
+
onActionToggled: c[0] || (c[0] = (p) => l("action-toggled"))
|
|
2363
2897
|
}, {
|
|
2364
|
-
action:
|
|
2365
|
-
|
|
2898
|
+
action: P(() => [
|
|
2899
|
+
L(d.$slots, "action")
|
|
2366
2900
|
]),
|
|
2367
|
-
misc:
|
|
2368
|
-
|
|
2901
|
+
misc: P(() => [
|
|
2902
|
+
L(d.$slots, "misc")
|
|
2369
2903
|
]),
|
|
2370
2904
|
_: 3
|
|
2371
2905
|
}, 8, ["profile-name", "company", "job-title", "email", "action", "action-icon", "misc-meta", "misc-meta-icon"])
|
|
@@ -2373,7 +2907,7 @@ const Dt = {
|
|
|
2373
2907
|
_: 3
|
|
2374
2908
|
}, 48, [".href", "data-layout", "onClick"]));
|
|
2375
2909
|
}
|
|
2376
|
-
}),
|
|
2910
|
+
}), gn = ["data-size"], mn = ["checked", "disabled", "id", "required", "value", "data-error"], sl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2377
2911
|
__name: "BsRadio",
|
|
2378
2912
|
props: {
|
|
2379
2913
|
label: {
|
|
@@ -2417,39 +2951,39 @@ const Dt = {
|
|
|
2417
2951
|
},
|
|
2418
2952
|
emits: ["update:modelValue"],
|
|
2419
2953
|
setup(e, { emit: a }) {
|
|
2420
|
-
const t = e,
|
|
2421
|
-
return (
|
|
2954
|
+
const t = e, l = U(), [n] = K(), { toChild: o, toRoot: u } = ae(t, l, ["aria-label", "name"]), i = g(() => t.inputId || n.value), r = g(() => t.checked || t.modelValue && t.modelValue === t.value);
|
|
2955
|
+
return (d, c) => (s(), v("div", M({
|
|
2422
2956
|
class: "bs-boolean",
|
|
2423
2957
|
"data-component": "bs-radio",
|
|
2424
2958
|
"data-size": e.size
|
|
2425
|
-
},
|
|
2426
|
-
|
|
2427
|
-
checked:
|
|
2959
|
+
}, f(u)), [
|
|
2960
|
+
$("input", M({
|
|
2961
|
+
checked: r.value,
|
|
2428
2962
|
disabled: e.disabled,
|
|
2429
2963
|
id: i.value,
|
|
2430
2964
|
required: e.required,
|
|
2431
2965
|
type: "radio",
|
|
2432
2966
|
value: e.value,
|
|
2433
2967
|
"data-error": e.error
|
|
2434
|
-
},
|
|
2435
|
-
onChange: c[0] || (c[0] = (
|
|
2436
|
-
}), null, 16,
|
|
2437
|
-
e.label ||
|
|
2968
|
+
}, f(o), {
|
|
2969
|
+
onChange: c[0] || (c[0] = (p) => d.$emit("update:modelValue", p.target.value))
|
|
2970
|
+
}), null, 16, mn),
|
|
2971
|
+
e.label || d.$slots.label ? (s(), O(ne, {
|
|
2438
2972
|
key: 0,
|
|
2439
2973
|
for: i.value,
|
|
2440
2974
|
disabled: e.disabled,
|
|
2441
2975
|
required: e.required
|
|
2442
2976
|
}, {
|
|
2443
|
-
default:
|
|
2444
|
-
|
|
2445
|
-
|
|
2977
|
+
default: P(() => [
|
|
2978
|
+
L(d.$slots, "label", {}, () => [
|
|
2979
|
+
W(A(e.label), 1)
|
|
2446
2980
|
])
|
|
2447
2981
|
]),
|
|
2448
2982
|
_: 3
|
|
2449
|
-
}, 8, ["for", "disabled", "required"])) :
|
|
2450
|
-
], 16,
|
|
2983
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0)
|
|
2984
|
+
], 16, gn));
|
|
2451
2985
|
}
|
|
2452
|
-
}),
|
|
2986
|
+
}), yn = ["id", "disabled", "required", "data-error", "value"], Bn = {
|
|
2453
2987
|
__name: "BsSelect",
|
|
2454
2988
|
props: {
|
|
2455
2989
|
disabled: { type: Boolean, default: !1 },
|
|
@@ -2462,22 +2996,22 @@ const Dt = {
|
|
|
2462
2996
|
},
|
|
2463
2997
|
emits: ["update:modelValue"],
|
|
2464
2998
|
setup(e, { emit: a }) {
|
|
2465
|
-
const t = e,
|
|
2466
|
-
return (
|
|
2467
|
-
id:
|
|
2999
|
+
const t = e, l = g(() => ({ [t.error ? "aria-errormessage" : "aria-describedby"]: t.hintId }));
|
|
3000
|
+
return (n, o) => (s(), v("select", M({
|
|
3001
|
+
id: n.$attrs.id || e.inputId,
|
|
2468
3002
|
class: "bs-select",
|
|
2469
3003
|
"data-component": "bs-select",
|
|
2470
3004
|
disabled: e.disabled,
|
|
2471
3005
|
required: e.required,
|
|
2472
3006
|
"data-error": e.error,
|
|
2473
3007
|
value: e.value || e.modelValue
|
|
2474
|
-
},
|
|
2475
|
-
onChange: o[0] || (o[0] = (u) =>
|
|
3008
|
+
}, l.value, {
|
|
3009
|
+
onChange: o[0] || (o[0] = (u) => n.$emit("update:modelValue", u.target.value))
|
|
2476
3010
|
}), [
|
|
2477
|
-
|
|
2478
|
-
], 16,
|
|
3011
|
+
L(n.$slots, "default")
|
|
3012
|
+
], 16, yn));
|
|
2479
3013
|
}
|
|
2480
|
-
},
|
|
3014
|
+
}, $n = ["selected", "disabled"], Sn = ["disabled", "selected", "value"], dl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2481
3015
|
__name: "BsSelectField",
|
|
2482
3016
|
props: {
|
|
2483
3017
|
data: {
|
|
@@ -2521,64 +3055,64 @@ const Dt = {
|
|
|
2521
3055
|
modelValue: [String, Number]
|
|
2522
3056
|
},
|
|
2523
3057
|
setup(e) {
|
|
2524
|
-
const a = e, t =
|
|
3058
|
+
const a = e, t = U(), [l, n] = K(2), { toChild: o, toRoot: u } = ae(a, t, [
|
|
2525
3059
|
"aria-label",
|
|
2526
3060
|
"autofocus",
|
|
2527
3061
|
"name"
|
|
2528
|
-
]), i =
|
|
2529
|
-
var
|
|
2530
|
-
return ((
|
|
3062
|
+
]), i = g(() => {
|
|
3063
|
+
var p, h;
|
|
3064
|
+
return ((h = (p = a.hints) == null ? void 0 : p.join) == null ? void 0 : h.call(p, `
|
|
2531
3065
|
`)) || a.hints;
|
|
2532
|
-
}),
|
|
2533
|
-
return (
|
|
2534
|
-
e.label ||
|
|
3066
|
+
}), r = g(() => a.error && a.errorMsg || a.hint || i.value || void 0), d = g(() => a.inputId || l.value), c = g(() => a.value || a.modelValue);
|
|
3067
|
+
return (p, h) => (s(), v("div", M({ "data-component": "bs-select-field" }, f(u)), [
|
|
3068
|
+
e.label || p.$slots.label ? (s(), O(ne, {
|
|
2535
3069
|
key: 0,
|
|
2536
|
-
for:
|
|
3070
|
+
for: d.value,
|
|
2537
3071
|
disabled: e.disabled,
|
|
2538
3072
|
required: e.required
|
|
2539
3073
|
}, {
|
|
2540
|
-
default:
|
|
2541
|
-
|
|
2542
|
-
|
|
3074
|
+
default: P(() => [
|
|
3075
|
+
L(p.$slots, "label", {}, () => [
|
|
3076
|
+
W(A(e.label), 1)
|
|
2543
3077
|
])
|
|
2544
3078
|
]),
|
|
2545
3079
|
_: 3
|
|
2546
|
-
}, 8, ["for", "disabled", "required"])) :
|
|
2547
|
-
|
|
3080
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0),
|
|
3081
|
+
D(Bn, M({
|
|
2548
3082
|
disabled: e.disabled,
|
|
2549
3083
|
error: e.error,
|
|
2550
|
-
"hint-id":
|
|
2551
|
-
"input-id":
|
|
3084
|
+
"hint-id": f(n),
|
|
3085
|
+
"input-id": d.value,
|
|
2552
3086
|
required: e.required,
|
|
2553
3087
|
value: c.value,
|
|
2554
|
-
"onUpdate:modelValue":
|
|
2555
|
-
},
|
|
2556
|
-
default:
|
|
2557
|
-
|
|
3088
|
+
"onUpdate:modelValue": h[0] || (h[0] = (m) => p.$emit("update:modelValue", m))
|
|
3089
|
+
}, f(o)), {
|
|
3090
|
+
default: P(() => [
|
|
3091
|
+
$("option", {
|
|
2558
3092
|
selected: !c.value,
|
|
2559
3093
|
value: "",
|
|
2560
3094
|
disabled: !!c.value
|
|
2561
|
-
},
|
|
2562
|
-
(
|
|
2563
|
-
key:
|
|
2564
|
-
disabled:
|
|
2565
|
-
selected: c.value ===
|
|
2566
|
-
value:
|
|
2567
|
-
},
|
|
3095
|
+
}, A(e.disabled ? "" : e.placeholder), 9, $n),
|
|
3096
|
+
(s(!0), v(R, null, G(e.data, (m) => (s(), v("option", {
|
|
3097
|
+
key: m.value,
|
|
3098
|
+
disabled: m.disabled,
|
|
3099
|
+
selected: c.value === m.value,
|
|
3100
|
+
value: m.value
|
|
3101
|
+
}, A(m.label), 9, Sn))), 128))
|
|
2568
3102
|
]),
|
|
2569
3103
|
_: 1
|
|
2570
3104
|
}, 16, ["disabled", "error", "hint-id", "input-id", "required", "value"]),
|
|
2571
|
-
|
|
3105
|
+
r.value ? (s(), O(Se, {
|
|
2572
3106
|
key: 1,
|
|
2573
3107
|
"data-disabled": e.disabled,
|
|
2574
3108
|
error: e.error,
|
|
2575
3109
|
"error-msg": e.errorMsg,
|
|
2576
3110
|
hint: e.hint || i.value,
|
|
2577
|
-
"hint-id":
|
|
2578
|
-
}, null, 8, ["data-disabled", "error", "error-msg", "hint", "hint-id"])) :
|
|
3111
|
+
"hint-id": f(n)
|
|
3112
|
+
}, null, 8, ["data-disabled", "error", "error-msg", "hint", "hint-id"])) : w("", !0)
|
|
2579
3113
|
], 16));
|
|
2580
3114
|
}
|
|
2581
|
-
}),
|
|
3115
|
+
}), wn = ["data-size"], kn = ["data-disabled", "data-pending", "data-size"], In = ["checked", "disabled", "id"], Tn = ["data-inner-on-label", "data-inner-off-label"], ul = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2582
3116
|
__name: "BsSwitch",
|
|
2583
3117
|
props: {
|
|
2584
3118
|
checked: {
|
|
@@ -2624,48 +3158,48 @@ const Dt = {
|
|
|
2624
3158
|
},
|
|
2625
3159
|
emits: ["update:modelValue"],
|
|
2626
3160
|
setup(e, { emit: a }) {
|
|
2627
|
-
const t = e,
|
|
2628
|
-
return (c,
|
|
3161
|
+
const t = e, l = a, n = U(), [o] = K(), { toChild: u, toRoot: i } = ae(t, n, ["aria-label", "name", "value"]), r = g(() => t.inputId || o.value), d = g(() => t.checked || t.modelValue);
|
|
3162
|
+
return (c, p) => (s(), v("div", M({
|
|
2629
3163
|
class: "bs-boolean",
|
|
2630
3164
|
"data-component": "bs-switch",
|
|
2631
3165
|
"data-size": e.size
|
|
2632
|
-
},
|
|
2633
|
-
e.label || c.$slots.label ? (
|
|
3166
|
+
}, f(i)), [
|
|
3167
|
+
e.label || c.$slots.label ? (s(), O(ne, {
|
|
2634
3168
|
key: 0,
|
|
2635
|
-
for:
|
|
3169
|
+
for: r.value,
|
|
2636
3170
|
disabled: e.disabled,
|
|
2637
3171
|
hide: e.hideLabel
|
|
2638
3172
|
}, {
|
|
2639
|
-
default:
|
|
2640
|
-
|
|
2641
|
-
|
|
3173
|
+
default: P(() => [
|
|
3174
|
+
L(c.$slots, "label", {}, () => [
|
|
3175
|
+
W(A(e.label), 1)
|
|
2642
3176
|
])
|
|
2643
3177
|
]),
|
|
2644
3178
|
_: 3
|
|
2645
|
-
}, 8, ["for", "disabled", "hide"])) :
|
|
2646
|
-
|
|
3179
|
+
}, 8, ["for", "disabled", "hide"])) : w("", !0),
|
|
3180
|
+
$("div", {
|
|
2647
3181
|
class: "bs-switch",
|
|
2648
3182
|
"data-disabled": e.disabled,
|
|
2649
3183
|
"data-pending": e.pending,
|
|
2650
3184
|
"data-size": e.size
|
|
2651
3185
|
}, [
|
|
2652
|
-
|
|
2653
|
-
checked:
|
|
3186
|
+
$("input", M({
|
|
3187
|
+
checked: d.value,
|
|
2654
3188
|
disabled: e.disabled,
|
|
2655
|
-
id:
|
|
3189
|
+
id: r.value,
|
|
2656
3190
|
type: "checkbox"
|
|
2657
|
-
},
|
|
2658
|
-
onChange:
|
|
2659
|
-
}), null, 16,
|
|
2660
|
-
|
|
3191
|
+
}, f(u), {
|
|
3192
|
+
onChange: p[0] || (p[0] = (h) => l("update:modelValue", h.target.checked))
|
|
3193
|
+
}), null, 16, In),
|
|
3194
|
+
$("span", {
|
|
2661
3195
|
"aria-hidden": "true",
|
|
2662
3196
|
"data-inner-on-label": e.innerOnLabel,
|
|
2663
3197
|
"data-inner-off-label": e.innerOffLabel
|
|
2664
|
-
}, null, 8,
|
|
2665
|
-
], 8,
|
|
2666
|
-
], 16,
|
|
3198
|
+
}, null, 8, Tn)
|
|
3199
|
+
], 8, kn)
|
|
3200
|
+
], 16, wn));
|
|
2667
3201
|
}
|
|
2668
|
-
}),
|
|
3202
|
+
}), xn = ["aria-controls", "aria-selected", "data-hidden"], cl = {
|
|
2669
3203
|
__name: "BsTab",
|
|
2670
3204
|
props: {
|
|
2671
3205
|
activeTabId: {
|
|
@@ -2682,17 +3216,17 @@ const Dt = {
|
|
|
2682
3216
|
},
|
|
2683
3217
|
emits: ["tabClick"],
|
|
2684
3218
|
setup(e, { emit: a }) {
|
|
2685
|
-
const t = e,
|
|
2686
|
-
function i(
|
|
2687
|
-
(
|
|
3219
|
+
const t = e, l = U(), n = I(), o = g(() => t.activeTabId === l.id), u = g(() => t.panelId || `${l.id}-panel`);
|
|
3220
|
+
function i(d) {
|
|
3221
|
+
(d.key === "Enter" || d.key === " ") && (d.preventDefault(), d.stopPropagation(), r());
|
|
2688
3222
|
}
|
|
2689
|
-
function
|
|
2690
|
-
if (t.activeTabId !==
|
|
2691
|
-
const
|
|
2692
|
-
|
|
3223
|
+
function r() {
|
|
3224
|
+
if (t.activeTabId !== l.id) {
|
|
3225
|
+
const d = new CustomEvent("tabClick", { detail: l.id, bubbles: !0 });
|
|
3226
|
+
n.value.dispatchEvent(d);
|
|
2693
3227
|
}
|
|
2694
3228
|
}
|
|
2695
|
-
return (
|
|
3229
|
+
return (d, c) => (s(), v("div", {
|
|
2696
3230
|
"aria-controls": u.value,
|
|
2697
3231
|
"aria-selected": o.value ? "true" : "false",
|
|
2698
3232
|
"data-hidden": e.hidden || void 0,
|
|
@@ -2700,14 +3234,14 @@ const Dt = {
|
|
|
2700
3234
|
role: "tab",
|
|
2701
3235
|
tabindex: "0",
|
|
2702
3236
|
ref_key: "hostEl",
|
|
2703
|
-
ref:
|
|
2704
|
-
onClick:
|
|
3237
|
+
ref: n,
|
|
3238
|
+
onClick: r,
|
|
2705
3239
|
onKeydown: i
|
|
2706
3240
|
}, [
|
|
2707
|
-
|
|
2708
|
-
], 40,
|
|
3241
|
+
L(d.$slots, "default")
|
|
3242
|
+
], 40, xn));
|
|
2709
3243
|
}
|
|
2710
|
-
},
|
|
3244
|
+
}, Cn = ["id", "data-resizing"], An = ["aria-controls", "aria-expanded", "data-active", "data-hidden", "id"], Ln = 73, Vn = 20, En = 16, fl = {
|
|
2711
3245
|
__name: "BsTabList",
|
|
2712
3246
|
props: {
|
|
2713
3247
|
activeTabId: { type: String, required: !0 },
|
|
@@ -2718,182 +3252,182 @@ const Dt = {
|
|
|
2718
3252
|
},
|
|
2719
3253
|
emits: ["tabChange", "update:modelValue"],
|
|
2720
3254
|
setup(e, { emit: a }) {
|
|
2721
|
-
const t = e,
|
|
2722
|
-
var
|
|
2723
|
-
return
|
|
2724
|
-
}),
|
|
2725
|
-
var
|
|
2726
|
-
let
|
|
3255
|
+
const t = e, l = a, n = I(!1), o = I(!1), u = I([]), i = I(!1), r = I(!1), d = I(), c = I([]), p = I(!1), h = I([]), m = I(), V = I(), T = I(), [k, E] = K(2), y = g(() => t.activeTabId ? h.value.findIndex((B) => B.id === t.activeTabId) : 0), b = g(() => u.value.some((B) => B.id === t.activeTabId)), S = g(() => `${E.value}-options`), x = g(() => `${E.value}-toggle`), N = g(() => {
|
|
3256
|
+
var B;
|
|
3257
|
+
return b.value ? (B = h.value[y.value]) == null ? void 0 : B.textContent : "More";
|
|
3258
|
+
}), re = g(() => b.value ? c.value[y.value] - c.value[y.value - 1] + Vn : Ln), Z = g(() => {
|
|
3259
|
+
var C, q;
|
|
3260
|
+
let B = [];
|
|
2727
3261
|
if (typeof window > "u")
|
|
2728
|
-
return
|
|
2729
|
-
for (let
|
|
2730
|
-
if (((
|
|
3262
|
+
return B;
|
|
3263
|
+
for (let j of h.value) {
|
|
3264
|
+
if (((C = j.dataset) == null ? void 0 : C.hidden) === "true" || ((q = j.dataset) == null ? void 0 : q.hidden) === "" || j.getAttribute("tabindex") === "-1")
|
|
2731
3265
|
break;
|
|
2732
|
-
|
|
3266
|
+
B.push(j);
|
|
2733
3267
|
}
|
|
2734
|
-
return
|
|
3268
|
+
return r.value && B.push(d.value.querySelector(".bs-tab-list-toggle")), B;
|
|
2735
3269
|
});
|
|
2736
|
-
function
|
|
2737
|
-
var
|
|
2738
|
-
let
|
|
2739
|
-
if ((
|
|
2740
|
-
for (let
|
|
2741
|
-
if (
|
|
2742
|
-
|
|
3270
|
+
function le() {
|
|
3271
|
+
var J;
|
|
3272
|
+
let B = !1, C, q = 0, j = !1, Y = [];
|
|
3273
|
+
if ((J = h.value) != null && J.length) {
|
|
3274
|
+
for (let X = 0; X < h.value.length; X++) {
|
|
3275
|
+
if (C = h.value[X], C.setAttribute("tabindex", "-1"), j && X !== y.value) {
|
|
3276
|
+
C.dataset.hidden = "true", Y.push(C);
|
|
2743
3277
|
continue;
|
|
2744
3278
|
}
|
|
2745
|
-
if (
|
|
2746
|
-
|
|
3279
|
+
if (q = X < h.value.length - 1 ? T.value - re.value : T.value, c.value[X] > q) {
|
|
3280
|
+
C.dataset.hidden = "true", Y.push(C), B = !0, j = !0;
|
|
2747
3281
|
continue;
|
|
2748
3282
|
}
|
|
2749
|
-
|
|
3283
|
+
C.dataset.hidden = "false", C.setAttribute("tabindex", "0");
|
|
2750
3284
|
}
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
},
|
|
3285
|
+
r.value = B, u.value = Y, n.value || oe(() => n.value = !0), setTimeout(() => {
|
|
3286
|
+
Ge(), p.value = !0;
|
|
3287
|
+
}, p.value ? 0 : 1e3);
|
|
2754
3288
|
}
|
|
2755
3289
|
}
|
|
2756
|
-
function
|
|
2757
|
-
|
|
3290
|
+
function he(B) {
|
|
3291
|
+
l("tabChange", B), l("update:modelValue", B);
|
|
2758
3292
|
}
|
|
2759
|
-
function
|
|
2760
|
-
var
|
|
2761
|
-
const
|
|
2762
|
-
return
|
|
3293
|
+
function qe(B) {
|
|
3294
|
+
var j, Y, J;
|
|
3295
|
+
const C = (J = (Y = (j = h.value[B]) == null ? void 0 : j.getBoundingClientRect) == null ? void 0 : Y.call(j)) == null ? void 0 : J.width;
|
|
3296
|
+
return C || (B === 0 ? c.value[0] : c.value[B] - c.value[B - 1]) || 0;
|
|
2763
3297
|
}
|
|
2764
|
-
function
|
|
2765
|
-
var
|
|
2766
|
-
(
|
|
3298
|
+
function Me() {
|
|
3299
|
+
var B;
|
|
3300
|
+
(B = h.value[y.value]) == null || B.setAttribute("aria-selected", "true"), le();
|
|
2767
3301
|
}
|
|
2768
|
-
function
|
|
2769
|
-
var
|
|
2770
|
-
(
|
|
3302
|
+
function ze() {
|
|
3303
|
+
var B;
|
|
3304
|
+
(B = m.value) == null || B.focus(), i.value = !1;
|
|
2771
3305
|
}
|
|
2772
|
-
function
|
|
3306
|
+
function Re() {
|
|
2773
3307
|
i.value = !i.value, o.value || (o.value = !0);
|
|
2774
3308
|
}
|
|
2775
|
-
function
|
|
2776
|
-
var
|
|
2777
|
-
i.value = !1, (
|
|
3309
|
+
function Ne(B) {
|
|
3310
|
+
var C;
|
|
3311
|
+
i.value = !1, (C = m.value) == null || C.focus(), he(B);
|
|
2778
3312
|
}
|
|
2779
|
-
function
|
|
3313
|
+
function je(B) {
|
|
2780
3314
|
if (t.withBsTabs)
|
|
2781
3315
|
return;
|
|
2782
|
-
const
|
|
2783
|
-
if (!
|
|
3316
|
+
const C = B.target.closest('[role="tab"]');
|
|
3317
|
+
if (!C || C.getAttribute("aria-selected") === "true")
|
|
2784
3318
|
return;
|
|
2785
|
-
const
|
|
2786
|
-
|
|
3319
|
+
const q = C.getAttribute("id");
|
|
3320
|
+
he(q);
|
|
2787
3321
|
}
|
|
2788
|
-
function
|
|
2789
|
-
if (
|
|
2790
|
-
const
|
|
2791
|
-
if (
|
|
3322
|
+
function We(B) {
|
|
3323
|
+
if (B.key === "ArrowLeft" || B.key === "ArrowRight") {
|
|
3324
|
+
const C = Z.value.findIndex((q) => q.id === B.target.id);
|
|
3325
|
+
if (C === -1)
|
|
2792
3326
|
return;
|
|
2793
|
-
|
|
3327
|
+
B.preventDefault(), B.stopPropagation(), B.key === "ArrowLeft" ? Ue(C) : Fe(C);
|
|
2794
3328
|
}
|
|
2795
3329
|
}
|
|
2796
|
-
function
|
|
2797
|
-
var
|
|
2798
|
-
const
|
|
2799
|
-
(
|
|
2800
|
-
}
|
|
2801
|
-
function
|
|
2802
|
-
var
|
|
2803
|
-
const
|
|
2804
|
-
(
|
|
2805
|
-
}
|
|
2806
|
-
function
|
|
2807
|
-
var
|
|
2808
|
-
const
|
|
2809
|
-
let
|
|
2810
|
-
|
|
2811
|
-
}
|
|
2812
|
-
function
|
|
2813
|
-
var
|
|
2814
|
-
(
|
|
2815
|
-
}
|
|
2816
|
-
function
|
|
2817
|
-
|
|
2818
|
-
for (let
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
}),
|
|
2822
|
-
}
|
|
2823
|
-
function
|
|
2824
|
-
|
|
2825
|
-
}
|
|
2826
|
-
function
|
|
2827
|
-
let
|
|
2828
|
-
|
|
2829
|
-
|
|
3330
|
+
function Fe(B) {
|
|
3331
|
+
var q;
|
|
3332
|
+
const C = (B + 1) % Z.value.length;
|
|
3333
|
+
(q = Z.value[C]) == null || q.focus();
|
|
3334
|
+
}
|
|
3335
|
+
function Ue(B) {
|
|
3336
|
+
var q;
|
|
3337
|
+
const C = B === 0 ? Z.value.length - 1 : B - 1;
|
|
3338
|
+
(q = Z.value[C]) == null || q.focus();
|
|
3339
|
+
}
|
|
3340
|
+
function Ge() {
|
|
3341
|
+
var J, X, we, ke;
|
|
3342
|
+
const B = parseInt(d.value.style.getPropertyValue("--active-line-offset")) || 0, C = T.value;
|
|
3343
|
+
let q = 300, j = ((X = (J = Z.value) == null ? void 0 : J[y.value]) == null ? void 0 : X.offsetLeft) || 0, Y = qe(y.value);
|
|
3344
|
+
r.value && b.value && (j = (we = m.value) == null ? void 0 : we.offsetLeft, Y = (ke = m.value) == null ? void 0 : ke.offsetWidth), q = Math.max(Math.abs((j - B) / C * 300), 100), d.value.style.setProperty("--active-line-max-width", `${C}px`), d.value.style.setProperty("--active-line-scale", `${Y / C}`), d.value.style.setProperty("--active-line-offset", `${j}px`), d.value.style.setProperty("--active-line-transition-duration", `${q}ms`);
|
|
3345
|
+
}
|
|
3346
|
+
function He() {
|
|
3347
|
+
var B, C;
|
|
3348
|
+
(C = (B = V.value) == null ? void 0 : B.disconnect) == null || C.call(B), V.value = null;
|
|
3349
|
+
}
|
|
3350
|
+
function Ke() {
|
|
3351
|
+
V.value = new ResizeObserver((B) => {
|
|
3352
|
+
for (let C of B)
|
|
3353
|
+
T.value = C.contentBoxSize[0].inlineSize;
|
|
3354
|
+
le();
|
|
3355
|
+
}), V.value.observe(d.value);
|
|
3356
|
+
}
|
|
3357
|
+
function Ye() {
|
|
3358
|
+
h.value = Array.from(d.value.children).filter((B) => B.role === "tab");
|
|
3359
|
+
}
|
|
3360
|
+
function Xe() {
|
|
3361
|
+
let B;
|
|
3362
|
+
h.value.forEach((C, q) => {
|
|
3363
|
+
B = C.getBoundingClientRect().width + En, c.value.push(q ? B + c.value[q - 1] : B);
|
|
2830
3364
|
});
|
|
2831
3365
|
}
|
|
2832
|
-
return
|
|
2833
|
-
var
|
|
3366
|
+
return z(() => t.activeTabId, Me), F(() => {
|
|
3367
|
+
var B;
|
|
2834
3368
|
try {
|
|
2835
|
-
|
|
2836
|
-
} catch (
|
|
2837
|
-
console.log("tab error",
|
|
3369
|
+
Ye(), Xe(), Ke(), T.value = d.value.getBoundingClientRect().width, le(), t.withBsTabs || (B = h.value[y.value]) == null || B.setAttribute("aria-selected", "true");
|
|
3370
|
+
} catch (C) {
|
|
3371
|
+
console.log("tab error", C);
|
|
2838
3372
|
}
|
|
2839
|
-
}),
|
|
3373
|
+
}), _(He), (B, C) => (s(), v("div", {
|
|
2840
3374
|
class: "bs-tab-list",
|
|
2841
3375
|
"data-component": "bs-tab-list",
|
|
2842
|
-
id:
|
|
3376
|
+
id: B.$attrs.id || f(k),
|
|
2843
3377
|
ref_key: "hostEl",
|
|
2844
|
-
ref:
|
|
3378
|
+
ref: d,
|
|
2845
3379
|
role: "tablist",
|
|
2846
|
-
"data-resizing": !
|
|
2847
|
-
onClick:
|
|
2848
|
-
"on:tabClick":
|
|
2849
|
-
onKeydown:
|
|
3380
|
+
"data-resizing": !n.value || void 0,
|
|
3381
|
+
onClick: je,
|
|
3382
|
+
"on:tabClick": C[0] || (C[0] = (q) => he(q.detail)),
|
|
3383
|
+
onKeydown: We
|
|
2850
3384
|
}, [
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
"aria-controls":
|
|
3385
|
+
L(B.$slots, "default"),
|
|
3386
|
+
$("button", {
|
|
3387
|
+
"aria-controls": f(E),
|
|
2854
3388
|
"aria-expanded": i.value,
|
|
2855
3389
|
class: "bs-tab-list-toggle",
|
|
2856
|
-
"data-active":
|
|
2857
|
-
"data-hidden": !
|
|
2858
|
-
id:
|
|
3390
|
+
"data-active": b.value || void 0,
|
|
3391
|
+
"data-hidden": !r.value,
|
|
3392
|
+
id: x.value,
|
|
2859
3393
|
ref_key: "dropdownToggle",
|
|
2860
|
-
ref:
|
|
2861
|
-
onClick:
|
|
3394
|
+
ref: m,
|
|
3395
|
+
onClick: Re
|
|
2862
3396
|
}, [
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
], 8,
|
|
2866
|
-
|
|
2867
|
-
"anchor-id":
|
|
2868
|
-
"container-id":
|
|
3397
|
+
D(f(rt), { size: "sm" }),
|
|
3398
|
+
W(" " + A(N.value), 1)
|
|
3399
|
+
], 8, An),
|
|
3400
|
+
D(Pe, {
|
|
3401
|
+
"anchor-id": x.value,
|
|
3402
|
+
"container-id": B.$attrs.id || f(k),
|
|
2869
3403
|
"helper-description": e.helperDescription || void 0,
|
|
2870
3404
|
"helper-text": e.helperText,
|
|
2871
|
-
id:
|
|
2872
|
-
"options-id":
|
|
3405
|
+
id: f(E),
|
|
3406
|
+
"options-id": S.value,
|
|
2873
3407
|
position: "right",
|
|
2874
3408
|
preloaded: "",
|
|
2875
3409
|
shown: i.value,
|
|
2876
3410
|
width: "content",
|
|
2877
|
-
onClose:
|
|
2878
|
-
"onUpdate:modelValue":
|
|
3411
|
+
onClose: ze,
|
|
3412
|
+
"onUpdate:modelValue": Ne
|
|
2879
3413
|
}, {
|
|
2880
|
-
default:
|
|
2881
|
-
(
|
|
2882
|
-
key:
|
|
2883
|
-
value:
|
|
2884
|
-
"options-id":
|
|
3414
|
+
default: P(() => [
|
|
3415
|
+
(s(!0), v(R, null, G(u.value, (q) => (s(), O(ie, {
|
|
3416
|
+
key: q.id,
|
|
3417
|
+
value: q.id,
|
|
3418
|
+
"options-id": S.value
|
|
2885
3419
|
}, {
|
|
2886
|
-
default:
|
|
2887
|
-
|
|
3420
|
+
default: P(() => [
|
|
3421
|
+
W(A(q.textContent), 1)
|
|
2888
3422
|
]),
|
|
2889
3423
|
_: 2
|
|
2890
3424
|
}, 1032, ["value", "options-id"]))), 128))
|
|
2891
3425
|
]),
|
|
2892
3426
|
_: 1
|
|
2893
3427
|
}, 8, ["anchor-id", "container-id", "helper-description", "helper-text", "id", "options-id", "shown"])
|
|
2894
|
-
], 40,
|
|
3428
|
+
], 40, Cn));
|
|
2895
3429
|
}
|
|
2896
|
-
},
|
|
3430
|
+
}, Pn = ["aria-labelledby", "data-active", "id"], vl = {
|
|
2897
3431
|
__name: "BsTabPanel",
|
|
2898
3432
|
props: {
|
|
2899
3433
|
activeTabId: {
|
|
@@ -2906,18 +3440,18 @@ const Dt = {
|
|
|
2906
3440
|
}
|
|
2907
3441
|
},
|
|
2908
3442
|
setup(e) {
|
|
2909
|
-
const a = e, t =
|
|
2910
|
-
return (o, u) => (
|
|
3443
|
+
const a = e, t = U(), l = g(() => a.activeTabId && a.activeTabId === a.tabId), n = g(() => t.id || `${a.tabId}-panel`);
|
|
3444
|
+
return (o, u) => (s(), v("section", {
|
|
2911
3445
|
"aria-labelledby": e.tabId,
|
|
2912
|
-
"data-active":
|
|
3446
|
+
"data-active": l.value,
|
|
2913
3447
|
"data-component": "bs-tab-panel",
|
|
2914
|
-
id:
|
|
3448
|
+
id: n.value,
|
|
2915
3449
|
role: "tabpanel"
|
|
2916
3450
|
}, [
|
|
2917
|
-
|
|
2918
|
-
], 8,
|
|
3451
|
+
L(o.$slots, "default")
|
|
3452
|
+
], 8, Pn));
|
|
2919
3453
|
}
|
|
2920
|
-
},
|
|
3454
|
+
}, On = ["data-error", "id", "rows", "value"], Dn = {
|
|
2921
3455
|
__name: "BsTextarea",
|
|
2922
3456
|
props: {
|
|
2923
3457
|
error: {
|
|
@@ -2932,18 +3466,18 @@ const Dt = {
|
|
|
2932
3466
|
},
|
|
2933
3467
|
emits: ["update:modelValue"],
|
|
2934
3468
|
setup(e, { emit: a }) {
|
|
2935
|
-
const t = e,
|
|
2936
|
-
return (
|
|
3469
|
+
const t = e, l = g(() => ({ [t.error ? "aria-errormessage" : "aria-describedby"]: t.hintId }));
|
|
3470
|
+
return (n, o) => (s(), v("textarea", M({
|
|
2937
3471
|
class: "bs-textarea",
|
|
2938
3472
|
"data-component": "bs-textarea",
|
|
2939
3473
|
"data-error": e.error,
|
|
2940
|
-
id:
|
|
2941
|
-
rows:
|
|
3474
|
+
id: n.$attrs.id || e.inputId,
|
|
3475
|
+
rows: n.$attrs.rows || 6,
|
|
2942
3476
|
value: e.value || e.modelValue,
|
|
2943
|
-
onInput: o[0] || (o[0] = (u) =>
|
|
2944
|
-
},
|
|
3477
|
+
onInput: o[0] || (o[0] = (u) => n.$emit("update:modelValue", u.target.value))
|
|
3478
|
+
}, l.value), null, 16, On));
|
|
2945
3479
|
}
|
|
2946
|
-
},
|
|
3480
|
+
}, pl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
2947
3481
|
__name: "BsTextareaField",
|
|
2948
3482
|
props: {
|
|
2949
3483
|
/** Sets the maximum value this textarea will allow. Will also display character count if present. This does not set maxlength, so users are able to enter text that is longer and edit it down. Enforcement of length must be by the developer. */
|
|
@@ -2992,59 +3526,59 @@ const Dt = {
|
|
|
2992
3526
|
},
|
|
2993
3527
|
emits: ["update:modelValue"],
|
|
2994
3528
|
setup(e, { emit: a }) {
|
|
2995
|
-
const t = e,
|
|
3529
|
+
const t = e, l = U(), [n, o] = K(2), { toChild: u, toRoot: i } = ae(t, l, [
|
|
2996
3530
|
"aria-label",
|
|
2997
3531
|
"autocomplete",
|
|
2998
3532
|
"cols",
|
|
2999
3533
|
"maxlength",
|
|
3000
3534
|
"minlength",
|
|
3001
3535
|
"name"
|
|
3002
|
-
]),
|
|
3003
|
-
var
|
|
3004
|
-
return ((
|
|
3005
|
-
}),
|
|
3006
|
-
var
|
|
3007
|
-
return ((
|
|
3536
|
+
]), r = g(() => {
|
|
3537
|
+
var h;
|
|
3538
|
+
return ((h = t.value || t.modelValue) == null ? void 0 : h.length) || 0;
|
|
3539
|
+
}), d = g(() => {
|
|
3540
|
+
var h, m;
|
|
3541
|
+
return ((m = (h = t.hints) == null ? void 0 : h.join) == null ? void 0 : m.call(h, `
|
|
3008
3542
|
`)) || t.hints;
|
|
3009
|
-
}), c =
|
|
3010
|
-
return (
|
|
3011
|
-
e.label ||
|
|
3543
|
+
}), c = g(() => t.error && t.errorMsg || t.hint || d.value || void 0), p = g(() => t.inputId || n.value);
|
|
3544
|
+
return (h, m) => (s(), v("div", M({ "data-component": "bs-textarea-field" }, f(i)), [
|
|
3545
|
+
e.label || h.$slots.label ? (s(), O(ne, {
|
|
3012
3546
|
key: 0,
|
|
3013
|
-
for:
|
|
3547
|
+
for: p.value,
|
|
3014
3548
|
disabled: e.disabled,
|
|
3015
3549
|
required: e.required
|
|
3016
3550
|
}, {
|
|
3017
|
-
default:
|
|
3018
|
-
|
|
3019
|
-
|
|
3551
|
+
default: P(() => [
|
|
3552
|
+
L(h.$slots, "label", {}, () => [
|
|
3553
|
+
W(A(e.label), 1)
|
|
3020
3554
|
])
|
|
3021
3555
|
]),
|
|
3022
3556
|
_: 3
|
|
3023
|
-
}, 8, ["for", "disabled", "required"])) :
|
|
3024
|
-
|
|
3557
|
+
}, 8, ["for", "disabled", "required"])) : w("", !0),
|
|
3558
|
+
D(Dn, M({
|
|
3025
3559
|
disabled: e.disabled,
|
|
3026
3560
|
error: e.error,
|
|
3027
|
-
"hint-id":
|
|
3028
|
-
id:
|
|
3561
|
+
"hint-id": f(o),
|
|
3562
|
+
id: p.value,
|
|
3029
3563
|
placeholder: e.placeholder,
|
|
3030
3564
|
required: e.required,
|
|
3031
3565
|
rows: e.rows,
|
|
3032
3566
|
value: e.value || e.modelValue,
|
|
3033
|
-
"onUpdate:modelValue":
|
|
3034
|
-
},
|
|
3035
|
-
c.value || e.charMax ? (
|
|
3567
|
+
"onUpdate:modelValue": m[0] || (m[0] = (V) => h.$emit("update:modelValue", V))
|
|
3568
|
+
}, f(u)), null, 16, ["disabled", "error", "hint-id", "id", "placeholder", "required", "rows", "value"]),
|
|
3569
|
+
c.value || e.charMax ? (s(), O(Se, {
|
|
3036
3570
|
key: 1,
|
|
3037
|
-
"char-count":
|
|
3571
|
+
"char-count": r.value,
|
|
3038
3572
|
"char-max": e.charMax,
|
|
3039
3573
|
"data-disabled": e.disabled,
|
|
3040
3574
|
error: e.error,
|
|
3041
3575
|
"error-msg": e.errorMsg,
|
|
3042
|
-
hint: e.hint ||
|
|
3043
|
-
"hint-id":
|
|
3044
|
-
}, null, 8, ["char-count", "char-max", "data-disabled", "error", "error-msg", "hint", "hint-id"])) :
|
|
3576
|
+
hint: e.hint || d.value,
|
|
3577
|
+
"hint-id": f(o)
|
|
3578
|
+
}, null, 8, ["char-count", "char-max", "data-disabled", "error", "error-msg", "hint", "hint-id"])) : w("", !0)
|
|
3045
3579
|
], 16));
|
|
3046
3580
|
}
|
|
3047
|
-
}),
|
|
3581
|
+
}), qn = ["data-variant", "data-stacked"], hl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
3048
3582
|
__name: "BsToast",
|
|
3049
3583
|
props: {
|
|
3050
3584
|
shown: {
|
|
@@ -3090,111 +3624,106 @@ const Dt = {
|
|
|
3090
3624
|
},
|
|
3091
3625
|
emits: ["dismiss", "after-enter", "after-leave"],
|
|
3092
3626
|
setup(e, { emit: a }) {
|
|
3093
|
-
const t = e,
|
|
3627
|
+
const t = e, l = a, { transition: n } = ve(t);
|
|
3094
3628
|
let o = null;
|
|
3095
|
-
|
|
3629
|
+
ee("variant", t.variant), ee("handleDismiss", i);
|
|
3096
3630
|
const u = te("stacked", t.stacked);
|
|
3097
3631
|
function i() {
|
|
3098
|
-
o && (clearTimeout(o), o = null),
|
|
3632
|
+
o && (clearTimeout(o), o = null), l("dismiss", t.toastId);
|
|
3099
3633
|
}
|
|
3100
|
-
function
|
|
3634
|
+
function r() {
|
|
3101
3635
|
t.duration > 0 && (o = setTimeout(() => {
|
|
3102
3636
|
i();
|
|
3103
|
-
}, t.duration)),
|
|
3637
|
+
}, t.duration)), l("after-enter");
|
|
3104
3638
|
}
|
|
3105
|
-
return (
|
|
3106
|
-
shown:
|
|
3639
|
+
return (d, c) => (s(), O(f(pe), {
|
|
3640
|
+
shown: f(n),
|
|
3107
3641
|
preloaded: e.preloaded,
|
|
3108
3642
|
duration: 200,
|
|
3109
3643
|
"enter-attribute": "data-shown",
|
|
3110
|
-
onAfterEnter:
|
|
3111
|
-
onAfterLeave: c[0] || (c[0] = (
|
|
3644
|
+
onAfterEnter: r,
|
|
3645
|
+
onAfterLeave: c[0] || (c[0] = (p) => l("after-leave"))
|
|
3112
3646
|
}, {
|
|
3113
|
-
default:
|
|
3114
|
-
|
|
3647
|
+
default: P(() => [
|
|
3648
|
+
$("div", M({
|
|
3115
3649
|
class: "bs-toast",
|
|
3116
3650
|
"data-variant": e.variant,
|
|
3117
|
-
"data-stacked":
|
|
3651
|
+
"data-stacked": f(u) || void 0,
|
|
3118
3652
|
"aria-role": "alert"
|
|
3119
|
-
},
|
|
3120
|
-
|
|
3121
|
-
], 16,
|
|
3653
|
+
}, d.$attrs), [
|
|
3654
|
+
L(d.$slots, "default")
|
|
3655
|
+
], 16, qn)
|
|
3122
3656
|
]),
|
|
3123
3657
|
_: 3
|
|
3124
3658
|
}, 8, ["shown", "preloaded"]));
|
|
3125
3659
|
}
|
|
3126
|
-
}),
|
|
3660
|
+
}), Mn = ["data-stacked"], bl = {
|
|
3127
3661
|
__name: "BsToastActions",
|
|
3128
3662
|
setup(e) {
|
|
3129
3663
|
const a = I(!1);
|
|
3130
|
-
|
|
3131
|
-
var
|
|
3132
|
-
const
|
|
3133
|
-
((
|
|
3664
|
+
F(() => {
|
|
3665
|
+
var n;
|
|
3666
|
+
const l = et();
|
|
3667
|
+
((n = l.default) == null ? void 0 : n.call(l).length) > 2 && (a.value = !0);
|
|
3134
3668
|
});
|
|
3135
3669
|
const t = te("handleDismiss");
|
|
3136
|
-
return (
|
|
3670
|
+
return (l, n) => (s(), v("div", {
|
|
3137
3671
|
class: "bs-toast-actions",
|
|
3138
3672
|
"data-stacked": a.value || void 0
|
|
3139
3673
|
}, [
|
|
3140
|
-
|
|
3141
|
-
|
|
3674
|
+
L(l.$slots, "default", {}, () => [
|
|
3675
|
+
D(Vt, {
|
|
3142
3676
|
size: "sm",
|
|
3143
3677
|
"text-btn": "",
|
|
3144
|
-
onClick:
|
|
3678
|
+
onClick: f(t)
|
|
3145
3679
|
}, {
|
|
3146
|
-
default:
|
|
3147
|
-
|
|
3680
|
+
default: P(() => [
|
|
3681
|
+
W(" Dismiss ")
|
|
3148
3682
|
]),
|
|
3149
3683
|
_: 1
|
|
3150
3684
|
}, 8, ["onClick"])
|
|
3151
3685
|
])
|
|
3152
|
-
], 8,
|
|
3686
|
+
], 8, Mn));
|
|
3153
3687
|
}
|
|
3154
|
-
},
|
|
3155
|
-
|
|
3156
|
-
|
|
3157
|
-
|
|
3158
|
-
return t;
|
|
3159
|
-
}, Bn = {}, $n = { class: "bs-toast-body" };
|
|
3160
|
-
function Sn(e, a) {
|
|
3161
|
-
return d(), f("div", $n, [
|
|
3162
|
-
k(e.$slots, "default")
|
|
3688
|
+
}, zn = {}, Rn = { class: "bs-toast-body" };
|
|
3689
|
+
function Nn(e, a) {
|
|
3690
|
+
return s(), v("div", Rn, [
|
|
3691
|
+
L(e.$slots, "default")
|
|
3163
3692
|
]);
|
|
3164
3693
|
}
|
|
3165
|
-
const
|
|
3694
|
+
const gl = /* @__PURE__ */ De(zn, [["render", Nn]]), jn = ["data-variant"], ml = {
|
|
3166
3695
|
__name: "BsToastHeader",
|
|
3167
3696
|
setup(e) {
|
|
3168
|
-
const a = te("variant"), t =
|
|
3697
|
+
const a = te("variant"), t = g(() => {
|
|
3169
3698
|
switch (a) {
|
|
3170
3699
|
case "warning":
|
|
3171
|
-
return
|
|
3700
|
+
return ge;
|
|
3172
3701
|
case "positive":
|
|
3173
|
-
return
|
|
3702
|
+
return dt;
|
|
3174
3703
|
case "negative":
|
|
3175
|
-
return
|
|
3704
|
+
return ge;
|
|
3176
3705
|
default:
|
|
3177
|
-
return
|
|
3706
|
+
return st;
|
|
3178
3707
|
}
|
|
3179
3708
|
});
|
|
3180
|
-
return (
|
|
3709
|
+
return (l, n) => (s(), v("div", {
|
|
3181
3710
|
class: "bs-toast-header",
|
|
3182
|
-
"data-variant":
|
|
3711
|
+
"data-variant": f(a)
|
|
3183
3712
|
}, [
|
|
3184
|
-
(
|
|
3185
|
-
|
|
3186
|
-
|
|
3713
|
+
(s(), O(H(t.value), { class: "bs-toast-header-icon" })),
|
|
3714
|
+
$("h5", null, [
|
|
3715
|
+
L(l.$slots, "default")
|
|
3187
3716
|
])
|
|
3188
|
-
], 8,
|
|
3717
|
+
], 8, jn));
|
|
3189
3718
|
}
|
|
3190
|
-
},
|
|
3719
|
+
}, Wn = { class: "bs-toaster" }, yl = {
|
|
3191
3720
|
__name: "BsToaster",
|
|
3192
3721
|
setup(e) {
|
|
3193
|
-
return
|
|
3194
|
-
|
|
3722
|
+
return ee("stacked", !0), (a, t) => (s(), v("div", Wn, [
|
|
3723
|
+
L(a.$slots, "default")
|
|
3195
3724
|
]));
|
|
3196
3725
|
}
|
|
3197
|
-
},
|
|
3726
|
+
}, Fn = ["data-position"], Un = ["id"], Bl = {
|
|
3198
3727
|
__name: "BsTooltip",
|
|
3199
3728
|
props: {
|
|
3200
3729
|
tooltipId: {
|
|
@@ -3221,20 +3750,20 @@ const el = /* @__PURE__ */ yn(Bn, [["render", Sn]]), wn = ["data-variant"], tl =
|
|
|
3221
3750
|
}
|
|
3222
3751
|
},
|
|
3223
3752
|
setup(e) {
|
|
3224
|
-
const a = e, t = I(!1),
|
|
3753
|
+
const a = e, t = I(!1), l = I(!1), n = g(() => {
|
|
3225
3754
|
let i = "bs-tooltip-text";
|
|
3226
|
-
return
|
|
3755
|
+
return l.value && (a.position === void 0 || a.position === "top" || a.position === "bottom" ? i += " escaped-x" : a.position === "left" || a.position === "right" ? i += " escaped-y" : i += " escaped"), i;
|
|
3227
3756
|
});
|
|
3228
|
-
|
|
3229
|
-
t.value && (t.value = !1,
|
|
3757
|
+
fe(["Escape"], () => {
|
|
3758
|
+
t.value && (t.value = !1, l.value = !0);
|
|
3230
3759
|
});
|
|
3231
3760
|
function o() {
|
|
3232
3761
|
t.value = !0;
|
|
3233
3762
|
}
|
|
3234
3763
|
function u() {
|
|
3235
|
-
t.value = !1,
|
|
3764
|
+
t.value = !1, l.value = !1;
|
|
3236
3765
|
}
|
|
3237
|
-
return (i,
|
|
3766
|
+
return (i, r) => (s(), v("div", {
|
|
3238
3767
|
class: "bs-tooltip",
|
|
3239
3768
|
"data-position": e.position || void 0,
|
|
3240
3769
|
"data-component": "bs-tooltip",
|
|
@@ -3243,58 +3772,61 @@ const el = /* @__PURE__ */ yn(Bn, [["render", Sn]]), wn = ["data-variant"], tl =
|
|
|
3243
3772
|
onMouseleave: u,
|
|
3244
3773
|
onFocusout: u
|
|
3245
3774
|
}, [
|
|
3246
|
-
|
|
3247
|
-
e.content ? (
|
|
3775
|
+
L(i.$slots, "default"),
|
|
3776
|
+
e.content ? (s(), v("div", {
|
|
3248
3777
|
key: 0,
|
|
3249
|
-
class:
|
|
3778
|
+
class: Q(n.value),
|
|
3250
3779
|
id: e.tooltipId,
|
|
3251
3780
|
role: "tooltip"
|
|
3252
|
-
},
|
|
3253
|
-
], 40,
|
|
3781
|
+
}, A(e.content), 11, Un)) : w("", !0)
|
|
3782
|
+
], 40, Fn));
|
|
3254
3783
|
}
|
|
3255
3784
|
};
|
|
3256
3785
|
export {
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
|
|
3276
|
-
|
|
3277
|
-
|
|
3278
|
-
|
|
3279
|
-
|
|
3280
|
-
|
|
3281
|
-
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
3297
|
-
|
|
3298
|
-
|
|
3299
|
-
|
|
3786
|
+
Xn as BsAccordion,
|
|
3787
|
+
xt as BsBadge,
|
|
3788
|
+
Zn as BsBanner,
|
|
3789
|
+
Vt as BsButton,
|
|
3790
|
+
Jn as BsChartBar,
|
|
3791
|
+
Ae as BsCheckbox,
|
|
3792
|
+
Qn as BsCircleButton,
|
|
3793
|
+
Ee as BsDropdown,
|
|
3794
|
+
ua as BsDropdownMultiselect,
|
|
3795
|
+
ie as BsDropdownOption,
|
|
3796
|
+
$e as BsDropdownOptionList,
|
|
3797
|
+
Pe as BsDropdownWithOptions,
|
|
3798
|
+
_n as BsDropdownWithToggle,
|
|
3799
|
+
Se as BsFieldDetails,
|
|
3800
|
+
va as BsFilterButton,
|
|
3801
|
+
el as BsIconGradientWrapper,
|
|
3802
|
+
Oe as BsInput,
|
|
3803
|
+
wa as BsInputAddon,
|
|
3804
|
+
tl as BsInputField,
|
|
3805
|
+
ka as BsInputSearch,
|
|
3806
|
+
al as BsInputTypeahead,
|
|
3807
|
+
ne as BsLabel,
|
|
3808
|
+
nl as BsLoader,
|
|
3809
|
+
ll as BsModal,
|
|
3810
|
+
za as BsOverlay,
|
|
3811
|
+
ol as BsPagination,
|
|
3812
|
+
il as BsPill,
|
|
3813
|
+
rl as BsProfile,
|
|
3814
|
+
vn as BsProfileDetails,
|
|
3815
|
+
bn as BsProfileImg,
|
|
3816
|
+
sl as BsRadio,
|
|
3817
|
+
Bn as BsSelect,
|
|
3818
|
+
dl as BsSelectField,
|
|
3819
|
+
ul as BsSwitch,
|
|
3820
|
+
cl as BsTab,
|
|
3821
|
+
fl as BsTabList,
|
|
3822
|
+
vl as BsTabPanel,
|
|
3823
|
+
Dn as BsTextarea,
|
|
3824
|
+
pl as BsTextareaField,
|
|
3825
|
+
hl as BsToast,
|
|
3826
|
+
bl as BsToastActions,
|
|
3827
|
+
gl as BsToastBody,
|
|
3828
|
+
ml as BsToastHeader,
|
|
3829
|
+
yl as BsToaster,
|
|
3830
|
+
Bl as BsTooltip,
|
|
3831
|
+
pe as BsTransition
|
|
3300
3832
|
};
|