aptechka 0.4.21 → 0.4.23

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,84 +1,84 @@
1
- var as = (e, i, r) => {
2
- if (!i.has(e))
1
+ var os = (s, i, r) => {
2
+ if (!i.has(s))
3
3
  throw TypeError("Cannot " + r);
4
4
  };
5
- var a = (e, i, r) => (as(e, i, "read from private field"), r ? r.call(e) : i.get(e)), $ = (e, i, r) => {
6
- if (i.has(e))
5
+ var a = (s, i, r) => (os(s, i, "read from private field"), r ? r.call(s) : i.get(s)), $ = (s, i, r) => {
6
+ if (i.has(s))
7
7
  throw TypeError("Cannot add the same private member more than once");
8
- i instanceof WeakSet ? i.add(e) : i.set(e, r);
9
- }, R = (e, i, r, h) => (as(e, i, "write to private field"), h ? h.call(e, r) : i.set(e, r), r);
10
- import { D as $s } from "../Damped-DpaKIZqv.js";
11
- import { i as Ze } from "../browser-0zX67oeU.js";
12
- import { a as ke, g as Pe } from "../layout-HoBT_Da2.js";
13
- import { c as Je, s as Fs, b as Os, a as Ds } from "../math-BOBiC4TN.js";
8
+ i instanceof WeakSet ? i.add(s) : i.set(s, r);
9
+ }, R = (s, i, r, h) => (os(s, i, "write to private field"), h ? h.call(s, r) : i.set(s, r), r);
10
+ import { D as Ds } from "../Damped-DpaKIZqv.js";
11
+ import { i as Je } from "../browser-0zX67oeU.js";
12
+ import { a as Pe, g as We } from "../layout-HoBT_Da2.js";
13
+ import { c as Qe, s as Rs, b as Ts, a as As } from "../math-BOBiC4TN.js";
14
14
  import "../path-data-polyfill-DgeDWYeI.js";
15
15
  import { S as mt } from "../Store-Cd-E5W1z.js";
16
- import { D as Rs } from "../Derived-DH-ouLBq.js";
16
+ import { D as Is } from "../Derived-DH-ouLBq.js";
17
17
  import "../ticker/index.js";
18
- import { W as Ts, K as As, D as Is } from "../DragControls-Ch_JO2ML.js";
19
- import { CustomElement as gs, define as qt } from "../custom-element/index.js";
20
- import { TICK_ORDER as Bs, RESIZE_ORDER as Qe } from "../order/index.js";
21
- import { windowResizer as Gt } from "../window-resizer/index.js";
22
- import { scrollEntries as xt } from "../scroll-entries/index.js";
23
- import { e as Xe, D as Oe, ay as We, p as Hs } from "../tags-BoPv9fDr.js";
24
- import { c as Ye } from "../createStylesheet-KMRQhSa-.js";
25
- import { cssUnitParser as os } from "../css-unit-parser/index.js";
26
- import { CSSProperty as f } from "../css-property/index.js";
27
- import { d as Gs } from "../Viewport-Bx-VImCe.js";
28
- import { s as Ks } from "../gestures-D2Fdra_G.js";
29
- import { aptechkaTheme as ls } from "../theme/index.js";
30
- import { elementResizer as cs } from "../element-resizer/index.js";
31
- import { f as Us } from "../dom-0S_WDL4g.js";
32
- import { d as ws } from "../function-C10DGppn.js";
33
- var qs = Object.defineProperty, Ns = Object.getOwnPropertyDescriptor, Zs = (e, i, r, h) => {
34
- for (var n = h > 1 ? void 0 : h ? Ns(i, r) : i, u = e.length - 1, m; u >= 0; u--)
35
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
36
- return h && n && qs(i, r, n), n;
37
- }, je = (e, i, r) => {
38
- if (!i.has(e))
18
+ import { W as Bs, K as Hs, D as Gs } from "../DragControls-Ch_JO2ML.js";
19
+ import { CustomElement as ws, define as Zt } from "../custom-element/index.js";
20
+ import { TICK_ORDER as Ns, RESIZE_ORDER as Xe } from "../order/index.js";
21
+ import { windowResizer as Kt } from "../window-resizer/index.js";
22
+ import { scrollEntries as Lt } from "../scroll-entries/index.js";
23
+ import { e as Ye, D as Oe, ay as Me, p as Ks } from "../tags-BoPv9fDr.js";
24
+ import { c as je } from "../createStylesheet-KMRQhSa-.js";
25
+ import { cssUnitParser as ls } from "../css-unit-parser/index.js";
26
+ import { CSSProperty as d } from "../css-property/index.js";
27
+ import { d as Us } from "../Viewport-Bx-VImCe.js";
28
+ import { s as qs } from "../gestures-D2Fdra_G.js";
29
+ import { aptechkaTheme as cs } from "../theme/index.js";
30
+ import { elementResizer as us } from "../element-resizer/index.js";
31
+ import { f as Zs } from "../dom-0S_WDL4g.js";
32
+ import { d as bs } from "../function-C10DGppn.js";
33
+ var Js = Object.defineProperty, Qs = Object.getOwnPropertyDescriptor, Xs = (s, i, r, h) => {
34
+ for (var n = h > 1 ? void 0 : h ? Qs(i, r) : i, p = s.length - 1, S; p >= 0; p--)
35
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
36
+ return h && n && Js(i, r, n), n;
37
+ }, ts = (s, i, r) => {
38
+ if (!i.has(s))
39
39
  throw TypeError("Cannot " + r);
40
- }, s = (e, i, r) => (je(e, i, "read from private field"), r ? r.call(e) : i.get(e)), l = (e, i, r) => {
41
- if (i.has(e))
40
+ }, e = (s, i, r) => (ts(s, i, "read from private field"), r ? r.call(s) : i.get(s)), l = (s, i, r) => {
41
+ if (i.has(s))
42
42
  throw TypeError("Cannot add the same private member more than once");
43
- i instanceof WeakSet ? i.add(e) : i.set(e, r);
44
- }, g = (e, i, r, h) => (je(e, i, "write to private field"), h ? h.call(e, r) : i.set(e, r), r), C = (e, i, r) => (je(e, i, "access private method"), r), p, F, tt, N, et, vt, st, Nt, D, Vt, oe, le, zt, $t, Ft, w, Me, d, ce, ue, E, _, A, Z, Wt, lt, y, Zt, gt, Kt, Ut, ie, Ee, It, re, xe, ts, Le, es, pe, De, fe, Re, j, $e, Te, bs, Jt, de, Ae, Ve, ss, b, P, Et, X;
45
- class Js {
43
+ i instanceof WeakSet ? i.add(s) : i.set(s, r);
44
+ }, g = (s, i, r, h) => (ts(s, i, "write to private field"), h ? h.call(s, r) : i.set(s, r), r), b = (s, i, r) => (ts(s, i, "access private method"), r), f, F, tt, q, et, Jt, vt, st, D, zt, le, ce, $t, Ft, Ot, w, Ee, c, ue, pe, E, C, A, Z, Wt, lt, y, Qt, gt, Ut, qt, Bt, he, Mt, Ht, xe, es, Le, ss, fe, De, de, Re, j, $e, Te, _s, Xt, Se, Ae, Ve, is, Ie, Cs, _, P, xt, X;
45
+ class Ys {
46
46
  constructor(i, r) {
47
- $(this, b, void 0);
47
+ $(this, _, void 0);
48
48
  $(this, P, void 0);
49
- $(this, Et, 0);
49
+ $(this, xt, 0);
50
50
  $(this, X, 0);
51
- R(this, b, i), R(this, P, r), xt.register(a(this, b));
51
+ R(this, _, i), R(this, P, r), Lt.register(a(this, _));
52
52
  }
53
53
  get size() {
54
- return a(this, Et);
54
+ return a(this, xt);
55
55
  }
56
56
  get position() {
57
57
  return a(this, X);
58
58
  }
59
59
  destroy() {
60
- xt.unregister(a(this, b)), a(this, b).style.transform = "";
60
+ Lt.unregister(a(this, _)), a(this, _).style.transform = "";
61
61
  }
62
62
  setSize(i) {
63
- i ? (a(this, b).style.setProperty("--size", i + "px"), a(this, P).axisCSSProperty.current === "x" ? (a(this, b).style.width = i + "px", a(this, b).style.height = "") : (a(this, b).style.height = i + "px", a(this, b).style.width = "")) : (a(this, b).style.width = "", a(this, b).style.height = "", a(this, b).style.removeProperty("--size"));
63
+ i ? (a(this, _).style.setProperty("--size", i + "px"), a(this, P).axisCSSProperty.current === "x" ? (a(this, _).style.width = i + "px", a(this, _).style.height = "") : (a(this, _).style.height = i + "px", a(this, _).style.width = "")) : (a(this, _).style.width = "", a(this, _).style.height = "", a(this, _).style.removeProperty("--size"));
64
64
  }
65
65
  resize() {
66
- R(this, Et, a(this, P).vertical ? a(this, b).offsetHeight : a(this, b).offsetWidth), R(this, X, a(this, P).vertical ? ke(a(this, b)) : Pe(a(this, b))), R(this, X, a(this, X) - a(this, P).contentPosition);
66
+ R(this, xt, a(this, P).vertical ? a(this, _).offsetHeight : a(this, _).offsetWidth), R(this, X, a(this, P).vertical ? Pe(a(this, _)) : We(a(this, _))), R(this, X, a(this, X) - a(this, P).contentPosition);
67
67
  }
68
68
  transform() {
69
69
  let i = 0;
70
70
  const r = a(this, P).viewportSize;
71
- a(this, P).infiniteCSSProperty.current && a(this, P).overscroll && a(this, X) + a(this, Et) < a(this, P).currentScrollValue && (i = a(this, P).distance * -1 - a(this, P).gap), xt.update(
72
- a(this, b),
71
+ a(this, P).infiniteCSSProperty.current && a(this, P).overscroll && a(this, X) + a(this, xt) < a(this, P).currentScrollValue && (i = a(this, P).distance * -1 - a(this, P).gap), Lt.update(
72
+ a(this, _),
73
73
  a(this, P).axisCSSProperty.current,
74
74
  i
75
75
  );
76
- const h = a(this, P).currentScrollValue + i, n = a(this, X) - a(this, P).viewportSize - r, u = a(this, X) + a(this, Et) + r, m = Je(h, n, u);
77
- a(this, P).vertical ? a(this, b).style.transform = `translate3d(0px, ${m * -1}px, 0px)` : a(this, b).style.transform = `translate3d(${m * -1}px, 0px, 0px)`;
76
+ const h = a(this, P).currentScrollValue + i, n = a(this, X) - a(this, P).viewportSize - r, p = a(this, X) + a(this, xt) + r, S = Qe(h, n, p);
77
+ a(this, P).vertical ? a(this, _).style.transform = `translate3d(0px, ${S * -1}px, 0px)` : a(this, _).style.transform = `translate3d(${S * -1}px, 0px, 0px)`;
78
78
  }
79
79
  }
80
- b = new WeakMap(), P = new WeakMap(), Et = new WeakMap(), X = new WeakMap();
81
- const Qs = Ye({
80
+ _ = new WeakMap(), P = new WeakMap(), xt = new WeakMap(), X = new WeakMap();
81
+ const js = je({
82
82
  ":host": {
83
83
  position: "relative",
84
84
  width: "100%",
@@ -110,219 +110,220 @@ const Qs = Ye({
110
110
  flexShrink: "0"
111
111
  }
112
112
  });
113
- let ze = class extends gs {
113
+ let ze = class extends ws {
114
114
  constructor() {
115
- super(), l(this, ie), l(this, It), l(this, xe), l(this, Le), l(this, pe), l(this, fe), l(this, Te), l(this, de), l(this, Ve), l(this, p, null), l(this, F, new f(this, "--axis", "y")), l(this, tt, new f(this, "--pages", 0, {
116
- validate: (e) => Math.max(0, e - 1)
117
- })), l(this, N, new f(this, "--split", !1)), l(this, et, new f(this, "--sectional", !1)), l(this, vt, new f(
115
+ super(), l(this, Bt), l(this, Mt), l(this, xe), l(this, Le), l(this, fe), l(this, de), l(this, Te), l(this, Se), l(this, Ve), l(this, Ie), l(this, f, null), l(this, F, new d(this, "--axis", "y")), l(this, tt, new d(this, "--pages", 0, {
116
+ validate: (s) => Math.max(0, s - 1)
117
+ })), l(this, q, new d(this, "--split", !1)), l(this, et, new d(this, "--sectional", !1)), l(this, Jt, new d(this, "--auto-size", !1)), l(this, vt, new d(
118
118
  this,
119
119
  "--wheel-max-delta",
120
120
  !1
121
- )), l(this, st, new f(
121
+ )), l(this, st, new d(
122
122
  this,
123
123
  "--sections-in-view",
124
124
  1
125
- )), l(this, Nt, new f(this, "--auto-size", !1)), l(this, D, new f(this, "--infinite", !1)), l(this, Vt, new f(this, "--damping", 20)), l(this, oe, new f(this, "--mass", 0)), l(this, le, new f(this, "--stiffness", 0)), l(this, zt, new f(this, "--mouse-drag", !1)), l(this, $t, new f(this, "--disabled", !1)), l(this, Ft, new f(this, "--hibernated", !1)), l(this, w, null), l(this, Me, null), l(this, d, []), l(this, ce, 0), l(this, ue, 0), l(this, E, 0), l(this, _, 0), l(this, A, 0), l(this, Z, null), l(this, Wt, null), l(this, lt, null), l(this, y, new mt(0)), l(this, Zt, 0), l(this, gt, 0), l(this, Kt, !0), l(this, Ut, !0), l(this, j, () => {
126
- const e = this.currentScrollValue / s(this, _) || 0;
127
- if (g(this, ce, this.vertical ? ke(this) : Pe(this)), g(this, ue, this.vertical ? ke(s(this, w)) : Pe(s(this, w))), g(this, E, this.vertical ? this.offsetHeight : this.offsetWidth), s(this, tt).current) {
128
- g(this, _, s(this, E) * s(this, tt).current);
129
- const i = s(this, _) + s(this, E);
130
- this.vertical ? (s(this, w).style.width = i + "px", s(this, w).style.height = "100%") : (s(this, w).style.height = i + "px", s(this, w).style.width = "100%");
131
- } else
132
- this.vertical ? (s(this, w).style.width = "100%", s(this, w).style.height = "max-content", g(this, _, s(this, w).offsetHeight - s(this, E))) : (s(this, w).style.width = "max-content", s(this, w).style.height = "100%", g(this, _, s(this, w).offsetWidth - s(this, E)));
133
- if (this.vertical ? g(this, A, os.parse(
134
- getComputedStyle(s(this, w)).rowGap
135
- )) : g(this, A, os.parse(
136
- getComputedStyle(s(this, w)).columnGap
137
- )), s(this, Nt).current && s(this, d).length) {
138
- const i = s(this, st).current, r = (s(this, E) - s(this, A) * (i - 1)) / i;
139
- s(this, d).forEach((h) => {
140
- h.setSize(r);
125
+ )), l(this, D, new d(this, "--infinite", !1)), l(this, zt, new d(this, "--damping", 20)), l(this, le, new d(this, "--mass", 0)), l(this, ce, new d(this, "--stiffness", 0)), l(this, $t, new d(this, "--mouse-drag", !1)), l(this, Ft, new d(this, "--disabled", !1)), l(this, Ot, new d(this, "--hibernated", !1)), l(this, w, null), l(this, Ee, null), l(this, c, []), l(this, ue, 0), l(this, pe, 0), l(this, E, 0), l(this, C, 0), l(this, A, 0), l(this, Z, null), l(this, Wt, null), l(this, lt, null), l(this, y, new mt(0)), l(this, Qt, 0), l(this, gt, 0), l(this, Ut, !0), l(this, qt, !0), l(this, j, () => {
126
+ e(this, f).unlistenAnimationFrame();
127
+ const s = this.currentScrollValue / e(this, C) || 0, i = e(this, y).current;
128
+ if (g(this, ue, this.vertical ? Pe(this) : We(this)), g(this, pe, this.vertical ? Pe(e(this, w)) : We(e(this, w))), g(this, E, this.vertical ? this.offsetHeight : this.offsetWidth), this.vertical ? g(this, A, ls.parse(
129
+ getComputedStyle(e(this, w)).rowGap
130
+ )) : g(this, A, ls.parse(
131
+ getComputedStyle(e(this, w)).columnGap
132
+ )), e(this, Jt).current && e(this, c).length) {
133
+ const r = e(this, st).current, h = (e(this, E) - e(this, A) * (r - 1)) / r;
134
+ e(this, c).forEach((n) => {
135
+ n.setSize(h);
141
136
  });
142
137
  } else
143
- s(this, d).forEach((i) => {
144
- i.setSize();
138
+ e(this, c).forEach((r) => {
139
+ r.setSize();
145
140
  });
146
- if (!s(this, D).current) {
147
- const i = getComputedStyle(this);
148
- g(this, _, s(this, _) + (this.vertical ? parseFloat(i.paddingBlockStart) + parseFloat(i.paddingBlockEnd) : parseFloat(i.paddingInlineStart) + parseFloat(i.paddingInlineEnd))), s(this, p).max = s(this, _);
141
+ if (e(this, c).forEach((r) => {
142
+ r.resize();
143
+ }), e(this, tt).current) {
144
+ g(this, C, e(this, E) * e(this, tt).current);
145
+ const r = e(this, C) + e(this, E);
146
+ this.vertical ? (e(this, w).style.width = r + "px", e(this, w).style.height = "100%") : (e(this, w).style.height = r + "px", e(this, w).style.width = "100%");
147
+ } else
148
+ this.vertical ? (e(this, w).style.width = "100%", e(this, w).style.height = "max-content", g(this, C, e(this, w).offsetHeight - e(this, E))) : (e(this, w).style.width = "max-content", e(this, w).style.height = "100%", g(this, C, e(this, w).offsetWidth - e(this, E)));
149
+ if (!e(this, D).current) {
150
+ const r = getComputedStyle(this), h = this.vertical ? parseFloat(r.paddingBlockStart) + parseFloat(r.paddingBlockEnd) : parseFloat(r.paddingInlineStart) + parseFloat(r.paddingInlineEnd);
151
+ g(this, C, e(this, C) + h), e(this, f).max = e(this, C);
149
152
  }
150
- if (s(this, d).forEach((i) => {
151
- i.resize(), i.transform();
152
- }), s(this, D).current && s(this, d).length) {
153
- const i = s(this, d)[s(this, d).length - 1], r = i.position + i.size - s(this, E), h = s(this, _) - r;
154
- g(this, gt, i.position + i.size + h);
153
+ if (e(this, D).current && e(this, c).length) {
154
+ const r = e(this, c)[e(this, c).length - 1], h = r.position + r.size - e(this, E), n = e(this, C) - h;
155
+ g(this, gt, r.position + r.size + n);
155
156
  } else
156
- g(this, gt, s(this, _));
157
- if (s(this, et).current && s(this, d).length) {
158
- const i = s(this, d)[s(this, y).current];
159
- s(this, p).set(i.position, !0);
157
+ g(this, gt, e(this, C));
158
+ if (e(this, et).current && e(this, c).length) {
159
+ const r = e(this, c)[i];
160
+ e(this, f).set(r.position, !0);
160
161
  } else
161
- s(this, p).set(e * s(this, _), !0);
162
+ e(this, f).set(s * e(this, C), !0);
162
163
  }), l(this, $e, () => {
163
- const e = this.currentScrollValue;
164
- if (g(this, Zt, Math.max(0, e - s(this, _))), s(this, d).length) {
164
+ const s = this.currentScrollValue;
165
+ if (g(this, Qt, Math.max(0, s - e(this, C))), e(this, c).length) {
165
166
  let i = 0;
166
- for (let r = 0; r < s(this, d).length; r++) {
167
- const h = s(this, d)[r];
167
+ for (let r = 0; r < e(this, c).length; r++) {
168
+ const h = e(this, c)[r];
168
169
  h.transform(), this.targetScrollValue + h.size / 2 >= h.position && (i = r);
169
170
  }
170
- s(this, y).current = i;
171
+ e(this, y).current = i;
171
172
  } else
172
- this.vertical ? s(this, w).style.transform = `translate3d(0px, ${e * -1}px, 0px)` : s(this, w).style.transform = `translate3d(${e * -1}px, 0px, 0px)`;
173
- xt.update(
173
+ this.vertical ? e(this, w).style.transform = `translate3d(0px, ${s * -1}px, 0px)` : e(this, w).style.transform = `translate3d(${s * -1}px, 0px, 0px)`;
174
+ Lt.update(
174
175
  this,
175
- s(this, F).current,
176
- e
176
+ e(this, F).current,
177
+ s
177
178
  );
178
- }), l(this, Jt, (e, i) => {
179
- if (!(e === "drag" && !Gs.isMobile && !s(this, zt).current))
180
- if (s(this, et).current) {
179
+ }), l(this, Xt, (s, i) => {
180
+ if (!(s === "drag" && !Us.isMobile && !e(this, $t).current))
181
+ if (e(this, et).current) {
181
182
  const r = Math.sign(i);
182
- s(this, d).length ? this.shiftSections(r) : s(this, p).shift(r * s(this, E));
183
+ e(this, c).length ? this.shiftSections(r) : e(this, f).shift(r * e(this, E));
183
184
  } else
184
- s(this, p).shift(i);
185
- }), Ze && (g(this, p, new $s(0, {
185
+ e(this, f).shift(i);
186
+ }), Je && (g(this, f, new Ds(0, {
186
187
  damping: 0.01,
187
188
  min: 0,
188
- order: Bs.SCROLL
189
- })), this.openShadow(Qs), Xe(this, {
189
+ order: Ns.SCROLL
190
+ })), this.openShadow(js), Ye(this, {
190
191
  tabIndex: 0,
191
192
  children: [
192
193
  Oe({
193
194
  class: "static",
194
- children: [We({ name: "static" })]
195
+ children: [Me({ name: "static" })]
195
196
  }),
196
197
  Oe({
197
198
  class: "content",
198
- children: [We({ ref: (e) => g(this, Me, e) })],
199
+ children: [Me({ ref: (s) => g(this, Ee, s) })],
199
200
  style: {
200
- flexDirection: new Rs(
201
- s(this, F),
202
- (e) => e === "x" ? "row" : "column"
201
+ flexDirection: new Is(
202
+ e(this, F),
203
+ (s) => s === "x" ? "row" : "column"
203
204
  )
204
205
  },
205
- ref: (e) => g(this, w, e)
206
+ ref: (s) => g(this, w, s)
206
207
  })
207
208
  ]
208
- }), g(this, Z, new Ts({ element: this })), s(this, Z).changeEvent.subscribe(s(this, Jt)), g(this, Wt, new As({ element: this })), s(this, Wt).changeEvent.subscribe(s(this, Jt)), g(this, lt, new Is({ element: this })), s(this, lt).changeEvent.subscribe(s(this, Jt)), s(this, F).subscribe(({ current: e }) => {
209
- s(this, w).style.flexDirection = e === "x" ? "row" : "column", s(this, Z).axis = s(this, vt).current ? "max" : e, s(this, Wt).dimension = e === "x" ? "width" : "height", s(this, lt).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), this.isConnected && s(this, j).call(this);
210
- }), s(this, vt).subscribe((e) => {
211
- s(this, Z).axis = e.current ? "max" : s(this, F).current;
212
- }), s(this, tt).subscribe(() => {
213
- this.isConnected && s(this, j).call(this);
214
- }), s(this, N).subscribe(({ current: e }) => {
215
- this.isConnected && (e ? C(this, ie, Ee).call(this) : C(this, It, re).call(this));
216
- }), s(this, et).subscribe((e) => {
217
- s(this, y).current = 0, s(this, Z).debounce = e.current, s(this, lt).swipe = e.current, s(this, p).reset(), this.isConnected && (e.current && !e.previous ? C(this, ie, Ee).call(this) : !e.current && e.previous && C(this, It, re).call(this));
218
- }), s(this, st).subscribe((e) => {
219
- this.isConnected && s(this, j).call(this);
220
- }), s(this, Nt).subscribe((e) => {
221
- this.isConnected && s(this, j).call(this);
222
- }), s(this, D).subscribe((e) => {
223
- e.current ? (this.isConnected && (s(this, d).length || (s(this, N).current = !0)), s(this, d).length && (s(this, p).max = 1 / 0, s(this, p).min = -1 / 0)) : (g(this, Zt, 0), s(this, p).max = s(this, _), s(this, p).min = 0);
224
- }), s(this, Vt).subscribe((e) => {
225
- s(this, p).damping = e.current;
226
- }), s(this, oe).subscribe((e) => {
227
- s(this, p).mass = e.current;
228
- }), s(this, le).subscribe((e) => {
229
- s(this, p).stiffness = e.current;
230
- }), s(this, $t).subscribe((e) => {
231
- e.current && !e.previous ? C(this, xe, ts).call(this) : !e.current && e.previous && C(this, Le, es).call(this);
232
- }), s(this, Ft).subscribe((e) => {
233
- e.current && !e.previous ? C(this, pe, De).call(this) : !e.current && e.previous && C(this, fe, Re).call(this);
234
- }), s(this, p).isRunning.subscribe((e) => {
235
- this.classList.toggle("active", e.current);
236
- }), s(this, y).subscribe((e) => {
237
- s(this, d).length && C(this, Ve, ss).call(this);
209
+ }), g(this, Z, new Bs({ element: this })), e(this, Z).changeEvent.subscribe(e(this, Xt)), g(this, Wt, new Hs({ element: this })), e(this, Wt).changeEvent.subscribe(e(this, Xt)), g(this, lt, new Gs({ element: this })), e(this, lt).changeEvent.subscribe(e(this, Xt)), e(this, F).subscribe(({ current: s }) => {
210
+ e(this, w).style.flexDirection = s === "x" ? "row" : "column", e(this, Z).axis = e(this, vt).current ? "max" : s, e(this, Wt).dimension = s === "x" ? "width" : "height", e(this, lt).axis = s, s === "x" ? this.style.touchAction = "pan-y" : s === "y" && (this.style.touchAction = "pan-x"), this.isConnected && e(this, j).call(this);
211
+ }), e(this, vt).subscribe((s) => {
212
+ e(this, Z).axis = s.current ? "max" : e(this, F).current;
213
+ }), e(this, tt).subscribe(() => {
214
+ this.isConnected && e(this, j).call(this);
215
+ }), e(this, q).subscribe(({ current: s }) => {
216
+ this.isConnected && (s ? b(this, Bt, he).call(this) : b(this, Mt, Ht).call(this));
217
+ }), e(this, et).subscribe((s) => {
218
+ e(this, Z).debounce = s.current, e(this, lt).swipe = s.current, this.isConnected && (s.current && !s.previous && !e(this, c).length ? b(this, Bt, he).call(this) : !s.current && s.previous && e(this, c).length && b(this, Mt, Ht).call(this));
219
+ }), e(this, Jt).subscribe((s) => {
220
+ this.isConnected && (e(this, j).call(this), s.current && !s.previous && !e(this, c).length ? b(this, Bt, he).call(this) : !s.current && s.previous && e(this, c).length && b(this, Mt, Ht).call(this));
221
+ }), e(this, st).subscribe((s) => {
222
+ this.isConnected && e(this, j).call(this);
223
+ }), e(this, D).subscribe((s) => {
224
+ s.current ? (this.isConnected && (e(this, c).length || (e(this, q).current = !0)), e(this, c).length && (e(this, f).max = 1 / 0, e(this, f).min = -1 / 0)) : (g(this, Qt, 0), e(this, f).max = e(this, C), e(this, f).min = 0);
225
+ }), e(this, zt).subscribe((s) => {
226
+ e(this, f).damping = s.current;
227
+ }), e(this, le).subscribe((s) => {
228
+ e(this, f).mass = s.current;
229
+ }), e(this, ce).subscribe((s) => {
230
+ e(this, f).stiffness = s.current;
231
+ }), e(this, Ft).subscribe((s) => {
232
+ s.current && !s.previous ? b(this, xe, es).call(this) : !s.current && s.previous && b(this, Le, ss).call(this);
233
+ }), e(this, Ot).subscribe((s) => {
234
+ s.current && !s.previous ? b(this, fe, De).call(this) : !s.current && s.previous && b(this, de, Re).call(this);
235
+ }), e(this, f).isRunning.subscribe((s) => {
236
+ this.classList.toggle("active", s.current);
237
+ }), e(this, y).subscribe((s) => {
238
+ e(this, c).length && b(this, Ve, is).call(this);
238
239
  }));
239
240
  }
240
241
  get axisCSSProperty() {
241
- return s(this, F);
242
+ return e(this, F);
242
243
  }
243
244
  get pagesCSSProperty() {
244
- return s(this, tt);
245
+ return e(this, tt);
245
246
  }
246
247
  get splitCSSProperty() {
247
- return s(this, N);
248
+ return e(this, q);
248
249
  }
249
250
  get sectionalCSSProperty() {
250
- return s(this, et);
251
+ return e(this, et);
252
+ }
253
+ get autoSizeCSSProperty() {
254
+ return e(this, Jt);
251
255
  }
252
256
  get wheelMaxDeltaCSSProperty() {
253
- return s(this, vt);
257
+ return e(this, vt);
254
258
  }
255
259
  get sectionsInViewCSSProperty() {
256
- return s(this, st);
257
- }
258
- get autoSizeCSSProperty() {
259
- return s(this, Nt);
260
+ return e(this, st);
260
261
  }
261
262
  get infiniteCSSProperty() {
262
- return s(this, D);
263
+ return e(this, D);
263
264
  }
264
265
  get dampingCSSProperty() {
265
- return s(this, Vt);
266
+ return e(this, zt);
266
267
  }
267
268
  get massCSSProperty() {
268
- return s(this, oe);
269
+ return e(this, le);
269
270
  }
270
271
  get stiffnessCSSProperty() {
271
- return s(this, le);
272
+ return e(this, ce);
272
273
  }
273
274
  get mouseDragCSSProperty() {
274
- return s(this, zt);
275
+ return e(this, $t);
275
276
  }
276
277
  get disabledCSSProperty() {
277
- return s(this, $t);
278
+ return e(this, Ft);
278
279
  }
279
280
  get hibernatedCSSProperty() {
280
- return s(this, Ft);
281
+ return e(this, Ot);
281
282
  }
282
283
  get currentScrollValue() {
283
- return C(this, de, Ae).call(this, "current");
284
+ return b(this, Se, Ae).call(this, "current");
284
285
  }
285
286
  get targetScrollValue() {
286
- return C(this, de, Ae).call(this, "target");
287
+ return b(this, Se, Ae).call(this, "target");
287
288
  }
288
289
  get contentElement() {
289
- return s(this, w);
290
+ return e(this, w);
290
291
  }
291
292
  get sections() {
292
- return s(this, d);
293
+ return e(this, c);
293
294
  }
294
295
  get position() {
295
- return s(this, ce);
296
+ return e(this, ue);
296
297
  }
297
298
  get contentPosition() {
298
- return s(this, ue);
299
+ return e(this, pe);
299
300
  }
300
301
  get viewportSize() {
301
- return s(this, E);
302
+ return e(this, E);
302
303
  }
303
304
  get scrollSize() {
304
- return s(this, _);
305
+ return e(this, C);
305
306
  }
306
307
  get gap() {
307
- return s(this, A);
308
+ return e(this, A);
308
309
  }
309
310
  get counter() {
310
- return s(this, y);
311
+ return e(this, y);
311
312
  }
312
313
  get limit() {
313
- return s(this, d).length - s(this, st).current;
314
+ return e(this, c).length - e(this, st).current;
314
315
  }
315
316
  get distance() {
316
- return s(this, gt);
317
+ return e(this, gt);
317
318
  }
318
319
  get infiniteDistance() {
319
- return s(this, D).current ? s(this, gt) + s(this, A) : s(this, gt);
320
+ return e(this, D).current ? e(this, gt) + e(this, A) : e(this, gt);
320
321
  }
321
322
  get overscroll() {
322
- return s(this, Zt);
323
+ return e(this, Qt);
323
324
  }
324
325
  get vertical() {
325
- return s(this, F).current === "y";
326
+ return e(this, F).current === "y";
326
327
  }
327
328
  get currentProgress() {
328
329
  return this.currentScrollValue / this.infiniteDistance || 0;
@@ -331,184 +332,196 @@ let ze = class extends gs {
331
332
  return this.targetScrollValue / this.infiniteDistance || 0;
332
333
  }
333
334
  get speed() {
334
- return s(this, p).speed;
335
+ return e(this, f).speed;
335
336
  }
336
337
  get direction() {
337
- return s(this, p).direction;
338
+ return e(this, f).direction;
338
339
  }
339
340
  get isRunning() {
340
- return s(this, p).isRunning;
341
+ return e(this, f).isRunning;
341
342
  }
342
343
  get scrollWidth() {
343
- return s(this, F).current === "y" ? 0 : s(this, p).length;
344
+ return e(this, F).current === "y" ? 0 : e(this, f).length;
344
345
  }
345
346
  get scrollHeight() {
346
- return s(this, F).current === "x" ? 0 : s(this, p).length;
347
+ return e(this, F).current === "x" ? 0 : e(this, f).length;
347
348
  }
348
- onScroll(...e) {
349
- return s(this, p).subscribe(...e);
349
+ onScroll(...s) {
350
+ return e(this, f).subscribe(...s);
350
351
  }
351
- offScroll(...e) {
352
- s(this, p).unsubscribe(...e);
352
+ offScroll(...s) {
353
+ e(this, f).unsubscribe(...s);
353
354
  }
354
355
  //https://github.com/pmndrs/drei/blob/d3282cdd02d170ef603a5e096505d83dc93cd57a/src/web/ScrollControls.tsx#L85C7-L100C9
355
- range(e, i, r = 0) {
356
- const h = e - r, n = h + i + r * 2;
356
+ range(s, i, r = 0) {
357
+ const h = s - r, n = h + i + r * 2;
357
358
  return this.currentProgress < h ? 0 : this.currentProgress > n ? 1 : (this.currentProgress - h) / (n - h);
358
359
  }
359
- curve(e, i, r = 0) {
360
- return Math.sin(this.range(e, i, r) * Math.PI);
360
+ curve(s, i, r = 0) {
361
+ return Math.sin(this.range(s, i, r) * Math.PI);
361
362
  }
362
- visible(e, i, r = 0) {
363
- const h = e - r, n = h + i + r * 2;
363
+ visible(s, i, r = 0) {
364
+ const h = s - r, n = h + i + r * 2;
364
365
  return this.currentProgress >= h && this.currentProgress <= n;
365
366
  }
366
- // TODO: Поправить значение когда скролл не секционный ??
367
- scrollToSection(e, i = "smooth") {
368
- if (!s(this, d).length)
367
+ scrollToSection(s, i = "smooth") {
368
+ if (!e(this, c).length)
369
369
  return;
370
- const r = s(this, y).current;
371
- C(this, Te, bs).call(this, e);
372
- const h = s(this, d)[r], n = s(this, d)[s(this, y).current];
370
+ const r = e(this, y).current;
371
+ b(this, Te, _s).call(this, s);
372
+ const h = e(this, c)[r], n = e(this, c)[e(this, y).current];
373
373
  if (h && n) {
374
- let u = 0;
375
- s(this, D).current ? s(this, y).current === 0 && r === this.limit ? u = s(this, _) + s(this, E) - h.position + s(this, A) : s(this, y).current === this.limit && r === 0 ? u = n.position - (s(this, _) + s(this, E) + s(this, A)) : u = n.position - h.position : u = n.position - h.position, s(this, p).shift(u, i === "instant");
374
+ let p = 0;
375
+ const S = b(this, Ie, Cs).call(this), Os = S ? this.targetScrollValue - S.position : 0;
376
+ e(this, D).current ? e(this, y).current === 0 && r === e(this, c).length - 1 ? p = e(this, C) + e(this, E) - h.position + e(this, A) : e(this, y).current === e(this, c).length - 1 && r === 0 ? p = n.position - (e(this, C) + e(this, E) + e(this, A)) : p = n.position - h.position : p = n.position - h.position, e(this, f).shift(
377
+ p - Os,
378
+ i === "instant"
379
+ );
376
380
  }
377
381
  }
378
- shiftSections(e, i = "smooth") {
379
- s(this, d).length && this.scrollToSection(s(this, y).current + e, i);
382
+ shiftSections(s, i = "smooth") {
383
+ e(this, c).length && this.scrollToSection(e(this, y).current + s, i);
380
384
  }
381
- setPosition(e, i = "smooth") {
382
- s(this, p).set(e, i === "instant");
385
+ setPosition(s, i = "smooth") {
386
+ e(this, f).set(s, i === "instant");
383
387
  }
384
388
  connectedCallback() {
385
- s(this, F).observe(), s(this, tt).observe(), s(this, N).observe(), s(this, et).observe(), s(this, vt).observe(), s(this, st).observe(), s(this, D).observe(), s(this, Vt).observe(), s(this, zt).observe(), s(this, $t).observe(), s(this, Ft).observe(), C(this, fe, Re).call(this);
389
+ e(this, F).observe(), e(this, tt).observe(), e(this, q).observe(), e(this, et).observe(), e(this, vt).observe(), e(this, st).observe(), e(this, D).observe(), e(this, zt).observe(), e(this, $t).observe(), e(this, Ft).observe(), e(this, Ot).observe(), b(this, de, Re).call(this);
386
390
  }
387
391
  disconnectedCallback() {
388
- s(this, F).unobserve(), s(this, tt).unobserve(), s(this, N).unobserve(), s(this, et).unobserve(), s(this, vt).unobserve(), s(this, st).unobserve(), s(this, D).unobserve(), s(this, Vt).unobserve(), s(this, zt).unobserve(), s(this, $t).unobserve(), s(this, Ft).unobserve(), C(this, pe, De).call(this);
392
+ e(this, F).unobserve(), e(this, tt).unobserve(), e(this, q).unobserve(), e(this, et).unobserve(), e(this, vt).unobserve(), e(this, st).unobserve(), e(this, D).unobserve(), e(this, zt).unobserve(), e(this, $t).unobserve(), e(this, Ft).unobserve(), e(this, Ot).unobserve(), b(this, fe, De).call(this);
389
393
  }
390
394
  };
391
- p = /* @__PURE__ */ new WeakMap();
395
+ f = /* @__PURE__ */ new WeakMap();
392
396
  F = /* @__PURE__ */ new WeakMap();
393
397
  tt = /* @__PURE__ */ new WeakMap();
394
- N = /* @__PURE__ */ new WeakMap();
398
+ q = /* @__PURE__ */ new WeakMap();
395
399
  et = /* @__PURE__ */ new WeakMap();
400
+ Jt = /* @__PURE__ */ new WeakMap();
396
401
  vt = /* @__PURE__ */ new WeakMap();
397
402
  st = /* @__PURE__ */ new WeakMap();
398
- Nt = /* @__PURE__ */ new WeakMap();
399
403
  D = /* @__PURE__ */ new WeakMap();
400
- Vt = /* @__PURE__ */ new WeakMap();
401
- oe = /* @__PURE__ */ new WeakMap();
402
- le = /* @__PURE__ */ new WeakMap();
403
404
  zt = /* @__PURE__ */ new WeakMap();
405
+ le = /* @__PURE__ */ new WeakMap();
406
+ ce = /* @__PURE__ */ new WeakMap();
404
407
  $t = /* @__PURE__ */ new WeakMap();
405
408
  Ft = /* @__PURE__ */ new WeakMap();
409
+ Ot = /* @__PURE__ */ new WeakMap();
406
410
  w = /* @__PURE__ */ new WeakMap();
407
- Me = /* @__PURE__ */ new WeakMap();
408
- d = /* @__PURE__ */ new WeakMap();
409
- ce = /* @__PURE__ */ new WeakMap();
411
+ Ee = /* @__PURE__ */ new WeakMap();
412
+ c = /* @__PURE__ */ new WeakMap();
410
413
  ue = /* @__PURE__ */ new WeakMap();
414
+ pe = /* @__PURE__ */ new WeakMap();
411
415
  E = /* @__PURE__ */ new WeakMap();
412
- _ = /* @__PURE__ */ new WeakMap();
416
+ C = /* @__PURE__ */ new WeakMap();
413
417
  A = /* @__PURE__ */ new WeakMap();
414
418
  Z = /* @__PURE__ */ new WeakMap();
415
419
  Wt = /* @__PURE__ */ new WeakMap();
416
420
  lt = /* @__PURE__ */ new WeakMap();
417
421
  y = /* @__PURE__ */ new WeakMap();
418
- Zt = /* @__PURE__ */ new WeakMap();
422
+ Qt = /* @__PURE__ */ new WeakMap();
419
423
  gt = /* @__PURE__ */ new WeakMap();
420
- Kt = /* @__PURE__ */ new WeakMap();
421
424
  Ut = /* @__PURE__ */ new WeakMap();
422
- ie = /* @__PURE__ */ new WeakSet();
423
- Ee = function() {
424
- C(this, It, re).call(this), s(this, Me).assignedElements().forEach((e) => {
425
- e instanceof HTMLElement && s(this, d).push(new Js(e, this));
426
- }), s(this, w).style.transform = "", this.dispatchEvent(
425
+ qt = /* @__PURE__ */ new WeakMap();
426
+ Bt = /* @__PURE__ */ new WeakSet();
427
+ he = function() {
428
+ b(this, Mt, Ht).call(this), e(this, Ee).assignedElements().forEach((s) => {
429
+ s instanceof HTMLElement && e(this, c).push(new Ys(s, this));
430
+ }), e(this, w).style.transform = "", this.dispatchEvent(
427
431
  new CustomEvent("sectionsChange", {
428
432
  composed: !0
429
433
  })
430
- ), s(this, j).call(this), C(this, Ve, ss).call(this);
434
+ ), e(this, j).call(this), b(this, Ve, is).call(this);
431
435
  };
432
- It = /* @__PURE__ */ new WeakSet();
433
- re = function() {
434
- s(this, d).forEach((e) => {
435
- e.destroy();
436
- }), g(this, d, []), this.dispatchEvent(
436
+ Mt = /* @__PURE__ */ new WeakSet();
437
+ Ht = function() {
438
+ e(this, c).forEach((s) => {
439
+ s.destroy();
440
+ }), g(this, c, []), e(this, y).current = 0, e(this, f).reset(), this.dispatchEvent(
437
441
  new CustomEvent("sectionsChange", {
438
442
  composed: !0
439
443
  })
440
444
  );
441
445
  };
442
446
  xe = /* @__PURE__ */ new WeakSet();
443
- ts = function() {
444
- s(this, Kt) || (g(this, Kt, !0), s(this, p).unsubscribe(s(this, $e)), s(this, p).unlistenAnimationFrame(), s(this, Z).disconnect(), s(this, Wt).disconnect(), s(this, lt).disconnect());
447
+ es = function() {
448
+ e(this, Ut) || (g(this, Ut, !0), e(this, f).unsubscribe(e(this, $e)), e(this, f).unlistenAnimationFrame(), e(this, Z).disconnect(), e(this, Wt).disconnect(), e(this, lt).disconnect());
445
449
  };
446
450
  Le = /* @__PURE__ */ new WeakSet();
447
- es = function() {
448
- s(this, Kt) && (g(this, Kt, !1), s(this, p).subscribe(s(this, $e)), s(this, Z).connect(), s(this, Wt).connect(), s(this, lt).connect());
451
+ ss = function() {
452
+ e(this, Ut) && (g(this, Ut, !1), e(this, f).subscribe(e(this, $e)), e(this, Z).connect(), e(this, Wt).connect(), e(this, lt).connect());
449
453
  };
450
- pe = /* @__PURE__ */ new WeakSet();
454
+ fe = /* @__PURE__ */ new WeakSet();
451
455
  De = function() {
452
- s(this, Ut) || (g(this, Ut, !0), Gt.unsubscribe(s(this, j)), s(this, p).reset(), C(this, xe, ts).call(this), s(this, w).style.transform = "", s(this, N).current && C(this, It, re).call(this), xt.unregister(this));
456
+ e(this, qt) || (g(this, qt, !0), Kt.unsubscribe(e(this, j)), e(this, f).reset(), b(this, xe, es).call(this), e(this, w).style.transform = "", e(this, q).current && b(this, Mt, Ht).call(this), Lt.unregister(this));
453
457
  };
454
- fe = /* @__PURE__ */ new WeakSet();
458
+ de = /* @__PURE__ */ new WeakSet();
455
459
  Re = function() {
456
- s(this, Ut) && (g(this, Ut, !1), s(this, N).current && C(this, ie, Ee).call(this), xt.register(this), Gt.subscribe(s(this, j), Qe.SCROLL), C(this, Le, es).call(this));
460
+ e(this, qt) && (g(this, qt, !1), e(this, q).current && b(this, Bt, he).call(this), Lt.register(this), Kt.subscribe(e(this, j), Xe.SCROLL), b(this, Le, ss).call(this));
457
461
  };
458
462
  j = /* @__PURE__ */ new WeakMap();
459
463
  $e = /* @__PURE__ */ new WeakMap();
460
464
  Te = /* @__PURE__ */ new WeakSet();
461
- bs = function(e) {
462
- s(this, D).current ? (s(this, y).current = e % s(this, d).length, s(this, y).current = s(this, y).current < 0 ? s(this, d).length + s(this, y).current : s(this, y).current) : s(this, y).current = Je(e, 0, this.limit);
465
+ _s = function(s) {
466
+ e(this, D).current ? (e(this, y).current = s % e(this, c).length, e(this, y).current = e(this, y).current < 0 ? e(this, c).length + e(this, y).current : e(this, y).current) : e(this, y).current = Qe(s, 0, this.limit);
463
467
  };
464
- Jt = /* @__PURE__ */ new WeakMap();
465
- de = /* @__PURE__ */ new WeakSet();
466
- Ae = function(e = "current") {
467
- if (s(this, D).current && s(this, d).length) {
468
- const i = s(this, p)[e] % (s(this, _) + s(this, E) + s(this, A));
469
- return i < 0 ? s(this, _) + i + s(this, E) + s(this, A) : i;
468
+ Xt = /* @__PURE__ */ new WeakMap();
469
+ Se = /* @__PURE__ */ new WeakSet();
470
+ Ae = function(s = "current") {
471
+ if (e(this, D).current && e(this, c).length) {
472
+ const i = e(this, f)[s] % (e(this, C) + e(this, E) + e(this, A));
473
+ return i < 0 ? e(this, C) + i + e(this, E) + e(this, A) : i;
470
474
  } else
471
- return s(this, p)[e];
475
+ return e(this, f)[s];
472
476
  };
473
477
  Ve = /* @__PURE__ */ new WeakSet();
474
- ss = function() {
475
- s(this, d).length && (s(this, y).current === 0 ? this.classList.add("start") : this.classList.remove("start"), s(this, y).current === this.limit ? this.classList.add("end") : this.classList.remove("end"));
478
+ is = function() {
479
+ e(this, c).length && (e(this, y).current === 0 ? this.classList.add("start") : this.classList.remove("start"), e(this, y).current === this.limit ? this.classList.add("end") : this.classList.remove("end"));
480
+ };
481
+ Ie = /* @__PURE__ */ new WeakSet();
482
+ Cs = function() {
483
+ let s = null, i = 1 / 0;
484
+ for (let r = 0; r < e(this, c).length; r++) {
485
+ const h = Math.abs(e(this, c)[r].position - this.targetScrollValue);
486
+ h < i && (i = h, s = r);
487
+ }
488
+ return s !== null ? e(this, c)[s] : null;
476
489
  };
477
- ze = Zs([
478
- qt("e-scroll")
490
+ ze = Xs([
491
+ Zt("e-scroll")
479
492
  ], ze);
480
- var he;
481
- class Fe extends gs {
493
+ var ne;
494
+ class Fe extends ws {
482
495
  constructor() {
483
496
  super(...arguments);
484
- $(this, he, null);
497
+ $(this, ne, null);
485
498
  }
486
499
  get scrollElement() {
487
- return a(this, he);
500
+ return a(this, ne);
488
501
  }
489
502
  connectedCallback() {
490
- const r = Us(this, ze);
491
- r instanceof ze ? R(this, he, r) : console.error(this, "e-scroll not found");
503
+ const r = Zs(this, ze);
504
+ r instanceof ze ? R(this, ne, r) : console.error(this, "e-scroll not found");
492
505
  }
493
506
  }
494
- he = new WeakMap();
495
- var Xs = Object.defineProperty, Ys = Object.getOwnPropertyDescriptor, js = (e, i, r, h) => {
496
- for (var n = h > 1 ? void 0 : h ? Ys(i, r) : i, u = e.length - 1, m; u >= 0; u--)
497
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
498
- return h && n && Xs(i, r, n), n;
499
- }, _s = (e, i, r) => {
500
- if (!i.has(e))
507
+ ne = new WeakMap();
508
+ var ti = Object.defineProperty, ei = Object.getOwnPropertyDescriptor, si = (s, i, r, h) => {
509
+ for (var n = h > 1 ? void 0 : h ? ei(i, r) : i, p = s.length - 1, S; p >= 0; p--)
510
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
511
+ return h && n && ti(i, r, n), n;
512
+ }, ys = (s, i, r) => {
513
+ if (!i.has(s))
501
514
  throw TypeError("Cannot " + r);
502
- }, c = (e, i, r) => (_s(e, i, "read from private field"), r ? r.call(e) : i.get(e)), K = (e, i, r) => {
503
- if (i.has(e))
515
+ }, u = (s, i, r) => (ys(s, i, "read from private field"), r ? r.call(s) : i.get(s)), N = (s, i, r) => {
516
+ if (i.has(s))
504
517
  throw TypeError("Cannot add the same private member more than once");
505
- i instanceof WeakSet ? i.add(e) : i.set(e, r);
506
- }, St = (e, i, r, h) => (_s(e, i, "write to private field"), h ? h.call(e, r) : i.set(e, r), r), Qt, O, it, rt, Xt, Yt, Ot, Se, me, ve;
507
- const ti = Ye({
518
+ i instanceof WeakSet ? i.add(s) : i.set(s, r);
519
+ }, St = (s, i, r, h) => (ys(s, i, "write to private field"), h ? h.call(s, r) : i.set(s, r), r), Yt, O, it, rt, jt, te, Dt, me, ve, ge;
520
+ const ii = je({
508
521
  ":host": {
509
522
  display: "inline-block",
510
523
  zIndex: "1",
511
- backgroundColor: ls.colorLight.var
524
+ backgroundColor: cs.colorLight.var
512
525
  },
513
526
  ':host([axis="y"])': {
514
527
  position: "absolute",
@@ -525,7 +538,7 @@ const ti = Ye({
525
538
  height: "1vmin"
526
539
  },
527
540
  ".default-thumb": {
528
- backgroundColor: ls.colorDark.var,
541
+ backgroundColor: cs.colorDark.var,
529
542
  borderRadius: "1vmin",
530
543
  touchAction: "none"
531
544
  },
@@ -533,231 +546,231 @@ const ti = Ye({
533
546
  touchAction: "none"
534
547
  }
535
548
  });
536
- let us = class extends Fe {
549
+ let ps = class extends Fe {
537
550
  constructor() {
538
- super(), K(this, Qt, null), K(this, O, null), K(this, it, !1), K(this, rt, 0), K(this, Xt, 0), K(this, Yt, 0), K(this, Ot, () => {
551
+ super(), N(this, Yt, null), N(this, O, null), N(this, it, !1), N(this, rt, 0), N(this, jt, 0), N(this, te, 0), N(this, Dt, () => {
539
552
  St(this, it, this.offsetWidth > this.offsetHeight);
540
- const e = c(this, it) ? this.offsetWidth : this.offsetHeight;
541
- St(this, rt, e / ((this.scrollElement.scrollSize + this.scrollElement.viewportSize) / e)), St(this, rt, Math.max(c(this, rt), 30)), c(this, it) ? (c(this, O).style.width = c(this, rt) + "px", c(this, O).style.height = "100%") : (c(this, O).style.width = "100%", c(this, O).style.height = c(this, rt) + "px"), St(this, Xt, e - c(this, rt)), this.scrollElement.scrollSize || (this.style.display = "none");
542
- }), K(this, Se, () => {
543
- St(this, Yt, this.scrollElement.currentProgress * c(this, Xt)), c(this, it) ? c(this, O).style.transform = `translate3d(${c(this, Yt)}px, 0px, 0px)` : c(this, O).style.transform = `translate3d(0px, ${c(this, Yt)}px, 0px)`;
544
- }), K(this, me, () => {
553
+ const s = u(this, it) ? this.offsetWidth : this.offsetHeight;
554
+ St(this, rt, s / ((this.scrollElement.scrollSize + this.scrollElement.viewportSize) / s)), St(this, rt, Math.max(u(this, rt), 30)), u(this, it) ? (u(this, O).style.width = u(this, rt) + "px", u(this, O).style.height = "100%") : (u(this, O).style.width = "100%", u(this, O).style.height = u(this, rt) + "px"), St(this, jt, s - u(this, rt)), this.scrollElement.scrollSize || (this.style.display = "none");
555
+ }), N(this, me, () => {
556
+ St(this, te, this.scrollElement.currentProgress * u(this, jt)), u(this, it) ? u(this, O).style.transform = `translate3d(${u(this, te)}px, 0px, 0px)` : u(this, O).style.transform = `translate3d(0px, ${u(this, te)}px, 0px)`;
557
+ }), N(this, ve, () => {
545
558
  this.setAttribute("axis", this.scrollElement.axisCSSProperty.current);
546
- }), K(this, ve, (e) => {
547
- document.documentElement.classList.add("grabbing"), Ks(
559
+ }), N(this, ge, (s) => {
560
+ document.documentElement.classList.add("grabbing"), qs(
548
561
  (h) => {
549
- const n = c(this, it) ? h.x : h.y, u = this.scrollElement.distance / c(this, Xt), m = (n - r) * u;
550
- this.scrollElement.setPosition(i + m);
562
+ const n = u(this, it) ? h.x : h.y, p = this.scrollElement.distance / u(this, jt), S = (n - r) * p;
563
+ this.scrollElement.setPosition(i + S);
551
564
  },
552
565
  () => {
553
566
  document.documentElement.classList.remove("grabbing");
554
567
  }
555
568
  );
556
- const i = this.scrollElement.targetScrollValue, r = c(this, it) ? e.x : e.y;
557
- }), Ze && (this.openShadow(ti), Xe(this, {
569
+ const i = this.scrollElement.targetScrollValue, r = u(this, it) ? s.x : s.y;
570
+ }), Je && (this.openShadow(ii), Ye(this, {
558
571
  slot: "static",
559
572
  "drag-dead-zone": "",
560
573
  children: [
561
- We({
562
- ref: (e) => St(this, Qt, e),
574
+ Me({
575
+ ref: (s) => St(this, Yt, s),
563
576
  children: Oe({ class: "default-thumb" })
564
577
  })
565
578
  ]
566
579
  }));
567
580
  }
568
581
  get thumbElement() {
569
- return c(this, O);
582
+ return u(this, O);
570
583
  }
571
584
  connectedCallback() {
572
585
  super.connectedCallback();
573
- const e = c(this, Qt).assignedElements()[0] || c(this, Qt).firstElementChild;
574
- St(this, O, e), c(this, O).addEventListener("pointerdown", c(this, ve)), Gt.subscribe(c(this, Ot), Qe.SCROLL + 1), cs.subscribe(this, c(this, Ot)), this.scrollElement.onScroll(c(this, Se)), this.scrollElement.axisCSSProperty.subscribe(c(this, me));
586
+ const s = u(this, Yt).assignedElements()[0] || u(this, Yt).firstElementChild;
587
+ St(this, O, s), u(this, O).addEventListener("pointerdown", u(this, ge)), Kt.subscribe(u(this, Dt), Xe.SCROLL + 1), us.subscribe(this, u(this, Dt)), this.scrollElement.onScroll(u(this, me)), this.scrollElement.axisCSSProperty.subscribe(u(this, ve));
575
588
  }
576
589
  disconnectedCallback() {
577
- c(this, O).removeEventListener("pointerdown", c(this, ve)), Gt.unsubscribe(c(this, Ot)), cs.unsubscribe(c(this, Ot)), this.scrollElement.offScroll(c(this, Se)), this.scrollElement.axisCSSProperty.unsubscribe(c(this, me));
590
+ u(this, O).removeEventListener("pointerdown", u(this, ge)), Kt.unsubscribe(u(this, Dt)), us.unsubscribe(u(this, Dt)), this.scrollElement.offScroll(u(this, me)), this.scrollElement.axisCSSProperty.unsubscribe(u(this, ve));
578
591
  }
579
592
  };
580
- Qt = /* @__PURE__ */ new WeakMap();
593
+ Yt = /* @__PURE__ */ new WeakMap();
581
594
  O = /* @__PURE__ */ new WeakMap();
582
595
  it = /* @__PURE__ */ new WeakMap();
583
596
  rt = /* @__PURE__ */ new WeakMap();
584
- Xt = /* @__PURE__ */ new WeakMap();
585
- Yt = /* @__PURE__ */ new WeakMap();
586
- Ot = /* @__PURE__ */ new WeakMap();
587
- Se = /* @__PURE__ */ new WeakMap();
597
+ jt = /* @__PURE__ */ new WeakMap();
598
+ te = /* @__PURE__ */ new WeakMap();
599
+ Dt = /* @__PURE__ */ new WeakMap();
588
600
  me = /* @__PURE__ */ new WeakMap();
589
601
  ve = /* @__PURE__ */ new WeakMap();
590
- us = js([
591
- qt("e-scrollbar")
592
- ], us);
593
- const ei = Ye({
602
+ ge = /* @__PURE__ */ new WeakMap();
603
+ ps = si([
604
+ Zt("e-scrollbar")
605
+ ], ps);
606
+ const ri = je({
594
607
  button: {
595
608
  all: "inherit"
596
609
  }
597
610
  });
598
- class Cs extends Fe {
611
+ class ks extends Fe {
599
612
  constructor() {
600
- super(), this.openShadow(ei), Ze && Xe(this, {
613
+ super(), this.openShadow(ri), Je && Ye(this, {
601
614
  children: [
602
- Hs({
615
+ Ks({
603
616
  onClick: () => {
604
617
  this.handleClick();
605
618
  },
606
- children: [We()]
619
+ children: [Me()]
607
620
  })
608
621
  ]
609
622
  });
610
623
  }
611
624
  }
612
- var si = Object.defineProperty, ii = Object.getOwnPropertyDescriptor, ri = (e, i, r, h) => {
613
- for (var n = h > 1 ? void 0 : h ? ii(i, r) : i, u = e.length - 1, m; u >= 0; u--)
614
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
615
- return h && n && si(i, r, n), n;
616
- };
617
- let ps = class extends Cs {
618
- handleClick() {
619
- const e = this.getAttribute("index"), i = this.getAttribute("behaviour");
620
- this.scrollElement.scrollToSection(parseInt(e || "0"), i);
621
- }
622
- };
623
- ps = ri([
624
- qt("e-scroll-set-button")
625
- ], ps);
626
- var hi = Object.defineProperty, ni = Object.getOwnPropertyDescriptor, ai = (e, i, r, h) => {
627
- for (var n = h > 1 ? void 0 : h ? ni(i, r) : i, u = e.length - 1, m; u >= 0; u--)
628
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
625
+ var hi = Object.defineProperty, ni = Object.getOwnPropertyDescriptor, ai = (s, i, r, h) => {
626
+ for (var n = h > 1 ? void 0 : h ? ni(i, r) : i, p = s.length - 1, S; p >= 0; p--)
627
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
629
628
  return h && n && hi(i, r, n), n;
630
629
  };
631
- let fs = class extends Cs {
630
+ let fs = class extends ks {
632
631
  handleClick() {
633
- const e = this.getAttribute("step"), i = this.getAttribute("behaviour");
634
- this.scrollElement.shiftSections(parseInt(e || "1"), i);
632
+ const s = this.getAttribute("index"), i = this.getAttribute("behaviour");
633
+ this.scrollElement.scrollToSection(parseInt(s || "0"), i);
635
634
  }
636
635
  };
637
636
  fs = ai([
638
- qt("e-scroll-step-button")
637
+ Zt("e-scroll-set-button")
639
638
  ], fs);
640
- var oi = Object.defineProperty, li = Object.getOwnPropertyDescriptor, ci = (e, i, r, h) => {
641
- for (var n = h > 1 ? void 0 : h ? li(i, r) : i, u = e.length - 1, m; u >= 0; u--)
642
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
639
+ var oi = Object.defineProperty, li = Object.getOwnPropertyDescriptor, ci = (s, i, r, h) => {
640
+ for (var n = h > 1 ? void 0 : h ? li(i, r) : i, p = s.length - 1, S; p >= 0; p--)
641
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
643
642
  return h && n && oi(i, r, n), n;
644
- }, ys = (e, i, r) => {
645
- if (!i.has(e))
643
+ };
644
+ let ds = class extends ks {
645
+ handleClick() {
646
+ const s = this.getAttribute("step"), i = this.getAttribute("behaviour");
647
+ this.scrollElement.shiftSections(parseInt(s || "1"), i);
648
+ }
649
+ };
650
+ ds = ci([
651
+ Zt("e-scroll-step-button")
652
+ ], ds);
653
+ var ui = Object.defineProperty, pi = Object.getOwnPropertyDescriptor, fi = (s, i, r, h) => {
654
+ for (var n = h > 1 ? void 0 : h ? pi(i, r) : i, p = s.length - 1, S; p >= 0; p--)
655
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
656
+ return h && n && ui(i, r, n), n;
657
+ }, Ps = (s, i, r) => {
658
+ if (!i.has(s))
646
659
  throw TypeError("Cannot " + r);
647
- }, Lt = (e, i, r) => (ys(e, i, "read from private field"), r ? r.call(e) : i.get(e)), ds = (e, i, r) => {
648
- if (i.has(e))
660
+ }, Vt = (s, i, r) => (Ps(s, i, "read from private field"), r ? r.call(s) : i.get(s)), Ss = (s, i, r) => {
661
+ if (i.has(s))
649
662
  throw TypeError("Cannot add the same private member more than once");
650
- i instanceof WeakSet ? i.add(e) : i.set(e, r);
651
- }, Ss = (e, i, r, h) => (ys(e, i, "write to private field"), h ? h.call(e, r) : i.set(e, r), r), wt, jt, Y, dt, Bt, ne, ae, Ht;
652
- class ui {
663
+ i instanceof WeakSet ? i.add(s) : i.set(s, r);
664
+ }, ms = (s, i, r, h) => (Ps(s, i, "write to private field"), h ? h.call(s, r) : i.set(s, r), r), wt, ee, Y, dt, Gt, ae, oe, Nt;
665
+ class di {
653
666
  constructor(i, r, h) {
654
667
  $(this, Y, void 0);
655
668
  $(this, dt, void 0);
656
- $(this, Bt, void 0);
657
- $(this, ne, void 0);
658
- $(this, ae, () => {
659
- a(this, dt).scrollToSection(a(this, Bt), a(this, ne));
669
+ $(this, Gt, void 0);
670
+ $(this, ae, void 0);
671
+ $(this, oe, () => {
672
+ a(this, dt).scrollToSection(a(this, Gt), a(this, ae));
660
673
  });
661
- $(this, Ht, () => {
674
+ $(this, Nt, () => {
662
675
  a(this, Y).classList.toggle(
663
676
  "current",
664
- a(this, dt).counter.current === a(this, Bt)
677
+ a(this, dt).counter.current === a(this, Gt)
665
678
  );
666
679
  });
667
- R(this, Y, document.createElement("button")), R(this, dt, i), R(this, ne, h), R(this, Bt, r), a(this, Y).addEventListener("click", a(this, ae)), a(this, dt).counter.subscribe(a(this, Ht)), a(this, Ht).call(this);
680
+ R(this, Y, document.createElement("button")), R(this, dt, i), R(this, ae, h), R(this, Gt, r), a(this, Y).addEventListener("click", a(this, oe)), a(this, dt).counter.subscribe(a(this, Nt)), a(this, Nt).call(this);
668
681
  }
669
682
  get element() {
670
683
  return a(this, Y);
671
684
  }
672
685
  destroy() {
673
- a(this, Y).removeEventListener("click", a(this, ae)), a(this, dt).counter.unsubscribe(a(this, Ht)), a(this, Y).remove();
686
+ a(this, Y).removeEventListener("click", a(this, oe)), a(this, dt).counter.unsubscribe(a(this, Nt)), a(this, Y).remove();
674
687
  }
675
688
  }
676
- Y = new WeakMap(), dt = new WeakMap(), Bt = new WeakMap(), ne = new WeakMap(), ae = new WeakMap(), Ht = new WeakMap();
677
- let ms = class extends Fe {
689
+ Y = new WeakMap(), dt = new WeakMap(), Gt = new WeakMap(), ae = new WeakMap(), oe = new WeakMap(), Nt = new WeakMap();
690
+ let vs = class extends Fe {
678
691
  constructor() {
679
- super(...arguments), ds(this, wt, []), ds(this, jt, ws(() => {
680
- Lt(this, wt).forEach((e) => e.destroy()), Ss(this, wt, []);
681
- for (let e = 0; e < this.scrollElement.sections.length; e++) {
682
- const i = new ui(
692
+ super(...arguments), Ss(this, wt, []), Ss(this, ee, bs(() => {
693
+ Vt(this, wt).forEach((s) => s.destroy()), ms(this, wt, []);
694
+ for (let s = 0; s < this.scrollElement.sections.length; s++) {
695
+ const i = new di(
683
696
  this.scrollElement,
684
- e,
697
+ s,
685
698
  this.getAttribute("behaviour") || "smooth"
686
699
  );
687
- this.appendChild(i.element), Lt(this, wt).push(i);
700
+ this.appendChild(i.element), Vt(this, wt).push(i);
688
701
  }
689
702
  }, 0));
690
703
  }
691
704
  connectedCallback() {
692
705
  super.connectedCallback(), this.scrollElement.addEventListener(
693
706
  "sectionsChange",
694
- Lt(this, jt)
695
- ), Lt(this, jt).call(this);
707
+ Vt(this, ee)
708
+ ), Vt(this, ee).call(this);
696
709
  }
697
710
  disconnectedCallback() {
698
711
  this.scrollElement.removeEventListener(
699
712
  "sectionsChange",
700
- Lt(this, jt)
701
- ), Lt(this, wt).forEach((e) => e.destroy()), Ss(this, wt, []);
713
+ Vt(this, ee)
714
+ ), Vt(this, wt).forEach((s) => s.destroy()), ms(this, wt, []);
702
715
  }
703
716
  };
704
717
  wt = /* @__PURE__ */ new WeakMap();
705
- jt = /* @__PURE__ */ new WeakMap();
706
- ms = ci([
707
- qt("e-scroll-bullet-buttons")
708
- ], ms);
709
- var pi = Object.defineProperty, fi = Object.getOwnPropertyDescriptor, di = (e, i, r, h) => {
710
- for (var n = h > 1 ? void 0 : h ? fi(i, r) : i, u = e.length - 1, m; u >= 0; u--)
711
- (m = e[u]) && (n = (h ? m(i, r, n) : m(n)) || n);
712
- return h && n && pi(i, r, n), n;
713
- }, is = (e, i, r) => {
714
- if (!i.has(e))
718
+ ee = /* @__PURE__ */ new WeakMap();
719
+ vs = fi([
720
+ Zt("e-scroll-bullet-buttons")
721
+ ], vs);
722
+ var Si = Object.defineProperty, mi = Object.getOwnPropertyDescriptor, vi = (s, i, r, h) => {
723
+ for (var n = h > 1 ? void 0 : h ? mi(i, r) : i, p = s.length - 1, S; p >= 0; p--)
724
+ (S = s[p]) && (n = (h ? S(i, r, n) : S(n)) || n);
725
+ return h && n && Si(i, r, n), n;
726
+ }, rs = (s, i, r) => {
727
+ if (!i.has(s))
715
728
  throw TypeError("Cannot " + r);
716
- }, t = (e, i, r) => (is(e, i, "read from private field"), r ? r.call(e) : i.get(e)), o = (e, i, r) => {
717
- if (i.has(e))
729
+ }, t = (s, i, r) => (rs(s, i, "read from private field"), r ? r.call(s) : i.get(s)), o = (s, i, r) => {
730
+ if (i.has(s))
718
731
  throw TypeError("Cannot add the same private member more than once");
719
- i instanceof WeakSet ? i.add(e) : i.set(e, r);
720
- }, S = (e, i, r, h) => (is(e, i, "write to private field"), h ? h.call(e, r) : i.set(e, r), r), k = (e, i, r) => (is(e, i, "access private method"), r), Dt, bt, _t, Ct, yt, z, B, H, G, Pt, L, ct, ut, nt, at, ot, Rt, te, x, q, U, pt, ft, J, ge, v, Tt, At, we, I, Q, V, M, T, ee, Mt, W, be, Ie, rs, ks, Be, Ps, He, Ws, Ge, Ms, Ke, Es, Ue, xs, qe, Ls, _e, se, ht, kt, hs, Vs, ns, zs, Ce, Ne, ye;
721
- let vs = class extends Fe {
732
+ i instanceof WeakSet ? i.add(s) : i.set(s, r);
733
+ }, m = (s, i, r, h) => (rs(s, i, "write to private field"), h ? h.call(s, r) : i.set(s, r), r), k = (s, i, r) => (rs(s, i, "access private method"), r), Rt, bt, _t, Ct, yt, z, B, H, G, Pt, L, ct, ut, nt, at, ot, Tt, se, x, U, K, pt, ft, J, we, v, At, It, be, I, Q, V, M, T, ie, Et, W, _e, Be, hs, Ws, He, Ms, Ge, Es, Ne, xs, Ke, Ls, Ue, Vs, qe, zs, Ce, re, ht, kt, ns, $s, as, Fs, ye, Ze, ke;
734
+ let gs = class extends Fe {
722
735
  constructor() {
723
- super(...arguments), o(this, be), o(this, rs), o(this, Be), o(this, He), o(this, Ge), o(this, Ke), o(this, Ue), o(this, qe), o(this, ht), o(this, hs), o(this, ns), o(this, Ce), o(this, Dt, new f(this, "--target", "")), o(this, bt, new f(this, "--disabled", !1)), o(this, _t, new f(
736
+ super(...arguments), o(this, _e), o(this, hs), o(this, He), o(this, Ge), o(this, Ne), o(this, Ke), o(this, Ue), o(this, qe), o(this, ht), o(this, ns), o(this, as), o(this, ye), o(this, Rt, new d(this, "--target", "")), o(this, bt, new d(this, "--disabled", !1)), o(this, _t, new d(
724
737
  this,
725
738
  "--distance-offset",
726
739
  0
727
- )), o(this, Ct, new f(this, "--start-offset", 0)), o(this, yt, new f(
740
+ )), o(this, Ct, new d(this, "--start-offset", 0)), o(this, yt, new d(
728
741
  this,
729
742
  "--capture-once",
730
743
  !1
731
- )), o(this, z, new f(this, "--captured", "")), o(this, B, new f(this, "--released", "")), o(this, H, new f(
744
+ )), o(this, z, new d(this, "--captured", "")), o(this, B, new d(this, "--released", "")), o(this, H, new d(
732
745
  this,
733
746
  "--captured-from-start",
734
747
  ""
735
- )), o(this, G, new f(
748
+ )), o(this, G, new d(
736
749
  this,
737
750
  "--captured-from-finish",
738
751
  ""
739
- )), o(this, Pt, new f(
752
+ )), o(this, Pt, new d(
740
753
  this,
741
754
  "--released-from-start",
742
755
  ""
743
- )), o(this, L, new f(
756
+ )), o(this, L, new d(
744
757
  this,
745
758
  "--released-from-finish",
746
759
  ""
747
- )), o(this, ct, new f(this, "--passed-var", "")), o(this, ut, new f(this, "--progress-var", "")), o(this, nt, new f(this, "--distance-var", "")), o(this, at, new f(this, "--start-var", "")), o(this, ot, new f(this, "--finish-var", "")), o(this, Rt, new f(this, "--smoothstep", !1)), o(this, te, new f(
760
+ )), o(this, ct, new d(this, "--passed-var", "")), o(this, ut, new d(this, "--progress-var", "")), o(this, nt, new d(this, "--distance-var", "")), o(this, at, new d(this, "--start-var", "")), o(this, ot, new d(this, "--finish-var", "")), o(this, Tt, new d(this, "--smoothstep", !1)), o(this, se, new d(
748
761
  this,
749
762
  "--smootherstep",
750
763
  !1
751
- )), o(this, x, new mt(!1)), o(this, q, new mt(!1)), o(this, U, new mt(!1)), o(this, pt, new mt(!1)), o(this, ft, new mt(!1)), o(this, J, new mt(!1)), o(this, ge, []), o(this, v, this), o(this, Tt, 0), o(this, At, 0), o(this, we, 0), o(this, I, 0), o(this, Q, 0), o(this, V, 0), o(this, M, 0), o(this, T, 0), o(this, ee, !1), o(this, Mt, !1), o(this, W, !0), o(this, _e, () => {
752
- t(this, W) || (this.resize(), t(this, se).call(this));
753
- }), o(this, se, () => {
754
- !t(this, W) && t(this, ee) && this.tick();
755
- }), o(this, ye, ws(() => {
756
- const e = xt.getAll(this).reverse();
764
+ )), o(this, x, new mt(!1)), o(this, U, new mt(!1)), o(this, K, new mt(!1)), o(this, pt, new mt(!1)), o(this, ft, new mt(!1)), o(this, J, new mt(!1)), o(this, we, []), o(this, v, this), o(this, At, 0), o(this, It, 0), o(this, be, 0), o(this, I, 0), o(this, Q, 0), o(this, V, 0), o(this, M, 0), o(this, T, 0), o(this, ie, !1), o(this, Et, !1), o(this, W, !0), o(this, Ce, () => {
765
+ t(this, W) || (this.resize(), t(this, re).call(this));
766
+ }), o(this, re, () => {
767
+ !t(this, W) && t(this, ie) && this.tick();
768
+ }), o(this, ke, bs(() => {
769
+ const s = Lt.getAll(this).reverse();
757
770
  let i = 0;
758
- e.forEach((r, h) => {
771
+ s.forEach((r, h) => {
759
772
  r.element === this.scrollElement && (i = h);
760
- }), S(this, ge, e.slice(i + 1));
773
+ }), m(this, we, s.slice(i + 1));
761
774
  }, 0));
762
775
  }
763
776
  get distanceOffsetCSSProperty() {
@@ -803,25 +816,25 @@ let vs = class extends Fe {
803
816
  return t(this, ot);
804
817
  }
805
818
  get smoothstepCSSProperty() {
806
- return t(this, Rt);
819
+ return t(this, Tt);
807
820
  }
808
821
  get smootherstepCSSProperty() {
809
- return t(this, te);
822
+ return t(this, se);
810
823
  }
811
824
  get disabledCSSProperty() {
812
825
  return t(this, bt);
813
826
  }
814
827
  get targetCSSProperty() {
815
- return t(this, Dt);
828
+ return t(this, Rt);
816
829
  }
817
830
  get isCaptured() {
818
831
  return t(this, x);
819
832
  }
820
833
  get isReleased() {
821
- return t(this, q);
834
+ return t(this, U);
822
835
  }
823
836
  get isCapturedFromStart() {
824
- return t(this, U);
837
+ return t(this, K);
825
838
  }
826
839
  get isReleasedFromStart() {
827
840
  return t(this, pt);
@@ -833,10 +846,10 @@ let vs = class extends Fe {
833
846
  return t(this, J);
834
847
  }
835
848
  get directionPosition() {
836
- return t(this, Tt);
849
+ return t(this, At);
837
850
  }
838
851
  get directionSize() {
839
- return t(this, At);
852
+ return t(this, It);
840
853
  }
841
854
  get passed() {
842
855
  return t(this, I);
@@ -854,42 +867,42 @@ let vs = class extends Fe {
854
867
  return t(this, M);
855
868
  }
856
869
  get isCapturedOnce() {
857
- return t(this, Mt);
870
+ return t(this, Et);
858
871
  }
859
872
  get isDisabled() {
860
873
  return t(this, W);
861
874
  }
862
875
  resize() {
863
- S(this, At, this.scrollElement.vertical ? this.offsetHeight : this.offsetWidth), S(this, Tt, this.scrollElement.vertical ? ke(this, this.scrollElement) : Pe(this, this.scrollElement)), S(this, V, this.getStart()), S(this, M, this.getDistance()), S(this, V, t(this, V) + t(this, Ct).current), S(this, M, t(this, M) + t(this, _t).current), S(this, T, t(this, V) + t(this, M)), this.scrollElement.currentScrollValue > t(this, T) && !t(this, x).current && !t(this, q).current && (t(this, x).current = !0), this.setVar(t(this, at).current, t(this, V)), this.setVar(t(this, ot).current, t(this, T)), this.setVar(t(this, nt).current, t(this, M)), S(this, ee, !0);
876
+ m(this, It, this.scrollElement.vertical ? this.offsetHeight : this.offsetWidth), m(this, At, this.scrollElement.vertical ? Pe(this, this.scrollElement) : We(this, this.scrollElement)), m(this, V, this.getStart()), m(this, M, this.getDistance()), m(this, V, t(this, V) + t(this, Ct).current), m(this, M, t(this, M) + t(this, _t).current), m(this, T, t(this, V) + t(this, M)), this.scrollElement.currentScrollValue > t(this, T) && !t(this, x).current && !t(this, U).current && (t(this, x).current = !0), this.setVar(t(this, at).current, t(this, V)), this.setVar(t(this, ot).current, t(this, T)), this.setVar(t(this, nt).current, t(this, M)), m(this, ie, !0);
864
877
  }
865
878
  tick() {
866
- let e = this.scrollElement.currentScrollValue;
867
- t(this, ge).forEach((r) => {
868
- e += r.value;
869
- }), S(this, I, this.updateValue(e - t(this, V), 0, t(this, M)) || 0), S(this, Q, t(this, I) / t(this, M) || 0);
870
- const i = Math.round(e);
871
- t(this, x).current && (i > t(this, V) ? t(this, U).current || k(this, Ge, Ms).call(this) : t(this, U).current && !t(this, pt).current && k(this, Ue, xs).call(this), i < t(this, T) ? t(this, J).current && !t(this, ft).current && k(this, Ke, Es).call(this) : t(this, U).current && !t(this, J).current && k(this, qe, Ls).call(this)), i > t(this, V) && i < t(this, T) ? (k(this, be, Ie).call(this), t(this, x).current || k(this, Be, Ps).call(this)) : t(this, x).current && (S(this, I, Fs(t(this, M) / 2, t(this, I), 0, t(this, M))), S(this, Q, t(this, I) / t(this, M)), k(this, be, Ie).call(this), k(this, He, Ws).call(this)), t(this, Mt) && t(this, yt).current && (t(this, z).current && t(this, v).classList.add(t(this, z).current), S(this, W, !0));
879
+ let s = this.scrollElement.currentScrollValue;
880
+ t(this, we).forEach((r) => {
881
+ s += r.value;
882
+ }), m(this, I, this.updateValue(s - t(this, V), 0, t(this, M)) || 0), m(this, Q, t(this, I) / t(this, M) || 0);
883
+ const i = Math.round(s);
884
+ t(this, x).current && (i > t(this, V) ? t(this, K).current || k(this, Ne, xs).call(this) : t(this, K).current && !t(this, pt).current && k(this, Ue, Vs).call(this), i < t(this, T) ? t(this, J).current && !t(this, ft).current && k(this, Ke, Ls).call(this) : t(this, K).current && !t(this, J).current && k(this, qe, zs).call(this)), i > t(this, V) && i < t(this, T) ? (k(this, _e, Be).call(this), t(this, x).current || k(this, He, Ms).call(this)) : t(this, x).current && (m(this, I, Rs(t(this, M) / 2, t(this, I), 0, t(this, M))), m(this, Q, t(this, I) / t(this, M)), k(this, _e, Be).call(this), k(this, Ge, Es).call(this)), t(this, Et) && t(this, yt).current && (t(this, z).current && t(this, v).classList.add(t(this, z).current), m(this, W, !0));
872
885
  }
873
886
  disable() {
874
- this.style.cssText = "", S(this, Tt, 0), S(this, At, 0), S(this, I, 0), S(this, Q, 0), S(this, V, 0), S(this, M, 0), S(this, T, 0), S(this, ee, !1), t(this, x).current = !1, t(this, q).current = !1, t(this, U).current = !1, t(this, pt).current = !1, t(this, ft).current = !1, t(this, J).current = !1, S(this, Mt, !1), S(this, W, !0), k(this, Ce, Ne).call(this);
887
+ this.style.cssText = "", m(this, At, 0), m(this, It, 0), m(this, I, 0), m(this, Q, 0), m(this, V, 0), m(this, M, 0), m(this, T, 0), m(this, ie, !1), t(this, x).current = !1, t(this, U).current = !1, t(this, K).current = !1, t(this, pt).current = !1, t(this, ft).current = !1, t(this, J).current = !1, m(this, Et, !1), m(this, W, !0), k(this, ye, Ze).call(this);
875
888
  }
876
889
  enable() {
877
- S(this, W, !1);
890
+ m(this, W, !1);
878
891
  }
879
892
  connectedCallback() {
880
- super.connectedCallback(), t(this, Dt).observe(), t(this, bt).observe(), t(this, _t).observe(), t(this, Ct).observe(), t(this, yt).observe(), t(this, z).observe(), t(this, B).observe(), t(this, H).observe(), t(this, G).observe(), t(this, Pt).observe(), t(this, L).observe(), t(this, ct).observe(), t(this, ut).observe(), t(this, nt).observe(), t(this, at).observe(), t(this, ot).observe(), t(this, Rt).observe(), t(this, te).observe();
881
- let e = !1;
893
+ super.connectedCallback(), t(this, Rt).observe(), t(this, bt).observe(), t(this, _t).observe(), t(this, Ct).observe(), t(this, yt).observe(), t(this, z).observe(), t(this, B).observe(), t(this, H).observe(), t(this, G).observe(), t(this, Pt).observe(), t(this, L).observe(), t(this, ct).observe(), t(this, ut).observe(), t(this, nt).observe(), t(this, at).observe(), t(this, ot).observe(), t(this, Tt).observe(), t(this, se).observe();
894
+ let s = !1;
882
895
  this.scrollElement.addEventListener(
883
896
  "sectionsChange",
884
- t(this, ye)
885
- ), t(this, ye).call(this), t(this, bt).current || this.enable(), t(this, Dt).subscribe((i) => {
886
- i.previous && k(this, Ce, Ne).call(this), i.current ? i.current === "parent" ? S(this, v, this.parentElement || this) : S(this, v, document.querySelector(i.current) || this) : S(this, v, this);
897
+ t(this, ke)
898
+ ), t(this, ke).call(this), t(this, bt).current || this.enable(), t(this, Rt).subscribe((i) => {
899
+ i.previous && k(this, ye, Ze).call(this), i.current ? i.current === "parent" ? m(this, v, this.parentElement || this) : m(this, v, document.querySelector(i.current) || this) : m(this, v, this);
887
900
  }), t(this, bt).subscribe((i) => {
888
901
  i.current && !i.previous ? this.disable() : !i.current && i.previous && (this.resize(), this.enable());
889
902
  }), t(this, Ct).subscribe(() => {
890
- e && !t(this, W) && this.resize();
903
+ s && !t(this, W) && this.resize();
891
904
  }), t(this, _t).subscribe(() => {
892
- e && !t(this, W) && this.resize();
905
+ s && !t(this, W) && this.resize();
893
906
  }), t(this, z).subscribe((i) => {
894
907
  k(this, ht, kt).call(this, i);
895
908
  }), t(this, H).subscribe((i) => {
@@ -914,28 +927,28 @@ let vs = class extends Fe {
914
927
  t(this, W) || (this.removeVar(i.previous), this.setVar(i.current, t(this, T)));
915
928
  }), t(this, nt).subscribe((i) => {
916
929
  t(this, W) || (this.removeVar(i.previous), this.setVar(i.current, t(this, M)));
917
- }), Gt.subscribe(t(this, _e), Qe.SEGMENT), this.scrollElement.onScroll(t(this, se)), e = !0;
930
+ }), Kt.subscribe(t(this, Ce), Xe.SEGMENT), this.scrollElement.onScroll(t(this, re)), s = !0;
918
931
  }
919
932
  disconnectedCallback() {
920
- Gt.unsubscribe(t(this, _e)), this.scrollElement.offScroll(t(this, se)), t(this, Dt).close(), t(this, bt).close(), t(this, _t).close(), t(this, Ct).close(), t(this, yt).close(), t(this, z).close(), t(this, B).close(), t(this, H).close(), t(this, G).close(), t(this, Pt).close(), t(this, L).close(), t(this, ct).close(), t(this, ut).close(), t(this, nt).close(), t(this, at).close(), t(this, ot).close(), t(this, Rt).close(), t(this, te).close(), t(this, x).close(), t(this, q).close(), t(this, U).close(), t(this, pt).close(), t(this, ft).close(), t(this, J).close(), this.disable();
933
+ Kt.unsubscribe(t(this, Ce)), this.scrollElement.offScroll(t(this, re)), t(this, Rt).close(), t(this, bt).close(), t(this, _t).close(), t(this, Ct).close(), t(this, yt).close(), t(this, z).close(), t(this, B).close(), t(this, H).close(), t(this, G).close(), t(this, Pt).close(), t(this, L).close(), t(this, ct).close(), t(this, ut).close(), t(this, nt).close(), t(this, at).close(), t(this, ot).close(), t(this, Tt).close(), t(this, se).close(), t(this, x).close(), t(this, U).close(), t(this, K).close(), t(this, pt).close(), t(this, ft).close(), t(this, J).close(), this.disable();
921
934
  }
922
- removeVar(e) {
923
- e && t(this, v).style.removeProperty(`--${e}`);
935
+ removeVar(s) {
936
+ s && t(this, v).style.removeProperty(`--${s}`);
924
937
  }
925
- setVar(e, i) {
926
- e && t(this, v).style.setProperty(`--${e}`, i.toString());
938
+ setVar(s, i) {
939
+ s && t(this, v).style.setProperty(`--${s}`, i.toString());
927
940
  }
928
- updateValue(e, i = 0, r = 1) {
929
- return this.smootherstepCSSProperty.current ? Os(e, i, r) * r : t(this, Rt).current ? Ds(e, i, r) * r : Je(e, i, r);
941
+ updateValue(s, i = 0, r = 1) {
942
+ return this.smootherstepCSSProperty.current ? Ts(s, i, r) * r : t(this, Tt).current ? As(s, i, r) * r : Qe(s, i, r);
930
943
  }
931
944
  getDistance() {
932
- return t(this, At) + t(this, we);
945
+ return t(this, It) + t(this, be);
933
946
  }
934
947
  getStart() {
935
- return t(this, Tt) - t(this, we);
948
+ return t(this, At) - t(this, be);
936
949
  }
937
950
  };
938
- Dt = /* @__PURE__ */ new WeakMap();
951
+ Rt = /* @__PURE__ */ new WeakMap();
939
952
  bt = /* @__PURE__ */ new WeakMap();
940
953
  _t = /* @__PURE__ */ new WeakMap();
941
954
  Ct = /* @__PURE__ */ new WeakMap();
@@ -951,33 +964,33 @@ ut = /* @__PURE__ */ new WeakMap();
951
964
  nt = /* @__PURE__ */ new WeakMap();
952
965
  at = /* @__PURE__ */ new WeakMap();
953
966
  ot = /* @__PURE__ */ new WeakMap();
954
- Rt = /* @__PURE__ */ new WeakMap();
955
- te = /* @__PURE__ */ new WeakMap();
967
+ Tt = /* @__PURE__ */ new WeakMap();
968
+ se = /* @__PURE__ */ new WeakMap();
956
969
  x = /* @__PURE__ */ new WeakMap();
957
- q = /* @__PURE__ */ new WeakMap();
958
970
  U = /* @__PURE__ */ new WeakMap();
971
+ K = /* @__PURE__ */ new WeakMap();
959
972
  pt = /* @__PURE__ */ new WeakMap();
960
973
  ft = /* @__PURE__ */ new WeakMap();
961
974
  J = /* @__PURE__ */ new WeakMap();
962
- ge = /* @__PURE__ */ new WeakMap();
975
+ we = /* @__PURE__ */ new WeakMap();
963
976
  v = /* @__PURE__ */ new WeakMap();
964
- Tt = /* @__PURE__ */ new WeakMap();
965
977
  At = /* @__PURE__ */ new WeakMap();
966
- we = /* @__PURE__ */ new WeakMap();
978
+ It = /* @__PURE__ */ new WeakMap();
979
+ be = /* @__PURE__ */ new WeakMap();
967
980
  I = /* @__PURE__ */ new WeakMap();
968
981
  Q = /* @__PURE__ */ new WeakMap();
969
982
  V = /* @__PURE__ */ new WeakMap();
970
983
  M = /* @__PURE__ */ new WeakMap();
971
984
  T = /* @__PURE__ */ new WeakMap();
972
- ee = /* @__PURE__ */ new WeakMap();
973
- Mt = /* @__PURE__ */ new WeakMap();
985
+ ie = /* @__PURE__ */ new WeakMap();
986
+ Et = /* @__PURE__ */ new WeakMap();
974
987
  W = /* @__PURE__ */ new WeakMap();
975
- be = /* @__PURE__ */ new WeakSet();
976
- Ie = function() {
977
- k(this, rs, ks).call(this), this.setVar(t(this, ct).current, t(this, I)), this.setVar(t(this, ut).current, t(this, Q));
988
+ _e = /* @__PURE__ */ new WeakSet();
989
+ Be = function() {
990
+ k(this, hs, Ws).call(this), this.setVar(t(this, ct).current, t(this, I)), this.setVar(t(this, ut).current, t(this, Q));
978
991
  };
979
- rs = /* @__PURE__ */ new WeakSet();
980
- ks = function() {
992
+ hs = /* @__PURE__ */ new WeakSet();
993
+ Ws = function() {
981
994
  this.dispatchEvent(
982
995
  new CustomEvent("segmentPass", {
983
996
  detail: {
@@ -990,81 +1003,81 @@ ks = function() {
990
1003
  })
991
1004
  );
992
1005
  };
993
- Be = /* @__PURE__ */ new WeakSet();
994
- Ps = function() {
995
- t(this, x).current = !0, t(this, q).current = !1, S(this, Mt, !0), t(this, B).current && t(this, v).classList.remove(t(this, B).current), t(this, L).current && t(this, v).classList.remove(
1006
+ He = /* @__PURE__ */ new WeakSet();
1007
+ Ms = function() {
1008
+ t(this, x).current = !0, t(this, U).current = !1, m(this, Et, !0), t(this, B).current && t(this, v).classList.remove(t(this, B).current), t(this, L).current && t(this, v).classList.remove(
996
1009
  t(this, L).current
997
1010
  ), t(this, L).current && t(this, v).classList.remove(
998
1011
  t(this, L).current
999
1012
  ), t(this, z).current && t(this, v).classList.add(t(this, z).current);
1000
1013
  };
1001
- He = /* @__PURE__ */ new WeakSet();
1002
- Ws = function() {
1003
- t(this, q).current = !0, t(this, x).current = !1, S(this, Mt, !0), t(this, z).current && t(this, v).classList.remove(t(this, z).current), t(this, H).current && t(this, v).classList.remove(
1014
+ Ge = /* @__PURE__ */ new WeakSet();
1015
+ Es = function() {
1016
+ t(this, U).current = !0, t(this, x).current = !1, m(this, Et, !0), t(this, z).current && t(this, v).classList.remove(t(this, z).current), t(this, H).current && t(this, v).classList.remove(
1004
1017
  t(this, H).current
1005
1018
  ), t(this, G).current && t(this, v).classList.remove(
1006
1019
  t(this, G).current
1007
1020
  ), t(this, B).current && t(this, v).classList.add(t(this, B).current);
1008
1021
  };
1009
- Ge = /* @__PURE__ */ new WeakSet();
1010
- Ms = function() {
1011
- t(this, x).current = !0, t(this, U).current = !0, t(this, pt).current = !1, t(this, H).current && t(this, v).classList.add(
1022
+ Ne = /* @__PURE__ */ new WeakSet();
1023
+ xs = function() {
1024
+ t(this, x).current = !0, t(this, K).current = !0, t(this, pt).current = !1, t(this, H).current && t(this, v).classList.add(
1012
1025
  t(this, H).current
1013
1026
  );
1014
1027
  };
1015
1028
  Ke = /* @__PURE__ */ new WeakSet();
1016
- Es = function() {
1029
+ Ls = function() {
1017
1030
  t(this, x).current = !0, t(this, ft).current = !0, t(this, J).current = !1, t(this, G).current && t(this, v).classList.add(
1018
1031
  t(this, G).current
1019
1032
  );
1020
1033
  };
1021
1034
  Ue = /* @__PURE__ */ new WeakSet();
1022
- xs = function() {
1023
- t(this, q).current = !0, t(this, pt).current = !0, t(this, U).current = !1, t(this, L).current && t(this, v).classList.add(
1035
+ Vs = function() {
1036
+ t(this, U).current = !0, t(this, pt).current = !0, t(this, K).current = !1, t(this, L).current && t(this, v).classList.add(
1024
1037
  t(this, L).current
1025
1038
  );
1026
1039
  };
1027
1040
  qe = /* @__PURE__ */ new WeakSet();
1028
- Ls = function() {
1029
- t(this, q).current = !0, t(this, J).current = !0, t(this, ft).current = !1, t(this, L).current && t(this, v).classList.add(
1041
+ zs = function() {
1042
+ t(this, U).current = !0, t(this, J).current = !0, t(this, ft).current = !1, t(this, L).current && t(this, v).classList.add(
1030
1043
  t(this, L).current
1031
1044
  );
1032
1045
  };
1033
- _e = /* @__PURE__ */ new WeakMap();
1034
- se = /* @__PURE__ */ new WeakMap();
1046
+ Ce = /* @__PURE__ */ new WeakMap();
1047
+ re = /* @__PURE__ */ new WeakMap();
1035
1048
  ht = /* @__PURE__ */ new WeakSet();
1036
- kt = function(e) {
1049
+ kt = function(s) {
1037
1050
  if (t(this, W)) {
1038
- e.previous && t(this, v).classList.remove(e.previous), e.current && t(this, v).classList.remove(e.current);
1051
+ s.previous && t(this, v).classList.remove(s.previous), s.current && t(this, v).classList.remove(s.current);
1039
1052
  return;
1040
1053
  }
1041
- e.current && t(this, x).current ? (e.previous && t(this, v).classList.remove(e.previous), t(this, v).classList.add(e.current)) : !e.current && e.previous && t(this, v).classList.remove(e.previous);
1054
+ s.current && t(this, x).current ? (s.previous && t(this, v).classList.remove(s.previous), t(this, v).classList.add(s.current)) : !s.current && s.previous && t(this, v).classList.remove(s.previous);
1042
1055
  };
1043
- hs = /* @__PURE__ */ new WeakSet();
1044
- Vs = function(...e) {
1045
- e.forEach((i) => {
1056
+ ns = /* @__PURE__ */ new WeakSet();
1057
+ $s = function(...s) {
1058
+ s.forEach((i) => {
1046
1059
  i && t(this, v).classList.remove(i);
1047
1060
  });
1048
1061
  };
1049
- ns = /* @__PURE__ */ new WeakSet();
1050
- zs = function(...e) {
1051
- e.forEach((i) => {
1062
+ as = /* @__PURE__ */ new WeakSet();
1063
+ Fs = function(...s) {
1064
+ s.forEach((i) => {
1052
1065
  i && t(this, v).style.removeProperty(`--${i}`);
1053
1066
  });
1054
1067
  };
1055
- Ce = /* @__PURE__ */ new WeakSet();
1056
- Ne = function() {
1057
- k(this, hs, Vs).call(this, t(this, z).current, t(this, H).current, t(this, G).current, t(this, B).current, t(this, Pt).current, t(this, L).current), k(this, ns, zs).call(this, t(this, ct).current, t(this, ut).current, t(this, nt).current, t(this, at).current, t(this, ot).current);
1068
+ ye = /* @__PURE__ */ new WeakSet();
1069
+ Ze = function() {
1070
+ k(this, ns, $s).call(this, t(this, z).current, t(this, H).current, t(this, G).current, t(this, B).current, t(this, Pt).current, t(this, L).current), k(this, as, Fs).call(this, t(this, ct).current, t(this, ut).current, t(this, nt).current, t(this, at).current, t(this, ot).current);
1058
1071
  };
1059
- ye = /* @__PURE__ */ new WeakMap();
1060
- vs = di([
1061
- qt("e-scroll-segment")
1062
- ], vs);
1072
+ ke = /* @__PURE__ */ new WeakMap();
1073
+ gs = vi([
1074
+ Zt("e-scroll-segment")
1075
+ ], gs);
1063
1076
  export {
1064
- ms as ScrollBulletButtonsElement,
1077
+ vs as ScrollBulletButtonsElement,
1065
1078
  ze as ScrollElement,
1066
- vs as ScrollSegmentElement,
1067
- ps as ScrollSetButtonElement,
1068
- fs as ScrollStepButtonElement,
1069
- us as ScrollbarElement
1079
+ gs as ScrollSegmentElement,
1080
+ fs as ScrollSetButtonElement,
1081
+ ds as ScrollStepButtonElement,
1082
+ ps as ScrollbarElement
1070
1083
  };