@ssgoi/core 6.4.0 → 6.5.0-beta.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/README.md +73 -125
- package/dist/index.cjs +13 -13
- package/dist/index.js +792 -717
- package/dist/internal.cjs +1 -1
- package/dist/internal.js +447 -340
- package/dist/ssgoi-transition/create-ssgoi-transition-context.d.ts.map +1 -1
- package/dist/ssgoi-transition/unmount-observer.d.ts.map +1 -1
- package/dist/ssgoi-transition/visibility-observer.d.ts +66 -0
- package/dist/ssgoi-transition/visibility-observer.d.ts.map +1 -0
- package/dist/transitions/axis/provider/x/fluid.d.ts.map +1 -1
- package/dist/transitions/axis/provider/x/snappy.d.ts.map +1 -1
- package/dist/transitions/axis/provider/y/directional.d.ts.map +1 -1
- package/dist/transitions/axis/provider/y/non-directional.d.ts.map +1 -1
- package/dist/transitions/axis/provider/z/directional.d.ts.map +1 -1
- package/dist/transitions/axis/provider/z/non-directional.d.ts.map +1 -1
- package/dist/transitions/axis/transition.d.ts.map +1 -1
- package/dist/transitions/blind/transition.d.ts +1 -0
- package/dist/transitions/blind/transition.d.ts.map +1 -1
- package/dist/transitions/drill/transition.d.ts.map +1 -1
- package/dist/transitions/fade/transition.d.ts.map +1 -1
- package/dist/transitions/film/transition.d.ts.map +1 -1
- package/dist/transitions/hero/provider/chrome/static.d.ts.map +1 -1
- package/dist/transitions/jaemin/transition.d.ts.map +1 -1
- package/dist/transitions/rotate/transition.d.ts.map +1 -1
- package/dist/transitions/scroll/transition.d.ts.map +1 -1
- package/dist/transitions/sheet/transition.d.ts.map +1 -1
- package/dist/transitions/slide/transition.d.ts.map +1 -1
- package/dist/transitions/strip/transition.d.ts.map +1 -1
- package/dist/transitions/zoom/transition.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/internal.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { A as
|
|
5
|
-
import { M as
|
|
6
|
-
class
|
|
1
|
+
var At = Object.defineProperty;
|
|
2
|
+
var Ct = (t, s, e) => s in t ? At(t, s, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[s] = e;
|
|
3
|
+
var B = (t, s, e) => Ct(t, typeof s != "symbol" ? s + "" : s, e);
|
|
4
|
+
import { A as xt } from "./multi-animation-CnxqLEka.js";
|
|
5
|
+
import { M as le, W as ce } from "./multi-animation-CnxqLEka.js";
|
|
6
|
+
class Mt extends xt {
|
|
7
7
|
constructor() {
|
|
8
8
|
super(...arguments);
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
B(this, "child", null);
|
|
10
|
+
B(this, "_state", "idle");
|
|
11
|
+
B(this, "_settled", !1);
|
|
12
|
+
B(this, "listeners", /* @__PURE__ */ new Set());
|
|
13
13
|
}
|
|
14
14
|
attach(e) {
|
|
15
|
-
const
|
|
16
|
-
if (this.child = e, this._settled = !1,
|
|
17
|
-
const
|
|
18
|
-
|
|
15
|
+
const n = this.child;
|
|
16
|
+
if (this.child = e, this._settled = !1, n) {
|
|
17
|
+
const c = n.getPose();
|
|
18
|
+
n.complete(), e.matchInto(c);
|
|
19
19
|
}
|
|
20
20
|
e.playbackRate = this.playbackRate;
|
|
21
|
-
const
|
|
21
|
+
const l = e.onComplete;
|
|
22
22
|
e.onComplete = () => {
|
|
23
|
-
|
|
23
|
+
l == null || l(), this.child === e && (this.child = null, this._state = "idle", this._settled = !0), this.notify();
|
|
24
24
|
};
|
|
25
|
-
const
|
|
26
|
-
e.onUpdate = (
|
|
27
|
-
var
|
|
28
|
-
|
|
25
|
+
const d = e.onUpdate;
|
|
26
|
+
e.onUpdate = (c) => {
|
|
27
|
+
var y;
|
|
28
|
+
d == null || d(c), (y = this.onUpdate) == null || y.call(this, c), this.notify();
|
|
29
29
|
}, this._state === "paused" ? e.pause() : this._state === "reversing" ? e.reverse() : (this._state = "playing", e.play()), this.notify();
|
|
30
30
|
}
|
|
31
31
|
play() {
|
|
@@ -63,8 +63,8 @@ class mt extends ht {
|
|
|
63
63
|
return ((e = this.child) == null ? void 0 : e.progress) ?? 0;
|
|
64
64
|
}
|
|
65
65
|
findTimeForProgress(e) {
|
|
66
|
-
var
|
|
67
|
-
return ((
|
|
66
|
+
var n;
|
|
67
|
+
return ((n = this.child) == null ? void 0 : n.findTimeForProgress(e)) ?? null;
|
|
68
68
|
}
|
|
69
69
|
get playbackRate() {
|
|
70
70
|
return super.playbackRate;
|
|
@@ -81,8 +81,8 @@ class mt extends ht {
|
|
|
81
81
|
return ((e = this.child) == null ? void 0 : e.getTimeline()) ?? [];
|
|
82
82
|
}
|
|
83
83
|
matchInto(e) {
|
|
84
|
-
var
|
|
85
|
-
(
|
|
84
|
+
var n;
|
|
85
|
+
(n = this.child) == null || n.matchInto(e);
|
|
86
86
|
}
|
|
87
87
|
/** Currently attached child, or null when nothing is playing. */
|
|
88
88
|
get activeChild() {
|
|
@@ -98,461 +98,568 @@ class mt extends ht {
|
|
|
98
98
|
for (const e of this.listeners) e();
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
|
-
const
|
|
101
|
+
const Lt = (t, s) => {
|
|
102
102
|
var e;
|
|
103
|
-
t.style.position = "absolute", t.style.width = "100%", t.style.top = `${-1 * (((e =
|
|
104
|
-
},
|
|
105
|
-
let
|
|
106
|
-
for (;
|
|
107
|
-
const e = window.getComputedStyle(
|
|
108
|
-
if (
|
|
109
|
-
return
|
|
110
|
-
|
|
103
|
+
t.style.position = "absolute", t.style.width = "100%", t.style.top = `${-1 * (((e = s == null ? void 0 : s.scrollOffset) == null ? void 0 : e.y) ?? 0)}px`, t.style.left = "0";
|
|
104
|
+
}, dt = /* @__PURE__ */ new Set(["auto", "scroll", "overlay"]), Ot = (t) => {
|
|
105
|
+
let s = t.parentElement;
|
|
106
|
+
for (; s && s !== document.body; ) {
|
|
107
|
+
const e = window.getComputedStyle(s);
|
|
108
|
+
if (dt.has(e.overflowY) || dt.has(e.overflowX))
|
|
109
|
+
return s;
|
|
110
|
+
s = s.parentElement;
|
|
111
111
|
}
|
|
112
112
|
return document.documentElement;
|
|
113
|
-
},
|
|
114
|
-
let
|
|
115
|
-
for (;
|
|
116
|
-
const e = window.getComputedStyle(
|
|
113
|
+
}, _t = (t) => {
|
|
114
|
+
let s = t.parentElement;
|
|
115
|
+
for (; s && s !== document.body; ) {
|
|
116
|
+
const e = window.getComputedStyle(s).position;
|
|
117
117
|
if (e === "relative" || e === "absolute" || e === "fixed" || e === "sticky")
|
|
118
|
-
return
|
|
119
|
-
|
|
118
|
+
return s;
|
|
119
|
+
s = s.parentElement;
|
|
120
120
|
}
|
|
121
121
|
return document.body;
|
|
122
122
|
};
|
|
123
|
-
function
|
|
124
|
-
const
|
|
125
|
-
return Promise.all(
|
|
126
|
-
const
|
|
127
|
-
return
|
|
128
|
-
|
|
129
|
-
}),
|
|
123
|
+
function kt(t) {
|
|
124
|
+
const s = Object.keys(t);
|
|
125
|
+
return Promise.all(s.map((e) => t[e])).then((e) => {
|
|
126
|
+
const n = {};
|
|
127
|
+
return s.forEach((l, d) => {
|
|
128
|
+
n[l] = e[d];
|
|
129
|
+
}), n;
|
|
130
130
|
});
|
|
131
131
|
}
|
|
132
|
-
function
|
|
133
|
-
const
|
|
132
|
+
function Dt(t) {
|
|
133
|
+
const s = t.filter((e) => e.symmetric).map((e) => ({
|
|
134
134
|
from: e.to,
|
|
135
135
|
to: e.from,
|
|
136
136
|
transition: e.transition
|
|
137
137
|
}));
|
|
138
|
-
return [...t, ...
|
|
138
|
+
return [...t, ...s];
|
|
139
139
|
}
|
|
140
|
-
function
|
|
141
|
-
if (
|
|
140
|
+
function X(t, s) {
|
|
141
|
+
if (s === "*")
|
|
142
142
|
return !0;
|
|
143
|
-
if (
|
|
144
|
-
const e =
|
|
143
|
+
if (s.endsWith("/*")) {
|
|
144
|
+
const e = s.slice(0, -1);
|
|
145
145
|
return t.startsWith(e) && t.length > e.length;
|
|
146
146
|
}
|
|
147
|
-
return t ===
|
|
147
|
+
return t === s;
|
|
148
148
|
}
|
|
149
|
-
function
|
|
150
|
-
for (const
|
|
151
|
-
if (
|
|
152
|
-
return
|
|
153
|
-
for (const
|
|
154
|
-
if ((
|
|
155
|
-
return
|
|
149
|
+
function Ht(t, s, e) {
|
|
150
|
+
for (const n of e)
|
|
151
|
+
if (X(t, n.from) && X(s, n.to))
|
|
152
|
+
return n.transition;
|
|
153
|
+
for (const n of e)
|
|
154
|
+
if ((n.from === "*" || X(t, n.from)) && (n.to === "*" || X(s, n.to)))
|
|
155
|
+
return n.transition;
|
|
156
156
|
return null;
|
|
157
157
|
}
|
|
158
|
-
const
|
|
159
|
-
function
|
|
160
|
-
const { preserveScroll:
|
|
161
|
-
let
|
|
162
|
-
const
|
|
163
|
-
const
|
|
164
|
-
return
|
|
165
|
-
},
|
|
166
|
-
var
|
|
167
|
-
const
|
|
168
|
-
if (
|
|
169
|
-
return { preserves: !1, shared: !1, storageKey: `path:${
|
|
170
|
-
if (
|
|
171
|
-
return { preserves: !0, shared: !1, storageKey: `path:${
|
|
172
|
-
const
|
|
158
|
+
const Nt = 768, It = 10, Wt = 10;
|
|
159
|
+
function Ft(t = {}) {
|
|
160
|
+
const { preserveScroll: s = (a) => a } = t, e = typeof s == "function" ? s : () => s;
|
|
161
|
+
let n = null, l = !1, d = !1;
|
|
162
|
+
const c = () => {
|
|
163
|
+
const a = (n == null ? void 0 : n.clientWidth) ?? 0, u = a > 0 ? a : typeof window < "u" ? window.innerWidth : 0;
|
|
164
|
+
return u > 0 && u < Nt;
|
|
165
|
+
}, y = () => (d || (l = c(), d = !0), l), E = (a) => {
|
|
166
|
+
var w;
|
|
167
|
+
const u = e(y());
|
|
168
|
+
if (u === !1)
|
|
169
|
+
return { preserves: !1, shared: !1, storageKey: `path:${a}` };
|
|
170
|
+
if (u === !0)
|
|
171
|
+
return { preserves: !0, shared: !1, storageKey: `path:${a}` };
|
|
172
|
+
const v = ((w = u.exclude) == null ? void 0 : w.some((P) => X(a, P))) ?? !1, S = !v && !!u.key;
|
|
173
173
|
return {
|
|
174
|
-
preserves: !
|
|
175
|
-
shared:
|
|
176
|
-
storageKey:
|
|
174
|
+
preserves: !v,
|
|
175
|
+
shared: S,
|
|
176
|
+
storageKey: S ? `shared:${u.key}` : `path:${a}`
|
|
177
177
|
};
|
|
178
|
-
},
|
|
179
|
-
let
|
|
180
|
-
const
|
|
181
|
-
let
|
|
182
|
-
const
|
|
183
|
-
|
|
184
|
-
x:
|
|
185
|
-
y:
|
|
178
|
+
}, O = (a) => E(a).preserves;
|
|
179
|
+
let _ = null;
|
|
180
|
+
const b = /* @__PURE__ */ new Map();
|
|
181
|
+
let M = null, k = !1, I = 0;
|
|
182
|
+
const W = () => {
|
|
183
|
+
n && M && !k && b.set(E(M).storageKey, {
|
|
184
|
+
x: n.scrollLeft,
|
|
185
|
+
y: n.scrollTop
|
|
186
186
|
});
|
|
187
|
-
},
|
|
188
|
-
if (!
|
|
189
|
-
const
|
|
190
|
-
if (
|
|
187
|
+
}, T = (a) => {
|
|
188
|
+
if (!n) return;
|
|
189
|
+
const u = E(a);
|
|
190
|
+
if (u.preserves && u.shared && !b.has(u.storageKey))
|
|
191
191
|
return;
|
|
192
|
-
const
|
|
193
|
-
let
|
|
194
|
-
const
|
|
195
|
-
if (!
|
|
196
|
-
|
|
197
|
-
top:
|
|
198
|
-
left:
|
|
199
|
-
}), !(Math.abs(
|
|
192
|
+
const v = u.preserves && b.has(u.storageKey) ? b.get(u.storageKey) : { x: 0, y: 0 };
|
|
193
|
+
let S = 0;
|
|
194
|
+
const w = () => {
|
|
195
|
+
if (!n) return;
|
|
196
|
+
n.scrollTo({
|
|
197
|
+
top: v.y,
|
|
198
|
+
left: v.x
|
|
199
|
+
}), !(Math.abs(n.scrollTop - v.y) < 1 && Math.abs(n.scrollLeft - v.x) < 1) && S < It && (S++, requestAnimationFrame(w));
|
|
200
200
|
};
|
|
201
|
-
requestAnimationFrame(
|
|
201
|
+
requestAnimationFrame(w);
|
|
202
202
|
};
|
|
203
203
|
return {
|
|
204
|
-
initializeContext: (
|
|
205
|
-
|
|
206
|
-
const
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}).observe(
|
|
204
|
+
initializeContext: (a, u) => {
|
|
205
|
+
k = !0;
|
|
206
|
+
const v = ++I;
|
|
207
|
+
_ = a, n || (n = Ot(a), l = c(), d = !0, typeof ResizeObserver < "u" && new ResizeObserver(() => {
|
|
208
|
+
l = c();
|
|
209
|
+
}).observe(n), (n === document.documentElement ? window : n).addEventListener("scroll", W, {
|
|
210
210
|
passive: !0
|
|
211
|
-
})),
|
|
212
|
-
let
|
|
213
|
-
const
|
|
214
|
-
|
|
211
|
+
})), M = u, T(u);
|
|
212
|
+
let S = 0;
|
|
213
|
+
const w = () => {
|
|
214
|
+
v === I && (S++, S >= Wt ? k = !1 : requestAnimationFrame(w));
|
|
215
215
|
};
|
|
216
|
-
requestAnimationFrame(
|
|
216
|
+
requestAnimationFrame(w);
|
|
217
217
|
},
|
|
218
|
-
calculateScrollOffset: (
|
|
219
|
-
const
|
|
218
|
+
calculateScrollOffset: (a, u) => {
|
|
219
|
+
const v = a ? E(a).storageKey : null, S = v && b.has(v) ? b.get(v) : { x: 0, y: 0 }, w = u ? E(u) : null, P = w != null && w.preserves ? w.storageKey : null, F = P && b.has(P) ? b.get(P) : { x: 0, y: 0 };
|
|
220
220
|
return {
|
|
221
|
-
x: -
|
|
222
|
-
y: -
|
|
221
|
+
x: -F.x + S.x,
|
|
222
|
+
y: -F.y + S.y
|
|
223
223
|
};
|
|
224
224
|
},
|
|
225
|
-
evictScrollPosition: (
|
|
226
|
-
|
|
225
|
+
evictScrollPosition: (a) => {
|
|
226
|
+
b.delete(E(a).storageKey);
|
|
227
227
|
},
|
|
228
|
-
shouldPreserve:
|
|
229
|
-
getScrollContainer: () =>
|
|
230
|
-
getPositionedParentElement: () =>
|
|
231
|
-
getScrollPosition: (
|
|
232
|
-
const
|
|
233
|
-
return
|
|
228
|
+
shouldPreserve: O,
|
|
229
|
+
getScrollContainer: () => n,
|
|
230
|
+
getPositionedParentElement: () => _ ? _t(_) : document.body,
|
|
231
|
+
getScrollPosition: (a) => {
|
|
232
|
+
const u = a ? E(a).storageKey : null;
|
|
233
|
+
return u && b.has(u) ? b.get(u) : { x: 0, y: 0 };
|
|
234
234
|
}
|
|
235
235
|
};
|
|
236
236
|
}
|
|
237
|
-
const
|
|
238
|
-
function
|
|
239
|
-
let t = null,
|
|
240
|
-
const
|
|
241
|
-
for (let
|
|
242
|
-
const
|
|
243
|
-
if (
|
|
237
|
+
const ht = 30, yt = 8, pt = 1.2, mt = 30, Kt = 600;
|
|
238
|
+
function Bt() {
|
|
239
|
+
let t = null, s = !1, e = !1, n = null, l = null, d = !1;
|
|
240
|
+
const c = (f, g) => {
|
|
241
|
+
for (let p = 0; p < f.length; p++) {
|
|
242
|
+
const m = f.item(p);
|
|
243
|
+
if (m && m.identifier === g) return m;
|
|
244
244
|
}
|
|
245
245
|
return null;
|
|
246
|
-
},
|
|
247
|
-
|
|
248
|
-
},
|
|
249
|
-
|
|
250
|
-
},
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
},
|
|
254
|
-
},
|
|
255
|
-
if (
|
|
246
|
+
}, y = () => {
|
|
247
|
+
n !== null && (clearTimeout(n), n = null);
|
|
248
|
+
}, E = () => {
|
|
249
|
+
l !== null && (clearTimeout(l), l = null);
|
|
250
|
+
}, O = () => {
|
|
251
|
+
s = !0, e = !0, y(), E(), n = setTimeout(() => {
|
|
252
|
+
s = !1, e = !1, n = null;
|
|
253
|
+
}, Kt);
|
|
254
|
+
}, _ = (f) => {
|
|
255
|
+
if (f.touches.length !== 1) {
|
|
256
256
|
t = null;
|
|
257
257
|
return;
|
|
258
258
|
}
|
|
259
|
-
const
|
|
260
|
-
if (!
|
|
259
|
+
const g = f.touches.item(0);
|
|
260
|
+
if (!g) {
|
|
261
261
|
t = null;
|
|
262
262
|
return;
|
|
263
263
|
}
|
|
264
|
-
const
|
|
265
|
-
if (!
|
|
264
|
+
const p = window.innerWidth, m = g.clientX <= ht, R = g.clientX >= p - ht;
|
|
265
|
+
if (!m && !R) {
|
|
266
266
|
t = null;
|
|
267
267
|
return;
|
|
268
268
|
}
|
|
269
269
|
t = {
|
|
270
|
-
identifier:
|
|
271
|
-
startX:
|
|
272
|
-
startY:
|
|
273
|
-
fromLeftEdge:
|
|
270
|
+
identifier: g.identifier,
|
|
271
|
+
startX: g.clientX,
|
|
272
|
+
startY: g.clientY,
|
|
273
|
+
fromLeftEdge: m,
|
|
274
274
|
moved: !1
|
|
275
275
|
};
|
|
276
|
-
},
|
|
276
|
+
}, b = (f) => {
|
|
277
277
|
if (!t) return;
|
|
278
|
-
if (
|
|
278
|
+
if (f.touches.length !== 1) {
|
|
279
279
|
t = null;
|
|
280
280
|
return;
|
|
281
281
|
}
|
|
282
|
-
const
|
|
283
|
-
if (!
|
|
282
|
+
const g = c(f.touches, t.identifier);
|
|
283
|
+
if (!g) {
|
|
284
284
|
t = null;
|
|
285
285
|
return;
|
|
286
286
|
}
|
|
287
|
-
const
|
|
288
|
-
if (
|
|
287
|
+
const p = g.clientX - t.startX, m = g.clientY - t.startY, R = Math.abs(p), a = Math.abs(m);
|
|
288
|
+
if (a > yt && a > R * pt) {
|
|
289
289
|
t = null;
|
|
290
290
|
return;
|
|
291
291
|
}
|
|
292
|
-
const
|
|
293
|
-
R >
|
|
294
|
-
},
|
|
292
|
+
const u = t.fromLeftEdge ? p > 0 : p < 0;
|
|
293
|
+
R > yt && R > a * pt && u && (t.moved = !0);
|
|
294
|
+
}, M = (f) => {
|
|
295
295
|
if (!t) return;
|
|
296
|
-
const
|
|
297
|
-
if (!
|
|
296
|
+
const g = c(f.changedTouches, t.identifier);
|
|
297
|
+
if (!g) {
|
|
298
298
|
t = null;
|
|
299
299
|
return;
|
|
300
300
|
}
|
|
301
|
-
const
|
|
302
|
-
if (t.moved &&
|
|
303
|
-
|
|
301
|
+
const p = g.clientX - t.startX, m = t.fromLeftEdge ? p > 0 : p < 0;
|
|
302
|
+
if (t.moved && m && Math.abs(p) >= mt) {
|
|
303
|
+
O(), t = null;
|
|
304
304
|
return;
|
|
305
305
|
}
|
|
306
|
-
t.moved && Math.abs(
|
|
307
|
-
},
|
|
308
|
-
t && (t.moved &&
|
|
306
|
+
t.moved && Math.abs(p) >= mt && O(), t = null;
|
|
307
|
+
}, k = () => {
|
|
308
|
+
t && (t.moved && O(), t = null);
|
|
309
309
|
};
|
|
310
310
|
return { initialize: () => {
|
|
311
|
-
if (typeof window > "u" ||
|
|
312
|
-
|
|
313
|
-
const
|
|
314
|
-
window.addEventListener("touchstart",
|
|
311
|
+
if (typeof window > "u" || d) return;
|
|
312
|
+
d = !0;
|
|
313
|
+
const f = { passive: !0, capture: !0 };
|
|
314
|
+
window.addEventListener("touchstart", _, f), window.addEventListener("touchmove", b, f), window.addEventListener("touchend", M, f), window.addEventListener("touchcancel", k, f);
|
|
315
315
|
}, destroy: () => {
|
|
316
|
-
if (typeof window > "u" || !
|
|
317
|
-
|
|
318
|
-
const
|
|
319
|
-
window.removeEventListener("touchstart",
|
|
316
|
+
if (typeof window > "u" || !d) return;
|
|
317
|
+
d = !1;
|
|
318
|
+
const f = { capture: !0 };
|
|
319
|
+
window.removeEventListener("touchstart", _, f), window.removeEventListener("touchmove", b, f), window.removeEventListener("touchend", M, f), window.removeEventListener("touchcancel", k, f), y(), E(), t = null, s = !1, e = !1;
|
|
320
320
|
}, isSwipeBack: () => {
|
|
321
|
-
const
|
|
322
|
-
return
|
|
321
|
+
const f = s || e;
|
|
322
|
+
return f && y(), f;
|
|
323
323
|
}, onPageEnter: () => {
|
|
324
|
-
|
|
325
|
-
e = !1,
|
|
324
|
+
s = !1, y(), E(), l = setTimeout(() => {
|
|
325
|
+
e = !1, l = null;
|
|
326
326
|
}, 0);
|
|
327
327
|
} };
|
|
328
328
|
}
|
|
329
|
-
function
|
|
329
|
+
function Xt() {
|
|
330
330
|
let t = null;
|
|
331
|
-
function
|
|
332
|
-
var
|
|
333
|
-
t && ((
|
|
331
|
+
function s() {
|
|
332
|
+
var n, l;
|
|
333
|
+
t && ((n = t.outResolve) == null || n.call(t, null), (l = t.inResolve) == null || l.call(t, null), t = null);
|
|
334
334
|
}
|
|
335
335
|
function e() {
|
|
336
336
|
if (t != null && t.from && (t != null && t.to) && (t != null && t.outResolve) && (t != null && t.inResolve)) {
|
|
337
337
|
if (t.from === t.to) {
|
|
338
|
-
|
|
338
|
+
s();
|
|
339
339
|
return;
|
|
340
340
|
}
|
|
341
|
-
const
|
|
342
|
-
t.outResolve(
|
|
341
|
+
const n = { from: t.from, to: t.to };
|
|
342
|
+
t.outResolve(n), t.inResolve(n), t = null;
|
|
343
343
|
}
|
|
344
344
|
}
|
|
345
345
|
return {
|
|
346
|
-
trigger(
|
|
347
|
-
var
|
|
348
|
-
|
|
346
|
+
trigger(n, l) {
|
|
347
|
+
var c;
|
|
348
|
+
l === "out" && (t == null ? void 0 : t.to) === n && !t.from && ((c = t.inResolve) == null || c.call(t, null), t = {}), t && (l === "out" && t.from && t.from !== n || l === "in" && t.to && t.to !== n) && s(), t || (t = {}), l === "out" ? t.from = n : t.to = n;
|
|
349
349
|
},
|
|
350
|
-
get(
|
|
351
|
-
return new Promise((
|
|
352
|
-
t || (t = {}),
|
|
350
|
+
get(n) {
|
|
351
|
+
return new Promise((l) => {
|
|
352
|
+
t || (t = {}), n === "out" ? t.outResolve = l : t.inResolve = l, e();
|
|
353
353
|
});
|
|
354
354
|
}
|
|
355
355
|
};
|
|
356
356
|
}
|
|
357
|
-
const
|
|
358
|
-
let
|
|
359
|
-
function
|
|
360
|
-
if (t instanceof HTMLElement &&
|
|
361
|
-
const
|
|
362
|
-
|
|
357
|
+
const $ = /* @__PURE__ */ new Map();
|
|
358
|
+
let Y = null, gt = !1;
|
|
359
|
+
function Et(t) {
|
|
360
|
+
if (t instanceof HTMLElement && $.has(t) && !t.isConnected) {
|
|
361
|
+
const s = $.get(t);
|
|
362
|
+
$.delete(t), queueMicrotask(s);
|
|
363
363
|
}
|
|
364
|
-
for (const
|
|
365
|
-
|
|
364
|
+
for (const s of Array.from(t.childNodes))
|
|
365
|
+
Et(s);
|
|
366
366
|
}
|
|
367
|
-
function
|
|
368
|
-
if (
|
|
369
|
-
|
|
370
|
-
for (const e of
|
|
371
|
-
for (const
|
|
372
|
-
|
|
367
|
+
function zt() {
|
|
368
|
+
if (gt || typeof document > "u") return;
|
|
369
|
+
gt = !0, Y = new MutationObserver((s) => {
|
|
370
|
+
for (const e of s)
|
|
371
|
+
for (const n of Array.from(e.removedNodes))
|
|
372
|
+
Et(n);
|
|
373
373
|
});
|
|
374
374
|
const t = () => {
|
|
375
|
-
|
|
375
|
+
Y == null || Y.observe(document.body, { childList: !0, subtree: !0 });
|
|
376
376
|
};
|
|
377
377
|
document.body ? t() : document.addEventListener("DOMContentLoaded", t, { once: !0 });
|
|
378
378
|
}
|
|
379
|
-
function
|
|
380
|
-
return
|
|
381
|
-
|
|
379
|
+
function $t(t, s) {
|
|
380
|
+
return zt(), $.set(t, s), () => {
|
|
381
|
+
$.delete(t);
|
|
382
|
+
};
|
|
383
|
+
}
|
|
384
|
+
const ot = /* @__PURE__ */ new WeakMap();
|
|
385
|
+
let G = null;
|
|
386
|
+
const Z = "none !important";
|
|
387
|
+
function z(t) {
|
|
388
|
+
const s = t.style.getPropertyValue("display");
|
|
389
|
+
return t.style.getPropertyPriority("display") ? `${s} !important` : s;
|
|
390
|
+
}
|
|
391
|
+
function Vt() {
|
|
392
|
+
return G || (G = new MutationObserver((t) => {
|
|
393
|
+
for (const s of t) {
|
|
394
|
+
const e = s.target, n = ot.get(e);
|
|
395
|
+
if (!n) continue;
|
|
396
|
+
const l = z(e);
|
|
397
|
+
l !== n.accounted && (n.accounted = l, l === Z ? (n.reactHidden = !0, n.onHide()) : l !== "none" && n.reactHidden && (n.reactHidden = !1, n.onShow()));
|
|
398
|
+
}
|
|
399
|
+
}), G);
|
|
400
|
+
}
|
|
401
|
+
function qt(t, s) {
|
|
402
|
+
const e = z(t), n = {
|
|
403
|
+
accounted: e,
|
|
404
|
+
reactHidden: e === Z,
|
|
405
|
+
onHide: s.onHide,
|
|
406
|
+
onShow: s.onShow
|
|
407
|
+
};
|
|
408
|
+
return ot.set(t, n), Vt().observe(t, {
|
|
409
|
+
attributes: !0,
|
|
410
|
+
attributeFilter: ["style"]
|
|
411
|
+
}), {
|
|
412
|
+
get isHidden() {
|
|
413
|
+
return z(t) === Z;
|
|
414
|
+
},
|
|
415
|
+
setDisplay(l, d = !1) {
|
|
416
|
+
l === null ? t.style.removeProperty("display") : t.style.setProperty(
|
|
417
|
+
"display",
|
|
418
|
+
l,
|
|
419
|
+
d ? "important" : ""
|
|
420
|
+
), n.accounted = z(t);
|
|
421
|
+
},
|
|
422
|
+
sync() {
|
|
423
|
+
n.accounted = z(t), n.reactHidden = n.accounted === Z;
|
|
424
|
+
},
|
|
425
|
+
stop() {
|
|
426
|
+
ot.delete(t);
|
|
427
|
+
}
|
|
382
428
|
};
|
|
383
429
|
}
|
|
384
|
-
function
|
|
430
|
+
function Ut(t) {
|
|
385
431
|
return Array.isArray(t);
|
|
386
432
|
}
|
|
387
|
-
function
|
|
388
|
-
const
|
|
433
|
+
function bt(t) {
|
|
434
|
+
const s = [];
|
|
389
435
|
for (const e of t)
|
|
390
|
-
|
|
391
|
-
return
|
|
436
|
+
Ut(e) ? s.push(...bt(e)) : s.push(e);
|
|
437
|
+
return s;
|
|
392
438
|
}
|
|
393
|
-
function
|
|
439
|
+
function se(t, s = {}) {
|
|
394
440
|
const {
|
|
395
441
|
transitions: e = [],
|
|
396
|
-
middleware:
|
|
397
|
-
preserveScroll:
|
|
398
|
-
} = t,
|
|
399
|
-
|
|
400
|
-
),
|
|
401
|
-
|
|
442
|
+
middleware: n = (o, i) => ({ from: o, to: i }),
|
|
443
|
+
preserveScroll: l = (o) => o
|
|
444
|
+
} = t, d = s.host ?? new Mt(), c = Xt(), y = Dt(
|
|
445
|
+
bt(e)
|
|
446
|
+
), E = Bt();
|
|
447
|
+
E.initialize();
|
|
402
448
|
const {
|
|
403
|
-
initializeContext:
|
|
404
|
-
calculateScrollOffset:
|
|
405
|
-
evictScrollPosition:
|
|
406
|
-
shouldPreserve:
|
|
407
|
-
getScrollContainer:
|
|
408
|
-
getPositionedParentElement:
|
|
409
|
-
getScrollPosition:
|
|
410
|
-
} =
|
|
411
|
-
let
|
|
412
|
-
const
|
|
413
|
-
|
|
414
|
-
parent:
|
|
415
|
-
nextSibling:
|
|
449
|
+
initializeContext: O,
|
|
450
|
+
calculateScrollOffset: _,
|
|
451
|
+
evictScrollPosition: b,
|
|
452
|
+
shouldPreserve: M,
|
|
453
|
+
getScrollContainer: k,
|
|
454
|
+
getPositionedParentElement: I,
|
|
455
|
+
getScrollPosition: W
|
|
456
|
+
} = Ft({ preserveScroll: l });
|
|
457
|
+
let T = null, A = null;
|
|
458
|
+
const f = /* @__PURE__ */ new WeakMap(), g = (o) => {
|
|
459
|
+
f.set(o, {
|
|
460
|
+
parent: o.parentElement,
|
|
461
|
+
nextSibling: o.nextElementSibling
|
|
416
462
|
});
|
|
417
|
-
},
|
|
418
|
-
const
|
|
419
|
-
return
|
|
420
|
-
parent:
|
|
421
|
-
nextSibling:
|
|
463
|
+
}, p = (o) => {
|
|
464
|
+
const i = f.get(o);
|
|
465
|
+
return i || {
|
|
466
|
+
parent: o.parentElement,
|
|
467
|
+
nextSibling: o.nextElementSibling
|
|
422
468
|
};
|
|
423
|
-
},
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
const
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
469
|
+
}, m = /* @__PURE__ */ new WeakMap(), R = /* @__PURE__ */ new WeakMap();
|
|
470
|
+
let a = 0;
|
|
471
|
+
const u = (o) => {
|
|
472
|
+
const i = typeof getComputedStyle < "u" ? getComputedStyle(o).display : "";
|
|
473
|
+
return i && i !== "none" ? i : "block";
|
|
474
|
+
}, v = (o, i) => {
|
|
475
|
+
i.visibleDisplay = o.style.getPropertyValue("display"), i.computedDisplay = u(o);
|
|
476
|
+
}, S = (o, i) => {
|
|
477
|
+
if (R.get(o) !== i) return;
|
|
478
|
+
R.delete(o);
|
|
479
|
+
const r = m.get(o);
|
|
480
|
+
r && (r.savedCss !== null && (o.style.cssText = r.savedCss, r.savedCss = null), r.intent === "hidden" ? r.vis.setDisplay("none", !0) : r.visibleDisplay ? (r.vis.setDisplay(r.visibleDisplay, !1), v(o, r)) : (r.vis.setDisplay(null), v(o, r)));
|
|
481
|
+
}, w = (o, i, r, h, L) => {
|
|
482
|
+
const x = h.element, D = L.element, H = (h.mode ?? "unmount") === "hidden", { parent: V, nextSibling: J } = h.parent ? { parent: h.parent, nextSibling: h.nextSibling } : p(x), q = _(i, r), Q = {
|
|
483
|
+
scrollOffset: q,
|
|
484
|
+
from: { scroll: W(i) },
|
|
485
|
+
to: { scroll: W(r) },
|
|
430
486
|
get scrollingElement() {
|
|
431
|
-
return
|
|
487
|
+
return k() || document.documentElement;
|
|
432
488
|
},
|
|
433
489
|
get positionedParent() {
|
|
434
|
-
return
|
|
490
|
+
return I();
|
|
435
491
|
}
|
|
436
492
|
};
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
493
|
+
let C;
|
|
494
|
+
if (H) {
|
|
495
|
+
C = x, C.style.top = `${-1 * ((q == null ? void 0 : q.y) ?? 0)}px`;
|
|
496
|
+
const N = m.get(D);
|
|
497
|
+
N && N.savedCss === null && (N.savedCss = D.style.cssText);
|
|
498
|
+
} else
|
|
499
|
+
C = x.cloneNode(!0), C.setAttribute("data-ssgoi-clone", ""), Lt(C, Q);
|
|
500
|
+
M(i) || b(i);
|
|
501
|
+
const U = H ? ++a : 0;
|
|
502
|
+
H && (R.set(D, U), R.set(x, U));
|
|
503
|
+
const at = Promise.resolve(C), ut = Promise.resolve(D), ft = [], Rt = {
|
|
504
|
+
from: at,
|
|
505
|
+
to: ut,
|
|
506
|
+
context: Q,
|
|
507
|
+
createElement: ((N, tt = "div") => {
|
|
508
|
+
const K = document.createElement(tt);
|
|
509
|
+
return K.setAttribute("data-ssgoi-id", N), ft.push(K), K;
|
|
445
510
|
})
|
|
446
|
-
},
|
|
447
|
-
|
|
511
|
+
}, Pt = Promise.resolve(
|
|
512
|
+
o.prepare ? o.prepare(Rt) : {}
|
|
448
513
|
);
|
|
449
|
-
|
|
450
|
-
from:
|
|
451
|
-
to:
|
|
452
|
-
extras:
|
|
453
|
-
}).then(({ from:
|
|
454
|
-
|
|
455
|
-
const
|
|
456
|
-
from:
|
|
457
|
-
to:
|
|
458
|
-
context:
|
|
514
|
+
kt({
|
|
515
|
+
from: at,
|
|
516
|
+
to: ut,
|
|
517
|
+
extras: Pt
|
|
518
|
+
}).then(({ from: N, to: tt, extras: K }) => {
|
|
519
|
+
!H && V && (J && V.contains(J) ? V.insertBefore(C, J) : V.appendChild(C));
|
|
520
|
+
const et = o.animation({
|
|
521
|
+
from: N,
|
|
522
|
+
to: tt,
|
|
523
|
+
context: Q,
|
|
459
524
|
...K
|
|
460
|
-
}),
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
for (const
|
|
464
|
-
|
|
465
|
-
},
|
|
525
|
+
}), nt = et.onComplete;
|
|
526
|
+
et.onComplete = () => {
|
|
527
|
+
nt == null || nt(), H ? (S(x, U), S(D, U)) : C.parentElement && C.parentElement.removeChild(C);
|
|
528
|
+
for (const st of ft)
|
|
529
|
+
st.parentElement && st.parentElement.removeChild(st);
|
|
530
|
+
}, d.attach(et);
|
|
466
531
|
});
|
|
467
|
-
},
|
|
468
|
-
const
|
|
469
|
-
|
|
470
|
-
if (
|
|
471
|
-
if (
|
|
472
|
-
|
|
532
|
+
}, P = (o, i) => {
|
|
533
|
+
const r = E.isSwipeBack();
|
|
534
|
+
c.trigger(o, i), c.get(i).then((h) => {
|
|
535
|
+
if (i === "in" && E.onPageEnter(), !h) return;
|
|
536
|
+
if (r) {
|
|
537
|
+
i === "out" && h.from && !M(h.from) && b(h.from), T = null, A = null;
|
|
473
538
|
return;
|
|
474
539
|
}
|
|
475
|
-
if (
|
|
476
|
-
const { from:
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
),
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
),
|
|
484
|
-
|
|
540
|
+
if (i !== "in") return;
|
|
541
|
+
const { from: L, to: x } = n(
|
|
542
|
+
h.from,
|
|
543
|
+
h.to
|
|
544
|
+
), D = Ht(
|
|
545
|
+
L,
|
|
546
|
+
x,
|
|
547
|
+
y
|
|
548
|
+
), j = T, H = A;
|
|
549
|
+
T = null, A = null, !(!D || !j || !H) && w(D, L, x, j, H);
|
|
485
550
|
});
|
|
486
|
-
},
|
|
487
|
-
const
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
551
|
+
}, F = (o, i) => {
|
|
552
|
+
const r = m.get(o);
|
|
553
|
+
if (!r) return;
|
|
554
|
+
const h = r.intent === "hidden";
|
|
555
|
+
if (r.intent = "hidden", r.savedCss === null && (r.savedCss = o.style.cssText), r.vis.setDisplay(r.computedDisplay || "block", !0), o.style.position = "absolute", o.style.width = "100%", o.style.left = "0", h) return;
|
|
556
|
+
const L = p(o);
|
|
557
|
+
T = {
|
|
558
|
+
element: o,
|
|
559
|
+
parent: L.parent,
|
|
560
|
+
nextSibling: L.nextSibling,
|
|
561
|
+
mode: "hidden"
|
|
562
|
+
};
|
|
563
|
+
const x = o.getAttribute("data-ssgoi-transition") ?? i;
|
|
564
|
+
P(x, "out");
|
|
565
|
+
}, St = (o, i) => {
|
|
566
|
+
const r = m.get(o);
|
|
567
|
+
if (!r || r.intent === "visible") return;
|
|
568
|
+
r.intent = "visible", v(o, r), r.savedCss !== null && (o.style.cssText = r.savedCss, r.visibleDisplay ? r.vis.setDisplay(r.visibleDisplay, !1) : r.vis.setDisplay(null)), O(o, i), A = {
|
|
569
|
+
element: o,
|
|
570
|
+
parent: o.parentElement,
|
|
571
|
+
nextSibling: o.nextElementSibling
|
|
572
|
+
};
|
|
573
|
+
const h = o.getAttribute("data-ssgoi-transition") ?? i;
|
|
574
|
+
P(h, "in");
|
|
575
|
+
}, Tt = (o, i) => {
|
|
576
|
+
const r = m.get(o);
|
|
577
|
+
if (r && (r.vis.stop(), m.delete(o), R.delete(o), r.intent === "hidden")) {
|
|
578
|
+
(T == null ? void 0 : T.element) === o && (T = null), (A == null ? void 0 : A.element) === o && (A = null);
|
|
579
|
+
return;
|
|
580
|
+
}
|
|
581
|
+
const h = p(o);
|
|
582
|
+
T = {
|
|
583
|
+
element: o,
|
|
584
|
+
parent: h.parent,
|
|
585
|
+
nextSibling: h.nextSibling,
|
|
586
|
+
mode: "unmount"
|
|
587
|
+
};
|
|
588
|
+
const L = o.getAttribute("data-ssgoi-transition") ?? i;
|
|
589
|
+
P(L, "out");
|
|
590
|
+
}, rt = /* @__PURE__ */ new WeakSet(), lt = (o, i) => {
|
|
591
|
+
if (rt.has(i)) return;
|
|
592
|
+
rt.add(i), g(i);
|
|
593
|
+
const r = qt(i, {
|
|
594
|
+
onHide: () => F(i, o),
|
|
595
|
+
onShow: () => St(i, o)
|
|
596
|
+
}), h = {
|
|
597
|
+
vis: r,
|
|
598
|
+
savedCss: null,
|
|
599
|
+
intent: r.isHidden ? "hidden" : "visible",
|
|
600
|
+
visibleDisplay: "",
|
|
601
|
+
computedDisplay: "block"
|
|
492
602
|
};
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
return s || (s = (w) => {
|
|
505
|
-
w && p(r, w);
|
|
506
|
-
}, E.set(r, s)), s;
|
|
603
|
+
m.set(i, h), r.isHidden || (v(i, h), O(i, o), A = {
|
|
604
|
+
element: i,
|
|
605
|
+
parent: i.parentElement,
|
|
606
|
+
nextSibling: i.nextElementSibling
|
|
607
|
+
}, P(o, "in")), $t(i, () => Tt(i, o));
|
|
608
|
+
}, ct = /* @__PURE__ */ new Map();
|
|
609
|
+
return { register: lt, refFor: (o) => {
|
|
610
|
+
let i = ct.get(o);
|
|
611
|
+
return i || (i = (r) => {
|
|
612
|
+
r && lt(o, r);
|
|
613
|
+
}, ct.set(o, i)), i;
|
|
507
614
|
} };
|
|
508
615
|
}
|
|
509
|
-
const
|
|
510
|
-
function
|
|
616
|
+
const wt = "data-ssgoi-root", Yt = `[${wt}]`, it = "data-ssgoi-transition", vt = `[${it}]`, Gt = "[data-ssgoi-clone]";
|
|
617
|
+
function Zt() {
|
|
511
618
|
return typeof MutationObserver < "u" && typeof HTMLElement < "u" && typeof Node < "u";
|
|
512
619
|
}
|
|
513
|
-
function
|
|
620
|
+
function jt(t) {
|
|
514
621
|
return t.nodeType === Node.ELEMENT_NODE;
|
|
515
622
|
}
|
|
516
|
-
function
|
|
623
|
+
function Jt(t) {
|
|
517
624
|
return t instanceof HTMLElement;
|
|
518
625
|
}
|
|
519
|
-
function
|
|
520
|
-
if (!
|
|
626
|
+
function oe(t, s) {
|
|
627
|
+
if (!Zt()) return () => {
|
|
521
628
|
};
|
|
522
|
-
t.setAttribute(
|
|
523
|
-
const e = (
|
|
524
|
-
if (!
|
|
629
|
+
t.setAttribute(wt, "");
|
|
630
|
+
const e = (c) => c.closest(Yt) === t, n = (c) => {
|
|
631
|
+
if (!Jt(c) || !e(c) || c.closest(Gt))
|
|
525
632
|
return;
|
|
526
|
-
const
|
|
527
|
-
|
|
528
|
-
},
|
|
529
|
-
if (
|
|
530
|
-
|
|
531
|
-
for (const
|
|
532
|
-
|
|
633
|
+
const y = c.getAttribute(it);
|
|
634
|
+
y !== null && s.register(y, c);
|
|
635
|
+
}, l = (c) => {
|
|
636
|
+
if (jt(c)) {
|
|
637
|
+
c.matches(vt) && n(c);
|
|
638
|
+
for (const y of c.querySelectorAll(vt))
|
|
639
|
+
n(y);
|
|
533
640
|
}
|
|
534
|
-
},
|
|
535
|
-
for (const
|
|
536
|
-
if (
|
|
537
|
-
|
|
641
|
+
}, d = new MutationObserver((c) => {
|
|
642
|
+
for (const y of c) {
|
|
643
|
+
if (y.type === "attributes") {
|
|
644
|
+
n(y.target);
|
|
538
645
|
continue;
|
|
539
646
|
}
|
|
540
|
-
for (const
|
|
541
|
-
|
|
647
|
+
for (const E of y.addedNodes)
|
|
648
|
+
l(E);
|
|
542
649
|
}
|
|
543
650
|
});
|
|
544
|
-
return
|
|
651
|
+
return d.observe(t, {
|
|
545
652
|
childList: !0,
|
|
546
653
|
subtree: !0,
|
|
547
654
|
attributes: !0,
|
|
548
|
-
attributeFilter: [
|
|
549
|
-
}),
|
|
655
|
+
attributeFilter: [it]
|
|
656
|
+
}), l(t), () => d.disconnect();
|
|
550
657
|
}
|
|
551
658
|
export {
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
659
|
+
xt as Animation,
|
|
660
|
+
Mt as HostAnimation,
|
|
661
|
+
le as MultiAnimation,
|
|
662
|
+
ce as WebAnimation,
|
|
663
|
+
se as createSggoiTransitionContext,
|
|
664
|
+
oe as observeSsgoiTransitions
|
|
558
665
|
};
|