@micjanic/recursive-grid 1.0.30 → 1.0.31
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.
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var p = (
|
|
4
|
-
import
|
|
1
|
+
var fe = Object.defineProperty;
|
|
2
|
+
var de = (s, t, n) => t in s ? fe(s, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : s[t] = n;
|
|
3
|
+
var p = (s, t, n) => de(s, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import me, { createContext as pe, useState as ee, useEffect as F, useContext as he, useRef as V, useCallback as _e } from "react";
|
|
5
5
|
import { useApplication as Ee, useTick as Re, extend as ve, Application as Te } from "@pixi/react";
|
|
6
|
-
import { Graphics as
|
|
7
|
-
var N = { exports: {} },
|
|
6
|
+
import { Graphics as re, Particle as te, Sprite as be, Container as xe, Texture as Pe, ParticleContainer as ye } from "pixi.js";
|
|
7
|
+
var N = { exports: {} }, A = {};
|
|
8
8
|
/**
|
|
9
9
|
* @license React
|
|
10
10
|
* react-jsx-runtime.production.js
|
|
@@ -15,28 +15,28 @@ var N = { exports: {} }, g = {};
|
|
|
15
15
|
* LICENSE file in the root directory of this source tree.
|
|
16
16
|
*/
|
|
17
17
|
var z;
|
|
18
|
-
function
|
|
19
|
-
if (z) return
|
|
18
|
+
function Ae() {
|
|
19
|
+
if (z) return A;
|
|
20
20
|
z = 1;
|
|
21
|
-
var
|
|
22
|
-
function n(f, a,
|
|
21
|
+
var s = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
|
|
22
|
+
function n(f, a, l) {
|
|
23
23
|
var o = null;
|
|
24
|
-
if (
|
|
25
|
-
|
|
24
|
+
if (l !== void 0 && (o = "" + l), a.key !== void 0 && (o = "" + a.key), "key" in a) {
|
|
25
|
+
l = {};
|
|
26
26
|
for (var d in a)
|
|
27
|
-
d !== "key" && (
|
|
28
|
-
} else
|
|
29
|
-
return a =
|
|
30
|
-
$$typeof:
|
|
27
|
+
d !== "key" && (l[d] = a[d]);
|
|
28
|
+
} else l = a;
|
|
29
|
+
return a = l.ref, {
|
|
30
|
+
$$typeof: s,
|
|
31
31
|
type: f,
|
|
32
32
|
key: o,
|
|
33
33
|
ref: a !== void 0 ? a : null,
|
|
34
|
-
props:
|
|
34
|
+
props: l
|
|
35
35
|
};
|
|
36
36
|
}
|
|
37
|
-
return
|
|
37
|
+
return A.Fragment = t, A.jsx = n, A.jsxs = n, A;
|
|
38
38
|
}
|
|
39
|
-
var
|
|
39
|
+
var S = {};
|
|
40
40
|
/**
|
|
41
41
|
* @license React
|
|
42
42
|
* react-jsx-runtime.development.js
|
|
@@ -47,12 +47,12 @@ var y = {};
|
|
|
47
47
|
* LICENSE file in the root directory of this source tree.
|
|
48
48
|
*/
|
|
49
49
|
var X;
|
|
50
|
-
function
|
|
50
|
+
function Se() {
|
|
51
51
|
return X || (X = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
52
|
-
function
|
|
52
|
+
function s(e) {
|
|
53
53
|
if (e == null) return null;
|
|
54
54
|
if (typeof e == "function")
|
|
55
|
-
return e.$$typeof ===
|
|
55
|
+
return e.$$typeof === ie ? null : e.displayName || e.name || null;
|
|
56
56
|
if (typeof e == "string") return e;
|
|
57
57
|
switch (e) {
|
|
58
58
|
case x:
|
|
@@ -61,11 +61,11 @@ function ye() {
|
|
|
61
61
|
return "Profiler";
|
|
62
62
|
case O:
|
|
63
63
|
return "StrictMode";
|
|
64
|
-
case ne:
|
|
65
|
-
return "Suspense";
|
|
66
64
|
case ae:
|
|
65
|
+
return "Suspense";
|
|
66
|
+
case oe:
|
|
67
67
|
return "SuspenseList";
|
|
68
|
-
case
|
|
68
|
+
case le:
|
|
69
69
|
return "Activity";
|
|
70
70
|
}
|
|
71
71
|
if (typeof e == "object")
|
|
@@ -76,17 +76,17 @@ function ye() {
|
|
|
76
76
|
return "Portal";
|
|
77
77
|
case C:
|
|
78
78
|
return e.displayName || "Context";
|
|
79
|
-
case
|
|
79
|
+
case y:
|
|
80
80
|
return (e._context.displayName || "Context") + ".Consumer";
|
|
81
81
|
case w:
|
|
82
82
|
var r = e.render;
|
|
83
83
|
return e = e.displayName, e || (e = r.displayName || r.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
84
|
-
case
|
|
85
|
-
return r = e.displayName || null, r !== null ? r :
|
|
84
|
+
case se:
|
|
85
|
+
return r = e.displayName || null, r !== null ? r : s(e.type) || "Memo";
|
|
86
86
|
case D:
|
|
87
87
|
r = e._payload, e = e._init;
|
|
88
88
|
try {
|
|
89
|
-
return
|
|
89
|
+
return s(e(r));
|
|
90
90
|
} catch {
|
|
91
91
|
}
|
|
92
92
|
}
|
|
@@ -117,7 +117,7 @@ function ye() {
|
|
|
117
117
|
if (typeof e == "object" && e !== null && e.$$typeof === D)
|
|
118
118
|
return "<...>";
|
|
119
119
|
try {
|
|
120
|
-
var r =
|
|
120
|
+
var r = s(e);
|
|
121
121
|
return r ? "<" + r + ">" : "<...>";
|
|
122
122
|
} catch {
|
|
123
123
|
return "<...>";
|
|
@@ -127,7 +127,7 @@ function ye() {
|
|
|
127
127
|
var e = Y.A;
|
|
128
128
|
return e === null ? null : e.getOwner();
|
|
129
129
|
}
|
|
130
|
-
function
|
|
130
|
+
function l() {
|
|
131
131
|
return Error("react-stack-top-frame");
|
|
132
132
|
}
|
|
133
133
|
function o(e) {
|
|
@@ -149,8 +149,8 @@ function ye() {
|
|
|
149
149
|
configurable: !0
|
|
150
150
|
});
|
|
151
151
|
}
|
|
152
|
-
function
|
|
153
|
-
var e =
|
|
152
|
+
function g() {
|
|
153
|
+
var e = s(this.type);
|
|
154
154
|
return U[e] || (U[e] = !0, console.error(
|
|
155
155
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
156
156
|
)), e = this.props.ref, e !== void 0 ? e : null;
|
|
@@ -165,7 +165,7 @@ function ye() {
|
|
|
165
165
|
_owner: u
|
|
166
166
|
}, (c !== void 0 ? c : null) !== null ? Object.defineProperty(e, "ref", {
|
|
167
167
|
enumerable: !1,
|
|
168
|
-
get:
|
|
168
|
+
get: g
|
|
169
169
|
}) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
|
|
170
170
|
configurable: !1,
|
|
171
171
|
enumerable: !1,
|
|
@@ -192,7 +192,7 @@ function ye() {
|
|
|
192
192
|
var c = r.children;
|
|
193
193
|
if (c !== void 0)
|
|
194
194
|
if (u)
|
|
195
|
-
if (
|
|
195
|
+
if (ue(c)) {
|
|
196
196
|
for (u = 0; u < c.length; u++)
|
|
197
197
|
E(c[u]);
|
|
198
198
|
Object.freeze && Object.freeze(c);
|
|
@@ -202,9 +202,9 @@ function ye() {
|
|
|
202
202
|
);
|
|
203
203
|
else E(c);
|
|
204
204
|
if (L.call(r, "key")) {
|
|
205
|
-
c =
|
|
206
|
-
var b = Object.keys(r).filter(function(
|
|
207
|
-
return
|
|
205
|
+
c = s(e);
|
|
206
|
+
var b = Object.keys(r).filter(function(ce) {
|
|
207
|
+
return ce !== "key";
|
|
208
208
|
});
|
|
209
209
|
u = 0 < b.length ? "{key: someKey, " + b.join(": ..., ") + ": ...}" : "{key: someKey}", J[c + u] || (b = 0 < b.length ? "{" + b.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
210
210
|
`A props object containing a "key" prop is being spread into JSX:
|
|
@@ -242,7 +242,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
242
242
|
function R(e) {
|
|
243
243
|
return typeof e == "object" && e !== null && e.$$typeof === v;
|
|
244
244
|
}
|
|
245
|
-
var h =
|
|
245
|
+
var h = me, v = Symbol.for("react.transitional.element"), T = Symbol.for("react.portal"), x = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), P = Symbol.for("react.profiler"), y = Symbol.for("react.consumer"), C = Symbol.for("react.context"), w = Symbol.for("react.forward_ref"), ae = Symbol.for("react.suspense"), oe = Symbol.for("react.suspense_list"), se = Symbol.for("react.memo"), D = Symbol.for("react.lazy"), le = Symbol.for("react.activity"), ie = Symbol.for("react.client.reference"), Y = h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, L = Object.prototype.hasOwnProperty, ue = Array.isArray, I = console.createTask ? console.createTask : function() {
|
|
246
246
|
return null;
|
|
247
247
|
};
|
|
248
248
|
h = {
|
|
@@ -252,9 +252,9 @@ React keys must be passed directly to JSX without using spread:
|
|
|
252
252
|
};
|
|
253
253
|
var G, U = {}, W = h.react_stack_bottom_frame.bind(
|
|
254
254
|
h,
|
|
255
|
-
|
|
256
|
-
)(), q = I(f(
|
|
257
|
-
|
|
255
|
+
l
|
|
256
|
+
)(), q = I(f(l)), J = {};
|
|
257
|
+
S.Fragment = x, S.jsx = function(e, r, i) {
|
|
258
258
|
var u = 1e4 > Y.recentlyCreatedOwnerStacks++;
|
|
259
259
|
return k(
|
|
260
260
|
e,
|
|
@@ -264,7 +264,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
264
264
|
u ? Error("react-stack-top-frame") : W,
|
|
265
265
|
u ? I(f(e)) : q
|
|
266
266
|
);
|
|
267
|
-
},
|
|
267
|
+
}, S.jsxs = function(e, r, i) {
|
|
268
268
|
var u = 1e4 > Y.recentlyCreatedOwnerStacks++;
|
|
269
269
|
return k(
|
|
270
270
|
e,
|
|
@@ -275,29 +275,29 @@ React keys must be passed directly to JSX without using spread:
|
|
|
275
275
|
u ? I(f(e)) : q
|
|
276
276
|
);
|
|
277
277
|
};
|
|
278
|
-
})()),
|
|
278
|
+
})()), S;
|
|
279
279
|
}
|
|
280
280
|
var H;
|
|
281
|
-
function
|
|
282
|
-
return H || (H = 1, process.env.NODE_ENV === "production" ? N.exports =
|
|
281
|
+
function ge() {
|
|
282
|
+
return H || (H = 1, process.env.NODE_ENV === "production" ? N.exports = Ae() : N.exports = Se()), N.exports;
|
|
283
283
|
}
|
|
284
|
-
var _ =
|
|
285
|
-
const
|
|
286
|
-
const { app: t } = Ee(), [n, f] =
|
|
284
|
+
var _ = ge();
|
|
285
|
+
const ne = pe({}), ke = ({ children: s }) => {
|
|
286
|
+
const { app: t } = Ee(), [n, f] = ee(null);
|
|
287
287
|
return F(() => {
|
|
288
288
|
if (!t) return;
|
|
289
289
|
let a = !1;
|
|
290
|
-
const
|
|
290
|
+
const l = () => {
|
|
291
291
|
if (!t.renderer) {
|
|
292
|
-
requestAnimationFrame(
|
|
292
|
+
requestAnimationFrame(l);
|
|
293
293
|
return;
|
|
294
294
|
}
|
|
295
|
-
const o = new
|
|
295
|
+
const o = new re();
|
|
296
296
|
o.setFillStyle({ color: "#121225" }), o.rect(0, 0, 1, 1), o.fill();
|
|
297
297
|
const d = t.renderer.generateTexture(o);
|
|
298
298
|
o.destroy(), a || f(d);
|
|
299
299
|
};
|
|
300
|
-
return
|
|
300
|
+
return l(), () => {
|
|
301
301
|
a = !0;
|
|
302
302
|
try {
|
|
303
303
|
n == null || n.destroy(!0);
|
|
@@ -305,11 +305,11 @@ const te = me({}), ke = ({ children: l }) => {
|
|
|
305
305
|
}
|
|
306
306
|
f(null);
|
|
307
307
|
};
|
|
308
|
-
}, [t]), n ? /* @__PURE__ */ _.jsx(
|
|
308
|
+
}, [t]), n ? /* @__PURE__ */ _.jsx(ne.Provider, { value: n, children: s }) : null;
|
|
309
309
|
};
|
|
310
|
-
class Oe extends
|
|
311
|
-
constructor(n, f, a,
|
|
312
|
-
super({ texture: n, x: f, y: a, scaleX:
|
|
310
|
+
class Oe extends te {
|
|
311
|
+
constructor(n, f, a, l, o, d) {
|
|
312
|
+
super({ texture: n, x: f, y: a, scaleX: l, scaleY: o, alpha: 0 });
|
|
313
313
|
p(this, "animationProgress", 0);
|
|
314
314
|
p(this, "delayCounter", 0);
|
|
315
315
|
p(this, "randomSpeed");
|
|
@@ -317,7 +317,7 @@ class Oe extends re {
|
|
|
317
317
|
p(this, "startScaleX");
|
|
318
318
|
p(this, "startScaleY");
|
|
319
319
|
p(this, "targetAlpha");
|
|
320
|
-
this.texture = n, this.x = f, this.y = a, this.scaleX =
|
|
320
|
+
this.texture = n, this.x = f, this.y = a, this.scaleX = l, this.scaleY = o, this.curLevel = d, this.startScaleX = l, this.startScaleY = o, this.curLevel = d, this.randomSpeed = 0.04 + Math.random() * 0.04, this.randomDelayOffset = Math.floor(Math.random() * 150), this.targetAlpha = 0.9 + Math.random() * 0.1;
|
|
321
321
|
}
|
|
322
322
|
update() {
|
|
323
323
|
if (this.delayCounter < this.curLevel * 15 + this.randomDelayOffset) {
|
|
@@ -336,8 +336,8 @@ class Ce {
|
|
|
336
336
|
p(this, "cells", []);
|
|
337
337
|
this.texture = t, this.particleContainerRefCurrent = n, this.texture = t;
|
|
338
338
|
}
|
|
339
|
-
add(t, n, f, a,
|
|
340
|
-
const o = new Oe(this.texture, t, n, f, a,
|
|
339
|
+
add(t, n, f, a, l) {
|
|
340
|
+
const o = new Oe(this.texture, t, n, f, a, l);
|
|
341
341
|
this.particleContainerRefCurrent.addParticle(o), this.cells.push(o);
|
|
342
342
|
}
|
|
343
343
|
updateAll() {
|
|
@@ -346,30 +346,30 @@ class Ce {
|
|
|
346
346
|
}
|
|
347
347
|
}
|
|
348
348
|
const we = ({
|
|
349
|
-
gridRows:
|
|
349
|
+
gridRows: s,
|
|
350
350
|
gridCols: t,
|
|
351
351
|
cellWidth: n,
|
|
352
352
|
cellHeight: f,
|
|
353
353
|
gridDepth: a
|
|
354
354
|
}) => {
|
|
355
|
-
const
|
|
355
|
+
const l = he(ne), o = V(null), d = V(null);
|
|
356
356
|
F(() => {
|
|
357
|
-
if (
|
|
357
|
+
if (l) {
|
|
358
358
|
if (o.current) {
|
|
359
359
|
try {
|
|
360
360
|
o.current.removeChildren();
|
|
361
361
|
} catch {
|
|
362
362
|
}
|
|
363
363
|
d.current = new Ce(
|
|
364
|
-
|
|
364
|
+
l,
|
|
365
365
|
o.current
|
|
366
|
-
),
|
|
366
|
+
), g(
|
|
367
367
|
0,
|
|
368
368
|
0,
|
|
369
369
|
n,
|
|
370
370
|
f,
|
|
371
371
|
t,
|
|
372
|
-
|
|
372
|
+
s,
|
|
373
373
|
a,
|
|
374
374
|
o.current
|
|
375
375
|
);
|
|
@@ -383,23 +383,23 @@ const we = ({
|
|
|
383
383
|
d.current = null;
|
|
384
384
|
};
|
|
385
385
|
}
|
|
386
|
-
}, [
|
|
386
|
+
}, [l, n, f, t, s, a]), Re(() => {
|
|
387
387
|
var m;
|
|
388
388
|
(m = d.current) == null || m.updateAll();
|
|
389
389
|
});
|
|
390
|
-
const
|
|
390
|
+
const g = _e(
|
|
391
391
|
(m, k, E, R, h, v, T, x) => {
|
|
392
392
|
var O;
|
|
393
393
|
for (let P = 0; P < v; P++)
|
|
394
|
-
for (let
|
|
395
|
-
const C = m +
|
|
394
|
+
for (let y = 0; y < h; y++) {
|
|
395
|
+
const C = m + y * E, w = k + P * R;
|
|
396
396
|
T <= 0 || Math.random() > 0.7 && T < a ? Math.random() > 0.1 && ((O = d.current) == null || O.add(
|
|
397
397
|
C,
|
|
398
398
|
w,
|
|
399
399
|
E - 1,
|
|
400
400
|
R - 1,
|
|
401
401
|
T
|
|
402
|
-
)) :
|
|
402
|
+
)) : g(
|
|
403
403
|
C,
|
|
404
404
|
w,
|
|
405
405
|
E / h,
|
|
@@ -425,7 +425,7 @@ const we = ({
|
|
|
425
425
|
}
|
|
426
426
|
);
|
|
427
427
|
}, je = ({
|
|
428
|
-
cellWidth:
|
|
428
|
+
cellWidth: s,
|
|
429
429
|
cellHeight: t,
|
|
430
430
|
gridRows: n,
|
|
431
431
|
gridCols: f,
|
|
@@ -433,37 +433,43 @@ const we = ({
|
|
|
433
433
|
}) => /* @__PURE__ */ _.jsx(ke, { children: /* @__PURE__ */ _.jsx(
|
|
434
434
|
we,
|
|
435
435
|
{
|
|
436
|
-
cellWidth:
|
|
436
|
+
cellWidth: s,
|
|
437
437
|
cellHeight: t,
|
|
438
438
|
gridCols: f,
|
|
439
439
|
gridRows: n,
|
|
440
440
|
gridDepth: a
|
|
441
441
|
}
|
|
442
442
|
) });
|
|
443
|
-
ve({ ParticleContainer:
|
|
444
|
-
const B = 2, Z = 2, Q = 300, K = 300, Ne = 6, $e = () =>
|
|
445
|
-
|
|
446
|
-
{
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
443
|
+
ve({ ParticleContainer: ye, Particle: te, Texture: Pe, Container: xe, Sprite: be, Graphics: re });
|
|
444
|
+
const B = 2, Z = 2, Q = 300, K = 300, Ne = 6, $e = () => {
|
|
445
|
+
const [s, t] = ee(0);
|
|
446
|
+
return F(() => (t((n) => n + 1), () => {
|
|
447
|
+
console.log("Pixi unmounted"), t((n) => n + 1);
|
|
448
|
+
}), []), /* @__PURE__ */ _.jsx("div", { className: "flex flex-col items-center justify-center w-full h-full", children: /* @__PURE__ */ _.jsx(
|
|
449
|
+
Te,
|
|
450
|
+
{
|
|
451
|
+
antialias: !1,
|
|
452
|
+
width: Q * B,
|
|
453
|
+
height: K * Z,
|
|
454
|
+
className: "image-pixelated w-full",
|
|
455
|
+
backgroundAlpha: 0,
|
|
456
|
+
autoDensity: !0,
|
|
457
|
+
preserveDrawingBuffer: !0,
|
|
458
|
+
powerPreference: "high-performance",
|
|
459
|
+
children: /* @__PURE__ */ _.jsx(
|
|
460
|
+
je,
|
|
461
|
+
{
|
|
462
|
+
gridCols: B,
|
|
463
|
+
gridRows: Z,
|
|
464
|
+
cellWidth: Q,
|
|
465
|
+
cellHeight: K,
|
|
466
|
+
gridDepth: Ne
|
|
467
|
+
}
|
|
468
|
+
)
|
|
469
|
+
},
|
|
470
|
+
s
|
|
471
|
+
) });
|
|
472
|
+
};
|
|
467
473
|
export {
|
|
468
474
|
$e as default
|
|
469
475
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"recursive-grid.es.js","sources":["../node_modules/react/cjs/react-jsx-runtime.production.js","../node_modules/react/cjs/react-jsx-runtime.development.js","../node_modules/react/jsx-runtime.js","../src/context/CellTexturesContext.tsx","../src/classes/Cell.ts","../src/classes/CellManager.ts","../src/components/RecursiveGrid.tsx","../src/components/RecursiveGridContainer.tsx","../src/components/PixiApp.tsx"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\");\nfunction jsxProd(type, config, maybeKey) {\n var key = null;\n void 0 !== maybeKey && (key = \"\" + maybeKey);\n void 0 !== config.key && (key = \"\" + config.key);\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n config = maybeKey.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== config ? config : null,\n props: maybeKey\n };\n}\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.jsx = jsxProd;\nexports.jsxs = jsxProd;\n","/**\n * @license React\n * react-jsx-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsx = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !1,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n exports.jsxs = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !0,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import { createContext, useContext, FC, ReactNode, useEffect, useState } from 'react'\r\nimport { useApplication } from '@pixi/react'\r\nimport { Graphics, Texture } from 'pixi.js'\r\n\r\ntype CellTextures = Texture\r\n\r\nconst CellTexturesContext = createContext<CellTextures>({} as CellTextures)\r\n\r\nexport const useCellTextures = () => useContext(CellTexturesContext)\r\n\r\nconst CellTexturesProvider: FC<{ children: ReactNode }> = ({ children }) => {\r\n const { app } = useApplication()\r\n const [texture, setTexture] = useState<Texture | null>(null)\r\n\r\n useEffect(() => {\r\n if (!app) return\r\n\r\n let isUnmounted = false\r\n\r\n const generate = () => {\r\n // Wait until Pixi Application has initialised the renderer\r\n if (!app.renderer) {\r\n requestAnimationFrame(generate)\r\n return\r\n }\r\n\r\n const g = new Graphics()\r\n g.setFillStyle({ color: '#121225' })\r\n g.rect(0, 0, 1, 1)\r\n g.fill()\r\n const generatedTexture = app.renderer.generateTexture(g)\r\n g.destroy()\r\n if (!isUnmounted) setTexture(generatedTexture)\r\n }\r\n\r\n generate()\r\n\r\n return () => {\r\n isUnmounted = true\r\n // Destroy generated texture to free GPU memory\r\n try {\r\n texture?.destroy(true)\r\n } catch {}\r\n setTexture(null)\r\n }\r\n }, [app])\r\n\r\n if (!texture) return null\r\n\r\n return (\r\n <CellTexturesContext.Provider value={texture}>\r\n {children}\r\n </CellTexturesContext.Provider>\r\n )\r\n}\r\n\r\nexport { CellTexturesContext, CellTexturesProvider }\r\n","import { Particle, Texture } from \"pixi.js\"\r\n\r\nexport class Cell extends Particle {\r\n private animationProgress = 0\r\n private delayCounter = 0\r\n private randomSpeed: number\r\n private randomDelayOffset: number\r\n startScaleX: number\r\n startScaleY: number\r\n targetAlpha: number\r\n\r\n constructor(\r\n public texture: Texture,\r\n public x: number,\r\n public y: number,\r\n public scaleX: number,\r\n public scaleY: number,\r\n public curLevel: number,\r\n ) {\r\n super({ texture, x, y, scaleX, scaleY, alpha: 0 })\r\n this.startScaleX = scaleX\r\n this.startScaleY = scaleY\r\n this.curLevel = curLevel\r\n\r\n // Randomize speed slightly (0.08 to 0.12)\r\n this.randomSpeed = 0.04 + Math.random() * 0.04\r\n // Randomize delay by a few frames\r\n this.randomDelayOffset = Math.floor(Math.random() * 150)\r\n this.targetAlpha = 0.9 + Math.random() * 0.1\r\n }\r\n\r\n update() {\r\n if (this.delayCounter < this.curLevel * 15 + this.randomDelayOffset) {\r\n this.delayCounter++\r\n return\r\n }\r\n\r\n if (this.animationProgress >= this.targetAlpha - 0.001) {\r\n this.animationProgress = this.targetAlpha\r\n this.alpha = this.targetAlpha\r\n return\r\n }\r\n\r\n this.animationProgress += (this.targetAlpha - this.animationProgress) * this.randomSpeed\r\n this.alpha = this.animationProgress\r\n }\r\n}\r\n","import { ParticleContainer, Texture } from 'pixi.js'\r\nimport { Cell } from './Cell'\r\n\r\nexport class CellManager {\r\n private cells: Cell[] = []\r\n\r\n constructor(\r\n public texture: Texture,\r\n public particleContainerRefCurrent: ParticleContainer\r\n ) {\r\n this.texture = texture\r\n }\r\n\r\n add(x: number, y: number, scaleX: number, scaleY: number, curLevel: number) {\r\n const cell = new Cell(this.texture, x, y, scaleX, scaleY, curLevel)\r\n this.particleContainerRefCurrent.addParticle(cell)\r\n this.cells.push(cell)\r\n }\r\n\r\n updateAll() {\r\n for (const cell of this.cells) {\r\n cell.update()\r\n }\r\n }\r\n}","import { FC, useCallback, useContext, useEffect, useRef } from 'react'\r\nimport { ParticleContainer } from 'pixi.js'\r\nimport { CellTexturesContext } from '../context/CellTexturesContext'\r\nimport { useTick } from '@pixi/react'\r\nimport { CellManager } from '../classes/CellManager'\r\n\r\ninterface GridProps {\r\n gridCols: number\r\n gridRows: number\r\n cellWidth: number\r\n cellHeight: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGrid: FC<GridProps> = ({\r\n gridRows,\r\n gridCols,\r\n cellWidth,\r\n cellHeight,\r\n gridDepth,\r\n}) => {\r\n const texture = useContext(CellTexturesContext)\r\n const particleContainerRef = useRef<ParticleContainer>(null)\r\n const cellManager = useRef<CellManager>(null)\r\n\r\n useEffect(() => {\r\n if (!texture) return\r\n if (particleContainerRef.current) {\r\n // Clear any previous content on re-init\r\n try {\r\n particleContainerRef.current.removeChildren()\r\n } catch {}\r\n\r\n cellManager.current = new CellManager(\r\n texture,\r\n particleContainerRef.current\r\n )\r\n\r\n buildRecursiveGrid(\r\n 0,\r\n 0,\r\n cellWidth,\r\n cellHeight,\r\n gridCols,\r\n gridRows,\r\n gridDepth,\r\n particleContainerRef.current\r\n )\r\n }\r\n return () => {\r\n // Clean up particles and references on unmount/texture change\r\n try {\r\n particleContainerRef.current?.removeChildren()\r\n } catch {}\r\n cellManager.current = null\r\n }\r\n }, [texture, cellWidth, cellHeight, gridCols, gridRows, gridDepth])\r\n\r\n useTick(() => {\r\n cellManager.current?.updateAll()\r\n })\r\n\r\n const buildRecursiveGrid = useCallback(\r\n (\r\n x: number,\r\n y: number,\r\n cellWidth: number,\r\n cellHeight: number,\r\n gridCols: number,\r\n gridRows: number,\r\n curLevel: number,\r\n currentParticlesRef: ParticleContainer\r\n ) => {\r\n for (let row = 0; row < gridRows; row++) {\r\n for (let col = 0; col < gridCols; col++) {\r\n const startX = x + col * cellWidth\r\n const startY = y + row * cellHeight\r\n\r\n if (\r\n curLevel <= 0 ||\r\n (Math.random() > 0.7 && curLevel < gridDepth)\r\n ) {\r\n if (Math.random() > 0.1) {\r\n cellManager.current?.add(\r\n startX,\r\n startY,\r\n cellWidth - 1,\r\n cellHeight - 1,\r\n curLevel\r\n )\r\n }\r\n } else {\r\n buildRecursiveGrid(\r\n startX,\r\n startY,\r\n cellWidth / gridCols,\r\n cellHeight / gridRows,\r\n gridCols,\r\n gridRows,\r\n curLevel - 1,\r\n currentParticlesRef\r\n )\r\n }\r\n }\r\n }\r\n },\r\n []\r\n )\r\n\r\n return (\r\n <pixiParticleContainer\r\n ref={particleContainerRef}\r\n dynamicProperties={{\r\n position: true,\r\n vertex: true,\r\n color: true,\r\n }}\r\n />\r\n )\r\n}\r\n\r\nexport default RecursiveGrid\r\n","import { FC } from 'react'\r\nimport RecursiveGrid from './RecursiveGrid'\r\n\r\nimport { CellTexturesProvider } from '../context/CellTexturesContext'\r\n\r\ninterface RecursiveGridContainerProps {\r\n cellWidth: number\r\n cellHeight: number\r\n gridRows: number\r\n gridCols: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGridContainer: FC<RecursiveGridContainerProps> = ({\r\n cellWidth,\r\n cellHeight,\r\n gridRows,\r\n gridCols,\r\n gridDepth,\r\n}) => {\r\n return (\r\n <CellTexturesProvider>\r\n <RecursiveGrid\r\n cellWidth={cellWidth}\r\n cellHeight={cellHeight}\r\n gridCols={gridCols}\r\n gridRows={gridRows}\r\n gridDepth={gridDepth}\r\n />\r\n </CellTexturesProvider>\r\n )\r\n}\r\n\r\nexport default RecursiveGridContainer\r\n","import { Application, extend } from '@pixi/react'\r\nimport {\r\n Sprite,\r\n Graphics,\r\n Container,\r\n Texture,\r\n Particle,\r\n ParticleContainer,\r\n} from 'pixi.js'\r\nimport RecursiveGridContainer from './RecursiveGridContainer'\r\nimport { useEffect } from 'react'\r\nextend({ ParticleContainer, Particle, Texture, Container, Sprite, Graphics })\r\n\r\nconst GRID_COLS = 2\r\nconst GRID_ROWS = 2\r\nconst CELL_WIDTH = 300\r\nconst CELL_HEIGHT = 300\r\nconst GRID_DEPTH = 6\r\n\r\nconst PixiApp = () => {\r\n useEffect(() => {\r\n console.log('Pixi mounted')\r\n return () => console.log('Pixi unmounted')\r\n }, [])\r\n\r\n return (\r\n <div className=\"flex flex-col items-center justify-center w-full h-full\">\r\n <Application\r\n antialias={false}\r\n width={CELL_WIDTH * GRID_COLS}\r\n height={CELL_HEIGHT * GRID_ROWS}\r\n className=\"image-pixelated w-full\"\r\n backgroundAlpha={0}\r\n autoDensity={true}\r\n preserveDrawingBuffer={true}\r\n powerPreference=\"high-performance\"\r\n >\r\n <RecursiveGridContainer\r\n gridCols={GRID_COLS}\r\n gridRows={GRID_ROWS}\r\n cellWidth={CELL_WIDTH}\r\n cellHeight={CELL_HEIGHT}\r\n gridDepth={GRID_DEPTH}\r\n />\r\n </Application>\r\n </div>\r\n )\r\n}\r\n\r\nexport default PixiApp\r\n"],"names":["REACT_ELEMENT_TYPE","REACT_FRAGMENT_TYPE","jsxProd","type","config","maybeKey","key","propName","reactJsxRuntime_production","getComponentNameFromType","REACT_CLIENT_REFERENCE","REACT_PROFILER_TYPE","REACT_STRICT_MODE_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_ACTIVITY_TYPE","REACT_PORTAL_TYPE","REACT_CONTEXT_TYPE","REACT_CONSUMER_TYPE","REACT_FORWARD_REF_TYPE","innerType","REACT_MEMO_TYPE","REACT_LAZY_TYPE","testStringCoercion","value","checkKeyStringCoercion","JSCompiler_inline_result","JSCompiler_temp_const","JSCompiler_inline_result$jscomp$0","getTaskName","name","getOwner","dispatcher","ReactSharedInternals","UnknownOwner","hasValidKey","hasOwnProperty","getter","defineKeyPropWarningGetter","props","displayName","warnAboutAccessingKey","specialPropKeyWarningShown","elementRefGetterWithDeprecationWarning","componentName","didWarnAboutElementRef","ReactElement","owner","debugStack","debugTask","refProp","jsxDEVImpl","isStaticChildren","children","isArrayImpl","validateChildKeys","keys","k","didWarnAboutKeySpread","node","isValidElement","object","React","require$$0","createTask","callStackForError","unknownOwnerDebugStack","unknownOwnerDebugTask","reactJsxRuntime_development","trackActualOwner","jsxRuntimeModule","require$$1","CellTexturesContext","createContext","CellTexturesProvider","app","useApplication","texture","setTexture","useState","useEffect","isUnmounted","generate","g","Graphics","generatedTexture","Cell","Particle","x","y","scaleX","scaleY","curLevel","__publicField","CellManager","particleContainerRefCurrent","cell","RecursiveGrid","gridRows","gridCols","cellWidth","cellHeight","gridDepth","useContext","particleContainerRef","useRef","cellManager","buildRecursiveGrid","_a","useTick","useCallback","currentParticlesRef","row","col","startX","startY","jsx","RecursiveGridContainer","extend","ParticleContainer","Texture","Container","Sprite","GRID_COLS","GRID_ROWS","CELL_WIDTH","CELL_HEIGHT","GRID_DEPTH","PixiApp","Application"],"mappings":";;;;;;;;;;;;;;;;;;;;AAWA,MAAIA,IAAqB,OAAO,IAAI,4BAA4B,GAC9DC,IAAsB,OAAO,IAAI,gBAAgB;AACnD,WAASC,EAAQC,GAAMC,GAAQC,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IACG,WAAW;AAAA,IACX,OAAOJ,IAAaF;AAAA,IACpB,QAAQG,IAAcF;AAAA,IACtB,WAAU;AAAA,IACV,iBAAiB;AAAA,IACjB,aAAa;AAAA,IACb,uBAAuB;AAAA,IACvB,iBAAgB;AAAA,IAEhB,UAAAR,gBAAAA,EAAAA;AAAAA,MAACC;AAAA,MAAA;AAAA,QACG,UAAUM;AAAA,QACV,UAAUC;AAAA,QACV,WAAWC;AAAA,QACX,YAAYC;AAAA,QACZ,WAAWC;AAAA,MAAA;AAAA,IAAA;AAAA,EACf;AAAA,GAER;","x_google_ignoreList":[0,1,2]}
|
|
1
|
+
{"version":3,"file":"recursive-grid.es.js","sources":["../node_modules/react/cjs/react-jsx-runtime.production.js","../node_modules/react/cjs/react-jsx-runtime.development.js","../node_modules/react/jsx-runtime.js","../src/context/CellTexturesContext.tsx","../src/classes/Cell.ts","../src/classes/CellManager.ts","../src/components/RecursiveGrid.tsx","../src/components/RecursiveGridContainer.tsx","../src/components/PixiApp.tsx"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\");\nfunction jsxProd(type, config, maybeKey) {\n var key = null;\n void 0 !== maybeKey && (key = \"\" + maybeKey);\n void 0 !== config.key && (key = \"\" + config.key);\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n config = maybeKey.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== config ? config : null,\n props: maybeKey\n };\n}\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.jsx = jsxProd;\nexports.jsxs = jsxProd;\n","/**\n * @license React\n * react-jsx-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsx = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !1,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n exports.jsxs = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !0,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import { createContext, useContext, FC, ReactNode, useEffect, useState } from 'react'\r\nimport { useApplication } from '@pixi/react'\r\nimport { Graphics, Texture } from 'pixi.js'\r\n\r\ntype CellTextures = Texture\r\n\r\nconst CellTexturesContext = createContext<CellTextures>({} as CellTextures)\r\n\r\nexport const useCellTextures = () => useContext(CellTexturesContext)\r\n\r\nconst CellTexturesProvider: FC<{ children: ReactNode }> = ({ children }) => {\r\n const { app } = useApplication()\r\n const [texture, setTexture] = useState<Texture | null>(null)\r\n\r\n useEffect(() => {\r\n if (!app) return\r\n\r\n let isUnmounted = false\r\n\r\n const generate = () => {\r\n // Wait until Pixi Application has initialised the renderer\r\n if (!app.renderer) {\r\n requestAnimationFrame(generate)\r\n return\r\n }\r\n\r\n const g = new Graphics()\r\n g.setFillStyle({ color: '#121225' })\r\n g.rect(0, 0, 1, 1)\r\n g.fill()\r\n const generatedTexture = app.renderer.generateTexture(g)\r\n g.destroy()\r\n if (!isUnmounted) setTexture(generatedTexture)\r\n }\r\n\r\n generate()\r\n\r\n return () => {\r\n isUnmounted = true\r\n // Destroy generated texture to free GPU memory\r\n try {\r\n texture?.destroy(true)\r\n } catch {}\r\n setTexture(null)\r\n }\r\n }, [app])\r\n\r\n if (!texture) return null\r\n\r\n return (\r\n <CellTexturesContext.Provider value={texture}>\r\n {children}\r\n </CellTexturesContext.Provider>\r\n )\r\n}\r\n\r\nexport { CellTexturesContext, CellTexturesProvider }\r\n","import { Particle, Texture } from \"pixi.js\"\r\n\r\nexport class Cell extends Particle {\r\n private animationProgress = 0\r\n private delayCounter = 0\r\n private randomSpeed: number\r\n private randomDelayOffset: number\r\n startScaleX: number\r\n startScaleY: number\r\n targetAlpha: number\r\n\r\n constructor(\r\n public texture: Texture,\r\n public x: number,\r\n public y: number,\r\n public scaleX: number,\r\n public scaleY: number,\r\n public curLevel: number,\r\n ) {\r\n super({ texture, x, y, scaleX, scaleY, alpha: 0 })\r\n this.startScaleX = scaleX\r\n this.startScaleY = scaleY\r\n this.curLevel = curLevel\r\n\r\n // Randomize speed slightly (0.08 to 0.12)\r\n this.randomSpeed = 0.04 + Math.random() * 0.04\r\n // Randomize delay by a few frames\r\n this.randomDelayOffset = Math.floor(Math.random() * 150)\r\n this.targetAlpha = 0.9 + Math.random() * 0.1\r\n }\r\n\r\n update() {\r\n if (this.delayCounter < this.curLevel * 15 + this.randomDelayOffset) {\r\n this.delayCounter++\r\n return\r\n }\r\n\r\n if (this.animationProgress >= this.targetAlpha - 0.001) {\r\n this.animationProgress = this.targetAlpha\r\n this.alpha = this.targetAlpha\r\n return\r\n }\r\n\r\n this.animationProgress += (this.targetAlpha - this.animationProgress) * this.randomSpeed\r\n this.alpha = this.animationProgress\r\n }\r\n}\r\n","import { ParticleContainer, Texture } from 'pixi.js'\r\nimport { Cell } from './Cell'\r\n\r\nexport class CellManager {\r\n private cells: Cell[] = []\r\n\r\n constructor(\r\n public texture: Texture,\r\n public particleContainerRefCurrent: ParticleContainer\r\n ) {\r\n this.texture = texture\r\n }\r\n\r\n add(x: number, y: number, scaleX: number, scaleY: number, curLevel: number) {\r\n const cell = new Cell(this.texture, x, y, scaleX, scaleY, curLevel)\r\n this.particleContainerRefCurrent.addParticle(cell)\r\n this.cells.push(cell)\r\n }\r\n\r\n updateAll() {\r\n for (const cell of this.cells) {\r\n cell.update()\r\n }\r\n }\r\n}","import { FC, useCallback, useContext, useEffect, useRef } from 'react'\r\nimport { ParticleContainer } from 'pixi.js'\r\nimport { CellTexturesContext } from '../context/CellTexturesContext'\r\nimport { useTick } from '@pixi/react'\r\nimport { CellManager } from '../classes/CellManager'\r\n\r\ninterface GridProps {\r\n gridCols: number\r\n gridRows: number\r\n cellWidth: number\r\n cellHeight: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGrid: FC<GridProps> = ({\r\n gridRows,\r\n gridCols,\r\n cellWidth,\r\n cellHeight,\r\n gridDepth,\r\n}) => {\r\n const texture = useContext(CellTexturesContext)\r\n const particleContainerRef = useRef<ParticleContainer>(null)\r\n const cellManager = useRef<CellManager>(null)\r\n\r\n useEffect(() => {\r\n if (!texture) return\r\n if (particleContainerRef.current) {\r\n // Clear any previous content on re-init\r\n try {\r\n particleContainerRef.current.removeChildren()\r\n } catch {}\r\n\r\n cellManager.current = new CellManager(\r\n texture,\r\n particleContainerRef.current\r\n )\r\n\r\n buildRecursiveGrid(\r\n 0,\r\n 0,\r\n cellWidth,\r\n cellHeight,\r\n gridCols,\r\n gridRows,\r\n gridDepth,\r\n particleContainerRef.current\r\n )\r\n }\r\n return () => {\r\n // Clean up particles and references on unmount/texture change\r\n try {\r\n particleContainerRef.current?.removeChildren()\r\n } catch {}\r\n cellManager.current = null\r\n }\r\n }, [texture, cellWidth, cellHeight, gridCols, gridRows, gridDepth])\r\n\r\n useTick(() => {\r\n cellManager.current?.updateAll()\r\n })\r\n\r\n const buildRecursiveGrid = useCallback(\r\n (\r\n x: number,\r\n y: number,\r\n cellWidth: number,\r\n cellHeight: number,\r\n gridCols: number,\r\n gridRows: number,\r\n curLevel: number,\r\n currentParticlesRef: ParticleContainer\r\n ) => {\r\n for (let row = 0; row < gridRows; row++) {\r\n for (let col = 0; col < gridCols; col++) {\r\n const startX = x + col * cellWidth\r\n const startY = y + row * cellHeight\r\n\r\n if (\r\n curLevel <= 0 ||\r\n (Math.random() > 0.7 && curLevel < gridDepth)\r\n ) {\r\n if (Math.random() > 0.1) {\r\n cellManager.current?.add(\r\n startX,\r\n startY,\r\n cellWidth - 1,\r\n cellHeight - 1,\r\n curLevel\r\n )\r\n }\r\n } else {\r\n buildRecursiveGrid(\r\n startX,\r\n startY,\r\n cellWidth / gridCols,\r\n cellHeight / gridRows,\r\n gridCols,\r\n gridRows,\r\n curLevel - 1,\r\n currentParticlesRef\r\n )\r\n }\r\n }\r\n }\r\n },\r\n []\r\n )\r\n\r\n return (\r\n <pixiParticleContainer\r\n ref={particleContainerRef}\r\n dynamicProperties={{\r\n position: true,\r\n vertex: true,\r\n color: true,\r\n }}\r\n />\r\n )\r\n}\r\n\r\nexport default RecursiveGrid\r\n","import { FC } from 'react'\r\nimport RecursiveGrid from './RecursiveGrid'\r\n\r\nimport { CellTexturesProvider } from '../context/CellTexturesContext'\r\n\r\ninterface RecursiveGridContainerProps {\r\n cellWidth: number\r\n cellHeight: number\r\n gridRows: number\r\n gridCols: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGridContainer: FC<RecursiveGridContainerProps> = ({\r\n cellWidth,\r\n cellHeight,\r\n gridRows,\r\n gridCols,\r\n gridDepth,\r\n}) => {\r\n return (\r\n <CellTexturesProvider>\r\n <RecursiveGrid\r\n cellWidth={cellWidth}\r\n cellHeight={cellHeight}\r\n gridCols={gridCols}\r\n gridRows={gridRows}\r\n gridDepth={gridDepth}\r\n />\r\n </CellTexturesProvider>\r\n )\r\n}\r\n\r\nexport default RecursiveGridContainer\r\n","import { Application, extend } from '@pixi/react'\r\nimport {\r\n Sprite,\r\n Graphics,\r\n Container,\r\n Texture,\r\n Particle,\r\n ParticleContainer,\r\n} from 'pixi.js'\r\nimport RecursiveGridContainer from './RecursiveGridContainer'\r\nimport { useEffect, useState } from 'react'\r\nextend({ ParticleContainer, Particle, Texture, Container, Sprite, Graphics })\r\n\r\nconst GRID_COLS = 2\r\nconst GRID_ROWS = 2\r\nconst CELL_WIDTH = 300\r\nconst CELL_HEIGHT = 300\r\nconst GRID_DEPTH = 6\r\n\r\nconst PixiApp = () => {\r\n const [reloadKey, setReloadKey] = useState<number>(0)\r\n\r\n useEffect(() => {\r\n setReloadKey((prev) => prev + 1)\r\n return () => {\r\n console.log('Pixi unmounted')\r\n setReloadKey((prev) => prev + 1)\r\n }\r\n }, [])\r\n\r\n return (\r\n <div className=\"flex flex-col items-center justify-center w-full h-full\">\r\n <Application\r\n key={reloadKey}\r\n antialias={false}\r\n width={CELL_WIDTH * GRID_COLS}\r\n height={CELL_HEIGHT * GRID_ROWS}\r\n className=\"image-pixelated w-full\"\r\n backgroundAlpha={0}\r\n autoDensity={true}\r\n preserveDrawingBuffer={true}\r\n powerPreference=\"high-performance\"\r\n >\r\n <RecursiveGridContainer\r\n gridCols={GRID_COLS}\r\n gridRows={GRID_ROWS}\r\n cellWidth={CELL_WIDTH}\r\n cellHeight={CELL_HEIGHT}\r\n gridDepth={GRID_DEPTH}\r\n />\r\n </Application>\r\n </div>\r\n )\r\n}\r\n\r\nexport default PixiApp\r\n"],"names":["REACT_ELEMENT_TYPE","REACT_FRAGMENT_TYPE","jsxProd","type","config","maybeKey","key","propName","reactJsxRuntime_production","getComponentNameFromType","REACT_CLIENT_REFERENCE","REACT_PROFILER_TYPE","REACT_STRICT_MODE_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_ACTIVITY_TYPE","REACT_PORTAL_TYPE","REACT_CONTEXT_TYPE","REACT_CONSUMER_TYPE","REACT_FORWARD_REF_TYPE","innerType","REACT_MEMO_TYPE","REACT_LAZY_TYPE","testStringCoercion","value","checkKeyStringCoercion","JSCompiler_inline_result","JSCompiler_temp_const","JSCompiler_inline_result$jscomp$0","getTaskName","name","getOwner","dispatcher","ReactSharedInternals","UnknownOwner","hasValidKey","hasOwnProperty","getter","defineKeyPropWarningGetter","props","displayName","warnAboutAccessingKey","specialPropKeyWarningShown","elementRefGetterWithDeprecationWarning","componentName","didWarnAboutElementRef","ReactElement","owner","debugStack","debugTask","refProp","jsxDEVImpl","isStaticChildren","children","isArrayImpl","validateChildKeys","keys","k","didWarnAboutKeySpread","node","isValidElement","object","React","require$$0","createTask","callStackForError","unknownOwnerDebugStack","unknownOwnerDebugTask","reactJsxRuntime_development","trackActualOwner","jsxRuntimeModule","require$$1","CellTexturesContext","createContext","CellTexturesProvider","app","useApplication","texture","setTexture","useState","useEffect","isUnmounted","generate","g","Graphics","generatedTexture","Cell","Particle","x","y","scaleX","scaleY","curLevel","__publicField","CellManager","particleContainerRefCurrent","cell","RecursiveGrid","gridRows","gridCols","cellWidth","cellHeight","gridDepth","useContext","particleContainerRef","useRef","cellManager","buildRecursiveGrid","_a","useTick","useCallback","currentParticlesRef","row","col","startX","startY","jsx","RecursiveGridContainer","extend","ParticleContainer","Texture","Container","Sprite","GRID_COLS","GRID_ROWS","CELL_WIDTH","CELL_HEIGHT","GRID_DEPTH","PixiApp","reloadKey","setReloadKey","prev","Application"],"mappings":";;;;;;;;;;;;;;;;;;;;AAWA,MAAIA,IAAqB,OAAO,IAAI,4BAA4B,GAC9DC,IAAsB,OAAO,IAAI,gBAAgB;AACnD,WAASC,EAAQC,GAAMC,GAAQC,GAAU;AACvC,QAAIC,IAAM;AAGV,QAFWD,MAAX,WAAwBC,IAAM,KAAKD,IACxBD,EAAO,QAAlB,WAA0BE,IAAM,KAAKF,EAAO,MACxC,SAASA,GAAQ;AACnB,MAAAC,IAAW,CAAA;AACX,eAASE,KAAYH;AACnB,QAAUG,MAAV,UAAuBF,EAASE,CAAQ,IAAIH,EAAOG,CAAQ;AAAA,IACjE,MAAS,CAAAF,IAAWD;AAClB,WAAAA,IAASC,EAAS,KACX;AAAA,MACL,UAAUL;AAAA,MACV,MAAMG;AAAA,MACN,KAAKG;AAAA,MACL,KAAgBF,MAAX,SAAoBA,IAAS;AAAA,MAClC,OAAOC;AAAA;EAEX;AACA,SAAAG,EAAA,WAAmBP,GACnBO,EAAA,MAAcN,GACdM,EAAA,OAAeN;;;;;;;;;;;;;;sBCtBE,QAAQ,IAAI,aAA7B,iBACG,WAAY;AACX,aAASO,EAAyBN,GAAM;AACtC,UAAYA,KAAR,KAAc,QAAO;AACzB,UAAmB,OAAOA,KAAtB;AACF,eAAOA,EAAK,aAAaO,KACrB,OACAP,EAAK,eAAeA,EAAK,QAAQ;AACvC,UAAiB,OAAOA,KAApB,SAA0B,QAAOA;AACrC,cAAQA,GAAI;AAAA,QACV,KAAKF;AACH,iBAAO;AAAA,QACT,KAAKU;AACH,iBAAO;AAAA,QACT,KAAKC;AACH,iBAAO;AAAA,QACT,KAA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,mBAAAC,IAAmB,UAAAhC,IAAU,SAAAiC,IAAS,WAAAC,IAAW,QAAAC,IAAQ,UAAAtC,IAAU;AAE5E,MAAMuC,IAAY,GACZC,IAAY,GACZC,IAAa,KACbC,IAAc,KACdC,KAAa,GAEbC,KAAU,MAAM;AAClB,QAAM,CAACC,GAAWC,CAAY,IAAInD,GAAiB,CAAC;AAEpD,SAAAC,EAAU,OACNkD,EAAa,CAACC,MAASA,IAAO,CAAC,GACxB,MAAM;AACT,YAAQ,IAAI,gBAAgB,GAC5BD,EAAa,CAACC,MAASA,IAAO,CAAC;AAAA,EACnC,IACD,CAAA,CAAE,GAGDf,gBAAAA,EAAAA,IAAC,OAAA,EAAI,WAAU,2DACX,UAAAA,gBAAAA,EAAAA;AAAAA,IAACgB;AAAA,IAAA;AAAA,MAEG,WAAW;AAAA,MACX,OAAOP,IAAaF;AAAA,MACpB,QAAQG,IAAcF;AAAA,MACtB,WAAU;AAAA,MACV,iBAAiB;AAAA,MACjB,aAAa;AAAA,MACb,uBAAuB;AAAA,MACvB,iBAAgB;AAAA,MAEhB,UAAAR,gBAAAA,EAAAA;AAAAA,QAACC;AAAA,QAAA;AAAA,UACG,UAAUM;AAAA,UACV,UAAUC;AAAA,UACV,WAAWC;AAAA,UACX,YAAYC;AAAA,UACZ,WAAWC;AAAA,QAAA;AAAA,MAAA;AAAA,IACf;AAAA,IAhBKE;AAAA,EAAA,GAkBb;AAER;","x_google_ignoreList":[0,1,2]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(s,m){typeof exports=="object"&&typeof module<"u"?module.exports=m(require("react"),require("@pixi/react"),require("pixi.js")):typeof define=="function"&&define.amd?define(["react","@pixi/react","pixi.js"],m):(s=typeof globalThis<"u"?globalThis:s||self,s["@micjanic/recursive-grid"]=m(s.React,s.PIXIReact,s.PIXI))})(this,(function(s,m,h){"use strict";var ve=Object.defineProperty;var _e=(s,m,h)=>m in s?ve(s,m,{enumerable:!0,configurable:!0,writable:!0,value:h}):s[m]=h;var R=(s,m,h)=>_e(s,typeof m!="symbol"?m+"":m,h);var O={exports:{}},A={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var W;function te(){if(W)return
|
|
9
|
+
*/var W;function te(){if(W)return A;W=1;var f=Symbol.for("react.transitional.element"),n=Symbol.for("react.fragment");function t(d,a,i){var o=null;if(i!==void 0&&(o=""+i),a.key!==void 0&&(o=""+a.key),"key"in a){i={};for(var p in a)p!=="key"&&(i[p]=a[p])}else i=a;return a=i.ref,{$$typeof:f,type:d,key:o,ref:a!==void 0?a:null,props:i}}return A.Fragment=n,A.jsx=t,A.jsxs=t,A}var S={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,10 +14,10 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var X;function ne(){return X||(X=1,process.env.NODE_ENV!=="production"&&(function(){function
|
|
17
|
+
*/var X;function ne(){return X||(X=1,process.env.NODE_ENV!=="production"&&(function(){function f(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===he?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case k:return"Fragment";case g:return"Profiler";case N:return"StrictMode";case fe:return"Suspense";case de:return"SuspenseList";case pe:return"Activity"}if(typeof e=="object")switch(typeof e.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),e.$$typeof){case P:return"Portal";case I:return e.displayName||"Context";case C:return(e._context.displayName||"Context")+".Consumer";case D:var r=e.render;return e=e.displayName,e||(e=r.displayName||r.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case me:return r=e.displayName||null,r!==null?r:f(e.type)||"Memo";case M:r=e._payload,e=e._init;try{return f(e(r))}catch{}}return null}function n(e){return""+e}function t(e){try{n(e);var r=!1}catch{r=!0}if(r){r=console;var l=r.error,u=typeof Symbol=="function"&&Symbol.toStringTag&&e[Symbol.toStringTag]||e.constructor.name||"Object";return l.call(r,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",u),n(e)}}function d(e){if(e===k)return"<>";if(typeof e=="object"&&e!==null&&e.$$typeof===M)return"<...>";try{var r=f(e);return r?"<"+r+">":"<...>"}catch{return"<...>"}}function a(){var e=F.A;return e===null?null:e.getOwner()}function i(){return Error("react-stack-top-frame")}function o(e){if(q.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function p(e,r){function l(){Q||(Q=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",r))}l.isReactWarning=!0,Object.defineProperty(e,"key",{get:l,configurable:!0})}function w(){var e=f(this.type);return K[e]||(K[e]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),e=this.props.ref,e!==void 0?e:null}function E(e,r,l,u,Y,L){var c=l.ref;return e={$$typeof:x,type:e,key:r,props:l,_owner:u},(c!==void 0?c:null)!==null?Object.defineProperty(e,"ref",{enumerable:!1,get:w}):Object.defineProperty(e,"ref",{enumerable:!1,value:null}),e._store={},Object.defineProperty(e._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(e,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(e,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:Y}),Object.defineProperty(e,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:L}),Object.freeze&&(Object.freeze(e.props),Object.freeze(e)),e}function j(e,r,l,u,Y,L){var c=r.children;if(c!==void 0)if(u)if(Ee(c)){for(u=0;u<c.length;u++)T(c[u]);Object.freeze&&Object.freeze(c)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else T(c);if(q.call(r,"key")){c=f(e);var y=Object.keys(r).filter(function(Re){return Re!=="key"});u=0<y.length?"{key: someKey, "+y.join(": ..., ")+": ...}":"{key: someKey}",re[c+u]||(y=0<y.length?"{"+y.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
18
18
|
let props = %s;
|
|
19
19
|
<%s {...props} />
|
|
20
20
|
React keys must be passed directly to JSX without using spread:
|
|
21
21
|
let props = %s;
|
|
22
|
-
<%s key={someKey} {...props} />`,u,c,
|
|
22
|
+
<%s key={someKey} {...props} />`,u,c,y,c),re[c+u]=!0)}if(c=null,l!==void 0&&(t(l),c=""+l),o(r)&&(t(r.key),c=""+r.key),"key"in r){l={};for(var U in r)U!=="key"&&(l[U]=r[U])}else l=r;return c&&p(l,typeof e=="function"?e.displayName||e.name||"Unknown":e),E(e,c,l,a(),Y,L)}function T(e){b(e)?e._store&&(e._store.validated=1):typeof e=="object"&&e!==null&&e.$$typeof===M&&(e._payload.status==="fulfilled"?b(e._payload.value)&&e._payload.value._store&&(e._payload.value._store.validated=1):e._store&&(e._store.validated=1))}function b(e){return typeof e=="object"&&e!==null&&e.$$typeof===x}var v=s,x=Symbol.for("react.transitional.element"),P=Symbol.for("react.portal"),k=Symbol.for("react.fragment"),N=Symbol.for("react.strict_mode"),g=Symbol.for("react.profiler"),C=Symbol.for("react.consumer"),I=Symbol.for("react.context"),D=Symbol.for("react.forward_ref"),fe=Symbol.for("react.suspense"),de=Symbol.for("react.suspense_list"),me=Symbol.for("react.memo"),M=Symbol.for("react.lazy"),pe=Symbol.for("react.activity"),he=Symbol.for("react.client.reference"),F=v.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,q=Object.prototype.hasOwnProperty,Ee=Array.isArray,G=console.createTask?console.createTask:function(){return null};v={react_stack_bottom_frame:function(e){return e()}};var Q,K={},$=v.react_stack_bottom_frame.bind(v,i)(),ee=G(d(i)),re={};S.Fragment=k,S.jsx=function(e,r,l){var u=1e4>F.recentlyCreatedOwnerStacks++;return j(e,r,l,!1,u?Error("react-stack-top-frame"):$,u?G(d(e)):ee)},S.jsxs=function(e,r,l){var u=1e4>F.recentlyCreatedOwnerStacks++;return j(e,r,l,!0,u?Error("react-stack-top-frame"):$,u?G(d(e)):ee)}})()),S}var J;function ae(){return J||(J=1,process.env.NODE_ENV==="production"?O.exports=te():O.exports=ne()),O.exports}var _=ae();const V=s.createContext({}),oe=({children:f})=>{const{app:n}=m.useApplication(),[t,d]=s.useState(null);return s.useEffect(()=>{if(!n)return;let a=!1;const i=()=>{if(!n.renderer){requestAnimationFrame(i);return}const o=new h.Graphics;o.setFillStyle({color:"#121225"}),o.rect(0,0,1,1),o.fill();const p=n.renderer.generateTexture(o);o.destroy(),a||d(p)};return i(),()=>{a=!0;try{t==null||t.destroy(!0)}catch{}d(null)}},[n]),t?_.jsx(V.Provider,{value:t,children:f}):null};class se extends h.Particle{constructor(t,d,a,i,o,p){super({texture:t,x:d,y:a,scaleX:i,scaleY:o,alpha:0});R(this,"animationProgress",0);R(this,"delayCounter",0);R(this,"randomSpeed");R(this,"randomDelayOffset");R(this,"startScaleX");R(this,"startScaleY");R(this,"targetAlpha");this.texture=t,this.x=d,this.y=a,this.scaleX=i,this.scaleY=o,this.curLevel=p,this.startScaleX=i,this.startScaleY=o,this.curLevel=p,this.randomSpeed=.04+Math.random()*.04,this.randomDelayOffset=Math.floor(Math.random()*150),this.targetAlpha=.9+Math.random()*.1}update(){if(this.delayCounter<this.curLevel*15+this.randomDelayOffset){this.delayCounter++;return}if(this.animationProgress>=this.targetAlpha-.001){this.animationProgress=this.targetAlpha,this.alpha=this.targetAlpha;return}this.animationProgress+=(this.targetAlpha-this.animationProgress)*this.randomSpeed,this.alpha=this.animationProgress}}class ie{constructor(n,t){R(this,"cells",[]);this.texture=n,this.particleContainerRefCurrent=t,this.texture=n}add(n,t,d,a,i){const o=new se(this.texture,n,t,d,a,i);this.particleContainerRefCurrent.addParticle(o),this.cells.push(o)}updateAll(){for(const n of this.cells)n.update()}}const le=({gridRows:f,gridCols:n,cellWidth:t,cellHeight:d,gridDepth:a})=>{const i=s.useContext(V),o=s.useRef(null),p=s.useRef(null);s.useEffect(()=>{if(i){if(o.current){try{o.current.removeChildren()}catch{}p.current=new ie(i,o.current),w(0,0,t,d,n,f,a,o.current)}return()=>{var E;try{(E=o.current)==null||E.removeChildren()}catch{}p.current=null}}},[i,t,d,n,f,a]),m.useTick(()=>{var E;(E=p.current)==null||E.updateAll()});const w=s.useCallback((E,j,T,b,v,x,P,k)=>{var N;for(let g=0;g<x;g++)for(let C=0;C<v;C++){const I=E+C*T,D=j+g*b;P<=0||Math.random()>.7&&P<a?Math.random()>.1&&((N=p.current)==null||N.add(I,D,T-1,b-1,P)):w(I,D,T/v,b/x,v,x,P-1,k)}},[]);return _.jsx("pixiParticleContainer",{ref:o,dynamicProperties:{position:!0,vertex:!0,color:!0}})},ue=({cellWidth:f,cellHeight:n,gridRows:t,gridCols:d,gridDepth:a})=>_.jsx(oe,{children:_.jsx(le,{cellWidth:f,cellHeight:n,gridCols:d,gridRows:t,gridDepth:a})});m.extend({ParticleContainer:h.ParticleContainer,Particle:h.Particle,Texture:h.Texture,Container:h.Container,Sprite:h.Sprite,Graphics:h.Graphics});const z=2,H=2,B=300,Z=300,ce=6;return()=>{const[f,n]=s.useState(0);return s.useEffect(()=>(n(t=>t+1),()=>{console.log("Pixi unmounted"),n(t=>t+1)}),[]),_.jsx("div",{className:"flex flex-col items-center justify-center w-full h-full",children:_.jsx(m.Application,{antialias:!1,width:B*z,height:Z*H,className:"image-pixelated w-full",backgroundAlpha:0,autoDensity:!0,preserveDrawingBuffer:!0,powerPreference:"high-performance",children:_.jsx(ue,{gridCols:z,gridRows:H,cellWidth:B,cellHeight:Z,gridDepth:ce})},f)})}}));
|
|
23
23
|
//# sourceMappingURL=recursive-grid.umd.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"recursive-grid.umd.js","sources":["../node_modules/react/cjs/react-jsx-runtime.production.js","../node_modules/react/cjs/react-jsx-runtime.development.js","../node_modules/react/jsx-runtime.js","../src/context/CellTexturesContext.tsx","../src/classes/Cell.ts","../src/classes/CellManager.ts","../src/components/RecursiveGrid.tsx","../src/components/RecursiveGridContainer.tsx","../src/components/PixiApp.tsx"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\");\nfunction jsxProd(type, config, maybeKey) {\n var key = null;\n void 0 !== maybeKey && (key = \"\" + maybeKey);\n void 0 !== config.key && (key = \"\" + config.key);\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n config = maybeKey.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== config ? config : null,\n props: maybeKey\n };\n}\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.jsx = jsxProd;\nexports.jsxs = jsxProd;\n","/**\n * @license React\n * react-jsx-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsx = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !1,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n exports.jsxs = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !0,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import { createContext, useContext, FC, ReactNode, useEffect, useState } from 'react'\r\nimport { useApplication } from '@pixi/react'\r\nimport { Graphics, Texture } from 'pixi.js'\r\n\r\ntype CellTextures = Texture\r\n\r\nconst CellTexturesContext = createContext<CellTextures>({} as CellTextures)\r\n\r\nexport const useCellTextures = () => useContext(CellTexturesContext)\r\n\r\nconst CellTexturesProvider: FC<{ children: ReactNode }> = ({ children }) => {\r\n const { app } = useApplication()\r\n const [texture, setTexture] = useState<Texture | null>(null)\r\n\r\n useEffect(() => {\r\n if (!app) return\r\n\r\n let isUnmounted = false\r\n\r\n const generate = () => {\r\n // Wait until Pixi Application has initialised the renderer\r\n if (!app.renderer) {\r\n requestAnimationFrame(generate)\r\n return\r\n }\r\n\r\n const g = new Graphics()\r\n g.setFillStyle({ color: '#121225' })\r\n g.rect(0, 0, 1, 1)\r\n g.fill()\r\n const generatedTexture = app.renderer.generateTexture(g)\r\n g.destroy()\r\n if (!isUnmounted) setTexture(generatedTexture)\r\n }\r\n\r\n generate()\r\n\r\n return () => {\r\n isUnmounted = true\r\n // Destroy generated texture to free GPU memory\r\n try {\r\n texture?.destroy(true)\r\n } catch {}\r\n setTexture(null)\r\n }\r\n }, [app])\r\n\r\n if (!texture) return null\r\n\r\n return (\r\n <CellTexturesContext.Provider value={texture}>\r\n {children}\r\n </CellTexturesContext.Provider>\r\n )\r\n}\r\n\r\nexport { CellTexturesContext, CellTexturesProvider }\r\n","import { Particle, Texture } from \"pixi.js\"\r\n\r\nexport class Cell extends Particle {\r\n private animationProgress = 0\r\n private delayCounter = 0\r\n private randomSpeed: number\r\n private randomDelayOffset: number\r\n startScaleX: number\r\n startScaleY: number\r\n targetAlpha: number\r\n\r\n constructor(\r\n public texture: Texture,\r\n public x: number,\r\n public y: number,\r\n public scaleX: number,\r\n public scaleY: number,\r\n public curLevel: number,\r\n ) {\r\n super({ texture, x, y, scaleX, scaleY, alpha: 0 })\r\n this.startScaleX = scaleX\r\n this.startScaleY = scaleY\r\n this.curLevel = curLevel\r\n\r\n // Randomize speed slightly (0.08 to 0.12)\r\n this.randomSpeed = 0.04 + Math.random() * 0.04\r\n // Randomize delay by a few frames\r\n this.randomDelayOffset = Math.floor(Math.random() * 150)\r\n this.targetAlpha = 0.9 + Math.random() * 0.1\r\n }\r\n\r\n update() {\r\n if (this.delayCounter < this.curLevel * 15 + this.randomDelayOffset) {\r\n this.delayCounter++\r\n return\r\n }\r\n\r\n if (this.animationProgress >= this.targetAlpha - 0.001) {\r\n this.animationProgress = this.targetAlpha\r\n this.alpha = this.targetAlpha\r\n return\r\n }\r\n\r\n this.animationProgress += (this.targetAlpha - this.animationProgress) * this.randomSpeed\r\n this.alpha = this.animationProgress\r\n }\r\n}\r\n","import { ParticleContainer, Texture } from 'pixi.js'\r\nimport { Cell } from './Cell'\r\n\r\nexport class CellManager {\r\n private cells: Cell[] = []\r\n\r\n constructor(\r\n public texture: Texture,\r\n public particleContainerRefCurrent: ParticleContainer\r\n ) {\r\n this.texture = texture\r\n }\r\n\r\n add(x: number, y: number, scaleX: number, scaleY: number, curLevel: number) {\r\n const cell = new Cell(this.texture, x, y, scaleX, scaleY, curLevel)\r\n this.particleContainerRefCurrent.addParticle(cell)\r\n this.cells.push(cell)\r\n }\r\n\r\n updateAll() {\r\n for (const cell of this.cells) {\r\n cell.update()\r\n }\r\n }\r\n}","import { FC, useCallback, useContext, useEffect, useRef } from 'react'\r\nimport { ParticleContainer } from 'pixi.js'\r\nimport { CellTexturesContext } from '../context/CellTexturesContext'\r\nimport { useTick } from '@pixi/react'\r\nimport { CellManager } from '../classes/CellManager'\r\n\r\ninterface GridProps {\r\n gridCols: number\r\n gridRows: number\r\n cellWidth: number\r\n cellHeight: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGrid: FC<GridProps> = ({\r\n gridRows,\r\n gridCols,\r\n cellWidth,\r\n cellHeight,\r\n gridDepth,\r\n}) => {\r\n const texture = useContext(CellTexturesContext)\r\n const particleContainerRef = useRef<ParticleContainer>(null)\r\n const cellManager = useRef<CellManager>(null)\r\n\r\n useEffect(() => {\r\n if (!texture) return\r\n if (particleContainerRef.current) {\r\n // Clear any previous content on re-init\r\n try {\r\n particleContainerRef.current.removeChildren()\r\n } catch {}\r\n\r\n cellManager.current = new CellManager(\r\n texture,\r\n particleContainerRef.current\r\n )\r\n\r\n buildRecursiveGrid(\r\n 0,\r\n 0,\r\n cellWidth,\r\n cellHeight,\r\n gridCols,\r\n gridRows,\r\n gridDepth,\r\n particleContainerRef.current\r\n )\r\n }\r\n return () => {\r\n // Clean up particles and references on unmount/texture change\r\n try {\r\n particleContainerRef.current?.removeChildren()\r\n } catch {}\r\n cellManager.current = null\r\n }\r\n }, [texture, cellWidth, cellHeight, gridCols, gridRows, gridDepth])\r\n\r\n useTick(() => {\r\n cellManager.current?.updateAll()\r\n })\r\n\r\n const buildRecursiveGrid = useCallback(\r\n (\r\n x: number,\r\n y: number,\r\n cellWidth: number,\r\n cellHeight: number,\r\n gridCols: number,\r\n gridRows: number,\r\n curLevel: number,\r\n currentParticlesRef: ParticleContainer\r\n ) => {\r\n for (let row = 0; row < gridRows; row++) {\r\n for (let col = 0; col < gridCols; col++) {\r\n const startX = x + col * cellWidth\r\n const startY = y + row * cellHeight\r\n\r\n if (\r\n curLevel <= 0 ||\r\n (Math.random() > 0.7 && curLevel < gridDepth)\r\n ) {\r\n if (Math.random() > 0.1) {\r\n cellManager.current?.add(\r\n startX,\r\n startY,\r\n cellWidth - 1,\r\n cellHeight - 1,\r\n curLevel\r\n )\r\n }\r\n } else {\r\n buildRecursiveGrid(\r\n startX,\r\n startY,\r\n cellWidth / gridCols,\r\n cellHeight / gridRows,\r\n gridCols,\r\n gridRows,\r\n curLevel - 1,\r\n currentParticlesRef\r\n )\r\n }\r\n }\r\n }\r\n },\r\n []\r\n )\r\n\r\n return (\r\n <pixiParticleContainer\r\n ref={particleContainerRef}\r\n dynamicProperties={{\r\n position: true,\r\n vertex: true,\r\n color: true,\r\n }}\r\n />\r\n )\r\n}\r\n\r\nexport default RecursiveGrid\r\n","import { FC } from 'react'\r\nimport RecursiveGrid from './RecursiveGrid'\r\n\r\nimport { CellTexturesProvider } from '../context/CellTexturesContext'\r\n\r\ninterface RecursiveGridContainerProps {\r\n cellWidth: number\r\n cellHeight: number\r\n gridRows: number\r\n gridCols: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGridContainer: FC<RecursiveGridContainerProps> = ({\r\n cellWidth,\r\n cellHeight,\r\n gridRows,\r\n gridCols,\r\n gridDepth,\r\n}) => {\r\n return (\r\n <CellTexturesProvider>\r\n <RecursiveGrid\r\n cellWidth={cellWidth}\r\n cellHeight={cellHeight}\r\n gridCols={gridCols}\r\n gridRows={gridRows}\r\n gridDepth={gridDepth}\r\n />\r\n </CellTexturesProvider>\r\n )\r\n}\r\n\r\nexport default RecursiveGridContainer\r\n","import { Application, extend } from '@pixi/react'\r\nimport {\r\n Sprite,\r\n Graphics,\r\n Container,\r\n Texture,\r\n Particle,\r\n ParticleContainer,\r\n} from 'pixi.js'\r\nimport RecursiveGridContainer from './RecursiveGridContainer'\r\nimport { useEffect } from 'react'\r\nextend({ ParticleContainer, Particle, Texture, Container, Sprite, Graphics })\r\n\r\nconst GRID_COLS = 2\r\nconst GRID_ROWS = 2\r\nconst CELL_WIDTH = 300\r\nconst CELL_HEIGHT = 300\r\nconst GRID_DEPTH = 6\r\n\r\nconst PixiApp = () => {\r\n useEffect(() => {\r\n console.log('Pixi mounted')\r\n return () => console.log('Pixi unmounted')\r\n }, [])\r\n\r\n return (\r\n <div className=\"flex flex-col items-center justify-center w-full h-full\">\r\n <Application\r\n antialias={false}\r\n width={CELL_WIDTH * GRID_COLS}\r\n height={CELL_HEIGHT * GRID_ROWS}\r\n className=\"image-pixelated w-full\"\r\n backgroundAlpha={0}\r\n autoDensity={true}\r\n preserveDrawingBuffer={true}\r\n powerPreference=\"high-performance\"\r\n >\r\n <RecursiveGridContainer\r\n gridCols={GRID_COLS}\r\n gridRows={GRID_ROWS}\r\n cellWidth={CELL_WIDTH}\r\n cellHeight={CELL_HEIGHT}\r\n gridDepth={GRID_DEPTH}\r\n />\r\n </Application>\r\n </div>\r\n )\r\n}\r\n\r\nexport default PixiApp\r\n"],"names":["REACT_ELEMENT_TYPE","REACT_FRAGMENT_TYPE","jsxProd","type","config","maybeKey","key","propName","reactJsxRuntime_production","getComponentNameFromType","REACT_CLIENT_REFERENCE","REACT_PROFILER_TYPE","REACT_STRICT_MODE_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_ACTIVITY_TYPE","REACT_PORTAL_TYPE","REACT_CONTEXT_TYPE","REACT_CONSUMER_TYPE","REACT_FORWARD_REF_TYPE","innerType","REACT_MEMO_TYPE","REACT_LAZY_TYPE","testStringCoercion","value","checkKeyStringCoercion","JSCompiler_inline_result","JSCompiler_temp_const","JSCompiler_inline_result$jscomp$0","getTaskName","name","getOwner","dispatcher","ReactSharedInternals","UnknownOwner","hasValidKey","hasOwnProperty","getter","defineKeyPropWarningGetter","props","displayName","warnAboutAccessingKey","specialPropKeyWarningShown","elementRefGetterWithDeprecationWarning","componentName","didWarnAboutElementRef","ReactElement","owner","debugStack","debugTask","refProp","jsxDEVImpl","isStaticChildren","children","isArrayImpl","validateChildKeys","keys","k","didWarnAboutKeySpread","node","isValidElement","object","React","require$$0","createTask","callStackForError","unknownOwnerDebugStack","unknownOwnerDebugTask","reactJsxRuntime_development","trackActualOwner","jsxRuntimeModule","require$$1","CellTexturesContext","createContext","CellTexturesProvider","app","useApplication","texture","setTexture","useState","useEffect","isUnmounted","generate","g","Graphics","generatedTexture","Cell","Particle","x","y","scaleX","scaleY","curLevel","__publicField","CellManager","particleContainerRefCurrent","cell","RecursiveGrid","gridRows","gridCols","cellWidth","cellHeight","gridDepth","useContext","particleContainerRef","useRef","cellManager","buildRecursiveGrid","_a","useTick","useCallback","currentParticlesRef","row","col","startX","startY","jsx","RecursiveGridContainer","extend","ParticleContainer","Texture","Container","Sprite","GRID_COLS","GRID_ROWS","CELL_WIDTH","CELL_HEIGHT","GRID_DEPTH","Application"],"mappings":";;;;;;;;yCAWA,IAAIA,EAAqB,OAAO,IAAI,4BAA4B,EAC9DC,EAAsB,OAAO,IAAI,gBAAgB,EACnD,SAASC,EAAQC,EAAMC,EAAQC,EAAU,CAC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","sources":["../node_modules/react/cjs/react-jsx-runtime.production.js","../node_modules/react/cjs/react-jsx-runtime.development.js","../node_modules/react/jsx-runtime.js","../src/context/CellTexturesContext.tsx","../src/classes/Cell.ts","../src/classes/CellManager.ts","../src/components/RecursiveGrid.tsx","../src/components/RecursiveGridContainer.tsx","../src/components/PixiApp.tsx"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\");\nfunction jsxProd(type, config, maybeKey) {\n var key = null;\n void 0 !== maybeKey && (key = \"\" + maybeKey);\n void 0 !== config.key && (key = \"\" + config.key);\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n config = maybeKey.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== config ? config : null,\n props: maybeKey\n };\n}\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.jsx = jsxProd;\nexports.jsxs = jsxProd;\n","/**\n * @license React\n * react-jsx-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsx = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !1,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n exports.jsxs = function (type, config, maybeKey) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n !0,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import { createContext, useContext, FC, ReactNode, useEffect, useState } from 'react'\r\nimport { useApplication } from '@pixi/react'\r\nimport { Graphics, Texture } from 'pixi.js'\r\n\r\ntype CellTextures = Texture\r\n\r\nconst CellTexturesContext = createContext<CellTextures>({} as CellTextures)\r\n\r\nexport const useCellTextures = () => useContext(CellTexturesContext)\r\n\r\nconst CellTexturesProvider: FC<{ children: ReactNode }> = ({ children }) => {\r\n const { app } = useApplication()\r\n const [texture, setTexture] = useState<Texture | null>(null)\r\n\r\n useEffect(() => {\r\n if (!app) return\r\n\r\n let isUnmounted = false\r\n\r\n const generate = () => {\r\n // Wait until Pixi Application has initialised the renderer\r\n if (!app.renderer) {\r\n requestAnimationFrame(generate)\r\n return\r\n }\r\n\r\n const g = new Graphics()\r\n g.setFillStyle({ color: '#121225' })\r\n g.rect(0, 0, 1, 1)\r\n g.fill()\r\n const generatedTexture = app.renderer.generateTexture(g)\r\n g.destroy()\r\n if (!isUnmounted) setTexture(generatedTexture)\r\n }\r\n\r\n generate()\r\n\r\n return () => {\r\n isUnmounted = true\r\n // Destroy generated texture to free GPU memory\r\n try {\r\n texture?.destroy(true)\r\n } catch {}\r\n setTexture(null)\r\n }\r\n }, [app])\r\n\r\n if (!texture) return null\r\n\r\n return (\r\n <CellTexturesContext.Provider value={texture}>\r\n {children}\r\n </CellTexturesContext.Provider>\r\n )\r\n}\r\n\r\nexport { CellTexturesContext, CellTexturesProvider }\r\n","import { Particle, Texture } from \"pixi.js\"\r\n\r\nexport class Cell extends Particle {\r\n private animationProgress = 0\r\n private delayCounter = 0\r\n private randomSpeed: number\r\n private randomDelayOffset: number\r\n startScaleX: number\r\n startScaleY: number\r\n targetAlpha: number\r\n\r\n constructor(\r\n public texture: Texture,\r\n public x: number,\r\n public y: number,\r\n public scaleX: number,\r\n public scaleY: number,\r\n public curLevel: number,\r\n ) {\r\n super({ texture, x, y, scaleX, scaleY, alpha: 0 })\r\n this.startScaleX = scaleX\r\n this.startScaleY = scaleY\r\n this.curLevel = curLevel\r\n\r\n // Randomize speed slightly (0.08 to 0.12)\r\n this.randomSpeed = 0.04 + Math.random() * 0.04\r\n // Randomize delay by a few frames\r\n this.randomDelayOffset = Math.floor(Math.random() * 150)\r\n this.targetAlpha = 0.9 + Math.random() * 0.1\r\n }\r\n\r\n update() {\r\n if (this.delayCounter < this.curLevel * 15 + this.randomDelayOffset) {\r\n this.delayCounter++\r\n return\r\n }\r\n\r\n if (this.animationProgress >= this.targetAlpha - 0.001) {\r\n this.animationProgress = this.targetAlpha\r\n this.alpha = this.targetAlpha\r\n return\r\n }\r\n\r\n this.animationProgress += (this.targetAlpha - this.animationProgress) * this.randomSpeed\r\n this.alpha = this.animationProgress\r\n }\r\n}\r\n","import { ParticleContainer, Texture } from 'pixi.js'\r\nimport { Cell } from './Cell'\r\n\r\nexport class CellManager {\r\n private cells: Cell[] = []\r\n\r\n constructor(\r\n public texture: Texture,\r\n public particleContainerRefCurrent: ParticleContainer\r\n ) {\r\n this.texture = texture\r\n }\r\n\r\n add(x: number, y: number, scaleX: number, scaleY: number, curLevel: number) {\r\n const cell = new Cell(this.texture, x, y, scaleX, scaleY, curLevel)\r\n this.particleContainerRefCurrent.addParticle(cell)\r\n this.cells.push(cell)\r\n }\r\n\r\n updateAll() {\r\n for (const cell of this.cells) {\r\n cell.update()\r\n }\r\n }\r\n}","import { FC, useCallback, useContext, useEffect, useRef } from 'react'\r\nimport { ParticleContainer } from 'pixi.js'\r\nimport { CellTexturesContext } from '../context/CellTexturesContext'\r\nimport { useTick } from '@pixi/react'\r\nimport { CellManager } from '../classes/CellManager'\r\n\r\ninterface GridProps {\r\n gridCols: number\r\n gridRows: number\r\n cellWidth: number\r\n cellHeight: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGrid: FC<GridProps> = ({\r\n gridRows,\r\n gridCols,\r\n cellWidth,\r\n cellHeight,\r\n gridDepth,\r\n}) => {\r\n const texture = useContext(CellTexturesContext)\r\n const particleContainerRef = useRef<ParticleContainer>(null)\r\n const cellManager = useRef<CellManager>(null)\r\n\r\n useEffect(() => {\r\n if (!texture) return\r\n if (particleContainerRef.current) {\r\n // Clear any previous content on re-init\r\n try {\r\n particleContainerRef.current.removeChildren()\r\n } catch {}\r\n\r\n cellManager.current = new CellManager(\r\n texture,\r\n particleContainerRef.current\r\n )\r\n\r\n buildRecursiveGrid(\r\n 0,\r\n 0,\r\n cellWidth,\r\n cellHeight,\r\n gridCols,\r\n gridRows,\r\n gridDepth,\r\n particleContainerRef.current\r\n )\r\n }\r\n return () => {\r\n // Clean up particles and references on unmount/texture change\r\n try {\r\n particleContainerRef.current?.removeChildren()\r\n } catch {}\r\n cellManager.current = null\r\n }\r\n }, [texture, cellWidth, cellHeight, gridCols, gridRows, gridDepth])\r\n\r\n useTick(() => {\r\n cellManager.current?.updateAll()\r\n })\r\n\r\n const buildRecursiveGrid = useCallback(\r\n (\r\n x: number,\r\n y: number,\r\n cellWidth: number,\r\n cellHeight: number,\r\n gridCols: number,\r\n gridRows: number,\r\n curLevel: number,\r\n currentParticlesRef: ParticleContainer\r\n ) => {\r\n for (let row = 0; row < gridRows; row++) {\r\n for (let col = 0; col < gridCols; col++) {\r\n const startX = x + col * cellWidth\r\n const startY = y + row * cellHeight\r\n\r\n if (\r\n curLevel <= 0 ||\r\n (Math.random() > 0.7 && curLevel < gridDepth)\r\n ) {\r\n if (Math.random() > 0.1) {\r\n cellManager.current?.add(\r\n startX,\r\n startY,\r\n cellWidth - 1,\r\n cellHeight - 1,\r\n curLevel\r\n )\r\n }\r\n } else {\r\n buildRecursiveGrid(\r\n startX,\r\n startY,\r\n cellWidth / gridCols,\r\n cellHeight / gridRows,\r\n gridCols,\r\n gridRows,\r\n curLevel - 1,\r\n currentParticlesRef\r\n )\r\n }\r\n }\r\n }\r\n },\r\n []\r\n )\r\n\r\n return (\r\n <pixiParticleContainer\r\n ref={particleContainerRef}\r\n dynamicProperties={{\r\n position: true,\r\n vertex: true,\r\n color: true,\r\n }}\r\n />\r\n )\r\n}\r\n\r\nexport default RecursiveGrid\r\n","import { FC } from 'react'\r\nimport RecursiveGrid from './RecursiveGrid'\r\n\r\nimport { CellTexturesProvider } from '../context/CellTexturesContext'\r\n\r\ninterface RecursiveGridContainerProps {\r\n cellWidth: number\r\n cellHeight: number\r\n gridRows: number\r\n gridCols: number\r\n gridDepth: number\r\n}\r\n\r\nconst RecursiveGridContainer: FC<RecursiveGridContainerProps> = ({\r\n cellWidth,\r\n cellHeight,\r\n gridRows,\r\n gridCols,\r\n gridDepth,\r\n}) => {\r\n return (\r\n <CellTexturesProvider>\r\n <RecursiveGrid\r\n cellWidth={cellWidth}\r\n cellHeight={cellHeight}\r\n gridCols={gridCols}\r\n gridRows={gridRows}\r\n gridDepth={gridDepth}\r\n />\r\n </CellTexturesProvider>\r\n )\r\n}\r\n\r\nexport default RecursiveGridContainer\r\n","import { Application, extend } from '@pixi/react'\r\nimport {\r\n Sprite,\r\n Graphics,\r\n Container,\r\n Texture,\r\n Particle,\r\n ParticleContainer,\r\n} from 'pixi.js'\r\nimport RecursiveGridContainer from './RecursiveGridContainer'\r\nimport { useEffect, useState } from 'react'\r\nextend({ ParticleContainer, Particle, Texture, Container, Sprite, Graphics })\r\n\r\nconst GRID_COLS = 2\r\nconst GRID_ROWS = 2\r\nconst CELL_WIDTH = 300\r\nconst CELL_HEIGHT = 300\r\nconst GRID_DEPTH = 6\r\n\r\nconst PixiApp = () => {\r\n const [reloadKey, setReloadKey] = useState<number>(0)\r\n\r\n useEffect(() => {\r\n setReloadKey((prev) => prev + 1)\r\n return () => {\r\n console.log('Pixi unmounted')\r\n setReloadKey((prev) => prev + 1)\r\n }\r\n }, [])\r\n\r\n return (\r\n <div className=\"flex flex-col items-center justify-center w-full h-full\">\r\n <Application\r\n key={reloadKey}\r\n antialias={false}\r\n width={CELL_WIDTH * GRID_COLS}\r\n height={CELL_HEIGHT * GRID_ROWS}\r\n className=\"image-pixelated w-full\"\r\n backgroundAlpha={0}\r\n autoDensity={true}\r\n preserveDrawingBuffer={true}\r\n powerPreference=\"high-performance\"\r\n >\r\n <RecursiveGridContainer\r\n gridCols={GRID_COLS}\r\n gridRows={GRID_ROWS}\r\n cellWidth={CELL_WIDTH}\r\n cellHeight={CELL_HEIGHT}\r\n gridDepth={GRID_DEPTH}\r\n />\r\n </Application>\r\n </div>\r\n )\r\n}\r\n\r\nexport default PixiApp\r\n"],"names":["REACT_ELEMENT_TYPE","REACT_FRAGMENT_TYPE","jsxProd","type","config","maybeKey","key","propName","reactJsxRuntime_production","getComponentNameFromType","REACT_CLIENT_REFERENCE","REACT_PROFILER_TYPE","REACT_STRICT_MODE_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_ACTIVITY_TYPE","REACT_PORTAL_TYPE","REACT_CONTEXT_TYPE","REACT_CONSUMER_TYPE","REACT_FORWARD_REF_TYPE","innerType","REACT_MEMO_TYPE","REACT_LAZY_TYPE","testStringCoercion","value","checkKeyStringCoercion","JSCompiler_inline_result","JSCompiler_temp_const","JSCompiler_inline_result$jscomp$0","getTaskName","name","getOwner","dispatcher","ReactSharedInternals","UnknownOwner","hasValidKey","hasOwnProperty","getter","defineKeyPropWarningGetter","props","displayName","warnAboutAccessingKey","specialPropKeyWarningShown","elementRefGetterWithDeprecationWarning","componentName","didWarnAboutElementRef","ReactElement","owner","debugStack","debugTask","refProp","jsxDEVImpl","isStaticChildren","children","isArrayImpl","validateChildKeys","keys","k","didWarnAboutKeySpread","node","isValidElement","object","React","require$$0","createTask","callStackForError","unknownOwnerDebugStack","unknownOwnerDebugTask","reactJsxRuntime_development","trackActualOwner","jsxRuntimeModule","require$$1","CellTexturesContext","createContext","CellTexturesProvider","app","useApplication","texture","setTexture","useState","useEffect","isUnmounted","generate","g","Graphics","generatedTexture","Cell","Particle","x","y","scaleX","scaleY","curLevel","__publicField","CellManager","particleContainerRefCurrent","cell","RecursiveGrid","gridRows","gridCols","cellWidth","cellHeight","gridDepth","useContext","particleContainerRef","useRef","cellManager","buildRecursiveGrid","_a","useTick","useCallback","currentParticlesRef","row","col","startX","startY","jsx","RecursiveGridContainer","extend","ParticleContainer","Texture","Container","Sprite","GRID_COLS","GRID_ROWS","CELL_WIDTH","CELL_HEIGHT","GRID_DEPTH","reloadKey","setReloadKey","prev","Application"],"mappings":";;;;;;;;yCAWA,IAAIA,EAAqB,OAAO,IAAI,4BAA4B,EAC9DC,EAAsB,OAAO,IAAI,gBAAgB,EACnD,SAASC,EAAQC,EAAMC,EAAQC,EAAU,CACvC,IAAIC,EAAM,KAGV,GAFWD,IAAX,SAAwBC,EAAM,GAAKD,GAC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