@ssgoi/core 4.3.0 → 4.3.2
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/dist/animator/runner/provider.d.ts +2 -2
- package/dist/animator/runner/provider.d.ts.map +1 -1
- package/dist/animator/single-animator.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +404 -366
- package/dist/ssgoi-transition/create-context-manager.d.ts +11 -1
- package/dist/ssgoi-transition/create-context-manager.d.ts.map +1 -1
- package/dist/ssgoi-transition/create-swipe-detector.d.ts.map +1 -1
- package/dist/transition/create-transition-callback.d.ts.map +1 -1
- package/dist/types.cjs +1 -1
- package/dist/types.d.ts +11 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +10 -8
- package/dist/view-transitions/drill.d.ts.map +1 -1
- package/dist/view-transitions/index.cjs +9 -9
- package/dist/view-transitions/index.js +217 -217
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { normalizeToMultiAnimation as
|
|
5
|
-
import { isCssAnimation as
|
|
6
|
-
import { S as
|
|
7
|
-
class
|
|
1
|
+
var et = Object.defineProperty;
|
|
2
|
+
var it = (e, n, t) => n in e ? et(e, n, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[n] = t;
|
|
3
|
+
var d = (e, n, t) => it(e, typeof n != "symbol" ? n + "" : n, t);
|
|
4
|
+
import { normalizeToMultiAnimation as M, normalizeSchedule as H } from "./types.js";
|
|
5
|
+
import { isCssAnimation as Ut, isMultiAnimation as Xt, isSingleAnimation as Yt, isTickAnimation as Ht } from "./types.js";
|
|
6
|
+
import { S as K, I as nt, a as rt } from "./provider-Cu4NSF1Q.js";
|
|
7
|
+
class ot {
|
|
8
8
|
constructor() {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
d(this, "listeners", /* @__PURE__ */ new Set());
|
|
10
|
+
d(this, "rafId", null);
|
|
11
|
+
d(this, "isRunning", !1);
|
|
12
12
|
// Timing
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
d(this, "startTime", Date.now());
|
|
14
|
+
d(this, "lastUpdate", this.startTime);
|
|
15
|
+
d(this, "elapsed", 0);
|
|
16
16
|
// Lag smoothing (mobile optimization)
|
|
17
|
-
|
|
17
|
+
d(this, "lagThreshold", 500);
|
|
18
18
|
// ms - detect tab switches, backgrounding
|
|
19
|
-
|
|
19
|
+
d(this, "adjustedLag", 33);
|
|
20
20
|
// ms - max time jump to prevent animation skip
|
|
21
|
-
|
|
21
|
+
d(this, "maxDeltaTime", 33);
|
|
22
22
|
// ms - clamp for physics stability (30fps minimum)
|
|
23
23
|
// FPS throttling
|
|
24
|
-
|
|
24
|
+
d(this, "gap", 1e3 / 240);
|
|
25
25
|
// max 240fps
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
d(this, "nextTime", this.gap);
|
|
27
|
+
d(this, "tick", () => {
|
|
28
28
|
const n = Date.now();
|
|
29
29
|
let i = n - this.lastUpdate;
|
|
30
30
|
i > this.lagThreshold || i < 0 ? (this.startTime += i - this.adjustedLag, i = this.adjustedLag) : i > this.maxDeltaTime && (i = this.maxDeltaTime), this.lastUpdate = n;
|
|
31
31
|
const r = n - this.startTime, o = r - this.nextTime;
|
|
32
32
|
if (o > 0) {
|
|
33
|
-
const
|
|
34
|
-
this.elapsed = r / 1e3, this.nextTime += o + (o >= this.gap ? 4 : this.gap - o), this.listeners.forEach((
|
|
35
|
-
|
|
33
|
+
const l = i / 1e3;
|
|
34
|
+
this.elapsed = r / 1e3, this.nextTime += o + (o >= this.gap ? 4 : this.gap - o), this.listeners.forEach((f) => {
|
|
35
|
+
f(l, this.elapsed);
|
|
36
36
|
});
|
|
37
37
|
}
|
|
38
38
|
this.listeners.size > 0 ? this.rafId = requestAnimationFrame(this.tick) : (this.isRunning = !1, this.rafId = null);
|
|
@@ -68,64 +68,64 @@ class rt {
|
|
|
68
68
|
return this.elapsed;
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
|
-
const
|
|
72
|
-
function
|
|
71
|
+
const N = new ot();
|
|
72
|
+
function st(e) {
|
|
73
73
|
const {
|
|
74
74
|
integrator: n,
|
|
75
75
|
from: t,
|
|
76
76
|
to: i,
|
|
77
77
|
velocity: r = 0,
|
|
78
78
|
onUpdate: o,
|
|
79
|
-
onComplete:
|
|
80
|
-
onStart:
|
|
79
|
+
onComplete: l,
|
|
80
|
+
onStart: f
|
|
81
81
|
} = e;
|
|
82
|
-
let
|
|
83
|
-
const
|
|
84
|
-
if (
|
|
85
|
-
if (
|
|
86
|
-
if (
|
|
87
|
-
|
|
82
|
+
let a = { position: t, velocity: r }, m = !0, y = 0, S = !1;
|
|
83
|
+
const C = (A) => {
|
|
84
|
+
if (m) {
|
|
85
|
+
if (S || (S = !0, f == null || f()), a = n.step(a, i, A), n.isSettled(a, i)) {
|
|
86
|
+
if (y += Math.min(A, 0.033), y >= K) {
|
|
87
|
+
a = { position: i, velocity: 0 }, m = !1, o(a.position), N.unsubscribe(C), l();
|
|
88
88
|
return;
|
|
89
89
|
}
|
|
90
90
|
} else
|
|
91
|
-
|
|
92
|
-
o(
|
|
91
|
+
y = 0;
|
|
92
|
+
o(a.position);
|
|
93
93
|
}
|
|
94
94
|
};
|
|
95
|
-
return
|
|
95
|
+
return N.subscribe(C), {
|
|
96
96
|
stop: () => {
|
|
97
|
-
|
|
97
|
+
m && (m = !1, N.unsubscribe(C));
|
|
98
98
|
},
|
|
99
|
-
getPosition: () =>
|
|
100
|
-
getVelocity: () =>
|
|
101
|
-
isRunning: () =>
|
|
99
|
+
getPosition: () => a.position,
|
|
100
|
+
getVelocity: () => a.velocity,
|
|
101
|
+
isRunning: () => m
|
|
102
102
|
};
|
|
103
103
|
}
|
|
104
|
-
const
|
|
105
|
-
function
|
|
106
|
-
let o = { position: n, velocity: i },
|
|
107
|
-
const
|
|
108
|
-
for (let
|
|
109
|
-
const
|
|
110
|
-
if (
|
|
111
|
-
time:
|
|
104
|
+
const O = 1e3 / 60;
|
|
105
|
+
function at(e, n, t, i = 0) {
|
|
106
|
+
let o = { position: n, velocity: i }, l = 0;
|
|
107
|
+
const f = [];
|
|
108
|
+
for (let a = 0; a < 600; a++) {
|
|
109
|
+
const m = a * O;
|
|
110
|
+
if (f.push({
|
|
111
|
+
time: m,
|
|
112
112
|
position: o.position,
|
|
113
113
|
velocity: o.velocity
|
|
114
|
-
}), o = e.step(o, t,
|
|
115
|
-
if (
|
|
116
|
-
|
|
117
|
-
time: (
|
|
114
|
+
}), o = e.step(o, t, O / 1e3), e.isSettled(o, t)) {
|
|
115
|
+
if (l += O / 1e3, l >= K) {
|
|
116
|
+
f.push({
|
|
117
|
+
time: (a + 1) * O,
|
|
118
118
|
position: t,
|
|
119
119
|
velocity: 0
|
|
120
120
|
});
|
|
121
121
|
break;
|
|
122
122
|
}
|
|
123
123
|
} else
|
|
124
|
-
|
|
124
|
+
l = 0;
|
|
125
125
|
}
|
|
126
|
-
return
|
|
126
|
+
return f;
|
|
127
127
|
}
|
|
128
|
-
function
|
|
128
|
+
function j(e, n) {
|
|
129
129
|
if (e.length === 0)
|
|
130
130
|
return { position: 0, velocity: 0 };
|
|
131
131
|
const t = e[0], i = e[e.length - 1];
|
|
@@ -135,105 +135,115 @@ function Y(e, n) {
|
|
|
135
135
|
return { position: i.position, velocity: i.velocity };
|
|
136
136
|
let r = 0, o = e.length - 1;
|
|
137
137
|
for (; r < o - 1; ) {
|
|
138
|
-
const
|
|
139
|
-
e[
|
|
138
|
+
const m = Math.floor((r + o) / 2);
|
|
139
|
+
e[m].time <= n ? r = m : o = m;
|
|
140
140
|
}
|
|
141
|
-
const
|
|
141
|
+
const l = e[r], f = e[o], a = (n - l.time) / (f.time - l.time);
|
|
142
142
|
return {
|
|
143
|
-
position:
|
|
144
|
-
velocity:
|
|
143
|
+
position: l.position + (f.position - l.position) * a,
|
|
144
|
+
velocity: l.velocity + (f.velocity - l.velocity) * a
|
|
145
145
|
};
|
|
146
146
|
}
|
|
147
|
-
function
|
|
147
|
+
function ct(e, n) {
|
|
148
148
|
return e.map((t) => n(t.position));
|
|
149
149
|
}
|
|
150
|
-
function
|
|
150
|
+
function lt(e) {
|
|
151
151
|
const {
|
|
152
152
|
integrator: n,
|
|
153
153
|
element: t,
|
|
154
154
|
from: i,
|
|
155
155
|
to: r,
|
|
156
156
|
velocity: o = 0,
|
|
157
|
-
style:
|
|
158
|
-
onComplete:
|
|
159
|
-
onStart:
|
|
160
|
-
} = e,
|
|
161
|
-
if (
|
|
162
|
-
return
|
|
157
|
+
style: l,
|
|
158
|
+
onComplete: f,
|
|
159
|
+
onStart: a
|
|
160
|
+
} = e, m = at(n, i, r, o);
|
|
161
|
+
if (m.length === 0)
|
|
162
|
+
return a == null || a(), f(), {
|
|
163
163
|
stop: () => {
|
|
164
164
|
},
|
|
165
165
|
getPosition: () => r,
|
|
166
166
|
getVelocity: () => 0,
|
|
167
167
|
isRunning: () => !1
|
|
168
168
|
};
|
|
169
|
-
const
|
|
170
|
-
if (
|
|
171
|
-
for (const
|
|
172
|
-
t.style[
|
|
173
|
-
const
|
|
174
|
-
duration:
|
|
169
|
+
const y = ct(m, l), S = m[m.length - 1], C = S.time, A = y[0];
|
|
170
|
+
if (A)
|
|
171
|
+
for (const h of Object.keys(A))
|
|
172
|
+
t.style[h] = "";
|
|
173
|
+
const c = t.animate(y, {
|
|
174
|
+
duration: C,
|
|
175
175
|
fill: "forwards",
|
|
176
176
|
easing: "linear",
|
|
177
177
|
composite: "replace"
|
|
178
178
|
});
|
|
179
|
-
let
|
|
180
|
-
const
|
|
181
|
-
return
|
|
182
|
-
|
|
179
|
+
let s = !0;
|
|
180
|
+
const g = performance.now();
|
|
181
|
+
return a == null || a(), c.onfinish = () => {
|
|
182
|
+
s && (s = !1, f());
|
|
183
183
|
}, {
|
|
184
184
|
stop: () => {
|
|
185
|
-
|
|
185
|
+
s && (s = !1, c.cancel());
|
|
186
186
|
},
|
|
187
187
|
getPosition: () => {
|
|
188
|
-
if (!
|
|
189
|
-
return
|
|
190
|
-
const
|
|
191
|
-
return
|
|
188
|
+
if (!s)
|
|
189
|
+
return S.position;
|
|
190
|
+
const h = performance.now() - g;
|
|
191
|
+
return j(m, h).position;
|
|
192
192
|
},
|
|
193
193
|
getVelocity: () => {
|
|
194
|
-
if (!
|
|
194
|
+
if (!s)
|
|
195
195
|
return 0;
|
|
196
|
-
const
|
|
197
|
-
return
|
|
196
|
+
const h = performance.now() - g;
|
|
197
|
+
return j(m, h).velocity;
|
|
198
|
+
},
|
|
199
|
+
isRunning: () => s
|
|
200
|
+
};
|
|
201
|
+
}
|
|
202
|
+
function ut(e) {
|
|
203
|
+
const { to: n, onStart: t, onComplete: i } = e;
|
|
204
|
+
return t == null || t(), i(), {
|
|
205
|
+
stop: () => {
|
|
198
206
|
},
|
|
199
|
-
|
|
207
|
+
getPosition: () => n,
|
|
208
|
+
getVelocity: () => 0,
|
|
209
|
+
isRunning: () => !1
|
|
200
210
|
};
|
|
201
211
|
}
|
|
202
|
-
class
|
|
212
|
+
class ft {
|
|
203
213
|
/**
|
|
204
214
|
* Get bound runner based on animation mode
|
|
205
215
|
*
|
|
206
216
|
* @param options Animation mode options (tick or css)
|
|
207
|
-
* @returns Bound runner function
|
|
217
|
+
* @returns Bound runner function (empty runner if no animation mode specified)
|
|
208
218
|
* @throws Error if both tick and css are provided
|
|
209
219
|
*/
|
|
210
220
|
static from(n) {
|
|
211
221
|
const { tick: t, css: i } = n;
|
|
212
222
|
if (t && i)
|
|
213
223
|
throw new Error("Cannot use both 'tick' and 'css' options together");
|
|
214
|
-
return i ? (r) =>
|
|
224
|
+
return i ? (r) => lt({
|
|
215
225
|
...r,
|
|
216
226
|
element: i.element,
|
|
217
227
|
style: i.style
|
|
218
|
-
}) : t ? (r) =>
|
|
228
|
+
}) : t ? (r) => st({
|
|
219
229
|
...r,
|
|
220
230
|
onUpdate: t
|
|
221
|
-
}) :
|
|
231
|
+
}) : ut;
|
|
222
232
|
}
|
|
223
233
|
}
|
|
224
|
-
class
|
|
234
|
+
class B {
|
|
225
235
|
}
|
|
226
|
-
const
|
|
227
|
-
class
|
|
236
|
+
const mt = { stiffness: 300, damping: 30 };
|
|
237
|
+
class W extends B {
|
|
228
238
|
constructor(t) {
|
|
229
239
|
super();
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
240
|
+
d(this, "options");
|
|
241
|
+
d(this, "runner");
|
|
242
|
+
d(this, "controls", null);
|
|
243
|
+
d(this, "isAnimating", !1);
|
|
244
|
+
d(this, "currentValue");
|
|
245
|
+
d(this, "currentVelocity", 0);
|
|
246
|
+
d(this, "updateFn");
|
|
237
247
|
if (this.options = {
|
|
238
248
|
from: t.from ?? 0,
|
|
239
249
|
to: t.to ?? 1,
|
|
@@ -249,14 +259,14 @@ class j extends K {
|
|
|
249
259
|
else if (t.css) {
|
|
250
260
|
const { element: i, style: r } = t.css;
|
|
251
261
|
this.updateFn = (o) => {
|
|
252
|
-
const
|
|
253
|
-
for (const [
|
|
254
|
-
i.style[
|
|
262
|
+
const l = r(o);
|
|
263
|
+
for (const [f, a] of Object.entries(l))
|
|
264
|
+
i.style[f] = typeof a == "number" ? String(a) : a;
|
|
255
265
|
};
|
|
256
266
|
} else
|
|
257
267
|
this.updateFn = () => {
|
|
258
268
|
};
|
|
259
|
-
this.runner =
|
|
269
|
+
this.runner = ft.from({
|
|
260
270
|
tick: t.tick,
|
|
261
271
|
css: t.css
|
|
262
272
|
});
|
|
@@ -275,18 +285,13 @@ class j extends K {
|
|
|
275
285
|
*/
|
|
276
286
|
createIntegrator() {
|
|
277
287
|
const t = this.options.physics;
|
|
278
|
-
return t != null && t.integrator ? t.integrator() : t != null && t.spring || t != null && t.inertia ?
|
|
288
|
+
return t != null && t.integrator ? t.integrator() : t != null && t.spring || t != null && t.inertia ? nt.from({
|
|
279
289
|
spring: t.spring,
|
|
280
290
|
inertia: t.inertia
|
|
281
|
-
}) : new
|
|
291
|
+
}) : new rt(mt);
|
|
282
292
|
}
|
|
283
293
|
runAnimation(t) {
|
|
284
|
-
|
|
285
|
-
if (this.isAnimating = !0, !this.runner) {
|
|
286
|
-
(r = (i = this.options).onStart) == null || r.call(i), this.currentValue = t, this.currentVelocity = 0, this.isAnimating = !1, this.options.onComplete();
|
|
287
|
-
return;
|
|
288
|
-
}
|
|
289
|
-
this.controls = this.runner({
|
|
294
|
+
this.isAnimating = !0, this.controls = this.runner({
|
|
290
295
|
integrator: this.createIntegrator(),
|
|
291
296
|
from: this.currentValue,
|
|
292
297
|
to: t,
|
|
@@ -339,20 +344,20 @@ class j extends K {
|
|
|
339
344
|
this.options = { ...this.options, ...t };
|
|
340
345
|
}
|
|
341
346
|
}
|
|
342
|
-
class
|
|
347
|
+
class z extends B {
|
|
343
348
|
constructor(t) {
|
|
344
349
|
super();
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
350
|
+
d(this, "config");
|
|
351
|
+
d(this, "animators", /* @__PURE__ */ new Map());
|
|
352
|
+
d(this, "itemOrder", []);
|
|
353
|
+
d(this, "completedCount", 0);
|
|
354
|
+
d(this, "completedAnimators", /* @__PURE__ */ new Set());
|
|
355
|
+
d(this, "direction", "forward");
|
|
356
|
+
d(this, "idCounter", 0);
|
|
357
|
+
d(this, "rafId", null);
|
|
358
|
+
d(this, "from");
|
|
359
|
+
d(this, "to");
|
|
360
|
+
d(this, "initialState");
|
|
356
361
|
this.config = t.config, this.from = t.from, this.to = t.to, this.initialState = t.state ?? {
|
|
357
362
|
position: t.from,
|
|
358
363
|
velocity: 0
|
|
@@ -363,7 +368,7 @@ class L extends K {
|
|
|
363
368
|
}
|
|
364
369
|
initializeAnimators() {
|
|
365
370
|
this.config.items.forEach((t, i) => {
|
|
366
|
-
const r = this.generateId(), o = new
|
|
371
|
+
const r = this.generateId(), o = new W({
|
|
367
372
|
from: this.from,
|
|
368
373
|
to: this.to,
|
|
369
374
|
physics: t.physics,
|
|
@@ -397,9 +402,9 @@ class L extends K {
|
|
|
397
402
|
return this.direction === "forward" ? this.itemOrder : [...this.itemOrder].reverse();
|
|
398
403
|
}
|
|
399
404
|
onAnimatorComplete(t) {
|
|
400
|
-
var r, o,
|
|
405
|
+
var r, o, l, f, a, m;
|
|
401
406
|
const i = this.animators.get(t);
|
|
402
|
-
!i || this.completedAnimators.has(t) || (this.completedAnimators.add(t), this.completedCount++, (o = (r = i.item).onComplete) == null || o.call(r), (
|
|
407
|
+
!i || this.completedAnimators.has(t) || (this.completedAnimators.add(t), this.completedCount++, (o = (r = i.item).onComplete) == null || o.call(r), (f = (l = this.config).onProgress) == null || f.call(l, this.completedCount, this.config.items.length), this.completedCount === this.config.items.length && (this.stopScheduler(), (m = (a = this.config).onEnd) == null || m.call(a)));
|
|
403
408
|
}
|
|
404
409
|
/**
|
|
405
410
|
* Check and start springs based on previous spring's progress
|
|
@@ -414,10 +419,10 @@ class L extends K {
|
|
|
414
419
|
this.startAnimator(r);
|
|
415
420
|
continue;
|
|
416
421
|
}
|
|
417
|
-
const
|
|
418
|
-
if (!
|
|
419
|
-
const
|
|
420
|
-
|
|
422
|
+
const l = t[i - 1], f = this.animators.get(l);
|
|
423
|
+
if (!f || !f.started) continue;
|
|
424
|
+
const a = this.getAnimatorProgress(f), m = o.item.normalizedOffset;
|
|
425
|
+
a >= m && this.startAnimator(r);
|
|
421
426
|
}
|
|
422
427
|
}
|
|
423
428
|
startAnimator(t) {
|
|
@@ -465,7 +470,7 @@ class L extends K {
|
|
|
465
470
|
return;
|
|
466
471
|
const i = t.animator.getCurrentState();
|
|
467
472
|
if (i.position === i.to) {
|
|
468
|
-
const o = new
|
|
473
|
+
const o = new W({
|
|
469
474
|
from: this.to,
|
|
470
475
|
to: this.from,
|
|
471
476
|
physics: t.item.physics,
|
|
@@ -532,10 +537,10 @@ class L extends K {
|
|
|
532
537
|
* Uses first animator's state for initialization
|
|
533
538
|
*/
|
|
534
539
|
static fromState(t, i) {
|
|
535
|
-
return new
|
|
540
|
+
return new z({ ...i, state: t });
|
|
536
541
|
}
|
|
537
542
|
}
|
|
538
|
-
const
|
|
543
|
+
const J = Symbol.for("TRANSITION_STRATEGY"), dt = (e) => ({
|
|
539
544
|
runIn: async (n) => {
|
|
540
545
|
const { currentAnimation: t } = e;
|
|
541
546
|
if (t && t.direction === "out") {
|
|
@@ -602,7 +607,7 @@ const B = Symbol.for("TRANSITION_STRATEGY"), ft = (e) => ({
|
|
|
602
607
|
direction: "forward"
|
|
603
608
|
};
|
|
604
609
|
}
|
|
605
|
-
}),
|
|
610
|
+
}), ht = () => ({
|
|
606
611
|
runIn: async (e) => e.in ? {
|
|
607
612
|
config: await e.in,
|
|
608
613
|
state: {
|
|
@@ -639,25 +644,25 @@ const B = Symbol.for("TRANSITION_STRATEGY"), ft = (e) => ({
|
|
|
639
644
|
to: 0,
|
|
640
645
|
direction: "forward"
|
|
641
646
|
}
|
|
642
|
-
}),
|
|
643
|
-
function
|
|
647
|
+
}), Q = "data-ssgoi-scope", Z = "data-ssgoi-scope-ready";
|
|
648
|
+
function xt() {
|
|
644
649
|
return (e) => {
|
|
645
650
|
if (e)
|
|
646
|
-
return e.setAttribute(
|
|
651
|
+
return e.setAttribute(Q, ""), queueMicrotask(() => {
|
|
647
652
|
queueMicrotask(() => {
|
|
648
|
-
e.setAttribute(
|
|
653
|
+
e.setAttribute(Z, "true");
|
|
649
654
|
});
|
|
650
655
|
}), () => {
|
|
651
656
|
};
|
|
652
657
|
};
|
|
653
658
|
}
|
|
654
|
-
function
|
|
655
|
-
return e.hasAttribute(
|
|
659
|
+
function gt(e) {
|
|
660
|
+
return e.hasAttribute(Z);
|
|
656
661
|
}
|
|
657
|
-
function
|
|
658
|
-
return e.closest(`[${
|
|
662
|
+
function pt(e) {
|
|
663
|
+
return e.closest(`[${Q}]`);
|
|
659
664
|
}
|
|
660
|
-
const
|
|
665
|
+
const wt = (e) => {
|
|
661
666
|
let n = e.parentElement;
|
|
662
667
|
for (; n && n !== document.body; ) {
|
|
663
668
|
const t = window.getComputedStyle(n), i = t.overflow + t.overflowY + t.overflowX;
|
|
@@ -666,7 +671,7 @@ const gt = (e) => {
|
|
|
666
671
|
n = n.parentElement;
|
|
667
672
|
}
|
|
668
673
|
return document.documentElement;
|
|
669
|
-
},
|
|
674
|
+
}, yt = (e) => {
|
|
670
675
|
let n = e.parentElement;
|
|
671
676
|
for (; n && n !== document.body; ) {
|
|
672
677
|
const t = window.getComputedStyle(n).position;
|
|
@@ -676,7 +681,7 @@ const gt = (e) => {
|
|
|
676
681
|
}
|
|
677
682
|
return document.body;
|
|
678
683
|
};
|
|
679
|
-
function
|
|
684
|
+
function G(e) {
|
|
680
685
|
return new Promise((n) => {
|
|
681
686
|
requestAnimationFrame(() => {
|
|
682
687
|
requestAnimationFrame(() => {
|
|
@@ -685,123 +690,123 @@ function W(e) {
|
|
|
685
690
|
});
|
|
686
691
|
});
|
|
687
692
|
}
|
|
688
|
-
function
|
|
689
|
-
var
|
|
693
|
+
function vt(e, n) {
|
|
694
|
+
var A;
|
|
690
695
|
let t = null, i = null, r = null, o = null;
|
|
691
|
-
const
|
|
696
|
+
const l = {
|
|
692
697
|
get currentAnimation() {
|
|
693
698
|
return t;
|
|
694
699
|
}
|
|
695
|
-
},
|
|
696
|
-
var
|
|
700
|
+
}, f = ((A = n == null ? void 0 : n.strategy) == null ? void 0 : A.call(n, l)) || dt(l), a = async (c) => {
|
|
701
|
+
var R, P;
|
|
697
702
|
i && (i.remove(), i = null);
|
|
698
|
-
const
|
|
699
|
-
if (!
|
|
703
|
+
const s = e(), g = s.in && s.in(c), h = !(n != null && n.strategy) && s.out ? s.out(c) : void 0;
|
|
704
|
+
if (!g)
|
|
700
705
|
return;
|
|
701
|
-
const
|
|
702
|
-
in:
|
|
703
|
-
out:
|
|
704
|
-
},
|
|
705
|
-
if (!
|
|
706
|
+
const T = {
|
|
707
|
+
in: M(g),
|
|
708
|
+
out: h ? M(h) : void 0
|
|
709
|
+
}, p = await f.runIn(T);
|
|
710
|
+
if (!p.config) {
|
|
706
711
|
t && (t.direction = "in");
|
|
707
712
|
return;
|
|
708
713
|
}
|
|
709
|
-
const
|
|
710
|
-
(
|
|
711
|
-
const
|
|
714
|
+
const u = p.config;
|
|
715
|
+
(R = u.prepare) == null || R.call(u);
|
|
716
|
+
const v = H(
|
|
712
717
|
{
|
|
713
|
-
...
|
|
718
|
+
...u,
|
|
714
719
|
onEnd: () => {
|
|
715
720
|
var k;
|
|
716
|
-
t = null, (k =
|
|
721
|
+
t = null, (k = u.onEnd) == null || k.call(u);
|
|
717
722
|
}
|
|
718
723
|
},
|
|
719
|
-
|
|
724
|
+
c
|
|
720
725
|
);
|
|
721
|
-
|
|
722
|
-
const
|
|
723
|
-
config:
|
|
724
|
-
from:
|
|
725
|
-
to:
|
|
726
|
+
u.wait && await u.wait();
|
|
727
|
+
const w = z.fromState(p.state, {
|
|
728
|
+
config: v,
|
|
729
|
+
from: p.from,
|
|
730
|
+
to: p.to
|
|
726
731
|
});
|
|
727
|
-
t = { controller:
|
|
728
|
-
},
|
|
729
|
-
var k;
|
|
730
|
-
i =
|
|
731
|
-
const
|
|
732
|
-
if (!
|
|
732
|
+
t = { controller: w, direction: "in" }, (P = u.onReady) == null || P.call(u), await G(), p.direction === "forward" ? w.forward() : w.backward();
|
|
733
|
+
}, m = async (c) => {
|
|
734
|
+
var P, k;
|
|
735
|
+
i = c;
|
|
736
|
+
const s = e(), g = !(n != null && n.strategy) && s.in ? s.in(c) : void 0, h = s.out && s.out(c);
|
|
737
|
+
if (!h)
|
|
733
738
|
return;
|
|
734
|
-
const
|
|
735
|
-
in:
|
|
736
|
-
out:
|
|
737
|
-
},
|
|
738
|
-
if (!
|
|
739
|
+
const T = {
|
|
740
|
+
in: g ? M(g) : void 0,
|
|
741
|
+
out: M(h)
|
|
742
|
+
}, p = await f.runOut(T);
|
|
743
|
+
if (!p.config) {
|
|
739
744
|
t && (t.direction = "out"), i && (i.remove(), i = null);
|
|
740
745
|
return;
|
|
741
746
|
}
|
|
742
|
-
const
|
|
743
|
-
|
|
744
|
-
const
|
|
747
|
+
const u = p.config;
|
|
748
|
+
R(), (P = u.prepare) == null || P.call(u);
|
|
749
|
+
const v = H(
|
|
745
750
|
{
|
|
746
|
-
...
|
|
751
|
+
...u,
|
|
747
752
|
onEnd: () => {
|
|
748
|
-
var V,
|
|
749
|
-
(V =
|
|
753
|
+
var V, F;
|
|
754
|
+
(V = u.onEnd) == null || V.call(u), i && (i.remove(), i = null), t = null, (F = n == null ? void 0 : n.onCleanupEnd) == null || F.call(n);
|
|
750
755
|
}
|
|
751
756
|
},
|
|
752
|
-
|
|
757
|
+
c
|
|
753
758
|
);
|
|
754
|
-
|
|
755
|
-
const
|
|
756
|
-
config:
|
|
757
|
-
from:
|
|
758
|
-
to:
|
|
759
|
+
u.wait && await u.wait();
|
|
760
|
+
const w = z.fromState(p.state, {
|
|
761
|
+
config: v,
|
|
762
|
+
from: p.from,
|
|
763
|
+
to: p.to
|
|
759
764
|
});
|
|
760
|
-
t = { controller:
|
|
761
|
-
function
|
|
765
|
+
t = { controller: w, direction: "out" }, (k = u.onReady) == null || k.call(u), await G(), p.direction === "forward" ? w.forward() : w.backward();
|
|
766
|
+
function R() {
|
|
762
767
|
!r || !i || (o && r.contains(o) ? r.insertBefore(i, o) : r.appendChild(i));
|
|
763
768
|
}
|
|
764
769
|
};
|
|
765
|
-
let
|
|
766
|
-
const
|
|
767
|
-
if (
|
|
768
|
-
|
|
769
|
-
const
|
|
770
|
-
|
|
771
|
-
document.contains(
|
|
772
|
-
}) :
|
|
770
|
+
let y = null, S = !1;
|
|
771
|
+
const C = (c) => () => {
|
|
772
|
+
if (S) return;
|
|
773
|
+
S = !0;
|
|
774
|
+
const s = c.cloneNode(!0);
|
|
775
|
+
y ? queueMicrotask(() => {
|
|
776
|
+
document.contains(y) && m(s);
|
|
777
|
+
}) : m(s);
|
|
773
778
|
};
|
|
774
|
-
return (
|
|
775
|
-
if (
|
|
779
|
+
return (c) => {
|
|
780
|
+
if (c)
|
|
776
781
|
return requestAnimationFrame(() => {
|
|
777
|
-
r =
|
|
778
|
-
}),
|
|
779
|
-
|
|
780
|
-
}) :
|
|
782
|
+
r = c.parentElement, o = c.nextElementSibling;
|
|
783
|
+
}), S = !1, (n == null ? void 0 : n.scope) === "local" ? queueMicrotask(() => {
|
|
784
|
+
y = pt(c), !(y && !gt(y)) && a(c);
|
|
785
|
+
}) : a(c), C(c);
|
|
781
786
|
};
|
|
782
787
|
}
|
|
783
|
-
const
|
|
784
|
-
let E = null,
|
|
785
|
-
function
|
|
786
|
-
if (e instanceof HTMLElement &&
|
|
787
|
-
const t =
|
|
788
|
-
|
|
788
|
+
const b = /* @__PURE__ */ new Map();
|
|
789
|
+
let E = null, U = !1;
|
|
790
|
+
function tt(e) {
|
|
791
|
+
if (e instanceof HTMLElement && b.has(e)) {
|
|
792
|
+
const t = b.get(e);
|
|
793
|
+
b.delete(e), queueMicrotask(() => {
|
|
789
794
|
t();
|
|
790
795
|
});
|
|
791
796
|
}
|
|
792
797
|
const n = e.childNodes;
|
|
793
798
|
for (let t = 0; t < n.length; t++) {
|
|
794
799
|
const i = n[t];
|
|
795
|
-
i &&
|
|
800
|
+
i && tt(i);
|
|
796
801
|
}
|
|
797
802
|
}
|
|
798
|
-
function
|
|
799
|
-
|
|
803
|
+
function St() {
|
|
804
|
+
U || typeof document > "u" || (U = !0, E = new MutationObserver((e) => {
|
|
800
805
|
for (const n of e) {
|
|
801
806
|
const t = n.removedNodes;
|
|
802
807
|
for (let i = 0; i < t.length; i++) {
|
|
803
808
|
const r = t[i];
|
|
804
|
-
r &&
|
|
809
|
+
r && tt(r);
|
|
805
810
|
}
|
|
806
811
|
}
|
|
807
812
|
}), document.body ? E.observe(document.body, {
|
|
@@ -818,69 +823,69 @@ function yt() {
|
|
|
818
823
|
{ once: !0 }
|
|
819
824
|
));
|
|
820
825
|
}
|
|
821
|
-
function
|
|
822
|
-
|
|
826
|
+
function Ct(e, n) {
|
|
827
|
+
St(), b.set(e, n);
|
|
823
828
|
}
|
|
824
|
-
function
|
|
825
|
-
return
|
|
829
|
+
function Mt(e) {
|
|
830
|
+
return b.has(e);
|
|
826
831
|
}
|
|
827
|
-
function
|
|
828
|
-
return
|
|
832
|
+
function Ot() {
|
|
833
|
+
return b.size;
|
|
829
834
|
}
|
|
830
|
-
function
|
|
831
|
-
const n =
|
|
832
|
-
return n ? (
|
|
835
|
+
function Lt(e) {
|
|
836
|
+
const n = b.get(e);
|
|
837
|
+
return n ? (b.delete(e), n(), !0) : !1;
|
|
833
838
|
}
|
|
834
|
-
function
|
|
835
|
-
|
|
839
|
+
function Dt() {
|
|
840
|
+
b.clear(), E == null || E.disconnect(), E = null, U = !1;
|
|
836
841
|
}
|
|
837
|
-
const
|
|
838
|
-
function
|
|
839
|
-
|
|
840
|
-
let i =
|
|
842
|
+
const D = /* @__PURE__ */ new Map(), X = /* @__PURE__ */ new Map(), Y = /* @__PURE__ */ new Map();
|
|
843
|
+
function At(e, n, t) {
|
|
844
|
+
D.set(e, n);
|
|
845
|
+
let i = X.get(e);
|
|
841
846
|
if (i)
|
|
842
847
|
return i;
|
|
843
848
|
const r = n;
|
|
844
|
-
return i =
|
|
849
|
+
return i = vt(
|
|
845
850
|
() => {
|
|
846
|
-
const o =
|
|
851
|
+
const o = D.get(e);
|
|
847
852
|
return o || (console.warn(`Transition "${String(e)}" not found`), {});
|
|
848
853
|
},
|
|
849
854
|
{
|
|
850
855
|
strategy: t == null ? void 0 : t.strategy,
|
|
851
856
|
scope: t == null ? void 0 : t.scope,
|
|
852
857
|
onCleanupEnd: () => {
|
|
853
|
-
|
|
858
|
+
D.get(e) === r && Tt(e);
|
|
854
859
|
}
|
|
855
860
|
}
|
|
856
|
-
),
|
|
861
|
+
), X.set(e, i), i;
|
|
857
862
|
}
|
|
858
|
-
function
|
|
859
|
-
|
|
863
|
+
function Tt(e) {
|
|
864
|
+
D.delete(e), X.delete(e), Y.delete(e);
|
|
860
865
|
}
|
|
861
|
-
function
|
|
862
|
-
const t =
|
|
866
|
+
function zt(e, n = "manual") {
|
|
867
|
+
const t = At(
|
|
863
868
|
e.key,
|
|
864
869
|
{
|
|
865
870
|
in: e.in,
|
|
866
871
|
out: e.out
|
|
867
872
|
},
|
|
868
873
|
{
|
|
869
|
-
strategy: e[
|
|
874
|
+
strategy: e[J],
|
|
870
875
|
scope: e.scope
|
|
871
876
|
}
|
|
872
877
|
);
|
|
873
878
|
if (n === "manual")
|
|
874
879
|
return t;
|
|
875
|
-
let i =
|
|
880
|
+
let i = Y.get(e.key);
|
|
876
881
|
return i || (i = (r) => {
|
|
877
882
|
if (r) {
|
|
878
883
|
const o = t(r);
|
|
879
|
-
o &&
|
|
884
|
+
o && Ct(r, o);
|
|
880
885
|
}
|
|
881
|
-
},
|
|
886
|
+
}, Y.set(e.key, i), i);
|
|
882
887
|
}
|
|
883
|
-
function
|
|
888
|
+
function Et(e) {
|
|
884
889
|
const n = e.filter((t) => t.symmetric).map((t) => ({
|
|
885
890
|
from: t.to,
|
|
886
891
|
to: t.from,
|
|
@@ -888,64 +893,89 @@ function At(e) {
|
|
|
888
893
|
}));
|
|
889
894
|
return [...e, ...n];
|
|
890
895
|
}
|
|
891
|
-
function
|
|
896
|
+
function bt(e) {
|
|
892
897
|
let n = !1, t = 0, i = 0, r = !1;
|
|
893
|
-
const o = 50,
|
|
898
|
+
const o = 50, l = (c) => {
|
|
894
899
|
if (!e) return;
|
|
895
|
-
const
|
|
896
|
-
|
|
897
|
-
},
|
|
900
|
+
const s = c.touches[0];
|
|
901
|
+
s && (r = s.clientX < o, r && (t = s.clientX, i = s.clientY));
|
|
902
|
+
}, f = (c) => {
|
|
898
903
|
if (!e || !r) return;
|
|
899
|
-
const
|
|
900
|
-
if (!
|
|
901
|
-
const
|
|
902
|
-
|
|
903
|
-
},
|
|
904
|
+
const s = c.touches[0];
|
|
905
|
+
if (!s) return;
|
|
906
|
+
const g = s.clientX - t, h = s.clientY - i;
|
|
907
|
+
g > window.outerWidth / 2 - 5 && Math.abs(g) > Math.abs(h) ? n = !0 : n = !1;
|
|
908
|
+
}, a = () => {
|
|
904
909
|
e && (r = !1, t = 0, i = 0);
|
|
905
|
-
},
|
|
906
|
-
typeof window > "u" || e && (window.addEventListener("touchstart",
|
|
907
|
-
},
|
|
908
|
-
typeof window > "u" || (window.removeEventListener("touchstart",
|
|
910
|
+
}, m = () => n, y = () => {
|
|
911
|
+
typeof window > "u" || e && (window.addEventListener("touchstart", l, { passive: !0 }), window.addEventListener("touchmove", f, { passive: !0 }), window.addEventListener("touchend", a, { passive: !0 }));
|
|
912
|
+
}, S = () => {
|
|
913
|
+
typeof window > "u" || (window.removeEventListener("touchstart", l), window.removeEventListener("touchmove", f), window.removeEventListener("touchend", a));
|
|
909
914
|
};
|
|
910
|
-
let
|
|
915
|
+
let C = 0;
|
|
911
916
|
return {
|
|
912
|
-
initialize:
|
|
913
|
-
cleanup:
|
|
914
|
-
isSwipePending:
|
|
917
|
+
initialize: y,
|
|
918
|
+
cleanup: S,
|
|
919
|
+
isSwipePending: m,
|
|
915
920
|
resetSwipeDetection: () => {
|
|
916
|
-
|
|
921
|
+
requestAnimationFrame(() => {
|
|
922
|
+
C++, C > 1 && (C = 0, n = !1);
|
|
923
|
+
});
|
|
917
924
|
}
|
|
918
925
|
};
|
|
919
926
|
}
|
|
920
|
-
function
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
927
|
+
function Rt(e = {}) {
|
|
928
|
+
const { preserveScroll: n = !1 } = e;
|
|
929
|
+
let t = null, i = null;
|
|
930
|
+
const r = /* @__PURE__ */ new Map();
|
|
931
|
+
let o = null, l = !1;
|
|
932
|
+
const f = () => {
|
|
933
|
+
t && o && !l && r.set(o, {
|
|
934
|
+
x: t.scrollLeft,
|
|
935
|
+
y: t.scrollTop
|
|
928
936
|
});
|
|
937
|
+
}, a = (c) => {
|
|
938
|
+
if (!t || !n) return;
|
|
939
|
+
const s = r.get(c);
|
|
940
|
+
if (!s) return;
|
|
941
|
+
const g = 10;
|
|
942
|
+
let h = 0;
|
|
943
|
+
const T = () => {
|
|
944
|
+
if (!t) return;
|
|
945
|
+
t.scrollTo({
|
|
946
|
+
top: s.y,
|
|
947
|
+
left: s.x
|
|
948
|
+
});
|
|
949
|
+
const p = t.scrollTop, u = t.scrollLeft;
|
|
950
|
+
!(Math.abs(p - s.y) < 1 && Math.abs(u - s.x) < 1) && h < g && (h++, requestAnimationFrame(T));
|
|
951
|
+
};
|
|
952
|
+
requestAnimationFrame(T);
|
|
929
953
|
};
|
|
930
954
|
return {
|
|
931
|
-
initializeContext: (
|
|
932
|
-
|
|
955
|
+
initializeContext: (c, s) => {
|
|
956
|
+
l = !0, i = c, t || (t = wt(c), (t === document.documentElement ? window : t).addEventListener("scroll", f, {
|
|
933
957
|
passive: !0
|
|
934
|
-
})),
|
|
958
|
+
})), o = s, n && t && (r.get(s) ? a(s) : t.scrollTo({ top: 0, left: 0 }));
|
|
959
|
+
const g = 10;
|
|
960
|
+
let h = 0;
|
|
961
|
+
const T = () => {
|
|
962
|
+
h++, h >= g ? l = !1 : requestAnimationFrame(T);
|
|
963
|
+
};
|
|
964
|
+
requestAnimationFrame(T);
|
|
935
965
|
},
|
|
936
|
-
calculateScrollOffset: (
|
|
937
|
-
const
|
|
966
|
+
calculateScrollOffset: (c, s) => {
|
|
967
|
+
const g = c && r.has(c) ? r.get(c) : { x: 0, y: 0 }, h = s && r.has(s) ? r.get(s) : { x: 0, y: 0 };
|
|
938
968
|
return {
|
|
939
|
-
x: -
|
|
940
|
-
y: -
|
|
969
|
+
x: -h.x + g.x,
|
|
970
|
+
y: -h.y + g.y
|
|
941
971
|
};
|
|
942
972
|
},
|
|
943
|
-
getScrollContainer: () =>
|
|
944
|
-
getPositionedParentElement: () =>
|
|
945
|
-
getScrollPosition: (
|
|
973
|
+
getScrollContainer: () => t,
|
|
974
|
+
getPositionedParentElement: () => i ? yt(i) : document.body,
|
|
975
|
+
getScrollPosition: (c) => c && r.has(c) ? r.get(c) : { x: 0, y: 0 }
|
|
946
976
|
};
|
|
947
977
|
}
|
|
948
|
-
function
|
|
978
|
+
function L(e, n) {
|
|
949
979
|
if (n === "*")
|
|
950
980
|
return !0;
|
|
951
981
|
if (n.endsWith("/*")) {
|
|
@@ -954,16 +984,16 @@ function x(e, n) {
|
|
|
954
984
|
}
|
|
955
985
|
return e === n;
|
|
956
986
|
}
|
|
957
|
-
function
|
|
987
|
+
function $(e, n, t) {
|
|
958
988
|
for (const i of t)
|
|
959
|
-
if (
|
|
989
|
+
if (L(e, i.from) && L(n, i.to))
|
|
960
990
|
return i.transition;
|
|
961
991
|
for (const i of t)
|
|
962
|
-
if ((i.from === "*" ||
|
|
992
|
+
if ((i.from === "*" || L(e, i.from)) && (i.to === "*" || L(n, i.to)))
|
|
963
993
|
return i.transition;
|
|
964
994
|
return null;
|
|
965
995
|
}
|
|
966
|
-
function
|
|
996
|
+
function Pt() {
|
|
967
997
|
let e = null;
|
|
968
998
|
function n() {
|
|
969
999
|
if (e != null && e.from && (e != null && e.to) && (e != null && e.outResolve) && (e != null && e.inResolve)) {
|
|
@@ -1005,111 +1035,119 @@ function kt() {
|
|
|
1005
1035
|
}
|
|
1006
1036
|
};
|
|
1007
1037
|
}
|
|
1008
|
-
function
|
|
1038
|
+
function qt(e, n) {
|
|
1009
1039
|
const {
|
|
1010
1040
|
transitions: t = [],
|
|
1011
1041
|
defaultTransition: i,
|
|
1012
|
-
middleware: r = (
|
|
1042
|
+
middleware: r = (u, v) => ({ from: u, to: v }),
|
|
1013
1043
|
// Identity function as default
|
|
1014
|
-
skipOnIosSwipe: o = !0
|
|
1044
|
+
skipOnIosSwipe: o = !0,
|
|
1015
1045
|
// Default to true - skip animations on iOS swipe
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1046
|
+
experimentalPreserveScroll: l = !1
|
|
1047
|
+
// Default to false - manual scroll management
|
|
1048
|
+
} = e, { outFirst: f = !0, createNavigationDetector: a } = n || {}, m = (a == null ? void 0 : a()) ?? (f ? Pt() : kt()), y = Et(t), {
|
|
1049
|
+
initializeContext: S,
|
|
1050
|
+
calculateScrollOffset: C,
|
|
1051
|
+
getScrollContainer: A,
|
|
1052
|
+
getPositionedParentElement: c,
|
|
1053
|
+
getScrollPosition: s
|
|
1054
|
+
} = Rt({ preserveScroll: l }), g = bt(o);
|
|
1055
|
+
g.initialize();
|
|
1056
|
+
const h = async (u, v) => {
|
|
1057
|
+
if (g.isSwipePending())
|
|
1058
|
+
return g.resetSwipeDetection(), v === "in" ? async (I) => ({
|
|
1059
|
+
onReady: () => {
|
|
1060
|
+
I.style.visibility = "visible";
|
|
1061
|
+
}
|
|
1062
|
+
}) : () => ({});
|
|
1063
|
+
m.trigger(u, v);
|
|
1064
|
+
const w = await m.get(v);
|
|
1065
|
+
if (!w) return () => ({});
|
|
1066
|
+
const { from: R, to: P } = r(
|
|
1067
|
+
w.from,
|
|
1068
|
+
w.to
|
|
1069
|
+
), V = $(
|
|
1070
|
+
R,
|
|
1071
|
+
P,
|
|
1072
|
+
y
|
|
1037
1073
|
) || i;
|
|
1038
1074
|
if (!V) return () => ({});
|
|
1039
|
-
const
|
|
1040
|
-
if (
|
|
1041
|
-
const
|
|
1042
|
-
scrollOffset:
|
|
1043
|
-
scroll:
|
|
1075
|
+
const F = C(w.from, w.to);
|
|
1076
|
+
if (v === "out") {
|
|
1077
|
+
const I = {
|
|
1078
|
+
scrollOffset: F,
|
|
1079
|
+
scroll: s(w.from),
|
|
1044
1080
|
get scrollingElement() {
|
|
1045
|
-
return
|
|
1081
|
+
return A() || document.documentElement;
|
|
1046
1082
|
},
|
|
1047
1083
|
get positionedParent() {
|
|
1048
|
-
return
|
|
1084
|
+
return c();
|
|
1049
1085
|
}
|
|
1050
1086
|
};
|
|
1051
|
-
return (
|
|
1087
|
+
return (x) => V.out(x, I);
|
|
1052
1088
|
} else {
|
|
1053
|
-
const
|
|
1054
|
-
scrollOffset:
|
|
1089
|
+
const I = {
|
|
1090
|
+
scrollOffset: F,
|
|
1055
1091
|
get scroll() {
|
|
1056
|
-
return
|
|
1092
|
+
return s(w.to);
|
|
1057
1093
|
},
|
|
1058
1094
|
get scrollingElement() {
|
|
1059
|
-
return
|
|
1095
|
+
return A() || document.documentElement;
|
|
1060
1096
|
},
|
|
1061
1097
|
get positionedParent() {
|
|
1062
|
-
return
|
|
1098
|
+
return c();
|
|
1063
1099
|
}
|
|
1064
1100
|
};
|
|
1065
|
-
return async (
|
|
1066
|
-
const
|
|
1067
|
-
return
|
|
1068
|
-
|
|
1069
|
-
},
|
|
1101
|
+
return async (x) => {
|
|
1102
|
+
const q = await Promise.resolve(V.in(x, I)), _ = q.onReady;
|
|
1103
|
+
return q.onReady = () => {
|
|
1104
|
+
x.style.visibility = "visible", _ == null || _();
|
|
1105
|
+
}, q;
|
|
1070
1106
|
};
|
|
1071
1107
|
}
|
|
1072
|
-
},
|
|
1073
|
-
key:
|
|
1074
|
-
in: async (
|
|
1075
|
-
out: async (
|
|
1108
|
+
}, T = (u) => ({
|
|
1109
|
+
key: u,
|
|
1110
|
+
in: async (v) => (S(v, u), (await h(u, "in"))(v)),
|
|
1111
|
+
out: async (v) => (await h(u, "out"))(v),
|
|
1076
1112
|
// Add page transition strategy for page-level transitions
|
|
1077
|
-
[
|
|
1078
|
-
}),
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1113
|
+
[J]: ht
|
|
1114
|
+
}), p = (u, v) => {
|
|
1115
|
+
if (g.isSwipePending())
|
|
1116
|
+
return !1;
|
|
1117
|
+
const { from: w, to: R } = r(u, v);
|
|
1118
|
+
return !!($(
|
|
1119
|
+
w,
|
|
1120
|
+
R,
|
|
1121
|
+
y
|
|
1084
1122
|
) || i);
|
|
1085
1123
|
};
|
|
1086
1124
|
return a ? {
|
|
1087
|
-
getTransition:
|
|
1088
|
-
hasMatchingTransition:
|
|
1089
|
-
} :
|
|
1125
|
+
getTransition: T,
|
|
1126
|
+
hasMatchingTransition: p
|
|
1127
|
+
} : T;
|
|
1090
1128
|
}
|
|
1091
1129
|
export {
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1130
|
+
Q as SCOPE_ATTR,
|
|
1131
|
+
Z as SCOPE_READY_ATTR,
|
|
1132
|
+
J as TRANSITION_STRATEGY,
|
|
1095
1133
|
kt as createAnyOrderDetector,
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1134
|
+
dt as createDefaultStrategy,
|
|
1135
|
+
Pt as createOutFirstDetector,
|
|
1136
|
+
ht as createPageTransitionStrategy,
|
|
1137
|
+
qt as createSggoiTransitionContext,
|
|
1138
|
+
xt as createTransitionScope,
|
|
1139
|
+
pt as findScope,
|
|
1140
|
+
Ot as getWatchedCount,
|
|
1141
|
+
Ut as isCssAnimation,
|
|
1142
|
+
Xt as isMultiAnimation,
|
|
1143
|
+
gt as isScopeReady,
|
|
1144
|
+
Yt as isSingleAnimation,
|
|
1107
1145
|
Ht as isTickAnimation,
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1146
|
+
Mt as isWatched,
|
|
1147
|
+
H as normalizeSchedule,
|
|
1148
|
+
M as normalizeToMultiAnimation,
|
|
1149
|
+
Dt as resetObserver,
|
|
1150
|
+
zt as transition,
|
|
1151
|
+
Lt as triggerUnmount,
|
|
1152
|
+
Ct as watchUnmount
|
|
1115
1153
|
};
|