@useinsider/ab-components 0.0.12 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ab-components.cjs.js +1 -1
- package/dist/ab-components.cjs.js.map +1 -1
- package/dist/ab-components.css +1 -1
- package/dist/ab-components.es.js +330 -328
- package/dist/ab-components.es.js.map +1 -1
- package/dist/ab-components.iife.js +1 -1
- package/dist/ab-components.iife.js.map +1 -1
- package/dist/ab-components.umd.js +1 -1
- package/dist/ab-components.umd.js.map +1 -1
- package/dist/icons.svg +10 -0
- package/dist/index.d.ts +7 -1
- package/package.json +1 -1
package/dist/ab-components.es.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as M, computed as C, openBlock as
|
|
2
|
-
const
|
|
3
|
-
button__size_default:
|
|
4
|
-
button__size_small:
|
|
1
|
+
import { defineComponent as M, computed as C, openBlock as c, createElementBlock as d, normalizeClass as s, unref as o, createBlock as F, createCommentVNode as w, toDisplayString as S, ref as v, reactive as me, onMounted as ue, watch as _e, Fragment as ie, createElementVNode as y, withDirectives as be, normalizeStyle as X, withModifiers as Me, vModelText as Te, renderList as ge, createVNode as we, onBeforeUnmount as He, renderSlot as D, withCtx as he, nextTick as ve, resolveDynamicComponent as Ve } from "vue";
|
|
2
|
+
const Le = "_button__size_default_16zzc_1", Ne = "_button__size_small_16zzc_8", Oe = "_button_16zzc_1", Ee = "_button__label_16zzc_193", De = "_button__solid_16zzc_205", We = "_fill_16zzc_1125", A = {
|
|
3
|
+
button__size_default: Le,
|
|
4
|
+
button__size_small: Ne,
|
|
5
5
|
button: Oe,
|
|
6
|
-
button__label:
|
|
6
|
+
button__label: Ee,
|
|
7
7
|
"button__solid-primary": "_button__solid-primary_16zzc_205",
|
|
8
8
|
"no-hover-effect": "_no-hover-effect_16zzc_212",
|
|
9
9
|
"button--selected": "_button--selected_16zzc_234",
|
|
@@ -31,9 +31,9 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
31
31
|
"button__outline-danger": "_button__outline-danger_16zzc_1000",
|
|
32
32
|
"button__outline-warning": "_button__outline-warning_16zzc_1037",
|
|
33
33
|
"button__outline-smart": "_button__outline-smart_16zzc_1074",
|
|
34
|
-
button__solid:
|
|
35
|
-
fill:
|
|
36
|
-
},
|
|
34
|
+
button__solid: De,
|
|
35
|
+
fill: We
|
|
36
|
+
}, je = ["disabled"], co = /* @__PURE__ */ M({
|
|
37
37
|
__name: "Button",
|
|
38
38
|
props: {
|
|
39
39
|
variant: {},
|
|
@@ -48,69 +48,69 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
48
48
|
fill: { type: Boolean, default: !1 }
|
|
49
49
|
},
|
|
50
50
|
emits: ["click"],
|
|
51
|
-
setup(
|
|
52
|
-
const a =
|
|
51
|
+
setup(u, { emit: n }) {
|
|
52
|
+
const a = u, t = n, l = (r) => {
|
|
53
53
|
a.disabled || t("click", r);
|
|
54
|
-
},
|
|
55
|
-
return (r, e) => (
|
|
54
|
+
}, p = C(() => a.loadingStatus ? "loading-circle" : a.successStatus ? "line-check-natural" : a.leftIconName);
|
|
55
|
+
return (r, e) => (c(), d("button", {
|
|
56
56
|
class: s([
|
|
57
|
-
o(
|
|
58
|
-
o(
|
|
59
|
-
o(
|
|
60
|
-
o(
|
|
61
|
-
{ [o(
|
|
57
|
+
o(A).button,
|
|
58
|
+
o(A)[`button__${r.variant}`],
|
|
59
|
+
o(A)[`button__${r.variant}-${r.color}`],
|
|
60
|
+
o(A)[`button__size_${r.size}`],
|
|
61
|
+
{ [o(A).fill]: r.fill }
|
|
62
62
|
]),
|
|
63
63
|
disabled: a.disabled,
|
|
64
64
|
onClick: l
|
|
65
65
|
}, [
|
|
66
|
-
|
|
66
|
+
p.value ? (c(), F(o(U), {
|
|
67
67
|
key: 0,
|
|
68
|
-
name:
|
|
68
|
+
name: p.value
|
|
69
69
|
}, null, 8, ["name"])) : w("", !0),
|
|
70
|
-
r.label ? (
|
|
70
|
+
r.label ? (c(), d("span", {
|
|
71
71
|
key: 1,
|
|
72
|
-
class: s(o(
|
|
72
|
+
class: s(o(A).button__label)
|
|
73
73
|
}, S(r.label), 3)) : w("", !0),
|
|
74
|
-
r.rightIconName ? (
|
|
74
|
+
r.rightIconName ? (c(), F(o(U), {
|
|
75
75
|
key: 2,
|
|
76
76
|
name: r.rightIconName
|
|
77
77
|
}, null, 8, ["name"])) : w("", !0)
|
|
78
|
-
], 10,
|
|
78
|
+
], 10, je));
|
|
79
79
|
}
|
|
80
|
-
}),
|
|
81
|
-
mounted(
|
|
82
|
-
|
|
83
|
-
[
|
|
84
|
-
}, document.addEventListener("click",
|
|
80
|
+
}), qe = {
|
|
81
|
+
mounted(u, n) {
|
|
82
|
+
u.clickOutsideEvent = (a) => {
|
|
83
|
+
[u, ...n.value.exclude || []].some((l) => l && (l === a.target || l.contains(a.target))) || n.value.handler();
|
|
84
|
+
}, document.addEventListener("click", u.clickOutsideEvent);
|
|
85
85
|
},
|
|
86
|
-
unmounted(
|
|
87
|
-
|
|
86
|
+
unmounted(u) {
|
|
87
|
+
u.clickOutsideEvent && document.removeEventListener("click", u.clickOutsideEvent);
|
|
88
88
|
}
|
|
89
|
-
},
|
|
89
|
+
}, Ae = (u, n) => {
|
|
90
90
|
var t;
|
|
91
91
|
let a = 0;
|
|
92
|
-
for (const l of
|
|
92
|
+
for (const l of u)
|
|
93
93
|
if (l.toLowerCase() === ((t = n[a]) == null ? void 0 : t.toLowerCase()) && a++, a === n.length)
|
|
94
94
|
return !0;
|
|
95
95
|
return !1;
|
|
96
|
-
},
|
|
96
|
+
}, Re = (u, n, a) => {
|
|
97
97
|
if (!a.trim())
|
|
98
|
-
return
|
|
98
|
+
return u;
|
|
99
99
|
const t = a.toLowerCase();
|
|
100
|
-
return
|
|
101
|
-
const
|
|
102
|
-
return
|
|
103
|
-
}).sort((l,
|
|
104
|
-
const r = String(l[n]).toLowerCase(), e = String(
|
|
100
|
+
return u.filter((l) => {
|
|
101
|
+
const p = String(l[n]);
|
|
102
|
+
return Ae(p.toLowerCase(), t);
|
|
103
|
+
}).sort((l, p) => {
|
|
104
|
+
const r = String(l[n]).toLowerCase(), e = String(p[n]).toLowerCase();
|
|
105
105
|
return r === t ? -1 : e === t ? 1 : r.startsWith(t) && !e.startsWith(t) ? -1 : !r.startsWith(t) && e.startsWith(t) ? 1 : r.length - e.length;
|
|
106
106
|
});
|
|
107
|
-
},
|
|
108
|
-
dropdown:
|
|
109
|
-
menu:
|
|
110
|
-
dropdown__valueContent:
|
|
107
|
+
}, Ge = "_dropdown_c02u6_1", Ye = "_menu_c02u6_1", Xe = "_dropdown__valueContent_c02u6_183", Fe = "_dropdown__label_c02u6_194", Ue = "_dropdown__value_c02u6_183", Qe = "_dropdown__placeholder_c02u6_202", Ze = "_dropdown__arrowIcon_c02u6_210", Je = "_menu__searchContainer_c02u6_225", Ke = "_menu__searchInputWrap_c02u6_229", et = "_menu__searchInput_c02u6_229", tt = "_menu__errorMessage_c02u6_251", ot = "_menu__addButton_c02u6_258", nt = "_menu__itemContainer_c02u6_266", rt = "_menu__item_c02u6_266", z = {
|
|
108
|
+
dropdown: Ge,
|
|
109
|
+
menu: Ye,
|
|
110
|
+
dropdown__valueContent: Xe,
|
|
111
111
|
"dropdown__valueContent--open": "_dropdown__valueContent--open_c02u6_191",
|
|
112
|
-
dropdown__label:
|
|
113
|
-
dropdown__value:
|
|
112
|
+
dropdown__label: Fe,
|
|
113
|
+
dropdown__value: Ue,
|
|
114
114
|
dropdown__placeholder: Qe,
|
|
115
115
|
dropdown__arrowIcon: Ze,
|
|
116
116
|
menu__searchContainer: Je,
|
|
@@ -122,7 +122,7 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
122
122
|
menu__itemContainer: nt,
|
|
123
123
|
menu__item: rt,
|
|
124
124
|
"menu__item--active": "_menu__item--active_c02u6_304"
|
|
125
|
-
}, at = ["for"], lt = ["placeholder"], st = ["onClick"],
|
|
125
|
+
}, at = ["for"], lt = ["placeholder"], st = ["onClick"], po = /* @__PURE__ */ M({
|
|
126
126
|
__name: "DropdownMenu",
|
|
127
127
|
props: {
|
|
128
128
|
id: {},
|
|
@@ -138,42 +138,42 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
138
138
|
validateAddItem: { type: Function, default: () => null }
|
|
139
139
|
},
|
|
140
140
|
emits: ["update:modelValue", "add-error", "item-added", "select-item"],
|
|
141
|
-
setup(
|
|
142
|
-
const a =
|
|
143
|
-
if (!
|
|
141
|
+
setup(u, { emit: n }) {
|
|
142
|
+
const a = qe, t = u, l = n, p = v(), r = v(), e = v(!1), _ = v(null), f = v(""), m = v(null), B = v({ x: 0, y: 0, width: 0, shouldOpenUp: !1, height: t.menuHeight }), T = me([...t.items]), P = me([...t.items]), j = () => {
|
|
143
|
+
if (!p.value)
|
|
144
144
|
return;
|
|
145
|
-
const { offsetTop:
|
|
145
|
+
const { offsetTop: b, offsetLeft: g, offsetWidth: I } = p.value, q = window.innerHeight, R = b + p.value.offsetHeight, K = R + t.menuHeight > q;
|
|
146
146
|
B.value = {
|
|
147
147
|
x: g + window.scrollX,
|
|
148
|
-
y: K ?
|
|
148
|
+
y: K ? b + window.scrollY : R + window.scrollY,
|
|
149
149
|
width: I,
|
|
150
150
|
shouldOpenUp: K,
|
|
151
151
|
height: t.menuHeight
|
|
152
152
|
};
|
|
153
|
-
},
|
|
154
|
-
|
|
155
|
-
},
|
|
156
|
-
|
|
153
|
+
}, x = () => {
|
|
154
|
+
j(), e.value = !e.value;
|
|
155
|
+
}, N = () => {
|
|
156
|
+
m.value = null, f.value = "", T.splice(0, T.length, ...P);
|
|
157
157
|
}, Q = () => {
|
|
158
|
-
e.value = !1,
|
|
159
|
-
}, oe = (
|
|
160
|
-
_.value =
|
|
161
|
-
},
|
|
162
|
-
const
|
|
158
|
+
e.value = !1, N();
|
|
159
|
+
}, oe = (b) => {
|
|
160
|
+
_.value = b, l("select-item", b), l("update:modelValue", b.value), Q();
|
|
161
|
+
}, W = () => {
|
|
162
|
+
const b = f.value.trim(), g = t.validateAddItem(b, P);
|
|
163
163
|
if (g) {
|
|
164
|
-
|
|
164
|
+
m.value = g, l("add-error", g);
|
|
165
165
|
return;
|
|
166
166
|
}
|
|
167
167
|
const I = {
|
|
168
|
-
text:
|
|
169
|
-
value:
|
|
168
|
+
text: b,
|
|
169
|
+
value: b
|
|
170
170
|
};
|
|
171
|
-
P.push(I),
|
|
171
|
+
P.push(I), N(), l("item-added", I);
|
|
172
172
|
}, ne = () => {
|
|
173
|
-
const
|
|
174
|
-
T.splice(0, T.length, ...
|
|
173
|
+
const b = Re(P, "text", f.value);
|
|
174
|
+
T.splice(0, T.length, ...b);
|
|
175
175
|
}, Z = () => {
|
|
176
|
-
|
|
176
|
+
m.value = "";
|
|
177
177
|
}, re = C(() => ({
|
|
178
178
|
top: B.value.shouldOpenUp ? `${B.value.y - 10}px` : `${B.value.y}px`,
|
|
179
179
|
left: `${B.value.x}px`,
|
|
@@ -181,29 +181,29 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
181
181
|
height: `${t.menuHeight}px`
|
|
182
182
|
}));
|
|
183
183
|
ue(() => {
|
|
184
|
-
if (
|
|
185
|
-
const
|
|
186
|
-
|
|
184
|
+
if (j(), t.modelValue) {
|
|
185
|
+
const b = P.find((g) => g.value === t.modelValue);
|
|
186
|
+
b && (_.value = b);
|
|
187
187
|
}
|
|
188
188
|
});
|
|
189
189
|
const J = C(() => _.value ? _.value.text : "");
|
|
190
190
|
return _e(
|
|
191
191
|
() => t.items,
|
|
192
|
-
(
|
|
193
|
-
P.splice(0, P.length, ...
|
|
192
|
+
(b) => {
|
|
193
|
+
P.splice(0, P.length, ...b), T.splice(0, T.length, ...b);
|
|
194
194
|
},
|
|
195
195
|
{ deep: !0 }
|
|
196
|
-
), (
|
|
196
|
+
), (b, g) => (c(), d(ie, null, [
|
|
197
197
|
y("div", {
|
|
198
198
|
ref_key: "dropdownRef",
|
|
199
|
-
ref:
|
|
199
|
+
ref: p,
|
|
200
200
|
class: s(o(z).dropdown)
|
|
201
201
|
}, [
|
|
202
|
-
|
|
202
|
+
b.label ? (c(), d("label", {
|
|
203
203
|
key: 0,
|
|
204
204
|
class: s(o(z).dropdown__label),
|
|
205
|
-
for:
|
|
206
|
-
}, S(
|
|
205
|
+
for: b.id
|
|
206
|
+
}, S(b.label), 11, at)) : w("", !0),
|
|
207
207
|
y("button", {
|
|
208
208
|
class: s([
|
|
209
209
|
o(z).dropdown__valueContent,
|
|
@@ -211,16 +211,16 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
211
211
|
[o(z)["dropdown__valueContent--open"]]: e.value
|
|
212
212
|
}
|
|
213
213
|
]),
|
|
214
|
-
onClick:
|
|
214
|
+
onClick: x
|
|
215
215
|
}, [
|
|
216
216
|
y("span", {
|
|
217
217
|
class: s(o(z).dropdown__value)
|
|
218
218
|
}, S(J.value), 3),
|
|
219
|
-
|
|
219
|
+
b.placeholder && !J.value ? (c(), d("span", {
|
|
220
220
|
key: 0,
|
|
221
221
|
class: s(o(z).dropdown__placeholder)
|
|
222
|
-
}, S(
|
|
223
|
-
(
|
|
222
|
+
}, S(b.placeholder), 3)) : w("", !0),
|
|
223
|
+
(c(), d("svg", {
|
|
224
224
|
fill: "none",
|
|
225
225
|
height: "17",
|
|
226
226
|
viewBox: "0 0 16 17",
|
|
@@ -235,64 +235,64 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
235
235
|
]), 2))
|
|
236
236
|
], 2)
|
|
237
237
|
], 2),
|
|
238
|
-
e.value ?
|
|
238
|
+
e.value ? be((c(), d("div", {
|
|
239
239
|
key: 0,
|
|
240
240
|
ref_key: "menuRef",
|
|
241
241
|
ref: r,
|
|
242
242
|
class: s(o(z).menu),
|
|
243
|
-
style:
|
|
243
|
+
style: X(re.value),
|
|
244
244
|
onClick: g[1] || (g[1] = Me(() => {
|
|
245
245
|
}, ["prevent"]))
|
|
246
246
|
}, [
|
|
247
|
-
t.searchable ? (
|
|
247
|
+
t.searchable ? (c(), d("div", {
|
|
248
248
|
key: 0,
|
|
249
249
|
class: s(o(z).menu__searchContainer)
|
|
250
250
|
}, [
|
|
251
251
|
y("div", {
|
|
252
252
|
class: s(o(z).menu__searchInputWrap)
|
|
253
253
|
}, [
|
|
254
|
-
|
|
254
|
+
be(y("input", {
|
|
255
255
|
type: "text",
|
|
256
256
|
class: s([
|
|
257
257
|
o(z).menu__searchInput,
|
|
258
258
|
{
|
|
259
|
-
[o(z)["menu__searchInput--error"]]:
|
|
259
|
+
[o(z)["menu__searchInput--error"]]: m.value
|
|
260
260
|
}
|
|
261
261
|
]),
|
|
262
|
-
placeholder:
|
|
263
|
-
"onUpdate:modelValue": g[0] || (g[0] = (I) =>
|
|
262
|
+
placeholder: b.searchPlaceHolder,
|
|
263
|
+
"onUpdate:modelValue": g[0] || (g[0] = (I) => f.value = I),
|
|
264
264
|
onFocus: Z,
|
|
265
265
|
onInput: ne
|
|
266
266
|
}, null, 42, lt), [
|
|
267
|
-
[Te,
|
|
267
|
+
[Te, f.value]
|
|
268
268
|
]),
|
|
269
|
-
|
|
269
|
+
m.value ? (c(), d("p", {
|
|
270
270
|
key: 0,
|
|
271
271
|
class: s(o(z).menu__errorMessage)
|
|
272
|
-
}, S(
|
|
272
|
+
}, S(m.value), 3)) : w("", !0)
|
|
273
273
|
], 2),
|
|
274
|
-
t.addable ? (
|
|
274
|
+
t.addable ? (c(), d("button", {
|
|
275
275
|
key: 0,
|
|
276
276
|
class: s(o(z).menu__addButton),
|
|
277
|
-
onClick:
|
|
278
|
-
}, S(
|
|
277
|
+
onClick: W
|
|
278
|
+
}, S(b.addButtonText), 3)) : w("", !0)
|
|
279
279
|
], 2)) : w("", !0),
|
|
280
280
|
y("ul", {
|
|
281
281
|
class: s(o(z).menu__itemContainer)
|
|
282
282
|
}, [
|
|
283
|
-
(
|
|
284
|
-
key: `${I.value}-${
|
|
283
|
+
(c(!0), d(ie, null, ge(T, (I, q) => (c(), d("li", {
|
|
284
|
+
key: `${I.value}-${q}`,
|
|
285
285
|
class: s([
|
|
286
286
|
o(z).menu__item,
|
|
287
287
|
{
|
|
288
288
|
[o(z)["menu__item--active"]]: _.value && I.value === _.value.value
|
|
289
289
|
}
|
|
290
290
|
]),
|
|
291
|
-
onClick: (
|
|
291
|
+
onClick: (R) => oe(I)
|
|
292
292
|
}, S(I.text), 11, st))), 128))
|
|
293
293
|
], 2)
|
|
294
294
|
], 6)), [
|
|
295
|
-
[o(a), { handler: Q, exclude: [
|
|
295
|
+
[o(a), { handler: Q, exclude: [p.value, r.value] }]
|
|
296
296
|
]) : w("", !0)
|
|
297
297
|
], 64));
|
|
298
298
|
}
|
|
@@ -303,9 +303,9 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
303
303
|
size: { default: 16 },
|
|
304
304
|
color: {}
|
|
305
305
|
},
|
|
306
|
-
setup(
|
|
307
|
-
const n =
|
|
308
|
-
return (t, l) => (
|
|
306
|
+
setup(u) {
|
|
307
|
+
const n = u, a = C(() => typeof n.size == "number" ? `${n.size}px` : n.size);
|
|
308
|
+
return (t, l) => (c(), d("svg", {
|
|
309
309
|
class: "icon",
|
|
310
310
|
fill: t.color || "currentColor",
|
|
311
311
|
height: a.value,
|
|
@@ -316,26 +316,26 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
316
316
|
}, null, 8, it)
|
|
317
317
|
], 8, _t));
|
|
318
318
|
}
|
|
319
|
-
}),
|
|
320
|
-
const a =
|
|
319
|
+
}), ct = (u, n) => {
|
|
320
|
+
const a = u.__vccOpts || u;
|
|
321
321
|
for (const [t, l] of n)
|
|
322
322
|
a[t] = l;
|
|
323
323
|
return a;
|
|
324
|
-
},
|
|
325
|
-
container:
|
|
324
|
+
}, U = /* @__PURE__ */ ct(ut, [["__scopeId", "data-v-f04c8857"]]), pt = "_container_2joy4_1", dt = "_container__text_2joy4_187", ft = "_container__default_2joy4_191", mt = "_container__warning_2joy4_199", bt = "_container__alert_2joy4_207", vt = "_container__success_2joy4_215", se = {
|
|
325
|
+
container: pt,
|
|
326
326
|
container__text: dt,
|
|
327
|
-
container__default:
|
|
328
|
-
container__warning:
|
|
329
|
-
container__alert:
|
|
327
|
+
container__default: ft,
|
|
328
|
+
container__warning: mt,
|
|
329
|
+
container__alert: bt,
|
|
330
330
|
container__success: vt
|
|
331
|
-
},
|
|
331
|
+
}, fo = /* @__PURE__ */ M({
|
|
332
332
|
__name: "OnPageMessage",
|
|
333
333
|
props: {
|
|
334
334
|
variant: { default: "default" },
|
|
335
335
|
text: {}
|
|
336
336
|
},
|
|
337
|
-
setup(
|
|
338
|
-
const n =
|
|
337
|
+
setup(u) {
|
|
338
|
+
const n = u, a = C(() => {
|
|
339
339
|
switch (n.variant) {
|
|
340
340
|
case "alert":
|
|
341
341
|
return "filled-error-box";
|
|
@@ -347,13 +347,13 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
347
347
|
return "filled-info-circle";
|
|
348
348
|
}
|
|
349
349
|
});
|
|
350
|
-
return (t, l) => (
|
|
350
|
+
return (t, l) => (c(), d("div", {
|
|
351
351
|
class: s([
|
|
352
352
|
o(se).container,
|
|
353
353
|
o(se)[`container__${t.variant}`]
|
|
354
354
|
])
|
|
355
355
|
}, [
|
|
356
|
-
we(
|
|
356
|
+
we(U, {
|
|
357
357
|
name: a.value,
|
|
358
358
|
size: 24
|
|
359
359
|
}, null, 8, ["name"]),
|
|
@@ -362,7 +362,7 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
362
362
|
}, S(t.text), 3)
|
|
363
363
|
], 2));
|
|
364
364
|
}
|
|
365
|
-
}), gt = "_button__size_default_4wo1i_1", wt = "_button__size_small_4wo1i_8", ht = "_button_4wo1i_1", yt = "_button__label_4wo1i_191", zt = "_button__solid_4wo1i_330", $t = "_segmentGroup_4wo1i_337",
|
|
365
|
+
}), gt = "_button__size_default_4wo1i_1", wt = "_button__size_small_4wo1i_8", ht = "_button_4wo1i_1", yt = "_button__label_4wo1i_191", zt = "_button__solid_4wo1i_330", $t = "_segmentGroup_4wo1i_337", kt = "_fill_4wo1i_359", V = {
|
|
366
366
|
button__size_default: gt,
|
|
367
367
|
button__size_small: wt,
|
|
368
368
|
button: ht,
|
|
@@ -377,8 +377,8 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
377
377
|
segmentGroup: $t,
|
|
378
378
|
"segmentGroup--vertical": "_segmentGroup--vertical_4wo1i_340",
|
|
379
379
|
"segmentGroup--horizontal": "_segmentGroup--horizontal_4wo1i_349",
|
|
380
|
-
fill:
|
|
381
|
-
},
|
|
380
|
+
fill: kt
|
|
381
|
+
}, xt = ["disabled", "onClick"], mo = /* @__PURE__ */ M({
|
|
382
382
|
__name: "SegmentButton",
|
|
383
383
|
props: {
|
|
384
384
|
color: {},
|
|
@@ -390,8 +390,8 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
390
390
|
modelValue: {}
|
|
391
391
|
},
|
|
392
392
|
emits: ["update:modelValue", "click"],
|
|
393
|
-
setup(
|
|
394
|
-
const a =
|
|
393
|
+
setup(u, { emit: n }) {
|
|
394
|
+
const a = u, t = n, l = v(a.modelValue || ""), p = (e) => {
|
|
395
395
|
a.disabled || e.disabled || (l.value = e.value, t("update:modelValue", e.value), t("click", e.value));
|
|
396
396
|
};
|
|
397
397
|
_e(() => a.modelValue, (e) => {
|
|
@@ -400,39 +400,39 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
400
400
|
const r = v([...a.segments]);
|
|
401
401
|
return _e(() => a.segments, (e) => {
|
|
402
402
|
r.value = [...e], e.some((_) => _.value === l.value) || (l.value = "", t("update:modelValue", ""));
|
|
403
|
-
}, { deep: !0 }), (e, _) => (
|
|
403
|
+
}, { deep: !0 }), (e, _) => (c(), d("div", {
|
|
404
404
|
class: s([
|
|
405
405
|
o(V).segmentGroup,
|
|
406
406
|
o(V)[`segmentGroup--${e.align}`],
|
|
407
407
|
{ [o(V).fill]: e.fill }
|
|
408
408
|
])
|
|
409
409
|
}, [
|
|
410
|
-
(
|
|
411
|
-
key: `${
|
|
410
|
+
(c(!0), d(ie, null, ge(r.value, (f, m) => (c(), d("button", {
|
|
411
|
+
key: `${f.value}-${m}`,
|
|
412
412
|
class: s([
|
|
413
413
|
o(V).button,
|
|
414
414
|
o(V)[`button--${e.color}`],
|
|
415
415
|
o(V)[`button__size_${e.size}`],
|
|
416
416
|
o(V).fill,
|
|
417
417
|
{
|
|
418
|
-
[o(V)["button--selected"]]:
|
|
418
|
+
[o(V)["button--selected"]]: f.value === l.value
|
|
419
419
|
}
|
|
420
420
|
]),
|
|
421
|
-
disabled:
|
|
422
|
-
onClick: (B) =>
|
|
421
|
+
disabled: f.disabled || a.disabled,
|
|
422
|
+
onClick: (B) => p(f)
|
|
423
423
|
}, [
|
|
424
|
-
|
|
424
|
+
f.icon ? (c(), F(o(U), {
|
|
425
425
|
key: 0,
|
|
426
|
-
name:
|
|
426
|
+
name: f.icon
|
|
427
427
|
}, null, 8, ["name"])) : w("", !0),
|
|
428
|
-
|
|
428
|
+
f.label ? (c(), d("span", {
|
|
429
429
|
key: 1,
|
|
430
430
|
class: s(o(V).button__label)
|
|
431
|
-
}, S(
|
|
432
|
-
], 10,
|
|
431
|
+
}, S(f.label), 3)) : w("", !0)
|
|
432
|
+
], 10, xt))), 128))
|
|
433
433
|
], 2));
|
|
434
434
|
}
|
|
435
|
-
}), Ct = "_wrapper__field_1ujuh_1", St = "_wrapper__label_1ujuh_1", It = "_wrapper__errorMessage_1ujuh_1", Bt = "_wrapper__counter_1ujuh_1", Pt = "_wrapper_1ujuh_1", Mt = "_wrapper__bottom_1ujuh_220",
|
|
435
|
+
}), Ct = "_wrapper__field_1ujuh_1", St = "_wrapper__label_1ujuh_1", It = "_wrapper__errorMessage_1ujuh_1", Bt = "_wrapper__counter_1ujuh_1", Pt = "_wrapper_1ujuh_1", Mt = "_wrapper__bottom_1ujuh_220", L = {
|
|
436
436
|
wrapper__field: Ct,
|
|
437
437
|
wrapper__label: St,
|
|
438
438
|
wrapper__errorMessage: It,
|
|
@@ -440,7 +440,7 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
440
440
|
wrapper: Pt,
|
|
441
441
|
wrapper__bottom: Mt,
|
|
442
442
|
"wrapper--error": "_wrapper--error_1ujuh_233"
|
|
443
|
-
}, Tt = ["for"], Ht = ["id", "maxlength", "name", "placeholder", "value"], Vt = ["id", "maxlength", "name", "placeholder", "value"],
|
|
443
|
+
}, Tt = ["for"], Ht = ["id", "maxlength", "name", "placeholder", "value"], Vt = ["id", "maxlength", "name", "placeholder", "value"], bo = /* @__PURE__ */ M({
|
|
444
444
|
__name: "TextInput",
|
|
445
445
|
props: {
|
|
446
446
|
id: {},
|
|
@@ -456,8 +456,8 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
456
456
|
counter: { type: Boolean }
|
|
457
457
|
},
|
|
458
458
|
emits: ["update:modelValue", "input", "change", "paste", "focus", "blur"],
|
|
459
|
-
setup(
|
|
460
|
-
const a =
|
|
459
|
+
setup(u, { emit: n }) {
|
|
460
|
+
const a = u, t = n, l = v(null), p = () => {
|
|
461
461
|
if (a.autoGrow && l.value) {
|
|
462
462
|
l.value.style.height = "";
|
|
463
463
|
const e = Math.min(l.value.scrollHeight, a.maxHeight || l.value.scrollHeight);
|
|
@@ -465,87 +465,87 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
465
465
|
}
|
|
466
466
|
}, r = (e) => {
|
|
467
467
|
const _ = e.target;
|
|
468
|
-
t("input", e), t("update:modelValue", _.value),
|
|
468
|
+
t("input", e), t("update:modelValue", _.value), p();
|
|
469
469
|
};
|
|
470
470
|
return ue(() => {
|
|
471
|
-
|
|
471
|
+
p();
|
|
472
472
|
}), (e, _) => {
|
|
473
|
-
var
|
|
474
|
-
return
|
|
475
|
-
class: s(o(
|
|
473
|
+
var f;
|
|
474
|
+
return c(), d("div", {
|
|
475
|
+
class: s(o(L).wrapper)
|
|
476
476
|
}, [
|
|
477
|
-
e.label ? (
|
|
477
|
+
e.label ? (c(), d("label", {
|
|
478
478
|
key: 0,
|
|
479
|
-
class: s(o(
|
|
479
|
+
class: s(o(L).wrapper__label),
|
|
480
480
|
for: e.id
|
|
481
481
|
}, S(e.label), 11, Tt)) : w("", !0),
|
|
482
|
-
e.multiline ? (
|
|
482
|
+
e.multiline ? (c(), d("textarea", {
|
|
483
483
|
key: 1,
|
|
484
484
|
id: e.id,
|
|
485
485
|
ref_key: "textareaRef",
|
|
486
486
|
ref: l,
|
|
487
487
|
class: s([
|
|
488
|
-
o(
|
|
488
|
+
o(L).wrapper__field,
|
|
489
489
|
{
|
|
490
|
-
[o(
|
|
490
|
+
[o(L)["wrapper--error"]]: e.error
|
|
491
491
|
}
|
|
492
492
|
]),
|
|
493
493
|
maxlength: e.maxLength,
|
|
494
494
|
name: e.name,
|
|
495
495
|
placeholder: e.placeholder,
|
|
496
|
-
style:
|
|
496
|
+
style: X(e.maxHeight ? { maxHeight: `${e.maxHeight}px` } : void 0),
|
|
497
497
|
value: e.modelValue,
|
|
498
|
-
onBlur: _[0] || (_[0] = (
|
|
499
|
-
onChange: _[1] || (_[1] = (
|
|
500
|
-
onFocus: _[2] || (_[2] = (
|
|
498
|
+
onBlur: _[0] || (_[0] = (m) => t("blur", m)),
|
|
499
|
+
onChange: _[1] || (_[1] = (m) => e.$emit("change", m)),
|
|
500
|
+
onFocus: _[2] || (_[2] = (m) => t("focus", m)),
|
|
501
501
|
onInput: r,
|
|
502
|
-
onPaste: _[3] || (_[3] = (
|
|
503
|
-
}, null, 46, Ht)) : (
|
|
502
|
+
onPaste: _[3] || (_[3] = (m) => t("paste", m))
|
|
503
|
+
}, null, 46, Ht)) : (c(), d("input", {
|
|
504
504
|
key: 2,
|
|
505
505
|
id: e.id,
|
|
506
506
|
type: "text",
|
|
507
507
|
class: s([
|
|
508
|
-
o(
|
|
508
|
+
o(L).wrapper__field,
|
|
509
509
|
{
|
|
510
|
-
[o(
|
|
510
|
+
[o(L)["wrapper--error"]]: e.error
|
|
511
511
|
}
|
|
512
512
|
]),
|
|
513
513
|
maxlength: e.maxLength,
|
|
514
514
|
name: e.name,
|
|
515
515
|
placeholder: e.placeholder,
|
|
516
516
|
value: e.modelValue,
|
|
517
|
-
onBlur: _[4] || (_[4] = (
|
|
518
|
-
onChange: _[5] || (_[5] = (
|
|
519
|
-
onFocus: _[6] || (_[6] = (
|
|
517
|
+
onBlur: _[4] || (_[4] = (m) => t("blur", m)),
|
|
518
|
+
onChange: _[5] || (_[5] = (m) => e.$emit("change", m)),
|
|
519
|
+
onFocus: _[6] || (_[6] = (m) => t("focus", m)),
|
|
520
520
|
onInput: r,
|
|
521
|
-
onPaste: _[7] || (_[7] = (
|
|
521
|
+
onPaste: _[7] || (_[7] = (m) => t("paste", m))
|
|
522
522
|
}, null, 42, Vt)),
|
|
523
523
|
y("div", {
|
|
524
|
-
class: s(o(
|
|
524
|
+
class: s(o(L).wrapper__bottom)
|
|
525
525
|
}, [
|
|
526
|
-
e.error ? (
|
|
526
|
+
e.error ? (c(), d("div", {
|
|
527
527
|
key: 0,
|
|
528
|
-
class: s(o(
|
|
528
|
+
class: s(o(L).wrapper__errorMessage)
|
|
529
529
|
}, S(e.error), 3)) : w("", !0),
|
|
530
|
-
e.counter ? (
|
|
530
|
+
e.counter ? (c(), d("div", {
|
|
531
531
|
key: 1,
|
|
532
|
-
class: s(o(
|
|
533
|
-
}, S(((
|
|
532
|
+
class: s(o(L).wrapper__counter)
|
|
533
|
+
}, S(((f = e.modelValue) == null ? void 0 : f.toString().length) || 0), 3)) : w("", !0)
|
|
534
534
|
], 2)
|
|
535
535
|
], 2);
|
|
536
536
|
};
|
|
537
537
|
}
|
|
538
|
-
}),
|
|
539
|
-
wrapper__label:
|
|
540
|
-
wrapper__errorMessage:
|
|
538
|
+
}), Lt = "_wrapper__label_3sncs_1", Nt = "_wrapper__errorMessage_3sncs_1", Ot = "_wrapper__counter_3sncs_1", Et = "_wrapper_3sncs_1", Dt = "_wrapper__field_3sncs_8", Wt = "_wrapper__size_default_3sncs_185", jt = "_wrapper__size_small_3sncs_188", qt = "_wrapper__bottom_3sncs_225", O = {
|
|
539
|
+
wrapper__label: Lt,
|
|
540
|
+
wrapper__errorMessage: Nt,
|
|
541
541
|
wrapper__counter: Ot,
|
|
542
|
-
wrapper:
|
|
543
|
-
wrapper__field:
|
|
544
|
-
wrapper__size_default:
|
|
545
|
-
wrapper__size_small:
|
|
546
|
-
wrapper__bottom:
|
|
542
|
+
wrapper: Et,
|
|
543
|
+
wrapper__field: Dt,
|
|
544
|
+
wrapper__size_default: Wt,
|
|
545
|
+
wrapper__size_small: jt,
|
|
546
|
+
wrapper__bottom: qt,
|
|
547
547
|
"wrapper--error": "_wrapper--error_3sncs_238"
|
|
548
|
-
},
|
|
548
|
+
}, At = ["for"], Rt = ["id", "max", "maxlength", "min", "name", "placeholder", "value"], vo = /* @__PURE__ */ M({
|
|
549
549
|
__name: "NumberInput",
|
|
550
550
|
props: {
|
|
551
551
|
id: {},
|
|
@@ -562,27 +562,27 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
562
562
|
size: { default: "default" }
|
|
563
563
|
},
|
|
564
564
|
emits: ["update:modelValue", "input", "change", "paste", "focus", "blur"],
|
|
565
|
-
setup(
|
|
566
|
-
const a =
|
|
567
|
-
var _,
|
|
565
|
+
setup(u, { emit: n }) {
|
|
566
|
+
const a = u, t = n, l = (r) => {
|
|
567
|
+
var _, f;
|
|
568
568
|
if (r === "")
|
|
569
569
|
return r;
|
|
570
570
|
const e = Number(r);
|
|
571
|
-
return typeof a.min == "number" && e < a.min ? (_ = a.min) == null ? void 0 : _.toString() : typeof a.max == "number" && e > a.max ? (
|
|
572
|
-
},
|
|
571
|
+
return typeof a.min == "number" && e < a.min ? (_ = a.min) == null ? void 0 : _.toString() : typeof a.max == "number" && e > a.max ? (f = a.max) == null ? void 0 : f.toString() : e.toString();
|
|
572
|
+
}, p = (r) => {
|
|
573
573
|
const e = r.target, _ = l(e.value);
|
|
574
574
|
e.value = _, t("input", r), t("update:modelValue", Number(_));
|
|
575
575
|
};
|
|
576
576
|
return (r, e) => {
|
|
577
577
|
var _;
|
|
578
|
-
return
|
|
578
|
+
return c(), d("div", {
|
|
579
579
|
class: s([o(O).wrapper, o(O)[`wrapper__size_${r.size}`]])
|
|
580
580
|
}, [
|
|
581
|
-
r.label ? (
|
|
581
|
+
r.label ? (c(), d("label", {
|
|
582
582
|
key: 0,
|
|
583
583
|
class: s(o(O).wrapper__label),
|
|
584
584
|
for: r.id
|
|
585
|
-
}, S(r.label), 11,
|
|
585
|
+
}, S(r.label), 11, At)) : w("", !0),
|
|
586
586
|
y("input", {
|
|
587
587
|
id: r.id,
|
|
588
588
|
type: "number",
|
|
@@ -598,21 +598,21 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
598
598
|
name: r.name,
|
|
599
599
|
placeholder: r.placeholder,
|
|
600
600
|
value: r.modelValue,
|
|
601
|
-
onBlur: e[0] || (e[0] = (
|
|
602
|
-
onChange: e[1] || (e[1] = (
|
|
603
|
-
onFocus: e[2] || (e[2] = (
|
|
604
|
-
onInput:
|
|
605
|
-
onPaste: e[3] || (e[3] = (
|
|
606
|
-
}, null, 42,
|
|
607
|
-
r.counter || r.error ? (
|
|
601
|
+
onBlur: e[0] || (e[0] = (f) => t("blur", f)),
|
|
602
|
+
onChange: e[1] || (e[1] = (f) => r.$emit("change", f)),
|
|
603
|
+
onFocus: e[2] || (e[2] = (f) => t("focus", f)),
|
|
604
|
+
onInput: p,
|
|
605
|
+
onPaste: e[3] || (e[3] = (f) => t("paste", f))
|
|
606
|
+
}, null, 42, Rt),
|
|
607
|
+
r.counter || r.error ? (c(), d("div", {
|
|
608
608
|
key: 1,
|
|
609
609
|
class: s(o(O).wrapper__bottom)
|
|
610
610
|
}, [
|
|
611
|
-
r.error ? (
|
|
611
|
+
r.error ? (c(), d("div", {
|
|
612
612
|
key: 0,
|
|
613
613
|
class: s(o(O).wrapper__errorMessage)
|
|
614
614
|
}, S(r.error), 3)) : w("", !0),
|
|
615
|
-
r.counter ? (
|
|
615
|
+
r.counter ? (c(), d("div", {
|
|
616
616
|
key: 1,
|
|
617
617
|
class: s(o(O).wrapper__counter)
|
|
618
618
|
}, S(((_ = r.modelValue) == null ? void 0 : _.toString().length) || 0), 3)) : w("", !0)
|
|
@@ -620,12 +620,12 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
620
620
|
], 2);
|
|
621
621
|
};
|
|
622
622
|
}
|
|
623
|
-
}),
|
|
624
|
-
wrapper:
|
|
625
|
-
wrapper__label:
|
|
626
|
-
wrapper__input:
|
|
627
|
-
wrapper_checked:
|
|
628
|
-
wrapper_disabled:
|
|
623
|
+
}), Gt = "_wrapper_d1zlt_169", Yt = "_wrapper__label_d1zlt_176", Xt = "_wrapper__input_d1zlt_200", Ft = "_wrapper_checked_d1zlt_210", Ut = "_wrapper_disabled_d1zlt_217", Y = {
|
|
624
|
+
wrapper: Gt,
|
|
625
|
+
wrapper__label: Yt,
|
|
626
|
+
wrapper__input: Xt,
|
|
627
|
+
wrapper_checked: Ft,
|
|
628
|
+
wrapper_disabled: Ut
|
|
629
629
|
}, Qt = ["id", "checked", "disabled", "name"], Zt = ["for"], go = /* @__PURE__ */ M({
|
|
630
630
|
__name: "Toggle",
|
|
631
631
|
props: {
|
|
@@ -635,64 +635,64 @@ const je = "_button__size_default_16zzc_1", Le = "_button__size_small_16zzc_8",
|
|
|
635
635
|
disabled: { type: Boolean, default: !1 }
|
|
636
636
|
},
|
|
637
637
|
emits: ["click"],
|
|
638
|
-
setup(
|
|
639
|
-
const a =
|
|
638
|
+
setup(u, { emit: n }) {
|
|
639
|
+
const a = u, t = n, l = () => {
|
|
640
640
|
t("click", !a.checked);
|
|
641
641
|
};
|
|
642
|
-
return (
|
|
642
|
+
return (p, r) => (c(), d("fieldset", {
|
|
643
643
|
class: s([
|
|
644
|
-
o(
|
|
644
|
+
o(Y).wrapper,
|
|
645
645
|
{
|
|
646
|
-
[o(
|
|
647
|
-
[o(
|
|
646
|
+
[o(Y).wrapper_checked]: p.checked,
|
|
647
|
+
[o(Y).wrapper_disabled]: p.disabled
|
|
648
648
|
}
|
|
649
649
|
])
|
|
650
650
|
}, [
|
|
651
651
|
y("input", {
|
|
652
|
-
id:
|
|
652
|
+
id: p.id,
|
|
653
653
|
type: "checkbox",
|
|
654
|
-
checked:
|
|
655
|
-
class: s(o(
|
|
656
|
-
disabled:
|
|
657
|
-
name:
|
|
654
|
+
checked: p.checked,
|
|
655
|
+
class: s(o(Y).wrapper__input),
|
|
656
|
+
disabled: p.disabled,
|
|
657
|
+
name: p.name,
|
|
658
658
|
onClick: l
|
|
659
659
|
}, null, 10, Qt),
|
|
660
660
|
y("label", {
|
|
661
|
-
class: s(o(
|
|
662
|
-
for:
|
|
661
|
+
class: s(o(Y).wrapper__label),
|
|
662
|
+
for: p.id
|
|
663
663
|
}, null, 10, Zt)
|
|
664
664
|
], 2));
|
|
665
665
|
}
|
|
666
666
|
});
|
|
667
|
-
function Jt(
|
|
668
|
-
return typeof
|
|
667
|
+
function Jt(u = "") {
|
|
668
|
+
return typeof u == "string" ? u.replace(/<\/style>/gi, "").replace(/<(.*?) on(.*?)=['"](.*?)>/gi, "").replace(/(<meta |<style|<\/*script)(.*?)>/gi, "").replace(/(<([^>]+)>)/ig, "").replace(/<(.*?) (href|src)="j(.*)a(.*)v(.*)a(.*)s(.*)c(.*)r(.*)i(.*)p(.*)t(.*):(.*?)>/gi, "") : u;
|
|
669
669
|
}
|
|
670
|
-
const Kt = "
|
|
670
|
+
const Kt = "_wrapper__box_1cst8_1", eo = "_wrapper_1cst8_1", to = "_wrapper__icon_1cst8_184", oo = "_wrapper__text_1cst8_267", E = {
|
|
671
671
|
wrapper__box: Kt,
|
|
672
672
|
wrapper: eo,
|
|
673
673
|
wrapper__icon: to,
|
|
674
|
-
"wrapper__box_bottom-start": "_wrapper__box_bottom-
|
|
675
|
-
"wrapper__box_bottom-center": "_wrapper__box_bottom-
|
|
676
|
-
"wrapper__box_bottom-end": "_wrapper__box_bottom-
|
|
677
|
-
"wrapper__box_top-start": "_wrapper__box_top-
|
|
678
|
-
"wrapper__box_top-center": "_wrapper__box_top-
|
|
679
|
-
"wrapper__box_top-end": "_wrapper__box_top-
|
|
680
|
-
"wrapper__box_right-start": "_wrapper__box_right-
|
|
681
|
-
"wrapper__box_right-center": "_wrapper__box_right-
|
|
682
|
-
"wrapper__box_right-end": "_wrapper__box_right-
|
|
683
|
-
"wrapper__box_left-start": "_wrapper__box_left-
|
|
684
|
-
"wrapper__box_left-center": "_wrapper__box_left-
|
|
685
|
-
"wrapper__box_left-end": "_wrapper__box_left-
|
|
674
|
+
"wrapper__box_bottom-start": "_wrapper__box_bottom-start_1cst8_199",
|
|
675
|
+
"wrapper__box_bottom-center": "_wrapper__box_bottom-center_1cst8_205",
|
|
676
|
+
"wrapper__box_bottom-end": "_wrapper__box_bottom-end_1cst8_211",
|
|
677
|
+
"wrapper__box_top-start": "_wrapper__box_top-start_1cst8_217",
|
|
678
|
+
"wrapper__box_top-center": "_wrapper__box_top-center_1cst8_223",
|
|
679
|
+
"wrapper__box_top-end": "_wrapper__box_top-end_1cst8_229",
|
|
680
|
+
"wrapper__box_right-start": "_wrapper__box_right-start_1cst8_235",
|
|
681
|
+
"wrapper__box_right-center": "_wrapper__box_right-center_1cst8_241",
|
|
682
|
+
"wrapper__box_right-end": "_wrapper__box_right-end_1cst8_247",
|
|
683
|
+
"wrapper__box_left-start": "_wrapper__box_left-start_1cst8_252",
|
|
684
|
+
"wrapper__box_left-center": "_wrapper__box_left-center_1cst8_257",
|
|
685
|
+
"wrapper__box_left-end": "_wrapper__box_left-end_1cst8_262",
|
|
686
686
|
wrapper__text: oo,
|
|
687
|
-
"wrapper__box-content": "_wrapper__box-
|
|
688
|
-
"bottom-entrance": "_bottom-
|
|
689
|
-
"top-entrance": "_top-
|
|
690
|
-
"left-entrance": "_left-
|
|
691
|
-
"right-entrance": "_right-
|
|
692
|
-
"bottom-leave": "_bottom-
|
|
693
|
-
"top-leave": "_top-
|
|
694
|
-
"right-leave": "_right-
|
|
695
|
-
"left-leave": "_left-
|
|
687
|
+
"wrapper__box-content": "_wrapper__box-content_1cst8_296",
|
|
688
|
+
"bottom-entrance": "_bottom-entrance_1cst8_309",
|
|
689
|
+
"top-entrance": "_top-entrance_1cst8_312",
|
|
690
|
+
"left-entrance": "_left-entrance_1cst8_315",
|
|
691
|
+
"right-entrance": "_right-entrance_1cst8_318",
|
|
692
|
+
"bottom-leave": "_bottom-leave_1cst8_321",
|
|
693
|
+
"top-leave": "_top-leave_1cst8_324",
|
|
694
|
+
"right-leave": "_right-leave_1cst8_327",
|
|
695
|
+
"left-leave": "_left-leave_1cst8_330"
|
|
696
696
|
}, no = ["id"], ro = ["innerHTML"], wo = /* @__PURE__ */ M({
|
|
697
697
|
__name: "Tooltip",
|
|
698
698
|
props: {
|
|
@@ -711,40 +711,40 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
711
711
|
absoluteTrianglePosition: { default: "top" },
|
|
712
712
|
absolutePosition: { type: [Boolean, null, String, Object, Array] }
|
|
713
713
|
},
|
|
714
|
-
setup(
|
|
715
|
-
const n =
|
|
714
|
+
setup(u) {
|
|
715
|
+
const n = u, a = v(null), t = v("center"), l = v("bottom"), p = v("center"), r = v(!1), e = v(""), _ = v(!1), f = v(!1), m = v(""), B = v("d-n"), T = v(null), P = v(null), j = v(null), x = C(() => n.staticPosition.split(" ")[0]), N = C(() => n.staticPosition.split(" ")[1]), Q = C(() => n.iconName ? "mt-1" : "mt-0"), oe = C(() => n.preventXss ? Jt(n.text) : n.text), W = C(() => n.absolutePositionStatus ? n.absoluteTrianglePosition : n.dynamicPosition && r.value ? l.value === "bottom" ? "top" : "bottom" : x.value === "top" ? "bottom" : x.value === "bottom" ? "top" : x.value === "left" ? "right" : x.value === "right" ? "left" : "bottom"), ne = C(() => n.absolutePositionStatus ? "" : _.value && f.value || m.value === "icon" && _.value ? "opa-1" : "opa-0"), Z = C(() => n.absolutePositionStatus ? n.absoluteTriangleAlignment : n.dynamicPosition && r.value ? t.value === "center" ? "center" : t.value === "end" ? "end" : t.value === "start" ? "start" : p.value : N.value === "center" ? "center" : N.value === "left" || N.value === "top" ? "start" : N.value === "right" || N.value === "bottom" ? "end" : "center"), re = C(() => n.absolutePositionStatus ? "" : n.dynamicPosition && r.value ? E[`wrapper__box_${l.value}-${t.value}`] : E[`wrapper__box_${x.value}-${Z.value}`]), J = C(() => n.offsetX === 0 && n.offsetY === 0 ? {} : n.dynamicPosition ? {
|
|
716
716
|
[`margin-${l.value === "bottom" ? "top" : "bottom"}`]: `${n.offsetY}px`
|
|
717
|
-
} :
|
|
718
|
-
[`margin-${
|
|
719
|
-
} : { [`margin-${
|
|
720
|
-
if (!
|
|
717
|
+
} : W.value === "top" || W.value === "bottom" ? {
|
|
718
|
+
[`margin-${W.value}`]: `${n.offsetY}px`
|
|
719
|
+
} : { [`margin-${W.value}`]: `${n.offsetX}px` }), b = (i, h, $ = !1) => {
|
|
720
|
+
if (!i || !P.value)
|
|
721
721
|
return { left: !1, right: !1, top: !1, bottom: !1, center: !1 };
|
|
722
|
-
const H = { left: 0, right: 0, top: 0, bottom: 0, width: 0, height: 0 }, le = P.value.clientHeight,
|
|
723
|
-
let
|
|
724
|
-
return n.iconName && (
|
|
722
|
+
const H = { left: 0, right: 0, top: 0, bottom: 0, width: 0, height: 0 }, le = P.value.clientHeight, G = window.innerWidth, Ce = window.innerHeight, ce = i.clientHeight, ee = i.clientWidth || 264, k = (h == null ? void 0 : h.getBoundingClientRect()) || H, pe = $ ? k == null ? void 0 : k.right : k == null ? void 0 : k.left, de = $ ? k == null ? void 0 : k.top : k == null ? void 0 : k.bottom, Se = pe + k.width + ee + n.offsetX < G, Ie = pe + k.width / 2 - (ee + n.offsetX) > 10, Be = de + ce < Ce - n.offsetY, Pe = de - (ce + le + n.offsetY) > 0;
|
|
723
|
+
let fe = !1;
|
|
724
|
+
return n.iconName && (fe = k.right + ee / 2 < G && k.left - (ee + n.offsetX) / 2 >= 10), {
|
|
725
725
|
left: Ie,
|
|
726
726
|
right: Se,
|
|
727
727
|
bottom: Be,
|
|
728
728
|
top: Pe,
|
|
729
|
-
center:
|
|
729
|
+
center: fe
|
|
730
730
|
};
|
|
731
731
|
}, g = () => {
|
|
732
732
|
ve(() => {
|
|
733
|
-
var
|
|
733
|
+
var G;
|
|
734
734
|
r.value = !0;
|
|
735
|
-
const { bottom:
|
|
736
|
-
|
|
737
|
-
(
|
|
735
|
+
const { bottom: i, left: h, right: $, top: H, center: le } = b(
|
|
736
|
+
j.value,
|
|
737
|
+
(G = j.value) == null ? void 0 : G.parentNode
|
|
738
738
|
);
|
|
739
739
|
if (le) {
|
|
740
|
-
t.value = "center", l.value =
|
|
740
|
+
t.value = "center", l.value = i && !H ? "bottom" : "top";
|
|
741
741
|
return;
|
|
742
742
|
}
|
|
743
|
-
if (
|
|
743
|
+
if (i && h && $ && H) {
|
|
744
744
|
t.value = "center", l.value = "top";
|
|
745
745
|
return;
|
|
746
746
|
}
|
|
747
|
-
if (H && !
|
|
747
|
+
if (H && !i) {
|
|
748
748
|
if ($ && h) {
|
|
749
749
|
t.value = "center", l.value = "top";
|
|
750
750
|
return;
|
|
@@ -758,108 +758,110 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
758
758
|
return;
|
|
759
759
|
}
|
|
760
760
|
}
|
|
761
|
-
if (
|
|
761
|
+
if (i && H) {
|
|
762
762
|
if (!$ && h) {
|
|
763
|
-
t.value = "end", l.value = "top",
|
|
763
|
+
t.value = "end", l.value = "top", p.value = "end";
|
|
764
764
|
return;
|
|
765
765
|
}
|
|
766
766
|
if ($ && !h) {
|
|
767
|
-
t.value = "start", l.value = "top",
|
|
767
|
+
t.value = "start", l.value = "top", p.value = "start";
|
|
768
768
|
return;
|
|
769
769
|
}
|
|
770
770
|
}
|
|
771
|
-
if (
|
|
771
|
+
if (i && !H) {
|
|
772
772
|
if ($ && h) {
|
|
773
|
-
t.value = "center", l.value = "bottom",
|
|
773
|
+
t.value = "center", l.value = "bottom", p.value = "top";
|
|
774
774
|
return;
|
|
775
775
|
}
|
|
776
776
|
if (!$ && h) {
|
|
777
|
-
t.value = "end", l.value = "bottom",
|
|
777
|
+
t.value = "end", l.value = "bottom", p.value = "top";
|
|
778
778
|
return;
|
|
779
779
|
}
|
|
780
|
-
$ && !h && (t.value = "start", l.value = "bottom",
|
|
780
|
+
$ && !h && (t.value = "start", l.value = "bottom", p.value = "top");
|
|
781
781
|
}
|
|
782
782
|
});
|
|
783
|
-
}, I = (
|
|
784
|
-
|
|
783
|
+
}, I = (i) => {
|
|
784
|
+
if (!(i instanceof HTMLElement))
|
|
785
|
+
return !1;
|
|
786
|
+
const h = i.scrollHeight > i.clientHeight, $ = window.getComputedStyle(i).overflowY, H = ["auto", "scroll"].includes($);
|
|
785
787
|
return h && H;
|
|
786
|
-
},
|
|
787
|
-
const h = (
|
|
788
|
-
return !
|
|
789
|
-
},
|
|
790
|
-
var
|
|
791
|
-
(
|
|
788
|
+
}, q = (i) => {
|
|
789
|
+
const h = (i == null ? void 0 : i.nodeType) === Node.COMMENT_NODE, $ = (i == null ? void 0 : i.nodeType) === Node.DOCUMENT_NODE;
|
|
790
|
+
return !i || h || $ ? document : I(i) ? i : q(i.parentNode);
|
|
791
|
+
}, R = () => {
|
|
792
|
+
var i;
|
|
793
|
+
(i = T.value) == null || i.removeEventListener("scroll", g), window == null || window.removeEventListener("resize", g);
|
|
792
794
|
}, K = () => {
|
|
793
795
|
ve(() => {
|
|
794
|
-
var
|
|
795
|
-
T.value =
|
|
796
|
+
var i;
|
|
797
|
+
T.value = q(P.value), (i = T.value) == null || i.addEventListener("scroll", g), window == null || window.addEventListener("resize", g);
|
|
796
798
|
});
|
|
797
799
|
}, ye = () => {
|
|
798
|
-
|
|
800
|
+
m.value = "wrapper", B.value = "d-b", _.value = !0;
|
|
799
801
|
}, ae = () => {
|
|
800
|
-
|
|
802
|
+
m.value = "icon", B.value = "d-b", f.value = !0;
|
|
801
803
|
}, ze = () => {
|
|
802
|
-
|
|
804
|
+
f.value = !1;
|
|
803
805
|
}, $e = () => {
|
|
804
|
-
|
|
805
|
-
},
|
|
806
|
-
$e(), n.dynamicPosition ? l.value === "bottom" ? e.value = "bottom-leave" : l.value === "top" && (e.value = "top-leave") :
|
|
806
|
+
m.value = "", _.value = !1, f.value = !1;
|
|
807
|
+
}, ke = () => {
|
|
808
|
+
$e(), n.dynamicPosition ? l.value === "bottom" ? e.value = "bottom-leave" : l.value === "top" && (e.value = "top-leave") : x.value === "top" ? e.value = "top-leave" : x.value === "bottom" ? e.value = "bottom-leave" : x.value === "left" ? e.value = "left-leave" : x.value === "right" && (e.value = "right-leave"), setTimeout(() => {
|
|
807
809
|
e.value = "", B.value = "d-n";
|
|
808
810
|
}, n.absolutePositionStatus ? 0 : 250);
|
|
809
|
-
},
|
|
810
|
-
ye(), g(), n.dynamicPosition ? l.value === "bottom" ? e.value = "top-entrance" : l.value === "top" && (e.value = "bottom-entrance") :
|
|
811
|
+
}, xe = () => {
|
|
812
|
+
ye(), g(), n.dynamicPosition ? l.value === "bottom" ? e.value = "top-entrance" : l.value === "top" && (e.value = "bottom-entrance") : x.value === "top" ? e.value = "bottom-entrance" : x.value === "bottom" ? e.value = "top-entrance" : x.value === "left" ? e.value = "right-entrance" : x.value === "right" && (e.value = "left-entrance"), setTimeout(() => {
|
|
811
813
|
e.value = "";
|
|
812
814
|
}, 250);
|
|
813
815
|
};
|
|
814
816
|
return ue(() => {
|
|
815
817
|
n.dynamicPosition && K();
|
|
816
818
|
}), He(() => {
|
|
817
|
-
|
|
818
|
-
}), (
|
|
819
|
-
id:
|
|
819
|
+
R();
|
|
820
|
+
}), (i, h) => (c(), d("div", {
|
|
821
|
+
id: i.id,
|
|
820
822
|
ref_key: "tooltipRootRef",
|
|
821
823
|
ref: P,
|
|
822
|
-
class: s(o(
|
|
823
|
-
onMouseenter:
|
|
824
|
-
onMouseleave:
|
|
824
|
+
class: s(o(E).wrapper),
|
|
825
|
+
onMouseenter: xe,
|
|
826
|
+
onMouseleave: ke
|
|
825
827
|
}, [
|
|
826
|
-
|
|
828
|
+
i.iconName ? (c(), F(o(U), {
|
|
827
829
|
key: 0,
|
|
828
830
|
ref_key: "tooltipIconRef",
|
|
829
831
|
ref: a,
|
|
830
|
-
class: s(o(
|
|
831
|
-
name:
|
|
832
|
+
class: s(o(E).wrapper__icon),
|
|
833
|
+
name: i.iconName,
|
|
832
834
|
onMouseenter: ae,
|
|
833
835
|
onMouseleave: ze
|
|
834
|
-
}, null, 8, ["class", "name"])) : (
|
|
836
|
+
}, null, 8, ["class", "name"])) : (c(), d("div", {
|
|
835
837
|
key: 1,
|
|
836
|
-
class: s(o(
|
|
838
|
+
class: s(o(E).wrapper__icon),
|
|
837
839
|
onMouseenter: ae,
|
|
838
840
|
onMouseleave: ae
|
|
839
841
|
}, [
|
|
840
|
-
|
|
842
|
+
D(i.$slots, "triggerElement")
|
|
841
843
|
], 34)),
|
|
842
|
-
|
|
844
|
+
i.status ? (c(), d("div", {
|
|
843
845
|
key: 2,
|
|
844
846
|
ref_key: "tooltipPopupRef",
|
|
845
|
-
ref:
|
|
846
|
-
class: s([o(
|
|
847
|
-
style:
|
|
847
|
+
ref: j,
|
|
848
|
+
class: s([o(E).wrapper__box, re.value, ne.value, B.value]),
|
|
849
|
+
style: X(i.absolutePosition)
|
|
848
850
|
}, [
|
|
849
851
|
we(o(io), {
|
|
850
852
|
"border-triangle": "",
|
|
851
853
|
"border-triangle-align": Z.value,
|
|
852
|
-
"border-triangle-position":
|
|
853
|
-
class: s([o(
|
|
854
|
-
style:
|
|
854
|
+
"border-triangle-position": W.value,
|
|
855
|
+
class: s([o(E)["wrapper__box-content"], Q.value, e.value]),
|
|
856
|
+
style: X(J.value)
|
|
855
857
|
}, {
|
|
856
858
|
default: he(() => [
|
|
857
859
|
y("div", {
|
|
858
|
-
class: s(o(
|
|
859
|
-
style:
|
|
860
|
+
class: s(o(E).wrapper__text),
|
|
861
|
+
style: X({ maxHeight: `${i.maxHeight}px`, overflowY: "auto" })
|
|
860
862
|
}, [
|
|
861
863
|
y("div", { innerHTML: oe.value }, null, 8, ro),
|
|
862
|
-
|
|
864
|
+
D(i.$slots, "contentSlot")
|
|
863
865
|
], 6)
|
|
864
866
|
]),
|
|
865
867
|
_: 3
|
|
@@ -867,20 +869,20 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
867
869
|
], 6)) : w("", !0)
|
|
868
870
|
], 42, no));
|
|
869
871
|
}
|
|
870
|
-
}), ao = "
|
|
872
|
+
}), ao = "_box_14qkh_169", lo = "_flipBox_14qkh_257", te = {
|
|
871
873
|
box: ao,
|
|
872
|
-
"box_top-start": "_box_top-
|
|
873
|
-
"box_top-center": "_box_top-
|
|
874
|
-
"box_top-end": "_box_top-
|
|
875
|
-
"box_right-start": "_box_right-
|
|
876
|
-
"box_right-center": "_box_right-
|
|
877
|
-
"box_right-end": "_box_right-
|
|
878
|
-
"box_bottom-start": "_box_bottom-
|
|
879
|
-
"box_bottom-center": "_box_bottom-
|
|
880
|
-
"box_bottom-end": "_box_bottom-
|
|
881
|
-
"box_left-start": "_box_left-
|
|
882
|
-
"box_left-center": "_box_left-
|
|
883
|
-
"box_left-end": "_box_left-
|
|
874
|
+
"box_top-start": "_box_top-start_14qkh_173",
|
|
875
|
+
"box_top-center": "_box_top-center_14qkh_173",
|
|
876
|
+
"box_top-end": "_box_top-end_14qkh_173",
|
|
877
|
+
"box_right-start": "_box_right-start_14qkh_173",
|
|
878
|
+
"box_right-center": "_box_right-center_14qkh_173",
|
|
879
|
+
"box_right-end": "_box_right-end_14qkh_173",
|
|
880
|
+
"box_bottom-start": "_box_bottom-start_14qkh_173",
|
|
881
|
+
"box_bottom-center": "_box_bottom-center_14qkh_173",
|
|
882
|
+
"box_bottom-end": "_box_bottom-end_14qkh_173",
|
|
883
|
+
"box_left-start": "_box_left-start_14qkh_173",
|
|
884
|
+
"box_left-center": "_box_left-center_14qkh_173",
|
|
885
|
+
"box_left-end": "_box_left-end_14qkh_173",
|
|
884
886
|
flipBox: lo
|
|
885
887
|
}, so = /* @__PURE__ */ M({
|
|
886
888
|
__name: "DefaultBox",
|
|
@@ -892,18 +894,18 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
892
894
|
borderTrianglePosition: { default: "top" }
|
|
893
895
|
},
|
|
894
896
|
emits: ["click"],
|
|
895
|
-
setup(
|
|
896
|
-
const a =
|
|
897
|
+
setup(u, { emit: n }) {
|
|
898
|
+
const a = u, t = n, l = C(
|
|
897
899
|
() => a.borderTriangle ? te[`box_${a.borderTrianglePosition}-${a.borderTriangleAlign}`] : ""
|
|
898
900
|
);
|
|
899
|
-
function
|
|
901
|
+
function p() {
|
|
900
902
|
t("click");
|
|
901
903
|
}
|
|
902
|
-
return (r, e) => (
|
|
904
|
+
return (r, e) => (c(), d("div", {
|
|
903
905
|
class: s([o(te).box, l.value, r.border, r.borderRadius]),
|
|
904
|
-
onClick:
|
|
906
|
+
onClick: p
|
|
905
907
|
}, [
|
|
906
|
-
|
|
908
|
+
D(r.$slots, "default")
|
|
907
909
|
], 2));
|
|
908
910
|
}
|
|
909
911
|
}), _o = /* @__PURE__ */ M({
|
|
@@ -911,20 +913,20 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
911
913
|
props: {
|
|
912
914
|
boxSpacing: { default: "" }
|
|
913
915
|
},
|
|
914
|
-
setup(
|
|
915
|
-
return (n, a) => (
|
|
916
|
+
setup(u) {
|
|
917
|
+
return (n, a) => (c(), d("div", {
|
|
916
918
|
class: s([o(te).flipBox, n.boxSpacing])
|
|
917
919
|
}, [
|
|
918
920
|
y("div", null, [
|
|
919
921
|
y("div", {
|
|
920
922
|
class: s([o(te).box, n.boxSpacing])
|
|
921
923
|
}, [
|
|
922
|
-
|
|
924
|
+
D(n.$slots, "front")
|
|
923
925
|
], 2),
|
|
924
926
|
y("div", {
|
|
925
927
|
class: s([n.boxSpacing])
|
|
926
928
|
}, [
|
|
927
|
-
|
|
929
|
+
D(n.$slots, "reverse")
|
|
928
930
|
], 2)
|
|
929
931
|
])
|
|
930
932
|
], 2));
|
|
@@ -938,21 +940,21 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
938
940
|
borderTrianglePosition: {},
|
|
939
941
|
boxSpacing: { default: "" }
|
|
940
942
|
},
|
|
941
|
-
setup(
|
|
943
|
+
setup(u) {
|
|
942
944
|
const n = {
|
|
943
945
|
default: so,
|
|
944
946
|
flip: _o
|
|
945
947
|
};
|
|
946
|
-
return (a, t) => (
|
|
948
|
+
return (a, t) => (c(), F(Ve(n[a.type]), {
|
|
947
949
|
"border-triangle": a.borderTriangle,
|
|
948
950
|
"border-triangle-align": a.borderTriangleAlign,
|
|
949
951
|
"border-triangle-position": a.borderTrianglePosition,
|
|
950
952
|
"box-spacing": a.boxSpacing
|
|
951
953
|
}, {
|
|
952
954
|
default: he(() => [
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
955
|
+
D(a.$slots, "default"),
|
|
956
|
+
D(a.$slots, "front"),
|
|
957
|
+
D(a.$slots, "reverse")
|
|
956
958
|
]),
|
|
957
959
|
_: 3
|
|
958
960
|
}, 8, ["border-triangle", "border-triangle-align", "border-triangle-position", "box-spacing"]));
|
|
@@ -960,13 +962,13 @@ const Kt = "_wrapper__box_ybeb8_1", eo = "_wrapper_ybeb8_1", to = "_wrapper__ico
|
|
|
960
962
|
});
|
|
961
963
|
export {
|
|
962
964
|
io as Box,
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
965
|
+
co as Button,
|
|
966
|
+
po as DropdownMenu,
|
|
967
|
+
U as Icon,
|
|
966
968
|
vo as NumberInput,
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
969
|
+
fo as OnPageMessage,
|
|
970
|
+
mo as SegmentButton,
|
|
971
|
+
bo as TextInput,
|
|
970
972
|
go as Toggle,
|
|
971
973
|
wo as Tooltip
|
|
972
974
|
};
|