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