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