@telefonica/mistica 14.42.1 → 14.44.0

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.
Files changed (45) hide show
  1. package/css/mistica.css +1 -1
  2. package/dist/accordion.d.ts +0 -2
  3. package/dist/carousel.d.ts +5 -5
  4. package/dist/carousel.js +169 -153
  5. package/dist/cvv-field.js +85 -40
  6. package/dist/feedback.js +36 -36
  7. package/dist/index.d.ts +7 -3
  8. package/dist/index.js +17 -1
  9. package/dist/logo.d.ts +1 -0
  10. package/dist/logo.js +110 -68
  11. package/dist/package-version.js +1 -1
  12. package/dist/popover.css-mistica.js +4 -43
  13. package/dist/popover.css.d.ts +1 -12
  14. package/dist/popover.d.ts +6 -2
  15. package/dist/popover.js +71 -226
  16. package/dist/select.js +176 -172
  17. package/dist/skins/constants.d.ts +1 -0
  18. package/dist/skins/constants.js +4 -1
  19. package/dist/skins/tu.d.ts +47 -0
  20. package/dist/skins/tu.js +362 -0
  21. package/dist/skins/types/index.d.ts +1 -1
  22. package/dist/skins/utils.js +7 -4
  23. package/dist/theme.d.ts +2 -1
  24. package/dist/theme.js +17 -13
  25. package/dist/tooltip.css-mistica.js +15 -6
  26. package/dist/tooltip.css.d.ts +3 -0
  27. package/dist/tooltip.d.ts +15 -1
  28. package/dist/tooltip.js +213 -140
  29. package/dist-es/carousel.js +193 -176
  30. package/dist-es/cvv-field.js +73 -69
  31. package/dist-es/feedback.js +58 -58
  32. package/dist-es/index.js +1744 -1743
  33. package/dist-es/logo.js +128 -89
  34. package/dist-es/package-version.js +1 -1
  35. package/dist-es/popover.css-mistica.js +2 -3
  36. package/dist-es/popover.js +75 -191
  37. package/dist-es/select.js +182 -178
  38. package/dist-es/skins/constants.js +2 -2
  39. package/dist-es/skins/tu.js +345 -0
  40. package/dist-es/skins/utils.js +21 -18
  41. package/dist-es/style.css +1 -1
  42. package/dist-es/theme.js +16 -12
  43. package/dist-es/tooltip.css-mistica.js +2 -2
  44. package/dist-es/tooltip.js +234 -169
  45. package/package.json +4 -4
package/dist/carousel.js CHANGED
@@ -11,31 +11,31 @@ function _export(target, all) {
11
11
  }
12
12
  _export(exports, {
13
13
  Carousel: function() {
14
- return Ot;
14
+ return _t;
15
15
  },
16
- CarouselContextConsummer: function() {
17
- return Gt;
16
+ CarouselContextConsumer: function() {
17
+ return zt;
18
18
  },
19
19
  CarouselContextProvider: function() {
20
- return Wt;
20
+ return Ot;
21
21
  },
22
22
  CenteredCarousel: function() {
23
- return Vt;
23
+ return jt;
24
24
  },
25
25
  IsInsideSlideshowProvider: function() {
26
- return vt;
26
+ return Ct;
27
27
  },
28
28
  PageBullets: function() {
29
29
  return xe;
30
30
  },
31
31
  Slideshow: function() {
32
- return _t;
32
+ return Kt;
33
33
  },
34
34
  useCarouselContext: function() {
35
- return Dt;
35
+ return Vt;
36
36
  },
37
37
  useIsInsideSlideshowContext: function() {
38
- return zt;
38
+ return Ft;
39
39
  }
40
40
  });
41
41
  const _jsxruntime = require("react/jsx-runtime");
@@ -159,10 +159,10 @@ const ve = (e, t)=>{
159
159
  }, xe = (param)=>{
160
160
  let { currentIndex: e, numPages: t, onPress: s } = param;
161
161
  var _t_tablet;
162
- const r = (0, _themevariantcontext.useIsInverseVariant)(), { isDesktopOrBigger: f } = (0, _hooks.useScreenSize)(), h = (i)=>{
163
- const d = i === e;
164
- return r ? d ? _carouselcssmistica.bulletActiveInverse : _carouselcssmistica.bulletInverse : d ? _carouselcssmistica.bulletActive : _carouselcssmistica.bullet;
165
- }, I = typeof t == "number" ? t : Math.max(t.mobile, (_t_tablet = t.tablet) !== null && _t_tablet !== void 0 ? _t_tablet : t.mobile, t.desktop);
162
+ const r = (0, _themevariantcontext.useIsInverseVariant)(), { isDesktopOrBigger: d } = (0, _hooks.useScreenSize)(), h = (i)=>{
163
+ const u = i === e;
164
+ return r ? u ? _carouselcssmistica.bulletActiveInverse : _carouselcssmistica.bulletInverse : u ? _carouselcssmistica.bulletActive : _carouselcssmistica.bullet;
165
+ }, w = typeof t == "number" ? t : Math.max(t.mobile, (_t_tablet = t.tablet) !== null && _t_tablet !== void 0 ? _t_tablet : t.mobile, t.desktop);
166
166
  return /* @__PURE__ */ (0, _jsxruntime.jsx)(_inline.default, {
167
167
  space: 0,
168
168
  alignItems: "center",
@@ -170,62 +170,62 @@ const ve = (e, t)=>{
170
170
  "component-name": "PageBullets"
171
171
  },
172
172
  children: Array.from({
173
- length: I
174
- }, (i, d)=>/* @__PURE__ */ {
173
+ length: w
174
+ }, (i, u)=>/* @__PURE__ */ {
175
175
  var _t_tablet;
176
176
  return (0, _jsxruntime.jsx)(_touchable.BaseTouchable, {
177
177
  className: (0, _classnames.default)(typeof t == "number" ? _carouselcssmistica.bulletButton : {
178
- [_carouselcssmistica.bulletButtonMobile]: d < t.mobile,
179
- [_carouselcssmistica.bulletButtonTablet]: d < ((_t_tablet = t.tablet) !== null && _t_tablet !== void 0 ? _t_tablet : t.mobile),
180
- [_carouselcssmistica.bulletButtonDesktop]: d < t.desktop
178
+ [_carouselcssmistica.bulletButtonMobile]: u < t.mobile,
179
+ [_carouselcssmistica.bulletButtonTablet]: u < ((_t_tablet = t.tablet) !== null && _t_tablet !== void 0 ? _t_tablet : t.mobile),
180
+ [_carouselcssmistica.bulletButtonDesktop]: u < t.desktop
181
181
  }),
182
- style: d === 0 ? {
182
+ style: u === 0 ? {
183
183
  paddingLeft: 0
184
184
  } : {},
185
185
  maybe: !0,
186
- onPress: f && s ? ()=>s(d) : void 0,
186
+ onPress: d && s ? ()=>s(u) : void 0,
187
187
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
188
- className: h(d)
188
+ className: h(u)
189
189
  })
190
- }, d);
190
+ }, u);
191
191
  })
192
192
  });
193
193
  }, oe = ()=>{
194
194
  throw new Error("You must wrap your component with a CarouselContextProvider to use CarouselContext");
195
- }, Ce = oe, Pe = oe, Ie = oe, Me = {
195
+ }, Ce = oe, Pe = oe, we = oe, Ie = {
196
196
  currentIndex: 0,
197
197
  numPages: 0
198
198
  }, se = /*#__PURE__*/ _react.createContext({
199
199
  goPrev: Ce,
200
200
  goNext: Pe,
201
- goToPage: Ie,
202
- bulletsProps: Me
203
- }), re = /*#__PURE__*/ _react.createContext(null), Wt = (param)=>{
201
+ goToPage: we,
202
+ bulletsProps: Ie
203
+ }), re = /*#__PURE__*/ _react.createContext(null), Ot = (param)=>{
204
204
  let { children: e } = param;
205
- const [t, s] = _react.useState(Me), r = _react.useRef(Ce), f = _react.useRef(Pe), h = _react.useRef(Ie), I = _react.useMemo(()=>({
205
+ const [t, s] = _react.useState(Ie), r = _react.useRef(Ce), d = _react.useRef(Pe), h = _react.useRef(we), w = _react.useMemo(()=>({
206
206
  goPrev: ()=>{
207
207
  r.current();
208
208
  },
209
209
  goNext: ()=>{
210
- f.current();
210
+ d.current();
211
211
  },
212
212
  goToPage: function(i) {
213
- let d = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
214
- h.current(i, d);
213
+ let u = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
214
+ h.current(i, u);
215
215
  },
216
216
  bulletsProps: t
217
217
  }), [
218
218
  t
219
219
  ]);
220
220
  return /* @__PURE__ */ (0, _jsxruntime.jsx)(se.Provider, {
221
- value: I,
221
+ value: w,
222
222
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(re.Provider, {
223
223
  value: {
224
224
  setGoPrev: (i)=>{
225
225
  r.current = i;
226
226
  },
227
227
  setGoNext: (i)=>{
228
- f.current = i;
228
+ d.current = i;
229
229
  },
230
230
  setGoToPage: (i)=>{
231
231
  h.current = i;
@@ -235,7 +235,7 @@ const ve = (e, t)=>{
235
235
  children: e
236
236
  })
237
237
  });
238
- }, Dt = ()=>_react.useContext(se), Gt = se.Consumer, ae = (e, t, s)=>s ? typeof s == "number" ? s : s[e] || t[e] : t[e], bt = (e, t)=>{
238
+ }, Vt = ()=>_react.useContext(se), zt = se.Consumer, ae = (e, t, s)=>s ? typeof s == "number" ? s : s[e] || t[e] : t[e], vt = (e, t)=>{
239
239
  const s = {
240
240
  mobile: 1,
241
241
  tablet: 2,
@@ -260,44 +260,44 @@ const ve = (e, t)=>{
260
260
  }, ie = (e, t)=>{
261
261
  if (e.length === 0) return [];
262
262
  const s = Math.ceil(e.length / t), r = [];
263
- for(let f = 0; f < e.length; f += s)r.push(e[f]);
263
+ for(let d = 0; d < e.length; d += s)r.push(e[d]);
264
264
  return r[r.length - 1] = e[e.length - s], r;
265
- }, gt = (e, t)=>{
265
+ }, xt = (e, t)=>{
266
266
  const s = [];
267
267
  for(let r = 0; r < t.length; r++)r === 0 ? s.push(t[0]) : s.push((t[r] + t[r - 1]) / 2);
268
268
  for(let r = s.length - 1; r >= 0; r--)if (e - s[r] >= -1) return r;
269
269
  return 0;
270
- }, we = 5e3, Ne = (param)=>{
271
- let { items: e, itemStyle: t, itemClassName: s, withBullets: r, renderBullets: f, initialActiveItem: h, itemsPerPage: I, itemsToScroll: i, mobilePageOffset: d, gap: C, free: b, centered: S, autoplay: x, onPageChange: A, dataAttributes: y } = param;
272
- const { texts: M, platformOverrides: k, skinName: J } = (0, _hooks.useTheme)(), Q = (0, _desktopcontainertypecontext.useDesktopContainerType)(), a = bt(Q || "large", I), { isDesktopOrBigger: R, isTablet: W } = (0, _hooks.useScreenSize)(), j = W ? a.tablet : a.mobile, P = Math.max(Math.floor(R ? a.desktop : j), 1), l = _react.useRef(null), m = Math.ceil(e.length / Math.max(Math.floor(a.mobile), 1)), v = Math.ceil(e.length / Math.max(Math.floor(a.tablet), 1)), w = Math.ceil(e.length / Math.max(Math.floor(a.desktop), 1)), B = Math.ceil(e.length / P), [{ scrollLeft: D, scrollRight: G }, ke] = _react.useState({
270
+ }, Me = 5e3, Se = (param)=>{
271
+ let { items: e, itemStyle: t, itemClassName: s, withBullets: r, renderBullets: d, initialActiveItem: h, itemsPerPage: w, itemsToScroll: i, mobilePageOffset: u, gap: C, free: b, centered: k, autoplay: x, onPageChange: y, dataAttributes: W } = param;
272
+ const { texts: I, platformOverrides: N, skinName: H } = (0, _hooks.useTheme)(), J = (0, _desktopcontainertypecontext.useDesktopContainerType)(), a = vt(J || "large", w), { isDesktopOrBigger: E, isTablet: A } = (0, _hooks.useScreenSize)(), j = A ? a.tablet : a.mobile, P = Math.max(Math.floor(E ? a.desktop : j), 1), l = _react.useRef(null), m = Math.ceil(e.length / Math.max(Math.floor(a.mobile), 1)), v = Math.ceil(e.length / Math.max(Math.floor(a.tablet), 1)), M = Math.ceil(e.length / Math.max(Math.floor(a.desktop), 1)), R = Math.ceil(e.length / P), [{ scrollLeft: D, scrollRight: G }, Ee] = _react.useState({
273
273
  scrollLeft: 0,
274
274
  scrollRight: 0
275
- }), [X, Re] = _react.useState([]), F = _react.useMemo(()=>ie(X, B), [
276
- X,
277
- B
278
- ]), U = i ? ie(X, Math.ceil(e.length / i)) : F, Be = G !== 0, Te = D !== 0;
275
+ }), [Q, Re] = _react.useState([]), F = _react.useMemo(()=>ie(Q, R), [
276
+ Q,
277
+ R
278
+ ]), K = i ? ie(Q, Math.ceil(e.length / i)) : F, Be = G !== 0, Te = D !== 0;
279
279
  _react.useEffect(()=>{
280
280
  if (l.current) {
281
- const c = l.current, u = ()=>{
282
- const { scrollWidth: q, clientWidth: V } = c, K = Math.round(c.scrollLeft), $ = Math.round(q - (K + V));
283
- ke({
284
- scrollLeft: K,
285
- scrollRight: $
281
+ const c = l.current, f = ()=>{
282
+ const { scrollWidth: Y, clientWidth: V } = c, q = Math.round(c.scrollLeft), Z = Math.round(Y - (q + V));
283
+ Ee({
284
+ scrollLeft: q,
285
+ scrollRight: Z
286
286
  });
287
287
  }, p = ()=>{
288
- const q = c.scrollWidth - c.clientWidth;
289
- Re(Array.from(c.querySelectorAll("[data-item]")).map((V, K)=>{
290
- if (K === e.length - 1) return q;
291
- const $ = V.offsetLeft, Ae = parseInt(getComputedStyle(V).scrollMargin), ye = S && !R ? $ - V.clientWidth / 2 : $;
292
- return Math.min(ye - Ae - c.offsetLeft, q);
288
+ const Y = c.scrollWidth - c.clientWidth;
289
+ Re(Array.from(c.querySelectorAll("[data-item]")).map((V, q)=>{
290
+ if (q === e.length - 1) return Y;
291
+ const Z = V.offsetLeft, We = parseInt(getComputedStyle(V).scrollMargin), Ae = k && !E ? Z - V.clientWidth / 2 : Z;
292
+ return Math.min(Ae - We - c.offsetLeft, Y);
293
293
  }));
294
294
  };
295
- u(), p(), c.addEventListener("scroll", u);
295
+ f(), p(), c.addEventListener("scroll", f);
296
296
  const g = (0, _dom.listenResize)(c, ()=>{
297
- u(), p();
297
+ f(), p();
298
298
  });
299
299
  return ()=>{
300
- c.removeEventListener("scroll", u), g();
300
+ c.removeEventListener("scroll", f), g();
301
301
  };
302
302
  }
303
303
  return ()=>{};
@@ -305,60 +305,60 @@ const ve = (e, t)=>{
305
305
  a.desktop,
306
306
  a.tablet,
307
307
  a.mobile,
308
- B,
309
- C,
310
- S,
311
308
  R,
309
+ C,
310
+ k,
311
+ E,
312
312
  e.length
313
313
  ]);
314
- const T = _react.useCallback(function(c) {
315
- let u = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
314
+ const B = _react.useCallback(function(c) {
315
+ let f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
316
316
  const p = l.current;
317
317
  if (p) {
318
318
  const g = F[c];
319
319
  p.scrollTo({
320
320
  left: g,
321
- behavior: u ? "smooth" : "auto"
321
+ behavior: f ? "smooth" : "auto"
322
322
  });
323
323
  }
324
324
  }, [
325
325
  F
326
- ]), Z = _react.useCallback(()=>{
326
+ ]), X = _react.useCallback(()=>{
327
327
  const c = l.current;
328
328
  if (c) {
329
- const { scrollLeft: u } = c, p = [
330
- ...U
331
- ].reverse().find((g)=>g - u < -1);
329
+ const { scrollLeft: f } = c, p = [
330
+ ...K
331
+ ].reverse().find((g)=>g - f < -1);
332
332
  c.scrollTo({
333
333
  left: p,
334
334
  behavior: "smooth"
335
335
  });
336
336
  }
337
337
  }, [
338
- U
338
+ K
339
339
  ]), O = _react.useCallback(()=>{
340
340
  const c = l.current;
341
341
  if (c) {
342
- const { scrollLeft: u } = c, p = U.find((g)=>g - u > 1);
342
+ const { scrollLeft: f } = c, p = K.find((g)=>g - f > 1);
343
343
  c.scrollTo({
344
344
  left: p,
345
345
  behavior: "smooth"
346
346
  });
347
347
  }
348
348
  }, [
349
- U
349
+ K
350
350
  ]), le = ve(!!x, l);
351
351
  _react.useEffect(()=>{
352
- h !== void 0 && T(Math.floor(h / P), !1);
352
+ h !== void 0 && B(Math.floor(h / P), !1);
353
353
  }, [
354
354
  h,
355
- T,
355
+ B,
356
356
  P
357
357
  ]), _react.useEffect(()=>{
358
358
  if (le && x) {
359
- const c = typeof x == "boolean" ? we : x.time, u = typeof x == "object" && x.loop, p = setInterval(()=>{
359
+ const c = typeof x == "boolean" ? Me : x.time, f = typeof x == "object" && x.loop, p = setInterval(()=>{
360
360
  var g;
361
- G !== 0 ? O() : u && ((g = l.current) == null || g.scrollTo({
361
+ G !== 0 ? O() : f && ((g = l.current) == null || g.scrollTo({
362
362
  left: 0,
363
363
  behavior: "smooth"
364
364
  }));
@@ -371,60 +371,60 @@ const ve = (e, t)=>{
371
371
  G,
372
372
  le
373
373
  ]);
374
- const N = gt(D, F), ne = _react.useRef(!h), ce = _react.useRef(0);
374
+ const S = xt(D, F), ne = _react.useRef(!h), ce = _react.useRef(0);
375
375
  _react.useEffect(()=>{
376
- if (A) {
377
- const c = Math.min((N + 1) * P - 1, e.length - 1), u = [];
376
+ if (y) {
377
+ const c = Math.min((S + 1) * P - 1, e.length - 1), f = [];
378
378
  for(let p = 0; p < P; p++){
379
379
  const g = c - p;
380
- g >= 0 && u.unshift(g);
380
+ g >= 0 && f.unshift(g);
381
381
  }
382
- ne.current ? ce.current !== N && A({
383
- pageIndex: N,
384
- shownItemIndexes: u
385
- }) : ne.current = u.includes(h || 0), ce.current = N;
382
+ ne.current ? ce.current !== S && y({
383
+ pageIndex: S,
384
+ shownItemIndexes: f
385
+ }) : ne.current = f.includes(h || 0), ce.current = S;
386
386
  }
387
387
  }, [
388
- N,
388
+ S,
389
389
  e.length,
390
390
  P,
391
391
  h,
392
- A
392
+ y
393
393
  ]);
394
- const E = _react.useContext(re), ee = _react.useMemo(()=>({
395
- currentIndex: N,
394
+ const T = _react.useContext(re), ee = _react.useMemo(()=>({
395
+ currentIndex: S,
396
396
  numPages: {
397
397
  mobile: m,
398
398
  tablet: v,
399
- desktop: w
399
+ desktop: M
400
400
  }
401
401
  }), [
402
- N,
403
- w,
402
+ S,
403
+ M,
404
404
  m,
405
405
  v
406
406
  ]);
407
407
  _react.useEffect(()=>{
408
- E && (E.setGoPrev(Z), E.setGoNext(O), E.setGoToPage(T), E.setBulletsProps(ee));
408
+ T && (T.setGoPrev(X), T.setGoNext(O), T.setGoToPage(B), T.setBulletsProps(ee));
409
409
  }, [
410
- E,
410
+ T,
411
411
  O,
412
- Z,
412
+ X,
413
413
  ee,
414
- T
414
+ B
415
415
  ]);
416
- let Y = null;
417
- f ? Y = f({
418
- numPages: B,
419
- currentIndex: N,
420
- onPress: T
421
- }) : r && (Y = /* @__PURE__ */ (0, _jsxruntime.jsx)(xe, _object_spread_props(_object_spread({}, ee), {
422
- onPress: T
416
+ let U = null;
417
+ d ? U = d({
418
+ numPages: R,
419
+ currentIndex: S,
420
+ onPress: B
421
+ }) : r && (U = /* @__PURE__ */ (0, _jsxruntime.jsx)(xe, _object_spread_props(_object_spread({}, ee), {
422
+ onPress: B
423
423
  })));
424
- const Ee = "64px", Le = "36px";
424
+ const Le = "64px", ye = "36px";
425
425
  return /* @__PURE__ */ (0, _jsxruntime.jsxs)("div", _object_spread_props(_object_spread({}, (0, _dom.getPrefixedDataAttributes)(_object_spread({
426
426
  "component-name": "Carousel"
427
- }, y))), {
427
+ }, W))), {
428
428
  children: [
429
429
  /* @__PURE__ */ (0, _jsxruntime.jsxs)("div", {
430
430
  className: _carouselcssmistica.carouselContainer,
@@ -433,15 +433,15 @@ const ve = (e, t)=>{
433
433
  isInverse: !1,
434
434
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_touchable.BaseTouchable, {
435
435
  className: _carouselcssmistica.carouselPrevArrowButton,
436
- "aria-label": M.carouselPrevButton,
437
- onPress: Z,
436
+ "aria-label": I.carouselPrevButton,
437
+ onPress: X,
438
438
  disabled: !Te,
439
439
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_iconchevronleftregular.default, {})
440
440
  })
441
441
  }),
442
442
  /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
443
443
  className: (0, _classnames.default)(_carouselcssmistica.carousel, {
444
- [_carouselcssmistica.centeredCarousel]: S,
444
+ [_carouselcssmistica.centeredCarousel]: k,
445
445
  [_carouselcssmistica.carouselWithScrollMobile]: m > 1,
446
446
  [_carouselcssmistica.carouselWithScrollTablet]: v > 1
447
447
  }),
@@ -449,10 +449,10 @@ const ve = (e, t)=>{
449
449
  [_carouselcssmistica.vars.itemsPerPageDesktop]: String(a.desktop),
450
450
  [_carouselcssmistica.vars.itemsPerPageTablet]: String(a.tablet),
451
451
  [_carouselcssmistica.vars.itemsPerPageMobile]: String(a.mobile)
452
- }, d === "large" ? {
453
- [_carouselcssmistica.vars.mobilePageOffset]: Ee
454
- } : J === _constants.VIVO_NEW_SKIN ? {
452
+ }, u === "large" ? {
455
453
  [_carouselcssmistica.vars.mobilePageOffset]: Le
454
+ } : H === _constants.VIVO_NEW_SKIN ? {
455
+ [_carouselcssmistica.vars.mobilePageOffset]: ye
456
456
  } : {}, C !== void 0 ? {
457
457
  [_carouselcssmistica.vars.gap]: String(C)
458
458
  } : {}))), {
@@ -462,23 +462,23 @@ const ve = (e, t)=>{
462
462
  // the bottom of the scrollable area in retina displays when it has a height with
463
463
  // decimals. This extra padding avoids that line to partially cover the carousel
464
464
  // slides border:
465
- paddingBottom: (0, _platform.isIos)(k) && !(0, _platform.isRunningAcceptanceTest)(k) ? 0.5 : void 0
465
+ paddingBottom: (0, _platform.isIos)(N) && !(0, _platform.isRunningAcceptanceTest)(N) ? 0.5 : void 0
466
466
  }),
467
467
  ref: l,
468
- children: e.map((c, u)=>/* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
468
+ children: e.map((c, f)=>/* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
469
469
  className: (0, _classnames.default)(_carouselcssmistica.carouselItem, s),
470
470
  style: _object_spread_props(_object_spread({}, t), {
471
- scrollSnapStop: (0, _platform.isAndroid)(k) ? "always" : "normal"
471
+ scrollSnapStop: (0, _platform.isAndroid)(N) ? "always" : "normal"
472
472
  }),
473
473
  "data-item": !0,
474
474
  children: c
475
- }, u))
475
+ }, f))
476
476
  }),
477
477
  /* @__PURE__ */ (0, _jsxruntime.jsx)(_themevariantcontext.ThemeVariant, {
478
478
  isInverse: !1,
479
479
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_touchable.BaseTouchable, {
480
480
  className: _carouselcssmistica.carouselNextArrowButton,
481
- "aria-label": M.carouselNextButton,
481
+ "aria-label": I.carouselNextButton,
482
482
  onPress: O,
483
483
  disabled: !Be,
484
484
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_iconchevronrightregular.default, {})
@@ -486,19 +486,35 @@ const ve = (e, t)=>{
486
486
  })
487
487
  ]
488
488
  }),
489
- Y && /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
489
+ U && /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
490
490
  className: (0, _classnames.default)(_carouselcssmistica.carouselBullets, {
491
- [_carouselcssmistica.noCarouselBulletsDesktop]: w <= 1,
491
+ [_carouselcssmistica.noCarouselBulletsDesktop]: M <= 1,
492
492
  [_carouselcssmistica.noCarouselBulletsTablet]: v <= 1,
493
493
  [_carouselcssmistica.noCarouselBulletsMobile]: m <= 1
494
494
  }),
495
- children: Y
495
+ children: U
496
496
  })
497
497
  ]
498
498
  }));
499
- }, Ot = (e)=>/* @__PURE__ */ (0, _jsxruntime.jsx)(Ne, _object_spread({}, e)), Vt = (param)=>{
500
- let { items: e, itemStyle: t, itemClassName: s, withBullets: r, renderBullets: f, initialActiveItem: h, onPageChange: I, dataAttributes: i } = param;
501
- return /* @__PURE__ */ (0, _jsxruntime.jsx)(Ne, {
499
+ }, ke = ()=>{
500
+ const [e, t] = _react.useState(1);
501
+ return _react.useEffect(()=>{
502
+ const s = ()=>{
503
+ window.innerWidth !== 0 && (t((r)=>r + 1), window.removeEventListener("resize", s));
504
+ };
505
+ return window.innerWidth === 0 && window.addEventListener("resize", s), ()=>{
506
+ window.removeEventListener("resize", s);
507
+ };
508
+ }, []), e;
509
+ }, _t = (e)=>{
510
+ const t = ke();
511
+ return /* @__PURE__ */ /*#__PURE__*/ (0, _react.createElement)(Se, _object_spread_props(_object_spread({}, e), {
512
+ key: t
513
+ }));
514
+ }, jt = (param)=>{
515
+ let { items: e, itemStyle: t, itemClassName: s, withBullets: r, renderBullets: d, initialActiveItem: h, onPageChange: w, dataAttributes: i } = param;
516
+ const u = ke();
517
+ return /* @__PURE__ */ (0, _jsxruntime.jsx)(Se, {
502
518
  items: e,
503
519
  itemStyle: t,
504
520
  itemClassName: s,
@@ -511,35 +527,35 @@ const ve = (e, t)=>{
511
527
  itemsToScroll: 1,
512
528
  gap: 0,
513
529
  withBullets: r,
514
- renderBullets: f,
530
+ renderBullets: d,
515
531
  initialActiveItem: h,
516
- onPageChange: I,
532
+ onPageChange: w,
517
533
  dataAttributes: i
518
- });
519
- }, Se = /*#__PURE__*/ _react.createContext(!1), zt = ()=>_react.useContext(Se), vt = (param)=>{
534
+ }, u);
535
+ }, Ne = /*#__PURE__*/ _react.createContext(!1), Ft = ()=>_react.useContext(Ne), Ct = (param)=>{
520
536
  let { children: e } = param;
521
- return /* @__PURE__ */ (0, _jsxruntime.jsx)(Se.Provider, {
537
+ return /* @__PURE__ */ (0, _jsxruntime.jsx)(Ne.Provider, {
522
538
  value: !0,
523
539
  children: e
524
540
  });
525
- }, _t = (param)=>{
526
- let { items: e, withBullets: t, autoplay: s, initialPageIndex: r = 0, onPageChange: f, dataAttributes: h, inverseBullets: I = !0 } = param;
527
- const { texts: i, platformOverrides: d } = (0, _hooks.useTheme)(), C = _react.useContext(re), b = _react.useRef(null), [{ scrollLeft: S, scrollRight: x }, A] = _react.useState({
541
+ }, Kt = (param)=>{
542
+ let { items: e, withBullets: t, autoplay: s, initialPageIndex: r = 0, onPageChange: d, dataAttributes: h, inverseBullets: w = !0 } = param;
543
+ const { texts: i, platformOverrides: u } = (0, _hooks.useTheme)(), C = _react.useContext(re), b = _react.useRef(null), [{ scrollLeft: k, scrollRight: x }, y] = _react.useState({
528
544
  scrollLeft: 0,
529
545
  scrollRight: 0
530
- }), y = _react.useCallback(()=>{
546
+ }), W = _react.useCallback(()=>{
531
547
  const l = b.current;
532
548
  l && l.scrollBy({
533
549
  left: -l.clientWidth,
534
550
  behavior: "smooth"
535
551
  });
536
- }, []), M = _react.useCallback(()=>{
552
+ }, []), I = _react.useCallback(()=>{
537
553
  const l = b.current;
538
554
  l && l.scrollBy({
539
555
  left: l.clientWidth,
540
556
  behavior: "smooth"
541
557
  });
542
- }, []), k = _react.useCallback(function(l) {
558
+ }, []), N = _react.useCallback(function(l) {
543
559
  let m = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
544
560
  const v = b.current;
545
561
  v && v.scrollTo({
@@ -548,13 +564,13 @@ const ve = (e, t)=>{
548
564
  });
549
565
  }, [
550
566
  b
551
- ]), J = x !== 0, Q = S !== 0, a = b.current ? Math.floor((S + b.current.clientWidth / 2) / b.current.clientWidth) : 0;
567
+ ]), H = x !== 0, J = k !== 0, a = b.current ? Math.floor((k + b.current.clientWidth / 2) / b.current.clientWidth) : 0;
552
568
  _react.useLayoutEffect(()=>{
553
569
  const l = b.current;
554
570
  if (l) {
555
571
  const m = ()=>{
556
- const { scrollWidth: w, clientWidth: B } = l, D = Math.round(l.scrollLeft), G = Math.round(w - (D + B));
557
- A({
572
+ const { scrollWidth: M, clientWidth: R } = l, D = Math.round(l.scrollLeft), G = Math.round(M - (D + R));
573
+ y({
558
574
  scrollLeft: D,
559
575
  scrollRight: G
560
576
  });
@@ -568,12 +584,12 @@ const ve = (e, t)=>{
568
584
  }, [
569
585
  e.length
570
586
  ]);
571
- const R = ve(!!s, b);
587
+ const E = ve(!!s, b);
572
588
  _react.useEffect(()=>{
573
- if (R && s) {
574
- const l = typeof s == "boolean" ? we : s.time, m = typeof s == "object" && s.loop, v = setInterval(()=>{
575
- var w;
576
- x !== 0 ? M() : m && ((w = b.current) == null || w.scrollTo({
589
+ if (E && s) {
590
+ const l = typeof s == "boolean" ? Me : s.time, m = typeof s == "object" && s.loop, v = setInterval(()=>{
591
+ var M;
592
+ x !== 0 ? I() : m && ((M = b.current) == null || M.scrollTo({
577
593
  left: 0,
578
594
  behavior: "smooth"
579
595
  }));
@@ -582,20 +598,20 @@ const ve = (e, t)=>{
582
598
  }
583
599
  }, [
584
600
  s,
585
- M,
601
+ I,
586
602
  x,
587
- R
603
+ E
588
604
  ]);
589
- const W = _react.useRef(!1), j = _react.useRef(0);
605
+ const A = _react.useRef(!1), j = _react.useRef(0);
590
606
  _react.useEffect(()=>{
591
- f && (W.current ? j.current !== a && f(a) : W.current = r === a), j.current = a;
607
+ d && (A.current ? j.current !== a && d(a) : A.current = r === a), j.current = a;
592
608
  }, [
593
609
  a,
594
610
  r,
595
- f
611
+ d
596
612
  ]), _react.useEffect(()=>{
597
613
  const l = b.current;
598
- r !== void 0 && l && !W.current && l.scrollTo({
614
+ r !== void 0 && l && !A.current && l.scrollTo({
599
615
  left: l.clientWidth * r
600
616
  });
601
617
  }, [
@@ -609,14 +625,14 @@ const ve = (e, t)=>{
609
625
  e.length
610
626
  ]);
611
627
  return _react.useEffect(()=>{
612
- C && (C.setGoPrev(y), C.setGoNext(M), C.setGoToPage(k), C.setBulletsProps(P));
628
+ C && (C.setGoPrev(W), C.setGoNext(I), C.setGoToPage(N), C.setBulletsProps(P));
613
629
  }, [
614
630
  C,
615
- M,
616
- y,
631
+ I,
632
+ W,
617
633
  P,
618
- k
619
- ]), /* @__PURE__ */ (0, _jsxruntime.jsx)(vt, {
634
+ N
635
+ ]), /* @__PURE__ */ (0, _jsxruntime.jsx)(Ct, {
620
636
  children: /* @__PURE__ */ (0, _jsxruntime.jsxs)("div", _object_spread_props(_object_spread({
621
637
  className: _carouselcssmistica.slideshowContainer
622
638
  }, (0, _dom.getPrefixedDataAttributes)(h, "SlideShow")), {
@@ -626,8 +642,8 @@ const ve = (e, t)=>{
626
642
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_touchable.BaseTouchable, {
627
643
  className: _carouselcssmistica.slideshowPrevArrowButton,
628
644
  "aria-label": i.carouselPrevButton,
629
- onPress: y,
630
- disabled: !Q,
645
+ onPress: W,
646
+ disabled: !J,
631
647
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_iconchevronleftregular.default, {})
632
648
  })
633
649
  }),
@@ -641,7 +657,7 @@ const ve = (e, t)=>{
641
657
  children: e.map((l, m)=>/* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
642
658
  className: _carouselcssmistica.slideshowItem,
643
659
  style: {
644
- scrollSnapStop: (0, _platform.isAndroid)(d) ? "always" : "normal"
660
+ scrollSnapStop: (0, _platform.isAndroid)(u) ? "always" : "normal"
645
661
  },
646
662
  children: l
647
663
  }, m))
@@ -652,13 +668,13 @@ const ve = (e, t)=>{
652
668
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_touchable.BaseTouchable, {
653
669
  className: _carouselcssmistica.slideshowNextArrowButton,
654
670
  "aria-label": i.carouselNextButton,
655
- onPress: M,
656
- disabled: !J,
671
+ onPress: I,
672
+ disabled: !H,
657
673
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_iconchevronrightregular.default, {})
658
674
  })
659
675
  }),
660
676
  t && e.length > 1 && /* @__PURE__ */ (0, _jsxruntime.jsx)(_themevariantcontext.ThemeVariant, {
661
- isInverse: I,
677
+ isInverse: w,
662
678
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
663
679
  className: _carouselcssmistica.slideshowBullets,
664
680
  children: /* @__PURE__ */ (0, _jsxruntime.jsx)(xe, _object_spread({}, P))