@colabcommerce/elements 0.0.4 → 0.9.1
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/.pnp.cjs +16484 -0
- package/.pnp.loader.mjs +2126 -0
- package/.yarn/install-state.gz +0 -0
- package/.yarn/releases/yarn-4.12.0.cjs +942 -0
- package/.yarnrc.yml +1 -0
- package/README.md +60 -41
- package/cypress/fixtures/example.json +5 -0
- package/cypress/support/commands.js +25 -0
- package/cypress/support/component-index.html +15 -0
- package/cypress/support/component.js +26 -0
- package/cypress.config.js +10 -0
- package/eslint.config.js +32 -0
- package/index.html +13 -0
- package/package.json +91 -67
- package/playground/index.html +14 -0
- package/playground/main.jsx +36 -0
- package/public/vite.svg +1 -0
- package/src/App.css +0 -0
- package/src/App.jsx +65 -0
- package/src/components/CollapsibleStoreHours/index.jsx +269 -0
- package/src/components/HoursList/index.jsx +225 -0
- package/src/components/LeadForm/index.jsx +241 -0
- package/src/components/MessageDialog/index.jsx +169 -0
- package/src/components/QuoteForm/index.jsx +82 -0
- package/src/components/QuoteFormSearch/index.jsx +276 -0
- package/src/components/QuoteFormStoreList/index.jsx +65 -0
- package/src/components/QuoteFormStoreListItem/index.jsx +134 -0
- package/src/components/QuoteLeadForm/index.jsx +16 -0
- package/src/components/QuoteMap/index.jsx +96 -0
- package/src/components/QuoteMapMarker/index.jsx +56 -0
- package/src/components/StaticMap/index.jsx +24 -0
- package/src/components/Store/index.jsx +44 -0
- package/src/components/StoreContact/index.jsx +96 -0
- package/src/components/StoreInfo/index.jsx +50 -0
- package/src/components/StoreList/index.jsx +59 -0
- package/src/components/StoreListItem/index.jsx +99 -0
- package/src/components/StoreListItem/indexStoreListItem.cy.jsx +30 -0
- package/src/components/StoreListNoneFound/index.jsx +16 -0
- package/src/components/StoreLocator/index.jsx +43 -0
- package/src/components/StoreLocatorMap/index.jsx +93 -0
- package/src/components/StoreLocatorMapMarker/index.jsx +55 -0
- package/src/components/StoreLocatorMessageDialog/index.jsx +20 -0
- package/src/components/StoreLocatorSearch/index.jsx +316 -0
- package/src/components/StoreMap/index.jsx +30 -0
- package/src/components/StoreMeta/index.jsx +7 -0
- package/src/components/StoreProducts/index.jsx +112 -0
- package/src/components/ui/Badge/index.jsx +46 -0
- package/src/components/ui/Button/index.jsx +56 -0
- package/src/components/ui/Button/indexButton.cy.jsx +9 -0
- package/src/components/ui/Card/index.jsx +90 -0
- package/src/components/ui/Input/index.jsx +19 -0
- package/src/components/ui/Input/indexInput.cy.jsx +9 -0
- package/src/components/ui/LoadingPuff/index.jsx +10 -0
- package/src/components/ui/Panel/index.jsx +23 -0
- package/src/components/ui/PhoneNumberInput/index.jsx +17 -0
- package/src/contexts/quote-form.jsx +94 -0
- package/src/contexts/store-locator.jsx +83 -0
- package/src/contexts/store.jsx +59 -0
- package/src/contexts/translations.jsx +11 -0
- package/src/dist.css +229 -0
- package/src/entries/QuoteForm.js +2 -0
- package/src/entries/Store.js +2 -0
- package/src/entries/StoreLocator.js +2 -0
- package/src/entries/StoreLocatorProvider.js +2 -0
- package/src/entries/styles.js +2 -0
- package/src/entries/useStoreLocator.js +2 -0
- package/src/i18n/defaultResources.js +19 -0
- package/src/i18n/index.js +44 -0
- package/src/i18n/mergeResources.js +22 -0
- package/src/index.css +214 -0
- package/src/lib/addressComponentsToAddress.js +43 -0
- package/src/lib/productSchema.js +6 -0
- package/src/lib/useGeolocation.js +266 -0
- package/src/lib/useHours.js +205 -0
- package/src/lib/usePlacesAutocomplete.js +288 -0
- package/src/lib/useProductAvailability.js +38 -0
- package/src/lib/useRudderAnalytics.js +50 -0
- package/src/lib/useSearchResults.js +102 -0
- package/src/lib/useStoreLocatorConfig.js +50 -0
- package/src/lib/utils/cn.js +6 -0
- package/src/lib/utils/measure.js +31 -0
- package/src/locales/en/default.json +58 -0
- package/src/locales/es/default.json +58 -0
- package/src/locales/fr/default.json +58 -0
- package/src/locales/it/default.json +58 -0
- package/src/main.jsx +10 -0
- package/vite.config.js +60 -53
- package/dist/CartForm.js +0 -617
- package/dist/Container-CU_WrBOi.js +0 -22
- package/dist/Modal-DTBKy_6d.js +0 -863
- package/dist/ProductForm.js +0 -343
- package/dist/Retailer.js +0 -3637
- package/dist/StoreLocator.js +0 -797
- package/dist/addressComponentsToAddress-DCL-K8mn.js +0 -1932
- package/dist/browser-ponyfill-DcK7_cJB.js +0 -339
- package/dist/globals-B8-hYoIU.js +0 -8518
- package/dist/index-CqSfhXDd.js +0 -137
- package/dist/index-FM02Uq_P.js +0 -100
- package/dist/style.css +0 -1
package/dist/Retailer.js
DELETED
|
@@ -1,3637 +0,0 @@
|
|
|
1
|
-
import { jsx as v, jsxs as N, Fragment as Ze } from "react/jsx-runtime";
|
|
2
|
-
import k, { createContext as Be, useState as X, useEffect as re, useContext as xt, forwardRef as Qe, useRef as U, useLayoutEffect as Tt } from "react";
|
|
3
|
-
import { u as Et, f as Ct, a as se, b as Pt, c as L, d as Ve, B as Ae, R as Z, C as q, e as Mt, g as It, h as pe, i as Lt, F as D, j as _t, A as Ot, k as Nt, M as zt, l as Re, I as At, m as $t } from "./globals-B8-hYoIU.js";
|
|
4
|
-
import { C as $e } from "./Container-CU_WrBOi.js";
|
|
5
|
-
import { M as me } from "./Modal-DTBKy_6d.js";
|
|
6
|
-
const Je = Be(), kt = ({ id: t, lng: e, children: i }) => {
|
|
7
|
-
const [s, n] = X(e), [r, l] = X(!1);
|
|
8
|
-
re(() => {
|
|
9
|
-
e && n(e);
|
|
10
|
-
}, [e]);
|
|
11
|
-
const { data: a, error: o, isLoading: c, mutate: d } = Et(() => {
|
|
12
|
-
if (t)
|
|
13
|
-
return [`https://api.colabcommerce.com/widget_api/company_retailer_locations/${t}`, { "X-Cc-Id": t }];
|
|
14
|
-
throw new Error("No id provided");
|
|
15
|
-
}, Ct);
|
|
16
|
-
re(() => {
|
|
17
|
-
if (a && !c) {
|
|
18
|
-
window.document.title = `Palliser Home Furniture ${a.company_retailer_location.address.city}`;
|
|
19
|
-
const h = document.querySelector('meta[name="description"]');
|
|
20
|
-
h && h.setAttribute("content", `Find all our high quality home furniture at our reseller ${a.company_retailer_location.retailer_name} in ${a.company_retailer_location.address.city}, sofas, chairs, and all our best home theatre seating furniture`);
|
|
21
|
-
}
|
|
22
|
-
}, [a, c]);
|
|
23
|
-
const p = {
|
|
24
|
-
retailer: (a == null ? void 0 : a.company_retailer_location) || {},
|
|
25
|
-
error: o,
|
|
26
|
-
isLoading: c,
|
|
27
|
-
mutate: d,
|
|
28
|
-
locale: s,
|
|
29
|
-
messageModalOpen: r,
|
|
30
|
-
setMessageModalOpen: l
|
|
31
|
-
};
|
|
32
|
-
return /* @__PURE__ */ v(Je.Provider, { value: p, children: i });
|
|
33
|
-
}, te = () => {
|
|
34
|
-
const t = xt(Je);
|
|
35
|
-
if (!t)
|
|
36
|
-
throw new Error("useRetailer must be used within a RetailerProvider");
|
|
37
|
-
return t;
|
|
38
|
-
}, Gt = k.createContext({}), et = !0;
|
|
39
|
-
function Dt({ baseColor: t, highlightColor: e, width: i, height: s, borderRadius: n, circle: r, direction: l, duration: a, enableAnimation: o = et, customHighlightBackground: c }) {
|
|
40
|
-
const d = {};
|
|
41
|
-
return l === "rtl" && (d["--animation-direction"] = "reverse"), typeof a == "number" && (d["--animation-duration"] = `${a}s`), o || (d["--pseudo-element-display"] = "none"), (typeof i == "string" || typeof i == "number") && (d.width = i), (typeof s == "string" || typeof s == "number") && (d.height = s), (typeof n == "string" || typeof n == "number") && (d.borderRadius = n), r && (d.borderRadius = "50%"), typeof t < "u" && (d["--base-color"] = t), typeof e < "u" && (d["--highlight-color"] = e), typeof c == "string" && (d["--custom-highlight-background"] = c), d;
|
|
42
|
-
}
|
|
43
|
-
function ce({ count: t = 1, wrapper: e, className: i, containerClassName: s, containerTestId: n, circle: r = !1, style: l, ...a }) {
|
|
44
|
-
var o, c, d;
|
|
45
|
-
const p = k.useContext(Gt), h = { ...a };
|
|
46
|
-
for (const [f, S] of Object.entries(a))
|
|
47
|
-
typeof S > "u" && delete h[f];
|
|
48
|
-
const w = {
|
|
49
|
-
...p,
|
|
50
|
-
...h,
|
|
51
|
-
circle: r
|
|
52
|
-
}, m = {
|
|
53
|
-
...l,
|
|
54
|
-
...Dt(w)
|
|
55
|
-
};
|
|
56
|
-
let b = "react-loading-skeleton";
|
|
57
|
-
i && (b += ` ${i}`);
|
|
58
|
-
const x = (o = w.inline) !== null && o !== void 0 ? o : !1, g = [], u = Math.ceil(t);
|
|
59
|
-
for (let f = 0; f < u; f++) {
|
|
60
|
-
let S = m;
|
|
61
|
-
if (u > t && f === u - 1) {
|
|
62
|
-
const P = (c = S.width) !== null && c !== void 0 ? c : "100%", I = t % 1, M = typeof P == "number" ? P * I : `calc(${P} * ${I})`;
|
|
63
|
-
S = { ...S, width: M };
|
|
64
|
-
}
|
|
65
|
-
const y = k.createElement("span", { className: b, style: S, key: f }, "");
|
|
66
|
-
x ? g.push(y) : g.push(k.createElement(
|
|
67
|
-
k.Fragment,
|
|
68
|
-
{ key: f },
|
|
69
|
-
y,
|
|
70
|
-
k.createElement("br", null)
|
|
71
|
-
));
|
|
72
|
-
}
|
|
73
|
-
return k.createElement("span", { className: s, "data-testid": n, "aria-live": "polite", "aria-busy": (d = w.enableAnimation) !== null && d !== void 0 ? d : et }, e ? g.map((f, S) => k.createElement(e, { key: S }, f)) : g);
|
|
74
|
-
}
|
|
75
|
-
const Bt = "hooFS", Vt = "dxXZo", Ft = "d-rRo", Ht = "TnhjQ", Rt = "cn0rU", jt = "-sN-9", Wt = "F3XjX", qt = "aQW1o", Xt = "QVB1F", Yt = "xH9dq", Ut = "QbyPq", H = {
|
|
76
|
-
wrapper: Bt,
|
|
77
|
-
title: Vt,
|
|
78
|
-
hours: Ft,
|
|
79
|
-
open: Ht,
|
|
80
|
-
closed: Rt,
|
|
81
|
-
soon: jt,
|
|
82
|
-
currentHours: Wt,
|
|
83
|
-
subHoursWrapper: qt,
|
|
84
|
-
subHours: Xt,
|
|
85
|
-
today: Yt,
|
|
86
|
-
shown: Ut
|
|
87
|
-
}, Kt = ({ i: t, hour: e }) => {
|
|
88
|
-
const { t: i, locale: s } = se("default"), n = /* @__PURE__ */ new Date();
|
|
89
|
-
n.setUTCHours(e.open_at_hour - e.utc_offset_minute / 60, e.open_at_minute, 0, 0);
|
|
90
|
-
const r = /* @__PURE__ */ new Date();
|
|
91
|
-
r.setUTCHours(e.close_at_hour - e.utc_offset_minute / 60, e.close_at_minute, 0, 0);
|
|
92
|
-
const l = n.getUTCMinutes() === 0 ? new Intl.DateTimeFormat(s, { hour: "numeric" }) : new Intl.DateTimeFormat(s, { hour: "numeric", minute: "2-digit" }), a = r.getUTCMinutes() === 0 ? new Intl.DateTimeFormat(s, { hour: "numeric" }) : new Intl.DateTimeFormat(s, { hour: "numeric", minute: "2-digit" }), c = (/* @__PURE__ */ new Date()).getDay(), d = e.day === c;
|
|
93
|
-
return /* @__PURE__ */ N("div", { className: [H.subHours, d ? H.today : ""].join(" "), children: [
|
|
94
|
-
/* @__PURE__ */ v("div", { children: i(`store.days.${e.day}`) }),
|
|
95
|
-
/* @__PURE__ */ N("div", { children: [
|
|
96
|
-
l.format(n),
|
|
97
|
-
" - ",
|
|
98
|
-
a.format(r)
|
|
99
|
-
] })
|
|
100
|
-
] }, e.day);
|
|
101
|
-
}, Zt = ({ hours: t, defaultOpen: e = !1 }) => {
|
|
102
|
-
const { t: i } = se(), { isOpen: s, openingSoon: n, closingSoon: r, openAt: l, closeAt: a, openFormatter: o, closeAtFormatter: c } = Pt(t), [d, p] = X(e), w = (/* @__PURE__ */ new Date()).getDay();
|
|
103
|
-
if (!(t == null ? void 0 : t.find((f) => f.day === w))) return null;
|
|
104
|
-
const b = s, x = t.sort((f, S) => f.day - S.day);
|
|
105
|
-
let g = null, u = null;
|
|
106
|
-
return b ? r ? (u = L(H.hours, H.soon), g = /* @__PURE__ */ v("span", { children: i("store.closingSoon") })) : (u = L(H.hours, H.open), g = /* @__PURE__ */ v("span", { children: i("store.openNow") })) : n ? (u = L(H.hours, H.soon), g = /* @__PURE__ */ v("span", { children: i("store.openingSoon") })) : (u = L(H.hours, H.closed), g = /* @__PURE__ */ v("span", { children: i("store.closedNow") })), /* @__PURE__ */ N("div", { className: d ? L(H.wrapper, H.shown) : L(H.wrapper), children: [
|
|
107
|
-
/* @__PURE__ */ N("div", { className: L(H.title), children: [
|
|
108
|
-
/* @__PURE__ */ N("span", { className: u, children: [
|
|
109
|
-
/* @__PURE__ */ v("i", { className: "lpe-icons", children: "clock" }),
|
|
110
|
-
g
|
|
111
|
-
] }),
|
|
112
|
-
/* @__PURE__ */ N("span", { className: L(H.currentHours), children: [
|
|
113
|
-
o.format(l),
|
|
114
|
-
" - ",
|
|
115
|
-
c.format(a)
|
|
116
|
-
] })
|
|
117
|
-
] }),
|
|
118
|
-
/* @__PURE__ */ v("div", { children: /* @__PURE__ */ v("div", { className: L(H.subHoursWrapper), children: x.map((f, S) => /* @__PURE__ */ v(Kt, { i: S, hour: f }, f.day)) }) })
|
|
119
|
-
] });
|
|
120
|
-
}, Qt = "h6I4-", Jt = "_4UN4N", ei = "QcO6J", ti = "B5SGn", ii = "CdDBV", si = "pY8Z2", ne = {
|
|
121
|
-
wrapper: Qt,
|
|
122
|
-
title: Jt,
|
|
123
|
-
hoursTitle: ei,
|
|
124
|
-
address: ti,
|
|
125
|
-
phoneLink: ii,
|
|
126
|
-
directionsLink: si
|
|
127
|
-
}, ni = () => {
|
|
128
|
-
const { retailer: t, isLoading: e } = te(), {
|
|
129
|
-
retailer_name: i,
|
|
130
|
-
address: s,
|
|
131
|
-
place_id: n,
|
|
132
|
-
retailer_location_hours: r
|
|
133
|
-
} = t, l = t == null ? void 0 : t.phone_number;
|
|
134
|
-
return /* @__PURE__ */ N("div", { className: L(ne.wrapper), children: [
|
|
135
|
-
/* @__PURE__ */ v("h1", { className: L(ne.title), children: i }),
|
|
136
|
-
/* @__PURE__ */ N("div", { className: L(ne.address), children: [
|
|
137
|
-
/* @__PURE__ */ v("div", { children: s == null ? void 0 : s.street_line_one }),
|
|
138
|
-
(s == null ? void 0 : s.street_line_two) && /* @__PURE__ */ v("div", { children: s.street_line_two }),
|
|
139
|
-
/* @__PURE__ */ N("div", { children: [
|
|
140
|
-
s == null ? void 0 : s.city,
|
|
141
|
-
", ",
|
|
142
|
-
s == null ? void 0 : s.province,
|
|
143
|
-
" ",
|
|
144
|
-
s == null ? void 0 : s.postal_code
|
|
145
|
-
] })
|
|
146
|
-
] }),
|
|
147
|
-
/* @__PURE__ */ N("div", { children: [
|
|
148
|
-
/* @__PURE__ */ v("a", { href: `https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(s == null ? void 0 : s.string)}`, target: "_blank", rel: "noopener noreferrer", className: L(ne.directionsLink), children: "Get Directions" }),
|
|
149
|
-
/* @__PURE__ */ v("a", { href: `tel:${l == null ? void 0 : l.phone_number}`, className: L(ne.phoneLink), children: l == null ? void 0 : l.formatted })
|
|
150
|
-
] }),
|
|
151
|
-
/* @__PURE__ */ v("div", { className: L(ne.hoursTitle), children: "Store Hours" }),
|
|
152
|
-
/* @__PURE__ */ v("div", { className: ne.hours, children: /* @__PURE__ */ v(Zt, { hours: r, defaultOpen: !0 }) })
|
|
153
|
-
] });
|
|
154
|
-
}, oe = (t, e = !1) => t ? e ? t.replace(/\s+/g, "-").toLowerCase().replace(/[^a-z0-9-]/g, "") : t.replace(/\s+/g, "+").replace(/[^a-zA-Z0-9+]/g, "") : "", ri = "YF6kz", ai = "ALvOL", je = {
|
|
155
|
-
breadcrumbs: ri,
|
|
156
|
-
breadcrumb: ai
|
|
157
|
-
}, li = () => {
|
|
158
|
-
var l, a, o, c, d, p;
|
|
159
|
-
const { retailer: t, locale: e, isLoading: i } = te(), { t: s } = se("default"), n = s(`retailer.breadcrumbs.country.${(l = t == null ? void 0 : t.address) == null ? void 0 : l.country}`), r = [
|
|
160
|
-
{
|
|
161
|
-
name: i ? /* @__PURE__ */ v(ce, { width: 50 }) : s("retailer.breadcrumbs.home"),
|
|
162
|
-
href: "/retailers"
|
|
163
|
-
},
|
|
164
|
-
{
|
|
165
|
-
name: i ? /* @__PURE__ */ v(ce, { width: 50 }) : n,
|
|
166
|
-
href: `/retailers/l/${oe(n)}`
|
|
167
|
-
},
|
|
168
|
-
{
|
|
169
|
-
name: i ? /* @__PURE__ */ v(ce, { width: 50 }) : (a = t == null ? void 0 : t.address) == null ? void 0 : a.province,
|
|
170
|
-
href: `/retailers/l/${oe(n)}/${oe((o = t == null ? void 0 : t.address) == null ? void 0 : o.province)}`
|
|
171
|
-
},
|
|
172
|
-
{
|
|
173
|
-
name: i ? /* @__PURE__ */ v(ce, { width: 50 }) : (c = t == null ? void 0 : t.address) == null ? void 0 : c.city,
|
|
174
|
-
href: `/retailers/l/${oe(n)}/${oe((d = t == null ? void 0 : t.address) == null ? void 0 : d.province)}/${oe((p = t == null ? void 0 : t.address) == null ? void 0 : p.city)}`
|
|
175
|
-
},
|
|
176
|
-
{
|
|
177
|
-
name: i ? /* @__PURE__ */ v(ce, { width: 50 }) : t == null ? void 0 : t.retailer_name,
|
|
178
|
-
href: `/retailer/${t == null ? void 0 : t.id}`
|
|
179
|
-
}
|
|
180
|
-
];
|
|
181
|
-
return /* @__PURE__ */ v("nav", { children: /* @__PURE__ */ v("ol", { className: L(je.breadcrumbs), children: r.map((h, w) => /* @__PURE__ */ N("li", { className: L(je.breadcrumb), children: [
|
|
182
|
-
/* @__PURE__ */ v("a", { href: h.href, children: h.name }),
|
|
183
|
-
w < r.length - 1 && " > "
|
|
184
|
-
] }, w)) }) });
|
|
185
|
-
};
|
|
186
|
-
function We(t) {
|
|
187
|
-
return t !== null && typeof t == "object" && "constructor" in t && t.constructor === Object;
|
|
188
|
-
}
|
|
189
|
-
function Fe(t, e) {
|
|
190
|
-
t === void 0 && (t = {}), e === void 0 && (e = {});
|
|
191
|
-
const i = ["__proto__", "constructor", "prototype"];
|
|
192
|
-
Object.keys(e).filter((s) => i.indexOf(s) < 0).forEach((s) => {
|
|
193
|
-
typeof t[s] > "u" ? t[s] = e[s] : We(e[s]) && We(t[s]) && Object.keys(e[s]).length > 0 && Fe(t[s], e[s]);
|
|
194
|
-
});
|
|
195
|
-
}
|
|
196
|
-
const tt = {
|
|
197
|
-
body: {},
|
|
198
|
-
addEventListener() {
|
|
199
|
-
},
|
|
200
|
-
removeEventListener() {
|
|
201
|
-
},
|
|
202
|
-
activeElement: {
|
|
203
|
-
blur() {
|
|
204
|
-
},
|
|
205
|
-
nodeName: ""
|
|
206
|
-
},
|
|
207
|
-
querySelector() {
|
|
208
|
-
return null;
|
|
209
|
-
},
|
|
210
|
-
querySelectorAll() {
|
|
211
|
-
return [];
|
|
212
|
-
},
|
|
213
|
-
getElementById() {
|
|
214
|
-
return null;
|
|
215
|
-
},
|
|
216
|
-
createEvent() {
|
|
217
|
-
return {
|
|
218
|
-
initEvent() {
|
|
219
|
-
}
|
|
220
|
-
};
|
|
221
|
-
},
|
|
222
|
-
createElement() {
|
|
223
|
-
return {
|
|
224
|
-
children: [],
|
|
225
|
-
childNodes: [],
|
|
226
|
-
style: {},
|
|
227
|
-
setAttribute() {
|
|
228
|
-
},
|
|
229
|
-
getElementsByTagName() {
|
|
230
|
-
return [];
|
|
231
|
-
}
|
|
232
|
-
};
|
|
233
|
-
},
|
|
234
|
-
createElementNS() {
|
|
235
|
-
return {};
|
|
236
|
-
},
|
|
237
|
-
importNode() {
|
|
238
|
-
return null;
|
|
239
|
-
},
|
|
240
|
-
location: {
|
|
241
|
-
hash: "",
|
|
242
|
-
host: "",
|
|
243
|
-
hostname: "",
|
|
244
|
-
href: "",
|
|
245
|
-
origin: "",
|
|
246
|
-
pathname: "",
|
|
247
|
-
protocol: "",
|
|
248
|
-
search: ""
|
|
249
|
-
}
|
|
250
|
-
};
|
|
251
|
-
function le() {
|
|
252
|
-
const t = typeof document < "u" ? document : {};
|
|
253
|
-
return Fe(t, tt), t;
|
|
254
|
-
}
|
|
255
|
-
const oi = {
|
|
256
|
-
document: tt,
|
|
257
|
-
navigator: {
|
|
258
|
-
userAgent: ""
|
|
259
|
-
},
|
|
260
|
-
location: {
|
|
261
|
-
hash: "",
|
|
262
|
-
host: "",
|
|
263
|
-
hostname: "",
|
|
264
|
-
href: "",
|
|
265
|
-
origin: "",
|
|
266
|
-
pathname: "",
|
|
267
|
-
protocol: "",
|
|
268
|
-
search: ""
|
|
269
|
-
},
|
|
270
|
-
history: {
|
|
271
|
-
replaceState() {
|
|
272
|
-
},
|
|
273
|
-
pushState() {
|
|
274
|
-
},
|
|
275
|
-
go() {
|
|
276
|
-
},
|
|
277
|
-
back() {
|
|
278
|
-
}
|
|
279
|
-
},
|
|
280
|
-
CustomEvent: function() {
|
|
281
|
-
return this;
|
|
282
|
-
},
|
|
283
|
-
addEventListener() {
|
|
284
|
-
},
|
|
285
|
-
removeEventListener() {
|
|
286
|
-
},
|
|
287
|
-
getComputedStyle() {
|
|
288
|
-
return {
|
|
289
|
-
getPropertyValue() {
|
|
290
|
-
return "";
|
|
291
|
-
}
|
|
292
|
-
};
|
|
293
|
-
},
|
|
294
|
-
Image() {
|
|
295
|
-
},
|
|
296
|
-
Date() {
|
|
297
|
-
},
|
|
298
|
-
screen: {},
|
|
299
|
-
setTimeout() {
|
|
300
|
-
},
|
|
301
|
-
clearTimeout() {
|
|
302
|
-
},
|
|
303
|
-
matchMedia() {
|
|
304
|
-
return {};
|
|
305
|
-
},
|
|
306
|
-
requestAnimationFrame(t) {
|
|
307
|
-
return typeof setTimeout > "u" ? (t(), null) : setTimeout(t, 0);
|
|
308
|
-
},
|
|
309
|
-
cancelAnimationFrame(t) {
|
|
310
|
-
typeof setTimeout > "u" || clearTimeout(t);
|
|
311
|
-
}
|
|
312
|
-
};
|
|
313
|
-
function j() {
|
|
314
|
-
const t = typeof window < "u" ? window : {};
|
|
315
|
-
return Fe(t, oi), t;
|
|
316
|
-
}
|
|
317
|
-
function di(t) {
|
|
318
|
-
return t === void 0 && (t = ""), t.trim().split(" ").filter((e) => !!e.trim());
|
|
319
|
-
}
|
|
320
|
-
function ci(t) {
|
|
321
|
-
const e = t;
|
|
322
|
-
Object.keys(e).forEach((i) => {
|
|
323
|
-
try {
|
|
324
|
-
e[i] = null;
|
|
325
|
-
} catch {
|
|
326
|
-
}
|
|
327
|
-
try {
|
|
328
|
-
delete e[i];
|
|
329
|
-
} catch {
|
|
330
|
-
}
|
|
331
|
-
});
|
|
332
|
-
}
|
|
333
|
-
function it(t, e) {
|
|
334
|
-
return e === void 0 && (e = 0), setTimeout(t, e);
|
|
335
|
-
}
|
|
336
|
-
function Se() {
|
|
337
|
-
return Date.now();
|
|
338
|
-
}
|
|
339
|
-
function ui(t) {
|
|
340
|
-
const e = j();
|
|
341
|
-
let i;
|
|
342
|
-
return e.getComputedStyle && (i = e.getComputedStyle(t, null)), !i && t.currentStyle && (i = t.currentStyle), i || (i = t.style), i;
|
|
343
|
-
}
|
|
344
|
-
function fi(t, e) {
|
|
345
|
-
e === void 0 && (e = "x");
|
|
346
|
-
const i = j();
|
|
347
|
-
let s, n, r;
|
|
348
|
-
const l = ui(t);
|
|
349
|
-
return i.WebKitCSSMatrix ? (n = l.transform || l.webkitTransform, n.split(",").length > 6 && (n = n.split(", ").map((a) => a.replace(",", ".")).join(", ")), r = new i.WebKitCSSMatrix(n === "none" ? "" : n)) : (r = l.MozTransform || l.OTransform || l.MsTransform || l.msTransform || l.transform || l.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,"), s = r.toString().split(",")), e === "x" && (i.WebKitCSSMatrix ? n = r.m41 : s.length === 16 ? n = parseFloat(s[12]) : n = parseFloat(s[4])), e === "y" && (i.WebKitCSSMatrix ? n = r.m42 : s.length === 16 ? n = parseFloat(s[13]) : n = parseFloat(s[5])), n || 0;
|
|
350
|
-
}
|
|
351
|
-
function he(t) {
|
|
352
|
-
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object";
|
|
353
|
-
}
|
|
354
|
-
function pi(t) {
|
|
355
|
-
return typeof window < "u" && typeof window.HTMLElement < "u" ? t instanceof HTMLElement : t && (t.nodeType === 1 || t.nodeType === 11);
|
|
356
|
-
}
|
|
357
|
-
function W() {
|
|
358
|
-
const t = Object(arguments.length <= 0 ? void 0 : arguments[0]), e = ["__proto__", "constructor", "prototype"];
|
|
359
|
-
for (let i = 1; i < arguments.length; i += 1) {
|
|
360
|
-
const s = i < 0 || arguments.length <= i ? void 0 : arguments[i];
|
|
361
|
-
if (s != null && !pi(s)) {
|
|
362
|
-
const n = Object.keys(Object(s)).filter((r) => e.indexOf(r) < 0);
|
|
363
|
-
for (let r = 0, l = n.length; r < l; r += 1) {
|
|
364
|
-
const a = n[r], o = Object.getOwnPropertyDescriptor(s, a);
|
|
365
|
-
o !== void 0 && o.enumerable && (he(t[a]) && he(s[a]) ? s[a].__swiper__ ? t[a] = s[a] : W(t[a], s[a]) : !he(t[a]) && he(s[a]) ? (t[a] = {}, s[a].__swiper__ ? t[a] = s[a] : W(t[a], s[a])) : t[a] = s[a]);
|
|
366
|
-
}
|
|
367
|
-
}
|
|
368
|
-
}
|
|
369
|
-
return t;
|
|
370
|
-
}
|
|
371
|
-
function ge(t, e, i) {
|
|
372
|
-
t.style.setProperty(e, i);
|
|
373
|
-
}
|
|
374
|
-
function st(t) {
|
|
375
|
-
let {
|
|
376
|
-
swiper: e,
|
|
377
|
-
targetPosition: i,
|
|
378
|
-
side: s
|
|
379
|
-
} = t;
|
|
380
|
-
const n = j(), r = -e.translate;
|
|
381
|
-
let l = null, a;
|
|
382
|
-
const o = e.params.speed;
|
|
383
|
-
e.wrapperEl.style.scrollSnapType = "none", n.cancelAnimationFrame(e.cssModeFrameID);
|
|
384
|
-
const c = i > r ? "next" : "prev", d = (h, w) => c === "next" && h >= w || c === "prev" && h <= w, p = () => {
|
|
385
|
-
a = (/* @__PURE__ */ new Date()).getTime(), l === null && (l = a);
|
|
386
|
-
const h = Math.max(Math.min((a - l) / o, 1), 0), w = 0.5 - Math.cos(h * Math.PI) / 2;
|
|
387
|
-
let m = r + w * (i - r);
|
|
388
|
-
if (d(m, i) && (m = i), e.wrapperEl.scrollTo({
|
|
389
|
-
[s]: m
|
|
390
|
-
}), d(m, i)) {
|
|
391
|
-
e.wrapperEl.style.overflow = "hidden", e.wrapperEl.style.scrollSnapType = "", setTimeout(() => {
|
|
392
|
-
e.wrapperEl.style.overflow = "", e.wrapperEl.scrollTo({
|
|
393
|
-
[s]: m
|
|
394
|
-
});
|
|
395
|
-
}), n.cancelAnimationFrame(e.cssModeFrameID);
|
|
396
|
-
return;
|
|
397
|
-
}
|
|
398
|
-
e.cssModeFrameID = n.requestAnimationFrame(p);
|
|
399
|
-
};
|
|
400
|
-
p();
|
|
401
|
-
}
|
|
402
|
-
function Q(t, e) {
|
|
403
|
-
e === void 0 && (e = "");
|
|
404
|
-
const i = j(), s = [...t.children];
|
|
405
|
-
return i.HTMLSlotElement && t instanceof HTMLSlotElement && s.push(...t.assignedElements()), e ? s.filter((n) => n.matches(e)) : s;
|
|
406
|
-
}
|
|
407
|
-
function mi(t, e) {
|
|
408
|
-
const i = [e];
|
|
409
|
-
for (; i.length > 0; ) {
|
|
410
|
-
const s = i.shift();
|
|
411
|
-
if (t === s)
|
|
412
|
-
return !0;
|
|
413
|
-
i.push(...s.children, ...s.shadowRoot ? s.shadowRoot.children : [], ...s.assignedElements ? s.assignedElements() : []);
|
|
414
|
-
}
|
|
415
|
-
}
|
|
416
|
-
function hi(t, e) {
|
|
417
|
-
const i = j();
|
|
418
|
-
let s = e.contains(t);
|
|
419
|
-
return !s && i.HTMLSlotElement && e instanceof HTMLSlotElement && (s = [...e.assignedElements()].includes(t), s || (s = mi(t, e))), s;
|
|
420
|
-
}
|
|
421
|
-
function be(t) {
|
|
422
|
-
try {
|
|
423
|
-
console.warn(t);
|
|
424
|
-
return;
|
|
425
|
-
} catch {
|
|
426
|
-
}
|
|
427
|
-
}
|
|
428
|
-
function ye(t, e) {
|
|
429
|
-
e === void 0 && (e = []);
|
|
430
|
-
const i = document.createElement(t);
|
|
431
|
-
return i.classList.add(...Array.isArray(e) ? e : di(e)), i;
|
|
432
|
-
}
|
|
433
|
-
function gi(t, e) {
|
|
434
|
-
const i = [];
|
|
435
|
-
for (; t.previousElementSibling; ) {
|
|
436
|
-
const s = t.previousElementSibling;
|
|
437
|
-
e ? s.matches(e) && i.push(s) : i.push(s), t = s;
|
|
438
|
-
}
|
|
439
|
-
return i;
|
|
440
|
-
}
|
|
441
|
-
function vi(t, e) {
|
|
442
|
-
const i = [];
|
|
443
|
-
for (; t.nextElementSibling; ) {
|
|
444
|
-
const s = t.nextElementSibling;
|
|
445
|
-
e ? s.matches(e) && i.push(s) : i.push(s), t = s;
|
|
446
|
-
}
|
|
447
|
-
return i;
|
|
448
|
-
}
|
|
449
|
-
function ie(t, e) {
|
|
450
|
-
return j().getComputedStyle(t, null).getPropertyValue(e);
|
|
451
|
-
}
|
|
452
|
-
function xe(t) {
|
|
453
|
-
let e = t, i;
|
|
454
|
-
if (e) {
|
|
455
|
-
for (i = 0; (e = e.previousSibling) !== null; )
|
|
456
|
-
e.nodeType === 1 && (i += 1);
|
|
457
|
-
return i;
|
|
458
|
-
}
|
|
459
|
-
}
|
|
460
|
-
function nt(t, e) {
|
|
461
|
-
const i = [];
|
|
462
|
-
let s = t.parentElement;
|
|
463
|
-
for (; s; )
|
|
464
|
-
e ? s.matches(e) && i.push(s) : i.push(s), s = s.parentElement;
|
|
465
|
-
return i;
|
|
466
|
-
}
|
|
467
|
-
function ke(t, e, i) {
|
|
468
|
-
const s = j();
|
|
469
|
-
return t[e === "width" ? "offsetWidth" : "offsetHeight"] + parseFloat(s.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-right" : "margin-top")) + parseFloat(s.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-left" : "margin-bottom"));
|
|
470
|
-
}
|
|
471
|
-
function V(t) {
|
|
472
|
-
return (Array.isArray(t) ? t : [t]).filter((e) => !!e);
|
|
473
|
-
}
|
|
474
|
-
function Te(t, e) {
|
|
475
|
-
e === void 0 && (e = ""), typeof trustedTypes < "u" ? t.innerHTML = trustedTypes.createPolicy("html", {
|
|
476
|
-
createHTML: (i) => i
|
|
477
|
-
}).createHTML(e) : t.innerHTML = e;
|
|
478
|
-
}
|
|
479
|
-
let Ce;
|
|
480
|
-
function wi() {
|
|
481
|
-
const t = j(), e = le();
|
|
482
|
-
return {
|
|
483
|
-
smoothScroll: e.documentElement && e.documentElement.style && "scrollBehavior" in e.documentElement.style,
|
|
484
|
-
touch: !!("ontouchstart" in t || t.DocumentTouch && e instanceof t.DocumentTouch)
|
|
485
|
-
};
|
|
486
|
-
}
|
|
487
|
-
function rt() {
|
|
488
|
-
return Ce || (Ce = wi()), Ce;
|
|
489
|
-
}
|
|
490
|
-
let Pe;
|
|
491
|
-
function Si(t) {
|
|
492
|
-
let {
|
|
493
|
-
userAgent: e
|
|
494
|
-
} = t === void 0 ? {} : t;
|
|
495
|
-
const i = rt(), s = j(), n = s.navigator.platform, r = e || s.navigator.userAgent, l = {
|
|
496
|
-
ios: !1,
|
|
497
|
-
android: !1
|
|
498
|
-
}, a = s.screen.width, o = s.screen.height, c = r.match(/(Android);?[\s\/]+([\d.]+)?/);
|
|
499
|
-
let d = r.match(/(iPad).*OS\s([\d_]+)/);
|
|
500
|
-
const p = r.match(/(iPod)(.*OS\s([\d_]+))?/), h = !d && r.match(/(iPhone\sOS|iOS)\s([\d_]+)/), w = n === "Win32";
|
|
501
|
-
let m = n === "MacIntel";
|
|
502
|
-
const b = ["1024x1366", "1366x1024", "834x1194", "1194x834", "834x1112", "1112x834", "768x1024", "1024x768", "820x1180", "1180x820", "810x1080", "1080x810"];
|
|
503
|
-
return !d && m && i.touch && b.indexOf(`${a}x${o}`) >= 0 && (d = r.match(/(Version)\/([\d.]+)/), d || (d = [0, 1, "13_0_0"]), m = !1), c && !w && (l.os = "android", l.android = !0), (d || h || p) && (l.os = "ios", l.ios = !0), l;
|
|
504
|
-
}
|
|
505
|
-
function at(t) {
|
|
506
|
-
return t === void 0 && (t = {}), Pe || (Pe = Si(t)), Pe;
|
|
507
|
-
}
|
|
508
|
-
let Me;
|
|
509
|
-
function bi() {
|
|
510
|
-
const t = j(), e = at();
|
|
511
|
-
let i = !1;
|
|
512
|
-
function s() {
|
|
513
|
-
const a = t.navigator.userAgent.toLowerCase();
|
|
514
|
-
return a.indexOf("safari") >= 0 && a.indexOf("chrome") < 0 && a.indexOf("android") < 0;
|
|
515
|
-
}
|
|
516
|
-
if (s()) {
|
|
517
|
-
const a = String(t.navigator.userAgent);
|
|
518
|
-
if (a.includes("Version/")) {
|
|
519
|
-
const [o, c] = a.split("Version/")[1].split(" ")[0].split(".").map((d) => Number(d));
|
|
520
|
-
i = o < 16 || o === 16 && c < 2;
|
|
521
|
-
}
|
|
522
|
-
}
|
|
523
|
-
const n = /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(t.navigator.userAgent), r = s(), l = r || n && e.ios;
|
|
524
|
-
return {
|
|
525
|
-
isSafari: i || r,
|
|
526
|
-
needPerspectiveFix: i,
|
|
527
|
-
need3dFix: l,
|
|
528
|
-
isWebView: n
|
|
529
|
-
};
|
|
530
|
-
}
|
|
531
|
-
function lt() {
|
|
532
|
-
return Me || (Me = bi()), Me;
|
|
533
|
-
}
|
|
534
|
-
function yi(t) {
|
|
535
|
-
let {
|
|
536
|
-
swiper: e,
|
|
537
|
-
on: i,
|
|
538
|
-
emit: s
|
|
539
|
-
} = t;
|
|
540
|
-
const n = j();
|
|
541
|
-
let r = null, l = null;
|
|
542
|
-
const a = () => {
|
|
543
|
-
!e || e.destroyed || !e.initialized || (s("beforeResize"), s("resize"));
|
|
544
|
-
}, o = () => {
|
|
545
|
-
!e || e.destroyed || !e.initialized || (r = new ResizeObserver((p) => {
|
|
546
|
-
l = n.requestAnimationFrame(() => {
|
|
547
|
-
const {
|
|
548
|
-
width: h,
|
|
549
|
-
height: w
|
|
550
|
-
} = e;
|
|
551
|
-
let m = h, b = w;
|
|
552
|
-
p.forEach((x) => {
|
|
553
|
-
let {
|
|
554
|
-
contentBoxSize: g,
|
|
555
|
-
contentRect: u,
|
|
556
|
-
target: f
|
|
557
|
-
} = x;
|
|
558
|
-
f && f !== e.el || (m = u ? u.width : (g[0] || g).inlineSize, b = u ? u.height : (g[0] || g).blockSize);
|
|
559
|
-
}), (m !== h || b !== w) && a();
|
|
560
|
-
});
|
|
561
|
-
}), r.observe(e.el));
|
|
562
|
-
}, c = () => {
|
|
563
|
-
l && n.cancelAnimationFrame(l), r && r.unobserve && e.el && (r.unobserve(e.el), r = null);
|
|
564
|
-
}, d = () => {
|
|
565
|
-
!e || e.destroyed || !e.initialized || s("orientationchange");
|
|
566
|
-
};
|
|
567
|
-
i("init", () => {
|
|
568
|
-
if (e.params.resizeObserver && typeof n.ResizeObserver < "u") {
|
|
569
|
-
o();
|
|
570
|
-
return;
|
|
571
|
-
}
|
|
572
|
-
n.addEventListener("resize", a), n.addEventListener("orientationchange", d);
|
|
573
|
-
}), i("destroy", () => {
|
|
574
|
-
c(), n.removeEventListener("resize", a), n.removeEventListener("orientationchange", d);
|
|
575
|
-
});
|
|
576
|
-
}
|
|
577
|
-
function xi(t) {
|
|
578
|
-
let {
|
|
579
|
-
swiper: e,
|
|
580
|
-
extendParams: i,
|
|
581
|
-
on: s,
|
|
582
|
-
emit: n
|
|
583
|
-
} = t;
|
|
584
|
-
const r = [], l = j(), a = function(d, p) {
|
|
585
|
-
p === void 0 && (p = {});
|
|
586
|
-
const h = l.MutationObserver || l.WebkitMutationObserver, w = new h((m) => {
|
|
587
|
-
if (e.__preventObserver__) return;
|
|
588
|
-
if (m.length === 1) {
|
|
589
|
-
n("observerUpdate", m[0]);
|
|
590
|
-
return;
|
|
591
|
-
}
|
|
592
|
-
const b = function() {
|
|
593
|
-
n("observerUpdate", m[0]);
|
|
594
|
-
};
|
|
595
|
-
l.requestAnimationFrame ? l.requestAnimationFrame(b) : l.setTimeout(b, 0);
|
|
596
|
-
});
|
|
597
|
-
w.observe(d, {
|
|
598
|
-
attributes: typeof p.attributes > "u" ? !0 : p.attributes,
|
|
599
|
-
childList: e.isElement || (typeof p.childList > "u" ? !0 : p).childList,
|
|
600
|
-
characterData: typeof p.characterData > "u" ? !0 : p.characterData
|
|
601
|
-
}), r.push(w);
|
|
602
|
-
}, o = () => {
|
|
603
|
-
if (e.params.observer) {
|
|
604
|
-
if (e.params.observeParents) {
|
|
605
|
-
const d = nt(e.hostEl);
|
|
606
|
-
for (let p = 0; p < d.length; p += 1)
|
|
607
|
-
a(d[p]);
|
|
608
|
-
}
|
|
609
|
-
a(e.hostEl, {
|
|
610
|
-
childList: e.params.observeSlideChildren
|
|
611
|
-
}), a(e.wrapperEl, {
|
|
612
|
-
attributes: !1
|
|
613
|
-
});
|
|
614
|
-
}
|
|
615
|
-
}, c = () => {
|
|
616
|
-
r.forEach((d) => {
|
|
617
|
-
d.disconnect();
|
|
618
|
-
}), r.splice(0, r.length);
|
|
619
|
-
};
|
|
620
|
-
i({
|
|
621
|
-
observer: !1,
|
|
622
|
-
observeParents: !1,
|
|
623
|
-
observeSlideChildren: !1
|
|
624
|
-
}), s("init", o), s("destroy", c);
|
|
625
|
-
}
|
|
626
|
-
var Ti = {
|
|
627
|
-
on(t, e, i) {
|
|
628
|
-
const s = this;
|
|
629
|
-
if (!s.eventsListeners || s.destroyed || typeof e != "function") return s;
|
|
630
|
-
const n = i ? "unshift" : "push";
|
|
631
|
-
return t.split(" ").forEach((r) => {
|
|
632
|
-
s.eventsListeners[r] || (s.eventsListeners[r] = []), s.eventsListeners[r][n](e);
|
|
633
|
-
}), s;
|
|
634
|
-
},
|
|
635
|
-
once(t, e, i) {
|
|
636
|
-
const s = this;
|
|
637
|
-
if (!s.eventsListeners || s.destroyed || typeof e != "function") return s;
|
|
638
|
-
function n() {
|
|
639
|
-
s.off(t, n), n.__emitterProxy && delete n.__emitterProxy;
|
|
640
|
-
for (var r = arguments.length, l = new Array(r), a = 0; a < r; a++)
|
|
641
|
-
l[a] = arguments[a];
|
|
642
|
-
e.apply(s, l);
|
|
643
|
-
}
|
|
644
|
-
return n.__emitterProxy = e, s.on(t, n, i);
|
|
645
|
-
},
|
|
646
|
-
onAny(t, e) {
|
|
647
|
-
const i = this;
|
|
648
|
-
if (!i.eventsListeners || i.destroyed || typeof t != "function") return i;
|
|
649
|
-
const s = e ? "unshift" : "push";
|
|
650
|
-
return i.eventsAnyListeners.indexOf(t) < 0 && i.eventsAnyListeners[s](t), i;
|
|
651
|
-
},
|
|
652
|
-
offAny(t) {
|
|
653
|
-
const e = this;
|
|
654
|
-
if (!e.eventsListeners || e.destroyed || !e.eventsAnyListeners) return e;
|
|
655
|
-
const i = e.eventsAnyListeners.indexOf(t);
|
|
656
|
-
return i >= 0 && e.eventsAnyListeners.splice(i, 1), e;
|
|
657
|
-
},
|
|
658
|
-
off(t, e) {
|
|
659
|
-
const i = this;
|
|
660
|
-
return !i.eventsListeners || i.destroyed || !i.eventsListeners || t.split(" ").forEach((s) => {
|
|
661
|
-
typeof e > "u" ? i.eventsListeners[s] = [] : i.eventsListeners[s] && i.eventsListeners[s].forEach((n, r) => {
|
|
662
|
-
(n === e || n.__emitterProxy && n.__emitterProxy === e) && i.eventsListeners[s].splice(r, 1);
|
|
663
|
-
});
|
|
664
|
-
}), i;
|
|
665
|
-
},
|
|
666
|
-
emit() {
|
|
667
|
-
const t = this;
|
|
668
|
-
if (!t.eventsListeners || t.destroyed || !t.eventsListeners) return t;
|
|
669
|
-
let e, i, s;
|
|
670
|
-
for (var n = arguments.length, r = new Array(n), l = 0; l < n; l++)
|
|
671
|
-
r[l] = arguments[l];
|
|
672
|
-
return typeof r[0] == "string" || Array.isArray(r[0]) ? (e = r[0], i = r.slice(1, r.length), s = t) : (e = r[0].events, i = r[0].data, s = r[0].context || t), i.unshift(s), (Array.isArray(e) ? e : e.split(" ")).forEach((o) => {
|
|
673
|
-
t.eventsAnyListeners && t.eventsAnyListeners.length && t.eventsAnyListeners.forEach((c) => {
|
|
674
|
-
c.apply(s, [o, ...i]);
|
|
675
|
-
}), t.eventsListeners && t.eventsListeners[o] && t.eventsListeners[o].forEach((c) => {
|
|
676
|
-
c.apply(s, i);
|
|
677
|
-
});
|
|
678
|
-
}), t;
|
|
679
|
-
}
|
|
680
|
-
};
|
|
681
|
-
function Ei() {
|
|
682
|
-
const t = this;
|
|
683
|
-
let e, i;
|
|
684
|
-
const s = t.el;
|
|
685
|
-
typeof t.params.width < "u" && t.params.width !== null ? e = t.params.width : e = s.clientWidth, typeof t.params.height < "u" && t.params.height !== null ? i = t.params.height : i = s.clientHeight, !(e === 0 && t.isHorizontal() || i === 0 && t.isVertical()) && (e = e - parseInt(ie(s, "padding-left") || 0, 10) - parseInt(ie(s, "padding-right") || 0, 10), i = i - parseInt(ie(s, "padding-top") || 0, 10) - parseInt(ie(s, "padding-bottom") || 0, 10), Number.isNaN(e) && (e = 0), Number.isNaN(i) && (i = 0), Object.assign(t, {
|
|
686
|
-
width: e,
|
|
687
|
-
height: i,
|
|
688
|
-
size: t.isHorizontal() ? e : i
|
|
689
|
-
}));
|
|
690
|
-
}
|
|
691
|
-
function Ci() {
|
|
692
|
-
const t = this;
|
|
693
|
-
function e(E, C) {
|
|
694
|
-
return parseFloat(E.getPropertyValue(t.getDirectionLabel(C)) || 0);
|
|
695
|
-
}
|
|
696
|
-
const i = t.params, {
|
|
697
|
-
wrapperEl: s,
|
|
698
|
-
slidesEl: n,
|
|
699
|
-
size: r,
|
|
700
|
-
rtlTranslate: l,
|
|
701
|
-
wrongRTL: a
|
|
702
|
-
} = t, o = t.virtual && i.virtual.enabled, c = o ? t.virtual.slides.length : t.slides.length, d = Q(n, `.${t.params.slideClass}, swiper-slide`), p = o ? t.virtual.slides.length : d.length;
|
|
703
|
-
let h = [];
|
|
704
|
-
const w = [], m = [];
|
|
705
|
-
let b = i.slidesOffsetBefore;
|
|
706
|
-
typeof b == "function" && (b = i.slidesOffsetBefore.call(t));
|
|
707
|
-
let x = i.slidesOffsetAfter;
|
|
708
|
-
typeof x == "function" && (x = i.slidesOffsetAfter.call(t));
|
|
709
|
-
const g = t.snapGrid.length, u = t.slidesGrid.length;
|
|
710
|
-
let f = i.spaceBetween, S = -b, y = 0, P = 0;
|
|
711
|
-
if (typeof r > "u")
|
|
712
|
-
return;
|
|
713
|
-
typeof f == "string" && f.indexOf("%") >= 0 ? f = parseFloat(f.replace("%", "")) / 100 * r : typeof f == "string" && (f = parseFloat(f)), t.virtualSize = -f, d.forEach((E) => {
|
|
714
|
-
l ? E.style.marginLeft = "" : E.style.marginRight = "", E.style.marginBottom = "", E.style.marginTop = "";
|
|
715
|
-
}), i.centeredSlides && i.cssMode && (ge(s, "--swiper-centered-offset-before", ""), ge(s, "--swiper-centered-offset-after", ""));
|
|
716
|
-
const I = i.grid && i.grid.rows > 1 && t.grid;
|
|
717
|
-
I ? t.grid.initSlides(d) : t.grid && t.grid.unsetSlides();
|
|
718
|
-
let M;
|
|
719
|
-
const T = i.slidesPerView === "auto" && i.breakpoints && Object.keys(i.breakpoints).filter((E) => typeof i.breakpoints[E].slidesPerView < "u").length > 0;
|
|
720
|
-
for (let E = 0; E < p; E += 1) {
|
|
721
|
-
M = 0;
|
|
722
|
-
let C;
|
|
723
|
-
if (d[E] && (C = d[E]), I && t.grid.updateSlide(E, C, d), !(d[E] && ie(C, "display") === "none")) {
|
|
724
|
-
if (i.slidesPerView === "auto") {
|
|
725
|
-
T && (d[E].style[t.getDirectionLabel("width")] = "");
|
|
726
|
-
const _ = getComputedStyle(C), z = C.style.transform, A = C.style.webkitTransform;
|
|
727
|
-
if (z && (C.style.transform = "none"), A && (C.style.webkitTransform = "none"), i.roundLengths)
|
|
728
|
-
M = t.isHorizontal() ? ke(C, "width") : ke(C, "height");
|
|
729
|
-
else {
|
|
730
|
-
const $ = e(_, "width"), O = e(_, "padding-left"), B = e(_, "padding-right"), F = e(_, "margin-left"), G = e(_, "margin-right"), Y = _.getPropertyValue("box-sizing");
|
|
731
|
-
if (Y && Y === "border-box")
|
|
732
|
-
M = $ + F + G;
|
|
733
|
-
else {
|
|
734
|
-
const {
|
|
735
|
-
clientWidth: bt,
|
|
736
|
-
offsetWidth: yt
|
|
737
|
-
} = C;
|
|
738
|
-
M = $ + O + B + F + G + (yt - bt);
|
|
739
|
-
}
|
|
740
|
-
}
|
|
741
|
-
z && (C.style.transform = z), A && (C.style.webkitTransform = A), i.roundLengths && (M = Math.floor(M));
|
|
742
|
-
} else
|
|
743
|
-
M = (r - (i.slidesPerView - 1) * f) / i.slidesPerView, i.roundLengths && (M = Math.floor(M)), d[E] && (d[E].style[t.getDirectionLabel("width")] = `${M}px`);
|
|
744
|
-
d[E] && (d[E].swiperSlideSize = M), m.push(M), i.centeredSlides ? (S = S + M / 2 + y / 2 + f, y === 0 && E !== 0 && (S = S - r / 2 - f), E === 0 && (S = S - r / 2 - f), Math.abs(S) < 1 / 1e3 && (S = 0), i.roundLengths && (S = Math.floor(S)), P % i.slidesPerGroup === 0 && h.push(S), w.push(S)) : (i.roundLengths && (S = Math.floor(S)), (P - Math.min(t.params.slidesPerGroupSkip, P)) % t.params.slidesPerGroup === 0 && h.push(S), w.push(S), S = S + M + f), t.virtualSize += M + f, y = M, P += 1;
|
|
745
|
-
}
|
|
746
|
-
}
|
|
747
|
-
if (t.virtualSize = Math.max(t.virtualSize, r) + x, l && a && (i.effect === "slide" || i.effect === "coverflow") && (s.style.width = `${t.virtualSize + f}px`), i.setWrapperSize && (s.style[t.getDirectionLabel("width")] = `${t.virtualSize + f}px`), I && t.grid.updateWrapperSize(M, h), !i.centeredSlides) {
|
|
748
|
-
const E = [];
|
|
749
|
-
for (let C = 0; C < h.length; C += 1) {
|
|
750
|
-
let _ = h[C];
|
|
751
|
-
i.roundLengths && (_ = Math.floor(_)), h[C] <= t.virtualSize - r && E.push(_);
|
|
752
|
-
}
|
|
753
|
-
h = E, Math.floor(t.virtualSize - r) - Math.floor(h[h.length - 1]) > 1 && h.push(t.virtualSize - r);
|
|
754
|
-
}
|
|
755
|
-
if (o && i.loop) {
|
|
756
|
-
const E = m[0] + f;
|
|
757
|
-
if (i.slidesPerGroup > 1) {
|
|
758
|
-
const C = Math.ceil((t.virtual.slidesBefore + t.virtual.slidesAfter) / i.slidesPerGroup), _ = E * i.slidesPerGroup;
|
|
759
|
-
for (let z = 0; z < C; z += 1)
|
|
760
|
-
h.push(h[h.length - 1] + _);
|
|
761
|
-
}
|
|
762
|
-
for (let C = 0; C < t.virtual.slidesBefore + t.virtual.slidesAfter; C += 1)
|
|
763
|
-
i.slidesPerGroup === 1 && h.push(h[h.length - 1] + E), w.push(w[w.length - 1] + E), t.virtualSize += E;
|
|
764
|
-
}
|
|
765
|
-
if (h.length === 0 && (h = [0]), f !== 0) {
|
|
766
|
-
const E = t.isHorizontal() && l ? "marginLeft" : t.getDirectionLabel("marginRight");
|
|
767
|
-
d.filter((C, _) => !i.cssMode || i.loop ? !0 : _ !== d.length - 1).forEach((C) => {
|
|
768
|
-
C.style[E] = `${f}px`;
|
|
769
|
-
});
|
|
770
|
-
}
|
|
771
|
-
if (i.centeredSlides && i.centeredSlidesBounds) {
|
|
772
|
-
let E = 0;
|
|
773
|
-
m.forEach((_) => {
|
|
774
|
-
E += _ + (f || 0);
|
|
775
|
-
}), E -= f;
|
|
776
|
-
const C = E > r ? E - r : 0;
|
|
777
|
-
h = h.map((_) => _ <= 0 ? -b : _ > C ? C + x : _);
|
|
778
|
-
}
|
|
779
|
-
if (i.centerInsufficientSlides) {
|
|
780
|
-
let E = 0;
|
|
781
|
-
m.forEach((_) => {
|
|
782
|
-
E += _ + (f || 0);
|
|
783
|
-
}), E -= f;
|
|
784
|
-
const C = (i.slidesOffsetBefore || 0) + (i.slidesOffsetAfter || 0);
|
|
785
|
-
if (E + C < r) {
|
|
786
|
-
const _ = (r - E - C) / 2;
|
|
787
|
-
h.forEach((z, A) => {
|
|
788
|
-
h[A] = z - _;
|
|
789
|
-
}), w.forEach((z, A) => {
|
|
790
|
-
w[A] = z + _;
|
|
791
|
-
});
|
|
792
|
-
}
|
|
793
|
-
}
|
|
794
|
-
if (Object.assign(t, {
|
|
795
|
-
slides: d,
|
|
796
|
-
snapGrid: h,
|
|
797
|
-
slidesGrid: w,
|
|
798
|
-
slidesSizesGrid: m
|
|
799
|
-
}), i.centeredSlides && i.cssMode && !i.centeredSlidesBounds) {
|
|
800
|
-
ge(s, "--swiper-centered-offset-before", `${-h[0]}px`), ge(s, "--swiper-centered-offset-after", `${t.size / 2 - m[m.length - 1] / 2}px`);
|
|
801
|
-
const E = -t.snapGrid[0], C = -t.slidesGrid[0];
|
|
802
|
-
t.snapGrid = t.snapGrid.map((_) => _ + E), t.slidesGrid = t.slidesGrid.map((_) => _ + C);
|
|
803
|
-
}
|
|
804
|
-
if (p !== c && t.emit("slidesLengthChange"), h.length !== g && (t.params.watchOverflow && t.checkOverflow(), t.emit("snapGridLengthChange")), w.length !== u && t.emit("slidesGridLengthChange"), i.watchSlidesProgress && t.updateSlidesOffset(), t.emit("slidesUpdated"), !o && !i.cssMode && (i.effect === "slide" || i.effect === "fade")) {
|
|
805
|
-
const E = `${i.containerModifierClass}backface-hidden`, C = t.el.classList.contains(E);
|
|
806
|
-
p <= i.maxBackfaceHiddenSlides ? C || t.el.classList.add(E) : C && t.el.classList.remove(E);
|
|
807
|
-
}
|
|
808
|
-
}
|
|
809
|
-
function Pi(t) {
|
|
810
|
-
const e = this, i = [], s = e.virtual && e.params.virtual.enabled;
|
|
811
|
-
let n = 0, r;
|
|
812
|
-
typeof t == "number" ? e.setTransition(t) : t === !0 && e.setTransition(e.params.speed);
|
|
813
|
-
const l = (a) => s ? e.slides[e.getSlideIndexByData(a)] : e.slides[a];
|
|
814
|
-
if (e.params.slidesPerView !== "auto" && e.params.slidesPerView > 1)
|
|
815
|
-
if (e.params.centeredSlides)
|
|
816
|
-
(e.visibleSlides || []).forEach((a) => {
|
|
817
|
-
i.push(a);
|
|
818
|
-
});
|
|
819
|
-
else
|
|
820
|
-
for (r = 0; r < Math.ceil(e.params.slidesPerView); r += 1) {
|
|
821
|
-
const a = e.activeIndex + r;
|
|
822
|
-
if (a > e.slides.length && !s) break;
|
|
823
|
-
i.push(l(a));
|
|
824
|
-
}
|
|
825
|
-
else
|
|
826
|
-
i.push(l(e.activeIndex));
|
|
827
|
-
for (r = 0; r < i.length; r += 1)
|
|
828
|
-
if (typeof i[r] < "u") {
|
|
829
|
-
const a = i[r].offsetHeight;
|
|
830
|
-
n = a > n ? a : n;
|
|
831
|
-
}
|
|
832
|
-
(n || n === 0) && (e.wrapperEl.style.height = `${n}px`);
|
|
833
|
-
}
|
|
834
|
-
function Mi() {
|
|
835
|
-
const t = this, e = t.slides, i = t.isElement ? t.isHorizontal() ? t.wrapperEl.offsetLeft : t.wrapperEl.offsetTop : 0;
|
|
836
|
-
for (let s = 0; s < e.length; s += 1)
|
|
837
|
-
e[s].swiperSlideOffset = (t.isHorizontal() ? e[s].offsetLeft : e[s].offsetTop) - i - t.cssOverflowAdjustment();
|
|
838
|
-
}
|
|
839
|
-
const qe = (t, e, i) => {
|
|
840
|
-
e && !t.classList.contains(i) ? t.classList.add(i) : !e && t.classList.contains(i) && t.classList.remove(i);
|
|
841
|
-
};
|
|
842
|
-
function Ii(t) {
|
|
843
|
-
t === void 0 && (t = this && this.translate || 0);
|
|
844
|
-
const e = this, i = e.params, {
|
|
845
|
-
slides: s,
|
|
846
|
-
rtlTranslate: n,
|
|
847
|
-
snapGrid: r
|
|
848
|
-
} = e;
|
|
849
|
-
if (s.length === 0) return;
|
|
850
|
-
typeof s[0].swiperSlideOffset > "u" && e.updateSlidesOffset();
|
|
851
|
-
let l = -t;
|
|
852
|
-
n && (l = t), e.visibleSlidesIndexes = [], e.visibleSlides = [];
|
|
853
|
-
let a = i.spaceBetween;
|
|
854
|
-
typeof a == "string" && a.indexOf("%") >= 0 ? a = parseFloat(a.replace("%", "")) / 100 * e.size : typeof a == "string" && (a = parseFloat(a));
|
|
855
|
-
for (let o = 0; o < s.length; o += 1) {
|
|
856
|
-
const c = s[o];
|
|
857
|
-
let d = c.swiperSlideOffset;
|
|
858
|
-
i.cssMode && i.centeredSlides && (d -= s[0].swiperSlideOffset);
|
|
859
|
-
const p = (l + (i.centeredSlides ? e.minTranslate() : 0) - d) / (c.swiperSlideSize + a), h = (l - r[0] + (i.centeredSlides ? e.minTranslate() : 0) - d) / (c.swiperSlideSize + a), w = -(l - d), m = w + e.slidesSizesGrid[o], b = w >= 0 && w <= e.size - e.slidesSizesGrid[o], x = w >= 0 && w < e.size - 1 || m > 1 && m <= e.size || w <= 0 && m >= e.size;
|
|
860
|
-
x && (e.visibleSlides.push(c), e.visibleSlidesIndexes.push(o)), qe(c, x, i.slideVisibleClass), qe(c, b, i.slideFullyVisibleClass), c.progress = n ? -p : p, c.originalProgress = n ? -h : h;
|
|
861
|
-
}
|
|
862
|
-
}
|
|
863
|
-
function Li(t) {
|
|
864
|
-
const e = this;
|
|
865
|
-
if (typeof t > "u") {
|
|
866
|
-
const d = e.rtlTranslate ? -1 : 1;
|
|
867
|
-
t = e && e.translate && e.translate * d || 0;
|
|
868
|
-
}
|
|
869
|
-
const i = e.params, s = e.maxTranslate() - e.minTranslate();
|
|
870
|
-
let {
|
|
871
|
-
progress: n,
|
|
872
|
-
isBeginning: r,
|
|
873
|
-
isEnd: l,
|
|
874
|
-
progressLoop: a
|
|
875
|
-
} = e;
|
|
876
|
-
const o = r, c = l;
|
|
877
|
-
if (s === 0)
|
|
878
|
-
n = 0, r = !0, l = !0;
|
|
879
|
-
else {
|
|
880
|
-
n = (t - e.minTranslate()) / s;
|
|
881
|
-
const d = Math.abs(t - e.minTranslate()) < 1, p = Math.abs(t - e.maxTranslate()) < 1;
|
|
882
|
-
r = d || n <= 0, l = p || n >= 1, d && (n = 0), p && (n = 1);
|
|
883
|
-
}
|
|
884
|
-
if (i.loop) {
|
|
885
|
-
const d = e.getSlideIndexByData(0), p = e.getSlideIndexByData(e.slides.length - 1), h = e.slidesGrid[d], w = e.slidesGrid[p], m = e.slidesGrid[e.slidesGrid.length - 1], b = Math.abs(t);
|
|
886
|
-
b >= h ? a = (b - h) / m : a = (b + m - w) / m, a > 1 && (a -= 1);
|
|
887
|
-
}
|
|
888
|
-
Object.assign(e, {
|
|
889
|
-
progress: n,
|
|
890
|
-
progressLoop: a,
|
|
891
|
-
isBeginning: r,
|
|
892
|
-
isEnd: l
|
|
893
|
-
}), (i.watchSlidesProgress || i.centeredSlides && i.autoHeight) && e.updateSlidesProgress(t), r && !o && e.emit("reachBeginning toEdge"), l && !c && e.emit("reachEnd toEdge"), (o && !r || c && !l) && e.emit("fromEdge"), e.emit("progress", n);
|
|
894
|
-
}
|
|
895
|
-
const Ie = (t, e, i) => {
|
|
896
|
-
e && !t.classList.contains(i) ? t.classList.add(i) : !e && t.classList.contains(i) && t.classList.remove(i);
|
|
897
|
-
};
|
|
898
|
-
function _i() {
|
|
899
|
-
const t = this, {
|
|
900
|
-
slides: e,
|
|
901
|
-
params: i,
|
|
902
|
-
slidesEl: s,
|
|
903
|
-
activeIndex: n
|
|
904
|
-
} = t, r = t.virtual && i.virtual.enabled, l = t.grid && i.grid && i.grid.rows > 1, a = (p) => Q(s, `.${i.slideClass}${p}, swiper-slide${p}`)[0];
|
|
905
|
-
let o, c, d;
|
|
906
|
-
if (r)
|
|
907
|
-
if (i.loop) {
|
|
908
|
-
let p = n - t.virtual.slidesBefore;
|
|
909
|
-
p < 0 && (p = t.virtual.slides.length + p), p >= t.virtual.slides.length && (p -= t.virtual.slides.length), o = a(`[data-swiper-slide-index="${p}"]`);
|
|
910
|
-
} else
|
|
911
|
-
o = a(`[data-swiper-slide-index="${n}"]`);
|
|
912
|
-
else
|
|
913
|
-
l ? (o = e.find((p) => p.column === n), d = e.find((p) => p.column === n + 1), c = e.find((p) => p.column === n - 1)) : o = e[n];
|
|
914
|
-
o && (l || (d = vi(o, `.${i.slideClass}, swiper-slide`)[0], i.loop && !d && (d = e[0]), c = gi(o, `.${i.slideClass}, swiper-slide`)[0], i.loop && !c === 0 && (c = e[e.length - 1]))), e.forEach((p) => {
|
|
915
|
-
Ie(p, p === o, i.slideActiveClass), Ie(p, p === d, i.slideNextClass), Ie(p, p === c, i.slidePrevClass);
|
|
916
|
-
}), t.emitSlidesClasses();
|
|
917
|
-
}
|
|
918
|
-
const we = (t, e) => {
|
|
919
|
-
if (!t || t.destroyed || !t.params) return;
|
|
920
|
-
const i = () => t.isElement ? "swiper-slide" : `.${t.params.slideClass}`, s = e.closest(i());
|
|
921
|
-
if (s) {
|
|
922
|
-
let n = s.querySelector(`.${t.params.lazyPreloaderClass}`);
|
|
923
|
-
!n && t.isElement && (s.shadowRoot ? n = s.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`) : requestAnimationFrame(() => {
|
|
924
|
-
s.shadowRoot && (n = s.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`), n && n.remove());
|
|
925
|
-
})), n && n.remove();
|
|
926
|
-
}
|
|
927
|
-
}, Le = (t, e) => {
|
|
928
|
-
if (!t.slides[e]) return;
|
|
929
|
-
const i = t.slides[e].querySelector('[loading="lazy"]');
|
|
930
|
-
i && i.removeAttribute("loading");
|
|
931
|
-
}, Ge = (t) => {
|
|
932
|
-
if (!t || t.destroyed || !t.params) return;
|
|
933
|
-
let e = t.params.lazyPreloadPrevNext;
|
|
934
|
-
const i = t.slides.length;
|
|
935
|
-
if (!i || !e || e < 0) return;
|
|
936
|
-
e = Math.min(e, i);
|
|
937
|
-
const s = t.params.slidesPerView === "auto" ? t.slidesPerViewDynamic() : Math.ceil(t.params.slidesPerView), n = t.activeIndex;
|
|
938
|
-
if (t.params.grid && t.params.grid.rows > 1) {
|
|
939
|
-
const l = n, a = [l - e];
|
|
940
|
-
a.push(...Array.from({
|
|
941
|
-
length: e
|
|
942
|
-
}).map((o, c) => l + s + c)), t.slides.forEach((o, c) => {
|
|
943
|
-
a.includes(o.column) && Le(t, c);
|
|
944
|
-
});
|
|
945
|
-
return;
|
|
946
|
-
}
|
|
947
|
-
const r = n + s - 1;
|
|
948
|
-
if (t.params.rewind || t.params.loop)
|
|
949
|
-
for (let l = n - e; l <= r + e; l += 1) {
|
|
950
|
-
const a = (l % i + i) % i;
|
|
951
|
-
(a < n || a > r) && Le(t, a);
|
|
952
|
-
}
|
|
953
|
-
else
|
|
954
|
-
for (let l = Math.max(n - e, 0); l <= Math.min(r + e, i - 1); l += 1)
|
|
955
|
-
l !== n && (l > r || l < n) && Le(t, l);
|
|
956
|
-
};
|
|
957
|
-
function Oi(t) {
|
|
958
|
-
const {
|
|
959
|
-
slidesGrid: e,
|
|
960
|
-
params: i
|
|
961
|
-
} = t, s = t.rtlTranslate ? t.translate : -t.translate;
|
|
962
|
-
let n;
|
|
963
|
-
for (let r = 0; r < e.length; r += 1)
|
|
964
|
-
typeof e[r + 1] < "u" ? s >= e[r] && s < e[r + 1] - (e[r + 1] - e[r]) / 2 ? n = r : s >= e[r] && s < e[r + 1] && (n = r + 1) : s >= e[r] && (n = r);
|
|
965
|
-
return i.normalizeSlideIndex && (n < 0 || typeof n > "u") && (n = 0), n;
|
|
966
|
-
}
|
|
967
|
-
function Ni(t) {
|
|
968
|
-
const e = this, i = e.rtlTranslate ? e.translate : -e.translate, {
|
|
969
|
-
snapGrid: s,
|
|
970
|
-
params: n,
|
|
971
|
-
activeIndex: r,
|
|
972
|
-
realIndex: l,
|
|
973
|
-
snapIndex: a
|
|
974
|
-
} = e;
|
|
975
|
-
let o = t, c;
|
|
976
|
-
const d = (w) => {
|
|
977
|
-
let m = w - e.virtual.slidesBefore;
|
|
978
|
-
return m < 0 && (m = e.virtual.slides.length + m), m >= e.virtual.slides.length && (m -= e.virtual.slides.length), m;
|
|
979
|
-
};
|
|
980
|
-
if (typeof o > "u" && (o = Oi(e)), s.indexOf(i) >= 0)
|
|
981
|
-
c = s.indexOf(i);
|
|
982
|
-
else {
|
|
983
|
-
const w = Math.min(n.slidesPerGroupSkip, o);
|
|
984
|
-
c = w + Math.floor((o - w) / n.slidesPerGroup);
|
|
985
|
-
}
|
|
986
|
-
if (c >= s.length && (c = s.length - 1), o === r && !e.params.loop) {
|
|
987
|
-
c !== a && (e.snapIndex = c, e.emit("snapIndexChange"));
|
|
988
|
-
return;
|
|
989
|
-
}
|
|
990
|
-
if (o === r && e.params.loop && e.virtual && e.params.virtual.enabled) {
|
|
991
|
-
e.realIndex = d(o);
|
|
992
|
-
return;
|
|
993
|
-
}
|
|
994
|
-
const p = e.grid && n.grid && n.grid.rows > 1;
|
|
995
|
-
let h;
|
|
996
|
-
if (e.virtual && n.virtual.enabled && n.loop)
|
|
997
|
-
h = d(o);
|
|
998
|
-
else if (p) {
|
|
999
|
-
const w = e.slides.find((b) => b.column === o);
|
|
1000
|
-
let m = parseInt(w.getAttribute("data-swiper-slide-index"), 10);
|
|
1001
|
-
Number.isNaN(m) && (m = Math.max(e.slides.indexOf(w), 0)), h = Math.floor(m / n.grid.rows);
|
|
1002
|
-
} else if (e.slides[o]) {
|
|
1003
|
-
const w = e.slides[o].getAttribute("data-swiper-slide-index");
|
|
1004
|
-
w ? h = parseInt(w, 10) : h = o;
|
|
1005
|
-
} else
|
|
1006
|
-
h = o;
|
|
1007
|
-
Object.assign(e, {
|
|
1008
|
-
previousSnapIndex: a,
|
|
1009
|
-
snapIndex: c,
|
|
1010
|
-
previousRealIndex: l,
|
|
1011
|
-
realIndex: h,
|
|
1012
|
-
previousIndex: r,
|
|
1013
|
-
activeIndex: o
|
|
1014
|
-
}), e.initialized && Ge(e), e.emit("activeIndexChange"), e.emit("snapIndexChange"), (e.initialized || e.params.runCallbacksOnInit) && (l !== h && e.emit("realIndexChange"), e.emit("slideChange"));
|
|
1015
|
-
}
|
|
1016
|
-
function zi(t, e) {
|
|
1017
|
-
const i = this, s = i.params;
|
|
1018
|
-
let n = t.closest(`.${s.slideClass}, swiper-slide`);
|
|
1019
|
-
!n && i.isElement && e && e.length > 1 && e.includes(t) && [...e.slice(e.indexOf(t) + 1, e.length)].forEach((a) => {
|
|
1020
|
-
!n && a.matches && a.matches(`.${s.slideClass}, swiper-slide`) && (n = a);
|
|
1021
|
-
});
|
|
1022
|
-
let r = !1, l;
|
|
1023
|
-
if (n) {
|
|
1024
|
-
for (let a = 0; a < i.slides.length; a += 1)
|
|
1025
|
-
if (i.slides[a] === n) {
|
|
1026
|
-
r = !0, l = a;
|
|
1027
|
-
break;
|
|
1028
|
-
}
|
|
1029
|
-
}
|
|
1030
|
-
if (n && r)
|
|
1031
|
-
i.clickedSlide = n, i.virtual && i.params.virtual.enabled ? i.clickedIndex = parseInt(n.getAttribute("data-swiper-slide-index"), 10) : i.clickedIndex = l;
|
|
1032
|
-
else {
|
|
1033
|
-
i.clickedSlide = void 0, i.clickedIndex = void 0;
|
|
1034
|
-
return;
|
|
1035
|
-
}
|
|
1036
|
-
s.slideToClickedSlide && i.clickedIndex !== void 0 && i.clickedIndex !== i.activeIndex && i.slideToClickedSlide();
|
|
1037
|
-
}
|
|
1038
|
-
var Ai = {
|
|
1039
|
-
updateSize: Ei,
|
|
1040
|
-
updateSlides: Ci,
|
|
1041
|
-
updateAutoHeight: Pi,
|
|
1042
|
-
updateSlidesOffset: Mi,
|
|
1043
|
-
updateSlidesProgress: Ii,
|
|
1044
|
-
updateProgress: Li,
|
|
1045
|
-
updateSlidesClasses: _i,
|
|
1046
|
-
updateActiveIndex: Ni,
|
|
1047
|
-
updateClickedSlide: zi
|
|
1048
|
-
};
|
|
1049
|
-
function $i(t) {
|
|
1050
|
-
t === void 0 && (t = this.isHorizontal() ? "x" : "y");
|
|
1051
|
-
const e = this, {
|
|
1052
|
-
params: i,
|
|
1053
|
-
rtlTranslate: s,
|
|
1054
|
-
translate: n,
|
|
1055
|
-
wrapperEl: r
|
|
1056
|
-
} = e;
|
|
1057
|
-
if (i.virtualTranslate)
|
|
1058
|
-
return s ? -n : n;
|
|
1059
|
-
if (i.cssMode)
|
|
1060
|
-
return n;
|
|
1061
|
-
let l = fi(r, t);
|
|
1062
|
-
return l += e.cssOverflowAdjustment(), s && (l = -l), l || 0;
|
|
1063
|
-
}
|
|
1064
|
-
function ki(t, e) {
|
|
1065
|
-
const i = this, {
|
|
1066
|
-
rtlTranslate: s,
|
|
1067
|
-
params: n,
|
|
1068
|
-
wrapperEl: r,
|
|
1069
|
-
progress: l
|
|
1070
|
-
} = i;
|
|
1071
|
-
let a = 0, o = 0;
|
|
1072
|
-
const c = 0;
|
|
1073
|
-
i.isHorizontal() ? a = s ? -t : t : o = t, n.roundLengths && (a = Math.floor(a), o = Math.floor(o)), i.previousTranslate = i.translate, i.translate = i.isHorizontal() ? a : o, n.cssMode ? r[i.isHorizontal() ? "scrollLeft" : "scrollTop"] = i.isHorizontal() ? -a : -o : n.virtualTranslate || (i.isHorizontal() ? a -= i.cssOverflowAdjustment() : o -= i.cssOverflowAdjustment(), r.style.transform = `translate3d(${a}px, ${o}px, ${c}px)`);
|
|
1074
|
-
let d;
|
|
1075
|
-
const p = i.maxTranslate() - i.minTranslate();
|
|
1076
|
-
p === 0 ? d = 0 : d = (t - i.minTranslate()) / p, d !== l && i.updateProgress(t), i.emit("setTranslate", i.translate, e);
|
|
1077
|
-
}
|
|
1078
|
-
function Gi() {
|
|
1079
|
-
return -this.snapGrid[0];
|
|
1080
|
-
}
|
|
1081
|
-
function Di() {
|
|
1082
|
-
return -this.snapGrid[this.snapGrid.length - 1];
|
|
1083
|
-
}
|
|
1084
|
-
function Bi(t, e, i, s, n) {
|
|
1085
|
-
t === void 0 && (t = 0), e === void 0 && (e = this.params.speed), i === void 0 && (i = !0), s === void 0 && (s = !0);
|
|
1086
|
-
const r = this, {
|
|
1087
|
-
params: l,
|
|
1088
|
-
wrapperEl: a
|
|
1089
|
-
} = r;
|
|
1090
|
-
if (r.animating && l.preventInteractionOnTransition)
|
|
1091
|
-
return !1;
|
|
1092
|
-
const o = r.minTranslate(), c = r.maxTranslate();
|
|
1093
|
-
let d;
|
|
1094
|
-
if (s && t > o ? d = o : s && t < c ? d = c : d = t, r.updateProgress(d), l.cssMode) {
|
|
1095
|
-
const p = r.isHorizontal();
|
|
1096
|
-
if (e === 0)
|
|
1097
|
-
a[p ? "scrollLeft" : "scrollTop"] = -d;
|
|
1098
|
-
else {
|
|
1099
|
-
if (!r.support.smoothScroll)
|
|
1100
|
-
return st({
|
|
1101
|
-
swiper: r,
|
|
1102
|
-
targetPosition: -d,
|
|
1103
|
-
side: p ? "left" : "top"
|
|
1104
|
-
}), !0;
|
|
1105
|
-
a.scrollTo({
|
|
1106
|
-
[p ? "left" : "top"]: -d,
|
|
1107
|
-
behavior: "smooth"
|
|
1108
|
-
});
|
|
1109
|
-
}
|
|
1110
|
-
return !0;
|
|
1111
|
-
}
|
|
1112
|
-
return e === 0 ? (r.setTransition(0), r.setTranslate(d), i && (r.emit("beforeTransitionStart", e, n), r.emit("transitionEnd"))) : (r.setTransition(e), r.setTranslate(d), i && (r.emit("beforeTransitionStart", e, n), r.emit("transitionStart")), r.animating || (r.animating = !0, r.onTranslateToWrapperTransitionEnd || (r.onTranslateToWrapperTransitionEnd = function(h) {
|
|
1113
|
-
!r || r.destroyed || h.target === this && (r.wrapperEl.removeEventListener("transitionend", r.onTranslateToWrapperTransitionEnd), r.onTranslateToWrapperTransitionEnd = null, delete r.onTranslateToWrapperTransitionEnd, r.animating = !1, i && r.emit("transitionEnd"));
|
|
1114
|
-
}), r.wrapperEl.addEventListener("transitionend", r.onTranslateToWrapperTransitionEnd))), !0;
|
|
1115
|
-
}
|
|
1116
|
-
var Vi = {
|
|
1117
|
-
getTranslate: $i,
|
|
1118
|
-
setTranslate: ki,
|
|
1119
|
-
minTranslate: Gi,
|
|
1120
|
-
maxTranslate: Di,
|
|
1121
|
-
translateTo: Bi
|
|
1122
|
-
};
|
|
1123
|
-
function Fi(t, e) {
|
|
1124
|
-
const i = this;
|
|
1125
|
-
i.params.cssMode || (i.wrapperEl.style.transitionDuration = `${t}ms`, i.wrapperEl.style.transitionDelay = t === 0 ? "0ms" : ""), i.emit("setTransition", t, e);
|
|
1126
|
-
}
|
|
1127
|
-
function ot(t) {
|
|
1128
|
-
let {
|
|
1129
|
-
swiper: e,
|
|
1130
|
-
runCallbacks: i,
|
|
1131
|
-
direction: s,
|
|
1132
|
-
step: n
|
|
1133
|
-
} = t;
|
|
1134
|
-
const {
|
|
1135
|
-
activeIndex: r,
|
|
1136
|
-
previousIndex: l
|
|
1137
|
-
} = e;
|
|
1138
|
-
let a = s;
|
|
1139
|
-
a || (r > l ? a = "next" : r < l ? a = "prev" : a = "reset"), e.emit(`transition${n}`), i && a === "reset" ? e.emit(`slideResetTransition${n}`) : i && r !== l && (e.emit(`slideChangeTransition${n}`), a === "next" ? e.emit(`slideNextTransition${n}`) : e.emit(`slidePrevTransition${n}`));
|
|
1140
|
-
}
|
|
1141
|
-
function Hi(t, e) {
|
|
1142
|
-
t === void 0 && (t = !0);
|
|
1143
|
-
const i = this, {
|
|
1144
|
-
params: s
|
|
1145
|
-
} = i;
|
|
1146
|
-
s.cssMode || (s.autoHeight && i.updateAutoHeight(), ot({
|
|
1147
|
-
swiper: i,
|
|
1148
|
-
runCallbacks: t,
|
|
1149
|
-
direction: e,
|
|
1150
|
-
step: "Start"
|
|
1151
|
-
}));
|
|
1152
|
-
}
|
|
1153
|
-
function Ri(t, e) {
|
|
1154
|
-
t === void 0 && (t = !0);
|
|
1155
|
-
const i = this, {
|
|
1156
|
-
params: s
|
|
1157
|
-
} = i;
|
|
1158
|
-
i.animating = !1, !s.cssMode && (i.setTransition(0), ot({
|
|
1159
|
-
swiper: i,
|
|
1160
|
-
runCallbacks: t,
|
|
1161
|
-
direction: e,
|
|
1162
|
-
step: "End"
|
|
1163
|
-
}));
|
|
1164
|
-
}
|
|
1165
|
-
var ji = {
|
|
1166
|
-
setTransition: Fi,
|
|
1167
|
-
transitionStart: Hi,
|
|
1168
|
-
transitionEnd: Ri
|
|
1169
|
-
};
|
|
1170
|
-
function Wi(t, e, i, s, n) {
|
|
1171
|
-
t === void 0 && (t = 0), i === void 0 && (i = !0), typeof t == "string" && (t = parseInt(t, 10));
|
|
1172
|
-
const r = this;
|
|
1173
|
-
let l = t;
|
|
1174
|
-
l < 0 && (l = 0);
|
|
1175
|
-
const {
|
|
1176
|
-
params: a,
|
|
1177
|
-
snapGrid: o,
|
|
1178
|
-
slidesGrid: c,
|
|
1179
|
-
previousIndex: d,
|
|
1180
|
-
activeIndex: p,
|
|
1181
|
-
rtlTranslate: h,
|
|
1182
|
-
wrapperEl: w,
|
|
1183
|
-
enabled: m
|
|
1184
|
-
} = r;
|
|
1185
|
-
if (!m && !s && !n || r.destroyed || r.animating && a.preventInteractionOnTransition)
|
|
1186
|
-
return !1;
|
|
1187
|
-
typeof e > "u" && (e = r.params.speed);
|
|
1188
|
-
const b = Math.min(r.params.slidesPerGroupSkip, l);
|
|
1189
|
-
let x = b + Math.floor((l - b) / r.params.slidesPerGroup);
|
|
1190
|
-
x >= o.length && (x = o.length - 1);
|
|
1191
|
-
const g = -o[x];
|
|
1192
|
-
if (a.normalizeSlideIndex)
|
|
1193
|
-
for (let I = 0; I < c.length; I += 1) {
|
|
1194
|
-
const M = -Math.floor(g * 100), T = Math.floor(c[I] * 100), E = Math.floor(c[I + 1] * 100);
|
|
1195
|
-
typeof c[I + 1] < "u" ? M >= T && M < E - (E - T) / 2 ? l = I : M >= T && M < E && (l = I + 1) : M >= T && (l = I);
|
|
1196
|
-
}
|
|
1197
|
-
if (r.initialized && l !== p && (!r.allowSlideNext && (h ? g > r.translate && g > r.minTranslate() : g < r.translate && g < r.minTranslate()) || !r.allowSlidePrev && g > r.translate && g > r.maxTranslate() && (p || 0) !== l))
|
|
1198
|
-
return !1;
|
|
1199
|
-
l !== (d || 0) && i && r.emit("beforeSlideChangeStart"), r.updateProgress(g);
|
|
1200
|
-
let u;
|
|
1201
|
-
l > p ? u = "next" : l < p ? u = "prev" : u = "reset";
|
|
1202
|
-
const f = r.virtual && r.params.virtual.enabled;
|
|
1203
|
-
if (!(f && n) && (h && -g === r.translate || !h && g === r.translate))
|
|
1204
|
-
return r.updateActiveIndex(l), a.autoHeight && r.updateAutoHeight(), r.updateSlidesClasses(), a.effect !== "slide" && r.setTranslate(g), u !== "reset" && (r.transitionStart(i, u), r.transitionEnd(i, u)), !1;
|
|
1205
|
-
if (a.cssMode) {
|
|
1206
|
-
const I = r.isHorizontal(), M = h ? g : -g;
|
|
1207
|
-
if (e === 0)
|
|
1208
|
-
f && (r.wrapperEl.style.scrollSnapType = "none", r._immediateVirtual = !0), f && !r._cssModeVirtualInitialSet && r.params.initialSlide > 0 ? (r._cssModeVirtualInitialSet = !0, requestAnimationFrame(() => {
|
|
1209
|
-
w[I ? "scrollLeft" : "scrollTop"] = M;
|
|
1210
|
-
})) : w[I ? "scrollLeft" : "scrollTop"] = M, f && requestAnimationFrame(() => {
|
|
1211
|
-
r.wrapperEl.style.scrollSnapType = "", r._immediateVirtual = !1;
|
|
1212
|
-
});
|
|
1213
|
-
else {
|
|
1214
|
-
if (!r.support.smoothScroll)
|
|
1215
|
-
return st({
|
|
1216
|
-
swiper: r,
|
|
1217
|
-
targetPosition: M,
|
|
1218
|
-
side: I ? "left" : "top"
|
|
1219
|
-
}), !0;
|
|
1220
|
-
w.scrollTo({
|
|
1221
|
-
[I ? "left" : "top"]: M,
|
|
1222
|
-
behavior: "smooth"
|
|
1223
|
-
});
|
|
1224
|
-
}
|
|
1225
|
-
return !0;
|
|
1226
|
-
}
|
|
1227
|
-
const P = lt().isSafari;
|
|
1228
|
-
return f && !n && P && r.isElement && r.virtual.update(!1, !1, l), r.setTransition(e), r.setTranslate(g), r.updateActiveIndex(l), r.updateSlidesClasses(), r.emit("beforeTransitionStart", e, s), r.transitionStart(i, u), e === 0 ? r.transitionEnd(i, u) : r.animating || (r.animating = !0, r.onSlideToWrapperTransitionEnd || (r.onSlideToWrapperTransitionEnd = function(M) {
|
|
1229
|
-
!r || r.destroyed || M.target === this && (r.wrapperEl.removeEventListener("transitionend", r.onSlideToWrapperTransitionEnd), r.onSlideToWrapperTransitionEnd = null, delete r.onSlideToWrapperTransitionEnd, r.transitionEnd(i, u));
|
|
1230
|
-
}), r.wrapperEl.addEventListener("transitionend", r.onSlideToWrapperTransitionEnd)), !0;
|
|
1231
|
-
}
|
|
1232
|
-
function qi(t, e, i, s) {
|
|
1233
|
-
t === void 0 && (t = 0), i === void 0 && (i = !0), typeof t == "string" && (t = parseInt(t, 10));
|
|
1234
|
-
const n = this;
|
|
1235
|
-
if (n.destroyed) return;
|
|
1236
|
-
typeof e > "u" && (e = n.params.speed);
|
|
1237
|
-
const r = n.grid && n.params.grid && n.params.grid.rows > 1;
|
|
1238
|
-
let l = t;
|
|
1239
|
-
if (n.params.loop)
|
|
1240
|
-
if (n.virtual && n.params.virtual.enabled)
|
|
1241
|
-
l = l + n.virtual.slidesBefore;
|
|
1242
|
-
else {
|
|
1243
|
-
let a;
|
|
1244
|
-
if (r) {
|
|
1245
|
-
const h = l * n.params.grid.rows;
|
|
1246
|
-
a = n.slides.find((w) => w.getAttribute("data-swiper-slide-index") * 1 === h).column;
|
|
1247
|
-
} else
|
|
1248
|
-
a = n.getSlideIndexByData(l);
|
|
1249
|
-
const o = r ? Math.ceil(n.slides.length / n.params.grid.rows) : n.slides.length, {
|
|
1250
|
-
centeredSlides: c
|
|
1251
|
-
} = n.params;
|
|
1252
|
-
let d = n.params.slidesPerView;
|
|
1253
|
-
d === "auto" ? d = n.slidesPerViewDynamic() : (d = Math.ceil(parseFloat(n.params.slidesPerView, 10)), c && d % 2 === 0 && (d = d + 1));
|
|
1254
|
-
let p = o - a < d;
|
|
1255
|
-
if (c && (p = p || a < Math.ceil(d / 2)), s && c && n.params.slidesPerView !== "auto" && !r && (p = !1), p) {
|
|
1256
|
-
const h = c ? a < n.activeIndex ? "prev" : "next" : a - n.activeIndex - 1 < n.params.slidesPerView ? "next" : "prev";
|
|
1257
|
-
n.loopFix({
|
|
1258
|
-
direction: h,
|
|
1259
|
-
slideTo: !0,
|
|
1260
|
-
activeSlideIndex: h === "next" ? a + 1 : a - o + 1,
|
|
1261
|
-
slideRealIndex: h === "next" ? n.realIndex : void 0
|
|
1262
|
-
});
|
|
1263
|
-
}
|
|
1264
|
-
if (r) {
|
|
1265
|
-
const h = l * n.params.grid.rows;
|
|
1266
|
-
l = n.slides.find((w) => w.getAttribute("data-swiper-slide-index") * 1 === h).column;
|
|
1267
|
-
} else
|
|
1268
|
-
l = n.getSlideIndexByData(l);
|
|
1269
|
-
}
|
|
1270
|
-
return requestAnimationFrame(() => {
|
|
1271
|
-
n.slideTo(l, e, i, s);
|
|
1272
|
-
}), n;
|
|
1273
|
-
}
|
|
1274
|
-
function Xi(t, e, i) {
|
|
1275
|
-
e === void 0 && (e = !0);
|
|
1276
|
-
const s = this, {
|
|
1277
|
-
enabled: n,
|
|
1278
|
-
params: r,
|
|
1279
|
-
animating: l
|
|
1280
|
-
} = s;
|
|
1281
|
-
if (!n || s.destroyed) return s;
|
|
1282
|
-
typeof t > "u" && (t = s.params.speed);
|
|
1283
|
-
let a = r.slidesPerGroup;
|
|
1284
|
-
r.slidesPerView === "auto" && r.slidesPerGroup === 1 && r.slidesPerGroupAuto && (a = Math.max(s.slidesPerViewDynamic("current", !0), 1));
|
|
1285
|
-
const o = s.activeIndex < r.slidesPerGroupSkip ? 1 : a, c = s.virtual && r.virtual.enabled;
|
|
1286
|
-
if (r.loop) {
|
|
1287
|
-
if (l && !c && r.loopPreventsSliding) return !1;
|
|
1288
|
-
if (s.loopFix({
|
|
1289
|
-
direction: "next"
|
|
1290
|
-
}), s._clientLeft = s.wrapperEl.clientLeft, s.activeIndex === s.slides.length - 1 && r.cssMode)
|
|
1291
|
-
return requestAnimationFrame(() => {
|
|
1292
|
-
s.slideTo(s.activeIndex + o, t, e, i);
|
|
1293
|
-
}), !0;
|
|
1294
|
-
}
|
|
1295
|
-
return r.rewind && s.isEnd ? s.slideTo(0, t, e, i) : s.slideTo(s.activeIndex + o, t, e, i);
|
|
1296
|
-
}
|
|
1297
|
-
function Yi(t, e, i) {
|
|
1298
|
-
e === void 0 && (e = !0);
|
|
1299
|
-
const s = this, {
|
|
1300
|
-
params: n,
|
|
1301
|
-
snapGrid: r,
|
|
1302
|
-
slidesGrid: l,
|
|
1303
|
-
rtlTranslate: a,
|
|
1304
|
-
enabled: o,
|
|
1305
|
-
animating: c
|
|
1306
|
-
} = s;
|
|
1307
|
-
if (!o || s.destroyed) return s;
|
|
1308
|
-
typeof t > "u" && (t = s.params.speed);
|
|
1309
|
-
const d = s.virtual && n.virtual.enabled;
|
|
1310
|
-
if (n.loop) {
|
|
1311
|
-
if (c && !d && n.loopPreventsSliding) return !1;
|
|
1312
|
-
s.loopFix({
|
|
1313
|
-
direction: "prev"
|
|
1314
|
-
}), s._clientLeft = s.wrapperEl.clientLeft;
|
|
1315
|
-
}
|
|
1316
|
-
const p = a ? s.translate : -s.translate;
|
|
1317
|
-
function h(u) {
|
|
1318
|
-
return u < 0 ? -Math.floor(Math.abs(u)) : Math.floor(u);
|
|
1319
|
-
}
|
|
1320
|
-
const w = h(p), m = r.map((u) => h(u)), b = n.freeMode && n.freeMode.enabled;
|
|
1321
|
-
let x = r[m.indexOf(w) - 1];
|
|
1322
|
-
if (typeof x > "u" && (n.cssMode || b)) {
|
|
1323
|
-
let u;
|
|
1324
|
-
r.forEach((f, S) => {
|
|
1325
|
-
w >= f && (u = S);
|
|
1326
|
-
}), typeof u < "u" && (x = b ? r[u] : r[u > 0 ? u - 1 : u]);
|
|
1327
|
-
}
|
|
1328
|
-
let g = 0;
|
|
1329
|
-
if (typeof x < "u" && (g = l.indexOf(x), g < 0 && (g = s.activeIndex - 1), n.slidesPerView === "auto" && n.slidesPerGroup === 1 && n.slidesPerGroupAuto && (g = g - s.slidesPerViewDynamic("previous", !0) + 1, g = Math.max(g, 0))), n.rewind && s.isBeginning) {
|
|
1330
|
-
const u = s.params.virtual && s.params.virtual.enabled && s.virtual ? s.virtual.slides.length - 1 : s.slides.length - 1;
|
|
1331
|
-
return s.slideTo(u, t, e, i);
|
|
1332
|
-
} else if (n.loop && s.activeIndex === 0 && n.cssMode)
|
|
1333
|
-
return requestAnimationFrame(() => {
|
|
1334
|
-
s.slideTo(g, t, e, i);
|
|
1335
|
-
}), !0;
|
|
1336
|
-
return s.slideTo(g, t, e, i);
|
|
1337
|
-
}
|
|
1338
|
-
function Ui(t, e, i) {
|
|
1339
|
-
e === void 0 && (e = !0);
|
|
1340
|
-
const s = this;
|
|
1341
|
-
if (!s.destroyed)
|
|
1342
|
-
return typeof t > "u" && (t = s.params.speed), s.slideTo(s.activeIndex, t, e, i);
|
|
1343
|
-
}
|
|
1344
|
-
function Ki(t, e, i, s) {
|
|
1345
|
-
e === void 0 && (e = !0), s === void 0 && (s = 0.5);
|
|
1346
|
-
const n = this;
|
|
1347
|
-
if (n.destroyed) return;
|
|
1348
|
-
typeof t > "u" && (t = n.params.speed);
|
|
1349
|
-
let r = n.activeIndex;
|
|
1350
|
-
const l = Math.min(n.params.slidesPerGroupSkip, r), a = l + Math.floor((r - l) / n.params.slidesPerGroup), o = n.rtlTranslate ? n.translate : -n.translate;
|
|
1351
|
-
if (o >= n.snapGrid[a]) {
|
|
1352
|
-
const c = n.snapGrid[a], d = n.snapGrid[a + 1];
|
|
1353
|
-
o - c > (d - c) * s && (r += n.params.slidesPerGroup);
|
|
1354
|
-
} else {
|
|
1355
|
-
const c = n.snapGrid[a - 1], d = n.snapGrid[a];
|
|
1356
|
-
o - c <= (d - c) * s && (r -= n.params.slidesPerGroup);
|
|
1357
|
-
}
|
|
1358
|
-
return r = Math.max(r, 0), r = Math.min(r, n.slidesGrid.length - 1), n.slideTo(r, t, e, i);
|
|
1359
|
-
}
|
|
1360
|
-
function Zi() {
|
|
1361
|
-
const t = this;
|
|
1362
|
-
if (t.destroyed) return;
|
|
1363
|
-
const {
|
|
1364
|
-
params: e,
|
|
1365
|
-
slidesEl: i
|
|
1366
|
-
} = t, s = e.slidesPerView === "auto" ? t.slidesPerViewDynamic() : e.slidesPerView;
|
|
1367
|
-
let n = t.getSlideIndexWhenGrid(t.clickedIndex), r;
|
|
1368
|
-
const l = t.isElement ? "swiper-slide" : `.${e.slideClass}`, a = t.grid && t.params.grid && t.params.grid.rows > 1;
|
|
1369
|
-
if (e.loop) {
|
|
1370
|
-
if (t.animating) return;
|
|
1371
|
-
r = parseInt(t.clickedSlide.getAttribute("data-swiper-slide-index"), 10), e.centeredSlides ? t.slideToLoop(r) : n > (a ? (t.slides.length - s) / 2 - (t.params.grid.rows - 1) : t.slides.length - s) ? (t.loopFix(), n = t.getSlideIndex(Q(i, `${l}[data-swiper-slide-index="${r}"]`)[0]), it(() => {
|
|
1372
|
-
t.slideTo(n);
|
|
1373
|
-
})) : t.slideTo(n);
|
|
1374
|
-
} else
|
|
1375
|
-
t.slideTo(n);
|
|
1376
|
-
}
|
|
1377
|
-
var Qi = {
|
|
1378
|
-
slideTo: Wi,
|
|
1379
|
-
slideToLoop: qi,
|
|
1380
|
-
slideNext: Xi,
|
|
1381
|
-
slidePrev: Yi,
|
|
1382
|
-
slideReset: Ui,
|
|
1383
|
-
slideToClosest: Ki,
|
|
1384
|
-
slideToClickedSlide: Zi
|
|
1385
|
-
};
|
|
1386
|
-
function Ji(t, e) {
|
|
1387
|
-
const i = this, {
|
|
1388
|
-
params: s,
|
|
1389
|
-
slidesEl: n
|
|
1390
|
-
} = i;
|
|
1391
|
-
if (!s.loop || i.virtual && i.params.virtual.enabled) return;
|
|
1392
|
-
const r = () => {
|
|
1393
|
-
Q(n, `.${s.slideClass}, swiper-slide`).forEach((w, m) => {
|
|
1394
|
-
w.setAttribute("data-swiper-slide-index", m);
|
|
1395
|
-
});
|
|
1396
|
-
}, l = () => {
|
|
1397
|
-
const h = Q(n, `.${s.slideBlankClass}`);
|
|
1398
|
-
h.forEach((w) => {
|
|
1399
|
-
w.remove();
|
|
1400
|
-
}), h.length > 0 && (i.recalcSlides(), i.updateSlides());
|
|
1401
|
-
}, a = i.grid && s.grid && s.grid.rows > 1;
|
|
1402
|
-
s.loopAddBlankSlides && (s.slidesPerGroup > 1 || a) && l();
|
|
1403
|
-
const o = s.slidesPerGroup * (a ? s.grid.rows : 1), c = i.slides.length % o !== 0, d = a && i.slides.length % s.grid.rows !== 0, p = (h) => {
|
|
1404
|
-
for (let w = 0; w < h; w += 1) {
|
|
1405
|
-
const m = i.isElement ? ye("swiper-slide", [s.slideBlankClass]) : ye("div", [s.slideClass, s.slideBlankClass]);
|
|
1406
|
-
i.slidesEl.append(m);
|
|
1407
|
-
}
|
|
1408
|
-
};
|
|
1409
|
-
if (c) {
|
|
1410
|
-
if (s.loopAddBlankSlides) {
|
|
1411
|
-
const h = o - i.slides.length % o;
|
|
1412
|
-
p(h), i.recalcSlides(), i.updateSlides();
|
|
1413
|
-
} else
|
|
1414
|
-
be("Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
|
|
1415
|
-
r();
|
|
1416
|
-
} else if (d) {
|
|
1417
|
-
if (s.loopAddBlankSlides) {
|
|
1418
|
-
const h = s.grid.rows - i.slides.length % s.grid.rows;
|
|
1419
|
-
p(h), i.recalcSlides(), i.updateSlides();
|
|
1420
|
-
} else
|
|
1421
|
-
be("Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
|
|
1422
|
-
r();
|
|
1423
|
-
} else
|
|
1424
|
-
r();
|
|
1425
|
-
i.loopFix({
|
|
1426
|
-
slideRealIndex: t,
|
|
1427
|
-
direction: s.centeredSlides ? void 0 : "next",
|
|
1428
|
-
initial: e
|
|
1429
|
-
});
|
|
1430
|
-
}
|
|
1431
|
-
function es(t) {
|
|
1432
|
-
let {
|
|
1433
|
-
slideRealIndex: e,
|
|
1434
|
-
slideTo: i = !0,
|
|
1435
|
-
direction: s,
|
|
1436
|
-
setTranslate: n,
|
|
1437
|
-
activeSlideIndex: r,
|
|
1438
|
-
initial: l,
|
|
1439
|
-
byController: a,
|
|
1440
|
-
byMousewheel: o
|
|
1441
|
-
} = t === void 0 ? {} : t;
|
|
1442
|
-
const c = this;
|
|
1443
|
-
if (!c.params.loop) return;
|
|
1444
|
-
c.emit("beforeLoopFix");
|
|
1445
|
-
const {
|
|
1446
|
-
slides: d,
|
|
1447
|
-
allowSlidePrev: p,
|
|
1448
|
-
allowSlideNext: h,
|
|
1449
|
-
slidesEl: w,
|
|
1450
|
-
params: m
|
|
1451
|
-
} = c, {
|
|
1452
|
-
centeredSlides: b,
|
|
1453
|
-
initialSlide: x
|
|
1454
|
-
} = m;
|
|
1455
|
-
if (c.allowSlidePrev = !0, c.allowSlideNext = !0, c.virtual && m.virtual.enabled) {
|
|
1456
|
-
i && (!m.centeredSlides && c.snapIndex === 0 ? c.slideTo(c.virtual.slides.length, 0, !1, !0) : m.centeredSlides && c.snapIndex < m.slidesPerView ? c.slideTo(c.virtual.slides.length + c.snapIndex, 0, !1, !0) : c.snapIndex === c.snapGrid.length - 1 && c.slideTo(c.virtual.slidesBefore, 0, !1, !0)), c.allowSlidePrev = p, c.allowSlideNext = h, c.emit("loopFix");
|
|
1457
|
-
return;
|
|
1458
|
-
}
|
|
1459
|
-
let g = m.slidesPerView;
|
|
1460
|
-
g === "auto" ? g = c.slidesPerViewDynamic() : (g = Math.ceil(parseFloat(m.slidesPerView, 10)), b && g % 2 === 0 && (g = g + 1));
|
|
1461
|
-
const u = m.slidesPerGroupAuto ? g : m.slidesPerGroup;
|
|
1462
|
-
let f = b ? Math.max(u, Math.ceil(g / 2)) : u;
|
|
1463
|
-
f % u !== 0 && (f += u - f % u), f += m.loopAdditionalSlides, c.loopedSlides = f;
|
|
1464
|
-
const S = c.grid && m.grid && m.grid.rows > 1;
|
|
1465
|
-
d.length < g + f || c.params.effect === "cards" && d.length < g + f * 2 ? be("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled or not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters") : S && m.grid.fill === "row" && be("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");
|
|
1466
|
-
const y = [], P = [], I = S ? Math.ceil(d.length / m.grid.rows) : d.length, M = l && I - x < g && !b;
|
|
1467
|
-
let T = M ? x : c.activeIndex;
|
|
1468
|
-
typeof r > "u" ? r = c.getSlideIndex(d.find((O) => O.classList.contains(m.slideActiveClass))) : T = r;
|
|
1469
|
-
const E = s === "next" || !s, C = s === "prev" || !s;
|
|
1470
|
-
let _ = 0, z = 0;
|
|
1471
|
-
const $ = (S ? d[r].column : r) + (b && typeof n > "u" ? -g / 2 + 0.5 : 0);
|
|
1472
|
-
if ($ < f) {
|
|
1473
|
-
_ = Math.max(f - $, u);
|
|
1474
|
-
for (let O = 0; O < f - $; O += 1) {
|
|
1475
|
-
const B = O - Math.floor(O / I) * I;
|
|
1476
|
-
if (S) {
|
|
1477
|
-
const F = I - B - 1;
|
|
1478
|
-
for (let G = d.length - 1; G >= 0; G -= 1)
|
|
1479
|
-
d[G].column === F && y.push(G);
|
|
1480
|
-
} else
|
|
1481
|
-
y.push(I - B - 1);
|
|
1482
|
-
}
|
|
1483
|
-
} else if ($ + g > I - f) {
|
|
1484
|
-
z = Math.max($ - (I - f * 2), u), M && (z = Math.max(z, g - I + x + 1));
|
|
1485
|
-
for (let O = 0; O < z; O += 1) {
|
|
1486
|
-
const B = O - Math.floor(O / I) * I;
|
|
1487
|
-
S ? d.forEach((F, G) => {
|
|
1488
|
-
F.column === B && P.push(G);
|
|
1489
|
-
}) : P.push(B);
|
|
1490
|
-
}
|
|
1491
|
-
}
|
|
1492
|
-
if (c.__preventObserver__ = !0, requestAnimationFrame(() => {
|
|
1493
|
-
c.__preventObserver__ = !1;
|
|
1494
|
-
}), c.params.effect === "cards" && d.length < g + f * 2 && (P.includes(r) && P.splice(P.indexOf(r), 1), y.includes(r) && y.splice(y.indexOf(r), 1)), C && y.forEach((O) => {
|
|
1495
|
-
d[O].swiperLoopMoveDOM = !0, w.prepend(d[O]), d[O].swiperLoopMoveDOM = !1;
|
|
1496
|
-
}), E && P.forEach((O) => {
|
|
1497
|
-
d[O].swiperLoopMoveDOM = !0, w.append(d[O]), d[O].swiperLoopMoveDOM = !1;
|
|
1498
|
-
}), c.recalcSlides(), m.slidesPerView === "auto" ? c.updateSlides() : S && (y.length > 0 && C || P.length > 0 && E) && c.slides.forEach((O, B) => {
|
|
1499
|
-
c.grid.updateSlide(B, O, c.slides);
|
|
1500
|
-
}), m.watchSlidesProgress && c.updateSlidesOffset(), i) {
|
|
1501
|
-
if (y.length > 0 && C) {
|
|
1502
|
-
if (typeof e > "u") {
|
|
1503
|
-
const O = c.slidesGrid[T], F = c.slidesGrid[T + _] - O;
|
|
1504
|
-
o ? c.setTranslate(c.translate - F) : (c.slideTo(T + Math.ceil(_), 0, !1, !0), n && (c.touchEventsData.startTranslate = c.touchEventsData.startTranslate - F, c.touchEventsData.currentTranslate = c.touchEventsData.currentTranslate - F));
|
|
1505
|
-
} else if (n) {
|
|
1506
|
-
const O = S ? y.length / m.grid.rows : y.length;
|
|
1507
|
-
c.slideTo(c.activeIndex + O, 0, !1, !0), c.touchEventsData.currentTranslate = c.translate;
|
|
1508
|
-
}
|
|
1509
|
-
} else if (P.length > 0 && E)
|
|
1510
|
-
if (typeof e > "u") {
|
|
1511
|
-
const O = c.slidesGrid[T], F = c.slidesGrid[T - z] - O;
|
|
1512
|
-
o ? c.setTranslate(c.translate - F) : (c.slideTo(T - z, 0, !1, !0), n && (c.touchEventsData.startTranslate = c.touchEventsData.startTranslate - F, c.touchEventsData.currentTranslate = c.touchEventsData.currentTranslate - F));
|
|
1513
|
-
} else {
|
|
1514
|
-
const O = S ? P.length / m.grid.rows : P.length;
|
|
1515
|
-
c.slideTo(c.activeIndex - O, 0, !1, !0);
|
|
1516
|
-
}
|
|
1517
|
-
}
|
|
1518
|
-
if (c.allowSlidePrev = p, c.allowSlideNext = h, c.controller && c.controller.control && !a) {
|
|
1519
|
-
const O = {
|
|
1520
|
-
slideRealIndex: e,
|
|
1521
|
-
direction: s,
|
|
1522
|
-
setTranslate: n,
|
|
1523
|
-
activeSlideIndex: r,
|
|
1524
|
-
byController: !0
|
|
1525
|
-
};
|
|
1526
|
-
Array.isArray(c.controller.control) ? c.controller.control.forEach((B) => {
|
|
1527
|
-
!B.destroyed && B.params.loop && B.loopFix({
|
|
1528
|
-
...O,
|
|
1529
|
-
slideTo: B.params.slidesPerView === m.slidesPerView ? i : !1
|
|
1530
|
-
});
|
|
1531
|
-
}) : c.controller.control instanceof c.constructor && c.controller.control.params.loop && c.controller.control.loopFix({
|
|
1532
|
-
...O,
|
|
1533
|
-
slideTo: c.controller.control.params.slidesPerView === m.slidesPerView ? i : !1
|
|
1534
|
-
});
|
|
1535
|
-
}
|
|
1536
|
-
c.emit("loopFix");
|
|
1537
|
-
}
|
|
1538
|
-
function ts() {
|
|
1539
|
-
const t = this, {
|
|
1540
|
-
params: e,
|
|
1541
|
-
slidesEl: i
|
|
1542
|
-
} = t;
|
|
1543
|
-
if (!e.loop || !i || t.virtual && t.params.virtual.enabled) return;
|
|
1544
|
-
t.recalcSlides();
|
|
1545
|
-
const s = [];
|
|
1546
|
-
t.slides.forEach((n) => {
|
|
1547
|
-
const r = typeof n.swiperSlideIndex > "u" ? n.getAttribute("data-swiper-slide-index") * 1 : n.swiperSlideIndex;
|
|
1548
|
-
s[r] = n;
|
|
1549
|
-
}), t.slides.forEach((n) => {
|
|
1550
|
-
n.removeAttribute("data-swiper-slide-index");
|
|
1551
|
-
}), s.forEach((n) => {
|
|
1552
|
-
i.append(n);
|
|
1553
|
-
}), t.recalcSlides(), t.slideTo(t.realIndex, 0);
|
|
1554
|
-
}
|
|
1555
|
-
var is = {
|
|
1556
|
-
loopCreate: Ji,
|
|
1557
|
-
loopFix: es,
|
|
1558
|
-
loopDestroy: ts
|
|
1559
|
-
};
|
|
1560
|
-
function ss(t) {
|
|
1561
|
-
const e = this;
|
|
1562
|
-
if (!e.params.simulateTouch || e.params.watchOverflow && e.isLocked || e.params.cssMode) return;
|
|
1563
|
-
const i = e.params.touchEventsTarget === "container" ? e.el : e.wrapperEl;
|
|
1564
|
-
e.isElement && (e.__preventObserver__ = !0), i.style.cursor = "move", i.style.cursor = t ? "grabbing" : "grab", e.isElement && requestAnimationFrame(() => {
|
|
1565
|
-
e.__preventObserver__ = !1;
|
|
1566
|
-
});
|
|
1567
|
-
}
|
|
1568
|
-
function ns() {
|
|
1569
|
-
const t = this;
|
|
1570
|
-
t.params.watchOverflow && t.isLocked || t.params.cssMode || (t.isElement && (t.__preventObserver__ = !0), t[t.params.touchEventsTarget === "container" ? "el" : "wrapperEl"].style.cursor = "", t.isElement && requestAnimationFrame(() => {
|
|
1571
|
-
t.__preventObserver__ = !1;
|
|
1572
|
-
}));
|
|
1573
|
-
}
|
|
1574
|
-
var rs = {
|
|
1575
|
-
setGrabCursor: ss,
|
|
1576
|
-
unsetGrabCursor: ns
|
|
1577
|
-
};
|
|
1578
|
-
function as(t, e) {
|
|
1579
|
-
e === void 0 && (e = this);
|
|
1580
|
-
function i(s) {
|
|
1581
|
-
if (!s || s === le() || s === j()) return null;
|
|
1582
|
-
s.assignedSlot && (s = s.assignedSlot);
|
|
1583
|
-
const n = s.closest(t);
|
|
1584
|
-
return !n && !s.getRootNode ? null : n || i(s.getRootNode().host);
|
|
1585
|
-
}
|
|
1586
|
-
return i(e);
|
|
1587
|
-
}
|
|
1588
|
-
function Xe(t, e, i) {
|
|
1589
|
-
const s = j(), {
|
|
1590
|
-
params: n
|
|
1591
|
-
} = t, r = n.edgeSwipeDetection, l = n.edgeSwipeThreshold;
|
|
1592
|
-
return r && (i <= l || i >= s.innerWidth - l) ? r === "prevent" ? (e.preventDefault(), !0) : !1 : !0;
|
|
1593
|
-
}
|
|
1594
|
-
function ls(t) {
|
|
1595
|
-
const e = this, i = le();
|
|
1596
|
-
let s = t;
|
|
1597
|
-
s.originalEvent && (s = s.originalEvent);
|
|
1598
|
-
const n = e.touchEventsData;
|
|
1599
|
-
if (s.type === "pointerdown") {
|
|
1600
|
-
if (n.pointerId !== null && n.pointerId !== s.pointerId)
|
|
1601
|
-
return;
|
|
1602
|
-
n.pointerId = s.pointerId;
|
|
1603
|
-
} else s.type === "touchstart" && s.targetTouches.length === 1 && (n.touchId = s.targetTouches[0].identifier);
|
|
1604
|
-
if (s.type === "touchstart") {
|
|
1605
|
-
Xe(e, s, s.targetTouches[0].pageX);
|
|
1606
|
-
return;
|
|
1607
|
-
}
|
|
1608
|
-
const {
|
|
1609
|
-
params: r,
|
|
1610
|
-
touches: l,
|
|
1611
|
-
enabled: a
|
|
1612
|
-
} = e;
|
|
1613
|
-
if (!a || !r.simulateTouch && s.pointerType === "mouse" || e.animating && r.preventInteractionOnTransition)
|
|
1614
|
-
return;
|
|
1615
|
-
!e.animating && r.cssMode && r.loop && e.loopFix();
|
|
1616
|
-
let o = s.target;
|
|
1617
|
-
if (r.touchEventsTarget === "wrapper" && !hi(o, e.wrapperEl) || "which" in s && s.which === 3 || "button" in s && s.button > 0 || n.isTouched && n.isMoved) return;
|
|
1618
|
-
const c = !!r.noSwipingClass && r.noSwipingClass !== "", d = s.composedPath ? s.composedPath() : s.path;
|
|
1619
|
-
c && s.target && s.target.shadowRoot && d && (o = d[0]);
|
|
1620
|
-
const p = r.noSwipingSelector ? r.noSwipingSelector : `.${r.noSwipingClass}`, h = !!(s.target && s.target.shadowRoot);
|
|
1621
|
-
if (r.noSwiping && (h ? as(p, o) : o.closest(p))) {
|
|
1622
|
-
e.allowClick = !0;
|
|
1623
|
-
return;
|
|
1624
|
-
}
|
|
1625
|
-
if (r.swipeHandler && !o.closest(r.swipeHandler))
|
|
1626
|
-
return;
|
|
1627
|
-
l.currentX = s.pageX, l.currentY = s.pageY;
|
|
1628
|
-
const w = l.currentX, m = l.currentY;
|
|
1629
|
-
if (!Xe(e, s, w))
|
|
1630
|
-
return;
|
|
1631
|
-
Object.assign(n, {
|
|
1632
|
-
isTouched: !0,
|
|
1633
|
-
isMoved: !1,
|
|
1634
|
-
allowTouchCallbacks: !0,
|
|
1635
|
-
isScrolling: void 0,
|
|
1636
|
-
startMoving: void 0
|
|
1637
|
-
}), l.startX = w, l.startY = m, n.touchStartTime = Se(), e.allowClick = !0, e.updateSize(), e.swipeDirection = void 0, r.threshold > 0 && (n.allowThresholdMove = !1);
|
|
1638
|
-
let b = !0;
|
|
1639
|
-
o.matches(n.focusableElements) && (b = !1, o.nodeName === "SELECT" && (n.isTouched = !1)), i.activeElement && i.activeElement.matches(n.focusableElements) && i.activeElement !== o && (s.pointerType === "mouse" || s.pointerType !== "mouse" && !o.matches(n.focusableElements)) && i.activeElement.blur();
|
|
1640
|
-
const x = b && e.allowTouchMove && r.touchStartPreventDefault;
|
|
1641
|
-
(r.touchStartForcePreventDefault || x) && !o.isContentEditable && s.preventDefault(), r.freeMode && r.freeMode.enabled && e.freeMode && e.animating && !r.cssMode && e.freeMode.onTouchStart(), e.emit("touchStart", s);
|
|
1642
|
-
}
|
|
1643
|
-
function os(t) {
|
|
1644
|
-
const e = le(), i = this, s = i.touchEventsData, {
|
|
1645
|
-
params: n,
|
|
1646
|
-
touches: r,
|
|
1647
|
-
rtlTranslate: l,
|
|
1648
|
-
enabled: a
|
|
1649
|
-
} = i;
|
|
1650
|
-
if (!a || !n.simulateTouch && t.pointerType === "mouse") return;
|
|
1651
|
-
let o = t;
|
|
1652
|
-
if (o.originalEvent && (o = o.originalEvent), o.type === "pointermove" && (s.touchId !== null || o.pointerId !== s.pointerId))
|
|
1653
|
-
return;
|
|
1654
|
-
let c;
|
|
1655
|
-
if (o.type === "touchmove") {
|
|
1656
|
-
if (c = [...o.changedTouches].find((y) => y.identifier === s.touchId), !c || c.identifier !== s.touchId) return;
|
|
1657
|
-
} else
|
|
1658
|
-
c = o;
|
|
1659
|
-
if (!s.isTouched) {
|
|
1660
|
-
s.startMoving && s.isScrolling && i.emit("touchMoveOpposite", o);
|
|
1661
|
-
return;
|
|
1662
|
-
}
|
|
1663
|
-
const d = c.pageX, p = c.pageY;
|
|
1664
|
-
if (o.preventedByNestedSwiper) {
|
|
1665
|
-
r.startX = d, r.startY = p;
|
|
1666
|
-
return;
|
|
1667
|
-
}
|
|
1668
|
-
if (!i.allowTouchMove) {
|
|
1669
|
-
o.target.matches(s.focusableElements) || (i.allowClick = !1), s.isTouched && (Object.assign(r, {
|
|
1670
|
-
startX: d,
|
|
1671
|
-
startY: p,
|
|
1672
|
-
currentX: d,
|
|
1673
|
-
currentY: p
|
|
1674
|
-
}), s.touchStartTime = Se());
|
|
1675
|
-
return;
|
|
1676
|
-
}
|
|
1677
|
-
if (n.touchReleaseOnEdges && !n.loop)
|
|
1678
|
-
if (i.isVertical()) {
|
|
1679
|
-
if (p < r.startY && i.translate <= i.maxTranslate() || p > r.startY && i.translate >= i.minTranslate()) {
|
|
1680
|
-
s.isTouched = !1, s.isMoved = !1;
|
|
1681
|
-
return;
|
|
1682
|
-
}
|
|
1683
|
-
} else {
|
|
1684
|
-
if (l && (d > r.startX && -i.translate <= i.maxTranslate() || d < r.startX && -i.translate >= i.minTranslate()))
|
|
1685
|
-
return;
|
|
1686
|
-
if (!l && (d < r.startX && i.translate <= i.maxTranslate() || d > r.startX && i.translate >= i.minTranslate()))
|
|
1687
|
-
return;
|
|
1688
|
-
}
|
|
1689
|
-
if (e.activeElement && e.activeElement.matches(s.focusableElements) && e.activeElement !== o.target && o.pointerType !== "mouse" && e.activeElement.blur(), e.activeElement && o.target === e.activeElement && o.target.matches(s.focusableElements)) {
|
|
1690
|
-
s.isMoved = !0, i.allowClick = !1;
|
|
1691
|
-
return;
|
|
1692
|
-
}
|
|
1693
|
-
s.allowTouchCallbacks && i.emit("touchMove", o), r.previousX = r.currentX, r.previousY = r.currentY, r.currentX = d, r.currentY = p;
|
|
1694
|
-
const h = r.currentX - r.startX, w = r.currentY - r.startY;
|
|
1695
|
-
if (i.params.threshold && Math.sqrt(h ** 2 + w ** 2) < i.params.threshold) return;
|
|
1696
|
-
if (typeof s.isScrolling > "u") {
|
|
1697
|
-
let y;
|
|
1698
|
-
i.isHorizontal() && r.currentY === r.startY || i.isVertical() && r.currentX === r.startX ? s.isScrolling = !1 : h * h + w * w >= 25 && (y = Math.atan2(Math.abs(w), Math.abs(h)) * 180 / Math.PI, s.isScrolling = i.isHorizontal() ? y > n.touchAngle : 90 - y > n.touchAngle);
|
|
1699
|
-
}
|
|
1700
|
-
if (s.isScrolling && i.emit("touchMoveOpposite", o), typeof s.startMoving > "u" && (r.currentX !== r.startX || r.currentY !== r.startY) && (s.startMoving = !0), s.isScrolling || o.type === "touchmove" && s.preventTouchMoveFromPointerMove) {
|
|
1701
|
-
s.isTouched = !1;
|
|
1702
|
-
return;
|
|
1703
|
-
}
|
|
1704
|
-
if (!s.startMoving)
|
|
1705
|
-
return;
|
|
1706
|
-
i.allowClick = !1, !n.cssMode && o.cancelable && o.preventDefault(), n.touchMoveStopPropagation && !n.nested && o.stopPropagation();
|
|
1707
|
-
let m = i.isHorizontal() ? h : w, b = i.isHorizontal() ? r.currentX - r.previousX : r.currentY - r.previousY;
|
|
1708
|
-
n.oneWayMovement && (m = Math.abs(m) * (l ? 1 : -1), b = Math.abs(b) * (l ? 1 : -1)), r.diff = m, m *= n.touchRatio, l && (m = -m, b = -b);
|
|
1709
|
-
const x = i.touchesDirection;
|
|
1710
|
-
i.swipeDirection = m > 0 ? "prev" : "next", i.touchesDirection = b > 0 ? "prev" : "next";
|
|
1711
|
-
const g = i.params.loop && !n.cssMode, u = i.touchesDirection === "next" && i.allowSlideNext || i.touchesDirection === "prev" && i.allowSlidePrev;
|
|
1712
|
-
if (!s.isMoved) {
|
|
1713
|
-
if (g && u && i.loopFix({
|
|
1714
|
-
direction: i.swipeDirection
|
|
1715
|
-
}), s.startTranslate = i.getTranslate(), i.setTransition(0), i.animating) {
|
|
1716
|
-
const y = new window.CustomEvent("transitionend", {
|
|
1717
|
-
bubbles: !0,
|
|
1718
|
-
cancelable: !0,
|
|
1719
|
-
detail: {
|
|
1720
|
-
bySwiperTouchMove: !0
|
|
1721
|
-
}
|
|
1722
|
-
});
|
|
1723
|
-
i.wrapperEl.dispatchEvent(y);
|
|
1724
|
-
}
|
|
1725
|
-
s.allowMomentumBounce = !1, n.grabCursor && (i.allowSlideNext === !0 || i.allowSlidePrev === !0) && i.setGrabCursor(!0), i.emit("sliderFirstMove", o);
|
|
1726
|
-
}
|
|
1727
|
-
if ((/* @__PURE__ */ new Date()).getTime(), n._loopSwapReset !== !1 && s.isMoved && s.allowThresholdMove && x !== i.touchesDirection && g && u && Math.abs(m) >= 1) {
|
|
1728
|
-
Object.assign(r, {
|
|
1729
|
-
startX: d,
|
|
1730
|
-
startY: p,
|
|
1731
|
-
currentX: d,
|
|
1732
|
-
currentY: p,
|
|
1733
|
-
startTranslate: s.currentTranslate
|
|
1734
|
-
}), s.loopSwapReset = !0, s.startTranslate = s.currentTranslate;
|
|
1735
|
-
return;
|
|
1736
|
-
}
|
|
1737
|
-
i.emit("sliderMove", o), s.isMoved = !0, s.currentTranslate = m + s.startTranslate;
|
|
1738
|
-
let f = !0, S = n.resistanceRatio;
|
|
1739
|
-
if (n.touchReleaseOnEdges && (S = 0), m > 0 ? (g && u && s.allowThresholdMove && s.currentTranslate > (n.centeredSlides ? i.minTranslate() - i.slidesSizesGrid[i.activeIndex + 1] - (n.slidesPerView !== "auto" && i.slides.length - n.slidesPerView >= 2 ? i.slidesSizesGrid[i.activeIndex + 1] + i.params.spaceBetween : 0) - i.params.spaceBetween : i.minTranslate()) && i.loopFix({
|
|
1740
|
-
direction: "prev",
|
|
1741
|
-
setTranslate: !0,
|
|
1742
|
-
activeSlideIndex: 0
|
|
1743
|
-
}), s.currentTranslate > i.minTranslate() && (f = !1, n.resistance && (s.currentTranslate = i.minTranslate() - 1 + (-i.minTranslate() + s.startTranslate + m) ** S))) : m < 0 && (g && u && s.allowThresholdMove && s.currentTranslate < (n.centeredSlides ? i.maxTranslate() + i.slidesSizesGrid[i.slidesSizesGrid.length - 1] + i.params.spaceBetween + (n.slidesPerView !== "auto" && i.slides.length - n.slidesPerView >= 2 ? i.slidesSizesGrid[i.slidesSizesGrid.length - 1] + i.params.spaceBetween : 0) : i.maxTranslate()) && i.loopFix({
|
|
1744
|
-
direction: "next",
|
|
1745
|
-
setTranslate: !0,
|
|
1746
|
-
activeSlideIndex: i.slides.length - (n.slidesPerView === "auto" ? i.slidesPerViewDynamic() : Math.ceil(parseFloat(n.slidesPerView, 10)))
|
|
1747
|
-
}), s.currentTranslate < i.maxTranslate() && (f = !1, n.resistance && (s.currentTranslate = i.maxTranslate() + 1 - (i.maxTranslate() - s.startTranslate - m) ** S))), f && (o.preventedByNestedSwiper = !0), !i.allowSlideNext && i.swipeDirection === "next" && s.currentTranslate < s.startTranslate && (s.currentTranslate = s.startTranslate), !i.allowSlidePrev && i.swipeDirection === "prev" && s.currentTranslate > s.startTranslate && (s.currentTranslate = s.startTranslate), !i.allowSlidePrev && !i.allowSlideNext && (s.currentTranslate = s.startTranslate), n.threshold > 0)
|
|
1748
|
-
if (Math.abs(m) > n.threshold || s.allowThresholdMove) {
|
|
1749
|
-
if (!s.allowThresholdMove) {
|
|
1750
|
-
s.allowThresholdMove = !0, r.startX = r.currentX, r.startY = r.currentY, s.currentTranslate = s.startTranslate, r.diff = i.isHorizontal() ? r.currentX - r.startX : r.currentY - r.startY;
|
|
1751
|
-
return;
|
|
1752
|
-
}
|
|
1753
|
-
} else {
|
|
1754
|
-
s.currentTranslate = s.startTranslate;
|
|
1755
|
-
return;
|
|
1756
|
-
}
|
|
1757
|
-
!n.followFinger || n.cssMode || ((n.freeMode && n.freeMode.enabled && i.freeMode || n.watchSlidesProgress) && (i.updateActiveIndex(), i.updateSlidesClasses()), n.freeMode && n.freeMode.enabled && i.freeMode && i.freeMode.onTouchMove(), i.updateProgress(s.currentTranslate), i.setTranslate(s.currentTranslate));
|
|
1758
|
-
}
|
|
1759
|
-
function ds(t) {
|
|
1760
|
-
const e = this, i = e.touchEventsData;
|
|
1761
|
-
let s = t;
|
|
1762
|
-
s.originalEvent && (s = s.originalEvent);
|
|
1763
|
-
let n;
|
|
1764
|
-
if (s.type === "touchend" || s.type === "touchcancel") {
|
|
1765
|
-
if (n = [...s.changedTouches].find((y) => y.identifier === i.touchId), !n || n.identifier !== i.touchId) return;
|
|
1766
|
-
} else {
|
|
1767
|
-
if (i.touchId !== null || s.pointerId !== i.pointerId) return;
|
|
1768
|
-
n = s;
|
|
1769
|
-
}
|
|
1770
|
-
if (["pointercancel", "pointerout", "pointerleave", "contextmenu"].includes(s.type) && !(["pointercancel", "contextmenu"].includes(s.type) && (e.browser.isSafari || e.browser.isWebView)))
|
|
1771
|
-
return;
|
|
1772
|
-
i.pointerId = null, i.touchId = null;
|
|
1773
|
-
const {
|
|
1774
|
-
params: l,
|
|
1775
|
-
touches: a,
|
|
1776
|
-
rtlTranslate: o,
|
|
1777
|
-
slidesGrid: c,
|
|
1778
|
-
enabled: d
|
|
1779
|
-
} = e;
|
|
1780
|
-
if (!d || !l.simulateTouch && s.pointerType === "mouse") return;
|
|
1781
|
-
if (i.allowTouchCallbacks && e.emit("touchEnd", s), i.allowTouchCallbacks = !1, !i.isTouched) {
|
|
1782
|
-
i.isMoved && l.grabCursor && e.setGrabCursor(!1), i.isMoved = !1, i.startMoving = !1;
|
|
1783
|
-
return;
|
|
1784
|
-
}
|
|
1785
|
-
l.grabCursor && i.isMoved && i.isTouched && (e.allowSlideNext === !0 || e.allowSlidePrev === !0) && e.setGrabCursor(!1);
|
|
1786
|
-
const p = Se(), h = p - i.touchStartTime;
|
|
1787
|
-
if (e.allowClick) {
|
|
1788
|
-
const y = s.path || s.composedPath && s.composedPath();
|
|
1789
|
-
e.updateClickedSlide(y && y[0] || s.target, y), e.emit("tap click", s), h < 300 && p - i.lastClickTime < 300 && e.emit("doubleTap doubleClick", s);
|
|
1790
|
-
}
|
|
1791
|
-
if (i.lastClickTime = Se(), it(() => {
|
|
1792
|
-
e.destroyed || (e.allowClick = !0);
|
|
1793
|
-
}), !i.isTouched || !i.isMoved || !e.swipeDirection || a.diff === 0 && !i.loopSwapReset || i.currentTranslate === i.startTranslate && !i.loopSwapReset) {
|
|
1794
|
-
i.isTouched = !1, i.isMoved = !1, i.startMoving = !1;
|
|
1795
|
-
return;
|
|
1796
|
-
}
|
|
1797
|
-
i.isTouched = !1, i.isMoved = !1, i.startMoving = !1;
|
|
1798
|
-
let w;
|
|
1799
|
-
if (l.followFinger ? w = o ? e.translate : -e.translate : w = -i.currentTranslate, l.cssMode)
|
|
1800
|
-
return;
|
|
1801
|
-
if (l.freeMode && l.freeMode.enabled) {
|
|
1802
|
-
e.freeMode.onTouchEnd({
|
|
1803
|
-
currentPos: w
|
|
1804
|
-
});
|
|
1805
|
-
return;
|
|
1806
|
-
}
|
|
1807
|
-
const m = w >= -e.maxTranslate() && !e.params.loop;
|
|
1808
|
-
let b = 0, x = e.slidesSizesGrid[0];
|
|
1809
|
-
for (let y = 0; y < c.length; y += y < l.slidesPerGroupSkip ? 1 : l.slidesPerGroup) {
|
|
1810
|
-
const P = y < l.slidesPerGroupSkip - 1 ? 1 : l.slidesPerGroup;
|
|
1811
|
-
typeof c[y + P] < "u" ? (m || w >= c[y] && w < c[y + P]) && (b = y, x = c[y + P] - c[y]) : (m || w >= c[y]) && (b = y, x = c[c.length - 1] - c[c.length - 2]);
|
|
1812
|
-
}
|
|
1813
|
-
let g = null, u = null;
|
|
1814
|
-
l.rewind && (e.isBeginning ? u = l.virtual && l.virtual.enabled && e.virtual ? e.virtual.slides.length - 1 : e.slides.length - 1 : e.isEnd && (g = 0));
|
|
1815
|
-
const f = (w - c[b]) / x, S = b < l.slidesPerGroupSkip - 1 ? 1 : l.slidesPerGroup;
|
|
1816
|
-
if (h > l.longSwipesMs) {
|
|
1817
|
-
if (!l.longSwipes) {
|
|
1818
|
-
e.slideTo(e.activeIndex);
|
|
1819
|
-
return;
|
|
1820
|
-
}
|
|
1821
|
-
e.swipeDirection === "next" && (f >= l.longSwipesRatio ? e.slideTo(l.rewind && e.isEnd ? g : b + S) : e.slideTo(b)), e.swipeDirection === "prev" && (f > 1 - l.longSwipesRatio ? e.slideTo(b + S) : u !== null && f < 0 && Math.abs(f) > l.longSwipesRatio ? e.slideTo(u) : e.slideTo(b));
|
|
1822
|
-
} else {
|
|
1823
|
-
if (!l.shortSwipes) {
|
|
1824
|
-
e.slideTo(e.activeIndex);
|
|
1825
|
-
return;
|
|
1826
|
-
}
|
|
1827
|
-
e.navigation && (s.target === e.navigation.nextEl || s.target === e.navigation.prevEl) ? s.target === e.navigation.nextEl ? e.slideTo(b + S) : e.slideTo(b) : (e.swipeDirection === "next" && e.slideTo(g !== null ? g : b + S), e.swipeDirection === "prev" && e.slideTo(u !== null ? u : b));
|
|
1828
|
-
}
|
|
1829
|
-
}
|
|
1830
|
-
function Ye() {
|
|
1831
|
-
const t = this, {
|
|
1832
|
-
params: e,
|
|
1833
|
-
el: i
|
|
1834
|
-
} = t;
|
|
1835
|
-
if (i && i.offsetWidth === 0) return;
|
|
1836
|
-
e.breakpoints && t.setBreakpoint();
|
|
1837
|
-
const {
|
|
1838
|
-
allowSlideNext: s,
|
|
1839
|
-
allowSlidePrev: n,
|
|
1840
|
-
snapGrid: r
|
|
1841
|
-
} = t, l = t.virtual && t.params.virtual.enabled;
|
|
1842
|
-
t.allowSlideNext = !0, t.allowSlidePrev = !0, t.updateSize(), t.updateSlides(), t.updateSlidesClasses();
|
|
1843
|
-
const a = l && e.loop;
|
|
1844
|
-
(e.slidesPerView === "auto" || e.slidesPerView > 1) && t.isEnd && !t.isBeginning && !t.params.centeredSlides && !a ? t.slideTo(t.slides.length - 1, 0, !1, !0) : t.params.loop && !l ? t.slideToLoop(t.realIndex, 0, !1, !0) : t.slideTo(t.activeIndex, 0, !1, !0), t.autoplay && t.autoplay.running && t.autoplay.paused && (clearTimeout(t.autoplay.resizeTimeout), t.autoplay.resizeTimeout = setTimeout(() => {
|
|
1845
|
-
t.autoplay && t.autoplay.running && t.autoplay.paused && t.autoplay.resume();
|
|
1846
|
-
}, 500)), t.allowSlidePrev = n, t.allowSlideNext = s, t.params.watchOverflow && r !== t.snapGrid && t.checkOverflow();
|
|
1847
|
-
}
|
|
1848
|
-
function cs(t) {
|
|
1849
|
-
const e = this;
|
|
1850
|
-
e.enabled && (e.allowClick || (e.params.preventClicks && t.preventDefault(), e.params.preventClicksPropagation && e.animating && (t.stopPropagation(), t.stopImmediatePropagation())));
|
|
1851
|
-
}
|
|
1852
|
-
function us() {
|
|
1853
|
-
const t = this, {
|
|
1854
|
-
wrapperEl: e,
|
|
1855
|
-
rtlTranslate: i,
|
|
1856
|
-
enabled: s
|
|
1857
|
-
} = t;
|
|
1858
|
-
if (!s) return;
|
|
1859
|
-
t.previousTranslate = t.translate, t.isHorizontal() ? t.translate = -e.scrollLeft : t.translate = -e.scrollTop, t.translate === 0 && (t.translate = 0), t.updateActiveIndex(), t.updateSlidesClasses();
|
|
1860
|
-
let n;
|
|
1861
|
-
const r = t.maxTranslate() - t.minTranslate();
|
|
1862
|
-
r === 0 ? n = 0 : n = (t.translate - t.minTranslate()) / r, n !== t.progress && t.updateProgress(i ? -t.translate : t.translate), t.emit("setTranslate", t.translate, !1);
|
|
1863
|
-
}
|
|
1864
|
-
function fs(t) {
|
|
1865
|
-
const e = this;
|
|
1866
|
-
we(e, t.target), !(e.params.cssMode || e.params.slidesPerView !== "auto" && !e.params.autoHeight) && e.update();
|
|
1867
|
-
}
|
|
1868
|
-
function ps() {
|
|
1869
|
-
const t = this;
|
|
1870
|
-
t.documentTouchHandlerProceeded || (t.documentTouchHandlerProceeded = !0, t.params.touchReleaseOnEdges && (t.el.style.touchAction = "auto"));
|
|
1871
|
-
}
|
|
1872
|
-
const dt = (t, e) => {
|
|
1873
|
-
const i = le(), {
|
|
1874
|
-
params: s,
|
|
1875
|
-
el: n,
|
|
1876
|
-
wrapperEl: r,
|
|
1877
|
-
device: l
|
|
1878
|
-
} = t, a = !!s.nested, o = e === "on" ? "addEventListener" : "removeEventListener", c = e;
|
|
1879
|
-
!n || typeof n == "string" || (i[o]("touchstart", t.onDocumentTouchStart, {
|
|
1880
|
-
passive: !1,
|
|
1881
|
-
capture: a
|
|
1882
|
-
}), n[o]("touchstart", t.onTouchStart, {
|
|
1883
|
-
passive: !1
|
|
1884
|
-
}), n[o]("pointerdown", t.onTouchStart, {
|
|
1885
|
-
passive: !1
|
|
1886
|
-
}), i[o]("touchmove", t.onTouchMove, {
|
|
1887
|
-
passive: !1,
|
|
1888
|
-
capture: a
|
|
1889
|
-
}), i[o]("pointermove", t.onTouchMove, {
|
|
1890
|
-
passive: !1,
|
|
1891
|
-
capture: a
|
|
1892
|
-
}), i[o]("touchend", t.onTouchEnd, {
|
|
1893
|
-
passive: !0
|
|
1894
|
-
}), i[o]("pointerup", t.onTouchEnd, {
|
|
1895
|
-
passive: !0
|
|
1896
|
-
}), i[o]("pointercancel", t.onTouchEnd, {
|
|
1897
|
-
passive: !0
|
|
1898
|
-
}), i[o]("touchcancel", t.onTouchEnd, {
|
|
1899
|
-
passive: !0
|
|
1900
|
-
}), i[o]("pointerout", t.onTouchEnd, {
|
|
1901
|
-
passive: !0
|
|
1902
|
-
}), i[o]("pointerleave", t.onTouchEnd, {
|
|
1903
|
-
passive: !0
|
|
1904
|
-
}), i[o]("contextmenu", t.onTouchEnd, {
|
|
1905
|
-
passive: !0
|
|
1906
|
-
}), (s.preventClicks || s.preventClicksPropagation) && n[o]("click", t.onClick, !0), s.cssMode && r[o]("scroll", t.onScroll), s.updateOnWindowResize ? t[c](l.ios || l.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", Ye, !0) : t[c]("observerUpdate", Ye, !0), n[o]("load", t.onLoad, {
|
|
1907
|
-
capture: !0
|
|
1908
|
-
}));
|
|
1909
|
-
};
|
|
1910
|
-
function ms() {
|
|
1911
|
-
const t = this, {
|
|
1912
|
-
params: e
|
|
1913
|
-
} = t;
|
|
1914
|
-
t.onTouchStart = ls.bind(t), t.onTouchMove = os.bind(t), t.onTouchEnd = ds.bind(t), t.onDocumentTouchStart = ps.bind(t), e.cssMode && (t.onScroll = us.bind(t)), t.onClick = cs.bind(t), t.onLoad = fs.bind(t), dt(t, "on");
|
|
1915
|
-
}
|
|
1916
|
-
function hs() {
|
|
1917
|
-
dt(this, "off");
|
|
1918
|
-
}
|
|
1919
|
-
var gs = {
|
|
1920
|
-
attachEvents: ms,
|
|
1921
|
-
detachEvents: hs
|
|
1922
|
-
};
|
|
1923
|
-
const Ue = (t, e) => t.grid && e.grid && e.grid.rows > 1;
|
|
1924
|
-
function vs() {
|
|
1925
|
-
const t = this, {
|
|
1926
|
-
realIndex: e,
|
|
1927
|
-
initialized: i,
|
|
1928
|
-
params: s,
|
|
1929
|
-
el: n
|
|
1930
|
-
} = t, r = s.breakpoints;
|
|
1931
|
-
if (!r || r && Object.keys(r).length === 0) return;
|
|
1932
|
-
const l = le(), a = s.breakpointsBase === "window" || !s.breakpointsBase ? s.breakpointsBase : "container", o = ["window", "container"].includes(s.breakpointsBase) || !s.breakpointsBase ? t.el : l.querySelector(s.breakpointsBase), c = t.getBreakpoint(r, a, o);
|
|
1933
|
-
if (!c || t.currentBreakpoint === c) return;
|
|
1934
|
-
const p = (c in r ? r[c] : void 0) || t.originalParams, h = Ue(t, s), w = Ue(t, p), m = t.params.grabCursor, b = p.grabCursor, x = s.enabled;
|
|
1935
|
-
h && !w ? (n.classList.remove(`${s.containerModifierClass}grid`, `${s.containerModifierClass}grid-column`), t.emitContainerClasses()) : !h && w && (n.classList.add(`${s.containerModifierClass}grid`), (p.grid.fill && p.grid.fill === "column" || !p.grid.fill && s.grid.fill === "column") && n.classList.add(`${s.containerModifierClass}grid-column`), t.emitContainerClasses()), m && !b ? t.unsetGrabCursor() : !m && b && t.setGrabCursor(), ["navigation", "pagination", "scrollbar"].forEach((P) => {
|
|
1936
|
-
if (typeof p[P] > "u") return;
|
|
1937
|
-
const I = s[P] && s[P].enabled, M = p[P] && p[P].enabled;
|
|
1938
|
-
I && !M && t[P].disable(), !I && M && t[P].enable();
|
|
1939
|
-
});
|
|
1940
|
-
const g = p.direction && p.direction !== s.direction, u = s.loop && (p.slidesPerView !== s.slidesPerView || g), f = s.loop;
|
|
1941
|
-
g && i && t.changeDirection(), W(t.params, p);
|
|
1942
|
-
const S = t.params.enabled, y = t.params.loop;
|
|
1943
|
-
Object.assign(t, {
|
|
1944
|
-
allowTouchMove: t.params.allowTouchMove,
|
|
1945
|
-
allowSlideNext: t.params.allowSlideNext,
|
|
1946
|
-
allowSlidePrev: t.params.allowSlidePrev
|
|
1947
|
-
}), x && !S ? t.disable() : !x && S && t.enable(), t.currentBreakpoint = c, t.emit("_beforeBreakpoint", p), i && (u ? (t.loopDestroy(), t.loopCreate(e), t.updateSlides()) : !f && y ? (t.loopCreate(e), t.updateSlides()) : f && !y && t.loopDestroy()), t.emit("breakpoint", p);
|
|
1948
|
-
}
|
|
1949
|
-
function ws(t, e, i) {
|
|
1950
|
-
if (e === void 0 && (e = "window"), !t || e === "container" && !i) return;
|
|
1951
|
-
let s = !1;
|
|
1952
|
-
const n = j(), r = e === "window" ? n.innerHeight : i.clientHeight, l = Object.keys(t).map((a) => {
|
|
1953
|
-
if (typeof a == "string" && a.indexOf("@") === 0) {
|
|
1954
|
-
const o = parseFloat(a.substr(1));
|
|
1955
|
-
return {
|
|
1956
|
-
value: r * o,
|
|
1957
|
-
point: a
|
|
1958
|
-
};
|
|
1959
|
-
}
|
|
1960
|
-
return {
|
|
1961
|
-
value: a,
|
|
1962
|
-
point: a
|
|
1963
|
-
};
|
|
1964
|
-
});
|
|
1965
|
-
l.sort((a, o) => parseInt(a.value, 10) - parseInt(o.value, 10));
|
|
1966
|
-
for (let a = 0; a < l.length; a += 1) {
|
|
1967
|
-
const {
|
|
1968
|
-
point: o,
|
|
1969
|
-
value: c
|
|
1970
|
-
} = l[a];
|
|
1971
|
-
e === "window" ? n.matchMedia(`(min-width: ${c}px)`).matches && (s = o) : c <= i.clientWidth && (s = o);
|
|
1972
|
-
}
|
|
1973
|
-
return s || "max";
|
|
1974
|
-
}
|
|
1975
|
-
var Ss = {
|
|
1976
|
-
setBreakpoint: vs,
|
|
1977
|
-
getBreakpoint: ws
|
|
1978
|
-
};
|
|
1979
|
-
function bs(t, e) {
|
|
1980
|
-
const i = [];
|
|
1981
|
-
return t.forEach((s) => {
|
|
1982
|
-
typeof s == "object" ? Object.keys(s).forEach((n) => {
|
|
1983
|
-
s[n] && i.push(e + n);
|
|
1984
|
-
}) : typeof s == "string" && i.push(e + s);
|
|
1985
|
-
}), i;
|
|
1986
|
-
}
|
|
1987
|
-
function ys() {
|
|
1988
|
-
const t = this, {
|
|
1989
|
-
classNames: e,
|
|
1990
|
-
params: i,
|
|
1991
|
-
rtl: s,
|
|
1992
|
-
el: n,
|
|
1993
|
-
device: r
|
|
1994
|
-
} = t, l = bs(["initialized", i.direction, {
|
|
1995
|
-
"free-mode": t.params.freeMode && i.freeMode.enabled
|
|
1996
|
-
}, {
|
|
1997
|
-
autoheight: i.autoHeight
|
|
1998
|
-
}, {
|
|
1999
|
-
rtl: s
|
|
2000
|
-
}, {
|
|
2001
|
-
grid: i.grid && i.grid.rows > 1
|
|
2002
|
-
}, {
|
|
2003
|
-
"grid-column": i.grid && i.grid.rows > 1 && i.grid.fill === "column"
|
|
2004
|
-
}, {
|
|
2005
|
-
android: r.android
|
|
2006
|
-
}, {
|
|
2007
|
-
ios: r.ios
|
|
2008
|
-
}, {
|
|
2009
|
-
"css-mode": i.cssMode
|
|
2010
|
-
}, {
|
|
2011
|
-
centered: i.cssMode && i.centeredSlides
|
|
2012
|
-
}, {
|
|
2013
|
-
"watch-progress": i.watchSlidesProgress
|
|
2014
|
-
}], i.containerModifierClass);
|
|
2015
|
-
e.push(...l), n.classList.add(...e), t.emitContainerClasses();
|
|
2016
|
-
}
|
|
2017
|
-
function xs() {
|
|
2018
|
-
const t = this, {
|
|
2019
|
-
el: e,
|
|
2020
|
-
classNames: i
|
|
2021
|
-
} = t;
|
|
2022
|
-
!e || typeof e == "string" || (e.classList.remove(...i), t.emitContainerClasses());
|
|
2023
|
-
}
|
|
2024
|
-
var Ts = {
|
|
2025
|
-
addClasses: ys,
|
|
2026
|
-
removeClasses: xs
|
|
2027
|
-
};
|
|
2028
|
-
function Es() {
|
|
2029
|
-
const t = this, {
|
|
2030
|
-
isLocked: e,
|
|
2031
|
-
params: i
|
|
2032
|
-
} = t, {
|
|
2033
|
-
slidesOffsetBefore: s
|
|
2034
|
-
} = i;
|
|
2035
|
-
if (s) {
|
|
2036
|
-
const n = t.slides.length - 1, r = t.slidesGrid[n] + t.slidesSizesGrid[n] + s * 2;
|
|
2037
|
-
t.isLocked = t.size > r;
|
|
2038
|
-
} else
|
|
2039
|
-
t.isLocked = t.snapGrid.length === 1;
|
|
2040
|
-
i.allowSlideNext === !0 && (t.allowSlideNext = !t.isLocked), i.allowSlidePrev === !0 && (t.allowSlidePrev = !t.isLocked), e && e !== t.isLocked && (t.isEnd = !1), e !== t.isLocked && t.emit(t.isLocked ? "lock" : "unlock");
|
|
2041
|
-
}
|
|
2042
|
-
var Cs = {
|
|
2043
|
-
checkOverflow: Es
|
|
2044
|
-
}, De = {
|
|
2045
|
-
init: !0,
|
|
2046
|
-
direction: "horizontal",
|
|
2047
|
-
oneWayMovement: !1,
|
|
2048
|
-
swiperElementNodeName: "SWIPER-CONTAINER",
|
|
2049
|
-
touchEventsTarget: "wrapper",
|
|
2050
|
-
initialSlide: 0,
|
|
2051
|
-
speed: 300,
|
|
2052
|
-
cssMode: !1,
|
|
2053
|
-
updateOnWindowResize: !0,
|
|
2054
|
-
resizeObserver: !0,
|
|
2055
|
-
nested: !1,
|
|
2056
|
-
createElements: !1,
|
|
2057
|
-
eventsPrefix: "swiper",
|
|
2058
|
-
enabled: !0,
|
|
2059
|
-
focusableElements: "input, select, option, textarea, button, video, label",
|
|
2060
|
-
// Overrides
|
|
2061
|
-
width: null,
|
|
2062
|
-
height: null,
|
|
2063
|
-
//
|
|
2064
|
-
preventInteractionOnTransition: !1,
|
|
2065
|
-
// ssr
|
|
2066
|
-
userAgent: null,
|
|
2067
|
-
url: null,
|
|
2068
|
-
// To support iOS's swipe-to-go-back gesture (when being used in-app).
|
|
2069
|
-
edgeSwipeDetection: !1,
|
|
2070
|
-
edgeSwipeThreshold: 20,
|
|
2071
|
-
// Autoheight
|
|
2072
|
-
autoHeight: !1,
|
|
2073
|
-
// Set wrapper width
|
|
2074
|
-
setWrapperSize: !1,
|
|
2075
|
-
// Virtual Translate
|
|
2076
|
-
virtualTranslate: !1,
|
|
2077
|
-
// Effects
|
|
2078
|
-
effect: "slide",
|
|
2079
|
-
// 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip'
|
|
2080
|
-
// Breakpoints
|
|
2081
|
-
breakpoints: void 0,
|
|
2082
|
-
breakpointsBase: "window",
|
|
2083
|
-
// Slides grid
|
|
2084
|
-
spaceBetween: 0,
|
|
2085
|
-
slidesPerView: 1,
|
|
2086
|
-
slidesPerGroup: 1,
|
|
2087
|
-
slidesPerGroupSkip: 0,
|
|
2088
|
-
slidesPerGroupAuto: !1,
|
|
2089
|
-
centeredSlides: !1,
|
|
2090
|
-
centeredSlidesBounds: !1,
|
|
2091
|
-
slidesOffsetBefore: 0,
|
|
2092
|
-
// in px
|
|
2093
|
-
slidesOffsetAfter: 0,
|
|
2094
|
-
// in px
|
|
2095
|
-
normalizeSlideIndex: !0,
|
|
2096
|
-
centerInsufficientSlides: !1,
|
|
2097
|
-
// Disable swiper and hide navigation when container not overflow
|
|
2098
|
-
watchOverflow: !0,
|
|
2099
|
-
// Round length
|
|
2100
|
-
roundLengths: !1,
|
|
2101
|
-
// Touches
|
|
2102
|
-
touchRatio: 1,
|
|
2103
|
-
touchAngle: 45,
|
|
2104
|
-
simulateTouch: !0,
|
|
2105
|
-
shortSwipes: !0,
|
|
2106
|
-
longSwipes: !0,
|
|
2107
|
-
longSwipesRatio: 0.5,
|
|
2108
|
-
longSwipesMs: 300,
|
|
2109
|
-
followFinger: !0,
|
|
2110
|
-
allowTouchMove: !0,
|
|
2111
|
-
threshold: 5,
|
|
2112
|
-
touchMoveStopPropagation: !1,
|
|
2113
|
-
touchStartPreventDefault: !0,
|
|
2114
|
-
touchStartForcePreventDefault: !1,
|
|
2115
|
-
touchReleaseOnEdges: !1,
|
|
2116
|
-
// Unique Navigation Elements
|
|
2117
|
-
uniqueNavElements: !0,
|
|
2118
|
-
// Resistance
|
|
2119
|
-
resistance: !0,
|
|
2120
|
-
resistanceRatio: 0.85,
|
|
2121
|
-
// Progress
|
|
2122
|
-
watchSlidesProgress: !1,
|
|
2123
|
-
// Cursor
|
|
2124
|
-
grabCursor: !1,
|
|
2125
|
-
// Clicks
|
|
2126
|
-
preventClicks: !0,
|
|
2127
|
-
preventClicksPropagation: !0,
|
|
2128
|
-
slideToClickedSlide: !1,
|
|
2129
|
-
// loop
|
|
2130
|
-
loop: !1,
|
|
2131
|
-
loopAddBlankSlides: !0,
|
|
2132
|
-
loopAdditionalSlides: 0,
|
|
2133
|
-
loopPreventsSliding: !0,
|
|
2134
|
-
// rewind
|
|
2135
|
-
rewind: !1,
|
|
2136
|
-
// Swiping/no swiping
|
|
2137
|
-
allowSlidePrev: !0,
|
|
2138
|
-
allowSlideNext: !0,
|
|
2139
|
-
swipeHandler: null,
|
|
2140
|
-
// '.swipe-handler',
|
|
2141
|
-
noSwiping: !0,
|
|
2142
|
-
noSwipingClass: "swiper-no-swiping",
|
|
2143
|
-
noSwipingSelector: null,
|
|
2144
|
-
// Passive Listeners
|
|
2145
|
-
passiveListeners: !0,
|
|
2146
|
-
maxBackfaceHiddenSlides: 10,
|
|
2147
|
-
// NS
|
|
2148
|
-
containerModifierClass: "swiper-",
|
|
2149
|
-
// NEW
|
|
2150
|
-
slideClass: "swiper-slide",
|
|
2151
|
-
slideBlankClass: "swiper-slide-blank",
|
|
2152
|
-
slideActiveClass: "swiper-slide-active",
|
|
2153
|
-
slideVisibleClass: "swiper-slide-visible",
|
|
2154
|
-
slideFullyVisibleClass: "swiper-slide-fully-visible",
|
|
2155
|
-
slideNextClass: "swiper-slide-next",
|
|
2156
|
-
slidePrevClass: "swiper-slide-prev",
|
|
2157
|
-
wrapperClass: "swiper-wrapper",
|
|
2158
|
-
lazyPreloaderClass: "swiper-lazy-preloader",
|
|
2159
|
-
lazyPreloadPrevNext: 0,
|
|
2160
|
-
// Callbacks
|
|
2161
|
-
runCallbacksOnInit: !0,
|
|
2162
|
-
// Internals
|
|
2163
|
-
_emitClasses: !1
|
|
2164
|
-
};
|
|
2165
|
-
function Ps(t, e) {
|
|
2166
|
-
return function(s) {
|
|
2167
|
-
s === void 0 && (s = {});
|
|
2168
|
-
const n = Object.keys(s)[0], r = s[n];
|
|
2169
|
-
if (typeof r != "object" || r === null) {
|
|
2170
|
-
W(e, s);
|
|
2171
|
-
return;
|
|
2172
|
-
}
|
|
2173
|
-
if (t[n] === !0 && (t[n] = {
|
|
2174
|
-
enabled: !0
|
|
2175
|
-
}), n === "navigation" && t[n] && t[n].enabled && !t[n].prevEl && !t[n].nextEl && (t[n].auto = !0), ["pagination", "scrollbar"].indexOf(n) >= 0 && t[n] && t[n].enabled && !t[n].el && (t[n].auto = !0), !(n in t && "enabled" in r)) {
|
|
2176
|
-
W(e, s);
|
|
2177
|
-
return;
|
|
2178
|
-
}
|
|
2179
|
-
typeof t[n] == "object" && !("enabled" in t[n]) && (t[n].enabled = !0), t[n] || (t[n] = {
|
|
2180
|
-
enabled: !1
|
|
2181
|
-
}), W(e, s);
|
|
2182
|
-
};
|
|
2183
|
-
}
|
|
2184
|
-
const _e = {
|
|
2185
|
-
eventsEmitter: Ti,
|
|
2186
|
-
update: Ai,
|
|
2187
|
-
translate: Vi,
|
|
2188
|
-
transition: ji,
|
|
2189
|
-
slide: Qi,
|
|
2190
|
-
loop: is,
|
|
2191
|
-
grabCursor: rs,
|
|
2192
|
-
events: gs,
|
|
2193
|
-
breakpoints: Ss,
|
|
2194
|
-
checkOverflow: Cs,
|
|
2195
|
-
classes: Ts
|
|
2196
|
-
}, Oe = {};
|
|
2197
|
-
let He = class ee {
|
|
2198
|
-
constructor() {
|
|
2199
|
-
let e, i;
|
|
2200
|
-
for (var s = arguments.length, n = new Array(s), r = 0; r < s; r++)
|
|
2201
|
-
n[r] = arguments[r];
|
|
2202
|
-
n.length === 1 && n[0].constructor && Object.prototype.toString.call(n[0]).slice(8, -1) === "Object" ? i = n[0] : [e, i] = n, i || (i = {}), i = W({}, i), e && !i.el && (i.el = e);
|
|
2203
|
-
const l = le();
|
|
2204
|
-
if (i.el && typeof i.el == "string" && l.querySelectorAll(i.el).length > 1) {
|
|
2205
|
-
const d = [];
|
|
2206
|
-
return l.querySelectorAll(i.el).forEach((p) => {
|
|
2207
|
-
const h = W({}, i, {
|
|
2208
|
-
el: p
|
|
2209
|
-
});
|
|
2210
|
-
d.push(new ee(h));
|
|
2211
|
-
}), d;
|
|
2212
|
-
}
|
|
2213
|
-
const a = this;
|
|
2214
|
-
a.__swiper__ = !0, a.support = rt(), a.device = at({
|
|
2215
|
-
userAgent: i.userAgent
|
|
2216
|
-
}), a.browser = lt(), a.eventsListeners = {}, a.eventsAnyListeners = [], a.modules = [...a.__modules__], i.modules && Array.isArray(i.modules) && a.modules.push(...i.modules);
|
|
2217
|
-
const o = {};
|
|
2218
|
-
a.modules.forEach((d) => {
|
|
2219
|
-
d({
|
|
2220
|
-
params: i,
|
|
2221
|
-
swiper: a,
|
|
2222
|
-
extendParams: Ps(i, o),
|
|
2223
|
-
on: a.on.bind(a),
|
|
2224
|
-
once: a.once.bind(a),
|
|
2225
|
-
off: a.off.bind(a),
|
|
2226
|
-
emit: a.emit.bind(a)
|
|
2227
|
-
});
|
|
2228
|
-
});
|
|
2229
|
-
const c = W({}, De, o);
|
|
2230
|
-
return a.params = W({}, c, Oe, i), a.originalParams = W({}, a.params), a.passedParams = W({}, i), a.params && a.params.on && Object.keys(a.params.on).forEach((d) => {
|
|
2231
|
-
a.on(d, a.params.on[d]);
|
|
2232
|
-
}), a.params && a.params.onAny && a.onAny(a.params.onAny), Object.assign(a, {
|
|
2233
|
-
enabled: a.params.enabled,
|
|
2234
|
-
el: e,
|
|
2235
|
-
// Classes
|
|
2236
|
-
classNames: [],
|
|
2237
|
-
// Slides
|
|
2238
|
-
slides: [],
|
|
2239
|
-
slidesGrid: [],
|
|
2240
|
-
snapGrid: [],
|
|
2241
|
-
slidesSizesGrid: [],
|
|
2242
|
-
// isDirection
|
|
2243
|
-
isHorizontal() {
|
|
2244
|
-
return a.params.direction === "horizontal";
|
|
2245
|
-
},
|
|
2246
|
-
isVertical() {
|
|
2247
|
-
return a.params.direction === "vertical";
|
|
2248
|
-
},
|
|
2249
|
-
// Indexes
|
|
2250
|
-
activeIndex: 0,
|
|
2251
|
-
realIndex: 0,
|
|
2252
|
-
//
|
|
2253
|
-
isBeginning: !0,
|
|
2254
|
-
isEnd: !1,
|
|
2255
|
-
// Props
|
|
2256
|
-
translate: 0,
|
|
2257
|
-
previousTranslate: 0,
|
|
2258
|
-
progress: 0,
|
|
2259
|
-
velocity: 0,
|
|
2260
|
-
animating: !1,
|
|
2261
|
-
cssOverflowAdjustment() {
|
|
2262
|
-
return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;
|
|
2263
|
-
},
|
|
2264
|
-
// Locks
|
|
2265
|
-
allowSlideNext: a.params.allowSlideNext,
|
|
2266
|
-
allowSlidePrev: a.params.allowSlidePrev,
|
|
2267
|
-
// Touch Events
|
|
2268
|
-
touchEventsData: {
|
|
2269
|
-
isTouched: void 0,
|
|
2270
|
-
isMoved: void 0,
|
|
2271
|
-
allowTouchCallbacks: void 0,
|
|
2272
|
-
touchStartTime: void 0,
|
|
2273
|
-
isScrolling: void 0,
|
|
2274
|
-
currentTranslate: void 0,
|
|
2275
|
-
startTranslate: void 0,
|
|
2276
|
-
allowThresholdMove: void 0,
|
|
2277
|
-
// Form elements to match
|
|
2278
|
-
focusableElements: a.params.focusableElements,
|
|
2279
|
-
// Last click time
|
|
2280
|
-
lastClickTime: 0,
|
|
2281
|
-
clickTimeout: void 0,
|
|
2282
|
-
// Velocities
|
|
2283
|
-
velocities: [],
|
|
2284
|
-
allowMomentumBounce: void 0,
|
|
2285
|
-
startMoving: void 0,
|
|
2286
|
-
pointerId: null,
|
|
2287
|
-
touchId: null
|
|
2288
|
-
},
|
|
2289
|
-
// Clicks
|
|
2290
|
-
allowClick: !0,
|
|
2291
|
-
// Touches
|
|
2292
|
-
allowTouchMove: a.params.allowTouchMove,
|
|
2293
|
-
touches: {
|
|
2294
|
-
startX: 0,
|
|
2295
|
-
startY: 0,
|
|
2296
|
-
currentX: 0,
|
|
2297
|
-
currentY: 0,
|
|
2298
|
-
diff: 0
|
|
2299
|
-
},
|
|
2300
|
-
// Images
|
|
2301
|
-
imagesToLoad: [],
|
|
2302
|
-
imagesLoaded: 0
|
|
2303
|
-
}), a.emit("_swiper"), a.params.init && a.init(), a;
|
|
2304
|
-
}
|
|
2305
|
-
getDirectionLabel(e) {
|
|
2306
|
-
return this.isHorizontal() ? e : {
|
|
2307
|
-
width: "height",
|
|
2308
|
-
"margin-top": "margin-left",
|
|
2309
|
-
"margin-bottom ": "margin-right",
|
|
2310
|
-
"margin-left": "margin-top",
|
|
2311
|
-
"margin-right": "margin-bottom",
|
|
2312
|
-
"padding-left": "padding-top",
|
|
2313
|
-
"padding-right": "padding-bottom",
|
|
2314
|
-
marginRight: "marginBottom"
|
|
2315
|
-
}[e];
|
|
2316
|
-
}
|
|
2317
|
-
getSlideIndex(e) {
|
|
2318
|
-
const {
|
|
2319
|
-
slidesEl: i,
|
|
2320
|
-
params: s
|
|
2321
|
-
} = this, n = Q(i, `.${s.slideClass}, swiper-slide`), r = xe(n[0]);
|
|
2322
|
-
return xe(e) - r;
|
|
2323
|
-
}
|
|
2324
|
-
getSlideIndexByData(e) {
|
|
2325
|
-
return this.getSlideIndex(this.slides.find((i) => i.getAttribute("data-swiper-slide-index") * 1 === e));
|
|
2326
|
-
}
|
|
2327
|
-
getSlideIndexWhenGrid(e) {
|
|
2328
|
-
return this.grid && this.params.grid && this.params.grid.rows > 1 && (this.params.grid.fill === "column" ? e = Math.floor(e / this.params.grid.rows) : this.params.grid.fill === "row" && (e = e % Math.ceil(this.slides.length / this.params.grid.rows))), e;
|
|
2329
|
-
}
|
|
2330
|
-
recalcSlides() {
|
|
2331
|
-
const e = this, {
|
|
2332
|
-
slidesEl: i,
|
|
2333
|
-
params: s
|
|
2334
|
-
} = e;
|
|
2335
|
-
e.slides = Q(i, `.${s.slideClass}, swiper-slide`);
|
|
2336
|
-
}
|
|
2337
|
-
enable() {
|
|
2338
|
-
const e = this;
|
|
2339
|
-
e.enabled || (e.enabled = !0, e.params.grabCursor && e.setGrabCursor(), e.emit("enable"));
|
|
2340
|
-
}
|
|
2341
|
-
disable() {
|
|
2342
|
-
const e = this;
|
|
2343
|
-
e.enabled && (e.enabled = !1, e.params.grabCursor && e.unsetGrabCursor(), e.emit("disable"));
|
|
2344
|
-
}
|
|
2345
|
-
setProgress(e, i) {
|
|
2346
|
-
const s = this;
|
|
2347
|
-
e = Math.min(Math.max(e, 0), 1);
|
|
2348
|
-
const n = s.minTranslate(), l = (s.maxTranslate() - n) * e + n;
|
|
2349
|
-
s.translateTo(l, typeof i > "u" ? 0 : i), s.updateActiveIndex(), s.updateSlidesClasses();
|
|
2350
|
-
}
|
|
2351
|
-
emitContainerClasses() {
|
|
2352
|
-
const e = this;
|
|
2353
|
-
if (!e.params._emitClasses || !e.el) return;
|
|
2354
|
-
const i = e.el.className.split(" ").filter((s) => s.indexOf("swiper") === 0 || s.indexOf(e.params.containerModifierClass) === 0);
|
|
2355
|
-
e.emit("_containerClasses", i.join(" "));
|
|
2356
|
-
}
|
|
2357
|
-
getSlideClasses(e) {
|
|
2358
|
-
const i = this;
|
|
2359
|
-
return i.destroyed ? "" : e.className.split(" ").filter((s) => s.indexOf("swiper-slide") === 0 || s.indexOf(i.params.slideClass) === 0).join(" ");
|
|
2360
|
-
}
|
|
2361
|
-
emitSlidesClasses() {
|
|
2362
|
-
const e = this;
|
|
2363
|
-
if (!e.params._emitClasses || !e.el) return;
|
|
2364
|
-
const i = [];
|
|
2365
|
-
e.slides.forEach((s) => {
|
|
2366
|
-
const n = e.getSlideClasses(s);
|
|
2367
|
-
i.push({
|
|
2368
|
-
slideEl: s,
|
|
2369
|
-
classNames: n
|
|
2370
|
-
}), e.emit("_slideClass", s, n);
|
|
2371
|
-
}), e.emit("_slideClasses", i);
|
|
2372
|
-
}
|
|
2373
|
-
slidesPerViewDynamic(e, i) {
|
|
2374
|
-
e === void 0 && (e = "current"), i === void 0 && (i = !1);
|
|
2375
|
-
const s = this, {
|
|
2376
|
-
params: n,
|
|
2377
|
-
slides: r,
|
|
2378
|
-
slidesGrid: l,
|
|
2379
|
-
slidesSizesGrid: a,
|
|
2380
|
-
size: o,
|
|
2381
|
-
activeIndex: c
|
|
2382
|
-
} = s;
|
|
2383
|
-
let d = 1;
|
|
2384
|
-
if (typeof n.slidesPerView == "number") return n.slidesPerView;
|
|
2385
|
-
if (n.centeredSlides) {
|
|
2386
|
-
let p = r[c] ? Math.ceil(r[c].swiperSlideSize) : 0, h;
|
|
2387
|
-
for (let w = c + 1; w < r.length; w += 1)
|
|
2388
|
-
r[w] && !h && (p += Math.ceil(r[w].swiperSlideSize), d += 1, p > o && (h = !0));
|
|
2389
|
-
for (let w = c - 1; w >= 0; w -= 1)
|
|
2390
|
-
r[w] && !h && (p += r[w].swiperSlideSize, d += 1, p > o && (h = !0));
|
|
2391
|
-
} else if (e === "current")
|
|
2392
|
-
for (let p = c + 1; p < r.length; p += 1)
|
|
2393
|
-
(i ? l[p] + a[p] - l[c] < o : l[p] - l[c] < o) && (d += 1);
|
|
2394
|
-
else
|
|
2395
|
-
for (let p = c - 1; p >= 0; p -= 1)
|
|
2396
|
-
l[c] - l[p] < o && (d += 1);
|
|
2397
|
-
return d;
|
|
2398
|
-
}
|
|
2399
|
-
update() {
|
|
2400
|
-
const e = this;
|
|
2401
|
-
if (!e || e.destroyed) return;
|
|
2402
|
-
const {
|
|
2403
|
-
snapGrid: i,
|
|
2404
|
-
params: s
|
|
2405
|
-
} = e;
|
|
2406
|
-
s.breakpoints && e.setBreakpoint(), [...e.el.querySelectorAll('[loading="lazy"]')].forEach((l) => {
|
|
2407
|
-
l.complete && we(e, l);
|
|
2408
|
-
}), e.updateSize(), e.updateSlides(), e.updateProgress(), e.updateSlidesClasses();
|
|
2409
|
-
function n() {
|
|
2410
|
-
const l = e.rtlTranslate ? e.translate * -1 : e.translate, a = Math.min(Math.max(l, e.maxTranslate()), e.minTranslate());
|
|
2411
|
-
e.setTranslate(a), e.updateActiveIndex(), e.updateSlidesClasses();
|
|
2412
|
-
}
|
|
2413
|
-
let r;
|
|
2414
|
-
if (s.freeMode && s.freeMode.enabled && !s.cssMode)
|
|
2415
|
-
n(), s.autoHeight && e.updateAutoHeight();
|
|
2416
|
-
else {
|
|
2417
|
-
if ((s.slidesPerView === "auto" || s.slidesPerView > 1) && e.isEnd && !s.centeredSlides) {
|
|
2418
|
-
const l = e.virtual && s.virtual.enabled ? e.virtual.slides : e.slides;
|
|
2419
|
-
r = e.slideTo(l.length - 1, 0, !1, !0);
|
|
2420
|
-
} else
|
|
2421
|
-
r = e.slideTo(e.activeIndex, 0, !1, !0);
|
|
2422
|
-
r || n();
|
|
2423
|
-
}
|
|
2424
|
-
s.watchOverflow && i !== e.snapGrid && e.checkOverflow(), e.emit("update");
|
|
2425
|
-
}
|
|
2426
|
-
changeDirection(e, i) {
|
|
2427
|
-
i === void 0 && (i = !0);
|
|
2428
|
-
const s = this, n = s.params.direction;
|
|
2429
|
-
return e || (e = n === "horizontal" ? "vertical" : "horizontal"), e === n || e !== "horizontal" && e !== "vertical" || (s.el.classList.remove(`${s.params.containerModifierClass}${n}`), s.el.classList.add(`${s.params.containerModifierClass}${e}`), s.emitContainerClasses(), s.params.direction = e, s.slides.forEach((r) => {
|
|
2430
|
-
e === "vertical" ? r.style.width = "" : r.style.height = "";
|
|
2431
|
-
}), s.emit("changeDirection"), i && s.update()), s;
|
|
2432
|
-
}
|
|
2433
|
-
changeLanguageDirection(e) {
|
|
2434
|
-
const i = this;
|
|
2435
|
-
i.rtl && e === "rtl" || !i.rtl && e === "ltr" || (i.rtl = e === "rtl", i.rtlTranslate = i.params.direction === "horizontal" && i.rtl, i.rtl ? (i.el.classList.add(`${i.params.containerModifierClass}rtl`), i.el.dir = "rtl") : (i.el.classList.remove(`${i.params.containerModifierClass}rtl`), i.el.dir = "ltr"), i.update());
|
|
2436
|
-
}
|
|
2437
|
-
mount(e) {
|
|
2438
|
-
const i = this;
|
|
2439
|
-
if (i.mounted) return !0;
|
|
2440
|
-
let s = e || i.params.el;
|
|
2441
|
-
if (typeof s == "string" && (s = document.querySelector(s)), !s)
|
|
2442
|
-
return !1;
|
|
2443
|
-
s.swiper = i, s.parentNode && s.parentNode.host && s.parentNode.host.nodeName === i.params.swiperElementNodeName.toUpperCase() && (i.isElement = !0);
|
|
2444
|
-
const n = () => `.${(i.params.wrapperClass || "").trim().split(" ").join(".")}`;
|
|
2445
|
-
let l = s && s.shadowRoot && s.shadowRoot.querySelector ? s.shadowRoot.querySelector(n()) : Q(s, n())[0];
|
|
2446
|
-
return !l && i.params.createElements && (l = ye("div", i.params.wrapperClass), s.append(l), Q(s, `.${i.params.slideClass}`).forEach((a) => {
|
|
2447
|
-
l.append(a);
|
|
2448
|
-
})), Object.assign(i, {
|
|
2449
|
-
el: s,
|
|
2450
|
-
wrapperEl: l,
|
|
2451
|
-
slidesEl: i.isElement && !s.parentNode.host.slideSlots ? s.parentNode.host : l,
|
|
2452
|
-
hostEl: i.isElement ? s.parentNode.host : s,
|
|
2453
|
-
mounted: !0,
|
|
2454
|
-
// RTL
|
|
2455
|
-
rtl: s.dir.toLowerCase() === "rtl" || ie(s, "direction") === "rtl",
|
|
2456
|
-
rtlTranslate: i.params.direction === "horizontal" && (s.dir.toLowerCase() === "rtl" || ie(s, "direction") === "rtl"),
|
|
2457
|
-
wrongRTL: ie(l, "display") === "-webkit-box"
|
|
2458
|
-
}), !0;
|
|
2459
|
-
}
|
|
2460
|
-
init(e) {
|
|
2461
|
-
const i = this;
|
|
2462
|
-
if (i.initialized || i.mount(e) === !1) return i;
|
|
2463
|
-
i.emit("beforeInit"), i.params.breakpoints && i.setBreakpoint(), i.addClasses(), i.updateSize(), i.updateSlides(), i.params.watchOverflow && i.checkOverflow(), i.params.grabCursor && i.enabled && i.setGrabCursor(), i.params.loop && i.virtual && i.params.virtual.enabled ? i.slideTo(i.params.initialSlide + i.virtual.slidesBefore, 0, i.params.runCallbacksOnInit, !1, !0) : i.slideTo(i.params.initialSlide, 0, i.params.runCallbacksOnInit, !1, !0), i.params.loop && i.loopCreate(void 0, !0), i.attachEvents();
|
|
2464
|
-
const n = [...i.el.querySelectorAll('[loading="lazy"]')];
|
|
2465
|
-
return i.isElement && n.push(...i.hostEl.querySelectorAll('[loading="lazy"]')), n.forEach((r) => {
|
|
2466
|
-
r.complete ? we(i, r) : r.addEventListener("load", (l) => {
|
|
2467
|
-
we(i, l.target);
|
|
2468
|
-
});
|
|
2469
|
-
}), Ge(i), i.initialized = !0, Ge(i), i.emit("init"), i.emit("afterInit"), i;
|
|
2470
|
-
}
|
|
2471
|
-
destroy(e, i) {
|
|
2472
|
-
e === void 0 && (e = !0), i === void 0 && (i = !0);
|
|
2473
|
-
const s = this, {
|
|
2474
|
-
params: n,
|
|
2475
|
-
el: r,
|
|
2476
|
-
wrapperEl: l,
|
|
2477
|
-
slides: a
|
|
2478
|
-
} = s;
|
|
2479
|
-
return typeof s.params > "u" || s.destroyed || (s.emit("beforeDestroy"), s.initialized = !1, s.detachEvents(), n.loop && s.loopDestroy(), i && (s.removeClasses(), r && typeof r != "string" && r.removeAttribute("style"), l && l.removeAttribute("style"), a && a.length && a.forEach((o) => {
|
|
2480
|
-
o.classList.remove(n.slideVisibleClass, n.slideFullyVisibleClass, n.slideActiveClass, n.slideNextClass, n.slidePrevClass), o.removeAttribute("style"), o.removeAttribute("data-swiper-slide-index");
|
|
2481
|
-
})), s.emit("destroy"), Object.keys(s.eventsListeners).forEach((o) => {
|
|
2482
|
-
s.off(o);
|
|
2483
|
-
}), e !== !1 && (s.el && typeof s.el != "string" && (s.el.swiper = null), ci(s)), s.destroyed = !0), null;
|
|
2484
|
-
}
|
|
2485
|
-
static extendDefaults(e) {
|
|
2486
|
-
W(Oe, e);
|
|
2487
|
-
}
|
|
2488
|
-
static get extendedDefaults() {
|
|
2489
|
-
return Oe;
|
|
2490
|
-
}
|
|
2491
|
-
static get defaults() {
|
|
2492
|
-
return De;
|
|
2493
|
-
}
|
|
2494
|
-
static installModule(e) {
|
|
2495
|
-
ee.prototype.__modules__ || (ee.prototype.__modules__ = []);
|
|
2496
|
-
const i = ee.prototype.__modules__;
|
|
2497
|
-
typeof e == "function" && i.indexOf(e) < 0 && i.push(e);
|
|
2498
|
-
}
|
|
2499
|
-
static use(e) {
|
|
2500
|
-
return Array.isArray(e) ? (e.forEach((i) => ee.installModule(i)), ee) : (ee.installModule(e), ee);
|
|
2501
|
-
}
|
|
2502
|
-
};
|
|
2503
|
-
Object.keys(_e).forEach((t) => {
|
|
2504
|
-
Object.keys(_e[t]).forEach((e) => {
|
|
2505
|
-
He.prototype[e] = _e[t][e];
|
|
2506
|
-
});
|
|
2507
|
-
});
|
|
2508
|
-
He.use([yi, xi]);
|
|
2509
|
-
const ct = [
|
|
2510
|
-
"eventsPrefix",
|
|
2511
|
-
"injectStyles",
|
|
2512
|
-
"injectStylesUrls",
|
|
2513
|
-
"modules",
|
|
2514
|
-
"init",
|
|
2515
|
-
"_direction",
|
|
2516
|
-
"oneWayMovement",
|
|
2517
|
-
"swiperElementNodeName",
|
|
2518
|
-
"touchEventsTarget",
|
|
2519
|
-
"initialSlide",
|
|
2520
|
-
"_speed",
|
|
2521
|
-
"cssMode",
|
|
2522
|
-
"updateOnWindowResize",
|
|
2523
|
-
"resizeObserver",
|
|
2524
|
-
"nested",
|
|
2525
|
-
"focusableElements",
|
|
2526
|
-
"_enabled",
|
|
2527
|
-
"_width",
|
|
2528
|
-
"_height",
|
|
2529
|
-
"preventInteractionOnTransition",
|
|
2530
|
-
"userAgent",
|
|
2531
|
-
"url",
|
|
2532
|
-
"_edgeSwipeDetection",
|
|
2533
|
-
"_edgeSwipeThreshold",
|
|
2534
|
-
"_freeMode",
|
|
2535
|
-
"_autoHeight",
|
|
2536
|
-
"setWrapperSize",
|
|
2537
|
-
"virtualTranslate",
|
|
2538
|
-
"_effect",
|
|
2539
|
-
"breakpoints",
|
|
2540
|
-
"breakpointsBase",
|
|
2541
|
-
"_spaceBetween",
|
|
2542
|
-
"_slidesPerView",
|
|
2543
|
-
"maxBackfaceHiddenSlides",
|
|
2544
|
-
"_grid",
|
|
2545
|
-
"_slidesPerGroup",
|
|
2546
|
-
"_slidesPerGroupSkip",
|
|
2547
|
-
"_slidesPerGroupAuto",
|
|
2548
|
-
"_centeredSlides",
|
|
2549
|
-
"_centeredSlidesBounds",
|
|
2550
|
-
"_slidesOffsetBefore",
|
|
2551
|
-
"_slidesOffsetAfter",
|
|
2552
|
-
"normalizeSlideIndex",
|
|
2553
|
-
"_centerInsufficientSlides",
|
|
2554
|
-
"_watchOverflow",
|
|
2555
|
-
"roundLengths",
|
|
2556
|
-
"touchRatio",
|
|
2557
|
-
"touchAngle",
|
|
2558
|
-
"simulateTouch",
|
|
2559
|
-
"_shortSwipes",
|
|
2560
|
-
"_longSwipes",
|
|
2561
|
-
"longSwipesRatio",
|
|
2562
|
-
"longSwipesMs",
|
|
2563
|
-
"_followFinger",
|
|
2564
|
-
"allowTouchMove",
|
|
2565
|
-
"_threshold",
|
|
2566
|
-
"touchMoveStopPropagation",
|
|
2567
|
-
"touchStartPreventDefault",
|
|
2568
|
-
"touchStartForcePreventDefault",
|
|
2569
|
-
"touchReleaseOnEdges",
|
|
2570
|
-
"uniqueNavElements",
|
|
2571
|
-
"_resistance",
|
|
2572
|
-
"_resistanceRatio",
|
|
2573
|
-
"_watchSlidesProgress",
|
|
2574
|
-
"_grabCursor",
|
|
2575
|
-
"preventClicks",
|
|
2576
|
-
"preventClicksPropagation",
|
|
2577
|
-
"_slideToClickedSlide",
|
|
2578
|
-
"_loop",
|
|
2579
|
-
"loopAdditionalSlides",
|
|
2580
|
-
"loopAddBlankSlides",
|
|
2581
|
-
"loopPreventsSliding",
|
|
2582
|
-
"_rewind",
|
|
2583
|
-
"_allowSlidePrev",
|
|
2584
|
-
"_allowSlideNext",
|
|
2585
|
-
"_swipeHandler",
|
|
2586
|
-
"_noSwiping",
|
|
2587
|
-
"noSwipingClass",
|
|
2588
|
-
"noSwipingSelector",
|
|
2589
|
-
"passiveListeners",
|
|
2590
|
-
"containerModifierClass",
|
|
2591
|
-
"slideClass",
|
|
2592
|
-
"slideActiveClass",
|
|
2593
|
-
"slideVisibleClass",
|
|
2594
|
-
"slideFullyVisibleClass",
|
|
2595
|
-
"slideNextClass",
|
|
2596
|
-
"slidePrevClass",
|
|
2597
|
-
"slideBlankClass",
|
|
2598
|
-
"wrapperClass",
|
|
2599
|
-
"lazyPreloaderClass",
|
|
2600
|
-
"lazyPreloadPrevNext",
|
|
2601
|
-
"runCallbacksOnInit",
|
|
2602
|
-
"observer",
|
|
2603
|
-
"observeParents",
|
|
2604
|
-
"observeSlideChildren",
|
|
2605
|
-
// modules
|
|
2606
|
-
"a11y",
|
|
2607
|
-
"_autoplay",
|
|
2608
|
-
"_controller",
|
|
2609
|
-
"coverflowEffect",
|
|
2610
|
-
"cubeEffect",
|
|
2611
|
-
"fadeEffect",
|
|
2612
|
-
"flipEffect",
|
|
2613
|
-
"creativeEffect",
|
|
2614
|
-
"cardsEffect",
|
|
2615
|
-
"hashNavigation",
|
|
2616
|
-
"history",
|
|
2617
|
-
"keyboard",
|
|
2618
|
-
"mousewheel",
|
|
2619
|
-
"_navigation",
|
|
2620
|
-
"_pagination",
|
|
2621
|
-
"parallax",
|
|
2622
|
-
"_scrollbar",
|
|
2623
|
-
"_thumbs",
|
|
2624
|
-
"virtual",
|
|
2625
|
-
"zoom",
|
|
2626
|
-
"control"
|
|
2627
|
-
];
|
|
2628
|
-
function ae(t) {
|
|
2629
|
-
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object" && !t.__swiper__;
|
|
2630
|
-
}
|
|
2631
|
-
function de(t, e) {
|
|
2632
|
-
const i = ["__proto__", "constructor", "prototype"];
|
|
2633
|
-
Object.keys(e).filter((s) => i.indexOf(s) < 0).forEach((s) => {
|
|
2634
|
-
typeof t[s] > "u" ? t[s] = e[s] : ae(e[s]) && ae(t[s]) && Object.keys(e[s]).length > 0 ? e[s].__swiper__ ? t[s] = e[s] : de(t[s], e[s]) : t[s] = e[s];
|
|
2635
|
-
});
|
|
2636
|
-
}
|
|
2637
|
-
function ut(t) {
|
|
2638
|
-
return t === void 0 && (t = {}), t.navigation && typeof t.navigation.nextEl > "u" && typeof t.navigation.prevEl > "u";
|
|
2639
|
-
}
|
|
2640
|
-
function ft(t) {
|
|
2641
|
-
return t === void 0 && (t = {}), t.pagination && typeof t.pagination.el > "u";
|
|
2642
|
-
}
|
|
2643
|
-
function pt(t) {
|
|
2644
|
-
return t === void 0 && (t = {}), t.scrollbar && typeof t.scrollbar.el > "u";
|
|
2645
|
-
}
|
|
2646
|
-
function mt(t) {
|
|
2647
|
-
t === void 0 && (t = "");
|
|
2648
|
-
const e = t.split(" ").map((s) => s.trim()).filter((s) => !!s), i = [];
|
|
2649
|
-
return e.forEach((s) => {
|
|
2650
|
-
i.indexOf(s) < 0 && i.push(s);
|
|
2651
|
-
}), i.join(" ");
|
|
2652
|
-
}
|
|
2653
|
-
function Ms(t) {
|
|
2654
|
-
return t === void 0 && (t = ""), t ? t.includes("swiper-wrapper") ? t : `swiper-wrapper ${t}` : "swiper-wrapper";
|
|
2655
|
-
}
|
|
2656
|
-
function Is(t) {
|
|
2657
|
-
let {
|
|
2658
|
-
swiper: e,
|
|
2659
|
-
slides: i,
|
|
2660
|
-
passedParams: s,
|
|
2661
|
-
changedParams: n,
|
|
2662
|
-
nextEl: r,
|
|
2663
|
-
prevEl: l,
|
|
2664
|
-
scrollbarEl: a,
|
|
2665
|
-
paginationEl: o
|
|
2666
|
-
} = t;
|
|
2667
|
-
const c = n.filter((T) => T !== "children" && T !== "direction" && T !== "wrapperClass"), {
|
|
2668
|
-
params: d,
|
|
2669
|
-
pagination: p,
|
|
2670
|
-
navigation: h,
|
|
2671
|
-
scrollbar: w,
|
|
2672
|
-
virtual: m,
|
|
2673
|
-
thumbs: b
|
|
2674
|
-
} = e;
|
|
2675
|
-
let x, g, u, f, S, y, P, I;
|
|
2676
|
-
n.includes("thumbs") && s.thumbs && s.thumbs.swiper && !s.thumbs.swiper.destroyed && d.thumbs && (!d.thumbs.swiper || d.thumbs.swiper.destroyed) && (x = !0), n.includes("controller") && s.controller && s.controller.control && d.controller && !d.controller.control && (g = !0), n.includes("pagination") && s.pagination && (s.pagination.el || o) && (d.pagination || d.pagination === !1) && p && !p.el && (u = !0), n.includes("scrollbar") && s.scrollbar && (s.scrollbar.el || a) && (d.scrollbar || d.scrollbar === !1) && w && !w.el && (f = !0), n.includes("navigation") && s.navigation && (s.navigation.prevEl || l) && (s.navigation.nextEl || r) && (d.navigation || d.navigation === !1) && h && !h.prevEl && !h.nextEl && (S = !0);
|
|
2677
|
-
const M = (T) => {
|
|
2678
|
-
e[T] && (e[T].destroy(), T === "navigation" ? (e.isElement && (e[T].prevEl.remove(), e[T].nextEl.remove()), d[T].prevEl = void 0, d[T].nextEl = void 0, e[T].prevEl = void 0, e[T].nextEl = void 0) : (e.isElement && e[T].el.remove(), d[T].el = void 0, e[T].el = void 0));
|
|
2679
|
-
};
|
|
2680
|
-
n.includes("loop") && e.isElement && (d.loop && !s.loop ? y = !0 : !d.loop && s.loop ? P = !0 : I = !0), c.forEach((T) => {
|
|
2681
|
-
if (ae(d[T]) && ae(s[T]))
|
|
2682
|
-
Object.assign(d[T], s[T]), (T === "navigation" || T === "pagination" || T === "scrollbar") && "enabled" in s[T] && !s[T].enabled && M(T);
|
|
2683
|
-
else {
|
|
2684
|
-
const E = s[T];
|
|
2685
|
-
(E === !0 || E === !1) && (T === "navigation" || T === "pagination" || T === "scrollbar") ? E === !1 && M(T) : d[T] = s[T];
|
|
2686
|
-
}
|
|
2687
|
-
}), c.includes("controller") && !g && e.controller && e.controller.control && d.controller && d.controller.control && (e.controller.control = d.controller.control), n.includes("children") && i && m && d.virtual.enabled ? (m.slides = i, m.update(!0)) : n.includes("virtual") && m && d.virtual.enabled && (i && (m.slides = i), m.update(!0)), n.includes("children") && i && d.loop && (I = !0), x && b.init() && b.update(!0), g && (e.controller.control = d.controller.control), u && (e.isElement && (!o || typeof o == "string") && (o = document.createElement("div"), o.classList.add("swiper-pagination"), o.part.add("pagination"), e.el.appendChild(o)), o && (d.pagination.el = o), p.init(), p.render(), p.update()), f && (e.isElement && (!a || typeof a == "string") && (a = document.createElement("div"), a.classList.add("swiper-scrollbar"), a.part.add("scrollbar"), e.el.appendChild(a)), a && (d.scrollbar.el = a), w.init(), w.updateSize(), w.setTranslate()), S && (e.isElement && ((!r || typeof r == "string") && (r = document.createElement("div"), r.classList.add("swiper-button-next"), Te(r, e.hostEl.constructor.nextButtonSvg), r.part.add("button-next"), e.el.appendChild(r)), (!l || typeof l == "string") && (l = document.createElement("div"), l.classList.add("swiper-button-prev"), Te(l, e.hostEl.constructor.prevButtonSvg), l.part.add("button-prev"), e.el.appendChild(l))), r && (d.navigation.nextEl = r), l && (d.navigation.prevEl = l), h.init(), h.update()), n.includes("allowSlideNext") && (e.allowSlideNext = s.allowSlideNext), n.includes("allowSlidePrev") && (e.allowSlidePrev = s.allowSlidePrev), n.includes("direction") && e.changeDirection(s.direction, !1), (y || I) && e.loopDestroy(), (P || I) && e.loopCreate(), e.update();
|
|
2688
|
-
}
|
|
2689
|
-
function Ls(t, e) {
|
|
2690
|
-
t === void 0 && (t = {}), e === void 0 && (e = !0);
|
|
2691
|
-
const i = {
|
|
2692
|
-
on: {}
|
|
2693
|
-
}, s = {}, n = {};
|
|
2694
|
-
de(i, De), i._emitClasses = !0, i.init = !1;
|
|
2695
|
-
const r = {}, l = ct.map((o) => o.replace(/_/, "")), a = Object.assign({}, t);
|
|
2696
|
-
return Object.keys(a).forEach((o) => {
|
|
2697
|
-
typeof t[o] > "u" || (l.indexOf(o) >= 0 ? ae(t[o]) ? (i[o] = {}, n[o] = {}, de(i[o], t[o]), de(n[o], t[o])) : (i[o] = t[o], n[o] = t[o]) : o.search(/on[A-Z]/) === 0 && typeof t[o] == "function" ? e ? s[`${o[2].toLowerCase()}${o.substr(3)}`] = t[o] : i.on[`${o[2].toLowerCase()}${o.substr(3)}`] = t[o] : r[o] = t[o]);
|
|
2698
|
-
}), ["navigation", "pagination", "scrollbar"].forEach((o) => {
|
|
2699
|
-
i[o] === !0 && (i[o] = {}), i[o] === !1 && delete i[o];
|
|
2700
|
-
}), {
|
|
2701
|
-
params: i,
|
|
2702
|
-
passedParams: n,
|
|
2703
|
-
rest: r,
|
|
2704
|
-
events: s
|
|
2705
|
-
};
|
|
2706
|
-
}
|
|
2707
|
-
function _s(t, e) {
|
|
2708
|
-
let {
|
|
2709
|
-
el: i,
|
|
2710
|
-
nextEl: s,
|
|
2711
|
-
prevEl: n,
|
|
2712
|
-
paginationEl: r,
|
|
2713
|
-
scrollbarEl: l,
|
|
2714
|
-
swiper: a
|
|
2715
|
-
} = t;
|
|
2716
|
-
ut(e) && s && n && (a.params.navigation.nextEl = s, a.originalParams.navigation.nextEl = s, a.params.navigation.prevEl = n, a.originalParams.navigation.prevEl = n), ft(e) && r && (a.params.pagination.el = r, a.originalParams.pagination.el = r), pt(e) && l && (a.params.scrollbar.el = l, a.originalParams.scrollbar.el = l), a.init(i);
|
|
2717
|
-
}
|
|
2718
|
-
function Os(t, e, i, s, n) {
|
|
2719
|
-
const r = [];
|
|
2720
|
-
if (!e) return r;
|
|
2721
|
-
const l = (o) => {
|
|
2722
|
-
r.indexOf(o) < 0 && r.push(o);
|
|
2723
|
-
};
|
|
2724
|
-
if (i && s) {
|
|
2725
|
-
const o = s.map(n), c = i.map(n);
|
|
2726
|
-
o.join("") !== c.join("") && l("children"), s.length !== i.length && l("children");
|
|
2727
|
-
}
|
|
2728
|
-
return ct.filter((o) => o[0] === "_").map((o) => o.replace(/_/, "")).forEach((o) => {
|
|
2729
|
-
if (o in t && o in e)
|
|
2730
|
-
if (ae(t[o]) && ae(e[o])) {
|
|
2731
|
-
const c = Object.keys(t[o]), d = Object.keys(e[o]);
|
|
2732
|
-
c.length !== d.length ? l(o) : (c.forEach((p) => {
|
|
2733
|
-
t[o][p] !== e[o][p] && l(o);
|
|
2734
|
-
}), d.forEach((p) => {
|
|
2735
|
-
t[o][p] !== e[o][p] && l(o);
|
|
2736
|
-
}));
|
|
2737
|
-
} else t[o] !== e[o] && l(o);
|
|
2738
|
-
}), r;
|
|
2739
|
-
}
|
|
2740
|
-
const Ns = (t) => {
|
|
2741
|
-
!t || t.destroyed || !t.params.virtual || t.params.virtual && !t.params.virtual.enabled || (t.updateSlides(), t.updateProgress(), t.updateSlidesClasses(), t.emit("_virtualUpdated"), t.parallax && t.params.parallax && t.params.parallax.enabled && t.parallax.setTranslate());
|
|
2742
|
-
};
|
|
2743
|
-
function Ee() {
|
|
2744
|
-
return Ee = Object.assign ? Object.assign.bind() : function(t) {
|
|
2745
|
-
for (var e = 1; e < arguments.length; e++) {
|
|
2746
|
-
var i = arguments[e];
|
|
2747
|
-
for (var s in i)
|
|
2748
|
-
Object.prototype.hasOwnProperty.call(i, s) && (t[s] = i[s]);
|
|
2749
|
-
}
|
|
2750
|
-
return t;
|
|
2751
|
-
}, Ee.apply(this, arguments);
|
|
2752
|
-
}
|
|
2753
|
-
function ht(t) {
|
|
2754
|
-
return t.type && t.type.displayName && t.type.displayName.includes("SwiperSlide");
|
|
2755
|
-
}
|
|
2756
|
-
function gt(t) {
|
|
2757
|
-
const e = [];
|
|
2758
|
-
return k.Children.toArray(t).forEach((i) => {
|
|
2759
|
-
ht(i) ? e.push(i) : i.props && i.props.children && gt(i.props.children).forEach((s) => e.push(s));
|
|
2760
|
-
}), e;
|
|
2761
|
-
}
|
|
2762
|
-
function zs(t) {
|
|
2763
|
-
const e = [], i = {
|
|
2764
|
-
"container-start": [],
|
|
2765
|
-
"container-end": [],
|
|
2766
|
-
"wrapper-start": [],
|
|
2767
|
-
"wrapper-end": []
|
|
2768
|
-
};
|
|
2769
|
-
return k.Children.toArray(t).forEach((s) => {
|
|
2770
|
-
if (ht(s))
|
|
2771
|
-
e.push(s);
|
|
2772
|
-
else if (s.props && s.props.slot && i[s.props.slot])
|
|
2773
|
-
i[s.props.slot].push(s);
|
|
2774
|
-
else if (s.props && s.props.children) {
|
|
2775
|
-
const n = gt(s.props.children);
|
|
2776
|
-
n.length > 0 ? n.forEach((r) => e.push(r)) : i["container-end"].push(s);
|
|
2777
|
-
} else
|
|
2778
|
-
i["container-end"].push(s);
|
|
2779
|
-
}), {
|
|
2780
|
-
slides: e,
|
|
2781
|
-
slots: i
|
|
2782
|
-
};
|
|
2783
|
-
}
|
|
2784
|
-
function As(t, e, i) {
|
|
2785
|
-
if (!i) return null;
|
|
2786
|
-
const s = (d) => {
|
|
2787
|
-
let p = d;
|
|
2788
|
-
return d < 0 ? p = e.length + d : p >= e.length && (p = p - e.length), p;
|
|
2789
|
-
}, n = t.isHorizontal() ? {
|
|
2790
|
-
[t.rtlTranslate ? "right" : "left"]: `${i.offset}px`
|
|
2791
|
-
} : {
|
|
2792
|
-
top: `${i.offset}px`
|
|
2793
|
-
}, {
|
|
2794
|
-
from: r,
|
|
2795
|
-
to: l
|
|
2796
|
-
} = i, a = t.params.loop ? -e.length : 0, o = t.params.loop ? e.length * 2 : e.length, c = [];
|
|
2797
|
-
for (let d = a; d < o; d += 1)
|
|
2798
|
-
d >= r && d <= l && c.push(e[s(d)]);
|
|
2799
|
-
return c.map((d, p) => /* @__PURE__ */ k.cloneElement(d, {
|
|
2800
|
-
swiper: t,
|
|
2801
|
-
style: n,
|
|
2802
|
-
key: d.props.virtualIndex || d.key || `slide-${p}`
|
|
2803
|
-
}));
|
|
2804
|
-
}
|
|
2805
|
-
function fe(t, e) {
|
|
2806
|
-
return typeof window > "u" ? re(t, e) : Tt(t, e);
|
|
2807
|
-
}
|
|
2808
|
-
const Ke = /* @__PURE__ */ Be(null), $s = /* @__PURE__ */ Be(null), vt = /* @__PURE__ */ Qe(function(t, e) {
|
|
2809
|
-
let {
|
|
2810
|
-
className: i,
|
|
2811
|
-
tag: s = "div",
|
|
2812
|
-
wrapperTag: n = "div",
|
|
2813
|
-
children: r,
|
|
2814
|
-
onSwiper: l,
|
|
2815
|
-
...a
|
|
2816
|
-
} = t === void 0 ? {} : t, o = !1;
|
|
2817
|
-
const [c, d] = X("swiper"), [p, h] = X(null), [w, m] = X(!1), b = U(!1), x = U(null), g = U(null), u = U(null), f = U(null), S = U(null), y = U(null), P = U(null), I = U(null), {
|
|
2818
|
-
params: M,
|
|
2819
|
-
passedParams: T,
|
|
2820
|
-
rest: E,
|
|
2821
|
-
events: C
|
|
2822
|
-
} = Ls(a), {
|
|
2823
|
-
slides: _,
|
|
2824
|
-
slots: z
|
|
2825
|
-
} = zs(r), A = () => {
|
|
2826
|
-
m(!w);
|
|
2827
|
-
};
|
|
2828
|
-
Object.assign(M.on, {
|
|
2829
|
-
_containerClasses(G, Y) {
|
|
2830
|
-
d(Y);
|
|
2831
|
-
}
|
|
2832
|
-
});
|
|
2833
|
-
const $ = () => {
|
|
2834
|
-
Object.assign(M.on, C), o = !0;
|
|
2835
|
-
const G = {
|
|
2836
|
-
...M
|
|
2837
|
-
};
|
|
2838
|
-
if (delete G.wrapperClass, g.current = new He(G), g.current.virtual && g.current.params.virtual.enabled) {
|
|
2839
|
-
g.current.virtual.slides = _;
|
|
2840
|
-
const Y = {
|
|
2841
|
-
cache: !1,
|
|
2842
|
-
slides: _,
|
|
2843
|
-
renderExternal: h,
|
|
2844
|
-
renderExternalUpdate: !1
|
|
2845
|
-
};
|
|
2846
|
-
de(g.current.params.virtual, Y), de(g.current.originalParams.virtual, Y);
|
|
2847
|
-
}
|
|
2848
|
-
};
|
|
2849
|
-
x.current || $(), g.current && g.current.on("_beforeBreakpoint", A);
|
|
2850
|
-
const O = () => {
|
|
2851
|
-
o || !C || !g.current || Object.keys(C).forEach((G) => {
|
|
2852
|
-
g.current.on(G, C[G]);
|
|
2853
|
-
});
|
|
2854
|
-
}, B = () => {
|
|
2855
|
-
!C || !g.current || Object.keys(C).forEach((G) => {
|
|
2856
|
-
g.current.off(G, C[G]);
|
|
2857
|
-
});
|
|
2858
|
-
};
|
|
2859
|
-
re(() => () => {
|
|
2860
|
-
g.current && g.current.off("_beforeBreakpoint", A);
|
|
2861
|
-
}), re(() => {
|
|
2862
|
-
!b.current && g.current && (g.current.emitSlidesClasses(), b.current = !0);
|
|
2863
|
-
}), fe(() => {
|
|
2864
|
-
if (e && (e.current = x.current), !!x.current)
|
|
2865
|
-
return g.current.destroyed && $(), _s({
|
|
2866
|
-
el: x.current,
|
|
2867
|
-
nextEl: S.current,
|
|
2868
|
-
prevEl: y.current,
|
|
2869
|
-
paginationEl: P.current,
|
|
2870
|
-
scrollbarEl: I.current,
|
|
2871
|
-
swiper: g.current
|
|
2872
|
-
}, M), l && !g.current.destroyed && l(g.current), () => {
|
|
2873
|
-
g.current && !g.current.destroyed && g.current.destroy(!0, !1);
|
|
2874
|
-
};
|
|
2875
|
-
}, []), fe(() => {
|
|
2876
|
-
O();
|
|
2877
|
-
const G = Os(T, u.current, _, f.current, (Y) => Y.key);
|
|
2878
|
-
return u.current = T, f.current = _, G.length && g.current && !g.current.destroyed && Is({
|
|
2879
|
-
swiper: g.current,
|
|
2880
|
-
slides: _,
|
|
2881
|
-
passedParams: T,
|
|
2882
|
-
changedParams: G,
|
|
2883
|
-
nextEl: S.current,
|
|
2884
|
-
prevEl: y.current,
|
|
2885
|
-
scrollbarEl: I.current,
|
|
2886
|
-
paginationEl: P.current
|
|
2887
|
-
}), () => {
|
|
2888
|
-
B();
|
|
2889
|
-
};
|
|
2890
|
-
}), fe(() => {
|
|
2891
|
-
Ns(g.current);
|
|
2892
|
-
}, [p]);
|
|
2893
|
-
function F() {
|
|
2894
|
-
return M.virtual ? As(g.current, _, p) : _.map((G, Y) => /* @__PURE__ */ k.cloneElement(G, {
|
|
2895
|
-
swiper: g.current,
|
|
2896
|
-
swiperSlideIndex: Y
|
|
2897
|
-
}));
|
|
2898
|
-
}
|
|
2899
|
-
return /* @__PURE__ */ k.createElement(s, Ee({
|
|
2900
|
-
ref: x,
|
|
2901
|
-
className: mt(`${c}${i ? ` ${i}` : ""}`)
|
|
2902
|
-
}, E), /* @__PURE__ */ k.createElement($s.Provider, {
|
|
2903
|
-
value: g.current
|
|
2904
|
-
}, z["container-start"], /* @__PURE__ */ k.createElement(n, {
|
|
2905
|
-
className: Ms(M.wrapperClass)
|
|
2906
|
-
}, z["wrapper-start"], F(), z["wrapper-end"]), ut(M) && /* @__PURE__ */ k.createElement(k.Fragment, null, /* @__PURE__ */ k.createElement("div", {
|
|
2907
|
-
ref: y,
|
|
2908
|
-
className: "swiper-button-prev"
|
|
2909
|
-
}), /* @__PURE__ */ k.createElement("div", {
|
|
2910
|
-
ref: S,
|
|
2911
|
-
className: "swiper-button-next"
|
|
2912
|
-
})), pt(M) && /* @__PURE__ */ k.createElement("div", {
|
|
2913
|
-
ref: I,
|
|
2914
|
-
className: "swiper-scrollbar"
|
|
2915
|
-
}), ft(M) && /* @__PURE__ */ k.createElement("div", {
|
|
2916
|
-
ref: P,
|
|
2917
|
-
className: "swiper-pagination"
|
|
2918
|
-
}), z["container-end"]));
|
|
2919
|
-
});
|
|
2920
|
-
vt.displayName = "Swiper";
|
|
2921
|
-
const wt = /* @__PURE__ */ Qe(function(t, e) {
|
|
2922
|
-
let {
|
|
2923
|
-
tag: i = "div",
|
|
2924
|
-
children: s,
|
|
2925
|
-
className: n = "",
|
|
2926
|
-
swiper: r,
|
|
2927
|
-
zoom: l,
|
|
2928
|
-
lazy: a,
|
|
2929
|
-
virtualIndex: o,
|
|
2930
|
-
swiperSlideIndex: c,
|
|
2931
|
-
...d
|
|
2932
|
-
} = t === void 0 ? {} : t;
|
|
2933
|
-
const p = U(null), [h, w] = X("swiper-slide"), [m, b] = X(!1);
|
|
2934
|
-
function x(S, y, P) {
|
|
2935
|
-
y === p.current && w(P);
|
|
2936
|
-
}
|
|
2937
|
-
fe(() => {
|
|
2938
|
-
if (typeof c < "u" && (p.current.swiperSlideIndex = c), e && (e.current = p.current), !(!p.current || !r)) {
|
|
2939
|
-
if (r.destroyed) {
|
|
2940
|
-
h !== "swiper-slide" && w("swiper-slide");
|
|
2941
|
-
return;
|
|
2942
|
-
}
|
|
2943
|
-
return r.on("_slideClass", x), () => {
|
|
2944
|
-
r && r.off("_slideClass", x);
|
|
2945
|
-
};
|
|
2946
|
-
}
|
|
2947
|
-
}), fe(() => {
|
|
2948
|
-
r && p.current && !r.destroyed && w(r.getSlideClasses(p.current));
|
|
2949
|
-
}, [r]);
|
|
2950
|
-
const g = {
|
|
2951
|
-
isActive: h.indexOf("swiper-slide-active") >= 0,
|
|
2952
|
-
isVisible: h.indexOf("swiper-slide-visible") >= 0,
|
|
2953
|
-
isPrev: h.indexOf("swiper-slide-prev") >= 0,
|
|
2954
|
-
isNext: h.indexOf("swiper-slide-next") >= 0
|
|
2955
|
-
}, u = () => typeof s == "function" ? s(g) : s, f = () => {
|
|
2956
|
-
b(!0);
|
|
2957
|
-
};
|
|
2958
|
-
return /* @__PURE__ */ k.createElement(i, Ee({
|
|
2959
|
-
ref: p,
|
|
2960
|
-
className: mt(`${h}${n ? ` ${n}` : ""}`),
|
|
2961
|
-
"data-swiper-slide-index": o,
|
|
2962
|
-
onLoad: f
|
|
2963
|
-
}, d), l && /* @__PURE__ */ k.createElement(Ke.Provider, {
|
|
2964
|
-
value: g
|
|
2965
|
-
}, /* @__PURE__ */ k.createElement("div", {
|
|
2966
|
-
className: "swiper-zoom-container",
|
|
2967
|
-
"data-swiper-zoom": typeof l == "number" ? l : void 0
|
|
2968
|
-
}, u(), a && !m && /* @__PURE__ */ k.createElement("div", {
|
|
2969
|
-
className: "swiper-lazy-preloader"
|
|
2970
|
-
}))), !l && /* @__PURE__ */ k.createElement(Ke.Provider, {
|
|
2971
|
-
value: g
|
|
2972
|
-
}, u(), a && !m && /* @__PURE__ */ k.createElement("div", {
|
|
2973
|
-
className: "swiper-lazy-preloader"
|
|
2974
|
-
})));
|
|
2975
|
-
});
|
|
2976
|
-
wt.displayName = "SwiperSlide";
|
|
2977
|
-
function St(t, e, i, s) {
|
|
2978
|
-
return t.params.createElements && Object.keys(s).forEach((n) => {
|
|
2979
|
-
if (!i[n] && i.auto === !0) {
|
|
2980
|
-
let r = Q(t.el, `.${s[n]}`)[0];
|
|
2981
|
-
r || (r = ye("div", s[n]), r.className = s[n], t.el.append(r)), i[n] = r, e[n] = r;
|
|
2982
|
-
}
|
|
2983
|
-
}), i;
|
|
2984
|
-
}
|
|
2985
|
-
function ks(t) {
|
|
2986
|
-
let {
|
|
2987
|
-
swiper: e,
|
|
2988
|
-
extendParams: i,
|
|
2989
|
-
on: s,
|
|
2990
|
-
emit: n
|
|
2991
|
-
} = t;
|
|
2992
|
-
i({
|
|
2993
|
-
navigation: {
|
|
2994
|
-
nextEl: null,
|
|
2995
|
-
prevEl: null,
|
|
2996
|
-
hideOnClick: !1,
|
|
2997
|
-
disabledClass: "swiper-button-disabled",
|
|
2998
|
-
hiddenClass: "swiper-button-hidden",
|
|
2999
|
-
lockClass: "swiper-button-lock",
|
|
3000
|
-
navigationDisabledClass: "swiper-navigation-disabled"
|
|
3001
|
-
}
|
|
3002
|
-
}), e.navigation = {
|
|
3003
|
-
nextEl: null,
|
|
3004
|
-
prevEl: null
|
|
3005
|
-
};
|
|
3006
|
-
function r(m) {
|
|
3007
|
-
let b;
|
|
3008
|
-
return m && typeof m == "string" && e.isElement && (b = e.el.querySelector(m) || e.hostEl.querySelector(m), b) ? b : (m && (typeof m == "string" && (b = [...document.querySelectorAll(m)]), e.params.uniqueNavElements && typeof m == "string" && b && b.length > 1 && e.el.querySelectorAll(m).length === 1 ? b = e.el.querySelector(m) : b && b.length === 1 && (b = b[0])), m && !b ? m : b);
|
|
3009
|
-
}
|
|
3010
|
-
function l(m, b) {
|
|
3011
|
-
const x = e.params.navigation;
|
|
3012
|
-
m = V(m), m.forEach((g) => {
|
|
3013
|
-
g && (g.classList[b ? "add" : "remove"](...x.disabledClass.split(" ")), g.tagName === "BUTTON" && (g.disabled = b), e.params.watchOverflow && e.enabled && g.classList[e.isLocked ? "add" : "remove"](x.lockClass));
|
|
3014
|
-
});
|
|
3015
|
-
}
|
|
3016
|
-
function a() {
|
|
3017
|
-
const {
|
|
3018
|
-
nextEl: m,
|
|
3019
|
-
prevEl: b
|
|
3020
|
-
} = e.navigation;
|
|
3021
|
-
if (e.params.loop) {
|
|
3022
|
-
l(b, !1), l(m, !1);
|
|
3023
|
-
return;
|
|
3024
|
-
}
|
|
3025
|
-
l(b, e.isBeginning && !e.params.rewind), l(m, e.isEnd && !e.params.rewind);
|
|
3026
|
-
}
|
|
3027
|
-
function o(m) {
|
|
3028
|
-
m.preventDefault(), !(e.isBeginning && !e.params.loop && !e.params.rewind) && (e.slidePrev(), n("navigationPrev"));
|
|
3029
|
-
}
|
|
3030
|
-
function c(m) {
|
|
3031
|
-
m.preventDefault(), !(e.isEnd && !e.params.loop && !e.params.rewind) && (e.slideNext(), n("navigationNext"));
|
|
3032
|
-
}
|
|
3033
|
-
function d() {
|
|
3034
|
-
const m = e.params.navigation;
|
|
3035
|
-
if (e.params.navigation = St(e, e.originalParams.navigation, e.params.navigation, {
|
|
3036
|
-
nextEl: "swiper-button-next",
|
|
3037
|
-
prevEl: "swiper-button-prev"
|
|
3038
|
-
}), !(m.nextEl || m.prevEl)) return;
|
|
3039
|
-
let b = r(m.nextEl), x = r(m.prevEl);
|
|
3040
|
-
Object.assign(e.navigation, {
|
|
3041
|
-
nextEl: b,
|
|
3042
|
-
prevEl: x
|
|
3043
|
-
}), b = V(b), x = V(x);
|
|
3044
|
-
const g = (u, f) => {
|
|
3045
|
-
u && u.addEventListener("click", f === "next" ? c : o), !e.enabled && u && u.classList.add(...m.lockClass.split(" "));
|
|
3046
|
-
};
|
|
3047
|
-
b.forEach((u) => g(u, "next")), x.forEach((u) => g(u, "prev"));
|
|
3048
|
-
}
|
|
3049
|
-
function p() {
|
|
3050
|
-
let {
|
|
3051
|
-
nextEl: m,
|
|
3052
|
-
prevEl: b
|
|
3053
|
-
} = e.navigation;
|
|
3054
|
-
m = V(m), b = V(b);
|
|
3055
|
-
const x = (g, u) => {
|
|
3056
|
-
g.removeEventListener("click", u === "next" ? c : o), g.classList.remove(...e.params.navigation.disabledClass.split(" "));
|
|
3057
|
-
};
|
|
3058
|
-
m.forEach((g) => x(g, "next")), b.forEach((g) => x(g, "prev"));
|
|
3059
|
-
}
|
|
3060
|
-
s("init", () => {
|
|
3061
|
-
e.params.navigation.enabled === !1 ? w() : (d(), a());
|
|
3062
|
-
}), s("toEdge fromEdge lock unlock", () => {
|
|
3063
|
-
a();
|
|
3064
|
-
}), s("destroy", () => {
|
|
3065
|
-
p();
|
|
3066
|
-
}), s("enable disable", () => {
|
|
3067
|
-
let {
|
|
3068
|
-
nextEl: m,
|
|
3069
|
-
prevEl: b
|
|
3070
|
-
} = e.navigation;
|
|
3071
|
-
if (m = V(m), b = V(b), e.enabled) {
|
|
3072
|
-
a();
|
|
3073
|
-
return;
|
|
3074
|
-
}
|
|
3075
|
-
[...m, ...b].filter((x) => !!x).forEach((x) => x.classList.add(e.params.navigation.lockClass));
|
|
3076
|
-
}), s("click", (m, b) => {
|
|
3077
|
-
let {
|
|
3078
|
-
nextEl: x,
|
|
3079
|
-
prevEl: g
|
|
3080
|
-
} = e.navigation;
|
|
3081
|
-
x = V(x), g = V(g);
|
|
3082
|
-
const u = b.target;
|
|
3083
|
-
let f = g.includes(u) || x.includes(u);
|
|
3084
|
-
if (e.isElement && !f) {
|
|
3085
|
-
const S = b.path || b.composedPath && b.composedPath();
|
|
3086
|
-
S && (f = S.find((y) => x.includes(y) || g.includes(y)));
|
|
3087
|
-
}
|
|
3088
|
-
if (e.params.navigation.hideOnClick && !f) {
|
|
3089
|
-
if (e.pagination && e.params.pagination && e.params.pagination.clickable && (e.pagination.el === u || e.pagination.el.contains(u))) return;
|
|
3090
|
-
let S;
|
|
3091
|
-
x.length ? S = x[0].classList.contains(e.params.navigation.hiddenClass) : g.length && (S = g[0].classList.contains(e.params.navigation.hiddenClass)), n(S === !0 ? "navigationShow" : "navigationHide"), [...x, ...g].filter((y) => !!y).forEach((y) => y.classList.toggle(e.params.navigation.hiddenClass));
|
|
3092
|
-
}
|
|
3093
|
-
});
|
|
3094
|
-
const h = () => {
|
|
3095
|
-
e.el.classList.remove(...e.params.navigation.navigationDisabledClass.split(" ")), d(), a();
|
|
3096
|
-
}, w = () => {
|
|
3097
|
-
e.el.classList.add(...e.params.navigation.navigationDisabledClass.split(" ")), p();
|
|
3098
|
-
};
|
|
3099
|
-
Object.assign(e.navigation, {
|
|
3100
|
-
enable: h,
|
|
3101
|
-
disable: w,
|
|
3102
|
-
update: a,
|
|
3103
|
-
init: d,
|
|
3104
|
-
destroy: p
|
|
3105
|
-
});
|
|
3106
|
-
}
|
|
3107
|
-
function ue(t) {
|
|
3108
|
-
return t === void 0 && (t = ""), `.${t.trim().replace(/([\.:!+\/()[\]])/g, "\\$1").replace(/ /g, ".")}`;
|
|
3109
|
-
}
|
|
3110
|
-
function Gs(t) {
|
|
3111
|
-
let {
|
|
3112
|
-
swiper: e,
|
|
3113
|
-
extendParams: i,
|
|
3114
|
-
on: s,
|
|
3115
|
-
emit: n
|
|
3116
|
-
} = t;
|
|
3117
|
-
const r = "swiper-pagination";
|
|
3118
|
-
i({
|
|
3119
|
-
pagination: {
|
|
3120
|
-
el: null,
|
|
3121
|
-
bulletElement: "span",
|
|
3122
|
-
clickable: !1,
|
|
3123
|
-
hideOnClick: !1,
|
|
3124
|
-
renderBullet: null,
|
|
3125
|
-
renderProgressbar: null,
|
|
3126
|
-
renderFraction: null,
|
|
3127
|
-
renderCustom: null,
|
|
3128
|
-
progressbarOpposite: !1,
|
|
3129
|
-
type: "bullets",
|
|
3130
|
-
// 'bullets' or 'progressbar' or 'fraction' or 'custom'
|
|
3131
|
-
dynamicBullets: !1,
|
|
3132
|
-
dynamicMainBullets: 1,
|
|
3133
|
-
formatFractionCurrent: (u) => u,
|
|
3134
|
-
formatFractionTotal: (u) => u,
|
|
3135
|
-
bulletClass: `${r}-bullet`,
|
|
3136
|
-
bulletActiveClass: `${r}-bullet-active`,
|
|
3137
|
-
modifierClass: `${r}-`,
|
|
3138
|
-
currentClass: `${r}-current`,
|
|
3139
|
-
totalClass: `${r}-total`,
|
|
3140
|
-
hiddenClass: `${r}-hidden`,
|
|
3141
|
-
progressbarFillClass: `${r}-progressbar-fill`,
|
|
3142
|
-
progressbarOppositeClass: `${r}-progressbar-opposite`,
|
|
3143
|
-
clickableClass: `${r}-clickable`,
|
|
3144
|
-
lockClass: `${r}-lock`,
|
|
3145
|
-
horizontalClass: `${r}-horizontal`,
|
|
3146
|
-
verticalClass: `${r}-vertical`,
|
|
3147
|
-
paginationDisabledClass: `${r}-disabled`
|
|
3148
|
-
}
|
|
3149
|
-
}), e.pagination = {
|
|
3150
|
-
el: null,
|
|
3151
|
-
bullets: []
|
|
3152
|
-
};
|
|
3153
|
-
let l, a = 0;
|
|
3154
|
-
function o() {
|
|
3155
|
-
return !e.params.pagination.el || !e.pagination.el || Array.isArray(e.pagination.el) && e.pagination.el.length === 0;
|
|
3156
|
-
}
|
|
3157
|
-
function c(u, f) {
|
|
3158
|
-
const {
|
|
3159
|
-
bulletActiveClass: S
|
|
3160
|
-
} = e.params.pagination;
|
|
3161
|
-
u && (u = u[`${f === "prev" ? "previous" : "next"}ElementSibling`], u && (u.classList.add(`${S}-${f}`), u = u[`${f === "prev" ? "previous" : "next"}ElementSibling`], u && u.classList.add(`${S}-${f}-${f}`)));
|
|
3162
|
-
}
|
|
3163
|
-
function d(u, f, S) {
|
|
3164
|
-
if (u = u % S, f = f % S, f === u + 1)
|
|
3165
|
-
return "next";
|
|
3166
|
-
if (f === u - 1)
|
|
3167
|
-
return "previous";
|
|
3168
|
-
}
|
|
3169
|
-
function p(u) {
|
|
3170
|
-
const f = u.target.closest(ue(e.params.pagination.bulletClass));
|
|
3171
|
-
if (!f)
|
|
3172
|
-
return;
|
|
3173
|
-
u.preventDefault();
|
|
3174
|
-
const S = xe(f) * e.params.slidesPerGroup;
|
|
3175
|
-
if (e.params.loop) {
|
|
3176
|
-
if (e.realIndex === S) return;
|
|
3177
|
-
const y = d(e.realIndex, S, e.slides.length);
|
|
3178
|
-
y === "next" ? e.slideNext() : y === "previous" ? e.slidePrev() : e.slideToLoop(S);
|
|
3179
|
-
} else
|
|
3180
|
-
e.slideTo(S);
|
|
3181
|
-
}
|
|
3182
|
-
function h() {
|
|
3183
|
-
const u = e.rtl, f = e.params.pagination;
|
|
3184
|
-
if (o()) return;
|
|
3185
|
-
let S = e.pagination.el;
|
|
3186
|
-
S = V(S);
|
|
3187
|
-
let y, P;
|
|
3188
|
-
const I = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length, M = e.params.loop ? Math.ceil(I / e.params.slidesPerGroup) : e.snapGrid.length;
|
|
3189
|
-
if (e.params.loop ? (P = e.previousRealIndex || 0, y = e.params.slidesPerGroup > 1 ? Math.floor(e.realIndex / e.params.slidesPerGroup) : e.realIndex) : typeof e.snapIndex < "u" ? (y = e.snapIndex, P = e.previousSnapIndex) : (P = e.previousIndex || 0, y = e.activeIndex || 0), f.type === "bullets" && e.pagination.bullets && e.pagination.bullets.length > 0) {
|
|
3190
|
-
const T = e.pagination.bullets;
|
|
3191
|
-
let E, C, _;
|
|
3192
|
-
if (f.dynamicBullets && (l = ke(T[0], e.isHorizontal() ? "width" : "height"), S.forEach((z) => {
|
|
3193
|
-
z.style[e.isHorizontal() ? "width" : "height"] = `${l * (f.dynamicMainBullets + 4)}px`;
|
|
3194
|
-
}), f.dynamicMainBullets > 1 && P !== void 0 && (a += y - (P || 0), a > f.dynamicMainBullets - 1 ? a = f.dynamicMainBullets - 1 : a < 0 && (a = 0)), E = Math.max(y - a, 0), C = E + (Math.min(T.length, f.dynamicMainBullets) - 1), _ = (C + E) / 2), T.forEach((z) => {
|
|
3195
|
-
const A = [...["", "-next", "-next-next", "-prev", "-prev-prev", "-main"].map(($) => `${f.bulletActiveClass}${$}`)].map(($) => typeof $ == "string" && $.includes(" ") ? $.split(" ") : $).flat();
|
|
3196
|
-
z.classList.remove(...A);
|
|
3197
|
-
}), S.length > 1)
|
|
3198
|
-
T.forEach((z) => {
|
|
3199
|
-
const A = xe(z);
|
|
3200
|
-
A === y ? z.classList.add(...f.bulletActiveClass.split(" ")) : e.isElement && z.setAttribute("part", "bullet"), f.dynamicBullets && (A >= E && A <= C && z.classList.add(...`${f.bulletActiveClass}-main`.split(" ")), A === E && c(z, "prev"), A === C && c(z, "next"));
|
|
3201
|
-
});
|
|
3202
|
-
else {
|
|
3203
|
-
const z = T[y];
|
|
3204
|
-
if (z && z.classList.add(...f.bulletActiveClass.split(" ")), e.isElement && T.forEach((A, $) => {
|
|
3205
|
-
A.setAttribute("part", $ === y ? "bullet-active" : "bullet");
|
|
3206
|
-
}), f.dynamicBullets) {
|
|
3207
|
-
const A = T[E], $ = T[C];
|
|
3208
|
-
for (let O = E; O <= C; O += 1)
|
|
3209
|
-
T[O] && T[O].classList.add(...`${f.bulletActiveClass}-main`.split(" "));
|
|
3210
|
-
c(A, "prev"), c($, "next");
|
|
3211
|
-
}
|
|
3212
|
-
}
|
|
3213
|
-
if (f.dynamicBullets) {
|
|
3214
|
-
const z = Math.min(T.length, f.dynamicMainBullets + 4), A = (l * z - l) / 2 - _ * l, $ = u ? "right" : "left";
|
|
3215
|
-
T.forEach((O) => {
|
|
3216
|
-
O.style[e.isHorizontal() ? $ : "top"] = `${A}px`;
|
|
3217
|
-
});
|
|
3218
|
-
}
|
|
3219
|
-
}
|
|
3220
|
-
S.forEach((T, E) => {
|
|
3221
|
-
if (f.type === "fraction" && (T.querySelectorAll(ue(f.currentClass)).forEach((C) => {
|
|
3222
|
-
C.textContent = f.formatFractionCurrent(y + 1);
|
|
3223
|
-
}), T.querySelectorAll(ue(f.totalClass)).forEach((C) => {
|
|
3224
|
-
C.textContent = f.formatFractionTotal(M);
|
|
3225
|
-
})), f.type === "progressbar") {
|
|
3226
|
-
let C;
|
|
3227
|
-
f.progressbarOpposite ? C = e.isHorizontal() ? "vertical" : "horizontal" : C = e.isHorizontal() ? "horizontal" : "vertical";
|
|
3228
|
-
const _ = (y + 1) / M;
|
|
3229
|
-
let z = 1, A = 1;
|
|
3230
|
-
C === "horizontal" ? z = _ : A = _, T.querySelectorAll(ue(f.progressbarFillClass)).forEach(($) => {
|
|
3231
|
-
$.style.transform = `translate3d(0,0,0) scaleX(${z}) scaleY(${A})`, $.style.transitionDuration = `${e.params.speed}ms`;
|
|
3232
|
-
});
|
|
3233
|
-
}
|
|
3234
|
-
f.type === "custom" && f.renderCustom ? (Te(T, f.renderCustom(e, y + 1, M)), E === 0 && n("paginationRender", T)) : (E === 0 && n("paginationRender", T), n("paginationUpdate", T)), e.params.watchOverflow && e.enabled && T.classList[e.isLocked ? "add" : "remove"](f.lockClass);
|
|
3235
|
-
});
|
|
3236
|
-
}
|
|
3237
|
-
function w() {
|
|
3238
|
-
const u = e.params.pagination;
|
|
3239
|
-
if (o()) return;
|
|
3240
|
-
const f = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.grid && e.params.grid.rows > 1 ? e.slides.length / Math.ceil(e.params.grid.rows) : e.slides.length;
|
|
3241
|
-
let S = e.pagination.el;
|
|
3242
|
-
S = V(S);
|
|
3243
|
-
let y = "";
|
|
3244
|
-
if (u.type === "bullets") {
|
|
3245
|
-
let P = e.params.loop ? Math.ceil(f / e.params.slidesPerGroup) : e.snapGrid.length;
|
|
3246
|
-
e.params.freeMode && e.params.freeMode.enabled && P > f && (P = f);
|
|
3247
|
-
for (let I = 0; I < P; I += 1)
|
|
3248
|
-
u.renderBullet ? y += u.renderBullet.call(e, I, u.bulletClass) : y += `<${u.bulletElement} ${e.isElement ? 'part="bullet"' : ""} class="${u.bulletClass}"></${u.bulletElement}>`;
|
|
3249
|
-
}
|
|
3250
|
-
u.type === "fraction" && (u.renderFraction ? y = u.renderFraction.call(e, u.currentClass, u.totalClass) : y = `<span class="${u.currentClass}"></span> / <span class="${u.totalClass}"></span>`), u.type === "progressbar" && (u.renderProgressbar ? y = u.renderProgressbar.call(e, u.progressbarFillClass) : y = `<span class="${u.progressbarFillClass}"></span>`), e.pagination.bullets = [], S.forEach((P) => {
|
|
3251
|
-
u.type !== "custom" && Te(P, y || ""), u.type === "bullets" && e.pagination.bullets.push(...P.querySelectorAll(ue(u.bulletClass)));
|
|
3252
|
-
}), u.type !== "custom" && n("paginationRender", S[0]);
|
|
3253
|
-
}
|
|
3254
|
-
function m() {
|
|
3255
|
-
e.params.pagination = St(e, e.originalParams.pagination, e.params.pagination, {
|
|
3256
|
-
el: "swiper-pagination"
|
|
3257
|
-
});
|
|
3258
|
-
const u = e.params.pagination;
|
|
3259
|
-
if (!u.el) return;
|
|
3260
|
-
let f;
|
|
3261
|
-
typeof u.el == "string" && e.isElement && (f = e.el.querySelector(u.el)), !f && typeof u.el == "string" && (f = [...document.querySelectorAll(u.el)]), f || (f = u.el), !(!f || f.length === 0) && (e.params.uniqueNavElements && typeof u.el == "string" && Array.isArray(f) && f.length > 1 && (f = [...e.el.querySelectorAll(u.el)], f.length > 1 && (f = f.find((S) => nt(S, ".swiper")[0] === e.el))), Array.isArray(f) && f.length === 1 && (f = f[0]), Object.assign(e.pagination, {
|
|
3262
|
-
el: f
|
|
3263
|
-
}), f = V(f), f.forEach((S) => {
|
|
3264
|
-
u.type === "bullets" && u.clickable && S.classList.add(...(u.clickableClass || "").split(" ")), S.classList.add(u.modifierClass + u.type), S.classList.add(e.isHorizontal() ? u.horizontalClass : u.verticalClass), u.type === "bullets" && u.dynamicBullets && (S.classList.add(`${u.modifierClass}${u.type}-dynamic`), a = 0, u.dynamicMainBullets < 1 && (u.dynamicMainBullets = 1)), u.type === "progressbar" && u.progressbarOpposite && S.classList.add(u.progressbarOppositeClass), u.clickable && S.addEventListener("click", p), e.enabled || S.classList.add(u.lockClass);
|
|
3265
|
-
}));
|
|
3266
|
-
}
|
|
3267
|
-
function b() {
|
|
3268
|
-
const u = e.params.pagination;
|
|
3269
|
-
if (o()) return;
|
|
3270
|
-
let f = e.pagination.el;
|
|
3271
|
-
f && (f = V(f), f.forEach((S) => {
|
|
3272
|
-
S.classList.remove(u.hiddenClass), S.classList.remove(u.modifierClass + u.type), S.classList.remove(e.isHorizontal() ? u.horizontalClass : u.verticalClass), u.clickable && (S.classList.remove(...(u.clickableClass || "").split(" ")), S.removeEventListener("click", p));
|
|
3273
|
-
})), e.pagination.bullets && e.pagination.bullets.forEach((S) => S.classList.remove(...u.bulletActiveClass.split(" ")));
|
|
3274
|
-
}
|
|
3275
|
-
s("changeDirection", () => {
|
|
3276
|
-
if (!e.pagination || !e.pagination.el) return;
|
|
3277
|
-
const u = e.params.pagination;
|
|
3278
|
-
let {
|
|
3279
|
-
el: f
|
|
3280
|
-
} = e.pagination;
|
|
3281
|
-
f = V(f), f.forEach((S) => {
|
|
3282
|
-
S.classList.remove(u.horizontalClass, u.verticalClass), S.classList.add(e.isHorizontal() ? u.horizontalClass : u.verticalClass);
|
|
3283
|
-
});
|
|
3284
|
-
}), s("init", () => {
|
|
3285
|
-
e.params.pagination.enabled === !1 ? g() : (m(), w(), h());
|
|
3286
|
-
}), s("activeIndexChange", () => {
|
|
3287
|
-
typeof e.snapIndex > "u" && h();
|
|
3288
|
-
}), s("snapIndexChange", () => {
|
|
3289
|
-
h();
|
|
3290
|
-
}), s("snapGridLengthChange", () => {
|
|
3291
|
-
w(), h();
|
|
3292
|
-
}), s("destroy", () => {
|
|
3293
|
-
b();
|
|
3294
|
-
}), s("enable disable", () => {
|
|
3295
|
-
let {
|
|
3296
|
-
el: u
|
|
3297
|
-
} = e.pagination;
|
|
3298
|
-
u && (u = V(u), u.forEach((f) => f.classList[e.enabled ? "remove" : "add"](e.params.pagination.lockClass)));
|
|
3299
|
-
}), s("lock unlock", () => {
|
|
3300
|
-
h();
|
|
3301
|
-
}), s("click", (u, f) => {
|
|
3302
|
-
const S = f.target, y = V(e.pagination.el);
|
|
3303
|
-
if (e.params.pagination.el && e.params.pagination.hideOnClick && y && y.length > 0 && !S.classList.contains(e.params.pagination.bulletClass)) {
|
|
3304
|
-
if (e.navigation && (e.navigation.nextEl && S === e.navigation.nextEl || e.navigation.prevEl && S === e.navigation.prevEl)) return;
|
|
3305
|
-
const P = y[0].classList.contains(e.params.pagination.hiddenClass);
|
|
3306
|
-
n(P === !0 ? "paginationShow" : "paginationHide"), y.forEach((I) => I.classList.toggle(e.params.pagination.hiddenClass));
|
|
3307
|
-
}
|
|
3308
|
-
});
|
|
3309
|
-
const x = () => {
|
|
3310
|
-
e.el.classList.remove(e.params.pagination.paginationDisabledClass);
|
|
3311
|
-
let {
|
|
3312
|
-
el: u
|
|
3313
|
-
} = e.pagination;
|
|
3314
|
-
u && (u = V(u), u.forEach((f) => f.classList.remove(e.params.pagination.paginationDisabledClass))), m(), w(), h();
|
|
3315
|
-
}, g = () => {
|
|
3316
|
-
e.el.classList.add(e.params.pagination.paginationDisabledClass);
|
|
3317
|
-
let {
|
|
3318
|
-
el: u
|
|
3319
|
-
} = e.pagination;
|
|
3320
|
-
u && (u = V(u), u.forEach((f) => f.classList.add(e.params.pagination.paginationDisabledClass))), b();
|
|
3321
|
-
};
|
|
3322
|
-
Object.assign(e.pagination, {
|
|
3323
|
-
enable: x,
|
|
3324
|
-
disable: g,
|
|
3325
|
-
render: w,
|
|
3326
|
-
update: h,
|
|
3327
|
-
init: m,
|
|
3328
|
-
destroy: b
|
|
3329
|
-
});
|
|
3330
|
-
}
|
|
3331
|
-
/**
|
|
3332
|
-
* @license lucide-react v0.542.0 - ISC
|
|
3333
|
-
*
|
|
3334
|
-
* This source code is licensed under the ISC license.
|
|
3335
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
3336
|
-
*/
|
|
3337
|
-
const Ds = [["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }]], ve = Ve("circle", Ds);
|
|
3338
|
-
/**
|
|
3339
|
-
* @license lucide-react v0.542.0 - ISC
|
|
3340
|
-
*
|
|
3341
|
-
* This source code is licensed under the ISC license.
|
|
3342
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
3343
|
-
*/
|
|
3344
|
-
const Bs = [
|
|
3345
|
-
["path", { d: "M18 8L22 12L18 16", key: "1r0oui" }],
|
|
3346
|
-
["path", { d: "M2 12H22", key: "1m8cig" }]
|
|
3347
|
-
], Vs = Ve("move-right", Bs);
|
|
3348
|
-
/**
|
|
3349
|
-
* @license lucide-react v0.542.0 - ISC
|
|
3350
|
-
*
|
|
3351
|
-
* This source code is licensed under the ISC license.
|
|
3352
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
3353
|
-
*/
|
|
3354
|
-
const Fs = [
|
|
3355
|
-
["path", { d: "M6 8L2 12L6 16", key: "kyvwex" }],
|
|
3356
|
-
["path", { d: "M2 12H22", key: "1m8cig" }]
|
|
3357
|
-
], Hs = Ve("move-left", Fs), Rs = "cZbkJ", js = "Wvq7U", Ws = "T2vT8", qs = "khI-G", Xs = "TiSFA", Ys = "eLmVC", Us = "q28da", K = {
|
|
3358
|
-
wrapper: Rs,
|
|
3359
|
-
title: js,
|
|
3360
|
-
image: Ws,
|
|
3361
|
-
productName: qs,
|
|
3362
|
-
productCategory: Xs,
|
|
3363
|
-
navButton: Ys,
|
|
3364
|
-
pagination: Us
|
|
3365
|
-
}, Ks = () => {
|
|
3366
|
-
var w, m, b;
|
|
3367
|
-
const { retailer: t, isLoading: e, locale: i } = te(), { t: s } = se("default"), [n, r] = X(null), [l, a] = X(0), o = U(null), c = () => {
|
|
3368
|
-
n && n.slideNext();
|
|
3369
|
-
}, d = () => {
|
|
3370
|
-
n && n.slidePrev();
|
|
3371
|
-
};
|
|
3372
|
-
if (!e && !((w = t == null ? void 0 : t.retailer_location_products) != null && w.length))
|
|
3373
|
-
return null;
|
|
3374
|
-
const p = (m = t == null ? void 0 : t.retailer_location_products) == null ? void 0 : m.map((x, g) => {
|
|
3375
|
-
var f;
|
|
3376
|
-
const u = ((f = x.images) == null ? void 0 : f[0]) || `https://placehold.co/684x507?text=${x.name}`;
|
|
3377
|
-
return /* @__PURE__ */ v(wt, { className: L(K.slide), children: /* @__PURE__ */ v("div", { children: /* @__PURE__ */ N("a", { href: (x == null ? void 0 : x.url) || "#", className: "d-inline-block text-decoration-none", children: [
|
|
3378
|
-
/* @__PURE__ */ v(
|
|
3379
|
-
"img",
|
|
3380
|
-
{
|
|
3381
|
-
className: L(K.image),
|
|
3382
|
-
src: u,
|
|
3383
|
-
alt: x.name
|
|
3384
|
-
}
|
|
3385
|
-
),
|
|
3386
|
-
/* @__PURE__ */ v("h3", { className: L(K.productName), children: x.name }),
|
|
3387
|
-
/* @__PURE__ */ v("p", { className: K.productCategory, children: x.category })
|
|
3388
|
-
] }) }) }, g);
|
|
3389
|
-
}), h = l === 0;
|
|
3390
|
-
return console.log("currentIndex", l, h), /* @__PURE__ */ N("section", { className: K.wrapper, children: [
|
|
3391
|
-
/* @__PURE__ */ v("h2", { className: L(K.title), children: s("retailer.product_feed.title") }),
|
|
3392
|
-
/* @__PURE__ */ v("div", { children: /* @__PURE__ */ v(
|
|
3393
|
-
vt,
|
|
3394
|
-
{
|
|
3395
|
-
className: L(K.swiper),
|
|
3396
|
-
slidesPerView: 1,
|
|
3397
|
-
spaceBetween: 16,
|
|
3398
|
-
autoHeight: !0,
|
|
3399
|
-
onSwiper: r,
|
|
3400
|
-
onSlideChange: (x) => a(x.activeIndex),
|
|
3401
|
-
modules: [Gs, ks],
|
|
3402
|
-
pagination: {
|
|
3403
|
-
dynamicBullets: !0,
|
|
3404
|
-
el: o.current,
|
|
3405
|
-
clickable: !0
|
|
3406
|
-
},
|
|
3407
|
-
breakpoints: {
|
|
3408
|
-
0: {
|
|
3409
|
-
slidesPerView: 1
|
|
3410
|
-
},
|
|
3411
|
-
640: {
|
|
3412
|
-
slidesPerView: 2
|
|
3413
|
-
},
|
|
3414
|
-
797: {
|
|
3415
|
-
slidesPerView: 3
|
|
3416
|
-
},
|
|
3417
|
-
924: {
|
|
3418
|
-
slidesPerView: 4
|
|
3419
|
-
},
|
|
3420
|
-
1200: {
|
|
3421
|
-
slidesPerView: 5
|
|
3422
|
-
}
|
|
3423
|
-
},
|
|
3424
|
-
children: p
|
|
3425
|
-
}
|
|
3426
|
-
) }),
|
|
3427
|
-
/* @__PURE__ */ N("div", { className: "d-flex align-items-center justify-content-center mt-4", children: [
|
|
3428
|
-
/* @__PURE__ */ v(Ae, { variant: "light", className: K.navButton, onClick: d, disabled: h, children: /* @__PURE__ */ v(Hs, {}) }),
|
|
3429
|
-
/* @__PURE__ */ v("div", { ref: o, className: `custom-pagination ${K.pagination}` }),
|
|
3430
|
-
/* @__PURE__ */ v(Ae, { variant: "light", className: K.navButton, onClick: c, disabled: n && l === ((b = t == null ? void 0 : t.retailer_location_products) == null ? void 0 : b.length) - n.params.slidesPerView, children: /* @__PURE__ */ v(Vs, {}) })
|
|
3431
|
-
] })
|
|
3432
|
-
] });
|
|
3433
|
-
}, Zs = "cRGD-", Qs = "JZbFO", Js = "q7sBX", en = "e0Iyb", tn = "M-2w0", sn = "_04I0I", J = {
|
|
3434
|
-
wrapper: Zs,
|
|
3435
|
-
h2: Qs,
|
|
3436
|
-
h3: Js,
|
|
3437
|
-
text: en,
|
|
3438
|
-
image: tn,
|
|
3439
|
-
link: sn
|
|
3440
|
-
}, nn = () => {
|
|
3441
|
-
const { locale: t } = te(), { t: e } = se("default");
|
|
3442
|
-
return /* @__PURE__ */ v("div", { className: L(J.wrapper), children: /* @__PURE__ */ N($e, { children: [
|
|
3443
|
-
/* @__PURE__ */ v(Z, { children: /* @__PURE__ */ N(q, { className: "text-center", children: [
|
|
3444
|
-
/* @__PURE__ */ v("h2", { className: L(J.h2), children: e("retailer.get_inspired.title") }),
|
|
3445
|
-
/* @__PURE__ */ v("p", { className: L(J.text), children: e("retailer.get_inspired.text") })
|
|
3446
|
-
] }) }),
|
|
3447
|
-
/* @__PURE__ */ N(Z, { children: [
|
|
3448
|
-
/* @__PURE__ */ N(q, { xs: 12, md: 6, children: [
|
|
3449
|
-
/* @__PURE__ */ v("span", { className: L(J.image), children: /* @__PURE__ */ v("img", { src: "https://ik.imagekit.io/ccimg/palliser/Palliser-store-details-quiz.jpg?updatedAt=1759260509721", alt: "", className: "img-fluid w-100" }) }),
|
|
3450
|
-
/* @__PURE__ */ v("h3", { className: L(J.h3), children: e("retailer.get_inspired.find_your_style.title") }),
|
|
3451
|
-
/* @__PURE__ */ v("p", { className: "fs-6", children: e("retailer.get_inspired.find_your_style.text") }),
|
|
3452
|
-
/* @__PURE__ */ N("a", { href: "https://www.palliser.com/style-finder", className: L(J.link), children: [
|
|
3453
|
-
e("retailer.get_inspired.find_your_style.cta"),
|
|
3454
|
-
" >"
|
|
3455
|
-
] })
|
|
3456
|
-
] }),
|
|
3457
|
-
/* @__PURE__ */ N(q, { xs: 12, md: 6, children: [
|
|
3458
|
-
/* @__PURE__ */ v("span", { className: L(J.image), children: /* @__PURE__ */ v("img", { src: "https://ik.imagekit.io/ccimg/palliser/Palliser-store-details-requestswatch.jpg?updatedAt=1759260516937", alt: "", className: "img-fluid w-100" }) }),
|
|
3459
|
-
/* @__PURE__ */ v("h3", { className: L(J.h3), children: e("retailer.get_inspired.request_a_swatch.title") }),
|
|
3460
|
-
/* @__PURE__ */ v("p", { className: "fs-6", children: e("retailer.get_inspired.request_a_swatch.text") }),
|
|
3461
|
-
/* @__PURE__ */ v("a", { href: "https://www.palliser.com/request-swatches", className: L(J.link), children: e("retailer.get_inspired.request_a_swatch.cta") })
|
|
3462
|
-
] })
|
|
3463
|
-
] })
|
|
3464
|
-
] }) });
|
|
3465
|
-
}, rn = "pLXZH", an = "EJh7m", Ne = {
|
|
3466
|
-
bg: rn,
|
|
3467
|
-
content: an
|
|
3468
|
-
}, ln = () => {
|
|
3469
|
-
var i, s;
|
|
3470
|
-
const { retailer: t } = te(), { t: e } = se("default");
|
|
3471
|
-
return /* @__PURE__ */ v("div", { className: Ne.container, children: /* @__PURE__ */ N("div", { className: Ne.bg, children: [
|
|
3472
|
-
/* @__PURE__ */ v("img", { src: "//cdn.sofasandsectionals.com/cc/retailer-main.jpg", alt: "Discover the Palliser Difference" }),
|
|
3473
|
-
/* @__PURE__ */ v(Z, { className: "mx-4", children: /* @__PURE__ */ v(q, { xs: 12, sm: 12, md: 12, lg: { span: 6, offset: 1 }, xl: { span: 4, offset: 1 }, children: /* @__PURE__ */ N("div", { className: Ne.content, children: [
|
|
3474
|
-
/* @__PURE__ */ v("h2", { children: e("discover_palliser.title", { retailerCity: (i = t == null ? void 0 : t.address) == null ? void 0 : i.city, retailerName: t.retailer_name }) }),
|
|
3475
|
-
/* @__PURE__ */ v("p", { className: "fs-6", children: e("discover_palliser.description", { retailerCity: (s = t == null ? void 0 : t.address) == null ? void 0 : s.city, retailerName: t.retailer_name }) })
|
|
3476
|
-
] }) }) })
|
|
3477
|
-
] }) });
|
|
3478
|
-
}, on = "qhCFp", dn = "b5DbC", cn = "As4TB", un = "_7Sbgn", fn = "rNiD8", pn = "WvNbK", R = {
|
|
3479
|
-
title: on,
|
|
3480
|
-
formGroup: dn,
|
|
3481
|
-
optIn: cn,
|
|
3482
|
-
submit: un,
|
|
3483
|
-
error: fn,
|
|
3484
|
-
success: pn
|
|
3485
|
-
}, mn = ({ messageModalOpen: t, setMessageModalOpen: e, selectedLocation: i, locale: s }) => {
|
|
3486
|
-
const { t: n } = se("default"), [r, l] = X(!1), a = /^((\\+[1-9]{1,4}[ \\-]*)|(\\([0-9]{2,3}\\)[ \\-]*)|([0-9]{2,4})[ \\-]*)*?[0-9]{3,4}?[ \\-]*[0-9]{3,4}?$/, o = Mt({
|
|
3487
|
-
name: pe().required(n("message.validation.name")),
|
|
3488
|
-
email: pe().email(n("message.validation.email")).required(n("message.validation.email")),
|
|
3489
|
-
phone: pe().matches(a, "Phone number is not valid"),
|
|
3490
|
-
message: pe().required(n("message.validation.message")),
|
|
3491
|
-
optIn: It().oneOf([!0], n("message.validation.optIn"))
|
|
3492
|
-
}), d = Lt({
|
|
3493
|
-
initialValues: {
|
|
3494
|
-
name: "",
|
|
3495
|
-
email: "",
|
|
3496
|
-
phone: "",
|
|
3497
|
-
message: "",
|
|
3498
|
-
optIn: !1
|
|
3499
|
-
},
|
|
3500
|
-
validationSchema: o,
|
|
3501
|
-
onSubmit: async (w) => {
|
|
3502
|
-
await new Promise((m) => setTimeout(m, 1e3)), l(!0);
|
|
3503
|
-
}
|
|
3504
|
-
}), p = () => {
|
|
3505
|
-
e(!1), l(!1), d.resetForm();
|
|
3506
|
-
}, h = document.querySelector(".cc") || null;
|
|
3507
|
-
return /* @__PURE__ */ N(me, { container: h, show: t, onHide: p, children: [
|
|
3508
|
-
/* @__PURE__ */ v(me.Header, { closeButton: !0, children: /* @__PURE__ */ N(me.Title, { className: L(R.title), children: [
|
|
3509
|
-
n("message.title"),
|
|
3510
|
-
" ",
|
|
3511
|
-
i == null ? void 0 : i.retailer_name
|
|
3512
|
-
] }) }),
|
|
3513
|
-
/* @__PURE__ */ v(me.Body, { children: /* @__PURE__ */ N(D, { onSubmit: d.handleSubmit, children: [
|
|
3514
|
-
/* @__PURE__ */ N(D.Group, { className: L(R.formGroup), children: [
|
|
3515
|
-
/* @__PURE__ */ v(D.Label, { children: n("message.name") }),
|
|
3516
|
-
/* @__PURE__ */ v(D.Control, { type: "text", name: "name", value: d.values.name, onChange: d.handleChange }),
|
|
3517
|
-
d.errors.name && d.touched.name && /* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.name })
|
|
3518
|
-
] }),
|
|
3519
|
-
/* @__PURE__ */ N(D.Group, { className: L(R.formGroup), children: [
|
|
3520
|
-
/* @__PURE__ */ v(D.Label, { children: n("message.email") }),
|
|
3521
|
-
/* @__PURE__ */ v(D.Control, { type: "email", name: "email", value: d.values.email, onChange: d.handleChange }),
|
|
3522
|
-
d.errors.email && /* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.email })
|
|
3523
|
-
] }),
|
|
3524
|
-
/* @__PURE__ */ N(D.Group, { className: L(R.formGroup), children: [
|
|
3525
|
-
/* @__PURE__ */ v(D.Label, { children: n("message.phone") }),
|
|
3526
|
-
/* @__PURE__ */ v(D.Control, { type: "tel", name: "phone", value: d.values.phone, onChange: d.handleChange }),
|
|
3527
|
-
d.errors.phone && /* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.phone })
|
|
3528
|
-
] }),
|
|
3529
|
-
/* @__PURE__ */ N(D.Group, { className: L(R.formGroup), children: [
|
|
3530
|
-
/* @__PURE__ */ v(D.Label, { children: n("message.message") }),
|
|
3531
|
-
/* @__PURE__ */ v(D.Control, { as: "textarea", name: "message", value: d.values.message, onChange: d.handleChange }),
|
|
3532
|
-
d.errors.message && /* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.message })
|
|
3533
|
-
] }),
|
|
3534
|
-
/* @__PURE__ */ N(D.Group, { className: L(R.formGroup, R.optIn), children: [
|
|
3535
|
-
/* @__PURE__ */ v(D.Check, { type: "checkbox", name: "optIn", label: n("message.optIn"), checked: d.values.optIn, onChange: d.handleChange }),
|
|
3536
|
-
d.errors.optIn && /* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.optIn })
|
|
3537
|
-
] }),
|
|
3538
|
-
/* @__PURE__ */ N(Ae, { className: L(R.submit), type: "submit", disabled: d.isSubmitting || r, children: [
|
|
3539
|
-
!r && /* @__PURE__ */ v(Ze, { children: d.isSubmitting ? n("message.sending") : n("message.send") }),
|
|
3540
|
-
r && n("message.sent"),
|
|
3541
|
-
d.isSubmitting && /* @__PURE__ */ v("img", { src: "https://images.sofasandsectionals.com/cc/pal-loader.svg", alt: "Loading", width: 20, height: 20 })
|
|
3542
|
-
] }),
|
|
3543
|
-
/* @__PURE__ */ v(D.Text, { className: L(R.success), children: r && n("message.success") }),
|
|
3544
|
-
/* @__PURE__ */ v(D.Text, { className: L(R.error), children: d.errors.general })
|
|
3545
|
-
] }) })
|
|
3546
|
-
] });
|
|
3547
|
-
}, hn = () => {
|
|
3548
|
-
const { messageModalOpen: t, setMessageModalOpen: e, retailer: i, locale: s } = te();
|
|
3549
|
-
return /* @__PURE__ */ v(mn, { messageModalOpen: t, setMessageModalOpen: e, selectedLocation: i, locale: s });
|
|
3550
|
-
}, gn = () => {
|
|
3551
|
-
var s, n;
|
|
3552
|
-
const { retailer: t } = te(), e = _t(), i = (t == null ? void 0 : t.store_type) === "Palliser Studio" ? e.studioSelected : e.standardSelected;
|
|
3553
|
-
return /* @__PURE__ */ v(
|
|
3554
|
-
Ot,
|
|
3555
|
-
{
|
|
3556
|
-
position: { lat: ((s = t == null ? void 0 : t.address) == null ? void 0 : s.latitude) * 1, lng: ((n = t == null ? void 0 : t.address) == null ? void 0 : n.longitude) * 1 },
|
|
3557
|
-
children: /* @__PURE__ */ v("img", { src: i, style: { width: 30 } })
|
|
3558
|
-
}
|
|
3559
|
-
);
|
|
3560
|
-
}, vn = {}, wn = () => {
|
|
3561
|
-
var l, a, o, c;
|
|
3562
|
-
const { retailer: t } = te(), e = Nt(), [i, s] = X(null), [n, r] = X(10);
|
|
3563
|
-
return re(() => {
|
|
3564
|
-
e && s(e);
|
|
3565
|
-
}, [e, s]), !((l = t == null ? void 0 : t.address) != null && l.latitude) || !((a = t == null ? void 0 : t.address) != null && a.longitude) ? null : /* @__PURE__ */ v(Ze, { children: /* @__PURE__ */ v(
|
|
3566
|
-
zt,
|
|
3567
|
-
{
|
|
3568
|
-
className: L(vn.map),
|
|
3569
|
-
zoom: n,
|
|
3570
|
-
center: {
|
|
3571
|
-
lat: ((o = t == null ? void 0 : t.address) == null ? void 0 : o.latitude) * 1,
|
|
3572
|
-
lng: ((c = t == null ? void 0 : t.address) == null ? void 0 : c.longitude) * 1
|
|
3573
|
-
},
|
|
3574
|
-
mapId: "fb10c7a27b297863",
|
|
3575
|
-
gestureHandling: "greedy",
|
|
3576
|
-
zoomControl: !0,
|
|
3577
|
-
disableDefaultUI: !0,
|
|
3578
|
-
children: /* @__PURE__ */ v(gn, { location: t }, t.id)
|
|
3579
|
-
}
|
|
3580
|
-
) });
|
|
3581
|
-
}, Sn = "bWrTW", bn = "HkXfs", ze = {
|
|
3582
|
-
video: Sn,
|
|
3583
|
-
studioInformation: bn
|
|
3584
|
-
}, yn = () => {
|
|
3585
|
-
var s;
|
|
3586
|
-
const { t } = se("default"), { retailer: e } = te();
|
|
3587
|
-
return ((s = e == null ? void 0 : e.store_type) == null ? void 0 : s.toLowerCase().includes("studio")) ? /* @__PURE__ */ N(Z, { className: `mb-5 ${ze.studioInformation}`, children: [
|
|
3588
|
-
/* @__PURE__ */ v(q, { xs: 12, md: 12, lg: 6, className: "mb-3", children: /* @__PURE__ */ v("div", { className: "d-flex align-items-center h-100", children: /* @__PURE__ */ v("video", { className: ze.video, autoPlay: !0, muted: !0, loop: !0, playsInline: !0, children: /* @__PURE__ */ v("source", { src: "//cdn.sofasandsectionals.com/cc/studio.mp4", type: "video/mp4" }) }) }) }),
|
|
3589
|
-
/* @__PURE__ */ v(q, { xs: 12, md: 12, lg: 6, className: "mb-3 d-flex align-items-center", children: /* @__PURE__ */ v("div", { children: /* @__PURE__ */ v("div", { children: /* @__PURE__ */ v(Z, { children: /* @__PURE__ */ v(q, { className: "text-center", children: /* @__PURE__ */ N("div", { className: L(ze.services), children: [
|
|
3590
|
-
/* @__PURE__ */ v("h3", { className: "text-start mb-3 fw-bold", children: t("studio_information.title") }),
|
|
3591
|
-
/* @__PURE__ */ N("div", { className: "text-start", children: [
|
|
3592
|
-
/* @__PURE__ */ N("div", { className: "mb-3 d-flex align-items-start", children: [
|
|
3593
|
-
/* @__PURE__ */ v("div", { className: "me-2 mt-2", children: /* @__PURE__ */ v(ve, { size: 6, fill: !0 }) }),
|
|
3594
|
-
/* @__PURE__ */ v("div", { className: "fs-6", dangerouslySetInnerHTML: { __html: t("studio_information.bullet_one") } })
|
|
3595
|
-
] }),
|
|
3596
|
-
/* @__PURE__ */ N("div", { className: "mb-3 d-flex align-items-start", children: [
|
|
3597
|
-
/* @__PURE__ */ v("div", { className: "me-2 mt-2", children: /* @__PURE__ */ v(ve, { size: 6, fill: !0 }) }),
|
|
3598
|
-
/* @__PURE__ */ v("div", { className: "fs-6", dangerouslySetInnerHTML: { __html: t("studio_information.bullet_two") } })
|
|
3599
|
-
] }),
|
|
3600
|
-
/* @__PURE__ */ N("div", { className: "mb-3 d-flex align-items-start", children: [
|
|
3601
|
-
/* @__PURE__ */ v("div", { className: "me-2 mt-2", children: /* @__PURE__ */ v(ve, { size: 6, fill: !0 }) }),
|
|
3602
|
-
/* @__PURE__ */ v("div", { className: "fs-6", dangerouslySetInnerHTML: { __html: t("studio_information.bullet_three") } })
|
|
3603
|
-
] }),
|
|
3604
|
-
/* @__PURE__ */ N("div", { className: "mb-3 d-flex align-items-start", children: [
|
|
3605
|
-
/* @__PURE__ */ v("div", { className: "me-2 mt-2", children: /* @__PURE__ */ v(ve, { size: 6, fill: !0 }) }),
|
|
3606
|
-
/* @__PURE__ */ v("div", { className: "fs-6", dangerouslySetInnerHTML: { __html: t("studio_information.bullet_four") } })
|
|
3607
|
-
] })
|
|
3608
|
-
] })
|
|
3609
|
-
] }) }) }) }) }) })
|
|
3610
|
-
] }) : null;
|
|
3611
|
-
}, xn = "yhT6j", Tn = {
|
|
3612
|
-
backToRetailers: xn
|
|
3613
|
-
};
|
|
3614
|
-
function Ln({ id: t, locale: e }) {
|
|
3615
|
-
return re(() => {
|
|
3616
|
-
Re.changeLanguage(e);
|
|
3617
|
-
}, [e]), /* @__PURE__ */ v(At, { i18n: Re, children: /* @__PURE__ */ v($t, { apiKey: "AIzaSyAnJmWEU1r63DiRWHkjczxzHyIEq3dhj4M", libraries: ["places"], children: /* @__PURE__ */ v(kt, { id: t, children: /* @__PURE__ */ N("div", { className: "cc-scope", children: [
|
|
3618
|
-
/* @__PURE__ */ N($e, { fluid: !0, className: "px-5", children: [
|
|
3619
|
-
/* @__PURE__ */ v(Z, { children: /* @__PURE__ */ v(q, { children: /* @__PURE__ */ v(li, {}) }) }),
|
|
3620
|
-
/* @__PURE__ */ N(Z, { className: "mb-5", children: [
|
|
3621
|
-
/* @__PURE__ */ v(q, { md: { span: 6 }, lg: { span: 4 }, children: /* @__PURE__ */ v(ni, {}) }),
|
|
3622
|
-
/* @__PURE__ */ v(q, { children: /* @__PURE__ */ v(wn, {}) })
|
|
3623
|
-
] }),
|
|
3624
|
-
/* @__PURE__ */ v(Z, { className: "mb-5", children: /* @__PURE__ */ v(q, { children: /* @__PURE__ */ v("div", { className: "py-3", children: /* @__PURE__ */ v(Ks, {}) }) }) }),
|
|
3625
|
-
/* @__PURE__ */ v(yn, {})
|
|
3626
|
-
] }),
|
|
3627
|
-
/* @__PURE__ */ v("div", { className: "mb-5", children: /* @__PURE__ */ v(ln, {}) }),
|
|
3628
|
-
/* @__PURE__ */ N($e, { children: [
|
|
3629
|
-
/* @__PURE__ */ v(Z, { children: /* @__PURE__ */ v(q, { children: /* @__PURE__ */ v(nn, {}) }) }),
|
|
3630
|
-
/* @__PURE__ */ v(Z, { children: /* @__PURE__ */ v(q, { children: /* @__PURE__ */ v("div", { className: "py-5 text-center fs-6", children: /* @__PURE__ */ v("a", { href: "/retailers", className: L(Tn.backToRetailers), children: "Back to Store Locator" }) }) }) })
|
|
3631
|
-
] }),
|
|
3632
|
-
/* @__PURE__ */ v(hn, {})
|
|
3633
|
-
] }) }) }) });
|
|
3634
|
-
}
|
|
3635
|
-
export {
|
|
3636
|
-
Ln as default
|
|
3637
|
-
};
|