@lanaco/lnc-react-ui 4.0.122 → 4.0.124

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,1576 +1,721 @@
1
- import { jsx as N, jsxs as le } from "react/jsx-runtime";
2
- import F, { forwardRef as Ce } from "react";
3
- import { c as Oe } from "./_commonjsHelpers-BkfeUUK-.js";
4
- import { p as Le, P as Se } from "./index-CblbdqjE.js";
5
- import { a as ke } from "./index-BXrmgzsU.js";
6
- import { s as te } from "./emotion-styled.browser.esm-BNN1dTl3.js";
7
- import { M as ne } from "./consts-BuFChS64.js";
8
- import { k as re } from "./utils-BbgAIA9N.js";
9
- import De from "./Button.js";
10
- var Re = {}, ie = {}, me = {}, fe = {}, ge;
11
- function Ae() {
12
- return ge || (ge = 1, function(t) {
13
- (function(n, r) {
14
- r(t, F, Le);
15
- })(Oe, function(n, r, i) {
16
- Object.defineProperty(n, "__esModule", {
17
- value: !0
18
- }), n.setHasSupportToCaptureOption = E;
19
- var e = a(r), o = a(i);
20
- function a(l) {
21
- return l && l.__esModule ? l : {
22
- default: l
23
- };
24
- }
25
- var s = Object.assign || function(l) {
26
- for (var p = 1; p < arguments.length; p++) {
27
- var S = arguments[p];
28
- for (var u in S)
29
- Object.prototype.hasOwnProperty.call(S, u) && (l[u] = S[u]);
30
- }
31
- return l;
32
- };
33
- function f(l, p) {
34
- var S = {};
35
- for (var u in l)
36
- p.indexOf(u) >= 0 || Object.prototype.hasOwnProperty.call(l, u) && (S[u] = l[u]);
37
- return S;
38
- }
39
- function h(l, p) {
40
- if (!(l instanceof p))
41
- throw new TypeError("Cannot call a class as a function");
42
- }
43
- var m = /* @__PURE__ */ function() {
44
- function l(p, S) {
45
- for (var u = 0; u < S.length; u++) {
46
- var g = S[u];
47
- g.enumerable = g.enumerable || !1, g.configurable = !0, "value" in g && (g.writable = !0), Object.defineProperty(p, g.key, g);
48
- }
49
- }
50
- return function(p, S, u) {
51
- return S && l(p.prototype, S), u && l(p, u), p;
52
- };
53
- }();
54
- function v(l, p) {
55
- if (!l)
56
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
57
- return p && (typeof p == "object" || typeof p == "function") ? p : l;
58
- }
59
- function _(l, p) {
60
- if (typeof p != "function" && p !== null)
61
- throw new TypeError("Super expression must either be null or a function, not " + typeof p);
62
- l.prototype = Object.create(p && p.prototype, {
63
- constructor: {
64
- value: l,
65
- enumerable: !1,
66
- writable: !0,
67
- configurable: !0
68
- }
69
- }), p && (Object.setPrototypeOf ? Object.setPrototypeOf(l, p) : l.__proto__ = p);
70
- }
71
- var b = !1;
72
- function E(l) {
73
- b = l;
74
- }
75
- try {
76
- addEventListener("test", null, Object.defineProperty({}, "capture", { get: function() {
77
- E(!0);
78
- } }));
79
- } catch {
80
- }
81
- function X() {
82
- var l = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : { capture: !0 };
83
- return b ? l : l.capture;
84
- }
85
- function ue(l) {
86
- if ("touches" in l) {
87
- var p = l.touches[0], S = p.pageX, u = p.pageY;
88
- return { x: S, y: u };
89
- }
90
- var g = l.screenX, T = l.screenY;
91
- return { x: g, y: T };
92
- }
93
- var z = function(l) {
94
- _(p, l);
95
- function p() {
96
- var S;
97
- h(this, p);
98
- for (var u = arguments.length, g = Array(u), T = 0; T < u; T++)
99
- g[T] = arguments[T];
100
- var w = v(this, (S = p.__proto__ || Object.getPrototypeOf(p)).call.apply(S, [this].concat(g)));
101
- return w._handleSwipeStart = w._handleSwipeStart.bind(w), w._handleSwipeMove = w._handleSwipeMove.bind(w), w._handleSwipeEnd = w._handleSwipeEnd.bind(w), w._onMouseDown = w._onMouseDown.bind(w), w._onMouseMove = w._onMouseMove.bind(w), w._onMouseUp = w._onMouseUp.bind(w), w._setSwiperRef = w._setSwiperRef.bind(w), w;
102
- }
103
- return m(p, [{
104
- key: "componentDidMount",
105
- value: function() {
106
- this.swiper && this.swiper.addEventListener("touchmove", this._handleSwipeMove, X({
107
- capture: !0,
108
- passive: !1
109
- }));
110
- }
111
- }, {
112
- key: "componentWillUnmount",
113
- value: function() {
114
- this.swiper && this.swiper.removeEventListener("touchmove", this._handleSwipeMove, X({
115
- capture: !0,
116
- passive: !1
117
- }));
118
- }
119
- }, {
120
- key: "_onMouseDown",
121
- value: function(u) {
122
- this.props.allowMouseEvents && (this.mouseDown = !0, document.addEventListener("mouseup", this._onMouseUp), document.addEventListener("mousemove", this._onMouseMove), this._handleSwipeStart(u));
123
- }
124
- }, {
125
- key: "_onMouseMove",
126
- value: function(u) {
127
- this.mouseDown && this._handleSwipeMove(u);
128
- }
129
- }, {
130
- key: "_onMouseUp",
131
- value: function(u) {
132
- this.mouseDown = !1, document.removeEventListener("mouseup", this._onMouseUp), document.removeEventListener("mousemove", this._onMouseMove), this._handleSwipeEnd(u);
133
- }
134
- }, {
135
- key: "_handleSwipeStart",
136
- value: function(u) {
137
- var g = ue(u), T = g.x, w = g.y;
138
- this.moveStart = { x: T, y: w }, this.props.onSwipeStart(u);
139
- }
140
- }, {
141
- key: "_handleSwipeMove",
142
- value: function(u) {
143
- if (this.moveStart) {
144
- var g = ue(u), T = g.x, w = g.y, Y = T - this.moveStart.x, we = w - this.moveStart.y;
145
- this.moving = !0;
146
- var Me = this.props.onSwipeMove({
147
- x: Y,
148
- y: we
149
- }, u);
150
- Me && u.cancelable && u.preventDefault(), this.movePosition = { deltaX: Y, deltaY: we };
151
- }
152
- }
153
- }, {
154
- key: "_handleSwipeEnd",
155
- value: function(u) {
156
- this.props.onSwipeEnd(u);
157
- var g = this.props.tolerance;
158
- this.moving && this.movePosition && (this.movePosition.deltaX < -g ? this.props.onSwipeLeft(1, u) : this.movePosition.deltaX > g && this.props.onSwipeRight(1, u), this.movePosition.deltaY < -g ? this.props.onSwipeUp(1, u) : this.movePosition.deltaY > g && this.props.onSwipeDown(1, u)), this.moveStart = null, this.moving = !1, this.movePosition = null;
159
- }
160
- }, {
161
- key: "_setSwiperRef",
162
- value: function(u) {
163
- this.swiper = u, this.props.innerRef(u);
164
- }
165
- }, {
166
- key: "render",
167
- value: function() {
168
- var u = this.props;
169
- u.tagName;
170
- var g = u.className, T = u.style, w = u.children;
171
- u.allowMouseEvents, u.onSwipeUp, u.onSwipeDown, u.onSwipeLeft, u.onSwipeRight, u.onSwipeStart, u.onSwipeMove, u.onSwipeEnd, u.innerRef, u.tolerance;
172
- var Y = f(u, ["tagName", "className", "style", "children", "allowMouseEvents", "onSwipeUp", "onSwipeDown", "onSwipeLeft", "onSwipeRight", "onSwipeStart", "onSwipeMove", "onSwipeEnd", "innerRef", "tolerance"]);
173
- return e.default.createElement(
174
- this.props.tagName,
175
- s({
176
- ref: this._setSwiperRef,
177
- onMouseDown: this._onMouseDown,
178
- onTouchStart: this._handleSwipeStart,
179
- onTouchEnd: this._handleSwipeEnd,
180
- className: g,
181
- style: T
182
- }, Y),
183
- w
184
- );
185
- }
186
- }]), p;
187
- }(r.Component);
188
- z.displayName = "ReactSwipe", z.propTypes = {
189
- tagName: o.default.string,
190
- className: o.default.string,
191
- style: o.default.object,
192
- children: o.default.node,
193
- allowMouseEvents: o.default.bool,
194
- onSwipeUp: o.default.func,
195
- onSwipeDown: o.default.func,
196
- onSwipeLeft: o.default.func,
197
- onSwipeRight: o.default.func,
198
- onSwipeStart: o.default.func,
199
- onSwipeMove: o.default.func,
200
- onSwipeEnd: o.default.func,
201
- innerRef: o.default.func,
202
- tolerance: o.default.number.isRequired
203
- }, z.defaultProps = {
204
- tagName: "div",
205
- allowMouseEvents: !1,
206
- onSwipeUp: function() {
207
- },
208
- onSwipeDown: function() {
209
- },
210
- onSwipeLeft: function() {
211
- },
212
- onSwipeRight: function() {
213
- },
214
- onSwipeStart: function() {
215
- },
216
- onSwipeMove: function() {
217
- },
218
- onSwipeEnd: function() {
219
- },
220
- innerRef: function() {
221
- },
222
- tolerance: 0
223
- }, n.default = z;
224
- });
225
- }(fe)), fe;
226
- }
227
- (function(t) {
228
- (function(n, r) {
229
- r(t, Ae());
230
- })(Oe, function(n, r) {
231
- Object.defineProperty(n, "__esModule", {
232
- value: !0
233
- });
234
- var i = e(r);
235
- function e(o) {
236
- return o && o.__esModule ? o : {
237
- default: o
238
- };
239
- }
240
- n.default = i.default;
241
- });
242
- })(me);
243
- var K = {};
244
- Object.defineProperty(K, "__esModule", {
245
- value: !0
246
- });
247
- K.default = void 0;
248
- var D = We(ke);
249
- function We(t) {
250
- return t && t.__esModule ? t : { default: t };
251
- }
252
- function ze(t, n, r) {
253
- return n in t ? Object.defineProperty(t, n, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[n] = r, t;
254
- }
255
- var Ne = {
256
- ROOT: function(n) {
257
- return (0, D.default)(ze({
258
- "carousel-root": !0
259
- }, n || "", !!n));
260
- },
261
- CAROUSEL: function(n) {
262
- return (0, D.default)({
263
- carousel: !0,
264
- "carousel-slider": n
265
- });
266
- },
267
- WRAPPER: function(n, r) {
268
- return (0, D.default)({
269
- "thumbs-wrapper": !n,
270
- "slider-wrapper": n,
271
- "axis-horizontal": r === "horizontal",
272
- "axis-vertical": r !== "horizontal"
273
- });
274
- },
275
- SLIDER: function(n, r) {
276
- return (0, D.default)({
277
- thumbs: !n,
278
- slider: n,
279
- animated: !r
280
- });
281
- },
282
- ITEM: function(n, r, i) {
283
- return (0, D.default)({
284
- thumb: !n,
285
- slide: n,
286
- selected: r,
287
- previous: i
288
- });
289
- },
290
- ARROW_PREV: function(n) {
291
- return (0, D.default)({
292
- "control-arrow control-prev": !0,
293
- "control-disabled": n
294
- });
295
- },
296
- ARROW_NEXT: function(n) {
297
- return (0, D.default)({
298
- "control-arrow control-next": !0,
299
- "control-disabled": n
300
- });
301
- },
302
- DOT: function(n) {
303
- return (0, D.default)({
304
- dot: !0,
305
- selected: n
306
- });
1
+ import { jsx as x, jsxs as z } from "react/jsx-runtime";
2
+ import A, { forwardRef as ft } from "react";
3
+ import { c as N, g as mt } from "./_commonjsHelpers-BkfeUUK-.js";
4
+ import { P as U } from "./index-CblbdqjE.js";
5
+ import vt from "./Button.js";
6
+ import { u as gt } from "./useDetectMobile-Bkvj0VMa.js";
7
+ import { s as yt } from "./emotion-styled.browser.esm-BNN1dTl3.js";
8
+ var q = {}, J = {}, m = {}, B = {};
9
+ (function(o) {
10
+ function i(n, s, l) {
11
+ var u = s.slidesToShow, d = s.currentSlide;
12
+ return l.length > 2 * u ? n + 2 * u : d >= l.length ? l.length + n : n;
307
13
  }
308
- };
309
- K.default = Ne;
310
- var j = {}, oe = {};
311
- Object.defineProperty(oe, "__esModule", {
312
- value: !0
313
- });
314
- oe.outerWidth = void 0;
315
- var xe = function(n) {
316
- var r = n.offsetWidth, i = getComputedStyle(n);
317
- return r += parseInt(i.marginLeft) + parseInt(i.marginRight), r;
318
- };
319
- oe.outerWidth = xe;
320
- var x = {};
321
- Object.defineProperty(x, "__esModule", {
322
- value: !0
323
- });
324
- x.default = void 0;
325
- var He = function(n, r, i) {
326
- var e = n === 0 ? n : n + r, o = i === "horizontal" ? [e, 0, 0] : [0, e, 0], a = "translate3d", s = "(" + o.join(",") + ")";
327
- return a + s;
328
- };
329
- x.default = He;
330
- var q = {};
331
- Object.defineProperty(q, "__esModule", {
332
- value: !0
333
- });
334
- q.default = void 0;
335
- var $e = function() {
336
- return window;
337
- };
338
- q.default = $e;
339
- Object.defineProperty(j, "__esModule", {
340
- value: !0
341
- });
342
- j.default = void 0;
343
- var I = Ke(F), A = ae(K), Ue = oe, be = ae(x), Fe = ae(me), V = ae(q);
344
- function ae(t) {
345
- return t && t.__esModule ? t : { default: t };
346
- }
347
- function Ee() {
348
- if (typeof WeakMap != "function") return null;
349
- var t = /* @__PURE__ */ new WeakMap();
350
- return Ee = function() {
351
- return t;
352
- }, t;
353
- }
354
- function Ke(t) {
355
- if (t && t.__esModule)
356
- return t;
357
- if (t === null || $(t) !== "object" && typeof t != "function")
358
- return { default: t };
359
- var n = Ee();
360
- if (n && n.has(t))
361
- return n.get(t);
362
- var r = {}, i = Object.defineProperty && Object.getOwnPropertyDescriptor;
363
- for (var e in t)
364
- if (Object.prototype.hasOwnProperty.call(t, e)) {
365
- var o = i ? Object.getOwnPropertyDescriptor(t, e) : null;
366
- o && (o.get || o.set) ? Object.defineProperty(r, e, o) : r[e] = t[e];
367
- }
368
- return r.default = t, n && n.set(t, r), r;
369
- }
370
- function $(t) {
371
- "@babel/helpers - typeof";
372
- return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? $ = function(r) {
373
- return typeof r;
374
- } : $ = function(r) {
375
- return r && typeof Symbol == "function" && r.constructor === Symbol && r !== Symbol.prototype ? "symbol" : typeof r;
376
- }, $(t);
377
- }
378
- function ce() {
379
- return ce = Object.assign || function(t) {
380
- for (var n = 1; n < arguments.length; n++) {
381
- var r = arguments[n];
382
- for (var i in r)
383
- Object.prototype.hasOwnProperty.call(r, i) && (t[i] = r[i]);
384
- }
385
- return t;
386
- }, ce.apply(this, arguments);
387
- }
388
- function je(t, n) {
389
- if (!(t instanceof n))
390
- throw new TypeError("Cannot call a class as a function");
391
- }
392
- function qe(t, n) {
393
- for (var r = 0; r < n.length; r++) {
394
- var i = n[r];
395
- i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(t, i.key, i);
14
+ function t(n, s) {
15
+ if (s.length > 2 * n) {
16
+ for (var l = {}, u = s.length - 2 * n, d = s.length - u, c = u, h = 0; h < d; h++) l[h] = c, c++;
17
+ var p = s.length + d, f = p + s.slice(0, 2 * n).length, g = 0;
18
+ for (h = p; h <= f; h++) l[h] = g, g++;
19
+ var w = p, b = 0;
20
+ for (h = d; h < w; h++) l[h] = b, b++;
21
+ return l;
22
+ }
23
+ l = {};
24
+ var _ = 3 * s.length, y = 0;
25
+ for (h = 0; h < _; h++) l[h] = y, ++y === s.length && (y = 0);
26
+ return l;
396
27
  }
397
- }
398
- function Be(t, n, r) {
399
- return n && qe(t.prototype, n), t;
400
- }
401
- function Xe(t, n) {
402
- if (typeof n != "function" && n !== null)
403
- throw new TypeError("Super expression must either be null or a function");
404
- t.prototype = Object.create(n && n.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), n && de(t, n);
405
- }
406
- function de(t, n) {
407
- return de = Object.setPrototypeOf || function(i, e) {
408
- return i.__proto__ = e, i;
409
- }, de(t, n);
410
- }
411
- function Ye(t) {
412
- var n = Ge();
28
+ function e(n, s) {
29
+ return s.length < n ? s : s.length > 2 * n ? s.slice(s.length - 2 * n, s.length).concat(s, s.slice(0, 2 * n)) : s.concat(s, s);
30
+ }
31
+ function r(n, s) {
32
+ return s.length > 2 * n ? 2 * n : s.length;
33
+ }
34
+ function a(n, s, l) {
35
+ var u, d = n.currentSlide, c = n.slidesToShow, h = n.itemWidth, p = n.totalItems, f = 0, g = 0, w = d === 0, b = s.length - (s.length - 2 * c);
36
+ return s.length < c ? (g = f = 0, w = u = !1) : s.length > 2 * c ? ((u = d >= b + s.length) && (g = -h * (f = d - s.length)), w && (g = -h * (f = b + (s.length - 2 * c)))) : ((u = d >= 2 * s.length) && (g = -h * (f = d - s.length)), w && (g = l.showDots ? -h * (f = s.length) : -h * (f = p / 3))), { isReachingTheEnd: u, isReachingTheStart: w, nextSlide: f, nextPosition: g };
37
+ }
38
+ Object.defineProperty(o, "__esModule", { value: !0 }), o.getOriginalCounterPart = i, o.getOriginalIndexLookupTableByClones = t, o.getClones = e, o.getInitialSlideInInfiniteMode = r, o.checkClonesPosition = a;
39
+ })(B);
40
+ var O = {};
41
+ Object.defineProperty(O, "__esModule", { value: !0 });
42
+ var rt = !1;
43
+ function St(o, i, t, e) {
44
+ var r = 0, a = e || t;
45
+ return i && a && (!rt && process.env.NODE_ENV !== "production" && o[a].paritialVisibilityGutter && (rt = !0, console.warn("You appear to be using paritialVisibilityGutter instead of partialVisibilityGutter which will be moved to partialVisibilityGutter in the future completely")), r = o[a].partialVisibilityGutter || o[a].paritialVisibilityGutter), r;
46
+ }
47
+ function Tt(o, i) {
48
+ var t;
49
+ return i[o] && (t = (100 / i[o].items).toFixed(1)), t;
50
+ }
51
+ function wt(o, i, t) {
52
+ return Math.round(t / (i + (o.centerMode ? 1 : 0)));
53
+ }
54
+ O.getPartialVisibilityGutter = St, O.getWidthFromDeviceType = Tt, O.getItemClientSideWidth = wt;
55
+ var S = {};
56
+ Object.defineProperty(S, "__esModule", { value: !0 });
57
+ var K = O;
58
+ function Q(o) {
59
+ var i = o.slidesToShow;
60
+ return o.totalItems < i;
61
+ }
62
+ function bt(o, i) {
63
+ var t, e = o.domLoaded, r = o.slidesToShow, a = o.containerWidth, n = o.itemWidth, s = i.deviceType, l = i.responsive, u = i.ssr, d = i.partialVisbile, c = i.partialVisible, h = !!(e && r && a && n);
64
+ u && s && !h && (t = K.getWidthFromDeviceType(s, l));
65
+ var p = !!(u && s && !h && t);
66
+ return { shouldRenderOnSSR: p, flexBisis: t, domFullyLoaded: h, partialVisibilityGutter: K.getPartialVisibilityGutter(l, d || c, s, o.deviceType), shouldRenderAtAll: p || h };
67
+ }
68
+ function _t(o, i) {
69
+ var t = i.currentSlide, e = i.slidesToShow;
70
+ return t <= o && o < t + e;
71
+ }
72
+ function lt(o, i, t) {
73
+ var e = t || o.transform;
74
+ return !i.infinite && o.currentSlide === 0 || Q(o) ? e : e + o.itemWidth / 2;
75
+ }
76
+ function Ct(o) {
77
+ return !(0 < o.currentSlide);
78
+ }
79
+ function ut(o) {
80
+ var i = o.currentSlide, t = o.totalItems;
81
+ return !(i + o.slidesToShow < t);
82
+ }
83
+ function dt(o, i, t, e) {
84
+ i === void 0 && (i = 0);
85
+ var r = o.currentSlide, a = o.slidesToShow, n = ut(o), s = !t.infinite && n, l = e || o.transform;
86
+ if (Q(o)) return l;
87
+ var u = l + r * i;
88
+ return s ? u + (o.containerWidth - (o.itemWidth - i) * a) : u;
89
+ }
90
+ function ht(o, i) {
91
+ return o.rtl ? -1 * i : i;
92
+ }
93
+ function It(o, i, t) {
94
+ var e = i.partialVisbile, r = i.partialVisible, a = i.responsive, n = i.deviceType, s = i.centerMode, l = t || o.transform, u = K.getPartialVisibilityGutter(a, e || r, n, o.deviceType);
95
+ return ht(i, r || e ? dt(o, u, i, t) : s ? lt(o, i, t) : l);
96
+ }
97
+ function Mt(o, i) {
98
+ var t = o.domLoaded, e = o.slidesToShow, r = o.containerWidth, a = o.itemWidth, n = i.deviceType, s = i.responsive, l = i.slidesToSlide || 1, u = !!(t && e && r && a);
99
+ return i.ssr && i.deviceType && !u && Object.keys(s).forEach(function(d) {
100
+ var c = s[d].slidesToSlide;
101
+ n === d && c && (l = c);
102
+ }), u && Object.keys(s).forEach(function(d) {
103
+ var c = s[d], h = c.breakpoint, p = c.slidesToSlide, f = h.max, g = h.min;
104
+ p && window.innerWidth >= g && window.innerWidth <= f && (l = p);
105
+ }), l;
106
+ }
107
+ S.notEnoughChildren = Q, S.getInitialState = bt, S.getIfSlideIsVisbile = _t, S.getTransformForCenterMode = lt, S.isInLeftEnd = Ct, S.isInRightEnd = ut, S.getTransformForPartialVsibile = dt, S.parsePosition = ht, S.getTransform = It, S.getSlidesToSlide = Mt;
108
+ var Z = {};
109
+ Object.defineProperty(Z, "__esModule", { value: !0 });
110
+ var Pt = function(o, i, t) {
111
+ var e;
413
112
  return function() {
414
- var i = J(t), e;
415
- if (n) {
416
- var o = J(this).constructor;
417
- e = Reflect.construct(i, arguments, o);
418
- } else
419
- e = i.apply(this, arguments);
420
- return Ve(this, e);
113
+ var r = arguments;
114
+ e || (o.apply(this, r), e = !0, typeof t == "function" && t(!0), setTimeout(function() {
115
+ e = !1, typeof t == "function" && t(!1);
116
+ }, i));
421
117
  };
422
- }
423
- function Ve(t, n) {
424
- return n && ($(n) === "object" || typeof n == "function") ? n : O(t);
425
- }
426
- function O(t) {
427
- if (t === void 0)
428
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
429
- return t;
430
- }
431
- function Ge() {
432
- if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
433
- if (typeof Proxy == "function") return !0;
434
- try {
435
- return Date.prototype.toString.call(Reflect.construct(Date, [], function() {
436
- })), !0;
437
- } catch {
438
- return !1;
118
+ };
119
+ Z.default = Pt;
120
+ var ct = {};
121
+ (function(o) {
122
+ function i(t, e) {
123
+ var r = e.partialVisbile, a = e.partialVisible, n = e.centerMode, s = e.ssr, l = e.responsive;
124
+ if ((r || a) && n) throw new Error("center mode can not be used at the same time with partialVisible");
125
+ if (!l) throw s ? new Error("ssr mode need to be used in conjunction with responsive prop") : new Error("Responsive prop is needed for deciding the amount of items to show on the screen");
126
+ if (l && typeof l != "object") throw new Error("responsive prop must be an object");
439
127
  }
440
- }
441
- function J(t) {
442
- return J = Object.setPrototypeOf ? Object.getPrototypeOf : function(r) {
443
- return r.__proto__ || Object.getPrototypeOf(r);
444
- }, J(t);
445
- }
446
- function P(t, n, r) {
447
- return n in t ? Object.defineProperty(t, n, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[n] = r, t;
448
- }
449
- var Ze = function(n) {
450
- return n.hasOwnProperty("key");
451
- }, ve = /* @__PURE__ */ function(t) {
452
- Xe(r, t);
453
- var n = Ye(r);
454
- function r(i) {
455
- var e;
456
- return je(this, r), e = n.call(this, i), P(O(e), "itemsWrapperRef", void 0), P(O(e), "itemsListRef", void 0), P(O(e), "thumbsRef", void 0), P(O(e), "setItemsWrapperRef", function(o) {
457
- e.itemsWrapperRef = o;
458
- }), P(O(e), "setItemsListRef", function(o) {
459
- e.itemsListRef = o;
460
- }), P(O(e), "setThumbsRef", function(o, a) {
461
- e.thumbsRef || (e.thumbsRef = []), e.thumbsRef[a] = o;
462
- }), P(O(e), "updateSizes", function() {
463
- if (!(!e.props.children || !e.itemsWrapperRef || !e.thumbsRef)) {
464
- var o = I.Children.count(e.props.children), a = e.itemsWrapperRef.clientWidth, s = e.props.thumbWidth ? e.props.thumbWidth : (0, Ue.outerWidth)(e.thumbsRef[0]), f = Math.floor(a / s), h = f < o, m = h ? o - f : 0;
465
- e.setState(function(v, _) {
466
- return {
467
- itemSize: s,
468
- visibleItems: f,
469
- firstItem: h ? e.getFirstItem(_.selectedItem) : 0,
470
- lastPosition: m,
471
- showArrows: h
472
- };
473
- });
474
- }
475
- }), P(O(e), "handleClickItem", function(o, a, s) {
476
- if (!Ze(s) || s.key === "Enter") {
477
- var f = e.props.onSelectItem;
478
- typeof f == "function" && f(o, a);
479
- }
480
- }), P(O(e), "onSwipeStart", function() {
481
- e.setState({
482
- swiping: !0
483
- });
484
- }), P(O(e), "onSwipeEnd", function() {
485
- e.setState({
486
- swiping: !1
487
- });
488
- }), P(O(e), "onSwipeMove", function(o) {
489
- var a = o.x;
490
- if (!e.state.itemSize || !e.itemsWrapperRef || !e.state.visibleItems)
491
- return !1;
492
- var s = 0, f = I.Children.count(e.props.children), h = -(e.state.firstItem * 100) / e.state.visibleItems, m = Math.max(f - e.state.visibleItems, 0), v = -m * 100 / e.state.visibleItems;
493
- h === s && a > 0 && (a = 0), h === v && a < 0 && (a = 0);
494
- var _ = e.itemsWrapperRef.clientWidth, b = h + 100 / (_ / a);
495
- return e.itemsListRef && ["WebkitTransform", "MozTransform", "MsTransform", "OTransform", "transform", "msTransform"].forEach(function(E) {
496
- e.itemsListRef.style[E] = (0, be.default)(b, "%", e.props.axis);
497
- }), !0;
498
- }), P(O(e), "slideRight", function(o) {
499
- e.moveTo(e.state.firstItem - (typeof o == "number" ? o : 1));
500
- }), P(O(e), "slideLeft", function(o) {
501
- e.moveTo(e.state.firstItem + (typeof o == "number" ? o : 1));
502
- }), P(O(e), "moveTo", function(o) {
503
- o = o < 0 ? 0 : o, o = o >= e.state.lastPosition ? e.state.lastPosition : o, e.setState({
504
- firstItem: o
505
- });
506
- }), e.state = {
507
- selectedItem: i.selectedItem,
508
- swiping: !1,
509
- showArrows: !1,
510
- firstItem: 0,
511
- visibleItems: 0,
512
- lastPosition: 0
513
- }, e;
128
+ Object.defineProperty(o, "__esModule", { value: !0 }), o.default = i;
129
+ })(ct);
130
+ var H = {};
131
+ Object.defineProperty(H, "__esModule", { value: !0 });
132
+ var Et = S;
133
+ function Rt(o, i, t) {
134
+ t === void 0 && (t = 0);
135
+ var e, r, a = o.slidesToShow, n = o.currentSlide, s = o.itemWidth, l = o.totalItems, u = Et.getSlidesToSlide(o, i), d = n + 1 + t + a + (0 < t ? 0 : u);
136
+ return r = d <= l ? -s * (e = n + t + (0 < t ? 0 : u)) : l < d && n !== l - a ? -s * (e = l - a) : e = void 0, { nextSlides: e, nextPosition: r };
137
+ }
138
+ H.populateNextSlides = Rt;
139
+ var tt = {};
140
+ Object.defineProperty(tt, "__esModule", { value: !0 });
141
+ var xt = A, Ot = S, At = S;
142
+ function Dt(o, i, t) {
143
+ t === void 0 && (t = 0);
144
+ var e, r, a = o.currentSlide, n = o.itemWidth, s = o.slidesToShow, l = i.children, u = i.showDots, d = i.infinite, c = Ot.getSlidesToSlide(o, i), h = a - t - (0 < t ? 0 : c), p = (xt.Children.toArray(l).length - s) % c;
145
+ return r = 0 <= h ? (e = h, u && !d && 0 < p && At.isInRightEnd(o) && (e = a - p), -n * e) : e = h < 0 && a !== 0 ? 0 : void 0, { nextSlides: e, nextPosition: r };
146
+ }
147
+ tt.populatePreviousSlides = Dt;
148
+ var pt = {};
149
+ (function(o) {
150
+ function i(t, e, r, a, n, s) {
151
+ var l, u, d = t.itemWidth, c = t.slidesToShow, h = t.totalItems, p = t.currentSlide, f = e.infinite, g = !1, w = Math.round((r - a) / d), b = Math.round((a - r) / d), _ = r < n;
152
+ if (n < r && w <= c) {
153
+ l = "right";
154
+ var y = Math.abs(-d * (h - c)), I = s - (a - n), C = p === h - c;
155
+ (Math.abs(I) <= y || C && f) && (u = I, g = !0);
156
+ }
157
+ return _ && b <= c && (l = "left", ((I = s + (n - a)) <= 0 || p === 0 && f) && (g = !0, u = I)), { direction: l, nextPosition: u, canContinue: g };
514
158
  }
515
- return Be(r, [{
516
- key: "componentDidMount",
517
- value: function() {
518
- this.setupThumbs();
519
- }
520
- }, {
521
- key: "componentDidUpdate",
522
- value: function(e) {
523
- this.props.selectedItem !== this.state.selectedItem && this.setState({
524
- selectedItem: this.props.selectedItem,
525
- firstItem: this.getFirstItem(this.props.selectedItem)
526
- }), this.props.children !== e.children && this.updateSizes();
527
- }
528
- }, {
529
- key: "componentWillUnmount",
530
- value: function() {
531
- this.destroyThumbs();
532
- }
533
- }, {
534
- key: "setupThumbs",
535
- value: function() {
536
- (0, V.default)().addEventListener("resize", this.updateSizes), (0, V.default)().addEventListener("DOMContentLoaded", this.updateSizes), this.updateSizes();
537
- }
538
- }, {
539
- key: "destroyThumbs",
540
- value: function() {
541
- (0, V.default)().removeEventListener("resize", this.updateSizes), (0, V.default)().removeEventListener("DOMContentLoaded", this.updateSizes);
542
- }
543
- }, {
544
- key: "getFirstItem",
545
- value: function(e) {
546
- var o = e;
547
- return e >= this.state.lastPosition && (o = this.state.lastPosition), e < this.state.firstItem + this.state.visibleItems && (o = this.state.firstItem), e < this.state.firstItem && (o = e), o;
548
- }
549
- }, {
550
- key: "renderItems",
551
- value: function() {
552
- var e = this;
553
- return this.props.children.map(function(o, a) {
554
- var s = A.default.ITEM(!1, a === e.state.selectedItem), f = {
555
- key: a,
556
- ref: function(m) {
557
- return e.setThumbsRef(m, a);
558
- },
559
- className: s,
560
- onClick: e.handleClickItem.bind(e, a, e.props.children[a]),
561
- onKeyDown: e.handleClickItem.bind(e, a, e.props.children[a]),
562
- "aria-label": "".concat(e.props.labels.item, " ").concat(a + 1),
563
- style: {
564
- width: e.props.thumbWidth
565
- }
566
- };
567
- return /* @__PURE__ */ I.default.createElement("li", ce({}, f, {
568
- role: "button",
569
- tabIndex: 0
570
- }), o);
571
- });
572
- }
573
- }, {
574
- key: "render",
575
- value: function() {
576
- var e = this;
577
- if (!this.props.children)
578
- return null;
579
- var o = I.Children.count(this.props.children) > 1, a = this.state.showArrows && this.state.firstItem > 0, s = this.state.showArrows && this.state.firstItem < this.state.lastPosition, f = {}, h = -this.state.firstItem * (this.state.itemSize || 0), m = (0, be.default)(h, "px", this.props.axis), v = this.props.transitionTime + "ms";
580
- return f = {
581
- WebkitTransform: m,
582
- MozTransform: m,
583
- MsTransform: m,
584
- OTransform: m,
585
- transform: m,
586
- msTransform: m,
587
- WebkitTransitionDuration: v,
588
- MozTransitionDuration: v,
589
- MsTransitionDuration: v,
590
- OTransitionDuration: v,
591
- transitionDuration: v,
592
- msTransitionDuration: v
593
- }, /* @__PURE__ */ I.default.createElement("div", {
594
- className: A.default.CAROUSEL(!1)
595
- }, /* @__PURE__ */ I.default.createElement("div", {
596
- className: A.default.WRAPPER(!1),
597
- ref: this.setItemsWrapperRef
598
- }, /* @__PURE__ */ I.default.createElement("button", {
599
- type: "button",
600
- className: A.default.ARROW_PREV(!a),
601
- onClick: function() {
602
- return e.slideRight();
603
- },
604
- "aria-label": this.props.labels.leftArrow
605
- }), o ? /* @__PURE__ */ I.default.createElement(Fe.default, {
606
- tagName: "ul",
607
- className: A.default.SLIDER(!1, this.state.swiping),
608
- onSwipeLeft: this.slideLeft,
609
- onSwipeRight: this.slideRight,
610
- onSwipeMove: this.onSwipeMove,
611
- onSwipeStart: this.onSwipeStart,
612
- onSwipeEnd: this.onSwipeEnd,
613
- style: f,
614
- innerRef: this.setItemsListRef,
615
- allowMouseEvents: this.props.emulateTouch
616
- }, this.renderItems()) : /* @__PURE__ */ I.default.createElement("ul", {
617
- className: A.default.SLIDER(!1, this.state.swiping),
618
- ref: function(b) {
619
- return e.setItemsListRef(b);
620
- },
621
- style: f
622
- }, this.renderItems()), /* @__PURE__ */ I.default.createElement("button", {
623
- type: "button",
624
- className: A.default.ARROW_NEXT(!s),
625
- onClick: function() {
626
- return e.slideLeft();
627
- },
628
- "aria-label": this.props.labels.rightArrow
629
- })));
159
+ Object.defineProperty(o, "__esModule", { value: !0 }), o.populateSlidesOnMouseTouchMove = i;
160
+ })(pt);
161
+ Object.defineProperty(m, "__esModule", { value: !0 });
162
+ var k = B;
163
+ m.getOriginalCounterPart = k.getOriginalCounterPart, m.getClones = k.getClones, m.checkClonesPosition = k.checkClonesPosition, m.getInitialSlideInInfiniteMode = k.getInitialSlideInInfiniteMode;
164
+ var X = O;
165
+ m.getWidthFromDeviceType = X.getWidthFromDeviceType, m.getPartialVisibilityGutter = X.getPartialVisibilityGutter, m.getItemClientSideWidth = X.getItemClientSideWidth;
166
+ var P = S;
167
+ m.getInitialState = P.getInitialState, m.getIfSlideIsVisbile = P.getIfSlideIsVisbile, m.getTransformForCenterMode = P.getTransformForCenterMode, m.getTransformForPartialVsibile = P.getTransformForPartialVsibile, m.isInLeftEnd = P.isInLeftEnd, m.isInRightEnd = P.isInRightEnd, m.notEnoughChildren = P.notEnoughChildren, m.getSlidesToSlide = P.getSlidesToSlide;
168
+ var Wt = Z;
169
+ m.throttle = Wt.default;
170
+ var Lt = ct;
171
+ m.throwError = Lt.default;
172
+ var kt = H;
173
+ m.populateNextSlides = kt.populateNextSlides;
174
+ var Vt = tt;
175
+ m.populatePreviousSlides = Vt.populatePreviousSlides;
176
+ var jt = pt;
177
+ m.populateSlidesOnMouseTouchMove = jt.populateSlidesOnMouseTouchMove;
178
+ var F = {}, Nt = N && N.__extends || /* @__PURE__ */ function() {
179
+ var o = function(i, t) {
180
+ return (o = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
181
+ e.__proto__ = r;
182
+ } || function(e, r) {
183
+ for (var a in r) r.hasOwnProperty(a) && (e[a] = r[a]);
184
+ })(i, t);
185
+ };
186
+ return function(i, t) {
187
+ function e() {
188
+ this.constructor = i;
630
189
  }
631
- }]), r;
632
- }(I.Component);
633
- j.default = ve;
634
- P(ve, "displayName", "Thumbs");
635
- P(ve, "defaultProps", {
636
- axis: "horizontal",
637
- labels: {
638
- leftArrow: "previous slide / item",
639
- rightArrow: "next slide / item",
640
- item: "slide item"
641
- },
642
- selectedItem: 0,
643
- thumbWidth: 80,
644
- transitionTime: 350
645
- });
646
- var se = {};
647
- Object.defineProperty(se, "__esModule", {
648
- value: !0
649
- });
650
- se.default = void 0;
651
- var Je = function() {
652
- return document;
653
- };
654
- se.default = Je;
655
- var R = {};
656
- Object.defineProperty(R, "__esModule", {
657
- value: !0
658
- });
659
- R.setPosition = R.getPosition = R.isKeyboardEvent = R.defaultStatusFormatter = R.noop = void 0;
660
- var Qe = F, et = tt(x);
661
- function tt(t) {
662
- return t && t.__esModule ? t : { default: t };
663
- }
664
- var nt = function() {
665
- };
666
- R.noop = nt;
667
- var rt = function(n, r) {
668
- return "".concat(n, " of ").concat(r);
669
- };
670
- R.defaultStatusFormatter = rt;
671
- var it = function(n) {
672
- return n ? n.hasOwnProperty("key") : !1;
673
- };
674
- R.isKeyboardEvent = it;
675
- var ot = function(n, r) {
676
- if (r.infiniteLoop && ++n, n === 0)
677
- return 0;
678
- var i = Qe.Children.count(r.children);
679
- if (r.centerMode && r.axis === "horizontal") {
680
- var e = -n * r.centerSlidePercentage, o = i - 1;
681
- return n && (n !== o || r.infiniteLoop) ? e += (100 - r.centerSlidePercentage) / 2 : n === o && (e += 100 - r.centerSlidePercentage), e;
190
+ o(i, t), i.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
191
+ };
192
+ }();
193
+ Object.defineProperty(F, "__esModule", { value: !0 });
194
+ var Gt = A;
195
+ function Bt(o) {
196
+ return "clientY" in o;
197
+ }
198
+ F.isMouseMoveEvent = Bt;
199
+ var Ft = function(o) {
200
+ function i() {
201
+ return o !== null && o.apply(this, arguments) || this;
682
202
  }
683
- return -n * 100;
203
+ return Nt(i, o), i;
204
+ }(Gt.Component);
205
+ F.default = Ft;
206
+ var et = {}, it = {};
207
+ Object.defineProperty(it, "__esModule", { value: !0 });
208
+ var $t = B, zt = S;
209
+ function Ut(o, i, t, e) {
210
+ var r = {}, a = zt.getSlidesToSlide(i, t);
211
+ return Array(o).fill(0).forEach(function(n, s) {
212
+ var l = $t.getOriginalCounterPart(s, i, e);
213
+ if (s === 0) r[0] = l;
214
+ else {
215
+ var u = r[s - 1] + a;
216
+ r[s] = u;
217
+ }
218
+ }), r;
219
+ }
220
+ it.getLookupTableForNextSlides = Ut;
221
+ Object.defineProperty(et, "__esModule", { value: !0 });
222
+ var W = A, Xt = B, Yt = it, nt = S, Kt = function(o) {
223
+ var i = o.props, t = o.state, e = o.goToSlide, r = o.getState, a = i.showDots, n = i.customDot, s = i.dotListClass, l = i.infinite, u = i.children;
224
+ if (!a || nt.notEnoughChildren(t)) return null;
225
+ var d, c = t.currentSlide, h = t.slidesToShow, p = nt.getSlidesToSlide(t, i), f = W.Children.toArray(u);
226
+ d = l ? Math.ceil(f.length / p) : Math.ceil((f.length - h) / p) + 1;
227
+ var g = Yt.getLookupTableForNextSlides(d, t, i, f), w = Xt.getOriginalIndexLookupTableByClones(h, f), b = w[c];
228
+ return W.createElement("ul", { className: "react-multi-carousel-dot-list " + s }, Array(d).fill(0).map(function(_, y) {
229
+ var I, C;
230
+ if (l) {
231
+ C = g[y];
232
+ var R = w[C];
233
+ I = b === R || R <= b && b < R + p;
234
+ } else {
235
+ var D = f.length - h, L = y * p;
236
+ I = (C = D < L ? D : L) === c || C < c && c < C + p && c < f.length - h;
237
+ }
238
+ return n ? W.cloneElement(n, { index: y, active: I, key: y, onClick: function() {
239
+ return e(C);
240
+ }, carouselState: r() }) : W.createElement("li", { "data-index": y, key: y, className: "react-multi-carousel-dot " + (I ? "react-multi-carousel-dot--active" : "") }, W.createElement("button", { "aria-label": "Go to slide " + (y + 1), onClick: function() {
241
+ return e(C);
242
+ } }));
243
+ }));
684
244
  };
685
- R.getPosition = ot;
686
- var at = function(n, r) {
687
- var i = {};
688
- return ["WebkitTransform", "MozTransform", "MsTransform", "OTransform", "transform", "msTransform"].forEach(function(e) {
689
- i[e] = (0, et.default)(n, "%", r);
690
- }), i;
245
+ et.default = Kt;
246
+ var $ = {};
247
+ Object.defineProperty($, "__esModule", { value: !0 });
248
+ var G = A, qt = function(o) {
249
+ var i = o.customLeftArrow, t = o.getState, e = o.previous, r = o.disabled, a = o.rtl;
250
+ if (i) return G.cloneElement(i, { onClick: function() {
251
+ return e();
252
+ }, carouselState: t(), disabled: r, rtl: a });
253
+ var n = a ? "rtl" : "";
254
+ return G.createElement("button", { "aria-label": "Go to previous slide", className: "react-multiple-carousel__arrow react-multiple-carousel__arrow--left " + n, onClick: function() {
255
+ return e();
256
+ }, type: "button", disabled: r });
691
257
  };
692
- R.setPosition = at;
693
- var C = {};
694
- Object.defineProperty(C, "__esModule", {
695
- value: !0
696
- });
697
- C.fadeAnimationHandler = C.slideStopSwipingHandler = C.slideSwipeAnimationHandler = C.slideAnimationHandler = void 0;
698
- var Te = F, st = ut(x), L = R;
699
- function ut(t) {
700
- return t && t.__esModule ? t : { default: t };
701
- }
702
- function _e(t, n) {
703
- var r = Object.keys(t);
704
- if (Object.getOwnPropertySymbols) {
705
- var i = Object.getOwnPropertySymbols(t);
706
- n && (i = i.filter(function(e) {
707
- return Object.getOwnPropertyDescriptor(t, e).enumerable;
708
- })), r.push.apply(r, i);
709
- }
710
- return r;
711
- }
712
- function W(t) {
713
- for (var n = 1; n < arguments.length; n++) {
714
- var r = arguments[n] != null ? arguments[n] : {};
715
- n % 2 ? _e(Object(r), !0).forEach(function(i) {
716
- lt(t, i, r[i]);
717
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : _e(Object(r)).forEach(function(i) {
718
- Object.defineProperty(t, i, Object.getOwnPropertyDescriptor(r, i));
719
- });
720
- }
721
- return t;
722
- }
723
- function lt(t, n, r) {
724
- return n in t ? Object.defineProperty(t, n, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[n] = r, t;
725
- }
726
- var ft = function(n, r) {
727
- var i = {}, e = r.selectedItem, o = e, a = Te.Children.count(n.children) - 1, s = n.infiniteLoop && (e < 0 || e > a);
728
- if (s)
729
- return o < 0 ? n.centerMode && n.centerSlidePercentage && n.axis === "horizontal" ? i.itemListStyle = (0, L.setPosition)(-(a + 2) * n.centerSlidePercentage - (100 - n.centerSlidePercentage) / 2, n.axis) : i.itemListStyle = (0, L.setPosition)(-(a + 2) * 100, n.axis) : o > a && (i.itemListStyle = (0, L.setPosition)(0, n.axis)), i;
730
- var f = (0, L.getPosition)(e, n), h = (0, st.default)(f, "%", n.axis), m = n.transitionTime + "ms";
731
- return i.itemListStyle = {
732
- WebkitTransform: h,
733
- msTransform: h,
734
- OTransform: h,
735
- transform: h
736
- }, r.swiping || (i.itemListStyle = W(W({}, i.itemListStyle), {}, {
737
- WebkitTransitionDuration: m,
738
- MozTransitionDuration: m,
739
- OTransitionDuration: m,
740
- transitionDuration: m,
741
- msTransitionDuration: m
742
- })), i;
743
- };
744
- C.slideAnimationHandler = ft;
745
- var ct = function(n, r, i, e) {
746
- var o = {}, a = r.axis === "horizontal", s = Te.Children.count(r.children), f = 0, h = (0, L.getPosition)(i.selectedItem, r), m = r.infiniteLoop ? (0, L.getPosition)(s - 1, r) - 100 : (0, L.getPosition)(s - 1, r), v = a ? n.x : n.y, _ = v;
747
- h === f && v > 0 && (_ = 0), h === m && v < 0 && (_ = 0);
748
- var b = h + 100 / (i.itemSize / _), E = Math.abs(v) > r.swipeScrollTolerance;
749
- return r.infiniteLoop && E && (i.selectedItem === 0 && b > -100 ? b -= s * 100 : i.selectedItem === s - 1 && b < -s * 100 && (b += s * 100)), (!r.preventMovementUntilSwipeScrollTolerance || E || i.swipeMovementStarted) && (i.swipeMovementStarted || e({
750
- swipeMovementStarted: !0
751
- }), o.itemListStyle = (0, L.setPosition)(b, r.axis)), E && !i.cancelClick && e({
752
- cancelClick: !0
753
- }), o;
258
+ $.LeftArrow = qt;
259
+ var Jt = function(o) {
260
+ var i = o.customRightArrow, t = o.getState, e = o.next, r = o.disabled, a = o.rtl;
261
+ if (i) return G.cloneElement(i, { onClick: function() {
262
+ return e();
263
+ }, carouselState: t(), disabled: r, rtl: a });
264
+ var n = a ? "rtl" : "";
265
+ return G.createElement("button", { "aria-label": "Go to next slide", className: "react-multiple-carousel__arrow react-multiple-carousel__arrow--right " + n, onClick: function() {
266
+ return e();
267
+ }, type: "button", disabled: r });
754
268
  };
755
- C.slideSwipeAnimationHandler = ct;
756
- var dt = function(n, r) {
757
- var i = (0, L.getPosition)(r.selectedItem, n), e = (0, L.setPosition)(i, n.axis);
758
- return {
759
- itemListStyle: e
760
- };
269
+ $.RightArrow = Jt;
270
+ var ot = {};
271
+ Object.defineProperty(ot, "__esModule", { value: !0 });
272
+ var V = A, Y = m, Qt = function(o) {
273
+ var i = o.props, t = o.state, e = o.goToSlide, r = o.clones, a = o.notEnoughChildren, n = t.itemWidth, s = i.children, l = i.infinite, u = i.itemClass, d = i.itemAriaLabel, c = i.partialVisbile, h = i.partialVisible, p = Y.getInitialState(t, i), f = p.flexBisis, g = p.shouldRenderOnSSR, w = p.domFullyLoaded, b = p.partialVisibilityGutter;
274
+ return p.shouldRenderAtAll ? (c && console.warn('WARNING: Please correct props name: "partialVisible" as old typo will be removed in future versions!'), V.createElement(V.Fragment, null, (l ? r : V.Children.toArray(s)).map(function(_, y) {
275
+ return V.createElement("li", { key: y, "data-index": y, onClick: function() {
276
+ i.focusOnSelect && e(y);
277
+ }, "aria-hidden": Y.getIfSlideIsVisbile(y, t) ? "false" : "true", "aria-label": d || (_.props.ariaLabel ? _.props.ariaLabel : null), style: { flex: g ? "1 0 " + f + "%" : "auto", position: "relative", width: w ? ((c || h) && b && !a ? n - b : n) + "px" : "auto" }, className: "react-multi-carousel-item " + (Y.getIfSlideIsVisbile(y, t) ? "react-multi-carousel-item--active" : "") + " " + u }, _);
278
+ }))) : null;
761
279
  };
762
- C.slideStopSwipingHandler = dt;
763
- var pt = function(n, r) {
764
- var i = n.transitionTime + "ms", e = "ease-in-out", o = {
765
- position: "absolute",
766
- display: "block",
767
- zIndex: -2,
768
- minHeight: "100%",
769
- opacity: 0,
770
- top: 0,
771
- right: 0,
772
- left: 0,
773
- bottom: 0,
774
- transitionTimingFunction: e,
775
- msTransitionTimingFunction: e,
776
- MozTransitionTimingFunction: e,
777
- WebkitTransitionTimingFunction: e,
778
- OTransitionTimingFunction: e
280
+ ot.default = Qt;
281
+ var Zt = N && N.__extends || /* @__PURE__ */ function() {
282
+ var o = function(i, t) {
283
+ return (o = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
284
+ e.__proto__ = r;
285
+ } || function(e, r) {
286
+ for (var a in r) r.hasOwnProperty(a) && (e[a] = r[a]);
287
+ })(i, t);
779
288
  };
780
- return r.swiping || (o = W(W({}, o), {}, {
781
- WebkitTransitionDuration: i,
782
- MozTransitionDuration: i,
783
- OTransitionDuration: i,
784
- transitionDuration: i,
785
- msTransitionDuration: i
786
- })), {
787
- slideStyle: o,
788
- selectedStyle: W(W({}, o), {}, {
789
- opacity: 1,
790
- position: "relative"
791
- }),
792
- prevStyle: W({}, o)
793
- };
794
- };
795
- C.fadeAnimationHandler = pt;
796
- Object.defineProperty(ie, "__esModule", {
797
- value: !0
798
- });
799
- ie.default = void 0;
800
- var y = vt(F), ht = B(me), k = B(K), mt = B(j), G = B(se), Z = B(q), H = R, Q = C;
801
- function B(t) {
802
- return t && t.__esModule ? t : { default: t };
803
- }
804
- function Ie() {
805
- if (typeof WeakMap != "function") return null;
806
- var t = /* @__PURE__ */ new WeakMap();
807
- return Ie = function() {
808
- return t;
809
- }, t;
810
- }
811
- function vt(t) {
812
- if (t && t.__esModule)
813
- return t;
814
- if (t === null || U(t) !== "object" && typeof t != "function")
815
- return { default: t };
816
- var n = Ie();
817
- if (n && n.has(t))
818
- return n.get(t);
819
- var r = {}, i = Object.defineProperty && Object.getOwnPropertyDescriptor;
820
- for (var e in t)
821
- if (Object.prototype.hasOwnProperty.call(t, e)) {
822
- var o = i ? Object.getOwnPropertyDescriptor(t, e) : null;
823
- o && (o.get || o.set) ? Object.defineProperty(r, e, o) : r[e] = t[e];
824
- }
825
- return r.default = t, n && n.set(t, r), r;
826
- }
827
- function U(t) {
828
- "@babel/helpers - typeof";
829
- return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? U = function(r) {
830
- return typeof r;
831
- } : U = function(r) {
832
- return r && typeof Symbol == "function" && r.constructor === Symbol && r !== Symbol.prototype ? "symbol" : typeof r;
833
- }, U(t);
834
- }
835
- function pe() {
836
- return pe = Object.assign || function(t) {
837
- for (var n = 1; n < arguments.length; n++) {
838
- var r = arguments[n];
839
- for (var i in r)
840
- Object.prototype.hasOwnProperty.call(r, i) && (t[i] = r[i]);
289
+ return function(i, t) {
290
+ function e() {
291
+ this.constructor = i;
841
292
  }
842
- return t;
843
- }, pe.apply(this, arguments);
844
- }
845
- function Pe(t, n) {
846
- var r = Object.keys(t);
847
- if (Object.getOwnPropertySymbols) {
848
- var i = Object.getOwnPropertySymbols(t);
849
- n && (i = i.filter(function(e) {
850
- return Object.getOwnPropertyDescriptor(t, e).enumerable;
851
- })), r.push.apply(r, i);
852
- }
853
- return r;
854
- }
855
- function M(t) {
856
- for (var n = 1; n < arguments.length; n++) {
857
- var r = arguments[n] != null ? arguments[n] : {};
858
- n % 2 ? Pe(Object(r), !0).forEach(function(i) {
859
- c(t, i, r[i]);
860
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : Pe(Object(r)).forEach(function(i) {
861
- Object.defineProperty(t, i, Object.getOwnPropertyDescriptor(r, i));
862
- });
863
- }
864
- return t;
865
- }
866
- function yt(t, n) {
867
- if (!(t instanceof n))
868
- throw new TypeError("Cannot call a class as a function");
869
- }
870
- function wt(t, n) {
871
- for (var r = 0; r < n.length; r++) {
872
- var i = n[r];
873
- i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(t, i.key, i);
874
- }
875
- }
876
- function St(t, n, r) {
877
- return n && wt(t.prototype, n), t;
878
- }
879
- function gt(t, n) {
880
- if (typeof n != "function" && n !== null)
881
- throw new TypeError("Super expression must either be null or a function");
882
- t.prototype = Object.create(n && n.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), n && he(t, n);
883
- }
884
- function he(t, n) {
885
- return he = Object.setPrototypeOf || function(i, e) {
886
- return i.__proto__ = e, i;
887
- }, he(t, n);
888
- }
889
- function bt(t) {
890
- var n = Pt();
891
- return function() {
892
- var i = ee(t), e;
893
- if (n) {
894
- var o = ee(this).constructor;
895
- e = Reflect.construct(i, arguments, o);
896
- } else
897
- e = i.apply(this, arguments);
898
- return _t(this, e);
293
+ o(i, t), i.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
899
294
  };
900
- }
901
- function _t(t, n) {
902
- return n && (U(n) === "object" || typeof n == "function") ? n : d(t);
903
- }
904
- function d(t) {
905
- if (t === void 0)
906
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
907
- return t;
908
- }
909
- function Pt() {
910
- if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
911
- if (typeof Proxy == "function") return !0;
912
- try {
913
- return Date.prototype.toString.call(Reflect.construct(Date, [], function() {
914
- })), !0;
915
- } catch {
916
- return !1;
295
+ }();
296
+ Object.defineProperty(J, "__esModule", { value: !0 });
297
+ var T = A, v = m, E = F, Ht = et, st = $, te = ot, j = S, M = 400, at = "transform 400ms ease-in-out", ee = function(o) {
298
+ function i(t) {
299
+ var e = o.call(this, t) || this;
300
+ return e.containerRef = T.createRef(), e.listRef = T.createRef(), e.state = { itemWidth: 0, slidesToShow: 0, currentSlide: 0, totalItems: T.Children.count(t.children), deviceType: "", domLoaded: !1, transform: 0, containerWidth: 0 }, e.onResize = e.onResize.bind(e), e.handleDown = e.handleDown.bind(e), e.handleMove = e.handleMove.bind(e), e.handleOut = e.handleOut.bind(e), e.onKeyUp = e.onKeyUp.bind(e), e.handleEnter = e.handleEnter.bind(e), e.setIsInThrottle = e.setIsInThrottle.bind(e), e.next = v.throttle(e.next.bind(e), t.transitionDuration || M, e.setIsInThrottle), e.previous = v.throttle(e.previous.bind(e), t.transitionDuration || M, e.setIsInThrottle), e.goToSlide = v.throttle(e.goToSlide.bind(e), t.transitionDuration || M, e.setIsInThrottle), e.onMove = !1, e.initialX = 0, e.lastX = 0, e.isAnimationAllowed = !1, e.direction = "", e.initialY = 0, e.isInThrottle = !1, e.transformPlaceHolder = 0, e;
917
301
  }
918
- }
919
- function ee(t) {
920
- return ee = Object.setPrototypeOf ? Object.getPrototypeOf : function(r) {
921
- return r.__proto__ || Object.getPrototypeOf(r);
922
- }, ee(t);
923
- }
924
- function c(t, n, r) {
925
- return n in t ? Object.defineProperty(t, n, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[n] = r, t;
926
- }
927
- var ye = /* @__PURE__ */ function(t) {
928
- gt(r, t);
929
- var n = bt(r);
930
- function r(i) {
302
+ return Zt(i, o), i.prototype.resetTotalItems = function() {
303
+ var t = this, e = T.Children.count(this.props.children), r = v.notEnoughChildren(this.state) ? 0 : Math.max(0, Math.min(this.state.currentSlide, e));
304
+ this.setState({ totalItems: e, currentSlide: r }, function() {
305
+ t.setContainerAndItemWidth(t.state.slidesToShow, !0);
306
+ });
307
+ }, i.prototype.setIsInThrottle = function(t) {
308
+ t === void 0 && (t = !1), this.isInThrottle = t;
309
+ }, i.prototype.setTransformDirectly = function(t, e) {
310
+ var r = this.props.additionalTransfrom;
311
+ this.transformPlaceHolder = t;
312
+ var a = j.getTransform(this.state, this.props, this.transformPlaceHolder);
313
+ this.listRef && this.listRef.current && (this.setAnimationDirectly(e), this.listRef.current.style.transform = "translate3d(" + (a + r) + "px,0,0)");
314
+ }, i.prototype.setAnimationDirectly = function(t) {
315
+ this.listRef && this.listRef.current && (this.listRef.current.style.transition = t ? this.props.customTransition || at : "none");
316
+ }, i.prototype.componentDidMount = function() {
317
+ this.setState({ domLoaded: !0 }), this.setItemsToShow(), window.addEventListener("resize", this.onResize), this.onResize(!0), this.props.keyBoardControl && window.addEventListener("keyup", this.onKeyUp), this.props.autoPlay && (this.autoPlay = setInterval(this.next, this.props.autoPlaySpeed));
318
+ }, i.prototype.setClones = function(t, e, r, a) {
319
+ var n = this;
320
+ a === void 0 && (a = !1), this.isAnimationAllowed = !1;
321
+ var s = T.Children.toArray(this.props.children), l = v.getInitialSlideInInfiniteMode(t || this.state.slidesToShow, s), u = v.getClones(this.state.slidesToShow, s), d = s.length < this.state.slidesToShow ? 0 : this.state.currentSlide;
322
+ this.setState({ totalItems: u.length, currentSlide: r && !a ? d : l }, function() {
323
+ n.correctItemsPosition(e || n.state.itemWidth);
324
+ });
325
+ }, i.prototype.setItemsToShow = function(t, e) {
326
+ var r = this, a = this.props.responsive;
327
+ Object.keys(a).forEach(function(n) {
328
+ var s = a[n], l = s.breakpoint, u = s.items, d = l.max, c = l.min, h = [window.innerWidth];
329
+ window.screen && window.screen.width && h.push(window.screen.width);
330
+ var p = Math.min.apply(Math, h);
331
+ c <= p && p <= d && (r.setState({ slidesToShow: u, deviceType: n }), r.setContainerAndItemWidth(u, t, e));
332
+ });
333
+ }, i.prototype.setContainerAndItemWidth = function(t, e, r) {
334
+ var a = this;
335
+ if (this.containerRef && this.containerRef.current) {
336
+ var n = this.containerRef.current.offsetWidth, s = v.getItemClientSideWidth(this.props, t, n);
337
+ this.setState({ containerWidth: n, itemWidth: s }, function() {
338
+ a.props.infinite && a.setClones(t, s, e, r);
339
+ }), e && this.correctItemsPosition(s);
340
+ }
341
+ }, i.prototype.correctItemsPosition = function(t, e, r) {
342
+ e && (this.isAnimationAllowed = !0), !e && this.isAnimationAllowed && (this.isAnimationAllowed = !1);
343
+ var a = this.state.totalItems < this.state.slidesToShow ? 0 : -t * this.state.currentSlide;
344
+ r && this.setTransformDirectly(a, !0), this.setState({ transform: a });
345
+ }, i.prototype.onResize = function(t) {
931
346
  var e;
932
- yt(this, r), e = n.call(this, i), c(d(e), "thumbsRef", void 0), c(d(e), "carouselWrapperRef", void 0), c(d(e), "listRef", void 0), c(d(e), "itemsRef", void 0), c(d(e), "timer", void 0), c(d(e), "animationHandler", void 0), c(d(e), "setThumbsRef", function(a) {
933
- e.thumbsRef = a;
934
- }), c(d(e), "setCarouselWrapperRef", function(a) {
935
- e.carouselWrapperRef = a;
936
- }), c(d(e), "setListRef", function(a) {
937
- e.listRef = a;
938
- }), c(d(e), "setItemsRef", function(a, s) {
939
- e.itemsRef || (e.itemsRef = []), e.itemsRef[s] = a;
940
- }), c(d(e), "autoPlay", function() {
941
- y.Children.count(e.props.children) <= 1 || (e.clearAutoPlay(), e.props.autoPlay && (e.timer = setTimeout(function() {
942
- e.increment();
943
- }, e.props.interval)));
944
- }), c(d(e), "clearAutoPlay", function() {
945
- e.timer && clearTimeout(e.timer);
946
- }), c(d(e), "resetAutoPlay", function() {
947
- e.clearAutoPlay(), e.autoPlay();
948
- }), c(d(e), "stopOnHover", function() {
949
- e.setState({
950
- isMouseEntered: !0
951
- }, e.clearAutoPlay);
952
- }), c(d(e), "startOnLeave", function() {
953
- e.setState({
954
- isMouseEntered: !1
955
- }, e.autoPlay);
956
- }), c(d(e), "isFocusWithinTheCarousel", function() {
957
- return e.carouselWrapperRef ? !!((0, G.default)().activeElement === e.carouselWrapperRef || e.carouselWrapperRef.contains((0, G.default)().activeElement)) : !1;
958
- }), c(d(e), "navigateWithKeyboard", function(a) {
959
- if (e.isFocusWithinTheCarousel()) {
960
- var s = e.props.axis, f = s === "horizontal", h = {
961
- ArrowUp: 38,
962
- ArrowRight: 39,
963
- ArrowDown: 40,
964
- ArrowLeft: 37
965
- }, m = f ? h.ArrowRight : h.ArrowDown, v = f ? h.ArrowLeft : h.ArrowUp;
966
- m === a.keyCode ? e.increment() : v === a.keyCode && e.decrement();
967
- }
968
- }), c(d(e), "updateSizes", function() {
969
- if (!(!e.state.initialized || !e.itemsRef || e.itemsRef.length === 0)) {
970
- var a = e.props.axis === "horizontal", s = e.itemsRef[0];
971
- if (s) {
972
- var f = a ? s.clientWidth : s.clientHeight;
973
- e.setState({
974
- itemSize: f
975
- }), e.thumbsRef && e.thumbsRef.updateSizes();
976
- }
977
- }
978
- }), c(d(e), "setMountState", function() {
979
- e.setState({
980
- hasMount: !0
981
- }), e.updateSizes();
982
- }), c(d(e), "handleClickItem", function(a, s) {
983
- if (y.Children.count(e.props.children) !== 0) {
984
- if (e.state.cancelClick) {
985
- e.setState({
986
- cancelClick: !1
987
- });
988
- return;
989
- }
990
- e.props.onClickItem(a, s), a !== e.state.selectedItem && e.setState({
991
- selectedItem: a
347
+ e = !!this.props.infinite && (typeof t != "boolean" || !t), this.setItemsToShow(e);
348
+ }, i.prototype.componentDidUpdate = function(t, e) {
349
+ var r = this, a = t.keyBoardControl, n = t.autoPlay, s = t.children, l = e.containerWidth, u = e.domLoaded, d = e.currentSlide;
350
+ if (this.containerRef && this.containerRef.current && this.containerRef.current.offsetWidth !== l && (this.itemsToShowTimeout && clearTimeout(this.itemsToShowTimeout), this.itemsToShowTimeout = setTimeout(function() {
351
+ r.setItemsToShow(!0);
352
+ }, this.props.transitionDuration || M)), a && !this.props.keyBoardControl && window.removeEventListener("keyup", this.onKeyUp), !a && this.props.keyBoardControl && window.addEventListener("keyup", this.onKeyUp), n && !this.props.autoPlay && this.autoPlay && (clearInterval(this.autoPlay), this.autoPlay = void 0), n || !this.props.autoPlay || this.autoPlay || (this.autoPlay = setInterval(this.next, this.props.autoPlaySpeed)), s.length !== this.props.children.length ? i.clonesTimeout = setTimeout(function() {
353
+ r.props.infinite ? r.setClones(r.state.slidesToShow, r.state.itemWidth, !0, !0) : r.resetTotalItems();
354
+ }, this.props.transitionDuration || M) : this.props.infinite && this.state.currentSlide !== d && this.correctClonesPosition({ domLoaded: u }), this.transformPlaceHolder !== this.state.transform && (this.transformPlaceHolder = this.state.transform), this.props.autoPlay && this.props.rewind && !this.props.infinite && v.isInRightEnd(this.state)) {
355
+ var c = this.props.transitionDuration || M;
356
+ i.isInThrottleTimeout = setTimeout(function() {
357
+ r.setIsInThrottle(!1), r.resetAutoplayInterval(), r.goToSlide(0, void 0, !!r.props.rewindWithAnimation);
358
+ }, c + this.props.autoPlaySpeed);
359
+ }
360
+ }, i.prototype.correctClonesPosition = function(t) {
361
+ var e = this, r = t.domLoaded, a = T.Children.toArray(this.props.children), n = v.checkClonesPosition(this.state, a, this.props), s = n.isReachingTheEnd, l = n.isReachingTheStart, u = n.nextSlide, d = n.nextPosition;
362
+ this.state.domLoaded && r && (s || l) && (this.isAnimationAllowed = !1, i.transformTimeout = setTimeout(function() {
363
+ e.setState({ transform: d, currentSlide: u });
364
+ }, this.props.transitionDuration || M));
365
+ }, i.prototype.next = function(t) {
366
+ var e = this;
367
+ t === void 0 && (t = 0);
368
+ var r = this.props, a = r.afterChange, n = r.beforeChange;
369
+ if (!v.notEnoughChildren(this.state)) {
370
+ var s = v.populateNextSlides(this.state, this.props, t), l = s.nextSlides, u = s.nextPosition, d = this.state.currentSlide;
371
+ l !== void 0 && u !== void 0 && (typeof n == "function" && n(l, this.getState()), this.isAnimationAllowed = !0, this.props.shouldResetAutoplay && this.resetAutoplayInterval(), this.setState({ transform: u, currentSlide: l }, function() {
372
+ typeof a == "function" && (i.afterChangeTimeout = setTimeout(function() {
373
+ a(d, e.getState());
374
+ }, e.props.transitionDuration || M));
375
+ }));
376
+ }
377
+ }, i.prototype.previous = function(t) {
378
+ var e = this;
379
+ t === void 0 && (t = 0);
380
+ var r = this.props, a = r.afterChange, n = r.beforeChange;
381
+ if (!v.notEnoughChildren(this.state)) {
382
+ var s = v.populatePreviousSlides(this.state, this.props, t), l = s.nextSlides, u = s.nextPosition;
383
+ if (l !== void 0 && u !== void 0) {
384
+ var d = this.state.currentSlide;
385
+ typeof n == "function" && n(l, this.getState()), this.isAnimationAllowed = !0, this.props.shouldResetAutoplay && this.resetAutoplayInterval(), this.setState({ transform: u, currentSlide: l }, function() {
386
+ typeof a == "function" && (i.afterChangeTimeout2 = setTimeout(function() {
387
+ a(d, e.getState());
388
+ }, e.props.transitionDuration || M));
992
389
  });
993
390
  }
994
- }), c(d(e), "handleOnChange", function(a, s) {
995
- y.Children.count(e.props.children) <= 1 || e.props.onChange(a, s);
996
- }), c(d(e), "handleClickThumb", function(a, s) {
997
- e.props.onClickThumb(a, s), e.moveTo(a);
998
- }), c(d(e), "onSwipeStart", function(a) {
999
- e.setState({
1000
- swiping: !0
1001
- }), e.props.onSwipeStart(a);
1002
- }), c(d(e), "onSwipeEnd", function(a) {
1003
- e.setState({
1004
- swiping: !1,
1005
- cancelClick: !1,
1006
- swipeMovementStarted: !1
1007
- }), e.props.onSwipeEnd(a), e.clearAutoPlay(), e.state.autoPlay && e.autoPlay();
1008
- }), c(d(e), "onSwipeMove", function(a, s) {
1009
- e.props.onSwipeMove(s);
1010
- var f = e.props.swipeAnimationHandler(a, e.props, e.state, e.setState.bind(d(e)));
1011
- return e.setState(M({}, f)), !!Object.keys(f).length;
1012
- }), c(d(e), "decrement", function() {
1013
- var a = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 1;
1014
- e.moveTo(e.state.selectedItem - (typeof a == "number" ? a : 1));
1015
- }), c(d(e), "increment", function() {
1016
- var a = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 1;
1017
- e.moveTo(e.state.selectedItem + (typeof a == "number" ? a : 1));
1018
- }), c(d(e), "moveTo", function(a) {
1019
- if (typeof a == "number") {
1020
- var s = y.Children.count(e.props.children) - 1;
1021
- a < 0 && (a = e.props.infiniteLoop ? s : 0), a > s && (a = e.props.infiniteLoop ? 0 : s), e.selectItem({
1022
- // if it's not a slider, we don't need to set position here
1023
- selectedItem: a
1024
- }), e.state.autoPlay && e.state.isMouseEntered === !1 && e.resetAutoPlay();
1025
- }
1026
- }), c(d(e), "onClickNext", function() {
1027
- e.increment(1);
1028
- }), c(d(e), "onClickPrev", function() {
1029
- e.decrement(1);
1030
- }), c(d(e), "onSwipeForward", function() {
1031
- e.increment(1), e.props.emulateTouch && e.setState({
1032
- cancelClick: !0
1033
- });
1034
- }), c(d(e), "onSwipeBackwards", function() {
1035
- e.decrement(1), e.props.emulateTouch && e.setState({
1036
- cancelClick: !0
1037
- });
1038
- }), c(d(e), "changeItem", function(a) {
1039
- return function(s) {
1040
- (!(0, H.isKeyboardEvent)(s) || s.key === "Enter") && e.moveTo(a);
1041
- };
1042
- }), c(d(e), "selectItem", function(a) {
1043
- e.setState(M({
1044
- previousItem: e.state.selectedItem
1045
- }, a), function() {
1046
- e.setState(e.animationHandler(e.props, e.state));
1047
- }), e.handleOnChange(a.selectedItem, y.Children.toArray(e.props.children)[a.selectedItem]);
1048
- }), c(d(e), "getInitialImage", function() {
1049
- var a = e.props.selectedItem, s = e.itemsRef && e.itemsRef[a], f = s && s.getElementsByTagName("img") || [];
1050
- return f[0];
1051
- }), c(d(e), "getVariableItemHeight", function(a) {
1052
- var s = e.itemsRef && e.itemsRef[a];
1053
- if (e.state.hasMount && s && s.children.length) {
1054
- var f = s.children[0].getElementsByTagName("img") || [];
1055
- if (f.length > 0) {
1056
- var h = f[0];
1057
- if (!h.complete) {
1058
- var m = function b() {
1059
- e.forceUpdate(), h.removeEventListener("load", b);
1060
- };
1061
- h.addEventListener("load", m);
1062
- }
1063
- }
1064
- var v = f[0] || s.children[0], _ = v.clientHeight;
1065
- return _ > 0 ? _ : null;
1066
- }
1067
- return null;
1068
- });
1069
- var o = {
1070
- initialized: !1,
1071
- previousItem: i.selectedItem,
1072
- selectedItem: i.selectedItem,
1073
- hasMount: !1,
1074
- isMouseEntered: !1,
1075
- autoPlay: i.autoPlay,
1076
- swiping: !1,
1077
- swipeMovementStarted: !1,
1078
- cancelClick: !1,
1079
- itemSize: 1,
1080
- itemListStyle: {},
1081
- slideStyle: {},
1082
- selectedStyle: {},
1083
- prevStyle: {}
1084
- };
1085
- return e.animationHandler = typeof i.animationHandler == "function" && i.animationHandler || i.animationHandler === "fade" && Q.fadeAnimationHandler || Q.slideAnimationHandler, e.state = M(M({}, o), e.animationHandler(i, o)), e;
1086
- }
1087
- return St(r, [{
1088
- key: "componentDidMount",
1089
- value: function() {
1090
- this.props.children && this.setupCarousel();
1091
- }
1092
- }, {
1093
- key: "componentDidUpdate",
1094
- value: function(e, o) {
1095
- !e.children && this.props.children && !this.state.initialized && this.setupCarousel(), !e.autoFocus && this.props.autoFocus && this.forceFocus(), o.swiping && !this.state.swiping && this.setState(M({}, this.props.stopSwipingHandler(this.props, this.state))), (e.selectedItem !== this.props.selectedItem || e.centerMode !== this.props.centerMode) && (this.updateSizes(), this.moveTo(this.props.selectedItem)), e.autoPlay !== this.props.autoPlay && (this.props.autoPlay ? this.setupAutoPlay() : this.destroyAutoPlay(), this.setState({
1096
- autoPlay: this.props.autoPlay
1097
- }));
1098
391
  }
1099
- }, {
1100
- key: "componentWillUnmount",
1101
- value: function() {
1102
- this.destroyCarousel();
392
+ }, i.prototype.resetAutoplayInterval = function() {
393
+ this.props.autoPlay && (clearInterval(this.autoPlay), this.autoPlay = setInterval(this.next, this.props.autoPlaySpeed));
394
+ }, i.prototype.componentWillUnmount = function() {
395
+ window.removeEventListener("resize", this.onResize), this.props.keyBoardControl && window.removeEventListener("keyup", this.onKeyUp), this.props.autoPlay && this.autoPlay && (clearInterval(this.autoPlay), this.autoPlay = void 0), this.itemsToShowTimeout && clearTimeout(this.itemsToShowTimeout), i.clonesTimeout && clearTimeout(i.clonesTimeout), i.isInThrottleTimeout && clearTimeout(i.isInThrottleTimeout), i.transformTimeout && clearTimeout(i.transformTimeout), i.afterChangeTimeout && clearTimeout(i.afterChangeTimeout), i.afterChangeTimeout2 && clearTimeout(i.afterChangeTimeout2), i.afterChangeTimeout3 && clearTimeout(i.afterChangeTimeout3);
396
+ }, i.prototype.resetMoveStatus = function() {
397
+ this.onMove = !1, this.initialX = 0, this.lastX = 0, this.direction = "", this.initialY = 0;
398
+ }, i.prototype.getCords = function(t) {
399
+ var e = t.clientX, r = t.clientY;
400
+ return { clientX: j.parsePosition(this.props, e), clientY: j.parsePosition(this.props, r) };
401
+ }, i.prototype.handleDown = function(t) {
402
+ if (!(!E.isMouseMoveEvent(t) && !this.props.swipeable || E.isMouseMoveEvent(t) && !this.props.draggable || this.isInThrottle)) {
403
+ var e = this.getCords(E.isMouseMoveEvent(t) ? t : t.touches[0]), r = e.clientX, a = e.clientY;
404
+ this.onMove = !0, this.initialX = r, this.initialY = a, this.lastX = r, this.isAnimationAllowed = !1;
405
+ }
406
+ }, i.prototype.handleMove = function(t) {
407
+ if (!(!E.isMouseMoveEvent(t) && !this.props.swipeable || E.isMouseMoveEvent(t) && !this.props.draggable || v.notEnoughChildren(this.state))) {
408
+ var e = this.getCords(E.isMouseMoveEvent(t) ? t : t.touches[0]), r = e.clientX, a = e.clientY, n = this.initialX - r, s = this.initialY - a;
409
+ if (this.onMove) {
410
+ if (!(Math.abs(n) > Math.abs(s))) return;
411
+ var l = v.populateSlidesOnMouseTouchMove(this.state, this.props, this.initialX, this.lastX, r, this.transformPlaceHolder), u = l.direction, d = l.nextPosition, c = l.canContinue;
412
+ u && (this.direction = u, c && d !== void 0 && this.setTransformDirectly(d)), this.lastX = r;
413
+ }
1103
414
  }
1104
- }, {
1105
- key: "setupCarousel",
1106
- value: function() {
1107
- var e = this;
1108
- this.bindEvents(), this.state.autoPlay && y.Children.count(this.props.children) > 1 && this.setupAutoPlay(), this.props.autoFocus && this.forceFocus(), this.setState({
1109
- initialized: !0
1110
- }, function() {
1111
- var o = e.getInitialImage();
1112
- o && !o.complete ? o.addEventListener("load", e.setMountState) : e.setMountState();
415
+ }, i.prototype.handleOut = function(t) {
416
+ this.props.autoPlay && !this.autoPlay && (this.autoPlay = setInterval(this.next, this.props.autoPlaySpeed));
417
+ var e = t.type === "touchend" && !this.props.swipeable, r = (t.type === "mouseleave" || t.type === "mouseup") && !this.props.draggable;
418
+ if (!e && !r && this.onMove) {
419
+ if (this.setAnimationDirectly(!0), this.direction === "right") if (this.initialX - this.lastX >= this.props.minimumTouchDrag) {
420
+ var a = Math.round((this.initialX - this.lastX) / this.state.itemWidth);
421
+ this.next(a);
422
+ } else this.correctItemsPosition(this.state.itemWidth, !0, !0);
423
+ this.direction === "left" && (this.lastX - this.initialX > this.props.minimumTouchDrag ? (a = Math.round((this.lastX - this.initialX) / this.state.itemWidth), this.previous(a)) : this.correctItemsPosition(this.state.itemWidth, !0, !0)), this.resetMoveStatus();
424
+ }
425
+ }, i.prototype.isInViewport = function(t) {
426
+ var e = t.getBoundingClientRect(), r = e.top, a = r === void 0 ? 0 : r, n = e.left, s = n === void 0 ? 0 : n, l = e.bottom, u = l === void 0 ? 0 : l, d = e.right, c = d === void 0 ? 0 : d;
427
+ return 0 <= a && 0 <= s && u <= (window.innerHeight || document.documentElement.clientHeight) && c <= (window.innerWidth || document.documentElement.clientWidth);
428
+ }, i.prototype.isChildOfCarousel = function(t) {
429
+ return !!(t instanceof Element && this.listRef && this.listRef.current) && this.listRef.current.contains(t);
430
+ }, i.prototype.onKeyUp = function(t) {
431
+ var e = t.target;
432
+ switch (t.keyCode) {
433
+ case 37:
434
+ if (this.isChildOfCarousel(e)) return this.previous();
435
+ break;
436
+ case 39:
437
+ if (this.isChildOfCarousel(e)) return this.next();
438
+ break;
439
+ case 9:
440
+ if (this.isChildOfCarousel(e) && e instanceof HTMLInputElement && this.isInViewport(e)) return this.next();
441
+ }
442
+ }, i.prototype.handleEnter = function(t) {
443
+ E.isMouseMoveEvent(t) && this.autoPlay && this.props.autoPlay && this.props.pauseOnHover && (clearInterval(this.autoPlay), this.autoPlay = void 0);
444
+ }, i.prototype.goToSlide = function(t, e, r) {
445
+ var a = this;
446
+ if (r === void 0 && (r = !0), !this.isInThrottle) {
447
+ var n = this.state.itemWidth, s = this.props, l = s.afterChange, u = s.beforeChange, d = this.state.currentSlide;
448
+ typeof u != "function" || e && (typeof e != "object" || e.skipBeforeChange) || u(t, this.getState()), this.isAnimationAllowed = r, this.props.shouldResetAutoplay && this.resetAutoplayInterval(), this.setState({ currentSlide: t, transform: -n * t }, function() {
449
+ a.props.infinite && a.correctClonesPosition({ domLoaded: !0 }), typeof l != "function" || e && (typeof e != "object" || e.skipAfterChange) || (i.afterChangeTimeout3 = setTimeout(function() {
450
+ l(d, a.getState());
451
+ }, a.props.transitionDuration || M));
1113
452
  });
1114
453
  }
1115
- }, {
1116
- key: "destroyCarousel",
1117
- value: function() {
1118
- this.state.initialized && (this.unbindEvents(), this.destroyAutoPlay());
1119
- }
1120
- }, {
1121
- key: "setupAutoPlay",
1122
- value: function() {
1123
- this.autoPlay();
1124
- var e = this.carouselWrapperRef;
1125
- this.props.stopOnHover && e && (e.addEventListener("mouseenter", this.stopOnHover), e.addEventListener("mouseleave", this.startOnLeave));
1126
- }
1127
- }, {
1128
- key: "destroyAutoPlay",
1129
- value: function() {
1130
- this.clearAutoPlay();
1131
- var e = this.carouselWrapperRef;
1132
- this.props.stopOnHover && e && (e.removeEventListener("mouseenter", this.stopOnHover), e.removeEventListener("mouseleave", this.startOnLeave));
1133
- }
1134
- }, {
1135
- key: "bindEvents",
1136
- value: function() {
1137
- (0, Z.default)().addEventListener("resize", this.updateSizes), (0, Z.default)().addEventListener("DOMContentLoaded", this.updateSizes), this.props.useKeyboardArrows && (0, G.default)().addEventListener("keydown", this.navigateWithKeyboard);
1138
- }
1139
- }, {
1140
- key: "unbindEvents",
1141
- value: function() {
1142
- (0, Z.default)().removeEventListener("resize", this.updateSizes), (0, Z.default)().removeEventListener("DOMContentLoaded", this.updateSizes);
1143
- var e = this.getInitialImage();
1144
- e && e.removeEventListener("load", this.setMountState), this.props.useKeyboardArrows && (0, G.default)().removeEventListener("keydown", this.navigateWithKeyboard);
1145
- }
1146
- }, {
1147
- key: "forceFocus",
1148
- value: function() {
1149
- var e;
1150
- (e = this.carouselWrapperRef) === null || e === void 0 || e.focus();
1151
- }
1152
- }, {
1153
- key: "renderItems",
1154
- value: function(e) {
1155
- var o = this;
1156
- return this.props.children ? y.Children.map(this.props.children, function(a, s) {
1157
- var f = s === o.state.selectedItem, h = s === o.state.previousItem, m = f && o.state.selectedStyle || h && o.state.prevStyle || o.state.slideStyle || {};
1158
- o.props.centerMode && o.props.axis === "horizontal" && (m = M(M({}, m), {}, {
1159
- minWidth: o.props.centerSlidePercentage + "%"
1160
- })), o.state.swiping && o.state.swipeMovementStarted && (m = M(M({}, m), {}, {
1161
- pointerEvents: "none"
1162
- }));
1163
- var v = {
1164
- ref: function(b) {
1165
- return o.setItemsRef(b, s);
1166
- },
1167
- key: "itemKey" + s + (e ? "clone" : ""),
1168
- className: k.default.ITEM(!0, s === o.state.selectedItem, s === o.state.previousItem),
1169
- onClick: o.handleClickItem.bind(o, s, a),
1170
- style: m
1171
- };
1172
- return /* @__PURE__ */ y.default.createElement("li", v, o.props.renderItem(a, {
1173
- isSelected: s === o.state.selectedItem,
1174
- isPrevious: s === o.state.previousItem
1175
- }));
1176
- }) : [];
1177
- }
1178
- }, {
1179
- key: "renderControls",
1180
- value: function() {
1181
- var e = this, o = this.props, a = o.showIndicators, s = o.labels, f = o.renderIndicator, h = o.children;
1182
- return a ? /* @__PURE__ */ y.default.createElement("ul", {
1183
- className: "control-dots"
1184
- }, y.Children.map(h, function(m, v) {
1185
- return f && f(e.changeItem(v), v === e.state.selectedItem, v, s.item);
1186
- })) : null;
1187
- }
1188
- }, {
1189
- key: "renderStatus",
1190
- value: function() {
1191
- return this.props.showStatus ? /* @__PURE__ */ y.default.createElement("p", {
1192
- className: "carousel-status"
1193
- }, this.props.statusFormatter(this.state.selectedItem + 1, y.Children.count(this.props.children))) : null;
1194
- }
1195
- }, {
1196
- key: "renderThumbs",
1197
- value: function() {
1198
- return !this.props.showThumbs || !this.props.children || y.Children.count(this.props.children) === 0 ? null : /* @__PURE__ */ y.default.createElement(mt.default, {
1199
- ref: this.setThumbsRef,
1200
- onSelectItem: this.handleClickThumb,
1201
- selectedItem: this.state.selectedItem,
1202
- transitionTime: this.props.transitionTime,
1203
- thumbWidth: this.props.thumbWidth,
1204
- labels: this.props.labels,
1205
- emulateTouch: this.props.emulateTouch
1206
- }, this.props.renderThumbs(this.props.children));
1207
- }
1208
- }, {
1209
- key: "render",
1210
- value: function() {
1211
- var e = this;
1212
- if (!this.props.children || y.Children.count(this.props.children) === 0)
1213
- return null;
1214
- var o = this.props.swipeable && y.Children.count(this.props.children) > 1, a = this.props.axis === "horizontal", s = this.props.showArrows && y.Children.count(this.props.children) > 1, f = s && (this.state.selectedItem > 0 || this.props.infiniteLoop) || !1, h = s && (this.state.selectedItem < y.Children.count(this.props.children) - 1 || this.props.infiniteLoop) || !1, m = this.renderItems(!0), v = m.shift(), _ = m.pop(), b = {
1215
- className: k.default.SLIDER(!0, this.state.swiping),
1216
- onSwipeMove: this.onSwipeMove,
1217
- onSwipeStart: this.onSwipeStart,
1218
- onSwipeEnd: this.onSwipeEnd,
1219
- style: this.state.itemListStyle,
1220
- tolerance: this.props.swipeScrollTolerance
1221
- }, E = {};
1222
- if (a) {
1223
- if (b.onSwipeLeft = this.onSwipeForward, b.onSwipeRight = this.onSwipeBackwards, this.props.dynamicHeight) {
1224
- var X = this.getVariableItemHeight(this.state.selectedItem);
1225
- E.height = X || "auto";
1226
- }
1227
- } else
1228
- b.onSwipeUp = this.props.verticalSwipe === "natural" ? this.onSwipeBackwards : this.onSwipeForward, b.onSwipeDown = this.props.verticalSwipe === "natural" ? this.onSwipeForward : this.onSwipeBackwards, b.style = M(M({}, b.style), {}, {
1229
- height: this.state.itemSize
1230
- }), E.height = this.state.itemSize;
1231
- return /* @__PURE__ */ y.default.createElement("div", {
1232
- "aria-label": this.props.ariaLabel,
1233
- className: k.default.ROOT(this.props.className),
1234
- ref: this.setCarouselWrapperRef,
1235
- tabIndex: this.props.useKeyboardArrows ? 0 : void 0
1236
- }, /* @__PURE__ */ y.default.createElement("div", {
1237
- className: k.default.CAROUSEL(!0),
1238
- style: {
1239
- width: this.props.width
1240
- }
1241
- }, this.renderControls(), this.props.renderArrowPrev(this.onClickPrev, f, this.props.labels.leftArrow), /* @__PURE__ */ y.default.createElement("div", {
1242
- className: k.default.WRAPPER(!0, this.props.axis),
1243
- style: E
1244
- }, o ? /* @__PURE__ */ y.default.createElement(ht.default, pe({
1245
- tagName: "ul",
1246
- innerRef: this.setListRef
1247
- }, b, {
1248
- allowMouseEvents: this.props.emulateTouch
1249
- }), this.props.infiniteLoop && _, this.renderItems(), this.props.infiniteLoop && v) : /* @__PURE__ */ y.default.createElement("ul", {
1250
- className: k.default.SLIDER(!0, this.state.swiping),
1251
- ref: function(z) {
1252
- return e.setListRef(z);
1253
- },
1254
- style: this.state.itemListStyle || {}
1255
- }, this.props.infiniteLoop && _, this.renderItems(), this.props.infiniteLoop && v)), this.props.renderArrowNext(this.onClickNext, h, this.props.labels.rightArrow), this.renderStatus()), this.renderThumbs());
1256
- }
1257
- }]), r;
1258
- }(y.default.Component);
1259
- ie.default = ye;
1260
- c(ye, "displayName", "Carousel");
1261
- c(ye, "defaultProps", {
1262
- ariaLabel: void 0,
1263
- axis: "horizontal",
1264
- centerSlidePercentage: 80,
1265
- interval: 3e3,
1266
- labels: {
1267
- leftArrow: "previous slide / item",
1268
- rightArrow: "next slide / item",
1269
- item: "slide item"
1270
- },
1271
- onClickItem: H.noop,
1272
- onClickThumb: H.noop,
1273
- onChange: H.noop,
1274
- onSwipeStart: function() {
1275
- },
1276
- onSwipeEnd: function() {
1277
- },
1278
- onSwipeMove: function() {
1279
- return !1;
1280
- },
1281
- preventMovementUntilSwipeScrollTolerance: !1,
1282
- renderArrowPrev: function(n, r, i) {
1283
- return /* @__PURE__ */ y.default.createElement("button", {
1284
- type: "button",
1285
- "aria-label": i,
1286
- className: k.default.ARROW_PREV(!r),
1287
- onClick: n
1288
- });
1289
- },
1290
- renderArrowNext: function(n, r, i) {
1291
- return /* @__PURE__ */ y.default.createElement("button", {
1292
- type: "button",
1293
- "aria-label": i,
1294
- className: k.default.ARROW_NEXT(!r),
1295
- onClick: n
1296
- });
1297
- },
1298
- renderIndicator: function(n, r, i, e) {
1299
- return /* @__PURE__ */ y.default.createElement("li", {
1300
- className: k.default.DOT(r),
1301
- onClick: n,
1302
- onKeyDown: n,
1303
- value: i,
1304
- key: i,
1305
- role: "button",
1306
- tabIndex: 0,
1307
- "aria-label": "".concat(e, " ").concat(i + 1)
1308
- });
1309
- },
1310
- renderItem: function(n) {
1311
- return n;
1312
- },
1313
- renderThumbs: function(n) {
1314
- var r = y.Children.map(n, function(i) {
1315
- var e = i;
1316
- if (i.type !== "img" && (e = y.Children.toArray(i.props.children).find(function(o) {
1317
- return o.type === "img";
1318
- })), !!e)
1319
- return e;
1320
- });
1321
- return r.filter(function(i) {
1322
- return i;
1323
- }).length === 0 ? (console.warn("No images found! Can't build the thumb list without images. If you don't need thumbs, set showThumbs={false} in the Carousel. Note that it's not possible to get images rendered inside custom components. More info at https://github.com/leandrowd/react-responsive-carousel/blob/master/TROUBLESHOOTING.md"), []) : r;
1324
- },
1325
- statusFormatter: H.defaultStatusFormatter,
1326
- selectedItem: 0,
1327
- showArrows: !0,
1328
- showIndicators: !0,
1329
- showStatus: !0,
1330
- showThumbs: !0,
1331
- stopOnHover: !0,
1332
- swipeScrollTolerance: 5,
1333
- swipeable: !0,
1334
- transitionTime: 350,
1335
- verticalSwipe: "standard",
1336
- width: "100%",
1337
- animationHandler: "slide",
1338
- swipeAnimationHandler: Q.slideSwipeAnimationHandler,
1339
- stopSwipingHandler: Q.slideStopSwipingHandler
1340
- });
1341
- var Ot = {};
1342
- (function(t) {
1343
- Object.defineProperty(t, "__esModule", {
1344
- value: !0
1345
- }), Object.defineProperty(t, "Carousel", {
1346
- enumerable: !0,
1347
- get: function() {
1348
- return n.default;
1349
- }
1350
- }), Object.defineProperty(t, "CarouselProps", {
1351
- enumerable: !0,
1352
- get: function() {
1353
- return r.CarouselProps;
1354
- }
1355
- }), Object.defineProperty(t, "Thumbs", {
1356
- enumerable: !0,
1357
- get: function() {
1358
- return i.default;
454
+ }, i.prototype.getState = function() {
455
+ return this.state;
456
+ }, i.prototype.renderLeftArrow = function(t) {
457
+ var e = this, r = this.props, a = r.customLeftArrow, n = r.rtl;
458
+ return T.createElement(st.LeftArrow, { customLeftArrow: a, getState: function() {
459
+ return e.getState();
460
+ }, previous: this.previous, disabled: t, rtl: n });
461
+ }, i.prototype.renderRightArrow = function(t) {
462
+ var e = this, r = this.props, a = r.customRightArrow, n = r.rtl;
463
+ return T.createElement(st.RightArrow, { customRightArrow: a, getState: function() {
464
+ return e.getState();
465
+ }, next: this.next, disabled: t, rtl: n });
466
+ }, i.prototype.renderButtonGroups = function() {
467
+ var t = this, e = this.props.customButtonGroup;
468
+ return e ? T.cloneElement(e, { previous: function() {
469
+ return t.previous();
470
+ }, next: function() {
471
+ return t.next();
472
+ }, goToSlide: function(r, a) {
473
+ return t.goToSlide(r, a);
474
+ }, carouselState: this.getState() }) : null;
475
+ }, i.prototype.renderDotsList = function() {
476
+ var t = this;
477
+ return T.createElement(Ht.default, { state: this.state, props: this.props, goToSlide: this.goToSlide, getState: function() {
478
+ return t.getState();
479
+ } });
480
+ }, i.prototype.renderCarouselItems = function() {
481
+ var t = [];
482
+ if (this.props.infinite) {
483
+ var e = T.Children.toArray(this.props.children);
484
+ t = v.getClones(this.state.slidesToShow, e);
485
+ }
486
+ return T.createElement(te.default, { clones: t, goToSlide: this.goToSlide, state: this.state, notEnoughChildren: v.notEnoughChildren(this.state), props: this.props });
487
+ }, i.prototype.render = function() {
488
+ var t = this.props, e = t.deviceType, r = t.arrows, a = t.renderArrowsWhenDisabled, n = t.removeArrowOnDeviceType, s = t.infinite, l = t.containerClass, u = t.sliderClass, d = t.customTransition, c = t.additionalTransfrom, h = t.renderDotsOutside, p = t.renderButtonGroupOutside, f = t.className, g = t.rtl;
489
+ process.env.NODE_ENV !== "production" && v.throwError(this.state, this.props);
490
+ var w = v.getInitialState(this.state, this.props), b = w.shouldRenderOnSSR, _ = w.shouldRenderAtAll, y = v.isInLeftEnd(this.state), I = v.isInRightEnd(this.state), C = r && !(n && (e && -1 < n.indexOf(e) || this.state.deviceType && -1 < n.indexOf(this.state.deviceType))) && !v.notEnoughChildren(this.state) && _, R = !s && y, D = !s && I, L = j.getTransform(this.state, this.props);
491
+ return T.createElement(T.Fragment, null, T.createElement("div", { className: "react-multi-carousel-list " + l + " " + f, dir: g ? "rtl" : "ltr", ref: this.containerRef }, T.createElement("ul", { ref: this.listRef, className: "react-multi-carousel-track " + u, style: { transition: this.isAnimationAllowed ? d || at : "none", overflow: b ? "hidden" : "unset", transform: "translate3d(" + (L + c) + "px,0,0)" }, onMouseMove: this.handleMove, onMouseDown: this.handleDown, onMouseUp: this.handleOut, onMouseEnter: this.handleEnter, onMouseLeave: this.handleOut, onTouchStart: this.handleDown, onTouchMove: this.handleMove, onTouchEnd: this.handleOut }, this.renderCarouselItems()), C && (!R || a) && this.renderLeftArrow(R), C && (!D || a) && this.renderRightArrow(D), _ && !p && this.renderButtonGroups(), _ && !h && this.renderDotsList()), _ && h && this.renderDotsList(), _ && p && this.renderButtonGroups());
492
+ }, i.defaultProps = { slidesToSlide: 1, infinite: !1, draggable: !0, swipeable: !0, arrows: !0, renderArrowsWhenDisabled: !1, containerClass: "", sliderClass: "", itemClass: "", keyBoardControl: !0, autoPlaySpeed: 3e3, showDots: !1, renderDotsOutside: !1, renderButtonGroupOutside: !1, minimumTouchDrag: 80, className: "", dotListClass: "", focusOnSelect: !1, centerMode: !1, additionalTransfrom: 0, pauseOnHover: !0, shouldResetAutoplay: !0, rewind: !1, rtl: !1, rewindWithAnimation: !1 }, i;
493
+ }(T.Component);
494
+ J.default = ee;
495
+ Object.defineProperty(q, "__esModule", { value: !0 });
496
+ var ie = J;
497
+ q.default = ie.default;
498
+ var oe = q;
499
+ const re = /* @__PURE__ */ mt(oe), ne = yt.div`
500
+ &:hover {
501
+ cursor: pointer;
502
+
503
+ & .react-multiple-carousel__arrow {
504
+ visibility: visible;
1359
505
  }
1360
- });
1361
- var n = e(ie), r = Ot, i = e(j);
1362
- function e(o) {
1363
- return o && o.__esModule ? o : { default: o };
1364
506
  }
1365
- })(Re);
1366
- const Rt = te.div`
1367
- position: relative;
1368
507
 
1369
- & .image-carousel {
1370
- height: 20.625rem;
1371
-
1372
- & img {
1373
- height: 20.625rem;
1374
- }
508
+ & .carousel-slider {
509
+ align-items: center;
510
+ }
1375
511
 
1376
- & .next,
1377
- .previous {
1378
- display: none;
1379
- }
512
+ & .carousel-container {
513
+ padding-bottom: 1.25rem;
1380
514
  }
1381
515
 
1382
- @media (max-width: ${ne + "px"}) {
1383
- & .image-carousel {
1384
- & > div {
1385
- border-radius: unset;
1386
- }
1387
- & img {
1388
- border-radius: unset;
1389
- }
1390
- }
516
+ & .carousel-item {
517
+ padding-right: 0;
1391
518
  }
1392
- `;
1393
- te.div`
1394
- position: absolute;
1395
- top: 0;
1396
- left: 0;
1397
- background: ${(t) => re(t == null ? void 0 : t.backgroundColor) ? t == null ? void 0 : t.backgroundColor : `linear-gradient(
1398
- to top left,
1399
- rgba(0, 0, 0, 0) 85%,
1400
- rgba(0, 0, 0, 1) 100%
1401
- )`};
1402
519
 
1403
- border-radius: 0%.75rem;
520
+ & .react-multiple-carousel__arrow {
521
+ width: 3rem;
522
+ height: 3rem;
523
+ padding: 0.5rem;
524
+ background: rgba(255, 255, 255, 0.8);
525
+ box-shadow: 1px 1px 4px 0 rgba(20, 22, 26, 0.08),
526
+ 0 2px 16px 0 rgba(20, 22, 26, 0.16);
527
+ backdrop-filter: blur(1.25rem);
528
+ visibility: hidden;
529
+
530
+ &::before {
531
+ color: var(--gray-950, #14161a);
532
+ }
1404
533
 
1405
- width: 100%;
1406
- height: 100%;
1407
- padding: 3rem 3rem 5.625rem 3rem;
534
+ &:hover {
535
+ background: rgba(255, 255, 255, 0.5);
536
+ }
537
+ }
1408
538
 
1409
- display: flex;
1410
- flex-direction: column;
1411
- gap: 1rem;
1412
- justify-content: space-between;
539
+ & .react-multiple-carousel__arrow--left {
540
+ left: 1rem;
541
+ }
1413
542
 
1414
- & button {
1415
- width: fit-content;
543
+ & .react-multiple-carousel__arrow--right {
544
+ right: 1rem;
1416
545
  }
1417
546
 
1418
- & .text-area {
1419
- max-width: 31.75rem;
1420
- font-size: 1rem;
547
+ & .section__card {
1421
548
  display: flex;
1422
549
  flex-direction: column;
1423
- gap: 0.5rem;
1424
- color: var(--white);
550
+ justify-content: space-between;
551
+ align-items: flex-start;
552
+ flex: 1 0 0;
553
+ align-self: stretch;
554
+ border-radius: 0.75rem;
555
+ width: 100%;
556
+ height: 22.5rem;
557
+ position: relative;
558
+ overflow: hidden;
1425
559
 
1426
- & .title {
1427
- font-weight: 700;
1428
- font-size: 2rem;
1429
- color: var(--white, #fff);
560
+ & .card__content {
561
+ position: absolute;
562
+ top: 0;
563
+ left: 0;
564
+ padding: 3rem;
565
+ height: 100%;
566
+ display: flex;
567
+ flex-direction: column;
568
+ justify-content: space-between;
1430
569
  }
1431
- }
1432
-
1433
- @media (max-width: ${ne + "px"}) {
1434
- display: none;
1435
- }
1436
- `;
1437
- const Et = te.div`
1438
- position: relative;
1439
- border-radius: 0.75rem;
1440
- cursor: pointer;
1441
570
 
1442
- background: ${(t) => re(t == null ? void 0 : t.backgroundColor) ? t == null ? void 0 : t.backgroundColor : `linear-gradient(
1443
- to top left,
1444
- rgba(0, 0, 0, 0) 85%,
1445
- rgba(0, 0, 0, 1) 100%
1446
- )`};
571
+ & .card__text {
572
+ display: flex;
573
+ flex-direction: column;
574
+ align-items: flex-start;
575
+ gap: 0.25rem;
576
+ }
1447
577
 
1448
- & img {
1449
- object-fit: cover;
1450
- max-height: 20.625rem;
1451
- border-radius: 0.75rem;
1452
- mix-blend-mode: multiply;
1453
- }
578
+ & .card__title {
579
+ color: var(--white, #fff);
580
+ font-size: 1.75rem;
581
+ font-style: normal;
582
+ font-weight: 600;
583
+ line-height: 2.25rem;
584
+ }
1454
585
 
1455
- & .banner-action {
1456
- background: var(--white, #fff);
1457
- color: var(--gray-950, #14161a);
1458
- font-size: 0.875rem;
1459
- font-style: normal;
1460
- font-weight: 500;
1461
- line-height: 1.25rem;
586
+ & .card__description {
587
+ color: var(--white, #fff);
588
+ font-size: 1rem;
589
+ font-style: normal;
590
+ font-weight: 400;
591
+ line-height: 1.5rem;
592
+ }
1462
593
 
1463
- &:hover {
1464
- background: var(--gray-200, #dddfe4);
594
+ & .card__action {
595
+ padding: 0.625rem 0.75rem;
596
+ background: var(--white, #fff);
1465
597
  color: var(--gray-950, #14161a);
598
+ font-size: 0.875rem;
599
+ font-style: normal;
600
+ font-weight: 500;
601
+ line-height: 1.25rem;
602
+ width: fit-content;
1466
603
  }
1467
604
  }
1468
605
 
1469
- @media (max-width: ${ne + "px"}) {
1470
- border-radius: unset;
1471
-
1472
- & img {
1473
- border-radius: unset;
606
+ & .react-multi-carousel-item:not(.react-multi-carousel-item--active) {
607
+ & .section__card {
608
+ height: 22.5rem;
1474
609
  }
1475
610
  }
1476
- `, Tt = te.div`
1477
- border-radius: 0.75rem;
1478
- position: absolute;
1479
- top: 0;
1480
- left: 0;
1481
- height: 100%;
1482
- width: 100%;
1483
- padding: 3rem 0 3rem 3rem;
1484
-
1485
- background: ${(t) => re(t == null ? void 0 : t.backgroundColor) ? t == null ? void 0 : t.backgroundColor : `linear-gradient(
1486
- to top left,
1487
- rgba(0, 0, 0, 0) 85%,
1488
- rgba(0, 0, 0, 1) 100%
1489
- )`};
1490
611
 
1491
- & .banner-content {
1492
- display: flex;
1493
- flex-direction: column;
1494
- gap: 3.5rem;
1495
- width: 45%;
612
+ & .section__image {
613
+ width: 100%;
614
+ height: 100%;
615
+ object-fit: cover;
616
+ display: block;
1496
617
  }
1497
618
 
1498
- & .banner-content button {
1499
- width: fit-content;
1500
- }
619
+ @media (max-width: 768px) {
620
+ & .section__card {
621
+ height: 23.4375rem;
622
+ border-radius: 0.5rem;
1501
623
 
1502
- & .banner-text {
1503
- text-align: left;
1504
- font-size: 1rem;
1505
- display: flex;
1506
- flex-direction: column;
1507
- gap: 0.5rem;
1508
- color: var(--white, #fff);
624
+ & .card__content {
625
+ display: none;
626
+ }
627
+ }
1509
628
 
1510
- & .banner-title {
1511
- font-weight: 700;
1512
- font-size: 2rem;
1513
- color: var(--white, #fff);
629
+ & .react-multi-carousel-item:not(.react-multi-carousel-item--active) {
630
+ & .section__card {
631
+ height: 20.625rem;
632
+ transform: scale(0.95);
633
+ }
1514
634
  }
1515
635
  }
1516
636
 
1517
- @media (max-width: ${ne + "px"}) {
1518
- border-radius: unset;
1519
- background: unset;
1520
-
1521
- & .banner-content {
1522
- display: none;
637
+ @media (max-width: 1024px) {
638
+ & .carousel-item {
639
+ padding-right: 0.5rem;
1523
640
  }
1524
641
  }
1525
- `, It = Ce(
1526
- ({ carouselItems: t = [], onSelectItem: n = () => {
1527
- }, onButtonAction: r = () => {
1528
- } }, i) => /* @__PURE__ */ N(Rt, { ref: i, children: /* @__PURE__ */ N(
1529
- Re.Carousel,
1530
- {
1531
- autoPlay: !0,
1532
- infiniteLoop: !0,
1533
- showArrows: !1,
1534
- showStatus: !1,
1535
- showThumbs: !1,
1536
- transitionTime: 500,
1537
- onClickItem: (e) => {
1538
- n(t == null ? void 0 : t[e]);
642
+ `, se = ft(
643
+ ({ items: o = [], onSelectItem: i = () => {
644
+ }, onButtonAction: t = () => {
645
+ } }, e) => {
646
+ const r = {
647
+ desktop: {
648
+ breakpoint: { max: 3e3, min: 1024 },
649
+ items: 1,
650
+ partialVisibilityGutter: 0
651
+ },
652
+ tablet: {
653
+ breakpoint: { max: 1024, min: 464 },
654
+ items: 1,
655
+ partialVisibilityGutter: 0
1539
656
  },
1540
- children: t && (t == null ? void 0 : t.map((e, o) => /* @__PURE__ */ le(
1541
- Et,
1542
- {
1543
- backgroundColor: e == null ? void 0 : e.backgroundColor,
1544
- children: [
1545
- /* @__PURE__ */ N("img", { loading: "lazy", src: e.imageUrl }),
1546
- /* @__PURE__ */ N(Tt, { backgroundColor: e == null ? void 0 : e.backgroundColor, children: /* @__PURE__ */ le("div", { className: "banner-content", children: [
1547
- /* @__PURE__ */ le("div", { className: "banner-text", children: [
1548
- /* @__PURE__ */ N("div", { className: "banner-title", children: e.title }),
1549
- e.description
1550
- ] }),
1551
- re(e == null ? void 0 : e.buttonText) && /* @__PURE__ */ N(
1552
- De,
657
+ mobile: {
658
+ breakpoint: { max: 464, min: 0 },
659
+ items: 1,
660
+ partialVisibilityGutter: 48
661
+ }
662
+ }, a = gt();
663
+ return /* @__PURE__ */ x(ne, { ref: e, children: /* @__PURE__ */ x(
664
+ re,
665
+ {
666
+ responsive: r,
667
+ removeArrowOnDeviceType: "mobile",
668
+ infinite: !a,
669
+ keyBoardControl: !0,
670
+ autoPlay: !0,
671
+ partialVisible: !0,
672
+ sliderClass: "carousel-slider",
673
+ itemClass: "carousel-item",
674
+ containerClass: "carousel-container",
675
+ children: o == null ? void 0 : o.map((n, s) => /* @__PURE__ */ z(
676
+ "div",
677
+ {
678
+ className: "section__card",
679
+ onClick: () => i(n),
680
+ children: [
681
+ /* @__PURE__ */ x(
682
+ "img",
1553
683
  {
1554
- color: "neutral",
1555
- className: "banner-action",
1556
- onClick: (a) => {
1557
- a == null || a.stopPropagation(), r(e);
1558
- },
1559
- children: e.buttonText
684
+ src: n == null ? void 0 : n.imageUrl,
685
+ alt: `Slide ${s + 1}`,
686
+ className: "section__image"
1560
687
  }
1561
- )
1562
- ] }) })
1563
- ]
1564
- },
1565
- `banner-${o + 1}`
1566
- )))
1567
- }
1568
- ) })
688
+ ),
689
+ /* @__PURE__ */ z("div", { className: "card__content", children: [
690
+ /* @__PURE__ */ z("div", { className: "card__text", children: [
691
+ (n == null ? void 0 : n.title) && /* @__PURE__ */ x("div", { className: "card__title", children: n == null ? void 0 : n.title }),
692
+ (n == null ? void 0 : n.title) && /* @__PURE__ */ x("div", { className: "card__description", children: n == null ? void 0 : n.description })
693
+ ] }),
694
+ (n == null ? void 0 : n.buttonText) && /* @__PURE__ */ x(
695
+ vt,
696
+ {
697
+ text: n == null ? void 0 : n.buttonText,
698
+ className: "card__action",
699
+ size: "medium",
700
+ onClick: (l) => {
701
+ l == null || l.stopPropagation(), t(n);
702
+ }
703
+ }
704
+ )
705
+ ] })
706
+ ]
707
+ },
708
+ `banner-section-carousel-item__${s + 1}`
709
+ ))
710
+ }
711
+ ) }, `banner-section-carousel__${a}`);
712
+ }
1569
713
  );
1570
- It.propTypes = {
1571
- items: Se.array,
1572
- handleClick: Se.func
714
+ se.propTypes = {
715
+ items: U.array,
716
+ onSelectItem: U.func,
717
+ onButtonAction: U.func
1573
718
  };
1574
719
  export {
1575
- It as default
720
+ se as default
1576
721
  };