@visitscotland/component-library 5.79.2 → 5.79.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/components/carbon-calculator/CarbonCalculator.vue.d.ts +2 -2
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorQuestion.vue.d.ts +2 -2
- package/dist/components/components/checkbox/Checkbox.vue.d.ts +1 -1
- package/dist/components/components/form/Form.vue.d.ts +4 -4
- package/dist/components/components/input/Input.vue.d.ts +1 -1
- package/dist/components/components/mega-nav/MegaNav.vue.d.ts +1 -1
- package/dist/components/components/navigation-bar/components/NavigationBarSearch.vue.d.ts +1 -1
- package/dist/components/components/number-input/NumberInput.vue.d.ts +1 -1
- package/dist/components/components/radio-button/RadioButton.vue.d.ts +1 -1
- package/dist/components/components/select/Select.vue.d.ts +1 -1
- package/dist/components/components/site-search/components/SiteSearchForm.vue.d.ts +1 -1
- package/dist/components/components/textarea/Textarea.vue.d.ts +1 -1
- package/dist/components/mixins/validateFormElementMixin.d.ts +1 -1
- package/dist/components/vs-component-library.js +7 -7
- package/dist/components/vs-component-library.mjs +262 -266
- package/package.json +192 -192
- package/CHANGELOG.md +0 -5419
|
@@ -202,7 +202,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
202
202
|
return j === "backdrop" && t.noCloseOnBackdrop || j === "esc" && t.noCloseOnEsc ? (n("hide-prevented", b("hide-prevented", { trigger: j })), C?.("hide-prevented"), k) : (v && (clearTimeout(v), v = void 0), j && !te && n(j, W), n("hide", pe), pe.defaultPrevented || W.defaultPrevented ? (n("hide-prevented", b("hide-prevented", { trigger: j })), e.value || nextTick$1(() => {
|
|
203
203
|
s = !0, e.value = !0;
|
|
204
204
|
}), C?.("hide-prevented"), k) : (se.value = !1, v && (clearTimeout(v), v = void 0, p.value || (c.value = !1), d.value = !1), _ = setTimeout(() => {
|
|
205
|
-
g && (_ = void 0,
|
|
205
|
+
g && (_ = void 0, O.value = !0, l.value = !1, r.hideFn?.(), e.value && (s = !0, e.value = u ? 0 : !1));
|
|
206
206
|
}, f.value ? 0 : typeof t.delay == "number" ? t.delay : t.delay?.hide || 0), k));
|
|
207
207
|
}, P = useThrottleFn((j) => N(j), 500), R = useThrottleFn(() => D(), 500), T = (j = !1) => {
|
|
208
208
|
const te = b("toggle", { cancelable: !0 });
|
|
@@ -219,7 +219,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
219
219
|
trigger: j,
|
|
220
220
|
el: te
|
|
221
221
|
}), te.addEventListener(j, M), V(te);
|
|
222
|
-
},
|
|
222
|
+
}, A = (j, te, pe = !0) => {
|
|
223
223
|
const W = S.findIndex((Z) => Z?.trigger === j && Z.el === te);
|
|
224
224
|
W > -1 && (S.splice(W, 1), te.removeEventListener(j, M), pe && (te.removeAttribute("aria-expanded"), te.classList.remove("collapsed"), te.classList.remove("not-collapsed")));
|
|
225
225
|
}, $ = inject(showHideRegistryKey, null)?.register({
|
|
@@ -229,7 +229,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
229
229
|
hide: N,
|
|
230
230
|
value: readonly(l),
|
|
231
231
|
registerTrigger: B,
|
|
232
|
-
unregisterTrigger:
|
|
232
|
+
unregisterTrigger: A,
|
|
233
233
|
component: getCurrentInstance()
|
|
234
234
|
}), V = (j) => {
|
|
235
235
|
j.setAttribute("aria-expanded", e.value ? "true" : "false"), j.classList.toggle("collapsed", !e.value), j.classList.toggle("not-collapsed", !!e.value);
|
|
@@ -249,7 +249,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
249
249
|
});
|
|
250
250
|
const w = ref(!1), L = () => {
|
|
251
251
|
t.lazy === !0 && (w.value = !0);
|
|
252
|
-
},
|
|
252
|
+
}, O = ref(!1), z = ref(i), F = ref(i), q = [...[r.transitionProps?.onBeforeEnter ?? noop, t.transitionProps?.onBeforeEnter ?? noop].flat(), () => {
|
|
253
253
|
z.value = !0;
|
|
254
254
|
}], U = [() => {
|
|
255
255
|
requestAnimationFrame(() => {
|
|
@@ -271,7 +271,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
271
271
|
}
|
|
272
272
|
], X = [
|
|
273
273
|
() => {
|
|
274
|
-
|
|
274
|
+
O.value || (O.value = !0);
|
|
275
275
|
},
|
|
276
276
|
...[r.transitionProps?.onBeforeLeave ?? noop, t.transitionProps?.onBeforeLeave ?? noop].flat(),
|
|
277
277
|
() => {
|
|
@@ -288,7 +288,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
288
288
|
},
|
|
289
289
|
...[r.transitionProps?.onAfterLeave ?? noop, t.transitionProps?.onAfterLeave ?? noop].flat(),
|
|
290
290
|
() => {
|
|
291
|
-
|
|
291
|
+
O.value = !1, z.value = !1, f.value && requestAnimationFrame(() => {
|
|
292
292
|
f.value = !1;
|
|
293
293
|
}), requestAnimationFrame(() => {
|
|
294
294
|
p.value || (c.value = !1);
|
|
@@ -325,7 +325,7 @@ var useBreadcrumb = (e = breadcrumbGlobalIndexKey) => {
|
|
|
325
325
|
setLocalTemporaryHide: (j) => {
|
|
326
326
|
p.value = j;
|
|
327
327
|
},
|
|
328
|
-
isLeaving: readonly(
|
|
328
|
+
isLeaving: readonly(O),
|
|
329
329
|
transitionProps: {
|
|
330
330
|
...fadeBaseTransitionProps,
|
|
331
331
|
...t.transitionProps,
|
|
@@ -698,21 +698,21 @@ function _regenerator() {
|
|
|
698
698
|
v: e,
|
|
699
699
|
a: S,
|
|
700
700
|
f: S.bind(e, 4),
|
|
701
|
-
d: function(B,
|
|
702
|
-
return D = B, I = 0, N = e, M.n =
|
|
701
|
+
d: function(B, A) {
|
|
702
|
+
return D = B, I = 0, N = e, M.n = A, s;
|
|
703
703
|
}
|
|
704
704
|
};
|
|
705
|
-
function S(B,
|
|
706
|
-
for (I = B, N =
|
|
705
|
+
function S(B, A) {
|
|
706
|
+
for (I = B, N = A, t = 0; !T && P && !$ && t < R.length; t++) {
|
|
707
707
|
var $, V = R[t], w = M.p, L = V[2];
|
|
708
|
-
B > 3 ? ($ = L ===
|
|
708
|
+
B > 3 ? ($ = L === A) && (N = V[(I = V[4]) ? 5 : (I = 3, 3)], V[4] = V[5] = e) : V[0] <= w && (($ = B < 2 && w < V[1]) ? (I = 0, M.v = A, M.n = V[1]) : w < L && ($ = B < 3 || V[0] > A || A > L) && (V[4] = B, V[5] = A, M.n = L, I = 0));
|
|
709
709
|
}
|
|
710
710
|
if ($ || B > 1) return s;
|
|
711
|
-
throw T = !0,
|
|
711
|
+
throw T = !0, A;
|
|
712
712
|
}
|
|
713
|
-
return function(B,
|
|
713
|
+
return function(B, A, $) {
|
|
714
714
|
if (P > 1) throw TypeError("Generator is already running");
|
|
715
|
-
for (T &&
|
|
715
|
+
for (T && A === 1 && S(A, $), I = A, N = $; (t = I < 2 ? e : N) || !T; ) {
|
|
716
716
|
D || (I ? I < 3 ? (I > 1 && (M.n = -1), S(I, N)) : M.n = N : M.v = N);
|
|
717
717
|
try {
|
|
718
718
|
if (P = 2, D) {
|
|
@@ -865,33 +865,33 @@ var activeFocusTraps = {
|
|
|
865
865
|
manuallyPaused: !1,
|
|
866
866
|
delayInitialFocusTimer: void 0,
|
|
867
867
|
recentNavEvent: void 0
|
|
868
|
-
}, i, l = function(S, B,
|
|
869
|
-
return S && S[B] !== void 0 ? S[B] : r[
|
|
868
|
+
}, i, l = function(S, B, A) {
|
|
869
|
+
return S && S[B] !== void 0 ? S[B] : r[A || B];
|
|
870
870
|
}, c = function(S, B) {
|
|
871
|
-
var
|
|
871
|
+
var A = typeof B?.composedPath == "function" ? B.composedPath() : void 0;
|
|
872
872
|
return s.containerGroups.findIndex(function($) {
|
|
873
873
|
var V = $.container, w = $.tabbableNodes;
|
|
874
|
-
return V.contains(S) ||
|
|
874
|
+
return V.contains(S) || A?.includes(V) || w.find(function(L) {
|
|
875
875
|
return L === S;
|
|
876
876
|
});
|
|
877
877
|
});
|
|
878
878
|
}, d = function(S) {
|
|
879
|
-
var B = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {},
|
|
879
|
+
var B = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, A = B.hasFallback, $ = A === void 0 ? !1 : A, V = B.params, w = V === void 0 ? [] : V, L = r[S];
|
|
880
880
|
if (typeof L == "function" && (L = L.apply(void 0, _toConsumableArray(w))), L === !0 && (L = void 0), !L) {
|
|
881
881
|
if (L === void 0 || L === !1) return L;
|
|
882
882
|
throw new Error("`".concat(S, "` was specified but was not a node, or did not return a node"));
|
|
883
883
|
}
|
|
884
|
-
var
|
|
884
|
+
var O = L;
|
|
885
885
|
if (typeof L == "string") {
|
|
886
886
|
try {
|
|
887
|
-
|
|
887
|
+
O = a.querySelector(L);
|
|
888
888
|
} catch (z) {
|
|
889
889
|
throw new Error("`".concat(S, '` appears to be an invalid selector; error="').concat(z.message, '"'));
|
|
890
890
|
}
|
|
891
|
-
if (!
|
|
891
|
+
if (!O && !$)
|
|
892
892
|
throw new Error("`".concat(S, "` as selector refers to no known node"));
|
|
893
893
|
}
|
|
894
|
-
return
|
|
894
|
+
return O;
|
|
895
895
|
}, u = function() {
|
|
896
896
|
var S = d("initialFocus", { hasFallback: !0 });
|
|
897
897
|
if (S === !1) return !1;
|
|
@@ -905,17 +905,17 @@ var activeFocusTraps = {
|
|
|
905
905
|
return S;
|
|
906
906
|
}, f = function() {
|
|
907
907
|
if (s.containerGroups = s.containers.map(function(S) {
|
|
908
|
-
var B = tabbable(S, r.tabbableOptions),
|
|
909
|
-
return isTabbable(
|
|
910
|
-
}), L =
|
|
911
|
-
return isTabbable(
|
|
908
|
+
var B = tabbable(S, r.tabbableOptions), A = focusable(S, r.tabbableOptions), $ = B.length > 0 ? B[0] : void 0, V = B.length > 0 ? B[B.length - 1] : void 0, w = A.find(function(O) {
|
|
909
|
+
return isTabbable(O);
|
|
910
|
+
}), L = A.slice().reverse().find(function(O) {
|
|
911
|
+
return isTabbable(O);
|
|
912
912
|
});
|
|
913
913
|
return {
|
|
914
914
|
container: S,
|
|
915
915
|
tabbableNodes: B,
|
|
916
|
-
focusableNodes:
|
|
917
|
-
posTabIndexesFound: !!B.find(function(
|
|
918
|
-
return getTabIndex(
|
|
916
|
+
focusableNodes: A,
|
|
917
|
+
posTabIndexesFound: !!B.find(function(O) {
|
|
918
|
+
return getTabIndex(O) > 0;
|
|
919
919
|
}),
|
|
920
920
|
firstTabbableNode: $,
|
|
921
921
|
lastTabbableNode: V,
|
|
@@ -923,9 +923,9 @@ var activeFocusTraps = {
|
|
|
923
923
|
lastDomTabbableNode: L,
|
|
924
924
|
nextTabbableNode: function(z) {
|
|
925
925
|
var F = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, q = B.indexOf(z);
|
|
926
|
-
return q < 0 ? F ?
|
|
926
|
+
return q < 0 ? F ? A.slice(A.indexOf(z) + 1).find(function(U) {
|
|
927
927
|
return isTabbable(U);
|
|
928
|
-
}) :
|
|
928
|
+
}) : A.slice(0, A.indexOf(z)).reverse().find(function(U) {
|
|
929
929
|
return isTabbable(U);
|
|
930
930
|
}) : B[q + (F ? 1 : -1)];
|
|
931
931
|
}
|
|
@@ -952,30 +952,30 @@ var activeFocusTraps = {
|
|
|
952
952
|
var B = d("setReturnFocus", { params: [S] });
|
|
953
953
|
return B || (B === !1 ? !1 : S);
|
|
954
954
|
}, b = function(S) {
|
|
955
|
-
var B = S.target,
|
|
956
|
-
B = B || getActualTarget(
|
|
955
|
+
var B = S.target, A = S.event, $ = S.isBackward, V = $ === void 0 ? !1 : $;
|
|
956
|
+
B = B || getActualTarget(A), f();
|
|
957
957
|
var w = null;
|
|
958
958
|
if (s.tabbableGroups.length > 0) {
|
|
959
|
-
var L = c(B,
|
|
959
|
+
var L = c(B, A), O = L >= 0 ? s.containerGroups[L] : void 0;
|
|
960
960
|
if (L < 0) V ? w = s.tabbableGroups[s.tabbableGroups.length - 1].lastTabbableNode : w = s.tabbableGroups[0].firstTabbableNode;
|
|
961
961
|
else if (V) {
|
|
962
962
|
var z = s.tabbableGroups.findIndex(function(ne) {
|
|
963
963
|
var ce = ne.firstTabbableNode;
|
|
964
964
|
return B === ce;
|
|
965
965
|
});
|
|
966
|
-
if (z < 0 && (
|
|
966
|
+
if (z < 0 && (O.container === B || isFocusable(B, r.tabbableOptions) && !isTabbable(B, r.tabbableOptions) && !O.nextTabbableNode(B, !1)) && (z = L), z >= 0) {
|
|
967
967
|
var F = z === 0 ? s.tabbableGroups.length - 1 : z - 1, q = s.tabbableGroups[F];
|
|
968
968
|
w = getTabIndex(B) >= 0 ? q.lastTabbableNode : q.lastDomTabbableNode;
|
|
969
|
-
} else isTabEvent(
|
|
969
|
+
} else isTabEvent(A) || (w = O.nextTabbableNode(B, !1));
|
|
970
970
|
} else {
|
|
971
971
|
var U = s.tabbableGroups.findIndex(function(ne) {
|
|
972
972
|
var ce = ne.lastTabbableNode;
|
|
973
973
|
return B === ce;
|
|
974
974
|
});
|
|
975
|
-
if (U < 0 && (
|
|
975
|
+
if (U < 0 && (O.container === B || isFocusable(B, r.tabbableOptions) && !isTabbable(B, r.tabbableOptions) && !O.nextTabbableNode(B)) && (U = L), U >= 0) {
|
|
976
976
|
var Q = U === s.tabbableGroups.length - 1 ? 0 : U + 1, X = s.tabbableGroups[Q];
|
|
977
977
|
w = getTabIndex(B) >= 0 ? X.firstTabbableNode : X.firstDomTabbableNode;
|
|
978
|
-
} else isTabEvent(
|
|
978
|
+
} else isTabEvent(A) || (w = O.nextTabbableNode(B));
|
|
979
979
|
}
|
|
980
980
|
} else w = d("fallbackFocus");
|
|
981
981
|
return w;
|
|
@@ -988,9 +988,9 @@ var activeFocusTraps = {
|
|
|
988
988
|
valueOrHandler(r.allowOutsideClick, S) || S.preventDefault();
|
|
989
989
|
}
|
|
990
990
|
}, _ = function(S) {
|
|
991
|
-
var B = getActualTarget(S),
|
|
992
|
-
if (
|
|
993
|
-
|
|
991
|
+
var B = getActualTarget(S), A = c(B, S) >= 0;
|
|
992
|
+
if (A || B instanceof Document)
|
|
993
|
+
A && (s.mostRecentlyFocusedNode = B);
|
|
994
994
|
else {
|
|
995
995
|
S.stopImmediatePropagation();
|
|
996
996
|
var $, V = !0;
|
|
@@ -998,10 +998,10 @@ var activeFocusTraps = {
|
|
|
998
998
|
if (getTabIndex(s.mostRecentlyFocusedNode) > 0) {
|
|
999
999
|
var w = c(s.mostRecentlyFocusedNode), L = s.containerGroups[w].tabbableNodes;
|
|
1000
1000
|
if (L.length > 0) {
|
|
1001
|
-
var
|
|
1001
|
+
var O = L.findIndex(function(z) {
|
|
1002
1002
|
return z === s.mostRecentlyFocusedNode;
|
|
1003
1003
|
});
|
|
1004
|
-
|
|
1004
|
+
O >= 0 && (r.isKeyForward(s.recentNavEvent) ? O + 1 < L.length && ($ = L[O + 1], V = !1) : O - 1 >= 0 && ($ = L[O - 1], V = !1));
|
|
1005
1005
|
}
|
|
1006
1006
|
} else s.containerGroups.some(function(z) {
|
|
1007
1007
|
return z.tabbableNodes.some(function(F) {
|
|
@@ -1018,11 +1018,11 @@ var activeFocusTraps = {
|
|
|
1018
1018
|
}, C = function(S) {
|
|
1019
1019
|
var B = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
1020
1020
|
s.recentNavEvent = S;
|
|
1021
|
-
var
|
|
1021
|
+
var A = b({
|
|
1022
1022
|
event: S,
|
|
1023
1023
|
isBackward: B
|
|
1024
1024
|
});
|
|
1025
|
-
|
|
1025
|
+
A && (isTabEvent(S) && S.preventDefault(), m(A));
|
|
1026
1026
|
}, k = function(S) {
|
|
1027
1027
|
(r.isKeyForward(S) || r.isKeyBackward(S)) && C(S, r.isKeyBackward(S));
|
|
1028
1028
|
}, E = function(S) {
|
|
@@ -1052,27 +1052,27 @@ var activeFocusTraps = {
|
|
|
1052
1052
|
}), a.addEventListener("keydown", E), S;
|
|
1053
1053
|
}, N = function(S) {
|
|
1054
1054
|
s.active && !s.paused && i._setSubtreeIsolation(!1), s.adjacentElements.clear(), s.alreadySilent.clear();
|
|
1055
|
-
var B = /* @__PURE__ */ new Set(),
|
|
1055
|
+
var B = /* @__PURE__ */ new Set(), A = /* @__PURE__ */ new Set(), $ = _createForOfIteratorHelper(S), V;
|
|
1056
1056
|
try {
|
|
1057
1057
|
for ($.s(); !(V = $.n()).done; ) {
|
|
1058
1058
|
var w = V.value;
|
|
1059
1059
|
B.add(w);
|
|
1060
|
-
for (var L = typeof ShadowRoot < "u" && w.getRootNode() instanceof ShadowRoot,
|
|
1061
|
-
B.add(
|
|
1062
|
-
var z =
|
|
1063
|
-
z ? F = z.children : !z && L && (F =
|
|
1060
|
+
for (var L = typeof ShadowRoot < "u" && w.getRootNode() instanceof ShadowRoot, O = w; O; ) {
|
|
1061
|
+
B.add(O);
|
|
1062
|
+
var z = O.parentElement, F = [];
|
|
1063
|
+
z ? F = z.children : !z && L && (F = O.getRootNode().children, z = O.getRootNode().host, L = typeof ShadowRoot < "u" && z.getRootNode() instanceof ShadowRoot);
|
|
1064
1064
|
var q = _createForOfIteratorHelper(F), U;
|
|
1065
1065
|
try {
|
|
1066
1066
|
for (q.s(); !(U = q.n()).done; ) {
|
|
1067
1067
|
var Q = U.value;
|
|
1068
|
-
|
|
1068
|
+
A.add(Q);
|
|
1069
1069
|
}
|
|
1070
1070
|
} catch (X) {
|
|
1071
1071
|
q.e(X);
|
|
1072
1072
|
} finally {
|
|
1073
1073
|
q.f();
|
|
1074
1074
|
}
|
|
1075
|
-
|
|
1075
|
+
O = z;
|
|
1076
1076
|
}
|
|
1077
1077
|
}
|
|
1078
1078
|
} catch (X) {
|
|
@@ -1081,15 +1081,15 @@ var activeFocusTraps = {
|
|
|
1081
1081
|
$.f();
|
|
1082
1082
|
}
|
|
1083
1083
|
B.forEach(function(X) {
|
|
1084
|
-
|
|
1085
|
-
}), s.adjacentElements =
|
|
1084
|
+
A.delete(X);
|
|
1085
|
+
}), s.adjacentElements = A;
|
|
1086
1086
|
}, P = function() {
|
|
1087
1087
|
if (s.active)
|
|
1088
1088
|
return a.removeEventListener("focusin", _, !0), a.removeEventListener("mousedown", v, !0), a.removeEventListener("touchstart", v, !0), a.removeEventListener("click", D, !0), a.removeEventListener("keydown", k, !0), a.removeEventListener("keydown", E), i;
|
|
1089
1089
|
}, R = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(function(S) {
|
|
1090
1090
|
S.some(function(B) {
|
|
1091
|
-
return Array.from(B.removedNodes).some(function(
|
|
1092
|
-
return
|
|
1091
|
+
return Array.from(B.removedNodes).some(function(A) {
|
|
1092
|
+
return A === s.mostRecentlyFocusedNode;
|
|
1093
1093
|
});
|
|
1094
1094
|
}) && m(u());
|
|
1095
1095
|
}) : void 0, T = function() {
|
|
@@ -1109,21 +1109,21 @@ var activeFocusTraps = {
|
|
|
1109
1109
|
},
|
|
1110
1110
|
activate: function(S) {
|
|
1111
1111
|
if (s.active) return this;
|
|
1112
|
-
var B = l(S, "onActivate"),
|
|
1112
|
+
var B = l(S, "onActivate"), A = l(S, "onPostActivate"), $ = l(S, "checkCanFocusTrap"), V = activeFocusTraps.getActiveTrap(o), w = !1;
|
|
1113
1113
|
if (V && !V.paused) {
|
|
1114
1114
|
var L;
|
|
1115
1115
|
(L = V._setSubtreeIsolation) === null || L === void 0 || L.call(V, !1), w = !0;
|
|
1116
1116
|
}
|
|
1117
1117
|
try {
|
|
1118
1118
|
$ || f(), s.active = !0, s.paused = !1, s.nodeFocusedBeforeActivation = p(a), B?.();
|
|
1119
|
-
var
|
|
1119
|
+
var O = /* @__PURE__ */ (function() {
|
|
1120
1120
|
var F = _asyncToGenerator(/* @__PURE__ */ _regenerator().m(function q() {
|
|
1121
1121
|
return _regenerator().w(function(U) {
|
|
1122
1122
|
for (; ; ) switch (U.n) {
|
|
1123
1123
|
case 0:
|
|
1124
1124
|
return $ && f(), U.n = 1, I();
|
|
1125
1125
|
case 1:
|
|
1126
|
-
i._setSubtreeIsolation(!0), T(),
|
|
1126
|
+
i._setSubtreeIsolation(!0), T(), A?.();
|
|
1127
1127
|
case 2:
|
|
1128
1128
|
return U.a(2);
|
|
1129
1129
|
}
|
|
@@ -1134,8 +1134,8 @@ var activeFocusTraps = {
|
|
|
1134
1134
|
};
|
|
1135
1135
|
})();
|
|
1136
1136
|
if ($)
|
|
1137
|
-
return $(s.containers.concat()).then(
|
|
1138
|
-
|
|
1137
|
+
return $(s.containers.concat()).then(O, O), this;
|
|
1138
|
+
O();
|
|
1139
1139
|
} catch (F) {
|
|
1140
1140
|
if (V === activeFocusTraps.getActiveTrap(o) && w) {
|
|
1141
1141
|
var z;
|
|
@@ -1153,8 +1153,8 @@ var activeFocusTraps = {
|
|
|
1153
1153
|
checkCanReturnFocus: r.checkCanReturnFocus
|
|
1154
1154
|
}, S);
|
|
1155
1155
|
clearTimeout(s.delayInitialFocusTimer), s.delayInitialFocusTimer = void 0, s.paused || i._setSubtreeIsolation(!1), s.alreadySilent.clear(), P(), s.active = !1, s.paused = !1, T(), activeFocusTraps.deactivateTrap(o, i);
|
|
1156
|
-
var
|
|
1157
|
-
|
|
1156
|
+
var A = l(B, "onDeactivate"), $ = l(B, "onPostDeactivate"), V = l(B, "checkCanReturnFocus"), w = l(B, "returnFocus", "returnFocusOnDeactivate");
|
|
1157
|
+
A?.();
|
|
1158
1158
|
var L = function() {
|
|
1159
1159
|
delay(function() {
|
|
1160
1160
|
w && m(g(s.nodeFocusedBeforeActivation)), $?.();
|
|
@@ -1180,12 +1180,12 @@ var activeFocusTraps = {
|
|
|
1180
1180
|
_setPausedState: { value: function(S, B) {
|
|
1181
1181
|
if (s.paused === S) return this;
|
|
1182
1182
|
if (s.paused = S, S) {
|
|
1183
|
-
var
|
|
1184
|
-
|
|
1183
|
+
var A = l(B, "onPause"), $ = l(B, "onPostPause");
|
|
1184
|
+
A?.(), P(), i._setSubtreeIsolation(!1), T(), $?.();
|
|
1185
1185
|
} else {
|
|
1186
1186
|
var V = l(B, "onUnpause"), w = l(B, "onPostUnpause");
|
|
1187
1187
|
V?.(), (/* @__PURE__ */ (function() {
|
|
1188
|
-
var L = _asyncToGenerator(/* @__PURE__ */ _regenerator().m(function
|
|
1188
|
+
var L = _asyncToGenerator(/* @__PURE__ */ _regenerator().m(function O() {
|
|
1189
1189
|
return _regenerator().w(function(z) {
|
|
1190
1190
|
for (; ; ) switch (z.n) {
|
|
1191
1191
|
case 0:
|
|
@@ -1195,7 +1195,7 @@ var activeFocusTraps = {
|
|
|
1195
1195
|
case 2:
|
|
1196
1196
|
return z.a(2);
|
|
1197
1197
|
}
|
|
1198
|
-
},
|
|
1198
|
+
}, O);
|
|
1199
1199
|
}));
|
|
1200
1200
|
return function() {
|
|
1201
1201
|
return L.apply(this, arguments);
|
|
@@ -1206,8 +1206,8 @@ var activeFocusTraps = {
|
|
|
1206
1206
|
} },
|
|
1207
1207
|
_setSubtreeIsolation: { value: function(S) {
|
|
1208
1208
|
r.isolateSubtrees && s.adjacentElements.forEach(function(B) {
|
|
1209
|
-
var
|
|
1210
|
-
S ? r.isolateSubtrees === "aria-hidden" ? ((B.ariaHidden === "true" || ((
|
|
1209
|
+
var A;
|
|
1210
|
+
S ? r.isolateSubtrees === "aria-hidden" ? ((B.ariaHidden === "true" || ((A = B.getAttribute("aria-hidden")) === null || A === void 0 ? void 0 : A.toLowerCase()) === "true") && s.alreadySilent.add(B), B.setAttribute("aria-hidden", "true")) : ((B.inert || B.hasAttribute("inert")) && s.alreadySilent.add(B), B.setAttribute("inert", !0)) : s.alreadySilent.has(B) || (r.isolateSubtrees === "aria-hidden" ? B.removeAttribute("aria-hidden") : B.removeAttribute("inert"));
|
|
1211
1211
|
});
|
|
1212
1212
|
} }
|
|
1213
1213
|
}), i.updateContainerElements(t), i;
|
|
@@ -1500,7 +1500,7 @@ var useActivatedFocusTrap = ({ element: e, isActive: t, noTrap: n, fallbackFocus
|
|
|
1500
1500
|
}
|
|
1501
1501
|
}, b = () => {
|
|
1502
1502
|
a.noTrap && a.focus !== !1 && m && (m?.focus(), m = null);
|
|
1503
|
-
}, { showRef: v, renderRef: _, renderBackdropRef: C, hide: k, show: E, toggle: D, computedNoAnimation: I, transitionProps: N, backdropTransitionProps: P, isLeaving: R, isVisible: T, trapActive: M, contentShowing: S, backdropReady: B, backdropVisible:
|
|
1503
|
+
}, { showRef: v, renderRef: _, renderBackdropRef: C, hide: k, show: E, toggle: D, computedNoAnimation: I, transitionProps: N, backdropTransitionProps: P, isLeaving: R, isVisible: T, trapActive: M, contentShowing: S, backdropReady: B, backdropVisible: A } = useShowHide(i, a, o, l, s, { transitionProps: {
|
|
1504
1504
|
onAfterEnter: g,
|
|
1505
1505
|
onAfterLeave: b
|
|
1506
1506
|
} }), { needsFallback: $ } = useActivatedFocusTrap({
|
|
@@ -1529,7 +1529,7 @@ var useActivatedFocusTrap = ({ element: e, isActive: t, noTrap: n, fallbackFocus
|
|
|
1529
1529
|
bgVariant: a.bodyBgVariant,
|
|
1530
1530
|
textVariant: a.bodyTextVariant,
|
|
1531
1531
|
variant: a.bodyVariant
|
|
1532
|
-
})),
|
|
1532
|
+
})), O = computed$1(() => [a.bodyClass, L.value]), z = useColorVariantClasses(() => ({
|
|
1533
1533
|
bgVariant: a.headerBgVariant,
|
|
1534
1534
|
textVariant: a.headerTextVariant,
|
|
1535
1535
|
variant: a.headerVariant,
|
|
@@ -1636,7 +1636,7 @@ var useActivatedFocusTrap = ({ element: e, isActive: t, noTrap: n, fallbackFocus
|
|
|
1636
1636
|
}, q.value, { onClick: G[1] || (G[1] = (ue) => unref(k)("close")) }), null, 16, ["aria-label"]))], 64))])], 16)),
|
|
1637
1637
|
createElementVNode("div", mergeProps({
|
|
1638
1638
|
id: `${unref(s)}-body`,
|
|
1639
|
-
class: ["modal-body",
|
|
1639
|
+
class: ["modal-body", O.value]
|
|
1640
1640
|
}, unref(a).bodyAttrs), [renderSlot(Z.$slots, "default", normalizeProps(guardReactiveProps(W.value)), () => [createTextVNode(toDisplayString(unref(a).body), 1)])], 16, _hoisted_2$1y),
|
|
1641
1641
|
unref(a).noFooter ? createCommentVNode("", !0) : (openBlock(), createElementBlock("div", {
|
|
1642
1642
|
key: 1,
|
|
@@ -1689,7 +1689,7 @@ var useActivatedFocusTrap = ({ element: e, isActive: t, noTrap: n, fallbackFocus
|
|
|
1689
1689
|
default: withCtx(() => [withDirectives(createElementVNode("div", {
|
|
1690
1690
|
class: normalizeClass(["modal-backdrop", {
|
|
1691
1691
|
fade: !unref(I),
|
|
1692
|
-
show: unref(
|
|
1692
|
+
show: unref(A) || unref(I),
|
|
1693
1693
|
...fe.value
|
|
1694
1694
|
}]),
|
|
1695
1695
|
style: normalizeStyle(pe.value),
|
|
@@ -2817,7 +2817,7 @@ var normalizeInput = (e, t) => {
|
|
|
2817
2817
|
strategy: toRef(() => a.strategy)
|
|
2818
2818
|
}), R = ref({ position: "absolute" });
|
|
2819
2819
|
let T;
|
|
2820
|
-
const { showRef: M, hide: S, show: B, toggle:
|
|
2820
|
+
const { showRef: M, hide: S, show: B, toggle: A, throttleHide: $, computedNoAnimation: V, transitionProps: w, contentShowing: L, isVisible: O, isActive: z, renderRef: F, localTemporaryHide: q, setLocalTemporaryHide: U } = useShowHide(i, a, o, d, l, {
|
|
2821
2821
|
showFn: () => {
|
|
2822
2822
|
P(), nextTick$1(() => {
|
|
2823
2823
|
T = autoUpdate$1(m.value, d.value, P, { animationFrame: a.realtime });
|
|
@@ -2843,7 +2843,7 @@ var normalizeInput = (e, t) => {
|
|
|
2843
2843
|
W,
|
|
2844
2844
|
`b-${W}`,
|
|
2845
2845
|
{
|
|
2846
|
-
show:
|
|
2846
|
+
show: O.value && !c.value,
|
|
2847
2847
|
fade: !V.value,
|
|
2848
2848
|
[`bs-${W}-${resolveBootstrapPlacement(N.value)}`]: N.value !== void 0
|
|
2849
2849
|
}
|
|
@@ -2862,12 +2862,12 @@ var normalizeInput = (e, t) => {
|
|
|
2862
2862
|
se(W);
|
|
2863
2863
|
}, 50));
|
|
2864
2864
|
};
|
|
2865
|
-
watch(
|
|
2865
|
+
watch(O, () => {
|
|
2866
2866
|
P();
|
|
2867
2867
|
}), t({
|
|
2868
2868
|
hide: S,
|
|
2869
2869
|
show: B,
|
|
2870
|
-
toggle:
|
|
2870
|
+
toggle: A
|
|
2871
2871
|
});
|
|
2872
2872
|
const de = (W) => {
|
|
2873
2873
|
M.value ? S(W.type === "click" ? "click" : "toggle") : B();
|
|
@@ -2913,11 +2913,11 @@ var normalizeInput = (e, t) => {
|
|
|
2913
2913
|
te(), j();
|
|
2914
2914
|
});
|
|
2915
2915
|
const pe = computed$1(() => ({
|
|
2916
|
-
toggle:
|
|
2916
|
+
toggle: A,
|
|
2917
2917
|
show: B,
|
|
2918
2918
|
hide: S,
|
|
2919
2919
|
id: l.value,
|
|
2920
|
-
visible:
|
|
2920
|
+
visible: O.value,
|
|
2921
2921
|
active: z.value
|
|
2922
2922
|
}));
|
|
2923
2923
|
return onMounted(() => {
|
|
@@ -3205,7 +3205,7 @@ var normalizeInput = (e, t) => {
|
|
|
3205
3205
|
} else U[q === -1 ? U.length - 1 : 0]?.focus();
|
|
3206
3206
|
};
|
|
3207
3207
|
onKeyStroke("ArrowUp", (F) => M(F, -1), { target: g }), onKeyStroke("ArrowDown", (F) => M(F, 1), { target: g }), onKeyStroke("ArrowUp", (F) => M(F, -1), { target: d }), onKeyStroke("ArrowDown", (F) => M(F, 1), { target: d });
|
|
3208
|
-
const S = ref({}), { update: B, floatingStyles:
|
|
3208
|
+
const S = ref({}), { update: B, floatingStyles: A } = useFloating(g, d, {
|
|
3209
3209
|
placement: () => a.placement,
|
|
3210
3210
|
middleware: computed$1(() => {
|
|
3211
3211
|
if (a.floatingMiddleware !== void 0) return a.floatingMiddleware;
|
|
@@ -3249,7 +3249,7 @@ var normalizeInput = (e, t) => {
|
|
|
3249
3249
|
show: a.split ? void 0 : v.value
|
|
3250
3250
|
}]), L = () => {
|
|
3251
3251
|
E();
|
|
3252
|
-
},
|
|
3252
|
+
}, O = (F) => {
|
|
3253
3253
|
if (a.split) {
|
|
3254
3254
|
o("split-click", F);
|
|
3255
3255
|
return;
|
|
@@ -3295,7 +3295,7 @@ var normalizeInput = (e, t) => {
|
|
|
3295
3295
|
href: unref(a).split ? unref(a).splitHref : void 0,
|
|
3296
3296
|
icon: unref(a).icon,
|
|
3297
3297
|
to: unref(a).split && unref(a).splitTo ? unref(a).splitTo : void 0
|
|
3298
|
-
}, unref(a).split ? void 0 : unref(a).toggleAttrs, { onClick:
|
|
3298
|
+
}, unref(a).split ? void 0 : unref(a).toggleAttrs, { onClick: O }), {
|
|
3299
3299
|
default: withCtx(() => [renderSlot(F.$slots, "button-content", {}, () => [createTextVNode(toDisplayString(unref(a).text), 1)])]),
|
|
3300
3300
|
_: 3
|
|
3301
3301
|
}, 16, [
|
|
@@ -3342,7 +3342,7 @@ var normalizeInput = (e, t) => {
|
|
|
3342
3342
|
id: unref(r) + "-menu",
|
|
3343
3343
|
ref: "_floating",
|
|
3344
3344
|
style: normalizeStyle([
|
|
3345
|
-
unref(
|
|
3345
|
+
unref(A),
|
|
3346
3346
|
S.value,
|
|
3347
3347
|
{ display: unref(v) || unref(R) ? "block" : "none" }
|
|
3348
3348
|
]),
|
|
@@ -3988,7 +3988,7 @@ var normalizeInput = (e, t) => {
|
|
|
3988
3988
|
setup(e, { expose: t, emit: n }) {
|
|
3989
3989
|
const a = useDefaults(e, "BOffcanvas"), o = n, r = useSlots(), s = useModel(e, "modelValue"), i = useId$1(() => a.id, "offcanvas"), l = useTemplateRef("_element"), c = useTemplateRef("_fallbackFocusElement"), d = useTemplateRef("_close"), u = () => a.focus && typeof a.focus != "boolean" ? a.focus === "close" ? d : getElement(a.focus, l.value ?? void 0) : l, f = () => {
|
|
3990
3990
|
nextTick$1(() => {
|
|
3991
|
-
a.focus !== !1 && !
|
|
3991
|
+
a.focus !== !1 && !A.value && a.noTrap && unrefElement(u())?.focus();
|
|
3992
3992
|
});
|
|
3993
3993
|
}, { showRef: p, renderRef: m, renderBackdropRef: g, hide: b, show: v, toggle: _, computedNoAnimation: C, contentShowing: k, transitionProps: E, backdropReady: D, backdropTransitionProps: I, backdropVisible: N, isVisible: P, buildTriggerableEvent: R, isLeaving: T, trapActive: M, setLocalNoAnimation: S } = useShowHide(s, a, o, l, i, { transitionProps: {
|
|
3994
3994
|
onAfterEnter: f,
|
|
@@ -3998,10 +3998,10 @@ var normalizeInput = (e, t) => {
|
|
|
3998
3998
|
leaveActiveClass: "",
|
|
3999
3999
|
enterFromClass: "",
|
|
4000
4000
|
leaveFromClass: ""
|
|
4001
|
-
} }), B = useBreakpoints(breakpointsBootstrapV5).smaller(() => a.responsive ?? "xs"),
|
|
4001
|
+
} }), B = useBreakpoints(breakpointsBootstrapV5).smaller(() => a.responsive ?? "xs"), A = ref(!1);
|
|
4002
4002
|
onMounted(() => {
|
|
4003
|
-
a.responsive !== void 0 && (
|
|
4004
|
-
}), useSafeScrollLock(p, () => a.bodyScrolling ||
|
|
4003
|
+
a.responsive !== void 0 && (A.value = !B.value, o("breakpoint", R("breakpoint"), A.value));
|
|
4004
|
+
}), useSafeScrollLock(p, () => a.bodyScrolling || A.value), onKeyStroke("Escape", () => {
|
|
4005
4005
|
b("esc");
|
|
4006
4006
|
}, {
|
|
4007
4007
|
target: l,
|
|
@@ -4010,13 +4010,13 @@ var normalizeInput = (e, t) => {
|
|
|
4010
4010
|
const { needsFallback: $ } = useActivatedFocusTrap({
|
|
4011
4011
|
element: l,
|
|
4012
4012
|
isActive: M,
|
|
4013
|
-
noTrap: () => a.noTrap ||
|
|
4013
|
+
noTrap: () => a.noTrap || A.value,
|
|
4014
4014
|
fallbackFocus: {
|
|
4015
4015
|
classSelector: fallbackClassSelector,
|
|
4016
4016
|
ref: c
|
|
4017
4017
|
},
|
|
4018
|
-
focus: () => a.focus === !1 ||
|
|
4019
|
-
}), V = computed$1(() => (a.responsive === void 0 || !
|
|
4018
|
+
focus: () => a.focus === !1 || A.value ? !1 : unrefElement(u()) ?? void 0
|
|
4019
|
+
}), V = computed$1(() => (a.responsive === void 0 || !A.value) && !a.noBackdrop && (p.value === !0 || T.value && a.backdropFirst && !C.value)), w = computed$1(() => !isEmptySlot(r["header-close"])), L = computed$1(() => [{ "text-reset": !w.value }, a.headerCloseClass]), O = computed$1(() => ({
|
|
4020
4020
|
variant: w.value ? a.headerCloseVariant : void 0,
|
|
4021
4021
|
class: L.value
|
|
4022
4022
|
})), z = computed$1(() => !isEmptySlot(r.footer)), F = computed$1(() => [
|
|
@@ -4039,29 +4039,29 @@ var normalizeInput = (e, t) => {
|
|
|
4039
4039
|
}));
|
|
4040
4040
|
return watch(B, (Q) => {
|
|
4041
4041
|
a.responsive !== void 0 && (Q === !0 ? (S(!0), requestAnimationFrame(() => {
|
|
4042
|
-
|
|
4042
|
+
A.value = !1;
|
|
4043
4043
|
}), o("breakpoint", R("breakpoint"), !1), o("hide", R("hide"))) : (S(!0), requestAnimationFrame(() => {
|
|
4044
|
-
|
|
4044
|
+
A.value = !0;
|
|
4045
4045
|
}), o("breakpoint", R("breakpoint"), !0), o("show", R("show"))));
|
|
4046
4046
|
}), watch(() => a.responsive, (Q) => {
|
|
4047
4047
|
if (Q === void 0) {
|
|
4048
|
-
|
|
4048
|
+
A.value = !1;
|
|
4049
4049
|
return;
|
|
4050
4050
|
}
|
|
4051
4051
|
const X = !B.value;
|
|
4052
|
-
X !==
|
|
4053
|
-
|
|
4052
|
+
X !== A.value && (S(!0), requestAnimationFrame(() => {
|
|
4053
|
+
A.value = X;
|
|
4054
4054
|
}), o("breakpoint", R("breakpoint"), X), X ? o("show", R("show")) : o("hide", R("hide")));
|
|
4055
4055
|
}), t({
|
|
4056
4056
|
hide: b,
|
|
4057
4057
|
show: v,
|
|
4058
4058
|
toggle: _,
|
|
4059
|
-
isOpenByBreakpoint:
|
|
4059
|
+
isOpenByBreakpoint: A
|
|
4060
4060
|
}), (Q, X) => (openBlock(), createBlock(ConditionalTeleport_default, {
|
|
4061
4061
|
to: unref(a).teleportTo,
|
|
4062
|
-
disabled: unref(a).teleportDisabled ||
|
|
4062
|
+
disabled: unref(a).teleportDisabled || A.value
|
|
4063
4063
|
}, {
|
|
4064
|
-
default: withCtx(() => [unref(m) || unref(k) ||
|
|
4064
|
+
default: withCtx(() => [unref(m) || unref(k) || A.value ? (openBlock(), createBlock(Transition, mergeProps({ key: 0 }, unref(E), { appear: s.value || unref(a).visible }), {
|
|
4065
4065
|
default: withCtx(() => [withDirectives(createElementVNode("div", mergeProps({
|
|
4066
4066
|
id: unref(i),
|
|
4067
4067
|
ref: "_element",
|
|
@@ -4072,7 +4072,7 @@ var normalizeInput = (e, t) => {
|
|
|
4072
4072
|
tabindex: "-1",
|
|
4073
4073
|
"aria-labelledby": `${unref(i)}-offcanvas-label`,
|
|
4074
4074
|
"data-bs-backdrop": "false"
|
|
4075
|
-
}, Q.$attrs), [unref(k) ||
|
|
4075
|
+
}, Q.$attrs), [unref(k) || A.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
4076
4076
|
unref(a).noHeader ? createCommentVNode("", !0) : (openBlock(), createElementBlock("div", mergeProps({
|
|
4077
4077
|
key: 0,
|
|
4078
4078
|
class: ["offcanvas-header", unref(a).headerClass]
|
|
@@ -4082,14 +4082,14 @@ var normalizeInput = (e, t) => {
|
|
|
4082
4082
|
}, [renderSlot(Q.$slots, "title", normalizeProps(guardReactiveProps(U.value)), () => [createTextVNode(toDisplayString(unref(a).title), 1)])], 8, _hoisted_2$1v), unref(a).noHeaderClose ? createCommentVNode("", !0) : (openBlock(), createElementBlock(Fragment, { key: 0 }, [w.value ? (openBlock(), createBlock(BButton_default, mergeProps({
|
|
4083
4083
|
key: 0,
|
|
4084
4084
|
ref: "_close"
|
|
4085
|
-
},
|
|
4085
|
+
}, O.value, { onClick: X[0] || (X[0] = (ne) => unref(b)("close")) }), {
|
|
4086
4086
|
default: withCtx(() => [renderSlot(Q.$slots, "header-close", normalizeProps(guardReactiveProps(U.value)))]),
|
|
4087
4087
|
_: 3
|
|
4088
4088
|
}, 16)) : (openBlock(), createBlock(BCloseButton_default, mergeProps({
|
|
4089
4089
|
key: 1,
|
|
4090
4090
|
ref: "_close",
|
|
4091
4091
|
"aria-label": unref(a).headerCloseLabel
|
|
4092
|
-
},
|
|
4092
|
+
}, O.value, { onClick: X[1] || (X[1] = (ne) => unref(b)("close")) }), null, 16, ["aria-label"]))], 64))])], 16)),
|
|
4093
4093
|
createElementVNode("div", mergeProps({ class: ["offcanvas-body", unref(a).bodyClass] }, unref(a).bodyAttrs), [renderSlot(Q.$slots, "default", normalizeProps(guardReactiveProps(U.value)))], 16),
|
|
4094
4094
|
z.value ? (openBlock(), createElementBlock("div", {
|
|
4095
4095
|
key: 1,
|
|
@@ -4105,7 +4105,7 @@ var normalizeInput = (e, t) => {
|
|
|
4105
4105
|
height: "0",
|
|
4106
4106
|
overflow: "hidden"
|
|
4107
4107
|
}
|
|
4108
|
-
}, null, 512)) : createCommentVNode("", !0)], 16, _hoisted_1$25), [[vShow, unref(p) && (unref(D) && unref(a).backdropFirst || !unref(a).backdropFirst) ||
|
|
4108
|
+
}, null, 512)) : createCommentVNode("", !0)], 16, _hoisted_1$25), [[vShow, unref(p) && (unref(D) && unref(a).backdropFirst || !unref(a).backdropFirst) || A.value]])]),
|
|
4109
4109
|
_: 3
|
|
4110
4110
|
}, 16, ["appear"])) : createCommentVNode("", !0), unref(a).noBackdrop ? createCommentVNode("", !0) : renderSlot(Q.$slots, "backdrop", normalizeProps(mergeProps({ key: 1 }, U.value)), () => [unref(g) ? (openBlock(), createBlock(Transition, normalizeProps(mergeProps({ key: 0 }, unref(I))), {
|
|
4111
4111
|
default: withCtx(() => [withDirectives(createElementVNode("div", {
|
|
@@ -4536,14 +4536,14 @@ var normalizeInput = (e, t) => {
|
|
|
4536
4536
|
r.value >= 0 && getSafeDocument()?.getElementById(p.value[r.value]?.buttonId)?.focus();
|
|
4537
4537
|
}));
|
|
4538
4538
|
}, R = ($, V) => {
|
|
4539
|
-
let w = $, L = -1,
|
|
4540
|
-
for (let z = 0; z < p.value.length; z++) p.value[z]?.disabled || (L === -1 && (L = z),
|
|
4541
|
-
for (; w >= L && w <=
|
|
4542
|
-
return w < L && (w = L), w >
|
|
4539
|
+
let w = $, L = -1, O = -1;
|
|
4540
|
+
for (let z = 0; z < p.value.length; z++) p.value[z]?.disabled || (L === -1 && (L = z), O = z);
|
|
4541
|
+
for (; w >= L && w <= O && p.value[w]?.disabled; ) w += V;
|
|
4542
|
+
return w < L && (w = L), w > O && (w = O), w;
|
|
4543
4543
|
};
|
|
4544
4544
|
let T, M = !1;
|
|
4545
4545
|
watch(r, ($, V) => {
|
|
4546
|
-
if (p.value.length <= 0 || p.value.filter((
|
|
4546
|
+
if (p.value.length <= 0 || p.value.filter((O) => !O.disabled).length <= 0) return;
|
|
4547
4547
|
if (M) {
|
|
4548
4548
|
M = !1;
|
|
4549
4549
|
return;
|
|
@@ -4562,18 +4562,18 @@ var normalizeInput = (e, t) => {
|
|
|
4562
4562
|
event: L
|
|
4563
4563
|
}), L.defaultPrevented) {
|
|
4564
4564
|
M = !0;
|
|
4565
|
-
const
|
|
4566
|
-
T = void 0, s.value !== p.value[
|
|
4567
|
-
|
|
4565
|
+
const O = T ?? V ?? R(0, 1);
|
|
4566
|
+
T = void 0, s.value !== p.value[O]?.id && (s.value = p.value[O]?.id), nextTick$1(() => {
|
|
4567
|
+
O >= 0 && getSafeDocument()?.getElementById(p.value[O]?.buttonId)?.focus();
|
|
4568
4568
|
});
|
|
4569
4569
|
return;
|
|
4570
4570
|
}
|
|
4571
4571
|
s.value !== p.value[w]?.id && (s.value = p.value[w]?.id), T = void 0;
|
|
4572
4572
|
}), watch(s, ($, V) => {
|
|
4573
|
-
if (p.value.length <= 0 || p.value.filter((
|
|
4574
|
-
const w = p.value.findIndex((
|
|
4573
|
+
if (p.value.length <= 0 || p.value.filter((O) => !O.disabled).length <= 0) return;
|
|
4574
|
+
const w = p.value.findIndex((O) => O.id === $);
|
|
4575
4575
|
if (w === r.value) return;
|
|
4576
|
-
const L = p.value.findIndex((
|
|
4576
|
+
const L = p.value.findIndex((O) => O.id === V);
|
|
4577
4577
|
if (p.value[w]?.disabled) {
|
|
4578
4578
|
r.value = R(w, w > L ? 1 : -1);
|
|
4579
4579
|
return;
|
|
@@ -4601,7 +4601,7 @@ var normalizeInput = (e, t) => {
|
|
|
4601
4601
|
});
|
|
4602
4602
|
const B = () => {
|
|
4603
4603
|
i.value.sort(($, V) => sortSlotElementsByPosition($.value.el.value, V.value.el.value)), s.value && r.value !== p.value.findIndex(($) => $.id === s.value) && (r.value = p.value.findIndex(($) => $.id === s.value));
|
|
4604
|
-
},
|
|
4604
|
+
}, A = ($) => {
|
|
4605
4605
|
i.value = i.value.filter((V) => V.value.internalId !== $);
|
|
4606
4606
|
};
|
|
4607
4607
|
return provide(tabsInjectionKey, {
|
|
@@ -4612,7 +4612,7 @@ var normalizeInput = (e, t) => {
|
|
|
4612
4612
|
inactiveTabClass: toRef(() => n.inactiveTabClass),
|
|
4613
4613
|
tabClass: toRef(() => n.tabClass),
|
|
4614
4614
|
registerTab: S,
|
|
4615
|
-
unregisterTab:
|
|
4615
|
+
unregisterTab: A,
|
|
4616
4616
|
activeId: s,
|
|
4617
4617
|
activateTab: ($) => {
|
|
4618
4618
|
const V = p.value.findIndex((w) => w.internalId === $);
|
|
@@ -4660,20 +4660,20 @@ var normalizeInput = (e, t) => {
|
|
|
4660
4660
|
type: "button"
|
|
4661
4661
|
}, { ref_for: !0 }, w.titleLinkAttrs, {
|
|
4662
4662
|
onKeydown: [
|
|
4663
|
-
V[0] || (V[0] = withKeys(withModifiers((
|
|
4664
|
-
V[1] || (V[1] = withKeys(withModifiers((
|
|
4665
|
-
V[2] || (V[2] = withKeys(withModifiers((
|
|
4666
|
-
V[3] || (V[3] = withKeys(withModifiers((
|
|
4667
|
-
V[4] || (V[4] = withKeys(withModifiers((
|
|
4668
|
-
V[5] || (V[5] = withKeys(withModifiers((
|
|
4669
|
-
V[6] || (V[6] = withKeys(withModifiers((
|
|
4670
|
-
V[7] || (V[7] = withKeys(withModifiers((
|
|
4671
|
-
V[8] || (V[8] = withKeys((
|
|
4672
|
-
V[9] || (V[9] = withKeys((
|
|
4673
|
-
V[10] || (V[10] = withKeys((
|
|
4674
|
-
V[11] || (V[11] = withKeys((
|
|
4663
|
+
V[0] || (V[0] = withKeys(withModifiers((O) => !unref(n).vertical && P(O, -1), ["exact"]), ["left"])),
|
|
4664
|
+
V[1] || (V[1] = withKeys(withModifiers((O) => !unref(n).vertical && P(O, -999), ["shift"]), ["left"])),
|
|
4665
|
+
V[2] || (V[2] = withKeys(withModifiers((O) => unref(n).vertical && P(O, -1), ["exact"]), ["up"])),
|
|
4666
|
+
V[3] || (V[3] = withKeys(withModifiers((O) => unref(n).vertical && P(O, -999), ["shift"]), ["up"])),
|
|
4667
|
+
V[4] || (V[4] = withKeys(withModifiers((O) => !unref(n).vertical && P(O, 1), ["exact"]), ["right"])),
|
|
4668
|
+
V[5] || (V[5] = withKeys(withModifiers((O) => !unref(n).vertical && P(O, 999), ["shift"]), ["right"])),
|
|
4669
|
+
V[6] || (V[6] = withKeys(withModifiers((O) => unref(n).vertical && P(O, 1), ["exact"]), ["down"])),
|
|
4670
|
+
V[7] || (V[7] = withKeys(withModifiers((O) => unref(n).vertical && P(O, 999), ["shift"]), ["down"])),
|
|
4671
|
+
V[8] || (V[8] = withKeys((O) => P(O, -999), ["page-up"])),
|
|
4672
|
+
V[9] || (V[9] = withKeys((O) => P(O, 999), ["page-down"])),
|
|
4673
|
+
V[10] || (V[10] = withKeys((O) => P(O, -999), ["home"])),
|
|
4674
|
+
V[11] || (V[11] = withKeys((O) => P(O, 999), ["end"]))
|
|
4675
4675
|
],
|
|
4676
|
-
onClick: withModifiers((
|
|
4676
|
+
onClick: withModifiers((O) => N(O, L), ["stop"])
|
|
4677
4677
|
}), [w.titleComponent ? (openBlock(), createBlock(resolveDynamicComponent(w.titleComponent), { key: 0 })) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [createTextVNode(toDisplayString(w.title), 1)], 64))], 16, _hoisted_2$1u)], 2))), 128)),
|
|
4678
4678
|
renderSlot($.$slots, "tabs-end")
|
|
4679
4679
|
], 10, _hoisted_1$24)], 2),
|
|
@@ -6429,17 +6429,17 @@ const MAX_RESET_COUNT = 50, computePosition$1 = async (e, t, n) => {
|
|
|
6429
6429
|
}, p = getAlignmentAxis(o), m = getAxisLength(p), g = await s.getDimensions(c), b = p === "y", v = b ? "top" : "left", _ = b ? "bottom" : "right", C = b ? "clientHeight" : "clientWidth", k = r.reference[m] + r.reference[p] - f[p] - r.floating[m], E = f[p] - r.reference[p], D = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(c));
|
|
6430
6430
|
let I = D ? D[C] : 0;
|
|
6431
6431
|
(!I || !await (s.isElement == null ? void 0 : s.isElement(D))) && (I = i.floating[C] || r.floating[m]);
|
|
6432
|
-
const N = k / 2 - E / 2, P = I / 2 - g[m] / 2 - 1, R = min$2(u[v], P), T = min$2(u[_], P), M = I - g[m] - T, S = I / 2 - g[m] / 2 + N, B = clamp(R, S, M),
|
|
6432
|
+
const N = k / 2 - E / 2, P = I / 2 - g[m] / 2 - 1, R = min$2(u[v], P), T = min$2(u[_], P), M = I - g[m] - T, S = I / 2 - g[m] / 2 + N, B = clamp(R, S, M), A = !l.arrow && getAlignment(o) != null && S !== B && r.reference[m] / 2 - (S < R ? R : T) - g[m] / 2 < 0, $ = A ? S < R ? S - R : S - M : 0;
|
|
6433
6433
|
return {
|
|
6434
6434
|
[p]: f[p] + $,
|
|
6435
6435
|
data: {
|
|
6436
6436
|
[p]: B,
|
|
6437
6437
|
centerOffset: S - B - $,
|
|
6438
|
-
...
|
|
6438
|
+
...A && {
|
|
6439
6439
|
alignmentOffset: $
|
|
6440
6440
|
}
|
|
6441
6441
|
},
|
|
6442
|
-
reset:
|
|
6442
|
+
reset: A
|
|
6443
6443
|
};
|
|
6444
6444
|
}
|
|
6445
6445
|
}), flip$1 = function(e) {
|
|
@@ -6479,8 +6479,8 @@ const MAX_RESET_COUNT = 50, computePosition$1 = async (e, t, n) => {
|
|
|
6479
6479
|
overflows: P
|
|
6480
6480
|
}], !P.every((B) => B <= 0)) {
|
|
6481
6481
|
var T, M;
|
|
6482
|
-
const B = (((T = r.flip) == null ? void 0 : T.index) || 0) + 1,
|
|
6483
|
-
if (
|
|
6482
|
+
const B = (((T = r.flip) == null ? void 0 : T.index) || 0) + 1, A = I[B];
|
|
6483
|
+
if (A && (!(u === "alignment" ? _ !== getSideAxis(A) : !1) || // We leave the current main axis only if every placement on that axis
|
|
6484
6484
|
// overflows the main axis.
|
|
6485
6485
|
R.every((w) => getSideAxis(w.placement) === _ ? w.overflows[0] > 0 : !0)))
|
|
6486
6486
|
return {
|
|
@@ -6489,7 +6489,7 @@ const MAX_RESET_COUNT = 50, computePosition$1 = async (e, t, n) => {
|
|
|
6489
6489
|
overflows: R
|
|
6490
6490
|
},
|
|
6491
6491
|
reset: {
|
|
6492
|
-
placement:
|
|
6492
|
+
placement: A
|
|
6493
6493
|
}
|
|
6494
6494
|
};
|
|
6495
6495
|
let $ = (M = R.filter((V) => V.overflows[0] <= 0).sort((V, w) => V.overflows[1] - w.overflows[1])[0]) == null ? void 0 : M.placement;
|
|
@@ -6505,7 +6505,7 @@ const MAX_RESET_COUNT = 50, computePosition$1 = async (e, t, n) => {
|
|
|
6505
6505
|
L === "y";
|
|
6506
6506
|
}
|
|
6507
6507
|
return !0;
|
|
6508
|
-
}).map((w) => [w.placement, w.overflows.filter((L) => L > 0).reduce((L,
|
|
6508
|
+
}).map((w) => [w.placement, w.overflows.filter((L) => L > 0).reduce((L, O) => L + O, 0)]).sort((w, L) => w[1] - L[1])[0]) == null ? void 0 : S[0];
|
|
6509
6509
|
V && ($ = V);
|
|
6510
6510
|
break;
|
|
6511
6511
|
}
|
|
@@ -10960,14 +10960,14 @@ function formatLocale(e) {
|
|
|
10960
10960
|
var D = g === "$" ? n : g === "#" && /[boxX]/.test(E) ? "0" + E.toLowerCase() : "", I = g === "$" ? a : /[%p]/.test(E) ? s : "", N = formatTypes[E], P = /[defgprs%]/.test(E);
|
|
10961
10961
|
C = C === void 0 ? 6 : /[gprs]/.test(E) ? Math.max(1, Math.min(21, C)) : Math.max(0, Math.min(20, C));
|
|
10962
10962
|
function R(T) {
|
|
10963
|
-
var M = D, S = I, B,
|
|
10963
|
+
var M = D, S = I, B, A, $;
|
|
10964
10964
|
if (E === "c")
|
|
10965
10965
|
S = N(T) + S, T = "";
|
|
10966
10966
|
else {
|
|
10967
10967
|
T = +T;
|
|
10968
10968
|
var V = T < 0 || 1 / T < 0;
|
|
10969
10969
|
if (T = isNaN(T) ? l : N(Math.abs(T), C), k && (T = formatTrim(T)), V && +T == 0 && m !== "+" && (V = !1), M = (V ? m === "(" ? m : i : m === "-" || m === "(" ? "" : m) + M, S = (E === "s" ? prefixes[8 + prefixExponent / 3] : "") + S + (V && m === "(" ? ")" : ""), P) {
|
|
10970
|
-
for (B = -1,
|
|
10970
|
+
for (B = -1, A = T.length; ++B < A; )
|
|
10971
10971
|
if ($ = T.charCodeAt(B), 48 > $ || $ > 57) {
|
|
10972
10972
|
S = ($ === 46 ? o + T.slice(B + 1) : T.slice(B)) + S, T = T.slice(0, B);
|
|
10973
10973
|
break;
|
|
@@ -11290,8 +11290,8 @@ function intersect(e, t, n, a, o, r, s, i) {
|
|
|
11290
11290
|
return f = (d * (t - r) - u * (e - o)) / f, [e + f * l, t + f * c];
|
|
11291
11291
|
}
|
|
11292
11292
|
function cornerTangents(e, t, n, a, o, r, s) {
|
|
11293
|
-
var i = e - n, l = t - a, c = (s ? r : -r) / sqrt(i * i + l * l), d = c * l, u = -c * i, f = e + d, p = t + u, m = n + d, g = a + u, b = (f + m) / 2, v = (p + g) / 2, _ = m - f, C = g - p, k = _ * _ + C * C, E = o - r, D = f * g - m * p, I = (C < 0 ? -1 : 1) * sqrt(max(0, E * E * k - D * D)), N = (D * C - _ * I) / k, P = (-D * _ - C * I) / k, R = (D * C + _ * I) / k, T = (-D * _ + C * I) / k, M = N - b, S = P - v, B = R - b,
|
|
11294
|
-
return M * M + S * S > B * B +
|
|
11293
|
+
var i = e - n, l = t - a, c = (s ? r : -r) / sqrt(i * i + l * l), d = c * l, u = -c * i, f = e + d, p = t + u, m = n + d, g = a + u, b = (f + m) / 2, v = (p + g) / 2, _ = m - f, C = g - p, k = _ * _ + C * C, E = o - r, D = f * g - m * p, I = (C < 0 ? -1 : 1) * sqrt(max(0, E * E * k - D * D)), N = (D * C - _ * I) / k, P = (-D * _ - C * I) / k, R = (D * C + _ * I) / k, T = (-D * _ + C * I) / k, M = N - b, S = P - v, B = R - b, A = T - v;
|
|
11294
|
+
return M * M + S * S > B * B + A * A && (N = R, P = T), {
|
|
11295
11295
|
cx: N,
|
|
11296
11296
|
cy: P,
|
|
11297
11297
|
x01: -d,
|
|
@@ -11310,20 +11310,20 @@ function arc() {
|
|
|
11310
11310
|
else {
|
|
11311
11311
|
var _ = m, C = g, k = m, E = g, D = b, I = b, N = s.apply(this, arguments) / 2, P = N > epsilon$2 && (a ? +a.apply(this, arguments) : sqrt(f * f + p * p)), R = min(abs(p - f) / 2, +n.apply(this, arguments)), T = R, M = R, S, B;
|
|
11312
11312
|
if (P > epsilon$2) {
|
|
11313
|
-
var
|
|
11314
|
-
(D -=
|
|
11313
|
+
var A = asin(P / f * sin(N)), $ = asin(P / p * sin(N));
|
|
11314
|
+
(D -= A * 2) > epsilon$2 ? (A *= v ? 1 : -1, k += A, E -= A) : (D = 0, k = E = (m + g) / 2), (I -= $ * 2) > epsilon$2 ? ($ *= v ? 1 : -1, _ += $, C -= $) : (I = 0, _ = C = (m + g) / 2);
|
|
11315
11315
|
}
|
|
11316
|
-
var V = p * cos(_), w = p * sin(_), L = f * cos(E),
|
|
11316
|
+
var V = p * cos(_), w = p * sin(_), L = f * cos(E), O = f * sin(E);
|
|
11317
11317
|
if (R > epsilon$2) {
|
|
11318
11318
|
var z = p * cos(C), F = p * sin(C), q = f * cos(k), U = f * sin(k), Q;
|
|
11319
11319
|
if (b < pi$1)
|
|
11320
|
-
if (Q = intersect(V, w, q, U, z, F, L,
|
|
11320
|
+
if (Q = intersect(V, w, q, U, z, F, L, O)) {
|
|
11321
11321
|
var X = V - Q[0], ne = w - Q[1], ce = z - Q[0], ie = F - Q[1], se = 1 / sin(acos((X * ce + ne * ie) / (sqrt(X * X + ne * ne) * sqrt(ce * ce + ie * ie))) / 2), de = sqrt(Q[0] * Q[0] + Q[1] * Q[1]);
|
|
11322
11322
|
T = min(R, (f - de) / (se - 1)), M = min(R, (p - de) / (se + 1));
|
|
11323
11323
|
} else
|
|
11324
11324
|
T = M = 0;
|
|
11325
11325
|
}
|
|
11326
|
-
I > epsilon$2 ? M > epsilon$2 ? (S = cornerTangents(q, U, V, w, p, M, v), B = cornerTangents(z, F, L,
|
|
11326
|
+
I > epsilon$2 ? M > epsilon$2 ? (S = cornerTangents(q, U, V, w, p, M, v), B = cornerTangents(z, F, L, O, p, M, v), i.moveTo(S.cx + S.x01, S.cy + S.y01), M < R ? i.arc(S.cx, S.cy, M, atan2(S.y01, S.x01), atan2(B.y01, B.x01), !v) : (i.arc(S.cx, S.cy, M, atan2(S.y01, S.x01), atan2(S.y11, S.x11), !v), i.arc(0, 0, p, atan2(S.cy + S.y11, S.cx + S.x11), atan2(B.cy + B.y11, B.cx + B.x11), !v), i.arc(B.cx, B.cy, M, atan2(B.y11, B.x11), atan2(B.y01, B.x01), !v))) : (i.moveTo(V, w), i.arc(0, 0, p, _, C, !v)) : i.moveTo(V, w), !(f > epsilon$2) || !(D > epsilon$2) ? i.lineTo(L, O) : T > epsilon$2 ? (S = cornerTangents(L, O, z, F, f, -T, v), B = cornerTangents(V, w, q, U, f, -T, v), i.lineTo(S.cx + S.x01, S.cy + S.y01), T < R ? i.arc(S.cx, S.cy, T, atan2(S.y01, S.x01), atan2(B.y01, B.x01), !v) : (i.arc(S.cx, S.cy, T, atan2(S.y01, S.x01), atan2(S.y11, S.x11), !v), i.arc(0, 0, f, atan2(S.cy + S.y11, S.cx + S.x11), atan2(B.cy + B.y11, B.cx + B.x11), v), i.arc(B.cx, B.cy, T, atan2(B.y11, B.x11), atan2(B.y01, B.x01), !v))) : i.arc(0, 0, f, E, k, v);
|
|
11327
11327
|
}
|
|
11328
11328
|
if (i.closePath(), d) return i = null, d + "" || null;
|
|
11329
11329
|
}
|
|
@@ -14737,14 +14737,14 @@ function setValidations(e) {
|
|
|
14737
14737
|
config: p,
|
|
14738
14738
|
validationGroups: m
|
|
14739
14739
|
} = sortValidations(t), g = _objectSpread2$1(_objectSpread2$1({}, i), p), b = a ? computed$1(() => {
|
|
14740
|
-
const
|
|
14741
|
-
return
|
|
14740
|
+
const O = unref(n);
|
|
14741
|
+
return O ? unref(O[a]) : void 0;
|
|
14742
14742
|
}) : n, v = _objectSpread2$1({}, unref(c) || {}), _ = computed$1(() => {
|
|
14743
|
-
const
|
|
14744
|
-
return a ?
|
|
14743
|
+
const O = unref(c);
|
|
14744
|
+
return a ? O ? unref(O[a]) : void 0 : O;
|
|
14745
14745
|
}), C = createValidationResults(u, b, a, s, d, g, l, _, n), k = collectNestedValidationResults(f, b, d, s, g, l, _), E = {};
|
|
14746
|
-
m && Object.entries(m).forEach((
|
|
14747
|
-
let [z, F] =
|
|
14746
|
+
m && Object.entries(m).forEach((O) => {
|
|
14747
|
+
let [z, F] = O;
|
|
14748
14748
|
E[z] = {
|
|
14749
14749
|
$invalid: gatherBooleanGroupProperties(F, k, "$invalid"),
|
|
14750
14750
|
$error: gatherBooleanGroupProperties(F, k, "$error"),
|
|
@@ -14763,36 +14763,36 @@ function setValidations(e) {
|
|
|
14763
14763
|
$touch: M,
|
|
14764
14764
|
$reset: S,
|
|
14765
14765
|
$silentErrors: B,
|
|
14766
|
-
$commit:
|
|
14766
|
+
$commit: A
|
|
14767
14767
|
} = createMetaFields(C, k, r), $ = a ? computed$1({
|
|
14768
14768
|
get: () => unref(b),
|
|
14769
|
-
set: (
|
|
14769
|
+
set: (O) => {
|
|
14770
14770
|
D.value = !0;
|
|
14771
14771
|
const z = unref(n), F = unref(c);
|
|
14772
|
-
F && (F[a] = v[a]), isRef(z[a]) ? z[a].value =
|
|
14772
|
+
F && (F[a] = v[a]), isRef(z[a]) ? z[a].value = O : z[a] = O;
|
|
14773
14773
|
}
|
|
14774
14774
|
}) : null;
|
|
14775
14775
|
a && g.$autoDirty && watch(b, () => {
|
|
14776
14776
|
D.value || M();
|
|
14777
|
-
const
|
|
14778
|
-
|
|
14777
|
+
const O = unref(c);
|
|
14778
|
+
O && (O[a] = v[a]);
|
|
14779
14779
|
}, {
|
|
14780
14780
|
flush: "sync"
|
|
14781
14781
|
});
|
|
14782
14782
|
async function V() {
|
|
14783
|
-
return M(), g.$rewardEarly && (
|
|
14784
|
-
if (!T.value) return
|
|
14783
|
+
return M(), g.$rewardEarly && (A(), await nextTick$1()), await nextTick$1(), new Promise((O) => {
|
|
14784
|
+
if (!T.value) return O(!N.value);
|
|
14785
14785
|
const z = watch(T, () => {
|
|
14786
|
-
|
|
14786
|
+
O(!N.value), z();
|
|
14787
14787
|
});
|
|
14788
14788
|
});
|
|
14789
14789
|
}
|
|
14790
|
-
function w(
|
|
14791
|
-
return (r.value || {})[
|
|
14790
|
+
function w(O) {
|
|
14791
|
+
return (r.value || {})[O];
|
|
14792
14792
|
}
|
|
14793
14793
|
function L() {
|
|
14794
|
-
isRef(c) ? c.value = v : Object.keys(v).length === 0 ? Object.keys(c).forEach((
|
|
14795
|
-
delete c[
|
|
14794
|
+
isRef(c) ? c.value = v : Object.keys(v).length === 0 ? Object.keys(c).forEach((O) => {
|
|
14795
|
+
delete c[O];
|
|
14796
14796
|
}) : Object.assign(c, v);
|
|
14797
14797
|
}
|
|
14798
14798
|
return reactive(_objectSpread2$1(_objectSpread2$1(_objectSpread2$1({}, C), {}, {
|
|
@@ -14808,7 +14808,7 @@ function setValidations(e) {
|
|
|
14808
14808
|
$path: d || ROOT_PATH,
|
|
14809
14809
|
$silentErrors: B,
|
|
14810
14810
|
$validate: V,
|
|
14811
|
-
$commit:
|
|
14811
|
+
$commit: A
|
|
14812
14812
|
}, r && {
|
|
14813
14813
|
$getResultsForChild: w,
|
|
14814
14814
|
$clearExternalResults: L,
|
|
@@ -15225,12 +15225,14 @@ const postcodeRegex = /^([A-Za-z][A-HJ-Ya-hj-y]?\d[A-Za-z\d]? ?\d[A-Za-z]{2}|GIR
|
|
|
15225
15225
|
}) : {};
|
|
15226
15226
|
},
|
|
15227
15227
|
errorsList() {
|
|
15228
|
-
const e = [];
|
|
15229
|
-
|
|
15230
|
-
this.v
|
|
15231
|
-
|
|
15228
|
+
const e = this.inputVal, t = [];
|
|
15229
|
+
Object.keys(this.rules.inputVal).forEach((o) => {
|
|
15230
|
+
this.v$.inputVal?.$errors && this.v$.inputVal.$errors.forEach((r) => {
|
|
15231
|
+
r.$validator === o && t.push(o);
|
|
15232
15232
|
});
|
|
15233
|
-
})
|
|
15233
|
+
});
|
|
15234
|
+
const a = typeof e == "string" ? !/\S/.test(e) : !e;
|
|
15235
|
+
return "required" in this.rules.inputVal && this.v$.inputVal?.$anyDirty && a && !t.includes("required") && t.push("required"), t;
|
|
15234
15236
|
}
|
|
15235
15237
|
},
|
|
15236
15238
|
watch: {
|
|
@@ -15243,17 +15245,11 @@ const postcodeRegex = /^([A-Za-z][A-HJ-Ya-hj-y]?\d[A-Za-z\d]? ?\d[A-Za-z]{2}|GIR
|
|
|
15243
15245
|
* manually run validation and emit to parent
|
|
15244
15246
|
*/
|
|
15245
15247
|
manualValidate() {
|
|
15246
|
-
|
|
15247
|
-
|
|
15248
|
-
typeof this.inputVal == "string" ? /\S/.test(this.inputVal) || (e = !0) : this.inputVal || (e = !0), e && this.errorsList.indexOf("required") === -1 && this.v$.inputVal?.$anyDirty && this.errorsList.push("required");
|
|
15249
|
-
} else
|
|
15250
|
-
this.errorsList.forEach((e, t) => {
|
|
15251
|
-
e === "required" && this.errorsList.splice(t, 1);
|
|
15252
|
-
});
|
|
15253
|
-
this.errorsList.length && (this.isInvalid = !0), this.touched = !0, this.$emit("status-update", {
|
|
15248
|
+
const e = [...this.errorsList];
|
|
15249
|
+
this.isInvalid = e.length > 0, this.touched = !0, this.$emit("status-update", {
|
|
15254
15250
|
field: this.fieldName,
|
|
15255
15251
|
value: this.inputVal,
|
|
15256
|
-
errors:
|
|
15252
|
+
errors: e
|
|
15257
15253
|
});
|
|
15258
15254
|
},
|
|
15259
15255
|
/**
|
|
@@ -17698,8 +17694,8 @@ function updateSwiper(e) {
|
|
|
17698
17694
|
l.includes("controller") && isObject$1(M) && M.control && isObject$1(S) && !S.control && (C = !0);
|
|
17699
17695
|
const B = b.pagination;
|
|
17700
17696
|
l.includes("pagination") && isObject$1(B) && (B.el || o) && (v.pagination || v.pagination === !1) && u && !u.el && (k = !0);
|
|
17701
|
-
const
|
|
17702
|
-
l.includes("scrollbar") && isObject$1(
|
|
17697
|
+
const A = b.scrollbar;
|
|
17698
|
+
l.includes("scrollbar") && isObject$1(A) && (A.el || a) && (v.scrollbar || v.scrollbar === !1) && p && !p.el && (E = !0);
|
|
17703
17699
|
const $ = b.navigation;
|
|
17704
17700
|
l.includes("navigation") && isObject$1($) && ($.prevEl || n) && ($.nextEl || t) && (v.navigation || v.navigation === !1) && f && !f.prevEl && !f.nextEl && (D = !0);
|
|
17705
17701
|
const V = (w) => {
|
|
@@ -17707,12 +17703,12 @@ function updateSwiper(e) {
|
|
|
17707
17703
|
if (!L)
|
|
17708
17704
|
return;
|
|
17709
17705
|
L.destroy();
|
|
17710
|
-
const
|
|
17706
|
+
const O = v[w], z = isObject$1(O) ? O : void 0;
|
|
17711
17707
|
w === "navigation" ? (r.isElement && (L.prevEl?.remove(), L.nextEl?.remove()), z && (z.prevEl = void 0, z.nextEl = void 0), L.prevEl = void 0, L.nextEl = void 0) : (r.isElement && L.el?.remove(), z && (z.el = void 0), L.el = void 0);
|
|
17712
17708
|
};
|
|
17713
17709
|
if (l.includes("loop") && r.isElement && (d.loop && !i.loop ? I = !0 : !d.loop && i.loop ? N = !0 : P = !0), c.forEach((w) => {
|
|
17714
|
-
const L = v[w],
|
|
17715
|
-
isObject$1(L) && isObject$1(
|
|
17710
|
+
const L = v[w], O = b[w];
|
|
17711
|
+
isObject$1(L) && isObject$1(O) ? (Object.assign(L, O), (w === "navigation" || w === "pagination" || w === "scrollbar") && "enabled" in O && !O.enabled && V(w)) : (O === !0 || O === !1) && (w === "navigation" || w === "pagination" || w === "scrollbar") ? O === !1 && V(w) : v[w] = O;
|
|
17716
17712
|
}), c.includes("controller") && !C && r.controller && r.controller.control && isObject$1(S) && S.control && (r.controller.control = S.control), l.includes("children") && s && m && d.virtual?.enabled ? (m.slides = s, m.update(!0)) : l.includes("virtual") && m && d.virtual?.enabled && (s && (m.slides = s), m.update(!0)), l.includes("children") && s && d.loop && (P = !0), _ && g && g.init() && g.update(!0), C && r.controller && isObject$1(S) && (r.controller.control = S.control), k && u) {
|
|
17717
17713
|
if (r.isElement && (!o || typeof o == "string")) {
|
|
17718
17714
|
const L = document.createElement("div");
|
|
@@ -18510,7 +18506,7 @@ function loopFix(e = {}) {
|
|
|
18510
18506
|
const P = [], R = [], T = N ? Math.ceil(u.length / g.grid.rows) : u.length, M = s && T - C < E && !k;
|
|
18511
18507
|
let S = M ? C : d.activeIndex;
|
|
18512
18508
|
typeof c > "u" ? c = d.getSlideIndex(u.find((z) => z.classList.contains(g.slideActiveClass))) : S = c;
|
|
18513
|
-
const B = a === "next" || !a,
|
|
18509
|
+
const B = a === "next" || !a, A = a === "prev" || !a;
|
|
18514
18510
|
let $ = 0, V = 0;
|
|
18515
18511
|
const L = (N ? u[c].column ?? 0 : c) + (k && typeof o > "u" ? -E / 2 + 0.5 : 0);
|
|
18516
18512
|
if (L < I) {
|
|
@@ -18535,16 +18531,16 @@ function loopFix(e = {}) {
|
|
|
18535
18531
|
}
|
|
18536
18532
|
if (d.__preventObserver__ = !0, requestAnimationFrame(() => {
|
|
18537
18533
|
d.__preventObserver__ = !1;
|
|
18538
|
-
}), d.params.effect === "cards" && u.length < E + I * 2 && (R.includes(c) && R.splice(R.indexOf(c), 1), P.includes(c) && P.splice(P.indexOf(c), 1)),
|
|
18534
|
+
}), d.params.effect === "cards" && u.length < E + I * 2 && (R.includes(c) && R.splice(R.indexOf(c), 1), P.includes(c) && P.splice(P.indexOf(c), 1)), A && P.forEach((z) => {
|
|
18539
18535
|
const F = u[z];
|
|
18540
18536
|
F.swiperLoopMoveDOM = !0, m.prepend(F), F.swiperLoopMoveDOM = !1;
|
|
18541
18537
|
}), B && R.forEach((z) => {
|
|
18542
18538
|
const F = u[z];
|
|
18543
18539
|
F.swiperLoopMoveDOM = !0, m.append(F), F.swiperLoopMoveDOM = !1;
|
|
18544
|
-
}), d.recalcSlides(), g.slidesPerView === "auto" ? d.updateSlides() : N && (P.length > 0 &&
|
|
18540
|
+
}), d.recalcSlides(), g.slidesPerView === "auto" ? d.updateSlides() : N && (P.length > 0 && A || R.length > 0 && B) && d.slides.forEach((z, F) => {
|
|
18545
18541
|
d.grid.updateSlide(F, z, d.slides);
|
|
18546
18542
|
}), g.watchSlidesProgress && d.updateSlidesOffset(), n) {
|
|
18547
|
-
if (P.length > 0 &&
|
|
18543
|
+
if (P.length > 0 && A) {
|
|
18548
18544
|
if (typeof t > "u") {
|
|
18549
18545
|
const z = d.slidesGrid[S], q = d.slidesGrid[S + $] - z;
|
|
18550
18546
|
l ? d.setTranslate(d.translate - q) : (d.slideTo(S + Math.ceil($), 0, !1, !0), o && (d.touchEventsData.startTranslate = d.touchEventsData.startTranslate - q, d.touchEventsData.currentTranslate = d.touchEventsData.currentTranslate - q));
|
|
@@ -18562,8 +18558,8 @@ function loopFix(e = {}) {
|
|
|
18562
18558
|
}
|
|
18563
18559
|
}
|
|
18564
18560
|
d.allowSlidePrev = f, d.allowSlideNext = p;
|
|
18565
|
-
const
|
|
18566
|
-
if (
|
|
18561
|
+
const O = d.controller?.control;
|
|
18562
|
+
if (O && !i) {
|
|
18567
18563
|
const z = {
|
|
18568
18564
|
slideRealIndex: t,
|
|
18569
18565
|
direction: a,
|
|
@@ -18571,14 +18567,14 @@ function loopFix(e = {}) {
|
|
|
18571
18567
|
activeSlideIndex: c,
|
|
18572
18568
|
byController: !0
|
|
18573
18569
|
};
|
|
18574
|
-
Array.isArray(
|
|
18570
|
+
Array.isArray(O) ? O.forEach((F) => {
|
|
18575
18571
|
!F.destroyed && F.params.loop && F.loopFix({
|
|
18576
18572
|
...z,
|
|
18577
18573
|
slideTo: F.params.slidesPerView === g.slidesPerView ? n : !1
|
|
18578
18574
|
});
|
|
18579
|
-
}) :
|
|
18575
|
+
}) : O instanceof d.constructor && O.params.loop && O.loopFix({
|
|
18580
18576
|
...z,
|
|
18581
|
-
slideTo:
|
|
18577
|
+
slideTo: O.params.slidesPerView === g.slidesPerView ? n : !1
|
|
18582
18578
|
});
|
|
18583
18579
|
}
|
|
18584
18580
|
d.emit("loopFix");
|
|
@@ -19095,19 +19091,19 @@ function updateSlides() {
|
|
|
19095
19091
|
n.virtual?.slidesPerViewAutoSlideSize && (P = n.virtual.slidesPerViewAutoSlideSize), P && M && (n.roundLengths && (P = Math.floor(P)), M.style[e.getDirectionLabel("width")] = `${P}px`);
|
|
19096
19092
|
else if (n.slidesPerView === "auto") {
|
|
19097
19093
|
R && (M.style[e.getDirectionLabel("width")] = "");
|
|
19098
|
-
const S = getComputedStyle(M), B = M.style.transform,
|
|
19099
|
-
if (B && (M.style.transform = "none"),
|
|
19094
|
+
const S = getComputedStyle(M), B = M.style.transform, A = M.style.webkitTransform;
|
|
19095
|
+
if (B && (M.style.transform = "none"), A && (M.style.webkitTransform = "none"), n.roundLengths)
|
|
19100
19096
|
P = e.isHorizontal() ? elementOuterSize(M, "width") : elementOuterSize(M, "height");
|
|
19101
19097
|
else {
|
|
19102
|
-
const $ = t(S, "width"), V = t(S, "padding-left"), w = t(S, "padding-right"), L = t(S, "margin-left"),
|
|
19098
|
+
const $ = t(S, "width"), V = t(S, "padding-left"), w = t(S, "padding-right"), L = t(S, "margin-left"), O = t(S, "margin-right"), z = S.getPropertyValue("box-sizing");
|
|
19103
19099
|
if (z && z === "border-box")
|
|
19104
|
-
P = $ + L +
|
|
19100
|
+
P = $ + L + O;
|
|
19105
19101
|
else {
|
|
19106
19102
|
const { clientWidth: F, offsetWidth: q } = M;
|
|
19107
|
-
P = $ + V + w + L +
|
|
19103
|
+
P = $ + V + w + L + O + (q - F);
|
|
19108
19104
|
}
|
|
19109
19105
|
}
|
|
19110
|
-
B && (M.style.transform = B),
|
|
19106
|
+
B && (M.style.transform = B), A && (M.style.webkitTransform = A), n.roundLengths && (P = Math.floor(P));
|
|
19111
19107
|
} else
|
|
19112
19108
|
P = (C - (n.slidesPerView - 1) * k) / n.slidesPerView, n.roundLengths && (P = Math.floor(P)), M && (M.style[e.getDirectionLabel("width")] = `${P}px`);
|
|
19113
19109
|
M && (M.swiperSlideSize = P), p.push(P), n.centeredSlides ? (E = E + P / 2 + D / 2 + k, D === 0 && T !== 0 && (E = E - C / 2 - k), T === 0 && (E = E - C / 2 - k), Math.abs(E) < 1 / 1e3 && (E = 0), n.roundLengths && (E = Math.floor(E)), I % n.slidesPerGroup === 0 && u.push(E), f.push(E)) : (n.roundLengths && (E = Math.floor(E)), (I - Math.min(e.params.slidesPerGroupSkip, I)) % e.params.slidesPerGroup === 0 && u.push(E), f.push(E), E = E + P + k), e.virtualSize += P + k, D = P, I += 1;
|
|
@@ -19117,31 +19113,31 @@ function updateSlides() {
|
|
|
19117
19113
|
const T = n.slidesPerView !== "auto" && n.slidesPerView % 1 !== 0, M = n.snapToSlideEdge && !n.loop && (n.slidesPerView === "auto" || T);
|
|
19118
19114
|
let S = u.length;
|
|
19119
19115
|
if (M) {
|
|
19120
|
-
let
|
|
19116
|
+
let A;
|
|
19121
19117
|
if (n.slidesPerView === "auto") {
|
|
19122
|
-
|
|
19118
|
+
A = 1;
|
|
19123
19119
|
let $ = 0;
|
|
19124
19120
|
for (let V = p.length - 1; V >= 0 && ($ += p[V] + (V < p.length - 1 ? k : 0), $ <= C); V -= 1)
|
|
19125
|
-
|
|
19121
|
+
A = p.length - V;
|
|
19126
19122
|
} else
|
|
19127
|
-
|
|
19128
|
-
S = Math.max(d -
|
|
19123
|
+
A = Math.floor(n.slidesPerView);
|
|
19124
|
+
S = Math.max(d - A, 0);
|
|
19129
19125
|
}
|
|
19130
19126
|
const B = [];
|
|
19131
|
-
for (let
|
|
19132
|
-
let $ = u[
|
|
19133
|
-
n.roundLengths && ($ = Math.floor($)), M ?
|
|
19127
|
+
for (let A = 0; A < u.length; A += 1) {
|
|
19128
|
+
let $ = u[A];
|
|
19129
|
+
n.roundLengths && ($ = Math.floor($)), M ? A <= S && B.push($) : u[A] <= e.virtualSize - C && B.push($);
|
|
19134
19130
|
}
|
|
19135
19131
|
u = B, Math.floor(e.virtualSize - C) - Math.floor(u[u.length - 1]) > 1 && (M || u.push(e.virtualSize - C));
|
|
19136
19132
|
}
|
|
19137
19133
|
if (i && n.loop) {
|
|
19138
19134
|
const T = p[0] + k, M = e.virtual.slidesBefore ?? 0, S = e.virtual.slidesAfter ?? 0, B = M + S;
|
|
19139
19135
|
if (n.slidesPerGroup > 1) {
|
|
19140
|
-
const
|
|
19141
|
-
for (let V = 0; V <
|
|
19136
|
+
const A = Math.ceil(B / n.slidesPerGroup), $ = T * n.slidesPerGroup;
|
|
19137
|
+
for (let V = 0; V < A; V += 1)
|
|
19142
19138
|
u.push(u[u.length - 1] + $);
|
|
19143
19139
|
}
|
|
19144
|
-
for (let
|
|
19140
|
+
for (let A = 0; A < B; A += 1)
|
|
19145
19141
|
n.slidesPerGroup === 1 && u.push(u[u.length - 1] + T), f.push(f[f.length - 1] + T), e.virtualSize += T;
|
|
19146
19142
|
}
|
|
19147
19143
|
if (u.length === 0 && (u = [0]), k !== 0) {
|
|
@@ -20299,10 +20295,10 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20299
20295
|
const T = u();
|
|
20300
20296
|
if (!T.el || !e.scrollbar.el)
|
|
20301
20297
|
return;
|
|
20302
|
-
const { scrollbar: M, rtlTranslate: S } = e, { dragEl: B, el:
|
|
20298
|
+
const { scrollbar: M, rtlTranslate: S } = e, { dragEl: B, el: A } = M, $ = e.params.loop ? e.progressLoop ?? 0 : e.progress;
|
|
20303
20299
|
let V = l, w = (c - l) * $;
|
|
20304
|
-
S ? (w = -w, w > 0 ? (V = l - w, w = 0) : -w + l > c && (V = c + w)) : w < 0 ? (V = l + w, w = 0) : w + l > c && (V = c - w), e.isHorizontal() ? (B.style.transform = `translate3d(${w}px, 0, 0)`, B.style.width = `${V}px`) : (B.style.transform = `translate3d(0px, ${w}px, 0)`, B.style.height = `${V}px`), T.hide && (r && clearTimeout(r),
|
|
20305
|
-
|
|
20300
|
+
S ? (w = -w, w > 0 ? (V = l - w, w = 0) : -w + l > c && (V = c + w)) : w < 0 ? (V = l + w, w = 0) : w + l > c && (V = c - w), e.isHorizontal() ? (B.style.transform = `translate3d(${w}px, 0, 0)`, B.style.width = `${V}px`) : (B.style.transform = `translate3d(0px, ${w}px, 0)`, B.style.height = `${V}px`), T.hide && (r && clearTimeout(r), A.style.opacity = "1", r = setTimeout(() => {
|
|
20301
|
+
A.style.opacity = "0", A.style.transitionDuration = "400ms";
|
|
20306
20302
|
}, 1e3));
|
|
20307
20303
|
}
|
|
20308
20304
|
function p(T) {
|
|
@@ -20320,31 +20316,31 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20320
20316
|
}
|
|
20321
20317
|
function b(T) {
|
|
20322
20318
|
const { scrollbar: M, rtlTranslate: S } = e, { el: B } = M;
|
|
20323
|
-
let
|
|
20324
|
-
|
|
20325
|
-
const $ = e.minTranslate() + (e.maxTranslate() - e.minTranslate()) *
|
|
20319
|
+
let A;
|
|
20320
|
+
A = (g(T) - elementOffset(B)[e.isHorizontal() ? "left" : "top"] - (i !== null ? i : l / 2)) / (c - l), A = Math.max(Math.min(A, 1), 0), S && (A = 1 - A);
|
|
20321
|
+
const $ = e.minTranslate() + (e.maxTranslate() - e.minTranslate()) * A;
|
|
20326
20322
|
e.updateProgress($), e.setTranslate($), e.updateActiveIndex(), e.updateSlidesClasses();
|
|
20327
20323
|
}
|
|
20328
20324
|
function v(T) {
|
|
20329
|
-
const M = u(), { scrollbar: S, wrapperEl: B } = e, { el:
|
|
20330
|
-
o = !0, i = T.target === $ ? g(T) - T.target.getBoundingClientRect()[e.isHorizontal() ? "left" : "top"] : null, T.preventDefault(), T.stopPropagation(), B.style.transitionDuration = "100ms", $.style.transitionDuration = "100ms", b(T), s && clearTimeout(s),
|
|
20325
|
+
const M = u(), { scrollbar: S, wrapperEl: B } = e, { el: A, dragEl: $ } = S;
|
|
20326
|
+
o = !0, i = T.target === $ ? g(T) - T.target.getBoundingClientRect()[e.isHorizontal() ? "left" : "top"] : null, T.preventDefault(), T.stopPropagation(), B.style.transitionDuration = "100ms", $.style.transitionDuration = "100ms", b(T), s && clearTimeout(s), A.style.transitionDuration = "0ms", M.hide && (A.style.opacity = "1"), e.params.cssMode && (e.wrapperEl.style.scrollSnapType = "none"), a("scrollbarDragStart", T);
|
|
20331
20327
|
}
|
|
20332
20328
|
function _(T) {
|
|
20333
|
-
const { scrollbar: M, wrapperEl: S } = e, { el: B, dragEl:
|
|
20334
|
-
o && (T.cancelable && T.preventDefault(), b(T), S.style.transitionDuration = "0ms", B.style.transitionDuration = "0ms",
|
|
20329
|
+
const { scrollbar: M, wrapperEl: S } = e, { el: B, dragEl: A } = M;
|
|
20330
|
+
o && (T.cancelable && T.preventDefault(), b(T), S.style.transitionDuration = "0ms", B.style.transitionDuration = "0ms", A.style.transitionDuration = "0ms", a("scrollbarDragMove", T));
|
|
20335
20331
|
}
|
|
20336
20332
|
function C(T) {
|
|
20337
|
-
const M = u(), { scrollbar: S, wrapperEl: B } = e, { el:
|
|
20333
|
+
const M = u(), { scrollbar: S, wrapperEl: B } = e, { el: A } = S;
|
|
20338
20334
|
o && (o = !1, e.params.cssMode && (e.wrapperEl.style.scrollSnapType = "", B.style.transitionDuration = ""), M.hide && (s && clearTimeout(s), s = nextTick(() => {
|
|
20339
|
-
|
|
20335
|
+
A.style.opacity = "0", A.style.transitionDuration = "400ms";
|
|
20340
20336
|
}, 1e3)), a("scrollbarDragEnd", T), M.snapOnRelease && e.slideToClosest());
|
|
20341
20337
|
}
|
|
20342
20338
|
function k(T) {
|
|
20343
20339
|
const { scrollbar: M, params: S } = e, B = M.el;
|
|
20344
20340
|
if (!B)
|
|
20345
20341
|
return;
|
|
20346
|
-
const
|
|
20347
|
-
B[V]("pointerdown", v,
|
|
20342
|
+
const A = S.passiveListeners ? { passive: !1, capture: !1 } : !1, $ = S.passiveListeners ? { passive: !0, capture: !1 } : !1, V = T === "on" ? "addEventListener" : "removeEventListener";
|
|
20343
|
+
B[V]("pointerdown", v, A), document[V]("pointermove", _, A), document[V]("pointerup", C, $);
|
|
20348
20344
|
}
|
|
20349
20345
|
function E() {
|
|
20350
20346
|
!u().el || !e.scrollbar.el || k("on");
|
|
@@ -20364,13 +20360,13 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20364
20360
|
return;
|
|
20365
20361
|
} else B || (B = S.el);
|
|
20366
20362
|
e.params.uniqueNavElements && typeof S.el == "string" && B.length > 1 && M.querySelectorAll(S.el).length === 1 && (B = M.querySelector(S.el)), B.length > 0 && (B = B[0]);
|
|
20367
|
-
const
|
|
20368
|
-
|
|
20363
|
+
const A = B;
|
|
20364
|
+
A.classList.add(e.isHorizontal() ? S.horizontalClass : S.verticalClass);
|
|
20369
20365
|
let $ = null;
|
|
20370
|
-
|
|
20371
|
-
el:
|
|
20366
|
+
A && ($ = A.querySelector(classesToSelector(S.dragClass)), $ || ($ = createElement("div", S.dragClass), A.append($))), Object.assign(T, {
|
|
20367
|
+
el: A,
|
|
20372
20368
|
dragEl: $
|
|
20373
|
-
}), S.draggable && E(),
|
|
20369
|
+
}), S.draggable && E(), A && A.classList[e.enabled ? "remove" : "add"](...classesToTokens(S.lockClass));
|
|
20374
20370
|
}
|
|
20375
20371
|
function N() {
|
|
20376
20372
|
const T = u(), M = e.scrollbar.el;
|
|
@@ -20498,8 +20494,8 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20498
20494
|
const V = i(), w = e.params.pagination, L = $.target;
|
|
20499
20495
|
if (!(e.pagination && e.pagination.el && (L === e.pagination.el || e.pagination.el.contains(L)) && !L.matches(classesToSelector(w?.bulletClass)))) {
|
|
20500
20496
|
if (e.navigation && e.navigation.prevEl && e.navigation.nextEl) {
|
|
20501
|
-
const
|
|
20502
|
-
makeElementsArray(e.navigation.nextEl).includes(L) && (e.isEnd && !e.params.loop || e.slideNext(), e.isEnd ? l(V.lastSlideMessage) : l(V.nextSlideMessage)),
|
|
20497
|
+
const O = makeElementsArray(e.navigation.prevEl);
|
|
20498
|
+
makeElementsArray(e.navigation.nextEl).includes(L) && (e.isEnd && !e.params.loop || e.slideNext(), e.isEnd ? l(V.lastSlideMessage) : l(V.nextSlideMessage)), O.includes(L) && (e.isBeginning && !e.params.loop || e.slidePrev(), e.isBeginning ? l(V.firstSlideMessage) : l(V.prevSlideMessage));
|
|
20503
20499
|
}
|
|
20504
20500
|
e.pagination && L.matches(classesToSelector(w?.bulletClass)) && L.click();
|
|
20505
20501
|
}
|
|
@@ -20546,19 +20542,19 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20546
20542
|
if (!L || !e.slides.includes(L))
|
|
20547
20543
|
return;
|
|
20548
20544
|
r = L;
|
|
20549
|
-
const
|
|
20545
|
+
const O = isVirtualEnabled(e), z = (O ? parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10) : e.slides.indexOf(L)) === e.activeIndex, F = e.params.watchSlidesProgress && e.visibleSlides && e.visibleSlides.includes(L);
|
|
20550
20546
|
if (z || F)
|
|
20551
20547
|
return;
|
|
20552
20548
|
const q = $.sourceCapabilities;
|
|
20553
20549
|
q && q.firesTouchEvents || (e.isHorizontal() ? e.el.scrollLeft = 0 : e.el.scrollTop = 0, requestAnimationFrame(() => {
|
|
20554
|
-
o || (e.params.loop ? e.slideToLoop(e.getSlideIndexWhenGrid(parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10)), 0) :
|
|
20550
|
+
o || (e.params.loop ? e.slideToLoop(e.getSlideIndexWhenGrid(parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10)), 0) : O ? e.slideTo(e.getSlideIndexWhenGrid(parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10)), 0) : e.slideTo(e.getSlideIndexWhenGrid(e.slides.indexOf(L)), 0), o = !1);
|
|
20555
20551
|
}));
|
|
20556
20552
|
}, S = () => {
|
|
20557
20553
|
const $ = i();
|
|
20558
20554
|
$.itemRoleDescriptionMessage && p(e.slides, $.itemRoleDescriptionMessage), $.slideRole && f(e.slides, $.slideRole);
|
|
20559
20555
|
const V = e.slides.length, w = $.slideLabelMessage;
|
|
20560
|
-
w && e.slides.forEach((L,
|
|
20561
|
-
const z = e.params.loop ? parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10) :
|
|
20556
|
+
w && e.slides.forEach((L, O) => {
|
|
20557
|
+
const z = e.params.loop ? parseInt(L.getAttribute("data-swiper-slide-index") || "0", 10) : O, F = w.replace(/\{\{index\}\}/, String(z + 1)).replace(/\{\{slidesLength\}\}/, String(V));
|
|
20562
20558
|
m(L, F);
|
|
20563
20559
|
});
|
|
20564
20560
|
}, B = () => {
|
|
@@ -20572,16 +20568,16 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20572
20568
|
b(w, U);
|
|
20573
20569
|
}
|
|
20574
20570
|
S();
|
|
20575
|
-
const
|
|
20571
|
+
const O = e.navigation ? e.navigation : { nextEl: void 0, prevEl: void 0 }, z = makeElementsArray(O.nextEl), F = makeElementsArray(O.prevEl);
|
|
20576
20572
|
z && z.forEach((q) => N(q, L, $.nextSlideMessage)), F && F.forEach((q) => N(q, L, $.prevSlideMessage)), D() && makeElementsArray(e.pagination.el).forEach((U) => {
|
|
20577
20573
|
U.addEventListener("keydown", C);
|
|
20578
20574
|
}), document.addEventListener("visibilitychange", T), e.el.addEventListener("focus", M, !0), e.el.addEventListener("pointerdown", P, !0), e.el.addEventListener("pointerup", R, !0);
|
|
20579
20575
|
};
|
|
20580
|
-
function
|
|
20576
|
+
function A() {
|
|
20581
20577
|
a && a.remove();
|
|
20582
20578
|
const $ = e.navigation ? e.navigation : { nextEl: void 0, prevEl: void 0 }, V = makeElementsArray($.nextEl), w = makeElementsArray($.prevEl);
|
|
20583
|
-
V && V.forEach((L) => L.removeEventListener("keydown", C)), w && w.forEach((L) => L.removeEventListener("keydown", C)), D() && makeElementsArray(e.pagination.el).forEach((
|
|
20584
|
-
|
|
20579
|
+
V && V.forEach((L) => L.removeEventListener("keydown", C)), w && w.forEach((L) => L.removeEventListener("keydown", C)), D() && makeElementsArray(e.pagination.el).forEach((O) => {
|
|
20580
|
+
O.removeEventListener("keydown", C);
|
|
20585
20581
|
}), document.removeEventListener("visibilitychange", T), e.el && typeof e.el != "string" && (e.el.removeEventListener("focus", M, !0), e.el.removeEventListener("pointerdown", P, !0), e.el.removeEventListener("pointerup", R, !0));
|
|
20586
20582
|
}
|
|
20587
20583
|
n("beforeInit", () => {
|
|
@@ -20595,7 +20591,7 @@ const Scrollbar = ({ swiper: e, extendParams: t, on: n, emit: a }) => {
|
|
|
20595
20591
|
}), n("paginationUpdate", () => {
|
|
20596
20592
|
i().enabled && I();
|
|
20597
20593
|
}), n("destroy", () => {
|
|
20598
|
-
i().enabled &&
|
|
20594
|
+
i().enabled && A();
|
|
20599
20595
|
});
|
|
20600
20596
|
}, _sfc_main$1V = {
|
|
20601
20597
|
name: "VsContentSwiper",
|
|
@@ -22698,7 +22694,7 @@ function _sfc_render$1i(e, t, n, a, o, r) {
|
|
|
22698
22694
|
}, 8, ["href"]);
|
|
22699
22695
|
}
|
|
22700
22696
|
const GlobalMenuLanguageItem = /* @__PURE__ */ _export_sfc(_sfc_main$1z, [["render", _sfc_render$1i]]), __vite_import_meta_env__ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1 };
|
|
22701
|
-
var define_process_env_default$2 = {
|
|
22697
|
+
var define_process_env_default$2 = {};
|
|
22702
22698
|
const getEnvValue = (e) => define_process_env_default$2 ? define_process_env_default$2[e] : __vite_import_meta_env__[e];
|
|
22703
22699
|
function isAppleIOS() {
|
|
22704
22700
|
const e = navigator.userAgent;
|
|
@@ -32497,8 +32493,8 @@ const _hoisted_1$t = {
|
|
|
32497
32493
|
return "https://www.visitscotland.com";
|
|
32498
32494
|
}), p = computed$1(() => `${f.value}${u.value ? "/" + u.value : ""}${l.value}/search-results`), g = "https://www.visitscotland.com/data/locations" + `?locale=${u.value}`, b = ref([]), v = "https://www.visitscotland.com/tms-api/v1/attractions", _ = ref([]), C = "https://www.visitscotland.com/tms-api/v1/origins?active=1", k = ref([]), E = ref([]), D = () => {
|
|
32499
32495
|
const w = getProductTypes(), L = [];
|
|
32500
|
-
w.forEach((
|
|
32501
|
-
L.push(
|
|
32496
|
+
w.forEach((O) => {
|
|
32497
|
+
L.push(O);
|
|
32502
32498
|
}), E.value = L;
|
|
32503
32499
|
}, I = computed$1(() => n.value ? [] : E.value.map((L) => ({
|
|
32504
32500
|
...L,
|
|
@@ -32513,7 +32509,7 @@ const _hoisted_1$t = {
|
|
|
32513
32509
|
const w = await getData(v);
|
|
32514
32510
|
w && (_.value = w.data);
|
|
32515
32511
|
}, T = (w, L) => {
|
|
32516
|
-
L === "key" ? r.value = b.value.find((
|
|
32512
|
+
L === "key" ? r.value = b.value.find((O) => O.key === w) : L === "id" ? r.value = b.value.find((O) => O.id === w) : r.value = b.value.find((O) => O.name === w.trim());
|
|
32517
32513
|
}, M = (w) => {
|
|
32518
32514
|
const L = w.value;
|
|
32519
32515
|
a.value = L, L === "tour" && (P(), R());
|
|
@@ -32521,7 +32517,7 @@ const _hoisted_1$t = {
|
|
|
32521
32517
|
n.value = !0, nextTick$1(() => {
|
|
32522
32518
|
n.value = !1, t.defaultLocation !== "" && c && T(t.defaultLocation, "id");
|
|
32523
32519
|
});
|
|
32524
|
-
},
|
|
32520
|
+
}, A = computed$1(() => a.value !== "cate" && a.value !== "acti,attr,reta" ? "d-lg-flex" : "");
|
|
32525
32521
|
onBeforeMount(async () => {
|
|
32526
32522
|
window.VS = {};
|
|
32527
32523
|
const w = document.createElement("script");
|
|
@@ -32552,12 +32548,12 @@ const _hoisted_1$t = {
|
|
|
32552
32548
|
createElementVNode("div", _hoisted_6$9, [
|
|
32553
32549
|
createElementVNode("label", _hoisted_7$8, toDisplayString(unref(getLabelText)("search_for", "I'm looking for")), 1),
|
|
32554
32550
|
createElementVNode("div", {
|
|
32555
|
-
class: normalizeClass(
|
|
32551
|
+
class: normalizeClass(A.value)
|
|
32556
32552
|
}, [
|
|
32557
32553
|
createVNode(VsSelect, {
|
|
32558
32554
|
options: I.value,
|
|
32559
32555
|
value: e.defaultProd,
|
|
32560
|
-
onUpdated: L[0] || (L[0] = (
|
|
32556
|
+
onUpdated: L[0] || (L[0] = (O) => M(O)),
|
|
32561
32557
|
"field-name": "prodtypes"
|
|
32562
32558
|
}, null, 8, ["options", "value"]),
|
|
32563
32559
|
createElementVNode("div", _hoisted_8$6, toDisplayString(unref(getLabelText)("in", "in")), 1)
|
|
@@ -32573,7 +32569,7 @@ const _hoisted_1$t = {
|
|
|
32573
32569
|
options: b.value,
|
|
32574
32570
|
placeholder: unref(getLabelText)("location_placeholder", "Enter a location"),
|
|
32575
32571
|
"track-by": "name",
|
|
32576
|
-
onChangeValue: L[1] || (L[1] = (
|
|
32572
|
+
onChangeValue: L[1] || (L[1] = (O) => T(O)),
|
|
32577
32573
|
"default-val": unref(r),
|
|
32578
32574
|
"data-chromatic": "ignore"
|
|
32579
32575
|
}, null, 8, ["label", "options", "placeholder", "default-val"])) : createCommentVNode("", !0),
|
|
@@ -32602,7 +32598,7 @@ const _hoisted_1$t = {
|
|
|
32602
32598
|
createVNode(_sfc_main$B, {
|
|
32603
32599
|
"start-label": unref(getLabelText)("startdate", "Start Date", "dates"),
|
|
32604
32600
|
"end-label": unref(getLabelText)("enddate", "End Date", "dates"),
|
|
32605
|
-
onDateUpdated: L[2] || (L[2] = (
|
|
32601
|
+
onDateUpdated: L[2] || (L[2] = (O) => $(O)),
|
|
32606
32602
|
"default-dates": i.value,
|
|
32607
32603
|
"selected-prod": a.value
|
|
32608
32604
|
}, null, 8, ["start-label", "end-label", "default-dates", "selected-prod"]),
|
|
@@ -32634,10 +32630,10 @@ const _hoisted_1$t = {
|
|
|
32634
32630
|
"track-by": "name",
|
|
32635
32631
|
"is-tour-location": !0
|
|
32636
32632
|
}, null, 8, ["label", "options", "placeholder"]),
|
|
32637
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(o.value, (
|
|
32633
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(o.value, (O) => (openBlock(), createElementBlock("input", {
|
|
32638
32634
|
type: "hidden",
|
|
32639
32635
|
name: "attractions[]",
|
|
32640
|
-
value:
|
|
32636
|
+
value: O
|
|
32641
32637
|
}, null, 8, _hoisted_19))), 256)),
|
|
32642
32638
|
createVNode(_sfc_main$D, {
|
|
32643
32639
|
id: "tour-month",
|
|
@@ -32653,7 +32649,7 @@ const _hoisted_1$t = {
|
|
|
32653
32649
|
class: "mt-150",
|
|
32654
32650
|
"data-test": "psw-submit",
|
|
32655
32651
|
type: "submit",
|
|
32656
|
-
onClick: L[3] || (L[3] = (
|
|
32652
|
+
onClick: L[3] || (L[3] = (O) => w.trackSubmit(a.value, typeof unref(r) > "u" ? "" : unref(r)))
|
|
32657
32653
|
}, {
|
|
32658
32654
|
default: withCtx(() => [
|
|
32659
32655
|
createTextVNode(toDisplayString(unref(getLabelText)("search", "Search")), 1)
|
|
@@ -36545,7 +36541,7 @@ const useFederatedSearchStore = defineStore("federatedSearch", () => {
|
|
|
36545
36541
|
async function B() {
|
|
36546
36542
|
return cludoAutocomplete(l.value, t.value);
|
|
36547
36543
|
}
|
|
36548
|
-
async function
|
|
36544
|
+
async function A($, V) {
|
|
36549
36545
|
const w = new URL(window.location.href);
|
|
36550
36546
|
if (V ? I.value = "Autosuggestion" : I.value = "User input", l.value ? w.searchParams.set("search-term", l.value) : w.searchParams.delete("search-term"), d.value ? w.searchParams.set("category", encodeURIComponent(d.value)) : w.searchParams.delete("category"), f.value.length > 0 ? w.searchParams.set("sub-category", encodeURIComponent(f.value.join(","))) : w.searchParams.delete("sub-category"), $ ? (a.value = 1, w.searchParams.set("page", a.value.toString())) : a.value && a.value > 1 ? w.searchParams.set("page", a.value.toString()) : w.searchParams.delete("page"), v.value ? w.searchParams.set("start-date", v.value) : w.searchParams.delete("start-date"), _.value ? w.searchParams.set("end-date", _.value) : w.searchParams.delete("end-date"), C.value ? w.searchParams.set("sort-by", C.value) : w.searchParams.delete("sort-by"), !b.value)
|
|
36551
36547
|
window.history.pushState({}, "", w), await S();
|
|
@@ -36574,7 +36570,7 @@ const useFederatedSearchStore = defineStore("federatedSearch", () => {
|
|
|
36574
36570
|
totalResults: p,
|
|
36575
36571
|
totalResultsCludo: m,
|
|
36576
36572
|
totalResultsEvents: g,
|
|
36577
|
-
navigateToResultsPage:
|
|
36573
|
+
navigateToResultsPage: A,
|
|
36578
36574
|
isHomePage: b,
|
|
36579
36575
|
startDate: v,
|
|
36580
36576
|
endDate: _,
|
|
@@ -38472,7 +38468,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38472
38468
|
east: 2
|
|
38473
38469
|
};
|
|
38474
38470
|
P.categoryLabelData = n.categoryLabels;
|
|
38475
|
-
let
|
|
38471
|
+
let A = 0;
|
|
38476
38472
|
const $ = {
|
|
38477
38473
|
headerLabel: n.labels.heading,
|
|
38478
38474
|
closeSidebarButtonLabel: n.labels.closeSidebarBtn,
|
|
@@ -38489,7 +38485,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38489
38485
|
getViewport: V,
|
|
38490
38486
|
hasViewportChanged: w,
|
|
38491
38487
|
isProgrammaticMove: L,
|
|
38492
|
-
isUserMove:
|
|
38488
|
+
isUserMove: O,
|
|
38493
38489
|
lastSearchViewport: z,
|
|
38494
38490
|
runProgrammaticMove: F,
|
|
38495
38491
|
showSearchAreaButton: q
|
|
@@ -38553,7 +38549,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38553
38549
|
console.error("Maps init error", H.message);
|
|
38554
38550
|
}
|
|
38555
38551
|
X(), l.addListener("zoom_changed", () => {
|
|
38556
|
-
N.value && (C.value = l.getZoom(), C.value < CATEGORY_VISIBLE_ZOOM ? X() : X(!0),
|
|
38552
|
+
N.value && (C.value = l.getZoom(), C.value < CATEGORY_VISIBLE_ZOOM ? X() : X(!0), O.value = !L.value, C.value > 7 && !L.value && O.value && (q.value = !0), O.value && Q(
|
|
38557
38553
|
{
|
|
38558
38554
|
category: R.selectedCategory ?? null,
|
|
38559
38555
|
subcategories: R.selectedSubcategories.join(",") ?? null,
|
|
@@ -38564,7 +38560,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38564
38560
|
!0
|
|
38565
38561
|
));
|
|
38566
38562
|
}), l.addListener("dragstart", () => {
|
|
38567
|
-
|
|
38563
|
+
O.value = !0;
|
|
38568
38564
|
}), l.addListener("tilesloaded", () => {
|
|
38569
38565
|
if (N.value) return;
|
|
38570
38566
|
N.value = !0;
|
|
@@ -38617,7 +38613,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38617
38613
|
!1
|
|
38618
38614
|
);
|
|
38619
38615
|
}), l.addListener("idle", () => {
|
|
38620
|
-
_ = Z(), !L.value && N.value &&
|
|
38616
|
+
_ = Z(), !L.value && N.value && O.value && w(V(l)) && (q.value = !0, P.selectedDestinationType = s[0].id, G.value = "", O.value = !1, Q(
|
|
38621
38617
|
{
|
|
38622
38618
|
"search-term": null,
|
|
38623
38619
|
location: null,
|
|
@@ -38716,8 +38712,8 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38716
38712
|
}
|
|
38717
38713
|
async function ne() {
|
|
38718
38714
|
const Y = R.selectedSubcategories.length > 0 ? R.selectedSubcategoryTypes : R.selectedCategoryTypes, H = R.selectedSubcategories.length > 0 ? R.selectedSubcategoryLabels : R.selectedCategoryLabel;
|
|
38719
|
-
de(), R.selfCateringClicked || fe(), E.value = `${H} ${G.value}` ?? "", E.value = E.value.trim(), b.value = E.value, P.showCategories = !0, a.value = !0,
|
|
38720
|
-
const J =
|
|
38715
|
+
de(), R.selfCateringClicked || fe(), E.value = `${H} ${G.value}` ?? "", E.value = E.value.trim(), b.value = E.value, P.showCategories = !0, a.value = !0, A += 1;
|
|
38716
|
+
const J = A;
|
|
38721
38717
|
P.filterUsesCount += 1, D.value = "nearby";
|
|
38722
38718
|
const ee = l.getBounds(), oe = ee.getNorthEast(), ae = ee.getSouthWest(), le = google.maps.geometry.spherical.computeDistanceBetween(oe, ae);
|
|
38723
38719
|
let ge = 25e3;
|
|
@@ -38727,7 +38723,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38727
38723
|
center: l.getCenter(),
|
|
38728
38724
|
radius: me
|
|
38729
38725
|
}, d.style.display = "block", d.addEventListener("gmp-load", () => {
|
|
38730
|
-
if (J !==
|
|
38726
|
+
if (J !== A) return;
|
|
38731
38727
|
ie(J);
|
|
38732
38728
|
let ke = "main", Se = R.selectedCategory;
|
|
38733
38729
|
R.selectedSubcategories.length > 0 && (ke = "sub", Se = [...R.selectedSubcategories].join(", ")), t.createDataLayerObject("googleMapFilterEvent", {
|
|
@@ -38754,8 +38750,8 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38754
38750
|
);
|
|
38755
38751
|
}
|
|
38756
38752
|
async function ce(Y = !1) {
|
|
38757
|
-
de(), R.selfCateringClicked || he(), G.value = "", a.value = !0,
|
|
38758
|
-
const H =
|
|
38753
|
+
de(), R.selfCateringClicked || he(), G.value = "", a.value = !0, A += 1;
|
|
38754
|
+
const H = A;
|
|
38759
38755
|
if (P.searchesCount += 1, D.value = "text", E.value = b.value.trim(), !E.value) return;
|
|
38760
38756
|
R.selfCateringClicked || Y ? (f.locationBias = null, f.locationRestriction = l.getBounds()) : (f.locationRestriction = null, f.locationBias = l.getCenter()), f.includedType = I.value.some(
|
|
38761
38757
|
(ge) => E.value.toLowerCase().includes(ge)
|
|
@@ -38772,7 +38768,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38772
38768
|
},
|
|
38773
38769
|
!1
|
|
38774
38770
|
), u.addEventListener("gmp-load", () => {
|
|
38775
|
-
H ===
|
|
38771
|
+
H === A && (ie(H), R.selfCateringClicked = !1, t.createDataLayerObject("googleMapSearchEvent", {
|
|
38776
38772
|
search_query: E.value,
|
|
38777
38773
|
search_map_location: l.getCenter().toString(),
|
|
38778
38774
|
search_results_count: u.places.length,
|
|
@@ -38784,7 +38780,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = {
|
|
|
38784
38780
|
}
|
|
38785
38781
|
async function ie(Y) {
|
|
38786
38782
|
const { AdvancedMarkerElement: H } = await importLibrary("marker"), { LatLngBounds: J } = await importLibrary("core");
|
|
38787
|
-
if (Y !==
|
|
38783
|
+
if (Y !== A) return;
|
|
38788
38784
|
const ee = ref();
|
|
38789
38785
|
D.value === "nearby" ? ee.value = d : D.value === "text" ? ee.value = u : console.error("Unrecognised Search type"), ee.value.places.length === 0 ? (T.value = !0, ee.value.style.display = "none") : (T.value = !1, ee.value.style.display = "block");
|
|
38790
38786
|
const oe = new J();
|