@dcodegroup-au/dsg-vue 0.0.14 → 0.0.16
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/{DsgDatepicker.vue_vue_type_style_index_0_lang-DQyls2gz.cjs → DsgDatepicker.vue_vue_type_style_index_0_lang-DEpSH9kZ.cjs} +2 -2
- package/dist/{DsgDatepicker.vue_vue_type_style_index_0_lang-CFpk3hbH.js → DsgDatepicker.vue_vue_type_style_index_0_lang-DzdjHcT0.js} +6152 -6144
- package/dist/components/Elements/DsgCheckboxGroup.vue.d.ts +52 -0
- package/dist/components/Elements/DsgInput.vue.d.ts +1 -0
- package/dist/components/Elements/ElementComponents.d.ts +2 -1
- package/dist/components/Navigation/DsgTab.vue.d.ts +2 -0
- package/dist/components/Table/DsgTable.vue.d.ts +16 -2
- package/dist/components/Table/DsgTableComponent.vue.d.ts +4 -0
- package/dist/components/Table/DsgTableFilter.vue.d.ts +2 -0
- package/dist/components/Table/DsgTableRowHeader.vue.d.ts +7 -3
- package/dist/dsg-vue.cjs +2 -2
- package/dist/dsg-vue.css +1 -1
- package/dist/dsg-vue.esm.js +1322 -1203
- package/dist/dsg-vue.table.cjs +7 -7
- package/dist/dsg-vue.table.esm.js +1682 -1601
- package/dist/helpers.d.ts +2 -0
- package/dist/main.d.ts +71 -0
- package/dist/table.d.ts +22 -2
- package/dist/utilities/URL.d.ts +18 -0
- package/package.json +3 -3
package/dist/dsg-vue.esm.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { _ as
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { C as
|
|
4
|
-
const
|
|
1
|
+
import { _ as G, D as ne, a as ts, b as $o, c as yt, k as os, d as _e, e as ss, f as is, g as ns, h as as } from "./DsgDatepicker.vue_vue_type_style_index_0_lang-DzdjHcT0.js";
|
|
2
|
+
import { defineComponent as H, createElementBlock as v, openBlock as h, normalizeClass as D, unref as ge, createVNode as I, normalizeProps as Lo, guardReactiveProps as ls, ref as Y, useTemplateRef as we, createElementVNode as T, createCommentVNode as w, renderSlot as M, createBlock as $, toDisplayString as P, reactive as Se, mergeProps as J, toRaw as ee, createApp as rs, nextTick as eo, computed as q, onMounted as to, onUnmounted as Io, Fragment as Z, h as ut, isVNode as _o, cloneVNode as ds, watchEffect as ht, useAttrs as us, mergeModels as Bo, useModel as Do, resolveDirective as cs, renderList as ke, withDirectives as Po, onBeforeUnmount as fs, withCtx as Vt, vModelSelect as gs, normalizeStyle as No, resolveDynamicComponent as ps, withModifiers as hs } from "vue";
|
|
3
|
+
import { C as ms } from "./_commonjsHelpers-CgdWM-5-.js";
|
|
4
|
+
const bs = /* @__PURE__ */ H({
|
|
5
5
|
__name: "DsgMiscIcon",
|
|
6
6
|
props: {
|
|
7
7
|
theme: { default: "brand" },
|
|
@@ -12,18 +12,18 @@ const ms = /* @__PURE__ */ q({
|
|
|
12
12
|
},
|
|
13
13
|
setup(e) {
|
|
14
14
|
const t = ["dsg-misc-icon", `dsg-misc-icon--${e.theme}`, `dsg-misc-icon--${e.type}`, `dsg-misc-icon--${e.size}`, e.classes].join(" ").replace(/\s+/g, " ").trim();
|
|
15
|
-
return (o,
|
|
16
|
-
class:
|
|
15
|
+
return (o, i) => (h(), v("div", {
|
|
16
|
+
class: D(ge(t))
|
|
17
17
|
}, [
|
|
18
|
-
|
|
18
|
+
I(G, Lo(ls(o.icon)), null, 16)
|
|
19
19
|
], 2));
|
|
20
20
|
}
|
|
21
|
-
}),
|
|
21
|
+
}), Mo = (e, t) => {
|
|
22
22
|
const o = e.__vccOpts || e;
|
|
23
|
-
for (const [
|
|
24
|
-
o[
|
|
23
|
+
for (const [i, s] of t)
|
|
24
|
+
o[i] = s;
|
|
25
25
|
return o;
|
|
26
|
-
},
|
|
26
|
+
}, Ie = /* @__PURE__ */ Mo(bs, [["__scopeId", "data-v-6f50208c"]]), vs = `<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
27
27
|
<g id="Size=4xl" clip-path="url(#clip0_3302_422487)">
|
|
28
28
|
<path id="Vector" d="M24.711 5.66721C25.0149 6.40224 25.5983 6.98649 26.3328 7.29151L28.9086 8.35843C29.6437 8.66292 30.2277 9.24694 30.5322 9.98202C30.8367 10.7171 30.8367 11.543 30.5322 12.2781L29.466 14.8521C29.1614 15.5875 29.161 16.4142 29.467 17.1493L30.5313 19.7224C30.6822 20.0865 30.76 20.4768 30.76 20.8709C30.7601 21.265 30.6825 21.6553 30.5317 22.0194C30.3808 22.3836 30.1597 22.7144 29.881 22.993C29.6023 23.2717 29.2714 23.4927 28.9072 23.6434L26.3333 24.7096C25.5982 25.0135 25.014 25.5968 24.709 26.3314L23.642 28.9072C23.3376 29.6423 22.7535 30.2263 22.0185 30.5308C21.2834 30.8353 20.4574 30.8353 19.7224 30.5308L17.1484 29.4646C16.4133 29.1609 15.5877 29.1615 14.853 29.4663L12.2773 30.5317C11.5426 30.8355 10.7174 30.8353 9.98289 30.531C9.2484 30.2268 8.6647 29.6435 8.36001 28.9092L7.29277 26.3326C6.98885 25.5976 6.40548 25.0133 5.67091 24.7083L3.09514 23.6414C2.36037 23.337 1.77652 22.7534 1.47193 22.0187C1.16734 21.2841 1.16692 20.4585 1.47078 19.7236L2.53694 17.1496C2.84067 16.4145 2.84005 15.5889 2.53521 14.8542L1.47059 12.2766C1.31964 11.9125 1.24192 11.5223 1.24186 11.1282C1.24179 10.734 1.31939 10.3438 1.47022 9.97962C1.62104 9.6155 1.84214 9.28466 2.12088 9.00601C2.39961 8.72737 2.73052 8.50638 3.09469 8.35567L5.66862 7.28951C6.40301 6.98586 6.98691 6.40322 7.29216 5.6695L8.35908 3.09372C8.66357 2.35864 9.24759 1.77461 9.98267 1.47013C10.7178 1.16565 11.5437 1.16565 12.2788 1.47013L14.8527 2.53629C15.5878 2.84002 16.4134 2.8394 17.1481 2.53456L19.7249 1.47178C20.4599 1.16747 21.2857 1.16754 22.0206 1.47196C22.7556 1.77638 23.3395 2.36023 23.644 3.09513L24.7113 5.67167L24.711 5.66721Z" fill="#0788F5"/>
|
|
29
29
|
<path id="Vector_2" fill-rule="evenodd" clip-rule="evenodd" d="M22.2665 11.8058C22.4803 11.4701 22.5519 11.0631 22.4656 10.6746C22.3794 10.286 22.1423 9.94759 21.8065 9.73383C21.4708 9.52006 21.0638 9.44843 20.6753 9.5347C20.2867 9.62097 19.9483 9.85806 19.7345 10.1938L13.8605 19.4238L11.1725 16.0638C10.924 15.753 10.5622 15.5536 10.1667 15.5095C9.77118 15.4655 9.37436 15.5803 9.06352 15.8288C8.75269 16.0773 8.55331 16.4391 8.50923 16.8347C8.46516 17.2302 8.58001 17.627 8.82852 17.9378L12.8285 22.9378C12.9776 23.1244 13.1691 23.2727 13.387 23.3703C13.6049 23.468 13.843 23.5122 14.0815 23.4993C14.32 23.4864 14.5519 23.4167 14.758 23.2961C14.9641 23.1755 15.1385 23.0074 15.2665 22.8058L22.2665 11.8058Z" fill="white"/>
|
|
@@ -34,23 +34,23 @@ const ms = /* @__PURE__ */ q({
|
|
|
34
34
|
</clipPath>
|
|
35
35
|
</defs>
|
|
36
36
|
</svg>
|
|
37
|
-
`,
|
|
37
|
+
`, ws = ["href", "title"], ys = {
|
|
38
38
|
class: "dsg-avatar--image-wrapper",
|
|
39
39
|
tabindex: "0",
|
|
40
40
|
ref: "avatarImageWrapperEl"
|
|
41
|
-
},
|
|
41
|
+
}, ks = ["src", "alt"], Cs = {
|
|
42
42
|
key: 1,
|
|
43
43
|
class: "dsg-avatar--initials"
|
|
44
|
-
},
|
|
44
|
+
}, Es = { class: "dsg-avatar--status" }, Ts = {
|
|
45
45
|
key: 0,
|
|
46
46
|
class: "dsg-avatar--activity"
|
|
47
|
-
},
|
|
47
|
+
}, As = ["innerHTML"], Ss = {
|
|
48
48
|
key: 2,
|
|
49
49
|
class: "dsg-avatar--logo"
|
|
50
|
-
},
|
|
50
|
+
}, Os = ["src", "alt"], $s = {
|
|
51
51
|
key: 0,
|
|
52
52
|
class: "dsg-avatar--info"
|
|
53
|
-
},
|
|
53
|
+
}, Ls = { class: "dsg-avatar--title" }, Is = { class: "dsg-avatar--subtext" }, ot = /* @__PURE__ */ H({
|
|
54
54
|
__name: "DsgAvatar",
|
|
55
55
|
props: {
|
|
56
56
|
profileUri: { default: "" },
|
|
@@ -70,7 +70,7 @@ const ms = /* @__PURE__ */ q({
|
|
|
70
70
|
},
|
|
71
71
|
emits: ["avatar-clicked", "before-change-status", "after-change-status"],
|
|
72
72
|
setup(e, { expose: t, emit: o }) {
|
|
73
|
-
const
|
|
73
|
+
const i = [
|
|
74
74
|
"dsg-avatar",
|
|
75
75
|
`dsg-avatar--${e.size}`,
|
|
76
76
|
`dsg-avatar--${e.theme}`,
|
|
@@ -81,77 +81,77 @@ const ms = /* @__PURE__ */ q({
|
|
|
81
81
|
`dsg-avatar--${["profile-photo", "profile-photo-verified"].indexOf(e.theme) !== -1 ? "profile-photo" : "non-profile-photo"}`,
|
|
82
82
|
e.classes
|
|
83
83
|
].join(" ");
|
|
84
|
-
["profile-photo", "profile-photo-verified"].indexOf(e.theme) !== -1 && (["sm", "md", "lg"].indexOf(e.size) === -1 && new ne("DsgAvatar: The 'profile-photo' theme only supports the 'sm', 'md', and 'lg' sizes."), (e.fullName || e.title || e.subText) && new
|
|
84
|
+
["profile-photo", "profile-photo-verified"].indexOf(e.theme) !== -1 && (["sm", "md", "lg"].indexOf(e.size) === -1 && new ne("DsgAvatar: The 'profile-photo' theme only supports the 'sm', 'md', and 'lg' sizes."), (e.fullName || e.title || e.subText) && new ts("DsgAvatar: The 'profile-photo' theme will not display the 'title' or 'subText' props.")), e.theme === "logo" && !e.companyLogoUri && new ne("DsgAvatar: The 'logo' theme requires a 'companyLogoUri' prop."), ["activity", "verified", "logo"].indexOf(e.theme) !== -1 && e.title?.length && e.subText?.length && ["xs", "sm", "md", "lg", "xl", "2xl"].indexOf(e.size) === -1 && new ne(
|
|
85
85
|
"DsgAvatar: The 'activity', 'verified', and 'logo' themes only support the 'xs', 'sm', 'md', 'lg', and 'xl' sizes when 'title' and 'subText' are provided."
|
|
86
86
|
), e.theme === "tile" && !e.title?.length && !e.fullName && new ne("DsgAvatar: The 'tile' theme requires either 'title' or 'fullName' prop."), e.size === "xxs" && (e.title?.length || e.subText?.length) && new ne("DsgAvatar: The 'xxs' size does not support the 'title' or 'subText' props.");
|
|
87
|
-
const
|
|
88
|
-
const
|
|
89
|
-
return (
|
|
90
|
-
}, n = () => e.fullName ? "Avatar of " + e.fullName : "Avatar", l = o, a = Y(!1),
|
|
91
|
-
l("before-change-status", a.value,
|
|
92
|
-
}, p = we("avatarImageWrapperEl"),
|
|
93
|
-
e.preventDefault || (l("avatar-clicked",
|
|
87
|
+
const s = (b) => {
|
|
88
|
+
const m = b.split(" ");
|
|
89
|
+
return (m[0].charAt(0) + m[m.length - 1].charAt(0)).toUpperCase();
|
|
90
|
+
}, n = () => e.fullName ? "Avatar of " + e.fullName : "Avatar", l = o, a = Y(!1), u = (b) => {
|
|
91
|
+
l("before-change-status", a.value, b), a.value = b, l("after-change-status", a.value);
|
|
92
|
+
}, p = we("avatarImageWrapperEl"), y = (b) => {
|
|
93
|
+
e.preventDefault || (l("avatar-clicked", b), p.value && !e.uri && p.value.focus());
|
|
94
94
|
};
|
|
95
95
|
return t({
|
|
96
|
-
setUserActiveStatus:
|
|
97
|
-
toggleFocus: (
|
|
98
|
-
p.value && (
|
|
96
|
+
setUserActiveStatus: u,
|
|
97
|
+
toggleFocus: (b) => {
|
|
98
|
+
p.value && (b ? p.value.focus() : p.value.blur());
|
|
99
99
|
}
|
|
100
|
-
}), (
|
|
101
|
-
class:
|
|
100
|
+
}), (b, m) => (h(), v("div", {
|
|
101
|
+
class: D(ge(i))
|
|
102
102
|
}, [
|
|
103
103
|
T("a", {
|
|
104
104
|
class: "dsg-avatar--link",
|
|
105
|
-
href:
|
|
105
|
+
href: b.uri,
|
|
106
106
|
title: n(),
|
|
107
107
|
target: "_blank",
|
|
108
108
|
ref: "avatarLink",
|
|
109
|
-
onClick:
|
|
109
|
+
onClick: y
|
|
110
110
|
}, [
|
|
111
|
-
T("div",
|
|
112
|
-
|
|
113
|
-
|
|
111
|
+
T("div", ys, [
|
|
112
|
+
M(b.$slots, "dsg-avatar--background", {}, () => [
|
|
113
|
+
b.profileUri ? (h(), v("img", {
|
|
114
114
|
key: 0,
|
|
115
115
|
class: "dsg-avatar--profile-image",
|
|
116
|
-
src:
|
|
116
|
+
src: b.profileUri,
|
|
117
117
|
alt: n()
|
|
118
|
-
}, null, 8,
|
|
119
|
-
!
|
|
120
|
-
!
|
|
118
|
+
}, null, 8, ks)) : w("", !0),
|
|
119
|
+
!b.profileUri && b.fullName ? (h(), v("span", Cs, P(s(b.fullName)), 1)) : w("", !0),
|
|
120
|
+
!b.profileUri && !b.fullName ? (h(), $(G, {
|
|
121
121
|
key: 2,
|
|
122
122
|
class: "dsg-avatar--user-icon",
|
|
123
123
|
icon: "user-01",
|
|
124
|
-
color:
|
|
125
|
-
size:
|
|
126
|
-
}, null, 8, ["color", "size"])) :
|
|
124
|
+
color: ge(ms).gray[600],
|
|
125
|
+
size: b.size
|
|
126
|
+
}, null, 8, ["color", "size"])) : w("", !0)
|
|
127
127
|
]),
|
|
128
|
-
["tile"].indexOf(
|
|
129
|
-
T("div",
|
|
130
|
-
|
|
131
|
-
["verified", "profile-photo-verified"].indexOf(
|
|
128
|
+
["tile"].indexOf(b.theme) === -1 ? M(b.$slots, "dsg-avatar--status", { key: 0 }, () => [
|
|
129
|
+
T("div", Es, [
|
|
130
|
+
b.theme === "activity" && b.isOnline ? (h(), v("span", Ts)) : w("", !0),
|
|
131
|
+
["verified", "profile-photo-verified"].indexOf(b.theme) !== -1 ? (h(), v("span", {
|
|
132
132
|
key: 1,
|
|
133
133
|
class: "dsg-avatar--verified",
|
|
134
|
-
innerHTML:
|
|
135
|
-
}, null, 8,
|
|
136
|
-
|
|
134
|
+
innerHTML: ge(vs)
|
|
135
|
+
}, null, 8, As)) : w("", !0),
|
|
136
|
+
b.theme === "logo" ? (h(), v("span", Ss, [
|
|
137
137
|
T("img", {
|
|
138
|
-
src:
|
|
138
|
+
src: b.companyLogoUri,
|
|
139
139
|
alt: n(),
|
|
140
140
|
class: "dsg-avatar--company-logo"
|
|
141
|
-
}, null, 8,
|
|
142
|
-
])) :
|
|
141
|
+
}, null, 8, Os)
|
|
142
|
+
])) : w("", !0)
|
|
143
143
|
])
|
|
144
|
-
]) :
|
|
144
|
+
]) : w("", !0)
|
|
145
145
|
], 512),
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
T("h3",
|
|
149
|
-
]) :
|
|
150
|
-
|
|
151
|
-
T("p",
|
|
152
|
-
]) :
|
|
153
|
-
])) :
|
|
154
|
-
], 8,
|
|
146
|
+
b.title?.length || b.theme === "tile" && (b.title?.length || b.fullName) ? (h(), v("div", $s, [
|
|
147
|
+
b.title?.length || b.theme === "tile" && (b.title?.length || b.fullName) ? M(b.$slots, "dsg-avatar--title", { key: 0 }, () => [
|
|
148
|
+
T("h3", Ls, P(b.title?.length ? b.title : b.fullName), 1)
|
|
149
|
+
]) : w("", !0),
|
|
150
|
+
b.subText?.length ? M(b.$slots, "dsg-avatar--subtext", { key: 1 }, () => [
|
|
151
|
+
T("p", Is, P(b.subText), 1)
|
|
152
|
+
]) : w("", !0)
|
|
153
|
+
])) : w("", !0)
|
|
154
|
+
], 8, ws)
|
|
155
155
|
], 2));
|
|
156
156
|
}
|
|
157
157
|
}), rt = {
|
|
@@ -172,13 +172,13 @@ const ms = /* @__PURE__ */ q({
|
|
|
172
172
|
WARNING: "warning",
|
|
173
173
|
ERROR: "error",
|
|
174
174
|
DEFAULT: "default"
|
|
175
|
-
},
|
|
175
|
+
}, _s = {
|
|
176
176
|
BOUNCE: "bounce",
|
|
177
177
|
SLIDE: "slide",
|
|
178
178
|
FLIP: "flip",
|
|
179
179
|
ZOOM: "zoom",
|
|
180
180
|
NONE: "none"
|
|
181
|
-
},
|
|
181
|
+
}, Bs = {
|
|
182
182
|
dangerouslyHTMLString: !1,
|
|
183
183
|
multiple: !0,
|
|
184
184
|
position: rt.TOP_RIGHT,
|
|
@@ -195,68 +195,68 @@ const ms = /* @__PURE__ */ q({
|
|
|
195
195
|
progressStyle: {},
|
|
196
196
|
role: "alert",
|
|
197
197
|
theme: "light"
|
|
198
|
-
},
|
|
198
|
+
}, Ds = {
|
|
199
199
|
rtl: !1,
|
|
200
200
|
newestOnTop: !1,
|
|
201
201
|
toastClassName: ""
|
|
202
|
-
},
|
|
203
|
-
...
|
|
204
|
-
...
|
|
202
|
+
}, xo = {
|
|
203
|
+
...Bs,
|
|
204
|
+
...Ds
|
|
205
205
|
};
|
|
206
206
|
F.DEFAULT;
|
|
207
207
|
var A = /* @__PURE__ */ ((e) => (e[e.COLLAPSE_DURATION = 300] = "COLLAPSE_DURATION", e[e.DEBOUNCE_DURATION = 50] = "DEBOUNCE_DURATION", e.CSS_NAMESPACE = "Toastify", e))(A || {}), jt = /* @__PURE__ */ ((e) => (e.ENTRANCE_ANIMATION_END = "d", e))(jt || {});
|
|
208
|
-
const
|
|
208
|
+
const Ps = {
|
|
209
209
|
enter: "Toastify--animate Toastify__bounce-enter",
|
|
210
210
|
exit: "Toastify--animate Toastify__bounce-exit",
|
|
211
211
|
appendPosition: !0
|
|
212
|
-
},
|
|
212
|
+
}, Ns = {
|
|
213
213
|
enter: "Toastify--animate Toastify__slide-enter",
|
|
214
214
|
exit: "Toastify--animate Toastify__slide-exit",
|
|
215
215
|
appendPosition: !0
|
|
216
|
-
},
|
|
216
|
+
}, Ms = {
|
|
217
217
|
enter: "Toastify--animate Toastify__zoom-enter",
|
|
218
218
|
exit: "Toastify--animate Toastify__zoom-exit"
|
|
219
|
-
},
|
|
219
|
+
}, xs = {
|
|
220
220
|
enter: "Toastify--animate Toastify__flip-enter",
|
|
221
221
|
exit: "Toastify--animate Toastify__flip-exit"
|
|
222
|
-
},
|
|
223
|
-
function
|
|
222
|
+
}, lo = "Toastify--animate Toastify__none-enter";
|
|
223
|
+
function Uo(e, t = !1) {
|
|
224
224
|
var o;
|
|
225
|
-
let
|
|
225
|
+
let i = Ps;
|
|
226
226
|
if (!e || typeof e == "string")
|
|
227
227
|
switch (e) {
|
|
228
228
|
case "flip":
|
|
229
|
-
|
|
229
|
+
i = xs;
|
|
230
230
|
break;
|
|
231
231
|
case "zoom":
|
|
232
|
-
|
|
232
|
+
i = Ms;
|
|
233
233
|
break;
|
|
234
234
|
case "slide":
|
|
235
|
-
|
|
235
|
+
i = Ns;
|
|
236
236
|
break;
|
|
237
237
|
}
|
|
238
238
|
else
|
|
239
|
-
|
|
239
|
+
i = e;
|
|
240
240
|
if (t)
|
|
241
|
-
|
|
242
|
-
else if (
|
|
243
|
-
const
|
|
244
|
-
|
|
241
|
+
i.enter = lo;
|
|
242
|
+
else if (i.enter === lo) {
|
|
243
|
+
const s = (o = i.exit.split("__")[1]) == null ? void 0 : o.split("-")[0];
|
|
244
|
+
i.enter = `Toastify--animate Toastify__${s}-enter`;
|
|
245
245
|
}
|
|
246
|
-
return
|
|
246
|
+
return i;
|
|
247
247
|
}
|
|
248
|
-
function
|
|
248
|
+
function Us(e) {
|
|
249
249
|
return e.containerId || String(e.position);
|
|
250
250
|
}
|
|
251
|
-
const
|
|
251
|
+
const Tt = "will-unmount";
|
|
252
252
|
function Rs(e = rt.TOP_RIGHT) {
|
|
253
253
|
return !!document.querySelector(`.${A.CSS_NAMESPACE}__toast-container--${e}`);
|
|
254
254
|
}
|
|
255
|
-
function
|
|
255
|
+
function zs(e = rt.TOP_RIGHT) {
|
|
256
256
|
return `${A.CSS_NAMESPACE}__toast-container--${e}`;
|
|
257
257
|
}
|
|
258
|
-
function
|
|
259
|
-
const
|
|
258
|
+
function Hs(e, t, o = !1) {
|
|
259
|
+
const i = [
|
|
260
260
|
`${A.CSS_NAMESPACE}__toast-container`,
|
|
261
261
|
`${A.CSS_NAMESPACE}__toast-container--${e}`,
|
|
262
262
|
o ? `${A.CSS_NAMESPACE}__toast-container--rtl` : null
|
|
@@ -264,120 +264,120 @@ function zs(e, t, o = !1) {
|
|
|
264
264
|
return Be(t) ? t({
|
|
265
265
|
position: e,
|
|
266
266
|
rtl: o,
|
|
267
|
-
defaultClassName:
|
|
268
|
-
}) : `${
|
|
267
|
+
defaultClassName: i
|
|
268
|
+
}) : `${i} ${t || ""}`;
|
|
269
269
|
}
|
|
270
|
-
function
|
|
270
|
+
function qs(e) {
|
|
271
271
|
var t;
|
|
272
|
-
const { position: o, containerClassName:
|
|
273
|
-
|
|
272
|
+
const { position: o, containerClassName: i, rtl: s = !1, style: n = {} } = e, l = A.CSS_NAMESPACE, a = zs(o), u = document.querySelector(`.${l}`), p = document.querySelector(`.${a}`), y = !!p && !((t = p.className) != null && t.includes(Tt)), k = u || document.createElement("div"), b = document.createElement("div");
|
|
273
|
+
b.className = Hs(
|
|
274
274
|
o,
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
),
|
|
278
|
-
for (const
|
|
279
|
-
if (Object.prototype.hasOwnProperty.call(n,
|
|
280
|
-
const S = n[
|
|
281
|
-
|
|
275
|
+
i,
|
|
276
|
+
s
|
|
277
|
+
), b.dataset.testid = `${A.CSS_NAMESPACE}__toast-container--${o}`, b.id = Us(e);
|
|
278
|
+
for (const m in n)
|
|
279
|
+
if (Object.prototype.hasOwnProperty.call(n, m)) {
|
|
280
|
+
const S = n[m];
|
|
281
|
+
b.style[m] = S;
|
|
282
282
|
}
|
|
283
|
-
return
|
|
283
|
+
return u || (k.className = A.CSS_NAMESPACE, document.body.appendChild(k)), y || k.appendChild(b), b;
|
|
284
284
|
}
|
|
285
|
-
function
|
|
286
|
-
var t, o,
|
|
287
|
-
const
|
|
288
|
-
n && n.removeEventListener("animationend",
|
|
285
|
+
function Kt(e) {
|
|
286
|
+
var t, o, i;
|
|
287
|
+
const s = typeof e == "string" ? e : ((t = e.currentTarget) == null ? void 0 : t.id) || ((o = e.target) == null ? void 0 : o.id), n = document.getElementById(s);
|
|
288
|
+
n && n.removeEventListener("animationend", Kt, !1);
|
|
289
289
|
try {
|
|
290
|
-
st[
|
|
290
|
+
st[s].unmount(), (i = document.getElementById(s)) == null || i.remove(), delete st[s], delete R[s];
|
|
291
291
|
} catch {
|
|
292
292
|
}
|
|
293
293
|
}
|
|
294
|
-
const st =
|
|
295
|
-
function
|
|
294
|
+
const st = Se({});
|
|
295
|
+
function Fs(e, t) {
|
|
296
296
|
const o = document.getElementById(String(t));
|
|
297
297
|
o && (st[o.id] = e);
|
|
298
298
|
}
|
|
299
|
-
function
|
|
299
|
+
function Gt(e, t = !0) {
|
|
300
300
|
const o = String(e);
|
|
301
301
|
if (!st[o]) return;
|
|
302
|
-
const
|
|
303
|
-
|
|
302
|
+
const i = document.getElementById(o);
|
|
303
|
+
i && i.classList.add(Tt), t ? (js(e), i && i.addEventListener("animationend", Kt, !1)) : Kt(o), le.items = le.items.filter((s) => s.containerId !== e);
|
|
304
304
|
}
|
|
305
|
-
function
|
|
305
|
+
function Vs(e) {
|
|
306
306
|
for (const t in st)
|
|
307
|
-
|
|
308
|
-
|
|
307
|
+
Gt(t, e);
|
|
308
|
+
le.items = [];
|
|
309
309
|
}
|
|
310
|
-
function
|
|
310
|
+
function Ro(e, t) {
|
|
311
311
|
const o = document.getElementById(e.toastId);
|
|
312
312
|
if (o) {
|
|
313
|
-
let
|
|
314
|
-
|
|
315
|
-
...
|
|
316
|
-
...
|
|
313
|
+
let i = e;
|
|
314
|
+
i = {
|
|
315
|
+
...i,
|
|
316
|
+
...Uo(i.transition)
|
|
317
317
|
};
|
|
318
|
-
const
|
|
319
|
-
o.className += ` ${
|
|
318
|
+
const s = i.appendPosition ? `${i.exit}--${i.position}` : i.exit;
|
|
319
|
+
o.className += ` ${s}`, t && t(o);
|
|
320
320
|
}
|
|
321
321
|
}
|
|
322
322
|
function js(e) {
|
|
323
323
|
for (const t in R)
|
|
324
324
|
if (t === e)
|
|
325
325
|
for (const o of R[t] || [])
|
|
326
|
-
|
|
326
|
+
Ro(o);
|
|
327
327
|
}
|
|
328
|
-
function
|
|
328
|
+
function Ks(e) {
|
|
329
329
|
const t = Me().find((o) => o.toastId === e);
|
|
330
330
|
return t?.containerId;
|
|
331
331
|
}
|
|
332
|
-
function
|
|
332
|
+
function oo(e) {
|
|
333
333
|
return document.getElementById(e);
|
|
334
334
|
}
|
|
335
|
-
function
|
|
336
|
-
const t =
|
|
337
|
-
return t && t.classList.contains(
|
|
335
|
+
function Gs(e) {
|
|
336
|
+
const t = oo(e.containerId);
|
|
337
|
+
return t && t.classList.contains(Tt);
|
|
338
338
|
}
|
|
339
|
-
function
|
|
339
|
+
function ro(e) {
|
|
340
340
|
var t;
|
|
341
|
-
const o =
|
|
342
|
-
return o ??
|
|
341
|
+
const o = _o(e.content) ? ee(e.content.props) : null;
|
|
342
|
+
return o ?? ee((t = e.data) != null ? t : {});
|
|
343
343
|
}
|
|
344
|
-
function
|
|
345
|
-
return e ?
|
|
344
|
+
function Ws(e) {
|
|
345
|
+
return e ? le.items.filter((t) => t.containerId === e).length > 0 : le.items.length > 0;
|
|
346
346
|
}
|
|
347
|
-
function
|
|
348
|
-
if (
|
|
349
|
-
const e =
|
|
347
|
+
function Xs() {
|
|
348
|
+
if (le.items.length > 0) {
|
|
349
|
+
const e = le.items.shift();
|
|
350
350
|
mt(e?.toastContent, e?.toastProps);
|
|
351
351
|
}
|
|
352
352
|
}
|
|
353
|
-
const R =
|
|
353
|
+
const R = Se({}), le = Se({ items: [] });
|
|
354
354
|
function Me() {
|
|
355
|
-
const e =
|
|
355
|
+
const e = ee(R);
|
|
356
356
|
return Object.values(e).reduce((t, o) => [...t, ...o], []);
|
|
357
357
|
}
|
|
358
|
-
function
|
|
358
|
+
function Ys(e) {
|
|
359
359
|
return Me().find((t) => t.toastId === e);
|
|
360
360
|
}
|
|
361
361
|
function mt(e, t = {}) {
|
|
362
|
-
if (
|
|
363
|
-
const o =
|
|
364
|
-
o && o.addEventListener("animationend",
|
|
362
|
+
if (Gs(t)) {
|
|
363
|
+
const o = oo(t.containerId);
|
|
364
|
+
o && o.addEventListener("animationend", Wt.bind(null, e, t), !1);
|
|
365
365
|
} else
|
|
366
|
-
|
|
367
|
-
}
|
|
368
|
-
function
|
|
369
|
-
const o =
|
|
370
|
-
o && o.removeEventListener("animationend",
|
|
371
|
-
const
|
|
372
|
-
if (!
|
|
373
|
-
const n =
|
|
374
|
-
t.useHandler && t.useHandler(l), l.mount(n),
|
|
366
|
+
Wt(e, t);
|
|
367
|
+
}
|
|
368
|
+
function Wt(e, t = {}) {
|
|
369
|
+
const o = oo(t.containerId);
|
|
370
|
+
o && o.removeEventListener("animationend", Wt.bind(null, e, t), !1);
|
|
371
|
+
const i = R[t.containerId] || [], s = i.length > 0;
|
|
372
|
+
if (!s && !Rs(t.position)) {
|
|
373
|
+
const n = qs(t), l = rs(mi, t);
|
|
374
|
+
t.useHandler && t.useHandler(l), l.mount(n), Fs(l, n.id);
|
|
375
375
|
}
|
|
376
|
-
|
|
377
|
-
t.updateId ?
|
|
376
|
+
s && !t.updateId && (t.position = i[0].position), eo(() => {
|
|
377
|
+
t.updateId ? W.update(t) : W.add(e, t);
|
|
378
378
|
});
|
|
379
379
|
}
|
|
380
|
-
const
|
|
380
|
+
const W = {
|
|
381
381
|
/**
|
|
382
382
|
* add a toast
|
|
383
383
|
* @param _ ..
|
|
@@ -385,9 +385,9 @@ const G = {
|
|
|
385
385
|
*/
|
|
386
386
|
add(e, t) {
|
|
387
387
|
const { containerId: o = "" } = t;
|
|
388
|
-
o && (R[o] = R[o] || [], R[o].find((
|
|
389
|
-
var
|
|
390
|
-
t.newestOnTop ? (
|
|
388
|
+
o && (R[o] = R[o] || [], R[o].find((i) => i.toastId === t.toastId) || setTimeout(() => {
|
|
389
|
+
var i, s;
|
|
390
|
+
t.newestOnTop ? (i = R[o]) == null || i.unshift(t) : (s = R[o]) == null || s.push(t), t.onOpen && t.onOpen(ro(t));
|
|
391
391
|
}, t.delay || 0));
|
|
392
392
|
},
|
|
393
393
|
/**
|
|
@@ -396,12 +396,12 @@ const G = {
|
|
|
396
396
|
*/
|
|
397
397
|
remove(e) {
|
|
398
398
|
if (e) {
|
|
399
|
-
const t =
|
|
399
|
+
const t = Ks(e);
|
|
400
400
|
if (t) {
|
|
401
401
|
const o = R[t];
|
|
402
|
-
let
|
|
403
|
-
R[t] = o.filter((
|
|
404
|
-
|
|
402
|
+
let i = o.find((s) => s.toastId === e);
|
|
403
|
+
R[t] = o.filter((s) => s.toastId !== e), !R[t].length && !Ws(t) && Gt(t, !1), Xs(), eo(() => {
|
|
404
|
+
i != null && i.onClose && (i.onClose(ro(i)), i = void 0);
|
|
405
405
|
});
|
|
406
406
|
}
|
|
407
407
|
}
|
|
@@ -414,13 +414,13 @@ const G = {
|
|
|
414
414
|
const { containerId: t = "" } = e;
|
|
415
415
|
if (t && e.updateId) {
|
|
416
416
|
R[t] = R[t] || [];
|
|
417
|
-
const o = R[t].find((n) => n.toastId === e.toastId),
|
|
417
|
+
const o = R[t].find((n) => n.toastId === e.toastId), i = o?.position !== e.position || o?.transition !== e.transition, s = {
|
|
418
418
|
...e,
|
|
419
|
-
disabledEnterTransition: !
|
|
419
|
+
disabledEnterTransition: !i,
|
|
420
420
|
updateId: void 0
|
|
421
421
|
};
|
|
422
|
-
|
|
423
|
-
|
|
422
|
+
W.dismissForce(e?.toastId), setTimeout(() => {
|
|
423
|
+
L(s.content, s);
|
|
424
424
|
}, e.delay || 0);
|
|
425
425
|
}
|
|
426
426
|
},
|
|
@@ -429,13 +429,13 @@ const G = {
|
|
|
429
429
|
* @param containerId container id
|
|
430
430
|
*/
|
|
431
431
|
clear(e, t = !0) {
|
|
432
|
-
e ?
|
|
432
|
+
e ? Gt(e, t) : Vs(t);
|
|
433
433
|
},
|
|
434
434
|
dismissCallback(e) {
|
|
435
435
|
var t;
|
|
436
|
-
const o = (t = e.currentTarget) == null ? void 0 : t.id,
|
|
437
|
-
|
|
438
|
-
|
|
436
|
+
const o = (t = e.currentTarget) == null ? void 0 : t.id, i = document.getElementById(o);
|
|
437
|
+
i && (i.removeEventListener("animationend", W.dismissCallback, !1), setTimeout(() => {
|
|
438
|
+
W.remove(o);
|
|
439
439
|
}));
|
|
440
440
|
},
|
|
441
441
|
dismiss(e) {
|
|
@@ -443,8 +443,8 @@ const G = {
|
|
|
443
443
|
const t = Me();
|
|
444
444
|
for (const o of t)
|
|
445
445
|
if (o.toastId === e) {
|
|
446
|
-
|
|
447
|
-
|
|
446
|
+
Ro(o, (i) => {
|
|
447
|
+
i.addEventListener("animationend", W.dismissCallback, !1);
|
|
448
448
|
});
|
|
449
449
|
break;
|
|
450
450
|
}
|
|
@@ -455,43 +455,43 @@ const G = {
|
|
|
455
455
|
const t = Me();
|
|
456
456
|
for (const o of t)
|
|
457
457
|
if (o.toastId === e) {
|
|
458
|
-
const
|
|
459
|
-
|
|
458
|
+
const i = document.getElementById(e);
|
|
459
|
+
i && (i.remove(), i.removeEventListener("animationend", W.dismissCallback, !1), W.remove(e));
|
|
460
460
|
break;
|
|
461
461
|
}
|
|
462
462
|
}
|
|
463
463
|
}
|
|
464
|
-
},
|
|
465
|
-
function
|
|
464
|
+
}, Zs = Se({ useHandler: void 0 }), zo = Se({}), kt = Se({});
|
|
465
|
+
function Ho() {
|
|
466
466
|
return Math.random().toString(36).substring(2, 9);
|
|
467
467
|
}
|
|
468
|
-
function
|
|
468
|
+
function Js(e) {
|
|
469
469
|
return typeof e == "number" && !isNaN(e);
|
|
470
470
|
}
|
|
471
|
-
function
|
|
471
|
+
function Xt(e) {
|
|
472
472
|
return typeof e == "string";
|
|
473
473
|
}
|
|
474
474
|
function Be(e) {
|
|
475
475
|
return typeof e == "function";
|
|
476
476
|
}
|
|
477
|
-
function
|
|
478
|
-
return
|
|
477
|
+
function At(...e) {
|
|
478
|
+
return J(...e);
|
|
479
479
|
}
|
|
480
480
|
function bt(e) {
|
|
481
481
|
return typeof e == "object" && (!!(e != null && e.render) || !!(e != null && e.setup) || typeof e?.type == "object");
|
|
482
482
|
}
|
|
483
|
-
function
|
|
484
|
-
|
|
485
|
-
}
|
|
486
|
-
function Qs() {
|
|
487
|
-
return Mo[`${A.CSS_NAMESPACE}-default-options`] || Do;
|
|
483
|
+
function Qs(e = {}) {
|
|
484
|
+
zo[`${A.CSS_NAMESPACE}-default-options`] = e;
|
|
488
485
|
}
|
|
489
486
|
function ei() {
|
|
487
|
+
return zo[`${A.CSS_NAMESPACE}-default-options`] || xo;
|
|
488
|
+
}
|
|
489
|
+
function ti() {
|
|
490
490
|
const e = window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches;
|
|
491
491
|
return document.documentElement.classList.contains("dark") || e ? "dark" : "light";
|
|
492
492
|
}
|
|
493
493
|
var vt = /* @__PURE__ */ ((e) => (e[e.Enter = 0] = "Enter", e[e.Exit = 1] = "Exit", e))(vt || {});
|
|
494
|
-
const
|
|
494
|
+
const qo = {
|
|
495
495
|
containerId: {
|
|
496
496
|
type: [String, Number],
|
|
497
497
|
required: !1,
|
|
@@ -678,7 +678,7 @@ const Ro = {
|
|
|
678
678
|
required: !1,
|
|
679
679
|
default: !1
|
|
680
680
|
}
|
|
681
|
-
},
|
|
681
|
+
}, oi = {
|
|
682
682
|
autoClose: {
|
|
683
683
|
type: [Number, Boolean],
|
|
684
684
|
required: !0
|
|
@@ -733,36 +733,36 @@ const Ro = {
|
|
|
733
733
|
required: !1,
|
|
734
734
|
default: void 0
|
|
735
735
|
}
|
|
736
|
-
},
|
|
736
|
+
}, si = /* @__PURE__ */ H({
|
|
737
737
|
name: "ProgressBar",
|
|
738
|
-
props:
|
|
738
|
+
props: oi,
|
|
739
739
|
// @ts-ignore
|
|
740
740
|
setup(e, {
|
|
741
741
|
attrs: t
|
|
742
742
|
}) {
|
|
743
|
-
const o = Y(),
|
|
743
|
+
const o = Y(), i = q(() => e.hide ? "true" : "false"), s = q(() => ({
|
|
744
744
|
...t.style || {},
|
|
745
745
|
animationDuration: `${e.autoClose === !0 ? 5e3 : e.autoClose}ms`,
|
|
746
746
|
animationPlayState: e.isRunning ? "running" : "paused",
|
|
747
747
|
opacity: e.hide || e.autoClose === !1 ? 0 : 1,
|
|
748
748
|
transform: e.controlledProgress ? `scaleX(${e.progress})` : "none"
|
|
749
|
-
})), n =
|
|
749
|
+
})), n = q(() => [`${A.CSS_NAMESPACE}__progress-bar`, e.controlledProgress ? `${A.CSS_NAMESPACE}__progress-bar--controlled` : `${A.CSS_NAMESPACE}__progress-bar--animated`, `${A.CSS_NAMESPACE}__progress-bar-theme--${e.theme}`, `${A.CSS_NAMESPACE}__progress-bar--${e.type}`, e.rtl ? `${A.CSS_NAMESPACE}__progress-bar--rtl` : null].filter(Boolean).join(" ")), l = q(() => `${n.value} ${t?.class || ""}`), a = () => {
|
|
750
750
|
o.value && (o.value.onanimationend = null, o.value.ontransitionend = null);
|
|
751
|
-
},
|
|
751
|
+
}, u = () => {
|
|
752
752
|
e.isIn && e.closeToast && e.autoClose !== !1 && (e.closeToast(), a());
|
|
753
|
-
}, p =
|
|
753
|
+
}, p = q(() => e.controlledProgress ? null : u), y = q(() => e.controlledProgress ? u : null);
|
|
754
754
|
return ht(() => {
|
|
755
|
-
o.value && (a(), o.value.onanimationend = p.value, o.value.ontransitionend =
|
|
756
|
-
}), () =>
|
|
755
|
+
o.value && (a(), o.value.onanimationend = p.value, o.value.ontransitionend = y.value);
|
|
756
|
+
}), () => I("div", {
|
|
757
757
|
ref: o,
|
|
758
758
|
role: "progressbar",
|
|
759
|
-
"aria-hidden":
|
|
759
|
+
"aria-hidden": i.value,
|
|
760
760
|
"aria-label": "notification timer",
|
|
761
761
|
class: l.value,
|
|
762
|
-
style:
|
|
762
|
+
style: s.value
|
|
763
763
|
}, null);
|
|
764
764
|
}
|
|
765
|
-
}),
|
|
765
|
+
}), ii = /* @__PURE__ */ H({
|
|
766
766
|
name: "CloseButton",
|
|
767
767
|
inheritAttrs: !1,
|
|
768
768
|
props: {
|
|
@@ -788,238 +788,238 @@ const Ro = {
|
|
|
788
788
|
}
|
|
789
789
|
},
|
|
790
790
|
setup(e) {
|
|
791
|
-
return () =>
|
|
791
|
+
return () => I("button", {
|
|
792
792
|
class: `${A.CSS_NAMESPACE}__close-button ${A.CSS_NAMESPACE}__close-button--${e.theme}`,
|
|
793
793
|
type: "button",
|
|
794
794
|
onClick: (t) => {
|
|
795
795
|
t.stopPropagation(), e.closeToast && e.closeToast(t);
|
|
796
796
|
},
|
|
797
797
|
"aria-label": e.ariaLabel
|
|
798
|
-
}, [
|
|
798
|
+
}, [I("svg", {
|
|
799
799
|
"aria-hidden": "true",
|
|
800
800
|
viewBox: "0 0 14 16"
|
|
801
|
-
}, [
|
|
801
|
+
}, [I("path", {
|
|
802
802
|
"fill-rule": "evenodd",
|
|
803
803
|
d: "M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"
|
|
804
804
|
}, null)])]);
|
|
805
805
|
}
|
|
806
|
-
}),
|
|
806
|
+
}), St = ({
|
|
807
807
|
theme: e,
|
|
808
808
|
type: t,
|
|
809
809
|
path: o,
|
|
810
|
-
...
|
|
811
|
-
}) =>
|
|
810
|
+
...i
|
|
811
|
+
}) => I("svg", J({
|
|
812
812
|
viewBox: "0 0 24 24",
|
|
813
813
|
width: "100%",
|
|
814
814
|
height: "100%",
|
|
815
815
|
fill: e === "colored" ? "currentColor" : `var(--toastify-icon-color-${t})`
|
|
816
|
-
},
|
|
816
|
+
}, i), [I("path", {
|
|
817
817
|
d: o
|
|
818
818
|
}, null)]);
|
|
819
|
-
function
|
|
820
|
-
return
|
|
819
|
+
function ni(e) {
|
|
820
|
+
return I(St, J(e, {
|
|
821
821
|
path: "M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"
|
|
822
822
|
}), null);
|
|
823
823
|
}
|
|
824
|
-
function
|
|
825
|
-
return
|
|
824
|
+
function ai(e) {
|
|
825
|
+
return I(St, J(e, {
|
|
826
826
|
path: "M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"
|
|
827
827
|
}), null);
|
|
828
828
|
}
|
|
829
|
-
function
|
|
830
|
-
return
|
|
829
|
+
function li(e) {
|
|
830
|
+
return I(St, J(e, {
|
|
831
831
|
path: "M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"
|
|
832
832
|
}), null);
|
|
833
833
|
}
|
|
834
|
-
function
|
|
835
|
-
return
|
|
834
|
+
function ri(e) {
|
|
835
|
+
return I(St, J(e, {
|
|
836
836
|
path: "M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"
|
|
837
837
|
}), null);
|
|
838
838
|
}
|
|
839
|
-
function
|
|
840
|
-
return
|
|
839
|
+
function di() {
|
|
840
|
+
return I("div", {
|
|
841
841
|
class: `${A.CSS_NAMESPACE}__spinner`
|
|
842
842
|
}, null);
|
|
843
843
|
}
|
|
844
844
|
const wt = {
|
|
845
|
-
info:
|
|
846
|
-
warning:
|
|
847
|
-
success:
|
|
848
|
-
error:
|
|
849
|
-
spinner:
|
|
850
|
-
},
|
|
851
|
-
function
|
|
845
|
+
info: ai,
|
|
846
|
+
warning: ni,
|
|
847
|
+
success: li,
|
|
848
|
+
error: ri,
|
|
849
|
+
spinner: di
|
|
850
|
+
}, ui = (e) => e in wt;
|
|
851
|
+
function ci({
|
|
852
852
|
theme: e,
|
|
853
853
|
type: t,
|
|
854
854
|
isLoading: o,
|
|
855
|
-
icon:
|
|
855
|
+
icon: i
|
|
856
856
|
}) {
|
|
857
|
-
let
|
|
857
|
+
let s;
|
|
858
858
|
const n = !!o || t === "loading", l = {
|
|
859
859
|
theme: e,
|
|
860
860
|
type: t
|
|
861
861
|
};
|
|
862
|
-
if (n && (
|
|
863
|
-
if (
|
|
864
|
-
if (bt(
|
|
865
|
-
|
|
866
|
-
else if (Be(
|
|
867
|
-
const a =
|
|
868
|
-
l.type = n ? "loading" : t,
|
|
869
|
-
} else
|
|
870
|
-
return
|
|
862
|
+
if (n && (i === void 0 || typeof i == "boolean")) return wt.spinner();
|
|
863
|
+
if (i !== !1) {
|
|
864
|
+
if (bt(i))
|
|
865
|
+
s = ee(i);
|
|
866
|
+
else if (Be(i)) {
|
|
867
|
+
const a = i;
|
|
868
|
+
l.type = n ? "loading" : t, s = a(l), s = !s && n ? wt.spinner() : s;
|
|
869
|
+
} else _o(i) ? s = ds(i, l) : Xt(i) || Js(i) ? s = i : ui(t) && (s = wt[t](l));
|
|
870
|
+
return s;
|
|
871
871
|
}
|
|
872
872
|
}
|
|
873
|
-
const
|
|
873
|
+
const fi = () => {
|
|
874
874
|
};
|
|
875
|
-
function
|
|
876
|
-
const { scrollHeight:
|
|
875
|
+
function gi(e, t, o = A.COLLAPSE_DURATION) {
|
|
876
|
+
const { scrollHeight: i, style: s } = e, n = o;
|
|
877
877
|
requestAnimationFrame(() => {
|
|
878
|
-
|
|
879
|
-
|
|
878
|
+
s.minHeight = "initial", s.height = i + "px", s.transition = `all ${n}ms`, requestAnimationFrame(() => {
|
|
879
|
+
s.height = "0", s.padding = "0", s.margin = "0", setTimeout(t, n);
|
|
880
880
|
});
|
|
881
881
|
});
|
|
882
882
|
}
|
|
883
|
-
function
|
|
884
|
-
const t = Y(!1), o = Y(!1),
|
|
883
|
+
function pi(e) {
|
|
884
|
+
const t = Y(!1), o = Y(!1), i = Y(!1), s = Y(vt.Enter), n = Se({
|
|
885
885
|
...e,
|
|
886
886
|
appendPosition: e.appendPosition || !1,
|
|
887
887
|
collapse: typeof e.collapse > "u" ? !0 : e.collapse,
|
|
888
888
|
collapseDuration: e.collapseDuration || A.COLLAPSE_DURATION
|
|
889
|
-
}), l = n.done ||
|
|
890
|
-
onMouseenter:
|
|
891
|
-
onMouseleave:
|
|
889
|
+
}), l = n.done || fi, a = q(() => n.appendPosition ? `${n.enter}--${n.position}` : n.enter), u = q(() => n.appendPosition ? `${n.exit}--${n.position}` : n.exit), p = q(() => e.pauseOnHover ? {
|
|
890
|
+
onMouseenter: U,
|
|
891
|
+
onMouseleave: C
|
|
892
892
|
} : {});
|
|
893
|
-
function
|
|
894
|
-
const
|
|
895
|
-
|
|
893
|
+
function y() {
|
|
894
|
+
const x = a.value.split(" ");
|
|
895
|
+
b().addEventListener(
|
|
896
896
|
jt.ENTRANCE_ANIMATION_END,
|
|
897
|
-
|
|
897
|
+
C,
|
|
898
898
|
{ once: !0 }
|
|
899
899
|
);
|
|
900
|
-
const oe = (
|
|
901
|
-
const He =
|
|
902
|
-
|
|
900
|
+
const oe = (Oe) => {
|
|
901
|
+
const He = b();
|
|
902
|
+
Oe.target === He && (He.dispatchEvent(new Event(jt.ENTRANCE_ANIMATION_END)), He.removeEventListener("animationend", oe), He.removeEventListener("animationcancel", oe), s.value === vt.Enter && Oe.type !== "animationcancel" && He.classList.remove(...x));
|
|
903
903
|
}, he = () => {
|
|
904
|
-
const
|
|
905
|
-
|
|
904
|
+
const Oe = b();
|
|
905
|
+
Oe.classList.add(...x), Oe.addEventListener("animationend", oe), Oe.addEventListener("animationcancel", oe);
|
|
906
906
|
};
|
|
907
|
-
e.pauseOnFocusLoss &&
|
|
907
|
+
e.pauseOnFocusLoss && m(), he();
|
|
908
908
|
}
|
|
909
|
-
function
|
|
910
|
-
if (!
|
|
911
|
-
const
|
|
912
|
-
const he =
|
|
913
|
-
he.removeEventListener("animationend",
|
|
909
|
+
function k() {
|
|
910
|
+
if (!b()) return;
|
|
911
|
+
const x = () => {
|
|
912
|
+
const he = b();
|
|
913
|
+
he.removeEventListener("animationend", x), n.collapse ? gi(he, l, n.collapseDuration) : l();
|
|
914
914
|
}, oe = () => {
|
|
915
|
-
const he =
|
|
916
|
-
|
|
915
|
+
const he = b();
|
|
916
|
+
s.value = vt.Exit, he && (he.className += ` ${u.value}`, he.addEventListener("animationend", x));
|
|
917
917
|
};
|
|
918
|
-
o.value || (
|
|
918
|
+
o.value || (i.value ? x() : setTimeout(oe));
|
|
919
919
|
}
|
|
920
|
-
function
|
|
920
|
+
function b() {
|
|
921
921
|
return e.toastRef.value;
|
|
922
922
|
}
|
|
923
|
-
function
|
|
924
|
-
document.hasFocus() ||
|
|
923
|
+
function m() {
|
|
924
|
+
document.hasFocus() || U(), window.addEventListener("focus", C), window.addEventListener("blur", U);
|
|
925
925
|
}
|
|
926
926
|
function S() {
|
|
927
|
-
window.removeEventListener("focus",
|
|
927
|
+
window.removeEventListener("focus", C), window.removeEventListener("blur", U);
|
|
928
928
|
}
|
|
929
|
-
function
|
|
929
|
+
function C() {
|
|
930
930
|
(!e.loading.value || e.isLoading === void 0) && (t.value = !0);
|
|
931
931
|
}
|
|
932
|
-
function
|
|
932
|
+
function U() {
|
|
933
933
|
t.value = !1;
|
|
934
934
|
}
|
|
935
|
-
function
|
|
936
|
-
|
|
935
|
+
function re(x) {
|
|
936
|
+
x && (x.stopPropagation(), x.preventDefault()), o.value = !1;
|
|
937
937
|
}
|
|
938
|
-
return ht(
|
|
939
|
-
const
|
|
940
|
-
o.value =
|
|
938
|
+
return ht(k), ht(() => {
|
|
939
|
+
const x = Me();
|
|
940
|
+
o.value = x.findIndex((oe) => oe.toastId === n.toastId) > -1;
|
|
941
941
|
}), ht(() => {
|
|
942
|
-
e.isLoading !== void 0 && (e.loading.value ?
|
|
943
|
-
}),
|
|
942
|
+
e.isLoading !== void 0 && (e.loading.value ? U() : C());
|
|
943
|
+
}), to(y), Io(() => {
|
|
944
944
|
e.pauseOnFocusLoss && S();
|
|
945
945
|
}), {
|
|
946
946
|
isIn: o,
|
|
947
947
|
isRunning: t,
|
|
948
|
-
hideToast:
|
|
948
|
+
hideToast: re,
|
|
949
949
|
eventHandlers: p
|
|
950
950
|
};
|
|
951
951
|
}
|
|
952
|
-
const
|
|
952
|
+
const hi = /* @__PURE__ */ H({
|
|
953
953
|
name: "ToastItem",
|
|
954
954
|
inheritAttrs: !1,
|
|
955
|
-
props:
|
|
955
|
+
props: qo,
|
|
956
956
|
// @ts-ignore
|
|
957
957
|
setup(e) {
|
|
958
|
-
const t = Y(), o =
|
|
958
|
+
const t = Y(), o = q(() => !!e.isLoading), i = q(() => e.progress !== void 0 && e.progress !== null), s = q(() => ci(e)), n = q(() => [`${A.CSS_NAMESPACE}__toast`, `${A.CSS_NAMESPACE}__toast-theme--${e.theme}`, `${A.CSS_NAMESPACE}__toast--${e.type}`, e.rtl ? `${A.CSS_NAMESPACE}__toast--rtl` : void 0, e.toastClassName || ""].filter(Boolean).join(" ")), {
|
|
959
959
|
isRunning: l,
|
|
960
960
|
isIn: a,
|
|
961
|
-
hideToast:
|
|
961
|
+
hideToast: u,
|
|
962
962
|
eventHandlers: p
|
|
963
|
-
} =
|
|
963
|
+
} = pi({
|
|
964
964
|
toastRef: t,
|
|
965
965
|
loading: o,
|
|
966
966
|
done: () => {
|
|
967
|
-
|
|
967
|
+
W.remove(e.toastId);
|
|
968
968
|
},
|
|
969
|
-
...
|
|
969
|
+
...Uo(e.transition, e.disabledEnterTransition),
|
|
970
970
|
...e
|
|
971
971
|
});
|
|
972
|
-
return () =>
|
|
972
|
+
return () => I("div", J({
|
|
973
973
|
id: e.toastId,
|
|
974
974
|
class: n.value,
|
|
975
975
|
style: e.toastStyle || {},
|
|
976
976
|
ref: t,
|
|
977
977
|
"data-testid": `toast-item-${e.toastId}`,
|
|
978
|
-
onClick: (
|
|
979
|
-
e.closeOnClick &&
|
|
978
|
+
onClick: (y) => {
|
|
979
|
+
e.closeOnClick && u(), e.onClick && e.onClick(y);
|
|
980
980
|
}
|
|
981
|
-
}, p.value), [
|
|
981
|
+
}, p.value), [I("div", {
|
|
982
982
|
role: e.role,
|
|
983
983
|
"data-testid": "toast-body",
|
|
984
984
|
class: `${A.CSS_NAMESPACE}__toast-body ${e.bodyClassName || ""}`
|
|
985
|
-
}, [
|
|
985
|
+
}, [s.value != null && I("div", {
|
|
986
986
|
"data-testid": `toast-icon-${e.type}`,
|
|
987
987
|
class: [`${A.CSS_NAMESPACE}__toast-icon`, e.isLoading ? "" : `${A.CSS_NAMESPACE}--animate-icon ${A.CSS_NAMESPACE}__zoom-enter`].join(" ")
|
|
988
|
-
}, [bt(
|
|
988
|
+
}, [bt(s.value) ? ut(ee(s.value), {
|
|
989
989
|
theme: e.theme,
|
|
990
990
|
type: e.type
|
|
991
|
-
}) : Be(
|
|
991
|
+
}) : Be(s.value) ? s.value({
|
|
992
992
|
theme: e.theme,
|
|
993
993
|
type: e.type
|
|
994
|
-
}) :
|
|
994
|
+
}) : s.value]), I("div", {
|
|
995
995
|
"data-testid": "toast-content"
|
|
996
|
-
}, [bt(e.content) ? ut(
|
|
997
|
-
toastProps:
|
|
998
|
-
closeToast:
|
|
996
|
+
}, [bt(e.content) ? ut(ee(e.content), {
|
|
997
|
+
toastProps: ee(e),
|
|
998
|
+
closeToast: u,
|
|
999
999
|
data: e.data,
|
|
1000
1000
|
...e.expandCustomProps ? e.contentProps : {
|
|
1001
1001
|
contentProps: e.contentProps || {}
|
|
1002
1002
|
}
|
|
1003
1003
|
}) : Be(e.content) ? e.content({
|
|
1004
|
-
toastProps:
|
|
1005
|
-
closeToast:
|
|
1004
|
+
toastProps: ee(e),
|
|
1005
|
+
closeToast: u,
|
|
1006
1006
|
data: e.data
|
|
1007
1007
|
}) : e.dangerouslyHTMLString ? ut("div", {
|
|
1008
1008
|
innerHTML: e.content
|
|
1009
|
-
}) : e.content])]), (e.closeButton === void 0 || e.closeButton === !0) &&
|
|
1009
|
+
}) : e.content])]), (e.closeButton === void 0 || e.closeButton === !0) && I(ii, {
|
|
1010
1010
|
theme: e.theme,
|
|
1011
|
-
closeToast: (
|
|
1012
|
-
|
|
1011
|
+
closeToast: (y) => {
|
|
1012
|
+
y.stopPropagation(), y.preventDefault(), u();
|
|
1013
1013
|
}
|
|
1014
|
-
}, null), bt(e.closeButton) ? ut(
|
|
1015
|
-
closeToast:
|
|
1014
|
+
}, null), bt(e.closeButton) ? ut(ee(e.closeButton), {
|
|
1015
|
+
closeToast: u,
|
|
1016
1016
|
type: e.type,
|
|
1017
1017
|
theme: e.theme
|
|
1018
1018
|
}) : Be(e.closeButton) ? e.closeButton({
|
|
1019
|
-
closeToast:
|
|
1019
|
+
closeToast: u,
|
|
1020
1020
|
type: e.type,
|
|
1021
1021
|
theme: e.theme
|
|
1022
|
-
}) : null,
|
|
1022
|
+
}) : null, I(si, {
|
|
1023
1023
|
className: e.progressClassName,
|
|
1024
1024
|
style: e.progressStyle,
|
|
1025
1025
|
rtl: e.rtl,
|
|
@@ -1029,58 +1029,58 @@ const pi = /* @__PURE__ */ q({
|
|
|
1029
1029
|
hide: e.hideProgressBar,
|
|
1030
1030
|
isRunning: l.value,
|
|
1031
1031
|
autoClose: e.autoClose,
|
|
1032
|
-
controlledProgress:
|
|
1032
|
+
controlledProgress: i.value,
|
|
1033
1033
|
progress: e.progress,
|
|
1034
|
-
closeToast: e.isLoading ? void 0 :
|
|
1034
|
+
closeToast: e.isLoading ? void 0 : u
|
|
1035
1035
|
}, null)]);
|
|
1036
1036
|
}
|
|
1037
1037
|
});
|
|
1038
1038
|
let et = 0;
|
|
1039
|
-
function
|
|
1040
|
-
typeof window > "u" || (et && window.cancelAnimationFrame(et), et = window.requestAnimationFrame(
|
|
1039
|
+
function Fo() {
|
|
1040
|
+
typeof window > "u" || (et && window.cancelAnimationFrame(et), et = window.requestAnimationFrame(Fo), kt.lastUrl !== window.location.href && (kt.lastUrl = window.location.href, W.clear()));
|
|
1041
1041
|
}
|
|
1042
|
-
const
|
|
1042
|
+
const mi = /* @__PURE__ */ H({
|
|
1043
1043
|
name: "ToastifyContainer",
|
|
1044
1044
|
inheritAttrs: !1,
|
|
1045
|
-
props:
|
|
1045
|
+
props: qo,
|
|
1046
1046
|
// @ts-ignore
|
|
1047
1047
|
setup(e) {
|
|
1048
|
-
const t =
|
|
1049
|
-
return
|
|
1050
|
-
typeof window < "u" && e.clearOnUrlChange && window.requestAnimationFrame(
|
|
1051
|
-
}),
|
|
1052
|
-
typeof window < "u" && et && (window.cancelAnimationFrame(et),
|
|
1053
|
-
}), () =>
|
|
1048
|
+
const t = q(() => e.containerId), o = q(() => R[t.value] || []), i = q(() => o.value.filter((s) => s.position === e.position));
|
|
1049
|
+
return to(() => {
|
|
1050
|
+
typeof window < "u" && e.clearOnUrlChange && window.requestAnimationFrame(Fo);
|
|
1051
|
+
}), Io(() => {
|
|
1052
|
+
typeof window < "u" && et && (window.cancelAnimationFrame(et), kt.lastUrl = "");
|
|
1053
|
+
}), () => I(Z, null, [i.value.map((s) => {
|
|
1054
1054
|
const {
|
|
1055
1055
|
toastId: n = ""
|
|
1056
|
-
} =
|
|
1057
|
-
return
|
|
1056
|
+
} = s;
|
|
1057
|
+
return I(hi, J({
|
|
1058
1058
|
key: n
|
|
1059
|
-
},
|
|
1059
|
+
}, s), null);
|
|
1060
1060
|
})]);
|
|
1061
1061
|
}
|
|
1062
1062
|
});
|
|
1063
|
-
let
|
|
1064
|
-
const
|
|
1063
|
+
let Lt = !1;
|
|
1064
|
+
const Vo = {
|
|
1065
1065
|
isLoading: !0,
|
|
1066
1066
|
autoClose: !1,
|
|
1067
1067
|
closeOnClick: !1,
|
|
1068
1068
|
closeButton: !1,
|
|
1069
1069
|
draggable: !1
|
|
1070
1070
|
};
|
|
1071
|
-
function
|
|
1071
|
+
function jo() {
|
|
1072
1072
|
const e = [];
|
|
1073
1073
|
return Me().forEach((t) => {
|
|
1074
1074
|
const o = document.getElementById(t.containerId);
|
|
1075
|
-
o && !o.classList.contains(
|
|
1075
|
+
o && !o.classList.contains(Tt) && e.push(t);
|
|
1076
1076
|
}), e;
|
|
1077
1077
|
}
|
|
1078
|
-
function mi(e) {
|
|
1079
|
-
const t = Ho().length, o = e ?? 0;
|
|
1080
|
-
return o > 0 && t + re.items.length >= o;
|
|
1081
|
-
}
|
|
1082
1078
|
function bi(e) {
|
|
1083
|
-
|
|
1079
|
+
const t = jo().length, o = e ?? 0;
|
|
1080
|
+
return o > 0 && t + le.items.length >= o;
|
|
1081
|
+
}
|
|
1082
|
+
function vi(e) {
|
|
1083
|
+
bi(e.limit) && !e.updateId && le.items.push({
|
|
1084
1084
|
toastId: e.toastId,
|
|
1085
1085
|
containerId: e.containerId,
|
|
1086
1086
|
toastContent: e.content,
|
|
@@ -1088,226 +1088,226 @@ function bi(e) {
|
|
|
1088
1088
|
});
|
|
1089
1089
|
}
|
|
1090
1090
|
function Ce(e, t, o = {}) {
|
|
1091
|
-
if (
|
|
1092
|
-
o =
|
|
1091
|
+
if (Lt) return;
|
|
1092
|
+
o = At(ei(), {
|
|
1093
1093
|
type: t
|
|
1094
|
-
},
|
|
1094
|
+
}, ee(o)), (!o.toastId || typeof o.toastId != "string" && typeof o.toastId != "number") && (o.toastId = Ho()), o = {
|
|
1095
1095
|
...o,
|
|
1096
|
-
...o.type === "loading" ?
|
|
1096
|
+
...o.type === "loading" ? Vo : {},
|
|
1097
1097
|
content: e,
|
|
1098
1098
|
containerId: o.containerId || String(o.position)
|
|
1099
1099
|
};
|
|
1100
|
-
const
|
|
1101
|
-
return !isNaN(
|
|
1100
|
+
const i = Number(o?.progress);
|
|
1101
|
+
return !isNaN(i) && i < 0 && (o.progress = 0), i > 1 && (o.progress = 1), o.theme === "auto" && (o.theme = ti()), vi(o), kt.lastUrl = window.location.href, o.multiple ? le.items.length ? o.updateId && mt(e, o) : mt(e, o) : (Lt = !0, L.clearAll(void 0, !1), setTimeout(() => {
|
|
1102
1102
|
mt(e, o);
|
|
1103
1103
|
}, 0), setTimeout(() => {
|
|
1104
|
-
|
|
1104
|
+
Lt = !1;
|
|
1105
1105
|
}, 390)), o.toastId;
|
|
1106
1106
|
}
|
|
1107
|
-
const
|
|
1108
|
-
|
|
1107
|
+
const L = (e, t) => Ce(e, F.DEFAULT, t);
|
|
1108
|
+
L.info = (e, t) => Ce(e, F.DEFAULT, {
|
|
1109
1109
|
...t,
|
|
1110
1110
|
type: F.INFO
|
|
1111
1111
|
});
|
|
1112
|
-
|
|
1112
|
+
L.error = (e, t) => Ce(e, F.DEFAULT, {
|
|
1113
1113
|
...t,
|
|
1114
1114
|
type: F.ERROR
|
|
1115
1115
|
});
|
|
1116
|
-
|
|
1116
|
+
L.warning = (e, t) => Ce(e, F.DEFAULT, {
|
|
1117
1117
|
...t,
|
|
1118
1118
|
type: F.WARNING
|
|
1119
1119
|
});
|
|
1120
|
-
|
|
1121
|
-
|
|
1120
|
+
L.warn = L.warning;
|
|
1121
|
+
L.success = (e, t) => Ce(e, F.DEFAULT, {
|
|
1122
1122
|
...t,
|
|
1123
1123
|
type: F.SUCCESS
|
|
1124
1124
|
});
|
|
1125
|
-
|
|
1126
|
-
|
|
1125
|
+
L.loading = (e, t) => Ce(e, F.DEFAULT, At(t, Vo));
|
|
1126
|
+
L.dark = (e, t) => Ce(e, F.DEFAULT, At(t, {
|
|
1127
1127
|
theme: Ne.DARK
|
|
1128
1128
|
}));
|
|
1129
|
-
|
|
1130
|
-
e ?
|
|
1129
|
+
L.remove = (e) => {
|
|
1130
|
+
e ? W.dismiss(e) : W.clear();
|
|
1131
1131
|
};
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1132
|
+
L.clearAll = (e, t) => {
|
|
1133
|
+
eo(() => {
|
|
1134
|
+
W.clear(e, t);
|
|
1135
1135
|
});
|
|
1136
1136
|
};
|
|
1137
|
-
|
|
1137
|
+
L.isActive = (e) => {
|
|
1138
1138
|
let t = !1;
|
|
1139
|
-
return t =
|
|
1139
|
+
return t = jo().findIndex((o) => o.toastId === e) > -1, t;
|
|
1140
1140
|
};
|
|
1141
|
-
|
|
1141
|
+
L.update = (e, t = {}) => {
|
|
1142
1142
|
setTimeout(() => {
|
|
1143
|
-
const o =
|
|
1143
|
+
const o = Ys(e);
|
|
1144
1144
|
if (o) {
|
|
1145
|
-
const
|
|
1146
|
-
content:
|
|
1147
|
-
} =
|
|
1148
|
-
...
|
|
1145
|
+
const i = ee(o), {
|
|
1146
|
+
content: s
|
|
1147
|
+
} = i, n = {
|
|
1148
|
+
...i,
|
|
1149
1149
|
...t,
|
|
1150
1150
|
toastId: t.toastId || e,
|
|
1151
|
-
updateId:
|
|
1152
|
-
}, l = n.render ||
|
|
1151
|
+
updateId: Ho()
|
|
1152
|
+
}, l = n.render || s;
|
|
1153
1153
|
delete n.render, Ce(l, n.type, n);
|
|
1154
1154
|
}
|
|
1155
1155
|
}, 0);
|
|
1156
1156
|
};
|
|
1157
|
-
|
|
1158
|
-
|
|
1157
|
+
L.done = (e) => {
|
|
1158
|
+
L.update(e, {
|
|
1159
1159
|
isLoading: !1,
|
|
1160
1160
|
progress: 1
|
|
1161
1161
|
});
|
|
1162
1162
|
};
|
|
1163
|
-
|
|
1164
|
-
function
|
|
1163
|
+
L.promise = wi;
|
|
1164
|
+
function wi(e, {
|
|
1165
1165
|
pending: t,
|
|
1166
1166
|
error: o,
|
|
1167
|
-
success:
|
|
1168
|
-
},
|
|
1167
|
+
success: i
|
|
1168
|
+
}, s) {
|
|
1169
1169
|
var n, l, a;
|
|
1170
|
-
let
|
|
1170
|
+
let u;
|
|
1171
1171
|
const p = {
|
|
1172
|
-
...
|
|
1172
|
+
...s || {},
|
|
1173
1173
|
autoClose: !1
|
|
1174
1174
|
};
|
|
1175
|
-
t && (
|
|
1175
|
+
t && (u = Xt(t) ? L.loading(t, p) : L.loading(t.render, {
|
|
1176
1176
|
...p,
|
|
1177
1177
|
...t
|
|
1178
1178
|
}));
|
|
1179
|
-
const
|
|
1180
|
-
autoClose: (n =
|
|
1181
|
-
closeOnClick: (l =
|
|
1182
|
-
closeButton: (a =
|
|
1179
|
+
const y = {
|
|
1180
|
+
autoClose: (n = s?.autoClose) != null ? n : !0,
|
|
1181
|
+
closeOnClick: (l = s?.closeOnClick) != null ? l : !0,
|
|
1182
|
+
closeButton: (a = s?.autoClose) != null ? a : null,
|
|
1183
1183
|
isLoading: void 0,
|
|
1184
1184
|
draggable: null,
|
|
1185
1185
|
delay: 100
|
|
1186
|
-
},
|
|
1186
|
+
}, k = (m, S, C) => {
|
|
1187
1187
|
if (S == null) {
|
|
1188
|
-
|
|
1188
|
+
L.remove(u);
|
|
1189
1189
|
return;
|
|
1190
1190
|
}
|
|
1191
|
-
const
|
|
1192
|
-
type:
|
|
1193
|
-
...
|
|
1194
|
-
...
|
|
1195
|
-
data:
|
|
1196
|
-
},
|
|
1191
|
+
const U = {
|
|
1192
|
+
type: m,
|
|
1193
|
+
...y,
|
|
1194
|
+
...s,
|
|
1195
|
+
data: C
|
|
1196
|
+
}, re = Xt(S) ? {
|
|
1197
1197
|
render: S
|
|
1198
1198
|
} : S;
|
|
1199
|
-
return
|
|
1200
|
-
...
|
|
1201
|
-
...
|
|
1199
|
+
return u ? L.update(u, {
|
|
1200
|
+
...U,
|
|
1201
|
+
...re,
|
|
1202
1202
|
isLoading: !1
|
|
1203
|
-
}) :
|
|
1204
|
-
...
|
|
1205
|
-
...
|
|
1203
|
+
}) : L(re.render, {
|
|
1204
|
+
...U,
|
|
1205
|
+
...re,
|
|
1206
1206
|
isLoading: !1
|
|
1207
|
-
}),
|
|
1208
|
-
},
|
|
1209
|
-
return
|
|
1210
|
-
|
|
1211
|
-
}).catch((
|
|
1212
|
-
|
|
1213
|
-
}),
|
|
1214
|
-
}
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
const
|
|
1207
|
+
}), C;
|
|
1208
|
+
}, b = Be(e) ? e() : e;
|
|
1209
|
+
return b.then((m) => {
|
|
1210
|
+
k("success", i, m);
|
|
1211
|
+
}).catch((m) => {
|
|
1212
|
+
k("error", o, m);
|
|
1213
|
+
}), b;
|
|
1214
|
+
}
|
|
1215
|
+
L.POSITION = rt;
|
|
1216
|
+
L.THEME = Ne;
|
|
1217
|
+
L.TYPE = F;
|
|
1218
|
+
L.TRANSITIONS = _s;
|
|
1219
|
+
const yi = {
|
|
1220
1220
|
install(e, t = {}) {
|
|
1221
|
-
|
|
1222
|
-
}),
|
|
1221
|
+
Zs.useHandler = t.useHandler || (() => {
|
|
1222
|
+
}), ki(t);
|
|
1223
1223
|
}
|
|
1224
1224
|
};
|
|
1225
|
-
typeof window < "u" && (window.Vue3Toastify =
|
|
1226
|
-
function
|
|
1227
|
-
const t =
|
|
1228
|
-
|
|
1225
|
+
typeof window < "u" && (window.Vue3Toastify = yi);
|
|
1226
|
+
function ki(e = {}) {
|
|
1227
|
+
const t = At(xo, e);
|
|
1228
|
+
Qs(t);
|
|
1229
1229
|
}
|
|
1230
|
-
const Ci = { class: "dsg-alert__wrapper" },
|
|
1230
|
+
const Ci = { class: "dsg-alert__wrapper" }, Ei = {
|
|
1231
1231
|
key: 0,
|
|
1232
1232
|
class: "dsg-alert__message"
|
|
1233
|
-
},
|
|
1233
|
+
}, Ti = /* @__PURE__ */ H({
|
|
1234
1234
|
__name: "DsgAlertComponent",
|
|
1235
1235
|
props: {
|
|
1236
1236
|
contentProps: { default: () => ({ title: "", message: "", type: "gray", hasCloseButton: !0 }) }
|
|
1237
1237
|
},
|
|
1238
1238
|
setup(e) {
|
|
1239
|
-
const t = ["dsg-alert", "dsg-alert--" + e.contentProps.type, e.contentProps.hasCloseButton ? "dsg-alert--has-close" : "dsg-alert--no-close"],
|
|
1240
|
-
|
|
1239
|
+
const t = ["dsg-alert", "dsg-alert--" + e.contentProps.type, e.contentProps.hasCloseButton ? "dsg-alert--has-close" : "dsg-alert--no-close"], i = us().closeToast, s = () => {
|
|
1240
|
+
i();
|
|
1241
1241
|
};
|
|
1242
|
-
return (n, l) => (
|
|
1243
|
-
class:
|
|
1242
|
+
return (n, l) => (h(), v("div", {
|
|
1243
|
+
class: D(t)
|
|
1244
1244
|
}, [
|
|
1245
|
-
n.contentProps.type === "gray" ? (
|
|
1245
|
+
n.contentProps.type === "gray" ? (h(), $(Ie, {
|
|
1246
1246
|
key: 0,
|
|
1247
1247
|
icon: { icon: "info-circle" },
|
|
1248
1248
|
type: "outline",
|
|
1249
1249
|
theme: "gray",
|
|
1250
1250
|
size: "lg"
|
|
1251
|
-
})) :
|
|
1252
|
-
n.contentProps.type === "error" ? (
|
|
1251
|
+
})) : w("", !0),
|
|
1252
|
+
n.contentProps.type === "error" ? (h(), $(Ie, {
|
|
1253
1253
|
key: 1,
|
|
1254
1254
|
icon: { icon: "alert-circle" },
|
|
1255
1255
|
type: "outline",
|
|
1256
1256
|
theme: "error",
|
|
1257
1257
|
size: "lg"
|
|
1258
|
-
})) :
|
|
1259
|
-
n.contentProps.type === "warning" ? (
|
|
1258
|
+
})) : w("", !0),
|
|
1259
|
+
n.contentProps.type === "warning" ? (h(), $(Ie, {
|
|
1260
1260
|
key: 2,
|
|
1261
1261
|
icon: { icon: "alert-circle" },
|
|
1262
1262
|
type: "outline",
|
|
1263
1263
|
theme: "warning",
|
|
1264
1264
|
size: "lg"
|
|
1265
|
-
})) :
|
|
1266
|
-
n.contentProps.type === "success" ? (
|
|
1265
|
+
})) : w("", !0),
|
|
1266
|
+
n.contentProps.type === "success" ? (h(), $(Ie, {
|
|
1267
1267
|
key: 3,
|
|
1268
1268
|
icon: { icon: "check-circle" },
|
|
1269
1269
|
type: "outline",
|
|
1270
1270
|
theme: "success",
|
|
1271
1271
|
size: "lg"
|
|
1272
|
-
})) :
|
|
1272
|
+
})) : w("", !0),
|
|
1273
1273
|
T("div", Ci, [
|
|
1274
1274
|
T("p", {
|
|
1275
|
-
class:
|
|
1276
|
-
},
|
|
1277
|
-
n.contentProps.message ? (
|
|
1275
|
+
class: D(["dsg-alert__title", { "dsg-alert__title--with-close-button": n.contentProps.hasCloseButton }])
|
|
1276
|
+
}, P(n.contentProps.title), 3),
|
|
1277
|
+
n.contentProps.message ? (h(), v("p", Ei, P(n.contentProps.message), 1)) : w("", !0)
|
|
1278
1278
|
]),
|
|
1279
|
-
n.contentProps.hasCloseButton ? (
|
|
1279
|
+
n.contentProps.hasCloseButton ? (h(), v("button", {
|
|
1280
1280
|
key: 4,
|
|
1281
|
-
onClick:
|
|
1281
|
+
onClick: s,
|
|
1282
1282
|
class: "dsg-alert__close-button"
|
|
1283
1283
|
}, [
|
|
1284
|
-
|
|
1284
|
+
I(G, {
|
|
1285
1285
|
icon: "x-close",
|
|
1286
1286
|
size: "sm"
|
|
1287
1287
|
})
|
|
1288
|
-
])) :
|
|
1288
|
+
])) : w("", !0)
|
|
1289
1289
|
]));
|
|
1290
1290
|
}
|
|
1291
|
-
}),
|
|
1292
|
-
info(t = "", o = "",
|
|
1293
|
-
Ye.showToast("gray", t, o,
|
|
1291
|
+
}), Ai = new class Ye {
|
|
1292
|
+
info(t = "", o = "", i = {}) {
|
|
1293
|
+
Ye.showToast("gray", t, o, i);
|
|
1294
1294
|
}
|
|
1295
|
-
error(t = "", o = "",
|
|
1296
|
-
Ye.showToast("error", t, o,
|
|
1295
|
+
error(t = "", o = "", i = {}) {
|
|
1296
|
+
Ye.showToast("error", t, o, i);
|
|
1297
1297
|
}
|
|
1298
|
-
warning(t = "", o = "",
|
|
1299
|
-
Ye.showToast("warning", t, o,
|
|
1298
|
+
warning(t = "", o = "", i = {}) {
|
|
1299
|
+
Ye.showToast("warning", t, o, i);
|
|
1300
1300
|
}
|
|
1301
|
-
success(t = "", o = "",
|
|
1302
|
-
Ye.showToast("success", t, o,
|
|
1301
|
+
success(t = "", o = "", i = {}) {
|
|
1302
|
+
Ye.showToast("success", t, o, i);
|
|
1303
1303
|
}
|
|
1304
|
-
static showToast(t, o,
|
|
1304
|
+
static showToast(t, o, i, s) {
|
|
1305
1305
|
const n = {
|
|
1306
1306
|
hasCloseButton: !1,
|
|
1307
1307
|
position: "top-right",
|
|
1308
|
-
...
|
|
1308
|
+
...s
|
|
1309
1309
|
};
|
|
1310
|
-
|
|
1310
|
+
L(Ti, {
|
|
1311
1311
|
autoClose: !n.hasCloseButton,
|
|
1312
1312
|
closeButton: !1,
|
|
1313
1313
|
hideProgressBar: !0,
|
|
@@ -1315,7 +1315,7 @@ const Ci = { class: "dsg-alert__wrapper" }, ki = {
|
|
|
1315
1315
|
position: n.position,
|
|
1316
1316
|
contentProps: {
|
|
1317
1317
|
title: o,
|
|
1318
|
-
message:
|
|
1318
|
+
message: i,
|
|
1319
1319
|
type: t,
|
|
1320
1320
|
hasCloseButton: n.hasCloseButton
|
|
1321
1321
|
},
|
|
@@ -1323,16 +1323,16 @@ const Ci = { class: "dsg-alert__wrapper" }, ki = {
|
|
|
1323
1323
|
}
|
|
1324
1324
|
});
|
|
1325
1325
|
}
|
|
1326
|
-
}(),
|
|
1326
|
+
}(), Si = { class: "dsg-badge--before" }, Oi = {
|
|
1327
1327
|
key: 2,
|
|
1328
1328
|
class: "dsg-badge--dot"
|
|
1329
|
-
},
|
|
1329
|
+
}, $i = {
|
|
1330
1330
|
key: 1,
|
|
1331
1331
|
class: "dsg-badge--label"
|
|
1332
|
-
},
|
|
1332
|
+
}, Li = { class: "dsg-badge--after" }, Ii = {
|
|
1333
1333
|
key: 1,
|
|
1334
1334
|
class: "dsg-badge--close-wrapper"
|
|
1335
|
-
},
|
|
1335
|
+
}, Ko = /* @__PURE__ */ H({
|
|
1336
1336
|
__name: "DsgBadge",
|
|
1337
1337
|
props: {
|
|
1338
1338
|
label: { default: "" },
|
|
@@ -1350,7 +1350,7 @@ const Ci = { class: "dsg-alert__wrapper" }, ki = {
|
|
|
1350
1350
|
},
|
|
1351
1351
|
emits: ["before-hide", "after-hide", "before-destroy", "after-destroy", "on-click"],
|
|
1352
1352
|
setup(e, { expose: t, emit: o }) {
|
|
1353
|
-
const
|
|
1353
|
+
const i = e.iconBefore || e.iconAfter || e.type === "add", s = [
|
|
1354
1354
|
"dsg-badge",
|
|
1355
1355
|
`dsg-badge--${e.size}`,
|
|
1356
1356
|
`dsg-badge--${e.type}`,
|
|
@@ -1359,16 +1359,16 @@ const Ci = { class: "dsg-alert__wrapper" }, ki = {
|
|
|
1359
1359
|
`${e.hasClose ? "dsg-badge--has-close" : ""}`,
|
|
1360
1360
|
`${e.avatarUri ? "dsg-badge--has-avatar" : ""}`,
|
|
1361
1361
|
`${e.hasDot ? "dsg-badge--has-dot" : ""}`,
|
|
1362
|
-
`${
|
|
1362
|
+
`${i ? "dsg-badge--has-icon" : ""}`,
|
|
1363
1363
|
`${e.iconBefore ? "dsg-badge--has-icon-before" : ""}`,
|
|
1364
1364
|
`${e.iconAfter ? "dsg-badge--has-icon-after" : ""}`,
|
|
1365
1365
|
e.classes
|
|
1366
1366
|
].join(" ").replaceAll(/\s+/g, " ").trim();
|
|
1367
1367
|
e.type === "add" && (e.label || e.avatarUri || e.hasDot || e.iconBefore || e.iconAfter || e.hasClose) && e.theme !== "badge-modern" && e.themeColor && new ne("DsgBadge: 'add' type badges should only be called with 'size', 'theme' and 'themeColor' props. Note that 'themeColor' prop is discarded for theme 'badge-modern'."), [e.avatarUri, e.iconBefore, e.hasDot].filter(Boolean).length > 1 && new ne("DsgBadge: 'avatarUri', 'iconBefore' and 'hasDot' props are mutually exclusive. Please use only one of them."), [e.iconAfter, e.hasClose].filter(Boolean).length > 1 && new ne("DsgBadge: 'iconAfter' and 'hasClose' props are mutually exclusive. Please use only one of them.");
|
|
1368
|
-
const a = o,
|
|
1369
|
-
e.destroyOnClose ? (a("before-destroy",
|
|
1370
|
-
},
|
|
1371
|
-
a("on-click",
|
|
1368
|
+
const a = o, u = we("dsgBadge"), p = (k) => {
|
|
1369
|
+
e.destroyOnClose ? (a("before-destroy", u.value), u.value?.remove(), a("after-destroy")) : (a("before-hide", u.value), u.value && (u.value.style.display = "none"), a("after-hide", u.value));
|
|
1370
|
+
}, y = (k) => {
|
|
1371
|
+
a("on-click", u.value);
|
|
1372
1372
|
};
|
|
1373
1373
|
return t({
|
|
1374
1374
|
/**
|
|
@@ -1384,130 +1384,239 @@ const Ci = { class: "dsg-alert__wrapper" }, ki = {
|
|
|
1384
1384
|
* @param {Event} clickEvent - The click event
|
|
1385
1385
|
* @returns void
|
|
1386
1386
|
*/
|
|
1387
|
-
clickEvent:
|
|
1388
|
-
}), (
|
|
1389
|
-
class:
|
|
1387
|
+
clickEvent: y
|
|
1388
|
+
}), (k, b) => (h(), v("div", {
|
|
1389
|
+
class: D(ge(s)),
|
|
1390
1390
|
ref: "dsgBadge",
|
|
1391
|
-
onClick:
|
|
1391
|
+
onClick: y
|
|
1392
1392
|
}, [
|
|
1393
|
-
|
|
1394
|
-
T("div",
|
|
1395
|
-
|
|
1393
|
+
k.type === "standard" ? M(k.$slots, "dsg-badge--before", { key: 0 }, () => [
|
|
1394
|
+
T("div", Si, [
|
|
1395
|
+
k.avatarUri ? (h(), $(ot, {
|
|
1396
1396
|
key: 0,
|
|
1397
|
-
"profile-uri":
|
|
1397
|
+
"profile-uri": k.avatarUri,
|
|
1398
1398
|
class: "dsg-badge--avatar",
|
|
1399
1399
|
size: "xxs"
|
|
1400
|
-
}, null, 8, ["profile-uri"])) :
|
|
1401
|
-
|
|
1400
|
+
}, null, 8, ["profile-uri"])) : w("", !0),
|
|
1401
|
+
k.iconBefore ? (h(), $(G, {
|
|
1402
1402
|
key: 1,
|
|
1403
|
-
icon:
|
|
1403
|
+
icon: k.iconBefore,
|
|
1404
1404
|
size: "xxs",
|
|
1405
1405
|
class: "dsg-badge--icon-before dsg-badge--icon"
|
|
1406
|
-
}, null, 8, ["icon"])) :
|
|
1407
|
-
|
|
1406
|
+
}, null, 8, ["icon"])) : w("", !0),
|
|
1407
|
+
k.hasDot ? (h(), v("span", Oi)) : w("", !0)
|
|
1408
1408
|
])
|
|
1409
|
-
]) :
|
|
1410
|
-
|
|
1411
|
-
|
|
1409
|
+
]) : w("", !0),
|
|
1410
|
+
k.type === "standard" ? (h(), v("label", $i, P(k.label), 1)) : w("", !0),
|
|
1411
|
+
k.type === "add" ? (h(), $(G, {
|
|
1412
1412
|
key: 2,
|
|
1413
1413
|
icon: "plus",
|
|
1414
1414
|
size: "xxs",
|
|
1415
1415
|
class: "dsg-badge--icon-add dsg-badge--icon"
|
|
1416
|
-
})) :
|
|
1417
|
-
|
|
1418
|
-
T("div",
|
|
1419
|
-
|
|
1416
|
+
})) : w("", !0),
|
|
1417
|
+
k.type === "standard" ? M(k.$slots, "dsg-badge--after", { key: 3 }, () => [
|
|
1418
|
+
T("div", Li, [
|
|
1419
|
+
k.iconAfter ? (h(), $(G, {
|
|
1420
1420
|
key: 0,
|
|
1421
|
-
icon:
|
|
1421
|
+
icon: k.iconAfter,
|
|
1422
1422
|
size: "xxs",
|
|
1423
1423
|
class: "dsg-badge--icon-after dsg-badge--icon"
|
|
1424
|
-
}, null, 8, ["icon"])) :
|
|
1425
|
-
|
|
1426
|
-
|
|
1424
|
+
}, null, 8, ["icon"])) : w("", !0),
|
|
1425
|
+
k.hasClose ? (h(), v("span", Ii, [
|
|
1426
|
+
k.hasClose ? (h(), $(G, {
|
|
1427
1427
|
key: 0,
|
|
1428
1428
|
icon: "x-close",
|
|
1429
1429
|
class: "dsg-badge--close",
|
|
1430
1430
|
size: "xxs",
|
|
1431
1431
|
onClick: p
|
|
1432
|
-
})) :
|
|
1433
|
-
])) :
|
|
1432
|
+
})) : w("", !0)
|
|
1433
|
+
])) : w("", !0)
|
|
1434
1434
|
])
|
|
1435
|
-
]) :
|
|
1435
|
+
]) : w("", !0)
|
|
1436
1436
|
], 2));
|
|
1437
1437
|
}
|
|
1438
|
+
}), _i = {
|
|
1439
|
+
key: 0,
|
|
1440
|
+
class: "dsg-checkbox-group--form-wrapper"
|
|
1441
|
+
}, Bi = { class: "dsg-checkbox-group--header" }, Di = { class: "dsg-checkbox-group--header-title-wrapper" }, Pi = { class: "dsg-checkbox-group--title" }, Ni = ["innerHTML"], Mi = { class: "dsg-checkbox-group--options" }, xi = ["onClick"], Ui = { class: "dsg-checkbox-group--panel-left" }, Ri = ["textContent"], zi = ["innerHTML", "data"], Hi = /* @__PURE__ */ H({
|
|
1442
|
+
__name: "DsgCheckboxGroup",
|
|
1443
|
+
props: /* @__PURE__ */ Bo({
|
|
1444
|
+
size: { default: "md" },
|
|
1445
|
+
theme: { default: "form" },
|
|
1446
|
+
title: { default: "" },
|
|
1447
|
+
subtext: { default: "" },
|
|
1448
|
+
options: { default: () => [] },
|
|
1449
|
+
tooltip: { default: null },
|
|
1450
|
+
defaultValue: { type: [String, Number, Boolean, Array, null], default: () => [] }
|
|
1451
|
+
}, {
|
|
1452
|
+
modelValue: { type: [String, Number, Boolean, Array, null], default: [] },
|
|
1453
|
+
modelModifiers: {}
|
|
1454
|
+
}),
|
|
1455
|
+
emits: ["update:modelValue"],
|
|
1456
|
+
setup(e) {
|
|
1457
|
+
const t = Do(e, "modelValue"), o = ["dsg-checkbox-group", `dsg-checkbox-group--${e.size}`, `dsg-checkbox-group--theme-${e.theme}`], i = (s, n) => {
|
|
1458
|
+
s.target instanceof HTMLAnchorElement || (t.value = n.value);
|
|
1459
|
+
};
|
|
1460
|
+
return (s, n) => {
|
|
1461
|
+
const l = cs("key");
|
|
1462
|
+
return h(), v("div", {
|
|
1463
|
+
class: D(o)
|
|
1464
|
+
}, [
|
|
1465
|
+
["form", "form-radio"].includes(s.theme) ? (h(), v("div", _i, [
|
|
1466
|
+
T("div", Bi, [
|
|
1467
|
+
M(s.$slots, "dsg-checkbox-group--header", {}, () => [
|
|
1468
|
+
T("div", Di, [
|
|
1469
|
+
T("h3", Pi, P(s.title), 1),
|
|
1470
|
+
s.tooltip ? (h(), $($o, {
|
|
1471
|
+
key: 0,
|
|
1472
|
+
label: s.tooltip,
|
|
1473
|
+
position: "top",
|
|
1474
|
+
triggers: ["hover"],
|
|
1475
|
+
"auto-hide": !0,
|
|
1476
|
+
theme: "dark",
|
|
1477
|
+
class: "dsg-checkbox-group--tooltip"
|
|
1478
|
+
}, null, 8, ["label"])) : w("", !0)
|
|
1479
|
+
]),
|
|
1480
|
+
s.subtext ? (h(), v("p", {
|
|
1481
|
+
key: 0,
|
|
1482
|
+
class: "dsg-checkbox-group--subtext",
|
|
1483
|
+
innerHTML: s.subtext
|
|
1484
|
+
}, null, 8, Ni)) : w("", !0)
|
|
1485
|
+
])
|
|
1486
|
+
]),
|
|
1487
|
+
T("div", Mi, [
|
|
1488
|
+
(h(!0), v(Z, null, ke(s.options, (a, u) => (h(), v("div", {
|
|
1489
|
+
key: u,
|
|
1490
|
+
class: "dsg-checkbox-group--option"
|
|
1491
|
+
}, [
|
|
1492
|
+
I(yt, {
|
|
1493
|
+
label: a.label,
|
|
1494
|
+
value: a.value,
|
|
1495
|
+
disabled: a.disabled,
|
|
1496
|
+
size: "sm",
|
|
1497
|
+
type: ["form", "panel"].includes(s.theme) ? "checkbox" : "radio",
|
|
1498
|
+
modelValue: t.value,
|
|
1499
|
+
"onUpdate:modelValue": n[0] || (n[0] = (p) => t.value = p)
|
|
1500
|
+
}, null, 8, ["label", "value", "disabled", "type", "modelValue"])
|
|
1501
|
+
]))), 128))
|
|
1502
|
+
])
|
|
1503
|
+
])) : w("", !0),
|
|
1504
|
+
["panel", "panel-content"].includes(s.theme) ? (h(!0), v(Z, { key: 1 }, ke(s.options, (a, u) => Po((h(), v("div", {
|
|
1505
|
+
class: D(["dsg-checkbox-group--panel", `dsg-checkbox-group--panel-${t.value === a.value ? "selected" : "unselected"}`]),
|
|
1506
|
+
onClick: (p) => i(p, a)
|
|
1507
|
+
}, [
|
|
1508
|
+
T("div", Ui, [
|
|
1509
|
+
M(s.$slots, `dsg-checkbox-group--panel-title--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g, "-").replace(/-+/g, "-")}`, { data: a }, () => [
|
|
1510
|
+
a.icon ? (h(), $(G, {
|
|
1511
|
+
key: 0,
|
|
1512
|
+
icon: a.icon,
|
|
1513
|
+
size: "xl"
|
|
1514
|
+
}, null, 8, ["icon"])) : w("", !0),
|
|
1515
|
+
T("h3", {
|
|
1516
|
+
class: "dsg-checkbox-group--panel-title",
|
|
1517
|
+
textContent: P(a.label)
|
|
1518
|
+
}, null, 8, Ri)
|
|
1519
|
+
]),
|
|
1520
|
+
M(s.$slots, `dsg-checkbox-group--panel-subtext--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g, "-").replace(/-+/g, "-")}`, {}, () => [
|
|
1521
|
+
a.subtext ? (h(), v("p", {
|
|
1522
|
+
key: 0,
|
|
1523
|
+
class: "dsg-checkbox-group--panel-subtext",
|
|
1524
|
+
innerHTML: a.subtext,
|
|
1525
|
+
data: a
|
|
1526
|
+
}, null, 8, zi)) : w("", !0)
|
|
1527
|
+
])
|
|
1528
|
+
]),
|
|
1529
|
+
(h(), v("div", {
|
|
1530
|
+
key: u,
|
|
1531
|
+
class: "dsg-checkbox-group--panel-right"
|
|
1532
|
+
}, [
|
|
1533
|
+
I(yt, {
|
|
1534
|
+
value: a.value,
|
|
1535
|
+
disabled: a.disabled,
|
|
1536
|
+
type: "radio",
|
|
1537
|
+
modelValue: t.value,
|
|
1538
|
+
"onUpdate:modelValue": n[1] || (n[1] = (p) => t.value = p)
|
|
1539
|
+
}, null, 8, ["value", "disabled", "modelValue"])
|
|
1540
|
+
]))
|
|
1541
|
+
], 10, xi)), [
|
|
1542
|
+
[l, u]
|
|
1543
|
+
])), 256)) : w("", !0)
|
|
1544
|
+
]);
|
|
1545
|
+
};
|
|
1546
|
+
}
|
|
1438
1547
|
});
|
|
1439
|
-
var
|
|
1440
|
-
var o = {},
|
|
1441
|
-
if (!
|
|
1442
|
-
|
|
1443
|
-
for (var
|
|
1444
|
-
for (var n in t[
|
|
1445
|
-
|
|
1548
|
+
var qi = "2.0.3", Yt = 500, uo = "user-agent", xe = "", co = "?", Ct = "function", ye = "undefined", Ue = "object", Zt = "string", V = "browser", ue = "cpu", ie = "device", Q = "engine", X = "os", De = "result", f = "name", r = "type", c = "vendor", g = "version", j = "architecture", it = "major", d = "model", Ze = "console", E = "mobile", O = "tablet", N = "smarttv", se = "wearable", It = "xr", Je = "embedded", qe = "inapp", so = "brands", Ae = "formFactors", io = "fullVersionList", Pe = "platform", no = "platformVersion", Ot = "bitness", Ee = "sec-ch-ua", Fi = Ee + "-full-version-list", Vi = Ee + "-arch", ji = Ee + "-" + Ot, Ki = Ee + "-form-factors", Gi = Ee + "-" + E, Wi = Ee + "-" + d, Go = Ee + "-" + Pe, Xi = Go + "-version", Wo = [so, io, E, d, Pe, no, j, Ae, Ot], ct = "Amazon", $e = "Apple", fo = "ASUS", go = "BlackBerry", Te = "Google", po = "Huawei", ho = "Lenovo", mo = "Honor", ft = "LG", _t = "Microsoft", Bt = "Motorola", Dt = "Nvidia", bo = "OnePlus", Pt = "OPPO", Fe = "Samsung", vo = "Sharp", Ve = "Sony", Nt = "Xiaomi", Mt = "Zebra", wo = "Chrome", yo = "Chromium", me = "Chromecast", Yi = "Edge", je = "Firefox", Ke = "Opera", xt = "Facebook", ko = "Sogou", Le = "Mobile ", Ge = " Browser", Jt = "Windows", Zi = typeof window !== ye, K = Zi && window.navigator ? window.navigator : void 0, be = K && K.userAgentData ? K.userAgentData : void 0, Ji = function(e, t) {
|
|
1549
|
+
var o = {}, i = t;
|
|
1550
|
+
if (!Et(t)) {
|
|
1551
|
+
i = {};
|
|
1552
|
+
for (var s in t)
|
|
1553
|
+
for (var n in t[s])
|
|
1554
|
+
i[n] = t[s][n].concat(i[n] ? i[n] : []);
|
|
1446
1555
|
}
|
|
1447
1556
|
for (var l in e)
|
|
1448
|
-
o[l] =
|
|
1557
|
+
o[l] = i[l] && i[l].length % 2 === 0 ? i[l].concat(e[l]) : e[l];
|
|
1449
1558
|
return o;
|
|
1450
|
-
},
|
|
1559
|
+
}, $t = function(e) {
|
|
1451
1560
|
for (var t = {}, o = 0; o < e.length; o++)
|
|
1452
1561
|
t[e[o].toUpperCase()] = e[o];
|
|
1453
1562
|
return t;
|
|
1454
|
-
},
|
|
1455
|
-
if (typeof e ===
|
|
1563
|
+
}, Qt = function(e, t) {
|
|
1564
|
+
if (typeof e === Ue && e.length > 0) {
|
|
1456
1565
|
for (var o in e)
|
|
1457
|
-
if (
|
|
1566
|
+
if (ce(e[o]) == ce(t)) return !0;
|
|
1458
1567
|
return !1;
|
|
1459
1568
|
}
|
|
1460
|
-
return ze(e) ?
|
|
1461
|
-
},
|
|
1569
|
+
return ze(e) ? ce(t).indexOf(ce(e)) !== -1 : !1;
|
|
1570
|
+
}, Et = function(e, t) {
|
|
1462
1571
|
for (var o in e)
|
|
1463
|
-
return /^(browser|cpu|device|engine|os)$/.test(o) || (t ?
|
|
1572
|
+
return /^(browser|cpu|device|engine|os)$/.test(o) || (t ? Et(e[o]) : !1);
|
|
1464
1573
|
}, ze = function(e) {
|
|
1465
|
-
return typeof e ===
|
|
1466
|
-
},
|
|
1574
|
+
return typeof e === Zt;
|
|
1575
|
+
}, Ut = function(e) {
|
|
1467
1576
|
if (e) {
|
|
1468
|
-
for (var t = [], o =
|
|
1469
|
-
if (o[
|
|
1470
|
-
var
|
|
1471
|
-
t[
|
|
1577
|
+
for (var t = [], o = Re(/\\?\"/g, e).split(","), i = 0; i < o.length; i++)
|
|
1578
|
+
if (o[i].indexOf(";") > -1) {
|
|
1579
|
+
var s = nt(o[i]).split(";v=");
|
|
1580
|
+
t[i] = { brand: s[0], version: s[1] };
|
|
1472
1581
|
} else
|
|
1473
|
-
t[
|
|
1582
|
+
t[i] = nt(o[i]);
|
|
1474
1583
|
return t;
|
|
1475
1584
|
}
|
|
1476
|
-
},
|
|
1585
|
+
}, ce = function(e) {
|
|
1477
1586
|
return ze(e) ? e.toLowerCase() : e;
|
|
1478
1587
|
}, Rt = function(e) {
|
|
1479
|
-
return ze(e) ?
|
|
1480
|
-
},
|
|
1588
|
+
return ze(e) ? Re(/[^\d\.]/g, e).split(".")[0] : void 0;
|
|
1589
|
+
}, fe = function(e) {
|
|
1481
1590
|
for (var t in e) {
|
|
1482
1591
|
var o = e[t];
|
|
1483
|
-
typeof o ==
|
|
1592
|
+
typeof o == Ue && o.length == 2 ? this[o[0]] = o[1] : this[o] = void 0;
|
|
1484
1593
|
}
|
|
1485
1594
|
return this;
|
|
1486
|
-
},
|
|
1595
|
+
}, Re = function(e, t) {
|
|
1487
1596
|
return ze(t) ? t.replace(e, xe) : t;
|
|
1488
1597
|
}, We = function(e) {
|
|
1489
|
-
return
|
|
1598
|
+
return Re(/\\?\"/g, e);
|
|
1490
1599
|
}, nt = function(e, t) {
|
|
1491
1600
|
if (ze(e))
|
|
1492
|
-
return e =
|
|
1493
|
-
},
|
|
1601
|
+
return e = Re(/^\s\s*/, e), typeof t === ye ? e : e.substring(0, Yt);
|
|
1602
|
+
}, zt = function(e, t) {
|
|
1494
1603
|
if (!(!e || !t))
|
|
1495
|
-
for (var o = 0,
|
|
1496
|
-
var p = t[o],
|
|
1497
|
-
for (
|
|
1498
|
-
if (a = p[
|
|
1499
|
-
for (n = 0; n <
|
|
1500
|
-
|
|
1604
|
+
for (var o = 0, i, s, n, l, a, u; o < t.length && !a; ) {
|
|
1605
|
+
var p = t[o], y = t[o + 1];
|
|
1606
|
+
for (i = s = 0; i < p.length && !a && p[i]; )
|
|
1607
|
+
if (a = p[i++].exec(e), a)
|
|
1608
|
+
for (n = 0; n < y.length; n++)
|
|
1609
|
+
u = a[++s], l = y[n], typeof l === Ue && l.length > 0 ? l.length === 2 ? typeof l[1] == Ct ? this[l[0]] = l[1].call(this, u) : this[l[0]] = l[1] : l.length === 3 ? typeof l[1] === Ct && !(l[1].exec && l[1].test) ? this[l[0]] = u ? l[1].call(this, u, l[2]) : void 0 : this[l[0]] = u ? u.replace(l[1], l[2]) : void 0 : l.length === 4 && (this[l[0]] = u ? l[3].call(this, u.replace(l[1], l[2])) : void 0) : this[l] = u || void 0;
|
|
1501
1610
|
o += 2;
|
|
1502
1611
|
}
|
|
1503
1612
|
}, ve = function(e, t) {
|
|
1504
1613
|
for (var o in t)
|
|
1505
|
-
if (typeof t[o] ===
|
|
1506
|
-
for (var
|
|
1507
|
-
if (
|
|
1508
|
-
return o ===
|
|
1509
|
-
} else if (
|
|
1510
|
-
return o ===
|
|
1614
|
+
if (typeof t[o] === Ue && t[o].length > 0) {
|
|
1615
|
+
for (var i = 0; i < t[o].length; i++)
|
|
1616
|
+
if (Qt(t[o][i], e))
|
|
1617
|
+
return o === co ? void 0 : o;
|
|
1618
|
+
} else if (Qt(t[o], e))
|
|
1619
|
+
return o === co ? void 0 : o;
|
|
1511
1620
|
return t.hasOwnProperty("*") ? t["*"] : e;
|
|
1512
1621
|
}, Co = {
|
|
1513
1622
|
ME: "4.90",
|
|
@@ -1521,7 +1630,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1521
1630
|
"8.1": "NT 6.3",
|
|
1522
1631
|
10: ["NT 6.4", "NT 10.0"],
|
|
1523
1632
|
RT: "ARM"
|
|
1524
|
-
},
|
|
1633
|
+
}, Eo = {
|
|
1525
1634
|
embedded: "Automotive",
|
|
1526
1635
|
mobile: "Mobile",
|
|
1527
1636
|
tablet: ["Tablet", "EInk"],
|
|
@@ -1530,14 +1639,14 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1530
1639
|
xr: ["VR", "XR"],
|
|
1531
1640
|
"?": ["Desktop", "Unknown"],
|
|
1532
1641
|
"*": void 0
|
|
1533
|
-
},
|
|
1642
|
+
}, To = {
|
|
1534
1643
|
browser: [
|
|
1535
1644
|
[
|
|
1536
1645
|
// Most common regardless engine
|
|
1537
1646
|
/\b(?:crmo|crios)\/([\w\.]+)/i
|
|
1538
1647
|
// Chrome for Android/iOS
|
|
1539
1648
|
],
|
|
1540
|
-
[g, [f,
|
|
1649
|
+
[g, [f, Le + "Chrome"]],
|
|
1541
1650
|
[
|
|
1542
1651
|
/edg(?:e|ios|a)?\/([\w\.]+)/i
|
|
1543
1652
|
// Microsoft Edge
|
|
@@ -1640,7 +1749,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1640
1749
|
/slbrowser\/([\w\.]+)/i
|
|
1641
1750
|
// Smart Lenovo Browser
|
|
1642
1751
|
],
|
|
1643
|
-
[g, [f, "Smart " +
|
|
1752
|
+
[g, [f, "Smart " + ho + Ge]],
|
|
1644
1753
|
[
|
|
1645
1754
|
/(avast|avg)\/([\w\.]+)/i
|
|
1646
1755
|
// Avast/AVG Secure Browser
|
|
@@ -1650,7 +1759,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1650
1759
|
/\bfocus\/([\w\.]+)/i
|
|
1651
1760
|
// Firefox Focus
|
|
1652
1761
|
],
|
|
1653
|
-
[g, [f,
|
|
1762
|
+
[g, [f, je + " Focus"]],
|
|
1654
1763
|
[
|
|
1655
1764
|
/\bopt\/([\w\.]+)/i
|
|
1656
1765
|
// Opera Touch
|
|
@@ -1680,7 +1789,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1680
1789
|
/fxios\/([\w\.-]+)/i
|
|
1681
1790
|
// Firefox for iOS
|
|
1682
1791
|
],
|
|
1683
|
-
[g, [f,
|
|
1792
|
+
[g, [f, Le + je]],
|
|
1684
1793
|
[
|
|
1685
1794
|
/\bqihoobrowser\/?([\w\.]*)/i
|
|
1686
1795
|
// 360
|
|
@@ -1705,12 +1814,12 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1705
1814
|
/metasr[\/ ]?([\d\.]+)/i
|
|
1706
1815
|
// Sogou Explorer
|
|
1707
1816
|
],
|
|
1708
|
-
[g, [f,
|
|
1817
|
+
[g, [f, ko + " Explorer"]],
|
|
1709
1818
|
[
|
|
1710
1819
|
/(sogou)mo\w+\/([\d\.]+)/i
|
|
1711
1820
|
// Sogou Mobile
|
|
1712
1821
|
],
|
|
1713
|
-
[[f,
|
|
1822
|
+
[[f, ko + " Mobile"], g],
|
|
1714
1823
|
[
|
|
1715
1824
|
/(electron)\/([\w\.]+) safari/i,
|
|
1716
1825
|
// Electron-based App
|
|
@@ -1737,7 +1846,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1737
1846
|
/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i
|
|
1738
1847
|
// Facebook App for iOS & Android
|
|
1739
1848
|
],
|
|
1740
|
-
[[f,
|
|
1849
|
+
[[f, xt], g, [r, qe]],
|
|
1741
1850
|
[
|
|
1742
1851
|
/(Klarna)\/([\w\.]+)/i,
|
|
1743
1852
|
// Klarna Shopping Browser for iOS & Android
|
|
@@ -1783,12 +1892,12 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1783
1892
|
/headlesschrome(?:\/([\w\.]+)| )/i
|
|
1784
1893
|
// Chrome Headless
|
|
1785
1894
|
],
|
|
1786
|
-
[g, [f,
|
|
1895
|
+
[g, [f, wo + " Headless"]],
|
|
1787
1896
|
[
|
|
1788
1897
|
/ wv\).+(chrome)\/([\w\.]+)/i
|
|
1789
1898
|
// Chrome WebView
|
|
1790
1899
|
],
|
|
1791
|
-
[[f,
|
|
1900
|
+
[[f, wo + " WebView"], g],
|
|
1792
1901
|
[
|
|
1793
1902
|
/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i
|
|
1794
1903
|
// Android Browser
|
|
@@ -1798,7 +1907,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1798
1907
|
/chrome\/([\w\.]+) mobile/i
|
|
1799
1908
|
// Chrome Mobile
|
|
1800
1909
|
],
|
|
1801
|
-
[g, [f,
|
|
1910
|
+
[g, [f, Le + "Chrome"]],
|
|
1802
1911
|
[
|
|
1803
1912
|
/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i
|
|
1804
1913
|
// Chrome/OmniWeb/Arora/Tizen/Nokia
|
|
@@ -1808,11 +1917,11 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1808
1917
|
/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i
|
|
1809
1918
|
// Safari Mobile
|
|
1810
1919
|
],
|
|
1811
|
-
[g, [f,
|
|
1920
|
+
[g, [f, Le + "Safari"]],
|
|
1812
1921
|
[
|
|
1813
1922
|
/iphone .*mobile(?:\/\w+ | ?)safari/i
|
|
1814
1923
|
],
|
|
1815
|
-
[[f,
|
|
1924
|
+
[[f, Le + "Safari"]],
|
|
1816
1925
|
[
|
|
1817
1926
|
/version\/([\w\.\,]+) .*(safari)/i
|
|
1818
1927
|
// Safari
|
|
@@ -1832,7 +1941,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1832
1941
|
/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i
|
|
1833
1942
|
// Firefox Mobile
|
|
1834
1943
|
],
|
|
1835
|
-
[[f,
|
|
1944
|
+
[[f, Le + je], g],
|
|
1836
1945
|
[
|
|
1837
1946
|
/(navigator|netscape\d?)\/([-\w\.]+)/i
|
|
1838
1947
|
// Netscape
|
|
@@ -1847,7 +1956,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1847
1956
|
/mobile vr; rv:([\w\.]+)\).+firefox/i
|
|
1848
1957
|
// Firefox Reality
|
|
1849
1958
|
],
|
|
1850
|
-
[g, [f,
|
|
1959
|
+
[g, [f, je + " Reality"]],
|
|
1851
1960
|
[
|
|
1852
1961
|
/ekiohf.+(flow)\/([\w\.]+)/i,
|
|
1853
1962
|
// Flow
|
|
@@ -1879,44 +1988,44 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1879
1988
|
/\b((amd|x|x86[-_]?|wow|win)64)\b/i
|
|
1880
1989
|
// AMD64 (x64)
|
|
1881
1990
|
],
|
|
1882
|
-
[[
|
|
1991
|
+
[[j, "amd64"]],
|
|
1883
1992
|
[
|
|
1884
1993
|
/(ia32(?=;))/i,
|
|
1885
1994
|
// IA32 (quicktime)
|
|
1886
1995
|
/\b((i[346]|x)86)(pc)?\b/i
|
|
1887
1996
|
// IA32 (x86)
|
|
1888
1997
|
],
|
|
1889
|
-
[[
|
|
1998
|
+
[[j, "ia32"]],
|
|
1890
1999
|
[
|
|
1891
2000
|
/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i
|
|
1892
2001
|
// ARM64
|
|
1893
2002
|
],
|
|
1894
|
-
[[
|
|
2003
|
+
[[j, "arm64"]],
|
|
1895
2004
|
[
|
|
1896
2005
|
/\b(arm(v[67])?ht?n?[fl]p?)\b/i
|
|
1897
2006
|
// ARMHF
|
|
1898
2007
|
],
|
|
1899
|
-
[[
|
|
2008
|
+
[[j, "armhf"]],
|
|
1900
2009
|
[
|
|
1901
2010
|
// PocketPC mistakenly identified as PowerPC
|
|
1902
2011
|
/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i
|
|
1903
2012
|
],
|
|
1904
|
-
[[
|
|
2013
|
+
[[j, "arm"]],
|
|
1905
2014
|
[
|
|
1906
2015
|
/((ppc|powerpc)(64)?)( mac|;|\))/i
|
|
1907
2016
|
// PowerPC
|
|
1908
2017
|
],
|
|
1909
|
-
[[
|
|
2018
|
+
[[j, /ower/, xe, ce]],
|
|
1910
2019
|
[
|
|
1911
2020
|
/ sun4\w[;\)]/i
|
|
1912
2021
|
// SPARC
|
|
1913
2022
|
],
|
|
1914
|
-
[[
|
|
2023
|
+
[[j, "sparc"]],
|
|
1915
2024
|
[
|
|
1916
2025
|
/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i
|
|
1917
2026
|
// IA64, 68K, ARM/64, AVR/32, IRIX/64, MIPS/64, SPARC/64, PA-RISC
|
|
1918
2027
|
],
|
|
1919
|
-
[[
|
|
2028
|
+
[[j, ce]]
|
|
1920
2029
|
],
|
|
1921
2030
|
device: [
|
|
1922
2031
|
[
|
|
@@ -1926,61 +2035,61 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1926
2035
|
// Samsung
|
|
1927
2036
|
/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i
|
|
1928
2037
|
],
|
|
1929
|
-
[d, [
|
|
2038
|
+
[d, [c, Fe], [r, O]],
|
|
1930
2039
|
[
|
|
1931
2040
|
/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,
|
|
1932
2041
|
/samsung[- ]((?!sm-[lr])[-\w]+)/i,
|
|
1933
2042
|
/sec-(sgh\w+)/i
|
|
1934
2043
|
],
|
|
1935
|
-
[d, [
|
|
2044
|
+
[d, [c, Fe], [r, E]],
|
|
1936
2045
|
[
|
|
1937
2046
|
// Apple
|
|
1938
2047
|
/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i
|
|
1939
2048
|
// iPod/iPhone
|
|
1940
2049
|
],
|
|
1941
|
-
[d, [
|
|
2050
|
+
[d, [c, $e], [r, E]],
|
|
1942
2051
|
[
|
|
1943
2052
|
/\((ipad);[-\w\),; ]+apple/i,
|
|
1944
2053
|
// iPad
|
|
1945
2054
|
/applecoremedia\/[\w\.]+ \((ipad)/i,
|
|
1946
2055
|
/\b(ipad)\d\d?,\d\d?[;\]].+ios/i
|
|
1947
2056
|
],
|
|
1948
|
-
[d, [
|
|
2057
|
+
[d, [c, $e], [r, O]],
|
|
1949
2058
|
[
|
|
1950
2059
|
/(macintosh);/i
|
|
1951
2060
|
],
|
|
1952
|
-
[d, [
|
|
2061
|
+
[d, [c, $e]],
|
|
1953
2062
|
[
|
|
1954
2063
|
// Sharp
|
|
1955
2064
|
/\b(sh-?[altvz]?\d\d[a-ekm]?)/i
|
|
1956
2065
|
],
|
|
1957
|
-
[d, [
|
|
2066
|
+
[d, [c, vo], [r, E]],
|
|
1958
2067
|
[
|
|
1959
2068
|
// Honor
|
|
1960
2069
|
/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i
|
|
1961
2070
|
],
|
|
1962
|
-
[d, [
|
|
2071
|
+
[d, [c, mo], [r, O]],
|
|
1963
2072
|
[
|
|
1964
2073
|
/honor([-\w ]+)[;\)]/i
|
|
1965
2074
|
],
|
|
1966
|
-
[d, [
|
|
2075
|
+
[d, [c, mo], [r, E]],
|
|
1967
2076
|
[
|
|
1968
2077
|
// Huawei
|
|
1969
2078
|
/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i
|
|
1970
2079
|
],
|
|
1971
|
-
[d, [
|
|
2080
|
+
[d, [c, po], [r, O]],
|
|
1972
2081
|
[
|
|
1973
2082
|
/(?:huawei)([-\w ]+)[;\)]/i,
|
|
1974
2083
|
/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i
|
|
1975
2084
|
],
|
|
1976
|
-
[d, [
|
|
2085
|
+
[d, [c, po], [r, E]],
|
|
1977
2086
|
[
|
|
1978
2087
|
// Xiaomi
|
|
1979
2088
|
/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,
|
|
1980
2089
|
/\b((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i
|
|
1981
2090
|
// Mi Pad tablets
|
|
1982
2091
|
],
|
|
1983
|
-
[[d, /_/g, " "], [
|
|
2092
|
+
[[d, /_/g, " "], [c, Nt], [r, O]],
|
|
1984
2093
|
[
|
|
1985
2094
|
/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,
|
|
1986
2095
|
// Xiaomi POCO
|
|
@@ -1996,98 +2105,98 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
1996
2105
|
// Xiaomi Mi
|
|
1997
2106
|
/ ([\w ]+) miui\/v?\d/i
|
|
1998
2107
|
],
|
|
1999
|
-
[[d, /_/g, " "], [
|
|
2108
|
+
[[d, /_/g, " "], [c, Nt], [r, E]],
|
|
2000
2109
|
[
|
|
2001
2110
|
// OPPO
|
|
2002
2111
|
/; (\w+) bui.+ oppo/i,
|
|
2003
2112
|
/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i
|
|
2004
2113
|
],
|
|
2005
|
-
[d, [
|
|
2114
|
+
[d, [c, Pt], [r, E]],
|
|
2006
2115
|
[
|
|
2007
2116
|
/\b(opd2(\d{3}a?))(?: bui|\))/i
|
|
2008
2117
|
],
|
|
2009
|
-
[d, [
|
|
2118
|
+
[d, [c, ve, { OnePlus: ["304", "403", "203"], "*": Pt }], [r, O]],
|
|
2010
2119
|
[
|
|
2011
2120
|
// BLU Vivo Series
|
|
2012
2121
|
/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i
|
|
2013
2122
|
],
|
|
2014
|
-
[d, [
|
|
2123
|
+
[d, [c, "BLU"], [r, E]],
|
|
2015
2124
|
[
|
|
2016
2125
|
// Vivo
|
|
2017
2126
|
/; vivo (\w+)(?: bui|\))/i,
|
|
2018
2127
|
/\b(v[12]\d{3}\w?[at])(?: bui|;)/i
|
|
2019
2128
|
],
|
|
2020
|
-
[d, [
|
|
2129
|
+
[d, [c, "Vivo"], [r, E]],
|
|
2021
2130
|
[
|
|
2022
2131
|
// Realme
|
|
2023
2132
|
/\b(rmx[1-3]\d{3})(?: bui|;|\))/i
|
|
2024
2133
|
],
|
|
2025
|
-
[d, [
|
|
2134
|
+
[d, [c, "Realme"], [r, E]],
|
|
2026
2135
|
[
|
|
2027
2136
|
// Motorola
|
|
2028
2137
|
/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,
|
|
2029
2138
|
/\bmot(?:orola)?[- ](\w*)/i,
|
|
2030
2139
|
/((?:moto(?! 360)[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i
|
|
2031
2140
|
],
|
|
2032
|
-
[d, [
|
|
2141
|
+
[d, [c, Bt], [r, E]],
|
|
2033
2142
|
[
|
|
2034
2143
|
/\b(mz60\d|xoom[2 ]{0,2}) build\//i
|
|
2035
2144
|
],
|
|
2036
|
-
[d, [
|
|
2145
|
+
[d, [c, Bt], [r, O]],
|
|
2037
2146
|
[
|
|
2038
2147
|
// LG
|
|
2039
2148
|
/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i
|
|
2040
2149
|
],
|
|
2041
|
-
[d, [
|
|
2150
|
+
[d, [c, ft], [r, O]],
|
|
2042
2151
|
[
|
|
2043
2152
|
/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,
|
|
2044
2153
|
/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch))(\w+)/i,
|
|
2045
2154
|
/\blg-?([\d\w]+) bui/i
|
|
2046
2155
|
],
|
|
2047
|
-
[d, [
|
|
2156
|
+
[d, [c, ft], [r, E]],
|
|
2048
2157
|
[
|
|
2049
2158
|
// Lenovo
|
|
2050
2159
|
/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,
|
|
2051
2160
|
/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i
|
|
2052
2161
|
],
|
|
2053
|
-
[d, [
|
|
2162
|
+
[d, [c, ho], [r, O]],
|
|
2054
2163
|
[
|
|
2055
2164
|
// Nokia
|
|
2056
2165
|
/(nokia) (t[12][01])/i
|
|
2057
2166
|
],
|
|
2058
|
-
[
|
|
2167
|
+
[c, d, [r, O]],
|
|
2059
2168
|
[
|
|
2060
2169
|
/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,
|
|
2061
2170
|
/nokia[-_ ]?(([-\w\. ]*))/i
|
|
2062
2171
|
],
|
|
2063
|
-
[[d, /_/g, " "], [r, E], [
|
|
2172
|
+
[[d, /_/g, " "], [r, E], [c, "Nokia"]],
|
|
2064
2173
|
[
|
|
2065
2174
|
// Google
|
|
2066
2175
|
/(pixel (c|tablet))\b/i
|
|
2067
2176
|
// Google Pixel C/Tablet
|
|
2068
2177
|
],
|
|
2069
|
-
[d, [
|
|
2178
|
+
[d, [c, Te], [r, O]],
|
|
2070
2179
|
[
|
|
2071
2180
|
/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i
|
|
2072
2181
|
// Google Pixel
|
|
2073
2182
|
],
|
|
2074
|
-
[d, [
|
|
2183
|
+
[d, [c, Te], [r, E]],
|
|
2075
2184
|
[
|
|
2076
2185
|
// Sony
|
|
2077
2186
|
/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i
|
|
2078
2187
|
],
|
|
2079
|
-
[d, [
|
|
2188
|
+
[d, [c, Ve], [r, E]],
|
|
2080
2189
|
[
|
|
2081
2190
|
/sony tablet [ps]/i,
|
|
2082
2191
|
/\b(?:sony)?sgp\w+(?: bui|\))/i
|
|
2083
2192
|
],
|
|
2084
|
-
[[d, "Xperia Tablet"], [
|
|
2193
|
+
[[d, "Xperia Tablet"], [c, Ve], [r, O]],
|
|
2085
2194
|
[
|
|
2086
2195
|
// OnePlus
|
|
2087
2196
|
/ (kb2005|in20[12]5|be20[12][59])\b/i,
|
|
2088
2197
|
/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i
|
|
2089
2198
|
],
|
|
2090
|
-
[d, [
|
|
2199
|
+
[d, [c, bo], [r, E]],
|
|
2091
2200
|
[
|
|
2092
2201
|
// Amazon
|
|
2093
2202
|
/(alexa)webm/i,
|
|
@@ -2096,39 +2205,39 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2096
2205
|
/(kf[a-z]+)( bui|\)).+silk\//i
|
|
2097
2206
|
// Kindle Fire HD
|
|
2098
2207
|
],
|
|
2099
|
-
[d, [
|
|
2208
|
+
[d, [c, ct], [r, O]],
|
|
2100
2209
|
[
|
|
2101
2210
|
/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i
|
|
2102
2211
|
// Fire Phone
|
|
2103
2212
|
],
|
|
2104
|
-
[[d, /(.+)/g, "Fire Phone $1"], [
|
|
2213
|
+
[[d, /(.+)/g, "Fire Phone $1"], [c, ct], [r, E]],
|
|
2105
2214
|
[
|
|
2106
2215
|
// BlackBerry
|
|
2107
2216
|
/(playbook);[-\w\),; ]+(rim)/i
|
|
2108
2217
|
// BlackBerry PlayBook
|
|
2109
2218
|
],
|
|
2110
|
-
[d,
|
|
2219
|
+
[d, c, [r, O]],
|
|
2111
2220
|
[
|
|
2112
2221
|
/\b((?:bb[a-f]|st[hv])100-\d)/i,
|
|
2113
2222
|
/\(bb10; (\w+)/i
|
|
2114
2223
|
// BlackBerry 10
|
|
2115
2224
|
],
|
|
2116
|
-
[d, [
|
|
2225
|
+
[d, [c, go], [r, E]],
|
|
2117
2226
|
[
|
|
2118
2227
|
// Asus
|
|
2119
2228
|
/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i
|
|
2120
2229
|
],
|
|
2121
|
-
[d, [
|
|
2230
|
+
[d, [c, fo], [r, O]],
|
|
2122
2231
|
[
|
|
2123
2232
|
/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i
|
|
2124
2233
|
],
|
|
2125
|
-
[d, [
|
|
2234
|
+
[d, [c, fo], [r, E]],
|
|
2126
2235
|
[
|
|
2127
2236
|
// HTC
|
|
2128
2237
|
/(nexus 9)/i
|
|
2129
2238
|
// HTC Nexus 9
|
|
2130
2239
|
],
|
|
2131
|
-
[d, [
|
|
2240
|
+
[d, [c, "HTC"], [r, O]],
|
|
2132
2241
|
[
|
|
2133
2242
|
/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,
|
|
2134
2243
|
// HTC
|
|
@@ -2137,71 +2246,71 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2137
2246
|
/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i
|
|
2138
2247
|
// Alcatel/GeeksPhone/Nexian/Panasonic/Sony
|
|
2139
2248
|
],
|
|
2140
|
-
[
|
|
2249
|
+
[c, [d, /_/g, " "], [r, E]],
|
|
2141
2250
|
[
|
|
2142
2251
|
// TCL
|
|
2143
2252
|
/tcl (xess p17aa)/i,
|
|
2144
2253
|
/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i
|
|
2145
2254
|
],
|
|
2146
|
-
[d, [
|
|
2255
|
+
[d, [c, "TCL"], [r, O]],
|
|
2147
2256
|
[
|
|
2148
2257
|
/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i
|
|
2149
2258
|
],
|
|
2150
|
-
[d, [
|
|
2259
|
+
[d, [c, "TCL"], [r, E]],
|
|
2151
2260
|
[
|
|
2152
2261
|
// itel
|
|
2153
2262
|
/(itel) ((\w+))/i
|
|
2154
2263
|
],
|
|
2155
|
-
[[
|
|
2264
|
+
[[c, ce], d, [r, ve, { tablet: ["p10001l", "w7001"], "*": "mobile" }]],
|
|
2156
2265
|
[
|
|
2157
2266
|
// Acer
|
|
2158
2267
|
/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i
|
|
2159
2268
|
],
|
|
2160
|
-
[d, [
|
|
2269
|
+
[d, [c, "Acer"], [r, O]],
|
|
2161
2270
|
[
|
|
2162
2271
|
// Meizu
|
|
2163
2272
|
/droid.+; (m[1-5] note) bui/i,
|
|
2164
2273
|
/\bmz-([-\w]{2,})/i
|
|
2165
2274
|
],
|
|
2166
|
-
[d, [
|
|
2275
|
+
[d, [c, "Meizu"], [r, E]],
|
|
2167
2276
|
[
|
|
2168
2277
|
// Ulefone
|
|
2169
2278
|
/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i
|
|
2170
2279
|
],
|
|
2171
|
-
[d, [
|
|
2280
|
+
[d, [c, "Ulefone"], [r, E]],
|
|
2172
2281
|
[
|
|
2173
2282
|
// Energizer
|
|
2174
2283
|
/; (energy ?\w+)(?: bui|\))/i,
|
|
2175
2284
|
/; energizer ([\w ]+)(?: bui|\))/i
|
|
2176
2285
|
],
|
|
2177
|
-
[d, [
|
|
2286
|
+
[d, [c, "Energizer"], [r, E]],
|
|
2178
2287
|
[
|
|
2179
2288
|
// Cat
|
|
2180
2289
|
/; cat (b35);/i,
|
|
2181
2290
|
/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i
|
|
2182
2291
|
],
|
|
2183
|
-
[d, [
|
|
2292
|
+
[d, [c, "Cat"], [r, E]],
|
|
2184
2293
|
[
|
|
2185
2294
|
// Smartfren
|
|
2186
2295
|
/((?:new )?andromax[\w- ]+)(?: bui|\))/i
|
|
2187
2296
|
],
|
|
2188
|
-
[d, [
|
|
2297
|
+
[d, [c, "Smartfren"], [r, E]],
|
|
2189
2298
|
[
|
|
2190
2299
|
// Nothing
|
|
2191
2300
|
/droid.+; (a(?:015|06[35]|142p?))/i
|
|
2192
2301
|
],
|
|
2193
|
-
[d, [
|
|
2302
|
+
[d, [c, "Nothing"], [r, E]],
|
|
2194
2303
|
[
|
|
2195
2304
|
// Archos
|
|
2196
2305
|
/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,
|
|
2197
2306
|
/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i
|
|
2198
2307
|
],
|
|
2199
|
-
[d, [
|
|
2308
|
+
[d, [c, "Archos"], [r, O]],
|
|
2200
2309
|
[
|
|
2201
2310
|
/archos ([\w ]+)( b|\))/i,
|
|
2202
2311
|
/; (ac[3-6]\d\w{2,8})( b|\))/i
|
|
2203
2312
|
],
|
|
2204
|
-
[d, [
|
|
2313
|
+
[d, [c, "Archos"], [r, E]],
|
|
2205
2314
|
[
|
|
2206
2315
|
// MIXED
|
|
2207
2316
|
/(imo) (tab \w+)/i,
|
|
@@ -2209,7 +2318,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2209
2318
|
/(infinix) (x1101b?)/i
|
|
2210
2319
|
// Infinix XPad
|
|
2211
2320
|
],
|
|
2212
|
-
[
|
|
2321
|
+
[c, d, [r, O]],
|
|
2213
2322
|
[
|
|
2214
2323
|
/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,
|
|
2215
2324
|
// BlackBerry/BenQ/Palm/Sony-Ericsson/Acer/Asus/Dell/Meizu/Motorola/Polytron/Infinix/Tecno/Micromax/Advan
|
|
@@ -2224,7 +2333,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2224
2333
|
/(oppo) ?([\w ]+) bui/i
|
|
2225
2334
|
// OPPO
|
|
2226
2335
|
],
|
|
2227
|
-
[
|
|
2336
|
+
[c, d, [r, E]],
|
|
2228
2337
|
[
|
|
2229
2338
|
/(kobo)\s(ereader|touch)/i,
|
|
2230
2339
|
// Kobo
|
|
@@ -2233,41 +2342,41 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2233
2342
|
/(kindle)\/([\w\.]+)/i
|
|
2234
2343
|
// Kindle
|
|
2235
2344
|
],
|
|
2236
|
-
[
|
|
2345
|
+
[c, d, [r, O]],
|
|
2237
2346
|
[
|
|
2238
2347
|
/(surface duo)/i
|
|
2239
2348
|
// Surface Duo
|
|
2240
2349
|
],
|
|
2241
|
-
[d, [
|
|
2350
|
+
[d, [c, _t], [r, O]],
|
|
2242
2351
|
[
|
|
2243
2352
|
/droid [\d\.]+; (fp\du?)(?: b|\))/i
|
|
2244
2353
|
// Fairphone
|
|
2245
2354
|
],
|
|
2246
|
-
[d, [
|
|
2355
|
+
[d, [c, "Fairphone"], [r, E]],
|
|
2247
2356
|
[
|
|
2248
2357
|
/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i
|
|
2249
2358
|
// Nvidia Tablets
|
|
2250
2359
|
],
|
|
2251
|
-
[d, [
|
|
2360
|
+
[d, [c, Dt], [r, O]],
|
|
2252
2361
|
[
|
|
2253
2362
|
/(sprint) (\w+)/i
|
|
2254
2363
|
// Sprint Phones
|
|
2255
2364
|
],
|
|
2256
|
-
[
|
|
2365
|
+
[c, d, [r, E]],
|
|
2257
2366
|
[
|
|
2258
2367
|
/(kin\.[onetw]{3})/i
|
|
2259
2368
|
// Microsoft Kin
|
|
2260
2369
|
],
|
|
2261
|
-
[[d, /\./g, " "], [
|
|
2370
|
+
[[d, /\./g, " "], [c, _t], [r, E]],
|
|
2262
2371
|
[
|
|
2263
2372
|
/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i
|
|
2264
2373
|
// Zebra
|
|
2265
2374
|
],
|
|
2266
|
-
[d, [
|
|
2375
|
+
[d, [c, Mt], [r, O]],
|
|
2267
2376
|
[
|
|
2268
2377
|
/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i
|
|
2269
2378
|
],
|
|
2270
|
-
[d, [
|
|
2379
|
+
[d, [c, Mt], [r, E]],
|
|
2271
2380
|
[
|
|
2272
2381
|
///////////////////
|
|
2273
2382
|
// SMARTTVS
|
|
@@ -2275,97 +2384,97 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2275
2384
|
/smart-tv.+(samsung)/i
|
|
2276
2385
|
// Samsung
|
|
2277
2386
|
],
|
|
2278
|
-
[
|
|
2387
|
+
[c, [r, N]],
|
|
2279
2388
|
[
|
|
2280
2389
|
/hbbtv.+maple;(\d+)/i
|
|
2281
2390
|
],
|
|
2282
|
-
[[d, /^/, "SmartTV"], [
|
|
2391
|
+
[[d, /^/, "SmartTV"], [c, Fe], [r, N]],
|
|
2283
2392
|
[
|
|
2284
2393
|
/tcast.+(lg)e?. ([-\w]+)/i
|
|
2285
2394
|
// LG SmartTV
|
|
2286
2395
|
],
|
|
2287
|
-
[
|
|
2396
|
+
[c, d, [r, N]],
|
|
2288
2397
|
[
|
|
2289
2398
|
/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i
|
|
2290
2399
|
],
|
|
2291
|
-
[[
|
|
2400
|
+
[[c, ft], [r, N]],
|
|
2292
2401
|
[
|
|
2293
2402
|
/(apple) ?tv/i
|
|
2294
2403
|
// Apple TV
|
|
2295
2404
|
],
|
|
2296
|
-
[
|
|
2405
|
+
[c, [d, $e + " TV"], [r, N]],
|
|
2297
2406
|
[
|
|
2298
2407
|
/crkey.*devicetype\/chromecast/i
|
|
2299
2408
|
// Google Chromecast Third Generation
|
|
2300
2409
|
],
|
|
2301
|
-
[[d, me + " Third Generation"], [
|
|
2410
|
+
[[d, me + " Third Generation"], [c, Te], [r, N]],
|
|
2302
2411
|
[
|
|
2303
2412
|
/crkey.*devicetype\/([^/]*)/i
|
|
2304
2413
|
// Google Chromecast with specific device type
|
|
2305
2414
|
],
|
|
2306
|
-
[[d, /^/, "Chromecast "], [
|
|
2415
|
+
[[d, /^/, "Chromecast "], [c, Te], [r, N]],
|
|
2307
2416
|
[
|
|
2308
2417
|
/fuchsia.*crkey/i
|
|
2309
2418
|
// Google Chromecast Nest Hub
|
|
2310
2419
|
],
|
|
2311
|
-
[[d, me + " Nest Hub"], [
|
|
2420
|
+
[[d, me + " Nest Hub"], [c, Te], [r, N]],
|
|
2312
2421
|
[
|
|
2313
2422
|
/crkey/i
|
|
2314
2423
|
// Google Chromecast, Linux-based or unknown
|
|
2315
2424
|
],
|
|
2316
|
-
[[d, me], [
|
|
2425
|
+
[[d, me], [c, Te], [r, N]],
|
|
2317
2426
|
[
|
|
2318
2427
|
/(portaltv)/i
|
|
2319
2428
|
// Facebook Portal TV
|
|
2320
2429
|
],
|
|
2321
|
-
[d, [
|
|
2430
|
+
[d, [c, xt], [r, N]],
|
|
2322
2431
|
[
|
|
2323
2432
|
/droid.+aft(\w+)( bui|\))/i
|
|
2324
2433
|
// Fire TV
|
|
2325
2434
|
],
|
|
2326
|
-
[d, [
|
|
2435
|
+
[d, [c, ct], [r, N]],
|
|
2327
2436
|
[
|
|
2328
2437
|
/(shield \w+ tv)/i
|
|
2329
2438
|
// Nvidia Shield TV
|
|
2330
2439
|
],
|
|
2331
|
-
[d, [
|
|
2440
|
+
[d, [c, Dt], [r, N]],
|
|
2332
2441
|
[
|
|
2333
2442
|
/\(dtv[\);].+(aquos)/i,
|
|
2334
2443
|
/(aquos-tv[\w ]+)\)/i
|
|
2335
2444
|
// Sharp
|
|
2336
2445
|
],
|
|
2337
|
-
[d, [
|
|
2446
|
+
[d, [c, vo], [r, N]],
|
|
2338
2447
|
[
|
|
2339
2448
|
/(bravia[\w ]+)( bui|\))/i
|
|
2340
2449
|
// Sony
|
|
2341
2450
|
],
|
|
2342
|
-
[d, [
|
|
2451
|
+
[d, [c, Ve], [r, N]],
|
|
2343
2452
|
[
|
|
2344
2453
|
/(mi(tv|box)-?\w+) bui/i
|
|
2345
2454
|
// Xiaomi
|
|
2346
2455
|
],
|
|
2347
|
-
[d, [
|
|
2456
|
+
[d, [c, Nt], [r, N]],
|
|
2348
2457
|
[
|
|
2349
2458
|
/Hbbtv.*(technisat) (.*);/i
|
|
2350
2459
|
// TechniSAT
|
|
2351
2460
|
],
|
|
2352
|
-
[
|
|
2461
|
+
[c, d, [r, N]],
|
|
2353
2462
|
[
|
|
2354
2463
|
/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,
|
|
2355
2464
|
// Roku
|
|
2356
2465
|
/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i
|
|
2357
2466
|
// HbbTV devices
|
|
2358
2467
|
],
|
|
2359
|
-
[[
|
|
2468
|
+
[[c, nt], [d, nt], [r, N]],
|
|
2360
2469
|
[
|
|
2361
2470
|
// SmartTV from Unidentified Vendors
|
|
2362
2471
|
/droid.+; ([\w- ]+) (?:android tv|smart[- ]?tv)/i
|
|
2363
2472
|
],
|
|
2364
|
-
[d, [r,
|
|
2473
|
+
[d, [r, N]],
|
|
2365
2474
|
[
|
|
2366
2475
|
/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i
|
|
2367
2476
|
],
|
|
2368
|
-
[[r,
|
|
2477
|
+
[[r, N]],
|
|
2369
2478
|
[
|
|
2370
2479
|
///////////////////
|
|
2371
2480
|
// CONSOLES
|
|
@@ -2375,22 +2484,22 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2375
2484
|
/(nintendo) (\w+)/i
|
|
2376
2485
|
// Nintendo
|
|
2377
2486
|
],
|
|
2378
|
-
[
|
|
2487
|
+
[c, d, [r, Ze]],
|
|
2379
2488
|
[
|
|
2380
2489
|
/droid.+; (shield)( bui|\))/i
|
|
2381
2490
|
// Nvidia Portable
|
|
2382
2491
|
],
|
|
2383
|
-
[d, [
|
|
2492
|
+
[d, [c, Dt], [r, Ze]],
|
|
2384
2493
|
[
|
|
2385
2494
|
/(playstation \w+)/i
|
|
2386
2495
|
// Playstation
|
|
2387
2496
|
],
|
|
2388
|
-
[d, [
|
|
2497
|
+
[d, [c, Ve], [r, Ze]],
|
|
2389
2498
|
[
|
|
2390
2499
|
/\b(xbox(?: one)?(?!; xbox))[\); ]/i
|
|
2391
2500
|
// Microsoft Xbox
|
|
2392
2501
|
],
|
|
2393
|
-
[d, [
|
|
2502
|
+
[d, [c, _t], [r, Ze]],
|
|
2394
2503
|
[
|
|
2395
2504
|
///////////////////
|
|
2396
2505
|
// WEARABLES
|
|
@@ -2398,48 +2507,48 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2398
2507
|
/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i
|
|
2399
2508
|
// Samsung Galaxy Watch
|
|
2400
2509
|
],
|
|
2401
|
-
[d, [
|
|
2510
|
+
[d, [c, Fe], [r, se]],
|
|
2402
2511
|
[
|
|
2403
2512
|
/((pebble))app/i,
|
|
2404
2513
|
// Pebble
|
|
2405
2514
|
/(asus|google|lg|oppo) ((pixel |zen)?watch[\w ]*)( bui|\))/i
|
|
2406
2515
|
// Asus ZenWatch / LG Watch / Pixel Watch
|
|
2407
2516
|
],
|
|
2408
|
-
[
|
|
2517
|
+
[c, d, [r, se]],
|
|
2409
2518
|
[
|
|
2410
2519
|
/(ow(?:19|20)?we?[1-3]{1,3})/i
|
|
2411
2520
|
// Oppo Watch
|
|
2412
2521
|
],
|
|
2413
|
-
[d, [
|
|
2522
|
+
[d, [c, Pt], [r, se]],
|
|
2414
2523
|
[
|
|
2415
2524
|
/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i
|
|
2416
2525
|
// Apple Watch
|
|
2417
2526
|
],
|
|
2418
|
-
[d, [
|
|
2527
|
+
[d, [c, $e], [r, se]],
|
|
2419
2528
|
[
|
|
2420
2529
|
/(opwwe\d{3})/i
|
|
2421
2530
|
// OnePlus Watch
|
|
2422
2531
|
],
|
|
2423
|
-
[d, [
|
|
2532
|
+
[d, [c, bo], [r, se]],
|
|
2424
2533
|
[
|
|
2425
2534
|
/(moto 360)/i
|
|
2426
2535
|
// Motorola 360
|
|
2427
2536
|
],
|
|
2428
|
-
[d, [
|
|
2537
|
+
[d, [c, Bt], [r, se]],
|
|
2429
2538
|
[
|
|
2430
2539
|
/(smartwatch 3)/i
|
|
2431
2540
|
// Sony SmartWatch
|
|
2432
2541
|
],
|
|
2433
|
-
[d, [
|
|
2542
|
+
[d, [c, Ve], [r, se]],
|
|
2434
2543
|
[
|
|
2435
2544
|
/(g watch r)/i
|
|
2436
2545
|
// LG G Watch R
|
|
2437
2546
|
],
|
|
2438
|
-
[d, [
|
|
2547
|
+
[d, [c, ft], [r, se]],
|
|
2439
2548
|
[
|
|
2440
2549
|
/droid.+; (wt63?0{2,3})\)/i
|
|
2441
2550
|
],
|
|
2442
|
-
[d, [
|
|
2551
|
+
[d, [c, Mt], [r, se]],
|
|
2443
2552
|
[
|
|
2444
2553
|
///////////////////
|
|
2445
2554
|
// XR
|
|
@@ -2447,17 +2556,17 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2447
2556
|
/droid.+; (glass) \d/i
|
|
2448
2557
|
// Google Glass
|
|
2449
2558
|
],
|
|
2450
|
-
[d, [
|
|
2559
|
+
[d, [c, Te], [r, It]],
|
|
2451
2560
|
[
|
|
2452
2561
|
/(pico) (4|neo3(?: link|pro)?)/i
|
|
2453
2562
|
// Pico
|
|
2454
2563
|
],
|
|
2455
|
-
[
|
|
2564
|
+
[c, d, [r, It]],
|
|
2456
2565
|
[
|
|
2457
2566
|
/(quest( \d| pro)?s?).+vr/i
|
|
2458
2567
|
// Meta Quest
|
|
2459
2568
|
],
|
|
2460
|
-
[d, [
|
|
2569
|
+
[d, [c, xt], [r, It]],
|
|
2461
2570
|
[
|
|
2462
2571
|
///////////////////
|
|
2463
2572
|
// EMBEDDED
|
|
@@ -2465,17 +2574,17 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2465
2574
|
/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i
|
|
2466
2575
|
// Tesla
|
|
2467
2576
|
],
|
|
2468
|
-
[
|
|
2577
|
+
[c, [r, Je]],
|
|
2469
2578
|
[
|
|
2470
2579
|
/(aeobc)\b/i
|
|
2471
2580
|
// Echo Dot
|
|
2472
2581
|
],
|
|
2473
|
-
[d, [
|
|
2582
|
+
[d, [c, ct], [r, Je]],
|
|
2474
2583
|
[
|
|
2475
2584
|
/(homepod).+mac os/i
|
|
2476
2585
|
// Apple HomePod
|
|
2477
2586
|
],
|
|
2478
|
-
[d, [
|
|
2587
|
+
[d, [c, $e], [r, Je]],
|
|
2479
2588
|
[
|
|
2480
2589
|
/windows iot/i
|
|
2481
2590
|
],
|
|
@@ -2501,14 +2610,14 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2501
2610
|
/droid .+?; ([\w\. -]+)( bui|\))/i
|
|
2502
2611
|
// Generic Android Device
|
|
2503
2612
|
],
|
|
2504
|
-
[d, [
|
|
2613
|
+
[d, [c, "Generic"]]
|
|
2505
2614
|
],
|
|
2506
2615
|
engine: [
|
|
2507
2616
|
[
|
|
2508
2617
|
/windows.+ edge\/([\w\.]+)/i
|
|
2509
2618
|
// EdgeHTML
|
|
2510
2619
|
],
|
|
2511
|
-
[g, [f,
|
|
2620
|
+
[g, [f, Yi + "HTML"]],
|
|
2512
2621
|
[
|
|
2513
2622
|
/(arkweb)\/([\w\.]+)/i
|
|
2514
2623
|
// ArkWeb
|
|
@@ -2562,7 +2671,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2562
2671
|
/windows[\/ ]([ntce\d\. ]+\w)(?!.+xbox)/i,
|
|
2563
2672
|
/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i
|
|
2564
2673
|
],
|
|
2565
|
-
[[g, ve, Co], [f,
|
|
2674
|
+
[[g, ve, Co], [f, Jt]],
|
|
2566
2675
|
[
|
|
2567
2676
|
// iOS/macOS
|
|
2568
2677
|
/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,
|
|
@@ -2623,7 +2732,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2623
2732
|
/\(bb(10);/i
|
|
2624
2733
|
// BlackBerry 10
|
|
2625
2734
|
],
|
|
2626
|
-
[g, [f,
|
|
2735
|
+
[g, [f, go]],
|
|
2627
2736
|
[
|
|
2628
2737
|
/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i
|
|
2629
2738
|
// Symbian
|
|
@@ -2633,7 +2742,7 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2633
2742
|
/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i
|
|
2634
2743
|
// Firefox OS
|
|
2635
2744
|
],
|
|
2636
|
-
[g, [f,
|
|
2745
|
+
[g, [f, je + " OS"]],
|
|
2637
2746
|
[
|
|
2638
2747
|
/web0s;.+rt(tv)/i,
|
|
2639
2748
|
/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i
|
|
@@ -2704,95 +2813,95 @@ var Li = "2.0.3", Xt = 500, ro = "user-agent", xe = "", uo = "?", Ct = "function
|
|
|
2704
2813
|
]
|
|
2705
2814
|
}, gt = function() {
|
|
2706
2815
|
var e = { init: {}, isIgnore: {}, isIgnoreRgx: {}, toString: {} };
|
|
2707
|
-
return
|
|
2708
|
-
[
|
|
2709
|
-
[
|
|
2710
|
-
[ie, [r, d,
|
|
2711
|
-
[
|
|
2816
|
+
return fe.call(e.init, [
|
|
2817
|
+
[V, [f, g, it, r]],
|
|
2818
|
+
[ue, [j]],
|
|
2819
|
+
[ie, [r, d, c]],
|
|
2820
|
+
[Q, [f, g]],
|
|
2712
2821
|
[X, [f, g]]
|
|
2713
|
-
]),
|
|
2714
|
-
[
|
|
2715
|
-
[
|
|
2822
|
+
]), fe.call(e.isIgnore, [
|
|
2823
|
+
[V, [g, it]],
|
|
2824
|
+
[Q, [g]],
|
|
2716
2825
|
[X, [g]]
|
|
2717
|
-
]),
|
|
2718
|
-
[
|
|
2826
|
+
]), fe.call(e.isIgnoreRgx, [
|
|
2827
|
+
[V, / ?browser$/i],
|
|
2719
2828
|
[X, / ?os$/i]
|
|
2720
|
-
]),
|
|
2721
|
-
[
|
|
2722
|
-
[
|
|
2723
|
-
[ie, [
|
|
2724
|
-
[
|
|
2829
|
+
]), fe.call(e.toString, [
|
|
2830
|
+
[V, [f, g]],
|
|
2831
|
+
[ue, [j]],
|
|
2832
|
+
[ie, [c, d]],
|
|
2833
|
+
[Q, [f, g]],
|
|
2725
2834
|
[X, [f, g]]
|
|
2726
2835
|
]), e;
|
|
2727
|
-
}(),
|
|
2728
|
-
var o = gt.init[t],
|
|
2836
|
+
}(), Qi = function(e, t) {
|
|
2837
|
+
var o = gt.init[t], i = gt.isIgnore[t] || 0, s = gt.isIgnoreRgx[t] || 0, n = gt.toString[t] || 0;
|
|
2729
2838
|
function l() {
|
|
2730
|
-
|
|
2839
|
+
fe.call(this, o);
|
|
2731
2840
|
}
|
|
2732
2841
|
return l.prototype.getItem = function() {
|
|
2733
2842
|
return e;
|
|
2734
2843
|
}, l.prototype.withClientHints = function() {
|
|
2735
|
-
return be ? be.getHighEntropyValues(
|
|
2736
|
-
return e.setCH(new
|
|
2844
|
+
return be ? be.getHighEntropyValues(Wo).then(function(a) {
|
|
2845
|
+
return e.setCH(new Xo(a, !1)).parseCH().get();
|
|
2737
2846
|
}) : e.parseCH().get();
|
|
2738
2847
|
}, l.prototype.withFeatureCheck = function() {
|
|
2739
2848
|
return e.detectFeature().get();
|
|
2740
2849
|
}, t != De && (l.prototype.is = function(a) {
|
|
2741
|
-
var
|
|
2850
|
+
var u = !1;
|
|
2742
2851
|
for (var p in this)
|
|
2743
|
-
if (this.hasOwnProperty(p) && !
|
|
2744
|
-
if (
|
|
2745
|
-
} else if (a == ye &&
|
|
2746
|
-
|
|
2852
|
+
if (this.hasOwnProperty(p) && !Qt(i, p) && ce(s ? Re(s, this[p]) : this[p]) == ce(s ? Re(s, a) : a)) {
|
|
2853
|
+
if (u = !0, a != ye) break;
|
|
2854
|
+
} else if (a == ye && u) {
|
|
2855
|
+
u = !u;
|
|
2747
2856
|
break;
|
|
2748
2857
|
}
|
|
2749
|
-
return
|
|
2858
|
+
return u;
|
|
2750
2859
|
}, l.prototype.toString = function() {
|
|
2751
2860
|
var a = xe;
|
|
2752
|
-
for (var
|
|
2753
|
-
typeof this[n[
|
|
2861
|
+
for (var u in n)
|
|
2862
|
+
typeof this[n[u]] !== ye && (a += (a ? " " : xe) + this[n[u]]);
|
|
2754
2863
|
return a || ye;
|
|
2755
2864
|
}), be || (l.prototype.then = function(a) {
|
|
2756
|
-
var
|
|
2757
|
-
for (var
|
|
2758
|
-
|
|
2865
|
+
var u = this, p = function() {
|
|
2866
|
+
for (var k in u)
|
|
2867
|
+
u.hasOwnProperty(k) && (this[k] = u[k]);
|
|
2759
2868
|
};
|
|
2760
2869
|
p.prototype = {
|
|
2761
2870
|
is: l.prototype.is,
|
|
2762
2871
|
toString: l.prototype.toString
|
|
2763
2872
|
};
|
|
2764
|
-
var
|
|
2765
|
-
return a(
|
|
2873
|
+
var y = new p();
|
|
2874
|
+
return a(y), y;
|
|
2766
2875
|
}), new l();
|
|
2767
2876
|
};
|
|
2768
|
-
function
|
|
2769
|
-
if (e = e || {},
|
|
2770
|
-
|
|
2771
|
-
[
|
|
2772
|
-
[
|
|
2773
|
-
[E, /\?1/.test(e[
|
|
2774
|
-
[d, We(e[
|
|
2775
|
-
[Pe, We(e[
|
|
2776
|
-
[
|
|
2777
|
-
[
|
|
2778
|
-
[
|
|
2779
|
-
[
|
|
2877
|
+
function Xo(e, t) {
|
|
2878
|
+
if (e = e || {}, fe.call(this, Wo), t)
|
|
2879
|
+
fe.call(this, [
|
|
2880
|
+
[so, Ut(e[Ee])],
|
|
2881
|
+
[io, Ut(e[Fi])],
|
|
2882
|
+
[E, /\?1/.test(e[Gi])],
|
|
2883
|
+
[d, We(e[Wi])],
|
|
2884
|
+
[Pe, We(e[Go])],
|
|
2885
|
+
[no, We(e[Xi])],
|
|
2886
|
+
[j, We(e[Vi])],
|
|
2887
|
+
[Ae, Ut(e[Ki])],
|
|
2888
|
+
[Ot, We(e[ji])]
|
|
2780
2889
|
]);
|
|
2781
2890
|
else
|
|
2782
2891
|
for (var o in e)
|
|
2783
2892
|
this.hasOwnProperty(o) && typeof e[o] !== ye && (this[o] = e[o]);
|
|
2784
2893
|
}
|
|
2785
|
-
function
|
|
2786
|
-
return this.get = function(
|
|
2787
|
-
return
|
|
2788
|
-
}, this.set = function(
|
|
2789
|
-
return this.data[
|
|
2790
|
-
}, this.setCH = function(
|
|
2791
|
-
return this.uaCH =
|
|
2894
|
+
function Ao(e, t, o, i) {
|
|
2895
|
+
return this.get = function(s) {
|
|
2896
|
+
return s ? this.data.hasOwnProperty(s) ? this.data[s] : void 0 : this.data;
|
|
2897
|
+
}, this.set = function(s, n) {
|
|
2898
|
+
return this.data[s] = n, this;
|
|
2899
|
+
}, this.setCH = function(s) {
|
|
2900
|
+
return this.uaCH = s, this;
|
|
2792
2901
|
}, this.detectFeature = function() {
|
|
2793
2902
|
if (K && K.userAgent == this.ua)
|
|
2794
2903
|
switch (this.itemType) {
|
|
2795
|
-
case
|
|
2904
|
+
case V:
|
|
2796
2905
|
K.brave && typeof K.brave.isBrave == Ct && this.set(f, "Brave");
|
|
2797
2906
|
break;
|
|
2798
2907
|
case ie:
|
|
@@ -2802,24 +2911,24 @@ function To(e, t, o, s) {
|
|
|
2802
2911
|
!this.get(f) && be && be[Pe] && this.set(f, be[Pe]);
|
|
2803
2912
|
break;
|
|
2804
2913
|
case De:
|
|
2805
|
-
var
|
|
2806
|
-
return
|
|
2914
|
+
var s = this.data, n = function(l) {
|
|
2915
|
+
return s[l].getItem().detectFeature().get();
|
|
2807
2916
|
};
|
|
2808
|
-
this.set(
|
|
2917
|
+
this.set(V, n(V)).set(ue, n(ue)).set(ie, n(ie)).set(Q, n(Q)).set(X, n(X));
|
|
2809
2918
|
}
|
|
2810
2919
|
return this;
|
|
2811
2920
|
}, this.parseUA = function() {
|
|
2812
|
-
return this.itemType != De &&
|
|
2921
|
+
return this.itemType != De && zt.call(this.data, this.ua, this.rgxMap), this.itemType == V && this.set(it, Rt(this.get(g))), this;
|
|
2813
2922
|
}, this.parseCH = function() {
|
|
2814
|
-
var
|
|
2923
|
+
var s = this.uaCH, n = this.rgxMap;
|
|
2815
2924
|
switch (this.itemType) {
|
|
2816
|
-
case
|
|
2817
|
-
case
|
|
2818
|
-
var l =
|
|
2925
|
+
case V:
|
|
2926
|
+
case Q:
|
|
2927
|
+
var l = s[io] || s[so], a;
|
|
2819
2928
|
if (l)
|
|
2820
|
-
for (var
|
|
2821
|
-
var p = l[
|
|
2822
|
-
this.itemType ==
|
|
2929
|
+
for (var u in l) {
|
|
2930
|
+
var p = l[u].brand || l[u], y = l[u].version;
|
|
2931
|
+
this.itemType == V && !/not.a.brand/i.test(p) && (!a || /chrom/i.test(a) && p != yo) && (p = ve(p, {
|
|
2823
2932
|
Chrome: "Google Chrome",
|
|
2824
2933
|
Edge: "Microsoft Edge",
|
|
2825
2934
|
"Chrome WebView": "Android WebView",
|
|
@@ -2828,109 +2937,109 @@ function To(e, t, o, s) {
|
|
|
2828
2937
|
"MIUI Browser": "Miui Browser",
|
|
2829
2938
|
"Opera Mobi": "OperaMobile",
|
|
2830
2939
|
Yandex: "YaBrowser"
|
|
2831
|
-
}), this.set(f, p).set(g,
|
|
2940
|
+
}), this.set(f, p).set(g, y).set(it, Rt(y)), a = p), this.itemType == Q && p == yo && this.set(g, y);
|
|
2832
2941
|
}
|
|
2833
2942
|
break;
|
|
2834
|
-
case
|
|
2835
|
-
var
|
|
2836
|
-
|
|
2943
|
+
case ue:
|
|
2944
|
+
var k = s[j];
|
|
2945
|
+
k && (k && s[Ot] == "64" && (k += "64"), zt.call(this.data, k + ";", n));
|
|
2837
2946
|
break;
|
|
2838
2947
|
case ie:
|
|
2839
|
-
if (
|
|
2840
|
-
var
|
|
2841
|
-
|
|
2948
|
+
if (s[E] && this.set(r, E), s[d] && (this.set(d, s[d]), !this.get(r) || !this.get(c))) {
|
|
2949
|
+
var b = {};
|
|
2950
|
+
zt.call(b, "droid 9; " + s[d] + ")", n), !this.get(r) && b.type && this.set(r, b.type), !this.get(c) && b.vendor && this.set(c, b.vendor);
|
|
2842
2951
|
}
|
|
2843
|
-
if (
|
|
2844
|
-
var
|
|
2845
|
-
if (typeof
|
|
2846
|
-
for (var S = 0; !
|
|
2847
|
-
|
|
2952
|
+
if (s[Ae]) {
|
|
2953
|
+
var m;
|
|
2954
|
+
if (typeof s[Ae] != "string")
|
|
2955
|
+
for (var S = 0; !m && S < s[Ae].length; )
|
|
2956
|
+
m = ve(s[Ae][S++], Eo);
|
|
2848
2957
|
else
|
|
2849
|
-
|
|
2850
|
-
this.set(r,
|
|
2958
|
+
m = ve(s[Ae], Eo);
|
|
2959
|
+
this.set(r, m);
|
|
2851
2960
|
}
|
|
2852
2961
|
break;
|
|
2853
2962
|
case X:
|
|
2854
|
-
var
|
|
2855
|
-
if (
|
|
2856
|
-
var
|
|
2857
|
-
|
|
2963
|
+
var C = s[Pe];
|
|
2964
|
+
if (C) {
|
|
2965
|
+
var U = s[no];
|
|
2966
|
+
C == Jt && (U = parseInt(Rt(U), 10) >= 13 ? "11" : "10"), this.set(f, C).set(g, U);
|
|
2858
2967
|
}
|
|
2859
|
-
this.get(f) ==
|
|
2968
|
+
this.get(f) == Jt && s[d] == "Xbox" && this.set(f, "Xbox").set(g, void 0);
|
|
2860
2969
|
break;
|
|
2861
2970
|
case De:
|
|
2862
|
-
var
|
|
2863
|
-
return
|
|
2971
|
+
var re = this.data, x = function(oe) {
|
|
2972
|
+
return re[oe].getItem().setCH(s).parseCH().get();
|
|
2864
2973
|
};
|
|
2865
|
-
this.set(
|
|
2974
|
+
this.set(V, x(V)).set(ue, x(ue)).set(ie, x(ie)).set(Q, x(Q)).set(X, x(X));
|
|
2866
2975
|
}
|
|
2867
2976
|
return this;
|
|
2868
|
-
},
|
|
2977
|
+
}, fe.call(this, [
|
|
2869
2978
|
["itemType", e],
|
|
2870
2979
|
["ua", t],
|
|
2871
|
-
["uaCH",
|
|
2980
|
+
["uaCH", i],
|
|
2872
2981
|
["rgxMap", o],
|
|
2873
|
-
["data",
|
|
2982
|
+
["data", Qi(this, e)]
|
|
2874
2983
|
]), this;
|
|
2875
2984
|
}
|
|
2876
2985
|
function pe(e, t, o) {
|
|
2877
|
-
if (typeof e ===
|
|
2878
|
-
var
|
|
2879
|
-
o.forEach(function(
|
|
2880
|
-
|
|
2881
|
-
}), o =
|
|
2986
|
+
if (typeof e === Ue ? (Et(e, !0) ? (typeof t === Ue && (o = t), t = e) : (o = e, t = void 0), e = void 0) : typeof e === Zt && !Et(t, !0) && (o = t, t = void 0), o && typeof o.append === Ct) {
|
|
2987
|
+
var i = {};
|
|
2988
|
+
o.forEach(function(u, p) {
|
|
2989
|
+
i[p] = u;
|
|
2990
|
+
}), o = i;
|
|
2882
2991
|
}
|
|
2883
2992
|
if (!(this instanceof pe))
|
|
2884
2993
|
return new pe(e, t, o).getResult();
|
|
2885
|
-
var
|
|
2994
|
+
var s = typeof e === Zt ? e : (
|
|
2886
2995
|
// Passed user-agent string
|
|
2887
|
-
o && o[
|
|
2996
|
+
o && o[uo] ? o[uo] : (
|
|
2888
2997
|
// User-Agent from passed headers
|
|
2889
2998
|
K && K.userAgent ? K.userAgent : (
|
|
2890
2999
|
// navigator.userAgent
|
|
2891
3000
|
xe
|
|
2892
3001
|
)
|
|
2893
3002
|
)
|
|
2894
|
-
), n = new
|
|
2895
|
-
return
|
|
2896
|
-
return new
|
|
3003
|
+
), n = new Xo(o, !0), l = t ? Ji(To, t) : To, a = function(u) {
|
|
3004
|
+
return u == De ? function() {
|
|
3005
|
+
return new Ao(u, s, l, n).set("ua", s).set(V, this.getBrowser()).set(ue, this.getCPU()).set(ie, this.getDevice()).set(Q, this.getEngine()).set(X, this.getOS()).get();
|
|
2897
3006
|
} : function() {
|
|
2898
|
-
return new
|
|
3007
|
+
return new Ao(u, s, l[u], n).parseUA().get();
|
|
2899
3008
|
};
|
|
2900
3009
|
};
|
|
2901
|
-
return
|
|
2902
|
-
["getBrowser", a(
|
|
2903
|
-
["getCPU", a(
|
|
3010
|
+
return fe.call(this, [
|
|
3011
|
+
["getBrowser", a(V)],
|
|
3012
|
+
["getCPU", a(ue)],
|
|
2904
3013
|
["getDevice", a(ie)],
|
|
2905
|
-
["getEngine", a(
|
|
3014
|
+
["getEngine", a(Q)],
|
|
2906
3015
|
["getOS", a(X)],
|
|
2907
3016
|
["getResult", a(De)],
|
|
2908
3017
|
["getUA", function() {
|
|
2909
|
-
return
|
|
3018
|
+
return s;
|
|
2910
3019
|
}],
|
|
2911
|
-
["setUA", function(
|
|
2912
|
-
return ze(
|
|
3020
|
+
["setUA", function(u) {
|
|
3021
|
+
return ze(u) && (s = u.length > Yt ? nt(u, Yt) : u), this;
|
|
2913
3022
|
}]
|
|
2914
|
-
]).setUA(
|
|
3023
|
+
]).setUA(s), this;
|
|
2915
3024
|
}
|
|
2916
|
-
pe.VERSION =
|
|
2917
|
-
pe.BROWSER =
|
|
2918
|
-
pe.CPU =
|
|
2919
|
-
pe.DEVICE =
|
|
2920
|
-
pe.ENGINE = pe.OS =
|
|
2921
|
-
const
|
|
2922
|
-
function
|
|
2923
|
-
e.addEventListener ? e.addEventListener(t, o,
|
|
3025
|
+
pe.VERSION = qi;
|
|
3026
|
+
pe.BROWSER = $t([f, g, it, r]);
|
|
3027
|
+
pe.CPU = $t([j]);
|
|
3028
|
+
pe.DEVICE = $t([d, c, r, Ze, E, N, O, se, Je]);
|
|
3029
|
+
pe.ENGINE = pe.OS = $t([f, g]);
|
|
3030
|
+
const Ht = typeof navigator < "u" ? navigator.userAgent.toLowerCase().indexOf("firefox") > 0 : !1;
|
|
3031
|
+
function qt(e, t, o, i) {
|
|
3032
|
+
e.addEventListener ? e.addEventListener(t, o, i) : e.attachEvent && e.attachEvent("on".concat(t), o);
|
|
2924
3033
|
}
|
|
2925
|
-
function Xe(e, t, o,
|
|
2926
|
-
e.removeEventListener ? e.removeEventListener(t, o,
|
|
3034
|
+
function Xe(e, t, o, i) {
|
|
3035
|
+
e.removeEventListener ? e.removeEventListener(t, o, i) : e.detachEvent && e.detachEvent("on".concat(t), o);
|
|
2927
3036
|
}
|
|
2928
|
-
function
|
|
3037
|
+
function Yo(e, t) {
|
|
2929
3038
|
const o = t.slice(0, t.length - 1);
|
|
2930
|
-
for (let
|
|
3039
|
+
for (let i = 0; i < o.length; i++) o[i] = e[o[i].toLowerCase()];
|
|
2931
3040
|
return o;
|
|
2932
3041
|
}
|
|
2933
|
-
function
|
|
3042
|
+
function Zo(e) {
|
|
2934
3043
|
typeof e != "string" && (e = ""), e = e.replace(/\s/g, "");
|
|
2935
3044
|
const t = e.split(",");
|
|
2936
3045
|
let o = t.lastIndexOf("");
|
|
@@ -2938,12 +3047,12 @@ function Go(e) {
|
|
|
2938
3047
|
t[o - 1] += ",", t.splice(o, 1), o = t.lastIndexOf("");
|
|
2939
3048
|
return t;
|
|
2940
3049
|
}
|
|
2941
|
-
function
|
|
2942
|
-
const o = e.length >= t.length ? e : t,
|
|
2943
|
-
let
|
|
3050
|
+
function en(e, t) {
|
|
3051
|
+
const o = e.length >= t.length ? e : t, i = e.length >= t.length ? t : e;
|
|
3052
|
+
let s = !0;
|
|
2944
3053
|
for (let n = 0; n < o.length; n++)
|
|
2945
|
-
|
|
2946
|
-
return
|
|
3054
|
+
i.indexOf(o[n]) === -1 && (s = !1);
|
|
3055
|
+
return s;
|
|
2947
3056
|
}
|
|
2948
3057
|
const at = {
|
|
2949
3058
|
backspace: 8,
|
|
@@ -2990,9 +3099,9 @@ const at = {
|
|
|
2990
3099
|
".": 190,
|
|
2991
3100
|
"/": 191,
|
|
2992
3101
|
"`": 192,
|
|
2993
|
-
"-":
|
|
2994
|
-
"=":
|
|
2995
|
-
";":
|
|
3102
|
+
"-": Ht ? 173 : 189,
|
|
3103
|
+
"=": Ht ? 61 : 187,
|
|
3104
|
+
";": Ht ? 59 : 186,
|
|
2996
3105
|
"'": 222,
|
|
2997
3106
|
"[": 219,
|
|
2998
3107
|
"]": 221,
|
|
@@ -3022,7 +3131,7 @@ const at = {
|
|
|
3022
3131
|
ctrlKey: 17,
|
|
3023
3132
|
altKey: 18,
|
|
3024
3133
|
metaKey: 91
|
|
3025
|
-
},
|
|
3134
|
+
}, z = {
|
|
3026
3135
|
16: !1,
|
|
3027
3136
|
18: !1,
|
|
3028
3137
|
17: !1,
|
|
@@ -3030,90 +3139,90 @@ const at = {
|
|
|
3030
3139
|
}, B = {};
|
|
3031
3140
|
for (let e = 1; e < 20; e++)
|
|
3032
3141
|
at["f".concat(e)] = 111 + e;
|
|
3033
|
-
let
|
|
3034
|
-
const
|
|
3035
|
-
function
|
|
3036
|
-
|
|
3142
|
+
let _ = [], tt = null, Jo = "all";
|
|
3143
|
+
const de = /* @__PURE__ */ new Map(), dt = (e) => at[e.toLowerCase()] || te[e.toLowerCase()] || e.toUpperCase().charCodeAt(0), tn = (e) => Object.keys(at).find((t) => at[t] === e), on = (e) => Object.keys(te).find((t) => te[t] === e);
|
|
3144
|
+
function Qo(e) {
|
|
3145
|
+
Jo = e || "all";
|
|
3037
3146
|
}
|
|
3038
3147
|
function lt() {
|
|
3039
|
-
return
|
|
3148
|
+
return Jo || "all";
|
|
3040
3149
|
}
|
|
3041
|
-
function
|
|
3042
|
-
return
|
|
3150
|
+
function sn() {
|
|
3151
|
+
return _.slice(0);
|
|
3043
3152
|
}
|
|
3044
|
-
function
|
|
3045
|
-
return
|
|
3153
|
+
function nn() {
|
|
3154
|
+
return _.map((e) => tn(e) || on(e) || String.fromCharCode(e));
|
|
3046
3155
|
}
|
|
3047
|
-
function
|
|
3156
|
+
function an() {
|
|
3048
3157
|
const e = [];
|
|
3049
3158
|
return Object.keys(B).forEach((t) => {
|
|
3050
3159
|
B[t].forEach((o) => {
|
|
3051
3160
|
let {
|
|
3052
|
-
key:
|
|
3053
|
-
scope:
|
|
3161
|
+
key: i,
|
|
3162
|
+
scope: s,
|
|
3054
3163
|
mods: n,
|
|
3055
3164
|
shortcut: l
|
|
3056
3165
|
} = o;
|
|
3057
3166
|
e.push({
|
|
3058
|
-
scope:
|
|
3167
|
+
scope: s,
|
|
3059
3168
|
shortcut: l,
|
|
3060
3169
|
mods: n,
|
|
3061
|
-
keys:
|
|
3170
|
+
keys: i.split("+").map((a) => dt(a))
|
|
3062
3171
|
});
|
|
3063
3172
|
});
|
|
3064
3173
|
}), e;
|
|
3065
3174
|
}
|
|
3066
|
-
function
|
|
3175
|
+
function ln(e) {
|
|
3067
3176
|
const t = e.target || e.srcElement, {
|
|
3068
3177
|
tagName: o
|
|
3069
3178
|
} = t;
|
|
3070
|
-
let
|
|
3071
|
-
const
|
|
3072
|
-
return (t.isContentEditable || (
|
|
3179
|
+
let i = !0;
|
|
3180
|
+
const s = o === "INPUT" && !["checkbox", "radio", "range", "button", "file", "reset", "submit", "color"].includes(t.type);
|
|
3181
|
+
return (t.isContentEditable || (s || o === "TEXTAREA" || o === "SELECT") && !t.readOnly) && (i = !1), i;
|
|
3073
3182
|
}
|
|
3074
|
-
function
|
|
3075
|
-
return typeof e == "string" && (e = dt(e)),
|
|
3183
|
+
function rn(e) {
|
|
3184
|
+
return typeof e == "string" && (e = dt(e)), _.indexOf(e) !== -1;
|
|
3076
3185
|
}
|
|
3077
|
-
function
|
|
3078
|
-
let o,
|
|
3186
|
+
function dn(e, t) {
|
|
3187
|
+
let o, i;
|
|
3079
3188
|
e || (e = lt());
|
|
3080
|
-
for (const
|
|
3081
|
-
if (Object.prototype.hasOwnProperty.call(B,
|
|
3082
|
-
for (o = B[
|
|
3083
|
-
o[
|
|
3189
|
+
for (const s in B)
|
|
3190
|
+
if (Object.prototype.hasOwnProperty.call(B, s))
|
|
3191
|
+
for (o = B[s], i = 0; i < o.length; )
|
|
3192
|
+
o[i].scope === e ? o.splice(i, 1).forEach((l) => {
|
|
3084
3193
|
let {
|
|
3085
3194
|
element: a
|
|
3086
3195
|
} = l;
|
|
3087
|
-
return
|
|
3088
|
-
}) :
|
|
3089
|
-
lt() === e &&
|
|
3196
|
+
return ao(a);
|
|
3197
|
+
}) : i++;
|
|
3198
|
+
lt() === e && Qo(t || "all");
|
|
3090
3199
|
}
|
|
3091
|
-
function
|
|
3200
|
+
function un(e) {
|
|
3092
3201
|
let t = e.keyCode || e.which || e.charCode;
|
|
3093
|
-
const o =
|
|
3094
|
-
if (o >= 0 &&
|
|
3095
|
-
|
|
3096
|
-
for (const
|
|
3202
|
+
const o = _.indexOf(t);
|
|
3203
|
+
if (o >= 0 && _.splice(o, 1), e.key && e.key.toLowerCase() === "meta" && _.splice(0, _.length), (t === 93 || t === 224) && (t = 91), t in z) {
|
|
3204
|
+
z[t] = !1;
|
|
3205
|
+
for (const i in te) te[i] === t && (ae[i] = !1);
|
|
3097
3206
|
}
|
|
3098
3207
|
}
|
|
3099
|
-
function
|
|
3208
|
+
function es(e) {
|
|
3100
3209
|
if (typeof e > "u")
|
|
3101
|
-
Object.keys(B).forEach((
|
|
3102
|
-
Array.isArray(B[
|
|
3103
|
-
}),
|
|
3210
|
+
Object.keys(B).forEach((s) => {
|
|
3211
|
+
Array.isArray(B[s]) && B[s].forEach((n) => pt(n)), delete B[s];
|
|
3212
|
+
}), ao(null);
|
|
3104
3213
|
else if (Array.isArray(e))
|
|
3105
|
-
e.forEach((
|
|
3106
|
-
|
|
3214
|
+
e.forEach((s) => {
|
|
3215
|
+
s.key && pt(s);
|
|
3107
3216
|
});
|
|
3108
3217
|
else if (typeof e == "object")
|
|
3109
3218
|
e.key && pt(e);
|
|
3110
3219
|
else if (typeof e == "string") {
|
|
3111
|
-
for (var t = arguments.length, o = new Array(t > 1 ? t - 1 : 0),
|
|
3112
|
-
o[
|
|
3113
|
-
let [
|
|
3114
|
-
typeof
|
|
3220
|
+
for (var t = arguments.length, o = new Array(t > 1 ? t - 1 : 0), i = 1; i < t; i++)
|
|
3221
|
+
o[i - 1] = arguments[i];
|
|
3222
|
+
let [s, n] = o;
|
|
3223
|
+
typeof s == "function" && (n = s, s = ""), pt({
|
|
3115
3224
|
key: e,
|
|
3116
|
-
scope:
|
|
3225
|
+
scope: s,
|
|
3117
3226
|
method: n,
|
|
3118
3227
|
splitKey: "+"
|
|
3119
3228
|
});
|
|
@@ -3123,189 +3232,189 @@ const pt = (e) => {
|
|
|
3123
3232
|
let {
|
|
3124
3233
|
key: t,
|
|
3125
3234
|
scope: o,
|
|
3126
|
-
method:
|
|
3127
|
-
splitKey:
|
|
3235
|
+
method: i,
|
|
3236
|
+
splitKey: s = "+"
|
|
3128
3237
|
} = e;
|
|
3129
|
-
|
|
3130
|
-
const a = l.split(
|
|
3131
|
-
if (!B[
|
|
3238
|
+
Zo(t).forEach((l) => {
|
|
3239
|
+
const a = l.split(s), u = a.length, p = a[u - 1], y = p === "*" ? "*" : dt(p);
|
|
3240
|
+
if (!B[y]) return;
|
|
3132
3241
|
o || (o = lt());
|
|
3133
|
-
const
|
|
3134
|
-
B[
|
|
3135
|
-
const
|
|
3136
|
-
return
|
|
3137
|
-
}),
|
|
3242
|
+
const k = u > 1 ? Yo(te, a) : [], b = [];
|
|
3243
|
+
B[y] = B[y].filter((m) => {
|
|
3244
|
+
const C = (i ? m.method === i : !0) && m.scope === o && en(m.mods, k);
|
|
3245
|
+
return C && b.push(m.element), !C;
|
|
3246
|
+
}), b.forEach((m) => ao(m));
|
|
3138
3247
|
});
|
|
3139
3248
|
};
|
|
3140
|
-
function
|
|
3141
|
-
if (t.element !==
|
|
3249
|
+
function So(e, t, o, i) {
|
|
3250
|
+
if (t.element !== i)
|
|
3142
3251
|
return;
|
|
3143
|
-
let
|
|
3252
|
+
let s;
|
|
3144
3253
|
if (t.scope === o || t.scope === "all") {
|
|
3145
|
-
|
|
3146
|
-
for (const n in
|
|
3147
|
-
Object.prototype.hasOwnProperty.call(
|
|
3148
|
-
(t.mods.length === 0 && !
|
|
3254
|
+
s = t.mods.length > 0;
|
|
3255
|
+
for (const n in z)
|
|
3256
|
+
Object.prototype.hasOwnProperty.call(z, n) && (!z[n] && t.mods.indexOf(+n) > -1 || z[n] && t.mods.indexOf(+n) === -1) && (s = !1);
|
|
3257
|
+
(t.mods.length === 0 && !z[16] && !z[18] && !z[17] && !z[91] || s || t.shortcut === "*") && (t.keys = [], t.keys = t.keys.concat(_), t.method(e, t) === !1 && (e.preventDefault ? e.preventDefault() : e.returnValue = !1, e.stopPropagation && e.stopPropagation(), e.cancelBubble && (e.cancelBubble = !0)));
|
|
3149
3258
|
}
|
|
3150
3259
|
}
|
|
3151
|
-
function
|
|
3260
|
+
function Oo(e, t) {
|
|
3152
3261
|
const o = B["*"];
|
|
3153
|
-
let
|
|
3154
|
-
if (!
|
|
3155
|
-
if ((
|
|
3156
|
-
const
|
|
3157
|
-
e[a] &&
|
|
3158
|
-
}),
|
|
3159
|
-
|
|
3262
|
+
let i = e.keyCode || e.which || e.charCode;
|
|
3263
|
+
if (!ae.filter.call(this, e)) return;
|
|
3264
|
+
if ((i === 93 || i === 224) && (i = 91), _.indexOf(i) === -1 && i !== 229 && _.push(i), ["metaKey", "ctrlKey", "altKey", "shiftKey"].forEach((a) => {
|
|
3265
|
+
const u = Qe[a];
|
|
3266
|
+
e[a] && _.indexOf(u) === -1 ? _.push(u) : !e[a] && _.indexOf(u) > -1 ? _.splice(_.indexOf(u), 1) : a === "metaKey" && e[a] && (_ = _.filter((p) => p in Qe || p === i));
|
|
3267
|
+
}), i in z) {
|
|
3268
|
+
z[i] = !0;
|
|
3160
3269
|
for (const a in te)
|
|
3161
3270
|
if (Object.prototype.hasOwnProperty.call(te, a)) {
|
|
3162
|
-
const
|
|
3163
|
-
|
|
3271
|
+
const u = Qe[te[a]];
|
|
3272
|
+
ae[a] = e[u];
|
|
3164
3273
|
}
|
|
3165
3274
|
if (!o) return;
|
|
3166
3275
|
}
|
|
3167
|
-
for (const a in
|
|
3168
|
-
Object.prototype.hasOwnProperty.call(
|
|
3169
|
-
e.getModifierState && !(e.altKey && !e.ctrlKey) && e.getModifierState("AltGraph") && (
|
|
3170
|
-
const
|
|
3276
|
+
for (const a in z)
|
|
3277
|
+
Object.prototype.hasOwnProperty.call(z, a) && (z[a] = e[Qe[a]]);
|
|
3278
|
+
e.getModifierState && !(e.altKey && !e.ctrlKey) && e.getModifierState("AltGraph") && (_.indexOf(17) === -1 && _.push(17), _.indexOf(18) === -1 && _.push(18), z[17] = !0, z[18] = !0);
|
|
3279
|
+
const s = lt();
|
|
3171
3280
|
if (o)
|
|
3172
3281
|
for (let a = 0; a < o.length; a++)
|
|
3173
|
-
o[a].scope ===
|
|
3174
|
-
if (!(
|
|
3175
|
-
const n = B[
|
|
3282
|
+
o[a].scope === s && (e.type === "keydown" && o[a].keydown || e.type === "keyup" && o[a].keyup) && So(e, o[a], s, t);
|
|
3283
|
+
if (!(i in B)) return;
|
|
3284
|
+
const n = B[i], l = n.length;
|
|
3176
3285
|
for (let a = 0; a < l; a++)
|
|
3177
3286
|
if ((e.type === "keydown" && n[a].keydown || e.type === "keyup" && n[a].keyup) && n[a].key) {
|
|
3178
|
-
const
|
|
3287
|
+
const u = n[a], {
|
|
3179
3288
|
splitKey: p
|
|
3180
|
-
} =
|
|
3181
|
-
for (let
|
|
3182
|
-
|
|
3183
|
-
|
|
3289
|
+
} = u, y = u.key.split(p), k = [];
|
|
3290
|
+
for (let b = 0; b < y.length; b++)
|
|
3291
|
+
k.push(dt(y[b]));
|
|
3292
|
+
k.sort().join("") === _.sort().join("") && So(e, u, s, t);
|
|
3184
3293
|
}
|
|
3185
3294
|
}
|
|
3186
|
-
function
|
|
3187
|
-
|
|
3188
|
-
const
|
|
3189
|
-
let
|
|
3190
|
-
for (o === void 0 && typeof t == "function" && (o = t), Object.prototype.toString.call(t) === "[object Object]" && (t.scope && (n = t.scope), t.element && (l = t.element), t.keyup && (
|
|
3191
|
-
e =
|
|
3192
|
-
keyup:
|
|
3295
|
+
function ae(e, t, o) {
|
|
3296
|
+
_ = [];
|
|
3297
|
+
const i = Zo(e);
|
|
3298
|
+
let s = [], n = "all", l = document, a = 0, u = !1, p = !0, y = "+", k = !1, b = !1;
|
|
3299
|
+
for (o === void 0 && typeof t == "function" && (o = t), Object.prototype.toString.call(t) === "[object Object]" && (t.scope && (n = t.scope), t.element && (l = t.element), t.keyup && (u = t.keyup), t.keydown !== void 0 && (p = t.keydown), t.capture !== void 0 && (k = t.capture), typeof t.splitKey == "string" && (y = t.splitKey), t.single === !0 && (b = !0)), typeof t == "string" && (n = t), b && es(e, n); a < i.length; a++)
|
|
3300
|
+
e = i[a].split(y), s = [], e.length > 1 && (s = Yo(te, e)), e = e[e.length - 1], e = e === "*" ? "*" : dt(e), e in B || (B[e] = []), B[e].push({
|
|
3301
|
+
keyup: u,
|
|
3193
3302
|
keydown: p,
|
|
3194
3303
|
scope: n,
|
|
3195
|
-
mods:
|
|
3196
|
-
shortcut:
|
|
3304
|
+
mods: s,
|
|
3305
|
+
shortcut: i[a],
|
|
3197
3306
|
method: o,
|
|
3198
|
-
key:
|
|
3199
|
-
splitKey:
|
|
3307
|
+
key: i[a],
|
|
3308
|
+
splitKey: y,
|
|
3200
3309
|
element: l
|
|
3201
3310
|
});
|
|
3202
3311
|
if (typeof l < "u" && window) {
|
|
3203
|
-
if (!
|
|
3204
|
-
const
|
|
3205
|
-
let
|
|
3206
|
-
return
|
|
3312
|
+
if (!de.has(l)) {
|
|
3313
|
+
const m = function() {
|
|
3314
|
+
let C = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : window.event;
|
|
3315
|
+
return Oo(C, l);
|
|
3207
3316
|
}, S = function() {
|
|
3208
|
-
let
|
|
3209
|
-
|
|
3317
|
+
let C = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : window.event;
|
|
3318
|
+
Oo(C, l), un(C);
|
|
3210
3319
|
};
|
|
3211
|
-
|
|
3212
|
-
keydownListener:
|
|
3320
|
+
de.set(l, {
|
|
3321
|
+
keydownListener: m,
|
|
3213
3322
|
keyupListenr: S,
|
|
3214
|
-
capture:
|
|
3215
|
-
}),
|
|
3323
|
+
capture: k
|
|
3324
|
+
}), qt(l, "keydown", m, k), qt(l, "keyup", S, k);
|
|
3216
3325
|
}
|
|
3217
3326
|
if (!tt) {
|
|
3218
|
-
const
|
|
3219
|
-
|
|
3327
|
+
const m = () => {
|
|
3328
|
+
_ = [];
|
|
3220
3329
|
};
|
|
3221
3330
|
tt = {
|
|
3222
|
-
listener:
|
|
3223
|
-
capture:
|
|
3224
|
-
},
|
|
3331
|
+
listener: m,
|
|
3332
|
+
capture: k
|
|
3333
|
+
}, qt(window, "focus", m, k);
|
|
3225
3334
|
}
|
|
3226
3335
|
}
|
|
3227
3336
|
}
|
|
3228
|
-
function
|
|
3337
|
+
function cn(e) {
|
|
3229
3338
|
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "all";
|
|
3230
3339
|
Object.keys(B).forEach((o) => {
|
|
3231
|
-
B[o].filter((
|
|
3232
|
-
|
|
3340
|
+
B[o].filter((s) => s.scope === t && s.shortcut === e).forEach((s) => {
|
|
3341
|
+
s && s.method && s.method();
|
|
3233
3342
|
});
|
|
3234
3343
|
});
|
|
3235
3344
|
}
|
|
3236
|
-
function
|
|
3345
|
+
function ao(e) {
|
|
3237
3346
|
const t = Object.values(B).flat();
|
|
3238
|
-
if (t.findIndex((
|
|
3347
|
+
if (t.findIndex((i) => {
|
|
3239
3348
|
let {
|
|
3240
|
-
element:
|
|
3241
|
-
} =
|
|
3242
|
-
return
|
|
3349
|
+
element: s
|
|
3350
|
+
} = i;
|
|
3351
|
+
return s === e;
|
|
3243
3352
|
}) < 0) {
|
|
3244
3353
|
const {
|
|
3245
|
-
keydownListener:
|
|
3246
|
-
keyupListenr:
|
|
3354
|
+
keydownListener: i,
|
|
3355
|
+
keyupListenr: s,
|
|
3247
3356
|
capture: n
|
|
3248
|
-
} =
|
|
3249
|
-
|
|
3357
|
+
} = de.get(e) || {};
|
|
3358
|
+
i && s && (Xe(e, "keyup", s, n), Xe(e, "keydown", i, n), de.delete(e));
|
|
3250
3359
|
}
|
|
3251
|
-
if ((t.length <= 0 ||
|
|
3360
|
+
if ((t.length <= 0 || de.size <= 0) && (Object.keys(de).forEach((s) => {
|
|
3252
3361
|
const {
|
|
3253
3362
|
keydownListener: n,
|
|
3254
3363
|
keyupListenr: l,
|
|
3255
3364
|
capture: a
|
|
3256
|
-
} =
|
|
3257
|
-
n && l && (Xe(
|
|
3258
|
-
}),
|
|
3365
|
+
} = de.get(s) || {};
|
|
3366
|
+
n && l && (Xe(s, "keyup", l, a), Xe(s, "keydown", n, a), de.delete(s));
|
|
3367
|
+
}), de.clear(), Object.keys(B).forEach((s) => delete B[s]), tt)) {
|
|
3259
3368
|
const {
|
|
3260
|
-
listener:
|
|
3369
|
+
listener: s,
|
|
3261
3370
|
capture: n
|
|
3262
3371
|
} = tt;
|
|
3263
|
-
Xe(window, "focus",
|
|
3372
|
+
Xe(window, "focus", s, n), tt = null;
|
|
3264
3373
|
}
|
|
3265
3374
|
}
|
|
3266
|
-
const
|
|
3267
|
-
getPressedKeyString:
|
|
3268
|
-
setScope:
|
|
3375
|
+
const Ft = {
|
|
3376
|
+
getPressedKeyString: nn,
|
|
3377
|
+
setScope: Qo,
|
|
3269
3378
|
getScope: lt,
|
|
3270
|
-
deleteScope:
|
|
3271
|
-
getPressedKeyCodes:
|
|
3272
|
-
getAllKeyCodes:
|
|
3273
|
-
isPressed:
|
|
3274
|
-
filter:
|
|
3275
|
-
trigger:
|
|
3276
|
-
unbind:
|
|
3379
|
+
deleteScope: dn,
|
|
3380
|
+
getPressedKeyCodes: sn,
|
|
3381
|
+
getAllKeyCodes: an,
|
|
3382
|
+
isPressed: rn,
|
|
3383
|
+
filter: ln,
|
|
3384
|
+
trigger: cn,
|
|
3385
|
+
unbind: es,
|
|
3277
3386
|
keyMap: at,
|
|
3278
3387
|
modifier: te,
|
|
3279
3388
|
modifierMap: Qe
|
|
3280
3389
|
};
|
|
3281
|
-
for (const e in
|
|
3282
|
-
Object.prototype.hasOwnProperty.call(
|
|
3390
|
+
for (const e in Ft)
|
|
3391
|
+
Object.prototype.hasOwnProperty.call(Ft, e) && (ae[e] = Ft[e]);
|
|
3283
3392
|
if (typeof window < "u") {
|
|
3284
3393
|
const e = window.hotkeys;
|
|
3285
|
-
|
|
3394
|
+
ae.noConflict = (t) => (t && window.hotkeys === ae && (window.hotkeys = e), ae), window.hotkeys = ae;
|
|
3286
3395
|
}
|
|
3287
|
-
const
|
|
3396
|
+
const fn = {
|
|
3288
3397
|
class: "dsg-dropdown--trigger",
|
|
3289
3398
|
tabindex: "0"
|
|
3290
|
-
},
|
|
3399
|
+
}, gn = { class: "dsg-dropdown--menu" }, pn = {
|
|
3291
3400
|
key: 0,
|
|
3292
3401
|
class: "dsg-dropdown--menu-header"
|
|
3293
|
-
},
|
|
3402
|
+
}, hn = {
|
|
3294
3403
|
key: 1,
|
|
3295
3404
|
class: "dsg-dropdown--menu-header"
|
|
3296
|
-
},
|
|
3405
|
+
}, mn = { class: "dsg-dropdown--menu-title" }, bn = {
|
|
3297
3406
|
key: 2,
|
|
3298
3407
|
class: "dsg-dropdown--menu-header subsection"
|
|
3299
|
-
},
|
|
3408
|
+
}, vn = { class: "dsg-dropdown--menu-subtitle" }, wn = ["href", "target", "tabindex", "title", "onClick"], yn = {
|
|
3300
3409
|
key: 0,
|
|
3301
3410
|
class: "dsg-dropdown--menu-item--content"
|
|
3302
|
-
},
|
|
3411
|
+
}, kn = {
|
|
3303
3412
|
key: 0,
|
|
3304
3413
|
class: "dsg-dropdown--menu-item--icon"
|
|
3305
|
-
},
|
|
3414
|
+
}, Cn = { class: "dsg-dropdown--menu-item--label" }, En = { class: "dsg-dropdown--menu-item--hotkey" }, Tn = { key: 0 }, An = {
|
|
3306
3415
|
key: 1,
|
|
3307
3416
|
class: "dsg-dropdown--menu-item--content"
|
|
3308
|
-
},
|
|
3417
|
+
}, Sn = /* @__PURE__ */ H({
|
|
3309
3418
|
__name: "DsgDropdown",
|
|
3310
3419
|
props: {
|
|
3311
3420
|
label: { default: "" },
|
|
@@ -3323,128 +3432,128 @@ const Qi = {
|
|
|
3323
3432
|
distance: { default: 0 }
|
|
3324
3433
|
},
|
|
3325
3434
|
setup(e, { expose: t }) {
|
|
3326
|
-
const o = Y(e.isOpen),
|
|
3327
|
-
e.menuItems.forEach((
|
|
3435
|
+
const o = Y(e.isOpen), i = new pe().getOS().name;
|
|
3436
|
+
e.menuItems.forEach((m) => {
|
|
3328
3437
|
});
|
|
3329
|
-
const
|
|
3438
|
+
const s = we("floatingVueDropdownEl"), n = we("dsgDropdownAvatarTriggerEl"), l = we("dsgDropdownButtonTriggerEl"), a = (m) => {
|
|
3330
3439
|
p(), n.value && setTimeout(() => {
|
|
3331
3440
|
n?.value?.toggleFocus(o.value);
|
|
3332
3441
|
}, 100);
|
|
3333
|
-
},
|
|
3442
|
+
}, u = (m) => {
|
|
3334
3443
|
p(), l.value && setTimeout(() => {
|
|
3335
3444
|
l?.value?.focusButton(o.value);
|
|
3336
3445
|
}, 100);
|
|
3337
3446
|
}, p = () => {
|
|
3338
|
-
o.value = !o.value, o.value ?
|
|
3339
|
-
},
|
|
3340
|
-
S.uri ||
|
|
3341
|
-
},
|
|
3342
|
-
return
|
|
3343
|
-
e.menuItems.forEach((
|
|
3344
|
-
|
|
3345
|
-
|
|
3447
|
+
o.value = !o.value, o.value ? s.value?.show() : s.value?.hide();
|
|
3448
|
+
}, y = (m, S) => {
|
|
3449
|
+
S.uri || m.preventDefault(), S.action && (S.action(), s.value?.hide());
|
|
3450
|
+
}, k = we("dsgDropdown"), b = (m) => (m = m.toLowerCase(), m.replace("ctrl", "⌃").replace("shift", "⇧").replace("alt", "⌥").replace("cmd", i === "macOS" ? "⌘" : "⊞").replace("++", "+").replace("+", "").toUpperCase());
|
|
3451
|
+
return to(() => {
|
|
3452
|
+
e.menuItems.forEach((m) => {
|
|
3453
|
+
m.hotkey && ae(m.hotkey, (S) => {
|
|
3454
|
+
m.hotkeyPreventDefault && m.hotkeyPreventDefault === !0 && S.preventDefault(), m.uri && window.open(m.uri, m.uriTarget ?? "_blank"), typeof m.action == "function" && (m.action(), s.value?.hide());
|
|
3346
3455
|
});
|
|
3347
3456
|
});
|
|
3348
|
-
}),
|
|
3349
|
-
|
|
3457
|
+
}), fs(() => {
|
|
3458
|
+
ae.deleteScope("dsgDropdown");
|
|
3350
3459
|
}), t({
|
|
3351
3460
|
handleTriggerClick: p
|
|
3352
|
-
}), (
|
|
3353
|
-
class:
|
|
3461
|
+
}), (m, S) => (h(), v("div", {
|
|
3462
|
+
class: D(["dsg-dropdown", m.classes]),
|
|
3354
3463
|
ref: "dsgDropdown"
|
|
3355
3464
|
}, [
|
|
3356
|
-
|
|
3465
|
+
I(ge(os), {
|
|
3357
3466
|
triggers: [],
|
|
3358
|
-
placement:
|
|
3467
|
+
placement: m.placement,
|
|
3359
3468
|
"handle-resize": !1,
|
|
3360
3469
|
strategy: "absolute",
|
|
3361
3470
|
shown: o.value,
|
|
3362
3471
|
flip: !1,
|
|
3363
3472
|
shift: !1,
|
|
3364
|
-
boundary:
|
|
3365
|
-
container:
|
|
3366
|
-
skidding:
|
|
3367
|
-
distance:
|
|
3473
|
+
boundary: k.value,
|
|
3474
|
+
container: k.value,
|
|
3475
|
+
skidding: m.skidding,
|
|
3476
|
+
distance: m.distance,
|
|
3368
3477
|
class: "dsg-dropdown--popper",
|
|
3369
|
-
onHide: S[0] || (S[0] = (
|
|
3478
|
+
onHide: S[0] || (S[0] = (C) => o.value = !1),
|
|
3370
3479
|
ref: "floatingVueDropdownEl"
|
|
3371
3480
|
}, {
|
|
3372
|
-
popper:
|
|
3373
|
-
T("div",
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3481
|
+
popper: Vt(() => [
|
|
3482
|
+
T("div", gn, [
|
|
3483
|
+
M(m.$slots, "dsg-dropdown-menu--header", {}, () => [
|
|
3484
|
+
m.headerType === "avatar" ? (h(), v("div", pn, [
|
|
3485
|
+
m.avatarInfo ? (h(), $(ot, {
|
|
3377
3486
|
key: 0,
|
|
3378
3487
|
size: "md",
|
|
3379
|
-
profileUri:
|
|
3380
|
-
fullName:
|
|
3381
|
-
isOnline:
|
|
3382
|
-
title:
|
|
3383
|
-
"sub-text":
|
|
3384
|
-
}, null, 8, ["profileUri", "fullName", "isOnline", "title", "sub-text"])) :
|
|
3385
|
-
])) :
|
|
3386
|
-
T("h3",
|
|
3387
|
-
])) :
|
|
3388
|
-
T("h4",
|
|
3389
|
-
])) :
|
|
3488
|
+
profileUri: m.avatarInfo.profileUri,
|
|
3489
|
+
fullName: m.avatarInfo.fullName,
|
|
3490
|
+
isOnline: m.avatarInfo.isOnline,
|
|
3491
|
+
title: m.avatarInfo.title,
|
|
3492
|
+
"sub-text": m.avatarInfo.subText
|
|
3493
|
+
}, null, 8, ["profileUri", "fullName", "isOnline", "title", "sub-text"])) : w("", !0)
|
|
3494
|
+
])) : m.headerType === "title" ? (h(), v("div", hn, [
|
|
3495
|
+
T("h3", mn, P(m.headerTitle), 1)
|
|
3496
|
+
])) : m.headerType === "subsection" ? (h(), v("div", bn, [
|
|
3497
|
+
T("h4", vn, P(m.headerTitle), 1)
|
|
3498
|
+
])) : w("", !0)
|
|
3390
3499
|
]),
|
|
3391
|
-
|
|
3392
|
-
(
|
|
3393
|
-
class:
|
|
3394
|
-
href:
|
|
3395
|
-
target:
|
|
3396
|
-
tabindex: !
|
|
3397
|
-
title:
|
|
3398
|
-
key:
|
|
3399
|
-
onClick: (
|
|
3500
|
+
M(m.$slots, "dsg-dropdown-menu-content", {}, () => [
|
|
3501
|
+
(h(!0), v(Z, null, ke(m.menuItems, (C, U) => (h(), v("a", {
|
|
3502
|
+
class: D(["dsg-dropdown--menu-item", { "is-divider": C.type === "divider" }]),
|
|
3503
|
+
href: C.uri,
|
|
3504
|
+
target: C.uriTarget ?? "_blank",
|
|
3505
|
+
tabindex: !C.uri && C.type !== "divider" ? 0 : void 0,
|
|
3506
|
+
title: C.label,
|
|
3507
|
+
key: U,
|
|
3508
|
+
onClick: (re) => y(re, C)
|
|
3400
3509
|
}, [
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
icon:
|
|
3510
|
+
C.type === "item" || C.type === void 0 ? (h(), v("div", yn, [
|
|
3511
|
+
C.icon ? (h(), v("div", kn, [
|
|
3512
|
+
I(G, {
|
|
3513
|
+
icon: C.icon,
|
|
3405
3514
|
size: "xs"
|
|
3406
3515
|
}, null, 8, ["icon"])
|
|
3407
|
-
])) :
|
|
3408
|
-
T("span",
|
|
3409
|
-
T("div",
|
|
3410
|
-
|
|
3516
|
+
])) : w("", !0),
|
|
3517
|
+
T("span", Cn, P(C.label), 1),
|
|
3518
|
+
T("div", En, [
|
|
3519
|
+
C.hotkey ? (h(), v("span", Tn, P(b(C.hotkey)), 1)) : w("", !0)
|
|
3411
3520
|
])
|
|
3412
|
-
])) :
|
|
3521
|
+
])) : C.type === "divider" ? (h(), v("div", An, S[1] || (S[1] = [
|
|
3413
3522
|
T("hr", null, null, -1)
|
|
3414
|
-
]))) :
|
|
3415
|
-
], 10,
|
|
3523
|
+
]))) : w("", !0)
|
|
3524
|
+
], 10, wn))), 128))
|
|
3416
3525
|
])
|
|
3417
3526
|
])
|
|
3418
3527
|
]),
|
|
3419
|
-
default:
|
|
3420
|
-
T("div",
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3528
|
+
default: Vt(() => [
|
|
3529
|
+
T("div", fn, [
|
|
3530
|
+
M(m.$slots, "dsg-dropdown--trigger", {}, () => [
|
|
3531
|
+
m.type === "avatar" ? (h(), v(Z, { key: 0 }, [
|
|
3532
|
+
m.avatarInfo ? (h(), $(ot, {
|
|
3424
3533
|
key: 0,
|
|
3425
3534
|
size: "lg",
|
|
3426
|
-
profileUri:
|
|
3427
|
-
fullName:
|
|
3535
|
+
profileUri: m.avatarInfo.profileUri,
|
|
3536
|
+
fullName: m.avatarInfo.fullName,
|
|
3428
3537
|
ref: "dsgDropdownAvatarTriggerEl",
|
|
3429
3538
|
onClick: a,
|
|
3430
3539
|
"prevent-default": !0
|
|
3431
|
-
}, null, 8, ["profileUri", "fullName"])) :
|
|
3432
|
-
], 64)) :
|
|
3540
|
+
}, null, 8, ["profileUri", "fullName"])) : w("", !0)
|
|
3541
|
+
], 64)) : m.type === "button" ? (h(), $(_e, {
|
|
3433
3542
|
key: 1,
|
|
3434
|
-
theme:
|
|
3435
|
-
label:
|
|
3436
|
-
onClick:
|
|
3543
|
+
theme: m.buttonTheme,
|
|
3544
|
+
label: m.label,
|
|
3545
|
+
onClick: u,
|
|
3437
3546
|
ref: "dsgDropdownButtonTriggerEl",
|
|
3438
3547
|
"icon-after": "chevron-down",
|
|
3439
|
-
class:
|
|
3440
|
-
}, null, 8, ["theme", "label", "class"])) :
|
|
3548
|
+
class: D({ "dropdown-active": o.value })
|
|
3549
|
+
}, null, 8, ["theme", "label", "class"])) : m.type === "icon" ? (h(), $(_e, {
|
|
3441
3550
|
key: 2,
|
|
3442
|
-
"icon-before":
|
|
3551
|
+
"icon-before": m.icon,
|
|
3443
3552
|
size: "sm",
|
|
3444
|
-
theme:
|
|
3445
|
-
class:
|
|
3553
|
+
theme: m.buttonTheme,
|
|
3554
|
+
class: D(["dsg-dropdown--trigger-button", { "dropdown-active": o.value }]),
|
|
3446
3555
|
onClick: p
|
|
3447
|
-
}, null, 8, ["icon-before", "theme", "class"])) :
|
|
3556
|
+
}, null, 8, ["icon-before", "theme", "class"])) : w("", !0)
|
|
3448
3557
|
])
|
|
3449
3558
|
])
|
|
3450
3559
|
]),
|
|
@@ -3452,9 +3561,9 @@ const Qi = {
|
|
|
3452
3561
|
}, 8, ["placement", "shown", "boundary", "container", "skidding", "distance"])
|
|
3453
3562
|
], 2));
|
|
3454
3563
|
}
|
|
3455
|
-
}),
|
|
3564
|
+
}), On = ["name"], $n = ["selected"], Ln = ["value", "selected"], In = /* @__PURE__ */ H({
|
|
3456
3565
|
__name: "DsgInputDropdown",
|
|
3457
|
-
props: /* @__PURE__ */
|
|
3566
|
+
props: /* @__PURE__ */ Bo({
|
|
3458
3567
|
name: { default: "" },
|
|
3459
3568
|
placeholder: { default: "" },
|
|
3460
3569
|
classes: { default: "" },
|
|
@@ -3465,31 +3574,31 @@ const Qi = {
|
|
|
3465
3574
|
}),
|
|
3466
3575
|
emits: ["update:modelValue"],
|
|
3467
3576
|
setup(e) {
|
|
3468
|
-
const t =
|
|
3469
|
-
return (o,
|
|
3470
|
-
class:
|
|
3577
|
+
const t = Do(e, "modelValue");
|
|
3578
|
+
return (o, i) => Po((h(), v("select", {
|
|
3579
|
+
class: D(["dsg-input-dropdown", o.classes]),
|
|
3471
3580
|
name: o.name,
|
|
3472
|
-
"onUpdate:modelValue":
|
|
3581
|
+
"onUpdate:modelValue": i[0] || (i[0] = (s) => t.value = s)
|
|
3473
3582
|
}, [
|
|
3474
|
-
o.placeholder ? (
|
|
3583
|
+
o.placeholder ? (h(), v("option", {
|
|
3475
3584
|
key: 0,
|
|
3476
3585
|
value: "",
|
|
3477
3586
|
disabled: "",
|
|
3478
3587
|
selected: t.value === ""
|
|
3479
|
-
},
|
|
3480
|
-
(
|
|
3588
|
+
}, P(o.placeholder), 9, $n)) : w("", !0),
|
|
3589
|
+
(h(!0), v(Z, null, ke(o.options, (s, n) => (h(), v("option", {
|
|
3481
3590
|
key: n,
|
|
3482
|
-
value:
|
|
3483
|
-
selected: t.value ===
|
|
3484
|
-
},
|
|
3485
|
-
], 10,
|
|
3486
|
-
[
|
|
3591
|
+
value: s.value,
|
|
3592
|
+
selected: t.value === s.value
|
|
3593
|
+
}, P(s.label), 9, Ln))), 128))
|
|
3594
|
+
], 10, On)), [
|
|
3595
|
+
[gs, t.value]
|
|
3487
3596
|
]);
|
|
3488
3597
|
}
|
|
3489
|
-
}),
|
|
3598
|
+
}), _n = ["href", "title", "target"], Bn = {
|
|
3490
3599
|
key: 0,
|
|
3491
3600
|
class: "dsg-link--label"
|
|
3492
|
-
},
|
|
3601
|
+
}, Dn = /* @__PURE__ */ H({
|
|
3493
3602
|
__name: "DsgLink",
|
|
3494
3603
|
props: {
|
|
3495
3604
|
label: { default: "Link" },
|
|
@@ -3505,34 +3614,34 @@ const Qi = {
|
|
|
3505
3614
|
"dsg-link",
|
|
3506
3615
|
"dsg-link--" + e.size,
|
|
3507
3616
|
e.classes
|
|
3508
|
-
].join(" "),
|
|
3509
|
-
e.preventDefault && n.preventDefault(),
|
|
3617
|
+
].join(" "), i = t, s = (n) => {
|
|
3618
|
+
e.preventDefault && n.preventDefault(), i("link-clicked", n);
|
|
3510
3619
|
};
|
|
3511
|
-
return (n, l) => (
|
|
3620
|
+
return (n, l) => (h(), v("a", {
|
|
3512
3621
|
href: n.href,
|
|
3513
3622
|
title: "Link: " + n.label,
|
|
3514
3623
|
target: n.uriTarget,
|
|
3515
|
-
class:
|
|
3516
|
-
onClick:
|
|
3624
|
+
class: D(ge(o)),
|
|
3625
|
+
onClick: s
|
|
3517
3626
|
}, [
|
|
3518
|
-
|
|
3519
|
-
n.label ? (
|
|
3627
|
+
M(n.$slots, "dsg-link-content", {}, () => [
|
|
3628
|
+
n.label ? (h(), v("span", Bn, P(n.label), 1)) : w("", !0)
|
|
3520
3629
|
])
|
|
3521
|
-
], 10,
|
|
3630
|
+
], 10, _n));
|
|
3522
3631
|
}
|
|
3523
|
-
}),
|
|
3632
|
+
}), Pn = {
|
|
3524
3633
|
key: 1,
|
|
3525
3634
|
class: "dsg-modal__header-text"
|
|
3526
|
-
},
|
|
3635
|
+
}, Nn = {
|
|
3527
3636
|
key: 0,
|
|
3528
3637
|
class: "dsg-modal__header-title"
|
|
3529
|
-
},
|
|
3638
|
+
}, Mn = {
|
|
3530
3639
|
key: 1,
|
|
3531
3640
|
class: "dsg-modal__header-description"
|
|
3532
|
-
},
|
|
3641
|
+
}, xn = {
|
|
3533
3642
|
key: 1,
|
|
3534
3643
|
class: "dsg-modal__body"
|
|
3535
|
-
},
|
|
3644
|
+
}, Un = /* @__PURE__ */ H({
|
|
3536
3645
|
__name: "DsgModal",
|
|
3537
3646
|
props: {
|
|
3538
3647
|
title: { default: "" },
|
|
@@ -3547,66 +3656,66 @@ const Qi = {
|
|
|
3547
3656
|
},
|
|
3548
3657
|
emits: ["before-open", "after-open", "before-close", "after-close", "secondary-button-clicked", "primary-button-clicked"],
|
|
3549
3658
|
setup(e, { expose: t, emit: o }) {
|
|
3550
|
-
const
|
|
3551
|
-
|
|
3659
|
+
const i = o, s = Y(!1), n = () => {
|
|
3660
|
+
i("before-open"), s.value = !0, i("after-open");
|
|
3552
3661
|
}, l = () => {
|
|
3553
|
-
|
|
3662
|
+
i("before-close"), s.value = !1, i("after-close");
|
|
3554
3663
|
}, a = () => {
|
|
3555
|
-
|
|
3556
|
-
},
|
|
3557
|
-
|
|
3664
|
+
i("secondary-button-clicked");
|
|
3665
|
+
}, u = () => {
|
|
3666
|
+
i("primary-button-clicked");
|
|
3558
3667
|
};
|
|
3559
|
-
return t({ open: n, close: l, secondaryButtonClicked: a, primaryButtonClicked:
|
|
3560
|
-
class:
|
|
3668
|
+
return t({ open: n, close: l, secondaryButtonClicked: a, primaryButtonClicked: u }), (p, y) => (h(), v("div", {
|
|
3669
|
+
class: D(["dsg-modal", `dsg-modal--${s.value ? "open" : "closed"}`])
|
|
3561
3670
|
}, [
|
|
3562
|
-
|
|
3671
|
+
y[0] || (y[0] = T("div", { class: "dsg-modal__background" }, null, -1)),
|
|
3563
3672
|
T("div", {
|
|
3564
3673
|
class: "dsg-modal__wrapper",
|
|
3565
|
-
style:
|
|
3674
|
+
style: No({ width: p.width })
|
|
3566
3675
|
}, [
|
|
3567
|
-
p.hasClosedButton ? (
|
|
3676
|
+
p.hasClosedButton ? (h(), $(_e, {
|
|
3568
3677
|
key: 0,
|
|
3569
3678
|
theme: "gray-tertiary",
|
|
3570
3679
|
iconBefore: "x",
|
|
3571
3680
|
size: "lg",
|
|
3572
|
-
class:
|
|
3681
|
+
class: D(["dsg-modal__close-button", `dsg-modal__close-button--${p.type}`]),
|
|
3573
3682
|
onClick: l
|
|
3574
|
-
}, null, 8, ["class"])) :
|
|
3575
|
-
|
|
3683
|
+
}, null, 8, ["class"])) : w("", !0),
|
|
3684
|
+
M(p.$slots, "dsg-modal__header", {}, () => [
|
|
3576
3685
|
T("div", {
|
|
3577
|
-
class:
|
|
3686
|
+
class: D(["dsg-modal__header", [`dsg-modal__header--${p.type}`, `${p.$slots.default ? "dsg-modal__header--with-body" : ""}`].join(" ")])
|
|
3578
3687
|
}, [
|
|
3579
|
-
p.miscIcon ? (
|
|
3580
|
-
p.title || p.description ? (
|
|
3581
|
-
p.title ? (
|
|
3582
|
-
p.description ? (
|
|
3583
|
-
])) :
|
|
3688
|
+
p.miscIcon ? (h(), $(Ie, Lo(J({ key: 0 }, p.miscIcon)), null, 16)) : w("", !0),
|
|
3689
|
+
p.title || p.description ? (h(), v("div", Pn, [
|
|
3690
|
+
p.title ? (h(), v("h3", Nn, P(p.title), 1)) : w("", !0),
|
|
3691
|
+
p.description ? (h(), v("p", Mn, P(p.description), 1)) : w("", !0)
|
|
3692
|
+
])) : w("", !0)
|
|
3584
3693
|
], 2)
|
|
3585
3694
|
]),
|
|
3586
|
-
p.$slots.default ? (
|
|
3587
|
-
|
|
3588
|
-
])) :
|
|
3589
|
-
|
|
3695
|
+
p.$slots.default ? (h(), v("div", xn, [
|
|
3696
|
+
M(p.$slots, "default")
|
|
3697
|
+
])) : w("", !0),
|
|
3698
|
+
M(p.$slots, "dsg-modal__footer", {}, () => [
|
|
3590
3699
|
T("div", {
|
|
3591
|
-
class:
|
|
3700
|
+
class: D(["dsg-modal__footer", `dsg-modal__footer--${p.footerType}`])
|
|
3592
3701
|
}, [
|
|
3593
|
-
p.secondaryButton ? (
|
|
3702
|
+
p.secondaryButton ? (h(), $(_e, J({ key: 0 }, p.secondaryButton, {
|
|
3594
3703
|
onButtonClicked: a,
|
|
3595
3704
|
classes: "dsg-modal__secondary-button"
|
|
3596
|
-
}), null, 16)) :
|
|
3597
|
-
p.primaryButton ? (
|
|
3598
|
-
onButtonClicked:
|
|
3705
|
+
}), null, 16)) : w("", !0),
|
|
3706
|
+
p.primaryButton ? (h(), $(_e, J({ key: 1 }, p.primaryButton, {
|
|
3707
|
+
onButtonClicked: u,
|
|
3599
3708
|
classes: "dsg-dsg-modal__primary-button"
|
|
3600
|
-
}), null, 16)) :
|
|
3709
|
+
}), null, 16)) : w("", !0)
|
|
3601
3710
|
], 2)
|
|
3602
3711
|
])
|
|
3603
3712
|
], 4)
|
|
3604
3713
|
], 2));
|
|
3605
3714
|
}
|
|
3606
|
-
}),
|
|
3715
|
+
}), Rn = { class: "dsg-tag--before" }, zn = { class: "dsg-tag--label" }, Hn = { class: "dsg-tag--after" }, qn = {
|
|
3607
3716
|
key: 0,
|
|
3608
3717
|
class: "dsg-tag--count"
|
|
3609
|
-
},
|
|
3718
|
+
}, Fn = /* @__PURE__ */ H({
|
|
3610
3719
|
__name: "DsgTag",
|
|
3611
3720
|
props: {
|
|
3612
3721
|
label: { default: "" },
|
|
@@ -3622,7 +3731,7 @@ const Qi = {
|
|
|
3622
3731
|
},
|
|
3623
3732
|
emits: ["before-checked", "after-checked", "before-hide", "after-hide", "before-destroy", "after-destroy"],
|
|
3624
3733
|
setup(e, { expose: t, emit: o }) {
|
|
3625
|
-
const
|
|
3734
|
+
const i = [
|
|
3626
3735
|
"dsg-tag",
|
|
3627
3736
|
`dsg-tag--${e.size}`,
|
|
3628
3737
|
`dsg-tag--${e.hasClose ? "has-close" : "no-close"}`,
|
|
@@ -3630,67 +3739,67 @@ const Qi = {
|
|
|
3630
3739
|
`dsg-tag--${e.avatarUri ? "has-avatar" : "no-avatar"}`,
|
|
3631
3740
|
`dsg-tag--${e.hasCheckbox ? "has-checkbox" : "no-checkbox"}`,
|
|
3632
3741
|
e.classes
|
|
3633
|
-
].join(" "),
|
|
3742
|
+
].join(" "), s = () => `tag-${e.size}`;
|
|
3634
3743
|
e.hasClose && e.tagCount !== null && new ne("DsgTag: 'hasClose' and 'tagCount' props are mutually exclusive. Please use only one of them."), e.avatarUri && e.dotHex && new ne("DsgTag: 'avatarUri' and 'dotHex' props are mutually exclusive. Please use only one of them.");
|
|
3635
|
-
const n = o, l = we("dsgTag"), a = (
|
|
3744
|
+
const n = o, l = we("dsgTag"), a = (C) => {
|
|
3636
3745
|
e.destroyOnClose ? (n("before-destroy", l.value), l.value?.remove(), n("after-destroy")) : (n("before-hide", l.value), l.value && (l.value.style.display = "none"), n("after-hide", l.value));
|
|
3637
|
-
},
|
|
3638
|
-
n("before-checked",
|
|
3639
|
-
}, p = (
|
|
3640
|
-
n("after-checked",
|
|
3641
|
-
},
|
|
3642
|
-
|
|
3643
|
-
},
|
|
3746
|
+
}, u = (C, U) => {
|
|
3747
|
+
n("before-checked", C, U);
|
|
3748
|
+
}, p = (C) => {
|
|
3749
|
+
n("after-checked", C);
|
|
3750
|
+
}, y = Y(e.tagCount), k = (C) => {
|
|
3751
|
+
y.value = C;
|
|
3752
|
+
}, b = Y(e.value);
|
|
3644
3753
|
return t({
|
|
3645
|
-
setTagCount:
|
|
3646
|
-
setValue: (
|
|
3647
|
-
|
|
3754
|
+
setTagCount: k,
|
|
3755
|
+
setValue: (C) => {
|
|
3756
|
+
b.value = C;
|
|
3648
3757
|
},
|
|
3649
|
-
getValue: () =>
|
|
3650
|
-
}), (
|
|
3651
|
-
class:
|
|
3758
|
+
getValue: () => b.value
|
|
3759
|
+
}), (C, U) => (h(), v("div", {
|
|
3760
|
+
class: D(ge(i)),
|
|
3652
3761
|
ref: "dsgTag"
|
|
3653
3762
|
}, [
|
|
3654
|
-
T("div",
|
|
3655
|
-
|
|
3763
|
+
T("div", Rn, [
|
|
3764
|
+
C.hasCheckbox ? (h(), $(yt, {
|
|
3656
3765
|
key: 0,
|
|
3657
3766
|
class: "dsg-tag--checkbox",
|
|
3658
|
-
size:
|
|
3767
|
+
size: s(),
|
|
3659
3768
|
"no-focus": !0,
|
|
3660
|
-
onBeforeChecked:
|
|
3769
|
+
onBeforeChecked: u,
|
|
3661
3770
|
onAfterChecked: p
|
|
3662
|
-
}, null, 8, ["size"])) :
|
|
3663
|
-
|
|
3771
|
+
}, null, 8, ["size"])) : w("", !0),
|
|
3772
|
+
C.avatarUri ? (h(), $(ot, {
|
|
3664
3773
|
key: 1,
|
|
3665
|
-
"profile-uri":
|
|
3774
|
+
"profile-uri": C.avatarUri,
|
|
3666
3775
|
size: "xxs",
|
|
3667
3776
|
"no-focus": !0,
|
|
3668
3777
|
class: "dsg-tag--avatar"
|
|
3669
|
-
}, null, 8, ["profile-uri"])) :
|
|
3670
|
-
|
|
3778
|
+
}, null, 8, ["profile-uri"])) : w("", !0),
|
|
3779
|
+
C.dotHex ? (h(), v("span", {
|
|
3671
3780
|
key: 2,
|
|
3672
3781
|
class: "dsg-tag--dot",
|
|
3673
|
-
style:
|
|
3674
|
-
}, null, 4)) :
|
|
3782
|
+
style: No({ backgroundColor: C.dotHex })
|
|
3783
|
+
}, null, 4)) : w("", !0)
|
|
3675
3784
|
]),
|
|
3676
|
-
|
|
3677
|
-
T("span",
|
|
3785
|
+
M(C.$slots, "dsg-tag--label", {}, () => [
|
|
3786
|
+
T("span", zn, P(C.label), 1)
|
|
3678
3787
|
]),
|
|
3679
|
-
T("div",
|
|
3680
|
-
|
|
3681
|
-
|
|
3788
|
+
T("div", Hn, [
|
|
3789
|
+
y.value && y.value > 0 ? (h(), v("div", qn, P(y.value), 1)) : w("", !0),
|
|
3790
|
+
C.hasClose ? (h(), $(G, {
|
|
3682
3791
|
key: 1,
|
|
3683
3792
|
icon: "x-close",
|
|
3684
3793
|
class: "dsg-tag--close",
|
|
3685
3794
|
onClick: a
|
|
3686
|
-
})) :
|
|
3795
|
+
})) : w("", !0)
|
|
3687
3796
|
])
|
|
3688
3797
|
], 2));
|
|
3689
3798
|
}
|
|
3690
|
-
}),
|
|
3799
|
+
}), Vn = { class: "dsg-toggle--element" }, jn = ["checked", "disabled"], Kn = {
|
|
3691
3800
|
key: 0,
|
|
3692
3801
|
class: "dsg-toggle--label-wrapper"
|
|
3693
|
-
},
|
|
3802
|
+
}, Gn = ["innerHTML"], Wn = ["innerHTML"], Xn = /* @__PURE__ */ H({
|
|
3694
3803
|
__name: "DsgToggle",
|
|
3695
3804
|
props: {
|
|
3696
3805
|
modelValue: { type: Boolean, default: !1 },
|
|
@@ -3702,55 +3811,55 @@ const Qi = {
|
|
|
3702
3811
|
},
|
|
3703
3812
|
emits: ["before-toggle", "after-toggle", "update:modelValue"],
|
|
3704
3813
|
setup(e, { expose: t, emit: o }) {
|
|
3705
|
-
const
|
|
3814
|
+
const i = [
|
|
3706
3815
|
"dsg-toggle",
|
|
3707
3816
|
`dsg-toggle--${e.size}`,
|
|
3708
3817
|
`dsg-toggle--${e.disabled ? "disabled" : "enabled"}`,
|
|
3709
3818
|
`dsg-toggle--${e.label.length ? "has-label" : "no-label"}`,
|
|
3710
3819
|
`dsg-toggle--${e.subText.length ? "has-subtext" : "no-subtext"}`,
|
|
3711
3820
|
e.classes
|
|
3712
|
-
].join(" "),
|
|
3713
|
-
e.disabled || (
|
|
3821
|
+
].join(" "), s = Y(e.modelValue), n = () => {
|
|
3822
|
+
e.disabled || (u("before-toggle", s.value, !s.value), s.value = !s.value, u("after-toggle", s.value), u("update:modelValue", s.value));
|
|
3714
3823
|
}, l = we("toggleCheckbox"), a = () => {
|
|
3715
3824
|
l.value && l.value.focus(), e.disabled || n();
|
|
3716
|
-
},
|
|
3825
|
+
}, u = o;
|
|
3717
3826
|
return t({
|
|
3718
|
-
set: (
|
|
3719
|
-
|
|
3827
|
+
set: (y) => {
|
|
3828
|
+
s.value = y;
|
|
3720
3829
|
}
|
|
3721
|
-
}), (
|
|
3722
|
-
class:
|
|
3830
|
+
}), (y, k) => (h(), v("div", {
|
|
3831
|
+
class: D(ge(i)),
|
|
3723
3832
|
onClick: a
|
|
3724
3833
|
}, [
|
|
3725
|
-
T("label",
|
|
3834
|
+
T("label", Vn, [
|
|
3726
3835
|
T("input", {
|
|
3727
3836
|
type: "checkbox",
|
|
3728
3837
|
class: "dsg-toggle--checkbox",
|
|
3729
|
-
checked:
|
|
3838
|
+
checked: s.value,
|
|
3730
3839
|
onChange: n,
|
|
3731
3840
|
title: "checkbox",
|
|
3732
3841
|
ref: "toggleCheckbox",
|
|
3733
|
-
disabled:
|
|
3734
|
-
}, null, 40,
|
|
3735
|
-
|
|
3842
|
+
disabled: y.disabled
|
|
3843
|
+
}, null, 40, jn),
|
|
3844
|
+
k[0] || (k[0] = T("span", { class: "dsg-toggle--slider" }, null, -1))
|
|
3736
3845
|
]),
|
|
3737
|
-
|
|
3738
|
-
|
|
3846
|
+
y.label.length ? (h(), v("div", Kn, [
|
|
3847
|
+
M(y.$slots, "dsg-toggle--label", {}, () => [
|
|
3739
3848
|
T("h3", {
|
|
3740
3849
|
class: "dsg-toggle--label",
|
|
3741
|
-
innerHTML:
|
|
3742
|
-
}, null, 8,
|
|
3850
|
+
innerHTML: y.label
|
|
3851
|
+
}, null, 8, Gn)
|
|
3743
3852
|
]),
|
|
3744
|
-
|
|
3853
|
+
y.label.length && y.subText.length ? M(y.$slots, "dsg-toggle--subtext", { key: 0 }, () => [
|
|
3745
3854
|
T("p", {
|
|
3746
3855
|
class: "dsg-toggle--subtext",
|
|
3747
|
-
innerHTML:
|
|
3748
|
-
}, null, 8,
|
|
3749
|
-
]) :
|
|
3750
|
-
])) :
|
|
3856
|
+
innerHTML: y.subText
|
|
3857
|
+
}, null, 8, Wn)
|
|
3858
|
+
]) : w("", !0)
|
|
3859
|
+
])) : w("", !0)
|
|
3751
3860
|
], 2));
|
|
3752
3861
|
}
|
|
3753
|
-
}),
|
|
3862
|
+
}), Yn = { key: 1 }, Zn = /* @__PURE__ */ H({
|
|
3754
3863
|
__name: "DsgBreadcrumb",
|
|
3755
3864
|
props: {
|
|
3756
3865
|
breadcrumbs: { default: () => [] },
|
|
@@ -3762,161 +3871,171 @@ const Qi = {
|
|
|
3762
3871
|
theme: { default: "text" }
|
|
3763
3872
|
},
|
|
3764
3873
|
setup(e) {
|
|
3765
|
-
return (t, o) => (
|
|
3766
|
-
class:
|
|
3874
|
+
return (t, o) => (h(), v("div", {
|
|
3875
|
+
class: D(["dsg-breadcrumbs", "dsg-breadcrumbs"])
|
|
3767
3876
|
}, [
|
|
3768
|
-
(
|
|
3769
|
-
key: `breadcrumb-item-${
|
|
3877
|
+
(h(!0), v(Z, null, ke(t.breadcrumbs, (i, s) => (h(), v(Z, {
|
|
3878
|
+
key: `breadcrumb-item-${s}`
|
|
3770
3879
|
}, [
|
|
3771
|
-
(
|
|
3772
|
-
href:
|
|
3773
|
-
disabled:
|
|
3774
|
-
class:
|
|
3880
|
+
(h(), $(ps(i.url ?? !1 ? "a" : "span"), {
|
|
3881
|
+
href: i.url ?? null,
|
|
3882
|
+
disabled: i.disabled,
|
|
3883
|
+
class: D(
|
|
3775
3884
|
[
|
|
3776
3885
|
"dsg-breadcrumbs__button-base",
|
|
3777
3886
|
`dsg-breadcrumbs__button-base--${t.theme}`,
|
|
3778
|
-
`${
|
|
3887
|
+
`${i.active ?? s === t.breadcrumbs.length - 1 ? "dsg-breadcrumbs__button-base--active" : ""}`
|
|
3779
3888
|
].join(" ")
|
|
3780
3889
|
)
|
|
3781
3890
|
}, {
|
|
3782
|
-
default:
|
|
3783
|
-
|
|
3891
|
+
default: Vt(() => [
|
|
3892
|
+
i.icon && i.useIcon ? (h(), $(G, {
|
|
3784
3893
|
key: 0,
|
|
3785
|
-
icon:
|
|
3894
|
+
icon: i.icon,
|
|
3786
3895
|
size: "sm",
|
|
3787
3896
|
classes: "dsg-breadcrumbs__icon"
|
|
3788
|
-
}, null, 8, ["icon"])) : (
|
|
3897
|
+
}, null, 8, ["icon"])) : (h(), v("span", Yn, P(i.label), 1))
|
|
3789
3898
|
]),
|
|
3790
3899
|
_: 2
|
|
3791
3900
|
}, 1032, ["href", "disabled", "class"])),
|
|
3792
|
-
|
|
3901
|
+
s < t.breadcrumbs.length - 1 ? (h(), $(G, J({
|
|
3793
3902
|
key: 0,
|
|
3794
3903
|
ref_for: !0
|
|
3795
|
-
}, t.divider, { class: "dsg-breadcrumbs__divider" }), null, 16)) :
|
|
3904
|
+
}, t.divider, { class: "dsg-breadcrumbs__divider" }), null, 16)) : w("", !0)
|
|
3796
3905
|
], 64))), 128))
|
|
3797
3906
|
]));
|
|
3798
3907
|
}
|
|
3799
|
-
}),
|
|
3908
|
+
}), Jn = /* @__PURE__ */ Mo(Zn, [["__scopeId", "data-v-8f108e12"]]), Qn = { class: "dsg-tab" }, ea = { class: "dsg-tab--mobile" }, ta = {
|
|
3800
3909
|
"aria-label": "Select a tab",
|
|
3801
3910
|
class: "dsg-tab--mobile-select"
|
|
3802
|
-
},
|
|
3911
|
+
}, oa = ["selected", "textContent"], sa = { class: "dsg-tab--desktop" }, ia = { class: "dsg-tab--desktop-wrapper" }, na = {
|
|
3803
3912
|
class: "dsg-tab--desktop-nav",
|
|
3804
3913
|
"aria-label": "Tabs"
|
|
3805
|
-
},
|
|
3914
|
+
}, aa = ["href", "onClick", "aria-current"], la = ["textContent"], ra = {
|
|
3806
3915
|
key: 0,
|
|
3807
3916
|
class: "dsg-tab--content"
|
|
3808
|
-
},
|
|
3917
|
+
}, da = /* @__PURE__ */ H({
|
|
3809
3918
|
__name: "DsgTab",
|
|
3810
3919
|
props: {
|
|
3811
3920
|
tabs: { default: () => [] },
|
|
3812
3921
|
preventVisits: { type: Boolean, default: !0 },
|
|
3813
3922
|
useWindowLocation: { type: Boolean, default: !1 },
|
|
3923
|
+
replaceState: { type: Boolean, default: !1 },
|
|
3924
|
+
replaceStrategy: { default: "window" },
|
|
3814
3925
|
useSlots: { type: Boolean, default: !1 },
|
|
3815
3926
|
selfUpdate: { type: Boolean, default: !0 },
|
|
3816
3927
|
teleportSlotTo: {}
|
|
3817
3928
|
},
|
|
3818
3929
|
emits: ["tab-clicked"],
|
|
3819
3930
|
setup(e, { emit: t }) {
|
|
3820
|
-
const o = t,
|
|
3931
|
+
const o = t, i = (n) => {
|
|
3821
3932
|
e.tabs.forEach((l) => {
|
|
3822
3933
|
l.current = n.name === l.name;
|
|
3823
3934
|
});
|
|
3824
|
-
},
|
|
3825
|
-
e.preventVisits && o("tab-clicked", n), e.useWindowLocation && (window.location.href = n.href), e.
|
|
3935
|
+
}, s = (n) => {
|
|
3936
|
+
if (e.preventVisits && o("tab-clicked", n), e.useWindowLocation && (window.location.href = n.href), e.replaceState) {
|
|
3937
|
+
const l = new URL(window.location.href), a = new URLSearchParams(l.search);
|
|
3938
|
+
a.set("tab", n.key);
|
|
3939
|
+
const u = `${l.origin}${l.pathname}?${a.toString()}`;
|
|
3940
|
+
e.replaceStrategy === "window" && window.history.replaceState({}, "", u);
|
|
3941
|
+
}
|
|
3942
|
+
e.selfUpdate && i(n);
|
|
3826
3943
|
};
|
|
3827
|
-
return (n, l) => (
|
|
3828
|
-
T("div",
|
|
3829
|
-
T("select",
|
|
3830
|
-
(
|
|
3944
|
+
return (n, l) => (h(), v("div", Qn, [
|
|
3945
|
+
T("div", ea, [
|
|
3946
|
+
T("select", ta, [
|
|
3947
|
+
(h(!0), v(Z, null, ke(n.tabs, (a) => (h(), v("option", {
|
|
3831
3948
|
key: a.name,
|
|
3832
3949
|
selected: a.current,
|
|
3833
|
-
textContent:
|
|
3834
|
-
}, null, 8,
|
|
3950
|
+
textContent: P(a.name)
|
|
3951
|
+
}, null, 8, oa))), 128))
|
|
3835
3952
|
]),
|
|
3836
|
-
|
|
3953
|
+
I(G, {
|
|
3837
3954
|
class: "dsg-tab--mobile-select-icon",
|
|
3838
3955
|
icon: "chevron-down",
|
|
3839
3956
|
"aria-hidden": "true",
|
|
3840
3957
|
size: "sm"
|
|
3841
3958
|
})
|
|
3842
3959
|
]),
|
|
3843
|
-
T("div",
|
|
3844
|
-
T("div",
|
|
3845
|
-
T("div",
|
|
3846
|
-
(
|
|
3960
|
+
T("div", sa, [
|
|
3961
|
+
T("div", ia, [
|
|
3962
|
+
T("div", na, [
|
|
3963
|
+
(h(!0), v(Z, null, ke(n.tabs, (a) => (h(), v("a", {
|
|
3847
3964
|
key: a.name,
|
|
3848
3965
|
href: a.href,
|
|
3849
|
-
onClick:
|
|
3850
|
-
class:
|
|
3966
|
+
onClick: hs((u) => s(a), ["prevent"]),
|
|
3967
|
+
class: D(["dsg-tab--desktop-link", a.current ? "link-active" : "link-inactive"]),
|
|
3851
3968
|
"aria-current": a.current ? "page" : void 0
|
|
3852
3969
|
}, [
|
|
3853
3970
|
T("span", {
|
|
3854
3971
|
class: "dsg-tab--desktop-link-label",
|
|
3855
|
-
textContent:
|
|
3856
|
-
}, null, 8,
|
|
3857
|
-
a.badge ? (
|
|
3972
|
+
textContent: P(a.name)
|
|
3973
|
+
}, null, 8, la),
|
|
3974
|
+
a.badge ? (h(), $(Ko, {
|
|
3858
3975
|
key: 0,
|
|
3859
3976
|
label: a.badge.label,
|
|
3860
3977
|
"theme-color": a.current ? "brand" : "gray",
|
|
3861
3978
|
theme: "pill-color",
|
|
3862
3979
|
size: "sm"
|
|
3863
|
-
}, null, 8, ["label", "theme-color"])) :
|
|
3864
|
-
], 10,
|
|
3980
|
+
}, null, 8, ["label", "theme-color"])) : w("", !0)
|
|
3981
|
+
], 10, aa))), 128))
|
|
3865
3982
|
])
|
|
3866
3983
|
])
|
|
3867
3984
|
]),
|
|
3868
|
-
n.useSlots ? (
|
|
3869
|
-
(
|
|
3870
|
-
a.current ?
|
|
3985
|
+
n.useSlots ? (h(), v("div", ra, [
|
|
3986
|
+
(h(!0), v(Z, null, ke(n.tabs, (a, u) => (h(), v(Z, null, [
|
|
3987
|
+
a.current ? M(n.$slots, `dsg-tab--content--${String(a.key).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g, "-").replace(/-+/g, "-")}`, {
|
|
3871
3988
|
key: 0,
|
|
3872
3989
|
data: a
|
|
3873
|
-
}) :
|
|
3990
|
+
}) : w("", !0)
|
|
3874
3991
|
], 64))), 256))
|
|
3875
|
-
])) :
|
|
3992
|
+
])) : w("", !0)
|
|
3876
3993
|
]));
|
|
3877
3994
|
}
|
|
3878
|
-
}),
|
|
3879
|
-
DsgIcon:
|
|
3880
|
-
DsgMiscIcon:
|
|
3881
|
-
DsgCreditCardIcon:
|
|
3882
|
-
DsgAlert:
|
|
3883
|
-
DsgAvatar:
|
|
3884
|
-
DsgBadge:
|
|
3885
|
-
DsgButton:
|
|
3886
|
-
DsgCheckbox:
|
|
3887
|
-
|
|
3888
|
-
|
|
3889
|
-
|
|
3890
|
-
|
|
3891
|
-
|
|
3892
|
-
|
|
3893
|
-
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3995
|
+
}), ua = G, ca = Ie, fa = ss, ga = Ai, pa = ot, ha = Ko, ma = _e, ba = yt, va = Hi, wa = Sn, ya = is, ka = In, Ca = ns, Ea = as, Ta = Dn, Aa = Un, Sa = Fn, Oa = Xn, $a = $o, La = Jn, Ia = da, Pa = {
|
|
3996
|
+
DsgIcon: ua,
|
|
3997
|
+
DsgMiscIcon: ca,
|
|
3998
|
+
DsgCreditCardIcon: fa,
|
|
3999
|
+
DsgAlert: ga,
|
|
4000
|
+
DsgAvatar: pa,
|
|
4001
|
+
DsgBadge: ha,
|
|
4002
|
+
DsgButton: ma,
|
|
4003
|
+
DsgCheckbox: ba,
|
|
4004
|
+
DsgCheckboxGroup: va,
|
|
4005
|
+
DsgDropdown: wa,
|
|
4006
|
+
DsgInput: ya,
|
|
4007
|
+
DsgInputDropdown: ka,
|
|
4008
|
+
DsgDatepicker: Ca,
|
|
4009
|
+
DsgLabel: Ea,
|
|
4010
|
+
DsgLink: Ta,
|
|
4011
|
+
DsgModal: Aa,
|
|
4012
|
+
DsgTag: Sa,
|
|
4013
|
+
DsgToggle: Oa,
|
|
4014
|
+
DsgTooltip: $a,
|
|
4015
|
+
DsgBreadcrumb: La,
|
|
4016
|
+
DsgTab: Ia
|
|
3899
4017
|
};
|
|
3900
4018
|
export {
|
|
3901
|
-
|
|
3902
|
-
|
|
3903
|
-
|
|
3904
|
-
|
|
3905
|
-
|
|
3906
|
-
|
|
3907
|
-
|
|
3908
|
-
|
|
3909
|
-
|
|
3910
|
-
|
|
3911
|
-
|
|
3912
|
-
|
|
3913
|
-
|
|
3914
|
-
|
|
3915
|
-
|
|
3916
|
-
|
|
3917
|
-
|
|
3918
|
-
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
4019
|
+
ga as DsgAlert,
|
|
4020
|
+
pa as DsgAvatar,
|
|
4021
|
+
ha as DsgBadge,
|
|
4022
|
+
La as DsgBreadcrumb,
|
|
4023
|
+
ma as DsgButton,
|
|
4024
|
+
ba as DsgCheckbox,
|
|
4025
|
+
va as DsgCheckboxGroup,
|
|
4026
|
+
fa as DsgCreditCardIcon,
|
|
4027
|
+
Ca as DsgDatepicker,
|
|
4028
|
+
wa as DsgDropdown,
|
|
4029
|
+
ua as DsgIcon,
|
|
4030
|
+
ya as DsgInput,
|
|
4031
|
+
ka as DsgInputDropdown,
|
|
4032
|
+
Ea as DsgLabel,
|
|
4033
|
+
Ta as DsgLink,
|
|
4034
|
+
ca as DsgMiscIcon,
|
|
4035
|
+
Aa as DsgModal,
|
|
4036
|
+
Ia as DsgTab,
|
|
4037
|
+
Sa as DsgTag,
|
|
4038
|
+
Oa as DsgToggle,
|
|
4039
|
+
$a as DsgTooltip,
|
|
4040
|
+
Pa as default
|
|
3922
4041
|
};
|