@ssgoi/core 3.2.2 → 3.4.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.
Files changed (48) hide show
  1. package/README.md +10 -9
  2. package/dist/animator/spring-core.d.ts +23 -4
  3. package/dist/animator/spring-core.d.ts.map +1 -1
  4. package/dist/index.cjs +1 -2
  5. package/dist/index.js +227 -213
  6. package/dist/transition/create-transition-callback.d.ts.map +1 -1
  7. package/dist/transition/transition.d.ts +1 -2
  8. package/dist/transition/transition.d.ts.map +1 -1
  9. package/dist/transitions/blur.d.ts +2 -18
  10. package/dist/transitions/blur.d.ts.map +1 -1
  11. package/dist/transitions/bounce.d.ts +2 -18
  12. package/dist/transitions/bounce.d.ts.map +1 -1
  13. package/dist/transitions/fade.d.ts +2 -18
  14. package/dist/transitions/fade.d.ts.map +1 -1
  15. package/dist/transitions/fly.d.ts +2 -18
  16. package/dist/transitions/fly.d.ts.map +1 -1
  17. package/dist/transitions/index.cjs +1 -1
  18. package/dist/transitions/index.js +188 -172
  19. package/dist/transitions/mask.d.ts +2 -18
  20. package/dist/transitions/mask.d.ts.map +1 -1
  21. package/dist/transitions/none.d.ts +2 -18
  22. package/dist/transitions/none.d.ts.map +1 -1
  23. package/dist/transitions/rotate.d.ts +2 -18
  24. package/dist/transitions/rotate.d.ts.map +1 -1
  25. package/dist/transitions/scale.d.ts +2 -18
  26. package/dist/transitions/scale.d.ts.map +1 -1
  27. package/dist/transitions/slide.d.ts +2 -18
  28. package/dist/transitions/slide.d.ts.map +1 -1
  29. package/dist/types.d.ts +15 -2
  30. package/dist/types.d.ts.map +1 -1
  31. package/dist/utils/index.d.ts +1 -1
  32. package/dist/utils/index.d.ts.map +1 -1
  33. package/dist/utils/with-resolvers.d.ts +7 -0
  34. package/dist/utils/with-resolvers.d.ts.map +1 -0
  35. package/dist/view-transitions/drill.d.ts.map +1 -1
  36. package/dist/view-transitions/fade.d.ts.map +1 -1
  37. package/dist/view-transitions/index.cjs +11 -11
  38. package/dist/view-transitions/index.d.ts +1 -0
  39. package/dist/view-transitions/index.d.ts.map +1 -1
  40. package/dist/view-transitions/index.js +479 -425
  41. package/dist/view-transitions/instagram.d.ts.map +1 -1
  42. package/dist/view-transitions/pinterest.d.ts.map +1 -1
  43. package/dist/view-transitions/rotate.d.ts +3 -0
  44. package/dist/view-transitions/rotate.d.ts.map +1 -0
  45. package/dist/view-transitions/slide.d.ts.map +1 -1
  46. package/package.json +1 -1
  47. package/dist/utils/parse-caller-location.d.ts +0 -6
  48. package/dist/utils/parse-caller-location.d.ts.map +0 -1
@@ -1,19 +1,26 @@
1
- import { p as x, g as b } from "../jaemin-BWkrXq0V.js";
2
- import { a as Xt } from "../jaemin-BWkrXq0V.js";
3
- const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damping: 25 }, H = { stiffness: 75, damping: 25 }, N = 300, q = 10, G = "horizontal", j = "#000000", St = (t = {}) => {
1
+ import { p as b, g as x } from "../jaemin-BWkrXq0V.js";
2
+ import { a as Ht } from "../jaemin-BWkrXq0V.js";
3
+ const F = (t) => new Promise((n) => setTimeout(n, t));
4
+ function T() {
5
+ let t, n;
6
+ return { promise: new Promise((d, a) => {
7
+ t = d, n = a;
8
+ }), resolve: t, reject: n };
9
+ }
10
+ const N = { stiffness: 80, damping: 25 }, G = { stiffness: 75, damping: 25 }, q = 300, j = 10, K = "horizontal", Z = "#000000", It = (t = {}) => {
4
11
  const {
5
- inSpring: n = H,
6
- outSpring: a = B,
7
- transitionDelay: d = N,
8
- blindCount: r = q,
9
- direction: s = G,
10
- blindColor: l = j
12
+ inSpring: n = G,
13
+ outSpring: i = N,
14
+ transitionDelay: d = q,
15
+ blindCount: a = j,
16
+ direction: s = K,
17
+ blindColor: l = Z
11
18
  } = t;
12
- let i, c = null;
13
- const o = (e, p, y = "left") => {
19
+ let r, o = null;
20
+ const c = (e, g, y = "left") => {
14
21
  window.getComputedStyle(e).position === "static" && (e.style.position = "relative");
15
- const g = document.createElement("div");
16
- g.className = "blind-container", g.style.cssText = `
22
+ const p = document.createElement("div");
23
+ p.className = "blind-container", p.style.cssText = `
17
24
  position: absolute;
18
25
  top: 0;
19
26
  left: 0;
@@ -24,10 +31,10 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
24
31
  overflow: hidden;
25
32
  `;
26
33
  const u = [];
27
- for (let m = 0; m < r; m++) {
34
+ for (let m = 0; m < a; m++) {
28
35
  const f = document.createElement("div");
29
36
  if (s === "horizontal") {
30
- const w = 100 / r, $ = `calc(${w}% + 1px)`;
37
+ const w = 100 / a, $ = `calc(${w}% + 1px)`;
31
38
  f.style.cssText = `
32
39
  position: absolute;
33
40
  top: ${w * m}%;
@@ -35,12 +42,12 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
35
42
  width: 100%;
36
43
  height: ${$};
37
44
  background: ${l};
38
- transform: scaleX(${p === "hidden" ? 0 : 1});
45
+ transform: scaleX(${g === "hidden" ? 0 : 1});
39
46
  transform-origin: ${y} center;
40
47
  will-change: transform;
41
48
  `;
42
49
  } else {
43
- const w = 100 / r, $ = `calc(${w}% + 1px)`;
50
+ const w = 100 / a, $ = `calc(${w}% + 1px)`;
44
51
  f.style.cssText = `
45
52
  position: absolute;
46
53
  top: 0;
@@ -48,78 +55,78 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
48
55
  width: ${$};
49
56
  height: 100%;
50
57
  background: ${l};
51
- transform: scaleY(${p === "hidden" ? 0 : 1});
58
+ transform: scaleY(${g === "hidden" ? 0 : 1});
52
59
  transform-origin: ${y === "left" ? "top" : "bottom"} center;
53
60
  will-change: transform;
54
61
  `;
55
62
  }
56
- u.push(f), g.appendChild(f);
63
+ u.push(f), p.appendChild(f);
57
64
  }
58
- return e.appendChild(g), { container: g, blinds: u };
65
+ return e.appendChild(p), { container: p, blinds: u };
59
66
  };
60
67
  return {
61
68
  out: () => {
62
69
  let e = null;
63
- i = new Promise((h) => {
64
- c = h;
70
+ r = new Promise((h) => {
71
+ o = h;
65
72
  });
66
- const p = (h) => {
67
- const g = 1 - h;
73
+ const g = (h) => {
74
+ const p = 1 - h;
68
75
  return {
69
- transform: s === "horizontal" ? `scaleX(${g})` : `scaleY(${g})`
76
+ transform: s === "horizontal" ? `scaleX(${p})` : `scaleY(${p})`
70
77
  };
71
78
  };
72
79
  return {
73
- springs: Array.from({ length: r }, (h, g) => ({
74
- spring: a,
80
+ springs: Array.from({ length: a }, (h, p) => ({
81
+ spring: i,
75
82
  offset: 0.2,
76
83
  css: {
77
84
  // Use getter for lazy element access (evaluated after prepare)
78
85
  get element() {
79
- return e == null ? void 0 : e.blinds[g];
86
+ return e == null ? void 0 : e.blinds[p];
80
87
  },
81
- style: p
88
+ style: g
82
89
  }
83
90
  })),
84
91
  schedule: "stagger",
85
92
  prepare: (h) => {
86
- x(h), h.style.zIndex = "1000", e = o(h, "hidden", "left");
93
+ b(h), h.style.zIndex = "1000", e = c(h, "hidden", "left");
87
94
  },
88
95
  onStart: () => {
89
96
  },
90
97
  onEnd: () => {
91
- c && c();
98
+ o && o();
92
99
  }
93
100
  };
94
101
  },
95
102
  in: () => {
96
103
  let e = null;
97
- const p = (h) => {
98
- const g = 1 - h;
104
+ const g = (h) => {
105
+ const p = 1 - h;
99
106
  return {
100
- transform: s === "horizontal" ? `scaleX(${g})` : `scaleY(${g})`
107
+ transform: s === "horizontal" ? `scaleX(${p})` : `scaleY(${p})`
101
108
  };
102
109
  };
103
110
  return {
104
- springs: Array.from({ length: r }, (h, g) => ({
111
+ springs: Array.from({ length: a }, (h, p) => ({
105
112
  spring: n,
106
113
  offset: 0.2,
107
114
  css: {
108
115
  // Use getter for lazy element access (evaluated after prepare)
109
116
  get element() {
110
- return e == null ? void 0 : e.blinds[g];
117
+ return e == null ? void 0 : e.blinds[p];
111
118
  },
112
- style: p
119
+ style: g
113
120
  }
114
121
  })),
115
122
  schedule: "stagger",
116
123
  prepare: (h) => {
117
- h.style.position = "relative", h.style.zIndex = "0", e = o(h, "closed", "right");
124
+ h.style.position = "relative", h.style.zIndex = "0", e = c(h, "closed", "right");
118
125
  },
119
126
  onStart: () => {
120
127
  },
121
128
  wait: async () => {
122
- i && await i, await P(d);
129
+ r && await r, await F(d);
123
130
  },
124
131
  onEnd: () => {
125
132
  e && e.container && e.container.remove();
@@ -127,114 +134,127 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
127
134
  };
128
135
  }
129
136
  };
130
- }, K = {
131
- stiffness: 150,
132
- damping: 20
133
- }, Z = {
134
- stiffness: 100,
135
- damping: 20
136
- }, _t = (t = {}) => {
137
- var s, l;
138
- const { opacity: n = !1, direction: a = "enter" } = t, d = a === "enter" ? K : Z, r = {
137
+ }, J = {
138
+ stiffness: 125,
139
+ damping: 20,
140
+ doubleSpring: 0.8
141
+ }, Q = {
142
+ stiffness: 130,
143
+ damping: 20,
144
+ doubleSpring: 0.8
145
+ }, Ot = (t = {}) => {
146
+ var s, l, r;
147
+ const { opacity: n = !1, direction: i = "enter" } = t, d = i === "enter" ? J : Q, a = {
139
148
  stiffness: ((s = t.spring) == null ? void 0 : s.stiffness) ?? d.stiffness,
140
- damping: ((l = t.spring) == null ? void 0 : l.damping) ?? d.damping
149
+ damping: ((l = t.spring) == null ? void 0 : l.damping) ?? d.damping,
150
+ doubleSpring: ((r = t.spring) == null ? void 0 : r.doubleSpring) ?? d.doubleSpring
141
151
  };
142
- return a === "enter" ? {
143
- in: (i) => ({
144
- spring: r,
152
+ return i === "enter" ? {
153
+ in: (o) => ({
154
+ spring: a,
145
155
  prepare: () => {
146
- i.style.willChange = n ? "transform, opacity" : "transform", i.style.backfaceVisibility = "hidden", i.style.contain = "layout paint";
156
+ o.style.willChange = n ? "transform, opacity" : "transform", o.style.backfaceVisibility = "hidden", o.style.contain = "layout paint";
147
157
  },
148
158
  css: (c) => {
149
- const o = {
159
+ const e = {
150
160
  transform: `translate3d(${(1 - c) * 100}%, 0, 0)`
151
161
  };
152
- return n && (o.opacity = c), o;
162
+ return n && (e.opacity = c), e;
153
163
  },
154
164
  onEnd: () => {
155
- i.style.willChange = "auto", i.style.backfaceVisibility = "", i.style.contain = "";
165
+ o.style.willChange = "auto", o.style.backfaceVisibility = "", o.style.contain = "";
156
166
  }
157
167
  }),
158
- out: (i, c) => ({
159
- spring: r,
160
- prepare: (o) => {
161
- x(o, c), o.style.zIndex = "-1", o.style.willChange = n ? "transform, opacity" : "transform", o.style.backfaceVisibility = "hidden", o.style.contain = "layout paint", o.style.pointerEvents = "none";
168
+ out: (o, c) => ({
169
+ spring: a,
170
+ prepare: (e) => {
171
+ b(e, c), e.style.zIndex = "-1", e.style.willChange = n ? "transform, opacity" : "transform", e.style.backfaceVisibility = "hidden", e.style.contain = "layout paint", e.style.pointerEvents = "none";
162
172
  },
163
- css: (o) => {
164
- const e = {
165
- transform: `translate3d(${-(1 - o) * 20}%, 0, 0)`
173
+ css: (e) => {
174
+ const g = {
175
+ transform: `translate3d(${-(1 - e) * 20}%, 0, 0)`
166
176
  };
167
- return n && (e.opacity = o), e;
177
+ return n && (g.opacity = e), g;
168
178
  }
169
179
  })
170
180
  } : {
171
- in: (i) => ({
172
- spring: r,
181
+ in: (o) => ({
182
+ spring: a,
173
183
  prepare: () => {
174
- i.style.willChange = n ? "transform, opacity" : "transform", i.style.backfaceVisibility = "hidden", i.style.contain = "layout paint";
184
+ o.style.willChange = n ? "transform, opacity" : "transform", o.style.backfaceVisibility = "hidden", o.style.contain = "layout paint";
175
185
  },
176
186
  css: (c) => {
177
- const o = {
187
+ const e = {
178
188
  transform: `translate3d(${-(1 - c) * 20}%, 0, 0)`
179
189
  };
180
- return n && (o.opacity = c), o;
190
+ return n && (e.opacity = c), e;
181
191
  },
182
192
  onEnd: () => {
183
- i.style.willChange = "auto", i.style.backfaceVisibility = "", i.style.contain = "";
193
+ o.style.willChange = "auto", o.style.backfaceVisibility = "", o.style.contain = "";
184
194
  }
185
195
  }),
186
- out: (i, c) => ({
187
- spring: r,
188
- prepare: (o) => {
189
- x(o, c), o.style.zIndex = "100", o.style.willChange = n ? "transform, opacity" : "transform", o.style.backfaceVisibility = "hidden", o.style.contain = "layout paint", o.style.pointerEvents = "none";
196
+ out: (o, c) => ({
197
+ spring: a,
198
+ prepare: (e) => {
199
+ b(e, c), e.style.zIndex = "100", e.style.willChange = n ? "transform, opacity" : "transform", e.style.backfaceVisibility = "hidden", e.style.contain = "layout paint", e.style.pointerEvents = "none";
190
200
  },
191
- css: (o) => {
192
- const e = {
193
- transform: `translate3d(${(1 - o) * 100}%, 0, 0)`
201
+ css: (e) => {
202
+ const g = {
203
+ transform: `translate3d(${(1 - e) * 100}%, 0, 0)`
194
204
  };
195
- return n && (e.opacity = o), e;
205
+ return n && (g.opacity = e), g;
196
206
  }
197
207
  })
198
208
  };
199
- }, J = { stiffness: 65, damping: 16 }, Q = { stiffness: 65, damping: 14 }, R = 0, It = (t = {}) => {
209
+ }, R = {
210
+ stiffness: 180,
211
+ damping: 20,
212
+ doubleSpring: !0
213
+ }, tt = {
214
+ stiffness: 170,
215
+ damping: 20,
216
+ doubleSpring: !0
217
+ }, nt = 0, Dt = (t = {}) => {
200
218
  const {
201
- inSpring: n = Q,
202
- outSpring: a = J,
203
- transitionDelay: d = R
219
+ inSpring: n = tt,
220
+ outSpring: i = R,
221
+ transitionDelay: d = nt
204
222
  } = t;
205
- let r, s = null;
223
+ let { promise: a, resolve: s } = T();
206
224
  return {
207
225
  in: (l) => ({
208
226
  spring: n,
209
227
  prepare: () => {
210
- l.style.willChange = "opacity";
228
+ l.style.opacity = "0", l.style.willChange = "opacity";
211
229
  },
212
230
  wait: async () => {
213
- r && (await r, await P(d));
231
+ if (a) {
232
+ await a;
233
+ const r = T();
234
+ a = r.promise, s = r.resolve, await F(d);
235
+ }
214
236
  },
215
- css: (i) => ({
216
- opacity: i
237
+ css: (r) => ({
238
+ opacity: r
217
239
  }),
218
240
  onEnd: () => {
219
- l.style.willChange = "auto";
241
+ l.style.willChange = "auto", l.style.opacity = "1";
220
242
  }
221
243
  }),
222
- out: (l, i) => (r = new Promise((c) => {
223
- s = c;
224
- }), {
225
- spring: a,
226
- css: (c) => ({
227
- opacity: c
244
+ out: (l, r) => ({
245
+ spring: i,
246
+ css: (o) => ({
247
+ opacity: o
228
248
  }),
229
249
  prepare: () => {
230
- x(l, i), l.style.willChange = "opacity";
250
+ b(l, r), l.style.willChange = "opacity";
231
251
  },
232
252
  onEnd: () => {
233
253
  s && s(), l.style.willChange = "auto";
234
254
  }
235
255
  })
236
256
  };
237
- }, tt = {
257
+ }, et = {
238
258
  scaleDown: { stiffness: 20, damping: 7 },
239
259
  // Soft start for cinematic scale
240
260
  translate: { stiffness: 15, damping: 7 },
@@ -248,21 +268,21 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
248
268
  // Start when scaleDown is 25% complete
249
269
  scaleUp: 0.8
250
270
  // Start when translate is 70% complete
251
- }, nt = 0.8, et = "white", Ot = (t) => {
252
- var r;
253
- const n = tt, a = nt, d = ((r = t == null ? void 0 : t.border) == null ? void 0 : r.color) ?? et;
271
+ }, it = 0.8, st = "white", Pt = (t) => {
272
+ var a;
273
+ const n = et, i = it, d = ((a = t == null ? void 0 : t.border) == null ? void 0 : a.color) ?? st;
254
274
  return {
255
275
  out: async (s, l) => {
256
- const i = T(l), c = b(document.body, l.positionedParent), o = st(d, {
257
- ...i,
258
- top: c.top
276
+ const r = k(l), o = x(document.body, l.positionedParent), c = at(d, {
277
+ ...r,
278
+ top: o.top
259
279
  }), e = {
260
280
  scale: 1,
261
- translateY: -i.top
262
- }, p = () => {
281
+ translateY: -r.top
282
+ }, g = () => {
263
283
  s.style.transform = `translateY(${e.translateY}px) scale(${e.scale})`;
264
- const y = (i.width - i.width * e.scale) / 2, h = (i.height - i.height * e.scale) / 2;
265
- it(o, y, h);
284
+ const y = (r.width - r.width * e.scale) / 2, h = (r.height - r.height * e.scale) / 2;
285
+ rt(c, y, h);
266
286
  };
267
287
  return {
268
288
  springs: [
@@ -272,7 +292,7 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
272
292
  offset: E.scaleDown,
273
293
  tick: (y) => {
274
294
  const h = 1 - y;
275
- e.scale = 1 - (1 - a) * h, p();
295
+ e.scale = 1 - (1 - i) * h, g();
276
296
  }
277
297
  },
278
298
  // Spring 2: Translate (vertical movement)
@@ -281,7 +301,7 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
281
301
  offset: E.translate,
282
302
  tick: (y) => {
283
303
  const h = 1 - y;
284
- e.translateY = -i.top - i.height * h, p();
304
+ e.translateY = -r.top - r.height * h, g();
285
305
  }
286
306
  },
287
307
  // Spring 3: Scale Up (scale → 1)
@@ -290,30 +310,30 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
290
310
  offset: E.scaleUp,
291
311
  tick: (y) => {
292
312
  const h = 1 - y;
293
- e.scale = a + (1 - a) * h, p();
313
+ e.scale = i + (1 - i) * h, g();
294
314
  }
295
315
  }
296
316
  ],
297
317
  schedule: "stagger",
298
318
  prepare: () => {
299
- x(s), k(s, i), S(s, i), at(s, i);
300
- for (const y of o)
319
+ b(s), _(s, r), I(s, r), lt(s, r);
320
+ for (const y of c)
301
321
  l.positionedParent.appendChild(y);
302
322
  },
303
323
  onEnd: () => {
304
324
  s.style.clipPath = "", s.style.transformOrigin = "", setTimeout(() => {
305
- for (const y of o)
325
+ for (const y of c)
306
326
  l.positionedParent.removeChild(y);
307
327
  }, 1e3);
308
328
  }
309
329
  };
310
330
  },
311
331
  in: async (s, l) => {
312
- const i = T(l), c = {
313
- scale: a,
314
- translateY: -i.top + i.height
315
- }, o = () => {
316
- s.style.transform = `translateY(${c.translateY}px) scale(${c.scale})`;
332
+ const r = k(l), o = {
333
+ scale: i,
334
+ translateY: -r.top + r.height
335
+ }, c = () => {
336
+ s.style.transform = `translateY(${o.translateY}px) scale(${o.scale})`;
317
337
  };
318
338
  return {
319
339
  springs: [
@@ -322,7 +342,7 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
322
342
  spring: n.scaleDown,
323
343
  offset: E.scaleDown,
324
344
  tick: (e) => {
325
- c.scale = 1 - (1 - a) * e, o();
345
+ o.scale = 1 - (1 - i) * e, c();
326
346
  }
327
347
  },
328
348
  // Spring 2: Translate (vertical movement from bottom to top)
@@ -330,7 +350,7 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
330
350
  spring: n.translate,
331
351
  offset: E.translate,
332
352
  tick: (e) => {
333
- c.translateY = -i.top + i.height * (1 - e), o();
353
+ o.translateY = -r.top + r.height * (1 - e), c();
334
354
  }
335
355
  },
336
356
  // Spring 3: Scale Up (scale → 1) - element returns to full size
@@ -338,13 +358,13 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
338
358
  spring: n.scaleUp,
339
359
  offset: E.scaleUp,
340
360
  tick: (e) => {
341
- c.scale = a + (1 - a) * e, o();
361
+ o.scale = i + (1 - i) * e, c();
342
362
  }
343
363
  }
344
364
  ],
345
365
  schedule: "stagger",
346
366
  prepare: () => {
347
- k(s, i), S(s, i), s.style.transform = `translateY(${-i.top + i.height}px) scale(${a})`;
367
+ _(s, r), I(s, r), s.style.transform = `translateY(${-r.top + r.height}px) scale(${i})`;
348
368
  },
349
369
  onEnd: () => {
350
370
  s.style.clipPath = "", s.style.transformOrigin = "", s.style.transform = "";
@@ -353,46 +373,46 @@ const P = (t) => new Promise((n) => setTimeout(n, t)), B = { stiffness: 80, damp
353
373
  }
354
374
  };
355
375
  };
356
- function it(t, n, a) {
357
- const d = n * 0.7, r = a * 0.7;
358
- t.topLeft.style.transform = `translate(${d}px, ${r}px)`, t.topRight.style.transform = `translate(${-d}px, ${r}px)`, t.bottomLeft.style.transform = `translate(${d}px, ${-r}px)`, t.bottomRight.style.transform = `translate(${-d}px, ${-r}px)`;
376
+ function rt(t, n, i) {
377
+ const d = n * 0.7, a = i * 0.7;
378
+ t.topLeft.style.transform = `translate(${d}px, ${a}px)`, t.topRight.style.transform = `translate(${-d}px, ${a}px)`, t.bottomLeft.style.transform = `translate(${d}px, ${-a}px)`, t.bottomRight.style.transform = `translate(${-d}px, ${-a}px)`;
359
379
  }
360
- function st(t = "white", n) {
361
- const r = document.createElement("div");
362
- r.style.position = "fixed", r.style.pointerEvents = "none", r.style.zIndex = "9999", r.style.top = `${n.top - 1}px`, r.style.left = `${n.left - 1}px`, r.style.width = "15px", r.style.height = "15px";
380
+ function at(t = "white", n) {
381
+ const a = document.createElement("div");
382
+ a.style.position = "fixed", a.style.pointerEvents = "none", a.style.zIndex = "9999", a.style.top = `${n.top - 1}px`, a.style.left = `${n.left - 1}px`, a.style.width = "15px", a.style.height = "15px";
363
383
  const s = document.createElement("div");
364
384
  s.style.position = "absolute", s.style.width = "15px", s.style.height = "1px", s.style.backgroundColor = t, s.style.top = "0", s.style.left = "0";
365
385
  const l = document.createElement("div");
366
- l.style.position = "absolute", l.style.width = "1px", l.style.height = "15px", l.style.backgroundColor = t, l.style.top = "0", l.style.left = "0", r.appendChild(s), r.appendChild(l);
367
- const i = document.createElement("div");
368
- i.style.position = "fixed", i.style.pointerEvents = "none", i.style.zIndex = "9999", i.style.top = `${n.top - 1}px`, i.style.left = `${n.left + n.width - 15 + 1}px`, i.style.width = "15px", i.style.height = "15px";
369
- const c = document.createElement("div");
370
- c.style.position = "absolute", c.style.width = "15px", c.style.height = "1px", c.style.backgroundColor = t, c.style.top = "0", c.style.right = "0";
386
+ l.style.position = "absolute", l.style.width = "1px", l.style.height = "15px", l.style.backgroundColor = t, l.style.top = "0", l.style.left = "0", a.appendChild(s), a.appendChild(l);
387
+ const r = document.createElement("div");
388
+ r.style.position = "fixed", r.style.pointerEvents = "none", r.style.zIndex = "9999", r.style.top = `${n.top - 1}px`, r.style.left = `${n.left + n.width - 15 + 1}px`, r.style.width = "15px", r.style.height = "15px";
371
389
  const o = document.createElement("div");
372
- o.style.position = "absolute", o.style.width = "1px", o.style.height = "15px", o.style.backgroundColor = t, o.style.top = "0", o.style.right = "0", i.appendChild(c), i.appendChild(o);
390
+ o.style.position = "absolute", o.style.width = "15px", o.style.height = "1px", o.style.backgroundColor = t, o.style.top = "0", o.style.right = "0";
391
+ const c = document.createElement("div");
392
+ c.style.position = "absolute", c.style.width = "1px", c.style.height = "15px", c.style.backgroundColor = t, c.style.top = "0", c.style.right = "0", r.appendChild(o), r.appendChild(c);
373
393
  const e = document.createElement("div");
374
394
  e.style.position = "fixed", e.style.pointerEvents = "none", e.style.zIndex = "9999", e.style.top = `${n.top + n.height - 15 + 1}px`, e.style.left = `${n.left - 1}px`, e.style.width = "15px", e.style.height = "15px";
375
- const p = document.createElement("div");
376
- p.style.position = "absolute", p.style.width = "15px", p.style.height = "1px", p.style.backgroundColor = t, p.style.bottom = "0", p.style.left = "0";
395
+ const g = document.createElement("div");
396
+ g.style.position = "absolute", g.style.width = "15px", g.style.height = "1px", g.style.backgroundColor = t, g.style.bottom = "0", g.style.left = "0";
377
397
  const y = document.createElement("div");
378
- y.style.position = "absolute", y.style.width = "1px", y.style.height = "15px", y.style.backgroundColor = t, y.style.bottom = "0", y.style.left = "0", e.appendChild(p), e.appendChild(y);
398
+ y.style.position = "absolute", y.style.width = "1px", y.style.height = "15px", y.style.backgroundColor = t, y.style.bottom = "0", y.style.left = "0", e.appendChild(g), e.appendChild(y);
379
399
  const h = document.createElement("div");
380
400
  h.style.position = "fixed", h.style.pointerEvents = "none", h.style.zIndex = "9999", h.style.top = `${n.top + n.height - 15 + 1}px`, h.style.left = `${n.left + n.width - 15 + 1}px`, h.style.width = "15px", h.style.height = "15px";
381
- const g = document.createElement("div");
382
- g.style.position = "absolute", g.style.width = "15px", g.style.height = "1px", g.style.backgroundColor = t, g.style.bottom = "0", g.style.right = "0";
401
+ const p = document.createElement("div");
402
+ p.style.position = "absolute", p.style.width = "15px", p.style.height = "1px", p.style.backgroundColor = t, p.style.bottom = "0", p.style.right = "0";
383
403
  const u = document.createElement("div");
384
- return u.style.position = "absolute", u.style.width = "1px", u.style.height = "15px", u.style.backgroundColor = t, u.style.bottom = "0", u.style.right = "0", h.appendChild(g), h.appendChild(u), {
385
- topLeft: r,
386
- topRight: i,
404
+ return u.style.position = "absolute", u.style.width = "1px", u.style.height = "15px", u.style.backgroundColor = t, u.style.bottom = "0", u.style.right = "0", h.appendChild(p), h.appendChild(u), {
405
+ topLeft: a,
406
+ topRight: r,
387
407
  bottomLeft: e,
388
408
  bottomRight: h,
389
409
  *[Symbol.iterator]() {
390
- yield r, yield i, yield e, yield h;
410
+ yield a, yield r, yield e, yield h;
391
411
  }
392
412
  };
393
413
  }
394
- function T(t) {
395
- const n = b(document.body, t.positionedParent);
414
+ function k(t) {
415
+ const n = x(document.body, t.positionedParent);
396
416
  return {
397
417
  top: t.scroll.y,
398
418
  left: 0,
@@ -400,11 +420,11 @@ function T(t) {
400
420
  height: window.innerHeight - n.top
401
421
  };
402
422
  }
403
- function k(t, n) {
404
- const a = n.left + n.width / 2, d = n.top + n.height / 2;
405
- t.style.transformOrigin = `${a}px ${d}px`;
423
+ function _(t, n) {
424
+ const i = n.left + n.width / 2, d = n.top + n.height / 2;
425
+ t.style.transformOrigin = `${i}px ${d}px`;
406
426
  }
407
- function S(t, n) {
427
+ function I(t, n) {
408
428
  t.style.clipPath = `polygon(
409
429
  ${n.left}px ${n.top}px,
410
430
  ${n.left + n.width}px ${n.top}px,
@@ -412,177 +432,177 @@ function S(t, n) {
412
432
  ${n.left}px ${n.top + n.height}px
413
433
  )`;
414
434
  }
415
- function at(t, n) {
435
+ function lt(t, n) {
416
436
  t.style.transform = `translateY(${-n.top}px)`;
417
437
  }
418
- function rt(t, n) {
438
+ function ot(t, n) {
419
439
  return t.querySelector(`[data-hero-key="${n}"]`);
420
440
  }
421
- const Dt = (t = {}) => {
422
- var l, i;
441
+ const vt = (t = {}) => {
442
+ var l, r;
423
443
  const n = {
424
444
  stiffness: ((l = t.spring) == null ? void 0 : l.stiffness) ?? 300,
425
- damping: ((i = t.spring) == null ? void 0 : i.damping) ?? 30
426
- }, a = t.timeout ?? 300, d = t.maxDistance ?? 700;
427
- let r = null, s = null;
445
+ damping: ((r = t.spring) == null ? void 0 : r.damping) ?? 30
446
+ }, i = t.timeout ?? 300, d = t.maxDistance ?? 700;
447
+ let a = null, s = null;
428
448
  return {
429
- in: async (c, o) => {
430
- const e = c, p = Array.from(e.querySelectorAll("[data-hero-key]"));
431
- if (p.length === 0)
449
+ in: async (o, c) => {
450
+ const e = o, g = Array.from(e.querySelectorAll("[data-hero-key]"));
451
+ if (g.length === 0)
432
452
  return {
433
453
  spring: n,
434
454
  tick: () => {
435
455
  }
436
456
  // No hero elements, skip animation
437
457
  };
438
- if (!await new Promise((g) => {
439
- r ? g(!0) : (s = g, setTimeout(() => {
440
- s = null, g(!1);
441
- }, a));
442
- }) || !r)
443
- return r = null, {
458
+ if (!await new Promise((p) => {
459
+ a ? p(!0) : (s = p, setTimeout(() => {
460
+ s = null, p(!1);
461
+ }, i));
462
+ }) || !a)
463
+ return a = null, {
444
464
  spring: n,
445
465
  tick: () => {
446
466
  }
447
467
  // No fromNode, skip animation
448
468
  };
449
- const h = p.map((g) => {
450
- const u = g.getAttribute("data-hero-key");
469
+ const h = g.map((p) => {
470
+ const u = p.getAttribute("data-hero-key");
451
471
  if (!u) return null;
452
- const m = rt(r, u);
472
+ const m = ot(a, u);
453
473
  if (!m) return null;
454
- const f = g, w = b(r, m), $ = b(e, f), v = w.left - $.left - o.scrollOffset.x, F = w.top - $.top - o.scrollOffset.y, Y = w.width / $.width, U = w.height / $.height, V = f.style.transform, W = f.style.position, z = f.style.transformOrigin, X = f.style.zIndex, M = f.style.willChange;
474
+ const f = p, w = x(a, m), $ = x(e, f), Y = w.left - $.left - c.scrollOffset.x, U = w.top - $.top - c.scrollOffset.y, V = w.width / $.width, W = w.height / $.height, z = f.style.transform, X = f.style.position, M = f.style.transformOrigin, B = f.style.zIndex, H = f.style.willChange;
455
475
  return {
456
476
  toEl: f,
457
- dx: v,
458
- dy: F,
459
- dw: Y,
460
- dh: U,
461
- originalTransform: V,
462
- originalPosition: W,
463
- originalTransformOrigin: z,
464
- originalZIndex: X,
465
- originalWillChange: M
477
+ dx: Y,
478
+ dy: U,
479
+ dw: V,
480
+ dh: W,
481
+ originalTransform: z,
482
+ originalPosition: X,
483
+ originalTransformOrigin: M,
484
+ originalZIndex: B,
485
+ originalWillChange: H
466
486
  };
467
487
  }).filter(
468
- (g) => g !== null && Math.abs(g.dy) <= d
488
+ (p) => p !== null && Math.abs(p.dy) <= d
469
489
  );
470
- return r = null, h.length === 0 ? {
490
+ return a = null, h.length === 0 ? {
471
491
  spring: n,
472
492
  tick: () => {
473
493
  }
474
494
  // No matching hero elements
475
495
  } : {
476
- springs: h.map(({ toEl: g, dx: u, dy: m, dw: f, dh: w }) => ({
496
+ springs: h.map(({ toEl: p, dx: u, dy: m, dw: f, dh: w }) => ({
477
497
  spring: n,
478
498
  tick: ($) => {
479
- g.style.transform = `translate(${(1 - $) * u}px, ${(1 - $) * m}px) scale(${$ + (1 - $) * f}, ${$ + (1 - $) * w})`;
499
+ p.style.transform = `translate(${(1 - $) * u}px, ${(1 - $) * m}px) scale(${$ + (1 - $) * f}, ${$ + (1 - $) * w})`;
480
500
  }
481
501
  })),
482
502
  schedule: "parallel",
483
503
  prepare: () => {
484
- h.forEach(({ toEl: g }) => {
485
- g.style.position = "relative", g.style.transformOrigin = "top left", g.style.zIndex = "1000", g.style.willChange = "transform";
504
+ h.forEach(({ toEl: p }) => {
505
+ p.style.position = "relative", p.style.transformOrigin = "top left", p.style.zIndex = "1000", p.style.willChange = "transform";
486
506
  });
487
507
  },
488
508
  onEnd: () => {
489
509
  h.forEach(
490
510
  ({
491
- toEl: g,
511
+ toEl: p,
492
512
  originalTransform: u,
493
513
  originalPosition: m,
494
514
  originalTransformOrigin: f,
495
515
  originalZIndex: w,
496
516
  originalWillChange: $
497
517
  }) => {
498
- g.style.transform = u, g.style.position = m, g.style.transformOrigin = f, g.style.zIndex = w, g.style.willChange = $;
518
+ p.style.transform = u, p.style.position = m, p.style.transformOrigin = f, p.style.zIndex = w, p.style.willChange = $;
499
519
  }
500
520
  );
501
521
  }
502
522
  };
503
523
  },
504
- out: async (c) => ({
524
+ out: async (o) => ({
505
525
  spring: n,
506
526
  onStart: () => {
507
- r = c, s && (s(!0), s = null);
527
+ a = o, s && (s(!0), s = null);
508
528
  },
509
529
  tick: () => {
510
530
  },
511
- prepare: (o) => {
512
- x(o), o.style.opacity = "0";
531
+ prepare: (c) => {
532
+ b(c), c.style.opacity = "0";
513
533
  }
514
534
  })
515
535
  };
516
536
  };
517
- function lt({
537
+ function ct({
518
538
  detailRect: t,
519
539
  galleryRect: n,
520
- pageRect: a,
540
+ pageRect: i,
521
541
  scrollOffset: d
522
542
  }) {
523
- const r = n.left - t.left + (n.width - t.width) / 2 - d.x, s = n.top - t.top + (n.height - t.height) / 2 - d.y, l = n.width / t.width, i = n.height / t.height, c = Math.max(l, i), o = t.top / a.height * 100, e = (a.width - (t.left + t.width)) / a.width * 100, p = (a.height - (t.top + t.height)) / a.height * 100, y = t.left / a.width * 100;
543
+ const a = n.left - t.left + (n.width - t.width) / 2 - d.x, s = n.top - t.top + (n.height - t.height) / 2 - d.y, l = n.width / t.width, r = n.height / t.height, o = Math.max(l, r), c = t.top / i.height * 100, e = (i.width - (t.left + t.width)) / i.width * 100, g = (i.height - (t.top + t.height)) / i.height * 100, y = t.left / i.width * 100;
524
544
  return {
525
545
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
526
- animate: (g) => {
527
- const u = 1 - g;
546
+ animate: (p) => {
547
+ const u = 1 - p;
528
548
  return {
529
- clipPath: `inset(${o * u}% ${e * u}% ${p * u}% ${y * u}%)`,
530
- transform: `translate(${r * u}px, ${s * u}px) scale(${1 + (c - 1) * u})`
549
+ clipPath: `inset(${c * u}% ${e * u}% ${g * u}% ${y * u}%)`,
550
+ transform: `translate(${a * u}px, ${s * u}px) scale(${1 + (o - 1) * u})`
531
551
  };
532
552
  }
533
553
  };
534
554
  }
535
- function ot({
555
+ function dt({
536
556
  detailRect: t,
537
557
  galleryRect: n,
538
- pageRect: a,
558
+ pageRect: i,
539
559
  scrollOffset: d
540
560
  }) {
541
- const r = n.left - t.left + (n.width - t.width) / 2 + d.x, s = n.top - t.top + (n.height - t.height) / 2 + d.y, l = n.width / t.width, i = n.height / t.height, c = Math.min(l, i), o = t.top / a.height * 100, e = (a.width - (t.left + t.width)) / a.width * 100, p = (a.height - (t.top + t.height)) / a.height * 100, y = t.left / a.width * 100;
561
+ const a = n.left - t.left + (n.width - t.width) / 2 + d.x, s = n.top - t.top + (n.height - t.height) / 2 + d.y, l = n.width / t.width, r = n.height / t.height, o = Math.min(l, r), c = t.top / i.height * 100, e = (i.width - (t.left + t.width)) / i.width * 100, g = (i.height - (t.top + t.height)) / i.height * 100, y = t.left / i.width * 100;
542
562
  return {
543
563
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
544
- animate: (g) => {
545
- const u = 1 - g;
564
+ animate: (p) => {
565
+ const u = 1 - p;
546
566
  return {
547
- clipPath: `inset(${o * u}% ${e * u}% ${p * u}% ${y * u}%)`,
548
- transform: `translate(${r * u - d.x}px, ${s * u - d.y}px) scale(${1 + (c - 1) * u})`
567
+ clipPath: `inset(${c * u}% ${e * u}% ${g * u}% ${y * u}%)`,
568
+ transform: `translate(${a * u - d.x}px, ${s * u - d.y}px) scale(${1 + (o - 1) * u})`
549
569
  };
550
570
  }
551
571
  };
552
572
  }
553
- function ct(t, n, a) {
573
+ function pt(t, n, i) {
554
574
  const d = t.querySelector(
555
575
  "[data-instagram-detail-key]"
556
- ), r = n.querySelector(
576
+ ), a = n.querySelector(
557
577
  "[data-instagram-detail-key]"
558
578
  );
559
579
  if (t.querySelectorAll("[data-instagram-detail-key]").length > 1 || n.querySelectorAll("[data-instagram-detail-key]").length > 1)
560
580
  return null;
561
- let s = null, l = null, i = !1;
562
- if (!d && r) {
563
- l = r;
581
+ let s = null, l = null, r = !1;
582
+ if (!d && a) {
583
+ l = a;
564
584
  const e = l.getAttribute("data-instagram-detail-key");
565
585
  if (!e) return null;
566
586
  s = t.querySelector(
567
587
  `[data-instagram-gallery-key="${e}"]`
568
- ), s && (i = !0);
569
- } else if (d && !r) {
588
+ ), s && (r = !0);
589
+ } else if (d && !a) {
570
590
  l = d;
571
591
  const e = l.getAttribute("data-instagram-detail-key");
572
592
  if (!e) return null;
573
593
  s = n.querySelector(
574
594
  `[data-instagram-gallery-key="${e}"]`
575
- ), s && (i = !1);
595
+ ), s && (r = !1);
576
596
  }
577
597
  if (!s || !l)
578
598
  return null;
579
- const c = b(i ? t : n, s), o = b(i ? n : t, l);
580
- if (i) {
581
- const e = lt({
582
- detailRect: o,
583
- galleryRect: c,
599
+ const o = x(r ? t : n, s), c = x(r ? n : t, l);
600
+ if (r) {
601
+ const e = ct({
602
+ detailRect: c,
603
+ galleryRect: o,
584
604
  pageRect: n.getBoundingClientRect(),
585
- scrollOffset: a
605
+ scrollOffset: i
586
606
  });
587
607
  return n.style.transformOrigin = e.transformOrigin, {
588
608
  isEnterMode: !0,
@@ -590,11 +610,11 @@ function ct(t, n, a) {
590
610
  // No outAnimation - gallery stays visible
591
611
  };
592
612
  } else {
593
- const e = ot({
594
- detailRect: o,
595
- galleryRect: c,
613
+ const e = dt({
614
+ detailRect: c,
615
+ galleryRect: o,
596
616
  pageRect: t.getBoundingClientRect(),
597
- scrollOffset: a
617
+ scrollOffset: i
598
618
  });
599
619
  return t.style.transformOrigin = e.transformOrigin, {
600
620
  isEnterMode: !1,
@@ -603,336 +623,369 @@ function ct(t, n, a) {
603
623
  };
604
624
  }
605
625
  }
606
- const Pt = (t = {}) => {
607
- var i, c;
626
+ const Ft = (t = {}) => {
627
+ var r, o, c;
608
628
  const n = {
609
- stiffness: ((i = t.spring) == null ? void 0 : i.stiffness) ?? 150,
610
- damping: ((c = t.spring) == null ? void 0 : c.damping) ?? 20
611
- }, a = t.timeout ?? 300;
612
- let d = null, r = null, s = null, l = null;
629
+ stiffness: ((r = t.spring) == null ? void 0 : r.stiffness) ?? 150,
630
+ damping: ((o = t.spring) == null ? void 0 : o.damping) ?? 20,
631
+ doubleSpring: ((c = t.spring) == null ? void 0 : c.doubleSpring) ?? !0
632
+ }, i = t.timeout ?? 300;
633
+ let d = null, a = null, s = null, l = null;
613
634
  return {
614
- in: async (o, { scrollOffset: e }) => {
615
- const p = o;
616
- return !await new Promise((h) => {
617
- d ? h(!0) : (r = h, setTimeout(() => {
618
- r = null, h(!1);
619
- }, a));
635
+ in: async (e, { scrollOffset: g }) => {
636
+ const y = e;
637
+ return !await new Promise((p) => {
638
+ d ? p(!0) : (a = p, setTimeout(() => {
639
+ a = null, p(!1);
640
+ }, i));
620
641
  }) || !d ? (l == null || l(), l = null, d = null, {
621
642
  spring: n,
622
643
  css: () => ({})
623
- }) : (s = ct(d, p, e), l == null || l(), l = null, s ? (d = null, {
644
+ }) : (s = pt(d, y, g), l == null || l(), l = null, s ? (d = null, {
624
645
  spring: n,
625
- css: (h) => s != null && s.inAnimation ? s.inAnimation(h) : {}
646
+ css: (p) => s != null && s.inAnimation ? s.inAnimation(p) : {}
626
647
  }) : (d = null, {
627
648
  spring: n,
628
649
  css: () => ({})
629
650
  }));
630
651
  },
631
- out: async (o, e) => {
632
- const p = new Promise((y) => {
633
- l = y;
652
+ out: async (e, g) => {
653
+ const y = new Promise((h) => {
654
+ l = h;
634
655
  });
635
656
  return {
636
657
  spring: n,
637
- prepare: (y) => {
638
- s != null && s.isEnterMode ? x(y) : (x(y, e), y.style.zIndex = "-1");
658
+ prepare: (h) => {
659
+ s != null && s.isEnterMode ? b(h) : (b(h, g), h.style.zIndex = "-1");
639
660
  },
640
661
  wait: async () => {
641
- d = o, r && (r(!0), r = null), await p;
662
+ d = e, a && (a(!0), a = null), await y;
642
663
  },
643
- css: (y) => s != null && s.outAnimation ? s.outAnimation(y) : {}
664
+ css: (h) => s != null && s.outAnimation ? s.outAnimation(h) : {}
644
665
  };
645
666
  }
646
667
  };
647
668
  };
648
- function dt({
669
+ function ht({
649
670
  detailRect: t,
650
671
  galleryRect: n,
651
- pageRect: a,
672
+ pageRect: i,
652
673
  scrollOffset: d
653
674
  }) {
654
- const r = n.left - t.left + (n.width - t.width) / 2 - d.x, s = n.top - t.top + (n.height - t.height) / 2 - d.y, l = n.width / t.width, i = n.height / t.height, c = Math.max(l, i), o = t.top / a.height * 100, e = (a.width - (t.left + t.width)) / a.width * 100, p = (a.height - (t.top + t.height)) / a.height * 100, y = t.left / a.width * 100;
675
+ const a = n.left - t.left + (n.width - t.width) / 2 - d.x, s = n.top - t.top + (n.height - t.height) / 2 - d.y, l = n.width / t.width, r = n.height / t.height, o = Math.max(l, r), c = t.top / i.height * 100, e = (i.width - (t.left + t.width)) / i.width * 100, g = (i.height - (t.top + t.height)) / i.height * 100, y = t.left / i.width * 100;
655
676
  return {
656
677
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
657
- animate: (g) => {
658
- const u = 1 - g;
678
+ animate: (p) => {
679
+ const u = 1 - p;
659
680
  return {
660
- clipPath: `inset(${o * u}% ${e * u}% ${p * u}% ${y * u}%)`,
661
- transform: `translate(${r * u}px, ${s * u}px) scale(${1 + (c - 1) * u})`
681
+ clipPath: `inset(${c * u}% ${e * u}% ${g * u}% ${y * u}%)`,
682
+ transform: `translate(${a * u}px, ${s * u}px) scale(${1 + (o - 1) * u})`
662
683
  };
663
684
  }
664
685
  };
665
686
  }
666
- function ht({
687
+ function yt({
667
688
  galleryRect: t,
668
689
  detailRect: n,
669
- scrollOffset: a
690
+ scrollOffset: i
670
691
  }) {
671
- const d = n.left - t.left + (n.width - t.width) / 2 + a.x, r = n.top - t.top + (n.height - t.height) / 2 + a.y, s = n.width / t.width, l = n.height / t.height, i = Math.max(s, l);
692
+ const d = n.left - t.left + (n.width - t.width) / 2 + i.x, a = n.top - t.top + (n.height - t.height) / 2 + i.y, s = n.width / t.width, l = n.height / t.height, r = Math.max(s, l);
672
693
  return {
673
694
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
674
- animate: (o) => {
675
- const e = 1 - o;
695
+ animate: (c) => {
696
+ const e = 1 - c;
676
697
  return {
677
- transform: `translate(${d * e - a.x}px, ${r * e - a.y}px) scale(${1 + (i - 1) * e})`,
698
+ transform: `translate(${d * e - i.x}px, ${a * e - i.y}px) scale(${1 + (r - 1) * e})`,
678
699
  opacity: `${1 - e}`
679
700
  };
680
701
  }
681
702
  };
682
703
  }
683
- function pt({
704
+ function gt({
684
705
  galleryRect: t,
685
706
  detailRect: n,
686
- scrollOffset: a
707
+ scrollOffset: i
687
708
  }) {
688
- const d = n.left - t.left + (n.width - t.width) / 2 - a.x, r = n.top - t.top + (n.height - t.height) / 2 - a.y, s = n.width / t.width, l = n.height / t.height, i = Math.max(s, l);
709
+ const d = n.left - t.left + (n.width - t.width) / 2 - i.x, a = n.top - t.top + (n.height - t.height) / 2 - i.y, s = n.width / t.width, l = n.height / t.height, r = Math.max(s, l);
689
710
  return {
690
711
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
691
- animate: (o) => {
692
- const e = 1 - o, p = o;
712
+ animate: (c) => {
713
+ const e = 1 - c, g = c;
693
714
  return {
694
- transform: `translate(${d * e}px, ${r * e}px) scale(${1 + (i - 1) * e})`,
695
- opacity: `${p}`
715
+ transform: `translate(${d * e}px, ${a * e}px) scale(${1 + (r - 1) * e})`,
716
+ opacity: `${g}`
696
717
  };
697
718
  }
698
719
  };
699
720
  }
700
- function yt({
721
+ function ut({
701
722
  detailRect: t,
702
723
  galleryRect: n,
703
- pageRect: a,
724
+ pageRect: i,
704
725
  scrollOffset: d
705
726
  }) {
706
- const r = n.left - t.left + (n.width - t.width) / 2 + d.x, s = n.top - t.top + (n.height - t.height) / 2 + d.y, l = n.width / t.width, i = n.height / t.height, c = Math.min(l, i), o = t.top / a.height * 100, e = (a.width - (t.left + t.width)) / a.width * 100, p = (a.height - (t.top + t.height)) / a.height * 100, y = t.left / a.width * 100;
727
+ const a = n.left - t.left + (n.width - t.width) / 2 + d.x, s = n.top - t.top + (n.height - t.height) / 2 + d.y, l = n.width / t.width, r = n.height / t.height, o = Math.min(l, r), c = t.top / i.height * 100, e = (i.width - (t.left + t.width)) / i.width * 100, g = (i.height - (t.top + t.height)) / i.height * 100, y = t.left / i.width * 100;
707
728
  return {
708
729
  transformOrigin: `${t.left + t.width / 2}px ${t.top + t.height / 2}px`,
709
- animate: (g) => {
710
- const u = 1 - g;
730
+ animate: (p) => {
731
+ const u = 1 - p;
711
732
  return {
712
- clipPath: `inset(${o * u}% ${e * u}% ${p * u}% ${y * u}%)`,
713
- transform: `translate(${r * u - d.x}px, ${s * u - d.y}px) scale(${1 + (c - 1) * u})`
733
+ clipPath: `inset(${c * u}% ${e * u}% ${g * u}% ${y * u}%)`,
734
+ transform: `translate(${a * u - d.x}px, ${s * u - d.y}px) scale(${1 + (o - 1) * u})`
714
735
  };
715
736
  }
716
737
  };
717
738
  }
718
- function gt(t, n, a) {
739
+ function ft(t, n, i) {
719
740
  const d = t.querySelector(
720
741
  "[data-pinterest-detail-key]"
721
- ), r = n.querySelector(
742
+ ), a = n.querySelector(
722
743
  "[data-pinterest-detail-key]"
723
744
  );
724
745
  if (t.querySelectorAll("[data-pinterest-detail-key]").length > 1 || n.querySelectorAll("[data-pinterest-detail-key]").length > 1)
725
746
  return null;
726
- let s = null, l = null, i = !1;
727
- if (!d && r) {
728
- l = r;
747
+ let s = null, l = null, r = !1;
748
+ if (!d && a) {
749
+ l = a;
729
750
  const e = l.getAttribute("data-pinterest-detail-key");
730
751
  if (!e) return null;
731
752
  s = t.querySelector(
732
753
  `[data-pinterest-gallery-key="${e}"]`
733
- ), s && (i = !0);
734
- } else if (d && !r) {
754
+ ), s && (r = !0);
755
+ } else if (d && !a) {
735
756
  l = d;
736
757
  const e = l.getAttribute("data-pinterest-detail-key");
737
758
  if (!e) return null;
738
759
  s = n.querySelector(
739
760
  `[data-pinterest-gallery-key="${e}"]`
740
- ), s && (i = !1);
761
+ ), s && (r = !1);
741
762
  }
742
763
  if (!s || !l)
743
764
  return null;
744
- const c = b(i ? t : n, s), o = b(i ? n : t, l);
745
- if (i) {
746
- const e = dt({
747
- detailRect: o,
748
- galleryRect: c,
765
+ const o = x(r ? t : n, s), c = x(r ? n : t, l);
766
+ if (r) {
767
+ const e = ht({
768
+ detailRect: c,
769
+ galleryRect: o,
749
770
  pageRect: n.getBoundingClientRect(),
750
- scrollOffset: a
751
- }), p = ht({
752
- galleryRect: c,
753
- detailRect: o,
754
- scrollOffset: a
771
+ scrollOffset: i
772
+ }), g = yt({
773
+ galleryRect: o,
774
+ detailRect: c,
775
+ scrollOffset: i
755
776
  });
756
- return n.style.transformOrigin = e.transformOrigin, t.style.transformOrigin = p.transformOrigin, {
777
+ return n.style.transformOrigin = e.transformOrigin, t.style.transformOrigin = g.transformOrigin, {
757
778
  inAnimation: e.animate,
758
- outAnimation: p.animate
779
+ outAnimation: g.animate
759
780
  };
760
781
  } else {
761
- const e = pt({
762
- galleryRect: c,
763
- detailRect: o,
764
- scrollOffset: a
765
- }), p = yt({
766
- detailRect: o,
767
- galleryRect: c,
782
+ const e = gt({
783
+ galleryRect: o,
784
+ detailRect: c,
785
+ scrollOffset: i
786
+ }), g = ut({
787
+ detailRect: c,
788
+ galleryRect: o,
768
789
  pageRect: t.getBoundingClientRect(),
769
- scrollOffset: a
790
+ scrollOffset: i
770
791
  });
771
- return n.style.transformOrigin = e.transformOrigin, t.style.transformOrigin = p.transformOrigin, {
792
+ return n.style.transformOrigin = e.transformOrigin, t.style.transformOrigin = g.transformOrigin, {
772
793
  inAnimation: e.animate,
773
- outAnimation: p.animate
794
+ outAnimation: g.animate
774
795
  };
775
796
  }
776
797
  }
777
- const vt = (t = {}) => {
778
- var i, c;
798
+ const Yt = (t = {}) => {
799
+ var r, o, c;
779
800
  const n = {
780
- stiffness: ((i = t.spring) == null ? void 0 : i.stiffness) ?? 30,
781
- damping: ((c = t.spring) == null ? void 0 : c.damping) ?? 10
782
- }, a = t.timeout ?? 300;
783
- let d = null, r = null, s = null, l = null;
801
+ stiffness: ((r = t.spring) == null ? void 0 : r.stiffness) ?? 30,
802
+ damping: ((o = t.spring) == null ? void 0 : o.damping) ?? 10,
803
+ doubleSpring: ((c = t.spring) == null ? void 0 : c.doubleSpring) ?? !0
804
+ }, i = t.timeout ?? 300;
805
+ let d = null, a = null, s = null, l = null;
784
806
  return {
785
- in: async (o, { scrollOffset: e }) => {
786
- const p = o;
787
- return !await new Promise((h) => {
788
- d ? h(!0) : (r = h, setTimeout(() => {
789
- r = null, h(!1);
790
- }, a));
807
+ in: async (e, { scrollOffset: g }) => {
808
+ const y = e;
809
+ return !await new Promise((p) => {
810
+ d ? p(!0) : (a = p, setTimeout(() => {
811
+ a = null, p(!1);
812
+ }, i));
791
813
  }) || !d ? (l == null || l(), l = null, d = null, {
792
814
  spring: n,
793
815
  css: () => ({})
794
- }) : (s = gt(d, p, e), l == null || l(), l = null, s ? (d = null, {
816
+ }) : (s = ft(d, y, g), l == null || l(), l = null, s ? (d = null, {
795
817
  spring: n,
796
- css: (h) => s ? s.inAnimation(h) : {}
818
+ css: (p) => s ? s.inAnimation(p) : {}
797
819
  }) : (d = null, {
798
820
  spring: n,
799
821
  css: () => ({})
800
822
  }));
801
823
  },
802
- out: async (o) => {
803
- const e = new Promise((p) => {
804
- l = p;
824
+ out: async (e) => {
825
+ const g = new Promise((y) => {
826
+ l = y;
805
827
  });
806
828
  return {
807
829
  spring: n,
808
- prepare: (p) => {
809
- x(p), p.style.zIndex = "-1";
830
+ prepare: (y) => {
831
+ b(y), y.style.zIndex = "-1";
810
832
  },
811
833
  wait: async () => {
812
- d = o, r && (r(!0), r = null), await e;
834
+ d = e, a && (a(!0), a = null), await g;
813
835
  },
814
- css: (p) => s ? s.outAnimation(p) : {}
836
+ css: (y) => s ? s.outAnimation(y) : {}
815
837
  };
816
838
  }
817
839
  };
818
- }, _ = {
840
+ }, O = { stiffness: 100, damping: 30 }, Ut = () => ({
841
+ in: (t) => ({
842
+ spring: O,
843
+ prepare: () => {
844
+ t.style.opacity = "0", t.style.transform = "rotate(-180deg)", t.style.transformOrigin = "center center", t.style.willChange = "transform, opacity";
845
+ },
846
+ css: (n) => ({
847
+ // -180deg → 0deg, show after 90deg (progress > 0.5)
848
+ transform: `rotate(${(n - 1) * 180}deg)`,
849
+ opacity: n > 0.5 ? 1 : 0
850
+ }),
851
+ onEnd: () => {
852
+ t.style.willChange = "auto", t.style.transform = "", t.style.transformOrigin = "", t.style.opacity = "";
853
+ }
854
+ }),
855
+ out: (t, n) => ({
856
+ spring: O,
857
+ prepare: () => {
858
+ b(t, n), t.style.transformOrigin = "center center", t.style.willChange = "transform, opacity";
859
+ },
860
+ css: (i) => ({
861
+ // 0deg → 180deg, hide after 90deg (progress < 0.5)
862
+ transform: `rotate(${(1 - i) * 180}deg)`,
863
+ opacity: i > 0.5 ? 1 : 0
864
+ }),
865
+ onEnd: () => {
866
+ t.style.willChange = "auto";
867
+ }
868
+ })
869
+ }), D = {
819
870
  stiffness: 5,
820
871
  damping: 4
821
- }, Ft = (t = {}) => {
822
- var c, o;
823
- const n = t.direction ?? "up", a = {
824
- stiffness: ((c = t.spring) == null ? void 0 : c.stiffness) ?? _.stiffness,
825
- damping: ((o = t.spring) == null ? void 0 : o.damping) ?? _.damping
872
+ }, Vt = (t = {}) => {
873
+ var o, c;
874
+ const n = t.direction ?? "up", i = {
875
+ stiffness: ((o = t.spring) == null ? void 0 : o.stiffness) ?? D.stiffness,
876
+ damping: ((c = t.spring) == null ? void 0 : c.damping) ?? D.damping
826
877
  }, d = n === "up";
827
- let r = null, s = null, l = null;
828
- const i = () => {
829
- if (r === null || s === null)
878
+ let a = null, s = null, l = null;
879
+ const r = () => {
880
+ if (a === null || s === null)
830
881
  return null;
831
- const e = Math.min(r, s), p = window.innerHeight;
832
- return Math.max(e, p);
882
+ const e = Math.min(a, s), g = window.innerHeight;
883
+ return Math.max(e, g);
833
884
  };
834
885
  return {
835
- in: (e) => (s = e.offsetHeight, r !== null && (l = i()), {
836
- spring: a,
886
+ in: (e) => (s = e.offsetHeight, a !== null && (l = r()), {
887
+ spring: i,
837
888
  prepare: () => {
838
889
  e.style.willChange = "transform", e.style.backfaceVisibility = "hidden", e.style.contain = "layout paint";
839
890
  },
840
- tick: (p) => {
841
- l === null && (l = i());
842
- const y = l ?? window.innerHeight, h = d ? (1 - p) * y : (1 - p) * -y;
891
+ tick: (g) => {
892
+ l === null && (l = r());
893
+ const y = l ?? window.innerHeight, h = d ? (1 - g) * y : (1 - g) * -y;
843
894
  e.style.transform = `translate3d(0, ${h}px, 0)`;
844
895
  },
845
896
  onEnd: () => {
846
897
  e.style.willChange = "auto", e.style.backfaceVisibility = "", e.style.contain = "";
847
898
  }
848
899
  }),
849
- out: (e, p) => ({
850
- spring: a,
900
+ out: (e, g) => ({
901
+ spring: i,
851
902
  onStart: () => {
852
- r = e.offsetHeight, s !== null && (l = i());
903
+ a = e.offsetHeight, s !== null && (l = r());
853
904
  },
854
905
  tick: (y) => {
855
- l === null && (l = i());
856
- const h = l ?? window.innerHeight, g = d ? (1 - y) * -h : (1 - y) * h;
857
- e.style.transform = `translate3d(0, ${g}px, 0)`;
906
+ l === null && (l = r());
907
+ const h = l ?? window.innerHeight, p = d ? (1 - y) * -h : (1 - y) * h;
908
+ e.style.transform = `translate3d(0, ${p}px, 0)`;
858
909
  },
859
910
  prepare: (y) => {
860
- x(y, p), y.style.zIndex = d ? "-1" : "1", y.style.willChange = "transform", y.style.backfaceVisibility = "hidden", y.style.contain = "layout paint", y.style.pointerEvents = "none";
911
+ b(y, g), y.style.zIndex = d ? "-1" : "1", y.style.willChange = "transform", y.style.backfaceVisibility = "hidden", y.style.contain = "layout paint", y.style.pointerEvents = "none";
861
912
  }
862
913
  })
863
914
  };
864
- }, I = {
915
+ }, S = {
865
916
  stiffness: 15,
866
- damping: 7
867
- }, Yt = (t = {}) => {
868
- var r, s;
869
- const n = t.direction ?? "left", a = {
870
- stiffness: ((r = t.spring) == null ? void 0 : r.stiffness) ?? I.stiffness,
871
- damping: ((s = t.spring) == null ? void 0 : s.damping) ?? I.damping
917
+ damping: 7,
918
+ doubleSpring: !0
919
+ }, Wt = (t = {}) => {
920
+ var a, s, l;
921
+ const n = t.direction ?? "left", i = {
922
+ stiffness: ((a = t.spring) == null ? void 0 : a.stiffness) ?? S.stiffness,
923
+ damping: ((s = t.spring) == null ? void 0 : s.damping) ?? S.damping,
924
+ doubleSpring: ((l = t.spring) == null ? void 0 : l.doubleSpring) ?? S.doubleSpring
872
925
  }, d = n === "left";
873
926
  return {
874
- in: (l) => ({
875
- spring: a,
927
+ in: (r) => ({
928
+ spring: i,
876
929
  prepare: () => {
877
- l.style.willChange = "transform", l.style.backfaceVisibility = "hidden", l.style.contain = "layout paint";
930
+ r.style.willChange = "transform", r.style.backfaceVisibility = "hidden", r.style.contain = "layout paint";
878
931
  },
879
- css: (i) => ({
880
- transform: `translate3d(${d ? (1 - i) * 100 : (1 - i) * -100}%, 0, 0)`
932
+ css: (o) => ({
933
+ transform: `translate3d(${d ? (1 - o) * 100 : (1 - o) * -100}%, 0, 0)`
881
934
  }),
882
935
  onEnd: () => {
883
- l.style.willChange = "auto", l.style.backfaceVisibility = "", l.style.contain = "";
936
+ r.style.willChange = "auto", r.style.backfaceVisibility = "", r.style.contain = "";
884
937
  }
885
938
  }),
886
- out: (l, i) => ({
887
- spring: a,
939
+ out: (r, o) => ({
940
+ spring: i,
888
941
  css: (c) => ({
889
942
  transform: `translate3d(${d ? (1 - c) * -100 : (1 - c) * 100}%, 0, 0)`
890
943
  }),
891
944
  prepare: (c) => {
892
- x(c, i), c.style.willChange = "transform", c.style.backfaceVisibility = "hidden", c.style.contain = "layout paint", c.style.pointerEvents = "none";
945
+ b(c, o), c.style.willChange = "transform", c.style.backfaceVisibility = "hidden", c.style.contain = "layout paint", c.style.pointerEvents = "none";
893
946
  }
894
947
  })
895
948
  };
896
- }, O = { stiffness: 17, damping: 6 }, L = 20, C = 800, Ut = () => {
949
+ }, P = { stiffness: 17, damping: 6 }, L = 20, C = 800, zt = () => {
897
950
  let t, n = null;
898
951
  return {
899
- in: (a) => ({
900
- spring: O,
952
+ in: (i) => ({
953
+ spring: P,
901
954
  prepare: () => {
902
- a.style.willChange = "transform", a.style.backfaceVisibility = "hidden", a.style.contain = "layout paint", a.style.transform = `perspective(${C}px) rotateY(${L}deg) translate3d(-100%, 0, 0)`;
955
+ i.style.willChange = "transform", i.style.backfaceVisibility = "hidden", i.style.contain = "layout paint", i.style.transform = `perspective(${C}px) rotateY(${L}deg) translate3d(-100%, 0, 0)`;
903
956
  },
904
957
  wait: async () => {
905
958
  t && await t;
906
959
  },
907
960
  css: (d) => {
908
- const r = (1 - d) * L, s = -(1 - d) * 100;
961
+ const a = (1 - d) * L, s = -(1 - d) * 100;
909
962
  return {
910
- transform: `perspective(${C}px) rotateY(${r}deg) translate3d(${s}%, 0, 0)`
963
+ transform: `perspective(${C}px) rotateY(${a}deg) translate3d(${s}%, 0, 0)`
911
964
  };
912
965
  },
913
966
  onEnd: () => {
914
- a.style.transform = "", a.style.willChange = "auto", a.style.backfaceVisibility = "", a.style.contain = "";
967
+ i.style.transform = "", i.style.willChange = "auto", i.style.backfaceVisibility = "", i.style.contain = "";
915
968
  }
916
969
  }),
917
- out: (a, d) => (t = new Promise((r) => {
918
- n = r;
970
+ out: (i, d) => (t = new Promise((a) => {
971
+ n = a;
919
972
  }), {
920
- spring: O,
921
- prepare: (r) => {
922
- x(r, d), r.style.willChange = "transform", r.style.backfaceVisibility = "hidden", r.style.contain = "layout paint", r.style.pointerEvents = "none", r.style.transform = `perspective(${C}px) rotateY(0deg) translate3d(0%, 0, 0)`;
973
+ spring: P,
974
+ prepare: (a) => {
975
+ b(a, d), a.style.willChange = "transform", a.style.backfaceVisibility = "hidden", a.style.contain = "layout paint", a.style.pointerEvents = "none", a.style.transform = `perspective(${C}px) rotateY(0deg) translate3d(0%, 0, 0)`;
923
976
  },
924
- css: (r) => {
925
- const s = 1 - r, l = s * L, i = s * 100;
977
+ css: (a) => {
978
+ const s = 1 - a, l = s * L, r = s * 100;
926
979
  return {
927
- transform: `perspective(${C}px) rotateY(${-l}deg) translate3d(${i}%, 0, 0)`
980
+ transform: `perspective(${C}px) rotateY(${-l}deg) translate3d(${r}%, 0, 0)`
928
981
  };
929
982
  },
930
983
  onEnd: () => {
931
- n && n(), a.style.transform = "";
984
+ n && n(), i.style.transform = "";
932
985
  }
933
986
  })
934
987
  };
935
- }, ut = { stiffness: 1, damping: 1 }, ft = { stiffness: 20, damping: 25 }, $t = "#000000", mt = "circle", D = "CURTAIN_REVEAL_OVERLAY_ID", wt = {
988
+ }, $t = { stiffness: 1, damping: 1 }, mt = { stiffness: 20, damping: 25 }, wt = "#000000", bt = "circle", v = "CURTAIN_REVEAL_OVERLAY_ID", xt = {
936
989
  position: "fixed",
937
990
  inset: "0",
938
991
  width: "100vw",
@@ -942,17 +995,17 @@ const vt = (t = {}) => {
942
995
  alignItems: "center",
943
996
  justifyContent: "center",
944
997
  overflow: "hidden"
945
- }, xt = {
998
+ }, Et = {
946
999
  position: "relative",
947
1000
  display: "inline-block",
948
1001
  height: "5.5rem",
949
1002
  overflow: "hidden"
950
- }, bt = {
1003
+ }, Ct = {
951
1004
  display: "flex",
952
1005
  height: "100%",
953
1006
  willChange: "transform",
954
1007
  transition: "transform 0.3s ease"
955
- }, Et = {
1008
+ }, At = {
956
1009
  display: "inline-flex",
957
1010
  alignItems: "center",
958
1011
  justifyContent: "center",
@@ -961,104 +1014,105 @@ const vt = (t = {}) => {
961
1014
  fontWeight: "900",
962
1015
  letterSpacing: "0.02em",
963
1016
  color: "#FFFFFF"
964
- }, Ct = 0.4, A = 0.5, At = 0.2;
965
- function Lt(t, n) {
1017
+ }, St = 0.4, A = 0.5, Lt = 0.2;
1018
+ function Tt(t, n) {
966
1019
  switch (t) {
967
1020
  case "circle":
968
1021
  return `circle(${n * 100}% at 50% 50%)`;
969
1022
  case "square":
970
1023
  return `inset(${(1 - n) * 50}% round ${10 * n}%)`;
971
1024
  case "triangle": {
972
- const a = n * 100;
973
- return `polygon(50% ${50 - a}%, ${50 - a}% ${50 + a}%, ${50 + a}% ${50 + a}%)`;
1025
+ const i = n * 100;
1026
+ return `polygon(50% ${50 - i}%, ${50 - i}% ${50 + i}%, ${50 + i}% ${50 + i}%)`;
974
1027
  }
975
1028
  }
976
1029
  }
977
- const Tt = (t) => t.reduce((n, a) => n + a, 0), Vt = (t = {}) => {
1030
+ const kt = (t) => t.reduce((n, i) => n + i, 0), Xt = (t = {}) => {
978
1031
  const {
979
- background: n = $t,
980
- texts: a = [],
981
- shape: d = mt,
982
- inSpring: r = ft,
983
- outSpring: s = ut,
1032
+ background: n = wt,
1033
+ texts: i = [],
1034
+ shape: d = bt,
1035
+ inSpring: a = mt,
1036
+ outSpring: s = $t,
984
1037
  textStyle: l = {}
985
1038
  } = t;
986
1039
  return {
987
- out: (i, c) => {
988
- const o = i.style.opacity;
1040
+ out: (r, o) => {
1041
+ const c = r.style.opacity;
989
1042
  return {
990
1043
  spring: s,
991
1044
  from: 1,
992
1045
  to: 0,
993
1046
  prepare: (e) => {
994
- x(e, c), e.style.opacity = "1";
1047
+ b(e, o), e.style.opacity = "1";
995
1048
  },
996
1049
  tick: (e) => {
997
- const p = Math.max(0, e - Ct);
998
- i.style.opacity = String(p);
1050
+ const g = Math.max(0, e - St);
1051
+ r.style.opacity = String(g);
999
1052
  },
1000
1053
  onEnd: () => {
1001
- i.style.opacity = o;
1054
+ r.style.opacity = c;
1002
1055
  }
1003
1056
  };
1004
1057
  },
1005
- in: (i) => {
1006
- let c = null, o = null, e = null;
1007
- const p = document.body.style.overflow, y = document.getElementById(
1008
- D
1058
+ in: (r) => {
1059
+ let o = null, c = null, e = null;
1060
+ const g = document.body.style.overflow, y = document.getElementById(
1061
+ v
1009
1062
  );
1010
1063
  let h = [];
1011
- const g = () => {
1012
- c = document.createElement("div"), c.id = D, Object.assign(c.style, wt, { background: n }), document.body.appendChild(c), o = document.createElement("div"), Object.assign(o.style, xt), c.appendChild(o), e = document.createElement("div"), Object.assign(e.style, bt), o.appendChild(e), a.forEach((u) => {
1064
+ const p = () => {
1065
+ o = document.createElement("div"), o.id = v, Object.assign(o.style, xt, { background: n }), document.body.appendChild(o), c = document.createElement("div"), Object.assign(c.style, Et), o.appendChild(c), e = document.createElement("div"), Object.assign(e.style, Ct), c.appendChild(e), i.forEach((u) => {
1013
1066
  const m = document.createElement("div");
1014
- m.textContent = u, Object.assign(m.style, Et, l), e.appendChild(m);
1067
+ m.textContent = u, Object.assign(m.style, At, l), e.appendChild(m);
1015
1068
  }), h = Array.from(e.children).map(
1016
1069
  (u) => u.getBoundingClientRect().width
1017
1070
  );
1018
1071
  };
1019
1072
  return {
1020
- spring: r,
1073
+ spring: a,
1021
1074
  from: 0,
1022
1075
  to: 1,
1023
1076
  prepare: () => {
1024
- document.body.style.overflow = "hidden", i.style.opacity = "1", y == null || y.remove(), g(), c && o && (c.style.clipPath = "none", o.style.transform = "scale(1)");
1077
+ document.body.style.overflow = "hidden", r.style.opacity = "1", y == null || y.remove(), p(), o && c && (o.style.clipPath = "none", c.style.transform = "scale(1)");
1025
1078
  },
1026
1079
  tick: (u) => {
1027
- if (!(!c || !o || !e)) {
1028
- if (u <= A && a.length > 0) {
1080
+ if (!(!o || !c || !e)) {
1081
+ if (u <= A && i.length > 0) {
1029
1082
  const m = u / A, f = Math.min(
1030
- Math.floor(m * a.length),
1031
- a.length - 1
1032
- ), w = h[f] ?? 0, $ = Tt(h.slice(0, f));
1033
- o.style.width = `${w}px`, e.style.transform = `translateX(-${$}px)`;
1083
+ Math.floor(m * i.length),
1084
+ i.length - 1
1085
+ ), w = h[f] ?? 0, $ = kt(h.slice(0, f));
1086
+ c.style.width = `${w}px`, e.style.transform = `translateX(-${$}px)`;
1034
1087
  }
1035
1088
  if (u > A) {
1036
1089
  const f = 1 - Math.max(
1037
1090
  0,
1038
- Math.min(1, (u - A) / At)
1091
+ Math.min(1, (u - A) / Lt)
1039
1092
  );
1040
- c.style.clipPath = Lt(d, f), o.style.transform = `scale(${f})`;
1093
+ o.style.clipPath = Tt(d, f), c.style.transform = `scale(${f})`;
1041
1094
  }
1042
1095
  }
1043
1096
  },
1044
1097
  onEnd: () => {
1045
- c == null || c.remove(), c = o = e = null, document.body.style.overflow = p;
1098
+ o == null || o.remove(), o = c = e = null, document.body.style.overflow = g;
1046
1099
  }
1047
1100
  };
1048
1101
  }
1049
1102
  };
1050
1103
  };
1051
1104
  export {
1052
- St as blind,
1053
- Vt as curtainReveal,
1054
- _t as drill,
1055
- It as fade,
1056
- Ot as film,
1057
- Dt as hero,
1058
- Pt as instagram,
1059
- Xt as jaemin,
1060
- vt as pinterest,
1061
- Ft as scroll,
1062
- Yt as slide,
1063
- Ut as strip
1105
+ It as blind,
1106
+ Xt as curtainReveal,
1107
+ Ot as drill,
1108
+ Dt as fade,
1109
+ Pt as film,
1110
+ vt as hero,
1111
+ Ft as instagram,
1112
+ Ht as jaemin,
1113
+ Yt as pinterest,
1114
+ Ut as rotate,
1115
+ Vt as scroll,
1116
+ Wt as slide,
1117
+ zt as strip
1064
1118
  };