@20minutes/hela 2.13.0 → 2.13.2

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 (32) hide show
  1. package/dist/index.es.js +2077 -2261
  2. package/dist/index.umd.js +1 -1
  3. package/dist/js/scripts.es.js +134 -132
  4. package/dist/js/scripts.umd.js +1 -1
  5. package/dist/scss/abstracts/variables/_token-variables.scss +1 -1
  6. package/dist/scss/abstracts/variables/_variables.scss +1 -1
  7. package/dist/src/components/atoms/Button/Button.d.ts +1 -1
  8. package/dist/src/components/atoms/Button/Button.stories.d.ts +2 -1
  9. package/dist/src/components/atoms/Link/Link.stories.d.ts +1 -1
  10. package/dist/src/components/atoms/ScrollToTopButton/ScrollToTopButton.stories.d.ts +1 -1
  11. package/dist/src/components/atoms/Slider/Slider.stories.d.ts +1 -1
  12. package/dist/src/components/molecules/Breadcrumb/Breadcrumb.stories.d.ts +0 -1
  13. package/dist/src/components/molecules/Card/Templates/CardWithSummary/CardWithSummary.stories.d.ts +1 -0
  14. package/dist/src/components/molecules/Countdown/Countdown.d.ts +3 -0
  15. package/dist/src/components/molecules/Countdown/Countdown.stories.d.ts +2 -0
  16. package/dist/src/components/molecules/Countdown/CountdownItem/CountdownItem.d.ts +2 -0
  17. package/dist/src/components/molecules/Countdown/CountdownItem/CountdownItem.stories.d.ts +1 -0
  18. package/dist/src/components/molecules/{SearchBanner → Elections/SearchBanner}/SearchBanner.d.ts +2 -2
  19. package/dist/src/components/molecules/{SearchBanner → Elections/SearchBanner}/SearchBanner.stories.d.ts +9 -9
  20. package/dist/src/components/molecules/Elections/index.d.ts +1 -0
  21. package/dist/src/components/molecules/MediaLink/MediaLink.stories.d.ts +1 -1
  22. package/dist/src/components/molecules/SocialBar/SocialBar.stories.d.ts +1 -0
  23. package/dist/src/components/molecules/index.d.ts +1 -2
  24. package/dist/src/constants/tokenVariables.d.ts +21 -36
  25. package/dist/src/types/Window.d.ts +2 -0
  26. package/dist/style.css +1 -1
  27. package/package.json +1 -1
  28. package/dist/src/components/molecules/Events/ElectionsPromoBanner/ElectionsPromoBanner.d.ts +0 -6
  29. package/dist/src/components/molecules/Events/ElectionsPromoBanner/ElectionsPromoBanner.stories.d.ts +0 -11
  30. package/dist/src/components/molecules/Events/ElectionsPromoBanner/index.d.ts +0 -1
  31. package/dist/src/components/molecules/Events/index.d.ts +0 -1
  32. /package/dist/src/components/molecules/{SearchBanner → Elections/SearchBanner}/index.d.ts +0 -0
@@ -1,15 +1,15 @@
1
- const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u" && navigator.userAgent.toLowerCase().includes("firefox"), zt = () => {
1
+ const Ct = () => /Android/i.test(navigator.userAgent), zt = typeof window < "u" && navigator.userAgent.toLowerCase().includes("firefox"), Ot = () => {
2
2
  const s = document.getElementById("js-download-band");
3
- s && Tt() && s.setAttribute(
3
+ s && Ct() && s.setAttribute(
4
4
  "href",
5
5
  "https://app.adjust.com/15shf6wg?campaign=Bandeau_1&deep_link=20minutes%3A%2F%2Fhome"
6
6
  );
7
- }, Ot = () => {
7
+ }, Dt = () => {
8
8
  const s = document.querySelector("#js-election-selector");
9
9
  s && s.addEventListener("change", (t) => {
10
10
  window.location.replace(t.target.value);
11
11
  });
12
- }, Dt = () => {
12
+ }, Mt = () => {
13
13
  const s = document.querySelector(".c-search-banner");
14
14
  if (!s)
15
15
  return;
@@ -22,7 +22,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
22
22
  e.getAttribute("aria-expanded") === "true" ? (e.setAttribute("aria-expanded", "false"), i.setAttribute("aria-hidden", "true")) : (e.setAttribute("aria-expanded", "true"), i.setAttribute("aria-hidden", "false"));
23
23
  });
24
24
  }
25
- }, Mt = [
25
+ }, $t = [
26
26
  {
27
27
  text: "Paris",
28
28
  _index: "town_1717424751904",
@@ -53,7 +53,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
53
53
  url: "/elections/resultats/paris/paris-75011"
54
54
  }
55
55
  }
56
- ], $t = (s, t, e, i, n, o) => {
56
+ ], Rt = (s, t, e, i, n, o) => {
57
57
  const r = document.getElementById(s);
58
58
  if (!r)
59
59
  return;
@@ -63,7 +63,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
63
63
  const d = r.querySelector(".c-autocomplete__input-spinner"), p = l.getAttribute("data-trigger-message"), m = async (g) => {
64
64
  try {
65
65
  let _;
66
- return a && t.includes("20minutes.fr") ? _ = Mt : _ = await (await fetch(`${c}${e}${encodeURIComponent(g)}`)).json(), o ? _[o] : _;
66
+ return a && t.includes("20minutes.fr") ? _ = $t : _ = await (await fetch(`${c}${e}${encodeURIComponent(g)}`)).json(), o ? _[o] : _;
67
67
  } catch (_) {
68
68
  return console.error("Error fetching autocomplete results:", _), [];
69
69
  }
@@ -94,7 +94,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
94
94
  }), l.addEventListener("focusin", () => {
95
95
  h.childElementCount > 0 && h.classList.remove("u-hidden");
96
96
  });
97
- }, Rt = () => {
97
+ }, Ft = () => {
98
98
  const s = document.querySelector(".js-content-header"), t = document.querySelector(".js-limit-scroll-close-article-btn"), e = document.querySelector(".js-close-article-btn"), i = document.querySelector(".c-header-mobile"), n = i instanceof HTMLElement ? i.offsetHeight : 0;
99
99
  if (s && t && e) {
100
100
  const o = new IntersectionObserver(
@@ -116,7 +116,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
116
116
  );
117
117
  t.getAttribute("aria-expanded") === "true" ? (t.setAttribute("aria-expanded", "false"), i?.setAttribute("aria-hidden", "true")) : (t.setAttribute("aria-expanded", "true"), i?.setAttribute("aria-hidden", "false"));
118
118
  }
119
- }, Ft = (s = document.querySelector(
119
+ }, kt = (s = document.querySelector(
120
120
  ".js-collapse__button"
121
121
  )) => {
122
122
  s && document.querySelectorAll(".c-collapse__button").forEach((e) => {
@@ -124,7 +124,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
124
124
  Zt(i);
125
125
  });
126
126
  });
127
- }, kt = (s, t) => {
127
+ }, N = (s, t) => {
128
128
  const e = document.querySelector(
129
129
  `#${t}`
130
130
  );
@@ -134,7 +134,9 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
134
134
  return;
135
135
  window.counters = {
136
136
  paralympicsGames: "2024-08-28 20:00:00",
137
- winterOlympicsGames: "2026-02-06 20:00:00"
137
+ winterOlympicsGames: "2026-02-06 20:00:00",
138
+ eurovision: "2026-05-16 21:00:00",
139
+ worldFoot2026: "2026-06-11 15:00:00"
138
140
  };
139
141
  const a = window.counters[s], l = new Date(a).getTime(), c = setInterval(() => {
140
142
  const h = (/* @__PURE__ */ new Date()).getTime(), d = l - h;
@@ -279,7 +281,7 @@ const Tt = () => /Android/i.test(navigator.userAgent), Ct = typeof window < "u"
279
281
  s && document.querySelectorAll(".js-expand-button").forEach((e) => e.addEventListener("click", Kt));
280
282
  }, Yt = () => {
281
283
  const s = document.querySelector(".js-game-alert");
282
- Ct && s && s.classList.remove("u-hidden");
284
+ zt && s && s.classList.remove("u-hidden");
283
285
  }, Qt = () => {
284
286
  const s = document.querySelectorAll(".js-half-donut-result");
285
287
  for (const t of Array.from(s)) {
@@ -386,7 +388,7 @@ var te = [
386
388
  `[contenteditable]${v.inert}${v.negTabIndex}`,
387
389
  `[tabindex]${v.inert}${v.negTabIndex}`
388
390
  ];
389
- function X(s) {
391
+ function Y(s) {
390
392
  (s.querySelector("[autofocus]") || s).focus();
391
393
  }
392
394
  function ee(s) {
@@ -394,16 +396,16 @@ function ee(s) {
394
396
  return [t, e];
395
397
  }
396
398
  function $(s, t) {
397
- if (t && J(s))
399
+ if (t && tt(s))
398
400
  return s;
399
401
  if (se(s))
400
402
  if (s.shadowRoot) {
401
- let e = Y(s.shadowRoot, t);
403
+ let e = Q(s.shadowRoot, t);
402
404
  for (; e; ) {
403
405
  const i = $(e, t);
404
406
  if (i)
405
407
  return i;
406
- e = Q(e, t);
408
+ e = J(e, t);
407
409
  }
408
410
  } else if (s.localName === "slot") {
409
411
  const e = s.assignedElements({
@@ -416,23 +418,23 @@ function $(s, t) {
416
418
  return n;
417
419
  }
418
420
  } else {
419
- let e = Y(s, t);
421
+ let e = Q(s, t);
420
422
  for (; e; ) {
421
423
  const i = $(e, t);
422
424
  if (i)
423
425
  return i;
424
- e = Q(e, t);
426
+ e = J(e, t);
425
427
  }
426
428
  }
427
- return !t && J(s) ? s : null;
429
+ return !t && tt(s) ? s : null;
428
430
  }
429
- function Y(s, t) {
431
+ function Q(s, t) {
430
432
  return t ? s.firstElementChild : s.lastElementChild;
431
433
  }
432
- function Q(s, t) {
434
+ function J(s, t) {
433
435
  return t ? s.nextElementSibling : s.previousElementSibling;
434
436
  }
435
- const ie = (s) => s.matches("details:not([open]) *") && !s.matches("details>summary:first-of-type") ? !0 : !(s.offsetWidth || s.offsetHeight || s.getClientRects().length), J = (s) => s.shadowRoot?.delegatesFocus ? !1 : s.matches(te.join(",")) && !ie(s);
437
+ const ie = (s) => s.matches("details:not([open]) *") && !s.matches("details>summary:first-of-type") ? !0 : !(s.offsetWidth || s.offsetHeight || s.getClientRects().length), tt = (s) => s.shadowRoot?.delegatesFocus ? !1 : s.matches(te.join(",")) && !ie(s);
436
438
  function se(s) {
437
439
  return s.shadowRoot && s.getAttribute("tabindex") === "-1" ? !1 : !s.matches(":disabled,[hidden],[inert]");
438
440
  }
@@ -451,16 +453,16 @@ function T(s, t) {
451
453
  function e(i) {
452
454
  if (!i || i === document || i === window)
453
455
  return null;
454
- const n = mt(i);
456
+ const n = ft(i);
455
457
  return n && (i = n), i.closest(s) || e(i.getRootNode().host);
456
458
  }
457
459
  return e(t);
458
460
  }
459
- function mt(s) {
460
- return s.assignedSlot || (s.parentNode ? mt(s.parentNode) : null);
461
+ function ft(s) {
462
+ return s.assignedSlot || (s.parentNode ? ft(s.parentNode) : null);
461
463
  }
462
464
  const C = "data-a11y-dialog";
463
- class ft {
465
+ class gt {
464
466
  $el;
465
467
  id;
466
468
  previouslyFocused;
@@ -480,7 +482,7 @@ class ft {
480
482
  * specific key presses and fire all registered callbacks for `show` event
481
483
  */
482
484
  show(t) {
483
- return this.shown ? this : this.fire("show", t).defaultPrevented ? this : (this.shown = !0, this.$el.removeAttribute("aria-hidden"), this.previouslyFocused = R(), this.previouslyFocused?.tagName === "BODY" && t?.target && (this.previouslyFocused = t.target), t?.type === "focus" ? this.maintainFocus() : X(this.$el), document.body.addEventListener("focus", this.maintainFocus, !0), this.$el.addEventListener("keydown", this.bindKeypress, !0), this);
485
+ return this.shown ? this : this.fire("show", t).defaultPrevented ? this : (this.shown = !0, this.$el.removeAttribute("aria-hidden"), this.previouslyFocused = R(), this.previouslyFocused?.tagName === "BODY" && t?.target && (this.previouslyFocused = t.target), t?.type === "focus" ? this.maintainFocus() : Y(this.$el), document.body.addEventListener("focus", this.maintainFocus, !0), this.$el.addEventListener("keydown", this.bindKeypress, !0), this);
484
486
  }
485
487
  /**
486
488
  * Hide the dialog element, restore the focus to the previously active
@@ -544,18 +546,18 @@ class ft {
544
546
  */
545
547
  maintainFocus() {
546
548
  const t = R();
547
- T(`[aria-modal="true"], [${C}-ignore-focus-trap]`, t) || X(this.$el);
549
+ T(`[aria-modal="true"], [${C}-ignore-focus-trap]`, t) || Y(this.$el);
548
550
  }
549
551
  }
550
- function tt() {
552
+ function et() {
551
553
  for (const s of document.querySelectorAll("[data-a11y-dialog]"))
552
- new ft(s);
554
+ new gt(s);
553
555
  }
554
- typeof document < "u" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", tt) : tt());
556
+ typeof document < "u" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", et) : et());
555
557
  const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
556
558
  if (!(s instanceof HTMLElement))
557
559
  return;
558
- const t = new ft(s);
560
+ const t = new gt(s);
559
561
  if (s.id === "dialog-menu") {
560
562
  const e = document.querySelectorAll("button[data-a11y-dialog-show='dialog-menu']"), i = document.querySelectorAll("button[data-a11y-dialog-hide='dialog-menu']");
561
563
  e.length > 0 && i.length > 0 && (t.on("show", () => {
@@ -569,13 +571,13 @@ const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
569
571
  }).on("hide", () => {
570
572
  document.body.classList.remove("noscroll");
571
573
  });
572
- }), gt = "68px", vt = "50px", K = ({
574
+ }), vt = "68px", _t = "50px", X = ({
573
575
  navigationContainer: s,
574
576
  navigatedList: t,
575
577
  nextBtn: e,
576
578
  prevBtn: i
577
579
  }) => {
578
- const n = s.classList.contains("c-breadcrumb--is-small") ? vt : gt;
580
+ const n = s.classList.contains("c-breadcrumb--is-small") ? _t : vt;
579
581
  e.classList.contains("o-nav-button--visible") && !i.classList.contains("o-nav-button--visible") && (s.style.paddingRight = n, s.style.paddingLeft = ""), i.classList.contains("o-nav-button--visible") && (s.style.paddingLeft = n, e.classList.contains("o-nav-button--visible") && (s.style.paddingRight = n), e.classList.contains("o-nav-button--visible") || (s.style.paddingRight = "")), !e.classList.contains("o-nav-button--visible") && !i.classList.contains("o-nav-button--visible") && (t.style.width = "", s.style.paddingRight = "");
580
582
  }, re = ({
581
583
  navigationContainer: s,
@@ -584,7 +586,7 @@ const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
584
586
  prevBtn: i
585
587
  }) => {
586
588
  const n = t.scrollLeft > 0, o = t.scrollLeft + (t.clientWidth + 0.5) < t.scrollWidth;
587
- n && o ? (e.classList?.add("o-nav-button--visible"), i.classList?.add("o-nav-button--visible")) : n ? (e.classList?.remove("o-nav-button--visible"), i.classList?.add("o-nav-button--visible")) : o ? (e.classList?.add("o-nav-button--visible"), i.classList?.remove("o-nav-button--visible")) : (e.classList?.remove("o-nav-button--visible"), i.classList?.remove("o-nav-button--visible")), e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && K({
589
+ n && o ? (e.classList?.add("o-nav-button--visible"), i.classList?.add("o-nav-button--visible")) : n ? (e.classList?.remove("o-nav-button--visible"), i.classList?.add("o-nav-button--visible")) : o ? (e.classList?.add("o-nav-button--visible"), i.classList?.remove("o-nav-button--visible")) : (e.classList?.remove("o-nav-button--visible"), i.classList?.remove("o-nav-button--visible")), e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && X({
588
590
  navigationContainer: s,
589
591
  navigatedList: t,
590
592
  nextBtn: e,
@@ -635,7 +637,7 @@ const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
635
637
  behavior: "smooth"
636
638
  }), e.classList.remove("o-nav-button--visible"), i.classList.add("o-nav-button--visible");
637
639
  }
638
- e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && K({
640
+ e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && X({
639
641
  navigationContainer: s,
640
642
  navigatedList: t,
641
643
  nextBtn: e,
@@ -683,7 +685,7 @@ const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
683
685
  left: 0,
684
686
  behavior: "smooth"
685
687
  }), i.classList.remove("o-nav-button--visible"), t.clientWidth < t.scrollWidth && e.classList.add("o-nav-button--visible");
686
- e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && K({
688
+ e.classList.contains("c-slider__button-container--has-space-around") && i.classList.contains("c-slider__button-container--has-space-around") && X({
687
689
  navigationContainer: s,
688
690
  navigatedList: t,
689
691
  nextBtn: e,
@@ -710,7 +712,7 @@ const oe = () => document.querySelectorAll(".js-modal").forEach((s) => {
710
712
  );
711
713
  if (!(!l || !c || !h)) {
712
714
  if (l.clientWidth < l.scrollWidth && (c.classList.add("o-nav-button--visible"), c.classList.contains("c-slider__button-container--has-space-around"))) {
713
- const d = s.classList.contains("c-breadcrumb--is-small") ? vt : gt;
715
+ const d = s.classList.contains("c-breadcrumb--is-small") ? _t : vt;
714
716
  s.style.paddingRight = d;
715
717
  }
716
718
  if (c.addEventListener(
@@ -794,35 +796,35 @@ function S(s, t, e) {
794
796
  function y(s, t) {
795
797
  return s.x = t.x, s.y = t.y, t.id !== void 0 && (s.id = t.id), s;
796
798
  }
797
- function _t(s) {
799
+ function yt(s) {
798
800
  s.x = Math.round(s.x), s.y = Math.round(s.y);
799
801
  }
800
- function W(s, t) {
802
+ function V(s, t) {
801
803
  const e = Math.abs(s.x - t.x), i = Math.abs(s.y - t.y);
802
804
  return Math.sqrt(e * e + i * i);
803
805
  }
804
- function Z(s, t) {
806
+ function F(s, t) {
805
807
  return s.x === t.x && s.y === t.y;
806
808
  }
807
809
  function k(s, t, e) {
808
810
  return Math.min(Math.max(s, t), e);
809
811
  }
810
- function F(s, t, e) {
812
+ function Z(s, t, e) {
811
813
  let i = `translate3d(${s}px,${t || 0}px,0)`;
812
814
  return e !== void 0 && (i += ` scale3d(${e},${e},1)`), i;
813
815
  }
814
816
  function I(s, t, e, i) {
815
- s.style.transform = F(t, e, i);
817
+ s.style.transform = Z(t, e, i);
816
818
  }
817
819
  const pe = "cubic-bezier(.4,0,.22,1)";
818
- function yt(s, t, e, i) {
820
+ function wt(s, t, e, i) {
819
821
  s.style.transition = t ? `${t} ${e}ms ${i || pe}` : "none";
820
822
  }
821
- function V(s, t, e) {
823
+ function j(s, t, e) {
822
824
  s.style.width = typeof t == "number" ? `${t}px` : t, s.style.height = typeof e == "number" ? `${e}px` : e;
823
825
  }
824
826
  function me(s) {
825
- yt(s);
827
+ wt(s);
826
828
  }
827
829
  function fe(s) {
828
830
  return "decode" in s ? s.decode().catch(() => {
@@ -851,14 +853,14 @@ function ve(s, t, e = document) {
851
853
  }
852
854
  return i;
853
855
  }
854
- function et() {
856
+ function it() {
855
857
  return !!(navigator.vendor && navigator.vendor.match(/apple/i));
856
858
  }
857
- let wt = !1;
859
+ let bt = !1;
858
860
  try {
859
861
  window.addEventListener("test", null, Object.defineProperty({}, "passive", {
860
862
  get: () => {
861
- wt = !0;
863
+ bt = !0;
862
864
  }
863
865
  }));
864
866
  } catch {
@@ -920,7 +922,7 @@ class _e {
920
922
  listener: i,
921
923
  passive: n
922
924
  }));
923
- const h = wt ? {
925
+ const h = bt ? {
924
926
  passive: n || !1
925
927
  } : !1;
926
928
  t[a](c, i, h);
@@ -928,7 +930,7 @@ class _e {
928
930
  });
929
931
  }
930
932
  }
931
- function bt(s, t) {
933
+ function St(s, t) {
932
934
  if (s.getViewportSizeFn) {
933
935
  const e = s.getViewportSizeFn(s, t);
934
936
  if (e)
@@ -955,7 +957,7 @@ function O(s, t, e, i, n) {
955
957
  }
956
958
  return Number(o) || 0;
957
959
  }
958
- function St(s, t, e, i) {
960
+ function Lt(s, t, e, i) {
959
961
  return {
960
962
  x: t.x - O("left", s, t, e, i) - O("right", s, t, e, i),
961
963
  y: t.y - O("top", s, t, e, i) - O("bottom", s, t, e, i)
@@ -1016,8 +1018,8 @@ class ye {
1016
1018
  return k(e, this.max[t], this.min[t]);
1017
1019
  }
1018
1020
  }
1019
- const it = 4e3;
1020
- let Lt = class {
1021
+ const st = 4e3;
1022
+ let Et = class {
1021
1023
  /**
1022
1024
  * @param {PhotoSwipeOptions} options PhotoSwipe options
1023
1025
  * @param {SlideData} itemData Slide data
@@ -1074,7 +1076,7 @@ let Lt = class {
1074
1076
  */
1075
1077
  _getSecondary() {
1076
1078
  let t = this._parseZoomLevelOption("secondary");
1077
- return t || (t = Math.min(1, this.fit * 3), this.elementSize && t * this.elementSize.x > it && (t = it / this.elementSize.x), t);
1079
+ return t || (t = Math.min(1, this.fit * 3), this.elementSize && t * this.elementSize.x > st && (t = st / this.elementSize.x), t);
1078
1080
  }
1079
1081
  /**
1080
1082
  * Get initial image zoom level.
@@ -1110,7 +1112,7 @@ class we {
1110
1112
  }, this.pan = {
1111
1113
  x: 0,
1112
1114
  y: 0
1113
- }, this.isFirstSlide = this.isActive && !i.opener.isOpen, this.zoomLevels = new Lt(i.options, t, e, i), this.pswp.dispatch("gettingData", {
1115
+ }, this.isFirstSlide = this.isActive && !i.opener.isOpen, this.zoomLevels = new Et(i.options, t, e, i), this.pswp.dispatch("gettingData", {
1114
1116
  slide: this,
1115
1117
  data: this.data,
1116
1118
  index: e
@@ -1238,7 +1240,7 @@ class we {
1238
1240
  transitionDuration: i
1239
1241
  }), o.animations.stopAllPan();
1240
1242
  const r = this.currZoomLevel;
1241
- n || (t = k(t, this.zoomLevels.min, this.zoomLevels.max)), this.setZoomLevel(t), this.pan.x = this.calculateZoomToPanOffset("x", e, r), this.pan.y = this.calculateZoomToPanOffset("y", e, r), _t(this.pan);
1243
+ n || (t = k(t, this.zoomLevels.min, this.zoomLevels.max)), this.setZoomLevel(t), this.pan.x = this.calculateZoomToPanOffset("x", e, r), this.pan.y = this.calculateZoomToPanOffset("y", e, r), yt(this.pan);
1242
1244
  const a = () => {
1243
1245
  this._setResolution(t), this.applyCurrentZoomPan();
1244
1246
  };
@@ -1339,14 +1341,14 @@ class we {
1339
1341
  const {
1340
1342
  pswp: t
1341
1343
  } = this;
1342
- y(this.panAreaSize, St(t.options, t.viewportSize, this.data, this.index)), this.zoomLevels.update(this.width, this.height, this.panAreaSize), t.dispatch("calcSlideSize", {
1344
+ y(this.panAreaSize, Lt(t.options, t.viewportSize, this.data, this.index)), this.zoomLevels.update(this.width, this.height, this.panAreaSize), t.dispatch("calcSlideSize", {
1343
1345
  slide: this
1344
1346
  });
1345
1347
  }
1346
1348
  /** @returns {string} */
1347
1349
  getCurrentTransform() {
1348
1350
  const t = this.currZoomLevel / (this.currentResolution || this.zoomLevels.initial);
1349
- return F(this.pan.x, this.pan.y, t);
1351
+ return Z(this.pan.x, this.pan.y, t);
1350
1352
  }
1351
1353
  /**
1352
1354
  * Set resolution and re-render the image.
@@ -1367,7 +1369,7 @@ class we {
1367
1369
  t !== this.currentResolution && (this.currentResolution = t, this.updateContentSize(), this.pswp.dispatch("resolutionChanged"));
1368
1370
  }
1369
1371
  }
1370
- const be = 0.35, Se = 0.6, st = 0.4, nt = 0.5;
1372
+ const be = 0.35, Se = 0.6, nt = 0.4, ot = 0.5;
1371
1373
  function Le(s, t) {
1372
1374
  return s * t / (1 - t);
1373
1375
  }
@@ -1402,7 +1404,7 @@ class Ee {
1402
1404
  this.pswp.applyBgOpacity(r), n.applyCurrentZoomPan();
1403
1405
  }
1404
1406
  } else
1405
- this._panOrMoveMainScroll("x") || (this._panOrMoveMainScroll("y"), n && (_t(n.pan), n.applyCurrentZoomPan()));
1407
+ this._panOrMoveMainScroll("x") || (this._panOrMoveMainScroll("y"), n && (yt(n.pan), n.applyCurrentZoomPan()));
1406
1408
  }
1407
1409
  end() {
1408
1410
  const {
@@ -1414,7 +1416,7 @@ class Ee {
1414
1416
  let n = 0;
1415
1417
  if (this.pswp.animations.stopAll(), e.isShifted()) {
1416
1418
  const r = (e.x - e.getCurrSlideX()) / this.pswp.viewportSize.x;
1417
- t.x < -nt && r < 0 || t.x < 0.1 && r < -0.5 ? (n = 1, t.x = Math.min(t.x, 0)) : (t.x > nt && r > 0 || t.x > -0.1 && r > 0.5) && (n = -1, t.x = Math.max(t.x, 0)), e.moveIndexBy(n, !0, t.x);
1419
+ t.x < -ot && r < 0 || t.x < 0.1 && r < -0.5 ? (n = 1, t.x = Math.min(t.x, 0)) : (t.x > ot && r > 0 || t.x > -0.1 && r > 0.5) && (n = -1, t.x = Math.max(t.x, 0)), e.moveIndexBy(n, !0, t.x);
1418
1420
  }
1419
1421
  i && i.currZoomLevel > i.zoomLevels.max || this.gestures.isMultitouch ? this.gestures.zoomLevels.correctZoomPan(!0) : (this._finishPanGestureForAxis("x"), this._finishPanGestureForAxis("y"));
1420
1422
  }
@@ -1436,7 +1438,7 @@ class Ee {
1436
1438
  } = i, r = n[t], a = this.pswp.bgOpacity < 1 && t === "y", c = r + Le(e[t], 0.995);
1437
1439
  if (a) {
1438
1440
  const f = this._getVerticalDragRatio(r), u = this._getVerticalDragRatio(c);
1439
- if (f < 0 && u < -st || f > 0 && u > st) {
1441
+ if (f < 0 && u < -nt || f > 0 && u > nt) {
1440
1442
  this.pswp.close();
1441
1443
  return;
1442
1444
  }
@@ -1554,7 +1556,7 @@ class Ee {
1554
1556
  }
1555
1557
  }
1556
1558
  const Ae = 0.05, Pe = 0.15;
1557
- function ot(s, t, e) {
1559
+ function rt(s, t, e) {
1558
1560
  return s.x = (t.x + e.x) / 2, s.y = (t.y + e.y) / 2, s;
1559
1561
  }
1560
1562
  class xe {
@@ -1594,8 +1596,8 @@ class xe {
1594
1596
  const a = r.zoomLevels.min, l = r.zoomLevels.max;
1595
1597
  if (!r.isZoomable() || o.mainScroll.isShifted())
1596
1598
  return;
1597
- ot(this._startZoomPoint, e, n), ot(this._zoomPoint, t, i);
1598
- let c = 1 / W(e, n) * W(t, i) * this._startZoomLevel;
1599
+ rt(this._startZoomPoint, e, n), rt(this._zoomPoint, t, i);
1600
+ let c = 1 / V(e, n) * V(t, i) * this._startZoomLevel;
1599
1601
  if (c > r.zoomLevels.initial + r.zoomLevels.initial / 15 && (this._wasOverFitZoomLevel = !0), c < a)
1600
1602
  if (o.options.pinchToClose && !this._wasOverFitZoomLevel && this._startZoomLevel <= r.zoomLevels.initial) {
1601
1603
  const h = 1 - (a - c) / (a / 1.2);
@@ -1660,7 +1662,7 @@ class xe {
1660
1662
  x: i.bounds.correctPan("x", h.x),
1661
1663
  y: i.bounds.correctPan("y", h.y)
1662
1664
  }, i.setZoomLevel(n);
1663
- const d = !Z(h, c);
1665
+ const d = !F(h, c);
1664
1666
  if (!d && !r && !l) {
1665
1667
  i._setResolution(o), i.applyCurrentZoomPan();
1666
1668
  return;
@@ -1688,7 +1690,7 @@ class xe {
1688
1690
  });
1689
1691
  }
1690
1692
  }
1691
- function rt(s) {
1693
+ function at(s) {
1692
1694
  return !!/** @type {HTMLElement} */
1693
1695
  s.target.closest(".pswp__container");
1694
1696
  }
@@ -1715,14 +1717,14 @@ class Ie {
1715
1717
  * @param {PointerEvent} originalEvent
1716
1718
  */
1717
1719
  tap(t, e) {
1718
- rt(e) && this._doClickOrTapAction("tap", t, e);
1720
+ at(e) && this._doClickOrTapAction("tap", t, e);
1719
1721
  }
1720
1722
  /**
1721
1723
  * @param {Point} point
1722
1724
  * @param {PointerEvent} originalEvent
1723
1725
  */
1724
1726
  doubleTap(t, e) {
1725
- rt(e) && this._doClickOrTapAction("doubleTap", t, e);
1727
+ at(e) && this._doClickOrTapAction("doubleTap", t, e);
1726
1728
  }
1727
1729
  /**
1728
1730
  * @private
@@ -1889,7 +1891,7 @@ class Oe {
1889
1891
  * @private
1890
1892
  */
1891
1893
  _rafRenderLoop() {
1892
- (this.isDragging || this.isZooming) && (this._updateVelocity(), this.isDragging ? Z(this.p1, this.prevP1) || this.drag.change() : (!Z(this.p1, this.prevP1) || !Z(this.p2, this.prevP2)) && this.zoomLevels.change(), this._updatePrevPoints(), this.raf = requestAnimationFrame(this._rafRenderLoop.bind(this)));
1894
+ (this.isDragging || this.isZooming) && (this._updateVelocity(), this.isDragging ? F(this.p1, this.prevP1) || this.drag.change() : (!F(this.p1, this.prevP1) || !F(this.p2, this.prevP2)) && this.zoomLevels.change(), this._updatePrevPoints(), this.raf = requestAnimationFrame(this._rafRenderLoop.bind(this)));
1893
1895
  }
1894
1896
  /**
1895
1897
  * Update velocity at 50ms interval
@@ -1920,7 +1922,7 @@ class Oe {
1920
1922
  return;
1921
1923
  }
1922
1924
  const i = this.pswp.options.doubleTapAction ? Ce : 0;
1923
- this._tapTimer ? (this._clearTapTimer(), W(this._lastStartP1, this.startP1) < ze && this.tapHandler.doubleTap(this.startP1, t)) : (y(this._lastStartP1, this.startP1), this._tapTimer = setTimeout(() => {
1925
+ this._tapTimer ? (this._clearTapTimer(), V(this._lastStartP1, this.startP1) < ze && this.tapHandler.doubleTap(this.startP1, t)) : (y(this._lastStartP1, this.startP1), this._tapTimer = setTimeout(() => {
1924
1926
  this.tapHandler.tap(this.startP1, t), this._clearTapTimer();
1925
1927
  }, i));
1926
1928
  }
@@ -2293,8 +2295,8 @@ class Re {
2293
2295
  ) && e.focus();
2294
2296
  }
2295
2297
  }
2296
- const Ze = "cubic-bezier(.4,0,.22,1)";
2297
- class Fe {
2298
+ const Fe = "cubic-bezier(.4,0,.22,1)";
2299
+ class Ze {
2298
2300
  /**
2299
2301
  * onComplete can be unpredictable, be careful about current state
2300
2302
  *
@@ -2310,12 +2312,12 @@ class Fe {
2310
2312
  onFinish: r = () => {
2311
2313
  },
2312
2314
  duration: a = 333,
2313
- easing: l = Ze
2315
+ easing: l = Fe
2314
2316
  } = t;
2315
2317
  this.onFinish = r;
2316
2318
  const c = o ? "transform" : "opacity", h = (e = t[c]) !== null && e !== void 0 ? e : "";
2317
2319
  this._target = i, this._onComplete = n, this._finished = !1, this._onTransitionEnd = this._onTransitionEnd.bind(this), this._helperTimeout = setTimeout(() => {
2318
- yt(i, c, a, l), this._helperTimeout = setTimeout(() => {
2320
+ wt(i, c, a, l), this._helperTimeout = setTimeout(() => {
2319
2321
  i.addEventListener("transitionend", this._onTransitionEnd, !1), i.addEventListener("transitioncancel", this._onTransitionEnd, !1), this._helperTimeout = setTimeout(() => {
2320
2322
  this._finalizeAnimation();
2321
2323
  }, a + 500), i.style[c] = h;
@@ -2436,7 +2438,7 @@ class Ne {
2436
2438
  const i = e ? new He(
2437
2439
  /** @type SpringAnimationProps */
2438
2440
  t
2439
- ) : new Fe(
2441
+ ) : new Ze(
2440
2442
  /** @type CssAnimationProps */
2441
2443
  t
2442
2444
  );
@@ -2573,7 +2575,7 @@ class je {
2573
2575
  c === "bar" ? (t.topBar || (t.topBar = S("pswp__top-bar pswp__hide-on-close", "div", t.scrollWrap)), h = t.topBar) : (l.classList.add("pswp__hide-on-close"), c === "wrapper" && (h = t.scrollWrap)), (i = h) === null || i === void 0 || i.appendChild(t.applyFilters("uiElement", l, e));
2574
2576
  }
2575
2577
  }
2576
- function Et(s, t, e) {
2578
+ function At(s, t, e) {
2577
2579
  s.classList.add("pswp__button--arrow"), s.setAttribute("aria-controls", "pswp__items"), t.on("change", () => {
2578
2580
  t.options.loop || (e ? s.disabled = !(t.currIndex < t.getNumItems() - 1) : s.disabled = !(t.currIndex > 0));
2579
2581
  });
@@ -2592,7 +2594,7 @@ const Ue = {
2592
2594
  outlineID: "pswp__icn-arrow"
2593
2595
  },
2594
2596
  onClick: "prev",
2595
- onInit: Et
2597
+ onInit: At
2596
2598
  }, Ge = {
2597
2599
  name: "arrowNext",
2598
2600
  className: "pswp__button--arrow--next",
@@ -2608,7 +2610,7 @@ const Ue = {
2608
2610
  },
2609
2611
  onClick: "next",
2610
2612
  onInit: (s, t) => {
2611
- Et(s, t, !0);
2613
+ At(s, t, !0);
2612
2614
  }
2613
2615
  }, Ke = {
2614
2616
  name: "close",
@@ -2673,7 +2675,7 @@ const Ue = {
2673
2675
  });
2674
2676
  }
2675
2677
  };
2676
- function at(s, t) {
2678
+ function lt(s, t) {
2677
2679
  s.classList.toggle("pswp--zoomed-in", t);
2678
2680
  }
2679
2681
  class Je {
@@ -2723,12 +2725,12 @@ class Je {
2723
2725
  this._lastUpdatedZoomLevel = n;
2724
2726
  const o = e.zoomLevels.initial - e.zoomLevels.secondary;
2725
2727
  if (Math.abs(o) < 0.01 || !e.isZoomable()) {
2726
- at(t, !1), t.classList.remove("pswp--zoom-allowed");
2728
+ lt(t, !1), t.classList.remove("pswp--zoom-allowed");
2727
2729
  return;
2728
2730
  }
2729
2731
  t.classList.add("pswp--zoom-allowed");
2730
2732
  const r = n === e.zoomLevels.initial ? e.zoomLevels.secondary : e.zoomLevels.initial;
2731
- at(t, r <= n), (i.imageClickAction === "zoom" || i.imageClickAction === "zoom-or-close") && t.classList.add("pswp--click-to-zoom");
2733
+ lt(t, r <= n), (i.imageClickAction === "zoom" || i.imageClickAction === "zoom-or-close") && t.classList.add("pswp--click-to-zoom");
2732
2734
  }
2733
2735
  }
2734
2736
  function ti(s) {
@@ -2877,7 +2879,7 @@ let si = class {
2877
2879
  * @param {number} height
2878
2880
  */
2879
2881
  setDisplayedSize(t, e) {
2880
- this.element && (this.element.tagName === "IMG" ? (V(this.element, 250, "auto"), this.element.style.transformOrigin = "0 0", this.element.style.transform = F(0, 0, t / 250)) : V(this.element, t, e));
2882
+ this.element && (this.element.tagName === "IMG" ? (j(this.element, 250, "auto"), this.element.style.transformOrigin = "0 0", this.element.style.transform = Z(0, 0, t / 250)) : j(this.element, t, e));
2881
2883
  }
2882
2884
  destroy() {
2883
2885
  var t;
@@ -3006,7 +3008,7 @@ let si = class {
3006
3008
  content: this,
3007
3009
  width: t,
3008
3010
  height: e
3009
- }).defaultPrevented && (V(this.element, t, e), this.isImageContent() && !this.isError()))) {
3011
+ }).defaultPrevented && (j(this.element, t, e), this.isImageContent() && !this.isError()))) {
3010
3012
  const i = !this.displayedImageWidth && t;
3011
3013
  this.displayedImageWidth = t, this.displayedImageHeight = e, i ? this.loadImage(!1) : this.updateSrcsetSizes(), this.slide && this.instance.dispatch("imageSizeChange", {
3012
3014
  slide: this.slide,
@@ -3088,7 +3090,7 @@ let si = class {
3088
3090
  }).defaultPrevented)
3089
3091
  return;
3090
3092
  const t = "decode" in this.element;
3091
- this.isImageContent() ? t && this.slide && (!this.slide.isActive || et()) ? (this.isDecoding = !0, this.element.decode().catch(() => {
3093
+ this.isImageContent() ? t && this.slide && (!this.slide.isActive || it()) ? (this.isDecoding = !0, this.element.decode().catch(() => {
3092
3094
  }).finally(() => {
3093
3095
  this.isDecoding = !1, this.appendImage();
3094
3096
  })) : this.appendImage() : this.slide && !this.element.parentNode && this.slide.container.appendChild(this.element);
@@ -3101,7 +3103,7 @@ let si = class {
3101
3103
  activate() {
3102
3104
  this.instance.dispatch("contentActivate", {
3103
3105
  content: this
3104
- }).defaultPrevented || !this.slide || (this.isImageContent() && this.isDecoding && !et() ? this.appendImage() : this.isError() && this.load(!1, !0), this.slide.holderElement && this.slide.holderElement.setAttribute("aria-hidden", "false"));
3106
+ }).defaultPrevented || !this.slide || (this.isImageContent() && this.isDecoding && !it() ? this.appendImage() : this.isError() && this.load(!1, !0), this.slide.holderElement && this.slide.holderElement.setAttribute("aria-hidden", "false"));
3105
3107
  }
3106
3108
  /**
3107
3109
  * Deactivate the content
@@ -3129,17 +3131,17 @@ let si = class {
3129
3131
  }
3130
3132
  };
3131
3133
  const ai = 5;
3132
- function At(s, t, e) {
3134
+ function Pt(s, t, e) {
3133
3135
  const i = t.createContentFromData(s, e);
3134
3136
  let n;
3135
3137
  const {
3136
3138
  options: o
3137
3139
  } = t;
3138
3140
  if (o) {
3139
- n = new Lt(o, s, -1);
3141
+ n = new Et(o, s, -1);
3140
3142
  let r;
3141
- t.pswp ? r = t.pswp.viewportSize : r = bt(o, t);
3142
- const a = St(o, r, s, e);
3143
+ t.pswp ? r = t.pswp.viewportSize : r = St(o, t);
3144
+ const a = Lt(o, r, s, e);
3143
3145
  n.update(i.width, i.height, a);
3144
3146
  }
3145
3147
  return i.lazyLoad(), n && i.setDisplayedSize(Math.ceil(i.width * n.initial), Math.ceil(i.height * n.initial)), i;
@@ -3150,7 +3152,7 @@ function li(s, t) {
3150
3152
  index: s,
3151
3153
  itemData: e
3152
3154
  }).defaultPrevented)
3153
- return At(e, t, s);
3155
+ return Pt(e, t, s);
3154
3156
  }
3155
3157
  class ci {
3156
3158
  /**
@@ -3315,7 +3317,7 @@ let hi = class extends ni {
3315
3317
  * @returns {Content} Image that is being decoded or false.
3316
3318
  */
3317
3319
  lazyLoadData(t, e) {
3318
- return At(t, this, e);
3320
+ return Pt(t, this, e);
3319
3321
  }
3320
3322
  };
3321
3323
  const z = 3e-3;
@@ -3435,7 +3437,7 @@ class di {
3435
3437
  } = e;
3436
3438
  if (this._croppedZoom && i && this._cropContainer1 && this._cropContainer2) {
3437
3439
  const r = -o.x + (this._thumbBounds.x - i.x) + i.w, a = -o.y + (this._thumbBounds.y - i.y) + i.h, l = o.x - i.w, c = o.y - i.h;
3438
- t ? (this._animateTo(this._cropContainer1, "transform", F(r, a)), this._animateTo(this._cropContainer2, "transform", F(l, c))) : (I(this._cropContainer1, r, a), I(this._cropContainer2, l, c));
3440
+ t ? (this._animateTo(this._cropContainer1, "transform", Z(r, a)), this._animateTo(this._cropContainer2, "transform", Z(l, c))) : (I(this._cropContainer1, r, a), I(this._cropContainer2, l, c));
3439
3441
  }
3440
3442
  n && (y(n.pan, i || this._thumbBounds), n.currZoomLevel = this._thumbBounds.w / n.width, t ? this._animateTo(n.container, "transform", n.getCurrentTransform()) : n.applyCurrentZoomPan());
3441
3443
  }
@@ -3649,8 +3651,8 @@ class pi extends hi {
3649
3651
  updateSize(t) {
3650
3652
  if (this.isDestroying)
3651
3653
  return;
3652
- const e = bt(this.options, this);
3653
- !t && Z(e, this._prevViewportSize) || (y(this._prevViewportSize, e), this.dispatch("beforeResize"), y(this.viewportSize, this._prevViewportSize), this._updatePageScrollOffset(), this.dispatch("viewportSize"), this.mainScroll.resize(this.opener.isOpen), !this.hasMouse && window.matchMedia("(any-hover: hover)").matches && this.mouseDetected(), this.dispatch("resize"));
3654
+ const e = St(this.options, this);
3655
+ !t && F(e, this._prevViewportSize) || (y(this._prevViewportSize, e), this.dispatch("beforeResize"), y(this.viewportSize, this._prevViewportSize), this._updatePageScrollOffset(), this.dispatch("viewportSize"), this.mainScroll.resize(this.opener.isOpen), !this.hasMouse && window.matchMedia("(any-hover: hover)").matches && this.mouseDetected(), this.dispatch("resize"));
3654
3656
  }
3655
3657
  /**
3656
3658
  * @param {number} opacity
@@ -3741,7 +3743,7 @@ function mi(s, t, e) {
3741
3743
  let i = `translate3d(${s}px,0px,0)`;
3742
3744
  return e !== void 0 && (i += ` scale3d(${e},${e},1)`), i;
3743
3745
  }
3744
- function j(s, t, e) {
3746
+ function U(s, t, e) {
3745
3747
  s.style.width = typeof t == "number" ? `${t}px` : t, s.style.height = typeof e == "number" ? `${e}px` : e;
3746
3748
  }
3747
3749
  const E = {
@@ -3768,7 +3770,7 @@ function M(s, t, e = document) {
3768
3770
  function gi(s) {
3769
3771
  return typeof s == "function" && s.prototype && s.prototype.goTo;
3770
3772
  }
3771
- function lt() {
3773
+ function ct() {
3772
3774
  return !!(navigator.vendor && navigator.vendor.match(/apple/i));
3773
3775
  }
3774
3776
  class vi {
@@ -3877,7 +3879,7 @@ class yi {
3877
3879
  * @param {number} height
3878
3880
  */
3879
3881
  setDisplayedSize(t, e) {
3880
- this.element && (this.element.tagName === "IMG" ? (j(this.element, 250, "auto"), this.element.style.transformOrigin = "0 0", this.element.style.transform = mi(0, 0, t / 250)) : j(this.element, t, e));
3882
+ this.element && (this.element.tagName === "IMG" ? (U(this.element, 250, "auto"), this.element.style.transformOrigin = "0 0", this.element.style.transform = mi(0, 0, t / 250)) : U(this.element, t, e));
3881
3883
  }
3882
3884
  destroy() {
3883
3885
  var t;
@@ -4007,7 +4009,7 @@ class wi {
4007
4009
  content: this,
4008
4010
  width: t,
4009
4011
  height: e
4010
- }).defaultPrevented && (j(this.element, t, e), this.isImageContent() && !this.isError()))) {
4012
+ }).defaultPrevented && (U(this.element, t, e), this.isImageContent() && !this.isError()))) {
4011
4013
  const i = !this.displayedImageWidth && t;
4012
4014
  this.displayedImageWidth = t, this.displayedImageHeight = e, i ? this.loadImage(!1) : this.updateSrcsetSizes(), this.slide && this.instance.dispatch("imageSizeChange", {
4013
4015
  slide: this.slide,
@@ -4089,7 +4091,7 @@ class wi {
4089
4091
  }).defaultPrevented)
4090
4092
  return;
4091
4093
  const t = "decode" in this.element;
4092
- this.isImageContent() ? t && this.slide && (!this.slide.isActive || lt()) ? (this.isDecoding = !0, this.element.decode().catch(() => {
4094
+ this.isImageContent() ? t && this.slide && (!this.slide.isActive || ct()) ? (this.isDecoding = !0, this.element.decode().catch(() => {
4093
4095
  }).finally(() => {
4094
4096
  this.isDecoding = !1, this.appendImage();
4095
4097
  })) : this.appendImage() : this.slide && !this.element.parentNode && this.slide.container.appendChild(this.element);
@@ -4102,7 +4104,7 @@ class wi {
4102
4104
  activate() {
4103
4105
  this.instance.dispatch("contentActivate", {
4104
4106
  content: this
4105
- }).defaultPrevented || !this.slide || (this.isImageContent() && this.isDecoding && !lt() ? this.appendImage() : this.isError() && this.load(!1, !0), this.slide.holderElement && this.slide.holderElement.setAttribute("aria-hidden", "false"));
4107
+ }).defaultPrevented || !this.slide || (this.isImageContent() && this.isDecoding && !ct() ? this.appendImage() : this.isError() && this.load(!1, !0), this.slide.holderElement && this.slide.holderElement.setAttribute("aria-hidden", "false"));
4106
4108
  }
4107
4109
  /**
4108
4110
  * Deactivate the content
@@ -4162,7 +4164,7 @@ function Si(s, t, e, i) {
4162
4164
  y: t.y - q("top", s, t, e, i) - q("bottom", s, t, e, i)
4163
4165
  };
4164
4166
  }
4165
- const ct = 4e3;
4167
+ const ht = 4e3;
4166
4168
  class Li {
4167
4169
  /**
4168
4170
  * @param {PhotoSwipeOptions} options PhotoSwipe options
@@ -4220,7 +4222,7 @@ class Li {
4220
4222
  */
4221
4223
  _getSecondary() {
4222
4224
  let t = this._parseZoomLevelOption("secondary");
4223
- return t || (t = Math.min(1, this.fit * 3), this.elementSize && t * this.elementSize.x > ct && (t = ct / this.elementSize.x), t);
4225
+ return t || (t = Math.min(1, this.fit * 3), this.elementSize && t * this.elementSize.x > ht && (t = ht / this.elementSize.x), t);
4224
4226
  }
4225
4227
  /**
4226
4228
  * Get initial image zoom level.
@@ -4243,7 +4245,7 @@ class Li {
4243
4245
  return this._parseZoomLevelOption("max") || Math.max(1, this.fit * 4);
4244
4246
  }
4245
4247
  }
4246
- function Pt(s, t, e) {
4248
+ function xt(s, t, e) {
4247
4249
  const i = t.createContentFromData(s, e);
4248
4250
  let n;
4249
4251
  const {
@@ -4264,7 +4266,7 @@ function Ei(s, t) {
4264
4266
  index: s,
4265
4267
  itemData: e
4266
4268
  }).defaultPrevented)
4267
- return Pt(e, t, s);
4269
+ return xt(e, t, s);
4268
4270
  }
4269
4271
  class Ai extends _i {
4270
4272
  /**
@@ -4357,7 +4359,7 @@ class Ai extends _i {
4357
4359
  * @returns {Content} Image that is being decoded or false.
4358
4360
  */
4359
4361
  lazyLoadData(t, e) {
4360
- return Pt(t, this, e);
4362
+ return xt(t, this, e);
4361
4363
  }
4362
4364
  }
4363
4365
  class Pi extends Ai {
@@ -4572,7 +4574,7 @@ const xi = () => {
4572
4574
  });
4573
4575
  };
4574
4576
  window.addEventListener("scroll", r), i.addEventListener("click", a), r();
4575
- }, N = "#page-content", U = "#text-tooltip", zi = ".tooltip-btn", xt = "c-text-tooltip--show", Oi = [
4577
+ }, W = "#page-content", G = "#text-tooltip", zi = ".tooltip-btn", It = "c-text-tooltip--show", Oi = [
4576
4578
  "#page-content .c-content p",
4577
4579
  "#page-content .c-content h2",
4578
4580
  "#page-content .c-content h3",
@@ -4584,17 +4586,17 @@ const xi = () => {
4584
4586
  "#page-content header span",
4585
4587
  "#page-content header h1",
4586
4588
  "#page-content header h2"
4587
- ], ht = (s, t) => s instanceof Element ? t.some((e) => s.matches(e)) : !1, Di = (s, t) => {
4589
+ ], dt = (s, t) => s instanceof Element ? t.some((e) => s.matches(e)) : !1, Di = (s, t) => {
4588
4590
  const e = s.startContainer.nodeType === Node.ELEMENT_NODE ? s.startContainer : s.startContainer.parentElement, i = s.endContainer.nodeType === Node.ELEMENT_NODE ? s.endContainer : s.endContainer.parentElement;
4589
- return !!e && ht(e, t) || !!i && ht(i, t);
4591
+ return !!e && dt(e, t) || !!i && dt(i, t);
4590
4592
  }, Mi = (s) => {
4591
4593
  if (!s.focusNode)
4592
4594
  return null;
4593
4595
  const t = s.anchorNode?.compareDocumentPosition(s.focusNode);
4594
4596
  return t ? (t & 4) > 0 : s.anchorOffset < s.focusOffset;
4595
4597
  }, $i = (s, t, e) => {
4596
- const i = document.querySelector(`${N} ${U}`), n = document.querySelector(`${N}`), o = document.querySelectorAll(
4597
- `${N} ${U} ${zi}`
4598
+ const i = document.querySelector(`${W} ${G}`), n = document.querySelector(`${W}`), o = document.querySelectorAll(
4599
+ `${W} ${G} ${zi}`
4598
4600
  );
4599
4601
  if (!i || !n) {
4600
4602
  console.warn("Text tooltip : Tooltip or it's parent are not found in the DOM");
@@ -4602,14 +4604,14 @@ const xi = () => {
4602
4604
  }
4603
4605
  Array.from(o).forEach((l) => l.setAttribute("data-selected-text", e));
4604
4606
  const r = s.getClientRects(), a = r[t ? r.length - 1 : 0];
4605
- i.style.top = `${a.top - n.getBoundingClientRect().top - (i.offsetHeight + 10)}px`, a.width < i.offsetWidth ? i.style.left = `${a.left - n.getBoundingClientRect().left + a.width / 2 - i.offsetWidth / 2}px` : t ? i.style.left = `${a.left - n.getBoundingClientRect().left + a.width - i.offsetWidth}px` : i.style.left = `${a.left - n.getBoundingClientRect().left}px`, i.classList.add(xt);
4606
- }, dt = () => {
4607
- const s = document.querySelector(`${U}`);
4608
- s && s.classList.remove(xt);
4607
+ i.style.top = `${a.top - n.getBoundingClientRect().top - (i.offsetHeight + 10)}px`, a.width < i.offsetWidth ? i.style.left = `${a.left - n.getBoundingClientRect().left + a.width / 2 - i.offsetWidth / 2}px` : t ? i.style.left = `${a.left - n.getBoundingClientRect().left + a.width - i.offsetWidth}px` : i.style.left = `${a.left - n.getBoundingClientRect().left}px`, i.classList.add(It);
4608
+ }, ut = () => {
4609
+ const s = document.querySelector(`${G}`);
4610
+ s && s.classList.remove(It);
4609
4611
  }, B = ({ type: s }) => {
4610
4612
  const t = window.getSelection();
4611
4613
  if (s === "selectionchange") {
4612
- dt();
4614
+ ut();
4613
4615
  return;
4614
4616
  }
4615
4617
  if (!t || !t.rangeCount)
@@ -4620,24 +4622,24 @@ const xi = () => {
4620
4622
  n && $i(e, o, i);
4621
4623
  return;
4622
4624
  }
4623
- dt();
4625
+ ut();
4624
4626
  }, Ri = () => {
4625
4627
  if (!window?.getSelection) {
4626
4628
  console.warn("Selection API isn't supported");
4627
4629
  return;
4628
4630
  }
4629
4631
  document.addEventListener("mouseup", B), document.addEventListener("selectionchange", B), document.addEventListener("touchend", B), document.addEventListener("touchcancel", B);
4630
- }, Zi = (s) => {
4632
+ }, Fi = (s) => {
4631
4633
  const { target: t } = s;
4632
4634
  if (t instanceof Element) {
4633
4635
  const e = t.closest(".c-search-form--button");
4634
4636
  e && (s.preventDefault(), e.classList.remove("c-search-form--button"));
4635
4637
  }
4636
- }, Fi = (s = document.querySelector(
4638
+ }, Zi = (s = document.querySelector(
4637
4639
  ".c-search-form--button"
4638
4640
  )) => {
4639
4641
  s && s.addEventListener("click", (t) => {
4640
- Zi(t);
4642
+ Fi(t);
4641
4643
  });
4642
4644
  }, ki = ({
4643
4645
  tabsContainerElement: s,
@@ -4655,7 +4657,7 @@ const xi = () => {
4655
4657
  }), n.forEach((a) => {
4656
4658
  a.setAttribute("aria-hidden", "true");
4657
4659
  }), e.setAttribute("aria-selected", "true"), r && r.removeAttribute("aria-hidden");
4658
- }, ut = (s) => s.code === "ArrowLeft" || s.keyCode === 39, pt = (s) => s.code === "ArrowRight" || s.keyCode === 37, qi = (s = document.querySelectorAll(
4660
+ }, pt = (s) => s.code === "ArrowLeft" || s.keyCode === 39, mt = (s) => s.code === "ArrowRight" || s.keyCode === 37, qi = (s = document.querySelectorAll(
4659
4661
  ".js-tabs"
4660
4662
  )) => {
4661
4663
  s.length > 0 && s.forEach((t) => {
@@ -4669,24 +4671,24 @@ const xi = () => {
4669
4671
  if (i && e.length > 0) {
4670
4672
  let n = 0;
4671
4673
  i.addEventListener("keydown", (o) => {
4672
- o instanceof KeyboardEvent && (ut(o) || pt(o)) && (e[n].setAttribute("tabindex", "-1"), ut(o) ? (n += 1, n >= e.length && (n = 0)) : pt(o) && (n -= 1, n < 0 && (n = e.length - 1)), e[n].setAttribute("tabindex", "0"), e[n].focus());
4674
+ o instanceof KeyboardEvent && (pt(o) || mt(o)) && (e[n].setAttribute("tabindex", "-1"), pt(o) ? (n += 1, n >= e.length && (n = 0)) : mt(o) && (n -= 1, n < 0 && (n = e.length - 1)), e[n].setAttribute("tabindex", "0"), e[n].focus());
4673
4675
  });
4674
4676
  }
4675
4677
  });
4676
4678
  }, H = (s) => {
4677
4679
  const [t, e] = s.split("h").map(Number);
4678
4680
  return t * 60 + e;
4679
- }, It = () => {
4681
+ }, Tt = () => {
4680
4682
  const s = /* @__PURE__ */ new Date(), t = s.getHours(), e = s.getMinutes();
4681
4683
  return t * 60 + e;
4682
4684
  }, Bi = (s, t) => {
4683
- const e = It();
4685
+ const e = Tt();
4684
4686
  if (e < s || e > t)
4685
4687
  return 0;
4686
4688
  const i = t - s;
4687
4689
  return (e - s) / i;
4688
4690
  }, Hi = (s) => {
4689
- const t = It();
4691
+ const t = Tt();
4690
4692
  let e = null, i = null, n = -1;
4691
4693
  return Array.from(s).find((o, r, a) => {
4692
4694
  if (r === a.length - 1)
@@ -4740,26 +4742,26 @@ const xi = () => {
4740
4742
  }
4741
4743
  }
4742
4744
  }
4743
- }, G = "c-icon-item__container--is-highlighted", Wi = (s) => {
4745
+ }, K = "c-icon-item__container--is-highlighted", Wi = (s) => {
4744
4746
  s.find(
4745
- (e) => e.classList.contains(G)
4746
- )?.classList.remove(G);
4747
+ (e) => e.classList.contains(K)
4748
+ )?.classList.remove(K);
4747
4749
  }, Vi = () => {
4748
4750
  const s = document.querySelector(".c-toolbar");
4749
4751
  if (s) {
4750
4752
  const t = window.location.origin + window.location.pathname, e = Array.from(s.querySelectorAll(".c-icon-item__container"));
4751
4753
  Wi(e), e.find(
4752
4754
  (n) => n.querySelector("a")?.getAttribute("href") === t
4753
- )?.classList.add(G);
4755
+ )?.classList.add(K);
4754
4756
  }
4755
4757
  }, Qi = () => {
4756
- Xt(), qi(), Ft(), jt(), Ti(), xi(), oe(), Fi(), kt("winterOlympicsGames", "countdown-winter-olympics-games"), Ri(), Rt(), Qt(), Ht(), $t(
4758
+ Xt(), qi(), kt(), jt(), Ti(), xi(), oe(), Zi(), N("winterOlympicsGames", "countdown-winter-olympics-games"), N("eurovision", "countdown-eurovision"), N("worldFoot2026", "countdown-world-foot-2026"), Ri(), Ft(), Qt(), Ht(), Rt(
4757
4759
  "localisation-input",
4758
4760
  "https://www.20minutes.fr/elections/resultats/recherche",
4759
4761
  "?searchValue=",
4760
4762
  "text",
4761
4763
  "text"
4762
- ), Bt(), Vi(), Ot(), Dt(), Jt(), de(), ue(), Yt(), zt(), Ni(), Ci();
4764
+ ), Bt(), Vi(), Dt(), Mt(), Jt(), de(), ue(), Yt(), Ot(), Ni(), Ci();
4763
4765
  };
4764
4766
  export {
4765
4767
  Qi as initScripts