aptechka 0.65.5 → 0.65.7
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.
- package/lib/{Animation-D29tc5VS.js → Animation-BDEX44-i.js} +1 -1
- package/lib/{Animation-BRqj4VfN.cjs → Animation-hZcAchp_.cjs} +1 -1
- package/lib/{Damped-YrqW5V4w.js → Damped-CtQmJ52v.js} +2 -2
- package/lib/{Damped-BD1OQ1fH.cjs → Damped-z9Uaw2MJ.cjs} +1 -1
- package/lib/DragControls-CfE2oPAi.cjs +1 -0
- package/lib/{DragControls-DGDUw6bM.js → DragControls-CkhCt-4W.js} +21 -21
- package/lib/{Tweened-_pF0zXXN.js → Tweened-BlZB0vl4.js} +2 -2
- package/lib/{Tweened-B-AHx93m.cjs → Tweened-mvHucL4Y.cjs} +1 -1
- package/lib/animation/index.cjs +1 -1
- package/lib/animation/index.js +3 -3
- package/lib/billboard/index.cjs +1 -1
- package/lib/billboard/index.js +20 -18
- package/lib/controls/index.cjs +1 -1
- package/lib/controls/index.js +1 -1
- package/lib/{layout-BSMtwCga.js → layout-DpZo-I0y.js} +2 -2
- package/lib/layout-box/index.js +1 -1
- package/lib/morph/index.js +1 -1
- package/lib/need_redo_tweaker/index.cjs +1 -1
- package/lib/need_redo_tweaker/index.js +1 -1
- package/lib/number-ChAm68cm.cjs +1 -0
- package/lib/number-CumqY64S.js +40 -0
- package/lib/pointer/index.cjs +1 -1
- package/lib/pointer/index.js +1 -1
- package/lib/scroll/ScrollSegmentElement.d.ts +63 -2
- package/lib/scroll/index.cjs +1 -1
- package/lib/scroll/index.js +935 -556
- package/lib/{scroll-DNGJVxa2.js → scroll-DPkCFTxg.js} +1 -1
- package/lib/ticker/index.cjs +1 -1
- package/lib/ticker/index.d.ts +1 -0
- package/lib/ticker/index.js +85 -82
- package/lib/utils/index.cjs +1 -1
- package/lib/utils/index.js +3 -3
- package/package.json +1 -9
- package/lib/DragControls-D8BXtKVu.cjs +0 -1
- package/lib/ScrollSegmentElement-B6gp1q_z.js +0 -459
- package/lib/ScrollSegmentElement-DtMMAirz.cjs +0 -1
- package/lib/number-CbdpfO3u.js +0 -39
- package/lib/number-DyefJ5a1.cjs +0 -1
- package/lib/scroll-segment/ScrollSegmentDefaultContainer.d.ts +0 -11
- package/lib/scroll-segment/ScrollSegmentElement.d.ts +0 -81
- package/lib/scroll-segment/index.cjs +0 -1
- package/lib/scroll-segment/index.d.ts +0 -2
- package/lib/scroll-segment/index.js +0 -5
package/lib/scroll/index.js
CHANGED
|
@@ -1,125 +1,124 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
throw TypeError(
|
|
1
|
+
var ri = Object.defineProperty;
|
|
2
|
+
var Ds = Object.getOwnPropertySymbols, hi = Object.getPrototypeOf, ni = Object.prototype.hasOwnProperty, oi = Object.prototype.propertyIsEnumerable, li = Reflect.get;
|
|
3
|
+
var $s = (d) => {
|
|
4
|
+
throw TypeError(d);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var Os = (d, n, e) => n in d ? ri(d, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : d[n] = e, Hs = (d, n) => {
|
|
7
7
|
for (var e in n || (n = {}))
|
|
8
|
-
|
|
9
|
-
if (
|
|
10
|
-
for (var e of
|
|
11
|
-
|
|
12
|
-
return
|
|
8
|
+
ni.call(n, e) && Os(d, e, n[e]);
|
|
9
|
+
if (Ds)
|
|
10
|
+
for (var e of Ds(n))
|
|
11
|
+
oi.call(n, e) && Os(d, e, n[e]);
|
|
12
|
+
return d;
|
|
13
13
|
};
|
|
14
|
-
var
|
|
15
|
-
var t = (
|
|
16
|
-
var
|
|
17
|
-
var
|
|
18
|
-
var
|
|
14
|
+
var xs = (d, n, e) => n.has(d) || $s("Cannot " + e);
|
|
15
|
+
var t = (d, n, e) => (xs(d, n, "read from private field"), e ? e.call(d) : n.get(d)), i = (d, n, e) => n.has(d) ? $s("Cannot add the same private member more than once") : n instanceof WeakSet ? n.add(d) : n.set(d, e), r = (d, n, e, s) => (xs(d, n, "write to private field"), s ? s.call(d, e) : n.set(d, e), e), o = (d, n, e) => (xs(d, n, "access private method"), e);
|
|
16
|
+
var Ws = (d, n, e) => li(hi(d), e, n);
|
|
17
|
+
var Bs = (d, n, e) => new Promise((s, h) => {
|
|
18
|
+
var u = (C) => {
|
|
19
19
|
try {
|
|
20
|
-
|
|
21
|
-
} catch (
|
|
22
|
-
|
|
20
|
+
v(e.next(C));
|
|
21
|
+
} catch (oe) {
|
|
22
|
+
h(oe);
|
|
23
23
|
}
|
|
24
|
-
},
|
|
24
|
+
}, g = (C) => {
|
|
25
25
|
try {
|
|
26
|
-
|
|
27
|
-
} catch (
|
|
28
|
-
|
|
26
|
+
v(e.throw(C));
|
|
27
|
+
} catch (oe) {
|
|
28
|
+
h(oe);
|
|
29
29
|
}
|
|
30
|
-
},
|
|
31
|
-
|
|
30
|
+
}, v = (C) => C.done ? s(C.value) : Promise.resolve(C.value).then(u, g);
|
|
31
|
+
v((e = e.apply(d, n)).next());
|
|
32
32
|
});
|
|
33
|
-
import { S as
|
|
34
|
-
import { i as
|
|
35
|
-
import { q as
|
|
36
|
-
import { i as
|
|
37
|
-
import { d as
|
|
38
|
-
import { d as
|
|
39
|
-
import { a as
|
|
40
|
-
import { c as
|
|
41
|
-
import { p as
|
|
42
|
-
import { c as
|
|
33
|
+
import { S as le } from "../Store-0BVty6AZ.js";
|
|
34
|
+
import { i as Y } from "../index-Bv9zgfdb.js";
|
|
35
|
+
import { q as ci } from "../easings-BEmRlrDd.js";
|
|
36
|
+
import { i as ui } from "../element-CGVl1jA-.js";
|
|
37
|
+
import { d as X } from "../events-CsVF98U6.js";
|
|
38
|
+
import { d as Cs } from "../function-C10DGppn.js";
|
|
39
|
+
import { a as Ps, g as ws, c as ai } from "../layout-DpZo-I0y.js";
|
|
40
|
+
import { c as qs, s as di } from "../math-BOBiC4TN.js";
|
|
41
|
+
import { p as fi, l as pi } from "../number-CumqY64S.js";
|
|
42
|
+
import { c as Gs } from "../stylesheet-DpnWNVyD.js";
|
|
43
43
|
import "../ticker/index.js";
|
|
44
|
-
import { TICK_ORDER as
|
|
45
|
-
import { D as
|
|
46
|
-
import { T as
|
|
47
|
-
import { W as
|
|
48
|
-
import { windowResizer as
|
|
49
|
-
import { scrollEntries as
|
|
50
|
-
import { cssUnitParser as
|
|
51
|
-
import { CSSProperty as
|
|
52
|
-
import { d as
|
|
44
|
+
import { TICK_ORDER as Us, RESIZE_ORDER as Es } from "../order/index.js";
|
|
45
|
+
import { D as Ks } from "../Damped-CtQmJ52v.js";
|
|
46
|
+
import { T as bi } from "../Tweened-BlZB0vl4.js";
|
|
47
|
+
import { W as mi, K as Si, D as gi, A as vi } from "../DragControls-CkhCt-4W.js";
|
|
48
|
+
import { windowResizer as he } from "../window-resizer/index.js";
|
|
49
|
+
import { scrollEntries as ne } from "../scroll-entries/index.js";
|
|
50
|
+
import { cssUnitParser as Ns } from "../css-unit-parser/index.js";
|
|
51
|
+
import { CSSProperty as l } from "../css-property/index.js";
|
|
52
|
+
import { d as yi } from "../Viewport-DA10iWAO.js";
|
|
53
53
|
import "construct-style-sheets-polyfill";
|
|
54
|
-
import { elementResizer as
|
|
55
|
-
import { s as
|
|
56
|
-
import { b as
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
s(this,
|
|
71
|
-
h(this, p, n), h(this, Nt, e), h(this, y, i), Ct.register(t(this, p)), this.setIndex(t(this, Nt));
|
|
54
|
+
import { elementResizer as is } from "../element-resizer/index.js";
|
|
55
|
+
import { s as Ci } from "../gestures-CcXV6fCp.js";
|
|
56
|
+
import { b as Pi } from "../dom-CVWzyXPH.js";
|
|
57
|
+
var p, Me, w, rs, hs, ae, dt, Dt, de, fe, ts;
|
|
58
|
+
class wi {
|
|
59
|
+
constructor(n, e, s) {
|
|
60
|
+
i(this, fe);
|
|
61
|
+
i(this, p);
|
|
62
|
+
i(this, Me);
|
|
63
|
+
i(this, w);
|
|
64
|
+
i(this, rs, 0);
|
|
65
|
+
i(this, hs, 0);
|
|
66
|
+
i(this, ae, 0);
|
|
67
|
+
i(this, dt, 0);
|
|
68
|
+
i(this, Dt, null);
|
|
69
|
+
i(this, de, 0);
|
|
70
|
+
r(this, p, n), r(this, Me, e), r(this, w, s), ne.register(t(this, p)), this.setIndex(t(this, Me));
|
|
72
71
|
}
|
|
73
72
|
get element() {
|
|
74
73
|
return t(this, p);
|
|
75
74
|
}
|
|
76
75
|
get index() {
|
|
77
|
-
return t(this,
|
|
76
|
+
return t(this, Me);
|
|
78
77
|
}
|
|
79
78
|
get size() {
|
|
80
|
-
return t(this,
|
|
79
|
+
return t(this, ae);
|
|
81
80
|
}
|
|
82
81
|
get width() {
|
|
83
|
-
return t(this,
|
|
82
|
+
return t(this, rs);
|
|
84
83
|
}
|
|
85
84
|
get height() {
|
|
86
|
-
return t(this,
|
|
85
|
+
return t(this, hs);
|
|
87
86
|
}
|
|
88
87
|
get position() {
|
|
89
|
-
return t(this,
|
|
88
|
+
return t(this, dt);
|
|
90
89
|
}
|
|
91
90
|
get transformPosition() {
|
|
92
|
-
return t(this,
|
|
91
|
+
return t(this, de);
|
|
93
92
|
}
|
|
94
93
|
destroy() {
|
|
95
|
-
|
|
94
|
+
ne.unregister(t(this, p)), this.unsetTransform();
|
|
96
95
|
}
|
|
97
96
|
unsetTransform() {
|
|
98
97
|
t(this, p).style.transform = "", this.setMark(null), this.setIndex(null), this.setCurrentIndex(null), this.setCurrentIndexArc(null), this.setCurrentIndexArcAbs(null), this.setMiddle(!1), this.setSize();
|
|
99
98
|
}
|
|
100
99
|
setSize(n) {
|
|
101
|
-
n ? (t(this, p).style.setProperty("--size", n + "px"), t(this,
|
|
100
|
+
n ? (t(this, p).style.setProperty("--size", n + "px"), t(this, w).axisCSSProperty.current === "x" ? (t(this, p).style.width = n + "px", t(this, p).style.height = "") : (t(this, p).style.height = n + "px", t(this, p).style.width = "")) : (t(this, p).style.width = "", t(this, p).style.height = "", t(this, p).style.removeProperty("--size"));
|
|
102
101
|
}
|
|
103
102
|
resize() {
|
|
104
|
-
|
|
103
|
+
r(this, rs, t(this, p).offsetWidth), r(this, hs, t(this, p).offsetHeight), r(this, ae, t(this, w).vertical ? t(this, p).offsetHeight : t(this, p).offsetWidth), r(this, dt, t(this, w).vertical ? Ps(t(this, p)) : ws(t(this, p))), r(this, dt, t(this, dt) - t(this, w).contentPosition);
|
|
105
104
|
}
|
|
106
105
|
transform() {
|
|
107
|
-
const n = t(this,
|
|
106
|
+
const n = t(this, w).shiftSectionPositionCSSProperty.current;
|
|
108
107
|
let e = n;
|
|
109
|
-
const
|
|
110
|
-
t(this,
|
|
108
|
+
const s = t(this, w).viewportSize * t(this, w).sectionDistanceScaleCSSProperty.current;
|
|
109
|
+
t(this, w).loopCSSProperty.current && t(this, dt) + t(this, ae) <= t(this, w).currentScrollValue - n / 2 && (e = (t(this, w).distance - n) * -1 - t(this, w).gap), ne.update(
|
|
111
110
|
t(this, p),
|
|
112
|
-
t(this,
|
|
111
|
+
t(this, w).axisCSSProperty.current,
|
|
113
112
|
e
|
|
114
113
|
);
|
|
115
|
-
const
|
|
116
|
-
|
|
114
|
+
const h = t(this, w).currentScrollValue + e, u = t(this, dt) - t(this, w).viewportSize - s, g = t(this, dt) + t(this, ae) + s, v = fi(qs(h, u, g), 3);
|
|
115
|
+
r(this, de, v * -1), t(this, w).vertical ? t(this, p).style.transform = `translate3d(0px, ${t(this, de)}px, 0px)` : t(this, p).style.transform = `translate3d(${t(this, de)}px, 0px, 0px)`;
|
|
117
116
|
}
|
|
118
117
|
setMark(n) {
|
|
119
|
-
t(this,
|
|
118
|
+
t(this, Dt) !== n && (t(this, Dt) && t(this, p).classList.remove(t(this, Dt)), n && t(this, p).classList.add(n), r(this, Dt, n), X(t(this, p), "scrollSectionMarkChange", {
|
|
120
119
|
composed: !0,
|
|
121
120
|
detail: {
|
|
122
|
-
mark: t(this,
|
|
121
|
+
mark: t(this, Dt)
|
|
123
122
|
},
|
|
124
123
|
custom: !0
|
|
125
124
|
}));
|
|
@@ -128,22 +127,22 @@ class ys {
|
|
|
128
127
|
t(this, p).classList.toggle("middle", n);
|
|
129
128
|
}
|
|
130
129
|
setIndex(n) {
|
|
131
|
-
|
|
130
|
+
o(this, fe, ts).call(this, "index", n);
|
|
132
131
|
}
|
|
133
132
|
setCurrentIndex(n) {
|
|
134
|
-
|
|
133
|
+
o(this, fe, ts).call(this, "current-index", n);
|
|
135
134
|
}
|
|
136
135
|
setCurrentIndexArc(n) {
|
|
137
|
-
|
|
136
|
+
o(this, fe, ts).call(this, "current-index-arc", n);
|
|
138
137
|
}
|
|
139
138
|
setCurrentIndexArcAbs(n) {
|
|
140
|
-
|
|
139
|
+
o(this, fe, ts).call(this, "current-index-arc-abs", n);
|
|
141
140
|
}
|
|
142
141
|
}
|
|
143
|
-
p = new WeakMap(),
|
|
142
|
+
p = new WeakMap(), Me = new WeakMap(), w = new WeakMap(), rs = new WeakMap(), hs = new WeakMap(), ae = new WeakMap(), dt = new WeakMap(), Dt = new WeakMap(), de = new WeakMap(), fe = new WeakSet(), ts = function(n, e) {
|
|
144
143
|
e !== null ? (t(this, p).style.setProperty(`--${n}`, e.toString()), t(this, p).setAttribute(`data-${n}`, e.toString())) : (t(this, p).style.removeProperty(`--${n}`), t(this, p).removeAttribute(`data-${n}`));
|
|
145
144
|
};
|
|
146
|
-
const
|
|
145
|
+
const Ei = Gs({
|
|
147
146
|
":host": {
|
|
148
147
|
position: "relative",
|
|
149
148
|
width: "100%",
|
|
@@ -182,356 +181,356 @@ const Cs = je({
|
|
|
182
181
|
flexShrink: "0"
|
|
183
182
|
}
|
|
184
183
|
});
|
|
185
|
-
var
|
|
186
|
-
class
|
|
184
|
+
var f, pe, T, Ot, ft, pt, bt, tt, $t, Ht, mt, Wt, be, et, V, me, Se, ge, ve, Fe, ye, Z, Ce, Bt, _, Nt, St, Pe, qt, we, Gt, Ut, Kt, b, Te, q, a, ns, os, L, P, G, st, Zt, it, M, R, Re, gt, vt, yt, Ct, De, _t, Pt, Ee, rt, k, Oe, wt, xe, $e, c, zs, es, Ie, vs, ys, Vs, ks, D, ls, Zs, He, cs, As, Is, ce, _s, us, ss, as;
|
|
185
|
+
class Ls extends HTMLElement {
|
|
187
186
|
constructor() {
|
|
188
187
|
super();
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
188
|
+
i(this, c);
|
|
189
|
+
i(this, f, null);
|
|
190
|
+
i(this, pe, new l(this, "--controls", !0));
|
|
191
|
+
i(this, T, new l(this, "--axis", "y"));
|
|
192
|
+
i(this, Ot, new l(this, "--reverse", !1));
|
|
193
|
+
i(this, ft, new l(this, "--direction", 0));
|
|
194
|
+
i(this, pt, new l(this, "--pages", 0, {
|
|
196
195
|
validate: (e) => Math.max(0, e - 1)
|
|
197
196
|
}));
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
197
|
+
i(this, bt, new l(this, "--split", !1));
|
|
198
|
+
i(this, tt, new l(this, "--sectional", !1));
|
|
199
|
+
i(this, $t, new l(
|
|
201
200
|
this,
|
|
202
201
|
"--tween-easing",
|
|
203
202
|
!1
|
|
204
203
|
));
|
|
205
|
-
|
|
204
|
+
i(this, Ht, new l(
|
|
206
205
|
this,
|
|
207
206
|
"--tween-duration",
|
|
208
207
|
!1
|
|
209
208
|
));
|
|
210
|
-
|
|
211
|
-
|
|
209
|
+
i(this, mt, new l(this, "--auto-size", !1));
|
|
210
|
+
i(this, Wt, new l(
|
|
212
211
|
this,
|
|
213
212
|
"--wheel-max-delta",
|
|
214
213
|
!1
|
|
215
214
|
));
|
|
216
|
-
|
|
217
|
-
|
|
215
|
+
i(this, be, new l(this, "--drag-inertion", 1));
|
|
216
|
+
i(this, et, new l(
|
|
218
217
|
this,
|
|
219
218
|
"--sections-in-view",
|
|
220
219
|
1
|
|
221
220
|
));
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
221
|
+
i(this, V, new l(this, "--loop", !1));
|
|
222
|
+
i(this, me, new l(this, "--damping", 20));
|
|
223
|
+
i(this, Se, new l(this, "--mass", 0));
|
|
224
|
+
i(this, ge, new l(this, "--stiffness", 0));
|
|
225
|
+
i(this, ve, new l(this, "--mouse-drag", !1));
|
|
226
|
+
i(this, Fe, new l(
|
|
228
227
|
this,
|
|
229
228
|
"--section-distance-scale",
|
|
230
229
|
0.5
|
|
231
230
|
));
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
231
|
+
i(this, ye, new l(this, "--start-section", 0));
|
|
232
|
+
i(this, Z, new l(this, "--autoplay", 0));
|
|
233
|
+
i(this, Ce, new l(
|
|
235
234
|
this,
|
|
236
235
|
"--autoplay-pause-duration",
|
|
237
236
|
0
|
|
238
237
|
));
|
|
239
|
-
|
|
238
|
+
i(this, Bt, new l(
|
|
240
239
|
this,
|
|
241
240
|
"--autoplay-user-direction",
|
|
242
241
|
!1
|
|
243
242
|
));
|
|
244
|
-
|
|
245
|
-
|
|
243
|
+
i(this, _, new l(this, "--classes", !1));
|
|
244
|
+
i(this, Nt, new l(
|
|
246
245
|
this,
|
|
247
246
|
"--current-index-start-offset",
|
|
248
247
|
0
|
|
249
248
|
));
|
|
250
|
-
|
|
249
|
+
i(this, St, new l(
|
|
251
250
|
this,
|
|
252
251
|
"--current-index-end-offset",
|
|
253
252
|
0
|
|
254
253
|
));
|
|
255
|
-
|
|
254
|
+
i(this, Pe, new l(
|
|
256
255
|
this,
|
|
257
256
|
"--shift-section-position",
|
|
258
257
|
0,
|
|
259
258
|
{ rawValueCheck: !1 }
|
|
260
259
|
));
|
|
261
|
-
|
|
262
|
-
|
|
260
|
+
i(this, qt, new l(this, "--focus-delay", 0));
|
|
261
|
+
i(this, we, new l(
|
|
263
262
|
this,
|
|
264
263
|
"--focus-duration",
|
|
265
264
|
3e3
|
|
266
265
|
));
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
if (e && t(this,
|
|
301
|
-
|
|
266
|
+
i(this, Gt, new l(this, "--disabled", !1));
|
|
267
|
+
i(this, Ut, new l(this, "--hibernate", !1));
|
|
268
|
+
i(this, Kt, null);
|
|
269
|
+
i(this, b, null);
|
|
270
|
+
i(this, Te, null);
|
|
271
|
+
i(this, q, []);
|
|
272
|
+
i(this, a, []);
|
|
273
|
+
i(this, ns, 0);
|
|
274
|
+
i(this, os, 0);
|
|
275
|
+
i(this, L, 0);
|
|
276
|
+
i(this, P, 0);
|
|
277
|
+
i(this, G, 0);
|
|
278
|
+
i(this, st, null);
|
|
279
|
+
i(this, Zt, null);
|
|
280
|
+
i(this, it, null);
|
|
281
|
+
i(this, M, null);
|
|
282
|
+
i(this, R, new le(0));
|
|
283
|
+
i(this, Re, 0);
|
|
284
|
+
i(this, gt, 0);
|
|
285
|
+
i(this, vt, !1);
|
|
286
|
+
i(this, yt, !0);
|
|
287
|
+
i(this, Ct, !0);
|
|
288
|
+
i(this, De);
|
|
289
|
+
i(this, _t);
|
|
290
|
+
i(this, Pt, new bi());
|
|
291
|
+
i(this, Ee, !1);
|
|
292
|
+
i(this, rt, null);
|
|
293
|
+
i(this, k, !1);
|
|
294
|
+
i(this, Oe, null);
|
|
295
|
+
i(this, wt, []);
|
|
296
|
+
i(this, xe, !1);
|
|
297
|
+
i(this, $e);
|
|
298
|
+
i(this, D, (e) => {
|
|
299
|
+
if (e && t(this, xe)) {
|
|
300
|
+
r(this, xe, !1);
|
|
302
301
|
return;
|
|
303
302
|
}
|
|
304
303
|
this.resize();
|
|
305
304
|
});
|
|
306
|
-
|
|
307
|
-
if (!t(this,
|
|
305
|
+
i(this, ls, () => {
|
|
306
|
+
if (!t(this, vt) || t(this, Ct) || t(this, yt))
|
|
308
307
|
return;
|
|
309
308
|
const e = this.currentScrollValue;
|
|
310
|
-
if (
|
|
311
|
-
for (let
|
|
312
|
-
t(this,
|
|
313
|
-
t(this,
|
|
309
|
+
if (r(this, Re, Math.max(0, e - t(this, P))), t(this, a).length) {
|
|
310
|
+
for (let s = 0; s < t(this, q).length; s++)
|
|
311
|
+
t(this, q)[s].transform();
|
|
312
|
+
t(this, R).current = o(this, c, ss).call(this);
|
|
314
313
|
} else
|
|
315
|
-
this.vertical ? t(this,
|
|
316
|
-
|
|
314
|
+
this.vertical ? t(this, b).style.transform = `translate3d(0px, ${e * -1}px, 0px)` : t(this, b).style.transform = `translate3d(${e * -1}px, 0px, 0px)`;
|
|
315
|
+
o(this, c, _s).call(this), ne.update(
|
|
317
316
|
this,
|
|
318
|
-
t(this,
|
|
317
|
+
t(this, T).current,
|
|
319
318
|
e
|
|
320
319
|
);
|
|
321
320
|
});
|
|
322
|
-
|
|
323
|
-
t(this,
|
|
321
|
+
i(this, He, (e, s) => {
|
|
322
|
+
t(this, pe).current && (o(this, c, As).call(this, Math.sign(s) || 1), t(this, cs).call(this, e, s));
|
|
324
323
|
});
|
|
325
|
-
|
|
326
|
-
if (t(this,
|
|
327
|
-
if (t(this,
|
|
324
|
+
i(this, cs, (e, s) => {
|
|
325
|
+
if (t(this, ft).current) {
|
|
326
|
+
if (t(this, ft).current < 0 && s > 0)
|
|
328
327
|
return;
|
|
329
|
-
if (t(this,
|
|
328
|
+
if (t(this, ft).current > 0 && s < 0)
|
|
330
329
|
return;
|
|
331
330
|
}
|
|
332
|
-
if (t(this,
|
|
333
|
-
const
|
|
334
|
-
|
|
331
|
+
if (t(this, _t) || t(this, Pt).unlistenAnimationFrame(), !t(this, Z).current && t(this, qt).current && (clearInterval(t(this, De)), r(this, De, setTimeout(() => {
|
|
332
|
+
const h = t(this, a)[o(this, c, ss).call(this)];
|
|
333
|
+
h && this.scrollToSection(h.index, {
|
|
335
334
|
tween: {
|
|
336
|
-
duration: t(this,
|
|
337
|
-
easing:
|
|
335
|
+
duration: t(this, we).current,
|
|
336
|
+
easing: ci
|
|
338
337
|
}
|
|
339
338
|
});
|
|
340
|
-
}, t(this,
|
|
341
|
-
if (t(this,
|
|
342
|
-
const
|
|
339
|
+
}, t(this, qt).current))), !(e.includes("drag") && !yi.isTouch && !t(this, ve).current)) {
|
|
340
|
+
if (t(this, tt).current && e !== "drag") {
|
|
341
|
+
const h = Math.sign(s);
|
|
343
342
|
if (t(this, a).length) {
|
|
344
|
-
const
|
|
345
|
-
tween: t(this,
|
|
346
|
-
easing: t(this,
|
|
347
|
-
duration: t(this,
|
|
343
|
+
const u = {
|
|
344
|
+
tween: t(this, $t).current || t(this, Ht).current ? {
|
|
345
|
+
easing: t(this, $t).current || "easeInOutCubic",
|
|
346
|
+
duration: t(this, Ht).current || 500
|
|
348
347
|
} : void 0
|
|
349
348
|
};
|
|
350
|
-
t(this,
|
|
349
|
+
t(this, Ee) ? this.scrollToSection(o(this, c, ss).call(this, !0), u) : this.shiftSections(h, u);
|
|
351
350
|
} else
|
|
352
|
-
t(this,
|
|
351
|
+
t(this, f).shift(h * t(this, L));
|
|
353
352
|
} else
|
|
354
|
-
t(this,
|
|
355
|
-
|
|
353
|
+
t(this, f).shift(s);
|
|
354
|
+
r(this, Ee, e === "drag");
|
|
356
355
|
}
|
|
357
356
|
});
|
|
358
|
-
|
|
359
|
-
const e = t(this,
|
|
360
|
-
const
|
|
361
|
-
return
|
|
357
|
+
i(this, us, Cs(() => {
|
|
358
|
+
const e = t(this, wt).reduce((s, h) => {
|
|
359
|
+
const u = this.vertical ? h.width : h.height;
|
|
360
|
+
return u > s ? u : s;
|
|
362
361
|
}, 0);
|
|
363
|
-
clearTimeout(t(this,
|
|
364
|
-
|
|
362
|
+
clearTimeout(t(this, $e)), r(this, xe, !0), this.style.setProperty("--max-section-size", ""), r(this, $e, setTimeout(() => {
|
|
363
|
+
r(this, xe, !0), this.style.setProperty("--max-section-size", e + "px");
|
|
365
364
|
}, 10));
|
|
366
365
|
}, 20));
|
|
367
|
-
|
|
368
|
-
|
|
366
|
+
i(this, as, () => {
|
|
367
|
+
r(this, k, !0), this.hibernatedCSSProperty.current || o(this, c, ks).call(this);
|
|
369
368
|
});
|
|
370
|
-
if (
|
|
369
|
+
if (Y) {
|
|
371
370
|
const e = this.attachShadow({ mode: "open" });
|
|
372
|
-
e.adoptedStyleSheets = [
|
|
373
|
-
const
|
|
374
|
-
|
|
375
|
-
|
|
371
|
+
e.adoptedStyleSheets = [Ei];
|
|
372
|
+
const s = document.createElement("div");
|
|
373
|
+
s.className = "static", s.innerHTML = '<slot name="static"></slot>', e.appendChild(s), r(this, Kt, document.createElement("div")), t(this, Kt).className = "content-wrapper", r(this, b, document.createElement("div")), t(this, b).className = "content", r(this, Te, document.createElement("slot")), t(this, b).appendChild(t(this, Te)), t(this, Kt).appendChild(t(this, b)), e.appendChild(t(this, Kt)), r(this, Oe, new MutationObserver(
|
|
374
|
+
Cs(() => {
|
|
376
375
|
this.tryResplit();
|
|
377
376
|
}, 10)
|
|
378
377
|
));
|
|
379
378
|
}
|
|
380
379
|
}
|
|
381
380
|
get damped() {
|
|
382
|
-
return t(this,
|
|
381
|
+
return t(this, f);
|
|
383
382
|
}
|
|
384
383
|
get controlsCSSProperty() {
|
|
385
|
-
return t(this,
|
|
384
|
+
return t(this, pe);
|
|
386
385
|
}
|
|
387
386
|
get axisCSSProperty() {
|
|
388
|
-
return t(this,
|
|
387
|
+
return t(this, T);
|
|
389
388
|
}
|
|
390
389
|
get reverseCSSProperty() {
|
|
391
|
-
return t(this,
|
|
390
|
+
return t(this, Ot);
|
|
392
391
|
}
|
|
393
392
|
get directionCSSProperty() {
|
|
394
|
-
return t(this,
|
|
393
|
+
return t(this, ft);
|
|
395
394
|
}
|
|
396
395
|
get pagesCSSProperty() {
|
|
397
|
-
return t(this,
|
|
396
|
+
return t(this, pt);
|
|
398
397
|
}
|
|
399
398
|
get splitCSSProperty() {
|
|
400
|
-
return t(this,
|
|
399
|
+
return t(this, bt);
|
|
401
400
|
}
|
|
402
401
|
get sectionalCSSProperty() {
|
|
403
|
-
return t(this,
|
|
402
|
+
return t(this, tt);
|
|
404
403
|
}
|
|
405
404
|
get easingCSSProperty() {
|
|
406
|
-
return t(this,
|
|
405
|
+
return t(this, $t);
|
|
407
406
|
}
|
|
408
407
|
get durationCSSProperty() {
|
|
409
|
-
return t(this,
|
|
408
|
+
return t(this, Ht);
|
|
410
409
|
}
|
|
411
410
|
get autoSizeCSSProperty() {
|
|
412
|
-
return t(this,
|
|
411
|
+
return t(this, mt);
|
|
413
412
|
}
|
|
414
413
|
get wheelMaxDeltaCSSProperty() {
|
|
415
|
-
return t(this,
|
|
414
|
+
return t(this, Wt);
|
|
416
415
|
}
|
|
417
416
|
get dragInertionCSSProperty() {
|
|
418
|
-
return t(this,
|
|
417
|
+
return t(this, be);
|
|
419
418
|
}
|
|
420
419
|
get sectionsInViewCSSProperty() {
|
|
421
|
-
return t(this,
|
|
420
|
+
return t(this, et);
|
|
422
421
|
}
|
|
423
422
|
get loopCSSProperty() {
|
|
424
|
-
return t(this,
|
|
423
|
+
return t(this, V);
|
|
425
424
|
}
|
|
426
425
|
get dampingCSSProperty() {
|
|
427
|
-
return t(this,
|
|
426
|
+
return t(this, me);
|
|
428
427
|
}
|
|
429
428
|
get massCSSProperty() {
|
|
430
|
-
return t(this,
|
|
429
|
+
return t(this, Se);
|
|
431
430
|
}
|
|
432
431
|
get stiffnessCSSProperty() {
|
|
433
|
-
return t(this,
|
|
432
|
+
return t(this, ge);
|
|
434
433
|
}
|
|
435
434
|
get mouseDragCSSProperty() {
|
|
436
|
-
return t(this,
|
|
435
|
+
return t(this, ve);
|
|
437
436
|
}
|
|
438
437
|
get sectionDistanceScaleCSSProperty() {
|
|
439
|
-
return t(this,
|
|
438
|
+
return t(this, Fe);
|
|
440
439
|
}
|
|
441
440
|
get startSectionCSSProperty() {
|
|
442
|
-
return t(this,
|
|
441
|
+
return t(this, ye);
|
|
443
442
|
}
|
|
444
443
|
get autoplayCSSProperty() {
|
|
445
|
-
return t(this,
|
|
444
|
+
return t(this, Z);
|
|
446
445
|
}
|
|
447
446
|
get autoplayPauseDurationCSSProperty() {
|
|
448
|
-
return t(this,
|
|
447
|
+
return t(this, Ce);
|
|
449
448
|
}
|
|
450
449
|
get autoplayUserDirectionCSSProperty() {
|
|
451
|
-
return t(this,
|
|
450
|
+
return t(this, Bt);
|
|
452
451
|
}
|
|
453
452
|
get classesCSSProperty() {
|
|
454
|
-
return t(this,
|
|
453
|
+
return t(this, _);
|
|
455
454
|
}
|
|
456
455
|
get currentIndexStartOffsetCSSProperty() {
|
|
457
|
-
return t(this,
|
|
456
|
+
return t(this, Nt);
|
|
458
457
|
}
|
|
459
458
|
get currentIndexEndOffsetCSSProperty() {
|
|
460
|
-
return t(this,
|
|
459
|
+
return t(this, St);
|
|
461
460
|
}
|
|
462
461
|
get shiftSectionPositionCSSProperty() {
|
|
463
|
-
return t(this,
|
|
462
|
+
return t(this, Pe);
|
|
464
463
|
}
|
|
465
464
|
get focusDelayCSSProperty() {
|
|
466
|
-
return t(this,
|
|
465
|
+
return t(this, qt);
|
|
467
466
|
}
|
|
468
467
|
get focusDurationCSSProperty() {
|
|
469
|
-
return t(this,
|
|
468
|
+
return t(this, we);
|
|
470
469
|
}
|
|
471
470
|
get disabledCSSProperty() {
|
|
472
|
-
return t(this,
|
|
471
|
+
return t(this, Gt);
|
|
473
472
|
}
|
|
474
473
|
get hibernatedCSSProperty() {
|
|
475
|
-
return t(this,
|
|
474
|
+
return t(this, Ut);
|
|
476
475
|
}
|
|
477
476
|
get currentScrollValue() {
|
|
478
|
-
return
|
|
477
|
+
return o(this, c, Is).call(this, "current");
|
|
479
478
|
}
|
|
480
479
|
get targetScrollValue() {
|
|
481
|
-
return
|
|
480
|
+
return o(this, c, Is).call(this, "target");
|
|
482
481
|
}
|
|
483
482
|
get contentWrapperElement() {
|
|
484
|
-
return t(this,
|
|
483
|
+
return t(this, Kt);
|
|
485
484
|
}
|
|
486
485
|
get contentElement() {
|
|
487
|
-
return t(this,
|
|
486
|
+
return t(this, b);
|
|
488
487
|
}
|
|
489
488
|
get sections() {
|
|
490
|
-
return t(this,
|
|
489
|
+
return t(this, q);
|
|
491
490
|
}
|
|
492
491
|
get visibleSections() {
|
|
493
492
|
return t(this, a);
|
|
494
493
|
}
|
|
495
494
|
get position() {
|
|
496
|
-
return t(this,
|
|
495
|
+
return t(this, ns);
|
|
497
496
|
}
|
|
498
497
|
get contentPosition() {
|
|
499
|
-
return t(this,
|
|
498
|
+
return t(this, os);
|
|
500
499
|
}
|
|
501
500
|
get viewportSize() {
|
|
502
|
-
return t(this,
|
|
501
|
+
return t(this, L);
|
|
503
502
|
}
|
|
504
503
|
get scrollSize() {
|
|
505
|
-
return t(this,
|
|
504
|
+
return t(this, P);
|
|
506
505
|
}
|
|
507
506
|
get gap() {
|
|
508
|
-
return t(this,
|
|
507
|
+
return t(this, G);
|
|
509
508
|
}
|
|
510
509
|
get counter() {
|
|
511
|
-
return t(this,
|
|
510
|
+
return t(this, R);
|
|
512
511
|
}
|
|
513
512
|
get limit() {
|
|
514
513
|
return Math.ceil(
|
|
515
|
-
t(this, a).length - t(this,
|
|
514
|
+
t(this, a).length - t(this, et).current
|
|
516
515
|
);
|
|
517
516
|
}
|
|
518
517
|
get distance() {
|
|
519
|
-
return t(this,
|
|
518
|
+
return t(this, gt);
|
|
520
519
|
}
|
|
521
520
|
get loopDistance() {
|
|
522
|
-
return t(this,
|
|
521
|
+
return t(this, V).current ? t(this, gt) + t(this, G) : t(this, gt);
|
|
523
522
|
}
|
|
524
523
|
get hasOverflow() {
|
|
525
|
-
return t(this,
|
|
524
|
+
return t(this, vt);
|
|
526
525
|
}
|
|
527
526
|
get overscroll() {
|
|
528
|
-
return t(this,
|
|
527
|
+
return t(this, Re);
|
|
529
528
|
}
|
|
530
529
|
get scrollLine() {
|
|
531
|
-
return t(this,
|
|
530
|
+
return t(this, rt);
|
|
532
531
|
}
|
|
533
532
|
get vertical() {
|
|
534
|
-
return t(this,
|
|
533
|
+
return t(this, T).current === "y";
|
|
535
534
|
}
|
|
536
535
|
get currentProgress() {
|
|
537
536
|
return this.currentScrollValue / this.loopDistance || 0;
|
|
@@ -540,306 +539,306 @@ class Ft extends HTMLElement {
|
|
|
540
539
|
return this.targetScrollValue / this.loopDistance || 0;
|
|
541
540
|
}
|
|
542
541
|
get scrollWidth() {
|
|
543
|
-
return t(this,
|
|
542
|
+
return t(this, T).current === "y" ? 0 : t(this, f).distance;
|
|
544
543
|
}
|
|
545
544
|
get scrollHeight() {
|
|
546
|
-
return t(this,
|
|
545
|
+
return t(this, T).current === "x" ? 0 : t(this, f).distance;
|
|
547
546
|
}
|
|
548
547
|
tryResplit() {
|
|
549
|
-
!t(this,
|
|
548
|
+
!t(this, Ct) && (t(this, V).current || t(this, bt).current || t(this, V).current || t(this, mt).current || t(this, tt).current) && o(this, c, es).call(this);
|
|
550
549
|
}
|
|
551
550
|
onScroll(...e) {
|
|
552
|
-
return t(this,
|
|
551
|
+
return t(this, f).subscribe(...e);
|
|
553
552
|
}
|
|
554
553
|
offScroll(...e) {
|
|
555
|
-
t(this,
|
|
554
|
+
t(this, f).unsubscribe(...e);
|
|
556
555
|
}
|
|
557
556
|
//https://github.com/pmndrs/drei/blob/d3282cdd02d170ef603a5e096505d83dc93cd57a/src/web/ScrollControls.tsx#L85C7-L100C9
|
|
558
|
-
range(e,
|
|
559
|
-
const
|
|
560
|
-
return this.currentProgress <
|
|
557
|
+
range(e, s, h = 0) {
|
|
558
|
+
const u = e - h, g = u + s + h * 2;
|
|
559
|
+
return this.currentProgress < u ? 0 : this.currentProgress > g ? 1 : (this.currentProgress - u) / (g - u);
|
|
561
560
|
}
|
|
562
|
-
curve(e,
|
|
563
|
-
return Math.sin(this.range(e,
|
|
561
|
+
curve(e, s, h = 0) {
|
|
562
|
+
return Math.sin(this.range(e, s, h) * Math.PI);
|
|
564
563
|
}
|
|
565
|
-
visible(e,
|
|
566
|
-
const
|
|
567
|
-
return this.currentProgress >=
|
|
564
|
+
visible(e, s, h = 0) {
|
|
565
|
+
const u = e - h, g = u + s + h * 2;
|
|
566
|
+
return this.currentProgress >= u && this.currentProgress <= g;
|
|
568
567
|
}
|
|
569
|
-
scrollToSection(e,
|
|
568
|
+
scrollToSection(e, s) {
|
|
570
569
|
if (!t(this, a).length)
|
|
571
570
|
return;
|
|
572
|
-
const
|
|
573
|
-
if (
|
|
574
|
-
let
|
|
575
|
-
const
|
|
576
|
-
let
|
|
577
|
-
t(this,
|
|
571
|
+
const h = t(this, R).current, u = o(this, c, Zs).call(this, e), g = t(this, a)[h], v = t(this, a)[u];
|
|
572
|
+
if (g && v) {
|
|
573
|
+
let C = 0;
|
|
574
|
+
const oe = o(this, c, ss).call(this), Ae = t(this, a)[oe];
|
|
575
|
+
let Ye = Ae ? this.targetScrollValue - Ae.position : 0;
|
|
576
|
+
t(this, V).current ? u === 0 && h === t(this, a).length - 1 ? (C = t(this, P) + t(this, L) - g.position + t(this, G), t(this, Ee) || (Ye = 0)) : u === t(this, a).length - 1 && h === 0 ? C = v.position - (t(this, P) + t(this, L) + t(this, G)) : C = v.position - g.position : C = v.position - g.position, this.shiftPosition(C - Ye, s);
|
|
578
577
|
}
|
|
579
578
|
}
|
|
580
|
-
shiftSections(e,
|
|
581
|
-
t(this, a).length && this.scrollToSection(t(this,
|
|
579
|
+
shiftSections(e, s) {
|
|
580
|
+
t(this, a).length && this.scrollToSection(t(this, R).current + e, s);
|
|
582
581
|
}
|
|
583
|
-
setPosition(e,
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
},
|
|
587
|
-
equalize: (
|
|
582
|
+
setPosition(e, s) {
|
|
583
|
+
o(this, c, As).call(this, Math.sign(e) || 1), s != null && s.tween ? t(this, _t) || (t(this, Pt).set(t(this, f).current, { equalize: !0 }), t(this, Pt).set(e, Hs({}, s.tween)), r(this, _t, setTimeout(() => {
|
|
584
|
+
r(this, _t, void 0);
|
|
585
|
+
}, s.tween.duration || 0))) : t(this, f).set(e, {
|
|
586
|
+
equalize: (s == null ? void 0 : s.behaviour) === "instant"
|
|
588
587
|
});
|
|
589
588
|
}
|
|
590
|
-
shiftPosition(e,
|
|
591
|
-
this.setPosition(t(this,
|
|
589
|
+
shiftPosition(e, s) {
|
|
590
|
+
this.setPosition(t(this, f).target + e, s);
|
|
592
591
|
}
|
|
593
592
|
resize() {
|
|
594
|
-
if (t(this,
|
|
593
|
+
if (t(this, Ut).current)
|
|
595
594
|
return;
|
|
596
|
-
|
|
597
|
-
(
|
|
595
|
+
r(this, a, t(this, q).filter(
|
|
596
|
+
(h) => ui(h.element)
|
|
598
597
|
)), this.style.setProperty(
|
|
599
598
|
"--sections",
|
|
600
599
|
t(this, a).length.toString()
|
|
601
|
-
), t(this,
|
|
602
|
-
const e = this.currentScrollValue / t(this,
|
|
603
|
-
if (
|
|
604
|
-
getComputedStyle(t(this,
|
|
605
|
-
)) :
|
|
606
|
-
getComputedStyle(t(this,
|
|
607
|
-
)), t(this,
|
|
608
|
-
const
|
|
609
|
-
t(this, a).forEach((
|
|
610
|
-
|
|
600
|
+
), t(this, f).unlistenAnimationFrame();
|
|
601
|
+
const e = this.currentScrollValue / t(this, P) || 0, s = t(this, R).current;
|
|
602
|
+
if (r(this, ns, this.vertical ? Ps(this) : ws(this)), r(this, os, this.vertical ? Ps(t(this, b)) : ws(t(this, b))), r(this, L, this.vertical ? this.offsetHeight : this.offsetWidth), this.vertical ? r(this, G, Ns.parse(
|
|
603
|
+
getComputedStyle(t(this, b)).rowGap
|
|
604
|
+
)) : r(this, G, Ns.parse(
|
|
605
|
+
getComputedStyle(t(this, b)).columnGap
|
|
606
|
+
)), t(this, mt).current && t(this, a).length) {
|
|
607
|
+
const h = t(this, et).current, u = (t(this, L) - t(this, G) * (h - 1)) / h;
|
|
608
|
+
t(this, a).forEach((g) => {
|
|
609
|
+
g.setSize(u);
|
|
611
610
|
});
|
|
612
611
|
} else
|
|
613
|
-
t(this, a).forEach((
|
|
614
|
-
|
|
612
|
+
t(this, a).forEach((h) => {
|
|
613
|
+
h.setSize();
|
|
615
614
|
});
|
|
616
|
-
if (t(this, a).forEach((
|
|
617
|
-
|
|
618
|
-
}), t(this,
|
|
619
|
-
|
|
620
|
-
const
|
|
621
|
-
this.vertical ? (t(this,
|
|
615
|
+
if (t(this, a).forEach((h) => {
|
|
616
|
+
h.resize();
|
|
617
|
+
}), t(this, pt).current) {
|
|
618
|
+
r(this, P, t(this, L) * t(this, pt).current);
|
|
619
|
+
const h = t(this, P) + t(this, L);
|
|
620
|
+
this.vertical ? (t(this, b).style.width = h + "px", t(this, b).style.height = "100%") : (t(this, b).style.height = h + "px", t(this, b).style.width = "100%");
|
|
622
621
|
} else
|
|
623
|
-
this.vertical ? (t(this,
|
|
624
|
-
if (!t(this,
|
|
625
|
-
const
|
|
626
|
-
|
|
622
|
+
this.vertical ? (t(this, b).style.width = "100%", t(this, b).style.height = "max-content", r(this, P, t(this, b).offsetHeight - t(this, L))) : (t(this, b).style.width = "max-content", t(this, b).style.height = "100%", r(this, P, t(this, b).offsetWidth - t(this, L)));
|
|
623
|
+
if (!t(this, V).current) {
|
|
624
|
+
const h = getComputedStyle(this), u = this.vertical ? parseFloat(h.paddingBlockStart) + parseFloat(h.paddingBlockEnd) : parseFloat(h.paddingInlineStart) + parseFloat(h.paddingInlineEnd);
|
|
625
|
+
r(this, P, t(this, P) + u), t(this, f).max = t(this, P);
|
|
627
626
|
}
|
|
628
|
-
if (t(this,
|
|
629
|
-
const
|
|
630
|
-
|
|
627
|
+
if (t(this, V).current && t(this, a).length) {
|
|
628
|
+
const h = t(this, a)[t(this, a).length - 1], u = h.position + h.size - t(this, L), g = t(this, P) - u;
|
|
629
|
+
r(this, gt, h.position + h.size + g);
|
|
631
630
|
} else
|
|
632
|
-
|
|
633
|
-
if (t(this,
|
|
634
|
-
const
|
|
635
|
-
t(this,
|
|
631
|
+
r(this, gt, t(this, P));
|
|
632
|
+
if (t(this, tt).current && t(this, a).length) {
|
|
633
|
+
const h = t(this, a)[s];
|
|
634
|
+
t(this, f).set(h.position, {
|
|
636
635
|
equalize: !0
|
|
637
636
|
});
|
|
638
637
|
} else
|
|
639
|
-
t(this,
|
|
638
|
+
t(this, f).set(e * t(this, P), {
|
|
640
639
|
equalize: !0
|
|
641
640
|
});
|
|
642
|
-
|
|
641
|
+
r(this, vt, (this.vertical ? t(this, b).offsetHeight : t(this, b).offsetWidth) > t(this, L)), this.classList.toggle("has-overflow", t(this, vt)), t(this, vt) ? t(this, Gt).current || o(this, c, ys).call(this) : o(this, c, vs).call(this), t(this, us).call(this), X(this, "scrollResize", { custom: !0 }), t(this, f).notify();
|
|
643
642
|
}
|
|
644
643
|
connectedCallback() {
|
|
645
|
-
|
|
644
|
+
ne.register(this), r(this, f, new Ks(0, {
|
|
646
645
|
damping: 0.01,
|
|
647
646
|
min: 0,
|
|
648
|
-
order:
|
|
649
|
-
})), this.setAttribute("tabindex", "0"),
|
|
647
|
+
order: Us.SCROLL
|
|
648
|
+
})), this.setAttribute("tabindex", "0"), r(this, st, new mi({ element: t(this, b) })), t(this, st).changeEvent.subscribe(t(this, He)), r(this, Zt, new Si({
|
|
650
649
|
element: this
|
|
651
|
-
})), t(this,
|
|
652
|
-
t(this,
|
|
653
|
-
),
|
|
654
|
-
element: t(this,
|
|
650
|
+
})), t(this, Zt).changeEvent.subscribe(
|
|
651
|
+
t(this, He)
|
|
652
|
+
), r(this, it, new gi({
|
|
653
|
+
element: t(this, b),
|
|
655
654
|
rootElement: this
|
|
656
|
-
})), t(this,
|
|
655
|
+
})), t(this, it).changeEvent.subscribe(t(this, He)), r(this, M, new vi({
|
|
657
656
|
culling: this
|
|
658
|
-
})), t(this,
|
|
659
|
-
|
|
660
|
-
}), t(this,
|
|
661
|
-
|
|
662
|
-
}), t(this,
|
|
663
|
-
t(this,
|
|
664
|
-
}), t(this,
|
|
665
|
-
t(this,
|
|
666
|
-
}), t(this,
|
|
667
|
-
t(this,
|
|
668
|
-
}), t(this,
|
|
669
|
-
t(this,
|
|
670
|
-
}), t(this,
|
|
671
|
-
t(this,
|
|
672
|
-
}), t(this,
|
|
673
|
-
t(this,
|
|
657
|
+
})), t(this, M).changeEvent.subscribe(t(this, cs)), t(this, T).subscribe(() => {
|
|
658
|
+
o(this, c, zs).call(this);
|
|
659
|
+
}), t(this, Ot).subscribe(() => {
|
|
660
|
+
o(this, c, zs).call(this);
|
|
661
|
+
}), t(this, Wt).subscribe((e) => {
|
|
662
|
+
t(this, st).axis = e.current ? "max" : t(this, T).current;
|
|
663
|
+
}), t(this, be).subscribe((e) => {
|
|
664
|
+
t(this, it).inertion = typeof e.current == "number" ? e.current : 1;
|
|
665
|
+
}), t(this, pt).subscribe(() => {
|
|
666
|
+
t(this, k) && t(this, D).call(this);
|
|
667
|
+
}), t(this, bt).subscribe(({ current: e }) => {
|
|
668
|
+
t(this, k) && (e ? o(this, c, es).call(this) : o(this, c, Ie).call(this));
|
|
669
|
+
}), t(this, tt).subscribe((e) => {
|
|
670
|
+
t(this, st).debounce = e.current, t(this, it).swipe = e.current, t(this, M).interval = e.current, t(this, k) && (e.current && !e.previous && !t(this, a).length ? o(this, c, es).call(this) : !e.current && e.previous && t(this, a).length && o(this, c, Ie).call(this));
|
|
671
|
+
}), t(this, mt).subscribe((e) => {
|
|
672
|
+
t(this, k) && (t(this, D).call(this), e.current && !e.previous && !t(this, a).length ? o(this, c, es).call(this) : !e.current && e.previous && t(this, a).length && o(this, c, Ie).call(this));
|
|
673
|
+
}), t(this, et).subscribe((e) => {
|
|
674
|
+
t(this, k) && (t(this, D).call(this), o(this, c, ce).call(this));
|
|
674
675
|
}), t(this, V).subscribe((e) => {
|
|
675
|
-
t(this,
|
|
676
|
-
}), t(this,
|
|
677
|
-
|
|
678
|
-
}), t(this,
|
|
679
|
-
t(this,
|
|
680
|
-
}), t(this,
|
|
681
|
-
t(this,
|
|
682
|
-
}), t(this,
|
|
683
|
-
t(this,
|
|
684
|
-
}), t(this,
|
|
685
|
-
|
|
686
|
-
}), t(this,
|
|
687
|
-
|
|
688
|
-
}), t(this,
|
|
689
|
-
t(this,
|
|
690
|
-
}), t(this,
|
|
691
|
-
t(this,
|
|
692
|
-
}), t(this,
|
|
693
|
-
t(this,
|
|
694
|
-
}), t(this,
|
|
695
|
-
t(this, w) && t(this, d).notify();
|
|
696
|
-
}), t(this, d).isRunning.subscribe((e) => {
|
|
676
|
+
e.current ? (t(this, k) && (t(this, a).length || (t(this, bt).current = !0)), t(this, f).max = 1 / 0, t(this, f).min = -1 / 0) : (r(this, Re, 0), t(this, f).max = t(this, P), t(this, f).min = 0);
|
|
677
|
+
}), t(this, me).subscribe((e) => {
|
|
678
|
+
t(this, f).damping = e.current;
|
|
679
|
+
}), t(this, Se).subscribe((e) => {
|
|
680
|
+
t(this, f).mass = e.current;
|
|
681
|
+
}), t(this, ge).subscribe((e) => {
|
|
682
|
+
t(this, f).stiffness = e.current;
|
|
683
|
+
}), t(this, Z).subscribe((e) => {
|
|
684
|
+
t(this, M).speed = e.current, !t(this, yt) && e.current && !e.previous ? t(this, M).connect() : !e.current && e.previous && t(this, M).disconnect();
|
|
685
|
+
}), t(this, Bt).subscribe((e) => {
|
|
686
|
+
e.current || (t(this, M).direction = 1);
|
|
687
|
+
}), t(this, _).subscribe((e) => {
|
|
688
|
+
t(this, k) && o(this, c, ce).call(this);
|
|
689
|
+
}), t(this, Nt).subscribe((e) => {
|
|
690
|
+
t(this, k) && t(this, _).current && o(this, c, ce).call(this);
|
|
691
|
+
}), t(this, St).subscribe((e) => {
|
|
692
|
+
t(this, k) && t(this, _).current && o(this, c, ce).call(this);
|
|
693
|
+
}), t(this, Pe).subscribe((e) => {
|
|
694
|
+
t(this, k) && t(this, f).notify();
|
|
695
|
+
}), t(this, f).isRunning.subscribe((e) => {
|
|
697
696
|
this.classList.toggle("active", e.current);
|
|
698
|
-
}), t(this,
|
|
699
|
-
t(this, a).length &&
|
|
700
|
-
}), t(this,
|
|
701
|
-
t(this,
|
|
702
|
-
}), t(this,
|
|
703
|
-
e.current && !e.previous ? (this.classList.add("disabled"),
|
|
704
|
-
}), t(this,
|
|
705
|
-
e.current && !e.previous ? (this.classList.add("hibernated"),
|
|
706
|
-
}), t(this,
|
|
697
|
+
}), t(this, R).subscribe((e) => {
|
|
698
|
+
t(this, a).length && o(this, c, ce).call(this), this.style.setProperty("--counter", e.current + "");
|
|
699
|
+
}), t(this, Pt).subscribe((e) => {
|
|
700
|
+
t(this, Pt).isRunning.current && t(this, f).set(e.current, { equalize: !0 });
|
|
701
|
+
}), t(this, Gt).subscribe((e) => {
|
|
702
|
+
e.current && !e.previous ? (this.classList.add("disabled"), o(this, c, vs).call(this)) : !e.current && e.previous && (this.classList.remove("disabled"), o(this, c, ys).call(this));
|
|
703
|
+
}), t(this, Ut).subscribe((e) => {
|
|
704
|
+
e.current && !e.previous ? (this.classList.add("hibernated"), o(this, c, Vs).call(this)) : !e.current && e.previous && (this.classList.remove("hibernated"), o(this, c, ks).call(this));
|
|
705
|
+
}), t(this, pe).observe(), t(this, T).observe(), t(this, Ot).observe(), t(this, ft).observe(), t(this, pt).observe(), t(this, bt).observe(), t(this, tt).observe(), t(this, $t).observe(), t(this, Ht).observe(), t(this, mt).observe(), t(this, Wt).observe(), t(this, be).observe(), t(this, et).observe(), t(this, V).observe(), t(this, me).observe(), t(this, Se).observe(), t(this, ge).observe(), t(this, ve).observe(), t(this, Fe).observe(), t(this, ye).observe(), t(this, Z).observe(), t(this, Z).observe(), t(this, Ce).observe(), t(this, Bt).observe(), t(this, _).observe(), t(this, Nt).observe(), t(this, St).observe(), t(this, Pe).observe(), t(this, qt).observe(), t(this, we).observe(), t(this, Gt).observe(), t(this, Ut).observe(), he.subscribe(t(this, as), Es.LAST), is.subscribe(this, t(this, D)), t(this, Oe).observe(this, { childList: !0 });
|
|
707
706
|
}
|
|
708
707
|
disconnectedCallback() {
|
|
709
|
-
this.removeAttribute("tabindex"), this.classList.remove("disabled"), this.classList.remove("hibernated"), t(this,
|
|
708
|
+
this.removeAttribute("tabindex"), this.classList.remove("disabled"), this.classList.remove("hibernated"), t(this, pe).unobserve(), t(this, T).unobserve(), t(this, Ot).unobserve(), t(this, ft).unobserve(), t(this, pt).unobserve(), t(this, bt).unobserve(), t(this, tt).unobserve(), t(this, $t).unobserve(), t(this, Ht).unobserve(), t(this, mt).unobserve(), t(this, Wt).unobserve(), t(this, be).unobserve(), t(this, et).unobserve(), t(this, V).unobserve(), t(this, me).unobserve(), t(this, Se).unobserve(), t(this, ge).unobserve(), t(this, ve).unobserve(), t(this, Fe).unobserve(), t(this, ye).unobserve(), t(this, Z).unobserve(), t(this, Ce).unobserve(), t(this, Bt).unobserve(), t(this, _).unobserve(), t(this, Nt).unobserve(), t(this, St).unobserve(), t(this, Pe).unobserve(), t(this, qt).unobserve(), t(this, we).unobserve(), t(this, Gt).unobserve(), t(this, Ut).unobserve(), he.unsubscribe(t(this, as)), is.unsubscribe(t(this, D)), o(this, c, Vs).call(this), t(this, Oe).disconnect();
|
|
710
709
|
}
|
|
711
710
|
}
|
|
712
|
-
|
|
713
|
-
const e = t(this,
|
|
714
|
-
t(this,
|
|
715
|
-
},
|
|
716
|
-
|
|
717
|
-
e instanceof HTMLElement && e.tagName !== "SCRIPT" && t(this,
|
|
718
|
-
}),
|
|
711
|
+
f = new WeakMap(), pe = new WeakMap(), T = new WeakMap(), Ot = new WeakMap(), ft = new WeakMap(), pt = new WeakMap(), bt = new WeakMap(), tt = new WeakMap(), $t = new WeakMap(), Ht = new WeakMap(), mt = new WeakMap(), Wt = new WeakMap(), be = new WeakMap(), et = new WeakMap(), V = new WeakMap(), me = new WeakMap(), Se = new WeakMap(), ge = new WeakMap(), ve = new WeakMap(), Fe = new WeakMap(), ye = new WeakMap(), Z = new WeakMap(), Ce = new WeakMap(), Bt = new WeakMap(), _ = new WeakMap(), Nt = new WeakMap(), St = new WeakMap(), Pe = new WeakMap(), qt = new WeakMap(), we = new WeakMap(), Gt = new WeakMap(), Ut = new WeakMap(), Kt = new WeakMap(), b = new WeakMap(), Te = new WeakMap(), q = new WeakMap(), a = new WeakMap(), ns = new WeakMap(), os = new WeakMap(), L = new WeakMap(), P = new WeakMap(), G = new WeakMap(), st = new WeakMap(), Zt = new WeakMap(), it = new WeakMap(), M = new WeakMap(), R = new WeakMap(), Re = new WeakMap(), gt = new WeakMap(), vt = new WeakMap(), yt = new WeakMap(), Ct = new WeakMap(), De = new WeakMap(), _t = new WeakMap(), Pt = new WeakMap(), Ee = new WeakMap(), rt = new WeakMap(), k = new WeakMap(), Oe = new WeakMap(), wt = new WeakMap(), xe = new WeakMap(), $e = new WeakMap(), c = new WeakSet(), zs = function() {
|
|
712
|
+
const e = t(this, T).current, s = t(this, Ot).current ? "-reverse" : "";
|
|
713
|
+
t(this, b).style.flexDirection = e === "x" ? `row${s}` : `column${s}`, t(this, st).axis = t(this, Wt).current ? "max" : e, t(this, Zt).dimension = e === "x" ? "width" : "height", t(this, it).axis = e, e === "x" ? this.style.touchAction = "pan-y" : e === "y" && (this.style.touchAction = "pan-x"), t(this, k) && t(this, D).call(this);
|
|
714
|
+
}, es = function() {
|
|
715
|
+
o(this, c, Ie).call(this), t(this, Te).assignedElements().forEach((e, s) => {
|
|
716
|
+
e instanceof HTMLElement && e.tagName !== "SCRIPT" && t(this, q).push(new wi(e, s, this));
|
|
717
|
+
}), r(this, a, [...t(this, q)]), t(this, b).style.transform = "", X(this, "scrollSectionsChange", {
|
|
719
718
|
custom: !0,
|
|
720
719
|
composed: !0
|
|
721
|
-
}), t(this,
|
|
722
|
-
},
|
|
723
|
-
t(this,
|
|
720
|
+
}), t(this, D).call(this), o(this, c, ce).call(this);
|
|
721
|
+
}, Ie = function() {
|
|
722
|
+
t(this, q).forEach((e) => {
|
|
724
723
|
e.destroy();
|
|
725
|
-
}),
|
|
724
|
+
}), r(this, q, []), r(this, a, []), t(this, R).reset(), t(this, f).reset(), this.style.removeProperty("--max-section-size"), X(this, "scrollSectionsChange", {
|
|
726
725
|
custom: !0,
|
|
727
726
|
composed: !0
|
|
728
727
|
});
|
|
729
|
-
},
|
|
730
|
-
t(this,
|
|
728
|
+
}, vs = function() {
|
|
729
|
+
t(this, yt) || (r(this, yt, !0), t(this, f).unsubscribe(t(this, ls)), t(this, f).unlistenAnimationFrame(), clearInterval(t(this, De)), clearInterval(t(this, _t)), t(this, Pt).unlistenAnimationFrame(), t(this, st).disconnect(), t(this, Zt).disconnect(), t(this, it).disconnect(), t(this, M).disconnect(), t(this, vt) || (this.sections.forEach((e) => {
|
|
731
730
|
e.unsetTransform();
|
|
732
|
-
}), t(this,
|
|
733
|
-
},
|
|
734
|
-
t(this,
|
|
735
|
-
},
|
|
736
|
-
t(this,
|
|
737
|
-
},
|
|
738
|
-
t(this,
|
|
731
|
+
}), t(this, D).call(this)));
|
|
732
|
+
}, ys = function() {
|
|
733
|
+
t(this, yt) && (r(this, yt, !1), t(this, f).subscribe(t(this, ls), -1e4), t(this, f).notify(), t(this, st).connect(), t(this, Zt).connect(), t(this, it).connect(), t(this, Z).current && t(this, M).connect());
|
|
734
|
+
}, Vs = function() {
|
|
735
|
+
t(this, Ct) || (r(this, Ct, !0), clearTimeout(t(this, $e)), he.unsubscribe(t(this, D)), o(this, c, vs).call(this), t(this, b).style.transform = "", t(this, b).style.height = "", t(this, b).style.width = "", this.classList.remove("has-overflow", "start", "end"), t(this, q).length ? o(this, c, Ie).call(this) : (t(this, R).reset(), t(this, f).reset()), ne.unregister(this));
|
|
736
|
+
}, ks = function() {
|
|
737
|
+
t(this, Ct) && (r(this, Ct, !1), ne.register(this), this.tryResplit(), o(this, c, ys).call(this), this.scrollToSection(t(this, ye).current, {
|
|
739
738
|
behaviour: "instant"
|
|
740
|
-
}),
|
|
741
|
-
},
|
|
742
|
-
let
|
|
743
|
-
return t(this,
|
|
744
|
-
},
|
|
745
|
-
t(this,
|
|
746
|
-
t(this,
|
|
739
|
+
}), he.subscribe(t(this, D), Es.SCROLL));
|
|
740
|
+
}, D = new WeakMap(), ls = new WeakMap(), Zs = function(e) {
|
|
741
|
+
let s = t(this, R).current;
|
|
742
|
+
return t(this, V).current ? s = pi(e, t(this, a).length) : s = qs(e, 0, this.limit), s;
|
|
743
|
+
}, He = new WeakMap(), cs = new WeakMap(), As = function(e = 1) {
|
|
744
|
+
t(this, Bt).current && (t(this, M).direction = e), t(this, Z).current && t(this, M).pauseAndContinue(
|
|
745
|
+
t(this, Ce).current,
|
|
747
746
|
this.sectionalCSSProperty.current
|
|
748
747
|
);
|
|
749
|
-
},
|
|
750
|
-
if (t(this,
|
|
751
|
-
const
|
|
752
|
-
return
|
|
748
|
+
}, Is = function(e = "current") {
|
|
749
|
+
if (t(this, V).current && t(this, a).length) {
|
|
750
|
+
const s = t(this, f)[e] % Math.round(t(this, P) + t(this, L) + t(this, G));
|
|
751
|
+
return s < 0 ? t(this, P) + s + t(this, L) + t(this, G) : s;
|
|
753
752
|
} else
|
|
754
|
-
return t(this,
|
|
755
|
-
},
|
|
753
|
+
return t(this, f)[e];
|
|
754
|
+
}, ce = function() {
|
|
756
755
|
if (t(this, a).length) {
|
|
757
|
-
const e = t(this,
|
|
758
|
-
if (e === 0 ?
|
|
759
|
-
detail: { line: t(this,
|
|
760
|
-
}), t(this,
|
|
761
|
-
this.classList.remove("end", "start"), t(this,
|
|
762
|
-
const
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
const
|
|
766
|
-
|
|
767
|
-
}), t(this,
|
|
756
|
+
const e = t(this, R).current + t(this, Nt).current;
|
|
757
|
+
if (e === 0 ? r(this, rt, "start") : e === this.limit ? r(this, rt, "end") : r(this, rt, null), X(this, "scrollLine", {
|
|
758
|
+
detail: { line: t(this, rt) }
|
|
759
|
+
}), t(this, _).current) {
|
|
760
|
+
this.classList.remove("end", "start"), t(this, rt) && this.classList.add(t(this, rt));
|
|
761
|
+
const s = t(this, et).current + t(this, St).current;
|
|
762
|
+
r(this, wt, []), t(this, a).forEach((h, u) => {
|
|
763
|
+
h.setCurrentIndex(null), h.setCurrentIndexArc(null), h.setCurrentIndexArcAbs(null), h.setMiddle(!1);
|
|
764
|
+
const g = e - this.limit - 1 + t(this, St).current, v = e + s, C = this.sections.length - v;
|
|
765
|
+
u >= e && u < v || u <= g ? (h.setMark("current"), t(this, wt).push(h)) : u >= v && u < v + C / 2 || u <= g + s ? h.setMark("next") : h.setMark("previous");
|
|
766
|
+
}), t(this, us).call(this);
|
|
768
767
|
}
|
|
769
768
|
}
|
|
770
|
-
},
|
|
771
|
-
if (t(this,
|
|
772
|
-
const e = Math.floor(t(this,
|
|
773
|
-
t(this,
|
|
774
|
-
const
|
|
775
|
-
|
|
769
|
+
}, _s = function() {
|
|
770
|
+
if (t(this, _).current) {
|
|
771
|
+
const e = Math.floor(t(this, wt).length / 2);
|
|
772
|
+
t(this, wt).sort((s, h) => s.element.getBoundingClientRect().left - h.element.getBoundingClientRect().left), t(this, wt).forEach((s, h) => {
|
|
773
|
+
const u = h - e;
|
|
774
|
+
s.setCurrentIndex(h), s.setCurrentIndexArc(u), s.setCurrentIndexArcAbs(Math.abs(u)), s.setMiddle(h === e);
|
|
776
775
|
});
|
|
777
776
|
}
|
|
778
|
-
},
|
|
779
|
-
let
|
|
780
|
-
const
|
|
781
|
-
for (let
|
|
782
|
-
const
|
|
783
|
-
let
|
|
784
|
-
this.overscroll &&
|
|
785
|
-
let
|
|
786
|
-
|
|
787
|
-
}
|
|
788
|
-
return
|
|
789
|
-
},
|
|
790
|
-
|
|
791
|
-
var
|
|
792
|
-
class
|
|
777
|
+
}, us = new WeakMap(), ss = function(e = !1) {
|
|
778
|
+
let s = this.targetScrollValue, h = 1 / 0, u = 0;
|
|
779
|
+
const g = t(this, f).direction;
|
|
780
|
+
for (let v = 0; v < t(this, a).length; v++) {
|
|
781
|
+
const C = t(this, a)[v];
|
|
782
|
+
let oe = t(this, Ee) ? C.size * g * -1 * 0.4 : 0, Ae = C.position;
|
|
783
|
+
this.overscroll && Ae === 0 && e && (Ae = t(this, gt));
|
|
784
|
+
let Ye = Math.abs(Ae + oe - s);
|
|
785
|
+
Ye <= h && (h = Ye, u = v);
|
|
786
|
+
}
|
|
787
|
+
return u;
|
|
788
|
+
}, as = new WeakMap();
|
|
789
|
+
Y && !customElements.get("e-scroll") && customElements.define("e-scroll", Ls);
|
|
790
|
+
var ds;
|
|
791
|
+
class gs extends HTMLElement {
|
|
793
792
|
constructor() {
|
|
794
793
|
super(...arguments);
|
|
795
|
-
|
|
794
|
+
i(this, ds, null);
|
|
796
795
|
}
|
|
797
796
|
get scrollElement() {
|
|
798
|
-
return t(this,
|
|
797
|
+
return t(this, ds);
|
|
799
798
|
}
|
|
800
799
|
connectedCallback() {
|
|
801
|
-
const e =
|
|
802
|
-
e instanceof
|
|
800
|
+
const e = Pi(this, Ls);
|
|
801
|
+
e instanceof Ls ? r(this, ds, e) : console.error(this, "e-scroll not found");
|
|
803
802
|
}
|
|
804
803
|
}
|
|
805
|
-
|
|
806
|
-
var
|
|
807
|
-
class
|
|
804
|
+
ds = new WeakMap();
|
|
805
|
+
var jt, O, Et, xt, We, Be, Jt, Ne, fs, ps;
|
|
806
|
+
class xi extends gs {
|
|
808
807
|
constructor() {
|
|
809
808
|
super();
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
const e = t(this,
|
|
819
|
-
|
|
809
|
+
i(this, jt, null);
|
|
810
|
+
i(this, O, null);
|
|
811
|
+
i(this, Et, !1);
|
|
812
|
+
i(this, xt, 0);
|
|
813
|
+
i(this, We, 0);
|
|
814
|
+
i(this, Be, 0);
|
|
815
|
+
i(this, Jt, () => {
|
|
816
|
+
r(this, Et, this.offsetWidth > this.offsetHeight);
|
|
817
|
+
const e = t(this, Et) ? this.offsetWidth : this.offsetHeight;
|
|
818
|
+
r(this, xt, e / ((this.scrollElement.scrollSize + this.scrollElement.viewportSize) / e)), r(this, xt, Math.max(t(this, xt), 30)), t(this, Et) ? (t(this, O).style.width = t(this, xt) + "px", t(this, O).style.height = "100%") : (t(this, O).style.width = "100%", t(this, O).style.height = t(this, xt) + "px"), r(this, We, e - t(this, xt)), this.scrollElement.scrollSize <= 0 ? this.style.display = "none" : this.style.display = "", t(this, Ne).call(this);
|
|
820
819
|
});
|
|
821
|
-
|
|
822
|
-
|
|
820
|
+
i(this, Ne, () => {
|
|
821
|
+
r(this, Be, this.scrollElement.currentProgress * t(this, We)), t(this, Et) ? t(this, O).style.transform = `translate3d(${t(this, Be)}px, 0px, 0px)` : t(this, O).style.transform = `translate3d(0px, ${t(this, Be)}px, 0px)`;
|
|
823
822
|
});
|
|
824
|
-
|
|
823
|
+
i(this, fs, () => {
|
|
825
824
|
this.setAttribute("axis", this.scrollElement.axisCSSProperty.current);
|
|
826
825
|
});
|
|
827
|
-
|
|
828
|
-
document.documentElement.classList.add("grabbing"),
|
|
829
|
-
(
|
|
830
|
-
const
|
|
831
|
-
this.scrollElement.setPosition(
|
|
826
|
+
i(this, ps, (e) => {
|
|
827
|
+
document.documentElement.classList.add("grabbing"), Ci(
|
|
828
|
+
(u) => {
|
|
829
|
+
const g = t(this, Et) ? u.x : u.y, v = this.scrollElement.distance / t(this, We), C = (g - h) * v;
|
|
830
|
+
this.scrollElement.setPosition(s + C);
|
|
832
831
|
},
|
|
833
832
|
() => {
|
|
834
833
|
document.documentElement.classList.remove("grabbing");
|
|
835
834
|
}
|
|
836
835
|
);
|
|
837
|
-
const
|
|
836
|
+
const s = this.scrollElement.damped.target, h = t(this, Et) ? e.x : e.y;
|
|
838
837
|
});
|
|
839
|
-
if (
|
|
838
|
+
if (Y) {
|
|
840
839
|
const e = this.attachShadow({ mode: "open" });
|
|
841
840
|
e.adoptedStyleSheets = [
|
|
842
|
-
|
|
841
|
+
Gs({
|
|
843
842
|
":host": {
|
|
844
843
|
display: "inline-block",
|
|
845
844
|
zIndex: "1",
|
|
@@ -868,203 +867,583 @@ class xs extends ke {
|
|
|
868
867
|
touchAction: "none"
|
|
869
868
|
}
|
|
870
869
|
})
|
|
871
|
-
],
|
|
870
|
+
], r(this, jt, document.createElement("slot")), t(this, jt).innerHTML = '<div class="default-thumb"></div>', e.appendChild(t(this, jt));
|
|
872
871
|
}
|
|
873
872
|
}
|
|
874
873
|
get thumbElement() {
|
|
875
|
-
return t(this,
|
|
874
|
+
return t(this, O);
|
|
876
875
|
}
|
|
877
876
|
connectedCallback() {
|
|
878
877
|
super.connectedCallback(), this.setAttribute("drag-dead-zone", "");
|
|
879
|
-
const e = t(this,
|
|
880
|
-
|
|
878
|
+
const e = t(this, jt).assignedElements()[0] || t(this, jt).firstElementChild;
|
|
879
|
+
r(this, O, e), t(this, O).addEventListener("pointerdown", t(this, ps)), he.subscribe(t(this, Jt), Es.SCROLL), is.subscribe(this, t(this, Jt)), is.subscribe(this.scrollElement, t(this, Jt)), this.scrollElement.onScroll(t(this, Ne)), this.scrollElement.axisCSSProperty.subscribe(t(this, fs));
|
|
881
880
|
}
|
|
882
881
|
disconnectedCallback() {
|
|
883
|
-
this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this,
|
|
882
|
+
this.removeAttribute("drag-dead-zone"), this.style.display = "", t(this, O).removeEventListener("pointerdown", t(this, ps)), he.unsubscribe(t(this, Jt)), is.unsubscribe(t(this, Jt)), this.scrollElement.offScroll(t(this, Ne)), this.scrollElement.axisCSSProperty.unsubscribe(t(this, fs));
|
|
884
883
|
}
|
|
885
884
|
}
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
var
|
|
889
|
-
class
|
|
885
|
+
jt = new WeakMap(), O = new WeakMap(), Et = new WeakMap(), xt = new WeakMap(), We = new WeakMap(), Be = new WeakMap(), Jt = new WeakMap(), Ne = new WeakMap(), fs = new WeakMap(), ps = new WeakMap();
|
|
886
|
+
Y && !customElements.get("e-scrollbar") && customElements.define("e-scrollbar", xi);
|
|
887
|
+
var qe, Ge, Ue;
|
|
888
|
+
class js extends gs {
|
|
890
889
|
constructor() {
|
|
891
890
|
super();
|
|
892
|
-
|
|
893
|
-
|
|
891
|
+
i(this, qe, new l(this, "--behaviour", "smooth"));
|
|
892
|
+
i(this, Ge, new l(
|
|
894
893
|
this,
|
|
895
894
|
"--tween-easing",
|
|
896
895
|
!1
|
|
897
896
|
));
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
const e = t(this,
|
|
897
|
+
i(this, Ue, new l(this, "--tween-duration", 0));
|
|
898
|
+
Y && this.addEventListener("click", () => {
|
|
899
|
+
const e = t(this, qe).current, s = t(this, Ge).current, h = t(this, Ue).current;
|
|
901
900
|
this.handleClick({
|
|
902
901
|
behaviour: e,
|
|
903
|
-
tween:
|
|
902
|
+
tween: s || h ? { easing: s, duration: h } : void 0
|
|
904
903
|
});
|
|
905
904
|
});
|
|
906
905
|
}
|
|
907
906
|
connectedCallback() {
|
|
908
|
-
super.connectedCallback(), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.hasAttribute("role") || this.setAttribute("role", "button"), t(this,
|
|
907
|
+
super.connectedCallback(), this.hasAttribute("tabindex") || this.setAttribute("tabindex", "0"), this.hasAttribute("role") || this.setAttribute("role", "button"), t(this, qe).observe(), t(this, Ge).observe(), t(this, Ue).observe();
|
|
909
908
|
}
|
|
910
909
|
disconnectedCallback() {
|
|
911
|
-
this.removeAttribute("tabindex"), this.removeAttribute("role"), t(this,
|
|
910
|
+
this.removeAttribute("tabindex"), this.removeAttribute("role"), t(this, qe).close(), t(this, Ge).close(), t(this, Ue).close();
|
|
912
911
|
}
|
|
913
912
|
}
|
|
914
|
-
|
|
915
|
-
var
|
|
916
|
-
class
|
|
913
|
+
qe = new WeakMap(), Ge = new WeakMap(), Ue = new WeakMap();
|
|
914
|
+
var Ke;
|
|
915
|
+
class Li extends js {
|
|
917
916
|
constructor() {
|
|
918
917
|
super(...arguments);
|
|
919
|
-
|
|
918
|
+
i(this, Ke, new l(this, "--set", 1));
|
|
920
919
|
}
|
|
921
920
|
handleClick(e) {
|
|
922
|
-
this.scrollElement.scrollToSection(t(this,
|
|
921
|
+
this.scrollElement.scrollToSection(t(this, Ke).current, e);
|
|
923
922
|
}
|
|
924
923
|
connectedCallback() {
|
|
925
|
-
super.connectedCallback(), t(this,
|
|
924
|
+
super.connectedCallback(), t(this, Ke).observe();
|
|
926
925
|
}
|
|
927
926
|
disconnectedCallback() {
|
|
928
|
-
super.disconnectedCallback(), t(this,
|
|
927
|
+
super.disconnectedCallback(), t(this, Ke).close();
|
|
929
928
|
}
|
|
930
929
|
}
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
var
|
|
934
|
-
class
|
|
930
|
+
Ke = new WeakMap();
|
|
931
|
+
Y && !customElements.get("e-scroll-set-button") && customElements.define("e-scroll-set-button", Li);
|
|
932
|
+
var Lt, Ze;
|
|
933
|
+
class zi extends js {
|
|
935
934
|
constructor() {
|
|
936
935
|
super(...arguments);
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
this.scrollElement.loopCSSProperty.current ? this.removeAttribute("disabled") : t(this,
|
|
936
|
+
i(this, Lt, new l(this, "--step", 1));
|
|
937
|
+
i(this, Ze, () => {
|
|
938
|
+
this.scrollElement.loopCSSProperty.current ? this.removeAttribute("disabled") : t(this, Lt).current > 0 && this.scrollElement.scrollLine === "end" || t(this, Lt).current < 0 && this.scrollElement.scrollLine === "start" ? this.setAttribute("disabled", "") : this.removeAttribute("disabled");
|
|
940
939
|
});
|
|
941
940
|
}
|
|
942
941
|
handleClick(e) {
|
|
943
|
-
this.scrollElement.shiftSections(t(this,
|
|
942
|
+
this.scrollElement.shiftSections(t(this, Lt).current, e);
|
|
944
943
|
}
|
|
945
944
|
connectedCallback() {
|
|
946
|
-
super.connectedCallback(), this.scrollElement && (t(this,
|
|
947
|
-
t(this,
|
|
948
|
-
}), t(this,
|
|
945
|
+
super.connectedCallback(), this.scrollElement && (t(this, Lt).subscribe(() => {
|
|
946
|
+
t(this, Ze).call(this);
|
|
947
|
+
}), t(this, Lt).observe(), this.scrollElement.addEventListener(
|
|
949
948
|
"scrollLine",
|
|
950
|
-
t(this,
|
|
951
|
-
), t(this,
|
|
949
|
+
t(this, Ze)
|
|
950
|
+
), t(this, Ze).call(this));
|
|
952
951
|
}
|
|
953
952
|
disconnectedCallback() {
|
|
954
|
-
super.disconnectedCallback(), t(this,
|
|
953
|
+
super.disconnectedCallback(), t(this, Lt).close(), this.removeAttribute("disabled");
|
|
955
954
|
}
|
|
956
955
|
}
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
var
|
|
960
|
-
class
|
|
961
|
-
constructor(n, e,
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
t(this,
|
|
968
|
-
behaviour: t(this,
|
|
956
|
+
Lt = new WeakMap(), Ze = new WeakMap();
|
|
957
|
+
Y && !customElements.get("e-scroll-step-button") && customElements.define("e-scroll-step-button", zi);
|
|
958
|
+
var ht, Qt, _e, bs, ms, je;
|
|
959
|
+
class Vi {
|
|
960
|
+
constructor(n, e, s) {
|
|
961
|
+
i(this, ht, null);
|
|
962
|
+
i(this, Qt, null);
|
|
963
|
+
i(this, _e, null);
|
|
964
|
+
i(this, bs, null);
|
|
965
|
+
i(this, ms, () => {
|
|
966
|
+
t(this, Qt).scrollToSection(t(this, _e), {
|
|
967
|
+
behaviour: t(this, bs)
|
|
969
968
|
});
|
|
970
969
|
});
|
|
971
|
-
|
|
972
|
-
t(this,
|
|
970
|
+
i(this, je, () => {
|
|
971
|
+
t(this, ht).classList.toggle(
|
|
973
972
|
"current",
|
|
974
|
-
t(this,
|
|
973
|
+
t(this, Qt).counter.current === t(this, _e)
|
|
975
974
|
);
|
|
976
975
|
});
|
|
977
|
-
|
|
976
|
+
Y && (r(this, ht, document.createElement("button")), t(this, ht).setAttribute("aria-label", `Go to section ${e + 1}`), r(this, Qt, n), r(this, bs, s), r(this, _e, e), t(this, ht).addEventListener("click", t(this, ms)), t(this, Qt).counter.subscribe(t(this, je)), t(this, je).call(this));
|
|
978
977
|
}
|
|
979
978
|
get element() {
|
|
980
|
-
return t(this,
|
|
979
|
+
return t(this, ht);
|
|
981
980
|
}
|
|
982
981
|
destroy() {
|
|
983
|
-
t(this,
|
|
982
|
+
t(this, ht).removeEventListener("click", t(this, ms)), t(this, Qt).counter.unsubscribe(t(this, je)), t(this, ht).remove();
|
|
984
983
|
}
|
|
985
984
|
}
|
|
986
|
-
|
|
987
|
-
var
|
|
988
|
-
class
|
|
985
|
+
ht = new WeakMap(), Qt = new WeakMap(), _e = new WeakMap(), bs = new WeakMap(), ms = new WeakMap(), je = new WeakMap();
|
|
986
|
+
var Le, Xt, zt;
|
|
987
|
+
class ki extends gs {
|
|
989
988
|
constructor() {
|
|
990
989
|
super(...arguments);
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
t(this,
|
|
990
|
+
i(this, Le, null);
|
|
991
|
+
i(this, Xt, []);
|
|
992
|
+
i(this, zt, Cs(() => {
|
|
993
|
+
t(this, Xt).forEach((s) => s.destroy()), r(this, Xt, []);
|
|
995
994
|
let e = 0;
|
|
996
995
|
this.scrollElement.loopCSSProperty.current ? e = this.scrollElement.visibleSections.length : e = this.scrollElement.visibleSections.length - Math.max(this.scrollElement.sectionsInViewCSSProperty.current - 1, 0);
|
|
997
|
-
for (let
|
|
998
|
-
const
|
|
996
|
+
for (let s = 0; s < e; s++) {
|
|
997
|
+
const h = new Vi(
|
|
999
998
|
this.scrollElement,
|
|
1000
|
-
|
|
999
|
+
s,
|
|
1001
1000
|
this.getAttribute("behaviour") || "smooth"
|
|
1002
1001
|
);
|
|
1003
|
-
t(this,
|
|
1002
|
+
t(this, Le).appendChild(h.element), t(this, Xt).push(h);
|
|
1004
1003
|
}
|
|
1005
1004
|
}, 0));
|
|
1006
1005
|
}
|
|
1007
1006
|
connectedCallback() {
|
|
1008
1007
|
super.connectedCallback(), this.innerHTML = "", this.scrollElement.addEventListener(
|
|
1009
1008
|
"scrollSectionsChange",
|
|
1010
|
-
t(this,
|
|
1009
|
+
t(this, zt)
|
|
1011
1010
|
), this.scrollElement.sectionsInViewCSSProperty.subscribe(
|
|
1012
|
-
t(this,
|
|
1013
|
-
), this.scrollElement.loopCSSProperty.subscribe(t(this,
|
|
1011
|
+
t(this, zt)
|
|
1012
|
+
), this.scrollElement.loopCSSProperty.subscribe(t(this, zt)), r(this, Le, document.createElement("div")), this.appendChild(t(this, Le));
|
|
1014
1013
|
}
|
|
1015
1014
|
disconnectedCallback() {
|
|
1016
1015
|
this.scrollElement.removeEventListener(
|
|
1017
1016
|
"scrollSectionsChange",
|
|
1018
|
-
t(this,
|
|
1017
|
+
t(this, zt)
|
|
1019
1018
|
), this.scrollElement.sectionsInViewCSSProperty.unsubscribe(
|
|
1020
|
-
t(this,
|
|
1021
|
-
), this.scrollElement.loopCSSProperty.unsubscribe(t(this,
|
|
1019
|
+
t(this, zt)
|
|
1020
|
+
), this.scrollElement.loopCSSProperty.unsubscribe(t(this, zt)), t(this, Xt).forEach((e) => e.destroy()), r(this, Xt, []), t(this, Le).remove();
|
|
1022
1021
|
}
|
|
1023
1022
|
}
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1023
|
+
Le = new WeakMap(), Xt = new WeakMap(), zt = new WeakMap();
|
|
1024
|
+
Y && !customElements.get("e-scroll-bullet-buttons") && customElements.define("e-scroll-bullet-buttons", ki);
|
|
1025
|
+
var Yt, te, ee, se, Vt, kt, At, It, A, $, H, W, Mt, z, nt, ot, j, Ft, ze, lt, ct, ut, E, B, N, J, Q, U, Je, S, Tt, ie, Qe, x, at, F, I, K, Ve, Rt, y, re, m, Js, Qs, Xs, Ys, ti, ei, Xe, ke, Ms, ue, si, ii, Fs;
|
|
1026
|
+
class Ai extends gs {
|
|
1027
|
+
constructor() {
|
|
1028
|
+
super(...arguments);
|
|
1029
|
+
i(this, m);
|
|
1030
|
+
i(this, Yt);
|
|
1031
|
+
i(this, te);
|
|
1032
|
+
i(this, ee);
|
|
1033
|
+
i(this, se);
|
|
1034
|
+
i(this, Vt);
|
|
1035
|
+
i(this, kt);
|
|
1036
|
+
i(this, At);
|
|
1037
|
+
i(this, It);
|
|
1038
|
+
i(this, A);
|
|
1039
|
+
i(this, $);
|
|
1040
|
+
i(this, H);
|
|
1041
|
+
i(this, W);
|
|
1042
|
+
i(this, Mt);
|
|
1043
|
+
i(this, z);
|
|
1044
|
+
i(this, nt);
|
|
1045
|
+
i(this, ot);
|
|
1046
|
+
i(this, j);
|
|
1047
|
+
i(this, Ft);
|
|
1048
|
+
i(this, ze);
|
|
1049
|
+
i(this, lt);
|
|
1050
|
+
i(this, ct);
|
|
1051
|
+
i(this, ut);
|
|
1052
|
+
i(this, E);
|
|
1053
|
+
i(this, B);
|
|
1054
|
+
i(this, N);
|
|
1055
|
+
i(this, J);
|
|
1056
|
+
i(this, Q);
|
|
1057
|
+
i(this, U);
|
|
1058
|
+
i(this, Je);
|
|
1059
|
+
i(this, S);
|
|
1060
|
+
i(this, Tt);
|
|
1061
|
+
i(this, ie);
|
|
1062
|
+
i(this, Qe);
|
|
1063
|
+
i(this, x);
|
|
1064
|
+
i(this, at);
|
|
1065
|
+
i(this, F);
|
|
1066
|
+
i(this, I);
|
|
1067
|
+
i(this, K);
|
|
1068
|
+
i(this, Ve);
|
|
1069
|
+
i(this, Rt);
|
|
1070
|
+
i(this, y);
|
|
1071
|
+
i(this, re);
|
|
1072
|
+
i(this, Xe);
|
|
1073
|
+
i(this, ke);
|
|
1074
|
+
r(this, Yt, new l(this, "--damping", 20)), r(this, te, new l(this, "--mass", 0)), r(this, ee, new l(this, "--stiffness", 0)), r(this, se, new l(this, "--target", "")), r(this, Vt, new l(this, "--disabled", !1)), r(this, kt, new l(
|
|
1075
|
+
this,
|
|
1076
|
+
"--distance-offset",
|
|
1077
|
+
0,
|
|
1078
|
+
{ rawValueCheck: !1 }
|
|
1079
|
+
)), r(this, At, new l(this, "--start-offset", 0, {
|
|
1080
|
+
rawValueCheck: !1
|
|
1081
|
+
})), r(this, It, new l(
|
|
1082
|
+
this,
|
|
1083
|
+
"--capture-once",
|
|
1084
|
+
!1
|
|
1085
|
+
)), r(this, A, new l(this, "--captured", "")), r(this, $, new l(this, "--released", "")), r(this, H, new l(
|
|
1086
|
+
this,
|
|
1087
|
+
"--captured-from-start",
|
|
1088
|
+
""
|
|
1089
|
+
)), r(this, W, new l(
|
|
1090
|
+
this,
|
|
1091
|
+
"--captured-from-finish",
|
|
1092
|
+
""
|
|
1093
|
+
)), r(this, Mt, new l(
|
|
1094
|
+
this,
|
|
1095
|
+
"--released-from-start",
|
|
1096
|
+
""
|
|
1097
|
+
)), r(this, z, new l(
|
|
1098
|
+
this,
|
|
1099
|
+
"--released-from-finish",
|
|
1100
|
+
""
|
|
1101
|
+
)), r(this, nt, new l(this, "--passed-var", "")), r(this, ot, new l(this, "--progress-var", "")), r(this, j, new l(
|
|
1102
|
+
this,
|
|
1103
|
+
"--progress-arc-var",
|
|
1104
|
+
""
|
|
1105
|
+
)), r(this, Ft, new l(
|
|
1106
|
+
this,
|
|
1107
|
+
"--progress-arc-mult",
|
|
1108
|
+
1
|
|
1109
|
+
)), r(this, ze, new l(
|
|
1110
|
+
this,
|
|
1111
|
+
"--animation-var-type",
|
|
1112
|
+
"target"
|
|
1113
|
+
)), r(this, lt, new l(this, "--distance-var", "")), r(this, ct, new l(this, "--start-var", "")), r(this, ut, new l(this, "--finish-var", "")), r(this, E, new le(!1)), r(this, B, new le(!1)), r(this, N, new le(!1)), r(this, J, new le(!1)), r(this, Q, new le(!1)), r(this, U, new le(!1)), r(this, Je, []), r(this, S, this), r(this, Tt, 0), r(this, ie, 0), r(this, Qe, 0), r(this, x, new Ks(0, { order: Us.SEGMENT, min: 0, max: 1 })), r(this, at, 0), r(this, F, 0), r(this, I, 0), r(this, K, 0), r(this, Ve, !1), r(this, Rt, !1), r(this, y, !0), r(this, re, !1), this.resize = () => {
|
|
1114
|
+
r(this, ie, this.scrollElement.vertical ? this.offsetHeight : this.offsetWidth), r(this, Tt, this.scrollElement.vertical ? Ps(this, this.scrollElement) : ws(this, this.scrollElement));
|
|
1115
|
+
const e = ai(
|
|
1116
|
+
this,
|
|
1117
|
+
this.scrollElement.vertical ? "top" : "left"
|
|
1118
|
+
);
|
|
1119
|
+
r(this, Tt, t(this, Tt) - e), r(this, F, this.getStart()), r(this, I, this.getDistance()), r(this, F, t(this, F) + t(this, At).current), r(this, I, t(this, I) + t(this, kt).current), r(this, K, t(this, F) + t(this, I)), this.scrollElement.currentScrollValue > t(this, K) && !t(this, E).current && !t(this, B).current && (t(this, E).current = !0), this.setVar(t(this, ct).current, t(this, F)), this.setVar(t(this, ut).current, t(this, K)), this.setVar(t(this, lt).current, t(this, I)), t(this, x).max = t(this, I), r(this, Ve, !0), t(this, ke).call(this);
|
|
1120
|
+
}, this.findAnotherScrollEntries = Cs(() => {
|
|
1121
|
+
const e = ne.getAll(this).reverse();
|
|
1122
|
+
let s = 0;
|
|
1123
|
+
e.forEach((h, u) => {
|
|
1124
|
+
h.element === this.scrollElement && (s = u);
|
|
1125
|
+
}), r(this, Je, e.slice(s + 1)), this.tick();
|
|
1126
|
+
}, 0), r(this, Xe, () => {
|
|
1127
|
+
t(this, y) || this.resize();
|
|
1128
|
+
}), r(this, ke, () => {
|
|
1129
|
+
!t(this, y) && t(this, Ve) && this.tick();
|
|
1130
|
+
});
|
|
1131
|
+
}
|
|
1132
|
+
get distanceOffsetCSSProperty() {
|
|
1133
|
+
return t(this, kt);
|
|
1134
|
+
}
|
|
1135
|
+
get startOffsetCSSProperty() {
|
|
1136
|
+
return t(this, At);
|
|
1137
|
+
}
|
|
1138
|
+
get captureOnceCSSProperty() {
|
|
1139
|
+
return t(this, It);
|
|
1140
|
+
}
|
|
1141
|
+
get capturedCSSProperty() {
|
|
1142
|
+
return t(this, A);
|
|
1143
|
+
}
|
|
1144
|
+
get releasedCSSProperty() {
|
|
1145
|
+
return t(this, $);
|
|
1146
|
+
}
|
|
1147
|
+
get capturedFromStartCSSProperty() {
|
|
1148
|
+
return t(this, H);
|
|
1149
|
+
}
|
|
1150
|
+
get capturedFromFinishCSSProperty() {
|
|
1151
|
+
return t(this, W);
|
|
1152
|
+
}
|
|
1153
|
+
get releasedFromStartCSSProperty() {
|
|
1154
|
+
return t(this, Mt);
|
|
1155
|
+
}
|
|
1156
|
+
get releasedFromFinishCSSProperty() {
|
|
1157
|
+
return t(this, z);
|
|
1158
|
+
}
|
|
1159
|
+
get passedVarCSSProperty() {
|
|
1160
|
+
return t(this, nt);
|
|
1161
|
+
}
|
|
1162
|
+
get progressVarCSSProperty() {
|
|
1163
|
+
return t(this, ot);
|
|
1164
|
+
}
|
|
1165
|
+
get progressArcVarCSSProperty() {
|
|
1166
|
+
return t(this, j);
|
|
1167
|
+
}
|
|
1168
|
+
get progressArcMultCSSProperty() {
|
|
1169
|
+
return t(this, Ft);
|
|
1170
|
+
}
|
|
1171
|
+
get animationVarTypeCSSProperty() {
|
|
1172
|
+
return t(this, ze);
|
|
1173
|
+
}
|
|
1174
|
+
get distanceVarCSSProperty() {
|
|
1175
|
+
return t(this, lt);
|
|
1176
|
+
}
|
|
1177
|
+
get startVarCSSProperty() {
|
|
1178
|
+
return t(this, ct);
|
|
1179
|
+
}
|
|
1180
|
+
get finishVarCSSProperty() {
|
|
1181
|
+
return t(this, ut);
|
|
1182
|
+
}
|
|
1183
|
+
get disabledCSSProperty() {
|
|
1184
|
+
return t(this, Vt);
|
|
1185
|
+
}
|
|
1186
|
+
get dampingCSSProperty() {
|
|
1187
|
+
return t(this, Yt);
|
|
1188
|
+
}
|
|
1189
|
+
get massCSSProperty() {
|
|
1190
|
+
return t(this, te);
|
|
1191
|
+
}
|
|
1192
|
+
get stiffnessCSSProperty() {
|
|
1193
|
+
return t(this, ee);
|
|
1194
|
+
}
|
|
1195
|
+
get targetCSSProperty() {
|
|
1196
|
+
return t(this, se);
|
|
1197
|
+
}
|
|
1198
|
+
get isCaptured() {
|
|
1199
|
+
return t(this, E);
|
|
1200
|
+
}
|
|
1201
|
+
get isReleased() {
|
|
1202
|
+
return t(this, B);
|
|
1203
|
+
}
|
|
1204
|
+
get isCapturedFromStart() {
|
|
1205
|
+
return t(this, N);
|
|
1206
|
+
}
|
|
1207
|
+
get isReleasedFromStart() {
|
|
1208
|
+
return t(this, J);
|
|
1209
|
+
}
|
|
1210
|
+
get isCapturedFromFinish() {
|
|
1211
|
+
return t(this, Q);
|
|
1212
|
+
}
|
|
1213
|
+
get isReleasedFromFinish() {
|
|
1214
|
+
return t(this, U);
|
|
1215
|
+
}
|
|
1216
|
+
get directionPosition() {
|
|
1217
|
+
return t(this, Tt);
|
|
1218
|
+
}
|
|
1219
|
+
get directionSize() {
|
|
1220
|
+
return t(this, ie);
|
|
1221
|
+
}
|
|
1222
|
+
get passed() {
|
|
1223
|
+
return t(this, x);
|
|
1224
|
+
}
|
|
1225
|
+
get progress() {
|
|
1226
|
+
return t(this, at);
|
|
1227
|
+
}
|
|
1228
|
+
get progressArc() {
|
|
1229
|
+
return Math.abs(Math.cos(t(this, at) * Math.PI)) * t(this, Ft).current;
|
|
1230
|
+
}
|
|
1231
|
+
get start() {
|
|
1232
|
+
return t(this, F);
|
|
1233
|
+
}
|
|
1234
|
+
get finish() {
|
|
1235
|
+
return t(this, K);
|
|
1236
|
+
}
|
|
1237
|
+
get distance() {
|
|
1238
|
+
return t(this, I);
|
|
1239
|
+
}
|
|
1240
|
+
get isCapturedOnce() {
|
|
1241
|
+
return t(this, Rt);
|
|
1242
|
+
}
|
|
1243
|
+
get isDisabled() {
|
|
1244
|
+
return t(this, y);
|
|
1245
|
+
}
|
|
1246
|
+
tick() {
|
|
1247
|
+
let e = this.scrollElement.currentScrollValue;
|
|
1248
|
+
t(this, Je).forEach((u) => {
|
|
1249
|
+
e += u.value;
|
|
1250
|
+
});
|
|
1251
|
+
const s = e - t(this, F);
|
|
1252
|
+
t(this, re) || r(this, re, t(this, x).previous ? Math.abs(t(this, x).previous - s) > 1e3 : !1), t(this, x).set(s);
|
|
1253
|
+
const h = Math.round(e);
|
|
1254
|
+
t(this, E).current && (h >= t(this, F) ? t(this, N).current || o(this, m, Xs).call(this) : t(this, N).current && !t(this, J).current && o(this, m, ti).call(this), h < t(this, K) ? t(this, U).current && !t(this, Q).current && o(this, m, Ys).call(this) : t(this, N).current && !t(this, U).current && o(this, m, ei).call(this)), h >= t(this, F) && h < t(this, K) ? t(this, E).current || o(this, m, Js).call(this) : t(this, E).current && (t(this, x).set(
|
|
1255
|
+
di(t(this, I) / 2, t(this, x).target, 0, t(this, I))
|
|
1256
|
+
), o(this, m, Qs).call(this)), t(this, Rt) && t(this, It).current && (t(this, A).current && t(this, S).classList.add(t(this, A).current), r(this, y, !0));
|
|
1257
|
+
}
|
|
1258
|
+
disable() {
|
|
1259
|
+
this.style.cssText = "", r(this, Tt, 0), r(this, ie, 0), t(this, x).reset(), r(this, at, 0), r(this, F, 0), r(this, I, 0), r(this, K, 0), r(this, Ve, !1), t(this, E).current = !1, t(this, B).current = !1, t(this, N).current = !1, t(this, J).current = !1, t(this, Q).current = !1, t(this, U).current = !1, r(this, Rt, !1), r(this, y, !0), o(this, m, Fs).call(this);
|
|
1260
|
+
}
|
|
1261
|
+
enable() {
|
|
1262
|
+
r(this, y, !1);
|
|
1263
|
+
}
|
|
1027
1264
|
connectedCallback() {
|
|
1028
|
-
|
|
1029
|
-
|
|
1265
|
+
super.connectedCallback(), t(this, E).subscribe((s) => {
|
|
1266
|
+
s.current && X(this, "scrollSegmentCapture", {
|
|
1267
|
+
composed: !0,
|
|
1268
|
+
custom: !0
|
|
1269
|
+
});
|
|
1270
|
+
}), t(this, N).subscribe((s) => {
|
|
1271
|
+
s.current && X(this, "scrollSegmentCaptureFromStart", {
|
|
1272
|
+
composed: !0,
|
|
1273
|
+
custom: !0
|
|
1274
|
+
});
|
|
1275
|
+
}), t(this, Q).subscribe((s) => {
|
|
1276
|
+
s.current && X(this, "scrollSegmentCaptureFromFinish", {
|
|
1277
|
+
composed: !0,
|
|
1278
|
+
custom: !0
|
|
1279
|
+
});
|
|
1280
|
+
}), t(this, B).subscribe((s) => {
|
|
1281
|
+
s.current && X(this, "scrollSegmentRelease", {
|
|
1282
|
+
composed: !0,
|
|
1283
|
+
custom: !0
|
|
1284
|
+
});
|
|
1285
|
+
}), t(this, J).subscribe((s) => {
|
|
1286
|
+
s.current && X(this, "scrollSegmentReleaseFromStart", {
|
|
1287
|
+
composed: !0,
|
|
1288
|
+
custom: !0
|
|
1289
|
+
});
|
|
1290
|
+
}), t(this, U).subscribe((s) => {
|
|
1291
|
+
s.current && X(this, "scrollSegmentReleaseFromFinish", {
|
|
1292
|
+
composed: !0,
|
|
1293
|
+
custom: !0
|
|
1294
|
+
});
|
|
1295
|
+
}), t(this, Yt).observe(), t(this, te).observe(), t(this, ee).observe(), t(this, se).observe(), t(this, Vt).observe(), t(this, kt).observe(), t(this, At).observe(), t(this, It).observe(), t(this, A).observe(), t(this, $).observe(), t(this, H).observe(), t(this, W).observe(), t(this, Mt).observe(), t(this, z).observe(), t(this, nt).observe(), t(this, ot).observe(), t(this, j).observe(), t(this, Ft).observe(), t(this, ze).observe(), t(this, lt).observe(), t(this, ct).observe(), t(this, ut).observe();
|
|
1296
|
+
let e = !1;
|
|
1297
|
+
this.findAnotherScrollEntries(), t(this, Vt).current || this.enable(), t(this, Yt).subscribe((s) => {
|
|
1298
|
+
t(this, x).damping = s.current;
|
|
1299
|
+
}), t(this, te).subscribe((s) => {
|
|
1300
|
+
t(this, x).mass = s.current;
|
|
1301
|
+
}), t(this, ee).subscribe((s) => {
|
|
1302
|
+
t(this, x).stiffness = s.current;
|
|
1303
|
+
}), t(this, se).subscribe((s) => {
|
|
1304
|
+
s.previous && o(this, m, Fs).call(this), s.current ? s.current === "parent" ? r(this, S, this.parentElement || this) : r(this, S, document.querySelector(s.current) || this) : r(this, S, this);
|
|
1305
|
+
}), t(this, Vt).subscribe((s) => {
|
|
1306
|
+
s.current && !s.previous ? this.disable() : !s.current && s.previous && (this.resize(), this.enable());
|
|
1307
|
+
}), t(this, At).subscribe(() => {
|
|
1308
|
+
e && !t(this, y) && this.resize();
|
|
1309
|
+
}), t(this, kt).subscribe(() => {
|
|
1310
|
+
e && !t(this, y) && this.resize();
|
|
1311
|
+
}), t(this, A).subscribe((s) => {
|
|
1312
|
+
o(this, m, ue).call(this, s);
|
|
1313
|
+
}), t(this, H).subscribe((s) => {
|
|
1314
|
+
o(this, m, ue).call(this, s);
|
|
1315
|
+
}), t(this, W).subscribe((s) => {
|
|
1316
|
+
o(this, m, ue).call(this, s);
|
|
1317
|
+
}), t(this, $).subscribe((s) => {
|
|
1318
|
+
o(this, m, ue).call(this, s);
|
|
1319
|
+
}), t(this, Mt).subscribe((s) => {
|
|
1320
|
+
o(this, m, ue).call(this, s);
|
|
1321
|
+
}), t(this, z).subscribe((s) => {
|
|
1322
|
+
o(this, m, ue).call(this, s);
|
|
1323
|
+
}), t(this, It).subscribe((s) => {
|
|
1324
|
+
t(this, y) || !s.current && s.previous && (this.resize(), this.enable());
|
|
1325
|
+
}), t(this, nt).subscribe((s) => {
|
|
1326
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, this.passed.current));
|
|
1327
|
+
}), t(this, ot).subscribe((s) => {
|
|
1328
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, t(this, at)));
|
|
1329
|
+
}), t(this, j).subscribe((s) => {
|
|
1330
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, this.progressArc));
|
|
1331
|
+
}), t(this, Ft).subscribe((s) => {
|
|
1332
|
+
t(this, y) || o(this, m, Ms).call(this);
|
|
1333
|
+
}), t(this, ct).subscribe((s) => {
|
|
1334
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, t(this, F)));
|
|
1335
|
+
}), t(this, ut).subscribe((s) => {
|
|
1336
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, t(this, K)));
|
|
1337
|
+
}), t(this, lt).subscribe((s) => {
|
|
1338
|
+
t(this, y) || (this.removeVar(s.previous), this.setVar(s.current, t(this, I)));
|
|
1339
|
+
}), t(this, x).subscribe((s) => {
|
|
1340
|
+
if (t(this, re)) {
|
|
1341
|
+
r(this, re, !1);
|
|
1342
|
+
return;
|
|
1343
|
+
}
|
|
1344
|
+
o(this, m, Ms).call(this);
|
|
1345
|
+
}), this.scrollElement.addEventListener(
|
|
1030
1346
|
"scrollSectionsChange",
|
|
1031
1347
|
this.findAnotherScrollEntries
|
|
1032
|
-
), this.
|
|
1348
|
+
), this.scrollElement.addEventListener("scrollResize", this.resize), he.subscribe(t(this, Xe), Es.SCROLL + 1), this.scrollElement.onScroll(t(this, ke)), e = !0;
|
|
1033
1349
|
}
|
|
1034
1350
|
disconnectedCallback() {
|
|
1035
|
-
|
|
1351
|
+
he.unsubscribe(t(this, Xe)), this.scrollElement.offScroll(t(this, ke)), this.scrollElement.removeEventListener(
|
|
1036
1352
|
"scrollSectionsChange",
|
|
1037
1353
|
this.findAnotherScrollEntries
|
|
1038
|
-
), this.
|
|
1354
|
+
), this.scrollElement.removeEventListener("scrollResize", this.resize), t(this, Yt).close(), t(this, te).close(), t(this, ee).close(), t(this, se).close(), t(this, Vt).close(), t(this, kt).close(), t(this, At).close(), t(this, It).close(), t(this, A).close(), t(this, $).close(), t(this, H).close(), t(this, W).close(), t(this, Mt).close(), t(this, z).close(), t(this, nt).close(), t(this, ot).close(), t(this, j).close(), t(this, Ft).close(), t(this, lt).close(), t(this, ct).close(), t(this, ut).close(), t(this, E).close(), t(this, B).close(), t(this, N).close(), t(this, J).close(), t(this, Q).close(), t(this, U).close(), this.disable(), t(this, x).close();
|
|
1355
|
+
}
|
|
1356
|
+
removeVar(e) {
|
|
1357
|
+
e && t(this, S).style.removeProperty(`--${e}`);
|
|
1358
|
+
}
|
|
1359
|
+
setVar(e, s) {
|
|
1360
|
+
if (e) {
|
|
1361
|
+
const h = typeof s == "number" ? s.toFixed(6) : s;
|
|
1362
|
+
t(this, S).style.setProperty(`--${e}`, h);
|
|
1363
|
+
}
|
|
1364
|
+
}
|
|
1365
|
+
getDistance() {
|
|
1366
|
+
return t(this, ie) + t(this, Qe);
|
|
1367
|
+
}
|
|
1368
|
+
getStart() {
|
|
1369
|
+
return t(this, Tt) - t(this, Qe);
|
|
1039
1370
|
}
|
|
1040
1371
|
}
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1372
|
+
Yt = new WeakMap(), te = new WeakMap(), ee = new WeakMap(), se = new WeakMap(), Vt = new WeakMap(), kt = new WeakMap(), At = new WeakMap(), It = new WeakMap(), A = new WeakMap(), $ = new WeakMap(), H = new WeakMap(), W = new WeakMap(), Mt = new WeakMap(), z = new WeakMap(), nt = new WeakMap(), ot = new WeakMap(), j = new WeakMap(), Ft = new WeakMap(), ze = new WeakMap(), lt = new WeakMap(), ct = new WeakMap(), ut = new WeakMap(), E = new WeakMap(), B = new WeakMap(), N = new WeakMap(), J = new WeakMap(), Q = new WeakMap(), U = new WeakMap(), Je = new WeakMap(), S = new WeakMap(), Tt = new WeakMap(), ie = new WeakMap(), Qe = new WeakMap(), x = new WeakMap(), at = new WeakMap(), F = new WeakMap(), I = new WeakMap(), K = new WeakMap(), Ve = new WeakMap(), Rt = new WeakMap(), y = new WeakMap(), re = new WeakMap(), m = new WeakSet(), Js = function() {
|
|
1373
|
+
t(this, E).current = !0, t(this, B).current = !1, r(this, Rt, !0), t(this, $).current && t(this, S).classList.remove(t(this, $).current), t(this, z).current && t(this, S).classList.remove(
|
|
1374
|
+
t(this, z).current
|
|
1375
|
+
), t(this, z).current && t(this, S).classList.remove(
|
|
1376
|
+
t(this, z).current
|
|
1377
|
+
), t(this, A).current && t(this, S).classList.add(t(this, A).current);
|
|
1378
|
+
}, Qs = function() {
|
|
1379
|
+
t(this, B).current = !0, t(this, E).current = !1, r(this, Rt, !0), t(this, A).current && t(this, S).classList.remove(t(this, A).current), t(this, H).current && t(this, S).classList.remove(
|
|
1380
|
+
t(this, H).current
|
|
1381
|
+
), t(this, W).current && t(this, S).classList.remove(
|
|
1382
|
+
t(this, W).current
|
|
1383
|
+
), t(this, $).current && t(this, S).classList.add(t(this, $).current);
|
|
1384
|
+
}, Xs = function() {
|
|
1385
|
+
t(this, E).current = !0, t(this, N).current = !0, t(this, J).current = !1, t(this, H).current && t(this, S).classList.add(
|
|
1386
|
+
t(this, H).current
|
|
1387
|
+
);
|
|
1388
|
+
}, Ys = function() {
|
|
1389
|
+
t(this, E).current = !0, t(this, Q).current = !0, t(this, U).current = !1, t(this, W).current && t(this, S).classList.add(
|
|
1390
|
+
t(this, W).current
|
|
1391
|
+
);
|
|
1392
|
+
}, ti = function() {
|
|
1393
|
+
t(this, B).current = !0, t(this, J).current = !0, t(this, N).current = !1, t(this, z).current && t(this, S).classList.add(
|
|
1394
|
+
t(this, z).current
|
|
1395
|
+
);
|
|
1396
|
+
}, ei = function() {
|
|
1397
|
+
t(this, B).current = !0, t(this, U).current = !0, t(this, Q).current = !1, t(this, z).current && t(this, S).classList.add(
|
|
1398
|
+
t(this, z).current
|
|
1399
|
+
);
|
|
1400
|
+
}, Xe = new WeakMap(), ke = new WeakMap(), Ms = function() {
|
|
1401
|
+
const e = t(this, x)[t(this, ze).current];
|
|
1402
|
+
this.setVar(t(this, nt).current, e), r(this, at, e / t(this, I) || 0), this.setVar(t(this, ot).current, t(this, at)), t(this, j).current && this.setVar(t(this, j).current, this.progressArc);
|
|
1403
|
+
}, ue = function(e) {
|
|
1404
|
+
if (t(this, y)) {
|
|
1405
|
+
e.previous && t(this, S).classList.remove(e.previous), e.current && t(this, S).classList.remove(e.current);
|
|
1406
|
+
return;
|
|
1407
|
+
}
|
|
1408
|
+
e.current && t(this, E).current ? (e.previous && t(this, S).classList.remove(e.previous), t(this, S).classList.add(e.current)) : !e.current && e.previous && t(this, S).classList.remove(e.previous);
|
|
1409
|
+
}, si = function(...e) {
|
|
1410
|
+
e.forEach((s) => {
|
|
1411
|
+
s && t(this, S).classList.remove(s);
|
|
1412
|
+
});
|
|
1413
|
+
}, ii = function(...e) {
|
|
1414
|
+
e.forEach((s) => {
|
|
1415
|
+
s && t(this, S).style.removeProperty(`--${s}`);
|
|
1416
|
+
});
|
|
1417
|
+
}, Fs = function() {
|
|
1418
|
+
o(this, m, si).call(this, t(this, A).current, t(this, H).current, t(this, W).current, t(this, $).current, t(this, Mt).current, t(this, z).current), o(this, m, ii).call(this, t(this, nt).current, t(this, ot).current, t(this, j).current, t(this, lt).current, t(this, ct).current, t(this, ut).current);
|
|
1419
|
+
};
|
|
1420
|
+
Y && !customElements.get("e-scroll-segment") && customElements.define("e-scroll-segment", Ai);
|
|
1421
|
+
var Ss;
|
|
1422
|
+
const Rs = class Rs extends gs {
|
|
1044
1423
|
constructor() {
|
|
1045
1424
|
super(...arguments);
|
|
1046
|
-
|
|
1425
|
+
i(this, Ss, () => {
|
|
1047
1426
|
this.textContent = `${this.scrollElement.counter.current + 1}`;
|
|
1048
1427
|
});
|
|
1049
1428
|
}
|
|
1050
1429
|
connectedCallback() {
|
|
1051
|
-
return
|
|
1052
|
-
|
|
1430
|
+
return Bs(this, null, function* () {
|
|
1431
|
+
Ws(Rs.prototype, this, "connectedCallback").call(this), this.scrollElement.counter.subscribe(t(this, Ss));
|
|
1053
1432
|
});
|
|
1054
1433
|
}
|
|
1055
1434
|
disconnectedCallback() {
|
|
1056
|
-
this.scrollElement.counter.unsubscribe(t(this,
|
|
1435
|
+
this.scrollElement.counter.unsubscribe(t(this, Ss));
|
|
1057
1436
|
}
|
|
1058
1437
|
};
|
|
1059
|
-
|
|
1060
|
-
let
|
|
1061
|
-
|
|
1438
|
+
Ss = new WeakMap();
|
|
1439
|
+
let Ts = Rs;
|
|
1440
|
+
Y && !customElements.get("e-scroll-counter") && customElements.define("e-scroll-counter", Ts);
|
|
1062
1441
|
export {
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1442
|
+
ki as ScrollBulletButtonsElement,
|
|
1443
|
+
Ts as ScrollCounterElement,
|
|
1444
|
+
Ls as ScrollElement,
|
|
1445
|
+
Ai as ScrollSegmentElement,
|
|
1446
|
+
Li as ScrollSetButtonElement,
|
|
1447
|
+
zi as ScrollStepButtonElement,
|
|
1448
|
+
xi as ScrollbarElement
|
|
1070
1449
|
};
|