gp-designer 1.0.53 → 1.0.55
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +1 -1
- package/dist/gp-designer.es.js +272 -270
- package/dist/gp-designer.umd.js +1 -1
- package/dist/spa/topic/css/common.css +9 -11
- package/dist/spa/topic/css/swiper-bundle.min.css +17 -0
- package/dist/spa/topic/html/demo-xiaoyuan.html +52 -0
- package/dist/spa/topic/js/index.js +42 -10
- package/dist/style.css +2 -2
- package/package.json +1 -1
- package/dist/spa/topic/js/jquery.1.10.2.js +0 -6
- package/dist/spa/topic/js/swiper.min.4.4.1.js +0 -3758
@@ -1,3758 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Swiper 4.4.1
|
3
|
-
* Most modern mobile touch slider and framework with hardware accelerated transitions
|
4
|
-
* http://www.idangero.us/swiper/
|
5
|
-
*
|
6
|
-
* Copyright 2014-2018 Vladimir Kharlampidi
|
7
|
-
*
|
8
|
-
* Released under the MIT License
|
9
|
-
*
|
10
|
-
* Released on: September 14, 2018
|
11
|
-
*/
|
12
|
-
! function (e, t) {
|
13
|
-
"object" == typeof exports && "undefined" != typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : e.Swiper = t()
|
14
|
-
}(this, function () {
|
15
|
-
"use strict";
|
16
|
-
var f = "undefined" == typeof document ? {
|
17
|
-
body: {},
|
18
|
-
addEventListener: function () {},
|
19
|
-
removeEventListener: function () {},
|
20
|
-
activeElement: {
|
21
|
-
blur: function () {},
|
22
|
-
nodeName: ""
|
23
|
-
},
|
24
|
-
querySelector: function () {
|
25
|
-
return null
|
26
|
-
},
|
27
|
-
querySelectorAll: function () {
|
28
|
-
return []
|
29
|
-
},
|
30
|
-
getElementById: function () {
|
31
|
-
return null
|
32
|
-
},
|
33
|
-
createEvent: function () {
|
34
|
-
return {
|
35
|
-
initEvent: function () {}
|
36
|
-
}
|
37
|
-
},
|
38
|
-
createElement: function () {
|
39
|
-
return {
|
40
|
-
children: [],
|
41
|
-
childNodes: [],
|
42
|
-
style: {},
|
43
|
-
setAttribute: function () {},
|
44
|
-
getElementsByTagName: function () {
|
45
|
-
return []
|
46
|
-
}
|
47
|
-
}
|
48
|
-
},
|
49
|
-
location: {
|
50
|
-
hash: ""
|
51
|
-
}
|
52
|
-
} : document,
|
53
|
-
Y = "undefined" == typeof window ? {
|
54
|
-
document: f,
|
55
|
-
navigator: {
|
56
|
-
userAgent: ""
|
57
|
-
},
|
58
|
-
location: {},
|
59
|
-
history: {},
|
60
|
-
CustomEvent: function () {
|
61
|
-
return this
|
62
|
-
},
|
63
|
-
addEventListener: function () {},
|
64
|
-
removeEventListener: function () {},
|
65
|
-
getComputedStyle: function () {
|
66
|
-
return {
|
67
|
-
getPropertyValue: function () {
|
68
|
-
return ""
|
69
|
-
}
|
70
|
-
}
|
71
|
-
},
|
72
|
-
Image: function () {},
|
73
|
-
Date: function () {},
|
74
|
-
screen: {},
|
75
|
-
setTimeout: function () {},
|
76
|
-
clearTimeout: function () {}
|
77
|
-
} : window,
|
78
|
-
l = function (e) {
|
79
|
-
for (var t = 0; t < e.length; t += 1) this[t] = e[t];
|
80
|
-
return this.length = e.length, this
|
81
|
-
};
|
82
|
-
|
83
|
-
function L(e, t) {
|
84
|
-
var a = [],
|
85
|
-
i = 0;
|
86
|
-
if (e && !t && e instanceof l) return e;
|
87
|
-
if (e)
|
88
|
-
if ("string" == typeof e) {
|
89
|
-
var s, r, n = e.trim();
|
90
|
-
if (0 <= n.indexOf("<") && 0 <= n.indexOf(">")) {
|
91
|
-
var o = "div";
|
92
|
-
for (0 === n.indexOf("<li") && (o = "ul"), 0 === n.indexOf("<tr") && (o = "tbody"), 0 !== n.indexOf("<td") && 0 !== n.indexOf("<th") || (o = "tr"), 0 === n.indexOf("<tbody") && (o = "table"), 0 === n.indexOf("<option") && (o = "select"), (r = f.createElement(o)).innerHTML = n, i = 0; i < r.childNodes.length; i += 1) a.push(r.childNodes[i])
|
93
|
-
} else
|
94
|
-
for (s = t || "#" !== e[0] || e.match(/[ .<>:~]/) ? (t || f).querySelectorAll(e.trim()) : [f.getElementById(e.trim().split("#")[1])], i = 0; i < s.length; i += 1) s[i] && a.push(s[i])
|
95
|
-
} else if (e.nodeType || e === Y || e === f) a.push(e);
|
96
|
-
else if (0 < e.length && e[0].nodeType)
|
97
|
-
for (i = 0; i < e.length; i += 1) a.push(e[i]);
|
98
|
-
return new l(a)
|
99
|
-
}
|
100
|
-
|
101
|
-
function r(e) {
|
102
|
-
for (var t = [], a = 0; a < e.length; a += 1) - 1 === t.indexOf(e[a]) && t.push(e[a]);
|
103
|
-
return t
|
104
|
-
}
|
105
|
-
L.fn = l.prototype, L.Class = l, L.Dom7 = l;
|
106
|
-
var t = {
|
107
|
-
addClass: function (e) {
|
108
|
-
if (void 0 === e) return this;
|
109
|
-
for (var t = e.split(" "), a = 0; a < t.length; a += 1)
|
110
|
-
for (var i = 0; i < this.length; i += 1) void 0 !== this[i] && void 0 !== this[i].classList && this[i].classList.add(t[a]);
|
111
|
-
return this
|
112
|
-
},
|
113
|
-
removeClass: function (e) {
|
114
|
-
for (var t = e.split(" "), a = 0; a < t.length; a += 1)
|
115
|
-
for (var i = 0; i < this.length; i += 1) void 0 !== this[i] && void 0 !== this[i].classList && this[i].classList.remove(t[a]);
|
116
|
-
return this
|
117
|
-
},
|
118
|
-
hasClass: function (e) {
|
119
|
-
return !!this[0] && this[0].classList.contains(e)
|
120
|
-
},
|
121
|
-
toggleClass: function (e) {
|
122
|
-
for (var t = e.split(" "), a = 0; a < t.length; a += 1)
|
123
|
-
for (var i = 0; i < this.length; i += 1) void 0 !== this[i] && void 0 !== this[i].classList && this[i].classList.toggle(t[a]);
|
124
|
-
return this
|
125
|
-
},
|
126
|
-
attr: function (e, t) {
|
127
|
-
var a = arguments;
|
128
|
-
if (1 === arguments.length && "string" == typeof e) return this[0] ? this[0].getAttribute(e) : void 0;
|
129
|
-
for (var i = 0; i < this.length; i += 1)
|
130
|
-
if (2 === a.length) this[i].setAttribute(e, t);
|
131
|
-
else
|
132
|
-
for (var s in e) this[i][s] = e[s], this[i].setAttribute(s, e[s]);
|
133
|
-
return this
|
134
|
-
},
|
135
|
-
removeAttr: function (e) {
|
136
|
-
for (var t = 0; t < this.length; t += 1) this[t].removeAttribute(e);
|
137
|
-
return this
|
138
|
-
},
|
139
|
-
data: function (e, t) {
|
140
|
-
var a;
|
141
|
-
if (void 0 !== t) {
|
142
|
-
for (var i = 0; i < this.length; i += 1)(a = this[i]).dom7ElementDataStorage || (a.dom7ElementDataStorage = {}), a.dom7ElementDataStorage[e] = t;
|
143
|
-
return this
|
144
|
-
}
|
145
|
-
if (a = this[0]) {
|
146
|
-
if (a.dom7ElementDataStorage && e in a.dom7ElementDataStorage) return a.dom7ElementDataStorage[e];
|
147
|
-
var s = a.getAttribute("data-" + e);
|
148
|
-
return s || void 0
|
149
|
-
}
|
150
|
-
},
|
151
|
-
transform: function (e) {
|
152
|
-
for (var t = 0; t < this.length; t += 1) {
|
153
|
-
var a = this[t].style;
|
154
|
-
a.webkitTransform = e, a.transform = e
|
155
|
-
}
|
156
|
-
return this
|
157
|
-
},
|
158
|
-
transition: function (e) {
|
159
|
-
"string" != typeof e && (e += "ms");
|
160
|
-
for (var t = 0; t < this.length; t += 1) {
|
161
|
-
var a = this[t].style;
|
162
|
-
a.webkitTransitionDuration = e, a.transitionDuration = e
|
163
|
-
}
|
164
|
-
return this
|
165
|
-
},
|
166
|
-
on: function () {
|
167
|
-
for (var e, t = [], a = arguments.length; a--;) t[a] = arguments[a];
|
168
|
-
var i = t[0],
|
169
|
-
r = t[1],
|
170
|
-
n = t[2],
|
171
|
-
s = t[3];
|
172
|
-
|
173
|
-
function o(e) {
|
174
|
-
var t = e.target;
|
175
|
-
if (t) {
|
176
|
-
var a = e.target.dom7EventData || [];
|
177
|
-
if (a.indexOf(e) < 0 && a.unshift(e), L(t).is(r)) n.apply(t, a);
|
178
|
-
else
|
179
|
-
for (var i = L(t).parents(), s = 0; s < i.length; s += 1) L(i[s]).is(r) && n.apply(i[s], a)
|
180
|
-
}
|
181
|
-
}
|
182
|
-
|
183
|
-
function l(e) {
|
184
|
-
var t = e && e.target && e.target.dom7EventData || [];
|
185
|
-
t.indexOf(e) < 0 && t.unshift(e), n.apply(this, t)
|
186
|
-
}
|
187
|
-
"function" == typeof t[1] && (i = (e = t)[0], n = e[1], s = e[2], r = void 0), s || (s = !1);
|
188
|
-
for (var d, p = i.split(" "), c = 0; c < this.length; c += 1) {
|
189
|
-
var u = this[c];
|
190
|
-
if (r)
|
191
|
-
for (d = 0; d < p.length; d += 1) {
|
192
|
-
var h = p[d];
|
193
|
-
u.dom7LiveListeners || (u.dom7LiveListeners = {}), u.dom7LiveListeners[h] || (u.dom7LiveListeners[h] = []), u.dom7LiveListeners[h].push({
|
194
|
-
listener: n,
|
195
|
-
proxyListener: o
|
196
|
-
}), u.addEventListener(h, o, s)
|
197
|
-
} else
|
198
|
-
for (d = 0; d < p.length; d += 1) {
|
199
|
-
var v = p[d];
|
200
|
-
u.dom7Listeners || (u.dom7Listeners = {}), u.dom7Listeners[v] || (u.dom7Listeners[v] = []), u.dom7Listeners[v].push({
|
201
|
-
listener: n,
|
202
|
-
proxyListener: l
|
203
|
-
}), u.addEventListener(v, l, s)
|
204
|
-
}
|
205
|
-
}
|
206
|
-
return this
|
207
|
-
},
|
208
|
-
off: function () {
|
209
|
-
for (var e, t = [], a = arguments.length; a--;) t[a] = arguments[a];
|
210
|
-
var i = t[0],
|
211
|
-
s = t[1],
|
212
|
-
r = t[2],
|
213
|
-
n = t[3];
|
214
|
-
"function" == typeof t[1] && (i = (e = t)[0], r = e[1], n = e[2], s = void 0), n || (n = !1);
|
215
|
-
for (var o = i.split(" "), l = 0; l < o.length; l += 1)
|
216
|
-
for (var d = o[l], p = 0; p < this.length; p += 1) {
|
217
|
-
var c = this[p],
|
218
|
-
u = void 0;
|
219
|
-
if (!s && c.dom7Listeners ? u = c.dom7Listeners[d] : s && c.dom7LiveListeners && (u = c.dom7LiveListeners[d]), u && u.length)
|
220
|
-
for (var h = u.length - 1; 0 <= h; h -= 1) {
|
221
|
-
var v = u[h];
|
222
|
-
r && v.listener === r ? (c.removeEventListener(d, v.proxyListener, n), u.splice(h, 1)) : r || (c.removeEventListener(d, v.proxyListener, n), u.splice(h, 1))
|
223
|
-
}
|
224
|
-
}
|
225
|
-
return this
|
226
|
-
},
|
227
|
-
trigger: function () {
|
228
|
-
for (var e = [], t = arguments.length; t--;) e[t] = arguments[t];
|
229
|
-
for (var a = e[0].split(" "), i = e[1], s = 0; s < a.length; s += 1)
|
230
|
-
for (var r = a[s], n = 0; n < this.length; n += 1) {
|
231
|
-
var o = this[n],
|
232
|
-
l = void 0;
|
233
|
-
try {
|
234
|
-
l = new Y.CustomEvent(r, {
|
235
|
-
detail: i,
|
236
|
-
bubbles: !0,
|
237
|
-
cancelable: !0
|
238
|
-
})
|
239
|
-
} catch (e) {
|
240
|
-
(l = f.createEvent("Event")).initEvent(r, !0, !0), l.detail = i
|
241
|
-
}
|
242
|
-
o.dom7EventData = e.filter(function (e, t) {
|
243
|
-
return 0 < t
|
244
|
-
}), o.dispatchEvent(l), o.dom7EventData = [], delete o.dom7EventData
|
245
|
-
}
|
246
|
-
return this
|
247
|
-
},
|
248
|
-
transitionEnd: function (t) {
|
249
|
-
var a, i = ["webkitTransitionEnd", "transitionend"],
|
250
|
-
s = this;
|
251
|
-
|
252
|
-
function r(e) {
|
253
|
-
if (e.target === this)
|
254
|
-
for (t.call(this, e), a = 0; a < i.length; a += 1) s.off(i[a], r)
|
255
|
-
}
|
256
|
-
if (t)
|
257
|
-
for (a = 0; a < i.length; a += 1) s.on(i[a], r);
|
258
|
-
return this
|
259
|
-
},
|
260
|
-
outerWidth: function (e) {
|
261
|
-
if (0 < this.length) {
|
262
|
-
if (e) {
|
263
|
-
var t = this.styles();
|
264
|
-
return this[0].offsetWidth + parseFloat(t.getPropertyValue("margin-right")) + parseFloat(t.getPropertyValue("margin-left"))
|
265
|
-
}
|
266
|
-
return this[0].offsetWidth
|
267
|
-
}
|
268
|
-
return null
|
269
|
-
},
|
270
|
-
outerHeight: function (e) {
|
271
|
-
if (0 < this.length) {
|
272
|
-
if (e) {
|
273
|
-
var t = this.styles();
|
274
|
-
return this[0].offsetHeight + parseFloat(t.getPropertyValue("margin-top")) + parseFloat(t.getPropertyValue("margin-bottom"))
|
275
|
-
}
|
276
|
-
return this[0].offsetHeight
|
277
|
-
}
|
278
|
-
return null
|
279
|
-
},
|
280
|
-
offset: function () {
|
281
|
-
if (0 < this.length) {
|
282
|
-
var e = this[0],
|
283
|
-
t = e.getBoundingClientRect(),
|
284
|
-
a = f.body,
|
285
|
-
i = e.clientTop || a.clientTop || 0,
|
286
|
-
s = e.clientLeft || a.clientLeft || 0,
|
287
|
-
r = e === Y ? Y.scrollY : e.scrollTop,
|
288
|
-
n = e === Y ? Y.scrollX : e.scrollLeft;
|
289
|
-
return {
|
290
|
-
top: t.top + r - i,
|
291
|
-
left: t.left + n - s
|
292
|
-
}
|
293
|
-
}
|
294
|
-
return null
|
295
|
-
},
|
296
|
-
css: function (e, t) {
|
297
|
-
var a;
|
298
|
-
if (1 === arguments.length) {
|
299
|
-
if ("string" != typeof e) {
|
300
|
-
for (a = 0; a < this.length; a += 1)
|
301
|
-
for (var i in e) this[a].style[i] = e[i];
|
302
|
-
return this
|
303
|
-
}
|
304
|
-
if (this[0]) return Y.getComputedStyle(this[0], null).getPropertyValue(e)
|
305
|
-
}
|
306
|
-
if (2 === arguments.length && "string" == typeof e) {
|
307
|
-
for (a = 0; a < this.length; a += 1) this[a].style[e] = t;
|
308
|
-
return this
|
309
|
-
}
|
310
|
-
return this
|
311
|
-
},
|
312
|
-
each: function (e) {
|
313
|
-
if (!e) return this;
|
314
|
-
for (var t = 0; t < this.length; t += 1)
|
315
|
-
if (!1 === e.call(this[t], t, this[t])) return this;
|
316
|
-
return this
|
317
|
-
},
|
318
|
-
html: function (e) {
|
319
|
-
if (void 0 === e) return this[0] ? this[0].innerHTML : void 0;
|
320
|
-
for (var t = 0; t < this.length; t += 1) this[t].innerHTML = e;
|
321
|
-
return this
|
322
|
-
},
|
323
|
-
text: function (e) {
|
324
|
-
if (void 0 === e) return this[0] ? this[0].textContent.trim() : null;
|
325
|
-
for (var t = 0; t < this.length; t += 1) this[t].textContent = e;
|
326
|
-
return this
|
327
|
-
},
|
328
|
-
is: function (e) {
|
329
|
-
var t, a, i = this[0];
|
330
|
-
if (!i || void 0 === e) return !1;
|
331
|
-
if ("string" == typeof e) {
|
332
|
-
if (i.matches) return i.matches(e);
|
333
|
-
if (i.webkitMatchesSelector) return i.webkitMatchesSelector(e);
|
334
|
-
if (i.msMatchesSelector) return i.msMatchesSelector(e);
|
335
|
-
for (t = L(e), a = 0; a < t.length; a += 1)
|
336
|
-
if (t[a] === i) return !0;
|
337
|
-
return !1
|
338
|
-
}
|
339
|
-
if (e === f) return i === f;
|
340
|
-
if (e === Y) return i === Y;
|
341
|
-
if (e.nodeType || e instanceof l) {
|
342
|
-
for (t = e.nodeType ? [e] : e, a = 0; a < t.length; a += 1)
|
343
|
-
if (t[a] === i) return !0;
|
344
|
-
return !1
|
345
|
-
}
|
346
|
-
return !1
|
347
|
-
},
|
348
|
-
index: function () {
|
349
|
-
var e, t = this[0];
|
350
|
-
if (t) {
|
351
|
-
for (e = 0; null !== (t = t.previousSibling);) 1 === t.nodeType && (e += 1);
|
352
|
-
return e
|
353
|
-
}
|
354
|
-
},
|
355
|
-
eq: function (e) {
|
356
|
-
if (void 0 === e) return this;
|
357
|
-
var t, a = this.length;
|
358
|
-
return new l(a - 1 < e ? [] : e < 0 ? (t = a + e) < 0 ? [] : [this[t]] : [this[e]])
|
359
|
-
},
|
360
|
-
append: function () {
|
361
|
-
for (var e, t = [], a = arguments.length; a--;) t[a] = arguments[a];
|
362
|
-
for (var i = 0; i < t.length; i += 1) {
|
363
|
-
e = t[i];
|
364
|
-
for (var s = 0; s < this.length; s += 1)
|
365
|
-
if ("string" == typeof e) {
|
366
|
-
var r = f.createElement("div");
|
367
|
-
for (r.innerHTML = e; r.firstChild;) this[s].appendChild(r.firstChild)
|
368
|
-
} else if (e instanceof l)
|
369
|
-
for (var n = 0; n < e.length; n += 1) this[s].appendChild(e[n]);
|
370
|
-
else this[s].appendChild(e)
|
371
|
-
}
|
372
|
-
return this
|
373
|
-
},
|
374
|
-
prepend: function (e) {
|
375
|
-
var t, a, i = this;
|
376
|
-
for (t = 0; t < this.length; t += 1)
|
377
|
-
if ("string" == typeof e) {
|
378
|
-
var s = f.createElement("div");
|
379
|
-
for (s.innerHTML = e, a = s.childNodes.length - 1; 0 <= a; a -= 1) i[t].insertBefore(s.childNodes[a], i[t].childNodes[0])
|
380
|
-
} else if (e instanceof l)
|
381
|
-
for (a = 0; a < e.length; a += 1) i[t].insertBefore(e[a], i[t].childNodes[0]);
|
382
|
-
else i[t].insertBefore(e, i[t].childNodes[0]);
|
383
|
-
return this
|
384
|
-
},
|
385
|
-
next: function (e) {
|
386
|
-
return 0 < this.length ? e ? this[0].nextElementSibling && L(this[0].nextElementSibling).is(e) ? new l([this[0].nextElementSibling]) : new l([]) : this[0].nextElementSibling ? new l([this[0].nextElementSibling]) : new l([]) : new l([])
|
387
|
-
},
|
388
|
-
nextAll: function (e) {
|
389
|
-
var t = [],
|
390
|
-
a = this[0];
|
391
|
-
if (!a) return new l([]);
|
392
|
-
for (; a.nextElementSibling;) {
|
393
|
-
var i = a.nextElementSibling;
|
394
|
-
e ? L(i).is(e) && t.push(i) : t.push(i), a = i
|
395
|
-
}
|
396
|
-
return new l(t)
|
397
|
-
},
|
398
|
-
prev: function (e) {
|
399
|
-
if (0 < this.length) {
|
400
|
-
var t = this[0];
|
401
|
-
return e ? t.previousElementSibling && L(t.previousElementSibling).is(e) ? new l([t.previousElementSibling]) : new l([]) : t.previousElementSibling ? new l([t.previousElementSibling]) : new l([])
|
402
|
-
}
|
403
|
-
return new l([])
|
404
|
-
},
|
405
|
-
prevAll: function (e) {
|
406
|
-
var t = [],
|
407
|
-
a = this[0];
|
408
|
-
if (!a) return new l([]);
|
409
|
-
for (; a.previousElementSibling;) {
|
410
|
-
var i = a.previousElementSibling;
|
411
|
-
e ? L(i).is(e) && t.push(i) : t.push(i), a = i
|
412
|
-
}
|
413
|
-
return new l(t)
|
414
|
-
},
|
415
|
-
parent: function (e) {
|
416
|
-
for (var t = [], a = 0; a < this.length; a += 1) null !== this[a].parentNode && (e ? L(this[a].parentNode).is(e) && t.push(this[a].parentNode) : t.push(this[a].parentNode));
|
417
|
-
return L(r(t))
|
418
|
-
},
|
419
|
-
parents: function (e) {
|
420
|
-
for (var t = [], a = 0; a < this.length; a += 1)
|
421
|
-
for (var i = this[a].parentNode; i;) e ? L(i).is(e) && t.push(i) : t.push(i), i = i.parentNode;
|
422
|
-
return L(r(t))
|
423
|
-
},
|
424
|
-
closest: function (e) {
|
425
|
-
var t = this;
|
426
|
-
return void 0 === e ? new l([]) : (t.is(e) || (t = t.parents(e).eq(0)), t)
|
427
|
-
},
|
428
|
-
find: function (e) {
|
429
|
-
for (var t = [], a = 0; a < this.length; a += 1)
|
430
|
-
for (var i = this[a].querySelectorAll(e), s = 0; s < i.length; s += 1) t.push(i[s]);
|
431
|
-
return new l(t)
|
432
|
-
},
|
433
|
-
children: function (e) {
|
434
|
-
for (var t = [], a = 0; a < this.length; a += 1)
|
435
|
-
for (var i = this[a].childNodes, s = 0; s < i.length; s += 1) e ? 1 === i[s].nodeType && L(i[s]).is(e) && t.push(i[s]) : 1 === i[s].nodeType && t.push(i[s]);
|
436
|
-
return new l(r(t))
|
437
|
-
},
|
438
|
-
remove: function () {
|
439
|
-
for (var e = 0; e < this.length; e += 1) this[e].parentNode && this[e].parentNode.removeChild(this[e]);
|
440
|
-
return this
|
441
|
-
},
|
442
|
-
add: function () {
|
443
|
-
for (var e = [], t = arguments.length; t--;) e[t] = arguments[t];
|
444
|
-
var a, i;
|
445
|
-
for (a = 0; a < e.length; a += 1) {
|
446
|
-
var s = L(e[a]);
|
447
|
-
for (i = 0; i < s.length; i += 1) this[this.length] = s[i], this.length += 1
|
448
|
-
}
|
449
|
-
return this
|
450
|
-
},
|
451
|
-
styles: function () {
|
452
|
-
return this[0] ? Y.getComputedStyle(this[0], null) : {}
|
453
|
-
}
|
454
|
-
};
|
455
|
-
Object.keys(t).forEach(function (e) {
|
456
|
-
L.fn[e] = t[e]
|
457
|
-
});
|
458
|
-
var e, a, i, V = {
|
459
|
-
deleteProps: function (e) {
|
460
|
-
var t = e;
|
461
|
-
Object.keys(t).forEach(function (e) {
|
462
|
-
try {
|
463
|
-
t[e] = null
|
464
|
-
} catch (e) {}
|
465
|
-
try {
|
466
|
-
delete t[e]
|
467
|
-
} catch (e) {}
|
468
|
-
})
|
469
|
-
},
|
470
|
-
nextTick: function (e, t) {
|
471
|
-
return void 0 === t && (t = 0), setTimeout(e, t)
|
472
|
-
},
|
473
|
-
now: function () {
|
474
|
-
return Date.now()
|
475
|
-
},
|
476
|
-
getTranslate: function (e, t) {
|
477
|
-
var a, i, s;
|
478
|
-
void 0 === t && (t = "x");
|
479
|
-
var r = Y.getComputedStyle(e, null);
|
480
|
-
return Y.WebKitCSSMatrix ? (6 < (i = r.transform || r.webkitTransform).split(",").length && (i = i.split(", ").map(function (e) {
|
481
|
-
return e.replace(",", ".")
|
482
|
-
}).join(", ")), s = new Y.WebKitCSSMatrix("none" === i ? "" : i)) : a = (s = r.MozTransform || r.OTransform || r.MsTransform || r.msTransform || r.transform || r.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,")).toString().split(","), "x" === t && (i = Y.WebKitCSSMatrix ? s.m41 : 16 === a.length ? parseFloat(a[12]) : parseFloat(a[4])), "y" === t && (i = Y.WebKitCSSMatrix ? s.m42 : 16 === a.length ? parseFloat(a[13]) : parseFloat(a[5])), i || 0
|
483
|
-
},
|
484
|
-
parseUrlQuery: function (e) {
|
485
|
-
var t, a, i, s, r = {},
|
486
|
-
n = e || Y.location.href;
|
487
|
-
if ("string" == typeof n && n.length)
|
488
|
-
for (s = (a = (n = -1 < n.indexOf("?") ? n.replace(/\S*\?/, "") : "").split("&").filter(function (e) {
|
489
|
-
return "" !== e
|
490
|
-
})).length, t = 0; t < s; t += 1) i = a[t].replace(/#\S+/g, "").split("="), r[decodeURIComponent(i[0])] = void 0 === i[1] ? void 0 : decodeURIComponent(i[1]) || "";
|
491
|
-
return r
|
492
|
-
},
|
493
|
-
isObject: function (e) {
|
494
|
-
return "object" == typeof e && null !== e && e.constructor && e.constructor === Object
|
495
|
-
},
|
496
|
-
extend: function () {
|
497
|
-
for (var e = [], t = arguments.length; t--;) e[t] = arguments[t];
|
498
|
-
for (var a = Object(e[0]), i = 1; i < e.length; i += 1) {
|
499
|
-
var s = e[i];
|
500
|
-
if (null != s)
|
501
|
-
for (var r = Object.keys(Object(s)), n = 0, o = r.length; n < o; n += 1) {
|
502
|
-
var l = r[n],
|
503
|
-
d = Object.getOwnPropertyDescriptor(s, l);
|
504
|
-
void 0 !== d && d.enumerable && (V.isObject(a[l]) && V.isObject(s[l]) ? V.extend(a[l], s[l]) : !V.isObject(a[l]) && V.isObject(s[l]) ? (a[l] = {}, V.extend(a[l], s[l])) : a[l] = s[l])
|
505
|
-
}
|
506
|
-
}
|
507
|
-
return a
|
508
|
-
}
|
509
|
-
},
|
510
|
-
R = (i = f.createElement("div"), {
|
511
|
-
touch: Y.Modernizr && !0 === Y.Modernizr.touch || !!("ontouchstart" in Y || Y.DocumentTouch && f instanceof Y.DocumentTouch),
|
512
|
-
pointerEvents: !(!Y.navigator.pointerEnabled && !Y.PointerEvent),
|
513
|
-
prefixedPointerEvents: !!Y.navigator.msPointerEnabled,
|
514
|
-
transition: (a = i.style, "transition" in a || "webkitTransition" in a || "MozTransition" in a),
|
515
|
-
transforms3d: Y.Modernizr && !0 === Y.Modernizr.csstransforms3d || (e = i.style, "webkitPerspective" in e || "MozPerspective" in e || "OPerspective" in e || "MsPerspective" in e || "perspective" in e),
|
516
|
-
flexbox: function () {
|
517
|
-
for (var e = i.style, t = "alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient".split(" "), a = 0; a < t.length; a += 1)
|
518
|
-
if (t[a] in e) return !0;
|
519
|
-
return !1
|
520
|
-
}(),
|
521
|
-
observer: "MutationObserver" in Y || "WebkitMutationObserver" in Y,
|
522
|
-
passiveListener: function () {
|
523
|
-
var e = !1;
|
524
|
-
try {
|
525
|
-
var t = Object.defineProperty({}, "passive", {
|
526
|
-
get: function () {
|
527
|
-
e = !0
|
528
|
-
}
|
529
|
-
});
|
530
|
-
Y.addEventListener("testPassiveListener", null, t)
|
531
|
-
} catch (e) {}
|
532
|
-
return e
|
533
|
-
}(),
|
534
|
-
gestures: "ongesturestart" in Y
|
535
|
-
}),
|
536
|
-
s = function (e) {
|
537
|
-
void 0 === e && (e = {});
|
538
|
-
var t = this;
|
539
|
-
t.params = e, t.eventsListeners = {}, t.params && t.params.on && Object.keys(t.params.on).forEach(function (e) {
|
540
|
-
t.on(e, t.params.on[e])
|
541
|
-
})
|
542
|
-
},
|
543
|
-
n = {
|
544
|
-
components: {
|
545
|
-
configurable: !0
|
546
|
-
}
|
547
|
-
};
|
548
|
-
s.prototype.on = function (e, t, a) {
|
549
|
-
var i = this;
|
550
|
-
if ("function" != typeof t) return i;
|
551
|
-
var s = a ? "unshift" : "push";
|
552
|
-
return e.split(" ").forEach(function (e) {
|
553
|
-
i.eventsListeners[e] || (i.eventsListeners[e] = []), i.eventsListeners[e][s](t)
|
554
|
-
}), i
|
555
|
-
}, s.prototype.once = function (i, s, e) {
|
556
|
-
var r = this;
|
557
|
-
if ("function" != typeof s) return r;
|
558
|
-
return r.on(i, function e() {
|
559
|
-
for (var t = [], a = arguments.length; a--;) t[a] = arguments[a];
|
560
|
-
s.apply(r, t), r.off(i, e)
|
561
|
-
}, e)
|
562
|
-
}, s.prototype.off = function (e, i) {
|
563
|
-
var s = this;
|
564
|
-
return s.eventsListeners && e.split(" ").forEach(function (a) {
|
565
|
-
void 0 === i ? s.eventsListeners[a] = [] : s.eventsListeners[a] && s.eventsListeners[a].length && s.eventsListeners[a].forEach(function (e, t) {
|
566
|
-
e === i && s.eventsListeners[a].splice(t, 1)
|
567
|
-
})
|
568
|
-
}), s
|
569
|
-
}, s.prototype.emit = function () {
|
570
|
-
for (var e = [], t = arguments.length; t--;) e[t] = arguments[t];
|
571
|
-
var a, i, s, r = this;
|
572
|
-
return r.eventsListeners && ("string" == typeof e[0] || Array.isArray(e[0]) ? (a = e[0], i = e.slice(1, e.length), s = r) : (a = e[0].events, i = e[0].data, s = e[0].context || r), (Array.isArray(a) ? a : a.split(" ")).forEach(function (e) {
|
573
|
-
if (r.eventsListeners && r.eventsListeners[e]) {
|
574
|
-
var t = [];
|
575
|
-
r.eventsListeners[e].forEach(function (e) {
|
576
|
-
t.push(e)
|
577
|
-
}), t.forEach(function (e) {
|
578
|
-
e.apply(s, i)
|
579
|
-
})
|
580
|
-
}
|
581
|
-
})), r
|
582
|
-
}, s.prototype.useModulesParams = function (a) {
|
583
|
-
var i = this;
|
584
|
-
i.modules && Object.keys(i.modules).forEach(function (e) {
|
585
|
-
var t = i.modules[e];
|
586
|
-
t.params && V.extend(a, t.params)
|
587
|
-
})
|
588
|
-
}, s.prototype.useModules = function (i) {
|
589
|
-
void 0 === i && (i = {});
|
590
|
-
var s = this;
|
591
|
-
s.modules && Object.keys(s.modules).forEach(function (e) {
|
592
|
-
var a = s.modules[e],
|
593
|
-
t = i[e] || {};
|
594
|
-
a.instance && Object.keys(a.instance).forEach(function (e) {
|
595
|
-
var t = a.instance[e];
|
596
|
-
s[e] = "function" == typeof t ? t.bind(s) : t
|
597
|
-
}), a.on && s.on && Object.keys(a.on).forEach(function (e) {
|
598
|
-
s.on(e, a.on[e])
|
599
|
-
}), a.create && a.create.bind(s)(t)
|
600
|
-
})
|
601
|
-
}, n.components.set = function (e) {
|
602
|
-
this.use && this.use(e)
|
603
|
-
}, s.installModule = function (t) {
|
604
|
-
for (var e = [], a = arguments.length - 1; 0 < a--;) e[a] = arguments[a + 1];
|
605
|
-
var i = this;
|
606
|
-
i.prototype.modules || (i.prototype.modules = {});
|
607
|
-
var s = t.name || Object.keys(i.prototype.modules).length + "_" + V.now();
|
608
|
-
return (i.prototype.modules[s] = t).proto && Object.keys(t.proto).forEach(function (e) {
|
609
|
-
i.prototype[e] = t.proto[e]
|
610
|
-
}), t.static && Object.keys(t.static).forEach(function (e) {
|
611
|
-
i[e] = t.static[e]
|
612
|
-
}), t.install && t.install.apply(i, e), i
|
613
|
-
}, s.use = function (e) {
|
614
|
-
for (var t = [], a = arguments.length - 1; 0 < a--;) t[a] = arguments[a + 1];
|
615
|
-
var i = this;
|
616
|
-
return Array.isArray(e) ? (e.forEach(function (e) {
|
617
|
-
return i.installModule(e)
|
618
|
-
}), i) : i.installModule.apply(i, [e].concat(t))
|
619
|
-
}, Object.defineProperties(s, n);
|
620
|
-
var o = {
|
621
|
-
updateSize: function () {
|
622
|
-
var e, t, a = this,
|
623
|
-
i = a.$el;
|
624
|
-
e = void 0 !== a.params.width ? a.params.width : i[0].clientWidth, t = void 0 !== a.params.height ? a.params.height : i[0].clientHeight, 0 === e && a.isHorizontal() || 0 === t && a.isVertical() || (e = e - parseInt(i.css("padding-left"), 10) - parseInt(i.css("padding-right"), 10), t = t - parseInt(i.css("padding-top"), 10) - parseInt(i.css("padding-bottom"), 10), V.extend(a, {
|
625
|
-
width: e,
|
626
|
-
height: t,
|
627
|
-
size: a.isHorizontal() ? e : t
|
628
|
-
}))
|
629
|
-
},
|
630
|
-
updateSlides: function () {
|
631
|
-
var e = this,
|
632
|
-
t = e.params,
|
633
|
-
a = e.$wrapperEl,
|
634
|
-
i = e.size,
|
635
|
-
s = e.rtlTranslate,
|
636
|
-
r = e.wrongRTL,
|
637
|
-
n = e.virtual && t.virtual.enabled,
|
638
|
-
o = n ? e.virtual.slides.length : e.slides.length,
|
639
|
-
l = a.children("." + e.params.slideClass),
|
640
|
-
d = n ? e.virtual.slides.length : l.length,
|
641
|
-
p = [],
|
642
|
-
c = [],
|
643
|
-
u = [],
|
644
|
-
h = t.slidesOffsetBefore;
|
645
|
-
"function" == typeof h && (h = t.slidesOffsetBefore.call(e));
|
646
|
-
var v = t.slidesOffsetAfter;
|
647
|
-
"function" == typeof v && (v = t.slidesOffsetAfter.call(e));
|
648
|
-
var f = e.snapGrid.length,
|
649
|
-
m = e.snapGrid.length,
|
650
|
-
g = t.spaceBetween,
|
651
|
-
b = -h,
|
652
|
-
w = 0,
|
653
|
-
y = 0;
|
654
|
-
if (void 0 !== i) {
|
655
|
-
var x, T;
|
656
|
-
"string" == typeof g && 0 <= g.indexOf("%") && (g = parseFloat(g.replace("%", "")) / 100 * i), e.virtualSize = -g, s ? l.css({
|
657
|
-
marginLeft: "",
|
658
|
-
marginTop: ""
|
659
|
-
}) : l.css({
|
660
|
-
marginRight: "",
|
661
|
-
marginBottom: ""
|
662
|
-
}), 1 < t.slidesPerColumn && (x = Math.floor(d / t.slidesPerColumn) === d / e.params.slidesPerColumn ? d : Math.ceil(d / t.slidesPerColumn) * t.slidesPerColumn, "auto" !== t.slidesPerView && "row" === t.slidesPerColumnFill && (x = Math.max(x, t.slidesPerView * t.slidesPerColumn)));
|
663
|
-
for (var E, S = t.slidesPerColumn, C = x / S, M = C - (t.slidesPerColumn * C - d), k = 0; k < d; k += 1) {
|
664
|
-
T = 0;
|
665
|
-
var z = l.eq(k);
|
666
|
-
if (1 < t.slidesPerColumn) {
|
667
|
-
var P = void 0,
|
668
|
-
$ = void 0,
|
669
|
-
L = void 0;
|
670
|
-
"column" === t.slidesPerColumnFill ? (L = k - ($ = Math.floor(k / S)) * S, (M < $ || $ === M && L === S - 1) && S <= (L += 1) && (L = 0, $ += 1), P = $ + L * x / S, z.css({
|
671
|
-
"-webkit-box-ordinal-group": P,
|
672
|
-
"-moz-box-ordinal-group": P,
|
673
|
-
"-ms-flex-order": P,
|
674
|
-
"-webkit-order": P,
|
675
|
-
order: P
|
676
|
-
})) : $ = k - (L = Math.floor(k / C)) * C, z.css("margin-" + (e.isHorizontal() ? "top" : "left"), 0 !== L && t.spaceBetween && t.spaceBetween + "px").attr("data-swiper-column", $).attr("data-swiper-row", L)
|
677
|
-
}
|
678
|
-
if ("none" !== z.css("display")) {
|
679
|
-
if ("auto" === t.slidesPerView) {
|
680
|
-
var I = Y.getComputedStyle(z[0], null),
|
681
|
-
D = z[0].style.transform,
|
682
|
-
O = z[0].style.webkitTransform;
|
683
|
-
D && (z[0].style.transform = "none"), O && (z[0].style.webkitTransform = "none"), T = t.roundLengths ? e.isHorizontal() ? z.outerWidth(!0) : z.outerHeight(!0) : e.isHorizontal() ? z[0].getBoundingClientRect().width + parseFloat(I.getPropertyValue("margin-left")) + parseFloat(I.getPropertyValue("margin-right")) : z[0].getBoundingClientRect().height + parseFloat(I.getPropertyValue("margin-top")) + parseFloat(I.getPropertyValue("margin-bottom")), D && (z[0].style.transform = D), O && (z[0].style.webkitTransform = O), t.roundLengths && (T = Math.floor(T))
|
684
|
-
} else T = (i - (t.slidesPerView - 1) * g) / t.slidesPerView, t.roundLengths && (T = Math.floor(T)), l[k] && (e.isHorizontal() ? l[k].style.width = T + "px" : l[k].style.height = T + "px");
|
685
|
-
l[k] && (l[k].swiperSlideSize = T), u.push(T), t.centeredSlides ? (b = b + T / 2 + w / 2 + g, 0 === w && 0 !== k && (b = b - i / 2 - g), 0 === k && (b = b - i / 2 - g), Math.abs(b) < .001 && (b = 0), t.roundLengths && (b = Math.floor(b)), y % t.slidesPerGroup == 0 && p.push(b), c.push(b)) : (t.roundLengths && (b = Math.floor(b)), y % t.slidesPerGroup == 0 && p.push(b), c.push(b), b = b + T + g), e.virtualSize += T + g, w = T, y += 1
|
686
|
-
}
|
687
|
-
}
|
688
|
-
if (e.virtualSize = Math.max(e.virtualSize, i) + v, s && r && ("slide" === t.effect || "coverflow" === t.effect) && a.css({
|
689
|
-
width: e.virtualSize + t.spaceBetween + "px"
|
690
|
-
}), R.flexbox && !t.setWrapperSize || (e.isHorizontal() ? a.css({
|
691
|
-
width: e.virtualSize + t.spaceBetween + "px"
|
692
|
-
}) : a.css({
|
693
|
-
height: e.virtualSize + t.spaceBetween + "px"
|
694
|
-
})), 1 < t.slidesPerColumn && (e.virtualSize = (T + t.spaceBetween) * x, e.virtualSize = Math.ceil(e.virtualSize / t.slidesPerColumn) - t.spaceBetween, e.isHorizontal() ? a.css({
|
695
|
-
width: e.virtualSize + t.spaceBetween + "px"
|
696
|
-
}) : a.css({
|
697
|
-
height: e.virtualSize + t.spaceBetween + "px"
|
698
|
-
}), t.centeredSlides)) {
|
699
|
-
E = [];
|
700
|
-
for (var A = 0; A < p.length; A += 1) {
|
701
|
-
var H = p[A];
|
702
|
-
t.roundLengths && (H = Math.floor(H)), p[A] < e.virtualSize + p[0] && E.push(H)
|
703
|
-
}
|
704
|
-
p = E
|
705
|
-
}
|
706
|
-
if (!t.centeredSlides) {
|
707
|
-
E = [];
|
708
|
-
for (var B = 0; B < p.length; B += 1) {
|
709
|
-
var G = p[B];
|
710
|
-
t.roundLengths && (G = Math.floor(G)), p[B] <= e.virtualSize - i && E.push(G)
|
711
|
-
}
|
712
|
-
p = E, 1 < Math.floor(e.virtualSize - i) - Math.floor(p[p.length - 1]) && p.push(e.virtualSize - i)
|
713
|
-
}
|
714
|
-
if (0 === p.length && (p = [0]), 0 !== t.spaceBetween && (e.isHorizontal() ? s ? l.css({
|
715
|
-
marginLeft: g + "px"
|
716
|
-
}) : l.css({
|
717
|
-
marginRight: g + "px"
|
718
|
-
}) : l.css({
|
719
|
-
marginBottom: g + "px"
|
720
|
-
})), t.centerInsufficientSlides) {
|
721
|
-
var N = 0;
|
722
|
-
if (u.forEach(function (e) {
|
723
|
-
N += e + (t.spaceBetween ? t.spaceBetween : 0)
|
724
|
-
}), (N -= t.spaceBetween) < i) {
|
725
|
-
var X = (i - N) / 2;
|
726
|
-
p.forEach(function (e, t) {
|
727
|
-
p[t] = e - X
|
728
|
-
}), c.forEach(function (e, t) {
|
729
|
-
c[t] = e + X
|
730
|
-
})
|
731
|
-
}
|
732
|
-
}
|
733
|
-
V.extend(e, {
|
734
|
-
slides: l,
|
735
|
-
snapGrid: p,
|
736
|
-
slidesGrid: c,
|
737
|
-
slidesSizesGrid: u
|
738
|
-
}), d !== o && e.emit("slidesLengthChange"), p.length !== f && (e.params.watchOverflow && e.checkOverflow(), e.emit("snapGridLengthChange")), c.length !== m && e.emit("slidesGridLengthChange"), (t.watchSlidesProgress || t.watchSlidesVisibility) && e.updateSlidesOffset()
|
739
|
-
}
|
740
|
-
},
|
741
|
-
updateAutoHeight: function (e) {
|
742
|
-
var t, a = this,
|
743
|
-
i = [],
|
744
|
-
s = 0;
|
745
|
-
if ("number" == typeof e ? a.setTransition(e) : !0 === e && a.setTransition(a.params.speed), "auto" !== a.params.slidesPerView && 1 < a.params.slidesPerView)
|
746
|
-
for (t = 0; t < Math.ceil(a.params.slidesPerView); t += 1) {
|
747
|
-
var r = a.activeIndex + t;
|
748
|
-
if (r > a.slides.length) break;
|
749
|
-
i.push(a.slides.eq(r)[0])
|
750
|
-
} else i.push(a.slides.eq(a.activeIndex)[0]);
|
751
|
-
for (t = 0; t < i.length; t += 1)
|
752
|
-
if (void 0 !== i[t]) {
|
753
|
-
var n = i[t].offsetHeight;
|
754
|
-
s = s < n ? n : s
|
755
|
-
} s && a.$wrapperEl.css("height", s + "px")
|
756
|
-
},
|
757
|
-
updateSlidesOffset: function () {
|
758
|
-
for (var e = this.slides, t = 0; t < e.length; t += 1) e[t].swiperSlideOffset = this.isHorizontal() ? e[t].offsetLeft : e[t].offsetTop
|
759
|
-
},
|
760
|
-
updateSlidesProgress: function (e) {
|
761
|
-
void 0 === e && (e = this && this.translate || 0);
|
762
|
-
var t = this,
|
763
|
-
a = t.params,
|
764
|
-
i = t.slides,
|
765
|
-
s = t.rtlTranslate;
|
766
|
-
if (0 !== i.length) {
|
767
|
-
void 0 === i[0].swiperSlideOffset && t.updateSlidesOffset();
|
768
|
-
var r = -e;
|
769
|
-
s && (r = e), i.removeClass(a.slideVisibleClass), t.visibleSlidesIndexes = [], t.visibleSlides = [];
|
770
|
-
for (var n = 0; n < i.length; n += 1) {
|
771
|
-
var o = i[n],
|
772
|
-
l = (r + (a.centeredSlides ? t.minTranslate() : 0) - o.swiperSlideOffset) / (o.swiperSlideSize + a.spaceBetween);
|
773
|
-
if (a.watchSlidesVisibility) {
|
774
|
-
var d = -(r - o.swiperSlideOffset),
|
775
|
-
p = d + t.slidesSizesGrid[n];
|
776
|
-
(0 <= d && d < t.size || 0 < p && p <= t.size || d <= 0 && p >= t.size) && (t.visibleSlides.push(o), t.visibleSlidesIndexes.push(n), i.eq(n).addClass(a.slideVisibleClass))
|
777
|
-
}
|
778
|
-
o.progress = s ? -l : l
|
779
|
-
}
|
780
|
-
t.visibleSlides = L(t.visibleSlides)
|
781
|
-
}
|
782
|
-
},
|
783
|
-
updateProgress: function (e) {
|
784
|
-
void 0 === e && (e = this && this.translate || 0);
|
785
|
-
var t = this,
|
786
|
-
a = t.params,
|
787
|
-
i = t.maxTranslate() - t.minTranslate(),
|
788
|
-
s = t.progress,
|
789
|
-
r = t.isBeginning,
|
790
|
-
n = t.isEnd,
|
791
|
-
o = r,
|
792
|
-
l = n;
|
793
|
-
0 === i ? n = r = !(s = 0) : (r = (s = (e - t.minTranslate()) / i) <= 0, n = 1 <= s), V.extend(t, {
|
794
|
-
progress: s,
|
795
|
-
isBeginning: r,
|
796
|
-
isEnd: n
|
797
|
-
}), (a.watchSlidesProgress || a.watchSlidesVisibility) && t.updateSlidesProgress(e), r && !o && t.emit("reachBeginning toEdge"), n && !l && t.emit("reachEnd toEdge"), (o && !r || l && !n) && t.emit("fromEdge"), t.emit("progress", s)
|
798
|
-
},
|
799
|
-
updateSlidesClasses: function () {
|
800
|
-
var e, t = this,
|
801
|
-
a = t.slides,
|
802
|
-
i = t.params,
|
803
|
-
s = t.$wrapperEl,
|
804
|
-
r = t.activeIndex,
|
805
|
-
n = t.realIndex,
|
806
|
-
o = t.virtual && i.virtual.enabled;
|
807
|
-
a.removeClass(i.slideActiveClass + " " + i.slideNextClass + " " + i.slidePrevClass + " " + i.slideDuplicateActiveClass + " " + i.slideDuplicateNextClass + " " + i.slideDuplicatePrevClass), (e = o ? t.$wrapperEl.find("." + i.slideClass + '[data-swiper-slide-index="' + r + '"]') : a.eq(r)).addClass(i.slideActiveClass), i.loop && (e.hasClass(i.slideDuplicateClass) ? s.children("." + i.slideClass + ":not(." + i.slideDuplicateClass + ')[data-swiper-slide-index="' + n + '"]').addClass(i.slideDuplicateActiveClass) : s.children("." + i.slideClass + "." + i.slideDuplicateClass + '[data-swiper-slide-index="' + n + '"]').addClass(i.slideDuplicateActiveClass));
|
808
|
-
var l = e.nextAll("." + i.slideClass).eq(0).addClass(i.slideNextClass);
|
809
|
-
i.loop && 0 === l.length && (l = a.eq(0)).addClass(i.slideNextClass);
|
810
|
-
var d = e.prevAll("." + i.slideClass).eq(0).addClass(i.slidePrevClass);
|
811
|
-
i.loop && 0 === d.length && (d = a.eq(-1)).addClass(i.slidePrevClass), i.loop && (l.hasClass(i.slideDuplicateClass) ? s.children("." + i.slideClass + ":not(." + i.slideDuplicateClass + ')[data-swiper-slide-index="' + l.attr("data-swiper-slide-index") + '"]').addClass(i.slideDuplicateNextClass) : s.children("." + i.slideClass + "." + i.slideDuplicateClass + '[data-swiper-slide-index="' + l.attr("data-swiper-slide-index") + '"]').addClass(i.slideDuplicateNextClass), d.hasClass(i.slideDuplicateClass) ? s.children("." + i.slideClass + ":not(." + i.slideDuplicateClass + ')[data-swiper-slide-index="' + d.attr("data-swiper-slide-index") + '"]').addClass(i.slideDuplicatePrevClass) : s.children("." + i.slideClass + "." + i.slideDuplicateClass + '[data-swiper-slide-index="' + d.attr("data-swiper-slide-index") + '"]').addClass(i.slideDuplicatePrevClass))
|
812
|
-
},
|
813
|
-
updateActiveIndex: function (e) {
|
814
|
-
var t, a = this,
|
815
|
-
i = a.rtlTranslate ? a.translate : -a.translate,
|
816
|
-
s = a.slidesGrid,
|
817
|
-
r = a.snapGrid,
|
818
|
-
n = a.params,
|
819
|
-
o = a.activeIndex,
|
820
|
-
l = a.realIndex,
|
821
|
-
d = a.snapIndex,
|
822
|
-
p = e;
|
823
|
-
if (void 0 === p) {
|
824
|
-
for (var c = 0; c < s.length; c += 1) void 0 !== s[c + 1] ? i >= s[c] && i < s[c + 1] - (s[c + 1] - s[c]) / 2 ? p = c : i >= s[c] && i < s[c + 1] && (p = c + 1) : i >= s[c] && (p = c);
|
825
|
-
n.normalizeSlideIndex && (p < 0 || void 0 === p) && (p = 0)
|
826
|
-
}
|
827
|
-
if ((t = 0 <= r.indexOf(i) ? r.indexOf(i) : Math.floor(p / n.slidesPerGroup)) >= r.length && (t = r.length - 1), p !== o) {
|
828
|
-
var u = parseInt(a.slides.eq(p).attr("data-swiper-slide-index") || p, 10);
|
829
|
-
V.extend(a, {
|
830
|
-
snapIndex: t,
|
831
|
-
realIndex: u,
|
832
|
-
previousIndex: o,
|
833
|
-
activeIndex: p
|
834
|
-
}), a.emit("activeIndexChange"), a.emit("snapIndexChange"), l !== u && a.emit("realIndexChange"), a.emit("slideChange")
|
835
|
-
} else t !== d && (a.snapIndex = t, a.emit("snapIndexChange"))
|
836
|
-
},
|
837
|
-
updateClickedSlide: function (e) {
|
838
|
-
var t = this,
|
839
|
-
a = t.params,
|
840
|
-
i = L(e.target).closest("." + a.slideClass)[0],
|
841
|
-
s = !1;
|
842
|
-
if (i)
|
843
|
-
for (var r = 0; r < t.slides.length; r += 1) t.slides[r] === i && (s = !0);
|
844
|
-
if (!i || !s) return t.clickedSlide = void 0, void(t.clickedIndex = void 0);
|
845
|
-
t.clickedSlide = i, t.virtual && t.params.virtual.enabled ? t.clickedIndex = parseInt(L(i).attr("data-swiper-slide-index"), 10) : t.clickedIndex = L(i).index(), a.slideToClickedSlide && void 0 !== t.clickedIndex && t.clickedIndex !== t.activeIndex && t.slideToClickedSlide()
|
846
|
-
}
|
847
|
-
};
|
848
|
-
var d = {
|
849
|
-
getTranslate: function (e) {
|
850
|
-
void 0 === e && (e = this.isHorizontal() ? "x" : "y");
|
851
|
-
var t = this.params,
|
852
|
-
a = this.rtlTranslate,
|
853
|
-
i = this.translate,
|
854
|
-
s = this.$wrapperEl;
|
855
|
-
if (t.virtualTranslate) return a ? -i : i;
|
856
|
-
var r = V.getTranslate(s[0], e);
|
857
|
-
return a && (r = -r), r || 0
|
858
|
-
},
|
859
|
-
setTranslate: function (e, t) {
|
860
|
-
var a = this,
|
861
|
-
i = a.rtlTranslate,
|
862
|
-
s = a.params,
|
863
|
-
r = a.$wrapperEl,
|
864
|
-
n = a.progress,
|
865
|
-
o = 0,
|
866
|
-
l = 0;
|
867
|
-
a.isHorizontal() ? o = i ? -e : e : l = e, s.roundLengths && (o = Math.floor(o), l = Math.floor(l)), s.virtualTranslate || (R.transforms3d ? r.transform("translate3d(" + o + "px, " + l + "px, 0px)") : r.transform("translate(" + o + "px, " + l + "px)")), a.previousTranslate = a.translate, a.translate = a.isHorizontal() ? o : l;
|
868
|
-
var d = a.maxTranslate() - a.minTranslate();
|
869
|
-
(0 === d ? 0 : (e - a.minTranslate()) / d) !== n && a.updateProgress(e), a.emit("setTranslate", a.translate, t)
|
870
|
-
},
|
871
|
-
minTranslate: function () {
|
872
|
-
return -this.snapGrid[0]
|
873
|
-
},
|
874
|
-
maxTranslate: function () {
|
875
|
-
return -this.snapGrid[this.snapGrid.length - 1]
|
876
|
-
}
|
877
|
-
};
|
878
|
-
var p = {
|
879
|
-
setTransition: function (e, t) {
|
880
|
-
this.$wrapperEl.transition(e), this.emit("setTransition", e, t)
|
881
|
-
},
|
882
|
-
transitionStart: function (e, t) {
|
883
|
-
void 0 === e && (e = !0);
|
884
|
-
var a = this,
|
885
|
-
i = a.activeIndex,
|
886
|
-
s = a.params,
|
887
|
-
r = a.previousIndex;
|
888
|
-
s.autoHeight && a.updateAutoHeight();
|
889
|
-
var n = t;
|
890
|
-
if (n || (n = r < i ? "next" : i < r ? "prev" : "reset"), a.emit("transitionStart"), e && i !== r) {
|
891
|
-
if ("reset" === n) return void a.emit("slideResetTransitionStart");
|
892
|
-
a.emit("slideChangeTransitionStart"), "next" === n ? a.emit("slideNextTransitionStart") : a.emit("slidePrevTransitionStart")
|
893
|
-
}
|
894
|
-
},
|
895
|
-
transitionEnd: function (e, t) {
|
896
|
-
void 0 === e && (e = !0);
|
897
|
-
var a = this,
|
898
|
-
i = a.activeIndex,
|
899
|
-
s = a.previousIndex;
|
900
|
-
a.animating = !1, a.setTransition(0);
|
901
|
-
var r = t;
|
902
|
-
if (r || (r = s < i ? "next" : i < s ? "prev" : "reset"), a.emit("transitionEnd"), e && i !== s) {
|
903
|
-
if ("reset" === r) return void a.emit("slideResetTransitionEnd");
|
904
|
-
a.emit("slideChangeTransitionEnd"), "next" === r ? a.emit("slideNextTransitionEnd") : a.emit("slidePrevTransitionEnd")
|
905
|
-
}
|
906
|
-
}
|
907
|
-
};
|
908
|
-
var c = {
|
909
|
-
slideTo: function (e, t, a, i) {
|
910
|
-
void 0 === e && (e = 0), void 0 === t && (t = this.params.speed), void 0 === a && (a = !0);
|
911
|
-
var s = this,
|
912
|
-
r = e;
|
913
|
-
r < 0 && (r = 0);
|
914
|
-
var n = s.params,
|
915
|
-
o = s.snapGrid,
|
916
|
-
l = s.slidesGrid,
|
917
|
-
d = s.previousIndex,
|
918
|
-
p = s.activeIndex,
|
919
|
-
c = s.rtlTranslate;
|
920
|
-
if (s.animating && n.preventInteractionOnTransition) return !1;
|
921
|
-
var u = Math.floor(r / n.slidesPerGroup);
|
922
|
-
u >= o.length && (u = o.length - 1), (p || n.initialSlide || 0) === (d || 0) && a && s.emit("beforeSlideChangeStart");
|
923
|
-
var h, v = -o[u];
|
924
|
-
if (s.updateProgress(v), n.normalizeSlideIndex)
|
925
|
-
for (var f = 0; f < l.length; f += 1) - Math.floor(100 * v) >= Math.floor(100 * l[f]) && (r = f);
|
926
|
-
if (s.initialized && r !== p) {
|
927
|
-
if (!s.allowSlideNext && v < s.translate && v < s.minTranslate()) return !1;
|
928
|
-
if (!s.allowSlidePrev && v > s.translate && v > s.maxTranslate() && (p || 0) !== r) return !1
|
929
|
-
}
|
930
|
-
return h = p < r ? "next" : r < p ? "prev" : "reset", c && -v === s.translate || !c && v === s.translate ? (s.updateActiveIndex(r), n.autoHeight && s.updateAutoHeight(), s.updateSlidesClasses(), "slide" !== n.effect && s.setTranslate(v), "reset" !== h && (s.transitionStart(a, h), s.transitionEnd(a, h)), !1) : (0 !== t && R.transition ? (s.setTransition(t), s.setTranslate(v), s.updateActiveIndex(r), s.updateSlidesClasses(), s.emit("beforeTransitionStart", t, i), s.transitionStart(a, h), s.animating || (s.animating = !0, s.onSlideToWrapperTransitionEnd || (s.onSlideToWrapperTransitionEnd = function (e) {
|
931
|
-
s && !s.destroyed && e.target === this && (s.$wrapperEl[0].removeEventListener("transitionend", s.onSlideToWrapperTransitionEnd), s.$wrapperEl[0].removeEventListener("webkitTransitionEnd", s.onSlideToWrapperTransitionEnd), s.onSlideToWrapperTransitionEnd = null, delete s.onSlideToWrapperTransitionEnd, s.transitionEnd(a, h))
|
932
|
-
}), s.$wrapperEl[0].addEventListener("transitionend", s.onSlideToWrapperTransitionEnd), s.$wrapperEl[0].addEventListener("webkitTransitionEnd", s.onSlideToWrapperTransitionEnd))) : (s.setTransition(0), s.setTranslate(v), s.updateActiveIndex(r), s.updateSlidesClasses(), s.emit("beforeTransitionStart", t, i), s.transitionStart(a, h), s.transitionEnd(a, h)), !0)
|
933
|
-
},
|
934
|
-
slideToLoop: function (e, t, a, i) {
|
935
|
-
void 0 === e && (e = 0), void 0 === t && (t = this.params.speed), void 0 === a && (a = !0);
|
936
|
-
var s = e;
|
937
|
-
return this.params.loop && (s += this.loopedSlides), this.slideTo(s, t, a, i)
|
938
|
-
},
|
939
|
-
slideNext: function (e, t, a) {
|
940
|
-
void 0 === e && (e = this.params.speed), void 0 === t && (t = !0);
|
941
|
-
var i = this,
|
942
|
-
s = i.params,
|
943
|
-
r = i.animating;
|
944
|
-
return s.loop ? !r && (i.loopFix(), i._clientLeft = i.$wrapperEl[0].clientLeft, i.slideTo(i.activeIndex + s.slidesPerGroup, e, t, a)) : i.slideTo(i.activeIndex + s.slidesPerGroup, e, t, a)
|
945
|
-
},
|
946
|
-
slidePrev: function (e, t, a) {
|
947
|
-
void 0 === e && (e = this.params.speed), void 0 === t && (t = !0);
|
948
|
-
var i = this,
|
949
|
-
s = i.params,
|
950
|
-
r = i.animating,
|
951
|
-
n = i.snapGrid,
|
952
|
-
o = i.slidesGrid,
|
953
|
-
l = i.rtlTranslate;
|
954
|
-
if (s.loop) {
|
955
|
-
if (r) return !1;
|
956
|
-
i.loopFix(), i._clientLeft = i.$wrapperEl[0].clientLeft
|
957
|
-
}
|
958
|
-
|
959
|
-
function d(e) {
|
960
|
-
return e < 0 ? -Math.floor(Math.abs(e)) : Math.floor(e)
|
961
|
-
}
|
962
|
-
var p, c = d(l ? i.translate : -i.translate),
|
963
|
-
u = n.map(function (e) {
|
964
|
-
return d(e)
|
965
|
-
}),
|
966
|
-
h = (o.map(function (e) {
|
967
|
-
return d(e)
|
968
|
-
}), n[u.indexOf(c)], n[u.indexOf(c) - 1]);
|
969
|
-
return void 0 !== h && (p = o.indexOf(h)) < 0 && (p = i.activeIndex - 1), i.slideTo(p, e, t, a)
|
970
|
-
},
|
971
|
-
slideReset: function (e, t, a) {
|
972
|
-
return void 0 === e && (e = this.params.speed), void 0 === t && (t = !0), this.slideTo(this.activeIndex, e, t, a)
|
973
|
-
},
|
974
|
-
slideToClosest: function (e, t, a) {
|
975
|
-
void 0 === e && (e = this.params.speed), void 0 === t && (t = !0);
|
976
|
-
var i = this,
|
977
|
-
s = i.activeIndex,
|
978
|
-
r = Math.floor(s / i.params.slidesPerGroup);
|
979
|
-
if (r < i.snapGrid.length - 1) {
|
980
|
-
var n = i.rtlTranslate ? i.translate : -i.translate,
|
981
|
-
o = i.snapGrid[r];
|
982
|
-
(i.snapGrid[r + 1] - o) / 2 < n - o && (s = i.params.slidesPerGroup)
|
983
|
-
}
|
984
|
-
return i.slideTo(s, e, t, a)
|
985
|
-
},
|
986
|
-
slideToClickedSlide: function () {
|
987
|
-
var e, t = this,
|
988
|
-
a = t.params,
|
989
|
-
i = t.$wrapperEl,
|
990
|
-
s = "auto" === a.slidesPerView ? t.slidesPerViewDynamic() : a.slidesPerView,
|
991
|
-
r = t.clickedIndex;
|
992
|
-
if (a.loop) {
|
993
|
-
if (t.animating) return;
|
994
|
-
e = parseInt(L(t.clickedSlide).attr("data-swiper-slide-index"), 10), a.centeredSlides ? r < t.loopedSlides - s / 2 || r > t.slides.length - t.loopedSlides + s / 2 ? (t.loopFix(), r = i.children("." + a.slideClass + '[data-swiper-slide-index="' + e + '"]:not(.' + a.slideDuplicateClass + ")").eq(0).index(), V.nextTick(function () {
|
995
|
-
t.slideTo(r)
|
996
|
-
})) : t.slideTo(r) : r > t.slides.length - s ? (t.loopFix(), r = i.children("." + a.slideClass + '[data-swiper-slide-index="' + e + '"]:not(.' + a.slideDuplicateClass + ")").eq(0).index(), V.nextTick(function () {
|
997
|
-
t.slideTo(r)
|
998
|
-
})) : t.slideTo(r)
|
999
|
-
} else t.slideTo(r)
|
1000
|
-
}
|
1001
|
-
};
|
1002
|
-
var u = {
|
1003
|
-
loopCreate: function () {
|
1004
|
-
var i = this,
|
1005
|
-
e = i.params,
|
1006
|
-
t = i.$wrapperEl;
|
1007
|
-
t.children("." + e.slideClass + "." + e.slideDuplicateClass).remove();
|
1008
|
-
var s = t.children("." + e.slideClass);
|
1009
|
-
if (e.loopFillGroupWithBlank) {
|
1010
|
-
var a = e.slidesPerGroup - s.length % e.slidesPerGroup;
|
1011
|
-
if (a !== e.slidesPerGroup) {
|
1012
|
-
for (var r = 0; r < a; r += 1) {
|
1013
|
-
var n = L(f.createElement("div")).addClass(e.slideClass + " " + e.slideBlankClass);
|
1014
|
-
t.append(n)
|
1015
|
-
}
|
1016
|
-
s = t.children("." + e.slideClass)
|
1017
|
-
}
|
1018
|
-
}
|
1019
|
-
"auto" !== e.slidesPerView || e.loopedSlides || (e.loopedSlides = s.length), i.loopedSlides = parseInt(e.loopedSlides || e.slidesPerView, 10), i.loopedSlides += e.loopAdditionalSlides, i.loopedSlides > s.length && (i.loopedSlides = s.length);
|
1020
|
-
var o = [],
|
1021
|
-
l = [];
|
1022
|
-
s.each(function (e, t) {
|
1023
|
-
var a = L(t);
|
1024
|
-
e < i.loopedSlides && l.push(t), e < s.length && e >= s.length - i.loopedSlides && o.push(t), a.attr("data-swiper-slide-index", e)
|
1025
|
-
});
|
1026
|
-
for (var d = 0; d < l.length; d += 1) t.append(L(l[d].cloneNode(!0)).addClass(e.slideDuplicateClass));
|
1027
|
-
for (var p = o.length - 1; 0 <= p; p -= 1) t.prepend(L(o[p].cloneNode(!0)).addClass(e.slideDuplicateClass))
|
1028
|
-
},
|
1029
|
-
loopFix: function () {
|
1030
|
-
var e, t = this,
|
1031
|
-
a = t.params,
|
1032
|
-
i = t.activeIndex,
|
1033
|
-
s = t.slides,
|
1034
|
-
r = t.loopedSlides,
|
1035
|
-
n = t.allowSlidePrev,
|
1036
|
-
o = t.allowSlideNext,
|
1037
|
-
l = t.snapGrid,
|
1038
|
-
d = t.rtlTranslate;
|
1039
|
-
t.allowSlidePrev = !0, t.allowSlideNext = !0;
|
1040
|
-
var p = -l[i] - t.getTranslate();
|
1041
|
-
i < r ? (e = s.length - 3 * r + i, e += r, t.slideTo(e, 0, !1, !0) && 0 !== p && t.setTranslate((d ? -t.translate : t.translate) - p)) : ("auto" === a.slidesPerView && 2 * r <= i || i >= s.length - r) && (e = -s.length + i + r, e += r, t.slideTo(e, 0, !1, !0) && 0 !== p && t.setTranslate((d ? -t.translate : t.translate) - p));
|
1042
|
-
t.allowSlidePrev = n, t.allowSlideNext = o
|
1043
|
-
},
|
1044
|
-
loopDestroy: function () {
|
1045
|
-
var e = this.$wrapperEl,
|
1046
|
-
t = this.params,
|
1047
|
-
a = this.slides;
|
1048
|
-
e.children("." + t.slideClass + "." + t.slideDuplicateClass).remove(), a.removeAttr("data-swiper-slide-index")
|
1049
|
-
}
|
1050
|
-
};
|
1051
|
-
var h = {
|
1052
|
-
setGrabCursor: function (e) {
|
1053
|
-
if (!(R.touch || !this.params.simulateTouch || this.params.watchOverflow && this.isLocked)) {
|
1054
|
-
var t = this.el;
|
1055
|
-
t.style.cursor = "move", t.style.cursor = e ? "-webkit-grabbing" : "-webkit-grab", t.style.cursor = e ? "-moz-grabbin" : "-moz-grab", t.style.cursor = e ? "grabbing" : "grab"
|
1056
|
-
}
|
1057
|
-
},
|
1058
|
-
unsetGrabCursor: function () {
|
1059
|
-
R.touch || this.params.watchOverflow && this.isLocked || (this.el.style.cursor = "")
|
1060
|
-
}
|
1061
|
-
};
|
1062
|
-
var v = {
|
1063
|
-
appendSlide: function (e) {
|
1064
|
-
var t = this,
|
1065
|
-
a = t.$wrapperEl,
|
1066
|
-
i = t.params;
|
1067
|
-
if (i.loop && t.loopDestroy(), "object" == typeof e && "length" in e)
|
1068
|
-
for (var s = 0; s < e.length; s += 1) e[s] && a.append(e[s]);
|
1069
|
-
else a.append(e);
|
1070
|
-
i.loop && t.loopCreate(), i.observer && R.observer || t.update()
|
1071
|
-
},
|
1072
|
-
prependSlide: function (e) {
|
1073
|
-
var t = this,
|
1074
|
-
a = t.params,
|
1075
|
-
i = t.$wrapperEl,
|
1076
|
-
s = t.activeIndex;
|
1077
|
-
a.loop && t.loopDestroy();
|
1078
|
-
var r = s + 1;
|
1079
|
-
if ("object" == typeof e && "length" in e) {
|
1080
|
-
for (var n = 0; n < e.length; n += 1) e[n] && i.prepend(e[n]);
|
1081
|
-
r = s + e.length
|
1082
|
-
} else i.prepend(e);
|
1083
|
-
a.loop && t.loopCreate(), a.observer && R.observer || t.update(), t.slideTo(r, 0, !1)
|
1084
|
-
},
|
1085
|
-
addSlide: function (e, t) {
|
1086
|
-
var a = this,
|
1087
|
-
i = a.$wrapperEl,
|
1088
|
-
s = a.params,
|
1089
|
-
r = a.activeIndex;
|
1090
|
-
s.loop && (r -= a.loopedSlides, a.loopDestroy(), a.slides = i.children("." + s.slideClass));
|
1091
|
-
var n = a.slides.length;
|
1092
|
-
if (e <= 0) a.prependSlide(t);
|
1093
|
-
else if (n <= e) a.appendSlide(t);
|
1094
|
-
else {
|
1095
|
-
for (var o = e < r ? r + 1 : r, l = [], d = n - 1; e <= d; d -= 1) {
|
1096
|
-
var p = a.slides.eq(d);
|
1097
|
-
p.remove(), l.unshift(p)
|
1098
|
-
}
|
1099
|
-
if ("object" == typeof t && "length" in t) {
|
1100
|
-
for (var c = 0; c < t.length; c += 1) t[c] && i.append(t[c]);
|
1101
|
-
o = e < r ? r + t.length : r
|
1102
|
-
} else i.append(t);
|
1103
|
-
for (var u = 0; u < l.length; u += 1) i.append(l[u]);
|
1104
|
-
s.loop && a.loopCreate(), s.observer && R.observer || a.update(), s.loop ? a.slideTo(o + a.loopedSlides, 0, !1) : a.slideTo(o, 0, !1)
|
1105
|
-
}
|
1106
|
-
},
|
1107
|
-
removeSlide: function (e) {
|
1108
|
-
var t = this,
|
1109
|
-
a = t.params,
|
1110
|
-
i = t.$wrapperEl,
|
1111
|
-
s = t.activeIndex;
|
1112
|
-
a.loop && (s -= t.loopedSlides, t.loopDestroy(), t.slides = i.children("." + a.slideClass));
|
1113
|
-
var r, n = s;
|
1114
|
-
if ("object" == typeof e && "length" in e) {
|
1115
|
-
for (var o = 0; o < e.length; o += 1) r = e[o], t.slides[r] && t.slides.eq(r).remove(), r < n && (n -= 1);
|
1116
|
-
n = Math.max(n, 0)
|
1117
|
-
} else r = e, t.slides[r] && t.slides.eq(r).remove(), r < n && (n -= 1), n = Math.max(n, 0);
|
1118
|
-
a.loop && t.loopCreate(), a.observer && R.observer || t.update(), a.loop ? t.slideTo(n + t.loopedSlides, 0, !1) : t.slideTo(n, 0, !1)
|
1119
|
-
},
|
1120
|
-
removeAllSlides: function () {
|
1121
|
-
for (var e = [], t = 0; t < this.slides.length; t += 1) e.push(t);
|
1122
|
-
this.removeSlide(e)
|
1123
|
-
}
|
1124
|
-
},
|
1125
|
-
m = function () {
|
1126
|
-
var e = Y.navigator.userAgent,
|
1127
|
-
t = {
|
1128
|
-
ios: !1,
|
1129
|
-
android: !1,
|
1130
|
-
androidChrome: !1,
|
1131
|
-
desktop: !1,
|
1132
|
-
windows: !1,
|
1133
|
-
iphone: !1,
|
1134
|
-
ipod: !1,
|
1135
|
-
ipad: !1,
|
1136
|
-
cordova: Y.cordova || Y.phonegap,
|
1137
|
-
phonegap: Y.cordova || Y.phonegap
|
1138
|
-
},
|
1139
|
-
a = e.match(/(Windows Phone);?[\s\/]+([\d.]+)?/),
|
1140
|
-
i = e.match(/(Android);?[\s\/]+([\d.]+)?/),
|
1141
|
-
s = e.match(/(iPad).*OS\s([\d_]+)/),
|
1142
|
-
r = e.match(/(iPod)(.*OS\s([\d_]+))?/),
|
1143
|
-
n = !s && e.match(/(iPhone\sOS|iOS)\s([\d_]+)/);
|
1144
|
-
if (a && (t.os = "windows", t.osVersion = a[2], t.windows = !0), i && !a && (t.os = "android", t.osVersion = i[2], t.android = !0, t.androidChrome = 0 <= e.toLowerCase().indexOf("chrome")), (s || n || r) && (t.os = "ios", t.ios = !0), n && !r && (t.osVersion = n[2].replace(/_/g, "."), t.iphone = !0), s && (t.osVersion = s[2].replace(/_/g, "."), t.ipad = !0), r && (t.osVersion = r[3] ? r[3].replace(/_/g, ".") : null, t.iphone = !0), t.ios && t.osVersion && 0 <= e.indexOf("Version/") && "10" === t.osVersion.split(".")[0] && (t.osVersion = e.toLowerCase().split("version/")[1].split(" ")[0]), t.desktop = !(t.os || t.android || t.webView), t.webView = (n || s || r) && e.match(/.*AppleWebKit(?!.*Safari)/i), t.os && "ios" === t.os) {
|
1145
|
-
var o = t.osVersion.split("."),
|
1146
|
-
l = f.querySelector('meta[name="viewport"]');
|
1147
|
-
t.minimalUi = !t.webView && (r || n) && (1 * o[0] == 7 ? 1 <= 1 * o[1] : 7 < 1 * o[0]) && l && 0 <= l.getAttribute("content").indexOf("minimal-ui")
|
1148
|
-
}
|
1149
|
-
return t.pixelRatio = Y.devicePixelRatio || 1, t
|
1150
|
-
}();
|
1151
|
-
|
1152
|
-
function g() {
|
1153
|
-
var e = this,
|
1154
|
-
t = e.params,
|
1155
|
-
a = e.el;
|
1156
|
-
if (!a || 0 !== a.offsetWidth) {
|
1157
|
-
t.breakpoints && e.setBreakpoint();
|
1158
|
-
var i = e.allowSlideNext,
|
1159
|
-
s = e.allowSlidePrev,
|
1160
|
-
r = e.snapGrid;
|
1161
|
-
if (e.allowSlideNext = !0, e.allowSlidePrev = !0, e.updateSize(), e.updateSlides(), t.freeMode) {
|
1162
|
-
var n = Math.min(Math.max(e.translate, e.maxTranslate()), e.minTranslate());
|
1163
|
-
e.setTranslate(n), e.updateActiveIndex(), e.updateSlidesClasses(), t.autoHeight && e.updateAutoHeight()
|
1164
|
-
} else e.updateSlidesClasses(), ("auto" === t.slidesPerView || 1 < t.slidesPerView) && e.isEnd && !e.params.centeredSlides ? e.slideTo(e.slides.length - 1, 0, !1, !0) : e.slideTo(e.activeIndex, 0, !1, !0);
|
1165
|
-
e.allowSlidePrev = s, e.allowSlideNext = i, e.params.watchOverflow && r !== e.snapGrid && e.checkOverflow()
|
1166
|
-
}
|
1167
|
-
}
|
1168
|
-
var b = {
|
1169
|
-
attachEvents: function () {
|
1170
|
-
var e = this,
|
1171
|
-
t = e.params,
|
1172
|
-
a = e.touchEvents,
|
1173
|
-
i = e.el,
|
1174
|
-
s = e.wrapperEl;
|
1175
|
-
e.onTouchStart = function (e) {
|
1176
|
-
var t = this,
|
1177
|
-
a = t.touchEventsData,
|
1178
|
-
i = t.params,
|
1179
|
-
s = t.touches;
|
1180
|
-
if (!t.animating || !i.preventInteractionOnTransition) {
|
1181
|
-
var r = e;
|
1182
|
-
if (r.originalEvent && (r = r.originalEvent), a.isTouchEvent = "touchstart" === r.type, (a.isTouchEvent || !("which" in r) || 3 !== r.which) && !(!a.isTouchEvent && "button" in r && 0 < r.button || a.isTouched && a.isMoved))
|
1183
|
-
if (i.noSwiping && L(r.target).closest(i.noSwipingSelector ? i.noSwipingSelector : "." + i.noSwipingClass)[0]) t.allowClick = !0;
|
1184
|
-
else if (!i.swipeHandler || L(r).closest(i.swipeHandler)[0]) {
|
1185
|
-
s.currentX = "touchstart" === r.type ? r.targetTouches[0].pageX : r.pageX, s.currentY = "touchstart" === r.type ? r.targetTouches[0].pageY : r.pageY;
|
1186
|
-
var n = s.currentX,
|
1187
|
-
o = s.currentY,
|
1188
|
-
l = i.edgeSwipeDetection || i.iOSEdgeSwipeDetection,
|
1189
|
-
d = i.edgeSwipeThreshold || i.iOSEdgeSwipeThreshold;
|
1190
|
-
if (!l || !(n <= d || n >= Y.screen.width - d)) {
|
1191
|
-
if (V.extend(a, {
|
1192
|
-
isTouched: !0,
|
1193
|
-
isMoved: !1,
|
1194
|
-
allowTouchCallbacks: !0,
|
1195
|
-
isScrolling: void 0,
|
1196
|
-
startMoving: void 0
|
1197
|
-
}), s.startX = n, s.startY = o, a.touchStartTime = V.now(), t.allowClick = !0, t.updateSize(), t.swipeDirection = void 0, 0 < i.threshold && (a.allowThresholdMove = !1), "touchstart" !== r.type) {
|
1198
|
-
var p = !0;
|
1199
|
-
L(r.target).is(a.formElements) && (p = !1), f.activeElement && L(f.activeElement).is(a.formElements) && f.activeElement !== r.target && f.activeElement.blur(), p && t.allowTouchMove && i.touchStartPreventDefault && r.preventDefault()
|
1200
|
-
}
|
1201
|
-
t.emit("touchStart", r)
|
1202
|
-
}
|
1203
|
-
}
|
1204
|
-
}
|
1205
|
-
}.bind(e), e.onTouchMove = function (e) {
|
1206
|
-
var t = this,
|
1207
|
-
a = t.touchEventsData,
|
1208
|
-
i = t.params,
|
1209
|
-
s = t.touches,
|
1210
|
-
r = t.rtlTranslate,
|
1211
|
-
n = e;
|
1212
|
-
if (n.originalEvent && (n = n.originalEvent), a.isTouched) {
|
1213
|
-
if (!a.isTouchEvent || "mousemove" !== n.type) {
|
1214
|
-
var o = "touchmove" === n.type ? n.targetTouches[0].pageX : n.pageX,
|
1215
|
-
l = "touchmove" === n.type ? n.targetTouches[0].pageY : n.pageY;
|
1216
|
-
if (n.preventedByNestedSwiper) return s.startX = o, void(s.startY = l);
|
1217
|
-
if (!t.allowTouchMove) return t.allowClick = !1, void(a.isTouched && (V.extend(s, {
|
1218
|
-
startX: o,
|
1219
|
-
startY: l,
|
1220
|
-
currentX: o,
|
1221
|
-
currentY: l
|
1222
|
-
}), a.touchStartTime = V.now()));
|
1223
|
-
if (a.isTouchEvent && i.touchReleaseOnEdges && !i.loop)
|
1224
|
-
if (t.isVertical()) {
|
1225
|
-
if (l < s.startY && t.translate <= t.maxTranslate() || l > s.startY && t.translate >= t.minTranslate()) return a.isTouched = !1, void(a.isMoved = !1)
|
1226
|
-
} else if (o < s.startX && t.translate <= t.maxTranslate() || o > s.startX && t.translate >= t.minTranslate()) return;
|
1227
|
-
if (a.isTouchEvent && f.activeElement && n.target === f.activeElement && L(n.target).is(a.formElements)) return a.isMoved = !0, void(t.allowClick = !1);
|
1228
|
-
if (a.allowTouchCallbacks && t.emit("touchMove", n), !(n.targetTouches && 1 < n.targetTouches.length)) {
|
1229
|
-
s.currentX = o, s.currentY = l;
|
1230
|
-
var d, p = s.currentX - s.startX,
|
1231
|
-
c = s.currentY - s.startY;
|
1232
|
-
if (!(t.params.threshold && Math.sqrt(Math.pow(p, 2) + Math.pow(c, 2)) < t.params.threshold))
|
1233
|
-
if (void 0 === a.isScrolling && (t.isHorizontal() && s.currentY === s.startY || t.isVertical() && s.currentX === s.startX ? a.isScrolling = !1 : 25 <= p * p + c * c && (d = 180 * Math.atan2(Math.abs(c), Math.abs(p)) / Math.PI, a.isScrolling = t.isHorizontal() ? d > i.touchAngle : 90 - d > i.touchAngle)), a.isScrolling && t.emit("touchMoveOpposite", n), void 0 === a.startMoving && (s.currentX === s.startX && s.currentY === s.startY || (a.startMoving = !0)), a.isScrolling) a.isTouched = !1;
|
1234
|
-
else if (a.startMoving) {
|
1235
|
-
t.allowClick = !1, n.preventDefault(), i.touchMoveStopPropagation && !i.nested && n.stopPropagation(), a.isMoved || (i.loop && t.loopFix(), a.startTranslate = t.getTranslate(), t.setTransition(0), t.animating && t.$wrapperEl.trigger("webkitTransitionEnd transitionend"), a.allowMomentumBounce = !1, !i.grabCursor || !0 !== t.allowSlideNext && !0 !== t.allowSlidePrev || t.setGrabCursor(!0), t.emit("sliderFirstMove", n)), t.emit("sliderMove", n), a.isMoved = !0;
|
1236
|
-
var u = t.isHorizontal() ? p : c;
|
1237
|
-
s.diff = u, u *= i.touchRatio, r && (u = -u), t.swipeDirection = 0 < u ? "prev" : "next", a.currentTranslate = u + a.startTranslate;
|
1238
|
-
var h = !0,
|
1239
|
-
v = i.resistanceRatio;
|
1240
|
-
if (i.touchReleaseOnEdges && (v = 0), 0 < u && a.currentTranslate > t.minTranslate() ? (h = !1, i.resistance && (a.currentTranslate = t.minTranslate() - 1 + Math.pow(-t.minTranslate() + a.startTranslate + u, v))) : u < 0 && a.currentTranslate < t.maxTranslate() && (h = !1, i.resistance && (a.currentTranslate = t.maxTranslate() + 1 - Math.pow(t.maxTranslate() - a.startTranslate - u, v))), h && (n.preventedByNestedSwiper = !0), !t.allowSlideNext && "next" === t.swipeDirection && a.currentTranslate < a.startTranslate && (a.currentTranslate = a.startTranslate), !t.allowSlidePrev && "prev" === t.swipeDirection && a.currentTranslate > a.startTranslate && (a.currentTranslate = a.startTranslate), 0 < i.threshold) {
|
1241
|
-
if (!(Math.abs(u) > i.threshold || a.allowThresholdMove)) return void(a.currentTranslate = a.startTranslate);
|
1242
|
-
if (!a.allowThresholdMove) return a.allowThresholdMove = !0, s.startX = s.currentX, s.startY = s.currentY, a.currentTranslate = a.startTranslate, void(s.diff = t.isHorizontal() ? s.currentX - s.startX : s.currentY - s.startY)
|
1243
|
-
}
|
1244
|
-
i.followFinger && ((i.freeMode || i.watchSlidesProgress || i.watchSlidesVisibility) && (t.updateActiveIndex(), t.updateSlidesClasses()), i.freeMode && (0 === a.velocities.length && a.velocities.push({
|
1245
|
-
position: s[t.isHorizontal() ? "startX" : "startY"],
|
1246
|
-
time: a.touchStartTime
|
1247
|
-
}), a.velocities.push({
|
1248
|
-
position: s[t.isHorizontal() ? "currentX" : "currentY"],
|
1249
|
-
time: V.now()
|
1250
|
-
})), t.updateProgress(a.currentTranslate), t.setTranslate(a.currentTranslate))
|
1251
|
-
}
|
1252
|
-
}
|
1253
|
-
}
|
1254
|
-
} else a.startMoving && a.isScrolling && t.emit("touchMoveOpposite", n)
|
1255
|
-
}.bind(e), e.onTouchEnd = function (e) {
|
1256
|
-
var t = this,
|
1257
|
-
a = t.touchEventsData,
|
1258
|
-
i = t.params,
|
1259
|
-
s = t.touches,
|
1260
|
-
r = t.rtlTranslate,
|
1261
|
-
n = t.$wrapperEl,
|
1262
|
-
o = t.slidesGrid,
|
1263
|
-
l = t.snapGrid,
|
1264
|
-
d = e;
|
1265
|
-
if (d.originalEvent && (d = d.originalEvent), a.allowTouchCallbacks && t.emit("touchEnd", d), a.allowTouchCallbacks = !1, !a.isTouched) return a.isMoved && i.grabCursor && t.setGrabCursor(!1), a.isMoved = !1, void(a.startMoving = !1);
|
1266
|
-
i.grabCursor && a.isMoved && a.isTouched && (!0 === t.allowSlideNext || !0 === t.allowSlidePrev) && t.setGrabCursor(!1);
|
1267
|
-
var p, c = V.now(),
|
1268
|
-
u = c - a.touchStartTime;
|
1269
|
-
if (t.allowClick && (t.updateClickedSlide(d), t.emit("tap", d), u < 300 && 300 < c - a.lastClickTime && (a.clickTimeout && clearTimeout(a.clickTimeout), a.clickTimeout = V.nextTick(function () {
|
1270
|
-
t && !t.destroyed && t.emit("click", d)
|
1271
|
-
}, 300)), u < 300 && c - a.lastClickTime < 300 && (a.clickTimeout && clearTimeout(a.clickTimeout), t.emit("doubleTap", d))), a.lastClickTime = V.now(), V.nextTick(function () {
|
1272
|
-
t.destroyed || (t.allowClick = !0)
|
1273
|
-
}), !a.isTouched || !a.isMoved || !t.swipeDirection || 0 === s.diff || a.currentTranslate === a.startTranslate) return a.isTouched = !1, a.isMoved = !1, void(a.startMoving = !1);
|
1274
|
-
if (a.isTouched = !1, a.isMoved = !1, a.startMoving = !1, p = i.followFinger ? r ? t.translate : -t.translate : -a.currentTranslate, i.freeMode) {
|
1275
|
-
if (p < -t.minTranslate()) return void t.slideTo(t.activeIndex);
|
1276
|
-
if (p > -t.maxTranslate()) return void(t.slides.length < l.length ? t.slideTo(l.length - 1) : t.slideTo(t.slides.length - 1));
|
1277
|
-
if (i.freeModeMomentum) {
|
1278
|
-
if (1 < a.velocities.length) {
|
1279
|
-
var h = a.velocities.pop(),
|
1280
|
-
v = a.velocities.pop(),
|
1281
|
-
f = h.position - v.position,
|
1282
|
-
m = h.time - v.time;
|
1283
|
-
t.velocity = f / m, t.velocity /= 2, Math.abs(t.velocity) < i.freeModeMinimumVelocity && (t.velocity = 0), (150 < m || 300 < V.now() - h.time) && (t.velocity = 0)
|
1284
|
-
} else t.velocity = 0;
|
1285
|
-
t.velocity *= i.freeModeMomentumVelocityRatio, a.velocities.length = 0;
|
1286
|
-
var g = 1e3 * i.freeModeMomentumRatio,
|
1287
|
-
b = t.velocity * g,
|
1288
|
-
w = t.translate + b;
|
1289
|
-
r && (w = -w);
|
1290
|
-
var y, x, T = !1,
|
1291
|
-
E = 20 * Math.abs(t.velocity) * i.freeModeMomentumBounceRatio;
|
1292
|
-
if (w < t.maxTranslate()) i.freeModeMomentumBounce ? (w + t.maxTranslate() < -E && (w = t.maxTranslate() - E), y = t.maxTranslate(), T = !0, a.allowMomentumBounce = !0) : w = t.maxTranslate(), i.loop && i.centeredSlides && (x = !0);
|
1293
|
-
else if (w > t.minTranslate()) i.freeModeMomentumBounce ? (w - t.minTranslate() > E && (w = t.minTranslate() + E), y = t.minTranslate(), T = !0, a.allowMomentumBounce = !0) : w = t.minTranslate(), i.loop && i.centeredSlides && (x = !0);
|
1294
|
-
else if (i.freeModeSticky) {
|
1295
|
-
for (var S, C = 0; C < l.length; C += 1)
|
1296
|
-
if (l[C] > -w) {
|
1297
|
-
S = C;
|
1298
|
-
break
|
1299
|
-
} w = -(w = Math.abs(l[S] - w) < Math.abs(l[S - 1] - w) || "next" === t.swipeDirection ? l[S] : l[S - 1])
|
1300
|
-
}
|
1301
|
-
if (x && t.once("transitionEnd", function () {
|
1302
|
-
t.loopFix()
|
1303
|
-
}), 0 !== t.velocity) g = r ? Math.abs((-w - t.translate) / t.velocity) : Math.abs((w - t.translate) / t.velocity);
|
1304
|
-
else if (i.freeModeSticky) return void t.slideToClosest();
|
1305
|
-
i.freeModeMomentumBounce && T ? (t.updateProgress(y), t.setTransition(g), t.setTranslate(w), t.transitionStart(!0, t.swipeDirection), t.animating = !0, n.transitionEnd(function () {
|
1306
|
-
t && !t.destroyed && a.allowMomentumBounce && (t.emit("momentumBounce"), t.setTransition(i.speed), t.setTranslate(y), n.transitionEnd(function () {
|
1307
|
-
t && !t.destroyed && t.transitionEnd()
|
1308
|
-
}))
|
1309
|
-
})) : t.velocity ? (t.updateProgress(w), t.setTransition(g), t.setTranslate(w), t.transitionStart(!0, t.swipeDirection), t.animating || (t.animating = !0, n.transitionEnd(function () {
|
1310
|
-
t && !t.destroyed && t.transitionEnd()
|
1311
|
-
}))) : t.updateProgress(w), t.updateActiveIndex(), t.updateSlidesClasses()
|
1312
|
-
} else if (i.freeModeSticky) return void t.slideToClosest();
|
1313
|
-
(!i.freeModeMomentum || u >= i.longSwipesMs) && (t.updateProgress(), t.updateActiveIndex(), t.updateSlidesClasses())
|
1314
|
-
} else {
|
1315
|
-
for (var M = 0, k = t.slidesSizesGrid[0], z = 0; z < o.length; z += i.slidesPerGroup) void 0 !== o[z + i.slidesPerGroup] ? p >= o[z] && p < o[z + i.slidesPerGroup] && (k = o[(M = z) + i.slidesPerGroup] - o[z]) : p >= o[z] && (M = z, k = o[o.length - 1] - o[o.length - 2]);
|
1316
|
-
var P = (p - o[M]) / k;
|
1317
|
-
if (u > i.longSwipesMs) {
|
1318
|
-
if (!i.longSwipes) return void t.slideTo(t.activeIndex);
|
1319
|
-
"next" === t.swipeDirection && (P >= i.longSwipesRatio ? t.slideTo(M + i.slidesPerGroup) : t.slideTo(M)), "prev" === t.swipeDirection && (P > 1 - i.longSwipesRatio ? t.slideTo(M + i.slidesPerGroup) : t.slideTo(M))
|
1320
|
-
} else {
|
1321
|
-
if (!i.shortSwipes) return void t.slideTo(t.activeIndex);
|
1322
|
-
"next" === t.swipeDirection && t.slideTo(M + i.slidesPerGroup), "prev" === t.swipeDirection && t.slideTo(M)
|
1323
|
-
}
|
1324
|
-
}
|
1325
|
-
}.bind(e), e.onClick = function (e) {
|
1326
|
-
this.allowClick || (this.params.preventClicks && e.preventDefault(), this.params.preventClicksPropagation && this.animating && (e.stopPropagation(), e.stopImmediatePropagation()))
|
1327
|
-
}.bind(e);
|
1328
|
-
var r = "container" === t.touchEventsTarget ? i : s,
|
1329
|
-
n = !!t.nested;
|
1330
|
-
if (R.touch || !R.pointerEvents && !R.prefixedPointerEvents) {
|
1331
|
-
if (R.touch) {
|
1332
|
-
var o = !("touchstart" !== a.start || !R.passiveListener || !t.passiveListeners) && {
|
1333
|
-
passive: !0,
|
1334
|
-
capture: !1
|
1335
|
-
};
|
1336
|
-
r.addEventListener(a.start, e.onTouchStart, o), r.addEventListener(a.move, e.onTouchMove, R.passiveListener ? {
|
1337
|
-
passive: !1,
|
1338
|
-
capture: n
|
1339
|
-
} : n), r.addEventListener(a.end, e.onTouchEnd, o)
|
1340
|
-
}(t.simulateTouch && !m.ios && !m.android || t.simulateTouch && !R.touch && m.ios) && (r.addEventListener("mousedown", e.onTouchStart, !1), f.addEventListener("mousemove", e.onTouchMove, n), f.addEventListener("mouseup", e.onTouchEnd, !1))
|
1341
|
-
} else r.addEventListener(a.start, e.onTouchStart, !1), f.addEventListener(a.move, e.onTouchMove, n), f.addEventListener(a.end, e.onTouchEnd, !1);
|
1342
|
-
(t.preventClicks || t.preventClicksPropagation) && r.addEventListener("click", e.onClick, !0), e.on(m.ios || m.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", g, !0)
|
1343
|
-
},
|
1344
|
-
detachEvents: function () {
|
1345
|
-
var e = this,
|
1346
|
-
t = e.params,
|
1347
|
-
a = e.touchEvents,
|
1348
|
-
i = e.el,
|
1349
|
-
s = e.wrapperEl,
|
1350
|
-
r = "container" === t.touchEventsTarget ? i : s,
|
1351
|
-
n = !!t.nested;
|
1352
|
-
if (R.touch || !R.pointerEvents && !R.prefixedPointerEvents) {
|
1353
|
-
if (R.touch) {
|
1354
|
-
var o = !("onTouchStart" !== a.start || !R.passiveListener || !t.passiveListeners) && {
|
1355
|
-
passive: !0,
|
1356
|
-
capture: !1
|
1357
|
-
};
|
1358
|
-
r.removeEventListener(a.start, e.onTouchStart, o), r.removeEventListener(a.move, e.onTouchMove, n), r.removeEventListener(a.end, e.onTouchEnd, o)
|
1359
|
-
}(t.simulateTouch && !m.ios && !m.android || t.simulateTouch && !R.touch && m.ios) && (r.removeEventListener("mousedown", e.onTouchStart, !1), f.removeEventListener("mousemove", e.onTouchMove, n), f.removeEventListener("mouseup", e.onTouchEnd, !1))
|
1360
|
-
} else r.removeEventListener(a.start, e.onTouchStart, !1), f.removeEventListener(a.move, e.onTouchMove, n), f.removeEventListener(a.end, e.onTouchEnd, !1);
|
1361
|
-
(t.preventClicks || t.preventClicksPropagation) && r.removeEventListener("click", e.onClick, !0), e.off(m.ios || m.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", g)
|
1362
|
-
}
|
1363
|
-
};
|
1364
|
-
var w, y = {
|
1365
|
-
setBreakpoint: function () {
|
1366
|
-
var e = this,
|
1367
|
-
t = e.activeIndex,
|
1368
|
-
a = e.initialized,
|
1369
|
-
i = e.loopedSlides;
|
1370
|
-
void 0 === i && (i = 0);
|
1371
|
-
var s = e.params,
|
1372
|
-
r = s.breakpoints;
|
1373
|
-
if (r && (!r || 0 !== Object.keys(r).length)) {
|
1374
|
-
var n = e.getBreakpoint(r);
|
1375
|
-
if (n && e.currentBreakpoint !== n) {
|
1376
|
-
var o = n in r ? r[n] : e.originalParams,
|
1377
|
-
l = s.loop && o.slidesPerView !== s.slidesPerView;
|
1378
|
-
V.extend(e.params, o), V.extend(e, {
|
1379
|
-
allowTouchMove: e.params.allowTouchMove,
|
1380
|
-
allowSlideNext: e.params.allowSlideNext,
|
1381
|
-
allowSlidePrev: e.params.allowSlidePrev
|
1382
|
-
}), e.currentBreakpoint = n, l && a && (e.loopDestroy(), e.loopCreate(), e.updateSlides(), e.slideTo(t - i + e.loopedSlides, 0, !1)), e.emit("breakpoint", o)
|
1383
|
-
}
|
1384
|
-
}
|
1385
|
-
},
|
1386
|
-
getBreakpoint: function (e) {
|
1387
|
-
if (e) {
|
1388
|
-
var t = !1,
|
1389
|
-
a = [];
|
1390
|
-
Object.keys(e).forEach(function (e) {
|
1391
|
-
a.push(e)
|
1392
|
-
}), a.sort(function (e, t) {
|
1393
|
-
return parseInt(e, 10) - parseInt(t, 10)
|
1394
|
-
});
|
1395
|
-
for (var i = 0; i < a.length; i += 1) {
|
1396
|
-
var s = a[i];
|
1397
|
-
this.params.breakpointsInverse ? s <= Y.innerWidth && (t = s) : s >= Y.innerWidth && !t && (t = s)
|
1398
|
-
}
|
1399
|
-
return t || "max"
|
1400
|
-
}
|
1401
|
-
}
|
1402
|
-
},
|
1403
|
-
I = {
|
1404
|
-
isIE: !!Y.navigator.userAgent.match(/Trident/g) || !!Y.navigator.userAgent.match(/MSIE/g),
|
1405
|
-
isEdge: !!Y.navigator.userAgent.match(/Edge/g),
|
1406
|
-
isSafari: (w = Y.navigator.userAgent.toLowerCase(), 0 <= w.indexOf("safari") && w.indexOf("chrome") < 0 && w.indexOf("android") < 0),
|
1407
|
-
isUiWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(Y.navigator.userAgent)
|
1408
|
-
};
|
1409
|
-
var x = {
|
1410
|
-
init: !0,
|
1411
|
-
direction: "horizontal",
|
1412
|
-
touchEventsTarget: "container",
|
1413
|
-
initialSlide: 0,
|
1414
|
-
speed: 300,
|
1415
|
-
preventInteractionOnTransition: !1,
|
1416
|
-
edgeSwipeDetection: !1,
|
1417
|
-
edgeSwipeThreshold: 20,
|
1418
|
-
freeMode: !1,
|
1419
|
-
freeModeMomentum: !0,
|
1420
|
-
freeModeMomentumRatio: 1,
|
1421
|
-
freeModeMomentumBounce: !0,
|
1422
|
-
freeModeMomentumBounceRatio: 1,
|
1423
|
-
freeModeMomentumVelocityRatio: 1,
|
1424
|
-
freeModeSticky: !1,
|
1425
|
-
freeModeMinimumVelocity: .02,
|
1426
|
-
autoHeight: !1,
|
1427
|
-
setWrapperSize: !1,
|
1428
|
-
virtualTranslate: !1,
|
1429
|
-
effect: "slide",
|
1430
|
-
breakpoints: void 0,
|
1431
|
-
breakpointsInverse: !1,
|
1432
|
-
spaceBetween: 0,
|
1433
|
-
slidesPerView: 1,
|
1434
|
-
slidesPerColumn: 1,
|
1435
|
-
slidesPerColumnFill: "column",
|
1436
|
-
slidesPerGroup: 1,
|
1437
|
-
centeredSlides: !1,
|
1438
|
-
slidesOffsetBefore: 0,
|
1439
|
-
slidesOffsetAfter: 0,
|
1440
|
-
normalizeSlideIndex: !0,
|
1441
|
-
centerInsufficientSlides: !1,
|
1442
|
-
watchOverflow: !1,
|
1443
|
-
roundLengths: !1,
|
1444
|
-
touchRatio: 1,
|
1445
|
-
touchAngle: 45,
|
1446
|
-
simulateTouch: !0,
|
1447
|
-
shortSwipes: !0,
|
1448
|
-
longSwipes: !0,
|
1449
|
-
longSwipesRatio: .5,
|
1450
|
-
longSwipesMs: 300,
|
1451
|
-
followFinger: !0,
|
1452
|
-
allowTouchMove: !0,
|
1453
|
-
threshold: 0,
|
1454
|
-
touchMoveStopPropagation: !0,
|
1455
|
-
touchStartPreventDefault: !0,
|
1456
|
-
touchReleaseOnEdges: !1,
|
1457
|
-
uniqueNavElements: !0,
|
1458
|
-
resistance: !0,
|
1459
|
-
resistanceRatio: .85,
|
1460
|
-
watchSlidesProgress: !1,
|
1461
|
-
watchSlidesVisibility: !1,
|
1462
|
-
grabCursor: !1,
|
1463
|
-
preventClicks: !0,
|
1464
|
-
preventClicksPropagation: !0,
|
1465
|
-
slideToClickedSlide: !1,
|
1466
|
-
preloadImages: !0,
|
1467
|
-
updateOnImagesReady: !0,
|
1468
|
-
loop: !1,
|
1469
|
-
loopAdditionalSlides: 0,
|
1470
|
-
loopedSlides: null,
|
1471
|
-
loopFillGroupWithBlank: !1,
|
1472
|
-
allowSlidePrev: !0,
|
1473
|
-
allowSlideNext: !0,
|
1474
|
-
swipeHandler: null,
|
1475
|
-
noSwiping: !0,
|
1476
|
-
noSwipingClass: "swiper-no-swiping",
|
1477
|
-
noSwipingSelector: null,
|
1478
|
-
passiveListeners: !0,
|
1479
|
-
containerModifierClass: "swiper-container-",
|
1480
|
-
slideClass: "swiper-slide",
|
1481
|
-
slideBlankClass: "swiper-slide-invisible-blank",
|
1482
|
-
slideActiveClass: "swiper-slide-active",
|
1483
|
-
slideDuplicateActiveClass: "swiper-slide-duplicate-active",
|
1484
|
-
slideVisibleClass: "swiper-slide-visible",
|
1485
|
-
slideDuplicateClass: "swiper-slide-duplicate",
|
1486
|
-
slideNextClass: "swiper-slide-next",
|
1487
|
-
slideDuplicateNextClass: "swiper-slide-duplicate-next",
|
1488
|
-
slidePrevClass: "swiper-slide-prev",
|
1489
|
-
slideDuplicatePrevClass: "swiper-slide-duplicate-prev",
|
1490
|
-
wrapperClass: "swiper-wrapper",
|
1491
|
-
runCallbacksOnInit: !0
|
1492
|
-
},
|
1493
|
-
T = {
|
1494
|
-
update: o,
|
1495
|
-
translate: d,
|
1496
|
-
transition: p,
|
1497
|
-
slide: c,
|
1498
|
-
loop: u,
|
1499
|
-
grabCursor: h,
|
1500
|
-
manipulation: v,
|
1501
|
-
events: b,
|
1502
|
-
breakpoints: y,
|
1503
|
-
checkOverflow: {
|
1504
|
-
checkOverflow: function () {
|
1505
|
-
var e = this,
|
1506
|
-
t = e.isLocked;
|
1507
|
-
e.isLocked = 1 === e.snapGrid.length, e.allowSlideNext = !e.isLocked, e.allowSlidePrev = !e.isLocked, t !== e.isLocked && e.emit(e.isLocked ? "lock" : "unlock"), t && t !== e.isLocked && (e.isEnd = !1, e.navigation.update())
|
1508
|
-
}
|
1509
|
-
},
|
1510
|
-
classes: {
|
1511
|
-
addClasses: function () {
|
1512
|
-
var t = this.classNames,
|
1513
|
-
a = this.params,
|
1514
|
-
e = this.rtl,
|
1515
|
-
i = this.$el,
|
1516
|
-
s = [];
|
1517
|
-
s.push(a.direction), a.freeMode && s.push("free-mode"), R.flexbox || s.push("no-flexbox"), a.autoHeight && s.push("autoheight"), e && s.push("rtl"), 1 < a.slidesPerColumn && s.push("multirow"), m.android && s.push("android"), m.ios && s.push("ios"), (I.isIE || I.isEdge) && (R.pointerEvents || R.prefixedPointerEvents) && s.push("wp8-" + a.direction), s.forEach(function (e) {
|
1518
|
-
t.push(a.containerModifierClass + e)
|
1519
|
-
}), i.addClass(t.join(" "))
|
1520
|
-
},
|
1521
|
-
removeClasses: function () {
|
1522
|
-
var e = this.$el,
|
1523
|
-
t = this.classNames;
|
1524
|
-
e.removeClass(t.join(" "))
|
1525
|
-
}
|
1526
|
-
},
|
1527
|
-
images: {
|
1528
|
-
loadImage: function (e, t, a, i, s, r) {
|
1529
|
-
var n;
|
1530
|
-
|
1531
|
-
function o() {
|
1532
|
-
r && r()
|
1533
|
-
}
|
1534
|
-
e.complete && s ? o() : t ? ((n = new Y.Image).onload = o, n.onerror = o, i && (n.sizes = i), a && (n.srcset = a), t && (n.src = t)) : o()
|
1535
|
-
},
|
1536
|
-
preloadImages: function () {
|
1537
|
-
var e = this;
|
1538
|
-
|
1539
|
-
function t() {
|
1540
|
-
null != e && e && !e.destroyed && (void 0 !== e.imagesLoaded && (e.imagesLoaded += 1), e.imagesLoaded === e.imagesToLoad.length && (e.params.updateOnImagesReady && e.update(), e.emit("imagesReady")))
|
1541
|
-
}
|
1542
|
-
e.imagesToLoad = e.$el.find("img");
|
1543
|
-
for (var a = 0; a < e.imagesToLoad.length; a += 1) {
|
1544
|
-
var i = e.imagesToLoad[a];
|
1545
|
-
e.loadImage(i, i.currentSrc || i.getAttribute("src"), i.srcset || i.getAttribute("srcset"), i.sizes || i.getAttribute("sizes"), !0, t)
|
1546
|
-
}
|
1547
|
-
}
|
1548
|
-
}
|
1549
|
-
},
|
1550
|
-
E = {},
|
1551
|
-
S = function (u) {
|
1552
|
-
function h() {
|
1553
|
-
for (var e, t, s, a = [], i = arguments.length; i--;) a[i] = arguments[i];
|
1554
|
-
1 === a.length && a[0].constructor && a[0].constructor === Object ? s = a[0] : (t = (e = a)[0], s = e[1]), s || (s = {}), s = V.extend({}, s), t && !s.el && (s.el = t), u.call(this, s), Object.keys(T).forEach(function (t) {
|
1555
|
-
Object.keys(T[t]).forEach(function (e) {
|
1556
|
-
h.prototype[e] || (h.prototype[e] = T[t][e])
|
1557
|
-
})
|
1558
|
-
});
|
1559
|
-
var r = this;
|
1560
|
-
void 0 === r.modules && (r.modules = {}), Object.keys(r.modules).forEach(function (e) {
|
1561
|
-
var t = r.modules[e];
|
1562
|
-
if (t.params) {
|
1563
|
-
var a = Object.keys(t.params)[0],
|
1564
|
-
i = t.params[a];
|
1565
|
-
if ("object" != typeof i || null === i) return;
|
1566
|
-
if (!(a in s && "enabled" in i)) return;
|
1567
|
-
!0 === s[a] && (s[a] = {
|
1568
|
-
enabled: !0
|
1569
|
-
}), "object" != typeof s[a] || "enabled" in s[a] || (s[a].enabled = !0), s[a] || (s[a] = {
|
1570
|
-
enabled: !1
|
1571
|
-
})
|
1572
|
-
}
|
1573
|
-
});
|
1574
|
-
var n = V.extend({}, x);
|
1575
|
-
r.useModulesParams(n), r.params = V.extend({}, n, E, s), r.originalParams = V.extend({}, r.params), r.passedParams = V.extend({}, s);
|
1576
|
-
var o = (r.$ = L)(r.params.el);
|
1577
|
-
if (t = o[0]) {
|
1578
|
-
if (1 < o.length) {
|
1579
|
-
var l = [];
|
1580
|
-
return o.each(function (e, t) {
|
1581
|
-
var a = V.extend({}, s, {
|
1582
|
-
el: t
|
1583
|
-
});
|
1584
|
-
l.push(new h(a))
|
1585
|
-
}), l
|
1586
|
-
}
|
1587
|
-
t.swiper = r, o.data("swiper", r);
|
1588
|
-
var d, p, c = o.children("." + r.params.wrapperClass);
|
1589
|
-
return V.extend(r, {
|
1590
|
-
$el: o,
|
1591
|
-
el: t,
|
1592
|
-
$wrapperEl: c,
|
1593
|
-
wrapperEl: c[0],
|
1594
|
-
classNames: [],
|
1595
|
-
slides: L(),
|
1596
|
-
slidesGrid: [],
|
1597
|
-
snapGrid: [],
|
1598
|
-
slidesSizesGrid: [],
|
1599
|
-
isHorizontal: function () {
|
1600
|
-
return "horizontal" === r.params.direction
|
1601
|
-
},
|
1602
|
-
isVertical: function () {
|
1603
|
-
return "vertical" === r.params.direction
|
1604
|
-
},
|
1605
|
-
rtl: "rtl" === t.dir.toLowerCase() || "rtl" === o.css("direction"),
|
1606
|
-
rtlTranslate: "horizontal" === r.params.direction && ("rtl" === t.dir.toLowerCase() || "rtl" === o.css("direction")),
|
1607
|
-
wrongRTL: "-webkit-box" === c.css("display"),
|
1608
|
-
activeIndex: 0,
|
1609
|
-
realIndex: 0,
|
1610
|
-
isBeginning: !0,
|
1611
|
-
isEnd: !1,
|
1612
|
-
translate: 0,
|
1613
|
-
previousTranslate: 0,
|
1614
|
-
progress: 0,
|
1615
|
-
velocity: 0,
|
1616
|
-
animating: !1,
|
1617
|
-
allowSlideNext: r.params.allowSlideNext,
|
1618
|
-
allowSlidePrev: r.params.allowSlidePrev,
|
1619
|
-
touchEvents: (d = ["touchstart", "touchmove", "touchend"], p = ["mousedown", "mousemove", "mouseup"], R.pointerEvents ? p = ["pointerdown", "pointermove", "pointerup"] : R.prefixedPointerEvents && (p = ["MSPointerDown", "MSPointerMove", "MSPointerUp"]), r.touchEventsTouch = {
|
1620
|
-
start: d[0],
|
1621
|
-
move: d[1],
|
1622
|
-
end: d[2]
|
1623
|
-
}, r.touchEventsDesktop = {
|
1624
|
-
start: p[0],
|
1625
|
-
move: p[1],
|
1626
|
-
end: p[2]
|
1627
|
-
}, R.touch || !r.params.simulateTouch ? r.touchEventsTouch : r.touchEventsDesktop),
|
1628
|
-
touchEventsData: {
|
1629
|
-
isTouched: void 0,
|
1630
|
-
isMoved: void 0,
|
1631
|
-
allowTouchCallbacks: void 0,
|
1632
|
-
touchStartTime: void 0,
|
1633
|
-
isScrolling: void 0,
|
1634
|
-
currentTranslate: void 0,
|
1635
|
-
startTranslate: void 0,
|
1636
|
-
allowThresholdMove: void 0,
|
1637
|
-
formElements: "input, select, option, textarea, button, video",
|
1638
|
-
lastClickTime: V.now(),
|
1639
|
-
clickTimeout: void 0,
|
1640
|
-
velocities: [],
|
1641
|
-
allowMomentumBounce: void 0,
|
1642
|
-
isTouchEvent: void 0,
|
1643
|
-
startMoving: void 0
|
1644
|
-
},
|
1645
|
-
allowClick: !0,
|
1646
|
-
allowTouchMove: r.params.allowTouchMove,
|
1647
|
-
touches: {
|
1648
|
-
startX: 0,
|
1649
|
-
startY: 0,
|
1650
|
-
currentX: 0,
|
1651
|
-
currentY: 0,
|
1652
|
-
diff: 0
|
1653
|
-
},
|
1654
|
-
imagesToLoad: [],
|
1655
|
-
imagesLoaded: 0
|
1656
|
-
}), r.useModules(), r.params.init && r.init(), r
|
1657
|
-
}
|
1658
|
-
}
|
1659
|
-
u && (h.__proto__ = u);
|
1660
|
-
var e = {
|
1661
|
-
extendedDefaults: {
|
1662
|
-
configurable: !0
|
1663
|
-
},
|
1664
|
-
defaults: {
|
1665
|
-
configurable: !0
|
1666
|
-
},
|
1667
|
-
Class: {
|
1668
|
-
configurable: !0
|
1669
|
-
},
|
1670
|
-
$: {
|
1671
|
-
configurable: !0
|
1672
|
-
}
|
1673
|
-
};
|
1674
|
-
return ((h.prototype = Object.create(u && u.prototype)).constructor = h).prototype.slidesPerViewDynamic = function () {
|
1675
|
-
var e = this,
|
1676
|
-
t = e.params,
|
1677
|
-
a = e.slides,
|
1678
|
-
i = e.slidesGrid,
|
1679
|
-
s = e.size,
|
1680
|
-
r = e.activeIndex,
|
1681
|
-
n = 1;
|
1682
|
-
if (t.centeredSlides) {
|
1683
|
-
for (var o, l = a[r].swiperSlideSize, d = r + 1; d < a.length; d += 1) a[d] && !o && (n += 1, s < (l += a[d].swiperSlideSize) && (o = !0));
|
1684
|
-
for (var p = r - 1; 0 <= p; p -= 1) a[p] && !o && (n += 1, s < (l += a[p].swiperSlideSize) && (o = !0))
|
1685
|
-
} else
|
1686
|
-
for (var c = r + 1; c < a.length; c += 1) i[c] - i[r] < s && (n += 1);
|
1687
|
-
return n
|
1688
|
-
}, h.prototype.update = function () {
|
1689
|
-
var a = this;
|
1690
|
-
if (a && !a.destroyed) {
|
1691
|
-
var e = a.snapGrid,
|
1692
|
-
t = a.params;
|
1693
|
-
t.breakpoints && a.setBreakpoint(), a.updateSize(), a.updateSlides(), a.updateProgress(), a.updateSlidesClasses(), a.params.freeMode ? (i(), a.params.autoHeight && a.updateAutoHeight()) : (("auto" === a.params.slidesPerView || 1 < a.params.slidesPerView) && a.isEnd && !a.params.centeredSlides ? a.slideTo(a.slides.length - 1, 0, !1, !0) : a.slideTo(a.activeIndex, 0, !1, !0)) || i(), t.watchOverflow && e !== a.snapGrid && a.checkOverflow(), a.emit("update")
|
1694
|
-
}
|
1695
|
-
|
1696
|
-
function i() {
|
1697
|
-
var e = a.rtlTranslate ? -1 * a.translate : a.translate,
|
1698
|
-
t = Math.min(Math.max(e, a.maxTranslate()), a.minTranslate());
|
1699
|
-
a.setTranslate(t), a.updateActiveIndex(), a.updateSlidesClasses()
|
1700
|
-
}
|
1701
|
-
}, h.prototype.init = function () {
|
1702
|
-
var e = this;
|
1703
|
-
e.initialized || (e.emit("beforeInit"), e.params.breakpoints && e.setBreakpoint(), e.addClasses(), e.params.loop && e.loopCreate(), e.updateSize(), e.updateSlides(), e.params.watchOverflow && e.checkOverflow(), e.params.grabCursor && e.setGrabCursor(), e.params.preloadImages && e.preloadImages(), e.params.loop ? e.slideTo(e.params.initialSlide + e.loopedSlides, 0, e.params.runCallbacksOnInit) : e.slideTo(e.params.initialSlide, 0, e.params.runCallbacksOnInit), e.attachEvents(), e.initialized = !0, e.emit("init"))
|
1704
|
-
}, h.prototype.destroy = function (e, t) {
|
1705
|
-
void 0 === e && (e = !0), void 0 === t && (t = !0);
|
1706
|
-
var a = this,
|
1707
|
-
i = a.params,
|
1708
|
-
s = a.$el,
|
1709
|
-
r = a.$wrapperEl,
|
1710
|
-
n = a.slides;
|
1711
|
-
return void 0 === a.params || a.destroyed || (a.emit("beforeDestroy"), a.initialized = !1, a.detachEvents(), i.loop && a.loopDestroy(), t && (a.removeClasses(), s.removeAttr("style"), r.removeAttr("style"), n && n.length && n.removeClass([i.slideVisibleClass, i.slideActiveClass, i.slideNextClass, i.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index").removeAttr("data-swiper-column").removeAttr("data-swiper-row")), a.emit("destroy"), Object.keys(a.eventsListeners).forEach(function (e) {
|
1712
|
-
a.off(e)
|
1713
|
-
}), !1 !== e && (a.$el[0].swiper = null, a.$el.data("swiper", null), V.deleteProps(a)), a.destroyed = !0), null
|
1714
|
-
}, h.extendDefaults = function (e) {
|
1715
|
-
V.extend(E, e)
|
1716
|
-
}, e.extendedDefaults.get = function () {
|
1717
|
-
return E
|
1718
|
-
}, e.defaults.get = function () {
|
1719
|
-
return x
|
1720
|
-
}, e.Class.get = function () {
|
1721
|
-
return u
|
1722
|
-
}, e.$.get = function () {
|
1723
|
-
return L
|
1724
|
-
}, Object.defineProperties(h, e), h
|
1725
|
-
}(s),
|
1726
|
-
C = {
|
1727
|
-
name: "device",
|
1728
|
-
proto: {
|
1729
|
-
device: m
|
1730
|
-
},
|
1731
|
-
static: {
|
1732
|
-
device: m
|
1733
|
-
}
|
1734
|
-
},
|
1735
|
-
M = {
|
1736
|
-
name: "support",
|
1737
|
-
proto: {
|
1738
|
-
support: R
|
1739
|
-
},
|
1740
|
-
static: {
|
1741
|
-
support: R
|
1742
|
-
}
|
1743
|
-
},
|
1744
|
-
k = {
|
1745
|
-
name: "browser",
|
1746
|
-
proto: {
|
1747
|
-
browser: I
|
1748
|
-
},
|
1749
|
-
static: {
|
1750
|
-
browser: I
|
1751
|
-
}
|
1752
|
-
},
|
1753
|
-
z = {
|
1754
|
-
name: "resize",
|
1755
|
-
create: function () {
|
1756
|
-
var e = this;
|
1757
|
-
V.extend(e, {
|
1758
|
-
resize: {
|
1759
|
-
resizeHandler: function () {
|
1760
|
-
e && !e.destroyed && e.initialized && (e.emit("beforeResize"), e.emit("resize"))
|
1761
|
-
},
|
1762
|
-
orientationChangeHandler: function () {
|
1763
|
-
e && !e.destroyed && e.initialized && e.emit("orientationchange")
|
1764
|
-
}
|
1765
|
-
}
|
1766
|
-
})
|
1767
|
-
},
|
1768
|
-
on: {
|
1769
|
-
init: function () {
|
1770
|
-
Y.addEventListener("resize", this.resize.resizeHandler), Y.addEventListener("orientationchange", this.resize.orientationChangeHandler)
|
1771
|
-
},
|
1772
|
-
destroy: function () {
|
1773
|
-
Y.removeEventListener("resize", this.resize.resizeHandler), Y.removeEventListener("orientationchange", this.resize.orientationChangeHandler)
|
1774
|
-
}
|
1775
|
-
}
|
1776
|
-
},
|
1777
|
-
P = {
|
1778
|
-
func: Y.MutationObserver || Y.WebkitMutationObserver,
|
1779
|
-
attach: function (e, t) {
|
1780
|
-
void 0 === t && (t = {});
|
1781
|
-
var a = this,
|
1782
|
-
i = new P.func(function (e) {
|
1783
|
-
if (1 !== e.length) {
|
1784
|
-
var t = function () {
|
1785
|
-
a.emit("observerUpdate", e[0])
|
1786
|
-
};
|
1787
|
-
Y.requestAnimationFrame ? Y.requestAnimationFrame(t) : Y.setTimeout(t, 0)
|
1788
|
-
} else a.emit("observerUpdate", e[0])
|
1789
|
-
});
|
1790
|
-
i.observe(e, {
|
1791
|
-
attributes: void 0 === t.attributes || t.attributes,
|
1792
|
-
childList: void 0 === t.childList || t.childList,
|
1793
|
-
characterData: void 0 === t.characterData || t.characterData
|
1794
|
-
}), a.observer.observers.push(i)
|
1795
|
-
},
|
1796
|
-
init: function () {
|
1797
|
-
var e = this;
|
1798
|
-
if (R.observer && e.params.observer) {
|
1799
|
-
if (e.params.observeParents)
|
1800
|
-
for (var t = e.$el.parents(), a = 0; a < t.length; a += 1) e.observer.attach(t[a]);
|
1801
|
-
e.observer.attach(e.$el[0], {
|
1802
|
-
childList: !1
|
1803
|
-
}), e.observer.attach(e.$wrapperEl[0], {
|
1804
|
-
attributes: !1
|
1805
|
-
})
|
1806
|
-
}
|
1807
|
-
},
|
1808
|
-
destroy: function () {
|
1809
|
-
this.observer.observers.forEach(function (e) {
|
1810
|
-
e.disconnect()
|
1811
|
-
}), this.observer.observers = []
|
1812
|
-
}
|
1813
|
-
},
|
1814
|
-
$ = {
|
1815
|
-
name: "observer",
|
1816
|
-
params: {
|
1817
|
-
observer: !1,
|
1818
|
-
observeParents: !1
|
1819
|
-
},
|
1820
|
-
create: function () {
|
1821
|
-
V.extend(this, {
|
1822
|
-
observer: {
|
1823
|
-
init: P.init.bind(this),
|
1824
|
-
attach: P.attach.bind(this),
|
1825
|
-
destroy: P.destroy.bind(this),
|
1826
|
-
observers: []
|
1827
|
-
}
|
1828
|
-
})
|
1829
|
-
},
|
1830
|
-
on: {
|
1831
|
-
init: function () {
|
1832
|
-
this.observer.init()
|
1833
|
-
},
|
1834
|
-
destroy: function () {
|
1835
|
-
this.observer.destroy()
|
1836
|
-
}
|
1837
|
-
}
|
1838
|
-
},
|
1839
|
-
D = {
|
1840
|
-
update: function (e) {
|
1841
|
-
var t = this,
|
1842
|
-
a = t.params,
|
1843
|
-
i = a.slidesPerView,
|
1844
|
-
s = a.slidesPerGroup,
|
1845
|
-
r = a.centeredSlides,
|
1846
|
-
n = t.params.virtual,
|
1847
|
-
o = n.addSlidesBefore,
|
1848
|
-
l = n.addSlidesAfter,
|
1849
|
-
d = t.virtual,
|
1850
|
-
p = d.from,
|
1851
|
-
c = d.to,
|
1852
|
-
u = d.slides,
|
1853
|
-
h = d.slidesGrid,
|
1854
|
-
v = d.renderSlide,
|
1855
|
-
f = d.offset;
|
1856
|
-
t.updateActiveIndex();
|
1857
|
-
var m, g, b, w = t.activeIndex || 0;
|
1858
|
-
m = t.rtlTranslate ? "right" : t.isHorizontal() ? "left" : "top", r ? (g = Math.floor(i / 2) + s + o, b = Math.floor(i / 2) + s + l) : (g = i + (s - 1) + o, b = s + l);
|
1859
|
-
var y = Math.max((w || 0) - b, 0),
|
1860
|
-
x = Math.min((w || 0) + g, u.length - 1),
|
1861
|
-
T = (t.slidesGrid[y] || 0) - (t.slidesGrid[0] || 0);
|
1862
|
-
|
1863
|
-
function E() {
|
1864
|
-
t.updateSlides(), t.updateProgress(), t.updateSlidesClasses(), t.lazy && t.params.lazy.enabled && t.lazy.load()
|
1865
|
-
}
|
1866
|
-
if (V.extend(t.virtual, {
|
1867
|
-
from: y,
|
1868
|
-
to: x,
|
1869
|
-
offset: T,
|
1870
|
-
slidesGrid: t.slidesGrid
|
1871
|
-
}), p === y && c === x && !e) return t.slidesGrid !== h && T !== f && t.slides.css(m, T + "px"), void t.updateProgress();
|
1872
|
-
if (t.params.virtual.renderExternal) return t.params.virtual.renderExternal.call(t, {
|
1873
|
-
offset: T,
|
1874
|
-
from: y,
|
1875
|
-
to: x,
|
1876
|
-
slides: function () {
|
1877
|
-
for (var e = [], t = y; t <= x; t += 1) e.push(u[t]);
|
1878
|
-
return e
|
1879
|
-
}()
|
1880
|
-
}), void E();
|
1881
|
-
var S = [],
|
1882
|
-
C = [];
|
1883
|
-
if (e) t.$wrapperEl.find("." + t.params.slideClass).remove();
|
1884
|
-
else
|
1885
|
-
for (var M = p; M <= c; M += 1)(M < y || x < M) && t.$wrapperEl.find("." + t.params.slideClass + '[data-swiper-slide-index="' + M + '"]').remove();
|
1886
|
-
for (var k = 0; k < u.length; k += 1) y <= k && k <= x && (void 0 === c || e ? C.push(k) : (c < k && C.push(k), k < p && S.push(k)));
|
1887
|
-
C.forEach(function (e) {
|
1888
|
-
t.$wrapperEl.append(v(u[e], e))
|
1889
|
-
}), S.sort(function (e, t) {
|
1890
|
-
return e < t
|
1891
|
-
}).forEach(function (e) {
|
1892
|
-
t.$wrapperEl.prepend(v(u[e], e))
|
1893
|
-
}), t.$wrapperEl.children(".swiper-slide").css(m, T + "px"), E()
|
1894
|
-
},
|
1895
|
-
renderSlide: function (e, t) {
|
1896
|
-
var a = this,
|
1897
|
-
i = a.params.virtual;
|
1898
|
-
if (i.cache && a.virtual.cache[t]) return a.virtual.cache[t];
|
1899
|
-
var s = i.renderSlide ? L(i.renderSlide.call(a, e, t)) : L('<div class="' + a.params.slideClass + '" data-swiper-slide-index="' + t + '">' + e + "</div>");
|
1900
|
-
return s.attr("data-swiper-slide-index") || s.attr("data-swiper-slide-index", t), i.cache && (a.virtual.cache[t] = s), s
|
1901
|
-
},
|
1902
|
-
appendSlide: function (e) {
|
1903
|
-
this.virtual.slides.push(e), this.virtual.update(!0)
|
1904
|
-
},
|
1905
|
-
prependSlide: function (e) {
|
1906
|
-
var t = this;
|
1907
|
-
if (t.virtual.slides.unshift(e), t.params.virtual.cache) {
|
1908
|
-
var a = t.virtual.cache,
|
1909
|
-
i = {};
|
1910
|
-
Object.keys(a).forEach(function (e) {
|
1911
|
-
i[e + 1] = a[e]
|
1912
|
-
}), t.virtual.cache = i
|
1913
|
-
}
|
1914
|
-
t.virtual.update(!0), t.slideNext(0)
|
1915
|
-
}
|
1916
|
-
},
|
1917
|
-
O = {
|
1918
|
-
name: "virtual",
|
1919
|
-
params: {
|
1920
|
-
virtual: {
|
1921
|
-
enabled: !1,
|
1922
|
-
slides: [],
|
1923
|
-
cache: !0,
|
1924
|
-
renderSlide: null,
|
1925
|
-
renderExternal: null,
|
1926
|
-
addSlidesBefore: 0,
|
1927
|
-
addSlidesAfter: 0
|
1928
|
-
}
|
1929
|
-
},
|
1930
|
-
create: function () {
|
1931
|
-
var e = this;
|
1932
|
-
V.extend(e, {
|
1933
|
-
virtual: {
|
1934
|
-
update: D.update.bind(e),
|
1935
|
-
appendSlide: D.appendSlide.bind(e),
|
1936
|
-
prependSlide: D.prependSlide.bind(e),
|
1937
|
-
renderSlide: D.renderSlide.bind(e),
|
1938
|
-
slides: e.params.virtual.slides,
|
1939
|
-
cache: {}
|
1940
|
-
}
|
1941
|
-
})
|
1942
|
-
},
|
1943
|
-
on: {
|
1944
|
-
beforeInit: function () {
|
1945
|
-
var e = this;
|
1946
|
-
if (e.params.virtual.enabled) {
|
1947
|
-
e.classNames.push(e.params.containerModifierClass + "virtual");
|
1948
|
-
var t = {
|
1949
|
-
watchSlidesProgress: !0
|
1950
|
-
};
|
1951
|
-
V.extend(e.params, t), V.extend(e.originalParams, t), e.virtual.update()
|
1952
|
-
}
|
1953
|
-
},
|
1954
|
-
setTranslate: function () {
|
1955
|
-
this.params.virtual.enabled && this.virtual.update()
|
1956
|
-
}
|
1957
|
-
}
|
1958
|
-
},
|
1959
|
-
A = {
|
1960
|
-
handle: function (e) {
|
1961
|
-
var t = this,
|
1962
|
-
a = t.rtlTranslate,
|
1963
|
-
i = e;
|
1964
|
-
i.originalEvent && (i = i.originalEvent);
|
1965
|
-
var s = i.keyCode || i.charCode;
|
1966
|
-
if (!t.allowSlideNext && (t.isHorizontal() && 39 === s || t.isVertical() && 40 === s)) return !1;
|
1967
|
-
if (!t.allowSlidePrev && (t.isHorizontal() && 37 === s || t.isVertical() && 38 === s)) return !1;
|
1968
|
-
if (!(i.shiftKey || i.altKey || i.ctrlKey || i.metaKey || f.activeElement && f.activeElement.nodeName && ("input" === f.activeElement.nodeName.toLowerCase() || "textarea" === f.activeElement.nodeName.toLowerCase()))) {
|
1969
|
-
if (t.params.keyboard.onlyInViewport && (37 === s || 39 === s || 38 === s || 40 === s)) {
|
1970
|
-
var r = !1;
|
1971
|
-
if (0 < t.$el.parents("." + t.params.slideClass).length && 0 === t.$el.parents("." + t.params.slideActiveClass).length) return;
|
1972
|
-
var n = Y.innerWidth,
|
1973
|
-
o = Y.innerHeight,
|
1974
|
-
l = t.$el.offset();
|
1975
|
-
a && (l.left -= t.$el[0].scrollLeft);
|
1976
|
-
for (var d = [
|
1977
|
-
[l.left, l.top],
|
1978
|
-
[l.left + t.width, l.top],
|
1979
|
-
[l.left, l.top + t.height],
|
1980
|
-
[l.left + t.width, l.top + t.height]
|
1981
|
-
], p = 0; p < d.length; p += 1) {
|
1982
|
-
var c = d[p];
|
1983
|
-
0 <= c[0] && c[0] <= n && 0 <= c[1] && c[1] <= o && (r = !0)
|
1984
|
-
}
|
1985
|
-
if (!r) return
|
1986
|
-
}
|
1987
|
-
t.isHorizontal() ? (37 !== s && 39 !== s || (i.preventDefault ? i.preventDefault() : i.returnValue = !1), (39 === s && !a || 37 === s && a) && t.slideNext(), (37 === s && !a || 39 === s && a) && t.slidePrev()) : (38 !== s && 40 !== s || (i.preventDefault ? i.preventDefault() : i.returnValue = !1), 40 === s && t.slideNext(), 38 === s && t.slidePrev()), t.emit("keyPress", s)
|
1988
|
-
}
|
1989
|
-
},
|
1990
|
-
enable: function () {
|
1991
|
-
this.keyboard.enabled || (L(f).on("keydown", this.keyboard.handle), this.keyboard.enabled = !0)
|
1992
|
-
},
|
1993
|
-
disable: function () {
|
1994
|
-
this.keyboard.enabled && (L(f).off("keydown", this.keyboard.handle), this.keyboard.enabled = !1)
|
1995
|
-
}
|
1996
|
-
},
|
1997
|
-
H = {
|
1998
|
-
name: "keyboard",
|
1999
|
-
params: {
|
2000
|
-
keyboard: {
|
2001
|
-
enabled: !1,
|
2002
|
-
onlyInViewport: !0
|
2003
|
-
}
|
2004
|
-
},
|
2005
|
-
create: function () {
|
2006
|
-
V.extend(this, {
|
2007
|
-
keyboard: {
|
2008
|
-
enabled: !1,
|
2009
|
-
enable: A.enable.bind(this),
|
2010
|
-
disable: A.disable.bind(this),
|
2011
|
-
handle: A.handle.bind(this)
|
2012
|
-
}
|
2013
|
-
})
|
2014
|
-
},
|
2015
|
-
on: {
|
2016
|
-
init: function () {
|
2017
|
-
this.params.keyboard.enabled && this.keyboard.enable()
|
2018
|
-
},
|
2019
|
-
destroy: function () {
|
2020
|
-
this.keyboard.enabled && this.keyboard.disable()
|
2021
|
-
}
|
2022
|
-
}
|
2023
|
-
};
|
2024
|
-
var B = {
|
2025
|
-
lastScrollTime: V.now(),
|
2026
|
-
event: -1 < Y.navigator.userAgent.indexOf("firefox") ? "DOMMouseScroll" : function () {
|
2027
|
-
var e = "onwheel",
|
2028
|
-
t = e in f;
|
2029
|
-
if (!t) {
|
2030
|
-
var a = f.createElement("div");
|
2031
|
-
a.setAttribute(e, "return;"), t = "function" == typeof a[e]
|
2032
|
-
}
|
2033
|
-
return !t && f.implementation && f.implementation.hasFeature && !0 !== f.implementation.hasFeature("", "") && (t = f.implementation.hasFeature("Events.wheel", "3.0")), t
|
2034
|
-
}() ? "wheel" : "mousewheel",
|
2035
|
-
normalize: function (e) {
|
2036
|
-
var t = 0,
|
2037
|
-
a = 0,
|
2038
|
-
i = 0,
|
2039
|
-
s = 0;
|
2040
|
-
return "detail" in e && (a = e.detail), "wheelDelta" in e && (a = -e.wheelDelta / 120), "wheelDeltaY" in e && (a = -e.wheelDeltaY / 120), "wheelDeltaX" in e && (t = -e.wheelDeltaX / 120), "axis" in e && e.axis === e.HORIZONTAL_AXIS && (t = a, a = 0), i = 10 * t, s = 10 * a, "deltaY" in e && (s = e.deltaY), "deltaX" in e && (i = e.deltaX), (i || s) && e.deltaMode && (1 === e.deltaMode ? (i *= 40, s *= 40) : (i *= 800, s *= 800)), i && !t && (t = i < 1 ? -1 : 1), s && !a && (a = s < 1 ? -1 : 1), {
|
2041
|
-
spinX: t,
|
2042
|
-
spinY: a,
|
2043
|
-
pixelX: i,
|
2044
|
-
pixelY: s
|
2045
|
-
}
|
2046
|
-
},
|
2047
|
-
handleMouseEnter: function () {
|
2048
|
-
this.mouseEntered = !0
|
2049
|
-
},
|
2050
|
-
handleMouseLeave: function () {
|
2051
|
-
this.mouseEntered = !1
|
2052
|
-
},
|
2053
|
-
handle: function (e) {
|
2054
|
-
var t = e,
|
2055
|
-
a = this,
|
2056
|
-
i = a.params.mousewheel;
|
2057
|
-
if (!a.mouseEntered && !i.releaseOnEdges) return !0;
|
2058
|
-
t.originalEvent && (t = t.originalEvent);
|
2059
|
-
var s = 0,
|
2060
|
-
r = a.rtlTranslate ? -1 : 1,
|
2061
|
-
n = B.normalize(t);
|
2062
|
-
if (i.forceToAxis)
|
2063
|
-
if (a.isHorizontal()) {
|
2064
|
-
if (!(Math.abs(n.pixelX) > Math.abs(n.pixelY))) return !0;
|
2065
|
-
s = n.pixelX * r
|
2066
|
-
} else {
|
2067
|
-
if (!(Math.abs(n.pixelY) > Math.abs(n.pixelX))) return !0;
|
2068
|
-
s = n.pixelY
|
2069
|
-
}
|
2070
|
-
else s = Math.abs(n.pixelX) > Math.abs(n.pixelY) ? -n.pixelX * r : -n.pixelY;
|
2071
|
-
if (0 === s) return !0;
|
2072
|
-
if (i.invert && (s = -s), a.params.freeMode) {
|
2073
|
-
a.params.loop && a.loopFix();
|
2074
|
-
var o = a.getTranslate() + s * i.sensitivity,
|
2075
|
-
l = a.isBeginning,
|
2076
|
-
d = a.isEnd;
|
2077
|
-
if (o >= a.minTranslate() && (o = a.minTranslate()), o <= a.maxTranslate() && (o = a.maxTranslate()), a.setTransition(0), a.setTranslate(o), a.updateProgress(), a.updateActiveIndex(), a.updateSlidesClasses(), (!l && a.isBeginning || !d && a.isEnd) && a.updateSlidesClasses(), a.params.freeModeSticky && (clearTimeout(a.mousewheel.timeout), a.mousewheel.timeout = V.nextTick(function () {
|
2078
|
-
a.slideToClosest()
|
2079
|
-
}, 300)), a.emit("scroll", t), a.params.autoplay && a.params.autoplayDisableOnInteraction && a.autoplay.stop(), o === a.minTranslate() || o === a.maxTranslate()) return !0
|
2080
|
-
} else {
|
2081
|
-
if (60 < V.now() - a.mousewheel.lastScrollTime)
|
2082
|
-
if (s < 0)
|
2083
|
-
if (a.isEnd && !a.params.loop || a.animating) {
|
2084
|
-
if (i.releaseOnEdges) return !0
|
2085
|
-
} else a.slideNext(), a.emit("scroll", t);
|
2086
|
-
else if (a.isBeginning && !a.params.loop || a.animating) {
|
2087
|
-
if (i.releaseOnEdges) return !0
|
2088
|
-
} else a.slidePrev(), a.emit("scroll", t);
|
2089
|
-
a.mousewheel.lastScrollTime = (new Y.Date).getTime()
|
2090
|
-
}
|
2091
|
-
return t.preventDefault ? t.preventDefault() : t.returnValue = !1, !1
|
2092
|
-
},
|
2093
|
-
enable: function () {
|
2094
|
-
var e = this;
|
2095
|
-
if (!B.event) return !1;
|
2096
|
-
if (e.mousewheel.enabled) return !1;
|
2097
|
-
var t = e.$el;
|
2098
|
-
return "container" !== e.params.mousewheel.eventsTarged && (t = L(e.params.mousewheel.eventsTarged)), t.on("mouseenter", e.mousewheel.handleMouseEnter), t.on("mouseleave", e.mousewheel.handleMouseLeave), t.on(B.event, e.mousewheel.handle), e.mousewheel.enabled = !0
|
2099
|
-
},
|
2100
|
-
disable: function () {
|
2101
|
-
var e = this;
|
2102
|
-
if (!B.event) return !1;
|
2103
|
-
if (!e.mousewheel.enabled) return !1;
|
2104
|
-
var t = e.$el;
|
2105
|
-
return "container" !== e.params.mousewheel.eventsTarged && (t = L(e.params.mousewheel.eventsTarged)), t.off(B.event, e.mousewheel.handle), !(e.mousewheel.enabled = !1)
|
2106
|
-
}
|
2107
|
-
},
|
2108
|
-
G = {
|
2109
|
-
update: function () {
|
2110
|
-
var e = this,
|
2111
|
-
t = e.params.navigation;
|
2112
|
-
if (!e.params.loop) {
|
2113
|
-
var a = e.navigation,
|
2114
|
-
i = a.$nextEl,
|
2115
|
-
s = a.$prevEl;
|
2116
|
-
s && 0 < s.length && (e.isBeginning ? s.addClass(t.disabledClass) : s.removeClass(t.disabledClass), s[e.params.watchOverflow && e.isLocked ? "addClass" : "removeClass"](t.lockClass)), i && 0 < i.length && (e.isEnd ? i.addClass(t.disabledClass) : i.removeClass(t.disabledClass), i[e.params.watchOverflow && e.isLocked ? "addClass" : "removeClass"](t.lockClass))
|
2117
|
-
}
|
2118
|
-
},
|
2119
|
-
init: function () {
|
2120
|
-
var e, t, a = this,
|
2121
|
-
i = a.params.navigation;
|
2122
|
-
(i.nextEl || i.prevEl) && (i.nextEl && (e = L(i.nextEl), a.params.uniqueNavElements && "string" == typeof i.nextEl && 1 < e.length && 1 === a.$el.find(i.nextEl).length && (e = a.$el.find(i.nextEl))), i.prevEl && (t = L(i.prevEl), a.params.uniqueNavElements && "string" == typeof i.prevEl && 1 < t.length && 1 === a.$el.find(i.prevEl).length && (t = a.$el.find(i.prevEl))), e && 0 < e.length && e.on("click", function (e) {
|
2123
|
-
e.preventDefault(), a.isEnd && !a.params.loop || a.slideNext()
|
2124
|
-
}), t && 0 < t.length && t.on("click", function (e) {
|
2125
|
-
e.preventDefault(), a.isBeginning && !a.params.loop || a.slidePrev()
|
2126
|
-
}), V.extend(a.navigation, {
|
2127
|
-
$nextEl: e,
|
2128
|
-
nextEl: e && e[0],
|
2129
|
-
$prevEl: t,
|
2130
|
-
prevEl: t && t[0]
|
2131
|
-
}))
|
2132
|
-
},
|
2133
|
-
destroy: function () {
|
2134
|
-
var e = this.navigation,
|
2135
|
-
t = e.$nextEl,
|
2136
|
-
a = e.$prevEl;
|
2137
|
-
t && t.length && (t.off("click"), t.removeClass(this.params.navigation.disabledClass)), a && a.length && (a.off("click"), a.removeClass(this.params.navigation.disabledClass))
|
2138
|
-
}
|
2139
|
-
},
|
2140
|
-
N = {
|
2141
|
-
update: function () {
|
2142
|
-
var e = this,
|
2143
|
-
t = e.rtl,
|
2144
|
-
s = e.params.pagination;
|
2145
|
-
if (s.el && e.pagination.el && e.pagination.$el && 0 !== e.pagination.$el.length) {
|
2146
|
-
var r, a = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length,
|
2147
|
-
i = e.pagination.$el,
|
2148
|
-
n = e.params.loop ? Math.ceil((a - 2 * e.loopedSlides) / e.params.slidesPerGroup) : e.snapGrid.length;
|
2149
|
-
if (e.params.loop ? ((r = Math.ceil((e.activeIndex - e.loopedSlides) / e.params.slidesPerGroup)) > a - 1 - 2 * e.loopedSlides && (r -= a - 2 * e.loopedSlides), n - 1 < r && (r -= n), r < 0 && "bullets" !== e.params.paginationType && (r = n + r)) : r = void 0 !== e.snapIndex ? e.snapIndex : e.activeIndex || 0, "bullets" === s.type && e.pagination.bullets && 0 < e.pagination.bullets.length) {
|
2150
|
-
var o, l, d, p = e.pagination.bullets;
|
2151
|
-
if (s.dynamicBullets && (e.pagination.bulletSize = p.eq(0)[e.isHorizontal() ? "outerWidth" : "outerHeight"](!0), i.css(e.isHorizontal() ? "width" : "height", e.pagination.bulletSize * (s.dynamicMainBullets + 4) + "px"), 1 < s.dynamicMainBullets && void 0 !== e.previousIndex && (e.pagination.dynamicBulletIndex += r - e.previousIndex, e.pagination.dynamicBulletIndex > s.dynamicMainBullets - 1 ? e.pagination.dynamicBulletIndex = s.dynamicMainBullets - 1 : e.pagination.dynamicBulletIndex < 0 && (e.pagination.dynamicBulletIndex = 0)), o = r - e.pagination.dynamicBulletIndex, d = ((l = o + (Math.min(p.length, s.dynamicMainBullets) - 1)) + o) / 2), p.removeClass(s.bulletActiveClass + " " + s.bulletActiveClass + "-next " + s.bulletActiveClass + "-next-next " + s.bulletActiveClass + "-prev " + s.bulletActiveClass + "-prev-prev " + s.bulletActiveClass + "-main"), 1 < i.length) p.each(function (e, t) {
|
2152
|
-
var a = L(t),
|
2153
|
-
i = a.index();
|
2154
|
-
i === r && a.addClass(s.bulletActiveClass), s.dynamicBullets && (o <= i && i <= l && a.addClass(s.bulletActiveClass + "-main"), i === o && a.prev().addClass(s.bulletActiveClass + "-prev").prev().addClass(s.bulletActiveClass + "-prev-prev"), i === l && a.next().addClass(s.bulletActiveClass + "-next").next().addClass(s.bulletActiveClass + "-next-next"))
|
2155
|
-
});
|
2156
|
-
else if (p.eq(r).addClass(s.bulletActiveClass), s.dynamicBullets) {
|
2157
|
-
for (var c = p.eq(o), u = p.eq(l), h = o; h <= l; h += 1) p.eq(h).addClass(s.bulletActiveClass + "-main");
|
2158
|
-
c.prev().addClass(s.bulletActiveClass + "-prev").prev().addClass(s.bulletActiveClass + "-prev-prev"), u.next().addClass(s.bulletActiveClass + "-next").next().addClass(s.bulletActiveClass + "-next-next")
|
2159
|
-
}
|
2160
|
-
if (s.dynamicBullets) {
|
2161
|
-
var v = Math.min(p.length, s.dynamicMainBullets + 4),
|
2162
|
-
f = (e.pagination.bulletSize * v - e.pagination.bulletSize) / 2 - d * e.pagination.bulletSize,
|
2163
|
-
m = t ? "right" : "left";
|
2164
|
-
p.css(e.isHorizontal() ? m : "top", f + "px")
|
2165
|
-
}
|
2166
|
-
}
|
2167
|
-
if ("fraction" === s.type && (i.find("." + s.currentClass).text(s.formatFractionCurrent(r + 1)), i.find("." + s.totalClass).text(s.formatFractionTotal(n))), "progressbar" === s.type) {
|
2168
|
-
var g;
|
2169
|
-
g = s.progressbarOpposite ? e.isHorizontal() ? "vertical" : "horizontal" : e.isHorizontal() ? "horizontal" : "vertical";
|
2170
|
-
var b = (r + 1) / n,
|
2171
|
-
w = 1,
|
2172
|
-
y = 1;
|
2173
|
-
"horizontal" === g ? w = b : y = b, i.find("." + s.progressbarFillClass).transform("translate3d(0,0,0) scaleX(" + w + ") scaleY(" + y + ")").transition(e.params.speed)
|
2174
|
-
}
|
2175
|
-
"custom" === s.type && s.renderCustom ? (i.html(s.renderCustom(e, r + 1, n)), e.emit("paginationRender", e, i[0])) : e.emit("paginationUpdate", e, i[0]), i[e.params.watchOverflow && e.isLocked ? "addClass" : "removeClass"](s.lockClass)
|
2176
|
-
}
|
2177
|
-
},
|
2178
|
-
render: function () {
|
2179
|
-
var e = this,
|
2180
|
-
t = e.params.pagination;
|
2181
|
-
if (t.el && e.pagination.el && e.pagination.$el && 0 !== e.pagination.$el.length) {
|
2182
|
-
var a = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length,
|
2183
|
-
i = e.pagination.$el,
|
2184
|
-
s = "";
|
2185
|
-
if ("bullets" === t.type) {
|
2186
|
-
for (var r = e.params.loop ? Math.ceil((a - 2 * e.loopedSlides) / e.params.slidesPerGroup) : e.snapGrid.length, n = 0; n < r; n += 1) t.renderBullet ? s += t.renderBullet.call(e, n, t.bulletClass) : s += "<" + t.bulletElement + ' class="' + t.bulletClass + '"></' + t.bulletElement + ">";
|
2187
|
-
i.html(s), e.pagination.bullets = i.find("." + t.bulletClass)
|
2188
|
-
}
|
2189
|
-
"fraction" === t.type && (s = t.renderFraction ? t.renderFraction.call(e, t.currentClass, t.totalClass) : '<span class="' + t.currentClass + '"></span> / <span class="' + t.totalClass + '"></span>', i.html(s)), "progressbar" === t.type && (s = t.renderProgressbar ? t.renderProgressbar.call(e, t.progressbarFillClass) : '<span class="' + t.progressbarFillClass + '"></span>', i.html(s)), "custom" !== t.type && e.emit("paginationRender", e.pagination.$el[0])
|
2190
|
-
}
|
2191
|
-
},
|
2192
|
-
init: function () {
|
2193
|
-
var a = this,
|
2194
|
-
e = a.params.pagination;
|
2195
|
-
if (e.el) {
|
2196
|
-
var t = L(e.el);
|
2197
|
-
0 !== t.length && (a.params.uniqueNavElements && "string" == typeof e.el && 1 < t.length && 1 === a.$el.find(e.el).length && (t = a.$el.find(e.el)), "bullets" === e.type && e.clickable && t.addClass(e.clickableClass), t.addClass(e.modifierClass + e.type), "bullets" === e.type && e.dynamicBullets && (t.addClass("" + e.modifierClass + e.type + "-dynamic"), a.pagination.dynamicBulletIndex = 0, e.dynamicMainBullets < 1 && (e.dynamicMainBullets = 1)), "progressbar" === e.type && e.progressbarOpposite && t.addClass(e.progressbarOppositeClass), e.clickable && t.on("click", "." + e.bulletClass, function (e) {
|
2198
|
-
e.preventDefault();
|
2199
|
-
var t = L(this).index() * a.params.slidesPerGroup;
|
2200
|
-
a.params.loop && (t += a.loopedSlides), a.slideTo(t)
|
2201
|
-
}), V.extend(a.pagination, {
|
2202
|
-
$el: t,
|
2203
|
-
el: t[0]
|
2204
|
-
}))
|
2205
|
-
}
|
2206
|
-
},
|
2207
|
-
destroy: function () {
|
2208
|
-
var e = this,
|
2209
|
-
t = e.params.pagination;
|
2210
|
-
if (t.el && e.pagination.el && e.pagination.$el && 0 !== e.pagination.$el.length) {
|
2211
|
-
var a = e.pagination.$el;
|
2212
|
-
a.removeClass(t.hiddenClass), a.removeClass(t.modifierClass + t.type), e.pagination.bullets && e.pagination.bullets.removeClass(t.bulletActiveClass), t.clickable && a.off("click", "." + t.bulletClass)
|
2213
|
-
}
|
2214
|
-
}
|
2215
|
-
},
|
2216
|
-
X = {
|
2217
|
-
setTranslate: function () {
|
2218
|
-
var e = this;
|
2219
|
-
if (e.params.scrollbar.el && e.scrollbar.el) {
|
2220
|
-
var t = e.scrollbar,
|
2221
|
-
a = e.rtlTranslate,
|
2222
|
-
i = e.progress,
|
2223
|
-
s = t.dragSize,
|
2224
|
-
r = t.trackSize,
|
2225
|
-
n = t.$dragEl,
|
2226
|
-
o = t.$el,
|
2227
|
-
l = e.params.scrollbar,
|
2228
|
-
d = s,
|
2229
|
-
p = (r - s) * i;
|
2230
|
-
a ? 0 < (p = -p) ? (d = s - p, p = 0) : r < -p + s && (d = r + p) : p < 0 ? (d = s + p, p = 0) : r < p + s && (d = r - p), e.isHorizontal() ? (R.transforms3d ? n.transform("translate3d(" + p + "px, 0, 0)") : n.transform("translateX(" + p + "px)"), n[0].style.width = d + "px") : (R.transforms3d ? n.transform("translate3d(0px, " + p + "px, 0)") : n.transform("translateY(" + p + "px)"), n[0].style.height = d + "px"), l.hide && (clearTimeout(e.scrollbar.timeout), o[0].style.opacity = 1, e.scrollbar.timeout = setTimeout(function () {
|
2231
|
-
o[0].style.opacity = 0, o.transition(400)
|
2232
|
-
}, 1e3))
|
2233
|
-
}
|
2234
|
-
},
|
2235
|
-
setTransition: function (e) {
|
2236
|
-
this.params.scrollbar.el && this.scrollbar.el && this.scrollbar.$dragEl.transition(e)
|
2237
|
-
},
|
2238
|
-
updateSize: function () {
|
2239
|
-
var e = this;
|
2240
|
-
if (e.params.scrollbar.el && e.scrollbar.el) {
|
2241
|
-
var t = e.scrollbar,
|
2242
|
-
a = t.$dragEl,
|
2243
|
-
i = t.$el;
|
2244
|
-
a[0].style.width = "", a[0].style.height = "";
|
2245
|
-
var s, r = e.isHorizontal() ? i[0].offsetWidth : i[0].offsetHeight,
|
2246
|
-
n = e.size / e.virtualSize,
|
2247
|
-
o = n * (r / e.size);
|
2248
|
-
s = "auto" === e.params.scrollbar.dragSize ? r * n : parseInt(e.params.scrollbar.dragSize, 10), e.isHorizontal() ? a[0].style.width = s + "px" : a[0].style.height = s + "px", i[0].style.display = 1 <= n ? "none" : "", e.params.scrollbarHide && (i[0].style.opacity = 0), V.extend(t, {
|
2249
|
-
trackSize: r,
|
2250
|
-
divider: n,
|
2251
|
-
moveDivider: o,
|
2252
|
-
dragSize: s
|
2253
|
-
}), t.$el[e.params.watchOverflow && e.isLocked ? "addClass" : "removeClass"](e.params.scrollbar.lockClass)
|
2254
|
-
}
|
2255
|
-
},
|
2256
|
-
setDragPosition: function (e) {
|
2257
|
-
var t, a = this,
|
2258
|
-
i = a.scrollbar,
|
2259
|
-
s = a.rtlTranslate,
|
2260
|
-
r = i.$el,
|
2261
|
-
n = i.dragSize,
|
2262
|
-
o = i.trackSize;
|
2263
|
-
t = ((a.isHorizontal() ? "touchstart" === e.type || "touchmove" === e.type ? e.targetTouches[0].pageX : e.pageX || e.clientX : "touchstart" === e.type || "touchmove" === e.type ? e.targetTouches[0].pageY : e.pageY || e.clientY) - r.offset()[a.isHorizontal() ? "left" : "top"] - n / 2) / (o - n), t = Math.max(Math.min(t, 1), 0), s && (t = 1 - t);
|
2264
|
-
var l = a.minTranslate() + (a.maxTranslate() - a.minTranslate()) * t;
|
2265
|
-
a.updateProgress(l), a.setTranslate(l), a.updateActiveIndex(), a.updateSlidesClasses()
|
2266
|
-
},
|
2267
|
-
onDragStart: function (e) {
|
2268
|
-
var t = this,
|
2269
|
-
a = t.params.scrollbar,
|
2270
|
-
i = t.scrollbar,
|
2271
|
-
s = t.$wrapperEl,
|
2272
|
-
r = i.$el,
|
2273
|
-
n = i.$dragEl;
|
2274
|
-
t.scrollbar.isTouched = !0, e.preventDefault(), e.stopPropagation(), s.transition(100), n.transition(100), i.setDragPosition(e), clearTimeout(t.scrollbar.dragTimeout), r.transition(0), a.hide && r.css("opacity", 1), t.emit("scrollbarDragStart", e)
|
2275
|
-
},
|
2276
|
-
onDragMove: function (e) {
|
2277
|
-
var t = this.scrollbar,
|
2278
|
-
a = this.$wrapperEl,
|
2279
|
-
i = t.$el,
|
2280
|
-
s = t.$dragEl;
|
2281
|
-
this.scrollbar.isTouched && (e.preventDefault ? e.preventDefault() : e.returnValue = !1, t.setDragPosition(e), a.transition(0), i.transition(0), s.transition(0), this.emit("scrollbarDragMove", e))
|
2282
|
-
},
|
2283
|
-
onDragEnd: function (e) {
|
2284
|
-
var t = this,
|
2285
|
-
a = t.params.scrollbar,
|
2286
|
-
i = t.scrollbar.$el;
|
2287
|
-
t.scrollbar.isTouched && (t.scrollbar.isTouched = !1, a.hide && (clearTimeout(t.scrollbar.dragTimeout), t.scrollbar.dragTimeout = V.nextTick(function () {
|
2288
|
-
i.css("opacity", 0), i.transition(400)
|
2289
|
-
}, 1e3)), t.emit("scrollbarDragEnd", e), a.snapOnRelease && t.slideToClosest())
|
2290
|
-
},
|
2291
|
-
enableDraggable: function () {
|
2292
|
-
var e = this;
|
2293
|
-
if (e.params.scrollbar.el) {
|
2294
|
-
var t = e.scrollbar,
|
2295
|
-
a = e.touchEvents,
|
2296
|
-
i = e.touchEventsDesktop,
|
2297
|
-
s = e.params,
|
2298
|
-
r = t.$el[0],
|
2299
|
-
n = !(!R.passiveListener || !s.passiveListeners) && {
|
2300
|
-
passive: !1,
|
2301
|
-
capture: !1
|
2302
|
-
},
|
2303
|
-
o = !(!R.passiveListener || !s.passiveListeners) && {
|
2304
|
-
passive: !0,
|
2305
|
-
capture: !1
|
2306
|
-
};
|
2307
|
-
R.touch || !R.pointerEvents && !R.prefixedPointerEvents ? (R.touch && (r.addEventListener(a.start, e.scrollbar.onDragStart, n), r.addEventListener(a.move, e.scrollbar.onDragMove, n), r.addEventListener(a.end, e.scrollbar.onDragEnd, o)), (s.simulateTouch && !m.ios && !m.android || s.simulateTouch && !R.touch && m.ios) && (r.addEventListener("mousedown", e.scrollbar.onDragStart, n), f.addEventListener("mousemove", e.scrollbar.onDragMove, n), f.addEventListener("mouseup", e.scrollbar.onDragEnd, o))) : (r.addEventListener(i.start, e.scrollbar.onDragStart, n), f.addEventListener(i.move, e.scrollbar.onDragMove, n), f.addEventListener(i.end, e.scrollbar.onDragEnd, o))
|
2308
|
-
}
|
2309
|
-
},
|
2310
|
-
disableDraggable: function () {
|
2311
|
-
var e = this;
|
2312
|
-
if (e.params.scrollbar.el) {
|
2313
|
-
var t = e.scrollbar,
|
2314
|
-
a = e.touchEvents,
|
2315
|
-
i = e.touchEventsDesktop,
|
2316
|
-
s = e.params,
|
2317
|
-
r = t.$el[0],
|
2318
|
-
n = !(!R.passiveListener || !s.passiveListeners) && {
|
2319
|
-
passive: !1,
|
2320
|
-
capture: !1
|
2321
|
-
},
|
2322
|
-
o = !(!R.passiveListener || !s.passiveListeners) && {
|
2323
|
-
passive: !0,
|
2324
|
-
capture: !1
|
2325
|
-
};
|
2326
|
-
R.touch || !R.pointerEvents && !R.prefixedPointerEvents ? (R.touch && (r.removeEventListener(a.start, e.scrollbar.onDragStart, n), r.removeEventListener(a.move, e.scrollbar.onDragMove, n), r.removeEventListener(a.end, e.scrollbar.onDragEnd, o)), (s.simulateTouch && !m.ios && !m.android || s.simulateTouch && !R.touch && m.ios) && (r.removeEventListener("mousedown", e.scrollbar.onDragStart, n), f.removeEventListener("mousemove", e.scrollbar.onDragMove, n), f.removeEventListener("mouseup", e.scrollbar.onDragEnd, o))) : (r.removeEventListener(i.start, e.scrollbar.onDragStart, n), f.removeEventListener(i.move, e.scrollbar.onDragMove, n), f.removeEventListener(i.end, e.scrollbar.onDragEnd, o))
|
2327
|
-
}
|
2328
|
-
},
|
2329
|
-
init: function () {
|
2330
|
-
var e = this;
|
2331
|
-
if (e.params.scrollbar.el) {
|
2332
|
-
var t = e.scrollbar,
|
2333
|
-
a = e.$el,
|
2334
|
-
i = e.params.scrollbar,
|
2335
|
-
s = L(i.el);
|
2336
|
-
e.params.uniqueNavElements && "string" == typeof i.el && 1 < s.length && 1 === a.find(i.el).length && (s = a.find(i.el));
|
2337
|
-
var r = s.find("." + e.params.scrollbar.dragClass);
|
2338
|
-
0 === r.length && (r = L('<div class="' + e.params.scrollbar.dragClass + '"></div>'), s.append(r)), V.extend(t, {
|
2339
|
-
$el: s,
|
2340
|
-
el: s[0],
|
2341
|
-
$dragEl: r,
|
2342
|
-
dragEl: r[0]
|
2343
|
-
}), i.draggable && t.enableDraggable()
|
2344
|
-
}
|
2345
|
-
},
|
2346
|
-
destroy: function () {
|
2347
|
-
this.scrollbar.disableDraggable()
|
2348
|
-
}
|
2349
|
-
},
|
2350
|
-
F = {
|
2351
|
-
setTransform: function (e, t) {
|
2352
|
-
var a = this.rtl,
|
2353
|
-
i = L(e),
|
2354
|
-
s = a ? -1 : 1,
|
2355
|
-
r = i.attr("data-swiper-parallax") || "0",
|
2356
|
-
n = i.attr("data-swiper-parallax-x"),
|
2357
|
-
o = i.attr("data-swiper-parallax-y"),
|
2358
|
-
l = i.attr("data-swiper-parallax-scale"),
|
2359
|
-
d = i.attr("data-swiper-parallax-opacity");
|
2360
|
-
if (n || o ? (n = n || "0", o = o || "0") : this.isHorizontal() ? (n = r, o = "0") : (o = r, n = "0"), n = 0 <= n.indexOf("%") ? parseInt(n, 10) * t * s + "%" : n * t * s + "px", o = 0 <= o.indexOf("%") ? parseInt(o, 10) * t + "%" : o * t + "px", null != d) {
|
2361
|
-
var p = d - (d - 1) * (1 - Math.abs(t));
|
2362
|
-
i[0].style.opacity = p
|
2363
|
-
}
|
2364
|
-
if (null == l) i.transform("translate3d(" + n + ", " + o + ", 0px)");
|
2365
|
-
else {
|
2366
|
-
var c = l - (l - 1) * (1 - Math.abs(t));
|
2367
|
-
i.transform("translate3d(" + n + ", " + o + ", 0px) scale(" + c + ")")
|
2368
|
-
}
|
2369
|
-
},
|
2370
|
-
setTranslate: function () {
|
2371
|
-
var i = this,
|
2372
|
-
e = i.$el,
|
2373
|
-
t = i.slides,
|
2374
|
-
s = i.progress,
|
2375
|
-
r = i.snapGrid;
|
2376
|
-
e.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function (e, t) {
|
2377
|
-
i.parallax.setTransform(t, s)
|
2378
|
-
}), t.each(function (e, t) {
|
2379
|
-
var a = t.progress;
|
2380
|
-
1 < i.params.slidesPerGroup && "auto" !== i.params.slidesPerView && (a += Math.ceil(e / 2) - s * (r.length - 1)), a = Math.min(Math.max(a, -1), 1), L(t).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function (e, t) {
|
2381
|
-
i.parallax.setTransform(t, a)
|
2382
|
-
})
|
2383
|
-
})
|
2384
|
-
},
|
2385
|
-
setTransition: function (s) {
|
2386
|
-
void 0 === s && (s = this.params.speed);
|
2387
|
-
this.$el.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function (e, t) {
|
2388
|
-
var a = L(t),
|
2389
|
-
i = parseInt(a.attr("data-swiper-parallax-duration"), 10) || s;
|
2390
|
-
0 === s && (i = 0), a.transition(i)
|
2391
|
-
})
|
2392
|
-
}
|
2393
|
-
},
|
2394
|
-
q = {
|
2395
|
-
getDistanceBetweenTouches: function (e) {
|
2396
|
-
if (e.targetTouches.length < 2) return 1;
|
2397
|
-
var t = e.targetTouches[0].pageX,
|
2398
|
-
a = e.targetTouches[0].pageY,
|
2399
|
-
i = e.targetTouches[1].pageX,
|
2400
|
-
s = e.targetTouches[1].pageY;
|
2401
|
-
return Math.sqrt(Math.pow(i - t, 2) + Math.pow(s - a, 2))
|
2402
|
-
},
|
2403
|
-
onGestureStart: function (e) {
|
2404
|
-
var t = this,
|
2405
|
-
a = t.params.zoom,
|
2406
|
-
i = t.zoom,
|
2407
|
-
s = i.gesture;
|
2408
|
-
if (i.fakeGestureTouched = !1, i.fakeGestureMoved = !1, !R.gestures) {
|
2409
|
-
if ("touchstart" !== e.type || "touchstart" === e.type && e.targetTouches.length < 2) return;
|
2410
|
-
i.fakeGestureTouched = !0, s.scaleStart = q.getDistanceBetweenTouches(e)
|
2411
|
-
}
|
2412
|
-
s.$slideEl && s.$slideEl.length || (s.$slideEl = L(e.target).closest(".swiper-slide"), 0 === s.$slideEl.length && (s.$slideEl = t.slides.eq(t.activeIndex)), s.$imageEl = s.$slideEl.find("img, svg, canvas"), s.$imageWrapEl = s.$imageEl.parent("." + a.containerClass), s.maxRatio = s.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio, 0 !== s.$imageWrapEl.length) ? (s.$imageEl.transition(0), t.zoom.isScaling = !0) : s.$imageEl = void 0
|
2413
|
-
},
|
2414
|
-
onGestureChange: function (e) {
|
2415
|
-
var t = this.params.zoom,
|
2416
|
-
a = this.zoom,
|
2417
|
-
i = a.gesture;
|
2418
|
-
if (!R.gestures) {
|
2419
|
-
if ("touchmove" !== e.type || "touchmove" === e.type && e.targetTouches.length < 2) return;
|
2420
|
-
a.fakeGestureMoved = !0, i.scaleMove = q.getDistanceBetweenTouches(e)
|
2421
|
-
}
|
2422
|
-
i.$imageEl && 0 !== i.$imageEl.length && (R.gestures ? this.zoom.scale = e.scale * a.currentScale : a.scale = i.scaleMove / i.scaleStart * a.currentScale, a.scale > i.maxRatio && (a.scale = i.maxRatio - 1 + Math.pow(a.scale - i.maxRatio + 1, .5)), a.scale < t.minRatio && (a.scale = t.minRatio + 1 - Math.pow(t.minRatio - a.scale + 1, .5)), i.$imageEl.transform("translate3d(0,0,0) scale(" + a.scale + ")"))
|
2423
|
-
},
|
2424
|
-
onGestureEnd: function (e) {
|
2425
|
-
var t = this.params.zoom,
|
2426
|
-
a = this.zoom,
|
2427
|
-
i = a.gesture;
|
2428
|
-
if (!R.gestures) {
|
2429
|
-
if (!a.fakeGestureTouched || !a.fakeGestureMoved) return;
|
2430
|
-
if ("touchend" !== e.type || "touchend" === e.type && e.changedTouches.length < 2 && !m.android) return;
|
2431
|
-
a.fakeGestureTouched = !1, a.fakeGestureMoved = !1
|
2432
|
-
}
|
2433
|
-
i.$imageEl && 0 !== i.$imageEl.length && (a.scale = Math.max(Math.min(a.scale, i.maxRatio), t.minRatio), i.$imageEl.transition(this.params.speed).transform("translate3d(0,0,0) scale(" + a.scale + ")"), a.currentScale = a.scale, a.isScaling = !1, 1 === a.scale && (i.$slideEl = void 0))
|
2434
|
-
},
|
2435
|
-
onTouchStart: function (e) {
|
2436
|
-
var t = this.zoom,
|
2437
|
-
a = t.gesture,
|
2438
|
-
i = t.image;
|
2439
|
-
a.$imageEl && 0 !== a.$imageEl.length && (i.isTouched || (m.android && e.preventDefault(), i.isTouched = !0, i.touchesStart.x = "touchstart" === e.type ? e.targetTouches[0].pageX : e.pageX, i.touchesStart.y = "touchstart" === e.type ? e.targetTouches[0].pageY : e.pageY))
|
2440
|
-
},
|
2441
|
-
onTouchMove: function (e) {
|
2442
|
-
var t = this,
|
2443
|
-
a = t.zoom,
|
2444
|
-
i = a.gesture,
|
2445
|
-
s = a.image,
|
2446
|
-
r = a.velocity;
|
2447
|
-
if (i.$imageEl && 0 !== i.$imageEl.length && (t.allowClick = !1, s.isTouched && i.$slideEl)) {
|
2448
|
-
s.isMoved || (s.width = i.$imageEl[0].offsetWidth, s.height = i.$imageEl[0].offsetHeight, s.startX = V.getTranslate(i.$imageWrapEl[0], "x") || 0, s.startY = V.getTranslate(i.$imageWrapEl[0], "y") || 0, i.slideWidth = i.$slideEl[0].offsetWidth, i.slideHeight = i.$slideEl[0].offsetHeight, i.$imageWrapEl.transition(0), t.rtl && (s.startX = -s.startX, s.startY = -s.startY));
|
2449
|
-
var n = s.width * a.scale,
|
2450
|
-
o = s.height * a.scale;
|
2451
|
-
if (!(n < i.slideWidth && o < i.slideHeight)) {
|
2452
|
-
if (s.minX = Math.min(i.slideWidth / 2 - n / 2, 0), s.maxX = -s.minX, s.minY = Math.min(i.slideHeight / 2 - o / 2, 0), s.maxY = -s.minY, s.touchesCurrent.x = "touchmove" === e.type ? e.targetTouches[0].pageX : e.pageX, s.touchesCurrent.y = "touchmove" === e.type ? e.targetTouches[0].pageY : e.pageY, !s.isMoved && !a.isScaling) {
|
2453
|
-
if (t.isHorizontal() && (Math.floor(s.minX) === Math.floor(s.startX) && s.touchesCurrent.x < s.touchesStart.x || Math.floor(s.maxX) === Math.floor(s.startX) && s.touchesCurrent.x > s.touchesStart.x)) return void(s.isTouched = !1);
|
2454
|
-
if (!t.isHorizontal() && (Math.floor(s.minY) === Math.floor(s.startY) && s.touchesCurrent.y < s.touchesStart.y || Math.floor(s.maxY) === Math.floor(s.startY) && s.touchesCurrent.y > s.touchesStart.y)) return void(s.isTouched = !1)
|
2455
|
-
}
|
2456
|
-
e.preventDefault(), e.stopPropagation(), s.isMoved = !0, s.currentX = s.touchesCurrent.x - s.touchesStart.x + s.startX, s.currentY = s.touchesCurrent.y - s.touchesStart.y + s.startY, s.currentX < s.minX && (s.currentX = s.minX + 1 - Math.pow(s.minX - s.currentX + 1, .8)), s.currentX > s.maxX && (s.currentX = s.maxX - 1 + Math.pow(s.currentX - s.maxX + 1, .8)), s.currentY < s.minY && (s.currentY = s.minY + 1 - Math.pow(s.minY - s.currentY + 1, .8)), s.currentY > s.maxY && (s.currentY = s.maxY - 1 + Math.pow(s.currentY - s.maxY + 1, .8)), r.prevPositionX || (r.prevPositionX = s.touchesCurrent.x), r.prevPositionY || (r.prevPositionY = s.touchesCurrent.y), r.prevTime || (r.prevTime = Date.now()), r.x = (s.touchesCurrent.x - r.prevPositionX) / (Date.now() - r.prevTime) / 2, r.y = (s.touchesCurrent.y - r.prevPositionY) / (Date.now() - r.prevTime) / 2, Math.abs(s.touchesCurrent.x - r.prevPositionX) < 2 && (r.x = 0), Math.abs(s.touchesCurrent.y - r.prevPositionY) < 2 && (r.y = 0), r.prevPositionX = s.touchesCurrent.x, r.prevPositionY = s.touchesCurrent.y, r.prevTime = Date.now(), i.$imageWrapEl.transform("translate3d(" + s.currentX + "px, " + s.currentY + "px,0)")
|
2457
|
-
}
|
2458
|
-
}
|
2459
|
-
},
|
2460
|
-
onTouchEnd: function () {
|
2461
|
-
var e = this.zoom,
|
2462
|
-
t = e.gesture,
|
2463
|
-
a = e.image,
|
2464
|
-
i = e.velocity;
|
2465
|
-
if (t.$imageEl && 0 !== t.$imageEl.length) {
|
2466
|
-
if (!a.isTouched || !a.isMoved) return a.isTouched = !1, void(a.isMoved = !1);
|
2467
|
-
a.isTouched = !1, a.isMoved = !1;
|
2468
|
-
var s = 300,
|
2469
|
-
r = 300,
|
2470
|
-
n = i.x * s,
|
2471
|
-
o = a.currentX + n,
|
2472
|
-
l = i.y * r,
|
2473
|
-
d = a.currentY + l;
|
2474
|
-
0 !== i.x && (s = Math.abs((o - a.currentX) / i.x)), 0 !== i.y && (r = Math.abs((d - a.currentY) / i.y));
|
2475
|
-
var p = Math.max(s, r);
|
2476
|
-
a.currentX = o, a.currentY = d;
|
2477
|
-
var c = a.width * e.scale,
|
2478
|
-
u = a.height * e.scale;
|
2479
|
-
a.minX = Math.min(t.slideWidth / 2 - c / 2, 0), a.maxX = -a.minX, a.minY = Math.min(t.slideHeight / 2 - u / 2, 0), a.maxY = -a.minY, a.currentX = Math.max(Math.min(a.currentX, a.maxX), a.minX), a.currentY = Math.max(Math.min(a.currentY, a.maxY), a.minY), t.$imageWrapEl.transition(p).transform("translate3d(" + a.currentX + "px, " + a.currentY + "px,0)")
|
2480
|
-
}
|
2481
|
-
},
|
2482
|
-
onTransitionEnd: function () {
|
2483
|
-
var e = this.zoom,
|
2484
|
-
t = e.gesture;
|
2485
|
-
t.$slideEl && this.previousIndex !== this.activeIndex && (t.$imageEl.transform("translate3d(0,0,0) scale(1)"), t.$imageWrapEl.transform("translate3d(0,0,0)"), t.$slideEl = void 0, t.$imageEl = void 0, t.$imageWrapEl = void 0, e.scale = 1, e.currentScale = 1)
|
2486
|
-
},
|
2487
|
-
toggle: function (e) {
|
2488
|
-
var t = this.zoom;
|
2489
|
-
t.scale && 1 !== t.scale ? t.out() : t.in(e)
|
2490
|
-
},
|
2491
|
-
in: function (e) {
|
2492
|
-
var t, a, i, s, r, n, o, l, d, p, c, u, h, v, f, m, g = this,
|
2493
|
-
b = g.zoom,
|
2494
|
-
w = g.params.zoom,
|
2495
|
-
y = b.gesture,
|
2496
|
-
x = b.image;
|
2497
|
-
(y.$slideEl || (y.$slideEl = g.clickedSlide ? L(g.clickedSlide) : g.slides.eq(g.activeIndex), y.$imageEl = y.$slideEl.find("img, svg, canvas"), y.$imageWrapEl = y.$imageEl.parent("." + w.containerClass)), y.$imageEl && 0 !== y.$imageEl.length) && (y.$slideEl.addClass("" + w.zoomedSlideClass), void 0 === x.touchesStart.x && e ? (t = "touchend" === e.type ? e.changedTouches[0].pageX : e.pageX, a = "touchend" === e.type ? e.changedTouches[0].pageY : e.pageY) : (t = x.touchesStart.x, a = x.touchesStart.y), b.scale = y.$imageWrapEl.attr("data-swiper-zoom") || w.maxRatio, b.currentScale = y.$imageWrapEl.attr("data-swiper-zoom") || w.maxRatio, e ? (f = y.$slideEl[0].offsetWidth, m = y.$slideEl[0].offsetHeight, i = y.$slideEl.offset().left + f / 2 - t, s = y.$slideEl.offset().top + m / 2 - a, o = y.$imageEl[0].offsetWidth, l = y.$imageEl[0].offsetHeight, d = o * b.scale, p = l * b.scale, h = -(c = Math.min(f / 2 - d / 2, 0)), v = -(u = Math.min(m / 2 - p / 2, 0)), (r = i * b.scale) < c && (r = c), h < r && (r = h), (n = s * b.scale) < u && (n = u), v < n && (n = v)) : n = r = 0, y.$imageWrapEl.transition(300).transform("translate3d(" + r + "px, " + n + "px,0)"), y.$imageEl.transition(300).transform("translate3d(0,0,0) scale(" + b.scale + ")"))
|
2498
|
-
},
|
2499
|
-
out: function () {
|
2500
|
-
var e = this,
|
2501
|
-
t = e.zoom,
|
2502
|
-
a = e.params.zoom,
|
2503
|
-
i = t.gesture;
|
2504
|
-
i.$slideEl || (i.$slideEl = e.clickedSlide ? L(e.clickedSlide) : e.slides.eq(e.activeIndex), i.$imageEl = i.$slideEl.find("img, svg, canvas"), i.$imageWrapEl = i.$imageEl.parent("." + a.containerClass)), i.$imageEl && 0 !== i.$imageEl.length && (t.scale = 1, t.currentScale = 1, i.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"), i.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"), i.$slideEl.removeClass("" + a.zoomedSlideClass), i.$slideEl = void 0)
|
2505
|
-
},
|
2506
|
-
enable: function () {
|
2507
|
-
var e = this,
|
2508
|
-
t = e.zoom;
|
2509
|
-
if (!t.enabled) {
|
2510
|
-
t.enabled = !0;
|
2511
|
-
var a = !("touchstart" !== e.touchEvents.start || !R.passiveListener || !e.params.passiveListeners) && {
|
2512
|
-
passive: !0,
|
2513
|
-
capture: !1
|
2514
|
-
};
|
2515
|
-
R.gestures ? (e.$wrapperEl.on("gesturestart", ".swiper-slide", t.onGestureStart, a), e.$wrapperEl.on("gesturechange", ".swiper-slide", t.onGestureChange, a), e.$wrapperEl.on("gestureend", ".swiper-slide", t.onGestureEnd, a)) : "touchstart" === e.touchEvents.start && (e.$wrapperEl.on(e.touchEvents.start, ".swiper-slide", t.onGestureStart, a), e.$wrapperEl.on(e.touchEvents.move, ".swiper-slide", t.onGestureChange, a), e.$wrapperEl.on(e.touchEvents.end, ".swiper-slide", t.onGestureEnd, a)), e.$wrapperEl.on(e.touchEvents.move, "." + e.params.zoom.containerClass, t.onTouchMove)
|
2516
|
-
}
|
2517
|
-
},
|
2518
|
-
disable: function () {
|
2519
|
-
var e = this,
|
2520
|
-
t = e.zoom;
|
2521
|
-
if (t.enabled) {
|
2522
|
-
e.zoom.enabled = !1;
|
2523
|
-
var a = !("touchstart" !== e.touchEvents.start || !R.passiveListener || !e.params.passiveListeners) && {
|
2524
|
-
passive: !0,
|
2525
|
-
capture: !1
|
2526
|
-
};
|
2527
|
-
R.gestures ? (e.$wrapperEl.off("gesturestart", ".swiper-slide", t.onGestureStart, a), e.$wrapperEl.off("gesturechange", ".swiper-slide", t.onGestureChange, a), e.$wrapperEl.off("gestureend", ".swiper-slide", t.onGestureEnd, a)) : "touchstart" === e.touchEvents.start && (e.$wrapperEl.off(e.touchEvents.start, ".swiper-slide", t.onGestureStart, a), e.$wrapperEl.off(e.touchEvents.move, ".swiper-slide", t.onGestureChange, a), e.$wrapperEl.off(e.touchEvents.end, ".swiper-slide", t.onGestureEnd, a)), e.$wrapperEl.off(e.touchEvents.move, "." + e.params.zoom.containerClass, t.onTouchMove)
|
2528
|
-
}
|
2529
|
-
}
|
2530
|
-
},
|
2531
|
-
W = {
|
2532
|
-
loadInSlide: function (e, l) {
|
2533
|
-
void 0 === l && (l = !0);
|
2534
|
-
var d = this,
|
2535
|
-
p = d.params.lazy;
|
2536
|
-
if (void 0 !== e && 0 !== d.slides.length) {
|
2537
|
-
var c = d.virtual && d.params.virtual.enabled ? d.$wrapperEl.children("." + d.params.slideClass + '[data-swiper-slide-index="' + e + '"]') : d.slides.eq(e),
|
2538
|
-
t = c.find("." + p.elementClass + ":not(." + p.loadedClass + "):not(." + p.loadingClass + ")");
|
2539
|
-
!c.hasClass(p.elementClass) || c.hasClass(p.loadedClass) || c.hasClass(p.loadingClass) || (t = t.add(c[0])), 0 !== t.length && t.each(function (e, t) {
|
2540
|
-
var i = L(t);
|
2541
|
-
i.addClass(p.loadingClass);
|
2542
|
-
var s = i.attr("data-background"),
|
2543
|
-
r = i.attr("data-src"),
|
2544
|
-
n = i.attr("data-srcset"),
|
2545
|
-
o = i.attr("data-sizes");
|
2546
|
-
d.loadImage(i[0], r || s, n, o, !1, function () {
|
2547
|
-
if (null != d && d && (!d || d.params) && !d.destroyed) {
|
2548
|
-
if (s ? (i.css("background-image", 'url("' + s + '")'), i.removeAttr("data-background")) : (n && (i.attr("srcset", n), i.removeAttr("data-srcset")), o && (i.attr("sizes", o), i.removeAttr("data-sizes")), r && (i.attr("src", r), i.removeAttr("data-src"))), i.addClass(p.loadedClass).removeClass(p.loadingClass), c.find("." + p.preloaderClass).remove(), d.params.loop && l) {
|
2549
|
-
var e = c.attr("data-swiper-slide-index");
|
2550
|
-
if (c.hasClass(d.params.slideDuplicateClass)) {
|
2551
|
-
var t = d.$wrapperEl.children('[data-swiper-slide-index="' + e + '"]:not(.' + d.params.slideDuplicateClass + ")");
|
2552
|
-
d.lazy.loadInSlide(t.index(), !1)
|
2553
|
-
} else {
|
2554
|
-
var a = d.$wrapperEl.children("." + d.params.slideDuplicateClass + '[data-swiper-slide-index="' + e + '"]');
|
2555
|
-
d.lazy.loadInSlide(a.index(), !1)
|
2556
|
-
}
|
2557
|
-
}
|
2558
|
-
d.emit("lazyImageReady", c[0], i[0])
|
2559
|
-
}
|
2560
|
-
}), d.emit("lazyImageLoad", c[0], i[0])
|
2561
|
-
})
|
2562
|
-
}
|
2563
|
-
},
|
2564
|
-
load: function () {
|
2565
|
-
var i = this,
|
2566
|
-
t = i.$wrapperEl,
|
2567
|
-
a = i.params,
|
2568
|
-
s = i.slides,
|
2569
|
-
e = i.activeIndex,
|
2570
|
-
r = i.virtual && a.virtual.enabled,
|
2571
|
-
n = a.lazy,
|
2572
|
-
o = a.slidesPerView;
|
2573
|
-
|
2574
|
-
function l(e) {
|
2575
|
-
if (r) {
|
2576
|
-
if (t.children("." + a.slideClass + '[data-swiper-slide-index="' + e + '"]').length) return !0
|
2577
|
-
} else if (s[e]) return !0;
|
2578
|
-
return !1
|
2579
|
-
}
|
2580
|
-
|
2581
|
-
function d(e) {
|
2582
|
-
return r ? L(e).attr("data-swiper-slide-index") : L(e).index()
|
2583
|
-
}
|
2584
|
-
if ("auto" === o && (o = 0), i.lazy.initialImageLoaded || (i.lazy.initialImageLoaded = !0), i.params.watchSlidesVisibility) t.children("." + a.slideVisibleClass).each(function (e, t) {
|
2585
|
-
var a = r ? L(t).attr("data-swiper-slide-index") : L(t).index();
|
2586
|
-
i.lazy.loadInSlide(a)
|
2587
|
-
});
|
2588
|
-
else if (1 < o)
|
2589
|
-
for (var p = e; p < e + o; p += 1) l(p) && i.lazy.loadInSlide(p);
|
2590
|
-
else i.lazy.loadInSlide(e);
|
2591
|
-
if (n.loadPrevNext)
|
2592
|
-
if (1 < o || n.loadPrevNextAmount && 1 < n.loadPrevNextAmount) {
|
2593
|
-
for (var c = n.loadPrevNextAmount, u = o, h = Math.min(e + u + Math.max(c, u), s.length), v = Math.max(e - Math.max(u, c), 0), f = e + o; f < h; f += 1) l(f) && i.lazy.loadInSlide(f);
|
2594
|
-
for (var m = v; m < e; m += 1) l(m) && i.lazy.loadInSlide(m)
|
2595
|
-
} else {
|
2596
|
-
var g = t.children("." + a.slideNextClass);
|
2597
|
-
0 < g.length && i.lazy.loadInSlide(d(g));
|
2598
|
-
var b = t.children("." + a.slidePrevClass);
|
2599
|
-
0 < b.length && i.lazy.loadInSlide(d(b))
|
2600
|
-
}
|
2601
|
-
}
|
2602
|
-
},
|
2603
|
-
j = {
|
2604
|
-
LinearSpline: function (e, t) {
|
2605
|
-
var a, i, s, r, n, o = function (e, t) {
|
2606
|
-
for (i = -1, a = e.length; 1 < a - i;) e[s = a + i >> 1] <= t ? i = s : a = s;
|
2607
|
-
return a
|
2608
|
-
};
|
2609
|
-
return this.x = e, this.y = t, this.lastIndex = e.length - 1, this.interpolate = function (e) {
|
2610
|
-
return e ? (n = o(this.x, e), r = n - 1, (e - this.x[r]) * (this.y[n] - this.y[r]) / (this.x[n] - this.x[r]) + this.y[r]) : 0
|
2611
|
-
}, this
|
2612
|
-
},
|
2613
|
-
getInterpolateFunction: function (e) {
|
2614
|
-
var t = this;
|
2615
|
-
t.controller.spline || (t.controller.spline = t.params.loop ? new j.LinearSpline(t.slidesGrid, e.slidesGrid) : new j.LinearSpline(t.snapGrid, e.snapGrid))
|
2616
|
-
},
|
2617
|
-
setTranslate: function (e, t) {
|
2618
|
-
var a, i, s = this,
|
2619
|
-
r = s.controller.control;
|
2620
|
-
|
2621
|
-
function n(e) {
|
2622
|
-
var t = s.rtlTranslate ? -s.translate : s.translate;
|
2623
|
-
"slide" === s.params.controller.by && (s.controller.getInterpolateFunction(e), i = -s.controller.spline.interpolate(-t)), i && "container" !== s.params.controller.by || (a = (e.maxTranslate() - e.minTranslate()) / (s.maxTranslate() - s.minTranslate()), i = (t - s.minTranslate()) * a + e.minTranslate()), s.params.controller.inverse && (i = e.maxTranslate() - i), e.updateProgress(i), e.setTranslate(i, s), e.updateActiveIndex(), e.updateSlidesClasses()
|
2624
|
-
}
|
2625
|
-
if (Array.isArray(r))
|
2626
|
-
for (var o = 0; o < r.length; o += 1) r[o] !== t && r[o] instanceof S && n(r[o]);
|
2627
|
-
else r instanceof S && t !== r && n(r)
|
2628
|
-
},
|
2629
|
-
setTransition: function (t, e) {
|
2630
|
-
var a, i = this,
|
2631
|
-
s = i.controller.control;
|
2632
|
-
|
2633
|
-
function r(e) {
|
2634
|
-
e.setTransition(t, i), 0 !== t && (e.transitionStart(), e.params.autoHeight && V.nextTick(function () {
|
2635
|
-
e.updateAutoHeight()
|
2636
|
-
}), e.$wrapperEl.transitionEnd(function () {
|
2637
|
-
s && (e.params.loop && "slide" === i.params.controller.by && e.loopFix(), e.transitionEnd())
|
2638
|
-
}))
|
2639
|
-
}
|
2640
|
-
if (Array.isArray(s))
|
2641
|
-
for (a = 0; a < s.length; a += 1) s[a] !== e && s[a] instanceof S && r(s[a]);
|
2642
|
-
else s instanceof S && e !== s && r(s)
|
2643
|
-
}
|
2644
|
-
},
|
2645
|
-
U = {
|
2646
|
-
makeElFocusable: function (e) {
|
2647
|
-
return e.attr("tabIndex", "0"), e
|
2648
|
-
},
|
2649
|
-
addElRole: function (e, t) {
|
2650
|
-
return e.attr("role", t), e
|
2651
|
-
},
|
2652
|
-
addElLabel: function (e, t) {
|
2653
|
-
return e.attr("aria-label", t), e
|
2654
|
-
},
|
2655
|
-
disableEl: function (e) {
|
2656
|
-
return e.attr("aria-disabled", !0), e
|
2657
|
-
},
|
2658
|
-
enableEl: function (e) {
|
2659
|
-
return e.attr("aria-disabled", !1), e
|
2660
|
-
},
|
2661
|
-
onEnterKey: function (e) {
|
2662
|
-
var t = this,
|
2663
|
-
a = t.params.a11y;
|
2664
|
-
if (13 === e.keyCode) {
|
2665
|
-
var i = L(e.target);
|
2666
|
-
t.navigation && t.navigation.$nextEl && i.is(t.navigation.$nextEl) && (t.isEnd && !t.params.loop || t.slideNext(), t.isEnd ? t.a11y.notify(a.lastSlideMessage) : t.a11y.notify(a.nextSlideMessage)), t.navigation && t.navigation.$prevEl && i.is(t.navigation.$prevEl) && (t.isBeginning && !t.params.loop || t.slidePrev(), t.isBeginning ? t.a11y.notify(a.firstSlideMessage) : t.a11y.notify(a.prevSlideMessage)), t.pagination && i.is("." + t.params.pagination.bulletClass) && i[0].click()
|
2667
|
-
}
|
2668
|
-
},
|
2669
|
-
notify: function (e) {
|
2670
|
-
var t = this.a11y.liveRegion;
|
2671
|
-
0 !== t.length && (t.html(""), t.html(e))
|
2672
|
-
},
|
2673
|
-
updateNavigation: function () {
|
2674
|
-
var e = this;
|
2675
|
-
if (!e.params.loop) {
|
2676
|
-
var t = e.navigation,
|
2677
|
-
a = t.$nextEl,
|
2678
|
-
i = t.$prevEl;
|
2679
|
-
i && 0 < i.length && (e.isBeginning ? e.a11y.disableEl(i) : e.a11y.enableEl(i)), a && 0 < a.length && (e.isEnd ? e.a11y.disableEl(a) : e.a11y.enableEl(a))
|
2680
|
-
}
|
2681
|
-
},
|
2682
|
-
updatePagination: function () {
|
2683
|
-
var i = this,
|
2684
|
-
s = i.params.a11y;
|
2685
|
-
i.pagination && i.params.pagination.clickable && i.pagination.bullets && i.pagination.bullets.length && i.pagination.bullets.each(function (e, t) {
|
2686
|
-
var a = L(t);
|
2687
|
-
i.a11y.makeElFocusable(a), i.a11y.addElRole(a, "button"), i.a11y.addElLabel(a, s.paginationBulletMessage.replace(/{{index}}/, a.index() + 1))
|
2688
|
-
})
|
2689
|
-
},
|
2690
|
-
init: function () {
|
2691
|
-
var e = this;
|
2692
|
-
e.$el.append(e.a11y.liveRegion);
|
2693
|
-
var t, a, i = e.params.a11y;
|
2694
|
-
e.navigation && e.navigation.$nextEl && (t = e.navigation.$nextEl), e.navigation && e.navigation.$prevEl && (a = e.navigation.$prevEl), t && (e.a11y.makeElFocusable(t), e.a11y.addElRole(t, "button"), e.a11y.addElLabel(t, i.nextSlideMessage), t.on("keydown", e.a11y.onEnterKey)), a && (e.a11y.makeElFocusable(a), e.a11y.addElRole(a, "button"), e.a11y.addElLabel(a, i.prevSlideMessage), a.on("keydown", e.a11y.onEnterKey)), e.pagination && e.params.pagination.clickable && e.pagination.bullets && e.pagination.bullets.length && e.pagination.$el.on("keydown", "." + e.params.pagination.bulletClass, e.a11y.onEnterKey)
|
2695
|
-
},
|
2696
|
-
destroy: function () {
|
2697
|
-
var e, t, a = this;
|
2698
|
-
a.a11y.liveRegion && 0 < a.a11y.liveRegion.length && a.a11y.liveRegion.remove(), a.navigation && a.navigation.$nextEl && (e = a.navigation.$nextEl), a.navigation && a.navigation.$prevEl && (t = a.navigation.$prevEl), e && e.off("keydown", a.a11y.onEnterKey), t && t.off("keydown", a.a11y.onEnterKey), a.pagination && a.params.pagination.clickable && a.pagination.bullets && a.pagination.bullets.length && a.pagination.$el.off("keydown", "." + a.params.pagination.bulletClass, a.a11y.onEnterKey)
|
2699
|
-
}
|
2700
|
-
},
|
2701
|
-
K = {
|
2702
|
-
init: function () {
|
2703
|
-
var e = this;
|
2704
|
-
if (e.params.history) {
|
2705
|
-
if (!Y.history || !Y.history.pushState) return e.params.history.enabled = !1, void(e.params.hashNavigation.enabled = !0);
|
2706
|
-
var t = e.history;
|
2707
|
-
t.initialized = !0, t.paths = K.getPathValues(), (t.paths.key || t.paths.value) && (t.scrollToSlide(0, t.paths.value, e.params.runCallbacksOnInit), e.params.history.replaceState || Y.addEventListener("popstate", e.history.setHistoryPopState))
|
2708
|
-
}
|
2709
|
-
},
|
2710
|
-
destroy: function () {
|
2711
|
-
this.params.history.replaceState || Y.removeEventListener("popstate", this.history.setHistoryPopState)
|
2712
|
-
},
|
2713
|
-
setHistoryPopState: function () {
|
2714
|
-
this.history.paths = K.getPathValues(), this.history.scrollToSlide(this.params.speed, this.history.paths.value, !1)
|
2715
|
-
},
|
2716
|
-
getPathValues: function () {
|
2717
|
-
var e = Y.location.pathname.slice(1).split("/").filter(function (e) {
|
2718
|
-
return "" !== e
|
2719
|
-
}),
|
2720
|
-
t = e.length;
|
2721
|
-
return {
|
2722
|
-
key: e[t - 2],
|
2723
|
-
value: e[t - 1]
|
2724
|
-
}
|
2725
|
-
},
|
2726
|
-
setHistory: function (e, t) {
|
2727
|
-
if (this.history.initialized && this.params.history.enabled) {
|
2728
|
-
var a = this.slides.eq(t),
|
2729
|
-
i = K.slugify(a.attr("data-history"));
|
2730
|
-
Y.location.pathname.includes(e) || (i = e + "/" + i);
|
2731
|
-
var s = Y.history.state;
|
2732
|
-
s && s.value === i || (this.params.history.replaceState ? Y.history.replaceState({
|
2733
|
-
value: i
|
2734
|
-
}, null, i) : Y.history.pushState({
|
2735
|
-
value: i
|
2736
|
-
}, null, i))
|
2737
|
-
}
|
2738
|
-
},
|
2739
|
-
slugify: function (e) {
|
2740
|
-
return e.toString().toLowerCase().replace(/\s+/g, "-").replace(/[^\w-]+/g, "").replace(/--+/g, "-").replace(/^-+/, "").replace(/-+$/, "")
|
2741
|
-
},
|
2742
|
-
scrollToSlide: function (e, t, a) {
|
2743
|
-
var i = this;
|
2744
|
-
if (t)
|
2745
|
-
for (var s = 0, r = i.slides.length; s < r; s += 1) {
|
2746
|
-
var n = i.slides.eq(s);
|
2747
|
-
if (K.slugify(n.attr("data-history")) === t && !n.hasClass(i.params.slideDuplicateClass)) {
|
2748
|
-
var o = n.index();
|
2749
|
-
i.slideTo(o, e, a)
|
2750
|
-
}
|
2751
|
-
} else i.slideTo(0, e, a)
|
2752
|
-
}
|
2753
|
-
},
|
2754
|
-
_ = {
|
2755
|
-
onHashCange: function () {
|
2756
|
-
var e = this,
|
2757
|
-
t = f.location.hash.replace("#", "");
|
2758
|
-
if (t !== e.slides.eq(e.activeIndex).attr("data-hash")) {
|
2759
|
-
var a = e.$wrapperEl.children("." + e.params.slideClass + '[data-hash="' + t + '"]').index();
|
2760
|
-
if (void 0 === a) return;
|
2761
|
-
e.slideTo(a)
|
2762
|
-
}
|
2763
|
-
},
|
2764
|
-
setHash: function () {
|
2765
|
-
var e = this;
|
2766
|
-
if (e.hashNavigation.initialized && e.params.hashNavigation.enabled)
|
2767
|
-
if (e.params.hashNavigation.replaceState && Y.history && Y.history.replaceState) Y.history.replaceState(null, null, "#" + e.slides.eq(e.activeIndex).attr("data-hash") || "");
|
2768
|
-
else {
|
2769
|
-
var t = e.slides.eq(e.activeIndex),
|
2770
|
-
a = t.attr("data-hash") || t.attr("data-history");
|
2771
|
-
f.location.hash = a || ""
|
2772
|
-
}
|
2773
|
-
},
|
2774
|
-
init: function () {
|
2775
|
-
var e = this;
|
2776
|
-
if (!(!e.params.hashNavigation.enabled || e.params.history && e.params.history.enabled)) {
|
2777
|
-
e.hashNavigation.initialized = !0;
|
2778
|
-
var t = f.location.hash.replace("#", "");
|
2779
|
-
if (t)
|
2780
|
-
for (var a = 0, i = e.slides.length; a < i; a += 1) {
|
2781
|
-
var s = e.slides.eq(a);
|
2782
|
-
if ((s.attr("data-hash") || s.attr("data-history")) === t && !s.hasClass(e.params.slideDuplicateClass)) {
|
2783
|
-
var r = s.index();
|
2784
|
-
e.slideTo(r, 0, e.params.runCallbacksOnInit, !0)
|
2785
|
-
}
|
2786
|
-
}
|
2787
|
-
e.params.hashNavigation.watchState && L(Y).on("hashchange", e.hashNavigation.onHashCange)
|
2788
|
-
}
|
2789
|
-
},
|
2790
|
-
destroy: function () {
|
2791
|
-
this.params.hashNavigation.watchState && L(Y).off("hashchange", this.hashNavigation.onHashCange)
|
2792
|
-
}
|
2793
|
-
},
|
2794
|
-
Z = {
|
2795
|
-
run: function () {
|
2796
|
-
var e = this,
|
2797
|
-
t = e.slides.eq(e.activeIndex),
|
2798
|
-
a = e.params.autoplay.delay;
|
2799
|
-
t.attr("data-swiper-autoplay") && (a = t.attr("data-swiper-autoplay") || e.params.autoplay.delay), e.autoplay.timeout = V.nextTick(function () {
|
2800
|
-
e.params.autoplay.reverseDirection ? e.params.loop ? (e.loopFix(), e.slidePrev(e.params.speed, !0, !0), e.emit("autoplay")) : e.isBeginning ? e.params.autoplay.stopOnLastSlide ? e.autoplay.stop() : (e.slideTo(e.slides.length - 1, e.params.speed, !0, !0), e.emit("autoplay")) : (e.slidePrev(e.params.speed, !0, !0), e.emit("autoplay")) : e.params.loop ? (e.loopFix(), e.slideNext(e.params.speed, !0, !0), e.emit("autoplay")) : e.isEnd ? e.params.autoplay.stopOnLastSlide ? e.autoplay.stop() : (e.slideTo(0, e.params.speed, !0, !0), e.emit("autoplay")) : (e.slideNext(e.params.speed, !0, !0), e.emit("autoplay"))
|
2801
|
-
}, a)
|
2802
|
-
},
|
2803
|
-
start: function () {
|
2804
|
-
var e = this;
|
2805
|
-
return void 0 === e.autoplay.timeout && (!e.autoplay.running && (e.autoplay.running = !0, e.emit("autoplayStart"), e.autoplay.run(), !0))
|
2806
|
-
},
|
2807
|
-
stop: function () {
|
2808
|
-
var e = this;
|
2809
|
-
return !!e.autoplay.running && (void 0 !== e.autoplay.timeout && (e.autoplay.timeout && (clearTimeout(e.autoplay.timeout), e.autoplay.timeout = void 0), e.autoplay.running = !1, e.emit("autoplayStop"), !0))
|
2810
|
-
},
|
2811
|
-
pause: function (e) {
|
2812
|
-
var t = this;
|
2813
|
-
t.autoplay.running && (t.autoplay.paused || (t.autoplay.timeout && clearTimeout(t.autoplay.timeout), t.autoplay.paused = !0, 0 !== e && t.params.autoplay.waitForTransition ? (t.$wrapperEl[0].addEventListener("transitionend", t.autoplay.onTransitionEnd), t.$wrapperEl[0].addEventListener("webkitTransitionEnd", t.autoplay.onTransitionEnd)) : (t.autoplay.paused = !1, t.autoplay.run())))
|
2814
|
-
}
|
2815
|
-
},
|
2816
|
-
Q = {
|
2817
|
-
setTranslate: function () {
|
2818
|
-
for (var e = this, t = e.slides, a = 0; a < t.length; a += 1) {
|
2819
|
-
var i = e.slides.eq(a),
|
2820
|
-
s = -i[0].swiperSlideOffset;
|
2821
|
-
e.params.virtualTranslate || (s -= e.translate);
|
2822
|
-
var r = 0;
|
2823
|
-
e.isHorizontal() || (r = s, s = 0);
|
2824
|
-
var n = e.params.fadeEffect.crossFade ? Math.max(1 - Math.abs(i[0].progress), 0) : 1 + Math.min(Math.max(i[0].progress, -1), 0);
|
2825
|
-
i.css({
|
2826
|
-
opacity: n
|
2827
|
-
}).transform("translate3d(" + s + "px, " + r + "px, 0px)")
|
2828
|
-
}
|
2829
|
-
},
|
2830
|
-
setTransition: function (e) {
|
2831
|
-
var a = this,
|
2832
|
-
t = a.slides,
|
2833
|
-
i = a.$wrapperEl;
|
2834
|
-
if (t.transition(e), a.params.virtualTranslate && 0 !== e) {
|
2835
|
-
var s = !1;
|
2836
|
-
t.transitionEnd(function () {
|
2837
|
-
if (!s && a && !a.destroyed) {
|
2838
|
-
s = !0, a.animating = !1;
|
2839
|
-
for (var e = ["webkitTransitionEnd", "transitionend"], t = 0; t < e.length; t += 1) i.trigger(e[t])
|
2840
|
-
}
|
2841
|
-
})
|
2842
|
-
}
|
2843
|
-
}
|
2844
|
-
},
|
2845
|
-
J = {
|
2846
|
-
setTranslate: function () {
|
2847
|
-
var e, t = this,
|
2848
|
-
a = t.$el,
|
2849
|
-
i = t.$wrapperEl,
|
2850
|
-
s = t.slides,
|
2851
|
-
r = t.width,
|
2852
|
-
n = t.height,
|
2853
|
-
o = t.rtlTranslate,
|
2854
|
-
l = t.size,
|
2855
|
-
d = t.params.cubeEffect,
|
2856
|
-
p = t.isHorizontal(),
|
2857
|
-
c = t.virtual && t.params.virtual.enabled,
|
2858
|
-
u = 0;
|
2859
|
-
d.shadow && (p ? (0 === (e = i.find(".swiper-cube-shadow")).length && (e = L('<div class="swiper-cube-shadow"></div>'), i.append(e)), e.css({
|
2860
|
-
height: r + "px"
|
2861
|
-
})) : 0 === (e = a.find(".swiper-cube-shadow")).length && (e = L('<div class="swiper-cube-shadow"></div>'), a.append(e)));
|
2862
|
-
for (var h = 0; h < s.length; h += 1) {
|
2863
|
-
var v = s.eq(h),
|
2864
|
-
f = h;
|
2865
|
-
c && (f = parseInt(v.attr("data-swiper-slide-index"), 10));
|
2866
|
-
var m = 90 * f,
|
2867
|
-
g = Math.floor(m / 360);
|
2868
|
-
o && (m = -m, g = Math.floor(-m / 360));
|
2869
|
-
var b = Math.max(Math.min(v[0].progress, 1), -1),
|
2870
|
-
w = 0,
|
2871
|
-
y = 0,
|
2872
|
-
x = 0;
|
2873
|
-
f % 4 == 0 ? (w = 4 * -g * l, x = 0) : (f - 1) % 4 == 0 ? (w = 0, x = 4 * -g * l) : (f - 2) % 4 == 0 ? (w = l + 4 * g * l, x = l) : (f - 3) % 4 == 0 && (w = -l, x = 3 * l + 4 * l * g), o && (w = -w), p || (y = w, w = 0);
|
2874
|
-
var T = "rotateX(" + (p ? 0 : -m) + "deg) rotateY(" + (p ? m : 0) + "deg) translate3d(" + w + "px, " + y + "px, " + x + "px)";
|
2875
|
-
if (b <= 1 && -1 < b && (u = 90 * f + 90 * b, o && (u = 90 * -f - 90 * b)), v.transform(T), d.slideShadows) {
|
2876
|
-
var E = p ? v.find(".swiper-slide-shadow-left") : v.find(".swiper-slide-shadow-top"),
|
2877
|
-
S = p ? v.find(".swiper-slide-shadow-right") : v.find(".swiper-slide-shadow-bottom");
|
2878
|
-
0 === E.length && (E = L('<div class="swiper-slide-shadow-' + (p ? "left" : "top") + '"></div>'), v.append(E)), 0 === S.length && (S = L('<div class="swiper-slide-shadow-' + (p ? "right" : "bottom") + '"></div>'), v.append(S)), E.length && (E[0].style.opacity = Math.max(-b, 0)), S.length && (S[0].style.opacity = Math.max(b, 0))
|
2879
|
-
}
|
2880
|
-
}
|
2881
|
-
if (i.css({
|
2882
|
-
"-webkit-transform-origin": "50% 50% -" + l / 2 + "px",
|
2883
|
-
"-moz-transform-origin": "50% 50% -" + l / 2 + "px",
|
2884
|
-
"-ms-transform-origin": "50% 50% -" + l / 2 + "px",
|
2885
|
-
"transform-origin": "50% 50% -" + l / 2 + "px"
|
2886
|
-
}), d.shadow)
|
2887
|
-
if (p) e.transform("translate3d(0px, " + (r / 2 + d.shadowOffset) + "px, " + -r / 2 + "px) rotateX(90deg) rotateZ(0deg) scale(" + d.shadowScale + ")");
|
2888
|
-
else {
|
2889
|
-
var C = Math.abs(u) - 90 * Math.floor(Math.abs(u) / 90),
|
2890
|
-
M = 1.5 - (Math.sin(2 * C * Math.PI / 360) / 2 + Math.cos(2 * C * Math.PI / 360) / 2),
|
2891
|
-
k = d.shadowScale,
|
2892
|
-
z = d.shadowScale / M,
|
2893
|
-
P = d.shadowOffset;
|
2894
|
-
e.transform("scale3d(" + k + ", 1, " + z + ") translate3d(0px, " + (n / 2 + P) + "px, " + -n / 2 / z + "px) rotateX(-90deg)")
|
2895
|
-
} var $ = I.isSafari || I.isUiWebView ? -l / 2 : 0;
|
2896
|
-
i.transform("translate3d(0px,0," + $ + "px) rotateX(" + (t.isHorizontal() ? 0 : u) + "deg) rotateY(" + (t.isHorizontal() ? -u : 0) + "deg)")
|
2897
|
-
},
|
2898
|
-
setTransition: function (e) {
|
2899
|
-
var t = this.$el;
|
2900
|
-
this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e), this.params.cubeEffect.shadow && !this.isHorizontal() && t.find(".swiper-cube-shadow").transition(e)
|
2901
|
-
}
|
2902
|
-
},
|
2903
|
-
ee = {
|
2904
|
-
setTranslate: function () {
|
2905
|
-
for (var e = this, t = e.slides, a = e.rtlTranslate, i = 0; i < t.length; i += 1) {
|
2906
|
-
var s = t.eq(i),
|
2907
|
-
r = s[0].progress;
|
2908
|
-
e.params.flipEffect.limitRotation && (r = Math.max(Math.min(s[0].progress, 1), -1));
|
2909
|
-
var n = -180 * r,
|
2910
|
-
o = 0,
|
2911
|
-
l = -s[0].swiperSlideOffset,
|
2912
|
-
d = 0;
|
2913
|
-
if (e.isHorizontal() ? a && (n = -n) : (d = l, o = -n, n = l = 0), s[0].style.zIndex = -Math.abs(Math.round(r)) + t.length, e.params.flipEffect.slideShadows) {
|
2914
|
-
var p = e.isHorizontal() ? s.find(".swiper-slide-shadow-left") : s.find(".swiper-slide-shadow-top"),
|
2915
|
-
c = e.isHorizontal() ? s.find(".swiper-slide-shadow-right") : s.find(".swiper-slide-shadow-bottom");
|
2916
|
-
0 === p.length && (p = L('<div class="swiper-slide-shadow-' + (e.isHorizontal() ? "left" : "top") + '"></div>'), s.append(p)), 0 === c.length && (c = L('<div class="swiper-slide-shadow-' + (e.isHorizontal() ? "right" : "bottom") + '"></div>'), s.append(c)), p.length && (p[0].style.opacity = Math.max(-r, 0)), c.length && (c[0].style.opacity = Math.max(r, 0))
|
2917
|
-
}
|
2918
|
-
s.transform("translate3d(" + l + "px, " + d + "px, 0px) rotateX(" + o + "deg) rotateY(" + n + "deg)")
|
2919
|
-
}
|
2920
|
-
},
|
2921
|
-
setTransition: function (e) {
|
2922
|
-
var a = this,
|
2923
|
-
t = a.slides,
|
2924
|
-
i = a.activeIndex,
|
2925
|
-
s = a.$wrapperEl;
|
2926
|
-
if (t.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e), a.params.virtualTranslate && 0 !== e) {
|
2927
|
-
var r = !1;
|
2928
|
-
t.eq(i).transitionEnd(function () {
|
2929
|
-
if (!r && a && !a.destroyed) {
|
2930
|
-
r = !0, a.animating = !1;
|
2931
|
-
for (var e = ["webkitTransitionEnd", "transitionend"], t = 0; t < e.length; t += 1) s.trigger(e[t])
|
2932
|
-
}
|
2933
|
-
})
|
2934
|
-
}
|
2935
|
-
}
|
2936
|
-
},
|
2937
|
-
te = {
|
2938
|
-
setTranslate: function () {
|
2939
|
-
for (var e = this, t = e.width, a = e.height, i = e.slides, s = e.$wrapperEl, r = e.slidesSizesGrid, n = e.params.coverflowEffect, o = e.isHorizontal(), l = e.translate, d = o ? t / 2 - l : a / 2 - l, p = o ? n.rotate : -n.rotate, c = n.depth, u = 0, h = i.length; u < h; u += 1) {
|
2940
|
-
var v = i.eq(u),
|
2941
|
-
f = r[u],
|
2942
|
-
m = (d - v[0].swiperSlideOffset - f / 2) / f * n.modifier,
|
2943
|
-
g = o ? p * m : 0,
|
2944
|
-
b = o ? 0 : p * m,
|
2945
|
-
w = -c * Math.abs(m),
|
2946
|
-
y = o ? 0 : n.stretch * m,
|
2947
|
-
x = o ? n.stretch * m : 0;
|
2948
|
-
Math.abs(x) < .001 && (x = 0), Math.abs(y) < .001 && (y = 0), Math.abs(w) < .001 && (w = 0), Math.abs(g) < .001 && (g = 0), Math.abs(b) < .001 && (b = 0);
|
2949
|
-
var T = "translate3d(" + x + "px," + y + "px," + w + "px) rotateX(" + b + "deg) rotateY(" + g + "deg)";
|
2950
|
-
if (v.transform(T), v[0].style.zIndex = 1 - Math.abs(Math.round(m)), n.slideShadows) {
|
2951
|
-
var E = o ? v.find(".swiper-slide-shadow-left") : v.find(".swiper-slide-shadow-top"),
|
2952
|
-
S = o ? v.find(".swiper-slide-shadow-right") : v.find(".swiper-slide-shadow-bottom");
|
2953
|
-
0 === E.length && (E = L('<div class="swiper-slide-shadow-' + (o ? "left" : "top") + '"></div>'), v.append(E)), 0 === S.length && (S = L('<div class="swiper-slide-shadow-' + (o ? "right" : "bottom") + '"></div>'), v.append(S)), E.length && (E[0].style.opacity = 0 < m ? m : 0), S.length && (S[0].style.opacity = 0 < -m ? -m : 0)
|
2954
|
-
}
|
2955
|
-
}(R.pointerEvents || R.prefixedPointerEvents) && (s[0].style.perspectiveOrigin = d + "px 50%")
|
2956
|
-
},
|
2957
|
-
setTransition: function (e) {
|
2958
|
-
this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)
|
2959
|
-
}
|
2960
|
-
},
|
2961
|
-
ae = {
|
2962
|
-
init: function () {
|
2963
|
-
var e = this,
|
2964
|
-
t = e.params.thumbs,
|
2965
|
-
a = e.constructor;
|
2966
|
-
t.swiper instanceof a ? (e.thumbs.swiper = t.swiper, V.extend(e.thumbs.swiper.originalParams, {
|
2967
|
-
watchSlidesProgress: !0,
|
2968
|
-
slideToClickedSlide: !1
|
2969
|
-
}), V.extend(e.thumbs.swiper.params, {
|
2970
|
-
watchSlidesProgress: !0,
|
2971
|
-
slideToClickedSlide: !1
|
2972
|
-
})) : V.isObject(t.swiper) && (e.thumbs.swiper = new a(V.extend({}, t.swiper, {
|
2973
|
-
watchSlidesVisibility: !0,
|
2974
|
-
watchSlidesProgress: !0,
|
2975
|
-
slideToClickedSlide: !1
|
2976
|
-
})), e.thumbs.swiperCreated = !0), e.thumbs.swiper.$el.addClass(e.params.thumbs.thumbsContainerClass), e.thumbs.swiper.on("tap", e.thumbs.onThumbClick)
|
2977
|
-
},
|
2978
|
-
onThumbClick: function () {
|
2979
|
-
var e = this,
|
2980
|
-
t = e.thumbs.swiper;
|
2981
|
-
if (t) {
|
2982
|
-
var a = t.clickedIndex;
|
2983
|
-
if (null != a) {
|
2984
|
-
var i;
|
2985
|
-
if (i = t.params.loop ? parseInt(L(t.clickedSlide).attr("data-swiper-slide-index"), 10) : a, e.params.loop) {
|
2986
|
-
var s = e.activeIndex;
|
2987
|
-
e.slides.eq(s).hasClass(e.params.slideDuplicateClass) && (e.loopFix(), e._clientLeft = e.$wrapperEl[0].clientLeft, s = e.activeIndex);
|
2988
|
-
var r = e.slides.eq(s).prevAll('[data-swiper-slide-index="' + i + '"]').eq(0).index(),
|
2989
|
-
n = e.slides.eq(s).nextAll('[data-swiper-slide-index="' + i + '"]').eq(0).index();
|
2990
|
-
i = void 0 === r ? n : void 0 === n ? r : n - s < s - r ? n : r
|
2991
|
-
}
|
2992
|
-
e.slideTo(i)
|
2993
|
-
}
|
2994
|
-
}
|
2995
|
-
},
|
2996
|
-
update: function (e) {
|
2997
|
-
var t = this,
|
2998
|
-
a = t.thumbs.swiper;
|
2999
|
-
if (a) {
|
3000
|
-
var i = "auto" === a.params.slidesPerView ? a.slidesPerViewDynamic() : a.params.slidesPerView;
|
3001
|
-
if (t.realIndex !== a.realIndex) {
|
3002
|
-
var s, r = a.activeIndex;
|
3003
|
-
if (a.params.loop) {
|
3004
|
-
a.slides.eq(r).hasClass(a.params.slideDuplicateClass) && (a.loopFix(), a._clientLeft = a.$wrapperEl[0].clientLeft, r = a.activeIndex);
|
3005
|
-
var n = a.slides.eq(r).prevAll('[data-swiper-slide-index="' + t.realIndex + '"]').eq(0).index(),
|
3006
|
-
o = a.slides.eq(r).nextAll('[data-swiper-slide-index="' + t.realIndex + '"]').eq(0).index();
|
3007
|
-
s = void 0 === n ? o : void 0 === o ? n : o - r < r - n ? o : n
|
3008
|
-
} else s = t.realIndex;
|
3009
|
-
a.visibleSlidesIndexes.indexOf(s) < 0 && (a.params.centeredSlides ? s = r < s ? s - Math.floor(i / 2) + 1 : s + Math.floor(i / 2) - 1 : r < s && (s = s - i + 1), a.slideTo(s, e ? 0 : void 0))
|
3010
|
-
}
|
3011
|
-
var l = 1,
|
3012
|
-
d = t.params.thumbs.slideThumbActiveClass;
|
3013
|
-
if (1 < t.params.slidesPerView && !t.params.centeredSlides && (l = t.params.slidesPerView), a.slides.removeClass(d), a.params.loop)
|
3014
|
-
for (var p = 0; p < l; p += 1) a.$wrapperEl.children('[data-swiper-slide-index="' + (t.realIndex + p) + '"]').addClass(d);
|
3015
|
-
else
|
3016
|
-
for (var c = 0; c < l; c += 1) a.slides.eq(t.realIndex + c).addClass(d)
|
3017
|
-
}
|
3018
|
-
}
|
3019
|
-
},
|
3020
|
-
ie = [C, M, k, z, $, O, H, {
|
3021
|
-
name: "mousewheel",
|
3022
|
-
params: {
|
3023
|
-
mousewheel: {
|
3024
|
-
enabled: !1,
|
3025
|
-
releaseOnEdges: !1,
|
3026
|
-
invert: !1,
|
3027
|
-
forceToAxis: !1,
|
3028
|
-
sensitivity: 1,
|
3029
|
-
eventsTarged: "container"
|
3030
|
-
}
|
3031
|
-
},
|
3032
|
-
create: function () {
|
3033
|
-
var e = this;
|
3034
|
-
V.extend(e, {
|
3035
|
-
mousewheel: {
|
3036
|
-
enabled: !1,
|
3037
|
-
enable: B.enable.bind(e),
|
3038
|
-
disable: B.disable.bind(e),
|
3039
|
-
handle: B.handle.bind(e),
|
3040
|
-
handleMouseEnter: B.handleMouseEnter.bind(e),
|
3041
|
-
handleMouseLeave: B.handleMouseLeave.bind(e),
|
3042
|
-
lastScrollTime: V.now()
|
3043
|
-
}
|
3044
|
-
})
|
3045
|
-
},
|
3046
|
-
on: {
|
3047
|
-
init: function () {
|
3048
|
-
this.params.mousewheel.enabled && this.mousewheel.enable()
|
3049
|
-
},
|
3050
|
-
destroy: function () {
|
3051
|
-
this.mousewheel.enabled && this.mousewheel.disable()
|
3052
|
-
}
|
3053
|
-
}
|
3054
|
-
}, {
|
3055
|
-
name: "navigation",
|
3056
|
-
params: {
|
3057
|
-
navigation: {
|
3058
|
-
nextEl: null,
|
3059
|
-
prevEl: null,
|
3060
|
-
hideOnClick: !1,
|
3061
|
-
disabledClass: "swiper-button-disabled",
|
3062
|
-
hiddenClass: "swiper-button-hidden",
|
3063
|
-
lockClass: "swiper-button-lock"
|
3064
|
-
}
|
3065
|
-
},
|
3066
|
-
create: function () {
|
3067
|
-
V.extend(this, {
|
3068
|
-
navigation: {
|
3069
|
-
init: G.init.bind(this),
|
3070
|
-
update: G.update.bind(this),
|
3071
|
-
destroy: G.destroy.bind(this)
|
3072
|
-
}
|
3073
|
-
})
|
3074
|
-
},
|
3075
|
-
on: {
|
3076
|
-
init: function () {
|
3077
|
-
this.navigation.init(), this.navigation.update()
|
3078
|
-
},
|
3079
|
-
toEdge: function () {
|
3080
|
-
this.navigation.update()
|
3081
|
-
},
|
3082
|
-
fromEdge: function () {
|
3083
|
-
this.navigation.update()
|
3084
|
-
},
|
3085
|
-
destroy: function () {
|
3086
|
-
this.navigation.destroy()
|
3087
|
-
},
|
3088
|
-
click: function (e) {
|
3089
|
-
var t = this.navigation,
|
3090
|
-
a = t.$nextEl,
|
3091
|
-
i = t.$prevEl;
|
3092
|
-
!this.params.navigation.hideOnClick || L(e.target).is(i) || L(e.target).is(a) || (a && a.toggleClass(this.params.navigation.hiddenClass), i && i.toggleClass(this.params.navigation.hiddenClass))
|
3093
|
-
}
|
3094
|
-
}
|
3095
|
-
}, {
|
3096
|
-
name: "pagination",
|
3097
|
-
params: {
|
3098
|
-
pagination: {
|
3099
|
-
el: null,
|
3100
|
-
bulletElement: "span",
|
3101
|
-
clickable: !1,
|
3102
|
-
hideOnClick: !1,
|
3103
|
-
renderBullet: null,
|
3104
|
-
renderProgressbar: null,
|
3105
|
-
renderFraction: null,
|
3106
|
-
renderCustom: null,
|
3107
|
-
progressbarOpposite: !1,
|
3108
|
-
type: "bullets",
|
3109
|
-
dynamicBullets: !1,
|
3110
|
-
dynamicMainBullets: 1,
|
3111
|
-
formatFractionCurrent: function (e) {
|
3112
|
-
return e
|
3113
|
-
},
|
3114
|
-
formatFractionTotal: function (e) {
|
3115
|
-
return e
|
3116
|
-
},
|
3117
|
-
bulletClass: "swiper-pagination-bullet",
|
3118
|
-
bulletActiveClass: "swiper-pagination-bullet-active",
|
3119
|
-
modifierClass: "swiper-pagination-",
|
3120
|
-
currentClass: "swiper-pagination-current",
|
3121
|
-
totalClass: "swiper-pagination-total",
|
3122
|
-
hiddenClass: "swiper-pagination-hidden",
|
3123
|
-
progressbarFillClass: "swiper-pagination-progressbar-fill",
|
3124
|
-
progressbarOppositeClass: "swiper-pagination-progressbar-opposite",
|
3125
|
-
clickableClass: "swiper-pagination-clickable",
|
3126
|
-
lockClass: "swiper-pagination-lock"
|
3127
|
-
}
|
3128
|
-
},
|
3129
|
-
create: function () {
|
3130
|
-
var e = this;
|
3131
|
-
V.extend(e, {
|
3132
|
-
pagination: {
|
3133
|
-
init: N.init.bind(e),
|
3134
|
-
render: N.render.bind(e),
|
3135
|
-
update: N.update.bind(e),
|
3136
|
-
destroy: N.destroy.bind(e),
|
3137
|
-
dynamicBulletIndex: 0
|
3138
|
-
}
|
3139
|
-
})
|
3140
|
-
},
|
3141
|
-
on: {
|
3142
|
-
init: function () {
|
3143
|
-
this.pagination.init(), this.pagination.render(), this.pagination.update()
|
3144
|
-
},
|
3145
|
-
activeIndexChange: function () {
|
3146
|
-
this.params.loop ? this.pagination.update() : void 0 === this.snapIndex && this.pagination.update()
|
3147
|
-
},
|
3148
|
-
snapIndexChange: function () {
|
3149
|
-
this.params.loop || this.pagination.update()
|
3150
|
-
},
|
3151
|
-
slidesLengthChange: function () {
|
3152
|
-
this.params.loop && (this.pagination.render(), this.pagination.update())
|
3153
|
-
},
|
3154
|
-
snapGridLengthChange: function () {
|
3155
|
-
this.params.loop || (this.pagination.render(), this.pagination.update())
|
3156
|
-
},
|
3157
|
-
destroy: function () {
|
3158
|
-
this.pagination.destroy()
|
3159
|
-
},
|
3160
|
-
click: function (e) {
|
3161
|
-
var t = this;
|
3162
|
-
t.params.pagination.el && t.params.pagination.hideOnClick && 0 < t.pagination.$el.length && !L(e.target).hasClass(t.params.pagination.bulletClass) && t.pagination.$el.toggleClass(t.params.pagination.hiddenClass)
|
3163
|
-
}
|
3164
|
-
}
|
3165
|
-
}, {
|
3166
|
-
name: "scrollbar",
|
3167
|
-
params: {
|
3168
|
-
scrollbar: {
|
3169
|
-
el: null,
|
3170
|
-
dragSize: "auto",
|
3171
|
-
hide: !1,
|
3172
|
-
draggable: !1,
|
3173
|
-
snapOnRelease: !0,
|
3174
|
-
lockClass: "swiper-scrollbar-lock",
|
3175
|
-
dragClass: "swiper-scrollbar-drag"
|
3176
|
-
}
|
3177
|
-
},
|
3178
|
-
create: function () {
|
3179
|
-
var e = this;
|
3180
|
-
V.extend(e, {
|
3181
|
-
scrollbar: {
|
3182
|
-
init: X.init.bind(e),
|
3183
|
-
destroy: X.destroy.bind(e),
|
3184
|
-
updateSize: X.updateSize.bind(e),
|
3185
|
-
setTranslate: X.setTranslate.bind(e),
|
3186
|
-
setTransition: X.setTransition.bind(e),
|
3187
|
-
enableDraggable: X.enableDraggable.bind(e),
|
3188
|
-
disableDraggable: X.disableDraggable.bind(e),
|
3189
|
-
setDragPosition: X.setDragPosition.bind(e),
|
3190
|
-
onDragStart: X.onDragStart.bind(e),
|
3191
|
-
onDragMove: X.onDragMove.bind(e),
|
3192
|
-
onDragEnd: X.onDragEnd.bind(e),
|
3193
|
-
isTouched: !1,
|
3194
|
-
timeout: null,
|
3195
|
-
dragTimeout: null
|
3196
|
-
}
|
3197
|
-
})
|
3198
|
-
},
|
3199
|
-
on: {
|
3200
|
-
init: function () {
|
3201
|
-
this.scrollbar.init(), this.scrollbar.updateSize(), this.scrollbar.setTranslate()
|
3202
|
-
},
|
3203
|
-
update: function () {
|
3204
|
-
this.scrollbar.updateSize()
|
3205
|
-
},
|
3206
|
-
resize: function () {
|
3207
|
-
this.scrollbar.updateSize()
|
3208
|
-
},
|
3209
|
-
observerUpdate: function () {
|
3210
|
-
this.scrollbar.updateSize()
|
3211
|
-
},
|
3212
|
-
setTranslate: function () {
|
3213
|
-
this.scrollbar.setTranslate()
|
3214
|
-
},
|
3215
|
-
setTransition: function (e) {
|
3216
|
-
this.scrollbar.setTransition(e)
|
3217
|
-
},
|
3218
|
-
destroy: function () {
|
3219
|
-
this.scrollbar.destroy()
|
3220
|
-
}
|
3221
|
-
}
|
3222
|
-
}, {
|
3223
|
-
name: "parallax",
|
3224
|
-
params: {
|
3225
|
-
parallax: {
|
3226
|
-
enabled: !1
|
3227
|
-
}
|
3228
|
-
},
|
3229
|
-
create: function () {
|
3230
|
-
V.extend(this, {
|
3231
|
-
parallax: {
|
3232
|
-
setTransform: F.setTransform.bind(this),
|
3233
|
-
setTranslate: F.setTranslate.bind(this),
|
3234
|
-
setTransition: F.setTransition.bind(this)
|
3235
|
-
}
|
3236
|
-
})
|
3237
|
-
},
|
3238
|
-
on: {
|
3239
|
-
beforeInit: function () {
|
3240
|
-
this.params.parallax.enabled && (this.params.watchSlidesProgress = !0, this.originalParams.watchSlidesProgress = !0)
|
3241
|
-
},
|
3242
|
-
init: function () {
|
3243
|
-
this.params.parallax && this.parallax.setTranslate()
|
3244
|
-
},
|
3245
|
-
setTranslate: function () {
|
3246
|
-
this.params.parallax && this.parallax.setTranslate()
|
3247
|
-
},
|
3248
|
-
setTransition: function (e) {
|
3249
|
-
this.params.parallax && this.parallax.setTransition(e)
|
3250
|
-
}
|
3251
|
-
}
|
3252
|
-
}, {
|
3253
|
-
name: "zoom",
|
3254
|
-
params: {
|
3255
|
-
zoom: {
|
3256
|
-
enabled: !1,
|
3257
|
-
maxRatio: 3,
|
3258
|
-
minRatio: 1,
|
3259
|
-
toggle: !0,
|
3260
|
-
containerClass: "swiper-zoom-container",
|
3261
|
-
zoomedSlideClass: "swiper-slide-zoomed"
|
3262
|
-
}
|
3263
|
-
},
|
3264
|
-
create: function () {
|
3265
|
-
var t = this,
|
3266
|
-
a = {
|
3267
|
-
enabled: !1,
|
3268
|
-
scale: 1,
|
3269
|
-
currentScale: 1,
|
3270
|
-
isScaling: !1,
|
3271
|
-
gesture: {
|
3272
|
-
$slideEl: void 0,
|
3273
|
-
slideWidth: void 0,
|
3274
|
-
slideHeight: void 0,
|
3275
|
-
$imageEl: void 0,
|
3276
|
-
$imageWrapEl: void 0,
|
3277
|
-
maxRatio: 3
|
3278
|
-
},
|
3279
|
-
image: {
|
3280
|
-
isTouched: void 0,
|
3281
|
-
isMoved: void 0,
|
3282
|
-
currentX: void 0,
|
3283
|
-
currentY: void 0,
|
3284
|
-
minX: void 0,
|
3285
|
-
minY: void 0,
|
3286
|
-
maxX: void 0,
|
3287
|
-
maxY: void 0,
|
3288
|
-
width: void 0,
|
3289
|
-
height: void 0,
|
3290
|
-
startX: void 0,
|
3291
|
-
startY: void 0,
|
3292
|
-
touchesStart: {},
|
3293
|
-
touchesCurrent: {}
|
3294
|
-
},
|
3295
|
-
velocity: {
|
3296
|
-
x: void 0,
|
3297
|
-
y: void 0,
|
3298
|
-
prevPositionX: void 0,
|
3299
|
-
prevPositionY: void 0,
|
3300
|
-
prevTime: void 0
|
3301
|
-
}
|
3302
|
-
};
|
3303
|
-
"onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out".split(" ").forEach(function (e) {
|
3304
|
-
a[e] = q[e].bind(t)
|
3305
|
-
}), V.extend(t, {
|
3306
|
-
zoom: a
|
3307
|
-
})
|
3308
|
-
},
|
3309
|
-
on: {
|
3310
|
-
init: function () {
|
3311
|
-
this.params.zoom.enabled && this.zoom.enable()
|
3312
|
-
},
|
3313
|
-
destroy: function () {
|
3314
|
-
this.zoom.disable()
|
3315
|
-
},
|
3316
|
-
touchStart: function (e) {
|
3317
|
-
this.zoom.enabled && this.zoom.onTouchStart(e)
|
3318
|
-
},
|
3319
|
-
touchEnd: function (e) {
|
3320
|
-
this.zoom.enabled && this.zoom.onTouchEnd(e)
|
3321
|
-
},
|
3322
|
-
doubleTap: function (e) {
|
3323
|
-
this.params.zoom.enabled && this.zoom.enabled && this.params.zoom.toggle && this.zoom.toggle(e)
|
3324
|
-
},
|
3325
|
-
transitionEnd: function () {
|
3326
|
-
this.zoom.enabled && this.params.zoom.enabled && this.zoom.onTransitionEnd()
|
3327
|
-
}
|
3328
|
-
}
|
3329
|
-
}, {
|
3330
|
-
name: "lazy",
|
3331
|
-
params: {
|
3332
|
-
lazy: {
|
3333
|
-
enabled: !1,
|
3334
|
-
loadPrevNext: !1,
|
3335
|
-
loadPrevNextAmount: 1,
|
3336
|
-
loadOnTransitionStart: !1,
|
3337
|
-
elementClass: "swiper-lazy",
|
3338
|
-
loadingClass: "swiper-lazy-loading",
|
3339
|
-
loadedClass: "swiper-lazy-loaded",
|
3340
|
-
preloaderClass: "swiper-lazy-preloader"
|
3341
|
-
}
|
3342
|
-
},
|
3343
|
-
create: function () {
|
3344
|
-
V.extend(this, {
|
3345
|
-
lazy: {
|
3346
|
-
initialImageLoaded: !1,
|
3347
|
-
load: W.load.bind(this),
|
3348
|
-
loadInSlide: W.loadInSlide.bind(this)
|
3349
|
-
}
|
3350
|
-
})
|
3351
|
-
},
|
3352
|
-
on: {
|
3353
|
-
beforeInit: function () {
|
3354
|
-
this.params.lazy.enabled && this.params.preloadImages && (this.params.preloadImages = !1)
|
3355
|
-
},
|
3356
|
-
init: function () {
|
3357
|
-
this.params.lazy.enabled && !this.params.loop && 0 === this.params.initialSlide && this.lazy.load()
|
3358
|
-
},
|
3359
|
-
scroll: function () {
|
3360
|
-
this.params.freeMode && !this.params.freeModeSticky && this.lazy.load()
|
3361
|
-
},
|
3362
|
-
resize: function () {
|
3363
|
-
this.params.lazy.enabled && this.lazy.load()
|
3364
|
-
},
|
3365
|
-
scrollbarDragMove: function () {
|
3366
|
-
this.params.lazy.enabled && this.lazy.load()
|
3367
|
-
},
|
3368
|
-
transitionStart: function () {
|
3369
|
-
var e = this;
|
3370
|
-
e.params.lazy.enabled && (e.params.lazy.loadOnTransitionStart || !e.params.lazy.loadOnTransitionStart && !e.lazy.initialImageLoaded) && e.lazy.load()
|
3371
|
-
},
|
3372
|
-
transitionEnd: function () {
|
3373
|
-
this.params.lazy.enabled && !this.params.lazy.loadOnTransitionStart && this.lazy.load()
|
3374
|
-
}
|
3375
|
-
}
|
3376
|
-
}, {
|
3377
|
-
name: "controller",
|
3378
|
-
params: {
|
3379
|
-
controller: {
|
3380
|
-
control: void 0,
|
3381
|
-
inverse: !1,
|
3382
|
-
by: "slide"
|
3383
|
-
}
|
3384
|
-
},
|
3385
|
-
create: function () {
|
3386
|
-
var e = this;
|
3387
|
-
V.extend(e, {
|
3388
|
-
controller: {
|
3389
|
-
control: e.params.controller.control,
|
3390
|
-
getInterpolateFunction: j.getInterpolateFunction.bind(e),
|
3391
|
-
setTranslate: j.setTranslate.bind(e),
|
3392
|
-
setTransition: j.setTransition.bind(e)
|
3393
|
-
}
|
3394
|
-
})
|
3395
|
-
},
|
3396
|
-
on: {
|
3397
|
-
update: function () {
|
3398
|
-
this.controller.control && this.controller.spline && (this.controller.spline = void 0, delete this.controller.spline)
|
3399
|
-
},
|
3400
|
-
resize: function () {
|
3401
|
-
this.controller.control && this.controller.spline && (this.controller.spline = void 0, delete this.controller.spline)
|
3402
|
-
},
|
3403
|
-
observerUpdate: function () {
|
3404
|
-
this.controller.control && this.controller.spline && (this.controller.spline = void 0, delete this.controller.spline)
|
3405
|
-
},
|
3406
|
-
setTranslate: function (e, t) {
|
3407
|
-
this.controller.control && this.controller.setTranslate(e, t)
|
3408
|
-
},
|
3409
|
-
setTransition: function (e, t) {
|
3410
|
-
this.controller.control && this.controller.setTransition(e, t)
|
3411
|
-
}
|
3412
|
-
}
|
3413
|
-
}, {
|
3414
|
-
name: "a11y",
|
3415
|
-
params: {
|
3416
|
-
a11y: {
|
3417
|
-
enabled: !0,
|
3418
|
-
notificationClass: "swiper-notification",
|
3419
|
-
prevSlideMessage: "Previous slide",
|
3420
|
-
nextSlideMessage: "Next slide",
|
3421
|
-
firstSlideMessage: "This is the first slide",
|
3422
|
-
lastSlideMessage: "This is the last slide",
|
3423
|
-
paginationBulletMessage: "Go to slide {{index}}"
|
3424
|
-
}
|
3425
|
-
},
|
3426
|
-
create: function () {
|
3427
|
-
var t = this;
|
3428
|
-
V.extend(t, {
|
3429
|
-
a11y: {
|
3430
|
-
liveRegion: L('<span class="' + t.params.a11y.notificationClass + '" aria-live="assertive" aria-atomic="true"></span>')
|
3431
|
-
}
|
3432
|
-
}), Object.keys(U).forEach(function (e) {
|
3433
|
-
t.a11y[e] = U[e].bind(t)
|
3434
|
-
})
|
3435
|
-
},
|
3436
|
-
on: {
|
3437
|
-
init: function () {
|
3438
|
-
this.params.a11y.enabled && (this.a11y.init(), this.a11y.updateNavigation())
|
3439
|
-
},
|
3440
|
-
toEdge: function () {
|
3441
|
-
this.params.a11y.enabled && this.a11y.updateNavigation()
|
3442
|
-
},
|
3443
|
-
fromEdge: function () {
|
3444
|
-
this.params.a11y.enabled && this.a11y.updateNavigation()
|
3445
|
-
},
|
3446
|
-
paginationUpdate: function () {
|
3447
|
-
this.params.a11y.enabled && this.a11y.updatePagination()
|
3448
|
-
},
|
3449
|
-
destroy: function () {
|
3450
|
-
this.params.a11y.enabled && this.a11y.destroy()
|
3451
|
-
}
|
3452
|
-
}
|
3453
|
-
}, {
|
3454
|
-
name: "history",
|
3455
|
-
params: {
|
3456
|
-
history: {
|
3457
|
-
enabled: !1,
|
3458
|
-
replaceState: !1,
|
3459
|
-
key: "slides"
|
3460
|
-
}
|
3461
|
-
},
|
3462
|
-
create: function () {
|
3463
|
-
var e = this;
|
3464
|
-
V.extend(e, {
|
3465
|
-
history: {
|
3466
|
-
init: K.init.bind(e),
|
3467
|
-
setHistory: K.setHistory.bind(e),
|
3468
|
-
setHistoryPopState: K.setHistoryPopState.bind(e),
|
3469
|
-
scrollToSlide: K.scrollToSlide.bind(e),
|
3470
|
-
destroy: K.destroy.bind(e)
|
3471
|
-
}
|
3472
|
-
})
|
3473
|
-
},
|
3474
|
-
on: {
|
3475
|
-
init: function () {
|
3476
|
-
this.params.history.enabled && this.history.init()
|
3477
|
-
},
|
3478
|
-
destroy: function () {
|
3479
|
-
this.params.history.enabled && this.history.destroy()
|
3480
|
-
},
|
3481
|
-
transitionEnd: function () {
|
3482
|
-
this.history.initialized && this.history.setHistory(this.params.history.key, this.activeIndex)
|
3483
|
-
}
|
3484
|
-
}
|
3485
|
-
}, {
|
3486
|
-
name: "hash-navigation",
|
3487
|
-
params: {
|
3488
|
-
hashNavigation: {
|
3489
|
-
enabled: !1,
|
3490
|
-
replaceState: !1,
|
3491
|
-
watchState: !1
|
3492
|
-
}
|
3493
|
-
},
|
3494
|
-
create: function () {
|
3495
|
-
var e = this;
|
3496
|
-
V.extend(e, {
|
3497
|
-
hashNavigation: {
|
3498
|
-
initialized: !1,
|
3499
|
-
init: _.init.bind(e),
|
3500
|
-
destroy: _.destroy.bind(e),
|
3501
|
-
setHash: _.setHash.bind(e),
|
3502
|
-
onHashCange: _.onHashCange.bind(e)
|
3503
|
-
}
|
3504
|
-
})
|
3505
|
-
},
|
3506
|
-
on: {
|
3507
|
-
init: function () {
|
3508
|
-
this.params.hashNavigation.enabled && this.hashNavigation.init()
|
3509
|
-
},
|
3510
|
-
destroy: function () {
|
3511
|
-
this.params.hashNavigation.enabled && this.hashNavigation.destroy()
|
3512
|
-
},
|
3513
|
-
transitionEnd: function () {
|
3514
|
-
this.hashNavigation.initialized && this.hashNavigation.setHash()
|
3515
|
-
}
|
3516
|
-
}
|
3517
|
-
}, {
|
3518
|
-
name: "autoplay",
|
3519
|
-
params: {
|
3520
|
-
autoplay: {
|
3521
|
-
enabled: !1,
|
3522
|
-
delay: 3e3,
|
3523
|
-
waitForTransition: !0,
|
3524
|
-
disableOnInteraction: !0,
|
3525
|
-
stopOnLastSlide: !1,
|
3526
|
-
reverseDirection: !1
|
3527
|
-
}
|
3528
|
-
},
|
3529
|
-
create: function () {
|
3530
|
-
var t = this;
|
3531
|
-
V.extend(t, {
|
3532
|
-
autoplay: {
|
3533
|
-
running: !1,
|
3534
|
-
paused: !1,
|
3535
|
-
run: Z.run.bind(t),
|
3536
|
-
start: Z.start.bind(t),
|
3537
|
-
stop: Z.stop.bind(t),
|
3538
|
-
pause: Z.pause.bind(t),
|
3539
|
-
onTransitionEnd: function (e) {
|
3540
|
-
t && !t.destroyed && t.$wrapperEl && e.target === this && (t.$wrapperEl[0].removeEventListener("transitionend", t.autoplay.onTransitionEnd), t.$wrapperEl[0].removeEventListener("webkitTransitionEnd", t.autoplay.onTransitionEnd), t.autoplay.paused = !1, t.autoplay.running ? t.autoplay.run() : t.autoplay.stop())
|
3541
|
-
}
|
3542
|
-
}
|
3543
|
-
})
|
3544
|
-
},
|
3545
|
-
on: {
|
3546
|
-
init: function () {
|
3547
|
-
this.params.autoplay.enabled && this.autoplay.start()
|
3548
|
-
},
|
3549
|
-
beforeTransitionStart: function (e, t) {
|
3550
|
-
this.autoplay.running && (t || !this.params.autoplay.disableOnInteraction ? this.autoplay.pause(e) : this.autoplay.stop())
|
3551
|
-
},
|
3552
|
-
sliderFirstMove: function () {
|
3553
|
-
this.autoplay.running && (this.params.autoplay.disableOnInteraction ? this.autoplay.stop() : this.autoplay.pause())
|
3554
|
-
},
|
3555
|
-
destroy: function () {
|
3556
|
-
this.autoplay.running && this.autoplay.stop()
|
3557
|
-
}
|
3558
|
-
}
|
3559
|
-
}, {
|
3560
|
-
name: "effect-fade",
|
3561
|
-
params: {
|
3562
|
-
fadeEffect: {
|
3563
|
-
crossFade: !1
|
3564
|
-
}
|
3565
|
-
},
|
3566
|
-
create: function () {
|
3567
|
-
V.extend(this, {
|
3568
|
-
fadeEffect: {
|
3569
|
-
setTranslate: Q.setTranslate.bind(this),
|
3570
|
-
setTransition: Q.setTransition.bind(this)
|
3571
|
-
}
|
3572
|
-
})
|
3573
|
-
},
|
3574
|
-
on: {
|
3575
|
-
beforeInit: function () {
|
3576
|
-
var e = this;
|
3577
|
-
if ("fade" === e.params.effect) {
|
3578
|
-
e.classNames.push(e.params.containerModifierClass + "fade");
|
3579
|
-
var t = {
|
3580
|
-
slidesPerView: 1,
|
3581
|
-
slidesPerColumn: 1,
|
3582
|
-
slidesPerGroup: 1,
|
3583
|
-
watchSlidesProgress: !0,
|
3584
|
-
spaceBetween: 0,
|
3585
|
-
virtualTranslate: !0
|
3586
|
-
};
|
3587
|
-
V.extend(e.params, t), V.extend(e.originalParams, t)
|
3588
|
-
}
|
3589
|
-
},
|
3590
|
-
setTranslate: function () {
|
3591
|
-
"fade" === this.params.effect && this.fadeEffect.setTranslate()
|
3592
|
-
},
|
3593
|
-
setTransition: function (e) {
|
3594
|
-
"fade" === this.params.effect && this.fadeEffect.setTransition(e)
|
3595
|
-
}
|
3596
|
-
}
|
3597
|
-
}, {
|
3598
|
-
name: "effect-cube",
|
3599
|
-
params: {
|
3600
|
-
cubeEffect: {
|
3601
|
-
slideShadows: !0,
|
3602
|
-
shadow: !0,
|
3603
|
-
shadowOffset: 20,
|
3604
|
-
shadowScale: .94
|
3605
|
-
}
|
3606
|
-
},
|
3607
|
-
create: function () {
|
3608
|
-
V.extend(this, {
|
3609
|
-
cubeEffect: {
|
3610
|
-
setTranslate: J.setTranslate.bind(this),
|
3611
|
-
setTransition: J.setTransition.bind(this)
|
3612
|
-
}
|
3613
|
-
})
|
3614
|
-
},
|
3615
|
-
on: {
|
3616
|
-
beforeInit: function () {
|
3617
|
-
var e = this;
|
3618
|
-
if ("cube" === e.params.effect) {
|
3619
|
-
e.classNames.push(e.params.containerModifierClass + "cube"), e.classNames.push(e.params.containerModifierClass + "3d");
|
3620
|
-
var t = {
|
3621
|
-
slidesPerView: 1,
|
3622
|
-
slidesPerColumn: 1,
|
3623
|
-
slidesPerGroup: 1,
|
3624
|
-
watchSlidesProgress: !0,
|
3625
|
-
resistanceRatio: 0,
|
3626
|
-
spaceBetween: 0,
|
3627
|
-
centeredSlides: !1,
|
3628
|
-
virtualTranslate: !0
|
3629
|
-
};
|
3630
|
-
V.extend(e.params, t), V.extend(e.originalParams, t)
|
3631
|
-
}
|
3632
|
-
},
|
3633
|
-
setTranslate: function () {
|
3634
|
-
"cube" === this.params.effect && this.cubeEffect.setTranslate()
|
3635
|
-
},
|
3636
|
-
setTransition: function (e) {
|
3637
|
-
"cube" === this.params.effect && this.cubeEffect.setTransition(e)
|
3638
|
-
}
|
3639
|
-
}
|
3640
|
-
}, {
|
3641
|
-
name: "effect-flip",
|
3642
|
-
params: {
|
3643
|
-
flipEffect: {
|
3644
|
-
slideShadows: !0,
|
3645
|
-
limitRotation: !0
|
3646
|
-
}
|
3647
|
-
},
|
3648
|
-
create: function () {
|
3649
|
-
V.extend(this, {
|
3650
|
-
flipEffect: {
|
3651
|
-
setTranslate: ee.setTranslate.bind(this),
|
3652
|
-
setTransition: ee.setTransition.bind(this)
|
3653
|
-
}
|
3654
|
-
})
|
3655
|
-
},
|
3656
|
-
on: {
|
3657
|
-
beforeInit: function () {
|
3658
|
-
var e = this;
|
3659
|
-
if ("flip" === e.params.effect) {
|
3660
|
-
e.classNames.push(e.params.containerModifierClass + "flip"), e.classNames.push(e.params.containerModifierClass + "3d");
|
3661
|
-
var t = {
|
3662
|
-
slidesPerView: 1,
|
3663
|
-
slidesPerColumn: 1,
|
3664
|
-
slidesPerGroup: 1,
|
3665
|
-
watchSlidesProgress: !0,
|
3666
|
-
spaceBetween: 0,
|
3667
|
-
virtualTranslate: !0
|
3668
|
-
};
|
3669
|
-
V.extend(e.params, t), V.extend(e.originalParams, t)
|
3670
|
-
}
|
3671
|
-
},
|
3672
|
-
setTranslate: function () {
|
3673
|
-
"flip" === this.params.effect && this.flipEffect.setTranslate()
|
3674
|
-
},
|
3675
|
-
setTransition: function (e) {
|
3676
|
-
"flip" === this.params.effect && this.flipEffect.setTransition(e)
|
3677
|
-
}
|
3678
|
-
}
|
3679
|
-
}, {
|
3680
|
-
name: "effect-coverflow",
|
3681
|
-
params: {
|
3682
|
-
coverflowEffect: {
|
3683
|
-
rotate: 50,
|
3684
|
-
stretch: 0,
|
3685
|
-
depth: 100,
|
3686
|
-
modifier: 1,
|
3687
|
-
slideShadows: !0
|
3688
|
-
}
|
3689
|
-
},
|
3690
|
-
create: function () {
|
3691
|
-
V.extend(this, {
|
3692
|
-
coverflowEffect: {
|
3693
|
-
setTranslate: te.setTranslate.bind(this),
|
3694
|
-
setTransition: te.setTransition.bind(this)
|
3695
|
-
}
|
3696
|
-
})
|
3697
|
-
},
|
3698
|
-
on: {
|
3699
|
-
beforeInit: function () {
|
3700
|
-
var e = this;
|
3701
|
-
"coverflow" === e.params.effect && (e.classNames.push(e.params.containerModifierClass + "coverflow"), e.classNames.push(e.params.containerModifierClass + "3d"), e.params.watchSlidesProgress = !0, e.originalParams.watchSlidesProgress = !0)
|
3702
|
-
},
|
3703
|
-
setTranslate: function () {
|
3704
|
-
"coverflow" === this.params.effect && this.coverflowEffect.setTranslate()
|
3705
|
-
},
|
3706
|
-
setTransition: function (e) {
|
3707
|
-
"coverflow" === this.params.effect && this.coverflowEffect.setTransition(e)
|
3708
|
-
}
|
3709
|
-
}
|
3710
|
-
}, {
|
3711
|
-
name: "thumbs",
|
3712
|
-
params: {
|
3713
|
-
thumbs: {
|
3714
|
-
swiper: null,
|
3715
|
-
slideThumbActiveClass: "swiper-slide-thumb-active",
|
3716
|
-
thumbsContainerClass: "swiper-container-thumbs"
|
3717
|
-
}
|
3718
|
-
},
|
3719
|
-
create: function () {
|
3720
|
-
V.extend(this, {
|
3721
|
-
thumbs: {
|
3722
|
-
swiper: null,
|
3723
|
-
init: ae.init.bind(this),
|
3724
|
-
update: ae.update.bind(this),
|
3725
|
-
onThumbClick: ae.onThumbClick.bind(this)
|
3726
|
-
}
|
3727
|
-
})
|
3728
|
-
},
|
3729
|
-
on: {
|
3730
|
-
beforeInit: function () {
|
3731
|
-
var e = this.params.thumbs;
|
3732
|
-
e && e.swiper && (this.thumbs.init(), this.thumbs.update(!0))
|
3733
|
-
},
|
3734
|
-
slideChange: function () {
|
3735
|
-
this.thumbs.swiper && this.thumbs.update()
|
3736
|
-
},
|
3737
|
-
update: function () {
|
3738
|
-
this.thumbs.swiper && this.thumbs.update()
|
3739
|
-
},
|
3740
|
-
resize: function () {
|
3741
|
-
this.thumbs.swiper && this.thumbs.update()
|
3742
|
-
},
|
3743
|
-
observerUpdate: function () {
|
3744
|
-
this.thumbs.swiper && this.thumbs.update()
|
3745
|
-
},
|
3746
|
-
setTransition: function (e) {
|
3747
|
-
var t = this.thumbs.swiper;
|
3748
|
-
t && t.setTransition(e)
|
3749
|
-
},
|
3750
|
-
beforeDestroy: function () {
|
3751
|
-
var e = this.thumbs.swiper;
|
3752
|
-
e && this.thumbs.swiperCreated && e && e.destroy()
|
3753
|
-
}
|
3754
|
-
}
|
3755
|
-
}];
|
3756
|
-
return void 0 === S.use && (S.use = S.Class.use, S.installModule = S.Class.installModule), S.use(ie), S
|
3757
|
-
});
|
3758
|
-
//# sourceMappingURL=swiper.min.js.map
|