aptechka 0.64.0 → 0.64.3

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 (118) hide show
  1. package/lib/Animation-BRqj4VfN.cjs +1 -0
  2. package/lib/{Animation-Cb-klopb.js → Animation-D29tc5VS.js} +5 -4
  3. package/lib/Damped-BD1OQ1fH.cjs +1 -0
  4. package/lib/{Damped-ByZFbNSt.js → Damped-YrqW5V4w.js} +5 -4
  5. package/lib/DragControls-D8BXtKVu.cjs +1 -0
  6. package/lib/DragControls-DGDUw6bM.js +226 -0
  7. package/lib/ScrollSegmentElement-B6gp1q_z.js +459 -0
  8. package/lib/ScrollSegmentElement-DtMMAirz.cjs +1 -0
  9. package/lib/SourceElement-D_YeNqsI.cjs +5 -0
  10. package/lib/SourceElement-jbviggZp.js +217 -0
  11. package/lib/{Store-swP_0ymB.js → Store-0BVty6AZ.js} +2 -1
  12. package/lib/Store-Cd1GlEmZ.cjs +1 -0
  13. package/lib/Tweened-B-AHx93m.cjs +1 -0
  14. package/lib/{Tweened-DzZwfKNm.js → Tweened-_pF0zXXN.js} +9 -8
  15. package/lib/Viewport-DA10iWAO.js +109 -0
  16. package/lib/Viewport-DB0qAZPJ.cjs +1 -0
  17. package/lib/accordion/index.cjs +1 -1
  18. package/lib/accordion/index.js +2 -1
  19. package/lib/animation/index.cjs +1 -1
  20. package/lib/animation/index.js +3 -3
  21. package/lib/attribute/index.cjs +1 -1
  22. package/lib/attribute/index.js +5 -4
  23. package/lib/billboard/index.cjs +1 -1
  24. package/lib/billboard/index.js +2 -1
  25. package/lib/canvas/index.cjs +1 -1
  26. package/lib/canvas/index.js +5 -5
  27. package/lib/controls/index.cjs +1 -1
  28. package/lib/controls/index.js +6 -223
  29. package/lib/css-property/index.cjs +1 -1
  30. package/lib/css-property/index.js +15 -14
  31. package/lib/custom-scrollbar/index.cjs +1 -1
  32. package/lib/custom-scrollbar/index.js +25 -24
  33. package/lib/dev/index.cjs +1 -1
  34. package/lib/dev/index.js +7 -6
  35. package/lib/device/index.cjs +1 -1
  36. package/lib/device/index.js +5 -106
  37. package/lib/element-linked-store/index.cjs +1 -1
  38. package/lib/element-linked-store/index.js +5 -4
  39. package/lib/element-resizer/index.cjs +1 -1
  40. package/lib/element-resizer/index.js +22 -21
  41. package/lib/en3/En3View.d.ts +2 -2
  42. package/lib/en3/en3.d.ts +3 -2
  43. package/lib/en3/index.cjs +3 -3
  44. package/lib/en3/index.js +93 -91
  45. package/lib/iframe/index.cjs +1 -1
  46. package/lib/iframe/index.js +4 -3
  47. package/lib/image/index.cjs +1 -1
  48. package/lib/image/index.js +5 -4
  49. package/lib/{index-euf5anj6.js → index-Bv9zgfdb.js} +3 -2
  50. package/lib/index-DekP7OZe.cjs +1 -0
  51. package/lib/intersector/index.cjs +1 -1
  52. package/lib/intersector/index.js +4 -3
  53. package/lib/ladder/index.cjs +1 -1
  54. package/lib/ladder/index.js +41 -40
  55. package/lib/{layout-DpZo-I0y.js → layout-BSMtwCga.js} +2 -2
  56. package/lib/layout-box/index.cjs +1 -1
  57. package/lib/layout-box/index.js +18 -17
  58. package/lib/loading/index.cjs +1 -1
  59. package/lib/loading/index.js +4 -3
  60. package/lib/masonry-layout/index.cjs +1 -1
  61. package/lib/masonry-layout/index.js +2 -2
  62. package/lib/media/index.cjs +1 -1
  63. package/lib/media/index.js +12 -11
  64. package/lib/morph/index.cjs +1 -1
  65. package/lib/morph/index.js +3 -2
  66. package/lib/need_redo_tweaker/index.cjs +3 -3
  67. package/lib/need_redo_tweaker/index.js +368 -340
  68. package/lib/pixel-perfect/index.cjs +1 -1
  69. package/lib/pixel-perfect/index.js +2 -2
  70. package/lib/pointer/index.cjs +1 -1
  71. package/lib/pointer/index.js +19 -18
  72. package/lib/popover/index.cjs +1 -1
  73. package/lib/popover/index.js +3 -2
  74. package/lib/radio/index.cjs +1 -1
  75. package/lib/radio/index.js +2 -1
  76. package/lib/router/index.cjs +1 -1
  77. package/lib/router/index.js +11 -10
  78. package/lib/scroll/index.cjs +1 -1
  79. package/lib/scroll/index.js +66 -65
  80. package/lib/{scroll-Benkuq-t.js → scroll-BWF48oHS.js} +11 -10
  81. package/lib/scroll-CFDCeArT.cjs +1 -0
  82. package/lib/scroll-segment/index.cjs +1 -1
  83. package/lib/scroll-segment/index.js +3 -456
  84. package/lib/sequence/index.cjs +1 -1
  85. package/lib/sequence/index.js +4 -3
  86. package/lib/size-element/index.cjs +1 -1
  87. package/lib/size-element/index.js +2 -1
  88. package/lib/slicer/index.cjs +3 -3
  89. package/lib/slicer/index.js +31 -30
  90. package/lib/source/SourceElement.d.ts +1 -1
  91. package/lib/source/index.cjs +1 -5
  92. package/lib/source/index.js +5 -214
  93. package/lib/store/index.cjs +1 -1
  94. package/lib/store/index.js +14 -13
  95. package/lib/stylesheet-DpnWNVyD.js +24 -0
  96. package/lib/stylesheet-HWF2a3nr.cjs +1 -0
  97. package/lib/ticker/index.cjs +1 -1
  98. package/lib/ticker/index.js +14 -13
  99. package/lib/utils/index.cjs +1 -1
  100. package/lib/utils/index.d.ts +1 -0
  101. package/lib/utils/index.js +5 -5
  102. package/lib/utils/jss.d.ts +0 -1
  103. package/lib/utils/stylesheet.d.ts +2 -0
  104. package/lib/video/index.cjs +1 -1
  105. package/lib/video/index.js +11 -10
  106. package/lib/window-resizer/index.cjs +1 -1
  107. package/lib/window-resizer/index.js +9 -8
  108. package/lib/youtube/index.cjs +1 -1
  109. package/lib/youtube/index.js +12 -11
  110. package/package.json +4 -4
  111. package/lib/Animation-dD_idtTU.cjs +0 -1
  112. package/lib/Damped-B8bmTxAr.cjs +0 -1
  113. package/lib/Store-GokLe_g-.cjs +0 -1
  114. package/lib/Tweened-BsL9FamJ.cjs +0 -1
  115. package/lib/index-Cqw2NKev.cjs +0 -1
  116. package/lib/jss-CRBgdvJ3.cjs +0 -1
  117. package/lib/jss-DtnXPEnq.js +0 -23
  118. package/lib/scroll-DAhSpkhR.cjs +0 -1
@@ -30,31 +30,32 @@ var Ke = (u, n, e) => new Promise((i, r) => {
30
30
  }, S = (g) => g.done ? i(g.value) : Promise.resolve(g.value).then(l, m);
31
31
  S((e = e.apply(u, n)).next());
32
32
  });
33
- import { S as ns } from "../Store-swP_0ymB.js";
34
- import { i as D } from "../index-euf5anj6.js";
33
+ import { S as ns } from "../Store-0BVty6AZ.js";
34
+ import { i as D } from "../index-Bv9zgfdb.js";
35
35
  import { q as hs } from "../easings-BEmRlrDd.js";
36
36
  import { i as os } from "../element-CGVl1jA-.js";
37
37
  import { d as oe } from "../events-CsVF98U6.js";
38
38
  import { d as Ae } from "../function-C10DGppn.js";
39
- import { c as _e } from "../jss-DtnXPEnq.js";
40
- import { a as Me, g as Te } from "../layout-DpZo-I0y.js";
41
- import { c as je } from "../math-BOBiC4TN.js";
39
+ import { a as Me, g as Te } from "../layout-BSMtwCga.js";
40
+ import { c as _e } from "../math-BOBiC4TN.js";
42
41
  import { p as ls, l as cs } from "../number-CbdpfO3u.js";
42
+ import { c as je } from "../stylesheet-DpnWNVyD.js";
43
43
  import "../ticker/index.js";
44
44
  import { TICK_ORDER as as, RESIZE_ORDER as De } from "../order/index.js";
45
- import { D as us } from "../Damped-ByZFbNSt.js";
46
- import { T as ds } from "../Tweened-DzZwfKNm.js";
47
- import { WheelControls as ps, KeyboardControls as fs, DragControls as bs, AutoplayControls as ms } from "../controls/index.js";
45
+ import { D as us } from "../Damped-YrqW5V4w.js";
46
+ import { T as ds } from "../Tweened-_pF0zXXN.js";
47
+ import { W as ps, K as fs, D as bs, A as ms } from "../DragControls-DGDUw6bM.js";
48
48
  import { windowResizer as Wt } from "../window-resizer/index.js";
49
49
  import { scrollEntries as Ct } from "../scroll-entries/index.js";
50
50
  import { cssUnitParser as Ze } from "../css-unit-parser/index.js";
51
51
  import { CSSProperty as p } from "../css-property/index.js";
52
- import { device as Ss } from "../device/index.js";
52
+ import { d as Ss } from "../Viewport-DA10iWAO.js";
53
+ import "construct-style-sheets-polyfill";
53
54
  import { elementResizer as ue } from "../element-resizer/index.js";
54
55
  import { s as gs } from "../gestures-CcXV6fCp.js";
55
56
  import { b as Je } from "../dom-CVWzyXPH.js";
56
- import { ScrollSegmentElement as vs } from "../scroll-segment/index.js";
57
- var f, Nt, y, de, pe, Et, W, st, wt, xt, le;
57
+ import { a as vs } from "../ScrollSegmentElement-B6gp1q_z.js";
58
+ var f, Nt, y, de, pe, wt, W, st, Et, xt, le;
58
59
  class ys {
59
60
  constructor(n, e, i) {
60
61
  s(this, xt);
@@ -63,10 +64,10 @@ class ys {
63
64
  s(this, y);
64
65
  s(this, de, 0);
65
66
  s(this, pe, 0);
66
- s(this, Et, 0);
67
+ s(this, wt, 0);
67
68
  s(this, W, 0);
68
69
  s(this, st, null);
69
- s(this, wt, 0);
70
+ s(this, Et, 0);
70
71
  h(this, f, n), h(this, Nt, e), h(this, y, i), Ct.register(t(this, f)), this.setIndex(t(this, Nt));
71
72
  }
72
73
  get element() {
@@ -76,7 +77,7 @@ class ys {
76
77
  return t(this, Nt);
77
78
  }
78
79
  get size() {
79
- return t(this, Et);
80
+ return t(this, wt);
80
81
  }
81
82
  get width() {
82
83
  return t(this, de);
@@ -88,7 +89,7 @@ class ys {
88
89
  return t(this, W);
89
90
  }
90
91
  get transformPosition() {
91
- return t(this, wt);
92
+ return t(this, Et);
92
93
  }
93
94
  destroy() {
94
95
  Ct.unregister(t(this, f)), this.unsetTransform();
@@ -100,19 +101,19 @@ class ys {
100
101
  n ? (t(this, f).style.setProperty("--size", n + "px"), t(this, y).axisCSSProperty.current === "x" ? (t(this, f).style.width = n + "px", t(this, f).style.height = "") : (t(this, f).style.height = n + "px", t(this, f).style.width = "")) : (t(this, f).style.width = "", t(this, f).style.height = "", t(this, f).style.removeProperty("--size"));
101
102
  }
102
103
  resize() {
103
- h(this, de, t(this, f).offsetWidth), h(this, pe, t(this, f).offsetHeight), h(this, Et, t(this, y).vertical ? t(this, f).offsetHeight : t(this, f).offsetWidth), h(this, W, t(this, y).vertical ? Me(t(this, f)) : Te(t(this, f))), h(this, W, t(this, W) - t(this, y).contentPosition);
104
+ h(this, de, t(this, f).offsetWidth), h(this, pe, t(this, f).offsetHeight), h(this, wt, t(this, y).vertical ? t(this, f).offsetHeight : t(this, f).offsetWidth), h(this, W, t(this, y).vertical ? Me(t(this, f)) : Te(t(this, f))), h(this, W, t(this, W) - t(this, y).contentPosition);
104
105
  }
105
106
  transform() {
106
107
  const n = t(this, y).shiftSectionPositionCSSProperty.current;
107
108
  let e = n;
108
109
  const i = t(this, y).viewportSize * t(this, y).sectionDistanceScaleCSSProperty.current;
109
- t(this, y).loopCSSProperty.current && t(this, W) + t(this, Et) <= t(this, y).currentScrollValue - n / 2 && (e = (t(this, y).distance - n) * -1 - t(this, y).gap), Ct.update(
110
+ t(this, y).loopCSSProperty.current && t(this, W) + t(this, wt) <= t(this, y).currentScrollValue - n / 2 && (e = (t(this, y).distance - n) * -1 - t(this, y).gap), Ct.update(
110
111
  t(this, f),
111
112
  t(this, y).axisCSSProperty.current,
112
113
  e
113
114
  );
114
- const r = t(this, y).currentScrollValue + e, l = t(this, W) - t(this, y).viewportSize - i, m = t(this, W) + t(this, Et) + i, S = ls(je(r, l, m), 3);
115
- h(this, wt, S * -1), t(this, y).vertical ? t(this, f).style.transform = `translate3d(0px, ${t(this, wt)}px, 0px)` : t(this, f).style.transform = `translate3d(${t(this, wt)}px, 0px, 0px)`;
115
+ const r = t(this, y).currentScrollValue + e, l = t(this, W) - t(this, y).viewportSize - i, m = t(this, W) + t(this, wt) + i, S = ls(_e(r, l, m), 3);
116
+ h(this, Et, S * -1), t(this, y).vertical ? t(this, f).style.transform = `translate3d(0px, ${t(this, Et)}px, 0px)` : t(this, f).style.transform = `translate3d(${t(this, Et)}px, 0px, 0px)`;
116
117
  }
117
118
  setMark(n) {
118
119
  t(this, st) !== n && (t(this, st) && t(this, f).classList.remove(t(this, st)), n && t(this, f).classList.add(n), h(this, st, n), oe(t(this, f), "scrollSectionMarkChange", {
@@ -139,10 +140,10 @@ class ys {
139
140
  c(this, xt, le).call(this, "current-index-arc-abs", n);
140
141
  }
141
142
  }
142
- f = new WeakMap(), Nt = new WeakMap(), y = new WeakMap(), de = new WeakMap(), pe = new WeakMap(), Et = new WeakMap(), W = new WeakMap(), st = new WeakMap(), wt = new WeakMap(), xt = new WeakSet(), le = function(n, e) {
143
+ f = new WeakMap(), Nt = new WeakMap(), y = new WeakMap(), de = new WeakMap(), pe = new WeakMap(), wt = new WeakMap(), W = new WeakMap(), st = new WeakMap(), Et = new WeakMap(), xt = new WeakSet(), le = function(n, e) {
143
144
  e !== null ? (t(this, f).style.setProperty(`--${n}`, e.toString()), t(this, f).setAttribute(`data-${n}`, e.toString())) : (t(this, f).style.removeProperty(`--${n}`), t(this, f).removeAttribute(`data-${n}`));
144
145
  };
145
- const Cs = _e({
146
+ const Cs = je({
146
147
  ":host": {
147
148
  position: "relative",
148
149
  width: "100%",
@@ -181,7 +182,7 @@ const Cs = _e({
181
182
  flexShrink: "0"
182
183
  }
183
184
  });
184
- var d, Pt, P, it, F, N, q, R, rt, nt, G, ht, Lt, V, E, zt, kt, It, At, qt, Mt, M, Tt, ot, T, lt, U, Dt, ct, Rt, at, ut, dt, b, Gt, I, a, fe, be, C, v, A, O, pt, H, x, L, Ut, K, Z, _, j, Kt, ft, J, Vt, $, w, Zt, Q, Ot, _t, o, Re, ce, Bt, Le, ze, Ve, Oe, z, me, Qe, jt, Se, He, $e, yt, Xe, ge, ae, ve;
185
+ var d, Pt, P, it, F, N, q, R, rt, nt, G, ht, Lt, V, w, zt, kt, It, At, qt, Mt, M, Tt, ot, T, lt, U, Dt, ct, Rt, at, ut, dt, b, Gt, I, a, fe, be, C, v, A, O, pt, H, x, L, Ut, K, Z, _, j, Kt, ft, J, Vt, $, E, Zt, Q, Ot, _t, o, Re, ce, Bt, Le, ze, Ve, Oe, z, me, Qe, jt, Se, He, $e, yt, Xe, ge, ae, ve;
185
186
  class Ft extends HTMLElement {
186
187
  constructor() {
187
188
  super();
@@ -218,7 +219,7 @@ class Ft extends HTMLElement {
218
219
  "--sections-in-view",
219
220
  1
220
221
  ));
221
- s(this, E, new p(this, "--loop", !1));
222
+ s(this, w, new p(this, "--loop", !1));
222
223
  s(this, zt, new p(this, "--damping", 20));
223
224
  s(this, kt, new p(this, "--mass", 0));
224
225
  s(this, It, new p(this, "--stiffness", 0));
@@ -290,7 +291,7 @@ class Ft extends HTMLElement {
290
291
  s(this, J, new ds());
291
292
  s(this, Vt, !1);
292
293
  s(this, $, null);
293
- s(this, w, !1);
294
+ s(this, E, !1);
294
295
  s(this, Zt, null);
295
296
  s(this, Q, []);
296
297
  s(this, Ot, !1);
@@ -364,7 +365,7 @@ class Ft extends HTMLElement {
364
365
  }, 10));
365
366
  }, 20));
366
367
  s(this, ve, () => {
367
- h(this, w, !0), this.hibernatedCSSProperty.current || c(this, o, Oe).call(this);
368
+ h(this, E, !0), this.hibernatedCSSProperty.current || c(this, o, Oe).call(this);
368
369
  });
369
370
  if (D) {
370
371
  const e = this.attachShadow({ mode: "open" });
@@ -420,7 +421,7 @@ class Ft extends HTMLElement {
420
421
  return t(this, V);
421
422
  }
422
423
  get loopCSSProperty() {
423
- return t(this, E);
424
+ return t(this, w);
424
425
  }
425
426
  get dampingCSSProperty() {
426
427
  return t(this, zt);
@@ -518,7 +519,7 @@ class Ft extends HTMLElement {
518
519
  return t(this, K);
519
520
  }
520
521
  get loopDistance() {
521
- return t(this, E).current ? t(this, K) + t(this, A) : t(this, K);
522
+ return t(this, w).current ? t(this, K) + t(this, A) : t(this, K);
522
523
  }
523
524
  get hasOverflow() {
524
525
  return t(this, Z);
@@ -545,7 +546,7 @@ class Ft extends HTMLElement {
545
546
  return t(this, P).current === "x" ? 0 : t(this, d).distance;
546
547
  }
547
548
  tryResplit() {
548
- !t(this, j) && (t(this, E).current || t(this, q).current || t(this, E).current || t(this, G).current || t(this, R).current) && c(this, o, ce).call(this);
549
+ !t(this, j) && (t(this, w).current || t(this, q).current || t(this, w).current || t(this, G).current || t(this, R).current) && c(this, o, ce).call(this);
549
550
  }
550
551
  onScroll(...e) {
551
552
  return t(this, d).subscribe(...e);
@@ -573,7 +574,7 @@ class Ft extends HTMLElement {
573
574
  let g = 0;
574
575
  const vt = c(this, o, ae).call(this), $t = t(this, a)[vt];
575
576
  let he = $t ? this.targetScrollValue - $t.position : 0;
576
- t(this, E).current ? l === 0 && r === t(this, a).length - 1 ? (g = t(this, v) + t(this, C) - m.position + t(this, A), t(this, Vt) || (he = 0)) : l === t(this, a).length - 1 && r === 0 ? g = S.position - (t(this, v) + t(this, C) + t(this, A)) : g = S.position - m.position : g = S.position - m.position, this.shiftPosition(g - he, i);
577
+ t(this, w).current ? l === 0 && r === t(this, a).length - 1 ? (g = t(this, v) + t(this, C) - m.position + t(this, A), t(this, Vt) || (he = 0)) : l === t(this, a).length - 1 && r === 0 ? g = S.position - (t(this, v) + t(this, C) + t(this, A)) : g = S.position - m.position : g = S.position - m.position, this.shiftPosition(g - he, i);
577
578
  }
578
579
  }
579
580
  shiftSections(e, i) {
@@ -620,11 +621,11 @@ class Ft extends HTMLElement {
620
621
  this.vertical ? (t(this, b).style.width = r + "px", t(this, b).style.height = "100%") : (t(this, b).style.height = r + "px", t(this, b).style.width = "100%");
621
622
  } else
622
623
  this.vertical ? (t(this, b).style.width = "100%", t(this, b).style.height = "max-content", h(this, v, t(this, b).offsetHeight - t(this, C))) : (t(this, b).style.width = "max-content", t(this, b).style.height = "100%", h(this, v, t(this, b).offsetWidth - t(this, C)));
623
- if (!t(this, E).current) {
624
+ if (!t(this, w).current) {
624
625
  const r = getComputedStyle(this), l = this.vertical ? parseFloat(r.paddingBlockStart) + parseFloat(r.paddingBlockEnd) : parseFloat(r.paddingInlineStart) + parseFloat(r.paddingInlineEnd);
625
626
  h(this, v, t(this, v) + l), t(this, d).max = t(this, v);
626
627
  }
627
- if (t(this, E).current && t(this, a).length) {
628
+ if (t(this, w).current && t(this, a).length) {
628
629
  const r = t(this, a)[t(this, a).length - 1], l = r.position + r.size - t(this, C), m = t(this, v) - l;
629
630
  h(this, K, r.position + r.size + m);
630
631
  } else
@@ -663,17 +664,17 @@ class Ft extends HTMLElement {
663
664
  }), t(this, Lt).subscribe((e) => {
664
665
  t(this, H).inertion = typeof e.current == "number" ? e.current : 1;
665
666
  }), t(this, N).subscribe(() => {
666
- t(this, w) && t(this, z).call(this);
667
+ t(this, E) && t(this, z).call(this);
667
668
  }), t(this, q).subscribe(({ current: e }) => {
668
- t(this, w) && (e ? c(this, o, ce).call(this) : c(this, o, Bt).call(this));
669
+ t(this, E) && (e ? c(this, o, ce).call(this) : c(this, o, Bt).call(this));
669
670
  }), t(this, R).subscribe((e) => {
670
- t(this, O).debounce = e.current, t(this, H).swipe = e.current, t(this, x).interval = e.current, t(this, w) && (e.current && !e.previous && !t(this, a).length ? c(this, o, ce).call(this) : !e.current && e.previous && t(this, a).length && c(this, o, Bt).call(this));
671
+ t(this, O).debounce = e.current, t(this, H).swipe = e.current, t(this, x).interval = e.current, t(this, E) && (e.current && !e.previous && !t(this, a).length ? c(this, o, ce).call(this) : !e.current && e.previous && t(this, a).length && c(this, o, Bt).call(this));
671
672
  }), t(this, G).subscribe((e) => {
672
- t(this, w) && (t(this, z).call(this), e.current && !e.previous && !t(this, a).length ? c(this, o, ce).call(this) : !e.current && e.previous && t(this, a).length && c(this, o, Bt).call(this));
673
+ t(this, E) && (t(this, z).call(this), e.current && !e.previous && !t(this, a).length ? c(this, o, ce).call(this) : !e.current && e.previous && t(this, a).length && c(this, o, Bt).call(this));
673
674
  }), t(this, V).subscribe((e) => {
674
- t(this, w) && (t(this, z).call(this), c(this, o, yt).call(this));
675
- }), t(this, E).subscribe((e) => {
676
- e.current ? (t(this, w) && (t(this, a).length || (t(this, q).current = !0)), t(this, d).max = 1 / 0, t(this, d).min = -1 / 0) : (h(this, Ut, 0), t(this, d).max = t(this, v), t(this, d).min = 0);
675
+ t(this, E) && (t(this, z).call(this), c(this, o, yt).call(this));
676
+ }), t(this, w).subscribe((e) => {
677
+ e.current ? (t(this, E) && (t(this, a).length || (t(this, q).current = !0)), t(this, d).max = 1 / 0, t(this, d).min = -1 / 0) : (h(this, Ut, 0), t(this, d).max = t(this, v), t(this, d).min = 0);
677
678
  }), t(this, zt).subscribe((e) => {
678
679
  t(this, d).damping = e.current;
679
680
  }), t(this, kt).subscribe((e) => {
@@ -685,13 +686,13 @@ class Ft extends HTMLElement {
685
686
  }), t(this, ot).subscribe((e) => {
686
687
  e.current || (t(this, x).direction = 1);
687
688
  }), t(this, T).subscribe((e) => {
688
- t(this, w) && c(this, o, yt).call(this);
689
+ t(this, E) && c(this, o, yt).call(this);
689
690
  }), t(this, lt).subscribe((e) => {
690
- t(this, w) && t(this, T).current && c(this, o, yt).call(this);
691
+ t(this, E) && t(this, T).current && c(this, o, yt).call(this);
691
692
  }), t(this, U).subscribe((e) => {
692
- t(this, w) && t(this, T).current && c(this, o, yt).call(this);
693
+ t(this, E) && t(this, T).current && c(this, o, yt).call(this);
693
694
  }), t(this, Dt).subscribe((e) => {
694
- t(this, w) && t(this, d).notify();
695
+ t(this, E) && t(this, d).notify();
695
696
  }), t(this, d).isRunning.subscribe((e) => {
696
697
  this.classList.toggle("active", e.current);
697
698
  }), t(this, L).subscribe((e) => {
@@ -702,15 +703,15 @@ class Ft extends HTMLElement {
702
703
  e.current && !e.previous ? (this.classList.add("disabled"), c(this, o, Le).call(this)) : !e.current && e.previous && (this.classList.remove("disabled"), c(this, o, ze).call(this));
703
704
  }), t(this, ut).subscribe((e) => {
704
705
  e.current && !e.previous ? (this.classList.add("hibernated"), c(this, o, Ve).call(this)) : !e.current && e.previous && (this.classList.remove("hibernated"), c(this, o, Oe).call(this));
705
- }), t(this, Pt).observe(), t(this, P).observe(), t(this, it).observe(), t(this, F).observe(), t(this, N).observe(), t(this, q).observe(), t(this, R).observe(), t(this, rt).observe(), t(this, nt).observe(), t(this, G).observe(), t(this, ht).observe(), t(this, Lt).observe(), t(this, V).observe(), t(this, E).observe(), t(this, zt).observe(), t(this, kt).observe(), t(this, It).observe(), t(this, At).observe(), t(this, qt).observe(), t(this, Mt).observe(), t(this, M).observe(), t(this, M).observe(), t(this, Tt).observe(), t(this, ot).observe(), t(this, T).observe(), t(this, lt).observe(), t(this, U).observe(), t(this, Dt).observe(), t(this, ct).observe(), t(this, Rt).observe(), t(this, at).observe(), t(this, ut).observe(), Wt.subscribe(t(this, ve), De.LAST), ue.subscribe(this, t(this, z)), t(this, Zt).observe(this, { childList: !0 });
706
+ }), t(this, Pt).observe(), t(this, P).observe(), t(this, it).observe(), t(this, F).observe(), t(this, N).observe(), t(this, q).observe(), t(this, R).observe(), t(this, rt).observe(), t(this, nt).observe(), t(this, G).observe(), t(this, ht).observe(), t(this, Lt).observe(), t(this, V).observe(), t(this, w).observe(), t(this, zt).observe(), t(this, kt).observe(), t(this, It).observe(), t(this, At).observe(), t(this, qt).observe(), t(this, Mt).observe(), t(this, M).observe(), t(this, M).observe(), t(this, Tt).observe(), t(this, ot).observe(), t(this, T).observe(), t(this, lt).observe(), t(this, U).observe(), t(this, Dt).observe(), t(this, ct).observe(), t(this, Rt).observe(), t(this, at).observe(), t(this, ut).observe(), Wt.subscribe(t(this, ve), De.LAST), ue.subscribe(this, t(this, z)), t(this, Zt).observe(this, { childList: !0 });
706
707
  }
707
708
  disconnectedCallback() {
708
- this.removeAttribute("tabindex"), this.classList.remove("disabled"), this.classList.remove("hibernated"), t(this, Pt).unobserve(), t(this, P).unobserve(), t(this, it).unobserve(), t(this, F).unobserve(), t(this, N).unobserve(), t(this, q).unobserve(), t(this, R).unobserve(), t(this, rt).unobserve(), t(this, nt).unobserve(), t(this, G).unobserve(), t(this, ht).unobserve(), t(this, Lt).unobserve(), t(this, V).unobserve(), t(this, E).unobserve(), t(this, zt).unobserve(), t(this, kt).unobserve(), t(this, It).unobserve(), t(this, At).unobserve(), t(this, qt).unobserve(), t(this, Mt).unobserve(), t(this, M).unobserve(), t(this, Tt).unobserve(), t(this, ot).unobserve(), t(this, T).unobserve(), t(this, lt).unobserve(), t(this, U).unobserve(), t(this, Dt).unobserve(), t(this, ct).unobserve(), t(this, Rt).unobserve(), t(this, at).unobserve(), t(this, ut).unobserve(), Wt.unsubscribe(t(this, ve)), ue.unsubscribe(t(this, z)), c(this, o, Ve).call(this), t(this, Zt).disconnect();
709
+ this.removeAttribute("tabindex"), this.classList.remove("disabled"), this.classList.remove("hibernated"), t(this, Pt).unobserve(), t(this, P).unobserve(), t(this, it).unobserve(), t(this, F).unobserve(), t(this, N).unobserve(), t(this, q).unobserve(), t(this, R).unobserve(), t(this, rt).unobserve(), t(this, nt).unobserve(), t(this, G).unobserve(), t(this, ht).unobserve(), t(this, Lt).unobserve(), t(this, V).unobserve(), t(this, w).unobserve(), t(this, zt).unobserve(), t(this, kt).unobserve(), t(this, It).unobserve(), t(this, At).unobserve(), t(this, qt).unobserve(), t(this, Mt).unobserve(), t(this, M).unobserve(), t(this, Tt).unobserve(), t(this, ot).unobserve(), t(this, T).unobserve(), t(this, lt).unobserve(), t(this, U).unobserve(), t(this, Dt).unobserve(), t(this, ct).unobserve(), t(this, Rt).unobserve(), t(this, at).unobserve(), t(this, ut).unobserve(), Wt.unsubscribe(t(this, ve)), ue.unsubscribe(t(this, z)), c(this, o, Ve).call(this), t(this, Zt).disconnect();
709
710
  }
710
711
  }
711
- d = new WeakMap(), Pt = new WeakMap(), P = new WeakMap(), it = new WeakMap(), F = new WeakMap(), N = new WeakMap(), q = new WeakMap(), R = new WeakMap(), rt = new WeakMap(), nt = new WeakMap(), G = new WeakMap(), ht = new WeakMap(), Lt = new WeakMap(), V = new WeakMap(), E = new WeakMap(), zt = new WeakMap(), kt = new WeakMap(), It = new WeakMap(), At = new WeakMap(), qt = new WeakMap(), Mt = new WeakMap(), M = new WeakMap(), Tt = new WeakMap(), ot = new WeakMap(), T = new WeakMap(), lt = new WeakMap(), U = new WeakMap(), Dt = new WeakMap(), ct = new WeakMap(), Rt = new WeakMap(), at = new WeakMap(), ut = new WeakMap(), dt = new WeakMap(), b = new WeakMap(), Gt = new WeakMap(), I = new WeakMap(), a = new WeakMap(), fe = new WeakMap(), be = new WeakMap(), C = new WeakMap(), v = new WeakMap(), A = new WeakMap(), O = new WeakMap(), pt = new WeakMap(), H = new WeakMap(), x = new WeakMap(), L = new WeakMap(), Ut = new WeakMap(), K = new WeakMap(), Z = new WeakMap(), _ = new WeakMap(), j = new WeakMap(), Kt = new WeakMap(), ft = new WeakMap(), J = new WeakMap(), Vt = new WeakMap(), $ = new WeakMap(), w = new WeakMap(), Zt = new WeakMap(), Q = new WeakMap(), Ot = new WeakMap(), _t = new WeakMap(), o = new WeakSet(), Re = function() {
712
+ d = new WeakMap(), Pt = new WeakMap(), P = new WeakMap(), it = new WeakMap(), F = new WeakMap(), N = new WeakMap(), q = new WeakMap(), R = new WeakMap(), rt = new WeakMap(), nt = new WeakMap(), G = new WeakMap(), ht = new WeakMap(), Lt = new WeakMap(), V = new WeakMap(), w = new WeakMap(), zt = new WeakMap(), kt = new WeakMap(), It = new WeakMap(), At = new WeakMap(), qt = new WeakMap(), Mt = new WeakMap(), M = new WeakMap(), Tt = new WeakMap(), ot = new WeakMap(), T = new WeakMap(), lt = new WeakMap(), U = new WeakMap(), Dt = new WeakMap(), ct = new WeakMap(), Rt = new WeakMap(), at = new WeakMap(), ut = new WeakMap(), dt = new WeakMap(), b = new WeakMap(), Gt = new WeakMap(), I = new WeakMap(), a = new WeakMap(), fe = new WeakMap(), be = new WeakMap(), C = new WeakMap(), v = new WeakMap(), A = new WeakMap(), O = new WeakMap(), pt = new WeakMap(), H = new WeakMap(), x = new WeakMap(), L = new WeakMap(), Ut = new WeakMap(), K = new WeakMap(), Z = new WeakMap(), _ = new WeakMap(), j = new WeakMap(), Kt = new WeakMap(), ft = new WeakMap(), J = new WeakMap(), Vt = new WeakMap(), $ = new WeakMap(), E = new WeakMap(), Zt = new WeakMap(), Q = new WeakMap(), Ot = new WeakMap(), _t = new WeakMap(), o = new WeakSet(), Re = function() {
712
713
  const e = t(this, P).current, i = t(this, it).current ? "-reverse" : "";
713
- t(this, b).style.flexDirection = e === "x" ? `row${i}` : `column${i}`, t(this, O).axis = t(this, ht).current ? "max" : e, t(this, pt).dimension = e === "x" ? "width" : "height", t(this, H).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), t(this, w) && t(this, z).call(this);
714
+ t(this, b).style.flexDirection = e === "x" ? `row${i}` : `column${i}`, t(this, O).axis = t(this, ht).current ? "max" : e, t(this, pt).dimension = e === "x" ? "width" : "height", t(this, H).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), t(this, E) && t(this, z).call(this);
714
715
  }, ce = function() {
715
716
  c(this, o, Bt).call(this), t(this, Gt).assignedElements().forEach((e, i) => {
716
717
  e instanceof HTMLElement && e.tagName !== "SCRIPT" && t(this, I).push(new ys(e, i, this));
@@ -739,14 +740,14 @@ d = new WeakMap(), Pt = new WeakMap(), P = new WeakMap(), it = new WeakMap(), F
739
740
  }), Wt.subscribe(t(this, z), De.SCROLL));
740
741
  }, z = new WeakMap(), me = new WeakMap(), Qe = function(e) {
741
742
  let i = t(this, L).current;
742
- return t(this, E).current ? i = cs(e, t(this, a).length) : i = je(e, 0, this.limit), i;
743
+ return t(this, w).current ? i = cs(e, t(this, a).length) : i = _e(e, 0, this.limit), i;
743
744
  }, jt = new WeakMap(), Se = new WeakMap(), He = function(e = 1) {
744
745
  t(this, ot).current && (t(this, x).direction = e), t(this, M).current && t(this, x).pauseAndContinue(
745
746
  t(this, Tt).current,
746
747
  this.sectionalCSSProperty.current
747
748
  );
748
749
  }, $e = function(e = "current") {
749
- if (t(this, E).current && t(this, a).length) {
750
+ if (t(this, w).current && t(this, a).length) {
750
751
  const i = t(this, d)[e] % Math.round(t(this, v) + t(this, C) + t(this, A));
751
752
  return i < 0 ? t(this, v) + i + t(this, C) + t(this, A) : i;
752
753
  } else
@@ -802,8 +803,8 @@ class ke extends HTMLElement {
802
803
  }
803
804
  }
804
805
  ye = new WeakMap();
805
- var bt, k, X, Y, Jt, Qt, mt, Xt, Ce, Ee;
806
- class Es extends ke {
806
+ var bt, k, X, Y, Jt, Qt, mt, Xt, Ce, we;
807
+ class ws extends ke {
807
808
  constructor() {
808
809
  super();
809
810
  s(this, bt, null);
@@ -823,7 +824,7 @@ class Es extends ke {
823
824
  s(this, Ce, () => {
824
825
  this.setAttribute("axis", this.scrollElement.axisCSSProperty.current);
825
826
  });
826
- s(this, Ee, (e) => {
827
+ s(this, we, (e) => {
827
828
  document.documentElement.classList.add("grabbing"), gs(
828
829
  (l) => {
829
830
  const m = t(this, X) ? l.x : l.y, S = this.scrollElement.distance / t(this, Jt), g = (m - r) * S;
@@ -838,7 +839,7 @@ class Es extends ke {
838
839
  if (D) {
839
840
  const e = this.attachShadow({ mode: "open" });
840
841
  e.adoptedStyleSheets = [
841
- _e({
842
+ je({
842
843
  ":host": {
843
844
  display: "inline-block",
844
845
  zIndex: "1",
@@ -876,14 +877,14 @@ class Es extends ke {
876
877
  connectedCallback() {
877
878
  super.connectedCallback(), this.setAttribute("drag-dead-zone", "");
878
879
  const e = t(this, bt).assignedElements()[0] || t(this, bt).firstElementChild;
879
- h(this, k, e), t(this, k).addEventListener("pointerdown", t(this, Ee)), Wt.subscribe(t(this, mt), De.SCROLL), ue.subscribe(this, t(this, mt)), ue.subscribe(this.scrollElement, t(this, mt)), this.scrollElement.onScroll(t(this, Xt)), this.scrollElement.axisCSSProperty.subscribe(t(this, Ce));
880
+ h(this, k, e), t(this, k).addEventListener("pointerdown", t(this, we)), Wt.subscribe(t(this, mt), De.SCROLL), ue.subscribe(this, t(this, mt)), ue.subscribe(this.scrollElement, t(this, mt)), this.scrollElement.onScroll(t(this, Xt)), this.scrollElement.axisCSSProperty.subscribe(t(this, Ce));
880
881
  }
881
882
  disconnectedCallback() {
882
- this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this, k).removeEventListener("pointerdown", t(this, Ee)), Wt.unsubscribe(t(this, mt)), ue.unsubscribe(t(this, mt)), this.scrollElement.offScroll(t(this, Xt)), this.scrollElement.axisCSSProperty.unsubscribe(t(this, Ce));
883
+ this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this, k).removeEventListener("pointerdown", t(this, we)), Wt.unsubscribe(t(this, mt)), ue.unsubscribe(t(this, mt)), this.scrollElement.offScroll(t(this, Xt)), this.scrollElement.axisCSSProperty.unsubscribe(t(this, Ce));
883
884
  }
884
885
  }
885
- bt = new WeakMap(), k = new WeakMap(), X = new WeakMap(), Y = new WeakMap(), Jt = new WeakMap(), Qt = new WeakMap(), mt = new WeakMap(), Xt = new WeakMap(), Ce = new WeakMap(), Ee = new WeakMap();
886
- D && !customElements.get("e-scrollbar") && customElements.define("e-scrollbar", Es);
886
+ bt = new WeakMap(), k = new WeakMap(), X = new WeakMap(), Y = new WeakMap(), Jt = new WeakMap(), Qt = new WeakMap(), mt = new WeakMap(), Xt = new WeakMap(), Ce = new WeakMap(), we = new WeakMap();
887
+ D && !customElements.get("e-scrollbar") && customElements.define("e-scrollbar", ws);
887
888
  var Yt, te, ee;
888
889
  class Ye extends ke {
889
890
  constructor() {
@@ -912,7 +913,7 @@ class Ye extends ke {
912
913
  }
913
914
  Yt = new WeakMap(), te = new WeakMap(), ee = new WeakMap();
914
915
  var se;
915
- class ws extends Ye {
916
+ class Es extends Ye {
916
917
  constructor() {
917
918
  super(...arguments);
918
919
  s(this, se, new p(this, "--set", 1));
@@ -928,7 +929,7 @@ class ws extends Ye {
928
929
  }
929
930
  }
930
931
  se = new WeakMap();
931
- D && !customElements.get("e-scroll-set-button") && customElements.define("e-scroll-set-button", ws);
932
+ D && !customElements.get("e-scroll-set-button") && customElements.define("e-scroll-set-button", Es);
932
933
  var tt, ie;
933
934
  class xs extends Ye {
934
935
  constructor() {
@@ -955,16 +956,16 @@ class xs extends Ye {
955
956
  }
956
957
  tt = new WeakMap(), ie = new WeakMap();
957
958
  D && !customElements.get("e-scroll-step-button") && customElements.define("e-scroll-step-button", xs);
958
- var B, St, re, we, xe, ne;
959
+ var B, St, re, Ee, xe, ne;
959
960
  class Ps {
960
961
  constructor(n, e, i) {
961
962
  s(this, B, null);
962
963
  s(this, St, null);
963
964
  s(this, re, null);
964
- s(this, we, null);
965
+ s(this, Ee, null);
965
966
  s(this, xe, () => {
966
967
  t(this, St).scrollToSection(t(this, re), {
967
- behaviour: t(this, we)
968
+ behaviour: t(this, Ee)
968
969
  });
969
970
  });
970
971
  s(this, ne, () => {
@@ -973,7 +974,7 @@ class Ps {
973
974
  t(this, St).counter.current === t(this, re)
974
975
  );
975
976
  });
976
- D && (h(this, B, document.createElement("button")), t(this, B).setAttribute("aria-label", `Go to section ${e + 1}`), h(this, St, n), h(this, we, i), h(this, re, e), t(this, B).addEventListener("click", t(this, xe)), t(this, St).counter.subscribe(t(this, ne)), t(this, ne).call(this));
977
+ D && (h(this, B, document.createElement("button")), t(this, B).setAttribute("aria-label", `Go to section ${e + 1}`), h(this, St, n), h(this, Ee, i), h(this, re, e), t(this, B).addEventListener("click", t(this, xe)), t(this, St).counter.subscribe(t(this, ne)), t(this, ne).call(this));
977
978
  }
978
979
  get element() {
979
980
  return t(this, B);
@@ -982,7 +983,7 @@ class Ps {
982
983
  t(this, B).removeEventListener("click", t(this, xe)), t(this, St).counter.unsubscribe(t(this, ne)), t(this, B).remove();
983
984
  }
984
985
  }
985
- B = new WeakMap(), St = new WeakMap(), re = new WeakMap(), we = new WeakMap(), xe = new WeakMap(), ne = new WeakMap();
986
+ B = new WeakMap(), St = new WeakMap(), re = new WeakMap(), Ee = new WeakMap(), xe = new WeakMap(), ne = new WeakMap();
986
987
  var Ht, gt, et;
987
988
  class Ls extends ke {
988
989
  constructor() {
@@ -1063,7 +1064,7 @@ export {
1063
1064
  Be as ScrollCounterElement,
1064
1065
  Ft as ScrollElement,
1065
1066
  zs as ScrollSegmentElement,
1066
- ws as ScrollSetButtonElement,
1067
+ Es as ScrollSetButtonElement,
1067
1068
  xs as ScrollStepButtonElement,
1068
- Es as ScrollbarElement
1069
+ ws as ScrollbarElement
1069
1070
  };
@@ -1,29 +1,30 @@
1
- import { g as r, f as u } from "./dom-CVWzyXPH.js";
2
- import { a as c } from "./layout-DpZo-I0y.js";
3
- import "./index-euf5anj6.js";
4
- function y(e) {
1
+ import { g as l, f as u } from "./dom-CVWzyXPH.js";
2
+ import { a as c } from "./layout-BSMtwCga.js";
3
+ import "construct-style-sheets-polyfill";
4
+ import "./index-Bv9zgfdb.js";
5
+ function E(e) {
5
6
  return new Promise((o) => {
6
7
  setTimeout(() => {
7
8
  o();
8
9
  }, e);
9
10
  });
10
11
  }
11
- function E(e, {
12
+ function H(e, {
12
13
  behavior: o = "instant",
13
14
  offset: i = 0,
14
15
  center: m = !1,
15
16
  scrollElement: s
16
17
  } = {}) {
17
- var l;
18
+ var r;
18
19
  let n, f = s, a = s;
19
20
  if (typeof e == "number")
20
21
  n = e;
21
22
  else {
22
- const t = r(e);
23
+ const t = l(e);
23
24
  t && (f = t, a = s || u(t), n = c(t));
24
25
  }
25
26
  if (f && a && typeof n == "number") {
26
- const t = (typeof i == "number" ? i : ((l = r(i)) == null ? void 0 : l.offsetHeight) || 0) * -1, p = m ? innerHeight / 2 * -1 + f.offsetHeight / 2 : 0;
27
+ const t = (typeof i == "number" ? i : ((r = l(i)) == null ? void 0 : r.offsetHeight) || 0) * -1, p = m ? innerHeight / 2 * -1 + f.offsetHeight / 2 : 0;
27
28
  a.scroll({
28
29
  top: n + t + p,
29
30
  behavior: o
@@ -31,6 +32,6 @@ function E(e, {
31
32
  }
32
33
  }
33
34
  export {
34
- E as s,
35
- y as w
35
+ H as s,
36
+ E as w
36
37
  };
@@ -0,0 +1 @@
1
+ "use strict";const u=require("./dom-JBOkFLTh.cjs"),m=require("./layout-Ctc2p3uz.cjs");require("construct-style-sheets-polyfill");require("./index-DekP7OZe.cjs");function g(t){return new Promise(i=>{setTimeout(()=>{i()},t)})}function p(t,{behavior:i="instant",offset:o=0,center:a=!1,scrollElement:l}={}){var f;let n,s=l,r=l;if(typeof t=="number")n=t;else{const e=u.getElement(t);e&&(s=e,r=l||u.findScrollParentElement(e),n=m.getCumulativeOffsetTop(e))}if(s&&r&&typeof n=="number"){const e=(typeof o=="number"?o:((f=u.getElement(o))==null?void 0:f.offsetHeight)||0)*-1,c=a?innerHeight/2*-1+s.offsetHeight/2:0;r.scroll({top:n+e+c,behavior:i})}}exports.scrollToElement=p;exports.wait=g;
@@ -1 +1 @@
1
- "use strict";var bt=l=>{throw TypeError(l)};var lt=(l,u,r)=>u.has(l)||bt("Cannot "+r);var t=(l,u,r)=>(lt(l,u,"read from private field"),r?r.call(l):u.get(l)),i=(l,u,r)=>u.has(l)?bt("Cannot add the same private member more than once"):u instanceof WeakSet?u.add(l):u.set(l,r),e=(l,u,r,s)=>(lt(l,u,"write to private field"),s?s.call(l,r):u.set(l,r),r),o=(l,u,r)=>(lt(l,u,"access private method"),r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const qt=require("../dom-JBOkFLTh.cjs"),kt=require("../index-Cqw2NKev.cjs"),Ct=require("../element-resizer/index.cjs"),ut=require("../window-resizer/index.cjs"),c=require("../css-property/index.cjs"),gt=require("../order/index.cjs"),et=require("../events-KVanG9sR.cjs"),xt=require("../function-MthRj-GJ.cjs"),St=require("../layout-Ctc2p3uz.cjs"),Mt=require("../math-GDWEqu7y.cjs"),rt=require("../Store-GokLe_g-.cjs"),At=require("../scroll-entries/index.cjs");require("../ticker/index.cjs");const Dt=require("../Damped-B8bmTxAr.cjs");var w,ct,it,B;class pt{constructor(u){i(this,w,null);i(this,ct);i(this,it,!1);i(this,B,()=>{e(this,it,!(t(this,w).scrollWidth>t(this,w).clientWidth))});e(this,ct,u),e(this,w,qt.findScrollParentElement(t(this,ct))),Ct.elementResizer.subscribe(t(this,w),t(this,B)),ut.windowResizer.subscribe(t(this,B)),t(this,B).call(this)}get element(){return t(this,w)}get currentScrollValue(){return t(this,it)?t(this,w).scrollTop:t(this,w).scrollLeft}get vertical(){return t(this,it)}destroy(){Ct.elementResizer.unsubscribe(t(this,B)),ut.windowResizer.unsubscribe(t(this,B))}onScroll(u){t(this,w).addEventListener("scroll",u)}offScroll(u){t(this,w).removeEventListener("scroll",u)}}w=new WeakMap,ct=new WeakMap,it=new WeakMap,B=new WeakMap;var S,G,K,Z,J,D,T,_,I,m,g,y,v,$,d,O,q,L,H,Y,k,x,M,p,P,V,R,z,F,ht,n,W,Q,nt,f,A,C,b,E,tt,N,a,U,h,Pt,ft,Vt,wt,Ft,Et,Lt,Rt,ot,st,dt,X,zt,Ot,mt,yt;let vt=(yt=class extends HTMLElement{constructor(){super(...arguments);i(this,h);i(this,S);i(this,G);i(this,K);i(this,Z);i(this,J);i(this,D);i(this,T);i(this,_);i(this,I);i(this,m);i(this,g);i(this,y);i(this,v);i(this,$);i(this,d);i(this,O);i(this,q);i(this,L);i(this,H);i(this,Y);i(this,k);i(this,x);i(this,M);i(this,p);i(this,P);i(this,V);i(this,R);i(this,z);i(this,F);i(this,ht);i(this,n);i(this,W);i(this,Q);i(this,nt);i(this,f);i(this,A);i(this,C);i(this,b);i(this,E);i(this,tt);i(this,N);i(this,a);i(this,U);i(this,ot);i(this,st);e(this,S,null),e(this,G,new c.CSSProperty(this,"--damping",20)),e(this,K,new c.CSSProperty(this,"--mass",0)),e(this,Z,new c.CSSProperty(this,"--stiffness",0)),e(this,J,new c.CSSProperty(this,"--target","")),e(this,D,new c.CSSProperty(this,"--disabled",!1)),e(this,T,new c.CSSProperty(this,"--distance-offset",0,{rawValueCheck:!1})),e(this,_,new c.CSSProperty(this,"--start-offset",0,{rawValueCheck:!1})),e(this,I,new c.CSSProperty(this,"--capture-once",!1)),e(this,m,new c.CSSProperty(this,"--captured","")),e(this,g,new c.CSSProperty(this,"--released","")),e(this,y,new c.CSSProperty(this,"--captured-from-start","")),e(this,v,new c.CSSProperty(this,"--captured-from-finish","")),e(this,$,new c.CSSProperty(this,"--released-from-start","")),e(this,d,new c.CSSProperty(this,"--released-from-finish","")),e(this,O,new c.CSSProperty(this,"--passed-var","")),e(this,q,new c.CSSProperty(this,"--progress-var","")),e(this,L,new c.CSSProperty(this,"--progress-arc-var","")),e(this,H,new c.CSSProperty(this,"--progress-arc-mult",1)),e(this,Y,new c.CSSProperty(this,"--animation-var-type","target")),e(this,k,new c.CSSProperty(this,"--distance-var","")),e(this,x,new c.CSSProperty(this,"--start-var","")),e(this,M,new c.CSSProperty(this,"--finish-var","")),e(this,p,new rt.Store(!1)),e(this,P,new rt.Store(!1)),e(this,V,new rt.Store(!1)),e(this,R,new rt.Store(!1)),e(this,z,new rt.Store(!1)),e(this,F,new rt.Store(!1)),e(this,ht,[]),e(this,n,this),e(this,W,0),e(this,Q,0),e(this,nt,0),e(this,f,new Dt.Damped(0,{order:gt.TICK_ORDER.SEGMENT,min:0,max:1})),e(this,A,0),e(this,C,0),e(this,b,0),e(this,E,0),e(this,tt,!1),e(this,N,!1),e(this,a,!0),e(this,U,!1),this.resize=()=>{e(this,Q,t(this,S).vertical?this.offsetHeight:this.offsetWidth);const r=t(this,S)instanceof HTMLElement?t(this,S):t(this,S).element;e(this,W,t(this,S).vertical?St.getCumulativeOffsetTop(this,r):St.getCumulativeOffsetLeft(this,r));const s=St.getStickyOffset(this,t(this,S).vertical?"top":"left");e(this,W,t(this,W)-s),e(this,C,this.getStart()),e(this,b,this.getDistance()),e(this,C,t(this,C)+t(this,_).current),e(this,b,t(this,b)+t(this,T).current),e(this,E,t(this,C)+t(this,b)),t(this,S).currentScrollValue>t(this,E)&&!t(this,p).current&&!t(this,P).current&&(t(this,p).current=!0),this.setVar(t(this,x).current,t(this,C)),this.setVar(t(this,M).current,t(this,E)),this.setVar(t(this,k).current,t(this,b)),t(this,f).max=t(this,b),e(this,tt,!0),t(this,st).call(this)},this.findAnotherScrollEntries=xt.debounce(()=>{const r=At.scrollEntries.getAll(this).reverse();let s=0;r.forEach((j,at)=>{j.element===t(this,S)&&(s=at)}),e(this,ht,r.slice(s+1)),this.tick()},0),e(this,ot,()=>{t(this,a)||this.resize()}),e(this,st,()=>{!t(this,a)&&t(this,tt)&&this.tick()})}get scrollContainer(){return t(this,S)}set scrollContainer(r){o(this,h,ft).call(this),e(this,S,r),o(this,h,Pt).call(this)}get distanceOffsetCSSProperty(){return t(this,T)}get startOffsetCSSProperty(){return t(this,_)}get captureOnceCSSProperty(){return t(this,I)}get capturedCSSProperty(){return t(this,m)}get releasedCSSProperty(){return t(this,g)}get capturedFromStartCSSProperty(){return t(this,y)}get capturedFromFinishCSSProperty(){return t(this,v)}get releasedFromStartCSSProperty(){return t(this,$)}get releasedFromFinishCSSProperty(){return t(this,d)}get passedVarCSSProperty(){return t(this,O)}get progressVarCSSProperty(){return t(this,q)}get progressArcVarCSSProperty(){return t(this,L)}get progressArcMultCSSProperty(){return t(this,H)}get animationVarTypeCSSProperty(){return t(this,Y)}get distanceVarCSSProperty(){return t(this,k)}get startVarCSSProperty(){return t(this,x)}get finishVarCSSProperty(){return t(this,M)}get disabledCSSProperty(){return t(this,D)}get dampingCSSProperty(){return t(this,G)}get massCSSProperty(){return t(this,K)}get stiffnessCSSProperty(){return t(this,Z)}get targetCSSProperty(){return t(this,J)}get isCaptured(){return t(this,p)}get isReleased(){return t(this,P)}get isCapturedFromStart(){return t(this,V)}get isReleasedFromStart(){return t(this,R)}get isCapturedFromFinish(){return t(this,z)}get isReleasedFromFinish(){return t(this,F)}get directionPosition(){return t(this,W)}get directionSize(){return t(this,Q)}get passed(){return t(this,f)}get progress(){return t(this,A)}get progressArc(){return Math.abs(Math.cos(t(this,A)*Math.PI))*t(this,H).current}get start(){return t(this,C)}get finish(){return t(this,E)}get distance(){return t(this,b)}get isCapturedOnce(){return t(this,N)}get isDisabled(){return t(this,a)}tick(){let r=t(this,S).currentScrollValue;t(this,ht).forEach(at=>{r+=at.value});const s=r-t(this,C);t(this,U)||e(this,U,t(this,f).previous?Math.abs(t(this,f).previous-s)>1e3:!1),t(this,f).set(s);const j=Math.round(r);t(this,p).current&&(j>=t(this,C)?t(this,V).current||o(this,h,Ft).call(this):t(this,V).current&&!t(this,R).current&&o(this,h,Lt).call(this),j<t(this,E)?t(this,F).current&&!t(this,z).current&&o(this,h,Et).call(this):t(this,V).current&&!t(this,F).current&&o(this,h,Rt).call(this)),j>=t(this,C)&&j<t(this,E)?t(this,p).current||o(this,h,Vt).call(this):t(this,p).current&&(t(this,f).set(Mt.step(t(this,b)/2,t(this,f).target,0,t(this,b))),o(this,h,wt).call(this)),t(this,N)&&t(this,I).current&&(t(this,m).current&&t(this,n).classList.add(t(this,m).current),e(this,a,!0))}disable(){this.style.cssText="",e(this,W,0),e(this,Q,0),t(this,f).reset(),e(this,A,0),e(this,C,0),e(this,b,0),e(this,E,0),e(this,tt,!1),t(this,p).current=!1,t(this,P).current=!1,t(this,V).current=!1,t(this,R).current=!1,t(this,z).current=!1,t(this,F).current=!1,e(this,N,!1),e(this,a,!0),o(this,h,mt).call(this)}enable(){e(this,a,!1)}connectedCallback(){this.scrollContainer=new pt(this)}disconnectedCallback(){t(this,S)instanceof pt&&t(this,S).destroy(),o(this,h,ft).call(this)}removeVar(r){r&&t(this,n).style.removeProperty(`--${r}`)}setVar(r,s){if(r){const j=typeof s=="number"?s.toFixed(6):s;t(this,n).style.setProperty(`--${r}`,j)}}getDistance(){return t(this,Q)+t(this,nt)}getStart(){return t(this,W)-t(this,nt)}},S=new WeakMap,G=new WeakMap,K=new WeakMap,Z=new WeakMap,J=new WeakMap,D=new WeakMap,T=new WeakMap,_=new WeakMap,I=new WeakMap,m=new WeakMap,g=new WeakMap,y=new WeakMap,v=new WeakMap,$=new WeakMap,d=new WeakMap,O=new WeakMap,q=new WeakMap,L=new WeakMap,H=new WeakMap,Y=new WeakMap,k=new WeakMap,x=new WeakMap,M=new WeakMap,p=new WeakMap,P=new WeakMap,V=new WeakMap,R=new WeakMap,z=new WeakMap,F=new WeakMap,ht=new WeakMap,n=new WeakMap,W=new WeakMap,Q=new WeakMap,nt=new WeakMap,f=new WeakMap,A=new WeakMap,C=new WeakMap,b=new WeakMap,E=new WeakMap,tt=new WeakMap,N=new WeakMap,a=new WeakMap,U=new WeakMap,h=new WeakSet,Pt=function(){if(!t(this,S))return;t(this,p).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentCapture",{composed:!0,custom:!0})}),t(this,V).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentCaptureFromStart",{composed:!0,custom:!0})}),t(this,z).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentCaptureFromFinish",{composed:!0,custom:!0})}),t(this,P).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentRelease",{composed:!0,custom:!0})}),t(this,R).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentReleaseFromStart",{composed:!0,custom:!0})}),t(this,F).subscribe(s=>{s.current&&et.dispatchEvent(this,"scrollSegmentReleaseFromFinish",{composed:!0,custom:!0})}),t(this,G).observe(),t(this,K).observe(),t(this,Z).observe(),t(this,J).observe(),t(this,D).observe(),t(this,T).observe(),t(this,_).observe(),t(this,I).observe(),t(this,m).observe(),t(this,g).observe(),t(this,y).observe(),t(this,v).observe(),t(this,$).observe(),t(this,d).observe(),t(this,O).observe(),t(this,q).observe(),t(this,L).observe(),t(this,H).observe(),t(this,Y).observe(),t(this,k).observe(),t(this,x).observe(),t(this,M).observe();let r=!1;this.findAnotherScrollEntries(),t(this,D).current||this.enable(),t(this,G).subscribe(s=>{t(this,f).damping=s.current}),t(this,K).subscribe(s=>{t(this,f).mass=s.current}),t(this,Z).subscribe(s=>{t(this,f).stiffness=s.current}),t(this,J).subscribe(s=>{s.previous&&o(this,h,mt).call(this),s.current?s.current==="parent"?e(this,n,this.parentElement||this):e(this,n,document.querySelector(s.current)||this):e(this,n,this)}),t(this,D).subscribe(s=>{s.current&&!s.previous?this.disable():!s.current&&s.previous&&(this.resize(),this.enable())}),t(this,_).subscribe(()=>{r&&!t(this,a)&&this.resize()}),t(this,T).subscribe(()=>{r&&!t(this,a)&&this.resize()}),t(this,m).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,y).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,v).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,g).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,$).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,d).subscribe(s=>{o(this,h,X).call(this,s)}),t(this,I).subscribe(s=>{t(this,a)||!s.current&&s.previous&&(this.resize(),this.enable())}),t(this,O).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,this.passed.current))}),t(this,q).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,t(this,A)))}),t(this,L).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,this.progressArc))}),t(this,H).subscribe(s=>{t(this,a)||o(this,h,dt).call(this)}),t(this,x).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,t(this,C)))}),t(this,M).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,t(this,E)))}),t(this,k).subscribe(s=>{t(this,a)||(this.removeVar(s.previous),this.setVar(s.current,t(this,b)))}),t(this,f).subscribe(s=>{if(t(this,U)){e(this,U,!1);return}o(this,h,dt).call(this)}),ut.windowResizer.subscribe(t(this,ot),gt.RESIZE_ORDER.SCROLL+1),this.scrollContainer.onScroll(t(this,st)),r=!0},ft=function(){t(this,S)&&(ut.windowResizer.unsubscribe(t(this,ot)),this.scrollContainer.offScroll(t(this,st)),t(this,G).close(),t(this,K).close(),t(this,Z).close(),t(this,J).close(),t(this,D).close(),t(this,T).close(),t(this,_).close(),t(this,I).close(),t(this,m).close(),t(this,g).close(),t(this,y).close(),t(this,v).close(),t(this,$).close(),t(this,d).close(),t(this,O).close(),t(this,q).close(),t(this,L).close(),t(this,H).close(),t(this,k).close(),t(this,x).close(),t(this,M).close(),t(this,p).close(),t(this,P).close(),t(this,V).close(),t(this,R).close(),t(this,z).close(),t(this,F).close(),this.disable(),t(this,f).close())},Vt=function(){t(this,p).current=!0,t(this,P).current=!1,e(this,N,!0),t(this,g).current&&t(this,n).classList.remove(t(this,g).current),t(this,d).current&&t(this,n).classList.remove(t(this,d).current),t(this,d).current&&t(this,n).classList.remove(t(this,d).current),t(this,m).current&&t(this,n).classList.add(t(this,m).current)},wt=function(){t(this,P).current=!0,t(this,p).current=!1,e(this,N,!0),t(this,m).current&&t(this,n).classList.remove(t(this,m).current),t(this,y).current&&t(this,n).classList.remove(t(this,y).current),t(this,v).current&&t(this,n).classList.remove(t(this,v).current),t(this,g).current&&t(this,n).classList.add(t(this,g).current)},Ft=function(){t(this,p).current=!0,t(this,V).current=!0,t(this,R).current=!1,t(this,y).current&&t(this,n).classList.add(t(this,y).current)},Et=function(){t(this,p).current=!0,t(this,z).current=!0,t(this,F).current=!1,t(this,v).current&&t(this,n).classList.add(t(this,v).current)},Lt=function(){t(this,P).current=!0,t(this,R).current=!0,t(this,V).current=!1,t(this,d).current&&t(this,n).classList.add(t(this,d).current)},Rt=function(){t(this,P).current=!0,t(this,F).current=!0,t(this,z).current=!1,t(this,d).current&&t(this,n).classList.add(t(this,d).current)},ot=new WeakMap,st=new WeakMap,dt=function(){const r=t(this,f)[t(this,Y).current];this.setVar(t(this,O).current,r),e(this,A,r/t(this,b)||0),this.setVar(t(this,q).current,t(this,A)),t(this,L).current&&this.setVar(t(this,L).current,this.progressArc)},X=function(r){if(t(this,a)){r.previous&&t(this,n).classList.remove(r.previous),r.current&&t(this,n).classList.remove(r.current);return}r.current&&t(this,p).current?(r.previous&&t(this,n).classList.remove(r.previous),t(this,n).classList.add(r.current)):!r.current&&r.previous&&t(this,n).classList.remove(r.previous)},zt=function(...r){r.forEach(s=>{s&&t(this,n).classList.remove(s)})},Ot=function(...r){r.forEach(s=>{s&&t(this,n).style.removeProperty(`--${s}`)})},mt=function(){o(this,h,zt).call(this,t(this,m).current,t(this,y).current,t(this,v).current,t(this,g).current,t(this,$).current,t(this,d).current),o(this,h,Ot).call(this,t(this,O).current,t(this,q).current,t(this,L).current,t(this,k).current,t(this,x).current,t(this,M).current)},yt);kt.isBrowser&&!customElements.get("scroll-segment")&&customElements.define("scroll-segment",vt);exports.ScrollSegmentDefaultContainer=pt;exports.ScrollSegmentElement=vt;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../ScrollSegmentElement-DtMMAirz.cjs");exports.ScrollSegmentDefaultContainer=e.ScrollSegmentDefaultContainer;exports.ScrollSegmentElement=e.ScrollSegmentElement;