modern-canvas 0.11.0 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +546 -614
- package/dist/index.d.cts +20 -44
- package/dist/index.d.mts +20 -44
- package/dist/index.d.ts +20 -44
- package/dist/index.js +40 -40
- package/dist/index.mjs +547 -615
- package/package.json +7 -7
package/dist/index.cjs
CHANGED
|
@@ -2103,13 +2103,13 @@ class Vector3 extends Vector {
|
|
|
2103
2103
|
}
|
|
2104
2104
|
}
|
|
2105
2105
|
|
|
2106
|
-
var __defProp$
|
|
2107
|
-
var __decorateClass$
|
|
2106
|
+
var __defProp$Q = Object.defineProperty;
|
|
2107
|
+
var __decorateClass$U = (decorators, target, key, kind) => {
|
|
2108
2108
|
var result = void 0 ;
|
|
2109
2109
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
2110
2110
|
if (decorator = decorators[i])
|
|
2111
2111
|
result = (decorator(target, key, result) ) || result;
|
|
2112
|
-
if (result) __defProp$
|
|
2112
|
+
if (result) __defProp$Q(target, key, result);
|
|
2113
2113
|
return result;
|
|
2114
2114
|
};
|
|
2115
2115
|
class MainLoop extends CoreObject {
|
|
@@ -2157,20 +2157,20 @@ class MainLoop extends CoreObject {
|
|
|
2157
2157
|
super.destroy();
|
|
2158
2158
|
}
|
|
2159
2159
|
}
|
|
2160
|
-
__decorateClass$
|
|
2160
|
+
__decorateClass$U([
|
|
2161
2161
|
modernIdoc.property({ fallback: 60 })
|
|
2162
2162
|
], MainLoop.prototype, "fps");
|
|
2163
|
-
__decorateClass$
|
|
2163
|
+
__decorateClass$U([
|
|
2164
2164
|
modernIdoc.property({ fallback: 1 })
|
|
2165
2165
|
], MainLoop.prototype, "speed");
|
|
2166
2166
|
|
|
2167
|
-
var __defProp$
|
|
2168
|
-
var __decorateClass$
|
|
2167
|
+
var __defProp$P = Object.defineProperty;
|
|
2168
|
+
var __decorateClass$T = (decorators, target, key, kind) => {
|
|
2169
2169
|
var result = void 0 ;
|
|
2170
2170
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
2171
2171
|
if (decorator = decorators[i])
|
|
2172
2172
|
result = (decorator(target, key, result) ) || result;
|
|
2173
|
-
if (result) __defProp$
|
|
2173
|
+
if (result) __defProp$P(target, key, result);
|
|
2174
2174
|
return result;
|
|
2175
2175
|
};
|
|
2176
2176
|
class Renderer extends modernIdoc.Reactivable {
|
|
@@ -2214,10 +2214,10 @@ class Renderer extends modernIdoc.Reactivable {
|
|
|
2214
2214
|
super.destroy();
|
|
2215
2215
|
}
|
|
2216
2216
|
}
|
|
2217
|
-
__decorateClass$
|
|
2217
|
+
__decorateClass$T([
|
|
2218
2218
|
modernIdoc.property({ fallback: DEVICE_PIXEL_RATIO })
|
|
2219
2219
|
], Renderer.prototype, "pixelRatio");
|
|
2220
|
-
__decorateClass$
|
|
2220
|
+
__decorateClass$T([
|
|
2221
2221
|
modernIdoc.property({ internal: true })
|
|
2222
2222
|
], Renderer.prototype, "view");
|
|
2223
2223
|
|
|
@@ -4414,13 +4414,13 @@ class Geometry extends Resource {
|
|
|
4414
4414
|
}
|
|
4415
4415
|
}
|
|
4416
4416
|
|
|
4417
|
-
var __defProp$
|
|
4418
|
-
var __decorateClass$
|
|
4417
|
+
var __defProp$O = Object.defineProperty;
|
|
4418
|
+
var __decorateClass$S = (decorators, target, key, kind) => {
|
|
4419
4419
|
var result = void 0 ;
|
|
4420
4420
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
4421
4421
|
if (decorator = decorators[i])
|
|
4422
4422
|
result = (decorator(target, key, result) ) || result;
|
|
4423
|
-
if (result) __defProp$
|
|
4423
|
+
if (result) __defProp$O(target, key, result);
|
|
4424
4424
|
return result;
|
|
4425
4425
|
};
|
|
4426
4426
|
class IndexBuffer extends Resource {
|
|
@@ -4464,20 +4464,20 @@ class IndexBuffer extends Resource {
|
|
|
4464
4464
|
return result;
|
|
4465
4465
|
}
|
|
4466
4466
|
}
|
|
4467
|
-
__decorateClass$
|
|
4467
|
+
__decorateClass$S([
|
|
4468
4468
|
modernIdoc.property({ internal: true, fallback: null })
|
|
4469
4469
|
], IndexBuffer.prototype, "data");
|
|
4470
|
-
__decorateClass$
|
|
4470
|
+
__decorateClass$S([
|
|
4471
4471
|
modernIdoc.property({ internal: true, fallback: false })
|
|
4472
4472
|
], IndexBuffer.prototype, "dynamic");
|
|
4473
4473
|
|
|
4474
|
-
var __defProp$
|
|
4475
|
-
var __decorateClass$
|
|
4474
|
+
var __defProp$N = Object.defineProperty;
|
|
4475
|
+
var __decorateClass$R = (decorators, target, key, kind) => {
|
|
4476
4476
|
var result = void 0 ;
|
|
4477
4477
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
4478
4478
|
if (decorator = decorators[i])
|
|
4479
4479
|
result = (decorator(target, key, result) ) || result;
|
|
4480
|
-
if (result) __defProp$
|
|
4480
|
+
if (result) __defProp$N(target, key, result);
|
|
4481
4481
|
return result;
|
|
4482
4482
|
};
|
|
4483
4483
|
class VertexBuffer extends Resource {
|
|
@@ -4521,20 +4521,20 @@ class VertexBuffer extends Resource {
|
|
|
4521
4521
|
return result;
|
|
4522
4522
|
}
|
|
4523
4523
|
}
|
|
4524
|
-
__decorateClass$
|
|
4524
|
+
__decorateClass$R([
|
|
4525
4525
|
modernIdoc.property({ internal: true, default: null })
|
|
4526
4526
|
], VertexBuffer.prototype, "data");
|
|
4527
|
-
__decorateClass$
|
|
4527
|
+
__decorateClass$R([
|
|
4528
4528
|
modernIdoc.property({ internal: true, fallback: false })
|
|
4529
4529
|
], VertexBuffer.prototype, "dynamic");
|
|
4530
4530
|
|
|
4531
|
-
var __defProp$
|
|
4532
|
-
var __decorateClass$
|
|
4531
|
+
var __defProp$M = Object.defineProperty;
|
|
4532
|
+
var __decorateClass$Q = (decorators, target, key, kind) => {
|
|
4533
4533
|
var result = void 0 ;
|
|
4534
4534
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
4535
4535
|
if (decorator = decorators[i])
|
|
4536
4536
|
result = (decorator(target, key, result) ) || result;
|
|
4537
|
-
if (result) __defProp$
|
|
4537
|
+
if (result) __defProp$M(target, key, result);
|
|
4538
4538
|
return result;
|
|
4539
4539
|
};
|
|
4540
4540
|
class VertexAttribute extends Resource {
|
|
@@ -4568,25 +4568,25 @@ class VertexAttribute extends Resource {
|
|
|
4568
4568
|
return result;
|
|
4569
4569
|
}
|
|
4570
4570
|
}
|
|
4571
|
-
__decorateClass$
|
|
4571
|
+
__decorateClass$Q([
|
|
4572
4572
|
modernIdoc.property({ internal: true })
|
|
4573
4573
|
], VertexAttribute.prototype, "buffer");
|
|
4574
|
-
__decorateClass$
|
|
4574
|
+
__decorateClass$Q([
|
|
4575
4575
|
modernIdoc.property({ fallback: 0 })
|
|
4576
4576
|
], VertexAttribute.prototype, "size");
|
|
4577
|
-
__decorateClass$
|
|
4577
|
+
__decorateClass$Q([
|
|
4578
4578
|
modernIdoc.property({ fallback: false })
|
|
4579
4579
|
], VertexAttribute.prototype, "normalized");
|
|
4580
|
-
__decorateClass$
|
|
4580
|
+
__decorateClass$Q([
|
|
4581
4581
|
modernIdoc.property({ fallback: "float" })
|
|
4582
4582
|
], VertexAttribute.prototype, "type");
|
|
4583
|
-
__decorateClass$
|
|
4583
|
+
__decorateClass$Q([
|
|
4584
4584
|
modernIdoc.property()
|
|
4585
4585
|
], VertexAttribute.prototype, "stride");
|
|
4586
|
-
__decorateClass$
|
|
4586
|
+
__decorateClass$Q([
|
|
4587
4587
|
modernIdoc.property()
|
|
4588
4588
|
], VertexAttribute.prototype, "offset");
|
|
4589
|
-
__decorateClass$
|
|
4589
|
+
__decorateClass$Q([
|
|
4590
4590
|
modernIdoc.property()
|
|
4591
4591
|
], VertexAttribute.prototype, "divisor");
|
|
4592
4592
|
|
|
@@ -4830,13 +4830,13 @@ class UvGeometry extends Geometry {
|
|
|
4830
4830
|
}
|
|
4831
4831
|
}
|
|
4832
4832
|
|
|
4833
|
-
var __defProp$
|
|
4834
|
-
var __decorateClass$
|
|
4833
|
+
var __defProp$L = Object.defineProperty;
|
|
4834
|
+
var __decorateClass$P = (decorators, target, key, kind) => {
|
|
4835
4835
|
var result = void 0 ;
|
|
4836
4836
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
4837
4837
|
if (decorator = decorators[i])
|
|
4838
4838
|
result = (decorator(target, key, result) ) || result;
|
|
4839
|
-
if (result) __defProp$
|
|
4839
|
+
if (result) __defProp$L(target, key, result);
|
|
4840
4840
|
return result;
|
|
4841
4841
|
};
|
|
4842
4842
|
class Texture2D extends Resource {
|
|
@@ -4860,9 +4860,6 @@ class Texture2D extends Resource {
|
|
|
4860
4860
|
}
|
|
4861
4861
|
_isPowerOfTwo = false;
|
|
4862
4862
|
_needsUpload = false;
|
|
4863
|
-
get valid() {
|
|
4864
|
-
return Boolean(this.width && this.height);
|
|
4865
|
-
}
|
|
4866
4863
|
get realWidth() {
|
|
4867
4864
|
return Math.round(this.width * this.pixelRatio);
|
|
4868
4865
|
}
|
|
@@ -4874,6 +4871,9 @@ class Texture2D extends Resource {
|
|
|
4874
4871
|
this.source = source;
|
|
4875
4872
|
this._updateSize();
|
|
4876
4873
|
}
|
|
4874
|
+
isValid() {
|
|
4875
|
+
return Boolean(this.width && this.height);
|
|
4876
|
+
}
|
|
4877
4877
|
/** @internal */
|
|
4878
4878
|
_glTextureOptions(renderer, options) {
|
|
4879
4879
|
let wrapMode = this.wrapMode;
|
|
@@ -4933,7 +4933,7 @@ class Texture2D extends Resource {
|
|
|
4933
4933
|
this._needsUpload = true;
|
|
4934
4934
|
}
|
|
4935
4935
|
upload(renderer, options) {
|
|
4936
|
-
if (this._needsUpload && this.
|
|
4936
|
+
if (this._needsUpload && this.isValid()) {
|
|
4937
4937
|
this._needsUpload = false;
|
|
4938
4938
|
renderer.texture.update(
|
|
4939
4939
|
this._glTexture(renderer, options),
|
|
@@ -4944,7 +4944,7 @@ class Texture2D extends Resource {
|
|
|
4944
4944
|
return false;
|
|
4945
4945
|
}
|
|
4946
4946
|
activate(renderer, location = 0) {
|
|
4947
|
-
if (this.
|
|
4947
|
+
if (this.isValid()) {
|
|
4948
4948
|
renderer.texture.bind({
|
|
4949
4949
|
target: "texture_2d",
|
|
4950
4950
|
value: this._glTexture(renderer, { location }),
|
|
@@ -4964,22 +4964,22 @@ class Texture2D extends Resource {
|
|
|
4964
4964
|
}
|
|
4965
4965
|
}
|
|
4966
4966
|
}
|
|
4967
|
-
__decorateClass$
|
|
4967
|
+
__decorateClass$P([
|
|
4968
4968
|
modernIdoc.property({ internal: true })
|
|
4969
4969
|
], Texture2D.prototype, "source");
|
|
4970
|
-
__decorateClass$
|
|
4970
|
+
__decorateClass$P([
|
|
4971
4971
|
modernIdoc.property({ fallback: 0 })
|
|
4972
4972
|
], Texture2D.prototype, "width");
|
|
4973
|
-
__decorateClass$
|
|
4973
|
+
__decorateClass$P([
|
|
4974
4974
|
modernIdoc.property({ fallback: 0 })
|
|
4975
4975
|
], Texture2D.prototype, "height");
|
|
4976
|
-
__decorateClass$
|
|
4976
|
+
__decorateClass$P([
|
|
4977
4977
|
modernIdoc.property({ fallback: "linear" })
|
|
4978
4978
|
], Texture2D.prototype, "filterMode");
|
|
4979
|
-
__decorateClass$
|
|
4979
|
+
__decorateClass$P([
|
|
4980
4980
|
modernIdoc.property({ fallback: "clamp_to_edge" })
|
|
4981
4981
|
], Texture2D.prototype, "wrapMode");
|
|
4982
|
-
__decorateClass$
|
|
4982
|
+
__decorateClass$P([
|
|
4983
4983
|
modernIdoc.property({ fallback: 1 })
|
|
4984
4984
|
], Texture2D.prototype, "pixelRatio");
|
|
4985
4985
|
|
|
@@ -5013,13 +5013,13 @@ class AnimatedTexture extends Resource {
|
|
|
5013
5013
|
}
|
|
5014
5014
|
}
|
|
5015
5015
|
|
|
5016
|
-
var __defProp$
|
|
5017
|
-
var __decorateClass$
|
|
5016
|
+
var __defProp$K = Object.defineProperty;
|
|
5017
|
+
var __decorateClass$O = (decorators, target, key, kind) => {
|
|
5018
5018
|
var result = void 0 ;
|
|
5019
5019
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
5020
5020
|
if (decorator = decorators[i])
|
|
5021
5021
|
result = (decorator(target, key, result) ) || result;
|
|
5022
|
-
if (result) __defProp$
|
|
5022
|
+
if (result) __defProp$K(target, key, result);
|
|
5023
5023
|
return result;
|
|
5024
5024
|
};
|
|
5025
5025
|
class CanvasTexture extends Texture2D {
|
|
@@ -5038,7 +5038,7 @@ class CanvasTexture extends Texture2D {
|
|
|
5038
5038
|
super._updateProperty(key, value, oldValue);
|
|
5039
5039
|
}
|
|
5040
5040
|
}
|
|
5041
|
-
__decorateClass$
|
|
5041
|
+
__decorateClass$O([
|
|
5042
5042
|
modernIdoc.property({ fallback: 2 })
|
|
5043
5043
|
], CanvasTexture.prototype, "pixelRatio");
|
|
5044
5044
|
|
|
@@ -5260,13 +5260,13 @@ class PixelsTexture extends Texture2D {
|
|
|
5260
5260
|
}
|
|
5261
5261
|
}
|
|
5262
5262
|
|
|
5263
|
-
var __defProp$
|
|
5264
|
-
var __decorateClass$
|
|
5263
|
+
var __defProp$J = Object.defineProperty;
|
|
5264
|
+
var __decorateClass$N = (decorators, target, key, kind) => {
|
|
5265
5265
|
var result = void 0 ;
|
|
5266
5266
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
5267
5267
|
if (decorator = decorators[i])
|
|
5268
5268
|
result = (decorator(target, key, result) ) || result;
|
|
5269
|
-
if (result) __defProp$
|
|
5269
|
+
if (result) __defProp$J(target, key, result);
|
|
5270
5270
|
return result;
|
|
5271
5271
|
};
|
|
5272
5272
|
function resolveOptions(options) {
|
|
@@ -5371,7 +5371,7 @@ const _VideoTexture = class _VideoTexture extends Texture2D {
|
|
|
5371
5371
|
}
|
|
5372
5372
|
}
|
|
5373
5373
|
_onPlayStart = () => {
|
|
5374
|
-
if (!this.
|
|
5374
|
+
if (!this.isValid()) {
|
|
5375
5375
|
this._onCanPlay();
|
|
5376
5376
|
}
|
|
5377
5377
|
this._setupAutoUpdate();
|
|
@@ -5383,7 +5383,7 @@ const _VideoTexture = class _VideoTexture extends Texture2D {
|
|
|
5383
5383
|
const source = this.source;
|
|
5384
5384
|
source.removeEventListener("canplay", this._onCanPlay);
|
|
5385
5385
|
source.removeEventListener("canplaythrough", this._onCanPlay);
|
|
5386
|
-
const valid = this.
|
|
5386
|
+
const valid = this.isValid();
|
|
5387
5387
|
this._nextTime = 0;
|
|
5388
5388
|
this._updateSize();
|
|
5389
5389
|
this.requestUpload();
|
|
@@ -5482,7 +5482,7 @@ const _VideoTexture = class _VideoTexture extends Texture2D {
|
|
|
5482
5482
|
this._onCanPlay();
|
|
5483
5483
|
}
|
|
5484
5484
|
this._sourceLoad = new Promise((resolve, reject) => {
|
|
5485
|
-
if (this.
|
|
5485
|
+
if (this.isValid()) {
|
|
5486
5486
|
this._sourceLoad = void 0;
|
|
5487
5487
|
resolve(this);
|
|
5488
5488
|
} else {
|
|
@@ -5510,10 +5510,10 @@ const _VideoTexture = class _VideoTexture extends Texture2D {
|
|
|
5510
5510
|
}
|
|
5511
5511
|
}
|
|
5512
5512
|
};
|
|
5513
|
-
__decorateClass$
|
|
5513
|
+
__decorateClass$N([
|
|
5514
5514
|
modernIdoc.property({ internal: true, fallback: true })
|
|
5515
5515
|
], _VideoTexture.prototype, "autoUpdate");
|
|
5516
|
-
__decorateClass$
|
|
5516
|
+
__decorateClass$N([
|
|
5517
5517
|
modernIdoc.property({ internal: true, fallback: 0 })
|
|
5518
5518
|
], _VideoTexture.prototype, "fps");
|
|
5519
5519
|
let VideoTexture = _VideoTexture;
|
|
@@ -5805,14 +5805,14 @@ class Meta extends CoreObject {
|
|
|
5805
5805
|
}
|
|
5806
5806
|
}
|
|
5807
5807
|
|
|
5808
|
-
var __defProp$
|
|
5809
|
-
var __getOwnPropDesc$
|
|
5810
|
-
var __decorateClass$
|
|
5811
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5808
|
+
var __defProp$I = Object.defineProperty;
|
|
5809
|
+
var __getOwnPropDesc$C = Object.getOwnPropertyDescriptor;
|
|
5810
|
+
var __decorateClass$M = (decorators, target, key, kind) => {
|
|
5811
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$C(target, key) : target;
|
|
5812
5812
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
5813
5813
|
if (decorator = decorators[i])
|
|
5814
5814
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5815
|
-
if (kind && result) __defProp$
|
|
5815
|
+
if (kind && result) __defProp$I(target, key, result);
|
|
5816
5816
|
return result;
|
|
5817
5817
|
};
|
|
5818
5818
|
const iidMap = {};
|
|
@@ -5913,9 +5913,6 @@ exports.Node = class Node extends CoreObject {
|
|
|
5913
5913
|
}
|
|
5914
5914
|
return this;
|
|
5915
5915
|
}
|
|
5916
|
-
log(...args) {
|
|
5917
|
-
this._tree?.log(...args);
|
|
5918
|
-
}
|
|
5919
5916
|
/** Parent */
|
|
5920
5917
|
_parent;
|
|
5921
5918
|
get parent() {
|
|
@@ -6251,24 +6248,35 @@ exports.Node = class Node extends CoreObject {
|
|
|
6251
6248
|
remove() {
|
|
6252
6249
|
this._parent?.removeChild(this);
|
|
6253
6250
|
}
|
|
6254
|
-
|
|
6255
|
-
this.
|
|
6256
|
-
|
|
6251
|
+
findOne(callbackfn) {
|
|
6252
|
+
for (const child of this._children.default) {
|
|
6253
|
+
const value = callbackfn(child) || child.findOne(callbackfn);
|
|
6254
|
+
if (value) {
|
|
6255
|
+
return value;
|
|
6256
|
+
}
|
|
6257
|
+
}
|
|
6258
|
+
return void 0;
|
|
6257
6259
|
}
|
|
6258
|
-
|
|
6259
|
-
|
|
6260
|
-
|
|
6261
|
-
child
|
|
6262
|
-
|
|
6263
|
-
|
|
6260
|
+
findAll(callbackfn) {
|
|
6261
|
+
const items = [];
|
|
6262
|
+
for (const child of this._children.default) {
|
|
6263
|
+
const value = callbackfn(child);
|
|
6264
|
+
if (value) {
|
|
6265
|
+
items.push(value);
|
|
6266
|
+
}
|
|
6267
|
+
items.push(...child.findAll(callbackfn));
|
|
6268
|
+
}
|
|
6269
|
+
return items;
|
|
6264
6270
|
}
|
|
6265
|
-
|
|
6266
|
-
const parent = this.
|
|
6271
|
+
findAncestor(callbackfn) {
|
|
6272
|
+
const parent = this._parent;
|
|
6267
6273
|
if (parent) {
|
|
6268
|
-
callbackfn(parent);
|
|
6269
|
-
|
|
6274
|
+
const value = callbackfn(parent) ?? parent.findAncestor(callbackfn);
|
|
6275
|
+
if (value) {
|
|
6276
|
+
return value;
|
|
6277
|
+
}
|
|
6270
6278
|
}
|
|
6271
|
-
return
|
|
6279
|
+
return void 0;
|
|
6272
6280
|
}
|
|
6273
6281
|
/** override */
|
|
6274
6282
|
_ready() {
|
|
@@ -6326,42 +6334,42 @@ exports.Node = class Node extends CoreObject {
|
|
|
6326
6334
|
return node;
|
|
6327
6335
|
}
|
|
6328
6336
|
};
|
|
6329
|
-
__decorateClass$
|
|
6337
|
+
__decorateClass$M([
|
|
6330
6338
|
modernIdoc.property({ fallback: modernIdoc.idGenerator() })
|
|
6331
6339
|
], exports.Node.prototype, "id", 2);
|
|
6332
|
-
__decorateClass$
|
|
6340
|
+
__decorateClass$M([
|
|
6333
6341
|
modernIdoc.property({ fallback: modernIdoc.idGenerator() })
|
|
6334
6342
|
], exports.Node.prototype, "name", 2);
|
|
6335
|
-
__decorateClass$
|
|
6343
|
+
__decorateClass$M([
|
|
6336
6344
|
modernIdoc.property({ internal: true, fallback: "inherit" })
|
|
6337
6345
|
], exports.Node.prototype, "processMode", 2);
|
|
6338
|
-
__decorateClass$
|
|
6346
|
+
__decorateClass$M([
|
|
6339
6347
|
modernIdoc.property({ internal: true, fallback: "default" })
|
|
6340
6348
|
], exports.Node.prototype, "processSortMode", 2);
|
|
6341
|
-
__decorateClass$
|
|
6349
|
+
__decorateClass$M([
|
|
6342
6350
|
modernIdoc.property({ internal: true, fallback: "inherit" })
|
|
6343
6351
|
], exports.Node.prototype, "renderMode", 2);
|
|
6344
|
-
__decorateClass$
|
|
6352
|
+
__decorateClass$M([
|
|
6345
6353
|
modernIdoc.property({ internal: true, fallback: "inherit" })
|
|
6346
6354
|
], exports.Node.prototype, "inputMode", 2);
|
|
6347
|
-
__decorateClass$
|
|
6355
|
+
__decorateClass$M([
|
|
6348
6356
|
modernIdoc.property({ internal: true, fallback: "default" })
|
|
6349
6357
|
], exports.Node.prototype, "internalMode", 2);
|
|
6350
|
-
__decorateClass$
|
|
6358
|
+
__decorateClass$M([
|
|
6351
6359
|
modernIdoc.property({ internal: true })
|
|
6352
6360
|
], exports.Node.prototype, "mask", 2);
|
|
6353
|
-
exports.Node = __decorateClass$
|
|
6361
|
+
exports.Node = __decorateClass$M([
|
|
6354
6362
|
customNode("Node")
|
|
6355
6363
|
], exports.Node);
|
|
6356
6364
|
|
|
6357
|
-
var __defProp$
|
|
6358
|
-
var __getOwnPropDesc$
|
|
6359
|
-
var __decorateClass$
|
|
6360
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6365
|
+
var __defProp$H = Object.defineProperty;
|
|
6366
|
+
var __getOwnPropDesc$B = Object.getOwnPropertyDescriptor;
|
|
6367
|
+
var __decorateClass$L = (decorators, target, key, kind) => {
|
|
6368
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$B(target, key) : target;
|
|
6361
6369
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
6362
6370
|
if (decorator = decorators[i])
|
|
6363
6371
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6364
|
-
if (kind && result) __defProp$
|
|
6372
|
+
if (kind && result) __defProp$H(target, key, result);
|
|
6365
6373
|
return result;
|
|
6366
6374
|
};
|
|
6367
6375
|
exports.TimelineNode = class TimelineNode extends exports.Node {
|
|
@@ -6409,9 +6417,15 @@ exports.TimelineNode = class TimelineNode extends exports.Node {
|
|
|
6409
6417
|
_updateCurrentTime(force = false) {
|
|
6410
6418
|
if (force || !this.paused) {
|
|
6411
6419
|
const parent = this._parent;
|
|
6412
|
-
|
|
6413
|
-
|
|
6414
|
-
|
|
6420
|
+
const startTime = this.delay + this.parentStartTime;
|
|
6421
|
+
const endTime = parent?.computedDuration ? Math.min(startTime + this.duration, parent.endTime) - startTime : this.duration;
|
|
6422
|
+
let currentTime = this.timelineCurrentTime - startTime;
|
|
6423
|
+
if (this.loop) {
|
|
6424
|
+
currentTime = currentTime % endTime;
|
|
6425
|
+
}
|
|
6426
|
+
this._startTime = startTime;
|
|
6427
|
+
this._currentTime = currentTime;
|
|
6428
|
+
this.computedDuration = endTime;
|
|
6415
6429
|
this.emit("updateCurrentTime", this._currentTime);
|
|
6416
6430
|
this.insideTimeRange = this.isInsideTimeRange();
|
|
6417
6431
|
}
|
|
@@ -6421,30 +6435,33 @@ exports.TimelineNode = class TimelineNode extends exports.Node {
|
|
|
6421
6435
|
this._updateCurrentTime();
|
|
6422
6436
|
}
|
|
6423
6437
|
};
|
|
6424
|
-
__decorateClass$
|
|
6438
|
+
__decorateClass$L([
|
|
6439
|
+
modernIdoc.property({ fallback: false })
|
|
6440
|
+
], exports.TimelineNode.prototype, "loop", 2);
|
|
6441
|
+
__decorateClass$L([
|
|
6425
6442
|
modernIdoc.property({ fallback: 0 })
|
|
6426
6443
|
], exports.TimelineNode.prototype, "delay", 2);
|
|
6427
|
-
__decorateClass$
|
|
6444
|
+
__decorateClass$L([
|
|
6428
6445
|
modernIdoc.property({ fallback: 0 })
|
|
6429
6446
|
], exports.TimelineNode.prototype, "duration", 2);
|
|
6430
|
-
__decorateClass$
|
|
6447
|
+
__decorateClass$L([
|
|
6431
6448
|
modernIdoc.property({ fallback: false })
|
|
6432
6449
|
], exports.TimelineNode.prototype, "paused", 2);
|
|
6433
|
-
__decorateClass$
|
|
6450
|
+
__decorateClass$L([
|
|
6434
6451
|
modernIdoc.property({ internal: true, fallback: false })
|
|
6435
6452
|
], exports.TimelineNode.prototype, "insideTimeRange", 2);
|
|
6436
|
-
exports.TimelineNode = __decorateClass$
|
|
6453
|
+
exports.TimelineNode = __decorateClass$L([
|
|
6437
6454
|
customNode("TimelineNode")
|
|
6438
6455
|
], exports.TimelineNode);
|
|
6439
6456
|
|
|
6440
|
-
var __defProp$
|
|
6441
|
-
var __getOwnPropDesc$
|
|
6442
|
-
var __decorateClass$
|
|
6443
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6457
|
+
var __defProp$G = Object.defineProperty;
|
|
6458
|
+
var __getOwnPropDesc$A = Object.getOwnPropertyDescriptor;
|
|
6459
|
+
var __decorateClass$K = (decorators, target, key, kind) => {
|
|
6460
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$A(target, key) : target;
|
|
6444
6461
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
6445
6462
|
if (decorator = decorators[i])
|
|
6446
6463
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6447
|
-
if (kind && result) __defProp$
|
|
6464
|
+
if (kind && result) __defProp$G(target, key, result);
|
|
6448
6465
|
return result;
|
|
6449
6466
|
};
|
|
6450
6467
|
exports.CanvasItem = class CanvasItem extends exports.TimelineNode {
|
|
@@ -6528,16 +6545,16 @@ exports.CanvasItem = class CanvasItem extends exports.TimelineNode {
|
|
|
6528
6545
|
this.emit("draw");
|
|
6529
6546
|
}
|
|
6530
6547
|
_redraw() {
|
|
6531
|
-
this.log(this.name, "drawing");
|
|
6548
|
+
this._tree?.log(this.name, "drawing");
|
|
6532
6549
|
this._draw();
|
|
6533
6550
|
return this.context.toBatchables();
|
|
6534
6551
|
}
|
|
6535
6552
|
_relayout(batchables) {
|
|
6536
|
-
this.log(this.name, "layouting");
|
|
6553
|
+
this._tree?.log(this.name, "layouting");
|
|
6537
6554
|
return batchables;
|
|
6538
6555
|
}
|
|
6539
6556
|
_repaint(batchables) {
|
|
6540
|
-
this.log(this.name, "painting");
|
|
6557
|
+
this._tree?.log(this.name, "painting");
|
|
6541
6558
|
const globalOpacity = this.globalOpacity;
|
|
6542
6559
|
return batchables.map((batchable) => {
|
|
6543
6560
|
return {
|
|
@@ -6597,30 +6614,30 @@ exports.CanvasItem = class CanvasItem extends exports.TimelineNode {
|
|
|
6597
6614
|
super._render(renderer);
|
|
6598
6615
|
}
|
|
6599
6616
|
};
|
|
6600
|
-
__decorateClass$
|
|
6617
|
+
__decorateClass$K([
|
|
6601
6618
|
modernIdoc.property()
|
|
6602
6619
|
], exports.CanvasItem.prototype, "modulate", 2);
|
|
6603
|
-
__decorateClass$
|
|
6620
|
+
__decorateClass$K([
|
|
6604
6621
|
modernIdoc.property()
|
|
6605
6622
|
], exports.CanvasItem.prototype, "blendMode", 2);
|
|
6606
|
-
__decorateClass$
|
|
6623
|
+
__decorateClass$K([
|
|
6607
6624
|
modernIdoc.property({ internal: true, fallback: true })
|
|
6608
6625
|
], exports.CanvasItem.prototype, "visible", 2);
|
|
6609
|
-
__decorateClass$
|
|
6626
|
+
__decorateClass$K([
|
|
6610
6627
|
modernIdoc.property({ internal: true, fallback: 1 })
|
|
6611
6628
|
], exports.CanvasItem.prototype, "opacity", 2);
|
|
6612
|
-
exports.CanvasItem = __decorateClass$
|
|
6629
|
+
exports.CanvasItem = __decorateClass$K([
|
|
6613
6630
|
customNode("CanvasItem")
|
|
6614
6631
|
], exports.CanvasItem);
|
|
6615
6632
|
|
|
6616
|
-
var __defProp$
|
|
6617
|
-
var __getOwnPropDesc$
|
|
6618
|
-
var __decorateClass$
|
|
6619
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6633
|
+
var __defProp$F = Object.defineProperty;
|
|
6634
|
+
var __getOwnPropDesc$z = Object.getOwnPropertyDescriptor;
|
|
6635
|
+
var __decorateClass$J = (decorators, target, key, kind) => {
|
|
6636
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$z(target, key) : target;
|
|
6620
6637
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
6621
6638
|
if (decorator = decorators[i])
|
|
6622
6639
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6623
|
-
if (kind && result) __defProp$
|
|
6640
|
+
if (kind && result) __defProp$F(target, key, result);
|
|
6624
6641
|
return result;
|
|
6625
6642
|
};
|
|
6626
6643
|
exports.Viewport = class Viewport extends exports.Node {
|
|
@@ -6771,33 +6788,33 @@ exports.Viewport = class Viewport extends exports.Node {
|
|
|
6771
6788
|
return this.canvasTransform.apply(globalPos, newPos);
|
|
6772
6789
|
}
|
|
6773
6790
|
};
|
|
6774
|
-
__decorateClass$
|
|
6791
|
+
__decorateClass$J([
|
|
6775
6792
|
modernIdoc.property({ fallback: 0 })
|
|
6776
6793
|
], exports.Viewport.prototype, "x", 2);
|
|
6777
|
-
__decorateClass$
|
|
6794
|
+
__decorateClass$J([
|
|
6778
6795
|
modernIdoc.property({ fallback: 0 })
|
|
6779
6796
|
], exports.Viewport.prototype, "y", 2);
|
|
6780
|
-
__decorateClass$
|
|
6797
|
+
__decorateClass$J([
|
|
6781
6798
|
modernIdoc.property({ fallback: 0 })
|
|
6782
6799
|
], exports.Viewport.prototype, "width", 2);
|
|
6783
|
-
__decorateClass$
|
|
6800
|
+
__decorateClass$J([
|
|
6784
6801
|
modernIdoc.property({ fallback: 0 })
|
|
6785
6802
|
], exports.Viewport.prototype, "height", 2);
|
|
6786
|
-
__decorateClass$
|
|
6803
|
+
__decorateClass$J([
|
|
6787
6804
|
modernIdoc.property({ internal: true, fallback: false })
|
|
6788
6805
|
], exports.Viewport.prototype, "msaa", 2);
|
|
6789
|
-
exports.Viewport = __decorateClass$
|
|
6806
|
+
exports.Viewport = __decorateClass$J([
|
|
6790
6807
|
customNode("Viewport")
|
|
6791
6808
|
], exports.Viewport);
|
|
6792
6809
|
|
|
6793
|
-
var __defProp$
|
|
6794
|
-
var __getOwnPropDesc$
|
|
6795
|
-
var __decorateClass$
|
|
6796
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6810
|
+
var __defProp$E = Object.defineProperty;
|
|
6811
|
+
var __getOwnPropDesc$y = Object.getOwnPropertyDescriptor;
|
|
6812
|
+
var __decorateClass$I = (decorators, target, key, kind) => {
|
|
6813
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$y(target, key) : target;
|
|
6797
6814
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
6798
6815
|
if (decorator = decorators[i])
|
|
6799
6816
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6800
|
-
if (kind && result) __defProp$
|
|
6817
|
+
if (kind && result) __defProp$E(target, key, result);
|
|
6801
6818
|
return result;
|
|
6802
6819
|
};
|
|
6803
6820
|
exports.Effect = class Effect extends exports.TimelineNode {
|
|
@@ -7039,19 +7056,19 @@ exports.Effect = class Effect extends exports.TimelineNode {
|
|
|
7039
7056
|
}
|
|
7040
7057
|
}
|
|
7041
7058
|
};
|
|
7042
|
-
__decorateClass$
|
|
7059
|
+
__decorateClass$I([
|
|
7043
7060
|
modernIdoc.property({ internal: true })
|
|
7044
7061
|
], exports.Effect.prototype, "material", 2);
|
|
7045
|
-
__decorateClass$
|
|
7062
|
+
__decorateClass$I([
|
|
7046
7063
|
modernIdoc.property()
|
|
7047
7064
|
], exports.Effect.prototype, "effectMode", 2);
|
|
7048
|
-
__decorateClass$
|
|
7065
|
+
__decorateClass$I([
|
|
7049
7066
|
modernIdoc.property()
|
|
7050
7067
|
], exports.Effect.prototype, "glsl", 2);
|
|
7051
|
-
__decorateClass$
|
|
7068
|
+
__decorateClass$I([
|
|
7052
7069
|
modernIdoc.property()
|
|
7053
7070
|
], exports.Effect.prototype, "glslSrc", 2);
|
|
7054
|
-
exports.Effect = __decorateClass$
|
|
7071
|
+
exports.Effect = __decorateClass$I([
|
|
7055
7072
|
customNode("Effect")
|
|
7056
7073
|
], exports.Effect);
|
|
7057
7074
|
|
|
@@ -7081,14 +7098,14 @@ class RenderStack {
|
|
|
7081
7098
|
}
|
|
7082
7099
|
}
|
|
7083
7100
|
|
|
7084
|
-
var __defProp$
|
|
7085
|
-
var __getOwnPropDesc$
|
|
7086
|
-
var __decorateClass$
|
|
7087
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7101
|
+
var __defProp$D = Object.defineProperty;
|
|
7102
|
+
var __getOwnPropDesc$x = Object.getOwnPropertyDescriptor;
|
|
7103
|
+
var __decorateClass$H = (decorators, target, key, kind) => {
|
|
7104
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$x(target, key) : target;
|
|
7088
7105
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7089
7106
|
if (decorator = decorators[i])
|
|
7090
7107
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7091
|
-
if (kind && result) __defProp$
|
|
7108
|
+
if (kind && result) __defProp$D(target, key, result);
|
|
7092
7109
|
return result;
|
|
7093
7110
|
};
|
|
7094
7111
|
exports.Timeline = class Timeline extends exports.Node {
|
|
@@ -7133,48 +7150,48 @@ exports.Timeline = class Timeline extends exports.Node {
|
|
|
7133
7150
|
this.addTime(delta);
|
|
7134
7151
|
}
|
|
7135
7152
|
};
|
|
7136
|
-
__decorateClass$
|
|
7153
|
+
__decorateClass$H([
|
|
7137
7154
|
modernIdoc.property({ fallback: 0 })
|
|
7138
7155
|
], exports.Timeline.prototype, "startTime", 2);
|
|
7139
|
-
__decorateClass$
|
|
7156
|
+
__decorateClass$H([
|
|
7140
7157
|
modernIdoc.property({ fallback: 0 })
|
|
7141
7158
|
], exports.Timeline.prototype, "currentTime", 2);
|
|
7142
|
-
__decorateClass$
|
|
7159
|
+
__decorateClass$H([
|
|
7143
7160
|
modernIdoc.property({ fallback: Number.MAX_SAFE_INTEGER })
|
|
7144
7161
|
], exports.Timeline.prototype, "endTime", 2);
|
|
7145
|
-
__decorateClass$
|
|
7162
|
+
__decorateClass$H([
|
|
7146
7163
|
modernIdoc.property({ fallback: false })
|
|
7147
7164
|
], exports.Timeline.prototype, "loop", 2);
|
|
7148
|
-
exports.Timeline = __decorateClass$
|
|
7165
|
+
exports.Timeline = __decorateClass$H([
|
|
7149
7166
|
customNode("Timeline")
|
|
7150
7167
|
], exports.Timeline);
|
|
7151
7168
|
|
|
7152
|
-
var __defProp$
|
|
7153
|
-
var __getOwnPropDesc$
|
|
7154
|
-
var __decorateClass$
|
|
7155
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7169
|
+
var __defProp$C = Object.defineProperty;
|
|
7170
|
+
var __getOwnPropDesc$w = Object.getOwnPropertyDescriptor;
|
|
7171
|
+
var __decorateClass$G = (decorators, target, key, kind) => {
|
|
7172
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$w(target, key) : target;
|
|
7156
7173
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7157
7174
|
if (decorator = decorators[i])
|
|
7158
7175
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7159
|
-
if (kind && result) __defProp$
|
|
7176
|
+
if (kind && result) __defProp$C(target, key, result);
|
|
7160
7177
|
return result;
|
|
7161
7178
|
};
|
|
7162
7179
|
exports.Window = class Window extends exports.Viewport {
|
|
7163
7180
|
};
|
|
7164
|
-
__decorateClass$
|
|
7181
|
+
__decorateClass$G([
|
|
7165
7182
|
modernIdoc.property({ fallback: false })
|
|
7166
7183
|
], exports.Window.prototype, "msaa", 2);
|
|
7167
|
-
exports.Window = __decorateClass$
|
|
7184
|
+
exports.Window = __decorateClass$G([
|
|
7168
7185
|
customNode("Window")
|
|
7169
7186
|
], exports.Window);
|
|
7170
7187
|
|
|
7171
|
-
var __defProp$
|
|
7172
|
-
var __decorateClass$
|
|
7188
|
+
var __defProp$B = Object.defineProperty;
|
|
7189
|
+
var __decorateClass$F = (decorators, target, key, kind) => {
|
|
7173
7190
|
var result = void 0 ;
|
|
7174
7191
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7175
7192
|
if (decorator = decorators[i])
|
|
7176
7193
|
result = (decorator(target, key, result) ) || result;
|
|
7177
|
-
if (result) __defProp$
|
|
7194
|
+
if (result) __defProp$B(target, key, result);
|
|
7178
7195
|
return result;
|
|
7179
7196
|
};
|
|
7180
7197
|
class SceneTree extends MainLoop {
|
|
@@ -7254,25 +7271,25 @@ class SceneTree extends MainLoop {
|
|
|
7254
7271
|
super.destroy();
|
|
7255
7272
|
}
|
|
7256
7273
|
}
|
|
7257
|
-
__decorateClass$
|
|
7274
|
+
__decorateClass$F([
|
|
7258
7275
|
modernIdoc.property()
|
|
7259
7276
|
], SceneTree.prototype, "backgroundColor");
|
|
7260
|
-
__decorateClass$
|
|
7277
|
+
__decorateClass$F([
|
|
7261
7278
|
modernIdoc.property({ internal: true, fallback: false })
|
|
7262
7279
|
], SceneTree.prototype, "debug");
|
|
7263
|
-
__decorateClass$
|
|
7280
|
+
__decorateClass$F([
|
|
7264
7281
|
modernIdoc.property({ internal: true, fallback: false })
|
|
7265
7282
|
], SceneTree.prototype, "processPaused");
|
|
7266
|
-
__decorateClass$
|
|
7283
|
+
__decorateClass$F([
|
|
7267
7284
|
modernIdoc.property({ internal: true, default: () => modernFont.fonts })
|
|
7268
7285
|
], SceneTree.prototype, "fonts");
|
|
7269
|
-
__decorateClass$
|
|
7286
|
+
__decorateClass$F([
|
|
7270
7287
|
modernIdoc.property({ internal: true, default: () => new exports.Timeline() })
|
|
7271
7288
|
], SceneTree.prototype, "timeline");
|
|
7272
7289
|
|
|
7273
|
-
var __getOwnPropDesc$
|
|
7274
|
-
var __decorateClass$
|
|
7275
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7290
|
+
var __getOwnPropDesc$v = Object.getOwnPropertyDescriptor;
|
|
7291
|
+
var __decorateClass$E = (decorators, target, key, kind) => {
|
|
7292
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$v(target, key) : target;
|
|
7276
7293
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7277
7294
|
if (decorator = decorators[i])
|
|
7278
7295
|
result = (decorator(result)) || result;
|
|
@@ -7284,7 +7301,7 @@ exports.Transition = class Transition extends exports.Effect {
|
|
|
7284
7301
|
this.setProperties(properties).append(children);
|
|
7285
7302
|
}
|
|
7286
7303
|
};
|
|
7287
|
-
exports.Transition = __decorateClass$
|
|
7304
|
+
exports.Transition = __decorateClass$E([
|
|
7288
7305
|
customNode("Transition", {
|
|
7289
7306
|
effectMode: "transition",
|
|
7290
7307
|
processMode: "pausable",
|
|
@@ -7292,14 +7309,14 @@ exports.Transition = __decorateClass$F([
|
|
|
7292
7309
|
})
|
|
7293
7310
|
], exports.Transition);
|
|
7294
7311
|
|
|
7295
|
-
var __defProp$
|
|
7296
|
-
var __getOwnPropDesc$
|
|
7297
|
-
var __decorateClass$
|
|
7298
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7312
|
+
var __defProp$A = Object.defineProperty;
|
|
7313
|
+
var __getOwnPropDesc$u = Object.getOwnPropertyDescriptor;
|
|
7314
|
+
var __decorateClass$D = (decorators, target, key, kind) => {
|
|
7315
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$u(target, key) : target;
|
|
7299
7316
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7300
7317
|
if (decorator = decorators[i])
|
|
7301
7318
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7302
|
-
if (kind && result) __defProp$
|
|
7319
|
+
if (kind && result) __defProp$A(target, key, result);
|
|
7303
7320
|
return result;
|
|
7304
7321
|
};
|
|
7305
7322
|
exports.Node2D = class Node2D extends exports.CanvasItem {
|
|
@@ -7401,24 +7418,24 @@ exports.Node2D = class Node2D extends exports.CanvasItem {
|
|
|
7401
7418
|
return this.globalTransform.apply(localPos, newPos);
|
|
7402
7419
|
}
|
|
7403
7420
|
};
|
|
7404
|
-
__decorateClass$
|
|
7421
|
+
__decorateClass$D([
|
|
7405
7422
|
modernIdoc.property({ internal: true, fallback: 0 })
|
|
7406
7423
|
], exports.Node2D.prototype, "rotation", 2);
|
|
7407
|
-
__decorateClass$
|
|
7424
|
+
__decorateClass$D([
|
|
7408
7425
|
modernIdoc.property({ internal: true, fallback: 0 })
|
|
7409
7426
|
], exports.Node2D.prototype, "globalRotation", 2);
|
|
7410
|
-
exports.Node2D = __decorateClass$
|
|
7427
|
+
exports.Node2D = __decorateClass$D([
|
|
7411
7428
|
customNode("Node2D")
|
|
7412
7429
|
], exports.Node2D);
|
|
7413
7430
|
|
|
7414
|
-
var __defProp$
|
|
7415
|
-
var __getOwnPropDesc$
|
|
7416
|
-
var __decorateClass$
|
|
7417
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7431
|
+
var __defProp$z = Object.defineProperty;
|
|
7432
|
+
var __getOwnPropDesc$t = Object.getOwnPropertyDescriptor;
|
|
7433
|
+
var __decorateClass$C = (decorators, target, key, kind) => {
|
|
7434
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$t(target, key) : target;
|
|
7418
7435
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7419
7436
|
if (decorator = decorators[i])
|
|
7420
7437
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7421
|
-
if (kind && result) __defProp$
|
|
7438
|
+
if (kind && result) __defProp$z(target, key, result);
|
|
7422
7439
|
return result;
|
|
7423
7440
|
};
|
|
7424
7441
|
exports.Camera2D = class Camera2D extends exports.Node2D {
|
|
@@ -7580,16 +7597,16 @@ exports.Camera2D = class Camera2D extends exports.Node2D {
|
|
|
7580
7597
|
};
|
|
7581
7598
|
}
|
|
7582
7599
|
};
|
|
7583
|
-
__decorateClass$
|
|
7600
|
+
__decorateClass$C([
|
|
7584
7601
|
modernIdoc.property({ fallback: 0.02 })
|
|
7585
7602
|
], exports.Camera2D.prototype, "wheelSensitivity", 2);
|
|
7586
|
-
__decorateClass$
|
|
7603
|
+
__decorateClass$C([
|
|
7587
7604
|
modernIdoc.property({ internal: true, fallback: false })
|
|
7588
7605
|
], exports.Camera2D.prototype, "spaceKey", 2);
|
|
7589
|
-
__decorateClass$
|
|
7606
|
+
__decorateClass$C([
|
|
7590
7607
|
modernIdoc.property({ internal: true, fallback: false })
|
|
7591
7608
|
], exports.Camera2D.prototype, "grabbing", 2);
|
|
7592
|
-
exports.Camera2D = __decorateClass$
|
|
7609
|
+
exports.Camera2D = __decorateClass$C([
|
|
7593
7610
|
customNode("Camera2D", {
|
|
7594
7611
|
processMode: "disabled",
|
|
7595
7612
|
renderMode: "disabled"
|
|
@@ -7742,15 +7759,15 @@ function parseCSSTransformOrigin(transformOrigin) {
|
|
|
7742
7759
|
});
|
|
7743
7760
|
}
|
|
7744
7761
|
|
|
7745
|
-
var __defProp$
|
|
7746
|
-
var __getOwnPropDesc$
|
|
7747
|
-
var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$
|
|
7748
|
-
var __decorateClass$
|
|
7749
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7762
|
+
var __defProp$y = Object.defineProperty;
|
|
7763
|
+
var __getOwnPropDesc$s = Object.getOwnPropertyDescriptor;
|
|
7764
|
+
var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7765
|
+
var __decorateClass$B = (decorators, target, key, kind) => {
|
|
7766
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$s(target, key) : target;
|
|
7750
7767
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7751
7768
|
if (decorator = decorators[i])
|
|
7752
7769
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7753
|
-
if (kind && result) __defProp$
|
|
7770
|
+
if (kind && result) __defProp$y(target, key, result);
|
|
7754
7771
|
return result;
|
|
7755
7772
|
};
|
|
7756
7773
|
var __publicField$j = (obj, key, value) => __defNormalProp$j(obj, key + "" , value);
|
|
@@ -7810,43 +7827,43 @@ void main(void) {
|
|
|
7810
7827
|
gl_FragColor = c * alpha;
|
|
7811
7828
|
}`
|
|
7812
7829
|
}));
|
|
7813
|
-
__decorateClass$
|
|
7830
|
+
__decorateClass$B([
|
|
7814
7831
|
modernIdoc.property({ fallback: 1 })
|
|
7815
7832
|
], exports.ColorAdjustEffect.prototype, "saturation", 2);
|
|
7816
|
-
__decorateClass$
|
|
7833
|
+
__decorateClass$B([
|
|
7817
7834
|
modernIdoc.property({ fallback: 1 })
|
|
7818
7835
|
], exports.ColorAdjustEffect.prototype, "contrast", 2);
|
|
7819
|
-
__decorateClass$
|
|
7836
|
+
__decorateClass$B([
|
|
7820
7837
|
modernIdoc.property({ fallback: 1 })
|
|
7821
7838
|
], exports.ColorAdjustEffect.prototype, "brightness", 2);
|
|
7822
|
-
__decorateClass$
|
|
7839
|
+
__decorateClass$B([
|
|
7823
7840
|
modernIdoc.property({ fallback: 1 })
|
|
7824
7841
|
], exports.ColorAdjustEffect.prototype, "red", 2);
|
|
7825
|
-
__decorateClass$
|
|
7842
|
+
__decorateClass$B([
|
|
7826
7843
|
modernIdoc.property({ fallback: 1 })
|
|
7827
7844
|
], exports.ColorAdjustEffect.prototype, "green", 2);
|
|
7828
|
-
__decorateClass$
|
|
7845
|
+
__decorateClass$B([
|
|
7829
7846
|
modernIdoc.property({ fallback: 1 })
|
|
7830
7847
|
], exports.ColorAdjustEffect.prototype, "blue", 2);
|
|
7831
|
-
__decorateClass$
|
|
7848
|
+
__decorateClass$B([
|
|
7832
7849
|
modernIdoc.property({ fallback: 1 })
|
|
7833
7850
|
], exports.ColorAdjustEffect.prototype, "alpha", 2);
|
|
7834
|
-
__decorateClass$
|
|
7851
|
+
__decorateClass$B([
|
|
7835
7852
|
modernIdoc.property({ fallback: 1 })
|
|
7836
7853
|
], exports.ColorAdjustEffect.prototype, "gamma", 2);
|
|
7837
|
-
exports.ColorAdjustEffect = __decorateClass$
|
|
7854
|
+
exports.ColorAdjustEffect = __decorateClass$B([
|
|
7838
7855
|
customNode("ColorAdjustEffect")
|
|
7839
7856
|
], exports.ColorAdjustEffect);
|
|
7840
7857
|
|
|
7841
|
-
var __defProp$
|
|
7842
|
-
var __getOwnPropDesc$
|
|
7843
|
-
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$
|
|
7844
|
-
var __decorateClass$
|
|
7845
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7858
|
+
var __defProp$x = Object.defineProperty;
|
|
7859
|
+
var __getOwnPropDesc$r = Object.getOwnPropertyDescriptor;
|
|
7860
|
+
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7861
|
+
var __decorateClass$A = (decorators, target, key, kind) => {
|
|
7862
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$r(target, key) : target;
|
|
7846
7863
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7847
7864
|
if (decorator = decorators[i])
|
|
7848
7865
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7849
|
-
if (kind && result) __defProp$
|
|
7866
|
+
if (kind && result) __defProp$x(target, key, result);
|
|
7850
7867
|
return result;
|
|
7851
7868
|
};
|
|
7852
7869
|
var __publicField$i = (obj, key, value) => __defNormalProp$i(obj, key + "" , value);
|
|
@@ -7926,22 +7943,22 @@ void main(void) {
|
|
|
7926
7943
|
);
|
|
7927
7944
|
}`
|
|
7928
7945
|
}));
|
|
7929
|
-
__decorateClass$
|
|
7946
|
+
__decorateClass$A([
|
|
7930
7947
|
modernIdoc.property()
|
|
7931
7948
|
], exports.ColorFilterEffect.prototype, "filter", 2);
|
|
7932
|
-
exports.ColorFilterEffect = __decorateClass$
|
|
7949
|
+
exports.ColorFilterEffect = __decorateClass$A([
|
|
7933
7950
|
customNode("ColorFilterEffect")
|
|
7934
7951
|
], exports.ColorFilterEffect);
|
|
7935
7952
|
|
|
7936
|
-
var __defProp$
|
|
7937
|
-
var __getOwnPropDesc$
|
|
7938
|
-
var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$
|
|
7939
|
-
var __decorateClass$
|
|
7940
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7953
|
+
var __defProp$w = Object.defineProperty;
|
|
7954
|
+
var __getOwnPropDesc$q = Object.getOwnPropertyDescriptor;
|
|
7955
|
+
var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7956
|
+
var __decorateClass$z = (decorators, target, key, kind) => {
|
|
7957
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$q(target, key) : target;
|
|
7941
7958
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
7942
7959
|
if (decorator = decorators[i])
|
|
7943
7960
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7944
|
-
if (kind && result) __defProp$
|
|
7961
|
+
if (kind && result) __defProp$w(target, key, result);
|
|
7945
7962
|
return result;
|
|
7946
7963
|
};
|
|
7947
7964
|
var __publicField$h = (obj, key, value) => __defNormalProp$h(obj, key + "" , value);
|
|
@@ -8017,25 +8034,25 @@ void main(void) {
|
|
|
8017
8034
|
gl_FragColor = vec4(mix(color.rgb, mask.rgb, color.a * mask.a), color.a);
|
|
8018
8035
|
}`
|
|
8019
8036
|
}));
|
|
8020
|
-
__decorateClass$
|
|
8037
|
+
__decorateClass$z([
|
|
8021
8038
|
modernIdoc.property({ default: () => [] })
|
|
8022
8039
|
], exports.ColorOverlayEffect.prototype, "colors", 2);
|
|
8023
|
-
__decorateClass$
|
|
8040
|
+
__decorateClass$z([
|
|
8024
8041
|
modernIdoc.property({ fallback: 0.5 })
|
|
8025
8042
|
], exports.ColorOverlayEffect.prototype, "alpha", 2);
|
|
8026
|
-
exports.ColorOverlayEffect = __decorateClass$
|
|
8043
|
+
exports.ColorOverlayEffect = __decorateClass$z([
|
|
8027
8044
|
customNode("ColorOverlayEffect")
|
|
8028
8045
|
], exports.ColorOverlayEffect);
|
|
8029
8046
|
|
|
8030
|
-
var __defProp$
|
|
8031
|
-
var __getOwnPropDesc$
|
|
8032
|
-
var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$
|
|
8033
|
-
var __decorateClass$
|
|
8034
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8047
|
+
var __defProp$v = Object.defineProperty;
|
|
8048
|
+
var __getOwnPropDesc$p = Object.getOwnPropertyDescriptor;
|
|
8049
|
+
var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8050
|
+
var __decorateClass$y = (decorators, target, key, kind) => {
|
|
8051
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$p(target, key) : target;
|
|
8035
8052
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8036
8053
|
if (decorator = decorators[i])
|
|
8037
8054
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8038
|
-
if (kind && result) __defProp$
|
|
8055
|
+
if (kind && result) __defProp$v(target, key, result);
|
|
8039
8056
|
return result;
|
|
8040
8057
|
};
|
|
8041
8058
|
var __publicField$g = (obj, key, value) => __defNormalProp$g(obj, key + "" , value);
|
|
@@ -8102,25 +8119,25 @@ void main(void) {
|
|
|
8102
8119
|
gl_FragColor = color;
|
|
8103
8120
|
}`
|
|
8104
8121
|
}));
|
|
8105
|
-
__decorateClass$
|
|
8122
|
+
__decorateClass$y([
|
|
8106
8123
|
modernIdoc.property({ default: () => [] })
|
|
8107
8124
|
], exports.ColorRemoveEffect.prototype, "colors", 2);
|
|
8108
|
-
__decorateClass$
|
|
8125
|
+
__decorateClass$y([
|
|
8109
8126
|
modernIdoc.property({ fallback: 0.5 })
|
|
8110
8127
|
], exports.ColorRemoveEffect.prototype, "epsilon", 2);
|
|
8111
|
-
exports.ColorRemoveEffect = __decorateClass$
|
|
8128
|
+
exports.ColorRemoveEffect = __decorateClass$y([
|
|
8112
8129
|
customNode("ColorRemoveEffect")
|
|
8113
8130
|
], exports.ColorRemoveEffect);
|
|
8114
8131
|
|
|
8115
|
-
var __defProp$
|
|
8116
|
-
var __getOwnPropDesc$
|
|
8117
|
-
var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$
|
|
8118
|
-
var __decorateClass$
|
|
8119
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8132
|
+
var __defProp$u = Object.defineProperty;
|
|
8133
|
+
var __getOwnPropDesc$o = Object.getOwnPropertyDescriptor;
|
|
8134
|
+
var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8135
|
+
var __decorateClass$x = (decorators, target, key, kind) => {
|
|
8136
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$o(target, key) : target;
|
|
8120
8137
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8121
8138
|
if (decorator = decorators[i])
|
|
8122
8139
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8123
|
-
if (kind && result) __defProp$
|
|
8140
|
+
if (kind && result) __defProp$u(target, key, result);
|
|
8124
8141
|
return result;
|
|
8125
8142
|
};
|
|
8126
8143
|
var __publicField$f = (obj, key, value) => __defNormalProp$f(obj, key + "" , value);
|
|
@@ -8209,25 +8226,25 @@ void main(void) {
|
|
|
8209
8226
|
}
|
|
8210
8227
|
}`
|
|
8211
8228
|
}));
|
|
8212
|
-
__decorateClass$
|
|
8229
|
+
__decorateClass$x([
|
|
8213
8230
|
modernIdoc.property({ default: () => [] })
|
|
8214
8231
|
], exports.ColorReplaceEffect.prototype, "colors", 2);
|
|
8215
|
-
__decorateClass$
|
|
8232
|
+
__decorateClass$x([
|
|
8216
8233
|
modernIdoc.property({ fallback: 0.05 })
|
|
8217
8234
|
], exports.ColorReplaceEffect.prototype, "epsilon", 2);
|
|
8218
|
-
exports.ColorReplaceEffect = __decorateClass$
|
|
8235
|
+
exports.ColorReplaceEffect = __decorateClass$x([
|
|
8219
8236
|
customNode("ColorReplaceEffect")
|
|
8220
8237
|
], exports.ColorReplaceEffect);
|
|
8221
8238
|
|
|
8222
|
-
var __defProp$
|
|
8223
|
-
var __getOwnPropDesc$
|
|
8224
|
-
var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$
|
|
8225
|
-
var __decorateClass$
|
|
8226
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8239
|
+
var __defProp$t = Object.defineProperty;
|
|
8240
|
+
var __getOwnPropDesc$n = Object.getOwnPropertyDescriptor;
|
|
8241
|
+
var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8242
|
+
var __decorateClass$w = (decorators, target, key, kind) => {
|
|
8243
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$n(target, key) : target;
|
|
8227
8244
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8228
8245
|
if (decorator = decorators[i])
|
|
8229
8246
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8230
|
-
if (kind && result) __defProp$
|
|
8247
|
+
if (kind && result) __defProp$t(target, key, result);
|
|
8231
8248
|
return result;
|
|
8232
8249
|
};
|
|
8233
8250
|
var __publicField$e = (obj, key, value) => __defNormalProp$e(obj, key + "" , value);
|
|
@@ -8320,28 +8337,28 @@ void main(void) {
|
|
|
8320
8337
|
gl_FragColor = color;
|
|
8321
8338
|
}`
|
|
8322
8339
|
}));
|
|
8323
|
-
__decorateClass$
|
|
8340
|
+
__decorateClass$w([
|
|
8324
8341
|
modernIdoc.property({ fallback: false })
|
|
8325
8342
|
], exports.DrawboardEffect.prototype, "checkerboard", 2);
|
|
8326
|
-
__decorateClass$
|
|
8343
|
+
__decorateClass$w([
|
|
8327
8344
|
modernIdoc.property({ fallback: 1 / 16 })
|
|
8328
8345
|
], exports.DrawboardEffect.prototype, "checkerboardScale", 2);
|
|
8329
|
-
__decorateClass$
|
|
8346
|
+
__decorateClass$w([
|
|
8330
8347
|
modernIdoc.property({ fallback: false })
|
|
8331
8348
|
], exports.DrawboardEffect.prototype, "pixelGrid", 2);
|
|
8332
|
-
exports.DrawboardEffect = __decorateClass$
|
|
8349
|
+
exports.DrawboardEffect = __decorateClass$w([
|
|
8333
8350
|
customNode("DrawboardEffect")
|
|
8334
8351
|
], exports.DrawboardEffect);
|
|
8335
8352
|
|
|
8336
|
-
var __defProp$
|
|
8337
|
-
var __getOwnPropDesc$
|
|
8338
|
-
var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$
|
|
8339
|
-
var __decorateClass$
|
|
8340
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8353
|
+
var __defProp$s = Object.defineProperty;
|
|
8354
|
+
var __getOwnPropDesc$m = Object.getOwnPropertyDescriptor;
|
|
8355
|
+
var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8356
|
+
var __decorateClass$v = (decorators, target, key, kind) => {
|
|
8357
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$m(target, key) : target;
|
|
8341
8358
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8342
8359
|
if (decorator = decorators[i])
|
|
8343
8360
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8344
|
-
if (kind && result) __defProp$
|
|
8361
|
+
if (kind && result) __defProp$s(target, key, result);
|
|
8345
8362
|
return result;
|
|
8346
8363
|
};
|
|
8347
8364
|
var __publicField$d = (obj, key, value) => __defNormalProp$d(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
@@ -8447,25 +8464,25 @@ void main(void) {
|
|
|
8447
8464
|
}`,
|
|
8448
8465
|
frag: frag$2
|
|
8449
8466
|
}));
|
|
8450
|
-
__decorateClass$
|
|
8467
|
+
__decorateClass$v([
|
|
8451
8468
|
modernIdoc.property({ fallback: 4 })
|
|
8452
8469
|
], exports.GaussianBlurEffect.prototype, "strength", 2);
|
|
8453
|
-
__decorateClass$
|
|
8470
|
+
__decorateClass$v([
|
|
8454
8471
|
modernIdoc.property({ fallback: 3 })
|
|
8455
8472
|
], exports.GaussianBlurEffect.prototype, "quality", 2);
|
|
8456
|
-
exports.GaussianBlurEffect = __decorateClass$
|
|
8473
|
+
exports.GaussianBlurEffect = __decorateClass$v([
|
|
8457
8474
|
customNode("GaussianBlurEffect")
|
|
8458
8475
|
], exports.GaussianBlurEffect);
|
|
8459
8476
|
|
|
8460
|
-
var __defProp$
|
|
8461
|
-
var __getOwnPropDesc$
|
|
8462
|
-
var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$
|
|
8463
|
-
var __decorateClass$
|
|
8464
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8477
|
+
var __defProp$r = Object.defineProperty;
|
|
8478
|
+
var __getOwnPropDesc$l = Object.getOwnPropertyDescriptor;
|
|
8479
|
+
var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8480
|
+
var __decorateClass$u = (decorators, target, key, kind) => {
|
|
8481
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$l(target, key) : target;
|
|
8465
8482
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8466
8483
|
if (decorator = decorators[i])
|
|
8467
8484
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8468
|
-
if (kind && result) __defProp$
|
|
8485
|
+
if (kind && result) __defProp$r(target, key, result);
|
|
8469
8486
|
return result;
|
|
8470
8487
|
};
|
|
8471
8488
|
var __publicField$c = (obj, key, value) => __defNormalProp$c(obj, key + "" , value);
|
|
@@ -8529,34 +8546,34 @@ void main(void) {
|
|
|
8529
8546
|
gl_FragColor = sample;
|
|
8530
8547
|
}`
|
|
8531
8548
|
}));
|
|
8532
|
-
__decorateClass$
|
|
8549
|
+
__decorateClass$u([
|
|
8533
8550
|
modernIdoc.property({ fallback: "#000000FF" })
|
|
8534
8551
|
], exports.DropShadowEffect.prototype, "color", 2);
|
|
8535
|
-
__decorateClass$
|
|
8552
|
+
__decorateClass$u([
|
|
8536
8553
|
modernIdoc.property({ fallback: 4 })
|
|
8537
8554
|
], exports.DropShadowEffect.prototype, "blur", 2);
|
|
8538
|
-
__decorateClass$
|
|
8555
|
+
__decorateClass$u([
|
|
8539
8556
|
modernIdoc.property({ fallback: 4 })
|
|
8540
8557
|
], exports.DropShadowEffect.prototype, "offsetX", 2);
|
|
8541
|
-
__decorateClass$
|
|
8558
|
+
__decorateClass$u([
|
|
8542
8559
|
modernIdoc.property({ fallback: 4 })
|
|
8543
8560
|
], exports.DropShadowEffect.prototype, "offsetY", 2);
|
|
8544
|
-
__decorateClass$
|
|
8561
|
+
__decorateClass$u([
|
|
8545
8562
|
modernIdoc.property({ fallback: false })
|
|
8546
8563
|
], exports.DropShadowEffect.prototype, "shadowOnly", 2);
|
|
8547
|
-
exports.DropShadowEffect = __decorateClass$
|
|
8564
|
+
exports.DropShadowEffect = __decorateClass$u([
|
|
8548
8565
|
customNode("DropShadowEffect")
|
|
8549
8566
|
], exports.DropShadowEffect);
|
|
8550
8567
|
|
|
8551
|
-
var __defProp$
|
|
8552
|
-
var __getOwnPropDesc$
|
|
8553
|
-
var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$
|
|
8554
|
-
var __decorateClass$
|
|
8555
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8568
|
+
var __defProp$q = Object.defineProperty;
|
|
8569
|
+
var __getOwnPropDesc$k = Object.getOwnPropertyDescriptor;
|
|
8570
|
+
var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8571
|
+
var __decorateClass$t = (decorators, target, key, kind) => {
|
|
8572
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$k(target, key) : target;
|
|
8556
8573
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8557
8574
|
if (decorator = decorators[i])
|
|
8558
8575
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8559
|
-
if (kind && result) __defProp$
|
|
8576
|
+
if (kind && result) __defProp$q(target, key, result);
|
|
8560
8577
|
return result;
|
|
8561
8578
|
};
|
|
8562
8579
|
var __publicField$b = (obj, key, value) => __defNormalProp$b(obj, key + "" , value);
|
|
@@ -8601,22 +8618,22 @@ void main(void) {
|
|
|
8601
8618
|
gl_FragColor = vec4(color.rgb * alpha, alpha);
|
|
8602
8619
|
}`
|
|
8603
8620
|
}));
|
|
8604
|
-
__decorateClass$
|
|
8621
|
+
__decorateClass$t([
|
|
8605
8622
|
modernIdoc.property({ fallback: 5 })
|
|
8606
8623
|
], exports.EmbossEffect.prototype, "strength", 2);
|
|
8607
|
-
exports.EmbossEffect = __decorateClass$
|
|
8624
|
+
exports.EmbossEffect = __decorateClass$t([
|
|
8608
8625
|
customNode("EmbossEffect")
|
|
8609
8626
|
], exports.EmbossEffect);
|
|
8610
8627
|
|
|
8611
|
-
var __defProp$
|
|
8612
|
-
var __getOwnPropDesc$
|
|
8613
|
-
var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$
|
|
8614
|
-
var __decorateClass$
|
|
8615
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8628
|
+
var __defProp$p = Object.defineProperty;
|
|
8629
|
+
var __getOwnPropDesc$j = Object.getOwnPropertyDescriptor;
|
|
8630
|
+
var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8631
|
+
var __decorateClass$s = (decorators, target, key, kind) => {
|
|
8632
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$j(target, key) : target;
|
|
8616
8633
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8617
8634
|
if (decorator = decorators[i])
|
|
8618
8635
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8619
|
-
if (kind && result) __defProp$
|
|
8636
|
+
if (kind && result) __defProp$p(target, key, result);
|
|
8620
8637
|
return result;
|
|
8621
8638
|
};
|
|
8622
8639
|
var __publicField$a = (obj, key, value) => __defNormalProp$a(obj, key + "" , value);
|
|
@@ -8790,46 +8807,46 @@ void main(void) {
|
|
|
8790
8807
|
gl_FragColor.a = texture2D(sampler, coord).a;
|
|
8791
8808
|
}`
|
|
8792
8809
|
}));
|
|
8793
|
-
__decorateClass$
|
|
8810
|
+
__decorateClass$s([
|
|
8794
8811
|
modernIdoc.property({ fallback: 10 })
|
|
8795
8812
|
], exports.GlitchEffect.prototype, "slices", 2);
|
|
8796
|
-
__decorateClass$
|
|
8813
|
+
__decorateClass$s([
|
|
8797
8814
|
modernIdoc.property({ fallback: 512 })
|
|
8798
8815
|
], exports.GlitchEffect.prototype, "sampleSize", 2);
|
|
8799
|
-
__decorateClass$
|
|
8816
|
+
__decorateClass$s([
|
|
8800
8817
|
modernIdoc.property({ fallback: 100 })
|
|
8801
8818
|
], exports.GlitchEffect.prototype, "offset", 2);
|
|
8802
|
-
__decorateClass$
|
|
8819
|
+
__decorateClass$s([
|
|
8803
8820
|
modernIdoc.property({ fallback: 0 })
|
|
8804
8821
|
], exports.GlitchEffect.prototype, "direction", 2);
|
|
8805
|
-
__decorateClass$
|
|
8822
|
+
__decorateClass$s([
|
|
8806
8823
|
modernIdoc.property({ fallback: 2 })
|
|
8807
8824
|
], exports.GlitchEffect.prototype, "fillMode", 2);
|
|
8808
|
-
__decorateClass$
|
|
8825
|
+
__decorateClass$s([
|
|
8809
8826
|
modernIdoc.property({ fallback: 0 })
|
|
8810
8827
|
], exports.GlitchEffect.prototype, "seed", 2);
|
|
8811
|
-
__decorateClass$
|
|
8828
|
+
__decorateClass$s([
|
|
8812
8829
|
modernIdoc.property({ default: () => [2, 2] })
|
|
8813
8830
|
], exports.GlitchEffect.prototype, "red", 2);
|
|
8814
|
-
__decorateClass$
|
|
8831
|
+
__decorateClass$s([
|
|
8815
8832
|
modernIdoc.property({ default: () => [-10, 4] })
|
|
8816
8833
|
], exports.GlitchEffect.prototype, "green", 2);
|
|
8817
|
-
__decorateClass$
|
|
8834
|
+
__decorateClass$s([
|
|
8818
8835
|
modernIdoc.property({ default: () => [10, -4] })
|
|
8819
8836
|
], exports.GlitchEffect.prototype, "blue", 2);
|
|
8820
|
-
exports.GlitchEffect = __decorateClass$
|
|
8837
|
+
exports.GlitchEffect = __decorateClass$s([
|
|
8821
8838
|
customNode("GlitchEffect")
|
|
8822
8839
|
], exports.GlitchEffect);
|
|
8823
8840
|
|
|
8824
|
-
var __defProp$
|
|
8825
|
-
var __getOwnPropDesc$
|
|
8826
|
-
var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$
|
|
8827
|
-
var __decorateClass$
|
|
8828
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8841
|
+
var __defProp$o = Object.defineProperty;
|
|
8842
|
+
var __getOwnPropDesc$i = Object.getOwnPropertyDescriptor;
|
|
8843
|
+
var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8844
|
+
var __decorateClass$r = (decorators, target, key, kind) => {
|
|
8845
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$i(target, key) : target;
|
|
8829
8846
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
8830
8847
|
if (decorator = decorators[i])
|
|
8831
8848
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8832
|
-
if (kind && result) __defProp$
|
|
8849
|
+
if (kind && result) __defProp$o(target, key, result);
|
|
8833
8850
|
return result;
|
|
8834
8851
|
};
|
|
8835
8852
|
var __publicField$9 = (obj, key, value) => __defNormalProp$9(obj, key + "" , value);
|
|
@@ -9007,39 +9024,39 @@ void main(void) {
|
|
|
9007
9024
|
gl_FragColor = vec4(color.rgb + mist.rgb, color.a);
|
|
9008
9025
|
}`
|
|
9009
9026
|
}));
|
|
9010
|
-
__decorateClass$
|
|
9027
|
+
__decorateClass$r([
|
|
9011
9028
|
modernIdoc.property({ fallback: 0 })
|
|
9012
9029
|
], exports.GodrayEffect.prototype, "time", 2);
|
|
9013
|
-
__decorateClass$
|
|
9030
|
+
__decorateClass$r([
|
|
9014
9031
|
modernIdoc.property({ fallback: 30 })
|
|
9015
9032
|
], exports.GodrayEffect.prototype, "angle", 2);
|
|
9016
|
-
__decorateClass$
|
|
9033
|
+
__decorateClass$r([
|
|
9017
9034
|
modernIdoc.property({ fallback: 0.5 })
|
|
9018
9035
|
], exports.GodrayEffect.prototype, "gain", 2);
|
|
9019
|
-
__decorateClass$
|
|
9036
|
+
__decorateClass$r([
|
|
9020
9037
|
modernIdoc.property({ fallback: 2.5 })
|
|
9021
9038
|
], exports.GodrayEffect.prototype, "lacunarity", 2);
|
|
9022
|
-
__decorateClass$
|
|
9039
|
+
__decorateClass$r([
|
|
9023
9040
|
modernIdoc.property({ fallback: true })
|
|
9024
9041
|
], exports.GodrayEffect.prototype, "parallel", 2);
|
|
9025
|
-
__decorateClass$
|
|
9042
|
+
__decorateClass$r([
|
|
9026
9043
|
modernIdoc.property({ default: () => [0, 0] })
|
|
9027
9044
|
], exports.GodrayEffect.prototype, "center", 2);
|
|
9028
|
-
__decorateClass$
|
|
9045
|
+
__decorateClass$r([
|
|
9029
9046
|
modernIdoc.property({ fallback: 1 })
|
|
9030
9047
|
], exports.GodrayEffect.prototype, "alpha", 2);
|
|
9031
|
-
exports.GodrayEffect = __decorateClass$
|
|
9048
|
+
exports.GodrayEffect = __decorateClass$r([
|
|
9032
9049
|
customNode("GodrayEffect")
|
|
9033
9050
|
], exports.GodrayEffect);
|
|
9034
9051
|
|
|
9035
|
-
var __defProp$
|
|
9036
|
-
var __getOwnPropDesc$
|
|
9037
|
-
var __decorateClass$
|
|
9038
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9052
|
+
var __defProp$n = Object.defineProperty;
|
|
9053
|
+
var __getOwnPropDesc$h = Object.getOwnPropertyDescriptor;
|
|
9054
|
+
var __decorateClass$q = (decorators, target, key, kind) => {
|
|
9055
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$h(target, key) : target;
|
|
9039
9056
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9040
9057
|
if (decorator = decorators[i])
|
|
9041
9058
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9042
|
-
if (kind && result) __defProp$
|
|
9059
|
+
if (kind && result) __defProp$n(target, key, result);
|
|
9043
9060
|
return result;
|
|
9044
9061
|
};
|
|
9045
9062
|
const frag$1 = `varying vec2 vUv;
|
|
@@ -9129,28 +9146,28 @@ void main() {
|
|
|
9129
9146
|
});
|
|
9130
9147
|
}
|
|
9131
9148
|
};
|
|
9132
|
-
__decorateClass$
|
|
9149
|
+
__decorateClass$q([
|
|
9133
9150
|
modernIdoc.property({ fallback: 4 })
|
|
9134
9151
|
], exports.KawaseBlurEffect.prototype, "strength", 2);
|
|
9135
|
-
__decorateClass$
|
|
9152
|
+
__decorateClass$q([
|
|
9136
9153
|
modernIdoc.property({ fallback: 3 })
|
|
9137
9154
|
], exports.KawaseBlurEffect.prototype, "quality", 2);
|
|
9138
|
-
__decorateClass$
|
|
9155
|
+
__decorateClass$q([
|
|
9139
9156
|
modernIdoc.property({ default: () => [1, 1] })
|
|
9140
9157
|
], exports.KawaseBlurEffect.prototype, "pixelSize", 2);
|
|
9141
|
-
exports.KawaseBlurEffect = __decorateClass$
|
|
9158
|
+
exports.KawaseBlurEffect = __decorateClass$q([
|
|
9142
9159
|
customNode("KawaseBlurEffect")
|
|
9143
9160
|
], exports.KawaseBlurEffect);
|
|
9144
9161
|
|
|
9145
|
-
var __defProp$
|
|
9146
|
-
var __getOwnPropDesc$
|
|
9147
|
-
var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$
|
|
9148
|
-
var __decorateClass$
|
|
9149
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9162
|
+
var __defProp$m = Object.defineProperty;
|
|
9163
|
+
var __getOwnPropDesc$g = Object.getOwnPropertyDescriptor;
|
|
9164
|
+
var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9165
|
+
var __decorateClass$p = (decorators, target, key, kind) => {
|
|
9166
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$g(target, key) : target;
|
|
9150
9167
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9151
9168
|
if (decorator = decorators[i])
|
|
9152
9169
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9153
|
-
if (kind && result) __defProp$
|
|
9170
|
+
if (kind && result) __defProp$m(target, key, result);
|
|
9154
9171
|
return result;
|
|
9155
9172
|
};
|
|
9156
9173
|
var __publicField$8 = (obj, key, value) => __defNormalProp$8(obj, key + "" , value);
|
|
@@ -9238,25 +9255,25 @@ void main(void) {
|
|
|
9238
9255
|
}
|
|
9239
9256
|
}`
|
|
9240
9257
|
}));
|
|
9241
|
-
__decorateClass$
|
|
9258
|
+
__decorateClass$p([
|
|
9242
9259
|
modernIdoc.property({ internal: true })
|
|
9243
9260
|
], exports.MaskEffect.prototype, "texture", 2);
|
|
9244
|
-
__decorateClass$
|
|
9261
|
+
__decorateClass$p([
|
|
9245
9262
|
modernIdoc.property({ fallback: "" })
|
|
9246
9263
|
], exports.MaskEffect.prototype, "src", 2);
|
|
9247
|
-
exports.MaskEffect = __decorateClass$
|
|
9264
|
+
exports.MaskEffect = __decorateClass$p([
|
|
9248
9265
|
customNode("MaskEffect")
|
|
9249
9266
|
], exports.MaskEffect);
|
|
9250
9267
|
|
|
9251
|
-
var __defProp$
|
|
9252
|
-
var __getOwnPropDesc$
|
|
9253
|
-
var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$
|
|
9254
|
-
var __decorateClass$
|
|
9255
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9268
|
+
var __defProp$l = Object.defineProperty;
|
|
9269
|
+
var __getOwnPropDesc$f = Object.getOwnPropertyDescriptor;
|
|
9270
|
+
var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9271
|
+
var __decorateClass$o = (decorators, target, key, kind) => {
|
|
9272
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$f(target, key) : target;
|
|
9256
9273
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9257
9274
|
if (decorator = decorators[i])
|
|
9258
9275
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9259
|
-
if (kind && result) __defProp$
|
|
9276
|
+
if (kind && result) __defProp$l(target, key, result);
|
|
9260
9277
|
return result;
|
|
9261
9278
|
};
|
|
9262
9279
|
var __publicField$7 = (obj, key, value) => __defNormalProp$7(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
@@ -9343,40 +9360,40 @@ void main() {
|
|
|
9343
9360
|
};
|
|
9344
9361
|
__publicField$7(exports.OutlineEffect, "MIN_SAMPLES", 1);
|
|
9345
9362
|
__publicField$7(exports.OutlineEffect, "MAX_SAMPLES", 100);
|
|
9346
|
-
__decorateClass$
|
|
9363
|
+
__decorateClass$o([
|
|
9347
9364
|
modernIdoc.property({ fallback: "#000000ff" })
|
|
9348
9365
|
], exports.OutlineEffect.prototype, "color", 2);
|
|
9349
|
-
__decorateClass$
|
|
9366
|
+
__decorateClass$o([
|
|
9350
9367
|
modernIdoc.property({ fallback: 1 })
|
|
9351
9368
|
], exports.OutlineEffect.prototype, "width", 2);
|
|
9352
|
-
__decorateClass$
|
|
9369
|
+
__decorateClass$o([
|
|
9353
9370
|
modernIdoc.property({ fallback: "solid" })
|
|
9354
9371
|
], exports.OutlineEffect.prototype, "style", 2);
|
|
9355
|
-
__decorateClass$
|
|
9372
|
+
__decorateClass$o([
|
|
9356
9373
|
modernIdoc.property()
|
|
9357
9374
|
], exports.OutlineEffect.prototype, "image", 2);
|
|
9358
|
-
__decorateClass$
|
|
9375
|
+
__decorateClass$o([
|
|
9359
9376
|
modernIdoc.property({ fallback: 1 })
|
|
9360
9377
|
], exports.OutlineEffect.prototype, "opacity", 2);
|
|
9361
|
-
__decorateClass$
|
|
9378
|
+
__decorateClass$o([
|
|
9362
9379
|
modernIdoc.property({ fallback: 0.1 })
|
|
9363
9380
|
], exports.OutlineEffect.prototype, "quality", 2);
|
|
9364
|
-
__decorateClass$
|
|
9381
|
+
__decorateClass$o([
|
|
9365
9382
|
modernIdoc.property({ fallback: false })
|
|
9366
9383
|
], exports.OutlineEffect.prototype, "knockout", 2);
|
|
9367
|
-
exports.OutlineEffect = __decorateClass$
|
|
9384
|
+
exports.OutlineEffect = __decorateClass$o([
|
|
9368
9385
|
customNode("OutlineEffect")
|
|
9369
9386
|
], exports.OutlineEffect);
|
|
9370
9387
|
|
|
9371
|
-
var __defProp$
|
|
9372
|
-
var __getOwnPropDesc$
|
|
9373
|
-
var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$
|
|
9374
|
-
var __decorateClass$
|
|
9375
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9388
|
+
var __defProp$k = Object.defineProperty;
|
|
9389
|
+
var __getOwnPropDesc$e = Object.getOwnPropertyDescriptor;
|
|
9390
|
+
var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9391
|
+
var __decorateClass$n = (decorators, target, key, kind) => {
|
|
9392
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$e(target, key) : target;
|
|
9376
9393
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9377
9394
|
if (decorator = decorators[i])
|
|
9378
9395
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9379
|
-
if (kind && result) __defProp$
|
|
9396
|
+
if (kind && result) __defProp$k(target, key, result);
|
|
9380
9397
|
return result;
|
|
9381
9398
|
};
|
|
9382
9399
|
var __publicField$6 = (obj, key, value) => __defNormalProp$6(obj, key + "" , value);
|
|
@@ -9432,22 +9449,22 @@ void main(void) {
|
|
|
9432
9449
|
gl_FragColor = texture2D(sampler, coord);
|
|
9433
9450
|
}`
|
|
9434
9451
|
}));
|
|
9435
|
-
__decorateClass$
|
|
9452
|
+
__decorateClass$n([
|
|
9436
9453
|
modernIdoc.property({ fallback: 10 })
|
|
9437
9454
|
], exports.PixelateEffect.prototype, "strength", 2);
|
|
9438
|
-
exports.PixelateEffect = __decorateClass$
|
|
9455
|
+
exports.PixelateEffect = __decorateClass$n([
|
|
9439
9456
|
customNode("PixelateEffect")
|
|
9440
9457
|
], exports.PixelateEffect);
|
|
9441
9458
|
|
|
9442
|
-
var __defProp$
|
|
9443
|
-
var __getOwnPropDesc$
|
|
9444
|
-
var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$
|
|
9445
|
-
var __decorateClass$
|
|
9446
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9459
|
+
var __defProp$j = Object.defineProperty;
|
|
9460
|
+
var __getOwnPropDesc$d = Object.getOwnPropertyDescriptor;
|
|
9461
|
+
var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9462
|
+
var __decorateClass$m = (decorators, target, key, kind) => {
|
|
9463
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$d(target, key) : target;
|
|
9447
9464
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9448
9465
|
if (decorator = decorators[i])
|
|
9449
9466
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9450
|
-
if (kind && result) __defProp$
|
|
9467
|
+
if (kind && result) __defProp$j(target, key, result);
|
|
9451
9468
|
return result;
|
|
9452
9469
|
};
|
|
9453
9470
|
var __publicField$5 = (obj, key, value) => __defNormalProp$5(obj, key + "" , value);
|
|
@@ -9560,19 +9577,19 @@ void main() {
|
|
|
9560
9577
|
gl_FragColor = color;
|
|
9561
9578
|
}`
|
|
9562
9579
|
}));
|
|
9563
|
-
__decorateClass$
|
|
9580
|
+
__decorateClass$m([
|
|
9564
9581
|
modernIdoc.property()
|
|
9565
9582
|
], exports.ZoomBlurEffect.prototype, "center", 2);
|
|
9566
|
-
__decorateClass$
|
|
9583
|
+
__decorateClass$m([
|
|
9567
9584
|
modernIdoc.property({ fallback: 20 })
|
|
9568
9585
|
], exports.ZoomBlurEffect.prototype, "innerRadius", 2);
|
|
9569
|
-
__decorateClass$
|
|
9586
|
+
__decorateClass$m([
|
|
9570
9587
|
modernIdoc.property({ fallback: -1 })
|
|
9571
9588
|
], exports.ZoomBlurEffect.prototype, "radius", 2);
|
|
9572
|
-
__decorateClass$
|
|
9589
|
+
__decorateClass$m([
|
|
9573
9590
|
modernIdoc.property({ fallback: 0.1 })
|
|
9574
9591
|
], exports.ZoomBlurEffect.prototype, "strength", 2);
|
|
9575
|
-
exports.ZoomBlurEffect = __decorateClass$
|
|
9592
|
+
exports.ZoomBlurEffect = __decorateClass$m([
|
|
9576
9593
|
customNode("ZoomBlurEffect")
|
|
9577
9594
|
], exports.ZoomBlurEffect);
|
|
9578
9595
|
|
|
@@ -9620,13 +9637,13 @@ function getDrawOptions(fill, box) {
|
|
|
9620
9637
|
return { disableWrapMode, uvTransform };
|
|
9621
9638
|
}
|
|
9622
9639
|
|
|
9623
|
-
var __defProp$
|
|
9624
|
-
var __decorateClass$
|
|
9640
|
+
var __defProp$i = Object.defineProperty;
|
|
9641
|
+
var __decorateClass$l = (decorators, target, key, kind) => {
|
|
9625
9642
|
var result = void 0 ;
|
|
9626
9643
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9627
9644
|
if (decorator = decorators[i])
|
|
9628
9645
|
result = (decorator(target, key, result) ) || result;
|
|
9629
|
-
if (result) __defProp$
|
|
9646
|
+
if (result) __defProp$i(target, key, result);
|
|
9630
9647
|
return result;
|
|
9631
9648
|
};
|
|
9632
9649
|
class BaseElement2DFill extends CoreObject {
|
|
@@ -9684,7 +9701,7 @@ class BaseElement2DFill extends CoreObject {
|
|
|
9684
9701
|
await this.loadTexture();
|
|
9685
9702
|
this.parent.requestRedraw();
|
|
9686
9703
|
}
|
|
9687
|
-
|
|
9704
|
+
isValid() {
|
|
9688
9705
|
return Boolean(
|
|
9689
9706
|
this.enabled && (this._texture || this._animatedTexture || this.color)
|
|
9690
9707
|
);
|
|
@@ -9736,47 +9753,47 @@ class BaseElement2DFill extends CoreObject {
|
|
|
9736
9753
|
return this;
|
|
9737
9754
|
}
|
|
9738
9755
|
}
|
|
9739
|
-
__decorateClass$
|
|
9756
|
+
__decorateClass$l([
|
|
9740
9757
|
modernIdoc.property({ fallback: true })
|
|
9741
9758
|
], BaseElement2DFill.prototype, "enabled");
|
|
9742
|
-
__decorateClass$
|
|
9759
|
+
__decorateClass$l([
|
|
9743
9760
|
modernIdoc.property()
|
|
9744
9761
|
], BaseElement2DFill.prototype, "color");
|
|
9745
|
-
__decorateClass$
|
|
9762
|
+
__decorateClass$l([
|
|
9746
9763
|
modernIdoc.property()
|
|
9747
9764
|
], BaseElement2DFill.prototype, "image");
|
|
9748
|
-
__decorateClass$
|
|
9765
|
+
__decorateClass$l([
|
|
9749
9766
|
modernIdoc.property()
|
|
9750
9767
|
], BaseElement2DFill.prototype, "linearGradient");
|
|
9751
|
-
__decorateClass$
|
|
9768
|
+
__decorateClass$l([
|
|
9752
9769
|
modernIdoc.property()
|
|
9753
9770
|
], BaseElement2DFill.prototype, "radialGradient");
|
|
9754
|
-
__decorateClass$
|
|
9771
|
+
__decorateClass$l([
|
|
9755
9772
|
modernIdoc.property()
|
|
9756
9773
|
], BaseElement2DFill.prototype, "cropRect");
|
|
9757
|
-
__decorateClass$
|
|
9774
|
+
__decorateClass$l([
|
|
9758
9775
|
modernIdoc.property()
|
|
9759
9776
|
], BaseElement2DFill.prototype, "stretchRect");
|
|
9760
|
-
__decorateClass$
|
|
9777
|
+
__decorateClass$l([
|
|
9761
9778
|
modernIdoc.property()
|
|
9762
9779
|
], BaseElement2DFill.prototype, "dpi");
|
|
9763
|
-
__decorateClass$
|
|
9780
|
+
__decorateClass$l([
|
|
9764
9781
|
modernIdoc.property()
|
|
9765
9782
|
], BaseElement2DFill.prototype, "rotateWithShape");
|
|
9766
|
-
__decorateClass$
|
|
9783
|
+
__decorateClass$l([
|
|
9767
9784
|
modernIdoc.property()
|
|
9768
9785
|
], BaseElement2DFill.prototype, "tile");
|
|
9769
|
-
__decorateClass$
|
|
9786
|
+
__decorateClass$l([
|
|
9770
9787
|
modernIdoc.property()
|
|
9771
9788
|
], BaseElement2DFill.prototype, "opacity");
|
|
9772
9789
|
|
|
9773
|
-
var __defProp$
|
|
9774
|
-
var __decorateClass$
|
|
9790
|
+
var __defProp$h = Object.defineProperty;
|
|
9791
|
+
var __decorateClass$k = (decorators, target, key, kind) => {
|
|
9775
9792
|
var result = void 0 ;
|
|
9776
9793
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9777
9794
|
if (decorator = decorators[i])
|
|
9778
9795
|
result = (decorator(target, key, result) ) || result;
|
|
9779
|
-
if (result) __defProp$
|
|
9796
|
+
if (result) __defProp$h(target, key, result);
|
|
9780
9797
|
return result;
|
|
9781
9798
|
};
|
|
9782
9799
|
class BaseElement2DBackground extends BaseElement2DFill {
|
|
@@ -9794,17 +9811,17 @@ class BaseElement2DBackground extends BaseElement2DFill {
|
|
|
9794
9811
|
}
|
|
9795
9812
|
}
|
|
9796
9813
|
}
|
|
9797
|
-
__decorateClass$
|
|
9814
|
+
__decorateClass$k([
|
|
9798
9815
|
modernIdoc.property()
|
|
9799
9816
|
], BaseElement2DBackground.prototype, "fillWithShape");
|
|
9800
9817
|
|
|
9801
|
-
var __defProp$
|
|
9802
|
-
var __decorateClass$
|
|
9818
|
+
var __defProp$g = Object.defineProperty;
|
|
9819
|
+
var __decorateClass$j = (decorators, target, key, kind) => {
|
|
9803
9820
|
var result = void 0 ;
|
|
9804
9821
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9805
9822
|
if (decorator = decorators[i])
|
|
9806
9823
|
result = (decorator(target, key, result) ) || result;
|
|
9807
|
-
if (result) __defProp$
|
|
9824
|
+
if (result) __defProp$g(target, key, result);
|
|
9808
9825
|
return result;
|
|
9809
9826
|
};
|
|
9810
9827
|
class BaseElement2DForeground extends BaseElement2DFill {
|
|
@@ -9822,17 +9839,17 @@ class BaseElement2DForeground extends BaseElement2DFill {
|
|
|
9822
9839
|
}
|
|
9823
9840
|
}
|
|
9824
9841
|
}
|
|
9825
|
-
__decorateClass$
|
|
9842
|
+
__decorateClass$j([
|
|
9826
9843
|
modernIdoc.property()
|
|
9827
9844
|
], BaseElement2DForeground.prototype, "fillWithShape");
|
|
9828
9845
|
|
|
9829
|
-
var __defProp$
|
|
9830
|
-
var __decorateClass$
|
|
9846
|
+
var __defProp$f = Object.defineProperty;
|
|
9847
|
+
var __decorateClass$i = (decorators, target, key, kind) => {
|
|
9831
9848
|
var result = void 0 ;
|
|
9832
9849
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9833
9850
|
if (decorator = decorators[i])
|
|
9834
9851
|
result = (decorator(target, key, result) ) || result;
|
|
9835
|
-
if (result) __defProp$
|
|
9852
|
+
if (result) __defProp$f(target, key, result);
|
|
9836
9853
|
return result;
|
|
9837
9854
|
};
|
|
9838
9855
|
class BaseElement2DOutline extends BaseElement2DFill {
|
|
@@ -9853,9 +9870,9 @@ class BaseElement2DOutline extends BaseElement2DFill {
|
|
|
9853
9870
|
break;
|
|
9854
9871
|
}
|
|
9855
9872
|
}
|
|
9856
|
-
|
|
9873
|
+
isValid() {
|
|
9857
9874
|
return Boolean(
|
|
9858
|
-
this.enabled && (this.width || this.color || super.
|
|
9875
|
+
this.enabled && (this.width || this.color || super.isValid())
|
|
9859
9876
|
);
|
|
9860
9877
|
}
|
|
9861
9878
|
draw() {
|
|
@@ -9875,29 +9892,29 @@ class BaseElement2DOutline extends BaseElement2DFill {
|
|
|
9875
9892
|
ctx.stroke({ disableWrapMode });
|
|
9876
9893
|
}
|
|
9877
9894
|
}
|
|
9878
|
-
__decorateClass$
|
|
9895
|
+
__decorateClass$i([
|
|
9879
9896
|
modernIdoc.property({ fallback: "#00000000" })
|
|
9880
9897
|
], BaseElement2DOutline.prototype, "color");
|
|
9881
|
-
__decorateClass$
|
|
9898
|
+
__decorateClass$i([
|
|
9882
9899
|
modernIdoc.property({ fallback: 0 })
|
|
9883
9900
|
], BaseElement2DOutline.prototype, "width");
|
|
9884
|
-
__decorateClass$
|
|
9901
|
+
__decorateClass$i([
|
|
9885
9902
|
modernIdoc.property({ fallback: "solid" })
|
|
9886
9903
|
], BaseElement2DOutline.prototype, "style");
|
|
9887
|
-
__decorateClass$
|
|
9904
|
+
__decorateClass$i([
|
|
9888
9905
|
modernIdoc.property({ fallback: "butt" })
|
|
9889
9906
|
], BaseElement2DOutline.prototype, "lineCap");
|
|
9890
|
-
__decorateClass$
|
|
9907
|
+
__decorateClass$i([
|
|
9891
9908
|
modernIdoc.property({ fallback: "miter" })
|
|
9892
9909
|
], BaseElement2DOutline.prototype, "lineJoin");
|
|
9893
9910
|
|
|
9894
|
-
var __defProp$
|
|
9895
|
-
var __decorateClass$
|
|
9911
|
+
var __defProp$e = Object.defineProperty;
|
|
9912
|
+
var __decorateClass$h = (decorators, target, key, kind) => {
|
|
9896
9913
|
var result = void 0 ;
|
|
9897
9914
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9898
9915
|
if (decorator = decorators[i])
|
|
9899
9916
|
result = (decorator(target, key, result) ) || result;
|
|
9900
|
-
if (result) __defProp$
|
|
9917
|
+
if (result) __defProp$e(target, key, result);
|
|
9901
9918
|
return result;
|
|
9902
9919
|
};
|
|
9903
9920
|
class BaseElement2DShadow extends CoreObject {
|
|
@@ -9937,29 +9954,29 @@ class BaseElement2DShadow extends CoreObject {
|
|
|
9937
9954
|
}
|
|
9938
9955
|
}
|
|
9939
9956
|
}
|
|
9940
|
-
__decorateClass$
|
|
9957
|
+
__decorateClass$h([
|
|
9941
9958
|
modernIdoc.property({ fallback: true })
|
|
9942
9959
|
], BaseElement2DShadow.prototype, "enabled");
|
|
9943
|
-
__decorateClass$
|
|
9960
|
+
__decorateClass$h([
|
|
9944
9961
|
modernIdoc.property({ fallback: "#000000FF" })
|
|
9945
9962
|
], BaseElement2DShadow.prototype, "color");
|
|
9946
|
-
__decorateClass$
|
|
9963
|
+
__decorateClass$h([
|
|
9947
9964
|
modernIdoc.property({ fallback: 0 })
|
|
9948
9965
|
], BaseElement2DShadow.prototype, "blur");
|
|
9949
|
-
__decorateClass$
|
|
9966
|
+
__decorateClass$h([
|
|
9950
9967
|
modernIdoc.property({ fallback: 0 })
|
|
9951
9968
|
], BaseElement2DShadow.prototype, "offsetY");
|
|
9952
|
-
__decorateClass$
|
|
9969
|
+
__decorateClass$h([
|
|
9953
9970
|
modernIdoc.property({ fallback: 0 })
|
|
9954
9971
|
], BaseElement2DShadow.prototype, "offsetX");
|
|
9955
9972
|
|
|
9956
|
-
var __defProp$
|
|
9957
|
-
var __decorateClass$
|
|
9973
|
+
var __defProp$d = Object.defineProperty;
|
|
9974
|
+
var __decorateClass$g = (decorators, target, key, kind) => {
|
|
9958
9975
|
var result = void 0 ;
|
|
9959
9976
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
9960
9977
|
if (decorator = decorators[i])
|
|
9961
9978
|
result = (decorator(target, key, result) ) || result;
|
|
9962
|
-
if (result) __defProp$
|
|
9979
|
+
if (result) __defProp$d(target, key, result);
|
|
9963
9980
|
return result;
|
|
9964
9981
|
};
|
|
9965
9982
|
class BaseElement2DShape extends CoreObject {
|
|
@@ -10010,18 +10027,18 @@ class BaseElement2DShape extends CoreObject {
|
|
|
10010
10027
|
path.applyTransform(new modernPath2d.Matrix3().translate(-x, -y).scale(1 / w, 1 / h));
|
|
10011
10028
|
});
|
|
10012
10029
|
}
|
|
10013
|
-
draw() {
|
|
10014
|
-
if (this.enabled && this._path2DSet.paths.length) {
|
|
10030
|
+
draw(rect = false) {
|
|
10031
|
+
if (!rect && this.enabled && this._path2DSet.paths.length) {
|
|
10015
10032
|
const ctx = this.parent.context;
|
|
10016
10033
|
const { width, height } = this.parent.size;
|
|
10017
10034
|
this._path2DSet.paths.forEach((path) => {
|
|
10018
10035
|
ctx.addPath(path.clone().applyTransform(new modernPath2d.Matrix3().scale(width, height)));
|
|
10019
10036
|
});
|
|
10020
10037
|
} else {
|
|
10021
|
-
this.
|
|
10038
|
+
this._drawRect();
|
|
10022
10039
|
}
|
|
10023
10040
|
}
|
|
10024
|
-
|
|
10041
|
+
_drawRect() {
|
|
10025
10042
|
const ctx = this.parent.context;
|
|
10026
10043
|
const { width, height } = this.parent.size;
|
|
10027
10044
|
const { borderRadius } = this.parent.style;
|
|
@@ -10034,19 +10051,19 @@ class BaseElement2DShape extends CoreObject {
|
|
|
10034
10051
|
}
|
|
10035
10052
|
}
|
|
10036
10053
|
}
|
|
10037
|
-
__decorateClass$
|
|
10054
|
+
__decorateClass$g([
|
|
10038
10055
|
modernIdoc.property({ fallback: true })
|
|
10039
10056
|
], BaseElement2DShape.prototype, "enabled");
|
|
10040
|
-
__decorateClass$
|
|
10057
|
+
__decorateClass$g([
|
|
10041
10058
|
modernIdoc.property()
|
|
10042
10059
|
], BaseElement2DShape.prototype, "preset");
|
|
10043
|
-
__decorateClass$
|
|
10060
|
+
__decorateClass$g([
|
|
10044
10061
|
modernIdoc.property()
|
|
10045
10062
|
], BaseElement2DShape.prototype, "svg");
|
|
10046
|
-
__decorateClass$
|
|
10063
|
+
__decorateClass$g([
|
|
10047
10064
|
modernIdoc.property()
|
|
10048
10065
|
], BaseElement2DShape.prototype, "viewBox");
|
|
10049
|
-
__decorateClass$
|
|
10066
|
+
__decorateClass$g([
|
|
10050
10067
|
modernIdoc.property()
|
|
10051
10068
|
], BaseElement2DShape.prototype, "paths");
|
|
10052
10069
|
|
|
@@ -10062,13 +10079,13 @@ for (const key in defaultStyles$1) {
|
|
|
10062
10079
|
modernIdoc.defineProperty(BaseElement2DStyle, key, { fallback });
|
|
10063
10080
|
}
|
|
10064
10081
|
|
|
10065
|
-
var __defProp$
|
|
10066
|
-
var __decorateClass$
|
|
10082
|
+
var __defProp$c = Object.defineProperty;
|
|
10083
|
+
var __decorateClass$f = (decorators, target, key, kind) => {
|
|
10067
10084
|
var result = void 0 ;
|
|
10068
10085
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
10069
10086
|
if (decorator = decorators[i])
|
|
10070
10087
|
result = (decorator(target, key, result) ) || result;
|
|
10071
|
-
if (result) __defProp$
|
|
10088
|
+
if (result) __defProp$c(target, key, result);
|
|
10072
10089
|
return result;
|
|
10073
10090
|
};
|
|
10074
10091
|
class BaseElement2DText extends CoreObject {
|
|
@@ -10080,6 +10097,7 @@ class BaseElement2DText extends CoreObject {
|
|
|
10080
10097
|
}
|
|
10081
10098
|
base;
|
|
10082
10099
|
measureResult;
|
|
10100
|
+
_texture = new CanvasTexture();
|
|
10083
10101
|
_textureMap = /* @__PURE__ */ new Map();
|
|
10084
10102
|
setProperties(properties) {
|
|
10085
10103
|
return super.setProperties(
|
|
@@ -10090,24 +10108,28 @@ class BaseElement2DText extends CoreObject {
|
|
|
10090
10108
|
super._updateProperty(key, value, oldValue);
|
|
10091
10109
|
switch (key) {
|
|
10092
10110
|
case "enabled":
|
|
10111
|
+
this.parent.requestRedraw();
|
|
10112
|
+
break;
|
|
10093
10113
|
case "effects":
|
|
10094
10114
|
case "measureDom":
|
|
10095
10115
|
case "fonts":
|
|
10116
|
+
this.update();
|
|
10096
10117
|
this.parent.requestRedraw();
|
|
10097
10118
|
break;
|
|
10098
10119
|
case "fill":
|
|
10099
10120
|
case "outline":
|
|
10100
10121
|
case "content":
|
|
10122
|
+
this.update();
|
|
10101
10123
|
this._updateTextureMap();
|
|
10124
|
+
this.parent.requestRedraw();
|
|
10102
10125
|
break;
|
|
10103
10126
|
}
|
|
10104
10127
|
}
|
|
10105
|
-
|
|
10128
|
+
update() {
|
|
10106
10129
|
this.base.fonts = this.base.fonts ?? this.parent.tree?.fonts;
|
|
10107
10130
|
this.base.update();
|
|
10108
10131
|
}
|
|
10109
10132
|
_updateTextureMap() {
|
|
10110
|
-
this._updateBase();
|
|
10111
10133
|
this._textureMap.clear();
|
|
10112
10134
|
const pGlyphBoxs = [];
|
|
10113
10135
|
this.base.paragraphs.forEach((p, pIndex) => {
|
|
@@ -10134,7 +10156,6 @@ class BaseElement2DText extends CoreObject {
|
|
|
10134
10156
|
this._updateTexture("fill", this.fill, glyphBox);
|
|
10135
10157
|
this._updateTexture("outline", this.outline, glyphBox);
|
|
10136
10158
|
}
|
|
10137
|
-
this.parent.requestRedraw();
|
|
10138
10159
|
}
|
|
10139
10160
|
async _updateTexture(key, fill, box) {
|
|
10140
10161
|
if (fill && Object.keys(fill).length > 0) {
|
|
@@ -10163,19 +10184,19 @@ class BaseElement2DText extends CoreObject {
|
|
|
10163
10184
|
this.content = modernIdoc.normalizeTextContent(content);
|
|
10164
10185
|
}
|
|
10165
10186
|
measure() {
|
|
10166
|
-
this.
|
|
10187
|
+
this.update();
|
|
10167
10188
|
return this.base.measure();
|
|
10168
10189
|
}
|
|
10169
10190
|
updateMeasure() {
|
|
10170
10191
|
this.measureResult = this.measure();
|
|
10171
10192
|
return this;
|
|
10172
10193
|
}
|
|
10173
|
-
|
|
10194
|
+
isValid() {
|
|
10174
10195
|
return Boolean(
|
|
10175
10196
|
this.enabled && !/^\s*$/.test(this.base.toString())
|
|
10176
10197
|
);
|
|
10177
10198
|
}
|
|
10178
|
-
|
|
10199
|
+
_createVertTransform() {
|
|
10179
10200
|
const parent = this.parent;
|
|
10180
10201
|
if (parent.scale.x > 0 && parent.scale.y > 0) {
|
|
10181
10202
|
return void 0;
|
|
@@ -10184,9 +10205,12 @@ class BaseElement2DText extends CoreObject {
|
|
|
10184
10205
|
const origin = parent.getTransformOrigin();
|
|
10185
10206
|
return new Transform2D().translate(-origin.x, -origin.y).scale(scale > 0 ? 1 : -1, 1).translate(origin.x, origin.y);
|
|
10186
10207
|
}
|
|
10187
|
-
|
|
10188
|
-
|
|
10189
|
-
|
|
10208
|
+
_useDrawByTexture() {
|
|
10209
|
+
return !!this.effects?.length || this.content.some((p) => {
|
|
10210
|
+
return p.fragments.some((f) => !!f.highlightImage);
|
|
10211
|
+
});
|
|
10212
|
+
}
|
|
10213
|
+
_drawByVertices(ctx) {
|
|
10190
10214
|
this.base.pathSets.forEach((pathSet) => {
|
|
10191
10215
|
pathSet.paths.forEach((path) => {
|
|
10192
10216
|
const meta = path.getMeta();
|
|
@@ -10209,13 +10233,13 @@ class BaseElement2DText extends CoreObject {
|
|
|
10209
10233
|
ctx.style = { ...path.style };
|
|
10210
10234
|
ctx.uvTransform = uvTransform;
|
|
10211
10235
|
ctx.fillStyle = texture?.texture ?? fill.color;
|
|
10212
|
-
ctx.vertTransform = this.
|
|
10236
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10213
10237
|
ctx.fill({ disableWrapMode });
|
|
10214
10238
|
}
|
|
10215
10239
|
} else {
|
|
10216
10240
|
ctx.addPath(path);
|
|
10217
10241
|
ctx.style = { ...path.style };
|
|
10218
|
-
ctx.vertTransform = this.
|
|
10242
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10219
10243
|
ctx.fill();
|
|
10220
10244
|
}
|
|
10221
10245
|
}
|
|
@@ -10238,54 +10262,70 @@ class BaseElement2DText extends CoreObject {
|
|
|
10238
10262
|
ctx.strokeStyle = texture?.texture ?? outline.color;
|
|
10239
10263
|
ctx.lineCap = outline.lineCap;
|
|
10240
10264
|
ctx.lineJoin = outline.lineJoin;
|
|
10241
|
-
ctx.vertTransform = this.
|
|
10265
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10242
10266
|
ctx.stroke({ disableWrapMode });
|
|
10243
10267
|
}
|
|
10244
10268
|
} else {
|
|
10245
10269
|
ctx.addPath(path);
|
|
10246
10270
|
ctx.style = { ...path.style };
|
|
10247
|
-
ctx.vertTransform = this.
|
|
10271
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10248
10272
|
ctx.stroke();
|
|
10249
10273
|
}
|
|
10250
10274
|
}
|
|
10251
10275
|
} else {
|
|
10252
10276
|
ctx.addPath(path);
|
|
10253
10277
|
ctx.style = { ...path.style };
|
|
10254
|
-
ctx.vertTransform = this.
|
|
10278
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10255
10279
|
ctx.fill();
|
|
10256
10280
|
}
|
|
10257
10281
|
});
|
|
10258
10282
|
});
|
|
10259
10283
|
}
|
|
10284
|
+
_drawByTexture(ctx) {
|
|
10285
|
+
this._texture.width = Math.round(this.base.boundingBox.width);
|
|
10286
|
+
this._texture.height = Math.round(this.base.boundingBox.height);
|
|
10287
|
+
this.base.render({ view: this._texture.source });
|
|
10288
|
+
ctx.fillStyle = this._texture;
|
|
10289
|
+
ctx.vertTransform = this._createVertTransform();
|
|
10290
|
+
ctx.fill();
|
|
10291
|
+
}
|
|
10292
|
+
draw() {
|
|
10293
|
+
const ctx = this.parent.context;
|
|
10294
|
+
if (this._useDrawByTexture()) {
|
|
10295
|
+
this._drawByTexture(ctx);
|
|
10296
|
+
} else {
|
|
10297
|
+
this._drawByVertices(ctx);
|
|
10298
|
+
}
|
|
10299
|
+
}
|
|
10260
10300
|
}
|
|
10261
|
-
__decorateClass$
|
|
10301
|
+
__decorateClass$f([
|
|
10262
10302
|
modernIdoc.property({ fallback: true })
|
|
10263
10303
|
], BaseElement2DText.prototype, "enabled");
|
|
10264
|
-
__decorateClass$
|
|
10304
|
+
__decorateClass$f([
|
|
10265
10305
|
modernIdoc.property({ fallback: () => [] })
|
|
10266
10306
|
], BaseElement2DText.prototype, "content");
|
|
10267
|
-
__decorateClass$
|
|
10307
|
+
__decorateClass$f([
|
|
10268
10308
|
modernIdoc.property({ alias: "parent.style.json" })
|
|
10269
10309
|
], BaseElement2DText.prototype, "style");
|
|
10270
|
-
__decorateClass$
|
|
10310
|
+
__decorateClass$f([
|
|
10271
10311
|
modernIdoc.property()
|
|
10272
10312
|
], BaseElement2DText.prototype, "effects");
|
|
10273
|
-
__decorateClass$
|
|
10313
|
+
__decorateClass$f([
|
|
10274
10314
|
modernIdoc.property()
|
|
10275
10315
|
], BaseElement2DText.prototype, "fill");
|
|
10276
|
-
__decorateClass$
|
|
10316
|
+
__decorateClass$f([
|
|
10277
10317
|
modernIdoc.property()
|
|
10278
10318
|
], BaseElement2DText.prototype, "outline");
|
|
10279
|
-
__decorateClass$
|
|
10319
|
+
__decorateClass$f([
|
|
10280
10320
|
modernIdoc.property({ alias: "base.measureDom" })
|
|
10281
10321
|
], BaseElement2DText.prototype, "measureDom");
|
|
10282
|
-
__decorateClass$
|
|
10322
|
+
__decorateClass$f([
|
|
10283
10323
|
modernIdoc.property({ alias: "base.fonts" })
|
|
10284
10324
|
], BaseElement2DText.prototype, "fonts");
|
|
10285
10325
|
|
|
10286
|
-
var __getOwnPropDesc$
|
|
10287
|
-
var __decorateClass$
|
|
10288
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10326
|
+
var __getOwnPropDesc$c = Object.getOwnPropertyDescriptor;
|
|
10327
|
+
var __decorateClass$e = (decorators, target, key, kind) => {
|
|
10328
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$c(target, key) : target;
|
|
10289
10329
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
10290
10330
|
if (decorator = decorators[i])
|
|
10291
10331
|
result = (decorator(result)) || result;
|
|
@@ -10395,13 +10435,13 @@ exports.BaseElement2D = class BaseElement2D extends exports.Node2D {
|
|
|
10395
10435
|
break;
|
|
10396
10436
|
case "scaleX":
|
|
10397
10437
|
this.scale.x = this.style.scaleX;
|
|
10398
|
-
if (this.text.
|
|
10438
|
+
if (this.text.isValid() && (value ^ oldValue) < 0) {
|
|
10399
10439
|
this.requestRedraw();
|
|
10400
10440
|
}
|
|
10401
10441
|
break;
|
|
10402
10442
|
case "scaleY":
|
|
10403
10443
|
this.scale.y = this.style.scaleY;
|
|
10404
|
-
if (this.text.
|
|
10444
|
+
if (this.text.isValid() && (value ^ oldValue) < 0) {
|
|
10405
10445
|
this.requestRedraw();
|
|
10406
10446
|
}
|
|
10407
10447
|
break;
|
|
@@ -10604,39 +10644,29 @@ exports.BaseElement2D = class BaseElement2D extends exports.Node2D {
|
|
|
10604
10644
|
}
|
|
10605
10645
|
_draw() {
|
|
10606
10646
|
super._draw();
|
|
10607
|
-
if (this.
|
|
10608
|
-
this._text.updateMeasure();
|
|
10609
|
-
}
|
|
10610
|
-
if (this._background.canDraw()) {
|
|
10647
|
+
if (this._background.isValid()) {
|
|
10611
10648
|
this._tree?.log(this.name, "background drawing");
|
|
10612
|
-
|
|
10613
|
-
this._shape.draw();
|
|
10614
|
-
} else {
|
|
10615
|
-
this._shape.drawRect();
|
|
10616
|
-
}
|
|
10649
|
+
this._shape.draw(!this._background.fillWithShape);
|
|
10617
10650
|
this._background.draw();
|
|
10618
10651
|
}
|
|
10619
|
-
if (this._fill.
|
|
10652
|
+
if (this._fill.isValid()) {
|
|
10620
10653
|
this._tree?.log(this.name, "fill drawing");
|
|
10621
10654
|
this._shape.draw();
|
|
10622
10655
|
this._fill.draw();
|
|
10623
10656
|
}
|
|
10624
|
-
if (this._outline.
|
|
10657
|
+
if (this._outline.isValid()) {
|
|
10625
10658
|
this._tree?.log(this.name, "outline drawing");
|
|
10626
10659
|
this._shape.draw();
|
|
10627
10660
|
this._outline.draw();
|
|
10628
10661
|
}
|
|
10629
|
-
if (this._foreground.
|
|
10662
|
+
if (this._foreground.isValid()) {
|
|
10630
10663
|
this._tree?.log(this.name, "foreground drawing");
|
|
10631
|
-
|
|
10632
|
-
this._shape.draw();
|
|
10633
|
-
} else {
|
|
10634
|
-
this._shape.drawRect();
|
|
10635
|
-
}
|
|
10664
|
+
this._shape.draw(!this._foreground.fillWithShape);
|
|
10636
10665
|
this._foreground.draw();
|
|
10637
10666
|
}
|
|
10638
|
-
if (this._text.
|
|
10667
|
+
if (this._text.isValid()) {
|
|
10639
10668
|
this._tree?.log(this.name, "text drawing");
|
|
10669
|
+
this._shape.draw(true);
|
|
10640
10670
|
this._text.draw();
|
|
10641
10671
|
}
|
|
10642
10672
|
this._drawContent();
|
|
@@ -10712,7 +10742,7 @@ exports.BaseElement2D = class BaseElement2D extends exports.Node2D {
|
|
|
10712
10742
|
});
|
|
10713
10743
|
}
|
|
10714
10744
|
};
|
|
10715
|
-
exports.BaseElement2D = __decorateClass$
|
|
10745
|
+
exports.BaseElement2D = __decorateClass$e([
|
|
10716
10746
|
customNode("BaseElement2D")
|
|
10717
10747
|
], exports.BaseElement2D);
|
|
10718
10748
|
|
|
@@ -10739,9 +10769,9 @@ class FlexElement2DStyle extends BaseElement2DStyle {
|
|
|
10739
10769
|
}
|
|
10740
10770
|
}
|
|
10741
10771
|
|
|
10742
|
-
var __getOwnPropDesc$
|
|
10743
|
-
var __decorateClass$
|
|
10744
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10772
|
+
var __getOwnPropDesc$b = Object.getOwnPropertyDescriptor;
|
|
10773
|
+
var __decorateClass$d = (decorators, target, key, kind) => {
|
|
10774
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$b(target, key) : target;
|
|
10745
10775
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
10746
10776
|
if (decorator = decorators[i])
|
|
10747
10777
|
result = (decorator(result)) || result;
|
|
@@ -10792,7 +10822,7 @@ exports.Element2D = class Element2D extends exports.BaseElement2D {
|
|
|
10792
10822
|
}
|
|
10793
10823
|
}
|
|
10794
10824
|
};
|
|
10795
|
-
exports.Element2D = __decorateClass$
|
|
10825
|
+
exports.Element2D = __decorateClass$d([
|
|
10796
10826
|
customNode("Element2D")
|
|
10797
10827
|
], exports.Element2D);
|
|
10798
10828
|
|
|
@@ -11102,9 +11132,9 @@ class FlexLayout {
|
|
|
11102
11132
|
}
|
|
11103
11133
|
}
|
|
11104
11134
|
|
|
11105
|
-
var __getOwnPropDesc$
|
|
11106
|
-
var __decorateClass$
|
|
11107
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11135
|
+
var __getOwnPropDesc$a = Object.getOwnPropertyDescriptor;
|
|
11136
|
+
var __decorateClass$c = (decorators, target, key, kind) => {
|
|
11137
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$a(target, key) : target;
|
|
11108
11138
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11109
11139
|
if (decorator = decorators[i])
|
|
11110
11140
|
result = (decorator(result)) || result;
|
|
@@ -11181,18 +11211,18 @@ exports.FlexElement2D = class FlexElement2D extends exports.BaseElement2D {
|
|
|
11181
11211
|
}
|
|
11182
11212
|
}
|
|
11183
11213
|
};
|
|
11184
|
-
exports.FlexElement2D = __decorateClass$
|
|
11214
|
+
exports.FlexElement2D = __decorateClass$c([
|
|
11185
11215
|
customNode("FlexElement2D")
|
|
11186
11216
|
], exports.FlexElement2D);
|
|
11187
11217
|
|
|
11188
|
-
var __defProp$
|
|
11189
|
-
var __getOwnPropDesc$
|
|
11190
|
-
var __decorateClass$
|
|
11191
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11218
|
+
var __defProp$b = Object.defineProperty;
|
|
11219
|
+
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
11220
|
+
var __decorateClass$b = (decorators, target, key, kind) => {
|
|
11221
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$9(target, key) : target;
|
|
11192
11222
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11193
11223
|
if (decorator = decorators[i])
|
|
11194
11224
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11195
|
-
if (kind && result) __defProp$
|
|
11225
|
+
if (kind && result) __defProp$b(target, key, result);
|
|
11196
11226
|
return result;
|
|
11197
11227
|
};
|
|
11198
11228
|
exports.Image2D = class Image2D extends exports.Element2D {
|
|
@@ -11304,7 +11334,7 @@ exports.Image2D = class Image2D extends exports.Element2D {
|
|
|
11304
11334
|
}
|
|
11305
11335
|
_drawContent() {
|
|
11306
11336
|
const texture = this.currentFrameTexture;
|
|
11307
|
-
if (texture?.
|
|
11337
|
+
if (texture?.isValid()) {
|
|
11308
11338
|
const { left = 0, top = 0, right = 0, bottom = 0 } = this.srcRect ?? {};
|
|
11309
11339
|
const { width, height } = this.size;
|
|
11310
11340
|
this.context.fillStyle = texture;
|
|
@@ -11328,19 +11358,19 @@ exports.Image2D = class Image2D extends exports.Element2D {
|
|
|
11328
11358
|
});
|
|
11329
11359
|
}
|
|
11330
11360
|
};
|
|
11331
|
-
__decorateClass$
|
|
11361
|
+
__decorateClass$b([
|
|
11332
11362
|
modernIdoc.property({ internal: true })
|
|
11333
11363
|
], exports.Image2D.prototype, "texture", 2);
|
|
11334
|
-
__decorateClass$
|
|
11364
|
+
__decorateClass$b([
|
|
11335
11365
|
modernIdoc.property({ fallback: "" })
|
|
11336
11366
|
], exports.Image2D.prototype, "src", 2);
|
|
11337
|
-
__decorateClass$
|
|
11367
|
+
__decorateClass$b([
|
|
11338
11368
|
modernIdoc.property()
|
|
11339
11369
|
], exports.Image2D.prototype, "srcRect", 2);
|
|
11340
|
-
__decorateClass$
|
|
11370
|
+
__decorateClass$b([
|
|
11341
11371
|
modernIdoc.property({ fallback: false })
|
|
11342
11372
|
], exports.Image2D.prototype, "gif", 2);
|
|
11343
|
-
exports.Image2D = __decorateClass$
|
|
11373
|
+
exports.Image2D = __decorateClass$b([
|
|
11344
11374
|
customNode("Image2D")
|
|
11345
11375
|
], exports.Image2D);
|
|
11346
11376
|
|
|
@@ -11351,27 +11381,22 @@ class TextureRect2D extends exports.Element2D {
|
|
|
11351
11381
|
this.setProperties(properties).append(children);
|
|
11352
11382
|
}
|
|
11353
11383
|
_drawContent() {
|
|
11354
|
-
if (this.texture?.
|
|
11355
|
-
|
|
11384
|
+
if (this.texture?.isValid()) {
|
|
11385
|
+
this.shape.draw(true);
|
|
11356
11386
|
this.context.fillStyle = this.texture;
|
|
11357
|
-
this.context.uvTransform = new Transform2D().scale(
|
|
11358
|
-
1 / width,
|
|
11359
|
-
1 / height
|
|
11360
|
-
);
|
|
11361
|
-
this.shape.drawRect();
|
|
11362
11387
|
this.context.fill();
|
|
11363
11388
|
}
|
|
11364
11389
|
}
|
|
11365
11390
|
}
|
|
11366
11391
|
|
|
11367
|
-
var __defProp$
|
|
11368
|
-
var __getOwnPropDesc$
|
|
11369
|
-
var __decorateClass$
|
|
11370
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11392
|
+
var __defProp$a = Object.defineProperty;
|
|
11393
|
+
var __getOwnPropDesc$8 = Object.getOwnPropertyDescriptor;
|
|
11394
|
+
var __decorateClass$a = (decorators, target, key, kind) => {
|
|
11395
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$8(target, key) : target;
|
|
11371
11396
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11372
11397
|
if (decorator = decorators[i])
|
|
11373
11398
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11374
|
-
if (kind && result) __defProp$
|
|
11399
|
+
if (kind && result) __defProp$a(target, key, result);
|
|
11375
11400
|
return result;
|
|
11376
11401
|
};
|
|
11377
11402
|
exports.Lottie2D = class Lottie2D extends TextureRect2D {
|
|
@@ -11414,20 +11439,20 @@ exports.Lottie2D = class Lottie2D extends TextureRect2D {
|
|
|
11414
11439
|
super._process(delta);
|
|
11415
11440
|
}
|
|
11416
11441
|
};
|
|
11417
|
-
__decorateClass$
|
|
11442
|
+
__decorateClass$a([
|
|
11418
11443
|
modernIdoc.property({ fallback: "" })
|
|
11419
11444
|
], exports.Lottie2D.prototype, "src", 2);
|
|
11420
|
-
exports.Lottie2D = __decorateClass$
|
|
11445
|
+
exports.Lottie2D = __decorateClass$a([
|
|
11421
11446
|
customNode("Lottie2D")
|
|
11422
11447
|
], exports.Lottie2D);
|
|
11423
11448
|
|
|
11424
|
-
var __defProp$
|
|
11425
|
-
var __decorateClass$
|
|
11449
|
+
var __defProp$9 = Object.defineProperty;
|
|
11450
|
+
var __decorateClass$9 = (decorators, target, key, kind) => {
|
|
11426
11451
|
var result = void 0 ;
|
|
11427
11452
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11428
11453
|
if (decorator = decorators[i])
|
|
11429
11454
|
result = (decorator(target, key, result) ) || result;
|
|
11430
|
-
if (result) __defProp$
|
|
11455
|
+
if (result) __defProp$9(target, key, result);
|
|
11431
11456
|
return result;
|
|
11432
11457
|
};
|
|
11433
11458
|
class TransformRect2D extends exports.Element2D {
|
|
@@ -11473,18 +11498,18 @@ class TransformRect2D extends exports.Element2D {
|
|
|
11473
11498
|
this._drawEllipse(width, height / 2);
|
|
11474
11499
|
}
|
|
11475
11500
|
}
|
|
11476
|
-
__decorateClass$
|
|
11501
|
+
__decorateClass$9([
|
|
11477
11502
|
modernIdoc.property({ fallback: 6 })
|
|
11478
11503
|
], TransformRect2D.prototype, "handleSize");
|
|
11479
11504
|
|
|
11480
|
-
var __defProp$
|
|
11481
|
-
var __getOwnPropDesc$
|
|
11482
|
-
var __decorateClass$
|
|
11483
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11505
|
+
var __defProp$8 = Object.defineProperty;
|
|
11506
|
+
var __getOwnPropDesc$7 = Object.getOwnPropertyDescriptor;
|
|
11507
|
+
var __decorateClass$8 = (decorators, target, key, kind) => {
|
|
11508
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$7(target, key) : target;
|
|
11484
11509
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11485
11510
|
if (decorator = decorators[i])
|
|
11486
11511
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11487
|
-
if (kind && result) __defProp$
|
|
11512
|
+
if (kind && result) __defProp$8(target, key, result);
|
|
11488
11513
|
return result;
|
|
11489
11514
|
};
|
|
11490
11515
|
exports.Video2D = class Video2D extends TextureRect2D {
|
|
@@ -11537,21 +11562,21 @@ exports.Video2D = class Video2D extends TextureRect2D {
|
|
|
11537
11562
|
super._process(delta);
|
|
11538
11563
|
}
|
|
11539
11564
|
};
|
|
11540
|
-
__decorateClass$
|
|
11565
|
+
__decorateClass$8([
|
|
11541
11566
|
modernIdoc.property({ fallback: "" })
|
|
11542
11567
|
], exports.Video2D.prototype, "src", 2);
|
|
11543
|
-
exports.Video2D = __decorateClass$
|
|
11568
|
+
exports.Video2D = __decorateClass$8([
|
|
11544
11569
|
customNode("Video2D")
|
|
11545
11570
|
], exports.Video2D);
|
|
11546
11571
|
|
|
11547
|
-
var __defProp$
|
|
11548
|
-
var __getOwnPropDesc$
|
|
11549
|
-
var __decorateClass$
|
|
11550
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11572
|
+
var __defProp$7 = Object.defineProperty;
|
|
11573
|
+
var __getOwnPropDesc$6 = Object.getOwnPropertyDescriptor;
|
|
11574
|
+
var __decorateClass$7 = (decorators, target, key, kind) => {
|
|
11575
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$6(target, key) : target;
|
|
11551
11576
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
11552
11577
|
if (decorator = decorators[i])
|
|
11553
11578
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11554
|
-
if (kind && result) __defProp$
|
|
11579
|
+
if (kind && result) __defProp$7(target, key, result);
|
|
11555
11580
|
return result;
|
|
11556
11581
|
};
|
|
11557
11582
|
const linear = (amount) => amount;
|
|
@@ -11870,19 +11895,16 @@ exports.Animation = class Animation extends exports.TimelineNode {
|
|
|
11870
11895
|
});
|
|
11871
11896
|
}
|
|
11872
11897
|
};
|
|
11873
|
-
__decorateClass$
|
|
11898
|
+
__decorateClass$7([
|
|
11874
11899
|
modernIdoc.property({ fallback: "parent" })
|
|
11875
11900
|
], exports.Animation.prototype, "effectMode", 2);
|
|
11876
|
-
__decorateClass$
|
|
11877
|
-
modernIdoc.property({ fallback: false })
|
|
11878
|
-
], exports.Animation.prototype, "loop", 2);
|
|
11879
|
-
__decorateClass$8([
|
|
11901
|
+
__decorateClass$7([
|
|
11880
11902
|
modernIdoc.property({ default: () => [] })
|
|
11881
11903
|
], exports.Animation.prototype, "keyframes", 2);
|
|
11882
|
-
__decorateClass$
|
|
11904
|
+
__decorateClass$7([
|
|
11883
11905
|
modernIdoc.property()
|
|
11884
11906
|
], exports.Animation.prototype, "easing", 2);
|
|
11885
|
-
exports.Animation = __decorateClass$
|
|
11907
|
+
exports.Animation = __decorateClass$7([
|
|
11886
11908
|
customNode("Animation", {
|
|
11887
11909
|
renderMode: "disabled",
|
|
11888
11910
|
processMode: "pausable",
|
|
@@ -12763,11 +12785,11 @@ class WebAudio extends AudioPipeline {
|
|
|
12763
12785
|
}
|
|
12764
12786
|
}
|
|
12765
12787
|
|
|
12766
|
-
var __defProp$
|
|
12767
|
-
var __getOwnPropDesc$
|
|
12768
|
-
var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$
|
|
12769
|
-
var __decorateClass$
|
|
12770
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
12788
|
+
var __defProp$6 = Object.defineProperty;
|
|
12789
|
+
var __getOwnPropDesc$5 = Object.getOwnPropertyDescriptor;
|
|
12790
|
+
var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
12791
|
+
var __decorateClass$6 = (decorators, target, key, kind) => {
|
|
12792
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$5(target, key) : target;
|
|
12771
12793
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
12772
12794
|
if (decorator = decorators[i])
|
|
12773
12795
|
result = (decorator(result)) || result;
|
|
@@ -12978,7 +13000,7 @@ exports.Audio = class Audio extends exports.TimelineNode {
|
|
|
12978
13000
|
}
|
|
12979
13001
|
};
|
|
12980
13002
|
__publicField$4(exports.Audio, "_soundPool", []);
|
|
12981
|
-
exports.Audio = __decorateClass$
|
|
13003
|
+
exports.Audio = __decorateClass$6([
|
|
12982
13004
|
customNode("Audio")
|
|
12983
13005
|
], exports.Audio);
|
|
12984
13006
|
|
|
@@ -12986,14 +13008,14 @@ class AudioSpectrum extends exports.Node2D {
|
|
|
12986
13008
|
//
|
|
12987
13009
|
}
|
|
12988
13010
|
|
|
12989
|
-
var __defProp$
|
|
12990
|
-
var __getOwnPropDesc$
|
|
12991
|
-
var __decorateClass$
|
|
12992
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
13011
|
+
var __defProp$5 = Object.defineProperty;
|
|
13012
|
+
var __getOwnPropDesc$4 = Object.getOwnPropertyDescriptor;
|
|
13013
|
+
var __decorateClass$5 = (decorators, target, key, kind) => {
|
|
13014
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$4(target, key) : target;
|
|
12993
13015
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
12994
13016
|
if (decorator = decorators[i])
|
|
12995
13017
|
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
12996
|
-
if (kind && result) __defProp$
|
|
13018
|
+
if (kind && result) __defProp$5(target, key, result);
|
|
12997
13019
|
return result;
|
|
12998
13020
|
};
|
|
12999
13021
|
exports.AudioWaveform = class AudioWaveform extends exports.Element2D {
|
|
@@ -13075,7 +13097,7 @@ exports.AudioWaveform = class AudioWaveform extends exports.Element2D {
|
|
|
13075
13097
|
}
|
|
13076
13098
|
_drawSrc() {
|
|
13077
13099
|
const src = this._src;
|
|
13078
|
-
if (src?.
|
|
13100
|
+
if (src?.isValid()) {
|
|
13079
13101
|
this.context.fillStyle = src;
|
|
13080
13102
|
this.context.uvTransform = new Transform2D().scale(
|
|
13081
13103
|
1 / this.style.width,
|
|
@@ -13084,109 +13106,19 @@ exports.AudioWaveform = class AudioWaveform extends exports.Element2D {
|
|
|
13084
13106
|
}
|
|
13085
13107
|
}
|
|
13086
13108
|
};
|
|
13087
|
-
__decorateClass$
|
|
13109
|
+
__decorateClass$5([
|
|
13088
13110
|
modernIdoc.property()
|
|
13089
13111
|
], exports.AudioWaveform.prototype, "src", 2);
|
|
13090
|
-
__decorateClass$
|
|
13112
|
+
__decorateClass$5([
|
|
13091
13113
|
modernIdoc.property({ fallback: 0 })
|
|
13092
13114
|
], exports.AudioWaveform.prototype, "gap", 2);
|
|
13093
|
-
__decorateClass$
|
|
13115
|
+
__decorateClass$5([
|
|
13094
13116
|
modernIdoc.property({ fallback: "#000000" })
|
|
13095
13117
|
], exports.AudioWaveform.prototype, "color", 2);
|
|
13096
|
-
exports.AudioWaveform = __decorateClass$
|
|
13118
|
+
exports.AudioWaveform = __decorateClass$5([
|
|
13097
13119
|
customNode("AudioWaveform")
|
|
13098
13120
|
], exports.AudioWaveform);
|
|
13099
13121
|
|
|
13100
|
-
var __defProp$5 = Object.defineProperty;
|
|
13101
|
-
var __getOwnPropDesc$4 = Object.getOwnPropertyDescriptor;
|
|
13102
|
-
var __decorateClass$5 = (decorators, target, key, kind) => {
|
|
13103
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$4(target, key) : target;
|
|
13104
|
-
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
13105
|
-
if (decorator = decorators[i])
|
|
13106
|
-
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13107
|
-
if (kind && result) __defProp$5(target, key, result);
|
|
13108
|
-
return result;
|
|
13109
|
-
};
|
|
13110
|
-
exports.Scaler = class Scaler extends exports.Node {
|
|
13111
|
-
get target() {
|
|
13112
|
-
if (this.parent?.style) {
|
|
13113
|
-
return this.parent;
|
|
13114
|
-
}
|
|
13115
|
-
return void 0;
|
|
13116
|
-
}
|
|
13117
|
-
constructor(properties, children = []) {
|
|
13118
|
-
super();
|
|
13119
|
-
this.setProperties(properties);
|
|
13120
|
-
this.append(children);
|
|
13121
|
-
}
|
|
13122
|
-
_updateProperty(key, value, oldValue) {
|
|
13123
|
-
super._updateProperty(key, value, oldValue);
|
|
13124
|
-
switch (key) {
|
|
13125
|
-
case "translateY":
|
|
13126
|
-
case "translateX":
|
|
13127
|
-
case "scale":
|
|
13128
|
-
case "min":
|
|
13129
|
-
case "max": {
|
|
13130
|
-
this.scale = clamp(this.scale, this.minScale, this.maxScale);
|
|
13131
|
-
this._updateTarget();
|
|
13132
|
-
break;
|
|
13133
|
-
}
|
|
13134
|
-
}
|
|
13135
|
-
}
|
|
13136
|
-
_updateTarget() {
|
|
13137
|
-
const target = this.target;
|
|
13138
|
-
if (target) {
|
|
13139
|
-
target.style.transform = `translate(${this.translateX}px, ${this.translateY}px) scale(${this.scale})`;
|
|
13140
|
-
this.emit("updateScale", this.scale);
|
|
13141
|
-
}
|
|
13142
|
-
}
|
|
13143
|
-
_onWheel(e) {
|
|
13144
|
-
const target = this.target;
|
|
13145
|
-
if (!target)
|
|
13146
|
-
return;
|
|
13147
|
-
e.preventDefault();
|
|
13148
|
-
if (e.ctrlKey) {
|
|
13149
|
-
const isTouchPad = e.wheelDeltaY ? Math.abs(Math.abs(e.wheelDeltaY) - Math.abs(3 * e.deltaY)) < 3 : e.deltaMode === 0;
|
|
13150
|
-
if (!isTouchPad) {
|
|
13151
|
-
e.preventDefault();
|
|
13152
|
-
this.scale += e.deltaY * -0.015;
|
|
13153
|
-
}
|
|
13154
|
-
} else {
|
|
13155
|
-
this.translateX -= e.deltaX;
|
|
13156
|
-
this.translateY -= e.deltaY;
|
|
13157
|
-
}
|
|
13158
|
-
}
|
|
13159
|
-
_input(event, key) {
|
|
13160
|
-
super._input(event, key);
|
|
13161
|
-
switch (key) {
|
|
13162
|
-
case "wheel":
|
|
13163
|
-
this._onWheel(event);
|
|
13164
|
-
break;
|
|
13165
|
-
}
|
|
13166
|
-
}
|
|
13167
|
-
};
|
|
13168
|
-
__decorateClass$5([
|
|
13169
|
-
modernIdoc.property({ default: 1 })
|
|
13170
|
-
], exports.Scaler.prototype, "translateX", 2);
|
|
13171
|
-
__decorateClass$5([
|
|
13172
|
-
modernIdoc.property({ default: 1 })
|
|
13173
|
-
], exports.Scaler.prototype, "translateY", 2);
|
|
13174
|
-
__decorateClass$5([
|
|
13175
|
-
modernIdoc.property({ default: 1 })
|
|
13176
|
-
], exports.Scaler.prototype, "scale", 2);
|
|
13177
|
-
__decorateClass$5([
|
|
13178
|
-
modernIdoc.property({ default: 0.05 })
|
|
13179
|
-
], exports.Scaler.prototype, "minScale", 2);
|
|
13180
|
-
__decorateClass$5([
|
|
13181
|
-
modernIdoc.property({ default: 10 })
|
|
13182
|
-
], exports.Scaler.prototype, "maxScale", 2);
|
|
13183
|
-
exports.Scaler = __decorateClass$5([
|
|
13184
|
-
customNode("Scaler", {
|
|
13185
|
-
processMode: "disabled",
|
|
13186
|
-
renderMode: "disabled"
|
|
13187
|
-
})
|
|
13188
|
-
], exports.Scaler);
|
|
13189
|
-
|
|
13190
13122
|
var __defProp$4 = Object.defineProperty;
|
|
13191
13123
|
var __getOwnPropDesc$3 = Object.getOwnPropertyDescriptor;
|
|
13192
13124
|
var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|