modern-canvas 0.13.1 → 0.13.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Engine.d.ts +0 -2
- package/dist/asset/Assets.d.ts +3 -3
- package/dist/asset/loaders/FontLoader.d.ts +1 -1
- package/dist/asset/loaders/GifLoader.d.ts +1 -1
- package/dist/asset/loaders/JsonLoader.d.ts +1 -1
- package/dist/asset/loaders/TextLoader.d.ts +1 -1
- package/dist/asset/loaders/TextureLoader.d.ts +1 -1
- package/dist/asset/parseMimeType.d.ts +1 -1
- package/dist/index.js +1169 -1214
- package/dist/render.d.ts +2 -1
- package/dist/scene/main/SceneTree.d.ts +2 -0
- package/dist/scene/main/Viewport.d.ts +1 -0
- package/dist/scene/main/Window.d.ts +3 -0
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { defineProperty as
|
|
1
|
+
import { defineProperty as qt, Observable as fe, Reactivable as Dr, parseColor as Ls, property as u, RawWeakMap as Ir, isGradient as Fs, isColorFillObject as _r, clearUndef as Br, idGenerator as zr, normalizeFill as $s, isNone as F, normalizeBackground as Vs, normalizeForeground as Gs, normalizeOutline as Ws, normalizeShadow as js, normalizeShape as qs, getDefaultStyle as Xs, normalizeText as Hs, normalizeTextContent as Ys, getDefaultTextStyle as Ks, getDefaultLayoutStyle as Zs } from "modern-idoc";
|
|
2
2
|
import { fonts as Js } from "modern-font";
|
|
3
3
|
import { extend as Qs } from "colord";
|
|
4
4
|
import ei from "colord/plugins/names";
|
|
5
|
-
import { Path2D as bt, Path2DSet as ti, svgToDom as ri, svgToPath2DSet as si, Matrix3 as
|
|
5
|
+
import { Path2D as bt, Path2DSet as ti, svgToDom as ri, svgToPath2DSet as si, Matrix3 as mr, BoundingBox as Nt } from "modern-path2d";
|
|
6
6
|
import { Text as ii, Character as oi } from "modern-text";
|
|
7
|
-
const
|
|
8
|
-
function
|
|
7
|
+
const Xt = /* @__PURE__ */ new Map();
|
|
8
|
+
function g(r, e) {
|
|
9
9
|
return function(t) {
|
|
10
10
|
Object.defineProperty(t.prototype, "is", {
|
|
11
11
|
value: r,
|
|
12
12
|
enumerable: !0,
|
|
13
13
|
configurable: !0
|
|
14
14
|
}), e && Object.keys(e).forEach((s) => {
|
|
15
|
-
|
|
15
|
+
qt(t, s, {
|
|
16
16
|
fallback: e[s]
|
|
17
17
|
});
|
|
18
|
-
}),
|
|
18
|
+
}), Xt.set(r, t);
|
|
19
19
|
};
|
|
20
20
|
}
|
|
21
21
|
function bl(r = "node", e = {}) {
|
|
22
|
-
const t =
|
|
22
|
+
const t = Xt.get(r);
|
|
23
23
|
if (!t)
|
|
24
24
|
throw new Error(`Failed to createNode, tag: ${r}`);
|
|
25
25
|
return new t().setProperties(e);
|
|
26
26
|
}
|
|
27
|
-
class
|
|
27
|
+
class U {
|
|
28
28
|
static _queue = [];
|
|
29
29
|
static _currentTime = 0;
|
|
30
30
|
static _elapsed = 0;
|
|
@@ -70,8 +70,8 @@ class M {
|
|
|
70
70
|
const l = o[h];
|
|
71
71
|
try {
|
|
72
72
|
l.cb();
|
|
73
|
-
} catch (
|
|
74
|
-
console.warn(
|
|
73
|
+
} catch (c) {
|
|
74
|
+
console.warn(c);
|
|
75
75
|
}
|
|
76
76
|
l.once || a.push(l);
|
|
77
77
|
}
|
|
@@ -80,10 +80,10 @@ class M {
|
|
|
80
80
|
this._queue = t;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
|
-
|
|
84
|
-
async function
|
|
83
|
+
U.start();
|
|
84
|
+
async function Nr(r) {
|
|
85
85
|
return new Promise((e) => {
|
|
86
|
-
|
|
86
|
+
U.on(
|
|
87
87
|
() => {
|
|
88
88
|
r?.(), e();
|
|
89
89
|
},
|
|
@@ -91,16 +91,16 @@ async function Lr(r) {
|
|
|
91
91
|
);
|
|
92
92
|
});
|
|
93
93
|
}
|
|
94
|
-
const
|
|
94
|
+
const Ht = Math.PI, B = Ht * 2;
|
|
95
95
|
let ai = 0;
|
|
96
96
|
function ni(r) {
|
|
97
97
|
return r?.__SPECTOR_Object_TAG?.id ?? ++ai;
|
|
98
98
|
}
|
|
99
|
-
function
|
|
99
|
+
function gr(r) {
|
|
100
100
|
return !(r & r - 1) && !!r;
|
|
101
101
|
}
|
|
102
102
|
const li = /([\w-]+)\((.+?)\)/g, hi = /[^,]+/g, ci = /([-e.\d]+)(.*)/;
|
|
103
|
-
function
|
|
103
|
+
function vr(r) {
|
|
104
104
|
return Array.isArray(r) ? r.map((e) => ({
|
|
105
105
|
name: e.name,
|
|
106
106
|
args: e.args.map((t) => ({
|
|
@@ -114,7 +114,7 @@ function br(r) {
|
|
|
114
114
|
}
|
|
115
115
|
function mt(r, e, t = {}) {
|
|
116
116
|
const s = Rt(e, t);
|
|
117
|
-
return s.length ? s :
|
|
117
|
+
return s.length ? s : Lr(r, e, t);
|
|
118
118
|
}
|
|
119
119
|
function Rt(r, e = {}) {
|
|
120
120
|
const t = [];
|
|
@@ -133,14 +133,14 @@ function ui(r, e, t = {}) {
|
|
|
133
133
|
let i, o = 0;
|
|
134
134
|
for (; (i = hi.exec(e)) !== null; )
|
|
135
135
|
s.push(
|
|
136
|
-
|
|
136
|
+
Lr(r, i[0], {
|
|
137
137
|
...t,
|
|
138
138
|
index: o++
|
|
139
139
|
})
|
|
140
140
|
);
|
|
141
141
|
return s;
|
|
142
142
|
}
|
|
143
|
-
function
|
|
143
|
+
function Lr(r, e, t = {}) {
|
|
144
144
|
const { width: s = 1, height: i = 1, index: o = 0 } = t, a = e.match(ci), n = {
|
|
145
145
|
unit: a?.[2] ?? null,
|
|
146
146
|
value: e,
|
|
@@ -187,7 +187,7 @@ function Fr(r, e, t = {}) {
|
|
|
187
187
|
}
|
|
188
188
|
return n;
|
|
189
189
|
}
|
|
190
|
-
const di = "WebGL2RenderingContext" in globalThis, fi = "ImageBitmap" in globalThis, pi = "ResizeObserver" in globalThis, He = "PointerEvent" in globalThis, _i = "WheelEvent" in globalThis, yl = "MouseEvent" in globalThis, ce = "ontouchstart" in globalThis, mi = "onclick" in globalThis,
|
|
190
|
+
const di = "WebGL2RenderingContext" in globalThis, fi = "ImageBitmap" in globalThis, pi = "ResizeObserver" in globalThis, He = "PointerEvent" in globalThis, _i = "WheelEvent" in globalThis, yl = "MouseEvent" in globalThis, ce = "ontouchstart" in globalThis, mi = "onclick" in globalThis, Fr = "createImageBitmap" in globalThis, $r = "AudioContext" in globalThis, Vr = "webkitAudioContext" in globalThis, Gr = "OfflineAudioContext" in globalThis, gi = "webkitOfflineAudioContext" in globalThis, vi = $r || Vr, Ot = typeof window < "u", bi = typeof navigator < "u" && navigator?.userAgent?.indexOf("Mac") >= 0, Wr = globalThis.devicePixelRatio || 1, jr = (r) => r !== null && typeof r == "object" && r.nodeType === 1, yi = (r) => jr(r) && r.tagName === "VIDEO", xl = (r) => jr(r) && r.tagName === "IMG";
|
|
191
191
|
function xi(r) {
|
|
192
192
|
return typeof r == "object" && r !== null && r.nodeType === 1 && r.tagName === "CANVAS";
|
|
193
193
|
}
|
|
@@ -208,7 +208,7 @@ function Ti(r, e = globalThis.location) {
|
|
|
208
208
|
function Ei(r, e, t) {
|
|
209
209
|
t === null && !e.startsWith("data:") ? r.crossOrigin = Ti(e) : t !== !1 && (r.crossOrigin = typeof t == "string" ? t : "anonymous");
|
|
210
210
|
}
|
|
211
|
-
class
|
|
211
|
+
class qr {
|
|
212
212
|
_map = /* @__PURE__ */ new WeakMap();
|
|
213
213
|
// fix: vue reactive object
|
|
214
214
|
_toRaw(e) {
|
|
@@ -245,7 +245,7 @@ class Xr {
|
|
|
245
245
|
return this._map.set(this._toRaw(e), this._toRaw(t)), this;
|
|
246
246
|
}
|
|
247
247
|
}
|
|
248
|
-
class
|
|
248
|
+
class Mt {
|
|
249
249
|
cursor;
|
|
250
250
|
// Event
|
|
251
251
|
bubbles = !1;
|
|
@@ -253,7 +253,7 @@ class kt {
|
|
|
253
253
|
cancelable = !1;
|
|
254
254
|
composed = !1;
|
|
255
255
|
defaultPrevented = !1;
|
|
256
|
-
eventPhase =
|
|
256
|
+
eventPhase = Mt.prototype.NONE;
|
|
257
257
|
isTrusted = !1;
|
|
258
258
|
timeStamp = 0;
|
|
259
259
|
type = "";
|
|
@@ -282,7 +282,7 @@ class kt {
|
|
|
282
282
|
throw new Error("initUIEvent() is a legacy DOM API. It is not implemented in the Federated Events API.");
|
|
283
283
|
}
|
|
284
284
|
}
|
|
285
|
-
class Si extends
|
|
285
|
+
class Si extends Mt {
|
|
286
286
|
getModifierState(...e) {
|
|
287
287
|
throw new Error("getModifierState() is a legacy DOM API. It is not implemented in the Federated Events API.");
|
|
288
288
|
}
|
|
@@ -290,7 +290,7 @@ class Si extends kt {
|
|
|
290
290
|
throw new Error("initKeyboardEvent() is a legacy DOM API. It is not implemented in the Federated Events API.");
|
|
291
291
|
}
|
|
292
292
|
}
|
|
293
|
-
class
|
|
293
|
+
class Xr extends Mt {
|
|
294
294
|
client = { x: 0, y: 0 };
|
|
295
295
|
get clientX() {
|
|
296
296
|
return this.client.x;
|
|
@@ -353,7 +353,7 @@ class Hr extends kt {
|
|
|
353
353
|
return this.global.y;
|
|
354
354
|
}
|
|
355
355
|
}
|
|
356
|
-
class Ci extends
|
|
356
|
+
class Ci extends Xr {
|
|
357
357
|
width = 0;
|
|
358
358
|
height = 0;
|
|
359
359
|
isPrimary = !1;
|
|
@@ -364,7 +364,7 @@ class Ci extends Hr {
|
|
|
364
364
|
throw new Error("getPredictedEvents is not supported!");
|
|
365
365
|
}
|
|
366
366
|
}
|
|
367
|
-
class Ai extends
|
|
367
|
+
class Ai extends Xr {
|
|
368
368
|
static DOM_DELTA_PIXEL = 0;
|
|
369
369
|
DOM_DELTA_PIXEL = 0;
|
|
370
370
|
static DOM_DELTA_LINE = 1;
|
|
@@ -535,9 +535,9 @@ class Oi extends fe {
|
|
|
535
535
|
this.removeEventListeners(), super.destroy();
|
|
536
536
|
}
|
|
537
537
|
}
|
|
538
|
-
let
|
|
539
|
-
class pe extends
|
|
540
|
-
instanceId = ++
|
|
538
|
+
let Mi = 0;
|
|
539
|
+
class pe extends Dr {
|
|
540
|
+
instanceId = ++Mi;
|
|
541
541
|
get json() {
|
|
542
542
|
return this.toJSON();
|
|
543
543
|
}
|
|
@@ -545,16 +545,16 @@ class pe extends Ir {
|
|
|
545
545
|
this.setProperties(e);
|
|
546
546
|
}
|
|
547
547
|
_nextTick() {
|
|
548
|
-
return
|
|
548
|
+
return Nr();
|
|
549
549
|
}
|
|
550
550
|
equal(e) {
|
|
551
551
|
return !!(e && this.instanceId === e.instanceId);
|
|
552
552
|
}
|
|
553
553
|
}
|
|
554
|
-
class
|
|
554
|
+
class ki extends pe {
|
|
555
555
|
//
|
|
556
556
|
}
|
|
557
|
-
class _e extends
|
|
557
|
+
class _e extends ki {
|
|
558
558
|
//
|
|
559
559
|
}
|
|
560
560
|
Qs([ei]);
|
|
@@ -651,11 +651,11 @@ class Z extends fe {
|
|
|
651
651
|
const { cols: l } = t;
|
|
652
652
|
switch (e) {
|
|
653
653
|
case "*":
|
|
654
|
-
for (let
|
|
654
|
+
for (let c = 0; c < i; c++) {
|
|
655
655
|
let d = 0;
|
|
656
656
|
for (let f = 0; f < i; f++)
|
|
657
|
-
d += o[
|
|
658
|
-
h[
|
|
657
|
+
d += o[c] * a[f * l + c];
|
|
658
|
+
h[c] = d;
|
|
659
659
|
}
|
|
660
660
|
break;
|
|
661
661
|
default:
|
|
@@ -680,20 +680,20 @@ class Z extends fe {
|
|
|
680
680
|
h[l] = o[l] / a[l];
|
|
681
681
|
break;
|
|
682
682
|
case "rot": {
|
|
683
|
-
const l = Math.cos(a[0]),
|
|
684
|
-
h[0] = o[0] * l - o[1] *
|
|
683
|
+
const l = Math.cos(a[0]), c = Math.sin(a[0]);
|
|
684
|
+
h[0] = o[0] * l - o[1] * c, h[1] = o[1] * l + o[0] * c;
|
|
685
685
|
break;
|
|
686
686
|
}
|
|
687
687
|
case "==": {
|
|
688
688
|
let l = !0;
|
|
689
|
-
for (let
|
|
690
|
-
l = l && o[
|
|
689
|
+
for (let c = 0; c < i; c++)
|
|
690
|
+
l = l && o[c] === a[c];
|
|
691
691
|
return l;
|
|
692
692
|
}
|
|
693
693
|
case "=":
|
|
694
694
|
for (let l = 0; l < i; l++) {
|
|
695
|
-
const
|
|
696
|
-
|
|
695
|
+
const c = a[l];
|
|
696
|
+
c !== void 0 && (o[l] = c);
|
|
697
697
|
}
|
|
698
698
|
return this._onUpdate(o), this.emit("update", o), this;
|
|
699
699
|
default:
|
|
@@ -757,8 +757,8 @@ class se extends fe {
|
|
|
757
757
|
const { cols: i, rows: o, length: a, _array: n } = this;
|
|
758
758
|
let h;
|
|
759
759
|
typeof t == "number" ? h = Array.from({ length: a }, () => t) : t instanceof Z || t instanceof se ? h = t.toArray() : h = t;
|
|
760
|
-
let l,
|
|
761
|
-
if (s ? s instanceof Z || s instanceof se ? l = s :
|
|
760
|
+
let l, c = [];
|
|
761
|
+
if (s ? s instanceof Z || s instanceof se ? l = s : c = s : t instanceof Z ? l = new t.constructor() : l = this, t instanceof Z) {
|
|
762
762
|
const { dim: d } = t;
|
|
763
763
|
switch (e) {
|
|
764
764
|
case "*":
|
|
@@ -766,7 +766,7 @@ class se extends fe {
|
|
|
766
766
|
let _ = 0;
|
|
767
767
|
for (let p = 0; p < i; p++)
|
|
768
768
|
p < d && (_ += n[f * i + p] * (h[p] ?? 0));
|
|
769
|
-
|
|
769
|
+
c[f] = _;
|
|
770
770
|
}
|
|
771
771
|
break;
|
|
772
772
|
default:
|
|
@@ -780,10 +780,10 @@ class se extends fe {
|
|
|
780
780
|
const _ = f * i;
|
|
781
781
|
let p = 0;
|
|
782
782
|
for (let m = 0; m < o; m++) {
|
|
783
|
-
const
|
|
784
|
-
p += n[
|
|
783
|
+
const v = _ + m, y = m * i + d;
|
|
784
|
+
p += n[v] * (h[y] ?? 0);
|
|
785
785
|
}
|
|
786
|
-
|
|
786
|
+
c[_ + d] = p;
|
|
787
787
|
}
|
|
788
788
|
break;
|
|
789
789
|
case "=":
|
|
@@ -795,7 +795,7 @@ class se extends fe {
|
|
|
795
795
|
default:
|
|
796
796
|
throw new Error(`Not support operator in '${this.toName()} ${e} Matrix2'`);
|
|
797
797
|
}
|
|
798
|
-
return l?.set(
|
|
798
|
+
return l?.set(c) ?? c;
|
|
799
799
|
}
|
|
800
800
|
identity() {
|
|
801
801
|
const { cols: e, rows: t } = this, s = [];
|
|
@@ -848,7 +848,7 @@ class Ui extends se {
|
|
|
848
848
|
super(4, 4, e);
|
|
849
849
|
}
|
|
850
850
|
}
|
|
851
|
-
const Di =
|
|
851
|
+
const Di = Ht / 180, wl = 180 / Ht;
|
|
852
852
|
function ie(r, e, t) {
|
|
853
853
|
return Math.max(e, Math.min(r, t));
|
|
854
854
|
}
|
|
@@ -873,7 +873,7 @@ class Ii extends Z {
|
|
|
873
873
|
super(4), this.set(e, t, s, i);
|
|
874
874
|
}
|
|
875
875
|
}
|
|
876
|
-
class
|
|
876
|
+
class Hr extends se {
|
|
877
877
|
constructor(e) {
|
|
878
878
|
super(4, 5, e);
|
|
879
879
|
}
|
|
@@ -1136,7 +1136,7 @@ class Tl extends se {
|
|
|
1136
1136
|
super(2, 2, e);
|
|
1137
1137
|
}
|
|
1138
1138
|
}
|
|
1139
|
-
class
|
|
1139
|
+
class Yr extends se {
|
|
1140
1140
|
constructor(e) {
|
|
1141
1141
|
super(3, 3, e);
|
|
1142
1142
|
}
|
|
@@ -1151,7 +1151,7 @@ class Kr extends se {
|
|
|
1151
1151
|
n,
|
|
1152
1152
|
h,
|
|
1153
1153
|
l
|
|
1154
|
-
] = this._array,
|
|
1154
|
+
] = this._array, c = l * o - a * h, d = a * n - l * i, f = h * i - o * n, _ = e * c + t * d + s * f;
|
|
1155
1155
|
if (_ === 0)
|
|
1156
1156
|
return this.set([
|
|
1157
1157
|
0,
|
|
@@ -1166,7 +1166,7 @@ class Kr extends se {
|
|
|
1166
1166
|
]);
|
|
1167
1167
|
const p = 1 / _;
|
|
1168
1168
|
return this.set([
|
|
1169
|
-
|
|
1169
|
+
c * p,
|
|
1170
1170
|
(s * h - l * t) * p,
|
|
1171
1171
|
(a * t - s * o) * p,
|
|
1172
1172
|
d * p,
|
|
@@ -1178,7 +1178,7 @@ class Kr extends se {
|
|
|
1178
1178
|
]);
|
|
1179
1179
|
}
|
|
1180
1180
|
}
|
|
1181
|
-
class Bi extends
|
|
1181
|
+
class Bi extends Yr {
|
|
1182
1182
|
constructor(e = 0, t = 0, s = 0, i = 0, o = !1) {
|
|
1183
1183
|
super(), this._x = e, this._y = t, this._width = s, this._height = i, this._flipY = o, this._performUpdateArray();
|
|
1184
1184
|
}
|
|
@@ -1274,7 +1274,7 @@ class C extends Z {
|
|
|
1274
1274
|
return new C(t).clone().sub(e).multiply(s).add(e);
|
|
1275
1275
|
}
|
|
1276
1276
|
}
|
|
1277
|
-
class
|
|
1277
|
+
class ye {
|
|
1278
1278
|
get x() {
|
|
1279
1279
|
return this.position.x;
|
|
1280
1280
|
}
|
|
@@ -1309,11 +1309,11 @@ class be {
|
|
|
1309
1309
|
break;
|
|
1310
1310
|
case 1: {
|
|
1311
1311
|
const i = e[0];
|
|
1312
|
-
if (i instanceof
|
|
1312
|
+
if (i instanceof ye)
|
|
1313
1313
|
t.set(i.position), s.set(i.size);
|
|
1314
1314
|
else {
|
|
1315
|
-
const o = i.map((d) => d.x), a = i.map((d) => d.y), n = Math.min(...o), h = Math.max(...o), l = Math.min(...a),
|
|
1316
|
-
t.set(n, l), s.set(h - n,
|
|
1315
|
+
const o = i.map((d) => d.x), a = i.map((d) => d.y), n = Math.min(...o), h = Math.max(...o), l = Math.min(...a), c = Math.max(...a);
|
|
1316
|
+
t.set(n, l), s.set(h - n, c - l);
|
|
1317
1317
|
}
|
|
1318
1318
|
break;
|
|
1319
1319
|
}
|
|
@@ -1352,7 +1352,7 @@ class be {
|
|
|
1352
1352
|
};
|
|
1353
1353
|
}
|
|
1354
1354
|
}
|
|
1355
|
-
class O extends
|
|
1355
|
+
class O extends Yr {
|
|
1356
1356
|
static _t2d = /* @__PURE__ */ new O();
|
|
1357
1357
|
premultiply(e) {
|
|
1358
1358
|
return e.multiply(this, this);
|
|
@@ -1461,7 +1461,7 @@ class O extends Kr {
|
|
|
1461
1461
|
if (e === 0 && t === 0)
|
|
1462
1462
|
return [0, 0, i];
|
|
1463
1463
|
{
|
|
1464
|
-
const o = Math.cos(i), a = Math.sin(i), n = o + e * e * (1 - o), h = e * t * (1 - o) - s * a, l = e * s * (1 - o) + t * a,
|
|
1464
|
+
const o = Math.cos(i), a = Math.sin(i), n = o + e * e * (1 - o), h = e * t * (1 - o) - s * a, l = e * s * (1 - o) + t * a, c = o + t * t * (1 - o), d = t * s * (1 - o) - e * a, f = o + s * s * (1 - o), _ = -Math.atan2(-d, c), p = -Math.atan2(l, Math.sqrt(d * d + f * f)), m = -Math.atan2(-h, n);
|
|
1465
1465
|
return [_, p, m];
|
|
1466
1466
|
}
|
|
1467
1467
|
}
|
|
@@ -1485,21 +1485,21 @@ class O extends Kr {
|
|
|
1485
1485
|
skew: { x: 0, y: 0 },
|
|
1486
1486
|
rotation: 0
|
|
1487
1487
|
}) {
|
|
1488
|
-
const { a: s, b: i, c: o, d: a, tx: n, ty: h } = this.toObject(), l = -Math.atan2(-o, a),
|
|
1489
|
-
return d < 1e-5 || Math.abs(B - d) < 1e-5 ? (t.rotation =
|
|
1488
|
+
const { a: s, b: i, c: o, d: a, tx: n, ty: h } = this.toObject(), l = -Math.atan2(-o, a), c = Math.atan2(i, s), d = Math.abs(l + c);
|
|
1489
|
+
return d < 1e-5 || Math.abs(B - d) < 1e-5 ? (t.rotation = c, t.skew.x = t.skew.y = 0) : (t.rotation = 0, t.skew.x = l, t.skew.y = c), t.scale.x = Math.sqrt(s * s + i * i), t.scale.y = Math.sqrt(o * o + a * a), t.position.x = n + (e.x * s + e.y * o), t.position.y = h + (e.x * i + e.y * a), t;
|
|
1490
1490
|
}
|
|
1491
1491
|
apply(e, t) {
|
|
1492
1492
|
t = t || new C();
|
|
1493
|
-
const { a: s, c: i, tx: o, b: a, d: n, ty: h } = this.toObject(), l = e.x,
|
|
1494
|
-
return t.x = s * l + i *
|
|
1493
|
+
const { a: s, c: i, tx: o, b: a, d: n, ty: h } = this.toObject(), l = e.x, c = e.y;
|
|
1494
|
+
return t.x = s * l + i * c + o, t.y = a * l + n * c + h, t;
|
|
1495
1495
|
}
|
|
1496
1496
|
affineInverse() {
|
|
1497
1497
|
return this.clone().affineInvert();
|
|
1498
1498
|
}
|
|
1499
1499
|
applyAffineInverse(e, t) {
|
|
1500
1500
|
t = t || new C();
|
|
1501
|
-
const { a: s, b: i, c: o, d: a, tx: n, ty: h } = this.toObject(), l = 1 / (s * a + o * -i),
|
|
1502
|
-
return t.x = a * l *
|
|
1501
|
+
const { a: s, b: i, c: o, d: a, tx: n, ty: h } = this.toObject(), l = 1 / (s * a + o * -i), c = e.x, d = e.y;
|
|
1502
|
+
return t.x = a * l * c + -o * l * d + (h * o - n * a) * l, t.y = s * l * d + -i * l * c + (-h * s + n * i) * l, t;
|
|
1503
1503
|
}
|
|
1504
1504
|
isIdentity() {
|
|
1505
1505
|
const { a: e, b: t, c: s, d: i, tx: o, ty: a } = this.toObject();
|
|
@@ -1525,12 +1525,12 @@ class El extends Z {
|
|
|
1525
1525
|
super(3);
|
|
1526
1526
|
}
|
|
1527
1527
|
}
|
|
1528
|
-
var zi = Object.defineProperty,
|
|
1528
|
+
var zi = Object.defineProperty, Kr = (r, e, t, s) => {
|
|
1529
1529
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
1530
1530
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
1531
1531
|
return i && zi(e, t, i), i;
|
|
1532
1532
|
};
|
|
1533
|
-
class
|
|
1533
|
+
class Yt extends pe {
|
|
1534
1534
|
_starting = !1;
|
|
1535
1535
|
_nextDeltaTime = 0;
|
|
1536
1536
|
_startedProcess;
|
|
@@ -1544,13 +1544,13 @@ class Kt extends pe {
|
|
|
1544
1544
|
super(), this._onTicker = this._onTicker.bind(this), this.setProperties(e);
|
|
1545
1545
|
}
|
|
1546
1546
|
start(e) {
|
|
1547
|
-
this._starting || (this._starting = !0, this._startedProcess && this.off("process", this._startedProcess), this._startedProcess = e, this.on("process", e),
|
|
1547
|
+
this._starting || (this._starting = !0, this._startedProcess && this.off("process", this._startedProcess), this._startedProcess = e, this.on("process", e), U.on(this._onTicker, { sort: 0 }));
|
|
1548
1548
|
}
|
|
1549
1549
|
stop() {
|
|
1550
|
-
this._starting && (this._starting = !1,
|
|
1550
|
+
this._starting && (this._starting = !1, U.off(this._onTicker, { sort: 0 }));
|
|
1551
1551
|
}
|
|
1552
1552
|
_onTicker() {
|
|
1553
|
-
const e =
|
|
1553
|
+
const e = U.elapsed * this.speed;
|
|
1554
1554
|
if ((this._nextDeltaTime -= e) <= 0) {
|
|
1555
1555
|
const s = (this._nextDeltaTime = this.spf) || e;
|
|
1556
1556
|
this.emit("process", s);
|
|
@@ -1560,20 +1560,20 @@ class Kt extends pe {
|
|
|
1560
1560
|
this.stop(), super.destroy();
|
|
1561
1561
|
}
|
|
1562
1562
|
}
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
],
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
],
|
|
1569
|
-
var Ni = Object.defineProperty,
|
|
1563
|
+
Kr([
|
|
1564
|
+
u({ fallback: 60 })
|
|
1565
|
+
], Yt.prototype, "fps");
|
|
1566
|
+
Kr([
|
|
1567
|
+
u({ fallback: 1 })
|
|
1568
|
+
], Yt.prototype, "speed");
|
|
1569
|
+
var Ni = Object.defineProperty, Zr = (r, e, t, s) => {
|
|
1570
1570
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
1571
1571
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
1572
1572
|
return i && Ni(e, t, i), i;
|
|
1573
1573
|
};
|
|
1574
|
-
class
|
|
1574
|
+
class Kt extends Dr {
|
|
1575
1575
|
screen = { x: 0, y: 0, width: 0, height: 0 };
|
|
1576
|
-
related = new
|
|
1576
|
+
related = new qr();
|
|
1577
1577
|
_updateProperty(e, t, s) {
|
|
1578
1578
|
switch (super._updateProperty(e, t, s), e) {
|
|
1579
1579
|
case "view":
|
|
@@ -1593,12 +1593,12 @@ class Zt extends Ir {
|
|
|
1593
1593
|
super.destroy();
|
|
1594
1594
|
}
|
|
1595
1595
|
}
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
],
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
],
|
|
1596
|
+
Zr([
|
|
1597
|
+
u({ fallback: Wr })
|
|
1598
|
+
], Kt.prototype, "pixelRatio");
|
|
1599
|
+
Zr([
|
|
1600
|
+
u({ internal: !0 })
|
|
1601
|
+
], Kt.prototype, "view");
|
|
1602
1602
|
var Ze = /* @__PURE__ */ ((r) => (r.NORMAL = "normal", r.ADD = "add", r.MULTIPLY = "multiply", r.SCREEN = "screen", r.NONE = "none", r.NORMAL_NPM = "normal_npm", r.ADD_NPM = "add_npm", r.SCREEN_NPM = "screen_npm", r.SRC_IN = "src_in", r.SRC_OUT = "src_out", r.SRC_ATOP = "src_atop", r.DST_OVER = "dst_over", r.DST_IN = "dst_in", r.DST_OUT = "dst_out", r.DST_ATOP = "dst_atop", r.XOR = "xor", r.SUBTRACT = "subtract", r))(Ze || {});
|
|
1603
1603
|
function Li(r) {
|
|
1604
1604
|
return {
|
|
@@ -1835,11 +1835,10 @@ void main(void) {
|
|
|
1835
1835
|
vec2 uv = vUv;
|
|
1836
1836
|
|
|
1837
1837
|
if (vSize.x > 0.0 && vSize.y > 0.0) {
|
|
1838
|
-
uv = floor(uv * vSize);
|
|
1839
|
-
uv = uv / vSize;
|
|
1838
|
+
uv = floor(uv * vSize + vec2(0.5)) / vSize;
|
|
1840
1839
|
}
|
|
1841
1840
|
|
|
1842
|
-
vec4 color = vec4(0.0
|
|
1841
|
+
vec4 color = vec4(0.0);
|
|
1843
1842
|
if (vDisableWrapMode > 0.0 && (uv.x < 0.0 || uv.y < 0.0 || uv.x > 1.0 || uv.y > 1.0))
|
|
1844
1843
|
{
|
|
1845
1844
|
//
|
|
@@ -1848,20 +1847,22 @@ void main(void) {
|
|
|
1848
1847
|
if (vTextureId < 0.0)
|
|
1849
1848
|
{
|
|
1850
1849
|
//
|
|
1851
|
-
}${Array.from({ length: e }, (l,
|
|
1850
|
+
}${Array.from({ length: e }, (l, c) => {
|
|
1852
1851
|
let d = " ";
|
|
1853
|
-
return
|
|
1854
|
-
else `),
|
|
1855
|
-
if (vTextureId < ${
|
|
1852
|
+
return c >= 0 && (d += `
|
|
1853
|
+
else `), c < e - 1 && (d += `
|
|
1854
|
+
if (vTextureId < ${c}.5)`), `${d}
|
|
1856
1855
|
{
|
|
1857
|
-
color = texture2D(samplers[${
|
|
1856
|
+
color = texture2D(samplers[${c}], uv);
|
|
1858
1857
|
}`;
|
|
1859
1858
|
}).join("")}
|
|
1860
1859
|
|
|
1861
1860
|
color += (1.0 - color.a) * vBackgroundColor;
|
|
1861
|
+
|
|
1862
1862
|
if (color.a > 0.0) {
|
|
1863
1863
|
color *= vModulate;
|
|
1864
1864
|
}
|
|
1865
|
+
|
|
1865
1866
|
gl_FragColor = color;
|
|
1866
1867
|
}`
|
|
1867
1868
|
}), i = t.buffer.create({
|
|
@@ -1874,33 +1875,33 @@ void main(void) {
|
|
|
1874
1875
|
usage: "dynamic_draw"
|
|
1875
1876
|
}), a = {
|
|
1876
1877
|
attributes: Object.fromEntries(
|
|
1877
|
-
Object.entries(this._attributes).map(([l,
|
|
1878
|
+
Object.entries(this._attributes).map(([l, c]) => [l, { ...c, buffer: i }])
|
|
1878
1879
|
),
|
|
1879
1880
|
elementArrayBuffer: o
|
|
1880
1881
|
}, n = t.vertexArray.create(s, a), h = new Int32Array(
|
|
1881
|
-
Array.from({ length: e }, (l,
|
|
1882
|
+
Array.from({ length: e }, (l, c) => c)
|
|
1882
1883
|
);
|
|
1883
1884
|
return {
|
|
1884
|
-
update: (l,
|
|
1885
|
+
update: (l, c) => {
|
|
1885
1886
|
t.vertexArray.bind(n ?? a), t.buffer.update(i, {
|
|
1886
1887
|
target: "array_buffer",
|
|
1887
1888
|
data: l
|
|
1888
1889
|
}), t.buffer.update(o, {
|
|
1889
1890
|
target: "element_array_buffer",
|
|
1890
|
-
data:
|
|
1891
|
+
data: c
|
|
1891
1892
|
});
|
|
1892
1893
|
},
|
|
1893
1894
|
draw: (l) => {
|
|
1894
|
-
const
|
|
1895
|
-
|
|
1896
|
-
const d =
|
|
1897
|
-
|
|
1895
|
+
const c = this._renderer;
|
|
1896
|
+
c.program.bind(s);
|
|
1897
|
+
const d = c.program.uniforms.viewMatrix;
|
|
1898
|
+
c.program.updateUniforms(s, {
|
|
1898
1899
|
samplers: h,
|
|
1899
1900
|
modulate: [1, 1, 1, 1],
|
|
1900
1901
|
zoom: [d[0], d[4]],
|
|
1901
1902
|
translate: [d[6], d[7]],
|
|
1902
|
-
...
|
|
1903
|
-
}),
|
|
1903
|
+
...c.program.uniforms
|
|
1904
|
+
}), c.vertexArray.bind(n ?? a), c.draw(l);
|
|
1904
1905
|
}
|
|
1905
1906
|
};
|
|
1906
1907
|
}
|
|
@@ -1914,33 +1915,33 @@ void main(void) {
|
|
|
1914
1915
|
const e = this._vertexCount, t = this._indexCount, s = this._batchables;
|
|
1915
1916
|
this._batchables = [], this._vertexCount = 0, this._indexCount = 0;
|
|
1916
1917
|
const i = this._renderer.texture.maxUnits, o = this._getAttributeBuffer(e), a = new Float32Array(o), n = new Uint8Array(o), h = this._getIndexBuffer(t);
|
|
1917
|
-
let l = 0,
|
|
1918
|
+
let l = 0, c = 0;
|
|
1918
1919
|
const d = [];
|
|
1919
|
-
for (let _ = s.length, p = { id: ++this._drawCallUid }, m = [],
|
|
1920
|
-
const A = s[R].texture,
|
|
1921
|
-
if (!A ||
|
|
1922
|
-
if (!
|
|
1920
|
+
for (let _ = s.length, p = { id: ++this._drawCallUid }, m = [], v = /* @__PURE__ */ new Map(), y = 0, P = 0, R = 0; R < _; R++) {
|
|
1921
|
+
const A = s[R].texture, L = R === _ - 1;
|
|
1922
|
+
if (!A || v.has(A)) {
|
|
1923
|
+
if (!L)
|
|
1923
1924
|
continue;
|
|
1924
1925
|
} else
|
|
1925
|
-
m.push(A),
|
|
1926
|
-
if (
|
|
1927
|
-
p.textures = m, p.textureLocationMap =
|
|
1926
|
+
m.push(A), v.set(A, y++);
|
|
1927
|
+
if (L || y >= i) {
|
|
1928
|
+
p.textures = m, p.textureLocationMap = v, y = 0, p.first = c;
|
|
1928
1929
|
for (let G = P; G <= R; G++) {
|
|
1929
1930
|
const {
|
|
1930
|
-
indices:
|
|
1931
|
-
vertices:
|
|
1932
|
-
uvs:
|
|
1933
|
-
size:
|
|
1934
|
-
texture:
|
|
1931
|
+
indices: cr,
|
|
1932
|
+
vertices: Bt,
|
|
1933
|
+
uvs: ur = new Float32Array(0),
|
|
1934
|
+
size: dr = new Float32Array(0),
|
|
1935
|
+
texture: fr,
|
|
1935
1936
|
modulate: qe = this._defaultModulate,
|
|
1936
1937
|
backgroundColor: Xe = this._defaultBackgroundColor,
|
|
1937
|
-
blendMode:
|
|
1938
|
+
blendMode: pr = Ze.NORMAL,
|
|
1938
1939
|
disableWrapMode: Us = !1
|
|
1939
|
-
} = s[G], Ds =
|
|
1940
|
-
P < G && p.blendMode !==
|
|
1941
|
-
const Bs = l / this._vertexSize, zs = (
|
|
1942
|
-
for (let
|
|
1943
|
-
if (a[l++] = zs, a[l++] =
|
|
1940
|
+
} = s[G], Ds = dr[0] || 0, Is = dr[1] || 0;
|
|
1941
|
+
P < G && p.blendMode !== pr && (p.count = c - p.first, d.push(p), P = G, p = { id: ++this._drawCallUid }, p.textures = m, p.first = c);
|
|
1942
|
+
const Bs = l / this._vertexSize, zs = (fr ? v.get(fr) : -1) ?? -1, Ns = Us ? 1 : 0;
|
|
1943
|
+
for (let zt = Bt.length, K = 0; K < zt; K += 2) {
|
|
1944
|
+
if (a[l++] = zs, a[l++] = Bt[K], a[l++] = Bt[K + 1], a[l++] = Ds, a[l++] = Is, a[l++] = ur[K], a[l++] = ur[K + 1], qe) {
|
|
1944
1945
|
const re = l * 4;
|
|
1945
1946
|
n[re] = qe[0], n[re + 1] = qe[1], n[re + 2] = qe[2], n[re + 3] = qe[3];
|
|
1946
1947
|
}
|
|
@@ -1950,50 +1951,50 @@ void main(void) {
|
|
|
1950
1951
|
}
|
|
1951
1952
|
l++, a[l++] = Ns;
|
|
1952
1953
|
}
|
|
1953
|
-
for (let
|
|
1954
|
-
h[
|
|
1955
|
-
p.blendMode =
|
|
1954
|
+
for (let zt = cr.length, K = 0; K < zt; K++)
|
|
1955
|
+
h[c++] = Bs + cr[K];
|
|
1956
|
+
p.blendMode = pr;
|
|
1956
1957
|
}
|
|
1957
|
-
P = R + 1, p.count =
|
|
1958
|
+
P = R + 1, p.count = c - p.first, d.push(p), p = { id: ++this._drawCallUid }, m = [], v = /* @__PURE__ */ new Map();
|
|
1958
1959
|
}
|
|
1959
1960
|
}
|
|
1960
1961
|
const f = this._getShader(i);
|
|
1961
1962
|
f.update(o, h);
|
|
1962
1963
|
for (let _ = d.length, p = 0; p < _; p++) {
|
|
1963
|
-
const m = d[p], { first:
|
|
1964
|
-
for (let R =
|
|
1965
|
-
const
|
|
1964
|
+
const m = d[p], { first: v = 0, textures: y, textureLocationMap: P } = m;
|
|
1965
|
+
for (let R = y.length, A = 0; A < R; A++) {
|
|
1966
|
+
const L = y[A], G = P.get(L);
|
|
1966
1967
|
G !== void 0 && this._renderer.texture.bind({
|
|
1967
1968
|
target: "texture_2d",
|
|
1968
1969
|
location: G,
|
|
1969
|
-
value:
|
|
1970
|
+
value: L
|
|
1970
1971
|
});
|
|
1971
1972
|
}
|
|
1972
1973
|
this._state.blendMode = m.blendMode, this._renderer.state.bind(this._state), f.draw({
|
|
1973
1974
|
mode: "triangles",
|
|
1974
1975
|
count: m.count,
|
|
1975
|
-
first:
|
|
1976
|
+
first: v,
|
|
1976
1977
|
bytesPerElement: 2
|
|
1977
1978
|
});
|
|
1978
1979
|
}
|
|
1979
1980
|
}
|
|
1980
1981
|
_getAttributeBuffer(e) {
|
|
1981
|
-
const t =
|
|
1982
|
+
const t = br(Math.ceil(e / 8)), s = yr(t), i = t * 8;
|
|
1982
1983
|
this._attributeBuffer.length <= s && (this._indexBuffers.length = s + 1);
|
|
1983
1984
|
let o = this._attributeBuffer[i];
|
|
1984
1985
|
return o || (this._attributeBuffer[i] = o = new ArrayBuffer(i * this._vertexSize * 4)), o;
|
|
1985
1986
|
}
|
|
1986
1987
|
_getIndexBuffer(e) {
|
|
1987
|
-
const t =
|
|
1988
|
+
const t = br(Math.ceil(e / 12)), s = yr(t), i = t * 12;
|
|
1988
1989
|
this._indexBuffers.length <= s && (this._indexBuffers.length = s + 1);
|
|
1989
1990
|
let o = this._indexBuffers[s];
|
|
1990
1991
|
return o || (this._indexBuffers[s] = o = new Uint16Array(i)), o;
|
|
1991
1992
|
}
|
|
1992
1993
|
}
|
|
1993
|
-
function
|
|
1994
|
+
function br(r) {
|
|
1994
1995
|
return r += r === 0 ? 1 : 0, --r, r |= r >>> 1, r |= r >>> 2, r |= r >>> 4, r |= r >>> 8, r |= r >>> 16, r + 1;
|
|
1995
1996
|
}
|
|
1996
|
-
function
|
|
1997
|
+
function yr(r) {
|
|
1997
1998
|
let e = (r > 65535 ? 1 : 0) << 4;
|
|
1998
1999
|
r >>>= e;
|
|
1999
2000
|
let t = (r > 255 ? 1 : 0) << 3;
|
|
@@ -2041,8 +2042,8 @@ class Vi extends H {
|
|
|
2041
2042
|
const o = i.target ?? this.boundTarget, a = i.usage ?? "static_draw", n = t.data, h = this.gl;
|
|
2042
2043
|
let l;
|
|
2043
2044
|
Array.isArray(n) ? o === "array_buffer" ? l = new Float32Array(n) : l = new Uint32Array(n) : l = n;
|
|
2044
|
-
const
|
|
2045
|
-
l && l.byteLength <= i.byteLength ? h.bufferSubData(
|
|
2045
|
+
const c = this._renderer.getBindPoint(o);
|
|
2046
|
+
l && l.byteLength <= i.byteLength ? h.bufferSubData(c, 0, l) : (h.bufferData(c, l, this._renderer.getBindPoint(a)), i.length = l?.length ?? 0, i.byteLength = l?.byteLength ?? 0, i.bytesPerElement = i.length ? i.byteLength / i.length : 0);
|
|
2046
2047
|
}
|
|
2047
2048
|
bind(e) {
|
|
2048
2049
|
let { target: t, value: s } = e;
|
|
@@ -2351,7 +2352,7 @@ class ji extends H {
|
|
|
2351
2352
|
return this._renderer.getRelated(e, () => ({
|
|
2352
2353
|
attributes: /* @__PURE__ */ new Map(),
|
|
2353
2354
|
uniforms: /* @__PURE__ */ new Map(),
|
|
2354
|
-
boundUniforms: new
|
|
2355
|
+
boundUniforms: new Ir()
|
|
2355
2356
|
}));
|
|
2356
2357
|
}
|
|
2357
2358
|
update(...e) {
|
|
@@ -2368,29 +2369,29 @@ class ji extends H {
|
|
|
2368
2369
|
throw new Error(`Unable to link program: ${i.getProgramInfoLog(s)}`);
|
|
2369
2370
|
o.attributes.clear(), o.uniforms.clear();
|
|
2370
2371
|
for (let h = i.getProgramParameter(s, i.ACTIVE_ATTRIBUTES), l = 0; l < h; l++) {
|
|
2371
|
-
const
|
|
2372
|
-
if (!
|
|
2372
|
+
const c = i.getActiveAttrib(s, l);
|
|
2373
|
+
if (!c || c.name.startsWith("gl_"))
|
|
2373
2374
|
continue;
|
|
2374
|
-
const d = this._renderer.bindPoints.get(
|
|
2375
|
-
o.attributes.set(
|
|
2375
|
+
const d = this._renderer.bindPoints.get(c.type) ?? String(c.type);
|
|
2376
|
+
o.attributes.set(c.name, {
|
|
2376
2377
|
type: d,
|
|
2377
|
-
name:
|
|
2378
|
+
name: c.name,
|
|
2378
2379
|
size: qi(d),
|
|
2379
|
-
location: i.getAttribLocation(s,
|
|
2380
|
+
location: i.getAttribLocation(s, c.name)
|
|
2380
2381
|
});
|
|
2381
2382
|
}
|
|
2382
2383
|
for (let h = i.getProgramParameter(s, i.ACTIVE_UNIFORMS), l = 0; l < h; l++) {
|
|
2383
|
-
const
|
|
2384
|
-
if (!
|
|
2384
|
+
const c = i.getActiveUniform(s, l);
|
|
2385
|
+
if (!c)
|
|
2385
2386
|
continue;
|
|
2386
|
-
const d =
|
|
2387
|
+
const d = c.name.replace(/\[.*?\]$/, "");
|
|
2387
2388
|
let f = i.getUniformLocation(s, d);
|
|
2388
|
-
f || (f = i.getUniformLocation(s,
|
|
2389
|
+
f || (f = i.getUniformLocation(s, c.name)), o.uniforms.set(d, {
|
|
2389
2390
|
name: d,
|
|
2390
2391
|
index: l,
|
|
2391
|
-
type: this._renderer.bindPoints.get(
|
|
2392
|
-
size:
|
|
2393
|
-
isArray: d !==
|
|
2392
|
+
type: this._renderer.bindPoints.get(c.type) ?? String(c.type),
|
|
2393
|
+
size: c.size,
|
|
2394
|
+
isArray: d !== c.name,
|
|
2394
2395
|
location: f
|
|
2395
2396
|
});
|
|
2396
2397
|
}
|
|
@@ -2427,9 +2428,9 @@ ${s.getShaderInfoLog(i)}`);
|
|
|
2427
2428
|
const h = i[n], l = o.get(n);
|
|
2428
2429
|
if (!l)
|
|
2429
2430
|
continue;
|
|
2430
|
-
const { type:
|
|
2431
|
+
const { type: c, isArray: d, location: f } = l;
|
|
2431
2432
|
if (!(!f || a.get(f) === h))
|
|
2432
|
-
switch (a.set(f, h),
|
|
2433
|
+
switch (a.set(f, h), c) {
|
|
2433
2434
|
case "float":
|
|
2434
2435
|
d ? s.uniform1fv(f, h) : s.uniform1f(f, h);
|
|
2435
2436
|
break;
|
|
@@ -2528,16 +2529,16 @@ function qi(r) {
|
|
|
2528
2529
|
}
|
|
2529
2530
|
}
|
|
2530
2531
|
function gt(r, e, t) {
|
|
2531
|
-
const [s, i, o, a, n, h, l,
|
|
2532
|
+
const [s, i, o, a, n, h, l, c, d] = r, f = s * e + a * t + l, _ = i * e + n * t + c, p = o * e + h * t + d;
|
|
2532
2533
|
return { x: f / p, y: _ / p };
|
|
2533
2534
|
}
|
|
2534
2535
|
function Xi(r, e) {
|
|
2535
|
-
const { x: t, y: s, width: i, height: o } = e, a = gt(r, t, s), n = gt(r, t + i, s), h = gt(r, t + i, s + o), l = gt(r, t, s + o),
|
|
2536
|
+
const { x: t, y: s, width: i, height: o } = e, a = gt(r, t, s), n = gt(r, t + i, s), h = gt(r, t + i, s + o), l = gt(r, t, s + o), c = [a, n, h, l], d = c.map((y) => y.x), f = c.map((y) => y.y), _ = Math.min(...d), p = Math.max(...d), m = Math.min(...f), v = Math.max(...f);
|
|
2536
2537
|
return {
|
|
2537
2538
|
x: _,
|
|
2538
2539
|
y: m,
|
|
2539
2540
|
width: p - _,
|
|
2540
|
-
height:
|
|
2541
|
+
height: v - m
|
|
2541
2542
|
};
|
|
2542
2543
|
}
|
|
2543
2544
|
class Hi extends H {
|
|
@@ -2560,10 +2561,10 @@ class Hi extends H {
|
|
|
2560
2561
|
}
|
|
2561
2562
|
}
|
|
2562
2563
|
use() {
|
|
2563
|
-
const e = this._renderer, { pixelRatio: t, mask: s, viewport: i, screen: o, gl: a, program: n } = e, { viewMatrix: h } = n.uniforms, l = Xi(h, s.last.mask), { x:
|
|
2564
|
+
const e = this._renderer, { pixelRatio: t, mask: s, viewport: i, screen: o, gl: a, program: n } = e, { viewMatrix: h } = n.uniforms, l = Xi(h, s.last.mask), { x: c, y: d, width: f, height: _ } = l;
|
|
2564
2565
|
let p;
|
|
2565
2566
|
i.boundViewport ? p = i.boundViewport.height - (_ + d) * t : p = (o.height - (_ + d)) * t, a.scissor(
|
|
2566
|
-
|
|
2567
|
+
c * t,
|
|
2567
2568
|
p,
|
|
2568
2569
|
f * t,
|
|
2569
2570
|
_ * t
|
|
@@ -2683,12 +2684,12 @@ class Zi extends H {
|
|
|
2683
2684
|
const d = this._renderer.getBindPoint(n.wrapMode);
|
|
2684
2685
|
a.texParameteri(l, a.TEXTURE_WRAP_S, d), a.texParameteri(l, a.TEXTURE_WRAP_T, d);
|
|
2685
2686
|
}
|
|
2686
|
-
const
|
|
2687
|
-
if (h.filterMode &&
|
|
2688
|
-
const d = this._renderer.getBindPoint(
|
|
2689
|
-
|
|
2687
|
+
const c = n.filterMode;
|
|
2688
|
+
if (h.filterMode && c) {
|
|
2689
|
+
const d = this._renderer.getBindPoint(c.split("_")[0]);
|
|
2690
|
+
c.includes("_") ? a.texParameteri(l, a.TEXTURE_MIN_FILTER, this._renderer.getBindPoint(c)) : a.texParameteri(l, a.TEXTURE_MIN_FILTER, d), a.texParameteri(l, a.TEXTURE_MAG_FILTER, d);
|
|
2690
2691
|
}
|
|
2691
|
-
if (n.anisoLevel &&
|
|
2692
|
+
if (n.anisoLevel && c === "linear" && this._renderer.extensions.anisotropicFiltering && h.anisoLevel) {
|
|
2692
2693
|
const {
|
|
2693
2694
|
MAX_TEXTURE_MAX_ANISOTROPY_EXT: d,
|
|
2694
2695
|
TEXTURE_MAX_ANISOTROPY_EXT: f
|
|
@@ -2713,9 +2714,9 @@ class Zi extends H {
|
|
|
2713
2714
|
i ??= "texture_2d", o ??= 0;
|
|
2714
2715
|
let n = this.boundTextures[o];
|
|
2715
2716
|
n || (this.boundTextures[o] = n = { texture_2d: null, texture_cube_map: null });
|
|
2716
|
-
const h = n[i] ?? null, l = this.boundLocation,
|
|
2717
|
-
location: o !== l && (
|
|
2718
|
-
texture:
|
|
2717
|
+
const h = n[i] ?? null, l = this.boundLocation, c = s !== h, d = {
|
|
2718
|
+
location: o !== l && (c || a),
|
|
2719
|
+
texture: c
|
|
2719
2720
|
}, f = this._renderer.getBindPoint(i);
|
|
2720
2721
|
d.location && (t.activeTexture(t.TEXTURE0 + o), this.boundLocation = o), d.texture && (t.bindTexture(f, s ?? this.emptyTextures[i]), n[i] = s), this.boundTarget = i;
|
|
2721
2722
|
}
|
|
@@ -2750,7 +2751,7 @@ class Ji extends H {
|
|
|
2750
2751
|
type: n = "float",
|
|
2751
2752
|
normalized: h = !1,
|
|
2752
2753
|
stride: l = 0,
|
|
2753
|
-
offset:
|
|
2754
|
+
offset: c = 0,
|
|
2754
2755
|
divisor: d
|
|
2755
2756
|
} = s, f = this._renderer.gl;
|
|
2756
2757
|
this._renderer.buffer.bind({ target: "array_buffer", value: o });
|
|
@@ -2761,7 +2762,7 @@ class Ji extends H {
|
|
|
2761
2762
|
this._renderer.getBindPoint(n),
|
|
2762
2763
|
h,
|
|
2763
2764
|
l,
|
|
2764
|
-
|
|
2765
|
+
c + (l - c) / i * _
|
|
2765
2766
|
);
|
|
2766
2767
|
d && ("vertexAttribDivisor" in f ? f.vertexAttribDivisor(t, d) : console.warn("Failed to active vertex array object, GPU Instancing is not supported on this device")), this.boundVertexArray.attributes[e] = {
|
|
2767
2768
|
enable: !0,
|
|
@@ -2801,9 +2802,9 @@ class Ji extends H {
|
|
|
2801
2802
|
if (s.attributes) {
|
|
2802
2803
|
const o = this._renderer.program.getMeta(t), a = {}, n = {};
|
|
2803
2804
|
for (const l in s.attributes) {
|
|
2804
|
-
const
|
|
2805
|
+
const c = s.attributes[l], d = o.attributes.get(l);
|
|
2805
2806
|
let f;
|
|
2806
|
-
"buffer" in
|
|
2807
|
+
"buffer" in c ? f = { ...c } : f = { buffer: c }, f.size = f.size || d?.size || 0;
|
|
2807
2808
|
const _ = this._renderer.buffer.getMeta(f.buffer), p = Number(d?.type.match(/mat(\d)/)?.[1] ?? 1);
|
|
2808
2809
|
let m;
|
|
2809
2810
|
switch (f.type) {
|
|
@@ -2822,8 +2823,8 @@ class Ji extends H {
|
|
|
2822
2823
|
}
|
|
2823
2824
|
const h = {};
|
|
2824
2825
|
for (const l in n) {
|
|
2825
|
-
const { attrib:
|
|
2826
|
-
f?.location !== void 0 && (h[d.id] ??= 0,
|
|
2826
|
+
const { attrib: c, meta: d, info: f, byteLength: _, dimension: p } = n[l];
|
|
2827
|
+
f?.location !== void 0 && (h[d.id] ??= 0, c.offset ??= h[d.id], c.stride ??= a[d.id] === _ ? 0 : a[d.id], this.enableVertexAttrib(l, f.location, c, p), h[d.id] += _);
|
|
2827
2828
|
}
|
|
2828
2829
|
}
|
|
2829
2830
|
const i = s.elementArrayBuffer ?? null;
|
|
@@ -2866,7 +2867,7 @@ class Qi extends H {
|
|
|
2866
2867
|
super.reset(), this.boundViewport = { x: 0, y: 0, width: 0, height: 0 };
|
|
2867
2868
|
}
|
|
2868
2869
|
}
|
|
2869
|
-
class eo extends
|
|
2870
|
+
class eo extends Kt {
|
|
2870
2871
|
_modules = [
|
|
2871
2872
|
new Zi(),
|
|
2872
2873
|
new Vi(),
|
|
@@ -2989,34 +2990,34 @@ class eo extends Zt {
|
|
|
2989
2990
|
toPixels(e = 0, t = 0, s = this.gl.drawingBufferWidth, i = this.gl.drawingBufferHeight) {
|
|
2990
2991
|
const o = s * i * 4, a = s * 4, n = (i - 1) * a, h = new Uint8Array(o), l = new Uint8ClampedArray(o);
|
|
2991
2992
|
this.gl.readPixels(e, t, s, i, this.gl.RGBA, this.gl.UNSIGNED_BYTE, h);
|
|
2992
|
-
for (let
|
|
2993
|
-
l.set(h.subarray(
|
|
2993
|
+
for (let c = 0; c < o; c += a)
|
|
2994
|
+
l.set(h.subarray(c, c + a), n - c);
|
|
2994
2995
|
return l;
|
|
2995
2996
|
}
|
|
2996
2997
|
}
|
|
2997
|
-
class
|
|
2998
|
+
class Ce {
|
|
2998
2999
|
}
|
|
2999
|
-
class to extends
|
|
3000
|
+
class to extends Ce {
|
|
3000
3001
|
install(e) {
|
|
3001
3002
|
const t = async (s) => {
|
|
3002
3003
|
const { parseFont: i } = await import("modern-font");
|
|
3003
|
-
return await
|
|
3004
|
+
return await s.arrayBuffer().then((o) => i(o));
|
|
3004
3005
|
};
|
|
3005
|
-
return this.load = (s) => e.loadBy(s
|
|
3006
|
-
"woff",
|
|
3007
|
-
"ttf",
|
|
3008
|
-
"otf"
|
|
3006
|
+
return this.load = (s) => typeof s == "string" ? e.loadBy(s).then(t) : t(s), [
|
|
3007
|
+
"font/woff",
|
|
3008
|
+
"font/ttf",
|
|
3009
|
+
"font/otf"
|
|
3009
3010
|
].forEach((s) => {
|
|
3010
3011
|
e.register(s, t);
|
|
3011
3012
|
}), e.font = this, this;
|
|
3012
3013
|
}
|
|
3013
3014
|
}
|
|
3014
|
-
class
|
|
3015
|
+
class Zt extends _e {
|
|
3015
3016
|
vertexAttributes;
|
|
3016
3017
|
indexBuffer;
|
|
3017
3018
|
instanceCount;
|
|
3018
3019
|
mode;
|
|
3019
|
-
_materialWeakMap = new
|
|
3020
|
+
_materialWeakMap = new qr();
|
|
3020
3021
|
constructor(e = {}) {
|
|
3021
3022
|
super(), this.vertexAttributes = new Map(Object.entries(e?.vertexAttributes ?? {})), this.indexBuffer = e?.indexBuffer, this.instanceCount = e?.instanceCount, this.mode = e?.mode ?? "triangles";
|
|
3022
3023
|
}
|
|
@@ -3064,7 +3065,7 @@ class Jt extends _e {
|
|
|
3064
3065
|
}), e.vertexArray.unbind();
|
|
3065
3066
|
}
|
|
3066
3067
|
}
|
|
3067
|
-
var ro = Object.defineProperty,
|
|
3068
|
+
var ro = Object.defineProperty, Jr = (r, e, t, s) => {
|
|
3068
3069
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
3069
3070
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3070
3071
|
return i && ro(e, t, i), i;
|
|
@@ -3102,13 +3103,13 @@ class nt extends _e {
|
|
|
3102
3103
|
)), t;
|
|
3103
3104
|
}
|
|
3104
3105
|
}
|
|
3105
|
-
|
|
3106
|
-
|
|
3106
|
+
Jr([
|
|
3107
|
+
u({ internal: !0, fallback: null })
|
|
3107
3108
|
], nt.prototype, "data");
|
|
3108
|
-
|
|
3109
|
-
|
|
3109
|
+
Jr([
|
|
3110
|
+
u({ internal: !0, fallback: !1 })
|
|
3110
3111
|
], nt.prototype, "dynamic");
|
|
3111
|
-
var so = Object.defineProperty,
|
|
3112
|
+
var so = Object.defineProperty, Qr = (r, e, t, s) => {
|
|
3112
3113
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
3113
3114
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3114
3115
|
return i && so(e, t, i), i;
|
|
@@ -3146,18 +3147,18 @@ class ue extends _e {
|
|
|
3146
3147
|
)), t;
|
|
3147
3148
|
}
|
|
3148
3149
|
}
|
|
3149
|
-
|
|
3150
|
-
|
|
3150
|
+
Qr([
|
|
3151
|
+
u({ internal: !0, default: null })
|
|
3151
3152
|
], ue.prototype, "data");
|
|
3152
|
-
|
|
3153
|
-
|
|
3153
|
+
Qr([
|
|
3154
|
+
u({ internal: !0, fallback: !1 })
|
|
3154
3155
|
], ue.prototype, "dynamic");
|
|
3155
|
-
var io = Object.defineProperty,
|
|
3156
|
+
var io = Object.defineProperty, Ae = (r, e, t, s) => {
|
|
3156
3157
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
3157
3158
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3158
3159
|
return i && io(e, t, i), i;
|
|
3159
3160
|
};
|
|
3160
|
-
class
|
|
3161
|
+
class $ extends _e {
|
|
3161
3162
|
needsUpload = !1;
|
|
3162
3163
|
constructor(e) {
|
|
3163
3164
|
super(), this.setProperties({
|
|
@@ -3183,32 +3184,32 @@ class F extends _e {
|
|
|
3183
3184
|
return e && (this.needsUpload = !1), e;
|
|
3184
3185
|
}
|
|
3185
3186
|
}
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
],
|
|
3189
|
-
|
|
3190
|
-
|
|
3191
|
-
],
|
|
3192
|
-
|
|
3193
|
-
|
|
3194
|
-
],
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
],
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
],
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
],
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
],
|
|
3207
|
-
class Sl extends
|
|
3187
|
+
Ae([
|
|
3188
|
+
u({ internal: !0 })
|
|
3189
|
+
], $.prototype, "buffer");
|
|
3190
|
+
Ae([
|
|
3191
|
+
u({ fallback: 0 })
|
|
3192
|
+
], $.prototype, "size");
|
|
3193
|
+
Ae([
|
|
3194
|
+
u({ fallback: !1 })
|
|
3195
|
+
], $.prototype, "normalized");
|
|
3196
|
+
Ae([
|
|
3197
|
+
u({ fallback: "float" })
|
|
3198
|
+
], $.prototype, "type");
|
|
3199
|
+
Ae([
|
|
3200
|
+
u()
|
|
3201
|
+
], $.prototype, "stride");
|
|
3202
|
+
Ae([
|
|
3203
|
+
u()
|
|
3204
|
+
], $.prototype, "offset");
|
|
3205
|
+
Ae([
|
|
3206
|
+
u()
|
|
3207
|
+
], $.prototype, "divisor");
|
|
3208
|
+
class Sl extends Zt {
|
|
3208
3209
|
constructor() {
|
|
3209
3210
|
super({
|
|
3210
3211
|
vertexAttributes: {
|
|
3211
|
-
position: new
|
|
3212
|
+
position: new $({
|
|
3212
3213
|
buffer: new ue({
|
|
3213
3214
|
data: new Float32Array([0, 0, 1, 0, 1, 1, 0, 1]),
|
|
3214
3215
|
dynamic: !1
|
|
@@ -3226,14 +3227,13 @@ class Sl extends Jt {
|
|
|
3226
3227
|
});
|
|
3227
3228
|
}
|
|
3228
3229
|
}
|
|
3229
|
-
class
|
|
3230
|
+
class w extends _e {
|
|
3230
3231
|
static instance = new this();
|
|
3231
3232
|
vert;
|
|
3232
3233
|
frag;
|
|
3233
3234
|
uniforms;
|
|
3234
3235
|
constructor(e = {}) {
|
|
3235
|
-
super(), this.vert = e.vert ?? `
|
|
3236
|
-
attribute vec2 position;
|
|
3236
|
+
super(), this.vert = e.vert ?? `attribute vec2 position;
|
|
3237
3237
|
uniform mat3 projectionMatrix;
|
|
3238
3238
|
uniform mat3 modelViewMatrix;
|
|
3239
3239
|
void main(void) {
|
|
@@ -3275,7 +3275,7 @@ function no(r) {
|
|
|
3275
3275
|
}
|
|
3276
3276
|
return Number(r);
|
|
3277
3277
|
}
|
|
3278
|
-
class yt extends
|
|
3278
|
+
class yt extends w {
|
|
3279
3279
|
vert = `attribute vec2 position;
|
|
3280
3280
|
attribute vec2 uv;
|
|
3281
3281
|
varying vec2 vUv;
|
|
@@ -3329,15 +3329,14 @@ void main(void) { gl_FragColor = transition(vUv); }` : ""}`;
|
|
|
3329
3329
|
});
|
|
3330
3330
|
}
|
|
3331
3331
|
}
|
|
3332
|
-
class xt extends
|
|
3332
|
+
class xt extends w {
|
|
3333
3333
|
static _instance;
|
|
3334
3334
|
static get instance() {
|
|
3335
3335
|
return this._instance ??= new this();
|
|
3336
3336
|
}
|
|
3337
3337
|
constructor() {
|
|
3338
3338
|
super({
|
|
3339
|
-
vert: `
|
|
3340
|
-
attribute vec2 position;
|
|
3339
|
+
vert: `attribute vec2 position;
|
|
3341
3340
|
attribute vec2 uv;
|
|
3342
3341
|
uniform mat3 projectionMatrix;
|
|
3343
3342
|
uniform mat3 modelViewMatrix;
|
|
@@ -3361,7 +3360,7 @@ void main(void) {
|
|
|
3361
3360
|
});
|
|
3362
3361
|
}
|
|
3363
3362
|
}
|
|
3364
|
-
class b extends
|
|
3363
|
+
class b extends Zt {
|
|
3365
3364
|
static _instance;
|
|
3366
3365
|
static get instance() {
|
|
3367
3366
|
return this._instance ??= new this();
|
|
@@ -3372,7 +3371,7 @@ class b extends Jt {
|
|
|
3372
3371
|
constructor() {
|
|
3373
3372
|
super({
|
|
3374
3373
|
vertexAttributes: {
|
|
3375
|
-
position: new
|
|
3374
|
+
position: new $({
|
|
3376
3375
|
buffer: new ue({
|
|
3377
3376
|
data: new Float32Array([-1, -1, 1, -1, 1, 1, -1, 1]),
|
|
3378
3377
|
dynamic: !1
|
|
@@ -3381,7 +3380,7 @@ class b extends Jt {
|
|
|
3381
3380
|
normalized: !1,
|
|
3382
3381
|
type: "float"
|
|
3383
3382
|
}),
|
|
3384
|
-
uv: new
|
|
3383
|
+
uv: new $({
|
|
3385
3384
|
buffer: new ue({
|
|
3386
3385
|
data: new Float32Array([0, 0, 1, 0, 1, 1, 0, 1]),
|
|
3387
3386
|
dynamic: !1
|
|
@@ -3398,20 +3397,20 @@ class b extends Jt {
|
|
|
3398
3397
|
});
|
|
3399
3398
|
}
|
|
3400
3399
|
}
|
|
3401
|
-
class Cl extends
|
|
3400
|
+
class Cl extends Zt {
|
|
3402
3401
|
positionBuffer;
|
|
3403
3402
|
uvBuffer;
|
|
3404
3403
|
constructor() {
|
|
3405
3404
|
const e = new ue({ data: new Float32Array(), dynamic: !0 }), t = new ue({ data: new Float32Array(), dynamic: !0 });
|
|
3406
3405
|
super({
|
|
3407
3406
|
vertexAttributes: {
|
|
3408
|
-
position: new
|
|
3407
|
+
position: new $({
|
|
3409
3408
|
buffer: e,
|
|
3410
3409
|
size: 2,
|
|
3411
3410
|
normalized: !1,
|
|
3412
3411
|
type: "float"
|
|
3413
3412
|
}),
|
|
3414
|
-
uv: new
|
|
3413
|
+
uv: new $({
|
|
3415
3414
|
buffer: t,
|
|
3416
3415
|
size: 2,
|
|
3417
3416
|
normalized: !1,
|
|
@@ -3425,7 +3424,7 @@ class Cl extends Jt {
|
|
|
3425
3424
|
}), this.positionBuffer = e, this.uvBuffer = t;
|
|
3426
3425
|
}
|
|
3427
3426
|
}
|
|
3428
|
-
var lo = Object.defineProperty,
|
|
3427
|
+
var lo = Object.defineProperty, Ne = (r, e, t, s) => {
|
|
3429
3428
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
3430
3429
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3431
3430
|
return i && lo(e, t, i), i;
|
|
@@ -3498,7 +3497,7 @@ class T extends _e {
|
|
|
3498
3497
|
}
|
|
3499
3498
|
}
|
|
3500
3499
|
_updatePOT() {
|
|
3501
|
-
this._isPowerOfTwo =
|
|
3500
|
+
this._isPowerOfTwo = gr(this.realWidth) && gr(this.realHeight), this.requestUpload();
|
|
3502
3501
|
}
|
|
3503
3502
|
updateSize() {
|
|
3504
3503
|
const e = this.source;
|
|
@@ -3527,25 +3526,25 @@ class T extends _e {
|
|
|
3527
3526
|
fi && this.source instanceof ImageBitmap && this.source.close();
|
|
3528
3527
|
}
|
|
3529
3528
|
}
|
|
3530
|
-
|
|
3531
|
-
|
|
3529
|
+
Ne([
|
|
3530
|
+
u({ internal: !0 })
|
|
3532
3531
|
], T.prototype, "source");
|
|
3533
|
-
|
|
3534
|
-
|
|
3532
|
+
Ne([
|
|
3533
|
+
u({ fallback: 0 })
|
|
3535
3534
|
], T.prototype, "width");
|
|
3536
|
-
|
|
3537
|
-
|
|
3535
|
+
Ne([
|
|
3536
|
+
u({ fallback: 0 })
|
|
3538
3537
|
], T.prototype, "height");
|
|
3539
|
-
|
|
3540
|
-
|
|
3538
|
+
Ne([
|
|
3539
|
+
u({ fallback: "linear" })
|
|
3541
3540
|
], T.prototype, "filterMode");
|
|
3542
|
-
|
|
3543
|
-
|
|
3541
|
+
Ne([
|
|
3542
|
+
u({ fallback: "clamp_to_edge" })
|
|
3544
3543
|
], T.prototype, "wrapMode");
|
|
3545
|
-
|
|
3546
|
-
|
|
3544
|
+
Ne([
|
|
3545
|
+
u({ fallback: 1 })
|
|
3547
3546
|
], T.prototype, "pixelRatio");
|
|
3548
|
-
class
|
|
3547
|
+
class $t extends _e {
|
|
3549
3548
|
frames;
|
|
3550
3549
|
frameIndex = 0;
|
|
3551
3550
|
get currentFrame() {
|
|
@@ -3576,7 +3575,7 @@ var ho = Object.defineProperty, co = (r, e, t, s) => {
|
|
|
3576
3575
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3577
3576
|
return i && ho(e, t, i), i;
|
|
3578
3577
|
};
|
|
3579
|
-
class
|
|
3578
|
+
class Jt extends T {
|
|
3580
3579
|
constructor(e = document.createElement("canvas")) {
|
|
3581
3580
|
super(e);
|
|
3582
3581
|
}
|
|
@@ -3593,8 +3592,8 @@ class Qt extends T {
|
|
|
3593
3592
|
}
|
|
3594
3593
|
}
|
|
3595
3594
|
co([
|
|
3596
|
-
|
|
3597
|
-
],
|
|
3595
|
+
u({ fallback: 2 })
|
|
3596
|
+
], Jt.prototype, "pixelRatio");
|
|
3598
3597
|
class Al extends T {
|
|
3599
3598
|
static _cached = /* @__PURE__ */ new Map();
|
|
3600
3599
|
static get(e) {
|
|
@@ -3615,7 +3614,7 @@ class Al extends T {
|
|
|
3615
3614
|
});
|
|
3616
3615
|
}
|
|
3617
3616
|
}
|
|
3618
|
-
class
|
|
3617
|
+
class kt extends T {
|
|
3619
3618
|
static test(e) {
|
|
3620
3619
|
return Fs(e);
|
|
3621
3620
|
}
|
|
@@ -3626,26 +3625,26 @@ class Mt extends T {
|
|
|
3626
3625
|
const o = i.getContext("2d");
|
|
3627
3626
|
if (!o)
|
|
3628
3627
|
throw new Error("Failed to parse linear gradient, get canvas context is null.");
|
|
3629
|
-
const { angle: a = 0, stops: n } = e, h = t, l = s,
|
|
3628
|
+
const { angle: a = 0, stops: n } = e, h = t, l = s, c = h / 2, d = l / 2, f = (a + 90) * Math.PI / 180, _ = Math.sin(f), p = -Math.cos(f), m = Math.abs(h * Math.sin(f)) + Math.abs(l * Math.cos(f)), v = c - _ * (m / 2), y = d - p * (m / 2), P = c + _ * (m / 2), R = d + p * (m / 2), A = o.createLinearGradient(v, y, P, R);
|
|
3630
3629
|
for (const G of n) A.addColorStop(G.offset, G.color);
|
|
3631
3630
|
o.fillStyle = A, o.fillRect(0, 0, h, l);
|
|
3632
|
-
const
|
|
3631
|
+
const L = o.getImageData(0, 0, i.width, i.height);
|
|
3633
3632
|
return {
|
|
3634
|
-
width:
|
|
3635
|
-
height:
|
|
3636
|
-
pixels: new Uint8Array(
|
|
3633
|
+
width: L.width,
|
|
3634
|
+
height: L.height,
|
|
3635
|
+
pixels: new Uint8Array(L.data.buffer)
|
|
3637
3636
|
};
|
|
3638
3637
|
}
|
|
3639
3638
|
constructor(e, t, s) {
|
|
3640
3639
|
super(
|
|
3641
|
-
|
|
3640
|
+
kt.linearGradient(e, t, s)
|
|
3642
3641
|
);
|
|
3643
3642
|
}
|
|
3644
3643
|
}
|
|
3645
3644
|
function uo(r) {
|
|
3646
3645
|
return {
|
|
3647
3646
|
autoLoad: !!(r?.autoLoad ?? !0),
|
|
3648
|
-
useBitmap: !!(r?.useBitmap ?? !0) &&
|
|
3647
|
+
useBitmap: !!(r?.useBitmap ?? !0) && Fr,
|
|
3649
3648
|
crossorigin: r?.crossorigin ?? null
|
|
3650
3649
|
};
|
|
3651
3650
|
}
|
|
@@ -3677,7 +3676,7 @@ class Rl extends T {
|
|
|
3677
3676
|
genBitmap() {
|
|
3678
3677
|
if (this._loadBitmap)
|
|
3679
3678
|
return this._loadBitmap;
|
|
3680
|
-
if (this.bitmap ||
|
|
3679
|
+
if (this.bitmap || !Fr)
|
|
3681
3680
|
return Promise.resolve(this);
|
|
3682
3681
|
const e = this.source, t = !e.crossOrigin || e.crossOrigin === "anonymous";
|
|
3683
3682
|
return this._loadBitmap = fetch(e.src, {
|
|
@@ -3707,7 +3706,7 @@ class Rl extends T {
|
|
|
3707
3706
|
return this.preserveBitmap && this.bitmap && (this.bitmap.close(), this.bitmap = void 0), t;
|
|
3708
3707
|
}
|
|
3709
3708
|
}
|
|
3710
|
-
class
|
|
3709
|
+
class es extends T {
|
|
3711
3710
|
constructor(e, t = 1, s = 1) {
|
|
3712
3711
|
const i = {
|
|
3713
3712
|
width: t,
|
|
@@ -3731,7 +3730,7 @@ class ts extends T {
|
|
|
3731
3730
|
super._updateProperty(e, t, s);
|
|
3732
3731
|
}
|
|
3733
3732
|
}
|
|
3734
|
-
var fo = Object.defineProperty,
|
|
3733
|
+
var fo = Object.defineProperty, ts = (r, e, t, s) => {
|
|
3735
3734
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
3736
3735
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
3737
3736
|
return i && fo(e, t, i), i;
|
|
@@ -3747,7 +3746,7 @@ function po(r) {
|
|
|
3747
3746
|
playsinline: !!(r?.playsinline ?? !0)
|
|
3748
3747
|
};
|
|
3749
3748
|
}
|
|
3750
|
-
const
|
|
3749
|
+
const Qt = class rs extends T {
|
|
3751
3750
|
static mimeTypes = new Map(Object.entries({
|
|
3752
3751
|
ogv: "video/ogg",
|
|
3753
3752
|
mov: "video/quicktime",
|
|
@@ -3790,8 +3789,8 @@ const er = class ss extends T {
|
|
|
3790
3789
|
if (n = n || e[a], n.startsWith("data:"))
|
|
3791
3790
|
h = n.slice(5, n.indexOf(";"));
|
|
3792
3791
|
else if (!n.startsWith("blob:")) {
|
|
3793
|
-
const
|
|
3794
|
-
h = h ||
|
|
3792
|
+
const c = n.split("?").shift().toLowerCase(), d = c.slice(c.lastIndexOf(".") + 1);
|
|
3793
|
+
h = h || rs.mimeTypes.get(d) || `video/${d}`;
|
|
3795
3794
|
}
|
|
3796
3795
|
const l = document.createElement("source");
|
|
3797
3796
|
l.src = n, h && (l.type = h), o.appendChild(l);
|
|
@@ -3830,15 +3829,15 @@ const er = class ss extends T {
|
|
|
3830
3829
|
this.autoUpdate && !this.isPlaying && (this._nextTime = 0, this.requestUpload(), this._nextTime = 0);
|
|
3831
3830
|
};
|
|
3832
3831
|
_setupAutoUpdate() {
|
|
3833
|
-
this.autoUpdate && this.isPlaying ? !this.fps && this.source.requestVideoFrameCallback ? (this._connected && (
|
|
3832
|
+
this.autoUpdate && this.isPlaying ? !this.fps && this.source.requestVideoFrameCallback ? (this._connected && (U.off(this.requestUpload), this._connected = !1, this._nextTime = 0), this._requestId === void 0 && (this._requestId = this.source.requestVideoFrameCallback(
|
|
3834
3833
|
this._videoFrameRequestCallback
|
|
3835
|
-
))) : (this._requestId !== void 0 && (this.source.cancelVideoFrameCallback(this._requestId), this._requestId = void 0), this._connected || (
|
|
3834
|
+
))) : (this._requestId !== void 0 && (this.source.cancelVideoFrameCallback(this._requestId), this._requestId = void 0), this._connected || (U.on(this.requestUpload), this._connected = !0, this._nextTime = 0)) : (this._requestId !== void 0 && (this.source.cancelVideoFrameCallback(this._requestId), this._requestId = void 0), this._connected && (U.off(this.requestUpload), this._connected = !1, this._nextTime = 0));
|
|
3836
3835
|
}
|
|
3837
3836
|
_videoFrameRequestCallback = () => {
|
|
3838
3837
|
this.requestUpload(), this._requestId = this.source.requestVideoFrameCallback(this._videoFrameRequestCallback);
|
|
3839
3838
|
};
|
|
3840
3839
|
requestUpload = () => {
|
|
3841
|
-
const e = Math.floor(
|
|
3840
|
+
const e = Math.floor(U.elapsed * this.source.playbackRate);
|
|
3842
3841
|
this._nextTime -= e, (!this._spf || this._nextTime <= 0) && (super.requestUpload(), this._nextTime = this._spf || 0);
|
|
3843
3842
|
};
|
|
3844
3843
|
async load() {
|
|
@@ -3856,14 +3855,14 @@ const er = class ss extends T {
|
|
|
3856
3855
|
e && (e.removeEventListener("play", this._onPlayStart), e.removeEventListener("pause", this._onPlayStop), e.removeEventListener("seeked", this._onSeeked), e.removeEventListener("canplay", this._onCanPlay), e.removeEventListener("canplaythrough", this._onCanPlay), e.removeEventListener("error", this._onError, !0), e.pause(), e.src = "", e.load());
|
|
3857
3856
|
}
|
|
3858
3857
|
};
|
|
3859
|
-
|
|
3860
|
-
|
|
3861
|
-
],
|
|
3862
|
-
|
|
3863
|
-
|
|
3864
|
-
],
|
|
3865
|
-
let _o =
|
|
3866
|
-
class
|
|
3858
|
+
ts([
|
|
3859
|
+
u({ internal: !0, fallback: !0 })
|
|
3860
|
+
], Qt.prototype, "autoUpdate");
|
|
3861
|
+
ts([
|
|
3862
|
+
u({ internal: !0, fallback: 0 })
|
|
3863
|
+
], Qt.prototype, "fps");
|
|
3864
|
+
let _o = Qt;
|
|
3865
|
+
class xr extends es {
|
|
3867
3866
|
//
|
|
3868
3867
|
}
|
|
3869
3868
|
class mo extends bt {
|
|
@@ -3895,7 +3894,7 @@ class mo extends bt {
|
|
|
3895
3894
|
t = this.style.stroke;
|
|
3896
3895
|
break;
|
|
3897
3896
|
case "object":
|
|
3898
|
-
|
|
3897
|
+
_r(this.style.stroke) && (t = this.style.stroke.color);
|
|
3899
3898
|
break;
|
|
3900
3899
|
}
|
|
3901
3900
|
this._draws.push({
|
|
@@ -3930,7 +3929,7 @@ class mo extends bt {
|
|
|
3930
3929
|
t = this.style.fill;
|
|
3931
3930
|
break;
|
|
3932
3931
|
case "object":
|
|
3933
|
-
|
|
3932
|
+
_r(this.style.fill) && (t = this.style.fill.color);
|
|
3934
3933
|
break;
|
|
3935
3934
|
}
|
|
3936
3935
|
this._draws.push({
|
|
@@ -3955,9 +3954,9 @@ class mo extends bt {
|
|
|
3955
3954
|
if (i) {
|
|
3956
3955
|
const a = i.width, n = i.height;
|
|
3957
3956
|
for (let h = t.length, l = e; l < h; l += 2) {
|
|
3958
|
-
const
|
|
3957
|
+
const c = t[l], d = t[l + 1];
|
|
3959
3958
|
let f, _;
|
|
3960
|
-
o ? [f, _] = o.apply({ x:
|
|
3959
|
+
o ? [f, _] = o.apply({ x: c, y: d }).toArray() : [f, _] = [c / a, d / n], s.push(f, _);
|
|
3961
3960
|
}
|
|
3962
3961
|
} else
|
|
3963
3962
|
for (let a = t.length, n = e; n < a; n += 2)
|
|
@@ -4065,12 +4064,12 @@ var bo = Object.defineProperty, yo = Object.getOwnPropertyDescriptor, ne = (r, e
|
|
|
4065
4064
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4066
4065
|
return s && i && bo(e, t, i), i;
|
|
4067
4066
|
};
|
|
4068
|
-
const
|
|
4067
|
+
const wr = {};
|
|
4069
4068
|
function xo(r) {
|
|
4070
|
-
let e =
|
|
4071
|
-
return e++,
|
|
4069
|
+
let e = wr[r] ?? 0;
|
|
4070
|
+
return e++, wr[r] = e, e;
|
|
4072
4071
|
}
|
|
4073
|
-
let
|
|
4072
|
+
let M = class extends pe {
|
|
4074
4073
|
_meta = new vo(this);
|
|
4075
4074
|
get meta() {
|
|
4076
4075
|
return this._meta;
|
|
@@ -4266,7 +4265,7 @@ let k = class extends pe {
|
|
|
4266
4265
|
const n = e.renderStack.push(this);
|
|
4267
4266
|
a = e.renderStack.currentCall, e.renderStack.currentCall = n;
|
|
4268
4267
|
}
|
|
4269
|
-
if (this.mask instanceof
|
|
4268
|
+
if (this.mask instanceof M)
|
|
4270
4269
|
this.getNode("__$mask") || (this.mask.processMode = "disabled", this.appendChild(this.mask, "front"));
|
|
4271
4270
|
else {
|
|
4272
4271
|
const n = this.getNode("__$mask");
|
|
@@ -4418,7 +4417,7 @@ let k = class extends pe {
|
|
|
4418
4417
|
);
|
|
4419
4418
|
}
|
|
4420
4419
|
toJSON() {
|
|
4421
|
-
return
|
|
4420
|
+
return Br({
|
|
4422
4421
|
...super.toJSON(),
|
|
4423
4422
|
children: this.children.length ? [...this.children.map((r) => r.toJSON())] : void 0,
|
|
4424
4423
|
meta: {
|
|
@@ -4430,43 +4429,43 @@ let k = class extends pe {
|
|
|
4430
4429
|
static parse(r) {
|
|
4431
4430
|
if (Array.isArray(r))
|
|
4432
4431
|
return r.map((n) => this.parse(n));
|
|
4433
|
-
const { meta: e = {}, children: t, ...s } = r, { inCanvasIs: i = "Node" } = e, o =
|
|
4432
|
+
const { meta: e = {}, children: t, ...s } = r, { inCanvasIs: i = "Node" } = e, o = Xt.get(i) ?? M, a = new o({ ...s, meta: e });
|
|
4434
4433
|
return t?.forEach((n) => a.appendChild(this.parse(n))), a;
|
|
4435
4434
|
}
|
|
4436
4435
|
};
|
|
4437
4436
|
ne([
|
|
4438
|
-
|
|
4439
|
-
],
|
|
4437
|
+
u({ fallback: zr() })
|
|
4438
|
+
], M.prototype, "id", 2);
|
|
4440
4439
|
ne([
|
|
4441
|
-
|
|
4442
|
-
],
|
|
4440
|
+
u({ fallback: zr() })
|
|
4441
|
+
], M.prototype, "name", 2);
|
|
4443
4442
|
ne([
|
|
4444
|
-
|
|
4445
|
-
],
|
|
4443
|
+
u({ internal: !0, fallback: "inherit" })
|
|
4444
|
+
], M.prototype, "processMode", 2);
|
|
4446
4445
|
ne([
|
|
4447
|
-
|
|
4448
|
-
],
|
|
4446
|
+
u({ internal: !0, fallback: "default" })
|
|
4447
|
+
], M.prototype, "processSortMode", 2);
|
|
4449
4448
|
ne([
|
|
4450
|
-
|
|
4451
|
-
],
|
|
4449
|
+
u({ internal: !0, fallback: "inherit" })
|
|
4450
|
+
], M.prototype, "renderMode", 2);
|
|
4452
4451
|
ne([
|
|
4453
|
-
|
|
4454
|
-
],
|
|
4452
|
+
u({ internal: !0, fallback: "inherit" })
|
|
4453
|
+
], M.prototype, "inputMode", 2);
|
|
4455
4454
|
ne([
|
|
4456
|
-
|
|
4457
|
-
],
|
|
4455
|
+
u({ internal: !0, fallback: "default" })
|
|
4456
|
+
], M.prototype, "internalMode", 2);
|
|
4458
4457
|
ne([
|
|
4459
|
-
|
|
4460
|
-
],
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
],
|
|
4464
|
-
var wo = Object.defineProperty, Po = Object.getOwnPropertyDescriptor,
|
|
4458
|
+
u({ internal: !0 })
|
|
4459
|
+
], M.prototype, "mask", 2);
|
|
4460
|
+
M = ne([
|
|
4461
|
+
g("Node")
|
|
4462
|
+
], M);
|
|
4463
|
+
var wo = Object.defineProperty, Po = Object.getOwnPropertyDescriptor, Le = (r, e, t, s) => {
|
|
4465
4464
|
for (var i = s > 1 ? void 0 : s ? Po(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
4466
4465
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4467
4466
|
return s && i && wo(e, t, i), i;
|
|
4468
4467
|
};
|
|
4469
|
-
let W = class extends
|
|
4468
|
+
let W = class extends M {
|
|
4470
4469
|
constructor(r, e = []) {
|
|
4471
4470
|
super(), this.setProperties(r).append(e);
|
|
4472
4471
|
}
|
|
@@ -4513,30 +4512,30 @@ let W = class extends k {
|
|
|
4513
4512
|
super._process(r), this._updateCurrentTime();
|
|
4514
4513
|
}
|
|
4515
4514
|
};
|
|
4516
|
-
|
|
4517
|
-
|
|
4515
|
+
Le([
|
|
4516
|
+
u({ fallback: !1 })
|
|
4518
4517
|
], W.prototype, "loop", 2);
|
|
4519
|
-
|
|
4520
|
-
|
|
4518
|
+
Le([
|
|
4519
|
+
u({ fallback: 0 })
|
|
4521
4520
|
], W.prototype, "delay", 2);
|
|
4522
|
-
|
|
4523
|
-
|
|
4521
|
+
Le([
|
|
4522
|
+
u({ fallback: 0 })
|
|
4524
4523
|
], W.prototype, "duration", 2);
|
|
4525
|
-
|
|
4526
|
-
|
|
4524
|
+
Le([
|
|
4525
|
+
u({ fallback: !1 })
|
|
4527
4526
|
], W.prototype, "paused", 2);
|
|
4528
|
-
|
|
4529
|
-
|
|
4527
|
+
Le([
|
|
4528
|
+
u({ internal: !0, fallback: !1 })
|
|
4530
4529
|
], W.prototype, "insideTimeRange", 2);
|
|
4531
|
-
W =
|
|
4532
|
-
|
|
4530
|
+
W = Le([
|
|
4531
|
+
g("TimelineNode")
|
|
4533
4532
|
], W);
|
|
4534
4533
|
var To = Object.defineProperty, Eo = Object.getOwnPropertyDescriptor, lt = (r, e, t, s) => {
|
|
4535
4534
|
for (var i = s > 1 ? void 0 : s ? Eo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
4536
4535
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4537
4536
|
return s && i && To(e, t, i), i;
|
|
4538
4537
|
};
|
|
4539
|
-
let
|
|
4538
|
+
let Pe = class extends W {
|
|
4540
4539
|
_parentGlobalVisible;
|
|
4541
4540
|
_globalVisible;
|
|
4542
4541
|
get globalVisible() {
|
|
@@ -4647,26 +4646,26 @@ let we = class extends W {
|
|
|
4647
4646
|
}
|
|
4648
4647
|
};
|
|
4649
4648
|
lt([
|
|
4650
|
-
|
|
4651
|
-
],
|
|
4649
|
+
u()
|
|
4650
|
+
], Pe.prototype, "modulate", 2);
|
|
4652
4651
|
lt([
|
|
4653
|
-
|
|
4654
|
-
],
|
|
4652
|
+
u()
|
|
4653
|
+
], Pe.prototype, "blendMode", 2);
|
|
4655
4654
|
lt([
|
|
4656
|
-
|
|
4657
|
-
],
|
|
4655
|
+
u({ internal: !0, fallback: !0 })
|
|
4656
|
+
], Pe.prototype, "visible", 2);
|
|
4658
4657
|
lt([
|
|
4659
|
-
|
|
4660
|
-
],
|
|
4661
|
-
|
|
4662
|
-
|
|
4663
|
-
],
|
|
4664
|
-
var So = Object.defineProperty, Co = Object.getOwnPropertyDescriptor,
|
|
4658
|
+
u({ internal: !0, fallback: 1 })
|
|
4659
|
+
], Pe.prototype, "opacity", 2);
|
|
4660
|
+
Pe = lt([
|
|
4661
|
+
g("CanvasItem")
|
|
4662
|
+
], Pe);
|
|
4663
|
+
var So = Object.defineProperty, Co = Object.getOwnPropertyDescriptor, Fe = (r, e, t, s) => {
|
|
4665
4664
|
for (var i = s > 1 ? void 0 : s ? Co(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
4666
4665
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4667
4666
|
return s && i && So(e, t, i), i;
|
|
4668
4667
|
};
|
|
4669
|
-
let j = class extends
|
|
4668
|
+
let j = class extends M {
|
|
4670
4669
|
constructor(r = !1) {
|
|
4671
4670
|
super(), this.flipY = r, this.projection.flipY(r);
|
|
4672
4671
|
}
|
|
@@ -4674,8 +4673,8 @@ let j = class extends k {
|
|
|
4674
4673
|
canvasTransform = new O();
|
|
4675
4674
|
_framebufferIndex = 0;
|
|
4676
4675
|
_framebuffers = [
|
|
4677
|
-
{ texture: new
|
|
4678
|
-
{ texture: new
|
|
4676
|
+
{ texture: new xr(), needsUpload: !1 },
|
|
4677
|
+
{ texture: new xr(), needsUpload: !1 }
|
|
4679
4678
|
];
|
|
4680
4679
|
get valid() {
|
|
4681
4680
|
return !!(this.width && this.height);
|
|
@@ -4739,9 +4738,12 @@ let j = class extends k {
|
|
|
4739
4738
|
activate(r) {
|
|
4740
4739
|
return this.valid ? (r.flush(), this._tree?.setCurrentViewport(this), this.upload(r), r.framebuffer.bind(this._glFramebuffer(r)), !0) : !1;
|
|
4741
4740
|
}
|
|
4741
|
+
flush(r) {
|
|
4742
|
+
r.flush();
|
|
4743
|
+
}
|
|
4742
4744
|
redraw(r, e) {
|
|
4743
4745
|
if (this.valid) {
|
|
4744
|
-
|
|
4746
|
+
this.flush(r);
|
|
4745
4747
|
const t = this.framebuffer.texture;
|
|
4746
4748
|
return this._framebufferIndex = (this._framebufferIndex + 1) % this._framebuffers.length, this.activate(r), r.clear(), t.activate(r, 0), e(), !0;
|
|
4747
4749
|
}
|
|
@@ -4757,7 +4759,7 @@ let j = class extends k {
|
|
|
4757
4759
|
r.program.uniforms.projectionMatrix = this.projection.toArray(!0), r.program.uniforms.viewMatrix = this.canvasTransform.toArray(!0), this.activate(r), r.clear(), super.render(r, e), r.flush(), t ? t.activate(r) : (r.framebuffer.bind(null), this._tree?.setCurrentViewport(void 0));
|
|
4758
4760
|
}
|
|
4759
4761
|
getRect() {
|
|
4760
|
-
return new
|
|
4762
|
+
return new ye(this.x, this.y, this.width, this.height);
|
|
4761
4763
|
}
|
|
4762
4764
|
toCanvasGlobal(r, e) {
|
|
4763
4765
|
return this.canvasTransform.applyAffineInverse(r, e);
|
|
@@ -4766,30 +4768,30 @@ let j = class extends k {
|
|
|
4766
4768
|
return this.canvasTransform.apply(r, e);
|
|
4767
4769
|
}
|
|
4768
4770
|
};
|
|
4769
|
-
|
|
4770
|
-
|
|
4771
|
+
Fe([
|
|
4772
|
+
u({ fallback: 0 })
|
|
4771
4773
|
], j.prototype, "x", 2);
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
+
Fe([
|
|
4775
|
+
u({ fallback: 0 })
|
|
4774
4776
|
], j.prototype, "y", 2);
|
|
4775
|
-
|
|
4776
|
-
|
|
4777
|
+
Fe([
|
|
4778
|
+
u({ fallback: 0 })
|
|
4777
4779
|
], j.prototype, "width", 2);
|
|
4778
|
-
|
|
4779
|
-
|
|
4780
|
+
Fe([
|
|
4781
|
+
u({ fallback: 0 })
|
|
4780
4782
|
], j.prototype, "height", 2);
|
|
4781
|
-
|
|
4782
|
-
|
|
4783
|
+
Fe([
|
|
4784
|
+
u({ internal: !0, fallback: !1 })
|
|
4783
4785
|
], j.prototype, "msaa", 2);
|
|
4784
|
-
j =
|
|
4785
|
-
|
|
4786
|
+
j = Fe([
|
|
4787
|
+
g("Viewport")
|
|
4786
4788
|
], j);
|
|
4787
4789
|
var Ao = Object.defineProperty, Ro = Object.getOwnPropertyDescriptor, ht = (r, e, t, s) => {
|
|
4788
4790
|
for (var i = s > 1 ? void 0 : s ? Ro(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
4789
4791
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4790
4792
|
return s && i && Ao(e, t, i), i;
|
|
4791
4793
|
};
|
|
4792
|
-
let
|
|
4794
|
+
let x = class extends W {
|
|
4793
4795
|
material;
|
|
4794
4796
|
get _effectMode() {
|
|
4795
4797
|
return this.effectMode ?? "parent";
|
|
@@ -4814,7 +4816,7 @@ let y = class extends W {
|
|
|
4814
4816
|
break;
|
|
4815
4817
|
}
|
|
4816
4818
|
case "glslSrc": {
|
|
4817
|
-
e ?
|
|
4819
|
+
e ? z.text.load(e).then((s) => this.glsl = s) : this.glsl = "";
|
|
4818
4820
|
break;
|
|
4819
4821
|
}
|
|
4820
4822
|
}
|
|
@@ -4949,20 +4951,20 @@ let y = class extends W {
|
|
|
4949
4951
|
}
|
|
4950
4952
|
};
|
|
4951
4953
|
ht([
|
|
4952
|
-
|
|
4953
|
-
],
|
|
4954
|
+
u({ internal: !0 })
|
|
4955
|
+
], x.prototype, "material", 2);
|
|
4954
4956
|
ht([
|
|
4955
|
-
|
|
4956
|
-
],
|
|
4957
|
+
u()
|
|
4958
|
+
], x.prototype, "effectMode", 2);
|
|
4957
4959
|
ht([
|
|
4958
|
-
|
|
4959
|
-
],
|
|
4960
|
+
u()
|
|
4961
|
+
], x.prototype, "glsl", 2);
|
|
4960
4962
|
ht([
|
|
4961
|
-
|
|
4962
|
-
],
|
|
4963
|
-
|
|
4964
|
-
|
|
4965
|
-
],
|
|
4963
|
+
u()
|
|
4964
|
+
], x.prototype, "glslSrc", 2);
|
|
4965
|
+
x = ht([
|
|
4966
|
+
g("Effect")
|
|
4967
|
+
], x);
|
|
4966
4968
|
class Oo {
|
|
4967
4969
|
currentCall;
|
|
4968
4970
|
calls = [];
|
|
@@ -4986,12 +4988,12 @@ class Oo {
|
|
|
4986
4988
|
}), this.calls = [];
|
|
4987
4989
|
}
|
|
4988
4990
|
}
|
|
4989
|
-
var
|
|
4990
|
-
for (var i = s > 1 ? void 0 : s ?
|
|
4991
|
+
var Mo = Object.defineProperty, ko = Object.getOwnPropertyDescriptor, $e = (r, e, t, s) => {
|
|
4992
|
+
for (var i = s > 1 ? void 0 : s ? ko(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
4991
4993
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
4992
|
-
return s && i &&
|
|
4994
|
+
return s && i && Mo(e, t, i), i;
|
|
4993
4995
|
};
|
|
4994
|
-
let oe = class extends
|
|
4996
|
+
let oe = class extends M {
|
|
4995
4997
|
static from(r, e = !1) {
|
|
4996
4998
|
const [t, s] = r ? Array.isArray(r) ? r : [0, r] : [];
|
|
4997
4999
|
return new oe({
|
|
@@ -5022,43 +5024,51 @@ let oe = class extends k {
|
|
|
5022
5024
|
super._process(r), this.paused || this.addTime(r);
|
|
5023
5025
|
}
|
|
5024
5026
|
};
|
|
5025
|
-
|
|
5026
|
-
|
|
5027
|
+
$e([
|
|
5028
|
+
u({ fallback: 0 })
|
|
5027
5029
|
], oe.prototype, "startTime", 2);
|
|
5028
|
-
|
|
5029
|
-
|
|
5030
|
+
$e([
|
|
5031
|
+
u({ fallback: 0 })
|
|
5030
5032
|
], oe.prototype, "currentTime", 2);
|
|
5031
|
-
|
|
5032
|
-
|
|
5033
|
+
$e([
|
|
5034
|
+
u({ fallback: Number.MAX_SAFE_INTEGER })
|
|
5033
5035
|
], oe.prototype, "endTime", 2);
|
|
5034
|
-
|
|
5035
|
-
|
|
5036
|
+
$e([
|
|
5037
|
+
u({ fallback: !1 })
|
|
5036
5038
|
], oe.prototype, "loop", 2);
|
|
5037
|
-
|
|
5038
|
-
|
|
5039
|
+
$e([
|
|
5040
|
+
u({ fallback: !1 })
|
|
5039
5041
|
], oe.prototype, "paused", 2);
|
|
5040
|
-
oe =
|
|
5041
|
-
|
|
5042
|
+
oe = $e([
|
|
5043
|
+
g("Timeline")
|
|
5042
5044
|
], oe);
|
|
5043
|
-
var Uo = Object.defineProperty, Do = Object.getOwnPropertyDescriptor,
|
|
5045
|
+
var Uo = Object.defineProperty, Do = Object.getOwnPropertyDescriptor, ss = (r, e, t, s) => {
|
|
5044
5046
|
for (var i = s > 1 ? void 0 : s ? Do(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5045
5047
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5046
5048
|
return s && i && Uo(e, t, i), i;
|
|
5047
5049
|
};
|
|
5048
5050
|
let wt = class extends j {
|
|
5051
|
+
finish(r) {
|
|
5052
|
+
r.framebuffer.finishRenderPass(
|
|
5053
|
+
this._glFramebuffer(r)
|
|
5054
|
+
);
|
|
5055
|
+
}
|
|
5056
|
+
flush(r) {
|
|
5057
|
+
this.finish(r), super.flush(r);
|
|
5058
|
+
}
|
|
5049
5059
|
};
|
|
5050
|
-
|
|
5051
|
-
|
|
5060
|
+
ss([
|
|
5061
|
+
u({ fallback: !1 })
|
|
5052
5062
|
], wt.prototype, "msaa", 2);
|
|
5053
|
-
wt =
|
|
5054
|
-
|
|
5063
|
+
wt = ss([
|
|
5064
|
+
g("Window")
|
|
5055
5065
|
], wt);
|
|
5056
|
-
var Io = Object.defineProperty,
|
|
5066
|
+
var Io = Object.defineProperty, Re = (r, e, t, s) => {
|
|
5057
5067
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
5058
5068
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
5059
5069
|
return i && Io(e, t, i), i;
|
|
5060
5070
|
};
|
|
5061
|
-
class
|
|
5071
|
+
class me extends Yt {
|
|
5062
5072
|
input = new Oi();
|
|
5063
5073
|
renderStack = new Oo();
|
|
5064
5074
|
root = new wt(!0).setTree(this);
|
|
@@ -5093,9 +5103,7 @@ class Ae extends Kt {
|
|
|
5093
5103
|
this.emit("rendering"), this.renderStack.render(e), this._renderScreen(e), this.emit("rendered");
|
|
5094
5104
|
}
|
|
5095
5105
|
_renderScreen(e) {
|
|
5096
|
-
this.root.
|
|
5097
|
-
this.root._glFramebuffer(e)
|
|
5098
|
-
), e.state.reset(), e.framebuffer.bind(null), e.gl.bindFramebuffer(e.gl.FRAMEBUFFER, null), e.viewport.bind({
|
|
5106
|
+
this.root.finish(e), e.state.reset(), e.framebuffer.bind(null), e.gl.bindFramebuffer(e.gl.FRAMEBUFFER, null), e.viewport.bind({
|
|
5099
5107
|
x: 0,
|
|
5100
5108
|
y: 0,
|
|
5101
5109
|
width: this.root.width * e.pixelRatio,
|
|
@@ -5108,47 +5116,50 @@ class Ae extends Kt {
|
|
|
5108
5116
|
this.root.destroy(), this.input.destroy(), super.destroy();
|
|
5109
5117
|
}
|
|
5110
5118
|
}
|
|
5111
|
-
|
|
5112
|
-
|
|
5113
|
-
],
|
|
5114
|
-
|
|
5115
|
-
|
|
5116
|
-
],
|
|
5117
|
-
|
|
5118
|
-
|
|
5119
|
-
],
|
|
5120
|
-
|
|
5121
|
-
|
|
5122
|
-
],
|
|
5123
|
-
|
|
5124
|
-
|
|
5125
|
-
],
|
|
5126
|
-
|
|
5127
|
-
|
|
5128
|
-
],
|
|
5119
|
+
Re([
|
|
5120
|
+
u({ alias: "root.msaa" })
|
|
5121
|
+
], me.prototype, "msaa");
|
|
5122
|
+
Re([
|
|
5123
|
+
u({ fallback: !1 })
|
|
5124
|
+
], me.prototype, "pixelate");
|
|
5125
|
+
Re([
|
|
5126
|
+
u()
|
|
5127
|
+
], me.prototype, "backgroundColor");
|
|
5128
|
+
Re([
|
|
5129
|
+
u({ internal: !0, fallback: !1 })
|
|
5130
|
+
], me.prototype, "debug");
|
|
5131
|
+
Re([
|
|
5132
|
+
u({ internal: !0, fallback: !1 })
|
|
5133
|
+
], me.prototype, "processPaused");
|
|
5134
|
+
Re([
|
|
5135
|
+
u({ internal: !0, default: () => Js })
|
|
5136
|
+
], me.prototype, "fonts");
|
|
5137
|
+
Re([
|
|
5138
|
+
u({ internal: !0, default: () => new oe() })
|
|
5139
|
+
], me.prototype, "timeline");
|
|
5129
5140
|
var Bo = Object.getOwnPropertyDescriptor, zo = (r, e, t, s) => {
|
|
5130
5141
|
for (var i = s > 1 ? void 0 : s ? Bo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5131
5142
|
(a = r[o]) && (i = a(i) || i);
|
|
5132
5143
|
return i;
|
|
5133
5144
|
};
|
|
5134
|
-
let
|
|
5145
|
+
let Ue = class extends x {
|
|
5135
5146
|
constructor(r, e = []) {
|
|
5136
5147
|
super(), this.setProperties(r).append(e);
|
|
5137
5148
|
}
|
|
5138
5149
|
};
|
|
5139
|
-
|
|
5140
|
-
|
|
5150
|
+
Ue = zo([
|
|
5151
|
+
g("Transition", {
|
|
5141
5152
|
effectMode: "transition",
|
|
5142
5153
|
processMode: "pausable",
|
|
5143
5154
|
duration: 2e3
|
|
5144
5155
|
})
|
|
5145
|
-
],
|
|
5146
|
-
var No = Object.defineProperty, Lo = Object.getOwnPropertyDescriptor,
|
|
5156
|
+
], Ue);
|
|
5157
|
+
var No = Object.defineProperty, Lo = Object.getOwnPropertyDescriptor, er = (r, e, t, s) => {
|
|
5147
5158
|
for (var i = s > 1 ? void 0 : s ? Lo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5148
5159
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5149
5160
|
return s && i && No(e, t, i), i;
|
|
5150
5161
|
};
|
|
5151
|
-
let
|
|
5162
|
+
let Te = class extends Pe {
|
|
5152
5163
|
position = new C().on("update", () => this.updateGlobalTransform());
|
|
5153
5164
|
scale = new C(1, 1).on("update", () => this.updateGlobalTransform());
|
|
5154
5165
|
skew = new C().on("update", () => this.updateGlobalTransform());
|
|
@@ -5197,9 +5208,9 @@ let Pe = class extends we {
|
|
|
5197
5208
|
} else
|
|
5198
5209
|
[t, s, i, o, a, n] = this.globalTransform.toArray();
|
|
5199
5210
|
const h = r.slice();
|
|
5200
|
-
for (let l = r.length,
|
|
5201
|
-
const d = r[
|
|
5202
|
-
h[
|
|
5211
|
+
for (let l = r.length, c = 0; c < l; c += 2) {
|
|
5212
|
+
const d = r[c], f = r[c + 1];
|
|
5213
|
+
h[c] = t * d + s * f + i, h[c + 1] = o * d + a * f + n;
|
|
5203
5214
|
}
|
|
5204
5215
|
return h;
|
|
5205
5216
|
}
|
|
@@ -5221,21 +5232,21 @@ let Pe = class extends we {
|
|
|
5221
5232
|
return this.globalTransform.apply(r, e);
|
|
5222
5233
|
}
|
|
5223
5234
|
};
|
|
5224
|
-
|
|
5225
|
-
|
|
5226
|
-
],
|
|
5227
|
-
|
|
5228
|
-
|
|
5229
|
-
],
|
|
5230
|
-
|
|
5231
|
-
|
|
5232
|
-
],
|
|
5233
|
-
var Fo = Object.defineProperty, $o = Object.getOwnPropertyDescriptor,
|
|
5235
|
+
er([
|
|
5236
|
+
u({ internal: !0, fallback: 0 })
|
|
5237
|
+
], Te.prototype, "rotation", 2);
|
|
5238
|
+
er([
|
|
5239
|
+
u({ internal: !0, fallback: 0 })
|
|
5240
|
+
], Te.prototype, "globalRotation", 2);
|
|
5241
|
+
Te = er([
|
|
5242
|
+
g("Node2D")
|
|
5243
|
+
], Te);
|
|
5244
|
+
var Fo = Object.defineProperty, $o = Object.getOwnPropertyDescriptor, tr = (r, e, t, s) => {
|
|
5234
5245
|
for (var i = s > 1 ? void 0 : s ? $o(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5235
5246
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5236
5247
|
return s && i && Fo(e, t, i), i;
|
|
5237
5248
|
};
|
|
5238
|
-
let Pt = class extends
|
|
5249
|
+
let Pt = class extends Te {
|
|
5239
5250
|
canvasTransform = new O();
|
|
5240
5251
|
_screenOffset = { x: 0, y: 0 };
|
|
5241
5252
|
_zoom = new C(1, 1).on("update", () => this.updateTransform());
|
|
@@ -5299,8 +5310,8 @@ let Pt = class extends Pe {
|
|
|
5299
5310
|
} else if (e === "pointermove") {
|
|
5300
5311
|
const t = r;
|
|
5301
5312
|
this.grabbing && (this.position.add(
|
|
5302
|
-
this._screenOffset.x - t.screenX,
|
|
5303
|
-
this._screenOffset.y - t.screenY
|
|
5313
|
+
Math.round(this._screenOffset.x - t.screenX),
|
|
5314
|
+
Math.round(this._screenOffset.y - t.screenY)
|
|
5304
5315
|
), this._screenOffset = { x: t.screenX, y: t.screenY });
|
|
5305
5316
|
} else if (e === "pointerup") {
|
|
5306
5317
|
const t = r;
|
|
@@ -5314,15 +5325,18 @@ let Pt = class extends Pe {
|
|
|
5314
5325
|
this.zoomWithWheel(i);
|
|
5315
5326
|
const o = this.toScreen(t);
|
|
5316
5327
|
this.position.add(
|
|
5317
|
-
o.x - e.x,
|
|
5318
|
-
o.y - e.y
|
|
5328
|
+
Math.round(o.x - e.x),
|
|
5329
|
+
Math.round(o.y - e.y)
|
|
5319
5330
|
);
|
|
5320
5331
|
} else
|
|
5321
|
-
r.preventDefault(), this.position.add(
|
|
5332
|
+
r.preventDefault(), this.position.add(
|
|
5333
|
+
Math.round(r.deltaX),
|
|
5334
|
+
Math.round(r.deltaY)
|
|
5335
|
+
);
|
|
5322
5336
|
}
|
|
5323
5337
|
zoomWithWheel(r) {
|
|
5324
|
-
const t = Math.log(this._zoom.x) + r;
|
|
5325
|
-
this.setZoom(Math.
|
|
5338
|
+
const t = Math.log(this._zoom.x) + r, s = Math.exp(t);
|
|
5339
|
+
this.setZoom(Math.round(s * 1e4) / 1e4);
|
|
5326
5340
|
}
|
|
5327
5341
|
updateTransform() {
|
|
5328
5342
|
super.updateTransform(), this.updateCanvasTransform();
|
|
@@ -5345,19 +5359,19 @@ let Pt = class extends Pe {
|
|
|
5345
5359
|
};
|
|
5346
5360
|
}
|
|
5347
5361
|
};
|
|
5348
|
-
|
|
5349
|
-
|
|
5362
|
+
tr([
|
|
5363
|
+
u({ internal: !0, fallback: !1 })
|
|
5350
5364
|
], Pt.prototype, "spaceKey", 2);
|
|
5351
|
-
|
|
5352
|
-
|
|
5365
|
+
tr([
|
|
5366
|
+
u({ internal: !0, fallback: !1 })
|
|
5353
5367
|
], Pt.prototype, "grabbing", 2);
|
|
5354
|
-
Pt =
|
|
5355
|
-
|
|
5368
|
+
Pt = tr([
|
|
5369
|
+
g("Camera2D", {
|
|
5356
5370
|
processMode: "disabled",
|
|
5357
5371
|
renderMode: "disabled"
|
|
5358
5372
|
})
|
|
5359
5373
|
], Pt);
|
|
5360
|
-
const
|
|
5374
|
+
const Pr = {
|
|
5361
5375
|
brightness: 1,
|
|
5362
5376
|
contrast: 1,
|
|
5363
5377
|
grayscale: 0,
|
|
@@ -5368,12 +5382,12 @@ const Tr = {
|
|
|
5368
5382
|
sepia: 0
|
|
5369
5383
|
};
|
|
5370
5384
|
function Ol(r) {
|
|
5371
|
-
const e = new
|
|
5385
|
+
const e = new Hr();
|
|
5372
5386
|
if (r === "none")
|
|
5373
5387
|
return e;
|
|
5374
5388
|
const t = Rt(r).reduce((s, { name: i, args: o }) => (s[i] = o[0].normalizedIntValue, s), {});
|
|
5375
|
-
Object.keys(
|
|
5376
|
-
t[s] = t[s] ??
|
|
5389
|
+
Object.keys(Pr).forEach((s) => {
|
|
5390
|
+
t[s] = t[s] ?? Pr[s];
|
|
5377
5391
|
});
|
|
5378
5392
|
for (const s in t) {
|
|
5379
5393
|
const i = t[s];
|
|
@@ -5493,18 +5507,18 @@ function Go(r) {
|
|
|
5493
5507
|
}
|
|
5494
5508
|
});
|
|
5495
5509
|
}
|
|
5496
|
-
var
|
|
5510
|
+
var is = Object.defineProperty, Wo = Object.getOwnPropertyDescriptor, jo = (r, e, t) => e in r ? is(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, le = (r, e, t, s) => {
|
|
5497
5511
|
for (var i = s > 1 ? void 0 : s ? Wo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5498
5512
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5499
|
-
return s && i &&
|
|
5513
|
+
return s && i && is(e, t, i), i;
|
|
5500
5514
|
}, qo = (r, e, t) => jo(r, e + "", t);
|
|
5501
|
-
let
|
|
5515
|
+
let V = class extends x {
|
|
5502
5516
|
constructor(r, e = []) {
|
|
5503
5517
|
super(), this.setProperties(r).append(e);
|
|
5504
5518
|
}
|
|
5505
5519
|
apply(r, e) {
|
|
5506
5520
|
e.redraw(r, () => {
|
|
5507
|
-
b.draw(r,
|
|
5521
|
+
b.draw(r, V.material, {
|
|
5508
5522
|
sampler: 0,
|
|
5509
5523
|
saturation: this.saturation,
|
|
5510
5524
|
contrast: this.contrast,
|
|
@@ -5518,7 +5532,7 @@ let $ = class extends y {
|
|
|
5518
5532
|
});
|
|
5519
5533
|
}
|
|
5520
5534
|
};
|
|
5521
|
-
qo(
|
|
5535
|
+
qo(V, "material", new w({
|
|
5522
5536
|
vert: `precision mediump float;
|
|
5523
5537
|
attribute vec2 position;
|
|
5524
5538
|
attribute vec2 uv;
|
|
@@ -5554,39 +5568,39 @@ void main(void) {
|
|
|
5554
5568
|
}`
|
|
5555
5569
|
}));
|
|
5556
5570
|
le([
|
|
5557
|
-
|
|
5558
|
-
],
|
|
5571
|
+
u({ fallback: 1 })
|
|
5572
|
+
], V.prototype, "saturation", 2);
|
|
5559
5573
|
le([
|
|
5560
|
-
|
|
5561
|
-
],
|
|
5574
|
+
u({ fallback: 1 })
|
|
5575
|
+
], V.prototype, "contrast", 2);
|
|
5562
5576
|
le([
|
|
5563
|
-
|
|
5564
|
-
],
|
|
5577
|
+
u({ fallback: 1 })
|
|
5578
|
+
], V.prototype, "brightness", 2);
|
|
5565
5579
|
le([
|
|
5566
|
-
|
|
5567
|
-
],
|
|
5580
|
+
u({ fallback: 1 })
|
|
5581
|
+
], V.prototype, "red", 2);
|
|
5568
5582
|
le([
|
|
5569
|
-
|
|
5570
|
-
],
|
|
5583
|
+
u({ fallback: 1 })
|
|
5584
|
+
], V.prototype, "green", 2);
|
|
5571
5585
|
le([
|
|
5572
|
-
|
|
5573
|
-
],
|
|
5586
|
+
u({ fallback: 1 })
|
|
5587
|
+
], V.prototype, "blue", 2);
|
|
5574
5588
|
le([
|
|
5575
|
-
|
|
5576
|
-
],
|
|
5589
|
+
u({ fallback: 1 })
|
|
5590
|
+
], V.prototype, "alpha", 2);
|
|
5577
5591
|
le([
|
|
5578
|
-
|
|
5579
|
-
],
|
|
5580
|
-
|
|
5581
|
-
|
|
5582
|
-
],
|
|
5583
|
-
var
|
|
5592
|
+
u({ fallback: 1 })
|
|
5593
|
+
], V.prototype, "gamma", 2);
|
|
5594
|
+
V = le([
|
|
5595
|
+
g("ColorAdjustEffect")
|
|
5596
|
+
], V);
|
|
5597
|
+
var os = Object.defineProperty, Xo = Object.getOwnPropertyDescriptor, Ho = (r, e, t) => e in r ? os(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, as = (r, e, t, s) => {
|
|
5584
5598
|
for (var i = s > 1 ? void 0 : s ? Xo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5585
5599
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5586
|
-
return s && i &&
|
|
5600
|
+
return s && i && os(e, t, i), i;
|
|
5587
5601
|
}, Yo = (r, e, t) => Ho(r, e + "", t);
|
|
5588
|
-
let Je = class extends
|
|
5589
|
-
_colorMatrix = new
|
|
5602
|
+
let Je = class extends x {
|
|
5603
|
+
_colorMatrix = new Hr();
|
|
5590
5604
|
constructor(r, e = []) {
|
|
5591
5605
|
super(), this.setProperties(r).append(e);
|
|
5592
5606
|
}
|
|
@@ -5631,7 +5645,7 @@ let Je = class extends y {
|
|
|
5631
5645
|
});
|
|
5632
5646
|
}
|
|
5633
5647
|
};
|
|
5634
|
-
Yo(Je, "material", new
|
|
5648
|
+
Yo(Je, "material", new w({
|
|
5635
5649
|
vert: `precision mediump float;
|
|
5636
5650
|
attribute vec2 position;
|
|
5637
5651
|
attribute vec2 uv;
|
|
@@ -5658,19 +5672,19 @@ void main(void) {
|
|
|
5658
5672
|
);
|
|
5659
5673
|
}`
|
|
5660
5674
|
}));
|
|
5661
|
-
|
|
5662
|
-
|
|
5675
|
+
as([
|
|
5676
|
+
u()
|
|
5663
5677
|
], Je.prototype, "filter", 2);
|
|
5664
|
-
Je =
|
|
5665
|
-
|
|
5678
|
+
Je = as([
|
|
5679
|
+
g("ColorFilterEffect")
|
|
5666
5680
|
], Je);
|
|
5667
|
-
var
|
|
5681
|
+
var ns = Object.defineProperty, Ko = Object.getOwnPropertyDescriptor, Zo = (r, e, t) => e in r ? ns(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, rr = (r, e, t, s) => {
|
|
5668
5682
|
for (var i = s > 1 ? void 0 : s ? Ko(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5669
5683
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5670
|
-
return s && i &&
|
|
5684
|
+
return s && i && ns(e, t, i), i;
|
|
5671
5685
|
}, Jo = (r, e, t) => Zo(r, e + "", t);
|
|
5672
5686
|
const Ke = 50;
|
|
5673
|
-
let
|
|
5687
|
+
let De = class extends x {
|
|
5674
5688
|
_color = new J();
|
|
5675
5689
|
constructor(r, e = []) {
|
|
5676
5690
|
super(), this.setProperties(r).append(e);
|
|
@@ -5684,14 +5698,14 @@ let Ue = class extends y {
|
|
|
5684
5698
|
});
|
|
5685
5699
|
for (; t.length < Ke; )
|
|
5686
5700
|
t.push([0, 0, 0, 0]);
|
|
5687
|
-
b.draw(r,
|
|
5701
|
+
b.draw(r, De.material, {
|
|
5688
5702
|
sampler: 0,
|
|
5689
5703
|
colors: t.slice(0, Ke).flatMap((s) => s)
|
|
5690
5704
|
});
|
|
5691
5705
|
});
|
|
5692
5706
|
}
|
|
5693
5707
|
};
|
|
5694
|
-
Jo(
|
|
5708
|
+
Jo(De, "material", new w({
|
|
5695
5709
|
vert: `precision mediump float;
|
|
5696
5710
|
attribute vec2 position;
|
|
5697
5711
|
attribute vec2 uv;
|
|
@@ -5738,21 +5752,21 @@ void main(void) {
|
|
|
5738
5752
|
gl_FragColor = vec4(mix(color.rgb, mask.rgb, color.a * mask.a), color.a);
|
|
5739
5753
|
}`
|
|
5740
5754
|
}));
|
|
5741
|
-
|
|
5742
|
-
|
|
5743
|
-
],
|
|
5744
|
-
|
|
5745
|
-
|
|
5746
|
-
],
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
],
|
|
5750
|
-
var
|
|
5755
|
+
rr([
|
|
5756
|
+
u({ default: () => [] })
|
|
5757
|
+
], De.prototype, "colors", 2);
|
|
5758
|
+
rr([
|
|
5759
|
+
u({ fallback: 0.5 })
|
|
5760
|
+
], De.prototype, "alpha", 2);
|
|
5761
|
+
De = rr([
|
|
5762
|
+
g("ColorOverlayEffect")
|
|
5763
|
+
], De);
|
|
5764
|
+
var ls = Object.defineProperty, Qo = Object.getOwnPropertyDescriptor, ea = (r, e, t) => e in r ? ls(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, sr = (r, e, t, s) => {
|
|
5751
5765
|
for (var i = s > 1 ? void 0 : s ? Qo(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5752
5766
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5753
|
-
return s && i &&
|
|
5767
|
+
return s && i && ls(e, t, i), i;
|
|
5754
5768
|
}, ta = (r, e, t) => ea(r, e + "", t);
|
|
5755
|
-
let
|
|
5769
|
+
let Ie = class extends x {
|
|
5756
5770
|
_color = new J();
|
|
5757
5771
|
constructor(r, e = []) {
|
|
5758
5772
|
super(), this.setProperties(r).append(e);
|
|
@@ -5764,7 +5778,7 @@ let De = class extends y {
|
|
|
5764
5778
|
i.slice(0, 50).forEach((o, a) => {
|
|
5765
5779
|
s[a * 3] = o[0], s[a * 3 + 1] = o[1], s[a * 3 + 2] = o[2];
|
|
5766
5780
|
}), e.redraw(r, () => {
|
|
5767
|
-
b.draw(r,
|
|
5781
|
+
b.draw(r, Ie.material, {
|
|
5768
5782
|
sampler: 0,
|
|
5769
5783
|
epsilon: this.epsilon,
|
|
5770
5784
|
originalColors: s
|
|
@@ -5772,7 +5786,7 @@ let De = class extends y {
|
|
|
5772
5786
|
});
|
|
5773
5787
|
}
|
|
5774
5788
|
};
|
|
5775
|
-
ta(
|
|
5789
|
+
ta(Ie, "material", new w({
|
|
5776
5790
|
vert: `precision mediump float;
|
|
5777
5791
|
attribute vec2 position;
|
|
5778
5792
|
attribute vec2 uv;
|
|
@@ -5805,22 +5819,22 @@ void main(void) {
|
|
|
5805
5819
|
gl_FragColor = color;
|
|
5806
5820
|
}`
|
|
5807
5821
|
}));
|
|
5808
|
-
|
|
5809
|
-
|
|
5810
|
-
],
|
|
5811
|
-
|
|
5812
|
-
|
|
5813
|
-
],
|
|
5814
|
-
|
|
5815
|
-
|
|
5816
|
-
],
|
|
5817
|
-
var
|
|
5822
|
+
sr([
|
|
5823
|
+
u({ default: () => [] })
|
|
5824
|
+
], Ie.prototype, "colors", 2);
|
|
5825
|
+
sr([
|
|
5826
|
+
u({ fallback: 0.5 })
|
|
5827
|
+
], Ie.prototype, "epsilon", 2);
|
|
5828
|
+
Ie = sr([
|
|
5829
|
+
g("ColorRemoveEffect")
|
|
5830
|
+
], Ie);
|
|
5831
|
+
var hs = Object.defineProperty, ra = Object.getOwnPropertyDescriptor, sa = (r, e, t) => e in r ? hs(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ir = (r, e, t, s) => {
|
|
5818
5832
|
for (var i = s > 1 ? void 0 : s ? ra(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
5819
5833
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
5820
|
-
return s && i &&
|
|
5834
|
+
return s && i && hs(e, t, i), i;
|
|
5821
5835
|
}, ia = (r, e, t) => sa(r, e + "", t);
|
|
5822
5836
|
const Ye = 50;
|
|
5823
|
-
let
|
|
5837
|
+
let Be = class extends x {
|
|
5824
5838
|
_color = new J();
|
|
5825
5839
|
constructor(r, e = []) {
|
|
5826
5840
|
super(), this.setProperties(r).append(e);
|
|
@@ -5844,7 +5858,7 @@ let Ie = class extends y {
|
|
|
5844
5858
|
t.slice(0, Ye).forEach(([a, n], h) => {
|
|
5845
5859
|
i[h * 3] = a[0], i[h * 3 + 1] = a[1], i[h * 3 + 2] = a[2], o[h * 3] = n[0], o[h * 3 + 1] = n[1], o[h * 3 + 2] = n[2];
|
|
5846
5860
|
}), e.redraw(r, () => {
|
|
5847
|
-
b.draw(r,
|
|
5861
|
+
b.draw(r, Be.material, {
|
|
5848
5862
|
sampler: 0,
|
|
5849
5863
|
epsilon: s,
|
|
5850
5864
|
originalColors: i,
|
|
@@ -5853,7 +5867,7 @@ let Ie = class extends y {
|
|
|
5853
5867
|
});
|
|
5854
5868
|
}
|
|
5855
5869
|
};
|
|
5856
|
-
ia(
|
|
5870
|
+
ia(Be, "material", new w({
|
|
5857
5871
|
vert: `precision mediump float;
|
|
5858
5872
|
attribute vec2 position;
|
|
5859
5873
|
attribute vec2 uv;
|
|
@@ -5893,16 +5907,18 @@ void main(void) {
|
|
|
5893
5907
|
}
|
|
5894
5908
|
}`
|
|
5895
5909
|
}));
|
|
5896
|
-
|
|
5897
|
-
|
|
5898
|
-
],
|
|
5899
|
-
|
|
5900
|
-
|
|
5901
|
-
],
|
|
5902
|
-
|
|
5903
|
-
|
|
5904
|
-
],
|
|
5905
|
-
const oa = `
|
|
5910
|
+
ir([
|
|
5911
|
+
u({ default: () => [] })
|
|
5912
|
+
], Be.prototype, "colors", 2);
|
|
5913
|
+
ir([
|
|
5914
|
+
u({ fallback: 0.05 })
|
|
5915
|
+
], Be.prototype, "epsilon", 2);
|
|
5916
|
+
Be = ir([
|
|
5917
|
+
g("ColorReplaceEffect")
|
|
5918
|
+
], Be);
|
|
5919
|
+
const oa = `precision highp float;
|
|
5920
|
+
|
|
5921
|
+
varying vec2 vUv;
|
|
5906
5922
|
uniform sampler2D texture;
|
|
5907
5923
|
uniform vec2 inputSize;
|
|
5908
5924
|
uniform vec2 zoom;
|
|
@@ -6051,12 +6067,12 @@ void main(void) {
|
|
|
6051
6067
|
gl_FragColor = color;
|
|
6052
6068
|
}
|
|
6053
6069
|
`;
|
|
6054
|
-
var
|
|
6070
|
+
var cs = Object.defineProperty, aa = Object.getOwnPropertyDescriptor, na = (r, e, t) => e in r ? cs(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ge = (r, e, t, s) => {
|
|
6055
6071
|
for (var i = s > 1 ? void 0 : s ? aa(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6056
6072
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6057
|
-
return s && i &&
|
|
6073
|
+
return s && i && cs(e, t, i), i;
|
|
6058
6074
|
}, la = (r, e, t) => na(r, e + "", t);
|
|
6059
|
-
let q = class extends
|
|
6075
|
+
let q = class extends x {
|
|
6060
6076
|
_watermark;
|
|
6061
6077
|
constructor(r, e = []) {
|
|
6062
6078
|
super(), this.setProperties(r).append(e);
|
|
@@ -6069,7 +6085,7 @@ let q = class extends y {
|
|
|
6069
6085
|
}
|
|
6070
6086
|
}
|
|
6071
6087
|
async _loadWatermark(r) {
|
|
6072
|
-
r ? this._watermark = await
|
|
6088
|
+
r ? this._watermark = await z.texture.load(r) : this._watermark = void 0;
|
|
6073
6089
|
}
|
|
6074
6090
|
_checkerboardStyleMap = {
|
|
6075
6091
|
grid: 1,
|
|
@@ -6110,9 +6126,8 @@ let q = class extends y {
|
|
|
6110
6126
|
});
|
|
6111
6127
|
}
|
|
6112
6128
|
};
|
|
6113
|
-
la(q, "material", new
|
|
6114
|
-
vert: `
|
|
6115
|
-
attribute vec2 position;
|
|
6129
|
+
la(q, "material", new w({
|
|
6130
|
+
vert: `attribute vec2 position;
|
|
6116
6131
|
attribute vec2 uv;
|
|
6117
6132
|
uniform mat3 projectionMatrix;
|
|
6118
6133
|
uniform mat3 viewMatrix;
|
|
@@ -6123,36 +6138,36 @@ void main() {
|
|
|
6123
6138
|
}`,
|
|
6124
6139
|
frag: oa
|
|
6125
6140
|
}));
|
|
6126
|
-
|
|
6127
|
-
|
|
6141
|
+
ge([
|
|
6142
|
+
u({ fallback: !1 })
|
|
6128
6143
|
], q.prototype, "checkerboard", 2);
|
|
6129
|
-
|
|
6130
|
-
|
|
6144
|
+
ge([
|
|
6145
|
+
u({ fallback: "grid" })
|
|
6131
6146
|
], q.prototype, "checkerboardStyle", 2);
|
|
6132
|
-
|
|
6133
|
-
|
|
6147
|
+
ge([
|
|
6148
|
+
u({ fallback: !1 })
|
|
6134
6149
|
], q.prototype, "pixelGrid", 2);
|
|
6135
|
-
|
|
6136
|
-
|
|
6150
|
+
ge([
|
|
6151
|
+
u()
|
|
6137
6152
|
], q.prototype, "watermark", 2);
|
|
6138
|
-
|
|
6139
|
-
|
|
6153
|
+
ge([
|
|
6154
|
+
u({ fallback: 100 })
|
|
6140
6155
|
], q.prototype, "watermarkWidth", 2);
|
|
6141
|
-
|
|
6142
|
-
|
|
6156
|
+
ge([
|
|
6157
|
+
u({ fallback: 0.05 })
|
|
6143
6158
|
], q.prototype, "watermarkAlpha", 2);
|
|
6144
|
-
|
|
6145
|
-
|
|
6159
|
+
ge([
|
|
6160
|
+
u({ fallback: 0.5236 })
|
|
6146
6161
|
], q.prototype, "watermarkRotation", 2);
|
|
6147
|
-
q =
|
|
6148
|
-
|
|
6162
|
+
q = ge([
|
|
6163
|
+
g("DrawboardEffect")
|
|
6149
6164
|
], q);
|
|
6150
|
-
var
|
|
6165
|
+
var us = Object.defineProperty, ha = Object.getOwnPropertyDescriptor, ca = (r, e, t) => e in r ? us(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, or = (r, e, t, s) => {
|
|
6151
6166
|
for (var i = s > 1 ? void 0 : s ? ha(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6152
6167
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6153
|
-
return s && i &&
|
|
6154
|
-
},
|
|
6155
|
-
const
|
|
6168
|
+
return s && i && us(e, t, i), i;
|
|
6169
|
+
}, ds = (r, e, t) => ca(r, typeof e != "symbol" ? e + "" : e, t);
|
|
6170
|
+
const fs = `varying vec2 vUv[9];
|
|
6156
6171
|
uniform sampler2D sampler;
|
|
6157
6172
|
|
|
6158
6173
|
void main(void) {
|
|
@@ -6187,7 +6202,7 @@ void main(void) {
|
|
|
6187
6202
|
gl_FragColor += texture2D(sampler, vUv[8]) * 0.028532;
|
|
6188
6203
|
}
|
|
6189
6204
|
}`;
|
|
6190
|
-
let ae = class extends
|
|
6205
|
+
let ae = class extends x {
|
|
6191
6206
|
constructor(r, e = []) {
|
|
6192
6207
|
super(), this.setProperties(r).append(e);
|
|
6193
6208
|
}
|
|
@@ -6209,7 +6224,7 @@ let ae = class extends y {
|
|
|
6209
6224
|
});
|
|
6210
6225
|
}
|
|
6211
6226
|
};
|
|
6212
|
-
|
|
6227
|
+
ds(ae, "materialX", new w({
|
|
6213
6228
|
vert: `attribute vec2 position;
|
|
6214
6229
|
attribute vec2 uv;
|
|
6215
6230
|
uniform float uStrength;
|
|
@@ -6227,9 +6242,9 @@ void main(void) {
|
|
|
6227
6242
|
vUv[7] = uv + vec2(3.0 * uStrength, 0.0);
|
|
6228
6243
|
vUv[8] = uv + vec2(4.0 * uStrength, 0.0);
|
|
6229
6244
|
}`,
|
|
6230
|
-
frag:
|
|
6245
|
+
frag: fs
|
|
6231
6246
|
}));
|
|
6232
|
-
|
|
6247
|
+
ds(ae, "materialY", new w({
|
|
6233
6248
|
vert: `attribute vec2 position;
|
|
6234
6249
|
attribute vec2 uv;
|
|
6235
6250
|
uniform float uStrength;
|
|
@@ -6247,23 +6262,23 @@ void main(void) {
|
|
|
6247
6262
|
vUv[7] = uv + vec2(0.0, 3.0 * uStrength);
|
|
6248
6263
|
vUv[8] = uv + vec2(0.0, 4.0 * uStrength);
|
|
6249
6264
|
}`,
|
|
6250
|
-
frag:
|
|
6265
|
+
frag: fs
|
|
6251
6266
|
}));
|
|
6252
|
-
|
|
6253
|
-
|
|
6267
|
+
or([
|
|
6268
|
+
u({ fallback: 4 })
|
|
6254
6269
|
], ae.prototype, "strength", 2);
|
|
6255
|
-
|
|
6256
|
-
|
|
6270
|
+
or([
|
|
6271
|
+
u({ fallback: 3 })
|
|
6257
6272
|
], ae.prototype, "quality", 2);
|
|
6258
|
-
ae =
|
|
6259
|
-
|
|
6273
|
+
ae = or([
|
|
6274
|
+
g("GaussianBlurEffect")
|
|
6260
6275
|
], ae);
|
|
6261
|
-
var
|
|
6276
|
+
var ps = Object.defineProperty, ua = Object.getOwnPropertyDescriptor, da = (r, e, t) => e in r ? ps(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, Ve = (r, e, t, s) => {
|
|
6262
6277
|
for (var i = s > 1 ? void 0 : s ? ua(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6263
6278
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6264
|
-
return s && i &&
|
|
6279
|
+
return s && i && ps(e, t, i), i;
|
|
6265
6280
|
}, fa = (r, e, t) => da(r, e + "", t);
|
|
6266
|
-
let Q = class extends
|
|
6281
|
+
let Q = class extends x {
|
|
6267
6282
|
blurEffect = new ae();
|
|
6268
6283
|
viewport3 = new j();
|
|
6269
6284
|
_color = new J();
|
|
@@ -6288,7 +6303,7 @@ let Q = class extends y {
|
|
|
6288
6303
|
});
|
|
6289
6304
|
}
|
|
6290
6305
|
};
|
|
6291
|
-
fa(Q, "material", new
|
|
6306
|
+
fa(Q, "material", new w({
|
|
6292
6307
|
vert: `precision mediump float;
|
|
6293
6308
|
attribute vec2 position;
|
|
6294
6309
|
attribute vec2 uv;
|
|
@@ -6313,29 +6328,29 @@ void main(void) {
|
|
|
6313
6328
|
}`
|
|
6314
6329
|
}));
|
|
6315
6330
|
Ve([
|
|
6316
|
-
|
|
6331
|
+
u({ fallback: "#000000FF" })
|
|
6317
6332
|
], Q.prototype, "color", 2);
|
|
6318
6333
|
Ve([
|
|
6319
|
-
|
|
6334
|
+
u({ fallback: 4 })
|
|
6320
6335
|
], Q.prototype, "blur", 2);
|
|
6321
6336
|
Ve([
|
|
6322
|
-
|
|
6337
|
+
u({ fallback: 4 })
|
|
6323
6338
|
], Q.prototype, "offsetX", 2);
|
|
6324
6339
|
Ve([
|
|
6325
|
-
|
|
6340
|
+
u({ fallback: 4 })
|
|
6326
6341
|
], Q.prototype, "offsetY", 2);
|
|
6327
6342
|
Ve([
|
|
6328
|
-
|
|
6343
|
+
u({ fallback: !1 })
|
|
6329
6344
|
], Q.prototype, "shadowOnly", 2);
|
|
6330
6345
|
Q = Ve([
|
|
6331
|
-
|
|
6346
|
+
g("DropShadowEffect")
|
|
6332
6347
|
], Q);
|
|
6333
|
-
var
|
|
6348
|
+
var _s = Object.defineProperty, pa = Object.getOwnPropertyDescriptor, _a = (r, e, t) => e in r ? _s(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ms = (r, e, t, s) => {
|
|
6334
6349
|
for (var i = s > 1 ? void 0 : s ? pa(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6335
6350
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6336
|
-
return s && i &&
|
|
6351
|
+
return s && i && _s(e, t, i), i;
|
|
6337
6352
|
}, ma = (r, e, t) => _a(r, e + "", t);
|
|
6338
|
-
let Qe = class extends
|
|
6353
|
+
let Qe = class extends x {
|
|
6339
6354
|
constructor(r, e = []) {
|
|
6340
6355
|
super(), this.setProperties(r).append(e);
|
|
6341
6356
|
}
|
|
@@ -6349,7 +6364,7 @@ let Qe = class extends y {
|
|
|
6349
6364
|
});
|
|
6350
6365
|
}
|
|
6351
6366
|
};
|
|
6352
|
-
ma(Qe, "material", new
|
|
6367
|
+
ma(Qe, "material", new w({
|
|
6353
6368
|
vert: `precision mediump float;
|
|
6354
6369
|
attribute vec2 position;
|
|
6355
6370
|
attribute vec2 uv;
|
|
@@ -6375,18 +6390,18 @@ void main(void) {
|
|
|
6375
6390
|
gl_FragColor = vec4(color.rgb * alpha, alpha);
|
|
6376
6391
|
}`
|
|
6377
6392
|
}));
|
|
6378
|
-
|
|
6379
|
-
|
|
6393
|
+
ms([
|
|
6394
|
+
u({ fallback: 5 })
|
|
6380
6395
|
], Qe.prototype, "strength", 2);
|
|
6381
|
-
Qe =
|
|
6382
|
-
|
|
6396
|
+
Qe = ms([
|
|
6397
|
+
g("EmbossEffect")
|
|
6383
6398
|
], Qe);
|
|
6384
|
-
var
|
|
6399
|
+
var gs = Object.defineProperty, ga = Object.getOwnPropertyDescriptor, va = (r, e, t) => e in r ? gs(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ee = (r, e, t, s) => {
|
|
6385
6400
|
for (var i = s > 1 ? void 0 : s ? ga(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6386
6401
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6387
|
-
return s && i &&
|
|
6402
|
+
return s && i && gs(e, t, i), i;
|
|
6388
6403
|
}, ba = (r, e, t) => va(r, e + "", t);
|
|
6389
|
-
let
|
|
6404
|
+
let N = class extends x {
|
|
6390
6405
|
_canvas;
|
|
6391
6406
|
_texture;
|
|
6392
6407
|
_sizes;
|
|
@@ -6410,7 +6425,7 @@ let z = class extends y {
|
|
|
6410
6425
|
this._needsRedraw || (this._needsRedraw = !0, this.redraw());
|
|
6411
6426
|
const t = e.width, s = e.height, i = this.direction * (Math.PI / 180), o = Math.sin(i), a = Math.cos(i);
|
|
6412
6427
|
e.redraw(r, () => {
|
|
6413
|
-
this._texture.activate(r, 1), b.draw(r,
|
|
6428
|
+
this._texture.activate(r, 1), b.draw(r, N.material, {
|
|
6414
6429
|
sampler: 0,
|
|
6415
6430
|
filterClamp: [0, 0, 1, 1],
|
|
6416
6431
|
filterArea: [t, s, 0, 0],
|
|
@@ -6429,7 +6444,7 @@ let z = class extends y {
|
|
|
6429
6444
|
});
|
|
6430
6445
|
}
|
|
6431
6446
|
};
|
|
6432
|
-
ba(
|
|
6447
|
+
ba(N, "material", new w({
|
|
6433
6448
|
vert: `precision mediump float;
|
|
6434
6449
|
attribute vec2 position;
|
|
6435
6450
|
attribute vec2 uv;
|
|
@@ -6535,39 +6550,39 @@ void main(void) {
|
|
|
6535
6550
|
}`
|
|
6536
6551
|
}));
|
|
6537
6552
|
ee([
|
|
6538
|
-
|
|
6539
|
-
],
|
|
6553
|
+
u({ fallback: 10 })
|
|
6554
|
+
], N.prototype, "slices", 2);
|
|
6540
6555
|
ee([
|
|
6541
|
-
|
|
6542
|
-
],
|
|
6556
|
+
u({ fallback: 512 })
|
|
6557
|
+
], N.prototype, "sampleSize", 2);
|
|
6543
6558
|
ee([
|
|
6544
|
-
|
|
6545
|
-
],
|
|
6559
|
+
u({ fallback: 100 })
|
|
6560
|
+
], N.prototype, "offset", 2);
|
|
6546
6561
|
ee([
|
|
6547
|
-
|
|
6548
|
-
],
|
|
6562
|
+
u({ fallback: 0 })
|
|
6563
|
+
], N.prototype, "direction", 2);
|
|
6549
6564
|
ee([
|
|
6550
|
-
|
|
6551
|
-
],
|
|
6565
|
+
u({ fallback: 2 })
|
|
6566
|
+
], N.prototype, "fillMode", 2);
|
|
6552
6567
|
ee([
|
|
6553
|
-
|
|
6554
|
-
],
|
|
6568
|
+
u({ fallback: 0 })
|
|
6569
|
+
], N.prototype, "seed", 2);
|
|
6555
6570
|
ee([
|
|
6556
|
-
|
|
6557
|
-
],
|
|
6571
|
+
u({ default: () => [2, 2] })
|
|
6572
|
+
], N.prototype, "red", 2);
|
|
6558
6573
|
ee([
|
|
6559
|
-
|
|
6560
|
-
],
|
|
6574
|
+
u({ default: () => [-10, 4] })
|
|
6575
|
+
], N.prototype, "green", 2);
|
|
6561
6576
|
ee([
|
|
6562
|
-
|
|
6563
|
-
],
|
|
6564
|
-
|
|
6565
|
-
|
|
6566
|
-
],
|
|
6567
|
-
var
|
|
6577
|
+
u({ default: () => [10, -4] })
|
|
6578
|
+
], N.prototype, "blue", 2);
|
|
6579
|
+
N = ee([
|
|
6580
|
+
g("GlitchEffect")
|
|
6581
|
+
], N);
|
|
6582
|
+
var vs = Object.defineProperty, ya = Object.getOwnPropertyDescriptor, xa = (r, e, t) => e in r ? vs(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ve = (r, e, t, s) => {
|
|
6568
6583
|
for (var i = s > 1 ? void 0 : s ? ya(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6569
6584
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6570
|
-
return s && i &&
|
|
6585
|
+
return s && i && vs(e, t, i), i;
|
|
6571
6586
|
}, wa = (r, e, t) => xa(r, e + "", t);
|
|
6572
6587
|
const Pa = `vec3 mod289(vec3 x)
|
|
6573
6588
|
{
|
|
@@ -6664,7 +6679,7 @@ float turb(vec3 P, vec3 rep, float lacunarity, float gain)
|
|
|
6664
6679
|
}
|
|
6665
6680
|
return abs(sum);
|
|
6666
6681
|
}`;
|
|
6667
|
-
let X = class extends
|
|
6682
|
+
let X = class extends x {
|
|
6668
6683
|
constructor(r, e = []) {
|
|
6669
6684
|
super(), this.setProperties(r).append(e);
|
|
6670
6685
|
}
|
|
@@ -6688,7 +6703,7 @@ let X = class extends y {
|
|
|
6688
6703
|
});
|
|
6689
6704
|
}
|
|
6690
6705
|
};
|
|
6691
|
-
wa(X, "material", new
|
|
6706
|
+
wa(X, "material", new w({
|
|
6692
6707
|
vert: `precision mediump float;
|
|
6693
6708
|
attribute vec2 position;
|
|
6694
6709
|
attribute vec2 uv;
|
|
@@ -6741,29 +6756,29 @@ void main(void) {
|
|
|
6741
6756
|
gl_FragColor = vec4(color.rgb + mist.rgb, color.a);
|
|
6742
6757
|
}`
|
|
6743
6758
|
}));
|
|
6744
|
-
|
|
6745
|
-
|
|
6759
|
+
ve([
|
|
6760
|
+
u({ fallback: 0 })
|
|
6746
6761
|
], X.prototype, "time", 2);
|
|
6747
|
-
|
|
6748
|
-
|
|
6762
|
+
ve([
|
|
6763
|
+
u({ fallback: 30 })
|
|
6749
6764
|
], X.prototype, "angle", 2);
|
|
6750
|
-
|
|
6751
|
-
|
|
6765
|
+
ve([
|
|
6766
|
+
u({ fallback: 0.5 })
|
|
6752
6767
|
], X.prototype, "gain", 2);
|
|
6753
|
-
|
|
6754
|
-
|
|
6768
|
+
ve([
|
|
6769
|
+
u({ fallback: 2.5 })
|
|
6755
6770
|
], X.prototype, "lacunarity", 2);
|
|
6756
|
-
|
|
6757
|
-
|
|
6771
|
+
ve([
|
|
6772
|
+
u({ fallback: !0 })
|
|
6758
6773
|
], X.prototype, "parallel", 2);
|
|
6759
|
-
|
|
6760
|
-
|
|
6774
|
+
ve([
|
|
6775
|
+
u({ default: () => [0, 0] })
|
|
6761
6776
|
], X.prototype, "center", 2);
|
|
6762
|
-
|
|
6763
|
-
|
|
6777
|
+
ve([
|
|
6778
|
+
u({ fallback: 1 })
|
|
6764
6779
|
], X.prototype, "alpha", 2);
|
|
6765
|
-
X =
|
|
6766
|
-
|
|
6780
|
+
X = ve([
|
|
6781
|
+
g("GodrayEffect")
|
|
6767
6782
|
], X);
|
|
6768
6783
|
var Ta = Object.defineProperty, Ea = Object.getOwnPropertyDescriptor, Ut = (r, e, t, s) => {
|
|
6769
6784
|
for (var i = s > 1 ? void 0 : s ? Ea(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
@@ -6796,10 +6811,10 @@ void main(void) {
|
|
|
6796
6811
|
color *= 0.25;
|
|
6797
6812
|
gl_FragColor = color;
|
|
6798
6813
|
}`;
|
|
6799
|
-
let et = class extends
|
|
6814
|
+
let et = class extends x {
|
|
6800
6815
|
_kernels = [0];
|
|
6801
6816
|
constructor(r, e = []) {
|
|
6802
|
-
super(), this.material = new
|
|
6817
|
+
super(), this.material = new w({
|
|
6803
6818
|
vert: `precision mediump float;
|
|
6804
6819
|
attribute vec2 position;
|
|
6805
6820
|
attribute vec2 uv;
|
|
@@ -6848,28 +6863,28 @@ void main() {
|
|
|
6848
6863
|
}
|
|
6849
6864
|
};
|
|
6850
6865
|
Ut([
|
|
6851
|
-
|
|
6866
|
+
u({ fallback: 4 })
|
|
6852
6867
|
], et.prototype, "strength", 2);
|
|
6853
6868
|
Ut([
|
|
6854
|
-
|
|
6869
|
+
u({ fallback: 3 })
|
|
6855
6870
|
], et.prototype, "quality", 2);
|
|
6856
6871
|
Ut([
|
|
6857
|
-
|
|
6872
|
+
u({ default: () => [1, 1] })
|
|
6858
6873
|
], et.prototype, "pixelSize", 2);
|
|
6859
6874
|
et = Ut([
|
|
6860
|
-
|
|
6875
|
+
g("KawaseBlurEffect")
|
|
6861
6876
|
], et);
|
|
6862
|
-
var
|
|
6877
|
+
var bs = Object.defineProperty, Aa = Object.getOwnPropertyDescriptor, Ra = (r, e, t) => e in r ? bs(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ar = (r, e, t, s) => {
|
|
6863
6878
|
for (var i = s > 1 ? void 0 : s ? Aa(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6864
6879
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6865
|
-
return s && i &&
|
|
6880
|
+
return s && i && bs(e, t, i), i;
|
|
6866
6881
|
}, Oa = (r, e, t) => Ra(r, e + "", t);
|
|
6867
|
-
let
|
|
6882
|
+
let Ee = class extends x {
|
|
6868
6883
|
constructor(r, e = []) {
|
|
6869
6884
|
super(), this.setProperties(r).append(e);
|
|
6870
6885
|
}
|
|
6871
6886
|
async load() {
|
|
6872
|
-
this.texture = void 0, this.src && (this.texture = await
|
|
6887
|
+
this.texture = void 0, this.src && (this.texture = await z.texture.load(this.src));
|
|
6873
6888
|
}
|
|
6874
6889
|
_updateProperty(r, e, t) {
|
|
6875
6890
|
switch (super._updateProperty(r, e, t), r) {
|
|
@@ -6883,7 +6898,7 @@ let Te = class extends y {
|
|
|
6883
6898
|
}
|
|
6884
6899
|
apply(r, e, t) {
|
|
6885
6900
|
this.texture && t.targetArea && e.redraw(r, () => {
|
|
6886
|
-
this.texture.activate(r, 1), b.draw(r,
|
|
6901
|
+
this.texture.activate(r, 1), b.draw(r, Ee.material, {
|
|
6887
6902
|
sampler: 0,
|
|
6888
6903
|
mask: 1,
|
|
6889
6904
|
area: t.targetArea,
|
|
@@ -6892,7 +6907,7 @@ let Te = class extends y {
|
|
|
6892
6907
|
});
|
|
6893
6908
|
}
|
|
6894
6909
|
};
|
|
6895
|
-
Oa(
|
|
6910
|
+
Oa(Ee, "material", new w({
|
|
6896
6911
|
vert: `precision mediump float;
|
|
6897
6912
|
attribute vec2 position;
|
|
6898
6913
|
attribute vec2 uv;
|
|
@@ -6939,20 +6954,20 @@ void main(void) {
|
|
|
6939
6954
|
}
|
|
6940
6955
|
}`
|
|
6941
6956
|
}));
|
|
6942
|
-
|
|
6943
|
-
|
|
6944
|
-
],
|
|
6945
|
-
|
|
6946
|
-
|
|
6947
|
-
],
|
|
6948
|
-
|
|
6949
|
-
|
|
6950
|
-
],
|
|
6951
|
-
var
|
|
6952
|
-
for (var i = s > 1 ? void 0 : s ?
|
|
6957
|
+
ar([
|
|
6958
|
+
u({ internal: !0 })
|
|
6959
|
+
], Ee.prototype, "texture", 2);
|
|
6960
|
+
ar([
|
|
6961
|
+
u({ fallback: "" })
|
|
6962
|
+
], Ee.prototype, "src", 2);
|
|
6963
|
+
Ee = ar([
|
|
6964
|
+
g("MaskEffect")
|
|
6965
|
+
], Ee);
|
|
6966
|
+
var ys = Object.defineProperty, Ma = Object.getOwnPropertyDescriptor, ka = (r, e, t) => e in r ? ys(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, be = (r, e, t, s) => {
|
|
6967
|
+
for (var i = s > 1 ? void 0 : s ? Ma(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
6953
6968
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
6954
|
-
return s && i &&
|
|
6955
|
-
},
|
|
6969
|
+
return s && i && ys(e, t, i), i;
|
|
6970
|
+
}, xs = (r, e, t) => ka(r, typeof e != "symbol" ? e + "" : e, t);
|
|
6956
6971
|
const Ua = `precision highp float;
|
|
6957
6972
|
varying vec2 vUv;
|
|
6958
6973
|
uniform sampler2D sampler;
|
|
@@ -6988,18 +7003,18 @@ void main(void) {
|
|
|
6988
7003
|
vec4 outlineColor = vec4(vec3(uColor) * outlineAlpha, outlineAlpha);
|
|
6989
7004
|
gl_FragColor = contentColor + outlineColor;
|
|
6990
7005
|
}`;
|
|
6991
|
-
let
|
|
7006
|
+
let D = class extends x {
|
|
6992
7007
|
static getAngleStep(r) {
|
|
6993
7008
|
return Number.parseFloat(
|
|
6994
7009
|
(Math.PI * 2 / Math.max(
|
|
6995
|
-
r *
|
|
6996
|
-
|
|
7010
|
+
r * D.MAX_SAMPLES,
|
|
7011
|
+
D.MIN_SAMPLES
|
|
6997
7012
|
)).toFixed(7)
|
|
6998
7013
|
);
|
|
6999
7014
|
}
|
|
7000
7015
|
_color = new J();
|
|
7001
7016
|
constructor(r, e = []) {
|
|
7002
|
-
super(), this.setProperties(r).append(e), this.material = new
|
|
7017
|
+
super(), this.setProperties(r).append(e), this.material = new w({
|
|
7003
7018
|
vert: `precision mediump float;
|
|
7004
7019
|
attribute vec2 position;
|
|
7005
7020
|
attribute vec2 uv;
|
|
@@ -7010,7 +7025,7 @@ void main() {
|
|
|
7010
7025
|
}`,
|
|
7011
7026
|
frag: Ua.replace(
|
|
7012
7027
|
/\{ANGLE_STEP\}/,
|
|
7013
|
-
|
|
7028
|
+
D.getAngleStep(this.quality).toFixed(7)
|
|
7014
7029
|
)
|
|
7015
7030
|
});
|
|
7016
7031
|
}
|
|
@@ -7024,45 +7039,45 @@ void main() {
|
|
|
7024
7039
|
],
|
|
7025
7040
|
uColor: this._color.toArray().slice(0, 3),
|
|
7026
7041
|
uAlpha: this.opacity !== 1 ? this.opacity : this._color.a,
|
|
7027
|
-
uAngleStep:
|
|
7042
|
+
uAngleStep: D.getAngleStep(this.quality),
|
|
7028
7043
|
uKnockout: this.knockout ? 1 : 0,
|
|
7029
7044
|
uInputClamp: [0, 0, 1, 1]
|
|
7030
7045
|
});
|
|
7031
7046
|
});
|
|
7032
7047
|
}
|
|
7033
7048
|
};
|
|
7034
|
-
|
|
7035
|
-
|
|
7036
|
-
|
|
7037
|
-
|
|
7038
|
-
],
|
|
7039
|
-
|
|
7040
|
-
|
|
7041
|
-
],
|
|
7042
|
-
|
|
7043
|
-
|
|
7044
|
-
],
|
|
7045
|
-
|
|
7046
|
-
|
|
7047
|
-
],
|
|
7048
|
-
|
|
7049
|
-
|
|
7050
|
-
],
|
|
7051
|
-
|
|
7052
|
-
|
|
7053
|
-
],
|
|
7054
|
-
|
|
7055
|
-
|
|
7056
|
-
],
|
|
7057
|
-
|
|
7058
|
-
|
|
7059
|
-
],
|
|
7060
|
-
var
|
|
7049
|
+
xs(D, "MIN_SAMPLES", 1);
|
|
7050
|
+
xs(D, "MAX_SAMPLES", 100);
|
|
7051
|
+
be([
|
|
7052
|
+
u({ fallback: "#000000ff" })
|
|
7053
|
+
], D.prototype, "color", 2);
|
|
7054
|
+
be([
|
|
7055
|
+
u({ fallback: 1 })
|
|
7056
|
+
], D.prototype, "width", 2);
|
|
7057
|
+
be([
|
|
7058
|
+
u({ fallback: "solid" })
|
|
7059
|
+
], D.prototype, "style", 2);
|
|
7060
|
+
be([
|
|
7061
|
+
u()
|
|
7062
|
+
], D.prototype, "image", 2);
|
|
7063
|
+
be([
|
|
7064
|
+
u({ fallback: 1 })
|
|
7065
|
+
], D.prototype, "opacity", 2);
|
|
7066
|
+
be([
|
|
7067
|
+
u({ fallback: 0.1 })
|
|
7068
|
+
], D.prototype, "quality", 2);
|
|
7069
|
+
be([
|
|
7070
|
+
u({ fallback: !1 })
|
|
7071
|
+
], D.prototype, "knockout", 2);
|
|
7072
|
+
D = be([
|
|
7073
|
+
g("OutlineEffect")
|
|
7074
|
+
], D);
|
|
7075
|
+
var ws = Object.defineProperty, Da = Object.getOwnPropertyDescriptor, Ia = (r, e, t) => e in r ? ws(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, Ps = (r, e, t, s) => {
|
|
7061
7076
|
for (var i = s > 1 ? void 0 : s ? Da(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
7062
7077
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
7063
|
-
return s && i &&
|
|
7078
|
+
return s && i && ws(e, t, i), i;
|
|
7064
7079
|
}, Ba = (r, e, t) => Ia(r, e + "", t);
|
|
7065
|
-
let tt = class extends
|
|
7080
|
+
let tt = class extends x {
|
|
7066
7081
|
constructor(r, e = []) {
|
|
7067
7082
|
super(), this.setProperties(r).append(e);
|
|
7068
7083
|
}
|
|
@@ -7076,7 +7091,7 @@ let tt = class extends y {
|
|
|
7076
7091
|
});
|
|
7077
7092
|
}
|
|
7078
7093
|
};
|
|
7079
|
-
Ba(tt, "material", new
|
|
7094
|
+
Ba(tt, "material", new w({
|
|
7080
7095
|
vert: `precision mediump float;
|
|
7081
7096
|
attribute vec2 position;
|
|
7082
7097
|
attribute vec2 uv;
|
|
@@ -7113,18 +7128,18 @@ void main(void) {
|
|
|
7113
7128
|
gl_FragColor = texture2D(sampler, coord);
|
|
7114
7129
|
}`
|
|
7115
7130
|
}));
|
|
7116
|
-
|
|
7117
|
-
|
|
7131
|
+
Ps([
|
|
7132
|
+
u({ fallback: 10 })
|
|
7118
7133
|
], tt.prototype, "strength", 2);
|
|
7119
|
-
tt =
|
|
7120
|
-
|
|
7134
|
+
tt = Ps([
|
|
7135
|
+
g("PixelateEffect")
|
|
7121
7136
|
], tt);
|
|
7122
|
-
var
|
|
7137
|
+
var Ts = Object.defineProperty, za = Object.getOwnPropertyDescriptor, Na = (r, e, t) => e in r ? Ts(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, ct = (r, e, t, s) => {
|
|
7123
7138
|
for (var i = s > 1 ? void 0 : s ? za(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
7124
7139
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
7125
|
-
return s && i &&
|
|
7140
|
+
return s && i && Ts(e, t, i), i;
|
|
7126
7141
|
}, La = (r, e, t) => Na(r, e + "", t);
|
|
7127
|
-
let de = class extends
|
|
7142
|
+
let de = class extends x {
|
|
7128
7143
|
constructor(r, e = []) {
|
|
7129
7144
|
super(), this.setProperties(r).append(e);
|
|
7130
7145
|
}
|
|
@@ -7145,7 +7160,7 @@ let de = class extends y {
|
|
|
7145
7160
|
});
|
|
7146
7161
|
}
|
|
7147
7162
|
};
|
|
7148
|
-
La(de, "material", new
|
|
7163
|
+
La(de, "material", new w({
|
|
7149
7164
|
vert: `attribute vec2 position;
|
|
7150
7165
|
attribute vec2 uv;
|
|
7151
7166
|
varying vec2 vUv;
|
|
@@ -7230,19 +7245,19 @@ void main() {
|
|
|
7230
7245
|
}`
|
|
7231
7246
|
}));
|
|
7232
7247
|
ct([
|
|
7233
|
-
|
|
7248
|
+
u()
|
|
7234
7249
|
], de.prototype, "center", 2);
|
|
7235
7250
|
ct([
|
|
7236
|
-
|
|
7251
|
+
u({ fallback: 20 })
|
|
7237
7252
|
], de.prototype, "innerRadius", 2);
|
|
7238
7253
|
ct([
|
|
7239
|
-
|
|
7254
|
+
u({ fallback: -1 })
|
|
7240
7255
|
], de.prototype, "radius", 2);
|
|
7241
7256
|
ct([
|
|
7242
|
-
|
|
7257
|
+
u({ fallback: 0.1 })
|
|
7243
7258
|
], de.prototype, "strength", 2);
|
|
7244
7259
|
de = ct([
|
|
7245
|
-
|
|
7260
|
+
g("ZoomBlurEffect")
|
|
7246
7261
|
], de);
|
|
7247
7262
|
function Tt(r, e) {
|
|
7248
7263
|
let t = !1;
|
|
@@ -7251,11 +7266,11 @@ function Tt(r, e) {
|
|
|
7251
7266
|
const {
|
|
7252
7267
|
left: h = 0,
|
|
7253
7268
|
top: l = 0,
|
|
7254
|
-
right:
|
|
7269
|
+
right: c = 0,
|
|
7255
7270
|
bottom: d = 0
|
|
7256
7271
|
} = r.cropRect;
|
|
7257
7272
|
n.scale(
|
|
7258
|
-
Math.abs(1 - (h +
|
|
7273
|
+
Math.abs(1 - (h + c)),
|
|
7259
7274
|
Math.abs(1 - (l + d))
|
|
7260
7275
|
).translate(h, l), t = !0;
|
|
7261
7276
|
}
|
|
@@ -7263,21 +7278,21 @@ function Tt(r, e) {
|
|
|
7263
7278
|
const {
|
|
7264
7279
|
translateX: h = 0,
|
|
7265
7280
|
translateY: l = 0,
|
|
7266
|
-
scaleX:
|
|
7281
|
+
scaleX: c = 1,
|
|
7267
7282
|
scaleY: d = 1
|
|
7268
7283
|
// flip, TODO
|
|
7269
7284
|
// alignment, TODO
|
|
7270
7285
|
} = r.tile;
|
|
7271
|
-
n.translate(-h / o, -l / a).scale(1 /
|
|
7286
|
+
n.translate(-h / o, -l / a).scale(1 / c, 1 / d), t = !0;
|
|
7272
7287
|
} else if (r.stretchRect) {
|
|
7273
7288
|
const {
|
|
7274
7289
|
left: h = 0,
|
|
7275
7290
|
top: l = 0,
|
|
7276
|
-
right:
|
|
7291
|
+
right: c = 0,
|
|
7277
7292
|
bottom: d = 0
|
|
7278
7293
|
} = r.stretchRect;
|
|
7279
7294
|
n.scale(
|
|
7280
|
-
Math.abs(1 - (-h + -
|
|
7295
|
+
Math.abs(1 - (-h + -c)),
|
|
7281
7296
|
Math.abs(1 - (-l + -d))
|
|
7282
7297
|
).translate(-h, -l), t = !0;
|
|
7283
7298
|
}
|
|
@@ -7288,7 +7303,7 @@ var Fa = Object.defineProperty, Y = (r, e, t, s) => {
|
|
|
7288
7303
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
7289
7304
|
return i && Fa(e, t, i), i;
|
|
7290
7305
|
};
|
|
7291
|
-
class
|
|
7306
|
+
class I extends pe {
|
|
7292
7307
|
constructor(e) {
|
|
7293
7308
|
super(), this.parent = e;
|
|
7294
7309
|
}
|
|
@@ -7299,7 +7314,7 @@ class D extends pe {
|
|
|
7299
7314
|
}
|
|
7300
7315
|
setProperties(e) {
|
|
7301
7316
|
return this._setProperties(
|
|
7302
|
-
|
|
7317
|
+
F(e) ? void 0 : $s(e)
|
|
7303
7318
|
);
|
|
7304
7319
|
}
|
|
7305
7320
|
_updateProperty(e, t, s) {
|
|
@@ -7322,11 +7337,18 @@ class D extends pe {
|
|
|
7322
7337
|
}
|
|
7323
7338
|
}
|
|
7324
7339
|
async loadTexture() {
|
|
7325
|
-
this.linearGradient || this.radialGradient
|
|
7326
|
-
this.
|
|
7327
|
-
|
|
7328
|
-
|
|
7329
|
-
|
|
7340
|
+
if (this.linearGradient || this.radialGradient)
|
|
7341
|
+
this.texture = new kt(
|
|
7342
|
+
this.linearGradient ?? this.radialGradient,
|
|
7343
|
+
this.parent.size.width,
|
|
7344
|
+
this.parent.size.height
|
|
7345
|
+
);
|
|
7346
|
+
else if (!F(this.image)) {
|
|
7347
|
+
this.parent.tree?.log(`load image ${this.image}`);
|
|
7348
|
+
let e = this.image.split("?")[0].endsWith(".gif");
|
|
7349
|
+
const t = await z.loadBy(this.image);
|
|
7350
|
+
e || (e = t.type.startsWith("image/gif") ?? !1), e ? this.animatedTexture = await z.gif.load(t) : this.texture = await z.texture.load(t);
|
|
7351
|
+
}
|
|
7330
7352
|
}
|
|
7331
7353
|
async _updateTexture() {
|
|
7332
7354
|
await this.loadTexture(), this.parent.requestRedraw();
|
|
@@ -7368,47 +7390,47 @@ class D extends pe {
|
|
|
7368
7390
|
}
|
|
7369
7391
|
}
|
|
7370
7392
|
Y([
|
|
7371
|
-
|
|
7372
|
-
],
|
|
7393
|
+
u({ fallback: !0 })
|
|
7394
|
+
], I.prototype, "enabled");
|
|
7373
7395
|
Y([
|
|
7374
|
-
|
|
7375
|
-
],
|
|
7396
|
+
u()
|
|
7397
|
+
], I.prototype, "color");
|
|
7376
7398
|
Y([
|
|
7377
|
-
|
|
7378
|
-
],
|
|
7399
|
+
u()
|
|
7400
|
+
], I.prototype, "image");
|
|
7379
7401
|
Y([
|
|
7380
|
-
|
|
7381
|
-
],
|
|
7402
|
+
u()
|
|
7403
|
+
], I.prototype, "linearGradient");
|
|
7382
7404
|
Y([
|
|
7383
|
-
|
|
7384
|
-
],
|
|
7405
|
+
u()
|
|
7406
|
+
], I.prototype, "radialGradient");
|
|
7385
7407
|
Y([
|
|
7386
|
-
|
|
7387
|
-
],
|
|
7408
|
+
u()
|
|
7409
|
+
], I.prototype, "cropRect");
|
|
7388
7410
|
Y([
|
|
7389
|
-
|
|
7390
|
-
],
|
|
7411
|
+
u()
|
|
7412
|
+
], I.prototype, "stretchRect");
|
|
7391
7413
|
Y([
|
|
7392
|
-
|
|
7393
|
-
],
|
|
7414
|
+
u()
|
|
7415
|
+
], I.prototype, "dpi");
|
|
7394
7416
|
Y([
|
|
7395
|
-
|
|
7396
|
-
],
|
|
7417
|
+
u()
|
|
7418
|
+
], I.prototype, "rotateWithShape");
|
|
7397
7419
|
Y([
|
|
7398
|
-
|
|
7399
|
-
],
|
|
7420
|
+
u()
|
|
7421
|
+
], I.prototype, "tile");
|
|
7400
7422
|
Y([
|
|
7401
|
-
|
|
7402
|
-
],
|
|
7423
|
+
u()
|
|
7424
|
+
], I.prototype, "opacity");
|
|
7403
7425
|
var $a = Object.defineProperty, Va = (r, e, t, s) => {
|
|
7404
7426
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
7405
7427
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
7406
7428
|
return i && $a(e, t, i), i;
|
|
7407
7429
|
};
|
|
7408
|
-
class
|
|
7430
|
+
class Es extends I {
|
|
7409
7431
|
setProperties(e) {
|
|
7410
7432
|
return super._setProperties(
|
|
7411
|
-
|
|
7433
|
+
F(e) ? void 0 : Vs(e)
|
|
7412
7434
|
);
|
|
7413
7435
|
}
|
|
7414
7436
|
_updateProperty(e, t, s) {
|
|
@@ -7420,17 +7442,17 @@ class Ss extends D {
|
|
|
7420
7442
|
}
|
|
7421
7443
|
}
|
|
7422
7444
|
Va([
|
|
7423
|
-
|
|
7424
|
-
],
|
|
7445
|
+
u()
|
|
7446
|
+
], Es.prototype, "fillWithShape");
|
|
7425
7447
|
var Ga = Object.defineProperty, Wa = (r, e, t, s) => {
|
|
7426
7448
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
7427
7449
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
7428
7450
|
return i && Ga(e, t, i), i;
|
|
7429
7451
|
};
|
|
7430
|
-
class
|
|
7452
|
+
class Ss extends I {
|
|
7431
7453
|
setProperties(e) {
|
|
7432
7454
|
return super._setProperties(
|
|
7433
|
-
|
|
7455
|
+
F(e) ? void 0 : Gs(e)
|
|
7434
7456
|
);
|
|
7435
7457
|
}
|
|
7436
7458
|
_updateProperty(e, t, s) {
|
|
@@ -7442,17 +7464,17 @@ class Cs extends D {
|
|
|
7442
7464
|
}
|
|
7443
7465
|
}
|
|
7444
7466
|
Wa([
|
|
7445
|
-
|
|
7446
|
-
],
|
|
7467
|
+
u()
|
|
7468
|
+
], Ss.prototype, "fillWithShape");
|
|
7447
7469
|
var ja = Object.defineProperty, ut = (r, e, t, s) => {
|
|
7448
7470
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
7449
7471
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
7450
7472
|
return i && ja(e, t, i), i;
|
|
7451
7473
|
};
|
|
7452
|
-
class Ge extends
|
|
7474
|
+
class Ge extends I {
|
|
7453
7475
|
setProperties(e) {
|
|
7454
7476
|
return super._setProperties(
|
|
7455
|
-
|
|
7477
|
+
F(e) ? void 0 : Ws(e)
|
|
7456
7478
|
);
|
|
7457
7479
|
}
|
|
7458
7480
|
_updateProperty(e, t, s) {
|
|
@@ -7484,19 +7506,19 @@ class Ge extends D {
|
|
|
7484
7506
|
}
|
|
7485
7507
|
}
|
|
7486
7508
|
ut([
|
|
7487
|
-
|
|
7509
|
+
u({ fallback: "#00000000" })
|
|
7488
7510
|
], Ge.prototype, "color");
|
|
7489
7511
|
ut([
|
|
7490
|
-
|
|
7512
|
+
u({ fallback: 0 })
|
|
7491
7513
|
], Ge.prototype, "width");
|
|
7492
7514
|
ut([
|
|
7493
|
-
|
|
7515
|
+
u({ fallback: "solid" })
|
|
7494
7516
|
], Ge.prototype, "style");
|
|
7495
7517
|
ut([
|
|
7496
|
-
|
|
7518
|
+
u({ fallback: "butt" })
|
|
7497
7519
|
], Ge.prototype, "lineCap");
|
|
7498
7520
|
ut([
|
|
7499
|
-
|
|
7521
|
+
u({ fallback: "miter" })
|
|
7500
7522
|
], Ge.prototype, "lineJoin");
|
|
7501
7523
|
var qa = Object.defineProperty, dt = (r, e, t, s) => {
|
|
7502
7524
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
@@ -7509,7 +7531,7 @@ class We extends pe {
|
|
|
7509
7531
|
}
|
|
7510
7532
|
setProperties(e) {
|
|
7511
7533
|
return super.setProperties(
|
|
7512
|
-
|
|
7534
|
+
F(e) ? void 0 : js(e)
|
|
7513
7535
|
);
|
|
7514
7536
|
}
|
|
7515
7537
|
_updateProperty(e, t, s) {
|
|
@@ -7529,19 +7551,19 @@ class We extends pe {
|
|
|
7529
7551
|
}
|
|
7530
7552
|
}
|
|
7531
7553
|
dt([
|
|
7532
|
-
|
|
7554
|
+
u({ fallback: !0 })
|
|
7533
7555
|
], We.prototype, "enabled");
|
|
7534
7556
|
dt([
|
|
7535
|
-
|
|
7557
|
+
u({ fallback: "#000000FF" })
|
|
7536
7558
|
], We.prototype, "color");
|
|
7537
7559
|
dt([
|
|
7538
|
-
|
|
7560
|
+
u({ fallback: 0 })
|
|
7539
7561
|
], We.prototype, "blur");
|
|
7540
7562
|
dt([
|
|
7541
|
-
|
|
7563
|
+
u({ fallback: 0 })
|
|
7542
7564
|
], We.prototype, "offsetY");
|
|
7543
7565
|
dt([
|
|
7544
|
-
|
|
7566
|
+
u({ fallback: 0 })
|
|
7545
7567
|
], We.prototype, "offsetX");
|
|
7546
7568
|
var Xa = Object.defineProperty, ft = (r, e, t, s) => {
|
|
7547
7569
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
@@ -7555,7 +7577,7 @@ class je extends pe {
|
|
|
7555
7577
|
_path2DSet = new ti();
|
|
7556
7578
|
setProperties(e) {
|
|
7557
7579
|
return super.setProperties(
|
|
7558
|
-
|
|
7580
|
+
F(e) ? void 0 : qs(e)
|
|
7559
7581
|
);
|
|
7560
7582
|
}
|
|
7561
7583
|
_updateProperty(e, t, s) {
|
|
@@ -7575,8 +7597,8 @@ class je extends pe {
|
|
|
7575
7597
|
this._path2DSet = si(a), e = this._path2DSet.viewBox;
|
|
7576
7598
|
} else
|
|
7577
7599
|
this.paths?.forEach((a, n) => {
|
|
7578
|
-
const { data: h, ...l } = a,
|
|
7579
|
-
|
|
7600
|
+
const { data: h, ...l } = a, c = new bt();
|
|
7601
|
+
c.style = l, c.addData(h), this._path2DSet.paths[n] = c;
|
|
7580
7602
|
});
|
|
7581
7603
|
if (!e) {
|
|
7582
7604
|
const a = this._path2DSet.getBoundingBox();
|
|
@@ -7584,14 +7606,14 @@ class je extends pe {
|
|
|
7584
7606
|
}
|
|
7585
7607
|
const [t, s, i, o] = e;
|
|
7586
7608
|
this._path2DSet.paths.forEach((a) => {
|
|
7587
|
-
a.applyTransform(new
|
|
7609
|
+
a.applyTransform(new mr().translate(-t, -s).scale(1 / i, 1 / o));
|
|
7588
7610
|
});
|
|
7589
7611
|
}
|
|
7590
7612
|
draw(e = !1) {
|
|
7591
7613
|
if (!e && this.enabled && this._path2DSet.paths.length) {
|
|
7592
7614
|
const t = this.parent.context, { width: s, height: i } = this.parent.size;
|
|
7593
7615
|
this._path2DSet.paths.forEach((o) => {
|
|
7594
|
-
t.addPath(o.clone().applyTransform(new
|
|
7616
|
+
t.addPath(o.clone().applyTransform(new mr().scale(s, i)));
|
|
7595
7617
|
});
|
|
7596
7618
|
} else
|
|
7597
7619
|
this._drawRect();
|
|
@@ -7602,29 +7624,29 @@ class je extends pe {
|
|
|
7602
7624
|
}
|
|
7603
7625
|
}
|
|
7604
7626
|
ft([
|
|
7605
|
-
|
|
7627
|
+
u({ fallback: !0 })
|
|
7606
7628
|
], je.prototype, "enabled");
|
|
7607
7629
|
ft([
|
|
7608
|
-
|
|
7630
|
+
u()
|
|
7609
7631
|
], je.prototype, "preset");
|
|
7610
7632
|
ft([
|
|
7611
|
-
|
|
7633
|
+
u()
|
|
7612
7634
|
], je.prototype, "svg");
|
|
7613
7635
|
ft([
|
|
7614
|
-
|
|
7636
|
+
u()
|
|
7615
7637
|
], je.prototype, "viewBox");
|
|
7616
7638
|
ft([
|
|
7617
|
-
|
|
7639
|
+
u()
|
|
7618
7640
|
], je.prototype, "paths");
|
|
7619
7641
|
class rt extends _e {
|
|
7620
7642
|
constructor(e) {
|
|
7621
7643
|
super(), this.setProperties(e);
|
|
7622
7644
|
}
|
|
7623
7645
|
}
|
|
7624
|
-
const
|
|
7625
|
-
for (const r in
|
|
7626
|
-
const e =
|
|
7627
|
-
|
|
7646
|
+
const Tr = Xs();
|
|
7647
|
+
for (const r in Tr) {
|
|
7648
|
+
const e = Tr[r];
|
|
7649
|
+
qt(rt, r, { fallback: e });
|
|
7628
7650
|
}
|
|
7629
7651
|
var Ha = Object.defineProperty, he = (r, e, t, s) => {
|
|
7630
7652
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
@@ -7636,11 +7658,11 @@ class te extends pe {
|
|
|
7636
7658
|
super(), this.parent = e, this.base = new ii(), this.base.setPropertyAccessor(this);
|
|
7637
7659
|
}
|
|
7638
7660
|
base;
|
|
7639
|
-
_texture = new
|
|
7661
|
+
_texture = new Jt();
|
|
7640
7662
|
_textureMap = /* @__PURE__ */ new Map();
|
|
7641
7663
|
setProperties(e) {
|
|
7642
7664
|
return super.setProperties(
|
|
7643
|
-
|
|
7665
|
+
F(e) ? void 0 : Hs(e)
|
|
7644
7666
|
);
|
|
7645
7667
|
}
|
|
7646
7668
|
_updateProperty(e, t, s) {
|
|
@@ -7673,17 +7695,17 @@ class te extends pe {
|
|
|
7673
7695
|
const i = [];
|
|
7674
7696
|
if (t.fragments.forEach((o, a) => {
|
|
7675
7697
|
if (o.characters.length) {
|
|
7676
|
-
const n =
|
|
7698
|
+
const n = Nt.from(
|
|
7677
7699
|
...o.characters.map((h) => h.compatibleGlyphBox)
|
|
7678
7700
|
);
|
|
7679
7701
|
this._updateTexture(`${s}.${a}.fill`, o.fill, n), this._updateTexture(`${s}.${a}.outline`, o.outline, n), i.push(n);
|
|
7680
7702
|
}
|
|
7681
7703
|
}), i.length) {
|
|
7682
|
-
const o =
|
|
7704
|
+
const o = Nt.from(...i);
|
|
7683
7705
|
this._updateTexture(`${s}.fill`, t.fill, o), this._updateTexture(`${s}.outline`, t.outline, o), e.push(o);
|
|
7684
7706
|
}
|
|
7685
7707
|
}), e.length) {
|
|
7686
|
-
const t =
|
|
7708
|
+
const t = Nt.from(...e);
|
|
7687
7709
|
this._updateTexture("fill", this.fill, t), this._updateTexture("outline", this.outline, t);
|
|
7688
7710
|
}
|
|
7689
7711
|
}
|
|
@@ -7694,11 +7716,11 @@ class te extends pe {
|
|
|
7694
7716
|
}), this.parent.requestRedraw());
|
|
7695
7717
|
}
|
|
7696
7718
|
async _loadTexture(e, t) {
|
|
7697
|
-
return e.linearGradient || e.radialGradient ? new
|
|
7719
|
+
return e.linearGradient || e.radialGradient ? new kt(
|
|
7698
7720
|
e.linearGradient ?? e.radialGradient,
|
|
7699
7721
|
t.width,
|
|
7700
7722
|
t.height
|
|
7701
|
-
) :
|
|
7723
|
+
) : F(e.image) ? void 0 : (this.parent.tree?.log(`load image ${e.image}`), await z.texture.load(e.image));
|
|
7702
7724
|
}
|
|
7703
7725
|
setContent(e) {
|
|
7704
7726
|
this.content = Ys(e);
|
|
@@ -7726,11 +7748,11 @@ class te extends pe {
|
|
|
7726
7748
|
const i = s.getMeta();
|
|
7727
7749
|
if (i instanceof oi) {
|
|
7728
7750
|
const o = i.parent.index, a = i.parent.parent.index;
|
|
7729
|
-
if (s.style.fill && !
|
|
7751
|
+
if (s.style.fill && !F(s.style.fill))
|
|
7730
7752
|
if (typeof s.style.fill == "object") {
|
|
7731
7753
|
const n = s.style.fill, h = this._textureMap.get(`${a}.${o}.fill`) ?? this._textureMap.get(`${a}.fill`) ?? this._textureMap.get("fill");
|
|
7732
7754
|
if (n.enabled !== !1 && (h || n.color)) {
|
|
7733
|
-
const { uvTransform: l, disableWrapMode:
|
|
7755
|
+
const { uvTransform: l, disableWrapMode: c } = Tt(
|
|
7734
7756
|
n,
|
|
7735
7757
|
h?.box ?? {
|
|
7736
7758
|
width: this.parent.size.width,
|
|
@@ -7740,18 +7762,18 @@ class te extends pe {
|
|
|
7740
7762
|
e.addPath(s), e.style = { ...s.style }, e.fillStyle = h?.texture ?? n.color, e.fill({
|
|
7741
7763
|
uvTransform: l,
|
|
7742
7764
|
vertTransform: this._createVertTransform(),
|
|
7743
|
-
disableWrapMode:
|
|
7765
|
+
disableWrapMode: c
|
|
7744
7766
|
});
|
|
7745
7767
|
}
|
|
7746
7768
|
} else
|
|
7747
7769
|
e.addPath(s), e.style = { ...s.style }, e.fill({
|
|
7748
7770
|
vertTransform: this._createVertTransform()
|
|
7749
7771
|
});
|
|
7750
|
-
if (s.style.stroke && !
|
|
7772
|
+
if (s.style.stroke && !F(s.style.stroke))
|
|
7751
7773
|
if (typeof s.style.stroke == "object") {
|
|
7752
7774
|
const n = s.style.stroke, h = this._textureMap.get(`${a}.${o}.outline`) ?? this._textureMap.get(`${a}.outline`) ?? this._textureMap.get("outline");
|
|
7753
7775
|
if (n.enabled !== !1 && (h || n.color) && (n.width === void 0 || n.width)) {
|
|
7754
|
-
const { uvTransform: l, disableWrapMode:
|
|
7776
|
+
const { uvTransform: l, disableWrapMode: c } = Tt(
|
|
7755
7777
|
n,
|
|
7756
7778
|
h?.box ?? {
|
|
7757
7779
|
width: this.parent.size.width,
|
|
@@ -7761,7 +7783,7 @@ class te extends pe {
|
|
|
7761
7783
|
e.addPath(s), e.style = { ...s.style }, e.lineWidth = n.width || 1, e.strokeStyle = h?.texture ?? n.color, e.lineCap = n.lineCap, e.lineJoin = n.lineJoin, e.stroke({
|
|
7762
7784
|
uvTransform: l,
|
|
7763
7785
|
vertTransform: this._createVertTransform(),
|
|
7764
|
-
disableWrapMode:
|
|
7786
|
+
disableWrapMode: c
|
|
7765
7787
|
});
|
|
7766
7788
|
}
|
|
7767
7789
|
} else
|
|
@@ -7788,31 +7810,31 @@ class te extends pe {
|
|
|
7788
7810
|
}
|
|
7789
7811
|
}
|
|
7790
7812
|
he([
|
|
7791
|
-
|
|
7813
|
+
u({ fallback: !0 })
|
|
7792
7814
|
], te.prototype, "enabled");
|
|
7793
7815
|
he([
|
|
7794
|
-
|
|
7816
|
+
u({ fallback: () => [] })
|
|
7795
7817
|
], te.prototype, "content");
|
|
7796
7818
|
he([
|
|
7797
|
-
|
|
7819
|
+
u({ alias: "parent.style.json" })
|
|
7798
7820
|
], te.prototype, "style");
|
|
7799
7821
|
he([
|
|
7800
|
-
|
|
7822
|
+
u()
|
|
7801
7823
|
], te.prototype, "effects");
|
|
7802
7824
|
he([
|
|
7803
|
-
|
|
7825
|
+
u()
|
|
7804
7826
|
], te.prototype, "fill");
|
|
7805
7827
|
he([
|
|
7806
|
-
|
|
7828
|
+
u()
|
|
7807
7829
|
], te.prototype, "outline");
|
|
7808
7830
|
he([
|
|
7809
|
-
|
|
7831
|
+
u({ alias: "base.measureDom" })
|
|
7810
7832
|
], te.prototype, "measureDom");
|
|
7811
7833
|
he([
|
|
7812
|
-
|
|
7834
|
+
u({ alias: "base.fonts" })
|
|
7813
7835
|
], te.prototype, "fonts");
|
|
7814
7836
|
he([
|
|
7815
|
-
|
|
7837
|
+
u({ fallback: "auto" })
|
|
7816
7838
|
], te.prototype, "drawMode");
|
|
7817
7839
|
var Ya = Object.getOwnPropertyDescriptor, Ka = (r, e, t, s) => {
|
|
7818
7840
|
for (var i = s > 1 ? void 0 : s ? Ya(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
@@ -7820,7 +7842,7 @@ var Ya = Object.getOwnPropertyDescriptor, Ka = (r, e, t, s) => {
|
|
|
7820
7842
|
return i;
|
|
7821
7843
|
};
|
|
7822
7844
|
const Za = new Set(Object.keys(Zs())), Ja = new Set(Object.keys(Ks()));
|
|
7823
|
-
let st = class extends
|
|
7845
|
+
let st = class extends Te {
|
|
7824
7846
|
size = new C().on("update", () => {
|
|
7825
7847
|
this.onUpdateStyleProperty("transform", this.style.transform, void 0), this.onUpdateStyleProperty("transformOrigin", this.style.transformOrigin, void 0), this.updateGlobalTransform(), this.requestRedraw();
|
|
7826
7848
|
});
|
|
@@ -7835,7 +7857,7 @@ let st = class extends Pe {
|
|
|
7835
7857
|
set style(r) {
|
|
7836
7858
|
this._style.resetProperties().setProperties(r);
|
|
7837
7859
|
}
|
|
7838
|
-
_background = new
|
|
7860
|
+
_background = new Es(this);
|
|
7839
7861
|
get background() {
|
|
7840
7862
|
return this._background;
|
|
7841
7863
|
}
|
|
@@ -7849,7 +7871,7 @@ let st = class extends Pe {
|
|
|
7849
7871
|
set shape(r) {
|
|
7850
7872
|
this._shape.resetProperties().setProperties(r);
|
|
7851
7873
|
}
|
|
7852
|
-
_fill = new
|
|
7874
|
+
_fill = new I(this);
|
|
7853
7875
|
get fill() {
|
|
7854
7876
|
return this._fill;
|
|
7855
7877
|
}
|
|
@@ -7863,7 +7885,7 @@ let st = class extends Pe {
|
|
|
7863
7885
|
set outline(r) {
|
|
7864
7886
|
this._outline.resetProperties().setProperties(r);
|
|
7865
7887
|
}
|
|
7866
|
-
_foreground = new
|
|
7888
|
+
_foreground = new Ss(this);
|
|
7867
7889
|
get foreground() {
|
|
7868
7890
|
return this._foreground;
|
|
7869
7891
|
}
|
|
@@ -7977,7 +7999,7 @@ let st = class extends Pe {
|
|
|
7977
7999
|
this._overflowHidden = e === "hidden";
|
|
7978
8000
|
break;
|
|
7979
8001
|
case "pointerEvents":
|
|
7980
|
-
this._allowPointerEvents = !
|
|
8002
|
+
this._allowPointerEvents = !F(e);
|
|
7981
8003
|
break;
|
|
7982
8004
|
case "borderRadius":
|
|
7983
8005
|
default:
|
|
@@ -7993,7 +8015,7 @@ let st = class extends Pe {
|
|
|
7993
8015
|
const e = "__$style.maskImage";
|
|
7994
8016
|
if (r && r !== "none") {
|
|
7995
8017
|
const t = this.getNode(e);
|
|
7996
|
-
t ? t.src = r : this.appendChild(new
|
|
8018
|
+
t ? t.src = r : this.appendChild(new Ee({ name: e, src: r }), "back");
|
|
7997
8019
|
} else {
|
|
7998
8020
|
const t = this.getNode(e);
|
|
7999
8021
|
t && this.removeChild(t);
|
|
@@ -8015,19 +8037,19 @@ let st = class extends Pe {
|
|
|
8015
8037
|
];
|
|
8016
8038
|
}
|
|
8017
8039
|
getAabb() {
|
|
8018
|
-
return new
|
|
8040
|
+
return new ye(
|
|
8019
8041
|
this._getPointArray().map((r) => this.transform.apply(r))
|
|
8020
8042
|
);
|
|
8021
8043
|
}
|
|
8022
8044
|
getGlobalAabb() {
|
|
8023
|
-
return new
|
|
8045
|
+
return new ye(
|
|
8024
8046
|
this._getPointArray().map((r) => this.globalTransform.apply(r))
|
|
8025
8047
|
);
|
|
8026
8048
|
}
|
|
8027
8049
|
getObb() {
|
|
8028
8050
|
const r = this.pivot, e = this.transform.apply(r).sub(r);
|
|
8029
8051
|
return {
|
|
8030
|
-
rect: new
|
|
8052
|
+
rect: new ye(
|
|
8031
8053
|
this._getPointArray().map((t) => (t.x += e.x, t.y += e.y, t))
|
|
8032
8054
|
),
|
|
8033
8055
|
rotation: this.rotation
|
|
@@ -8036,7 +8058,7 @@ let st = class extends Pe {
|
|
|
8036
8058
|
getGlobalObb() {
|
|
8037
8059
|
const r = this.pivot, e = this.globalTransform.apply(r).sub(r);
|
|
8038
8060
|
return {
|
|
8039
|
-
rect: new
|
|
8061
|
+
rect: new ye(
|
|
8040
8062
|
this._getPointArray().map((t) => (t.x += e.x, t.y += e.y, t))
|
|
8041
8063
|
),
|
|
8042
8064
|
rotation: this.globalRotation
|
|
@@ -8123,7 +8145,7 @@ let st = class extends Pe {
|
|
|
8123
8145
|
}
|
|
8124
8146
|
toJSON() {
|
|
8125
8147
|
const r = (e) => Object.keys(e).length > 0 ? e : void 0;
|
|
8126
|
-
return
|
|
8148
|
+
return Br({
|
|
8127
8149
|
...super.toJSON(),
|
|
8128
8150
|
style: r(this.style.toJSON()),
|
|
8129
8151
|
background: r(this.background.toJSON()),
|
|
@@ -8137,21 +8159,21 @@ let st = class extends Pe {
|
|
|
8137
8159
|
}
|
|
8138
8160
|
};
|
|
8139
8161
|
st = Ka([
|
|
8140
|
-
|
|
8162
|
+
g("BaseElement2D")
|
|
8141
8163
|
], st);
|
|
8142
|
-
class
|
|
8164
|
+
class Cs extends rt {
|
|
8143
8165
|
constructor(e) {
|
|
8144
8166
|
super(), this.setProperties(e);
|
|
8145
8167
|
}
|
|
8146
8168
|
}
|
|
8147
|
-
const
|
|
8169
|
+
const Er = {
|
|
8148
8170
|
left: 0,
|
|
8149
8171
|
top: 0,
|
|
8150
8172
|
width: 0,
|
|
8151
8173
|
height: 0
|
|
8152
8174
|
};
|
|
8153
|
-
for (const r in
|
|
8154
|
-
|
|
8175
|
+
for (const r in Er)
|
|
8176
|
+
qt(Cs, r, { fallback: Er[r] });
|
|
8155
8177
|
class Qa extends rt {
|
|
8156
8178
|
constructor(e) {
|
|
8157
8179
|
super(), this.setProperties(e);
|
|
@@ -8162,8 +8184,8 @@ var en = Object.getOwnPropertyDescriptor, tn = (r, e, t, s) => {
|
|
|
8162
8184
|
(a = r[o]) && (i = a(i) || i);
|
|
8163
8185
|
return i;
|
|
8164
8186
|
};
|
|
8165
|
-
let
|
|
8166
|
-
_style = new
|
|
8187
|
+
let Se = class extends st {
|
|
8188
|
+
_style = new Cs().on("updateProperty", (...r) => {
|
|
8167
8189
|
this.onUpdateStyleProperty(r[0], r[1], r[2]);
|
|
8168
8190
|
});
|
|
8169
8191
|
get style() {
|
|
@@ -8198,9 +8220,9 @@ let Ee = class extends st {
|
|
|
8198
8220
|
}
|
|
8199
8221
|
}
|
|
8200
8222
|
};
|
|
8201
|
-
|
|
8202
|
-
|
|
8203
|
-
],
|
|
8223
|
+
Se = tn([
|
|
8224
|
+
g("Element2D")
|
|
8225
|
+
], Se);
|
|
8204
8226
|
const E = {
|
|
8205
8227
|
left: 0,
|
|
8206
8228
|
// Edge.Left
|
|
@@ -8227,7 +8249,7 @@ const E = {
|
|
|
8227
8249
|
// Gutter.Row
|
|
8228
8250
|
all: 2
|
|
8229
8251
|
// Gutter.All
|
|
8230
|
-
},
|
|
8252
|
+
}, Oe = {
|
|
8231
8253
|
auto: 0,
|
|
8232
8254
|
// Align.Auto
|
|
8233
8255
|
"flex-start": 1,
|
|
@@ -8246,21 +8268,21 @@ const E = {
|
|
|
8246
8268
|
// Align.SpaceAround
|
|
8247
8269
|
"space-evenly": 8
|
|
8248
8270
|
// Align.SpaceEvenly
|
|
8249
|
-
},
|
|
8271
|
+
}, Sr = {
|
|
8250
8272
|
flex: 0,
|
|
8251
8273
|
// Display.Flex
|
|
8252
8274
|
none: 1,
|
|
8253
8275
|
// Display.None
|
|
8254
8276
|
contents: 2
|
|
8255
8277
|
// Display.Contents
|
|
8256
|
-
},
|
|
8278
|
+
}, Vt = {
|
|
8257
8279
|
inherit: 0,
|
|
8258
8280
|
// Direction.Inherit
|
|
8259
8281
|
ltr: 1,
|
|
8260
8282
|
// Direction.LTR
|
|
8261
8283
|
rtl: 2
|
|
8262
8284
|
// Direction.RTL
|
|
8263
|
-
},
|
|
8285
|
+
}, Cr = {
|
|
8264
8286
|
column: 0,
|
|
8265
8287
|
// FlexDirection.Column
|
|
8266
8288
|
"column-reverse": 1,
|
|
@@ -8269,14 +8291,14 @@ const E = {
|
|
|
8269
8291
|
// FlexDirection.Row
|
|
8270
8292
|
"row-reverse": 3
|
|
8271
8293
|
// FlexDirection.RowReverse
|
|
8272
|
-
},
|
|
8294
|
+
}, Ar = {
|
|
8273
8295
|
"no-wrap": 0,
|
|
8274
8296
|
// Wrap.NoWrap
|
|
8275
8297
|
wrap: 1,
|
|
8276
8298
|
// Wrap.Wrap
|
|
8277
8299
|
"Wrap-reverse": 2
|
|
8278
8300
|
// Wrap.WrapReverse
|
|
8279
|
-
},
|
|
8301
|
+
}, Rr = {
|
|
8280
8302
|
"flex-start": 0,
|
|
8281
8303
|
// Justify.FlexStart
|
|
8282
8304
|
center: 1,
|
|
@@ -8289,7 +8311,7 @@ const E = {
|
|
|
8289
8311
|
// Justify.SpaceAround
|
|
8290
8312
|
"space-evenly": 5
|
|
8291
8313
|
// Justify.SpaceEvenly
|
|
8292
|
-
},
|
|
8314
|
+
}, Or = {
|
|
8293
8315
|
visible: 0,
|
|
8294
8316
|
// Overflow.Visible
|
|
8295
8317
|
hidden: 1,
|
|
@@ -8303,13 +8325,13 @@ const E = {
|
|
|
8303
8325
|
// PositionType.Relative
|
|
8304
8326
|
absolute: 2
|
|
8305
8327
|
// PositionType.Absolute
|
|
8306
|
-
},
|
|
8328
|
+
}, kr = {
|
|
8307
8329
|
"border-box": 0,
|
|
8308
8330
|
// BoxSizing.BorderBox
|
|
8309
8331
|
"content-box": 1
|
|
8310
8332
|
// BoxSizing.ContentBox
|
|
8311
8333
|
};
|
|
8312
|
-
class
|
|
8334
|
+
class nr {
|
|
8313
8335
|
constructor(e) {
|
|
8314
8336
|
this._element = e;
|
|
8315
8337
|
}
|
|
@@ -8318,7 +8340,7 @@ class lr {
|
|
|
8318
8340
|
const { loadYoga: e } = await import("yoga-layout/load");
|
|
8319
8341
|
this._yoga = await e();
|
|
8320
8342
|
}
|
|
8321
|
-
_node =
|
|
8343
|
+
_node = nr._yoga.Node.create();
|
|
8322
8344
|
get _style() {
|
|
8323
8345
|
return this._element.style;
|
|
8324
8346
|
}
|
|
@@ -8345,17 +8367,17 @@ class lr {
|
|
|
8345
8367
|
switch (e) {
|
|
8346
8368
|
case "alignContent":
|
|
8347
8369
|
this._node.setAlignContent(
|
|
8348
|
-
t ?
|
|
8370
|
+
t ? Oe[t] : Oe["flex-start"]
|
|
8349
8371
|
);
|
|
8350
8372
|
break;
|
|
8351
8373
|
case "alignItems":
|
|
8352
8374
|
this._node.setAlignItems(
|
|
8353
|
-
t ?
|
|
8375
|
+
t ? Oe[t] : Oe["flex-start"]
|
|
8354
8376
|
);
|
|
8355
8377
|
break;
|
|
8356
8378
|
case "alignSelf":
|
|
8357
8379
|
this._node.setAlignSelf(
|
|
8358
|
-
t ?
|
|
8380
|
+
t ? Oe[t] : Oe["flex-start"]
|
|
8359
8381
|
);
|
|
8360
8382
|
break;
|
|
8361
8383
|
case "aspectRatio":
|
|
@@ -8378,12 +8400,12 @@ class lr {
|
|
|
8378
8400
|
break;
|
|
8379
8401
|
case "direction":
|
|
8380
8402
|
this._node.setDirection(
|
|
8381
|
-
t ?
|
|
8403
|
+
t ? Vt[t] : Vt.inherit
|
|
8382
8404
|
);
|
|
8383
8405
|
break;
|
|
8384
8406
|
case "display":
|
|
8385
8407
|
this._node.setDisplay(
|
|
8386
|
-
t ?
|
|
8408
|
+
t ? Sr[t] : Sr.flex
|
|
8387
8409
|
);
|
|
8388
8410
|
break;
|
|
8389
8411
|
case "flex":
|
|
@@ -8394,7 +8416,7 @@ class lr {
|
|
|
8394
8416
|
break;
|
|
8395
8417
|
case "flexDirection":
|
|
8396
8418
|
this._node.setFlexDirection(
|
|
8397
|
-
t ?
|
|
8419
|
+
t ? Cr[t] : Cr.row
|
|
8398
8420
|
);
|
|
8399
8421
|
break;
|
|
8400
8422
|
case "flexGrow":
|
|
@@ -8405,7 +8427,7 @@ class lr {
|
|
|
8405
8427
|
break;
|
|
8406
8428
|
case "flexWrap":
|
|
8407
8429
|
this._node.setFlexWrap(
|
|
8408
|
-
t ?
|
|
8430
|
+
t ? Ar[t] : Ar.wrap
|
|
8409
8431
|
);
|
|
8410
8432
|
break;
|
|
8411
8433
|
case "height":
|
|
@@ -8413,7 +8435,7 @@ class lr {
|
|
|
8413
8435
|
break;
|
|
8414
8436
|
case "justifyContent":
|
|
8415
8437
|
this._node.setJustifyContent(
|
|
8416
|
-
t ?
|
|
8438
|
+
t ? Rr[t] : Rr["flex-start"]
|
|
8417
8439
|
);
|
|
8418
8440
|
break;
|
|
8419
8441
|
case "gap":
|
|
@@ -8450,7 +8472,7 @@ class lr {
|
|
|
8450
8472
|
break;
|
|
8451
8473
|
case "overflow":
|
|
8452
8474
|
this._node.setOverflow(
|
|
8453
|
-
t ?
|
|
8475
|
+
t ? Or[t] : Or.visible
|
|
8454
8476
|
);
|
|
8455
8477
|
break;
|
|
8456
8478
|
case "paddingTop":
|
|
@@ -8487,7 +8509,7 @@ class lr {
|
|
|
8487
8509
|
break;
|
|
8488
8510
|
case "boxSizing":
|
|
8489
8511
|
this._node.setBoxSizing(
|
|
8490
|
-
t ?
|
|
8512
|
+
t ? kr[t] : kr["content-box"]
|
|
8491
8513
|
);
|
|
8492
8514
|
break;
|
|
8493
8515
|
case "width":
|
|
@@ -8501,7 +8523,7 @@ var sn = Object.getOwnPropertyDescriptor, on = (r, e, t, s) => {
|
|
|
8501
8523
|
(a = r[o]) && (i = a(i) || i);
|
|
8502
8524
|
return i;
|
|
8503
8525
|
};
|
|
8504
|
-
let
|
|
8526
|
+
let Ur = class extends st {
|
|
8505
8527
|
_style = new Qa().on("updateProperty", (...r) => {
|
|
8506
8528
|
this.onUpdateStyleProperty(r[0], r[1], r[2]);
|
|
8507
8529
|
});
|
|
@@ -8511,7 +8533,7 @@ let Dr = class extends st {
|
|
|
8511
8533
|
set style(r) {
|
|
8512
8534
|
this._style.resetProperties().setProperties(r);
|
|
8513
8535
|
}
|
|
8514
|
-
_layout = new
|
|
8536
|
+
_layout = new nr(this);
|
|
8515
8537
|
get offsetLeft() {
|
|
8516
8538
|
return this._layout.offsetLeft;
|
|
8517
8539
|
}
|
|
@@ -8540,7 +8562,7 @@ let Dr = class extends st {
|
|
|
8540
8562
|
super._updateStyleProperty(r, e, t), this._layout.updateStyleProperty(r, e, t), this._layout._node.isDirty() && this.requestRelayout();
|
|
8541
8563
|
}
|
|
8542
8564
|
updateTransform() {
|
|
8543
|
-
this.calculateLayout(void 0, void 0,
|
|
8565
|
+
this.calculateLayout(void 0, void 0, Vt.ltr);
|
|
8544
8566
|
const { left: r, top: e, width: t, height: s } = this._layout.getComputedLayout();
|
|
8545
8567
|
this.position.x = r, this.position.y = e, this.size.x = t, this.size.y = s, super.updateTransform();
|
|
8546
8568
|
}
|
|
@@ -8549,15 +8571,15 @@ let Dr = class extends st {
|
|
|
8549
8571
|
s?._layout?.calculateLayout ? s?._layout.calculateLayout(r, e, t) : this._layout.calculateLayout(r, e, t);
|
|
8550
8572
|
}
|
|
8551
8573
|
};
|
|
8552
|
-
|
|
8553
|
-
|
|
8554
|
-
],
|
|
8574
|
+
Ur = on([
|
|
8575
|
+
g("FlexElement2D")
|
|
8576
|
+
], Ur);
|
|
8555
8577
|
var an = Object.defineProperty, nn = Object.getOwnPropertyDescriptor, pt = (r, e, t, s) => {
|
|
8556
8578
|
for (var i = s > 1 ? void 0 : s ? nn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
8557
8579
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
8558
8580
|
return s && i && an(e, t, i), i;
|
|
8559
8581
|
};
|
|
8560
|
-
let
|
|
8582
|
+
let ze = class extends Se {
|
|
8561
8583
|
get currentFrameTexture() {
|
|
8562
8584
|
return this.texture?.frames[this._frameIndex]?.texture;
|
|
8563
8585
|
}
|
|
@@ -8595,7 +8617,7 @@ let Be = class extends Ee {
|
|
|
8595
8617
|
}
|
|
8596
8618
|
setResource(r) {
|
|
8597
8619
|
let e;
|
|
8598
|
-
if (r instanceof
|
|
8620
|
+
if (r instanceof $t ? e = r : e = new $t(r), this.texture = e.updateDuration(), this.currentFrameTexture && (!this.style.width || !this.style.height)) {
|
|
8599
8621
|
const t = this.currentFrameTexture;
|
|
8600
8622
|
this.style.width = t.realWidth, this.style.height = t.realHeight;
|
|
8601
8623
|
}
|
|
@@ -8605,7 +8627,7 @@ let Be = class extends Ee {
|
|
|
8605
8627
|
if (this._complete = !1, r)
|
|
8606
8628
|
try {
|
|
8607
8629
|
this.setResource(
|
|
8608
|
-
this.gif || r?.includes(".gif") ? await
|
|
8630
|
+
this.gif || r?.includes(".gif") ? await z.gif.load(r) : await z.texture.load(r)
|
|
8609
8631
|
), this.requestRedraw(), this.emit("load");
|
|
8610
8632
|
} catch (e) {
|
|
8611
8633
|
console.warn(e), this.emit("error", e);
|
|
@@ -8643,8 +8665,8 @@ let Be = class extends Ee {
|
|
|
8643
8665
|
if (r?.isValid()) {
|
|
8644
8666
|
const { left: e = 0, top: t = 0, right: s = 0, bottom: i = 0 } = this.srcRect ?? {}, { width: o, height: a } = this.size;
|
|
8645
8667
|
this.context.fillStyle = r;
|
|
8646
|
-
const n = Math.abs(1 + (e + s)) * o, h = Math.abs(1 + (t + i)) * a, l = 1 / n,
|
|
8647
|
-
this.context.uvTransform = new O().scale(l,
|
|
8668
|
+
const n = Math.abs(1 + (e + s)) * o, h = Math.abs(1 + (t + i)) * a, l = 1 / n, c = 1 / h, d = e * o * l, f = t * a * c;
|
|
8669
|
+
this.context.uvTransform = new O().scale(l, c).translate(d, f), this.shape.draw(), this.context.fill();
|
|
8648
8670
|
}
|
|
8649
8671
|
}
|
|
8650
8672
|
_repaint(r) {
|
|
@@ -8655,21 +8677,21 @@ let Be = class extends Ee {
|
|
|
8655
8677
|
}
|
|
8656
8678
|
};
|
|
8657
8679
|
pt([
|
|
8658
|
-
|
|
8659
|
-
],
|
|
8680
|
+
u({ internal: !0 })
|
|
8681
|
+
], ze.prototype, "texture", 2);
|
|
8660
8682
|
pt([
|
|
8661
|
-
|
|
8662
|
-
],
|
|
8683
|
+
u({ fallback: "" })
|
|
8684
|
+
], ze.prototype, "src", 2);
|
|
8663
8685
|
pt([
|
|
8664
|
-
|
|
8665
|
-
],
|
|
8686
|
+
u()
|
|
8687
|
+
], ze.prototype, "srcRect", 2);
|
|
8666
8688
|
pt([
|
|
8667
|
-
|
|
8668
|
-
],
|
|
8669
|
-
|
|
8670
|
-
|
|
8671
|
-
],
|
|
8672
|
-
class
|
|
8689
|
+
u({ fallback: !1 })
|
|
8690
|
+
], ze.prototype, "gif", 2);
|
|
8691
|
+
ze = pt([
|
|
8692
|
+
g("Image2D")
|
|
8693
|
+
], ze);
|
|
8694
|
+
class As extends Se {
|
|
8673
8695
|
texture;
|
|
8674
8696
|
constructor(e, t = []) {
|
|
8675
8697
|
super(), this.setProperties(e).append(t);
|
|
@@ -8678,13 +8700,13 @@ class Rs extends Ee {
|
|
|
8678
8700
|
this.texture?.isValid() && (this.shape.draw(!0), this.context.fillStyle = this.texture, this.context.fill());
|
|
8679
8701
|
}
|
|
8680
8702
|
}
|
|
8681
|
-
var ln = Object.defineProperty, hn = Object.getOwnPropertyDescriptor,
|
|
8703
|
+
var ln = Object.defineProperty, hn = Object.getOwnPropertyDescriptor, Rs = (r, e, t, s) => {
|
|
8682
8704
|
for (var i = s > 1 ? void 0 : s ? hn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
8683
8705
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
8684
8706
|
return s && i && ln(e, t, i), i;
|
|
8685
8707
|
};
|
|
8686
|
-
let
|
|
8687
|
-
texture = new
|
|
8708
|
+
let Gt = class extends As {
|
|
8709
|
+
texture = new Jt();
|
|
8688
8710
|
animation;
|
|
8689
8711
|
constructor(r, e = []) {
|
|
8690
8712
|
super(), this.setProperties(r), this.append(e);
|
|
@@ -8707,24 +8729,24 @@ let Wt = class extends Rs {
|
|
|
8707
8729
|
}
|
|
8708
8730
|
}
|
|
8709
8731
|
async _load() {
|
|
8710
|
-
this.animation = await
|
|
8732
|
+
this.animation = await z.lottie.load(this.src, this.texture.source), this.duration = this.animation.getDuration(!1) * 1e3, this.texture.requestUpload(), this.requestRedraw();
|
|
8711
8733
|
}
|
|
8712
8734
|
_process(r) {
|
|
8713
8735
|
this.animation?.goToAndStop(this.currentTime, !1), this.texture.requestUpload(), this.requestRedraw(), super._process(r);
|
|
8714
8736
|
}
|
|
8715
8737
|
};
|
|
8716
|
-
|
|
8717
|
-
|
|
8718
|
-
],
|
|
8719
|
-
|
|
8720
|
-
|
|
8721
|
-
],
|
|
8738
|
+
Rs([
|
|
8739
|
+
u({ fallback: "" })
|
|
8740
|
+
], Gt.prototype, "src", 2);
|
|
8741
|
+
Gt = Rs([
|
|
8742
|
+
g("Lottie2D")
|
|
8743
|
+
], Gt);
|
|
8722
8744
|
var cn = Object.defineProperty, un = (r, e, t, s) => {
|
|
8723
8745
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
8724
8746
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
8725
8747
|
return i && cn(e, t, i), i;
|
|
8726
8748
|
};
|
|
8727
|
-
class dn extends
|
|
8749
|
+
class dn extends Se {
|
|
8728
8750
|
constructor(e, t = []) {
|
|
8729
8751
|
super(), this.setProperties(e).append(t);
|
|
8730
8752
|
}
|
|
@@ -8748,14 +8770,14 @@ class dn extends Ee {
|
|
|
8748
8770
|
}
|
|
8749
8771
|
}
|
|
8750
8772
|
un([
|
|
8751
|
-
|
|
8773
|
+
u({ fallback: 6 })
|
|
8752
8774
|
], dn.prototype, "handleSize");
|
|
8753
|
-
var fn = Object.defineProperty, pn = Object.getOwnPropertyDescriptor,
|
|
8775
|
+
var fn = Object.defineProperty, pn = Object.getOwnPropertyDescriptor, Os = (r, e, t, s) => {
|
|
8754
8776
|
for (var i = s > 1 ? void 0 : s ? pn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
8755
8777
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
8756
8778
|
return s && i && fn(e, t, i), i;
|
|
8757
8779
|
};
|
|
8758
|
-
let
|
|
8780
|
+
let Wt = class extends As {
|
|
8759
8781
|
get videoDuration() {
|
|
8760
8782
|
return (this.texture?.duration ?? 0) * 1e3;
|
|
8761
8783
|
}
|
|
@@ -8774,7 +8796,7 @@ let jt = class extends Rs {
|
|
|
8774
8796
|
return this._wait;
|
|
8775
8797
|
}
|
|
8776
8798
|
async _load(r) {
|
|
8777
|
-
this.texture = await
|
|
8799
|
+
this.texture = await z.video.load(r), (!this.style.width || !this.style.height) && (this.style.width = this.texture.width, this.style.height = this.texture.height), this.requestRedraw();
|
|
8778
8800
|
}
|
|
8779
8801
|
_updateVideoCurrentTime() {
|
|
8780
8802
|
let r = this._currentTime;
|
|
@@ -8790,12 +8812,12 @@ let jt = class extends Rs {
|
|
|
8790
8812
|
this._updateVideoCurrentTime(), super._process(r);
|
|
8791
8813
|
}
|
|
8792
8814
|
};
|
|
8793
|
-
|
|
8794
|
-
|
|
8795
|
-
],
|
|
8796
|
-
|
|
8797
|
-
|
|
8798
|
-
],
|
|
8815
|
+
Os([
|
|
8816
|
+
u({ fallback: "" })
|
|
8817
|
+
], Wt.prototype, "src", 2);
|
|
8818
|
+
Wt = Os([
|
|
8819
|
+
g("Video2D")
|
|
8820
|
+
], Wt);
|
|
8799
8821
|
var _n = Object.defineProperty, mn = Object.getOwnPropertyDescriptor, Dt = (r, e, t, s) => {
|
|
8800
8822
|
for (var i = s > 1 ? void 0 : s ? mn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
8801
8823
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
@@ -8803,27 +8825,27 @@ var _n = Object.defineProperty, mn = Object.getOwnPropertyDescriptor, Dt = (r, e
|
|
|
8803
8825
|
};
|
|
8804
8826
|
const gn = (r) => r, vn = _t(0.25, 0.1, 0.25, 1), bn = _t(0.42, 0, 1, 1), yn = _t(0, 0, 0.58, 1), xn = _t(0.42, 0, 0.58, 1);
|
|
8805
8827
|
function _t(r, e, t, s) {
|
|
8806
|
-
const o = 3 * r - 3 * t + 1, a = 3 * t - 6 * r, n = 3 * r, h = 3 * e - 3 * s + 1, l = 3 * s - 6 * e,
|
|
8828
|
+
const o = 3 * r - 3 * t + 1, a = 3 * t - 6 * r, n = 3 * r, h = 3 * e - 3 * s + 1, l = 3 * s - 6 * e, c = 3 * e, d = (m) => (3 * o * m + 2 * a) * m + n, f = (m) => ((o * m + a) * m + n) * m, _ = (m) => ((h * m + l) * m + c) * m;
|
|
8807
8829
|
function p(m) {
|
|
8808
|
-
let
|
|
8809
|
-
for (let
|
|
8810
|
-
if (P = f(
|
|
8811
|
-
return
|
|
8812
|
-
if (
|
|
8830
|
+
let v = m, y, P;
|
|
8831
|
+
for (let L = 0; L < 8; L++) {
|
|
8832
|
+
if (P = f(v) - m, Math.abs(P) < 1e-6)
|
|
8833
|
+
return v;
|
|
8834
|
+
if (y = d(v), Math.abs(y) < 1e-6)
|
|
8813
8835
|
break;
|
|
8814
|
-
|
|
8836
|
+
v -= P / y;
|
|
8815
8837
|
}
|
|
8816
8838
|
let R = 1, A = 0;
|
|
8817
|
-
for (
|
|
8818
|
-
if (P = f(
|
|
8819
|
-
return
|
|
8820
|
-
P > 0 ? R =
|
|
8839
|
+
for (v = m; R > A; ) {
|
|
8840
|
+
if (P = f(v) - m, Math.abs(P) < 1e-6)
|
|
8841
|
+
return v;
|
|
8842
|
+
P > 0 ? R = v : A = v, v = (R + A) / 2;
|
|
8821
8843
|
}
|
|
8822
|
-
return
|
|
8844
|
+
return v;
|
|
8823
8845
|
}
|
|
8824
8846
|
return (m) => _(p(m));
|
|
8825
8847
|
}
|
|
8826
|
-
const
|
|
8848
|
+
const Lt = {
|
|
8827
8849
|
linear: gn,
|
|
8828
8850
|
ease: vn,
|
|
8829
8851
|
easeIn: bn,
|
|
@@ -8833,7 +8855,7 @@ const Ft = {
|
|
|
8833
8855
|
let it = class extends W {
|
|
8834
8856
|
_keyframes = [];
|
|
8835
8857
|
_isFirstUpdatePosition = !1;
|
|
8836
|
-
_cachedProps = new
|
|
8858
|
+
_cachedProps = new Ir();
|
|
8837
8859
|
_stoped = !1;
|
|
8838
8860
|
constructor(r, e = []) {
|
|
8839
8861
|
super(), this.setProperties(r).append(e);
|
|
@@ -8866,7 +8888,7 @@ let it = class extends W {
|
|
|
8866
8888
|
r = [this.getParent()].filter(Boolean);
|
|
8867
8889
|
break;
|
|
8868
8890
|
}
|
|
8869
|
-
return r.filter((e) => e instanceof
|
|
8891
|
+
return r.filter((e) => e instanceof Se);
|
|
8870
8892
|
}
|
|
8871
8893
|
_updateKeyframes() {
|
|
8872
8894
|
const r = [], e = this.keyframes;
|
|
@@ -8924,9 +8946,9 @@ let it = class extends W {
|
|
|
8924
8946
|
}
|
|
8925
8947
|
_parseEasing(r) {
|
|
8926
8948
|
if (!r)
|
|
8927
|
-
return
|
|
8928
|
-
if (r in
|
|
8929
|
-
return
|
|
8949
|
+
return Lt.linear;
|
|
8950
|
+
if (r in Lt)
|
|
8951
|
+
return Lt[r];
|
|
8930
8952
|
const e = r.replace(/cubic-bezier\((.+)\)/, "$1").split(",").map((t) => Number(t));
|
|
8931
8953
|
return _t(e[0], e[1], e[2], e[3]);
|
|
8932
8954
|
}
|
|
@@ -8940,13 +8962,13 @@ let it = class extends W {
|
|
|
8940
8962
|
} = a, l = { ...a.props };
|
|
8941
8963
|
if (t && r <= n) {
|
|
8942
8964
|
const {
|
|
8943
|
-
offset:
|
|
8965
|
+
offset: c,
|
|
8944
8966
|
easing: d
|
|
8945
8967
|
} = t, f = { ...t.props };
|
|
8946
8968
|
return e.forEach((_, p) => {
|
|
8947
8969
|
(!(p in f) || f[p] === null) && (f[p] = _), (!(p in l) || l[p] === null) && (l[p] = _);
|
|
8948
8970
|
}), [
|
|
8949
|
-
{ offset:
|
|
8971
|
+
{ offset: c, easing: d, props: f },
|
|
8950
8972
|
{ offset: n, easing: h, props: l }
|
|
8951
8973
|
];
|
|
8952
8974
|
}
|
|
@@ -8955,7 +8977,7 @@ let it = class extends W {
|
|
|
8955
8977
|
return null;
|
|
8956
8978
|
}
|
|
8957
8979
|
_commitStyle(r, e, t, s, i) {
|
|
8958
|
-
const { offset: o, easing: a, props: n } = s, { offset: h, props: l } = i,
|
|
8980
|
+
const { offset: o, easing: a, props: n } = s, { offset: h, props: l } = i, c = h - o, d = a((r - o) / c), f = {
|
|
8959
8981
|
width: e.size.x,
|
|
8960
8982
|
height: e.size.y,
|
|
8961
8983
|
fontSize: e.style.fontSize
|
|
@@ -8978,9 +9000,9 @@ let it = class extends W {
|
|
|
8978
9000
|
let o, a;
|
|
8979
9001
|
if (e === "none" && (e = void 0), t === "none" && (t = void 0), e === void 0 || t === void 0)
|
|
8980
9002
|
if (e !== void 0)
|
|
8981
|
-
o = mt(r, String(e), i), a =
|
|
9003
|
+
o = mt(r, String(e), i), a = vr(o);
|
|
8982
9004
|
else if (t !== void 0)
|
|
8983
|
-
a = mt(r, String(t), i), o =
|
|
9005
|
+
a = mt(r, String(t), i), o = vr(a);
|
|
8984
9006
|
else
|
|
8985
9007
|
return;
|
|
8986
9008
|
else
|
|
@@ -8992,14 +9014,14 @@ let it = class extends W {
|
|
|
8992
9014
|
}), a.forEach(({ name: d, args: f }) => {
|
|
8993
9015
|
l[d] = f, n.add(d);
|
|
8994
9016
|
});
|
|
8995
|
-
let
|
|
9017
|
+
let c = "";
|
|
8996
9018
|
return n.forEach((d) => {
|
|
8997
9019
|
const f = Math.max(h[d]?.length ?? 0, l[d]?.length ?? 0), _ = h[d], p = l[d];
|
|
8998
|
-
|
|
8999
|
-
const
|
|
9020
|
+
c += `${d}(${Array.from({ length: f }, (m, v) => {
|
|
9021
|
+
const y = _?.[v], P = p?.[v], R = y?.normalizedIntValue ?? 0, A = P?.normalizedIntValue ?? 0;
|
|
9000
9022
|
return Number.isNaN(R) || Number.isNaN(A) ? P?.value ?? 0 : S(R, A, s);
|
|
9001
9023
|
}).join(", ")}) `;
|
|
9002
|
-
}),
|
|
9024
|
+
}), c;
|
|
9003
9025
|
} else if (!Array.isArray(o) && !Array.isArray(a))
|
|
9004
9026
|
return Number.isNaN(o.normalizedIntValue) || Number.isNaN(a.normalizedIntValue) ? a.value : S(o.normalizedIntValue, a.normalizedIntValue, s);
|
|
9005
9027
|
}
|
|
@@ -9024,26 +9046,26 @@ let it = class extends W {
|
|
|
9024
9046
|
}
|
|
9025
9047
|
};
|
|
9026
9048
|
Dt([
|
|
9027
|
-
|
|
9049
|
+
u({ fallback: "parent" })
|
|
9028
9050
|
], it.prototype, "effectMode", 2);
|
|
9029
9051
|
Dt([
|
|
9030
|
-
|
|
9052
|
+
u({ default: () => [] })
|
|
9031
9053
|
], it.prototype, "keyframes", 2);
|
|
9032
9054
|
Dt([
|
|
9033
|
-
|
|
9055
|
+
u()
|
|
9034
9056
|
], it.prototype, "easing", 2);
|
|
9035
9057
|
it = Dt([
|
|
9036
|
-
|
|
9058
|
+
g("Animation", {
|
|
9037
9059
|
renderMode: "disabled",
|
|
9038
9060
|
processMode: "pausable",
|
|
9039
9061
|
processSortMode: "parent_before",
|
|
9040
9062
|
duration: 2e3
|
|
9041
9063
|
})
|
|
9042
9064
|
], it);
|
|
9043
|
-
class
|
|
9065
|
+
class lr extends fe {
|
|
9044
9066
|
static _instance;
|
|
9045
9067
|
static get instance() {
|
|
9046
|
-
return this._instance || (this._instance = new
|
|
9068
|
+
return this._instance || (this._instance = new lr()), this._instance;
|
|
9047
9069
|
}
|
|
9048
9070
|
playbackRate = 1;
|
|
9049
9071
|
muted = !1;
|
|
@@ -9193,17 +9215,17 @@ class Et extends fe {
|
|
|
9193
9215
|
return;
|
|
9194
9216
|
const { start: t = 0, end: s = 0 } = e;
|
|
9195
9217
|
s && console.assert(s > t, "End time is before start time"), e.playbackRate !== void 0 && (this._playbackRate = e.playbackRate), e.volume !== void 0 && (this._volume = e.volume), e.loop !== void 0 && (this._loop = e.loop), e.muted !== void 0 && (this._muted = e.muted), this.refresh(), this.loop && s !== null && (console.warn('Looping not support when specifying an "end" time'), this.loop = !1), this._start = t, this._end = s || this._duration, this._start = Math.max(0, this._start - Et.PADDING), this._end = Math.min(this._end + Et.PADDING, this._duration), this._source.onloadedmetadata = () => {
|
|
9196
|
-
this._source && (this._source.currentTime = t, this._source.onloadedmetadata = null, this.emit("progress", t, this._duration),
|
|
9218
|
+
this._source && (this._source.currentTime = t, this._source.onloadedmetadata = null, this.emit("progress", t, this._duration), U.on(this._onUpdate));
|
|
9197
9219
|
}, this._source.onended = this._onComplete.bind(this), this._source.play(), this.emit("start");
|
|
9198
9220
|
}
|
|
9199
9221
|
_onUpdate = () => {
|
|
9200
9222
|
this._source && (this.emit("progress", this.progress, this._duration), this._source.currentTime >= this._end && !this._source.loop && this._onComplete());
|
|
9201
9223
|
};
|
|
9202
9224
|
_onComplete() {
|
|
9203
|
-
|
|
9225
|
+
U.off(this._onUpdate), this._stop(), this.emit("progress", 1, this._duration), this.emit("end", this);
|
|
9204
9226
|
}
|
|
9205
9227
|
destroy() {
|
|
9206
|
-
|
|
9228
|
+
U.off(this._onUpdate), super.destroy();
|
|
9207
9229
|
const e = this._source;
|
|
9208
9230
|
e && (e.onended = null, e.onplay = null, e.onpause = null, this._stop()), this._source = null, this._playbackRate = 1, this._volume = 1, this._loop = !1, this._end = 0, this._start = 0, this._duration = 0, this._playing = !1, this._pausedReal = !1, this._paused = !1, this._muted = !1, this._audio && (this._audio.context.off("refresh", this.refresh), this._audio.context.off("refreshPaused", this.refreshPaused), this._audio = null);
|
|
9209
9231
|
}
|
|
@@ -9227,7 +9249,7 @@ class wn {
|
|
|
9227
9249
|
return !!this.source && this.source.readyState === 4;
|
|
9228
9250
|
}
|
|
9229
9251
|
get context() {
|
|
9230
|
-
return
|
|
9252
|
+
return lr.instance;
|
|
9231
9253
|
}
|
|
9232
9254
|
async load() {
|
|
9233
9255
|
return new Promise((e) => {
|
|
@@ -9259,7 +9281,7 @@ class Ms extends fe {
|
|
|
9259
9281
|
return this._input;
|
|
9260
9282
|
}
|
|
9261
9283
|
}
|
|
9262
|
-
class
|
|
9284
|
+
class Ml {
|
|
9263
9285
|
constructor(e, t = null) {
|
|
9264
9286
|
this.destination = e, this.source = t;
|
|
9265
9287
|
}
|
|
@@ -9271,16 +9293,16 @@ class kl {
|
|
|
9271
9293
|
}
|
|
9272
9294
|
}
|
|
9273
9295
|
function Pn() {
|
|
9274
|
-
if (
|
|
9296
|
+
if ($r)
|
|
9275
9297
|
return new AudioContext();
|
|
9276
|
-
if (
|
|
9298
|
+
if (Vr) {
|
|
9277
9299
|
const r = globalThis.webkitAudioContext;
|
|
9278
9300
|
return new r();
|
|
9279
9301
|
} else
|
|
9280
9302
|
throw new Error("Failed to createAudioContext");
|
|
9281
9303
|
}
|
|
9282
9304
|
function Tn(r, e, t) {
|
|
9283
|
-
if (
|
|
9305
|
+
if (Gr)
|
|
9284
9306
|
return new OfflineAudioContext(r, e, t);
|
|
9285
9307
|
if (gi) {
|
|
9286
9308
|
const s = globalThis.webkitOfflineAudioContext;
|
|
@@ -9288,11 +9310,11 @@ function Tn(r, e, t) {
|
|
|
9288
9310
|
} else
|
|
9289
9311
|
throw new Error("Failed to createOfflineAudioContext");
|
|
9290
9312
|
}
|
|
9291
|
-
class
|
|
9313
|
+
class xe extends Ms {
|
|
9292
9314
|
/** Singleton */
|
|
9293
9315
|
static _instance;
|
|
9294
9316
|
static get instance() {
|
|
9295
|
-
return this._instance || (this._instance = new
|
|
9317
|
+
return this._instance || (this._instance = new xe()), this._instance;
|
|
9296
9318
|
}
|
|
9297
9319
|
static get audioContext() {
|
|
9298
9320
|
return this.instance.audioContext;
|
|
@@ -9336,7 +9358,7 @@ class ye extends Ms {
|
|
|
9336
9358
|
const e = Pn(), t = Tn(
|
|
9337
9359
|
1,
|
|
9338
9360
|
2,
|
|
9339
|
-
|
|
9361
|
+
Gr ? Math.max(8e3, Math.min(96e3, e.sampleRate)) : 44100
|
|
9340
9362
|
), s = e.createDynamicsCompressor(), i = e.createAnalyser();
|
|
9341
9363
|
i.connect(s), s.connect(e.destination), super(i, s), this._context = e, this._offlineContext = t, this._compressor = s, this._analyser = i, this._locked = e.state === "suspended" && (ce || mi), Ot && (this._locked && (this._unlock(), document.addEventListener("mousedown", this._unlock, !0), document.addEventListener("touchstart", this._unlock, !0), document.addEventListener("touchend", this._unlock, !0)), globalThis.addEventListener("focus", this._onFocus), globalThis.addEventListener("blur", this._onBlur));
|
|
9342
9364
|
}
|
|
@@ -9529,7 +9551,7 @@ class En extends fe {
|
|
|
9529
9551
|
};
|
|
9530
9552
|
_updateListener = () => this._update();
|
|
9531
9553
|
_enableTicker(e) {
|
|
9532
|
-
|
|
9554
|
+
U.off(this._updateListener), e && U.on(this._updateListener);
|
|
9533
9555
|
}
|
|
9534
9556
|
destroy() {
|
|
9535
9557
|
super.destroy(), this._stop(), this._gain?.disconnect(), this._gain = null, this._audio?.context.off("refresh", this.refresh), this._audio?.context.off("refreshPaused", this.refreshPaused), this._audio = null, this._processors.forEach((e) => e.disconnect()), this._processors.length = 0, this._end = 0, this._playbackRate = 1, this._volume = 1, this._loop = !1, this._elapsed = 0, this._duration = 0, this._paused = !1, this._muted = !1, this._pausedReal = !1;
|
|
@@ -9537,8 +9559,8 @@ class En extends fe {
|
|
|
9537
9559
|
}
|
|
9538
9560
|
class Sn extends Ms {
|
|
9539
9561
|
constructor(e) {
|
|
9540
|
-
const t =
|
|
9541
|
-
s.connect(o), o.connect(i), i.connect(
|
|
9562
|
+
const t = xe.audioContext, s = t.createBufferSource(), i = t.createGain(), o = t.createAnalyser();
|
|
9563
|
+
s.connect(o), o.connect(i), i.connect(xe.instance.destination), super(o, i), this.parent = e, this._sourceNode = s, this.gain = i, this.analyser = o;
|
|
9542
9564
|
}
|
|
9543
9565
|
/** Source */
|
|
9544
9566
|
_sourceBuffer;
|
|
@@ -9548,7 +9570,7 @@ class Sn extends Ms {
|
|
|
9548
9570
|
gain;
|
|
9549
9571
|
analyser;
|
|
9550
9572
|
get context() {
|
|
9551
|
-
return
|
|
9573
|
+
return xe.instance;
|
|
9552
9574
|
}
|
|
9553
9575
|
get isPlayable() {
|
|
9554
9576
|
return !!this._sourceNode.buffer;
|
|
@@ -9574,7 +9596,7 @@ class Sn extends Ms {
|
|
|
9574
9596
|
}
|
|
9575
9597
|
_decode(e) {
|
|
9576
9598
|
return Promise.resolve(
|
|
9577
|
-
e instanceof AudioBuffer ? e :
|
|
9599
|
+
e instanceof AudioBuffer ? e : xe.decode(e)
|
|
9578
9600
|
).then((t) => (this.parent.isLoaded = !0, this.buffer = t, t));
|
|
9579
9601
|
}
|
|
9580
9602
|
cloneSource() {
|
|
@@ -9589,8 +9611,8 @@ var Cn = Object.defineProperty, An = Object.getOwnPropertyDescriptor, Rn = (r, e
|
|
|
9589
9611
|
for (var i = s > 1 ? void 0 : s ? An(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
9590
9612
|
(a = r[o]) && (i = a(i) || i);
|
|
9591
9613
|
return i;
|
|
9592
|
-
},
|
|
9593
|
-
let
|
|
9614
|
+
}, Mn = (r, e, t) => Rn(r, e + "", t);
|
|
9615
|
+
let we = class extends W {
|
|
9594
9616
|
_sounds = [];
|
|
9595
9617
|
/** PlatformAudio */
|
|
9596
9618
|
_platformAudio = vi ? new Sn(this) : new wn(this);
|
|
@@ -9696,7 +9718,7 @@ let xe = class extends W {
|
|
|
9696
9718
|
this._sounds.length = 0;
|
|
9697
9719
|
}
|
|
9698
9720
|
_createSound() {
|
|
9699
|
-
return
|
|
9721
|
+
return we._soundPool.length > 0 ? we._soundPool.pop().init(this._platformAudio) : this._platformAudio.createSound().init(this._platformAudio);
|
|
9700
9722
|
}
|
|
9701
9723
|
refresh() {
|
|
9702
9724
|
for (let r = this._sounds.length, e = 0; e < r; e++)
|
|
@@ -9714,7 +9736,7 @@ let xe = class extends W {
|
|
|
9714
9736
|
this._recycleSound(r);
|
|
9715
9737
|
};
|
|
9716
9738
|
_recycleSound(r) {
|
|
9717
|
-
r.destroy(),
|
|
9739
|
+
r.destroy(), we._soundPool.includes(r) || we._soundPool.push(r);
|
|
9718
9740
|
}
|
|
9719
9741
|
_prevTime = 0;
|
|
9720
9742
|
_timer = 0;
|
|
@@ -9732,19 +9754,19 @@ let xe = class extends W {
|
|
|
9732
9754
|
}, 100);
|
|
9733
9755
|
}
|
|
9734
9756
|
};
|
|
9735
|
-
|
|
9736
|
-
|
|
9737
|
-
|
|
9738
|
-
],
|
|
9739
|
-
class
|
|
9757
|
+
Mn(we, "_soundPool", []);
|
|
9758
|
+
we = On([
|
|
9759
|
+
g("Audio")
|
|
9760
|
+
], we);
|
|
9761
|
+
class kl extends Te {
|
|
9740
9762
|
//
|
|
9741
9763
|
}
|
|
9742
|
-
var
|
|
9764
|
+
var kn = Object.defineProperty, Un = Object.getOwnPropertyDescriptor, It = (r, e, t, s) => {
|
|
9743
9765
|
for (var i = s > 1 ? void 0 : s ? Un(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
9744
9766
|
(a = r[o]) && (i = (s ? a(e, t, i) : a(i)) || i);
|
|
9745
|
-
return s && i &&
|
|
9767
|
+
return s && i && kn(e, t, i), i;
|
|
9746
9768
|
};
|
|
9747
|
-
let ot = class extends
|
|
9769
|
+
let ot = class extends Se {
|
|
9748
9770
|
_audioBuffer;
|
|
9749
9771
|
_src = Ot ? new T(document.createElement("canvas")) : void 0;
|
|
9750
9772
|
_needsUpdateTexture = !1;
|
|
@@ -9765,7 +9787,7 @@ let ot = class extends Ee {
|
|
|
9765
9787
|
}
|
|
9766
9788
|
}
|
|
9767
9789
|
async _loadSrc(r) {
|
|
9768
|
-
await globalThis.fetch(r).then((e) => e.arrayBuffer()).then((e) =>
|
|
9790
|
+
await globalThis.fetch(r).then((e) => e.arrayBuffer()).then((e) => xe.decode(e)).then((e) => {
|
|
9769
9791
|
this._audioBuffer = e, this.syncTexture(!0);
|
|
9770
9792
|
});
|
|
9771
9793
|
}
|
|
@@ -9786,14 +9808,14 @@ let ot = class extends Ee {
|
|
|
9786
9808
|
}
|
|
9787
9809
|
o.fillStyle = this.color;
|
|
9788
9810
|
const a = e.getChannelData(0), n = Math.ceil(a.length / s), h = i / 2;
|
|
9789
|
-
for (let l = 1,
|
|
9811
|
+
for (let l = 1, c = -1, d = 0; d < s; d++) {
|
|
9790
9812
|
for (let f = 0; f < n; f++) {
|
|
9791
9813
|
const _ = a[d * n + f];
|
|
9792
|
-
_ < l && (l = _), _ >
|
|
9814
|
+
_ < l && (l = _), _ > c && (c = _);
|
|
9793
9815
|
}
|
|
9794
9816
|
if (!this.gap || d % (this.gap * 2) === 0) {
|
|
9795
|
-
const f = d, _ = (1 + l) * h, p = this.gap || 1, m = Math.max(1, (
|
|
9796
|
-
o.fillRect(f, _, p, m), l = 1,
|
|
9817
|
+
const f = d, _ = (1 + l) * h, p = this.gap || 1, m = Math.max(1, (c - l) * h);
|
|
9818
|
+
o.fillRect(f, _, p, m), l = 1, c = -1;
|
|
9797
9819
|
}
|
|
9798
9820
|
}
|
|
9799
9821
|
this._src?.requestUpload(), this.requestRedraw();
|
|
@@ -9810,55 +9832,55 @@ let ot = class extends Ee {
|
|
|
9810
9832
|
}
|
|
9811
9833
|
};
|
|
9812
9834
|
It([
|
|
9813
|
-
|
|
9835
|
+
u()
|
|
9814
9836
|
], ot.prototype, "src", 2);
|
|
9815
9837
|
It([
|
|
9816
|
-
|
|
9838
|
+
u({ fallback: 0 })
|
|
9817
9839
|
], ot.prototype, "gap", 2);
|
|
9818
9840
|
It([
|
|
9819
|
-
|
|
9841
|
+
u({ fallback: "#000000" })
|
|
9820
9842
|
], ot.prototype, "color", 2);
|
|
9821
9843
|
ot = It([
|
|
9822
|
-
|
|
9844
|
+
g("AudioWaveform")
|
|
9823
9845
|
], ot);
|
|
9824
9846
|
var Dn = Object.defineProperty, In = Object.getOwnPropertyDescriptor, Bn = (r, e, t) => e in r ? Dn(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, zn = (r, e, t, s) => {
|
|
9825
9847
|
for (var i = s > 1 ? void 0 : s ? In(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
9826
9848
|
(a = r[o]) && (i = a(i) || i);
|
|
9827
9849
|
return i;
|
|
9828
9850
|
}, Nn = (r, e, t) => Bn(r, e + "", t);
|
|
9829
|
-
let St = class extends
|
|
9851
|
+
let St = class extends Ue {
|
|
9830
9852
|
blur = 10;
|
|
9831
9853
|
quality = 10;
|
|
9832
9854
|
apply(r, e) {
|
|
9833
9855
|
const t = this.currentTimeProgress;
|
|
9834
9856
|
let s, i;
|
|
9835
9857
|
t < 0.5 ? (s = 0, i = (0.5 - t) / 0.5) : (s = 1, i = (t - 0.5) / 0.5);
|
|
9836
|
-
const o = this.blur, a = this.quality, n = e.width, h = e.height, l = [],
|
|
9858
|
+
const o = this.blur, a = this.quality, n = e.width, h = e.height, l = [], c = [o];
|
|
9837
9859
|
if (o > 0) {
|
|
9838
|
-
let
|
|
9839
|
-
const
|
|
9860
|
+
let v = o;
|
|
9861
|
+
const y = o / a;
|
|
9840
9862
|
for (let P = 1; P < a; P++)
|
|
9841
|
-
|
|
9863
|
+
v -= y, c.push(v);
|
|
9842
9864
|
}
|
|
9843
9865
|
const d = 1 / n, f = 1 / h, _ = [];
|
|
9844
9866
|
let p;
|
|
9845
9867
|
const m = a - 1;
|
|
9846
|
-
for (let
|
|
9847
|
-
p =
|
|
9868
|
+
for (let v = 0; v < m; v++)
|
|
9869
|
+
p = c[v] + 0.5, _[0] = p * d, _[1] = p * f, l.push({
|
|
9848
9870
|
offset: _
|
|
9849
9871
|
});
|
|
9850
|
-
p =
|
|
9872
|
+
p = c[m] + 0.5, _[0] = p * d, _[1] = p * f, l.push({
|
|
9851
9873
|
offset: _
|
|
9852
|
-
}), l.forEach((
|
|
9874
|
+
}), l.forEach((v) => {
|
|
9853
9875
|
b.draw(r, St.material, {
|
|
9854
9876
|
sampler: s,
|
|
9855
9877
|
progress: i,
|
|
9856
|
-
...
|
|
9878
|
+
...v
|
|
9857
9879
|
});
|
|
9858
9880
|
});
|
|
9859
9881
|
}
|
|
9860
9882
|
};
|
|
9861
|
-
Nn(St, "material", new
|
|
9883
|
+
Nn(St, "material", new w({
|
|
9862
9884
|
vert: `attribute vec2 position;
|
|
9863
9885
|
attribute vec2 uv;
|
|
9864
9886
|
varying vec2 vUv;
|
|
@@ -9884,14 +9906,14 @@ void main(void) {
|
|
|
9884
9906
|
}`
|
|
9885
9907
|
}));
|
|
9886
9908
|
St = zn([
|
|
9887
|
-
|
|
9909
|
+
g("KawaseTransition")
|
|
9888
9910
|
], St);
|
|
9889
9911
|
var Ln = Object.defineProperty, Fn = Object.getOwnPropertyDescriptor, $n = (r, e, t) => e in r ? Ln(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, Vn = (r, e, t, s) => {
|
|
9890
9912
|
for (var i = s > 1 ? void 0 : s ? Fn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
9891
9913
|
(a = r[o]) && (i = a(i) || i);
|
|
9892
9914
|
return i;
|
|
9893
9915
|
}, Gn = (r, e, t) => $n(r, e + "", t);
|
|
9894
|
-
let Ct = class extends
|
|
9916
|
+
let Ct = class extends Ue {
|
|
9895
9917
|
apply(r) {
|
|
9896
9918
|
b.draw(r, Ct.material, {
|
|
9897
9919
|
previous: 0,
|
|
@@ -9900,7 +9922,7 @@ let Ct = class extends Me {
|
|
|
9900
9922
|
});
|
|
9901
9923
|
}
|
|
9902
9924
|
};
|
|
9903
|
-
Gn(Ct, "material", new
|
|
9925
|
+
Gn(Ct, "material", new w({
|
|
9904
9926
|
vert: `attribute vec2 position;
|
|
9905
9927
|
attribute vec2 uv;
|
|
9906
9928
|
varying vec2 vUv;
|
|
@@ -9930,21 +9952,21 @@ void main() {
|
|
|
9930
9952
|
}`
|
|
9931
9953
|
}));
|
|
9932
9954
|
Ct = Vn([
|
|
9933
|
-
|
|
9955
|
+
g("LeftEraseTransition")
|
|
9934
9956
|
], Ct);
|
|
9935
9957
|
var Wn = Object.defineProperty, jn = Object.getOwnPropertyDescriptor, qn = (r, e, t) => e in r ? Wn(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, Xn = (r, e, t, s) => {
|
|
9936
9958
|
for (var i = s > 1 ? void 0 : s ? jn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
9937
9959
|
(a = r[o]) && (i = a(i) || i);
|
|
9938
9960
|
return i;
|
|
9939
9961
|
}, Hn = (r, e, t) => qn(r, e + "", t);
|
|
9940
|
-
let at = class extends
|
|
9962
|
+
let at = class extends Ue {
|
|
9941
9963
|
blur = 100;
|
|
9942
9964
|
gradientBlur = 600;
|
|
9943
9965
|
apply(r, e) {
|
|
9944
9966
|
const t = this.currentTimeProgress;
|
|
9945
9967
|
let s, i;
|
|
9946
9968
|
t < 0.5 ? (s = 0, i = (0.5 - t) / 0.5) : (s = 1, i = (t - 0.5) / 0.5);
|
|
9947
|
-
const o = e.width, a = e.height, n = [0, a / 2], h = [600, a / 2], l = [o, a],
|
|
9969
|
+
const o = e.width, a = e.height, n = [0, a / 2], h = [600, a / 2], l = [o, a], c = h[0] - n[0], d = h[1] - n[1], f = Math.sqrt(c * c + d * d);
|
|
9948
9970
|
b.draw(r, at.material, {
|
|
9949
9971
|
sampler: s,
|
|
9950
9972
|
progress: i,
|
|
@@ -9952,7 +9974,7 @@ let at = class extends Me {
|
|
|
9952
9974
|
gradientBlur: this.gradientBlur,
|
|
9953
9975
|
start: n,
|
|
9954
9976
|
end: h,
|
|
9955
|
-
delta: [
|
|
9977
|
+
delta: [c / f, d / f],
|
|
9956
9978
|
texSize: l
|
|
9957
9979
|
}), b.draw(r, at.material, {
|
|
9958
9980
|
sampler: s,
|
|
@@ -9961,12 +9983,12 @@ let at = class extends Me {
|
|
|
9961
9983
|
gradientBlur: this.gradientBlur,
|
|
9962
9984
|
start: n,
|
|
9963
9985
|
end: h,
|
|
9964
|
-
delta: [-d / f,
|
|
9986
|
+
delta: [-d / f, c / f],
|
|
9965
9987
|
texSize: l
|
|
9966
9988
|
});
|
|
9967
9989
|
}
|
|
9968
9990
|
};
|
|
9969
|
-
Hn(at, "material", new
|
|
9991
|
+
Hn(at, "material", new w({
|
|
9970
9992
|
vert: `attribute vec2 position;
|
|
9971
9993
|
attribute vec2 uv;
|
|
9972
9994
|
varying vec2 vUv;
|
|
@@ -10015,14 +10037,14 @@ void main(void) {
|
|
|
10015
10037
|
}`
|
|
10016
10038
|
}));
|
|
10017
10039
|
at = Xn([
|
|
10018
|
-
|
|
10040
|
+
g("TiltShiftTransition")
|
|
10019
10041
|
], at);
|
|
10020
10042
|
var Yn = Object.defineProperty, Kn = Object.getOwnPropertyDescriptor, Zn = (r, e, t) => e in r ? Yn(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, Jn = (r, e, t, s) => {
|
|
10021
10043
|
for (var i = s > 1 ? void 0 : s ? Kn(e, t) : e, o = r.length - 1, a; o >= 0; o--)
|
|
10022
10044
|
(a = r[o]) && (i = a(i) || i);
|
|
10023
10045
|
return i;
|
|
10024
10046
|
}, Qn = (r, e, t) => Zn(r, e + "", t);
|
|
10025
|
-
let At = class extends
|
|
10047
|
+
let At = class extends Ue {
|
|
10026
10048
|
radius;
|
|
10027
10049
|
angle = 4;
|
|
10028
10050
|
padding = 20;
|
|
@@ -10043,7 +10065,7 @@ let At = class extends Me {
|
|
|
10043
10065
|
});
|
|
10044
10066
|
}
|
|
10045
10067
|
};
|
|
10046
|
-
Qn(At, "material", new
|
|
10068
|
+
Qn(At, "material", new w({
|
|
10047
10069
|
vert: `attribute vec2 position;
|
|
10048
10070
|
attribute vec2 uv;
|
|
10049
10071
|
varying vec2 vUv;
|
|
@@ -10094,72 +10116,66 @@ void main(void) {
|
|
|
10094
10116
|
}`
|
|
10095
10117
|
}));
|
|
10096
10118
|
At = Jn([
|
|
10097
|
-
|
|
10119
|
+
g("TwistTransition")
|
|
10098
10120
|
], At);
|
|
10099
|
-
class el extends
|
|
10121
|
+
class el extends Ce {
|
|
10100
10122
|
install(e) {
|
|
10101
10123
|
const t = async (s) => {
|
|
10102
10124
|
const { decodeFrames: i } = await import("modern-gif");
|
|
10103
|
-
return await
|
|
10125
|
+
return await s.arrayBuffer().then((o) => i(
|
|
10104
10126
|
o,
|
|
10105
10127
|
e.gifWorkerUrl ? { workerUrl: e.gifWorkerUrl } : void 0
|
|
10106
|
-
)).then((o) => new
|
|
10128
|
+
)).then((o) => new $t(
|
|
10107
10129
|
o.map((a) => ({
|
|
10108
10130
|
duration: a.delay,
|
|
10109
|
-
texture: new
|
|
10131
|
+
texture: new es(a.data, a.width, a.height)
|
|
10110
10132
|
}))
|
|
10111
10133
|
));
|
|
10112
10134
|
};
|
|
10113
|
-
return this.load = (s) => e.loadBy(s
|
|
10135
|
+
return this.load = (s) => typeof s == "string" ? e.loadBy(s).then(t) : t(s), [
|
|
10114
10136
|
"image/gif"
|
|
10115
10137
|
].forEach((s) => {
|
|
10116
10138
|
e.register(s, t);
|
|
10117
10139
|
}), e.gif = this, this;
|
|
10118
10140
|
}
|
|
10119
10141
|
}
|
|
10120
|
-
class tl extends
|
|
10142
|
+
class tl extends Ce {
|
|
10121
10143
|
install(e) {
|
|
10122
|
-
const t = (s) =>
|
|
10123
|
-
return this.load = (s) => e.loadBy(s
|
|
10124
|
-
"json"
|
|
10144
|
+
const t = async (s) => JSON.parse(await s.text());
|
|
10145
|
+
return this.load = (s) => typeof s == "string" ? e.loadBy(s).then(t) : t(s), [
|
|
10146
|
+
"application/json"
|
|
10125
10147
|
].forEach((s) => {
|
|
10126
10148
|
e.register(s, t);
|
|
10127
10149
|
}), e.json = this, this;
|
|
10128
10150
|
}
|
|
10129
10151
|
}
|
|
10130
|
-
class rl extends
|
|
10152
|
+
class rl extends Ce {
|
|
10131
10153
|
install(e) {
|
|
10132
|
-
|
|
10154
|
+
return this.load = async (t, s) => (await import("lottie-web").then((o) => o.default)).loadAnimation({
|
|
10133
10155
|
container: null,
|
|
10134
10156
|
renderer: "canvas",
|
|
10135
10157
|
rendererSettings: {
|
|
10136
|
-
context:
|
|
10158
|
+
context: s.getContext("2d")
|
|
10137
10159
|
},
|
|
10138
10160
|
loop: !1,
|
|
10139
10161
|
autoplay: !1,
|
|
10140
10162
|
animationData: await e.loadBy(
|
|
10141
|
-
|
|
10142
|
-
() => e.fetch(
|
|
10163
|
+
t,
|
|
10164
|
+
() => e.fetch(t).then((o) => o.json())
|
|
10143
10165
|
)
|
|
10144
|
-
});
|
|
10145
|
-
return this.load = (s, i) => t(s, i), [
|
|
10146
|
-
"lottie"
|
|
10147
|
-
].forEach((s) => {
|
|
10148
|
-
e.register(s, t);
|
|
10149
10166
|
}), e.lottie = this, this;
|
|
10150
10167
|
}
|
|
10151
10168
|
}
|
|
10152
|
-
class sl extends
|
|
10169
|
+
class sl extends Ce {
|
|
10153
10170
|
install(e) {
|
|
10154
|
-
const t = async (s) =>
|
|
10155
|
-
return this.load = (s) => e.loadBy(s
|
|
10171
|
+
const t = async (s) => s.text();
|
|
10172
|
+
return this.load = (s) => typeof s == "string" ? e.loadBy(s).then(t) : t(s), e.text = this, this;
|
|
10156
10173
|
}
|
|
10157
10174
|
}
|
|
10158
|
-
class il extends
|
|
10175
|
+
class il extends Ce {
|
|
10159
10176
|
install(e) {
|
|
10160
10177
|
const t = (s) => e.fetchImageBitmap(s, { premultiplyAlpha: "premultiply" }).then((i) => new T(i));
|
|
10161
|
-
return this.load = (s) => e.loadBy(s
|
|
10162
|
-
"image/gif",
|
|
10178
|
+
return this.load = (s) => typeof s == "string" ? e.loadBy(s).then(t) : t(s), [
|
|
10163
10179
|
"image/jpeg",
|
|
10164
10180
|
"image/png",
|
|
10165
10181
|
"image/tiff",
|
|
@@ -10174,38 +10190,17 @@ class il extends Se {
|
|
|
10174
10190
|
}), e.texture = this, this;
|
|
10175
10191
|
}
|
|
10176
10192
|
}
|
|
10177
|
-
class ol extends
|
|
10193
|
+
class ol extends Ce {
|
|
10178
10194
|
install(e) {
|
|
10179
|
-
|
|
10180
|
-
return this.load = (s) => e.loadBy(s, () => t(s)), [
|
|
10181
|
-
"video/3gpp",
|
|
10182
|
-
"video/mpeg",
|
|
10183
|
-
"video/quicktime",
|
|
10184
|
-
"video/x-flv",
|
|
10185
|
-
"video/x-mng",
|
|
10186
|
-
"video/x-ms-asf",
|
|
10187
|
-
"video/x-ms-wmv",
|
|
10188
|
-
"video/x-msvideo",
|
|
10189
|
-
"video/mp4"
|
|
10190
|
-
].forEach((s) => {
|
|
10191
|
-
e.register(s, t);
|
|
10192
|
-
}), e.video = this, this;
|
|
10195
|
+
return this.load = (t) => new _o(t).load(), e.video = this, this;
|
|
10193
10196
|
}
|
|
10194
10197
|
}
|
|
10195
10198
|
const al = Object.entries({
|
|
10196
|
-
"
|
|
10197
|
-
"
|
|
10198
|
-
"
|
|
10199
|
+
"font/woff": ["woff"],
|
|
10200
|
+
"font/ttf": ["ttf"],
|
|
10201
|
+
"font/otf": ["otf"],
|
|
10199
10202
|
"image/gif": ["gif"],
|
|
10200
10203
|
"image/jpeg": ["jpeg", "jpg"],
|
|
10201
|
-
"application/x-javascript": ["js"],
|
|
10202
|
-
"application/atom+xml": ["atom"],
|
|
10203
|
-
"application/rss+xml": ["rss"],
|
|
10204
|
-
"text/mathml": ["mml"],
|
|
10205
|
-
"text/plain": ["txt"],
|
|
10206
|
-
"text/vnd.sun.j2me.app-descriptor": ["jad"],
|
|
10207
|
-
"text/vnd.wap.wml": ["wml"],
|
|
10208
|
-
"text/x-component": ["htc"],
|
|
10209
10204
|
"image/png": ["png"],
|
|
10210
10205
|
"image/tiff": ["tif", "tiff"],
|
|
10211
10206
|
"image/vnd.wap.wbmp": ["wbmp"],
|
|
@@ -10214,55 +10209,14 @@ const al = Object.entries({
|
|
|
10214
10209
|
"image/x-ms-bmp": ["bmp"],
|
|
10215
10210
|
"image/svg+xml": ["svg"],
|
|
10216
10211
|
"image/webp": ["webp"],
|
|
10217
|
-
"application/
|
|
10218
|
-
"application/mac-binhex40": ["hqx"],
|
|
10219
|
-
"application/msword": ["doc"],
|
|
10220
|
-
"application/pdf": ["pdf"],
|
|
10221
|
-
"application/postscript": ["ps", "eps", "ai"],
|
|
10222
|
-
"application/rtf": ["rtf"],
|
|
10223
|
-
"application/vnd.ms-excel": ["xls"],
|
|
10224
|
-
"application/vnd.ms-powerpoint": ["ppt"],
|
|
10225
|
-
"application/vnd.wap.wmlc": ["wmlc"],
|
|
10226
|
-
"application/vnd.google-earth.kml+xml": ["kml"],
|
|
10227
|
-
"application/vnd.google-earth.kmz": ["kmz"],
|
|
10228
|
-
"application/x-7z-compressed": ["7z"],
|
|
10229
|
-
"application/x-cocoa": ["cco"],
|
|
10230
|
-
"application/x-java-archive-diff": ["jardiff"],
|
|
10231
|
-
"application/x-java-jnlp-file": ["jnlp"],
|
|
10232
|
-
"application/x-makeself": ["run"],
|
|
10233
|
-
"application/x-perl": ["pl", "pm"],
|
|
10234
|
-
"application/x-pilot": ["prc", "pdb"],
|
|
10235
|
-
"application/x-rar-compressed": ["rar"],
|
|
10236
|
-
"application/x-redhat-package-manager": ["rpm"],
|
|
10237
|
-
"application/x-sea": ["sea"],
|
|
10238
|
-
"application/x-shockwave-flash": ["swf"],
|
|
10239
|
-
"application/x-stuffit": ["sit"],
|
|
10240
|
-
"application/x-tcl": ["tcl", "tk"],
|
|
10241
|
-
"application/x-x509-ca-cert": ["der", "pem", "crt"],
|
|
10242
|
-
"application/x-xpinstall": ["xpi"],
|
|
10243
|
-
"application/xhtml+xml": ["xhtml"],
|
|
10244
|
-
"application/zip": ["zip"],
|
|
10245
|
-
"application/octet-stream": ["bin", "exe", "dll", "deb", "dmg", "eot", "iso", "img", "msi", "msp", "msm"],
|
|
10246
|
-
"audio/midi": ["mid", "midi", "kar"],
|
|
10247
|
-
"audio/mpeg": ["mp3"],
|
|
10248
|
-
"audio/ogg": ["ogg"],
|
|
10249
|
-
"audio/x-realaudio": ["ra"],
|
|
10250
|
-
"video/3gpp": ["3gpp", "3gp"],
|
|
10251
|
-
"video/mpeg": ["mpeg", "mpg"],
|
|
10252
|
-
"video/quicktime": ["mov"],
|
|
10253
|
-
"video/x-flv": ["flv"],
|
|
10254
|
-
"video/x-mng": ["mng"],
|
|
10255
|
-
"video/x-ms-asf": ["asx", "asf"],
|
|
10256
|
-
"video/x-ms-wmv": ["wmv"],
|
|
10257
|
-
"video/x-msvideo": ["avi"],
|
|
10258
|
-
"video/mp4": ["m4v", "mp4"]
|
|
10212
|
+
"application/json": ["json"]
|
|
10259
10213
|
});
|
|
10260
10214
|
function nl(r) {
|
|
10261
10215
|
for (const [e, t] of al)
|
|
10262
10216
|
if (t.includes(r))
|
|
10263
10217
|
return e;
|
|
10264
10218
|
}
|
|
10265
|
-
|
|
10219
|
+
function ll(r) {
|
|
10266
10220
|
let e;
|
|
10267
10221
|
if (r.startsWith("data:"))
|
|
10268
10222
|
e = r.match(/^data:(.+?);/)?.[1];
|
|
@@ -10270,11 +10224,11 @@ async function ll(r) {
|
|
|
10270
10224
|
const t = r.split(/[#?]/)[0].split(".").pop()?.trim();
|
|
10271
10225
|
t && (e = nl(t));
|
|
10272
10226
|
}
|
|
10273
|
-
return e
|
|
10227
|
+
return e;
|
|
10274
10228
|
}
|
|
10275
10229
|
const vt = "WeakRef" in globalThis;
|
|
10276
10230
|
class hl extends fe {
|
|
10277
|
-
defaultHandler = (e) =>
|
|
10231
|
+
defaultHandler = (e) => e;
|
|
10278
10232
|
_handlers = /* @__PURE__ */ new Map();
|
|
10279
10233
|
_handleing = /* @__PURE__ */ new Map();
|
|
10280
10234
|
_handled = /* @__PURE__ */ new Map();
|
|
@@ -10283,7 +10237,7 @@ class hl extends fe {
|
|
|
10283
10237
|
t && "destroy" in t && t.destroy(), this._handled.delete(e);
|
|
10284
10238
|
}) : void 0;
|
|
10285
10239
|
constructor() {
|
|
10286
|
-
super(), vt ||
|
|
10240
|
+
super(), vt || U.on(this.gc.bind(this), { sort: 2 });
|
|
10287
10241
|
}
|
|
10288
10242
|
use(e) {
|
|
10289
10243
|
return e.install(this), this;
|
|
@@ -10305,26 +10259,30 @@ class hl extends fe {
|
|
|
10305
10259
|
return `data:image/svg+xml;charset=utf-8,${encodeURIComponent(s.outerHTML)}`;
|
|
10306
10260
|
}
|
|
10307
10261
|
async fetchImageBitmap(e, t) {
|
|
10308
|
-
|
|
10309
|
-
this.
|
|
10310
|
-
|
|
10311
|
-
|
|
10312
|
-
|
|
10313
|
-
|
|
10314
|
-
|
|
10315
|
-
|
|
10316
|
-
i
|
|
10317
|
-
|
|
10318
|
-
|
|
10319
|
-
|
|
10320
|
-
|
|
10321
|
-
|
|
10322
|
-
|
|
10323
|
-
|
|
10324
|
-
|
|
10325
|
-
|
|
10326
|
-
|
|
10327
|
-
|
|
10262
|
+
if (e instanceof Blob || typeof e == "string" && e.startsWith("http")) {
|
|
10263
|
+
const s = e instanceof Blob ? e : await this.fetch(e).then((i) => i.blob());
|
|
10264
|
+
return s.type === "image/svg+xml" ? s.text().then((i) => this.fetchImageBitmap(
|
|
10265
|
+
this._fixSVG(`data:image/svg+xml;charset=utf-8,${encodeURIComponent(i)}`),
|
|
10266
|
+
t
|
|
10267
|
+
)) : createImageBitmap(s, t);
|
|
10268
|
+
} else
|
|
10269
|
+
return e.startsWith("data:image/svg+xml;") && (e = this._fixSVG(e)), new Promise((s) => {
|
|
10270
|
+
const i = new Image();
|
|
10271
|
+
i.onerror = () => {
|
|
10272
|
+
console.warn(`Failed load image error: ${e}`), s(i);
|
|
10273
|
+
}, i.onload = () => {
|
|
10274
|
+
i.decode().finally(() => {
|
|
10275
|
+
s(i);
|
|
10276
|
+
});
|
|
10277
|
+
}, i.src = e;
|
|
10278
|
+
}).then((s) => {
|
|
10279
|
+
if (s.complete && s.naturalWidth && s.naturalHeight)
|
|
10280
|
+
return createImageBitmap(s, t);
|
|
10281
|
+
{
|
|
10282
|
+
const i = document.createElement("canvas");
|
|
10283
|
+
return i.width = 1, i.height = 1, createImageBitmap(i);
|
|
10284
|
+
}
|
|
10285
|
+
});
|
|
10328
10286
|
}
|
|
10329
10287
|
get(e) {
|
|
10330
10288
|
let t = this._handled.get(e);
|
|
@@ -10334,7 +10292,7 @@ class hl extends fe {
|
|
|
10334
10292
|
let s = t;
|
|
10335
10293
|
vt && typeof t == "object" && (this._gc.register(t, e), s = new WeakRef(t)), this._handled.set(e, s);
|
|
10336
10294
|
}
|
|
10337
|
-
async loadBy(e, t) {
|
|
10295
|
+
async loadBy(e, t = () => this.fetch(e).then((s) => s.blob())) {
|
|
10338
10296
|
const s = this.get(e) ?? this._handleing.get(e);
|
|
10339
10297
|
if (s)
|
|
10340
10298
|
return s;
|
|
@@ -10344,10 +10302,9 @@ class hl extends fe {
|
|
|
10344
10302
|
return this._handleing.set(e, i), i;
|
|
10345
10303
|
}
|
|
10346
10304
|
async load(e, t) {
|
|
10347
|
-
|
|
10348
|
-
|
|
10349
|
-
|
|
10350
|
-
});
|
|
10305
|
+
const s = await this.loadBy(e);
|
|
10306
|
+
let i = ll(e);
|
|
10307
|
+
return i === void 0 && (i = s.type?.split(";")[0] ?? void 0), ((i ? this._handlers.get(i) : void 0) ?? this.defaultHandler)(s, t);
|
|
10351
10308
|
}
|
|
10352
10309
|
async waitUntilLoad() {
|
|
10353
10310
|
await Promise.all(
|
|
@@ -10363,13 +10320,13 @@ class hl extends fe {
|
|
|
10363
10320
|
}), this._handled.clear();
|
|
10364
10321
|
}
|
|
10365
10322
|
}
|
|
10366
|
-
const
|
|
10367
|
-
var cl = Object.defineProperty,
|
|
10323
|
+
const z = new hl().use(new to()).use(new el()).use(new tl()).use(new rl()).use(new sl()).use(new il()).use(new ol());
|
|
10324
|
+
var cl = Object.defineProperty, ks = (r, e, t, s) => {
|
|
10368
10325
|
for (var i = void 0, o = r.length - 1, a; o >= 0; o--)
|
|
10369
10326
|
(a = r[o]) && (i = a(e, t, i) || i);
|
|
10370
10327
|
return i && cl(e, t, i), i;
|
|
10371
10328
|
};
|
|
10372
|
-
const
|
|
10329
|
+
const Me = {
|
|
10373
10330
|
alpha: !0,
|
|
10374
10331
|
stencil: !0,
|
|
10375
10332
|
antialias: !1,
|
|
@@ -10377,7 +10334,7 @@ const Oe = {
|
|
|
10377
10334
|
preserveDrawingBuffer: !1,
|
|
10378
10335
|
powerPreference: "default"
|
|
10379
10336
|
};
|
|
10380
|
-
class
|
|
10337
|
+
class hr extends me {
|
|
10381
10338
|
renderer;
|
|
10382
10339
|
get view() {
|
|
10383
10340
|
return this.renderer.view;
|
|
@@ -10412,16 +10369,16 @@ class Bt extends Ae {
|
|
|
10412
10369
|
view: t,
|
|
10413
10370
|
width: s,
|
|
10414
10371
|
height: i,
|
|
10415
|
-
pixelRatio: o =
|
|
10372
|
+
pixelRatio: o = Wr,
|
|
10416
10373
|
autoResize: a
|
|
10417
10374
|
} = e;
|
|
10418
10375
|
super(), this.renderer = new eo(t, {
|
|
10419
|
-
alpha:
|
|
10420
|
-
stencil:
|
|
10421
|
-
antialias:
|
|
10422
|
-
premultipliedAlpha:
|
|
10423
|
-
preserveDrawingBuffer:
|
|
10424
|
-
powerPreference:
|
|
10376
|
+
alpha: Me.alpha ?? e.alpha,
|
|
10377
|
+
stencil: Me.stencil ?? e.stencil,
|
|
10378
|
+
antialias: Me.antialias ?? e.antialias,
|
|
10379
|
+
premultipliedAlpha: Me.premultipliedAlpha ?? e.premultipliedAlpha,
|
|
10380
|
+
preserveDrawingBuffer: Me.preserveDrawingBuffer ?? e.preserveDrawingBuffer,
|
|
10381
|
+
powerPreference: Me.powerPreference ?? e.powerPreference
|
|
10425
10382
|
}), this._setupInput(), this.pixelRatio = o, a ? !t && this.renderer.view && (this.renderer.view.style.width = "100%", this.renderer.view.style.height = "100%") : this.resize(
|
|
10426
10383
|
s || this.gl.drawingBufferWidth || this.view?.clientWidth || 200,
|
|
10427
10384
|
i || this.gl.drawingBufferHeight || this.view?.clientHeight || 200,
|
|
@@ -10458,13 +10415,13 @@ class Bt extends Ae {
|
|
|
10458
10415
|
return this.renderer.resize(e, t, s), this.root.width = e, this.root.height = t, this.root.requestUpload(), this.render(), this;
|
|
10459
10416
|
}
|
|
10460
10417
|
nextTick() {
|
|
10461
|
-
return
|
|
10418
|
+
return Nr();
|
|
10462
10419
|
}
|
|
10463
10420
|
async waitUntilLoad() {
|
|
10464
|
-
await
|
|
10421
|
+
await z.waitUntilLoad(), await this.nextTick();
|
|
10465
10422
|
}
|
|
10466
10423
|
async waitAndRender(e = 0) {
|
|
10467
|
-
await
|
|
10424
|
+
await z.waitUntilLoad(), this._process(e), await this.nextTick(), this._render(this.renderer);
|
|
10468
10425
|
}
|
|
10469
10426
|
render(e = 0) {
|
|
10470
10427
|
this._process(e), this._render(this.renderer);
|
|
@@ -10508,22 +10465,19 @@ class Bt extends Ae {
|
|
|
10508
10465
|
this._resizeObserver?.disconnect(), this.renderer.destroy(), super.destroy();
|
|
10509
10466
|
}
|
|
10510
10467
|
}
|
|
10511
|
-
|
|
10512
|
-
|
|
10513
|
-
],
|
|
10514
|
-
|
|
10515
|
-
|
|
10516
|
-
],
|
|
10517
|
-
|
|
10518
|
-
|
|
10519
|
-
|
|
10520
|
-
let I;
|
|
10521
|
-
const qt = [];
|
|
10522
|
-
let $t = !1;
|
|
10468
|
+
ks([
|
|
10469
|
+
u({ fallback: !1 })
|
|
10470
|
+
], hr.prototype, "autoResize");
|
|
10471
|
+
ks([
|
|
10472
|
+
u({ fallback: !1 })
|
|
10473
|
+
], hr.prototype, "autoStart");
|
|
10474
|
+
let k;
|
|
10475
|
+
const jt = [];
|
|
10476
|
+
let Ft = !1;
|
|
10523
10477
|
async function ul(r = 100) {
|
|
10524
|
-
if (
|
|
10525
|
-
for (
|
|
10526
|
-
const e =
|
|
10478
|
+
if (!Ft) {
|
|
10479
|
+
for (Ft = !0; jt.length; ) {
|
|
10480
|
+
const e = jt.shift();
|
|
10527
10481
|
if (e)
|
|
10528
10482
|
try {
|
|
10529
10483
|
await e();
|
|
@@ -10533,7 +10487,7 @@ async function ul(r = 100) {
|
|
|
10533
10487
|
else
|
|
10534
10488
|
await new Promise((t) => setTimeout(t, r));
|
|
10535
10489
|
}
|
|
10536
|
-
|
|
10490
|
+
Ft = !1;
|
|
10537
10491
|
}
|
|
10538
10492
|
}
|
|
10539
10493
|
async function dl(r) {
|
|
@@ -10545,49 +10499,50 @@ async function dl(r) {
|
|
|
10545
10499
|
data: o,
|
|
10546
10500
|
keyframes: a = [],
|
|
10547
10501
|
onBefore: n,
|
|
10548
|
-
onKeyframe: h
|
|
10502
|
+
onKeyframe: h,
|
|
10503
|
+
...l
|
|
10549
10504
|
} = r;
|
|
10550
|
-
return
|
|
10505
|
+
return k ??= new hr({
|
|
10551
10506
|
pixelRatio: 1,
|
|
10552
10507
|
width: 1,
|
|
10553
10508
|
height: 1,
|
|
10554
10509
|
preserveDrawingBuffer: !0
|
|
10555
|
-
}),
|
|
10556
|
-
|
|
10557
|
-
}), await n?.(
|
|
10558
|
-
let
|
|
10559
|
-
const
|
|
10560
|
-
async function
|
|
10561
|
-
if (
|
|
10562
|
-
return
|
|
10563
|
-
const
|
|
10564
|
-
|
|
10565
|
-
currentTime:
|
|
10566
|
-
duration:
|
|
10567
|
-
progress:
|
|
10568
|
-
}), requestAnimationFrame(
|
|
10569
|
-
}
|
|
10570
|
-
|
|
10571
|
-
}),
|
|
10510
|
+
}), k.resetProperties(), k.setProperties(l), k.debug = e, k.fonts = t, k.timeline.currentTime = 0, k.root.removeChildren(), k.resize(s, i, !0), (Array.isArray(o) ? o : [o]).forEach((c) => {
|
|
10511
|
+
c instanceof M ? (c.parent = void 0, k.root.appendChild(c)) : k.root.appendChild(M.parse(c));
|
|
10512
|
+
}), await n?.(k), await k.waitAndRender(), a.length && await new Promise((c) => {
|
|
10513
|
+
let d = 0;
|
|
10514
|
+
const f = a.length, _ = a[f - 1];
|
|
10515
|
+
async function p() {
|
|
10516
|
+
if (d === f)
|
|
10517
|
+
return c();
|
|
10518
|
+
const m = a[d++], y = (a[d] || m) - m;
|
|
10519
|
+
k.timeline.currentTime = m, k.render(), await h?.(k.toPixels(), {
|
|
10520
|
+
currentTime: m,
|
|
10521
|
+
duration: y,
|
|
10522
|
+
progress: _ !== 0 ? m / _ : 1
|
|
10523
|
+
}), requestAnimationFrame(p);
|
|
10524
|
+
}
|
|
10525
|
+
p();
|
|
10526
|
+
}), k.toCanvas2D();
|
|
10572
10527
|
}
|
|
10573
10528
|
async function Ul(r) {
|
|
10574
10529
|
return new Promise((e) => {
|
|
10575
|
-
|
|
10530
|
+
jt.push(async () => e(await dl(r))), ul();
|
|
10576
10531
|
});
|
|
10577
10532
|
}
|
|
10578
10533
|
export {
|
|
10579
|
-
|
|
10534
|
+
$t as AnimatedTexture,
|
|
10580
10535
|
it as Animation,
|
|
10581
10536
|
hl as Assets,
|
|
10582
|
-
|
|
10537
|
+
we as Audio,
|
|
10583
10538
|
Ms as AudioPipeline,
|
|
10584
|
-
|
|
10585
|
-
|
|
10539
|
+
Ml as AudioProcessor,
|
|
10540
|
+
kl as AudioSpectrum,
|
|
10586
10541
|
ot as AudioWaveform,
|
|
10587
10542
|
st as BaseElement2D,
|
|
10588
|
-
|
|
10589
|
-
|
|
10590
|
-
|
|
10543
|
+
Es as BaseElement2DBackground,
|
|
10544
|
+
I as BaseElement2DFill,
|
|
10545
|
+
Ss as BaseElement2DForeground,
|
|
10591
10546
|
Ge as BaseElement2DOutline,
|
|
10592
10547
|
We as BaseElement2DShadow,
|
|
10593
10548
|
je as BaseElement2DShape,
|
|
@@ -10595,107 +10550,107 @@ export {
|
|
|
10595
10550
|
te as BaseElement2DText,
|
|
10596
10551
|
Pt as Camera2D,
|
|
10597
10552
|
mo as CanvasContext,
|
|
10598
|
-
|
|
10599
|
-
|
|
10553
|
+
Pe as CanvasItem,
|
|
10554
|
+
Jt as CanvasTexture,
|
|
10600
10555
|
J as Color,
|
|
10601
|
-
|
|
10556
|
+
V as ColorAdjustEffect,
|
|
10602
10557
|
Je as ColorFilterEffect,
|
|
10603
|
-
|
|
10604
|
-
|
|
10605
|
-
|
|
10606
|
-
|
|
10558
|
+
Hr as ColorMatrix,
|
|
10559
|
+
De as ColorOverlayEffect,
|
|
10560
|
+
Ie as ColorRemoveEffect,
|
|
10561
|
+
Be as ColorReplaceEffect,
|
|
10607
10562
|
Al as ColorTexture,
|
|
10608
10563
|
pe as CoreObject,
|
|
10609
10564
|
Di as DEG_TO_RAD,
|
|
10610
|
-
|
|
10565
|
+
Wr as DEVICE_PIXEL_RATIO,
|
|
10611
10566
|
q as DrawboardEffect,
|
|
10612
10567
|
Q as DropShadowEffect,
|
|
10613
|
-
|
|
10568
|
+
x as Effect,
|
|
10614
10569
|
yt as EffectMaterial,
|
|
10615
|
-
|
|
10616
|
-
|
|
10570
|
+
Se as Element2D,
|
|
10571
|
+
Cs as Element2DStyle,
|
|
10617
10572
|
Qe as EmbossEffect,
|
|
10618
|
-
|
|
10619
|
-
|
|
10573
|
+
hr as Engine,
|
|
10574
|
+
Ur as FlexElement2D,
|
|
10620
10575
|
Qa as FlexElement2DStyle,
|
|
10621
|
-
|
|
10576
|
+
nr as FlexLayout,
|
|
10622
10577
|
to as FontLoader,
|
|
10623
10578
|
ae as GaussianBlurEffect,
|
|
10624
|
-
|
|
10579
|
+
Zt as Geometry,
|
|
10625
10580
|
el as GifLoader,
|
|
10626
|
-
|
|
10581
|
+
N as GlitchEffect,
|
|
10627
10582
|
X as GodrayEffect,
|
|
10628
|
-
|
|
10583
|
+
kt as GradientTexture,
|
|
10629
10584
|
wn as HTMLAudio,
|
|
10630
|
-
|
|
10585
|
+
lr as HTMLAudioContext,
|
|
10631
10586
|
Et as HTMLSound,
|
|
10632
10587
|
Ot as IN_BROWSER,
|
|
10633
10588
|
bi as IN_MAC_OS,
|
|
10634
|
-
|
|
10589
|
+
ze as Image2D,
|
|
10635
10590
|
Rl as ImageTexture,
|
|
10636
10591
|
nt as IndexBuffer,
|
|
10637
10592
|
Oi as Input,
|
|
10638
|
-
|
|
10593
|
+
Mt as InputEvent,
|
|
10639
10594
|
tl as JsonLoader,
|
|
10640
10595
|
et as KawaseBlurEffect,
|
|
10641
10596
|
St as KawaseTransition,
|
|
10642
10597
|
Si as KeyboardInputEvent,
|
|
10643
10598
|
Ct as LeftEraseTransition,
|
|
10644
|
-
|
|
10645
|
-
|
|
10599
|
+
Ce as Loader,
|
|
10600
|
+
Gt as Lottie2D,
|
|
10646
10601
|
rl as LottieLoader,
|
|
10647
|
-
|
|
10648
|
-
|
|
10649
|
-
|
|
10602
|
+
Yt as MainLoop,
|
|
10603
|
+
Ee as MaskEffect,
|
|
10604
|
+
w as Material,
|
|
10650
10605
|
se as Matrix,
|
|
10651
10606
|
Tl as Matrix2,
|
|
10652
|
-
|
|
10607
|
+
Yr as Matrix3,
|
|
10653
10608
|
Ui as Matrix4,
|
|
10654
10609
|
vo as Meta,
|
|
10655
|
-
|
|
10656
|
-
|
|
10657
|
-
|
|
10658
|
-
|
|
10659
|
-
|
|
10610
|
+
Xr as MouseInputEvent,
|
|
10611
|
+
M as Node,
|
|
10612
|
+
Te as Node2D,
|
|
10613
|
+
D as OutlineEffect,
|
|
10614
|
+
Ht as PI,
|
|
10660
10615
|
B as PI_2,
|
|
10661
10616
|
tt as PixelateEffect,
|
|
10662
|
-
|
|
10617
|
+
es as PixelsTexture,
|
|
10663
10618
|
Ci as PointerInputEvent,
|
|
10664
10619
|
Bi as Projection2D,
|
|
10665
10620
|
Sl as QuadGeometry,
|
|
10666
10621
|
b as QuadUvGeometry,
|
|
10667
10622
|
wl as RAD_TO_DEG,
|
|
10668
|
-
|
|
10669
|
-
|
|
10670
|
-
|
|
10671
|
-
|
|
10623
|
+
qr as RawWeakMap,
|
|
10624
|
+
ye as Rect2,
|
|
10625
|
+
ki as RefCounted,
|
|
10626
|
+
Kt as Renderer,
|
|
10672
10627
|
_e as Resource,
|
|
10673
|
-
|
|
10628
|
+
$r as SUPPORTS_AUDIO_CONTEXT,
|
|
10674
10629
|
mi as SUPPORTS_CLICK_EVENTS,
|
|
10675
|
-
|
|
10630
|
+
Fr as SUPPORTS_CREATE_IMAGE_BITMAP,
|
|
10676
10631
|
fi as SUPPORTS_IMAGE_BITMAP,
|
|
10677
10632
|
yl as SUPPORTS_MOUSE_EVENTS,
|
|
10678
|
-
|
|
10633
|
+
Gr as SUPPORTS_OFFLINE_AUDIO_CONTEXT,
|
|
10679
10634
|
He as SUPPORTS_POINTER_EVENTS,
|
|
10680
10635
|
pi as SUPPORTS_RESIZE_OBSERVER,
|
|
10681
10636
|
ce as SUPPORTS_TOUCH_EVENTS,
|
|
10682
10637
|
di as SUPPORTS_WEBGL2,
|
|
10683
|
-
|
|
10638
|
+
Vr as SUPPORTS_WEBKIT_AUDIO_CONTEXT,
|
|
10684
10639
|
gi as SUPPORTS_WEBKIT_OFFLINE_AUDIO_CONTEXT,
|
|
10685
10640
|
vi as SUPPORTS_WEB_AUDIO,
|
|
10686
10641
|
_i as SUPPORTS_WHEEL_EVENTS,
|
|
10687
|
-
|
|
10642
|
+
me as SceneTree,
|
|
10688
10643
|
sl as TextLoader,
|
|
10689
10644
|
T as Texture2D,
|
|
10690
10645
|
il as TextureLoader,
|
|
10691
|
-
|
|
10692
|
-
|
|
10646
|
+
As as TextureRect2D,
|
|
10647
|
+
U as Ticker,
|
|
10693
10648
|
at as TiltShiftTransition,
|
|
10694
10649
|
oe as Timeline,
|
|
10695
10650
|
W as TimelineNode,
|
|
10696
10651
|
O as Transform2D,
|
|
10697
10652
|
dn as TransformRect2D,
|
|
10698
|
-
|
|
10653
|
+
Ue as Transition,
|
|
10699
10654
|
At as TwistTransition,
|
|
10700
10655
|
Cl as UvGeometry,
|
|
10701
10656
|
xt as UvMaterial,
|
|
@@ -10703,15 +10658,15 @@ export {
|
|
|
10703
10658
|
C as Vector2,
|
|
10704
10659
|
El as Vector3,
|
|
10705
10660
|
Ii as Vector4,
|
|
10706
|
-
|
|
10661
|
+
$ as VertexAttribute,
|
|
10707
10662
|
ue as VertexBuffer,
|
|
10708
|
-
|
|
10663
|
+
Wt as Video2D,
|
|
10709
10664
|
ol as VideoLoader,
|
|
10710
10665
|
_o as VideoTexture,
|
|
10711
10666
|
j as Viewport,
|
|
10712
|
-
|
|
10667
|
+
xr as ViewportTexture,
|
|
10713
10668
|
Sn as WebAudio,
|
|
10714
|
-
|
|
10669
|
+
xe as WebAudioContext,
|
|
10715
10670
|
$i as WebGLBatch2DModule,
|
|
10716
10671
|
Ze as WebGLBlendMode,
|
|
10717
10672
|
Vi as WebGLBufferModule,
|
|
@@ -10731,9 +10686,9 @@ export {
|
|
|
10731
10686
|
Ai as WheelInputEvent,
|
|
10732
10687
|
wt as Window,
|
|
10733
10688
|
de as ZoomBlurEffect,
|
|
10734
|
-
|
|
10735
|
-
|
|
10736
|
-
|
|
10689
|
+
Oe as alignMap,
|
|
10690
|
+
z as assets,
|
|
10691
|
+
kr as boxSizingMap,
|
|
10737
10692
|
ie as clamp,
|
|
10738
10693
|
Ca as clampFrag,
|
|
10739
10694
|
Pi as createHTMLCanvas,
|
|
@@ -10741,36 +10696,36 @@ export {
|
|
|
10741
10696
|
Ei as crossOrigin,
|
|
10742
10697
|
_t as cubicBezier,
|
|
10743
10698
|
Pl as curves,
|
|
10744
|
-
|
|
10745
|
-
|
|
10746
|
-
|
|
10699
|
+
g as customNode,
|
|
10700
|
+
Xt as customNodes,
|
|
10701
|
+
Me as defaultOptions,
|
|
10747
10702
|
Ti as determineCrossOrigin,
|
|
10748
|
-
|
|
10749
|
-
|
|
10703
|
+
Vt as directionMap,
|
|
10704
|
+
Sr as displayMap,
|
|
10750
10705
|
vn as ease,
|
|
10751
10706
|
bn as easeIn,
|
|
10752
10707
|
xn as easeInOut,
|
|
10753
10708
|
yn as easeOut,
|
|
10754
10709
|
E as edgeMap,
|
|
10755
|
-
|
|
10756
|
-
|
|
10710
|
+
Cr as flexDirectionMap,
|
|
10711
|
+
Ar as flexWrapMap,
|
|
10757
10712
|
Sa as frag,
|
|
10758
|
-
|
|
10713
|
+
vr as getDefaultCssPropertyValue,
|
|
10759
10714
|
rn as gutterMap,
|
|
10760
10715
|
xi as isCanvasElement,
|
|
10761
|
-
|
|
10716
|
+
jr as isElementNode,
|
|
10762
10717
|
xl as isImageElement,
|
|
10763
|
-
|
|
10718
|
+
gr as isPow2,
|
|
10764
10719
|
yi as isVideoElement,
|
|
10765
10720
|
wi as isWebgl2,
|
|
10766
|
-
|
|
10721
|
+
Rr as justifyMap,
|
|
10767
10722
|
S as lerp,
|
|
10768
10723
|
gn as linear,
|
|
10769
|
-
|
|
10724
|
+
yr as log2,
|
|
10770
10725
|
Li as mapWebGLBlendModes,
|
|
10771
|
-
|
|
10772
|
-
|
|
10773
|
-
|
|
10726
|
+
br as nextPow2,
|
|
10727
|
+
Nr as nextTick,
|
|
10728
|
+
Or as overflowMap,
|
|
10774
10729
|
Ol as parseCSSFilter,
|
|
10775
10730
|
Vo as parseCSSTransform,
|
|
10776
10731
|
Go as parseCSSTransformOrigin,
|
|
@@ -10778,6 +10733,6 @@ export {
|
|
|
10778
10733
|
mt as parseCssProperty,
|
|
10779
10734
|
Mr as positionTypeMap,
|
|
10780
10735
|
Ul as render,
|
|
10781
|
-
|
|
10736
|
+
Lt as timingFunctions,
|
|
10782
10737
|
ni as uid
|
|
10783
10738
|
};
|