aptechka 0.33.8 → 0.34.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,96 +1,96 @@
1
- var ye = Object.defineProperty;
2
- var le = Object.getOwnPropertySymbols;
3
- var Ce = Object.prototype.hasOwnProperty, Ee = Object.prototype.propertyIsEnumerable;
4
- var ae = (a) => {
1
+ var ze = Object.defineProperty;
2
+ var be = Object.getOwnPropertySymbols;
3
+ var De = Object.prototype.hasOwnProperty, Ie = Object.prototype.propertyIsEnumerable;
4
+ var ge = (a) => {
5
5
  throw TypeError(a);
6
6
  };
7
- var ce = (a, r, e) => r in a ? ye(a, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[r] = e, ue = (a, r) => {
8
- for (var e in r || (r = {}))
9
- Ce.call(r, e) && ce(a, e, r[e]);
10
- if (le)
11
- for (var e of le(r))
12
- Ee.call(r, e) && ce(a, e, r[e]);
7
+ var Se = (a, h, e) => h in a ? ze(a, h, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[h] = e, ve = (a, h) => {
8
+ for (var e in h || (h = {}))
9
+ De.call(h, e) && Se(a, e, h[e]);
10
+ if (be)
11
+ for (var e of be(h))
12
+ Ie.call(h, e) && Se(a, e, h[e]);
13
13
  return a;
14
14
  };
15
- var Xt = (a, r, e) => r.has(a) || ae("Cannot " + e);
16
- var t = (a, r, e) => (Xt(a, r, "read from private field"), e ? e.call(a) : r.get(a)), s = (a, r, e) => r.has(a) ? ae("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(a) : r.set(a, e), h = (a, r, e, i) => (Xt(a, r, "write to private field"), i ? i.call(a, e) : r.set(a, e), e), d = (a, r, e) => (Xt(a, r, "access private method"), e);
17
- import { S as we } from "../../Store-OTdcl6SX.js";
18
- import { i as Qt } from "../../browser-0zX67oeU.js";
19
- import { q as xe } from "../../easings-BEmRlrDd.js";
20
- import { d as Yt } from "../../events-CsVF98U6.js";
21
- import { c as fe } from "../../jss-CjccJC-K.js";
22
- import { a as te, g as ee } from "../../layout-HoBT_Da2.js";
23
- import { c as pe } from "../../math-BOBiC4TN.js";
15
+ var he = (a, h, e) => h.has(a) || ge("Cannot " + e);
16
+ var t = (a, h, e) => (he(a, h, "read from private field"), e ? e.call(a) : h.get(a)), s = (a, h, e) => h.has(a) ? ge("Cannot add the same private member more than once") : h instanceof WeakSet ? h.add(a) : h.set(a, e), n = (a, h, e, i) => (he(a, h, "write to private field"), i ? i.call(a, e) : h.set(a, e), e), d = (a, h, e) => (he(a, h, "access private method"), e);
17
+ import { S as Te } from "../../Store-OTdcl6SX.js";
18
+ import { i as ne } from "../../browser-0zX67oeU.js";
19
+ import { q as Ae } from "../../easings-BEmRlrDd.js";
20
+ import { d as ee } from "../../events-CsVF98U6.js";
21
+ import { c as Ce } from "../../jss-CjccJC-K.js";
22
+ import { a as oe, g as le } from "../../layout-HoBT_Da2.js";
23
+ import { c as we } from "../../math-BOBiC4TN.js";
24
24
  import "../../ticker/vanilla/index.js";
25
- import { TICK_ORDER as Pe, RESIZE_ORDER as me } from "../../order/index.js";
26
- import { D as Le } from "../../Damped-Chu29wn-.js";
27
- import { T as ze } from "../../Tweened-B_ZFQKGQ.js";
28
- import { WheelControls as ke, KeyboardControls as Ie, DragControls as De, AutoplayControls as Ae } from "../../controls/index.js";
29
- import { windowResizer as Jt } from "../../window-resizer/vanilla/index.js";
30
- import { scrollEntries as ct } from "../../scroll-entries/index.js";
31
- import { cssUnitParser as de } from "../../css-unit-parser/index.js";
32
- import { CSSProperty as p } from "../../css-property/index.js";
33
- import { device as Te } from "../../device/index.js";
34
- import { elementResizer as Rt } from "../../element-resizer/vanilla/index.js";
35
- import { s as Me } from "../../gestures-D2Fdra_G.js";
36
- import { f as be } from "../../dom-0S_WDL4g.js";
37
- import { d as Ve } from "../../function-C10DGppn.js";
38
- import { ScrollSegmentElement as Oe } from "../../scroll-segment/index.js";
39
- var m, Bt, v, at, V, G;
40
- class Re {
41
- constructor(r, e, i) {
25
+ import { TICK_ORDER as Me, RESIZE_ORDER as Ee } from "../../order/index.js";
26
+ import { D as Ve } from "../../Damped-Chu29wn-.js";
27
+ import { T as Oe } from "../../Tweened-DJzAFsVZ.js";
28
+ import { WheelControls as Re, KeyboardControls as He, DragControls as Be, AutoplayControls as We } from "../../controls/index.js";
29
+ import { windowResizer as re } from "../../window-resizer/vanilla/index.js";
30
+ import { scrollEntries as dt } from "../../scroll-entries/index.js";
31
+ import { cssUnitParser as ye } from "../../css-unit-parser/index.js";
32
+ import { CSSProperty as f } from "../../css-property/index.js";
33
+ import { device as Fe } from "../../device/index.js";
34
+ import { elementResizer as Nt } from "../../element-resizer/vanilla/index.js";
35
+ import { s as $e } from "../../gestures-D2Fdra_G.js";
36
+ import { f as xe } from "../../dom-0S_WDL4g.js";
37
+ import { d as qe } from "../../function-C10DGppn.js";
38
+ import { ScrollSegmentElement as Ne } from "../../scroll-segment/index.js";
39
+ var m, Gt, g, ft, R, Z;
40
+ class Ue {
41
+ constructor(h, e, i) {
42
42
  s(this, m);
43
- s(this, Bt);
44
- s(this, v);
45
- s(this, at, 0);
46
- s(this, V, 0);
47
- s(this, G, null);
48
- h(this, m, r), h(this, Bt, e), h(this, v, i), ct.register(t(this, m));
43
+ s(this, Gt);
44
+ s(this, g);
45
+ s(this, ft, 0);
46
+ s(this, R, 0);
47
+ s(this, Z, null);
48
+ n(this, m, h), n(this, Gt, e), n(this, g, i), dt.register(t(this, m));
49
49
  }
50
50
  get index() {
51
- return t(this, Bt);
51
+ return t(this, Gt);
52
52
  }
53
53
  get size() {
54
- return t(this, at);
54
+ return t(this, ft);
55
55
  }
56
56
  get position() {
57
- return t(this, V);
57
+ return t(this, R);
58
58
  }
59
59
  destroy() {
60
- ct.unregister(t(this, m)), this.unsetTransform();
60
+ dt.unregister(t(this, m)), this.unsetTransform();
61
61
  }
62
62
  unsetTransform() {
63
63
  t(this, m).style.transform = "", this.mark(null);
64
64
  }
65
- setSize(r) {
66
- r ? (t(this, m).style.setProperty("--size", r + "px"), t(this, v).axisCSSProperty.current === "x" ? (t(this, m).style.width = r + "px", t(this, m).style.height = "") : (t(this, m).style.height = r + "px", t(this, m).style.width = "")) : (t(this, m).style.width = "", t(this, m).style.height = "", t(this, m).style.removeProperty("--size"));
65
+ setSize(h) {
66
+ h ? (t(this, m).style.setProperty("--size", h + "px"), t(this, g).axisCSSProperty.current === "x" ? (t(this, m).style.width = h + "px", t(this, m).style.height = "") : (t(this, m).style.height = h + "px", t(this, m).style.width = "")) : (t(this, m).style.width = "", t(this, m).style.height = "", t(this, m).style.removeProperty("--size"));
67
67
  }
68
68
  resize() {
69
- h(this, at, t(this, v).vertical ? t(this, m).offsetHeight : t(this, m).offsetWidth), h(this, V, t(this, v).vertical ? te(t(this, m)) : ee(t(this, m))), h(this, V, t(this, V) - t(this, v).contentPosition);
69
+ n(this, ft, t(this, g).vertical ? t(this, m).offsetHeight : t(this, m).offsetWidth), n(this, R, t(this, g).vertical ? oe(t(this, m)) : le(t(this, m))), n(this, R, t(this, R) - t(this, g).contentPosition);
70
70
  }
71
71
  transform() {
72
- let r = 0;
73
- const e = t(this, v).viewportSize * t(this, v).sectionDistanceScaleCSSProperty.current;
74
- t(this, v).loopCSSProperty.current && t(this, v).overscroll && t(this, V) + t(this, at) < t(this, v).currentScrollValue && (r = t(this, v).distance * -1 - t(this, v).gap), ct.update(
72
+ let h = 0;
73
+ const e = t(this, g).viewportSize * t(this, g).sectionDistanceScaleCSSProperty.current;
74
+ t(this, g).loopCSSProperty.current && t(this, g).overscroll && t(this, R) + t(this, ft) < t(this, g).currentScrollValue && (h = t(this, g).distance * -1 - t(this, g).gap), dt.update(
75
75
  t(this, m),
76
- t(this, v).axisCSSProperty.current,
77
- r
76
+ t(this, g).axisCSSProperty.current,
77
+ h
78
78
  );
79
- const i = t(this, v).currentScrollValue + r, n = t(this, V) - t(this, v).viewportSize - e, c = t(this, V) + t(this, at) + e, b = pe(i, n, c);
80
- t(this, v).vertical ? t(this, m).style.transform = `translate3d(0px, ${b * -1}px, 0px)` : t(this, m).style.transform = `translate3d(${b * -1}px, 0px, 0px)`;
79
+ const i = t(this, g).currentScrollValue + h, r = t(this, R) - t(this, g).viewportSize - e, c = t(this, R) + t(this, ft) + e, b = we(i, r, c);
80
+ t(this, g).vertical ? t(this, m).style.transform = `translate3d(0px, ${b * -1}px, 0px)` : t(this, m).style.transform = `translate3d(${b * -1}px, 0px, 0px)`;
81
81
  }
82
- mark(r) {
83
- t(this, G) !== r && (t(this, G) && t(this, m).classList.remove(t(this, G)), r && t(this, m).classList.add(r), h(this, G, r), Yt(t(this, m), "scrollSectionMarkChange", {
82
+ mark(h) {
83
+ t(this, Z) !== h && (t(this, Z) && t(this, m).classList.remove(t(this, Z)), h && t(this, m).classList.add(h), n(this, Z, h), ee(t(this, m), "scrollSectionMarkChange", {
84
84
  composed: !0,
85
85
  detail: {
86
- mark: t(this, G)
86
+ mark: t(this, Z)
87
87
  },
88
88
  custom: !0
89
89
  }));
90
90
  }
91
91
  }
92
- m = new WeakMap(), Bt = new WeakMap(), v = new WeakMap(), at = new WeakMap(), V = new WeakMap(), G = new WeakMap();
93
- const He = fe({
92
+ m = new WeakMap(), Gt = new WeakMap(), g = new WeakMap(), ft = new WeakMap(), R = new WeakMap(), Z = new WeakMap();
93
+ const Ge = Ce({
94
94
  ":host": {
95
95
  position: "relative",
96
96
  width: "100%",
@@ -128,350 +128,354 @@ const He = fe({
128
128
  flexShrink: "0"
129
129
  }
130
130
  });
131
- var u, ut, P, O, R, H, I, K, _, B, Z, dt, D, C, ft, pt, mt, bt, wt, k, gt, j, A, J, F, Q, St, vt, X, Y, f, xt, l, Ft, Wt, y, S, L, T, tt, M, E, g, Pt, et, W, st, yt, Lt, it, $, $t, o, Ot, Et, Zt, jt, se, ie, z, zt, ge, kt, qt, re, ne, lt, he;
132
- class Ht extends HTMLElement {
131
+ var u, pt, x, H, B, W, D, j, J, F, Q, mt, I, y, bt, St, gt, vt, Pt, z, yt, X, T, Y, $, tt, Ct, wt, et, st, p, Lt, l, Kt, _t, v, S, P, A, it, M, C, w, kt, rt, q, nt, Et, zt, ht, N, Zt, V, o, qt, xt, se, ie, ce, ae, L, Dt, Pe, It, jt, ue, de, ut, fe;
132
+ class Ut extends HTMLElement {
133
133
  constructor() {
134
134
  super();
135
135
  s(this, o);
136
136
  s(this, u, null);
137
- s(this, ut, new p(this, "--controls", !0));
138
- s(this, P, new p(this, "--axis", "y"));
139
- s(this, O, new p(this, "--direction", 0));
140
- s(this, R, new p(this, "--pages", 0, {
137
+ s(this, pt, new f(this, "--controls", !0));
138
+ s(this, x, new f(this, "--axis", "y"));
139
+ s(this, H, new f(this, "--direction", 0));
140
+ s(this, B, new f(this, "--pages", 0, {
141
141
  validate: (e) => Math.max(0, e - 1)
142
142
  }));
143
- s(this, H, new p(this, "--split", !1));
144
- s(this, I, new p(this, "--sectional", !1));
145
- s(this, K, new p(
143
+ s(this, W, new f(this, "--split", !1));
144
+ s(this, D, new f(this, "--sectional", !1));
145
+ s(this, j, new f(
146
146
  this,
147
- "--easing",
147
+ "--tween-easing",
148
148
  !1
149
149
  ));
150
- s(this, _, new p(
150
+ s(this, J, new f(
151
151
  this,
152
- "--duration",
152
+ "--tween-duration",
153
153
  !1
154
154
  ));
155
- s(this, B, new p(this, "--auto-size", !1));
156
- s(this, Z, new p(
155
+ s(this, F, new f(this, "--auto-size", !1));
156
+ s(this, Q, new f(
157
157
  this,
158
158
  "--wheel-max-delta",
159
159
  !1
160
160
  ));
161
- s(this, dt, new p(this, "--drag-inertion", 1));
162
- s(this, D, new p(
161
+ s(this, mt, new f(this, "--drag-inertion", 1));
162
+ s(this, I, new f(
163
163
  this,
164
164
  "--sections-in-view",
165
165
  1
166
166
  ));
167
- s(this, C, new p(this, "--loop", !1));
168
- s(this, ft, new p(this, "--damping", 20));
169
- s(this, pt, new p(this, "--mass", 0));
170
- s(this, mt, new p(this, "--stiffness", 0));
171
- s(this, bt, new p(this, "--mouse-drag", !1));
172
- s(this, wt, new p(
167
+ s(this, y, new f(this, "--loop", !1));
168
+ s(this, bt, new f(this, "--damping", 20));
169
+ s(this, St, new f(this, "--mass", 0));
170
+ s(this, gt, new f(this, "--stiffness", 0));
171
+ s(this, vt, new f(this, "--mouse-drag", !1));
172
+ s(this, Pt, new f(
173
173
  this,
174
174
  "--section-distance-scale",
175
175
  0.5
176
176
  ));
177
- s(this, k, new p(this, "--autoplay", 0));
178
- s(this, gt, new p(
177
+ s(this, z, new f(this, "--autoplay", 0));
178
+ s(this, yt, new f(
179
179
  this,
180
180
  "--autoplay-pause-duration",
181
181
  0
182
182
  ));
183
- s(this, j, new p(
183
+ s(this, X, new f(
184
184
  this,
185
185
  "--autoplay-user-direction",
186
186
  !1
187
187
  ));
188
- s(this, A, new p(this, "--classes", !1));
189
- s(this, J, new p(
188
+ s(this, T, new f(this, "--classes", !1));
189
+ s(this, Y, new f(
190
190
  this,
191
191
  "--current-index-start-offset",
192
192
  0
193
193
  ));
194
- s(this, F, new p(
194
+ s(this, $, new f(
195
195
  this,
196
196
  "--current-index-end-offset",
197
197
  0
198
198
  ));
199
- s(this, Q, new p(this, "--focus-delay", 0));
200
- s(this, St, new p(
199
+ s(this, tt, new f(this, "--focus-delay", 0));
200
+ s(this, Ct, new f(
201
201
  this,
202
202
  "--focus-duration",
203
203
  3e3
204
204
  ));
205
- s(this, vt, new p(this, "--disabled", !1));
206
- s(this, X, new p(this, "--hibernated", !1));
207
- s(this, Y, null);
208
- s(this, f, null);
209
- s(this, xt, null);
205
+ s(this, wt, new f(this, "--disabled", !1));
206
+ s(this, et, new f(this, "--hibernated", !1));
207
+ s(this, st, null);
208
+ s(this, p, null);
209
+ s(this, Lt, null);
210
210
  s(this, l, []);
211
- s(this, Ft, 0);
212
- s(this, Wt, 0);
213
- s(this, y, 0);
211
+ s(this, Kt, 0);
212
+ s(this, _t, 0);
213
+ s(this, v, 0);
214
214
  s(this, S, 0);
215
- s(this, L, 0);
216
- s(this, T, null);
217
- s(this, tt, null);
215
+ s(this, P, 0);
216
+ s(this, A, null);
217
+ s(this, it, null);
218
218
  s(this, M, null);
219
- s(this, E, null);
220
- s(this, g, new we(0));
221
- s(this, Pt, 0);
222
- s(this, et, 0);
223
- s(this, W, !1);
224
- s(this, st, !0);
225
- s(this, yt, !0);
226
- s(this, Lt);
227
- s(this, it);
228
- s(this, $, new ze());
229
- s(this, $t, !1);
230
- s(this, z, () => {
219
+ s(this, C, null);
220
+ s(this, w, new Te(0));
221
+ s(this, kt, 0);
222
+ s(this, rt, 0);
223
+ s(this, q, !1);
224
+ s(this, nt, !0);
225
+ s(this, Et, !0);
226
+ s(this, zt);
227
+ s(this, ht);
228
+ s(this, N, new Oe());
229
+ s(this, Zt, !1);
230
+ s(this, V, null);
231
+ s(this, L, () => {
231
232
  t(this, u).unlistenAnimationFrame();
232
- const e = this.currentScrollValue / t(this, S) || 0, i = t(this, g).current;
233
- if (h(this, Ft, this.vertical ? te(this) : ee(this)), h(this, Wt, this.vertical ? te(t(this, f)) : ee(t(this, f))), h(this, y, this.vertical ? this.offsetHeight : this.offsetWidth), this.vertical ? h(this, L, de.parse(
234
- getComputedStyle(t(this, f)).rowGap
235
- )) : h(this, L, de.parse(
236
- getComputedStyle(t(this, f)).columnGap
237
- )), t(this, B).current && t(this, l).length) {
238
- const n = t(this, D).current, c = (t(this, y) - t(this, L) * (n - 1)) / n;
233
+ const e = this.currentScrollValue / t(this, S) || 0, i = t(this, w).current;
234
+ if (n(this, Kt, this.vertical ? oe(this) : le(this)), n(this, _t, this.vertical ? oe(t(this, p)) : le(t(this, p))), n(this, v, this.vertical ? this.offsetHeight : this.offsetWidth), this.vertical ? n(this, P, ye.parse(
235
+ getComputedStyle(t(this, p)).rowGap
236
+ )) : n(this, P, ye.parse(
237
+ getComputedStyle(t(this, p)).columnGap
238
+ )), t(this, F).current && t(this, l).length) {
239
+ const r = t(this, I).current, c = (t(this, v) - t(this, P) * (r - 1)) / r;
239
240
  t(this, l).forEach((b) => {
240
241
  b.setSize(c);
241
242
  });
242
243
  } else
243
- t(this, l).forEach((n) => {
244
- n.setSize();
244
+ t(this, l).forEach((r) => {
245
+ r.setSize();
245
246
  });
246
- if (t(this, l).forEach((n) => {
247
- n.resize();
248
- }), t(this, R).current) {
249
- h(this, S, t(this, y) * t(this, R).current);
250
- const n = t(this, S) + t(this, y);
251
- this.vertical ? (t(this, f).style.width = n + "px", t(this, f).style.height = "100%") : (t(this, f).style.height = n + "px", t(this, f).style.width = "100%");
247
+ if (t(this, l).forEach((r) => {
248
+ r.resize();
249
+ }), t(this, B).current) {
250
+ n(this, S, t(this, v) * t(this, B).current);
251
+ const r = t(this, S) + t(this, v);
252
+ this.vertical ? (t(this, p).style.width = r + "px", t(this, p).style.height = "100%") : (t(this, p).style.height = r + "px", t(this, p).style.width = "100%");
252
253
  } else
253
- this.vertical ? (t(this, f).style.width = "100%", t(this, f).style.height = "max-content", h(this, S, t(this, f).offsetHeight - t(this, y))) : (t(this, f).style.width = "max-content", t(this, f).style.height = "100%", h(this, S, t(this, f).offsetWidth - t(this, y)));
254
- if (!t(this, C).current) {
255
- const n = getComputedStyle(this), c = this.vertical ? parseFloat(n.paddingBlockStart) + parseFloat(n.paddingBlockEnd) : parseFloat(n.paddingInlineStart) + parseFloat(n.paddingInlineEnd);
256
- h(this, S, t(this, S) + c), t(this, u).max = t(this, S);
254
+ this.vertical ? (t(this, p).style.width = "100%", t(this, p).style.height = "max-content", n(this, S, t(this, p).offsetHeight - t(this, v))) : (t(this, p).style.width = "max-content", t(this, p).style.height = "100%", n(this, S, t(this, p).offsetWidth - t(this, v)));
255
+ if (!t(this, y).current) {
256
+ const r = getComputedStyle(this), c = this.vertical ? parseFloat(r.paddingBlockStart) + parseFloat(r.paddingBlockEnd) : parseFloat(r.paddingInlineStart) + parseFloat(r.paddingInlineEnd);
257
+ n(this, S, t(this, S) + c), t(this, u).max = t(this, S);
257
258
  }
258
- if (t(this, C).current && t(this, l).length) {
259
- const n = t(this, l)[t(this, l).length - 1], c = n.position + n.size - t(this, y), b = t(this, S) - c;
260
- h(this, et, n.position + n.size + b);
259
+ if (t(this, y).current && t(this, l).length) {
260
+ const r = t(this, l)[t(this, l).length - 1], c = r.position + r.size - t(this, v), b = t(this, S) - c;
261
+ n(this, rt, r.position + r.size + b);
261
262
  } else
262
- h(this, et, t(this, S));
263
- if (t(this, I).current && t(this, l).length) {
264
- const n = t(this, l)[i];
265
- t(this, u).set(n.position, {
263
+ n(this, rt, t(this, S));
264
+ if (t(this, D).current && t(this, l).length) {
265
+ const r = t(this, l)[i];
266
+ t(this, u).set(r.position, {
266
267
  equalize: !0
267
268
  });
268
269
  } else
269
270
  t(this, u).set(e * t(this, S), {
270
271
  equalize: !0
271
272
  });
272
- h(this, W, (this.vertical ? t(this, f).offsetHeight : t(this, f).offsetWidth) > t(this, y)), this.classList.toggle("has-overflow", t(this, W)), t(this, W) ? d(this, o, jt).call(this) : d(this, o, Zt).call(this), t(this, zt).call(this);
273
+ n(this, q, (this.vertical ? t(this, p).offsetHeight : t(this, p).offsetWidth) > t(this, v)), this.classList.toggle("has-overflow", t(this, q)), t(this, q) ? d(this, o, ie).call(this) : d(this, o, se).call(this), t(this, Dt).call(this);
273
274
  });
274
- s(this, zt, () => {
275
- if (!t(this, W))
275
+ s(this, Dt, () => {
276
+ if (!t(this, q))
276
277
  return;
277
278
  const e = this.currentScrollValue;
278
- if (h(this, Pt, Math.max(0, e - t(this, S))), t(this, l).length) {
279
+ if (n(this, kt, Math.max(0, e - t(this, S))), t(this, l).length) {
279
280
  let i = 0;
280
- for (let n = 0; n < t(this, l).length; n++) {
281
- const c = t(this, l)[n];
282
- c.transform(), this.targetScrollValue + c.size / 2 >= c.position && (i = n);
281
+ for (let r = 0; r < t(this, l).length; r++) {
282
+ const c = t(this, l)[r];
283
+ c.transform(), this.targetScrollValue + c.size / 2 >= c.position && (i = r);
283
284
  }
284
- t(this, g).current = i;
285
+ t(this, w).current = i;
285
286
  } else
286
- this.vertical ? t(this, f).style.transform = `translate3d(0px, ${e * -1}px, 0px)` : t(this, f).style.transform = `translate3d(${e * -1}px, 0px, 0px)`;
287
- ct.update(
287
+ this.vertical ? t(this, p).style.transform = `translate3d(0px, ${e * -1}px, 0px)` : t(this, p).style.transform = `translate3d(${e * -1}px, 0px, 0px)`;
288
+ dt.update(
288
289
  this,
289
- t(this, P).current,
290
+ t(this, x).current,
290
291
  e
291
292
  );
292
293
  });
293
- s(this, kt, (e, i) => {
294
- t(this, ut).current && (d(this, o, re).call(this, Math.sign(i) || 1), t(this, qt).call(this, e, i));
294
+ s(this, It, (e, i) => {
295
+ t(this, pt).current && (d(this, o, ue).call(this, Math.sign(i) || 1), t(this, jt).call(this, e, i));
295
296
  });
296
- s(this, qt, (e, i) => {
297
- if (t(this, O).current) {
298
- if (t(this, O).current < 0 && i > 0)
297
+ s(this, jt, (e, i) => {
298
+ if (t(this, H).current) {
299
+ if (t(this, H).current < 0 && i > 0)
299
300
  return;
300
- if (t(this, O).current > 0 && i < 0)
301
+ if (t(this, H).current > 0 && i < 0)
301
302
  return;
302
303
  }
303
- if (t(this, it) || t(this, $).unlistenAnimationFrame(), !t(this, k).current && t(this, Q).current && (clearInterval(t(this, Lt)), h(this, Lt, setTimeout(() => {
304
- const n = d(this, o, he).call(this);
305
- n && this.scrollToSection(n.index, {
304
+ if (t(this, ht) || t(this, N).unlistenAnimationFrame(), !t(this, z).current && t(this, tt).current && (clearInterval(t(this, zt)), n(this, zt, setTimeout(() => {
305
+ const r = d(this, o, fe).call(this);
306
+ r && this.scrollToSection(r.index, {
306
307
  tween: {
307
- duration: t(this, St).current,
308
- easing: xe
308
+ duration: t(this, Ct).current,
309
+ easing: Ae
309
310
  }
310
311
  });
311
- }, t(this, Q).current))), !(e.includes("drag") && !Te.isMobile && !t(this, bt).current)) {
312
- if (t(this, I).current && e !== "drag") {
313
- const n = Math.sign(i);
312
+ }, t(this, tt).current))), !(e.includes("drag") && !Fe.isMobile && !t(this, vt).current)) {
313
+ if (t(this, D).current && e !== "drag") {
314
+ const r = Math.sign(i);
314
315
  if (t(this, l).length) {
315
316
  const c = {
316
- tween: t(this, K).current || t(this, _).current ? {
317
- easing: t(this, K).current || "easeInOutCubic",
318
- duration: t(this, _).current || 500
317
+ tween: t(this, j).current || t(this, J).current ? {
318
+ easing: t(this, j).current || "easeInOutCubic",
319
+ duration: t(this, J).current || 500
319
320
  } : void 0
320
321
  };
321
- t(this, $t) ? this.scrollToSection(t(this, g).current, c) : this.shiftSections(n, c);
322
+ t(this, Zt) ? this.scrollToSection(t(this, w).current, c) : this.shiftSections(r, c);
322
323
  } else
323
- t(this, u).shift(n * t(this, y));
324
+ t(this, u).shift(r * t(this, v));
324
325
  } else
325
326
  t(this, u).shift(i);
326
- h(this, $t, e === "drag");
327
+ n(this, Zt, e === "drag");
327
328
  }
328
329
  });
329
- if (Qt) {
330
+ if (ne) {
330
331
  const e = this.attachShadow({ mode: "open" });
331
- e.adoptedStyleSheets = [He];
332
+ e.adoptedStyleSheets = [Ge];
332
333
  const i = document.createElement("div");
333
- i.className = "static", i.innerHTML = '<slot name="static"></slot>', e.appendChild(i), h(this, Y, document.createElement("div")), t(this, Y).className = "content-wrapper", h(this, f, document.createElement("div")), t(this, f).className = "content", h(this, xt, document.createElement("slot")), t(this, f).appendChild(t(this, xt)), t(this, Y).appendChild(t(this, f)), e.appendChild(t(this, Y));
334
+ i.className = "static", i.innerHTML = '<slot name="static"></slot>', e.appendChild(i), n(this, st, document.createElement("div")), t(this, st).className = "content-wrapper", n(this, p, document.createElement("div")), t(this, p).className = "content", n(this, Lt, document.createElement("slot")), t(this, p).appendChild(t(this, Lt)), t(this, st).appendChild(t(this, p)), e.appendChild(t(this, st));
334
335
  }
335
336
  }
336
337
  get damped() {
337
338
  return t(this, u);
338
339
  }
339
340
  get controlsCSSProperty() {
340
- return t(this, ut);
341
+ return t(this, pt);
341
342
  }
342
343
  get axisCSSProperty() {
343
- return t(this, P);
344
+ return t(this, x);
344
345
  }
345
346
  get directionCSSProperty() {
346
- return t(this, O);
347
+ return t(this, H);
347
348
  }
348
349
  get pagesCSSProperty() {
349
- return t(this, R);
350
+ return t(this, B);
350
351
  }
351
352
  get splitCSSProperty() {
352
- return t(this, H);
353
+ return t(this, W);
353
354
  }
354
355
  get sectionalCSSProperty() {
355
- return t(this, I);
356
+ return t(this, D);
356
357
  }
357
358
  get easingCSSProperty() {
358
- return t(this, K);
359
+ return t(this, j);
359
360
  }
360
361
  get durationCSSProperty() {
361
- return t(this, _);
362
+ return t(this, J);
362
363
  }
363
364
  get autoSizeCSSProperty() {
364
- return t(this, B);
365
+ return t(this, F);
365
366
  }
366
367
  get wheelMaxDeltaCSSProperty() {
367
- return t(this, Z);
368
+ return t(this, Q);
368
369
  }
369
370
  get dragInertionCSSProperty() {
370
- return t(this, dt);
371
+ return t(this, mt);
371
372
  }
372
373
  get sectionsInViewCSSProperty() {
373
- return t(this, D);
374
+ return t(this, I);
374
375
  }
375
376
  get loopCSSProperty() {
376
- return t(this, C);
377
+ return t(this, y);
377
378
  }
378
379
  get dampingCSSProperty() {
379
- return t(this, ft);
380
+ return t(this, bt);
380
381
  }
381
382
  get massCSSProperty() {
382
- return t(this, pt);
383
+ return t(this, St);
383
384
  }
384
385
  get stiffnessCSSProperty() {
385
- return t(this, mt);
386
+ return t(this, gt);
386
387
  }
387
388
  get mouseDragCSSProperty() {
388
- return t(this, bt);
389
+ return t(this, vt);
389
390
  }
390
391
  get sectionDistanceScaleCSSProperty() {
391
- return t(this, wt);
392
+ return t(this, Pt);
392
393
  }
393
394
  get autoplayCSSProperty() {
394
- return t(this, k);
395
+ return t(this, z);
395
396
  }
396
397
  get autoplayPauseDurationCSSProperty() {
397
- return t(this, gt);
398
+ return t(this, yt);
398
399
  }
399
400
  get autoplayUserDirectionCSSProperty() {
400
- return t(this, j);
401
+ return t(this, X);
401
402
  }
402
403
  get classesCSSProperty() {
403
- return t(this, A);
404
+ return t(this, T);
404
405
  }
405
406
  get currentIndexStartOffsetCSSProperty() {
406
- return t(this, J);
407
+ return t(this, Y);
407
408
  }
408
409
  get currentIndexEndOffsetCSSProperty() {
409
- return t(this, F);
410
+ return t(this, $);
410
411
  }
411
412
  get focusDelayCSSProperty() {
412
- return t(this, Q);
413
+ return t(this, tt);
413
414
  }
414
415
  get focusDurationCSSProperty() {
415
- return t(this, St);
416
+ return t(this, Ct);
416
417
  }
417
418
  get disabledCSSProperty() {
418
- return t(this, vt);
419
+ return t(this, wt);
419
420
  }
420
421
  get hibernatedCSSProperty() {
421
- return t(this, X);
422
+ return t(this, et);
422
423
  }
423
424
  get currentScrollValue() {
424
- return d(this, o, ne).call(this, "current");
425
+ return d(this, o, de).call(this, "current");
425
426
  }
426
427
  get targetScrollValue() {
427
- return d(this, o, ne).call(this, "target");
428
+ return d(this, o, de).call(this, "target");
428
429
  }
429
430
  get contentWrapperElement() {
430
- return t(this, Y);
431
+ return t(this, st);
431
432
  }
432
433
  get contentElement() {
433
- return t(this, f);
434
+ return t(this, p);
434
435
  }
435
436
  get sections() {
436
437
  return t(this, l);
437
438
  }
438
439
  get position() {
439
- return t(this, Ft);
440
+ return t(this, Kt);
440
441
  }
441
442
  get contentPosition() {
442
- return t(this, Wt);
443
+ return t(this, _t);
443
444
  }
444
445
  get viewportSize() {
445
- return t(this, y);
446
+ return t(this, v);
446
447
  }
447
448
  get scrollSize() {
448
449
  return t(this, S);
449
450
  }
450
451
  get gap() {
451
- return t(this, L);
452
+ return t(this, P);
452
453
  }
453
454
  get counter() {
454
- return t(this, g);
455
+ return t(this, w);
455
456
  }
456
457
  get limit() {
457
458
  return Math.ceil(
458
- t(this, l).length - t(this, D).current
459
+ t(this, l).length - t(this, I).current
459
460
  );
460
461
  }
461
462
  get distance() {
462
- return t(this, et);
463
+ return t(this, rt);
463
464
  }
464
465
  get loopDistance() {
465
- return t(this, C).current ? t(this, et) + t(this, L) : t(this, et);
466
+ return t(this, y).current ? t(this, rt) + t(this, P) : t(this, rt);
466
467
  }
467
468
  get hasOverflow() {
468
- return t(this, W);
469
+ return t(this, q);
469
470
  }
470
471
  get overscroll() {
471
- return t(this, Pt);
472
+ return t(this, kt);
473
+ }
474
+ get scrollLine() {
475
+ return t(this, V);
472
476
  }
473
477
  get vertical() {
474
- return t(this, P).current === "y";
478
+ return t(this, x).current === "y";
475
479
  }
476
480
  get currentProgress() {
477
481
  return this.currentScrollValue / this.loopDistance || 0;
@@ -480,10 +484,10 @@ class Ht extends HTMLElement {
480
484
  return this.targetScrollValue / this.loopDistance || 0;
481
485
  }
482
486
  get scrollWidth() {
483
- return t(this, P).current === "y" ? 0 : t(this, u).distance;
487
+ return t(this, x).current === "y" ? 0 : t(this, u).distance;
484
488
  }
485
489
  get scrollHeight() {
486
- return t(this, P).current === "x" ? 0 : t(this, u).distance;
490
+ return t(this, x).current === "x" ? 0 : t(this, u).distance;
487
491
  }
488
492
  onScroll(...e) {
489
493
  return t(this, u).subscribe(...e);
@@ -492,36 +496,34 @@ class Ht extends HTMLElement {
492
496
  t(this, u).unsubscribe(...e);
493
497
  }
494
498
  //https://github.com/pmndrs/drei/blob/d3282cdd02d170ef603a5e096505d83dc93cd57a/src/web/ScrollControls.tsx#L85C7-L100C9
495
- range(e, i, n = 0) {
496
- const c = e - n, b = c + i + n * 2;
499
+ range(e, i, r = 0) {
500
+ const c = e - r, b = c + i + r * 2;
497
501
  return this.currentProgress < c ? 0 : this.currentProgress > b ? 1 : (this.currentProgress - c) / (b - c);
498
502
  }
499
- curve(e, i, n = 0) {
500
- return Math.sin(this.range(e, i, n) * Math.PI);
503
+ curve(e, i, r = 0) {
504
+ return Math.sin(this.range(e, i, r) * Math.PI);
501
505
  }
502
- visible(e, i, n = 0) {
503
- const c = e - n, b = c + i + n * 2;
506
+ visible(e, i, r = 0) {
507
+ const c = e - r, b = c + i + r * 2;
504
508
  return this.currentProgress >= c && this.currentProgress <= b;
505
509
  }
506
510
  scrollToSection(e, i) {
507
511
  if (!t(this, l).length)
508
512
  return;
509
- const n = t(this, g).current;
510
- d(this, o, ge).call(this, e);
511
- const c = t(this, l)[n], b = t(this, l)[t(this, g).current];
512
- if (c && b) {
513
- let x = 0;
514
- const Ct = d(this, o, he).call(this), ve = Ct ? this.targetScrollValue - Ct.position : 0;
515
- t(this, C).current ? t(this, g).current === 0 && n === t(this, l).length - 1 ? x = t(this, S) + t(this, y) - c.position + t(this, L) : t(this, g).current === t(this, l).length - 1 && n === 0 ? x = b.position - (t(this, S) + t(this, y) + t(this, L)) : x = b.position - c.position : x = b.position - c.position, this.shiftPosition(x - ve, i);
513
+ const r = t(this, w).current, c = d(this, o, Pe).call(this, e), b = t(this, l)[r], k = t(this, l)[c];
514
+ if (b && k) {
515
+ let O = 0;
516
+ const me = d(this, o, fe).call(this), ke = me ? this.targetScrollValue - me.position : 0;
517
+ t(this, y).current ? c === 0 && r === t(this, l).length - 1 ? O = t(this, S) + t(this, v) - b.position + t(this, P) : c === t(this, l).length - 1 && r === 0 ? O = k.position - (t(this, S) + t(this, v) + t(this, P)) : O = k.position - b.position : O = k.position - b.position, this.shiftPosition(O - ke, i);
516
518
  }
517
519
  }
518
520
  shiftSections(e, i) {
519
- t(this, l).length && this.scrollToSection(t(this, g).current + e, i);
521
+ t(this, l).length && this.scrollToSection(t(this, w).current + e, i);
520
522
  }
521
523
  setPosition(e, i) {
522
- d(this, o, re).call(this, Math.sign(e) || 1), i != null && i.tween ? t(this, it) || (t(this, $).set(t(this, u).current, { equalize: !0 }), t(this, $).set(e, ue({}, i.tween)), h(this, it, setTimeout(() => {
523
- h(this, it, void 0);
524
- }, i.tween.duration))) : t(this, u).set(e, {
524
+ d(this, o, ue).call(this, Math.sign(e) || 1), i != null && i.tween ? t(this, ht) || (t(this, N).set(t(this, u).current, { equalize: !0 }), t(this, N).set(e, ve({}, i.tween)), n(this, ht, setTimeout(() => {
525
+ n(this, ht, void 0);
526
+ }, i.tween.duration || 0))) : t(this, u).set(e, {
525
527
  equalize: (i == null ? void 0 : i.behaviour) === "instant"
526
528
  });
527
529
  }
@@ -529,174 +531,179 @@ class Ht extends HTMLElement {
529
531
  this.setPosition(t(this, u).target + e, i);
530
532
  }
531
533
  connectedCallback() {
532
- ct.register(this), h(this, u, new Le(0, {
534
+ dt.register(this), n(this, u, new Ve(0, {
533
535
  damping: 0.01,
534
536
  min: 0,
535
- order: Pe.SCROLL
536
- })), this.setAttribute("tabindex", "0"), h(this, T, new ke({ element: t(this, f) })), t(this, T).changeEvent.subscribe(t(this, kt)), h(this, tt, new Ie({
537
+ order: Me.SCROLL
538
+ })), this.setAttribute("tabindex", "0"), n(this, A, new Re({ element: t(this, p) })), t(this, A).changeEvent.subscribe(t(this, It)), n(this, it, new He({
537
539
  element: this
538
- })), t(this, tt).changeEvent.subscribe(
539
- t(this, kt)
540
- ), h(this, M, new De({ element: t(this, f) })), t(this, M).changeEvent.subscribe(t(this, kt)), h(this, E, new Ae({
540
+ })), t(this, it).changeEvent.subscribe(
541
+ t(this, It)
542
+ ), n(this, M, new Be({ element: t(this, p) })), t(this, M).changeEvent.subscribe(t(this, It)), n(this, C, new We({
541
543
  culling: this
542
- })), t(this, E).changeEvent.subscribe(t(this, qt)), t(this, P).subscribe(({ current: e }) => {
543
- t(this, f).style.flexDirection = e === "x" ? "row" : "column", t(this, T).axis = t(this, Z).current ? "max" : e, t(this, tt).dimension = e === "x" ? "width" : "height", t(this, M).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), this.isConnected && t(this, z).call(this);
544
- }), t(this, Z).subscribe((e) => {
545
- t(this, T).axis = e.current ? "max" : t(this, P).current;
546
- }), t(this, dt).subscribe((e) => {
544
+ })), t(this, C).changeEvent.subscribe(t(this, jt)), t(this, x).subscribe(({ current: e }) => {
545
+ t(this, p).style.flexDirection = e === "x" ? "row" : "column", t(this, A).axis = t(this, Q).current ? "max" : e, t(this, it).dimension = e === "x" ? "width" : "height", t(this, M).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), this.isConnected && t(this, L).call(this);
546
+ }), t(this, Q).subscribe((e) => {
547
+ t(this, A).axis = e.current ? "max" : t(this, x).current;
548
+ }), t(this, mt).subscribe((e) => {
547
549
  t(this, M).inertion = typeof e.current == "number" ? e.current : 1;
548
- }), t(this, R).subscribe(() => {
549
- this.isConnected && t(this, z).call(this);
550
- }), t(this, H).subscribe(({ current: e }) => {
551
- this.isConnected && (e ? d(this, o, Ot).call(this) : d(this, o, Et).call(this));
552
- }), t(this, I).subscribe((e) => {
553
- t(this, T).debounce = e.current, t(this, M).swipe = e.current, t(this, E).interval = e.current, this.isConnected && (e.current && !e.previous && !t(this, l).length ? d(this, o, Ot).call(this) : !e.current && e.previous && t(this, l).length && d(this, o, Et).call(this));
554
- }), t(this, B).subscribe((e) => {
555
- this.isConnected && (t(this, z).call(this), e.current && !e.previous && !t(this, l).length ? d(this, o, Ot).call(this) : !e.current && e.previous && t(this, l).length && d(this, o, Et).call(this));
550
+ }), t(this, B).subscribe(() => {
551
+ this.isConnected && t(this, L).call(this);
552
+ }), t(this, W).subscribe(({ current: e }) => {
553
+ this.isConnected && (e ? d(this, o, qt).call(this) : d(this, o, xt).call(this));
556
554
  }), t(this, D).subscribe((e) => {
557
- this.isConnected && (t(this, z).call(this), d(this, o, lt).call(this));
558
- }), t(this, C).subscribe((e) => {
559
- e.current ? (this.isConnected && (t(this, l).length || (t(this, H).current = !0)), t(this, l).length && (t(this, u).max = 1 / 0, t(this, u).min = -1 / 0)) : (h(this, Pt, 0), t(this, u).max = t(this, S), t(this, u).min = 0);
560
- }), t(this, ft).subscribe((e) => {
555
+ t(this, A).debounce = e.current, t(this, M).swipe = e.current, t(this, C).interval = e.current, this.isConnected && (e.current && !e.previous && !t(this, l).length ? d(this, o, qt).call(this) : !e.current && e.previous && t(this, l).length && d(this, o, xt).call(this));
556
+ }), t(this, F).subscribe((e) => {
557
+ this.isConnected && (t(this, L).call(this), e.current && !e.previous && !t(this, l).length ? d(this, o, qt).call(this) : !e.current && e.previous && t(this, l).length && d(this, o, xt).call(this));
558
+ }), t(this, I).subscribe((e) => {
559
+ this.isConnected && (t(this, L).call(this), d(this, o, ut).call(this));
560
+ }), t(this, y).subscribe((e) => {
561
+ e.current ? (this.isConnected && (t(this, l).length || (t(this, W).current = !0)), t(this, l).length && (t(this, u).max = 1 / 0, t(this, u).min = -1 / 0)) : (n(this, kt, 0), t(this, u).max = t(this, S), t(this, u).min = 0);
562
+ }), t(this, bt).subscribe((e) => {
561
563
  t(this, u).damping = e.current;
562
- }), t(this, pt).subscribe((e) => {
564
+ }), t(this, St).subscribe((e) => {
563
565
  t(this, u).mass = e.current;
564
- }), t(this, mt).subscribe((e) => {
566
+ }), t(this, gt).subscribe((e) => {
565
567
  t(this, u).stiffness = e.current;
566
- }), t(this, k).subscribe((e) => {
567
- t(this, E).speed = e.current, !t(this, st) && e.current && !e.previous ? t(this, E).connect() : !e.current && e.previous && t(this, E).disconnect();
568
- }), t(this, j).subscribe((e) => {
569
- e.current || (t(this, E).direction = 1);
570
- }), t(this, A).subscribe((e) => {
571
- this.isConnected && d(this, o, lt).call(this);
572
- }), t(this, J).subscribe((e) => {
573
- this.isConnected && t(this, A).current && d(this, o, lt).call(this);
574
- }), t(this, F).subscribe((e) => {
575
- this.isConnected && t(this, A).current && d(this, o, lt).call(this);
568
+ }), t(this, z).subscribe((e) => {
569
+ t(this, C).speed = e.current, !t(this, nt) && e.current && !e.previous ? t(this, C).connect() : !e.current && e.previous && t(this, C).disconnect();
570
+ }), t(this, X).subscribe((e) => {
571
+ e.current || (t(this, C).direction = 1);
572
+ }), t(this, T).subscribe((e) => {
573
+ this.isConnected && d(this, o, ut).call(this);
574
+ }), t(this, Y).subscribe((e) => {
575
+ this.isConnected && t(this, T).current && d(this, o, ut).call(this);
576
+ }), t(this, $).subscribe((e) => {
577
+ this.isConnected && t(this, T).current && d(this, o, ut).call(this);
576
578
  }), t(this, u).isRunning.subscribe((e) => {
577
579
  this.classList.toggle("active", e.current);
578
- }), t(this, g).subscribe((e) => {
579
- t(this, l).length && d(this, o, lt).call(this);
580
- }), t(this, $).subscribe((e) => {
581
- t(this, $).isRunning.current && t(this, u).set(e.current, { equalize: !0 });
582
- }), t(this, vt).subscribe((e) => {
583
- e.current && !e.previous ? d(this, o, Zt).call(this) : !e.current && e.previous && d(this, o, jt).call(this);
584
- }), t(this, X).subscribe((e) => {
580
+ }), t(this, w).subscribe((e) => {
581
+ t(this, l).length && d(this, o, ut).call(this);
582
+ }), t(this, N).subscribe((e) => {
583
+ t(this, N).isRunning.current && t(this, u).set(e.current, { equalize: !0 });
584
+ }), t(this, wt).subscribe((e) => {
585
585
  e.current && !e.previous ? d(this, o, se).call(this) : !e.current && e.previous && d(this, o, ie).call(this);
586
- }), t(this, ut).observe(), t(this, P).observe(), t(this, O).observe(), t(this, R).observe(), t(this, H).observe(), t(this, I).observe(), t(this, K).observe(), t(this, _).observe(), t(this, B).observe(), t(this, Z).observe(), t(this, dt).observe(), t(this, D).observe(), t(this, C).observe(), t(this, ft).observe(), t(this, pt).observe(), t(this, mt).observe(), t(this, bt).observe(), t(this, wt).observe(), t(this, k).observe(), t(this, k).observe(), t(this, gt).observe(), t(this, j).observe(), t(this, A).observe(), t(this, J).observe(), t(this, F).observe(), t(this, Q).observe(), t(this, St).observe(), t(this, vt).observe(), t(this, X).observe(), t(this, X).current || d(this, o, ie).call(this);
586
+ }), t(this, et).subscribe((e) => {
587
+ e.current && !e.previous ? d(this, o, ce).call(this) : !e.current && e.previous && d(this, o, ae).call(this);
588
+ }), t(this, pt).observe(), t(this, x).observe(), t(this, H).observe(), t(this, B).observe(), t(this, W).observe(), t(this, D).observe(), t(this, j).observe(), t(this, J).observe(), t(this, F).observe(), t(this, Q).observe(), t(this, mt).observe(), t(this, I).observe(), t(this, y).observe(), t(this, bt).observe(), t(this, St).observe(), t(this, gt).observe(), t(this, vt).observe(), t(this, Pt).observe(), t(this, z).observe(), t(this, z).observe(), t(this, yt).observe(), t(this, X).observe(), t(this, T).observe(), t(this, Y).observe(), t(this, $).observe(), t(this, tt).observe(), t(this, Ct).observe(), t(this, wt).observe(), t(this, et).observe(), t(this, et).current || d(this, o, ae).call(this);
587
589
  }
588
590
  disconnectedCallback() {
589
- this.removeAttribute("tabindex"), this.classList.remove("has-overflow"), t(this, ut).unobserve(), t(this, P).unobserve(), t(this, O).unobserve(), t(this, R).unobserve(), t(this, H).unobserve(), t(this, I).unobserve(), t(this, K).unobserve(), t(this, _).unobserve(), t(this, B).unobserve(), t(this, Z).unobserve(), t(this, dt).unobserve(), t(this, D).unobserve(), t(this, C).unobserve(), t(this, ft).unobserve(), t(this, pt).unobserve(), t(this, mt).unobserve(), t(this, bt).unobserve(), t(this, wt).unobserve(), t(this, k).unobserve(), t(this, gt).unobserve(), t(this, j).unobserve(), t(this, A).unobserve(), t(this, J).unobserve(), t(this, F).unobserve(), t(this, Q).unobserve(), t(this, St).unobserve(), t(this, vt).unobserve(), t(this, X).unobserve(), d(this, o, se).call(this);
591
+ this.removeAttribute("tabindex"), this.classList.remove("has-overflow"), t(this, pt).unobserve(), t(this, x).unobserve(), t(this, H).unobserve(), t(this, B).unobserve(), t(this, W).unobserve(), t(this, D).unobserve(), t(this, j).unobserve(), t(this, J).unobserve(), t(this, F).unobserve(), t(this, Q).unobserve(), t(this, mt).unobserve(), t(this, I).unobserve(), t(this, y).unobserve(), t(this, bt).unobserve(), t(this, St).unobserve(), t(this, gt).unobserve(), t(this, vt).unobserve(), t(this, Pt).unobserve(), t(this, z).unobserve(), t(this, yt).unobserve(), t(this, X).unobserve(), t(this, T).unobserve(), t(this, Y).unobserve(), t(this, $).unobserve(), t(this, tt).unobserve(), t(this, Ct).unobserve(), t(this, wt).unobserve(), t(this, et).unobserve(), d(this, o, ce).call(this);
590
592
  }
591
593
  }
592
- u = new WeakMap(), ut = new WeakMap(), P = new WeakMap(), O = new WeakMap(), R = new WeakMap(), H = new WeakMap(), I = new WeakMap(), K = new WeakMap(), _ = new WeakMap(), B = new WeakMap(), Z = new WeakMap(), dt = new WeakMap(), D = new WeakMap(), C = new WeakMap(), ft = new WeakMap(), pt = new WeakMap(), mt = new WeakMap(), bt = new WeakMap(), wt = new WeakMap(), k = new WeakMap(), gt = new WeakMap(), j = new WeakMap(), A = new WeakMap(), J = new WeakMap(), F = new WeakMap(), Q = new WeakMap(), St = new WeakMap(), vt = new WeakMap(), X = new WeakMap(), Y = new WeakMap(), f = new WeakMap(), xt = new WeakMap(), l = new WeakMap(), Ft = new WeakMap(), Wt = new WeakMap(), y = new WeakMap(), S = new WeakMap(), L = new WeakMap(), T = new WeakMap(), tt = new WeakMap(), M = new WeakMap(), E = new WeakMap(), g = new WeakMap(), Pt = new WeakMap(), et = new WeakMap(), W = new WeakMap(), st = new WeakMap(), yt = new WeakMap(), Lt = new WeakMap(), it = new WeakMap(), $ = new WeakMap(), $t = new WeakMap(), o = new WeakSet(), Ot = function() {
593
- d(this, o, Et).call(this), t(this, xt).assignedElements().forEach((e, i) => {
594
- e instanceof HTMLElement && t(this, l).push(new Re(e, i, this));
595
- }), t(this, f).style.transform = "", Yt(this, "scrollSectionsChange", {
594
+ u = new WeakMap(), pt = new WeakMap(), x = new WeakMap(), H = new WeakMap(), B = new WeakMap(), W = new WeakMap(), D = new WeakMap(), j = new WeakMap(), J = new WeakMap(), F = new WeakMap(), Q = new WeakMap(), mt = new WeakMap(), I = new WeakMap(), y = new WeakMap(), bt = new WeakMap(), St = new WeakMap(), gt = new WeakMap(), vt = new WeakMap(), Pt = new WeakMap(), z = new WeakMap(), yt = new WeakMap(), X = new WeakMap(), T = new WeakMap(), Y = new WeakMap(), $ = new WeakMap(), tt = new WeakMap(), Ct = new WeakMap(), wt = new WeakMap(), et = new WeakMap(), st = new WeakMap(), p = new WeakMap(), Lt = new WeakMap(), l = new WeakMap(), Kt = new WeakMap(), _t = new WeakMap(), v = new WeakMap(), S = new WeakMap(), P = new WeakMap(), A = new WeakMap(), it = new WeakMap(), M = new WeakMap(), C = new WeakMap(), w = new WeakMap(), kt = new WeakMap(), rt = new WeakMap(), q = new WeakMap(), nt = new WeakMap(), Et = new WeakMap(), zt = new WeakMap(), ht = new WeakMap(), N = new WeakMap(), Zt = new WeakMap(), V = new WeakMap(), o = new WeakSet(), qt = function() {
595
+ d(this, o, xt).call(this), t(this, Lt).assignedElements().forEach((e, i) => {
596
+ e instanceof HTMLElement && t(this, l).push(new Ue(e, i, this));
597
+ }), t(this, p).style.transform = "", ee(this, "scrollSectionsChange", {
596
598
  custom: !0,
597
599
  composed: !0
598
- }), t(this, z).call(this), d(this, o, lt).call(this);
599
- }, Et = function() {
600
+ }), t(this, L).call(this), d(this, o, ut).call(this);
601
+ }, xt = function() {
600
602
  t(this, l).forEach((e) => {
601
603
  e.destroy();
602
- }), h(this, l, []), t(this, g).reset(), t(this, u).reset(), Yt(this, "scrollSectionsChange", {
604
+ }), n(this, l, []), t(this, w).reset(), t(this, u).reset(), ee(this, "scrollSectionsChange", {
603
605
  custom: !0,
604
606
  composed: !0
605
607
  });
606
- }, Zt = function() {
607
- t(this, st) || (h(this, st, !0), t(this, u).unsubscribe(t(this, zt)), t(this, u).unlistenAnimationFrame(), clearInterval(t(this, Lt)), clearInterval(t(this, it)), t(this, $).unlistenAnimationFrame(), t(this, T).disconnect(), t(this, tt).disconnect(), t(this, M).disconnect(), t(this, E).disconnect(), t(this, W) || this.sections.forEach((e) => {
608
+ }, se = function() {
609
+ t(this, nt) || (n(this, nt, !0), t(this, u).unsubscribe(t(this, Dt)), t(this, u).unlistenAnimationFrame(), clearInterval(t(this, zt)), clearInterval(t(this, ht)), t(this, N).unlistenAnimationFrame(), t(this, A).disconnect(), t(this, it).disconnect(), t(this, M).disconnect(), t(this, C).disconnect(), t(this, q) || this.sections.forEach((e) => {
608
610
  e.unsetTransform();
609
611
  }));
610
- }, jt = function() {
611
- t(this, st) && (h(this, st, !1), t(this, u).subscribe(t(this, zt)), t(this, T).connect(), t(this, tt).connect(), t(this, M).connect(), t(this, k).current && t(this, E).connect());
612
- }, se = function() {
613
- t(this, yt) || (h(this, yt, !0), Jt.unsubscribe(t(this, z)), Rt.unsubscribe(t(this, z)), d(this, o, Zt).call(this), t(this, f).style.transform = "", t(this, l).length ? d(this, o, Et).call(this) : (t(this, g).reset(), t(this, u).reset()), ct.unregister(this));
614
612
  }, ie = function() {
615
- t(this, yt) && (h(this, yt, !1), ct.register(this), (t(this, C).current || t(this, H).current || t(this, C).current || t(this, B).current || t(this, I).current) && d(this, o, Ot).call(this), d(this, o, jt).call(this), Jt.subscribe(t(this, z), me.SCROLL), Rt.subscribe(this, t(this, z)));
616
- }, z = new WeakMap(), zt = new WeakMap(), ge = function(e) {
617
- t(this, C).current ? (t(this, g).current = e % t(this, l).length, t(this, g).current = t(this, g).current < 0 ? t(this, l).length + t(this, g).current : t(this, g).current) : t(this, g).current = pe(e, 0, this.limit);
618
- }, kt = new WeakMap(), qt = new WeakMap(), re = function(e = 1) {
619
- t(this, j).current && (t(this, E).direction = e), t(this, k).current && t(this, E).pauseAndContinue(
620
- t(this, gt).current,
613
+ t(this, nt) && (n(this, nt, !1), t(this, u).subscribe(t(this, Dt)), t(this, A).connect(), t(this, it).connect(), t(this, M).connect(), t(this, z).current && t(this, C).connect());
614
+ }, ce = function() {
615
+ t(this, Et) || (n(this, Et, !0), re.unsubscribe(t(this, L)), Nt.unsubscribe(t(this, L)), d(this, o, se).call(this), t(this, p).style.transform = "", t(this, l).length ? d(this, o, xt).call(this) : (t(this, w).reset(), t(this, u).reset()), dt.unregister(this));
616
+ }, ae = function() {
617
+ t(this, Et) && (n(this, Et, !1), dt.register(this), (t(this, y).current || t(this, W).current || t(this, y).current || t(this, F).current || t(this, D).current) && d(this, o, qt).call(this), d(this, o, ie).call(this), re.subscribe(t(this, L), Ee.SCROLL), Nt.subscribe(this, t(this, L)));
618
+ }, L = new WeakMap(), Dt = new WeakMap(), Pe = function(e) {
619
+ let i = t(this, w).current;
620
+ return t(this, y).current ? (i = e % t(this, l).length, i = i < 0 ? t(this, l).length + i : i) : i = we(e, 0, this.limit), i;
621
+ }, It = new WeakMap(), jt = new WeakMap(), ue = function(e = 1) {
622
+ t(this, X).current && (t(this, C).direction = e), t(this, z).current && t(this, C).pauseAndContinue(
623
+ t(this, yt).current,
621
624
  this.sectionalCSSProperty.current
622
625
  );
623
- }, ne = function(e = "current") {
624
- if (t(this, C).current && t(this, l).length) {
625
- const i = t(this, u)[e] % (t(this, S) + t(this, y) + t(this, L));
626
- return i < 0 ? t(this, S) + i + t(this, y) + t(this, L) : i;
626
+ }, de = function(e = "current") {
627
+ if (t(this, y).current && t(this, l).length) {
628
+ const i = t(this, u)[e] % (t(this, S) + t(this, v) + t(this, P));
629
+ return i < 0 ? t(this, S) + i + t(this, v) + t(this, P) : i;
627
630
  } else
628
631
  return t(this, u)[e];
629
- }, lt = function() {
630
- if (t(this, A).current && t(this, l).length) {
631
- const e = t(this, g).current + t(this, J).current;
632
- e === 0 ? this.classList.add("start") : this.classList.remove("start"), e === this.limit ? this.classList.add("end") : this.classList.remove("end");
633
- const i = t(this, D).current + t(this, F).current;
634
- t(this, l).forEach((n, c) => {
635
- const b = e - this.limit - 1 + t(this, F).current, x = e + i, Ct = this.sections.length - x;
636
- c >= e && c < x || c <= b ? n.mark("current") : c >= x && c < x + Ct / 2 || c <= b + i ? n.mark("next") : n.mark("previous");
637
- });
632
+ }, ut = function() {
633
+ if (t(this, l).length) {
634
+ const e = t(this, w).current + t(this, Y).current;
635
+ if (e === 0 ? n(this, V, "start") : e === this.limit ? n(this, V, "end") : n(this, V, null), ee(this, "scrollLine", {
636
+ detail: { line: t(this, V) }
637
+ }), t(this, T).current) {
638
+ this.classList.remove("end", "start"), t(this, V) && this.classList.add(t(this, V));
639
+ const i = t(this, I).current + t(this, $).current;
640
+ t(this, l).forEach((r, c) => {
641
+ const b = e - this.limit - 1 + t(this, $).current, k = e + i, O = this.sections.length - k;
642
+ c >= e && c < k || c <= b ? r.mark("current") : c >= k && c < k + O / 2 || c <= b + i ? r.mark("next") : r.mark("previous");
643
+ });
644
+ }
638
645
  }
639
- }, he = function(e = this.targetScrollValue) {
640
- let i = null, n = 1 / 0;
646
+ }, fe = function(e = this.targetScrollValue) {
647
+ let i = null, r = 1 / 0;
641
648
  for (let c = 0; c < t(this, l).length; c++) {
642
649
  const b = Math.abs(t(this, l)[c].position - e);
643
- b < n && (n = b, i = c);
650
+ b < r && (r = b, i = c);
644
651
  }
645
652
  return i !== null ? t(this, l)[i] : null;
646
653
  };
647
- customElements.get("e-scroll") || customElements.define("e-scroll", Ht);
648
- var Nt;
649
- class oe extends HTMLElement {
654
+ customElements.get("e-scroll") || customElements.define("e-scroll", Ut);
655
+ var Jt;
656
+ class pe extends HTMLElement {
650
657
  constructor() {
651
658
  super(...arguments);
652
- s(this, Nt, null);
659
+ s(this, Jt, null);
653
660
  }
654
661
  get scrollElement() {
655
- return t(this, Nt);
662
+ return t(this, Jt);
656
663
  }
657
664
  connectedCallback() {
658
- const e = be(this, Ht);
659
- e instanceof Ht ? h(this, Nt, e) : console.error(this, "e-scroll not found");
665
+ const e = xe(this, Ut);
666
+ e instanceof Ut ? n(this, Jt, e) : console.error(this, "e-scroll not found");
660
667
  }
661
668
  }
662
- Nt = new WeakMap();
663
- var rt, w, q, N, It, Dt, nt, At, Ut, Gt;
664
- class Be extends oe {
669
+ Jt = new WeakMap();
670
+ var ot, E, U, G, Tt, At, lt, Mt, Qt, Xt;
671
+ class Ke extends pe {
665
672
  constructor() {
666
673
  super();
667
- s(this, rt, null);
668
- s(this, w, null);
669
- s(this, q, !1);
670
- s(this, N, 0);
671
- s(this, It, 0);
672
- s(this, Dt, 0);
673
- s(this, nt, () => {
674
- h(this, q, this.offsetWidth > this.offsetHeight);
675
- const e = t(this, q) ? this.offsetWidth : this.offsetHeight;
676
- h(this, N, e / ((this.scrollElement.scrollSize + this.scrollElement.viewportSize) / e)), h(this, N, Math.max(t(this, N), 30)), t(this, q) ? (t(this, w).style.width = t(this, N) + "px", t(this, w).style.height = "100%") : (t(this, w).style.width = "100%", t(this, w).style.height = t(this, N) + "px"), h(this, It, e - t(this, N)), this.scrollElement.scrollSize ? this.style.display = "" : this.style.display = "none", t(this, At).call(this);
674
+ s(this, ot, null);
675
+ s(this, E, null);
676
+ s(this, U, !1);
677
+ s(this, G, 0);
678
+ s(this, Tt, 0);
679
+ s(this, At, 0);
680
+ s(this, lt, () => {
681
+ n(this, U, this.offsetWidth > this.offsetHeight);
682
+ const e = t(this, U) ? this.offsetWidth : this.offsetHeight;
683
+ n(this, G, e / ((this.scrollElement.scrollSize + this.scrollElement.viewportSize) / e)), n(this, G, Math.max(t(this, G), 30)), t(this, U) ? (t(this, E).style.width = t(this, G) + "px", t(this, E).style.height = "100%") : (t(this, E).style.width = "100%", t(this, E).style.height = t(this, G) + "px"), n(this, Tt, e - t(this, G)), this.scrollElement.scrollSize ? this.style.display = "" : this.style.display = "none", t(this, Mt).call(this);
677
684
  });
678
- s(this, At, () => {
679
- h(this, Dt, this.scrollElement.currentProgress * t(this, It)), t(this, q) ? t(this, w).style.transform = `translate3d(${t(this, Dt)}px, 0px, 0px)` : t(this, w).style.transform = `translate3d(0px, ${t(this, Dt)}px, 0px)`;
685
+ s(this, Mt, () => {
686
+ n(this, At, this.scrollElement.currentProgress * t(this, Tt)), t(this, U) ? t(this, E).style.transform = `translate3d(${t(this, At)}px, 0px, 0px)` : t(this, E).style.transform = `translate3d(0px, ${t(this, At)}px, 0px)`;
680
687
  });
681
- s(this, Ut, () => {
688
+ s(this, Qt, () => {
682
689
  this.setAttribute("axis", this.scrollElement.axisCSSProperty.current);
683
690
  });
684
- s(this, Gt, (e) => {
685
- document.documentElement.classList.add("grabbing"), Me(
691
+ s(this, Xt, (e) => {
692
+ document.documentElement.classList.add("grabbing"), $e(
686
693
  (c) => {
687
- const b = t(this, q) ? c.x : c.y, x = this.scrollElement.distance / t(this, It), Ct = (b - n) * x;
688
- this.scrollElement.setPosition(i + Ct);
694
+ const b = t(this, U) ? c.x : c.y, k = this.scrollElement.distance / t(this, Tt), O = (b - r) * k;
695
+ this.scrollElement.setPosition(i + O);
689
696
  },
690
697
  () => {
691
698
  document.documentElement.classList.remove("grabbing");
692
699
  }
693
700
  );
694
- const i = this.scrollElement.damped.target, n = t(this, q) ? e.x : e.y;
701
+ const i = this.scrollElement.damped.target, r = t(this, U) ? e.x : e.y;
695
702
  });
696
- if (Qt) {
703
+ if (ne) {
697
704
  const e = this.attachShadow({ mode: "open" });
698
705
  e.adoptedStyleSheets = [
699
- fe({
706
+ Ce({
700
707
  ":host": {
701
708
  display: "inline-block",
702
709
  zIndex: "1",
@@ -725,123 +732,166 @@ class Be extends oe {
725
732
  touchAction: "none"
726
733
  }
727
734
  })
728
- ], h(this, rt, document.createElement("slot")), t(this, rt).innerHTML = '<div class="default-thumb"></div>', e.appendChild(t(this, rt));
735
+ ], n(this, ot, document.createElement("slot")), t(this, ot).innerHTML = '<div class="default-thumb"></div>', e.appendChild(t(this, ot));
729
736
  }
730
737
  }
731
738
  get thumbElement() {
732
- return t(this, w);
739
+ return t(this, E);
733
740
  }
734
741
  connectedCallback() {
735
742
  super.connectedCallback(), this.setAttribute("drag-dead-zone", "");
736
- const e = t(this, rt).assignedElements()[0] || t(this, rt).firstElementChild;
737
- h(this, w, e), t(this, w).addEventListener("pointerdown", t(this, Gt)), Jt.subscribe(t(this, nt), me.SCROLL), Rt.subscribe(this, t(this, nt)), Rt.subscribe(this.scrollElement, t(this, nt)), this.scrollElement.onScroll(t(this, At)), this.scrollElement.axisCSSProperty.subscribe(t(this, Ut));
743
+ const e = t(this, ot).assignedElements()[0] || t(this, ot).firstElementChild;
744
+ n(this, E, e), t(this, E).addEventListener("pointerdown", t(this, Xt)), re.subscribe(t(this, lt), Ee.SCROLL), Nt.subscribe(this, t(this, lt)), Nt.subscribe(this.scrollElement, t(this, lt)), this.scrollElement.onScroll(t(this, Mt)), this.scrollElement.axisCSSProperty.subscribe(t(this, Qt));
738
745
  }
739
746
  disconnectedCallback() {
740
- this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this, w).removeEventListener("pointerdown", t(this, Gt)), Jt.unsubscribe(t(this, nt)), Rt.unsubscribe(t(this, nt)), this.scrollElement.offScroll(t(this, At)), this.scrollElement.axisCSSProperty.unsubscribe(t(this, Ut));
747
+ this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this, E).removeEventListener("pointerdown", t(this, Xt)), re.unsubscribe(t(this, lt)), Nt.unsubscribe(t(this, lt)), this.scrollElement.offScroll(t(this, Mt)), this.scrollElement.axisCSSProperty.unsubscribe(t(this, Qt));
741
748
  }
742
749
  }
743
- rt = new WeakMap(), w = new WeakMap(), q = new WeakMap(), N = new WeakMap(), It = new WeakMap(), Dt = new WeakMap(), nt = new WeakMap(), At = new WeakMap(), Ut = new WeakMap(), Gt = new WeakMap();
744
- customElements.get("e-scrollbar") || customElements.define("e-scrollbar", Be);
745
- class Se extends oe {
750
+ ot = new WeakMap(), E = new WeakMap(), U = new WeakMap(), G = new WeakMap(), Tt = new WeakMap(), At = new WeakMap(), lt = new WeakMap(), Mt = new WeakMap(), Qt = new WeakMap(), Xt = new WeakMap();
751
+ customElements.get("e-scrollbar") || customElements.define("e-scrollbar", Ke);
752
+ var Vt, Ot, Rt;
753
+ class Le extends pe {
746
754
  constructor() {
747
- super(), Qt && this.addEventListener("click", () => {
748
- const r = this.getAttribute("behaviour"), e = this.getAttribute("easing") || void 0, i = e ? parseFloat(this.getAttribute("duration") || "0") : void 0;
755
+ super();
756
+ s(this, Vt, new f(this, "--behaviour", "smooth"));
757
+ s(this, Ot, new f(
758
+ this,
759
+ "--tween-easing",
760
+ !1
761
+ ));
762
+ s(this, Rt, new f(this, "--tween-duration", 0));
763
+ ne && this.addEventListener("click", () => {
764
+ const e = t(this, Vt).current, i = t(this, Ot).current, r = t(this, Rt).current;
749
765
  this.handleClick({
750
- behaviour: r,
751
- tween: e ? { easing: e, duration: i } : void 0
766
+ behaviour: e,
767
+ tween: i || r ? { easing: i, duration: r } : void 0
752
768
  });
753
769
  });
754
770
  }
771
+ connectedCallback() {
772
+ super.connectedCallback(), t(this, Vt).observe(), t(this, Ot).observe(), t(this, Rt).observe();
773
+ }
774
+ disconnectedCallback() {
775
+ t(this, Vt).close(), t(this, Ot).close(), t(this, Rt).close();
776
+ }
755
777
  }
756
- class Fe extends Se {
757
- handleClick(r) {
758
- const e = this.getAttribute("index");
759
- this.scrollElement.scrollToSection(parseInt(e || "0"), r);
778
+ Vt = new WeakMap(), Ot = new WeakMap(), Rt = new WeakMap();
779
+ var Ht;
780
+ class _e extends Le {
781
+ constructor() {
782
+ super(...arguments);
783
+ s(this, Ht, new f(this, "--set", 1));
784
+ }
785
+ handleClick(e) {
786
+ this.scrollElement.scrollToSection(t(this, Ht).current, e);
787
+ }
788
+ connectedCallback() {
789
+ super.connectedCallback(), t(this, Ht).observe();
790
+ }
791
+ disconnectedCallback() {
792
+ super.disconnectedCallback(), t(this, Ht).close();
760
793
  }
761
794
  }
762
- customElements.get("e-scroll-set-button") || customElements.define("e-scroll-set-button", Fe);
763
- class We extends Se {
764
- handleClick(r) {
765
- const e = this.getAttribute("step");
766
- this.scrollElement.shiftSections(parseInt(e || "1"), r);
795
+ Ht = new WeakMap();
796
+ customElements.get("e-scroll-set-button") || customElements.define("e-scroll-set-button", _e);
797
+ var K, Bt;
798
+ class Ze extends Le {
799
+ constructor() {
800
+ super(...arguments);
801
+ s(this, K, new f(this, "--step", 1));
802
+ s(this, Bt, () => {
803
+ this.scrollElement.loopCSSProperty.current ? this.removeAttribute("disabled") : t(this, K).current > 0 && this.scrollElement.scrollLine === "end" || t(this, K).current < 0 && this.scrollElement.scrollLine === "start" ? this.setAttribute("disabled", "") : this.removeAttribute("disabled");
804
+ });
805
+ }
806
+ handleClick(e) {
807
+ this.scrollElement.shiftSections(t(this, K).current, e);
808
+ }
809
+ connectedCallback() {
810
+ super.connectedCallback(), t(this, K).subscribe(() => {
811
+ t(this, Bt).call(this);
812
+ }), t(this, K).observe(), this.scrollElement.addEventListener("scrollLine", t(this, Bt)), t(this, Bt).call(this);
813
+ }
814
+ disconnectedCallback() {
815
+ super.disconnectedCallback(), t(this, K).close(), this.removeAttribute("disabled");
767
816
  }
768
817
  }
769
- customElements.get("e-scroll-step-button") || customElements.define("e-scroll-step-button", We);
770
- var U, ht, Tt, Kt, _t, Mt;
771
- class $e {
772
- constructor(r, e, i) {
773
- s(this, U, null);
774
- s(this, ht, null);
775
- s(this, Tt, null);
776
- s(this, Kt, null);
777
- s(this, _t, () => {
778
- t(this, ht).scrollToSection(t(this, Tt), {
779
- behaviour: t(this, Kt)
818
+ K = new WeakMap(), Bt = new WeakMap();
819
+ customElements.get("e-scroll-step-button") || customElements.define("e-scroll-step-button", Ze);
820
+ var _, ct, Wt, Yt, te, Ft;
821
+ class je {
822
+ constructor(h, e, i) {
823
+ s(this, _, null);
824
+ s(this, ct, null);
825
+ s(this, Wt, null);
826
+ s(this, Yt, null);
827
+ s(this, te, () => {
828
+ t(this, ct).scrollToSection(t(this, Wt), {
829
+ behaviour: t(this, Yt)
780
830
  });
781
831
  });
782
- s(this, Mt, () => {
783
- t(this, U).classList.toggle(
832
+ s(this, Ft, () => {
833
+ t(this, _).classList.toggle(
784
834
  "current",
785
- t(this, ht).counter.current === t(this, Tt)
835
+ t(this, ct).counter.current === t(this, Wt)
786
836
  );
787
837
  });
788
- Qt && (h(this, U, document.createElement("button")), h(this, ht, r), h(this, Kt, i), h(this, Tt, e), t(this, U).addEventListener("click", t(this, _t)), t(this, ht).counter.subscribe(t(this, Mt)), t(this, Mt).call(this));
838
+ ne && (n(this, _, document.createElement("button")), n(this, ct, h), n(this, Yt, i), n(this, Wt, e), t(this, _).addEventListener("click", t(this, te)), t(this, ct).counter.subscribe(t(this, Ft)), t(this, Ft).call(this));
789
839
  }
790
840
  get element() {
791
- return t(this, U);
841
+ return t(this, _);
792
842
  }
793
843
  destroy() {
794
- t(this, U).removeEventListener("click", t(this, _t)), t(this, ht).counter.unsubscribe(t(this, Mt)), t(this, U).remove();
844
+ t(this, _).removeEventListener("click", t(this, te)), t(this, ct).counter.unsubscribe(t(this, Ft)), t(this, _).remove();
795
845
  }
796
846
  }
797
- U = new WeakMap(), ht = new WeakMap(), Tt = new WeakMap(), Kt = new WeakMap(), _t = new WeakMap(), Mt = new WeakMap();
798
- var ot, Vt;
799
- class qe extends oe {
847
+ _ = new WeakMap(), ct = new WeakMap(), Wt = new WeakMap(), Yt = new WeakMap(), te = new WeakMap(), Ft = new WeakMap();
848
+ var at, $t;
849
+ class Je extends pe {
800
850
  constructor() {
801
851
  super(...arguments);
802
- s(this, ot, []);
803
- s(this, Vt, Ve(() => {
804
- t(this, ot).forEach((e) => e.destroy()), h(this, ot, []);
852
+ s(this, at, []);
853
+ s(this, $t, qe(() => {
854
+ t(this, at).forEach((e) => e.destroy()), n(this, at, []);
805
855
  for (let e = 0; e < this.scrollElement.sections.length; e++) {
806
- const i = new $e(
856
+ const i = new je(
807
857
  this.scrollElement,
808
858
  e,
809
859
  this.getAttribute("behaviour") || "smooth"
810
860
  );
811
- this.appendChild(i.element), t(this, ot).push(i);
861
+ this.appendChild(i.element), t(this, at).push(i);
812
862
  }
813
863
  }, 0));
814
864
  }
815
865
  connectedCallback() {
816
866
  super.connectedCallback(), this.scrollElement.addEventListener(
817
867
  "sectionsChange",
818
- t(this, Vt)
819
- ), t(this, Vt).call(this);
868
+ t(this, $t)
869
+ ), t(this, $t).call(this);
820
870
  }
821
871
  disconnectedCallback() {
822
872
  this.scrollElement.removeEventListener(
823
873
  "sectionsChange",
824
- t(this, Vt)
825
- ), t(this, ot).forEach((e) => e.destroy()), h(this, ot, []);
874
+ t(this, $t)
875
+ ), t(this, at).forEach((e) => e.destroy()), n(this, at, []);
826
876
  }
827
877
  }
828
- ot = new WeakMap(), Vt = new WeakMap();
829
- customElements.get("e-scroll-bullet-buttons") || customElements.define("e-scroll-bullet-buttons", qe);
830
- class Ne extends Oe {
878
+ at = new WeakMap(), $t = new WeakMap();
879
+ customElements.get("e-scroll-bullet-buttons") || customElements.define("e-scroll-bullet-buttons", Je);
880
+ class Qe extends Ne {
831
881
  connectedCallback() {
832
- const r = be(this, Ht);
833
- r instanceof Ht ? (this.scrollContainer = r, this.scrollContainer.addEventListener(
882
+ const h = xe(this, Ut);
883
+ h instanceof Ut ? (this.scrollContainer = h, this.scrollContainer.addEventListener(
834
884
  "scrollSectionsChange",
835
885
  this.findAnotherScrollEntries
836
886
  )) : console.error(this, "e-scroll not found");
837
887
  }
838
888
  }
839
- customElements.get("e-scroll-segment") || customElements.define("e-scroll-segment", Ne);
889
+ customElements.get("e-scroll-segment") || customElements.define("e-scroll-segment", Qe);
840
890
  export {
841
- qe as ScrollBulletButtonsElement,
842
- Ht as ScrollElement,
843
- Ne as ScrollSegmentElement,
844
- Fe as ScrollSetButtonElement,
845
- We as ScrollStepButtonElement,
846
- Be as ScrollbarElement
891
+ Je as ScrollBulletButtonsElement,
892
+ Ut as ScrollElement,
893
+ Qe as ScrollSegmentElement,
894
+ _e as ScrollSetButtonElement,
895
+ Ze as ScrollStepButtonElement,
896
+ Ke as ScrollbarElement
847
897
  };