@visactor/vrender 0.22.0-vstory.1 → 0.22.0-vstory.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/dist/index.es.js +768 -1200
- package/dist/index.js +769 -1204
- package/dist/index.min.js +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -577,17 +577,17 @@
|
|
|
577
577
|
const VGlobal = Symbol.for("VGlobal");
|
|
578
578
|
const DEFAULT_TEXT_FONT_FAMILY = "PingFang SC,Helvetica Neue,Microsoft Yahei,system-ui,-apple-system,segoe ui,Roboto,Helvetica,Arial,sans-serif,apple color emoji,segoe ui emoji,segoe ui symbol";
|
|
579
579
|
|
|
580
|
-
var __decorate$
|
|
580
|
+
var __decorate$1J = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
581
581
|
var d,
|
|
582
582
|
c = arguments.length,
|
|
583
583
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
584
584
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
585
585
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
586
586
|
},
|
|
587
|
-
__metadata$
|
|
587
|
+
__metadata$1i = undefined && undefined.__metadata || function (k, v) {
|
|
588
588
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
589
589
|
},
|
|
590
|
-
__param$
|
|
590
|
+
__param$U = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
591
591
|
return function (target, key) {
|
|
592
592
|
decorator(target, key, paramIndex);
|
|
593
593
|
};
|
|
@@ -621,12 +621,6 @@
|
|
|
621
621
|
get env() {
|
|
622
622
|
return this._env;
|
|
623
623
|
}
|
|
624
|
-
get isImageAnonymous() {
|
|
625
|
-
return this._isImageAnonymous;
|
|
626
|
-
}
|
|
627
|
-
set isImageAnonymous(isImageAnonymous) {
|
|
628
|
-
this._isImageAnonymous = isImageAnonymous;
|
|
629
|
-
}
|
|
630
624
|
get devicePixelRatio() {
|
|
631
625
|
return this._env || this.setEnv("browser"), this.envContribution.getDevicePixelRatio();
|
|
632
626
|
}
|
|
@@ -661,7 +655,7 @@
|
|
|
661
655
|
this._env || this.setEnv("browser"), this.envContribution.applyStyles = support;
|
|
662
656
|
}
|
|
663
657
|
constructor(contributions) {
|
|
664
|
-
this.contributions = contributions, this.
|
|
658
|
+
this.contributions = contributions, this.id = Generator.GenAutoIncrementId(), this.hooks = {
|
|
665
659
|
onSetEnv: new SyncHook(["lastEnv", "env", "global"])
|
|
666
660
|
}, this.measureTextMethod = "native", this.optimizeVisible = !1;
|
|
667
661
|
}
|
|
@@ -789,7 +783,7 @@
|
|
|
789
783
|
return this._env || this.setEnv("browser"), this.envContribution.copyToClipBoard(text);
|
|
790
784
|
}
|
|
791
785
|
};
|
|
792
|
-
exports.DefaultGlobal = __decorate$
|
|
786
|
+
exports.DefaultGlobal = __decorate$1J([injectable(), __param$U(0, inject(ContributionProvider)), __param$U(0, named(EnvContribution)), __metadata$1i("design:paramtypes", [Object])], exports.DefaultGlobal);
|
|
793
787
|
|
|
794
788
|
exports.MeasureModeEnum = void 0;
|
|
795
789
|
!function (MeasureModeEnum) {
|
|
@@ -4305,6 +4299,7 @@
|
|
|
4305
4299
|
});
|
|
4306
4300
|
const DefaultRichTextAttribute = Object.assign(Object.assign(Object.assign({}, DefaultAttribute), DefaultTextStyle), {
|
|
4307
4301
|
editable: !1,
|
|
4302
|
+
editOptions: null,
|
|
4308
4303
|
width: 300,
|
|
4309
4304
|
height: 300,
|
|
4310
4305
|
ellipsis: !0,
|
|
@@ -4352,7 +4347,7 @@
|
|
|
4352
4347
|
class Application {}
|
|
4353
4348
|
const application = new Application();
|
|
4354
4349
|
|
|
4355
|
-
const parse
|
|
4350
|
+
const parse = function () {
|
|
4356
4351
|
const tokens = {
|
|
4357
4352
|
linearGradient: /^(linear\-gradient)/i,
|
|
4358
4353
|
radialGradient: /^(radial\-gradient)/i,
|
|
@@ -4505,7 +4500,7 @@
|
|
|
4505
4500
|
}
|
|
4506
4501
|
static Parse(c) {
|
|
4507
4502
|
if (GradientParser.IsGradientStr(c)) try {
|
|
4508
|
-
const datum = parse
|
|
4503
|
+
const datum = parse(c)[0];
|
|
4509
4504
|
if (datum) {
|
|
4510
4505
|
if ("linear" === datum.type) return GradientParser.ParseLinear(datum);
|
|
4511
4506
|
if ("radial" === datum.type) return GradientParser.ParseRadial(datum);
|
|
@@ -4762,7 +4757,7 @@
|
|
|
4762
4757
|
return "number" != typeof measurement.actualBoundingBoxAscent || "number" != typeof measurement.actualBoundingBoxDescent ? (result.width = Math.floor(measurement.width), result.height = character.fontSize || 0, result.ascent = result.height, result.descent = 0) : (result.width = Math.floor(measurement.width), result.height = Math.floor(measurement.actualBoundingBoxAscent + measurement.actualBoundingBoxDescent), result.ascent = Math.floor(measurement.actualBoundingBoxAscent), result.descent = result.height - result.ascent), result;
|
|
4763
4758
|
}
|
|
4764
4759
|
|
|
4765
|
-
var __decorate$
|
|
4760
|
+
var __decorate$1I = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
4766
4761
|
var d,
|
|
4767
4762
|
c = arguments.length,
|
|
4768
4763
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -5144,9 +5139,9 @@
|
|
|
5144
5139
|
return data.str = data.result, data.width += suffixWidth, data;
|
|
5145
5140
|
}
|
|
5146
5141
|
};
|
|
5147
|
-
ATextMeasure = __decorate$
|
|
5142
|
+
ATextMeasure = __decorate$1I([injectable()], ATextMeasure);
|
|
5148
5143
|
|
|
5149
|
-
var __decorate$
|
|
5144
|
+
var __decorate$1H = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
5150
5145
|
var d,
|
|
5151
5146
|
c = arguments.length,
|
|
5152
5147
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -5155,7 +5150,7 @@
|
|
|
5155
5150
|
};
|
|
5156
5151
|
const TextMeasureContribution = Symbol.for("TextMeasureContribution");
|
|
5157
5152
|
exports.DefaultTextMeasureContribution = class DefaultTextMeasureContribution extends ATextMeasure {};
|
|
5158
|
-
exports.DefaultTextMeasureContribution = __decorate$
|
|
5153
|
+
exports.DefaultTextMeasureContribution = __decorate$1H([injectable()], exports.DefaultTextMeasureContribution);
|
|
5159
5154
|
|
|
5160
5155
|
const container = new Container();
|
|
5161
5156
|
|
|
@@ -5569,14 +5564,14 @@
|
|
|
5569
5564
|
}
|
|
5570
5565
|
const canvasAllocate = new DefaultCanvasAllocate();
|
|
5571
5566
|
|
|
5572
|
-
var __decorate$
|
|
5567
|
+
var __decorate$1G = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
5573
5568
|
var d,
|
|
5574
5569
|
c = arguments.length,
|
|
5575
5570
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
5576
5571
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
5577
5572
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
5578
5573
|
},
|
|
5579
|
-
__metadata$
|
|
5574
|
+
__metadata$1h = undefined && undefined.__metadata || function (k, v) {
|
|
5580
5575
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
5581
5576
|
};
|
|
5582
5577
|
const VWindow = Symbol.for("VWindow");
|
|
@@ -5713,19 +5708,19 @@
|
|
|
5713
5708
|
return this._handler.getTopLeft(baseWindow);
|
|
5714
5709
|
}
|
|
5715
5710
|
};
|
|
5716
|
-
exports.DefaultWindow = __decorate$
|
|
5711
|
+
exports.DefaultWindow = __decorate$1G([injectable(), __metadata$1h("design:paramtypes", [])], exports.DefaultWindow);
|
|
5717
5712
|
|
|
5718
|
-
var __decorate$
|
|
5713
|
+
var __decorate$1F = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
5719
5714
|
var d,
|
|
5720
5715
|
c = arguments.length,
|
|
5721
5716
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
5722
5717
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
5723
5718
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
5724
5719
|
},
|
|
5725
|
-
__metadata$
|
|
5720
|
+
__metadata$1g = undefined && undefined.__metadata || function (k, v) {
|
|
5726
5721
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
5727
5722
|
},
|
|
5728
|
-
__param$
|
|
5723
|
+
__param$T = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
5729
5724
|
return function (target, key) {
|
|
5730
5725
|
decorator(target, key, paramIndex);
|
|
5731
5726
|
};
|
|
@@ -5820,7 +5815,7 @@
|
|
|
5820
5815
|
return c.nativeCanvas ? c.nativeCanvas : null;
|
|
5821
5816
|
}
|
|
5822
5817
|
};
|
|
5823
|
-
exports.DefaultGraphicUtil = __decorate$
|
|
5818
|
+
exports.DefaultGraphicUtil = __decorate$1F([injectable(), __param$T(0, inject(ContributionProvider)), __param$T(0, named(TextMeasureContribution)), __metadata$1g("design:paramtypes", [Object])], exports.DefaultGraphicUtil);
|
|
5824
5819
|
var TransformMode;
|
|
5825
5820
|
!function (TransformMode) {
|
|
5826
5821
|
TransformMode[TransformMode.transform = 0] = "transform", TransformMode[TransformMode.matrix = 1] = "matrix";
|
|
@@ -5878,7 +5873,7 @@
|
|
|
5878
5873
|
return this;
|
|
5879
5874
|
}
|
|
5880
5875
|
};
|
|
5881
|
-
exports.DefaultTransformUtil = __decorate$
|
|
5876
|
+
exports.DefaultTransformUtil = __decorate$1F([injectable(), __metadata$1g("design:paramtypes", [])], exports.DefaultTransformUtil);
|
|
5882
5877
|
|
|
5883
5878
|
const defaultThemeObj = {
|
|
5884
5879
|
arc: DefaultArcAttribute,
|
|
@@ -9727,7 +9722,7 @@
|
|
|
9727
9722
|
}
|
|
9728
9723
|
static GetFile(url, type) {
|
|
9729
9724
|
let data = ResourceLoader.cache.get(url);
|
|
9730
|
-
return data ? "fail" === data.loadState ? Promise.reject() : "
|
|
9725
|
+
return data ? "init" === data.loadState || "fail" === data.loadState ? Promise.reject() : "loading" === data.loadState ? data.dataPromise.then(data => data.data) : Promise.resolve(data.data) : (data = {
|
|
9731
9726
|
type: type,
|
|
9732
9727
|
loadState: "init"
|
|
9733
9728
|
}, ResourceLoader.cache.set(url, data), "arrayBuffer" === type ? data.dataPromise = application.global.loadArrayBuffer(url) : "blob" === type ? data.dataPromise = application.global.loadBlob(url) : "json" === type && (data.dataPromise = application.global.loadJson(url)), data.dataPromise.then(data => data.data));
|
|
@@ -9837,7 +9832,7 @@
|
|
|
9837
9832
|
}
|
|
9838
9833
|
}
|
|
9839
9834
|
get AABBBounds() {
|
|
9840
|
-
return this.tryUpdateAABBBounds(
|
|
9835
|
+
return this.tryUpdateAABBBounds();
|
|
9841
9836
|
}
|
|
9842
9837
|
get OBBBounds() {
|
|
9843
9838
|
return this.tryUpdateOBBBounds();
|
|
@@ -9881,12 +9876,13 @@
|
|
|
9881
9876
|
onAnimateBind(animate) {
|
|
9882
9877
|
this._emitCustomEvent("animate-bind", animate);
|
|
9883
9878
|
}
|
|
9884
|
-
tryUpdateAABBBounds(
|
|
9879
|
+
tryUpdateAABBBounds() {
|
|
9880
|
+
const full = "imprecise" === this.attribute.boundsMode;
|
|
9885
9881
|
if (!this.shouldUpdateAABBBounds()) return this._AABBBounds;
|
|
9886
9882
|
if (!this.valid) return this._AABBBounds.clear(), this._AABBBounds;
|
|
9887
9883
|
application.graphicService.beforeUpdateAABBBounds(this, this.stage, !0, this._AABBBounds);
|
|
9888
9884
|
const bounds = this.doUpdateAABBBounds(full);
|
|
9889
|
-
return application.graphicService.afterUpdateAABBBounds(this, this.stage, this._AABBBounds, this, !0), bounds;
|
|
9885
|
+
return application.graphicService.afterUpdateAABBBounds(this, this.stage, this._AABBBounds, this, !0), "empty" === this.attribute.boundsMode && bounds.clear(), bounds;
|
|
9890
9886
|
}
|
|
9891
9887
|
tryUpdateOBBBounds() {
|
|
9892
9888
|
if (this._OBBBounds || (this._OBBBounds = new OBBBounds()), this.tryUpdateAABBBounds(), this.updateOBBBoundsStamp === this.updateAABBBoundsStamp) return this._OBBBounds;
|
|
@@ -10130,7 +10126,7 @@
|
|
|
10130
10126
|
context && context.skipUpdateCallback || (application.graphicService.onAttributeUpdate(this), this._emitCustomEvent("afterAttributeUpdate", context));
|
|
10131
10127
|
}
|
|
10132
10128
|
update(d) {
|
|
10133
|
-
d ? (d.bounds && this.tryUpdateAABBBounds(
|
|
10129
|
+
d ? (d.bounds && this.tryUpdateAABBBounds(), d.trans && this.tryUpdateLocalTransMatrix()) : (this.tryUpdateAABBBounds(), this.tryUpdateLocalTransMatrix());
|
|
10134
10130
|
}
|
|
10135
10131
|
hasState(stateName) {
|
|
10136
10132
|
return !(!this.currentStates || !this.currentStates.length) && (!!isNil$1(stateName) || this.currentStates.includes(stateName));
|
|
@@ -11180,14 +11176,14 @@
|
|
|
11180
11176
|
const VirtualLayerHandlerContribution = Symbol.for("VirtualLayerHandlerContribution");
|
|
11181
11177
|
|
|
11182
11178
|
var DefaultLayerService_1,
|
|
11183
|
-
__decorate$
|
|
11179
|
+
__decorate$1E = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
11184
11180
|
var d,
|
|
11185
11181
|
c = arguments.length,
|
|
11186
11182
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
11187
11183
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
11188
11184
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
11189
11185
|
},
|
|
11190
|
-
__metadata$
|
|
11186
|
+
__metadata$1f = undefined && undefined.__metadata || function (k, v) {
|
|
11191
11187
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
11192
11188
|
};
|
|
11193
11189
|
exports.DefaultLayerService = DefaultLayerService_1 = class {
|
|
@@ -11251,7 +11247,7 @@
|
|
|
11251
11247
|
this.layerMap.delete(stage);
|
|
11252
11248
|
}
|
|
11253
11249
|
};
|
|
11254
|
-
exports.DefaultLayerService.idprefix = "visactor_layer", exports.DefaultLayerService.prefix_count = 0, exports.DefaultLayerService = DefaultLayerService_1 = __decorate$
|
|
11250
|
+
exports.DefaultLayerService.idprefix = "visactor_layer", exports.DefaultLayerService.prefix_count = 0, exports.DefaultLayerService = DefaultLayerService_1 = __decorate$1E([injectable(), __metadata$1f("design:paramtypes", [])], exports.DefaultLayerService);
|
|
11255
11251
|
|
|
11256
11252
|
var coreModule = new ContainerModule(bind => {
|
|
11257
11253
|
bind(VGlobal).to(exports.DefaultGlobal).inSingletonScope(), bind(VWindow).to(exports.DefaultWindow), bind(GraphicUtil).to(exports.DefaultGraphicUtil).inSingletonScope(), bind(TransformUtil).to(exports.DefaultTransformUtil).inSingletonScope(), bind(LayerService).to(exports.DefaultLayerService).inSingletonScope();
|
|
@@ -11790,17 +11786,17 @@
|
|
|
11790
11786
|
const matrixAllocate = new DefaultMatrixAllocate();
|
|
11791
11787
|
const mat4Allocate = new DefaultMat4Allocate();
|
|
11792
11788
|
|
|
11793
|
-
var __decorate$
|
|
11789
|
+
var __decorate$1D = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
11794
11790
|
var d,
|
|
11795
11791
|
c = arguments.length,
|
|
11796
11792
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
11797
11793
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
11798
11794
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
11799
11795
|
},
|
|
11800
|
-
__metadata$
|
|
11796
|
+
__metadata$1e = undefined && undefined.__metadata || function (k, v) {
|
|
11801
11797
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
11802
11798
|
},
|
|
11803
|
-
__param$
|
|
11799
|
+
__param$S = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
11804
11800
|
return function (target, key) {
|
|
11805
11801
|
decorator(target, key, paramIndex);
|
|
11806
11802
|
};
|
|
@@ -12012,7 +12008,7 @@
|
|
|
12012
12008
|
};
|
|
12013
12009
|
}
|
|
12014
12010
|
};
|
|
12015
|
-
exports.DefaultGraphicService = __decorate$
|
|
12011
|
+
exports.DefaultGraphicService = __decorate$1D([injectable(), __param$S(0, inject(GraphicCreator$1)), __metadata$1e("design:paramtypes", [Object])], exports.DefaultGraphicService);
|
|
12016
12012
|
|
|
12017
12013
|
const updateBoundsOfCommonOuterBorder = (attribute, theme, aabbBounds) => {
|
|
12018
12014
|
const {
|
|
@@ -13891,6 +13887,18 @@
|
|
|
13891
13887
|
}
|
|
13892
13888
|
}
|
|
13893
13889
|
|
|
13890
|
+
function getFixedLRTB(left, right, top, bottom) {
|
|
13891
|
+
const leftInt = Math.round(left),
|
|
13892
|
+
topInt = Math.round(top),
|
|
13893
|
+
rightInt = Math.round(right),
|
|
13894
|
+
bottomInt = Math.round(bottom);
|
|
13895
|
+
return {
|
|
13896
|
+
left: left > leftInt ? leftInt : leftInt - .5,
|
|
13897
|
+
top: top > topInt ? topInt : topInt - .5,
|
|
13898
|
+
right: rightInt > right ? rightInt : rightInt + .5,
|
|
13899
|
+
bottom: bottomInt > bottom ? bottomInt : bottomInt + .5
|
|
13900
|
+
};
|
|
13901
|
+
}
|
|
13894
13902
|
class Paragraph {
|
|
13895
13903
|
constructor(text, newLine, character) {
|
|
13896
13904
|
this.fontSize = character.fontSize || 16, this.textBaseline = character.textBaseline || "alphabetic";
|
|
@@ -13913,7 +13921,8 @@
|
|
|
13913
13921
|
} = measureTextCanvas(this.text, this.character);
|
|
13914
13922
|
this.width = width, "vertical" === this.direction && (this.widthOrigin = this.width, this.width = this.heightOrigin, this.height = this.widthOrigin);
|
|
13915
13923
|
}
|
|
13916
|
-
|
|
13924
|
+
drawBackground(ctx, top, ascent, deltaLeft, isLineFirst, textAlign, lineHeight) {
|
|
13925
|
+
if (!this.character.background || this.character.backgroundOpacity && !(this.character.backgroundOpacity > 0)) return;
|
|
13917
13926
|
let baseline = top + ascent,
|
|
13918
13927
|
text = this.text,
|
|
13919
13928
|
left = this.left + deltaLeft;
|
|
@@ -13938,15 +13947,63 @@
|
|
|
13938
13947
|
case "sub":
|
|
13939
13948
|
baseline += this.descent / 2;
|
|
13940
13949
|
}
|
|
13941
|
-
|
|
13942
|
-
|
|
13943
|
-
|
|
13944
|
-
|
|
13950
|
+
"vertical" === direction && (ctx.save(), ctx.rotateAbout(Math.PI / 2, left, baseline), ctx.translate(-this.heightOrigin || -this.lineHeight / 2, -this.descent / 2), ctx.translate(left, baseline), left = 0, baseline = 0);
|
|
13951
|
+
const fillStyle = ctx.fillStyle,
|
|
13952
|
+
globalAlpha = ctx.globalAlpha;
|
|
13953
|
+
ctx.fillStyle = this.character.background, void 0 !== this.character.backgroundOpacity && (ctx.globalAlpha = this.character.backgroundOpacity);
|
|
13954
|
+
const lrtb = getFixedLRTB(left, left + (this.widthOrigin || this.width), top, top + lineHeight);
|
|
13955
|
+
ctx.fillRect(lrtb.left, lrtb.top, lrtb.right - lrtb.left, lrtb.bottom - lrtb.top), ctx.fillStyle = fillStyle, ctx.globalAlpha = globalAlpha;
|
|
13956
|
+
}
|
|
13957
|
+
draw(ctx, top, ascent, deltaLeft, isLineFirst, textAlign, lineHeight) {
|
|
13958
|
+
let baseline = top + ascent,
|
|
13959
|
+
text = this.text,
|
|
13960
|
+
left = this.left + deltaLeft;
|
|
13961
|
+
baseline += this.top;
|
|
13962
|
+
let direction = this.direction;
|
|
13963
|
+
if (this.verticalEllipsis) text = this.ellipsisStr, direction = "vertical", baseline -= this.ellipsisWidth / 2;else {
|
|
13964
|
+
if ("hide" === this.ellipsis) return;
|
|
13965
|
+
if ("add" === this.ellipsis) text += this.ellipsisStr, "right" !== textAlign && "end" !== textAlign || (left -= this.ellipsisWidth);else if ("replace" === this.ellipsis) {
|
|
13966
|
+
const index = getStrByWithCanvas(text, ("vertical" === direction ? this.height : this.width) - this.ellipsisWidth + this.ellipsisOtherParagraphWidth, this.character, text.length - 1);
|
|
13967
|
+
if (text = text.slice(0, index), text += this.ellipsisStr, "right" === textAlign || "end" === textAlign) {
|
|
13968
|
+
const {
|
|
13969
|
+
width: width
|
|
13970
|
+
} = measureTextCanvas(this.text.slice(index), this.character);
|
|
13971
|
+
"vertical" === direction || (left -= this.ellipsisWidth - width);
|
|
13972
|
+
}
|
|
13973
|
+
}
|
|
13974
|
+
}
|
|
13975
|
+
switch (this.character.script) {
|
|
13976
|
+
case "super":
|
|
13977
|
+
baseline -= this.ascent * (1 / 3);
|
|
13978
|
+
break;
|
|
13979
|
+
case "sub":
|
|
13980
|
+
baseline += this.descent / 2;
|
|
13945
13981
|
}
|
|
13982
|
+
"vertical" === direction && (ctx.save(), ctx.rotateAbout(Math.PI / 2, left, baseline), ctx.translate(-this.heightOrigin || -this.lineHeight / 2, -this.descent / 2), ctx.translate(left, baseline), left = 0, baseline = 0);
|
|
13946
13983
|
const {
|
|
13947
13984
|
lineWidth = 1
|
|
13948
13985
|
} = this.character;
|
|
13949
|
-
this.character.stroke && lineWidth && ctx.strokeText(text, left, baseline), this.character.fill && ctx.fillText(text, left, baseline), this.character.fill
|
|
13986
|
+
if (this.character.stroke && lineWidth && ctx.strokeText(text, left, baseline), this.character.fill && ctx.fillText(text, left, baseline), this.character.fill) if (this.character.lineThrough || this.character.underline) {
|
|
13987
|
+
if (this.character.underline) {
|
|
13988
|
+
const top = 1 + baseline,
|
|
13989
|
+
lrtb = getFixedLRTB(left, left + (this.widthOrigin || this.width), top, top + (this.character.fontSize ? Math.max(1, Math.floor(this.character.fontSize / 10)) : 1));
|
|
13990
|
+
ctx.fillRect(lrtb.left, lrtb.top, lrtb.right - lrtb.left, lrtb.bottom - lrtb.top);
|
|
13991
|
+
}
|
|
13992
|
+
if (this.character.lineThrough) {
|
|
13993
|
+
const top = 1 + baseline - this.ascent / 2,
|
|
13994
|
+
lrtb = getFixedLRTB(left, left + (this.widthOrigin || this.width), top, top + (this.character.fontSize ? Math.max(1, Math.floor(this.character.fontSize / 10)) : 1));
|
|
13995
|
+
ctx.fillRect(lrtb.left, lrtb.top, lrtb.right - lrtb.left, lrtb.bottom - lrtb.top);
|
|
13996
|
+
}
|
|
13997
|
+
} else if ("underline" === this.character.textDecoration) {
|
|
13998
|
+
const top = 1 + baseline,
|
|
13999
|
+
lrtb = getFixedLRTB(left, left + (this.widthOrigin || this.width), top, top + (this.character.fontSize ? Math.max(1, Math.floor(this.character.fontSize / 10)) : 1));
|
|
14000
|
+
ctx.fillRect(lrtb.left, lrtb.top, lrtb.right - lrtb.left, lrtb.bottom - lrtb.top);
|
|
14001
|
+
} else if ("line-through" === this.character.textDecoration) {
|
|
14002
|
+
const top = 1 + baseline - this.ascent / 2,
|
|
14003
|
+
lrtb = getFixedLRTB(left, left + (this.widthOrigin || this.width), top, top + (this.character.fontSize ? Math.max(1, Math.floor(this.character.fontSize / 10)) : 1));
|
|
14004
|
+
ctx.fillRect(lrtb.left, lrtb.top, lrtb.right - lrtb.left, lrtb.bottom - lrtb.top);
|
|
14005
|
+
}
|
|
14006
|
+
"vertical" === direction && ctx.restore();
|
|
13950
14007
|
}
|
|
13951
14008
|
getWidthWithEllips(direction) {
|
|
13952
14009
|
let text = this.text;
|
|
@@ -14170,6 +14227,8 @@
|
|
|
14170
14227
|
}
|
|
14171
14228
|
}
|
|
14172
14229
|
this.paragraphs.forEach((paragraph, index) => {
|
|
14230
|
+
paragraph instanceof RichTextIcon || paragraph.drawBackground(ctx, y, this.ascent, x, 0 === index, this.textAlign, this.height);
|
|
14231
|
+
}), this.paragraphs.forEach((paragraph, index) => {
|
|
14173
14232
|
if (paragraph instanceof RichTextIcon) return paragraph.setAttributes({
|
|
14174
14233
|
x: x + paragraph._x,
|
|
14175
14234
|
y: y + paragraph._y
|
|
@@ -14180,7 +14239,7 @@
|
|
|
14180
14239
|
x2: this.left + this.actualWidth,
|
|
14181
14240
|
y2: this.top + this.height
|
|
14182
14241
|
};
|
|
14183
|
-
applyStrokeStyle(ctx, paragraph.character), applyFillStyle(ctx, paragraph.character, b), paragraph.draw(ctx, y, this.ascent, x, 0 === index, this.textAlign);
|
|
14242
|
+
applyStrokeStyle(ctx, paragraph.character), applyFillStyle(ctx, paragraph.character, b), paragraph.draw(ctx, y, this.ascent, x, 0 === index, this.textAlign, this.height);
|
|
14184
14243
|
});
|
|
14185
14244
|
}
|
|
14186
14245
|
getWidthWithEllips(ellipsis) {
|
|
@@ -14347,13 +14406,15 @@
|
|
|
14347
14406
|
}), tc;
|
|
14348
14407
|
}
|
|
14349
14408
|
updateAABBBounds(attribute, richtextTheme, aabbBounds) {
|
|
14409
|
+
var _a, _b;
|
|
14350
14410
|
const {
|
|
14351
14411
|
width = richtextTheme.width,
|
|
14352
14412
|
height = richtextTheme.height,
|
|
14353
14413
|
maxWidth = richtextTheme.maxWidth,
|
|
14354
14414
|
maxHeight = richtextTheme.maxHeight,
|
|
14355
14415
|
textAlign = richtextTheme.textAlign,
|
|
14356
|
-
textBaseline = richtextTheme.textBaseline
|
|
14416
|
+
textBaseline = richtextTheme.textBaseline,
|
|
14417
|
+
editOptions: editOptions
|
|
14357
14418
|
} = attribute;
|
|
14358
14419
|
if (width > 0 && height > 0) aabbBounds.set(0, 0, width, height);else {
|
|
14359
14420
|
const frameCache = this.getFrameCache(),
|
|
@@ -14365,6 +14426,7 @@
|
|
|
14365
14426
|
contentHeight = height || actualHeight || 0;
|
|
14366
14427
|
contentHeight = "number" == typeof maxHeight && contentHeight > maxHeight ? maxHeight : contentHeight || 0, contentWidth = "number" == typeof maxWidth && contentWidth > maxWidth ? maxWidth : contentWidth || 0, aabbBounds.set(0, 0, contentWidth, contentHeight);
|
|
14367
14428
|
}
|
|
14429
|
+
editOptions && editOptions.keepHeightWhileEmpty && !aabbBounds.height() && !(null === (_a = attribute.textConfig) || void 0 === _a ? void 0 : _a.length) && (aabbBounds.y2 = aabbBounds.y1 + (null !== (_b = attribute.fontSize) && void 0 !== _b ? _b : 12), aabbBounds.x2 = aabbBounds.x1 + 2);
|
|
14368
14430
|
let deltaY = 0;
|
|
14369
14431
|
switch (textBaseline) {
|
|
14370
14432
|
case "top":
|
|
@@ -15342,17 +15404,17 @@
|
|
|
15342
15404
|
}
|
|
15343
15405
|
}
|
|
15344
15406
|
|
|
15345
|
-
var __decorate$
|
|
15407
|
+
var __decorate$1C = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
15346
15408
|
var d,
|
|
15347
15409
|
c = arguments.length,
|
|
15348
15410
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
15349
15411
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
15350
15412
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
15351
15413
|
},
|
|
15352
|
-
__metadata$
|
|
15414
|
+
__metadata$1d = undefined && undefined.__metadata || function (k, v) {
|
|
15353
15415
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
15354
15416
|
},
|
|
15355
|
-
__param$
|
|
15417
|
+
__param$R = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
15356
15418
|
return function (target, key) {
|
|
15357
15419
|
decorator(target, key, paramIndex);
|
|
15358
15420
|
};
|
|
@@ -15449,7 +15511,7 @@
|
|
|
15449
15511
|
});
|
|
15450
15512
|
}
|
|
15451
15513
|
};
|
|
15452
|
-
exports.DefaultBaseInteractiveRenderContribution = __decorate$
|
|
15514
|
+
exports.DefaultBaseInteractiveRenderContribution = __decorate$1C([injectable(), __param$R(0, inject(ContributionProvider)), __param$R(0, named(InteractiveSubRenderContribution)), __metadata$1d("design:paramtypes", [Object])], exports.DefaultBaseInteractiveRenderContribution);
|
|
15453
15515
|
|
|
15454
15516
|
function formatRatio(ratio) {
|
|
15455
15517
|
return ratio <= .5 ? 4 * ratio - 1 : -4 * ratio + 3;
|
|
@@ -15797,7 +15859,7 @@
|
|
|
15797
15859
|
return !edgeCb && path.closePath(), path;
|
|
15798
15860
|
}
|
|
15799
15861
|
|
|
15800
|
-
var __decorate$
|
|
15862
|
+
var __decorate$1B = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
15801
15863
|
var d,
|
|
15802
15864
|
c = arguments.length,
|
|
15803
15865
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -15862,7 +15924,7 @@
|
|
|
15862
15924
|
Array.isArray(stroke) && stroke.some(s => !1 === s) && (doFillOrStroke.doStroke = !1);
|
|
15863
15925
|
}
|
|
15864
15926
|
};
|
|
15865
|
-
exports.SplitRectBeforeRenderContribution = __decorate$
|
|
15927
|
+
exports.SplitRectBeforeRenderContribution = __decorate$1B([injectable()], exports.SplitRectBeforeRenderContribution);
|
|
15866
15928
|
exports.SplitRectAfterRenderContribution = class SplitRectAfterRenderContribution {
|
|
15867
15929
|
constructor() {
|
|
15868
15930
|
this.time = exports.BaseRenderContributionTime.afterFillStroke, this.useStyle = !0, this.order = 0;
|
|
@@ -15899,7 +15961,7 @@
|
|
|
15899
15961
|
}
|
|
15900
15962
|
}
|
|
15901
15963
|
};
|
|
15902
|
-
exports.SplitRectAfterRenderContribution = __decorate$
|
|
15964
|
+
exports.SplitRectAfterRenderContribution = __decorate$1B([injectable()], exports.SplitRectAfterRenderContribution);
|
|
15903
15965
|
const defaultRectRenderContribution = new DefaultRectRenderContribution();
|
|
15904
15966
|
const defaultRectTextureRenderContribution = defaultBaseTextureRenderContribution;
|
|
15905
15967
|
const defaultRectBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
|
|
@@ -15908,8 +15970,8 @@
|
|
|
15908
15970
|
constructor() {
|
|
15909
15971
|
super(...arguments), this.time = exports.BaseRenderContributionTime.afterFillStroke, this.useStyle = !0, this.order = 0;
|
|
15910
15972
|
}
|
|
15911
|
-
drawShape(
|
|
15912
|
-
return super.drawShape(
|
|
15973
|
+
drawShape(rect, context, x, y, doFill, doStroke, fVisible, sVisible, rectAttribute, drawContext, fillCb, strokeCb) {
|
|
15974
|
+
return super.drawShape(rect, context, x, y, doFill, doStroke, fVisible, sVisible, rectAttribute, drawContext, fillCb, strokeCb);
|
|
15913
15975
|
}
|
|
15914
15976
|
}
|
|
15915
15977
|
const defaultImageRenderContribution = new DefaultImageRenderContribution();
|
|
@@ -16004,17 +16066,17 @@
|
|
|
16004
16066
|
}
|
|
16005
16067
|
}
|
|
16006
16068
|
|
|
16007
|
-
var __decorate$
|
|
16069
|
+
var __decorate$1A = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16008
16070
|
var d,
|
|
16009
16071
|
c = arguments.length,
|
|
16010
16072
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
16011
16073
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
16012
16074
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16013
16075
|
},
|
|
16014
|
-
__metadata$
|
|
16076
|
+
__metadata$1c = undefined && undefined.__metadata || function (k, v) {
|
|
16015
16077
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
16016
16078
|
},
|
|
16017
|
-
__param$
|
|
16079
|
+
__param$Q = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
16018
16080
|
return function (target, key) {
|
|
16019
16081
|
decorator(target, key, paramIndex);
|
|
16020
16082
|
};
|
|
@@ -16178,19 +16240,19 @@
|
|
|
16178
16240
|
this._draw(arc, arcAttribute, !1, drawContext, params);
|
|
16179
16241
|
}
|
|
16180
16242
|
};
|
|
16181
|
-
exports.DefaultCanvasArcRender = __decorate$
|
|
16243
|
+
exports.DefaultCanvasArcRender = __decorate$1A([injectable(), __param$Q(0, inject(ContributionProvider)), __param$Q(0, named(ArcRenderContribution)), __metadata$1c("design:paramtypes", [Object])], exports.DefaultCanvasArcRender);
|
|
16182
16244
|
|
|
16183
|
-
var __decorate$
|
|
16245
|
+
var __decorate$1z = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16184
16246
|
var d,
|
|
16185
16247
|
c = arguments.length,
|
|
16186
16248
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
16187
16249
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
16188
16250
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16189
16251
|
},
|
|
16190
|
-
__metadata$
|
|
16252
|
+
__metadata$1b = undefined && undefined.__metadata || function (k, v) {
|
|
16191
16253
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
16192
16254
|
},
|
|
16193
|
-
__param$
|
|
16255
|
+
__param$P = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
16194
16256
|
return function (target, key) {
|
|
16195
16257
|
decorator(target, key, paramIndex);
|
|
16196
16258
|
};
|
|
@@ -16231,7 +16293,7 @@
|
|
|
16231
16293
|
this._draw(circle, circleAttribute, !1, drawContext, params);
|
|
16232
16294
|
}
|
|
16233
16295
|
};
|
|
16234
|
-
exports.DefaultCanvasCircleRender = __decorate$
|
|
16296
|
+
exports.DefaultCanvasCircleRender = __decorate$1z([injectable(), __param$P(0, inject(ContributionProvider)), __param$P(0, named(CircleRenderContribution)), __metadata$1b("design:paramtypes", [Object])], exports.DefaultCanvasCircleRender);
|
|
16235
16297
|
|
|
16236
16298
|
function drawSegItem(ctx, curve, endPercent, params) {
|
|
16237
16299
|
if (!curve.p1) return;
|
|
@@ -16355,7 +16417,7 @@
|
|
|
16355
16417
|
});
|
|
16356
16418
|
}
|
|
16357
16419
|
|
|
16358
|
-
var __decorate$
|
|
16420
|
+
var __decorate$1y = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16359
16421
|
var d,
|
|
16360
16422
|
c = arguments.length,
|
|
16361
16423
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -16516,7 +16578,7 @@
|
|
|
16516
16578
|
} else this.drawSegmentItem(context, line.cache, !!fill, !!stroke, fillOpacity, strokeOpacity, line.attribute, lineAttribute, clipRange, clipRangeByDimension, x, y, line, fillCb, strokeCb);
|
|
16517
16579
|
}
|
|
16518
16580
|
};
|
|
16519
|
-
exports.DefaultCanvasLineRender = __decorate$
|
|
16581
|
+
exports.DefaultCanvasLineRender = __decorate$1y([injectable()], exports.DefaultCanvasLineRender);
|
|
16520
16582
|
|
|
16521
16583
|
function drawAreaSegments(path, segPath, percent, params) {
|
|
16522
16584
|
var _a;
|
|
@@ -16645,17 +16707,17 @@
|
|
|
16645
16707
|
const defaultAreaTextureRenderContribution = new DefaultAreaTextureRenderContribution();
|
|
16646
16708
|
const defaultAreaBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
|
|
16647
16709
|
|
|
16648
|
-
var __decorate$
|
|
16710
|
+
var __decorate$1x = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16649
16711
|
var d,
|
|
16650
16712
|
c = arguments.length,
|
|
16651
16713
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
16652
16714
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
16653
16715
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16654
16716
|
},
|
|
16655
|
-
__metadata$
|
|
16717
|
+
__metadata$1a = undefined && undefined.__metadata || function (k, v) {
|
|
16656
16718
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
16657
16719
|
},
|
|
16658
|
-
__param$
|
|
16720
|
+
__param$O = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
16659
16721
|
return function (target, key) {
|
|
16660
16722
|
decorator(target, key, paramIndex);
|
|
16661
16723
|
};
|
|
@@ -16898,22 +16960,22 @@
|
|
|
16898
16960
|
})(), !1;
|
|
16899
16961
|
}
|
|
16900
16962
|
};
|
|
16901
|
-
exports.DefaultCanvasAreaRender = __decorate$
|
|
16963
|
+
exports.DefaultCanvasAreaRender = __decorate$1x([injectable(), __param$O(0, inject(ContributionProvider)), __param$O(0, named(AreaRenderContribution)), __metadata$1a("design:paramtypes", [Object])], exports.DefaultCanvasAreaRender);
|
|
16902
16964
|
|
|
16903
16965
|
const defaultPathTextureRenderContribution = defaultBaseTextureRenderContribution;
|
|
16904
16966
|
const defaultPathBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
|
|
16905
16967
|
|
|
16906
|
-
var __decorate$
|
|
16968
|
+
var __decorate$1w = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16907
16969
|
var d,
|
|
16908
16970
|
c = arguments.length,
|
|
16909
16971
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
16910
16972
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
16911
16973
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16912
16974
|
},
|
|
16913
|
-
__metadata$
|
|
16975
|
+
__metadata$19 = undefined && undefined.__metadata || function (k, v) {
|
|
16914
16976
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
16915
16977
|
},
|
|
16916
|
-
__param$
|
|
16978
|
+
__param$N = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
16917
16979
|
return function (target, key) {
|
|
16918
16980
|
decorator(target, key, paramIndex);
|
|
16919
16981
|
};
|
|
@@ -16957,19 +17019,19 @@
|
|
|
16957
17019
|
this.tempTheme = pathAttribute, this._draw(path, pathAttribute, !1, drawContext, params), this.tempTheme = null;
|
|
16958
17020
|
}
|
|
16959
17021
|
};
|
|
16960
|
-
exports.DefaultCanvasPathRender = __decorate$
|
|
17022
|
+
exports.DefaultCanvasPathRender = __decorate$1w([injectable(), __param$N(0, inject(ContributionProvider)), __param$N(0, named(PathRenderContribution)), __metadata$19("design:paramtypes", [Object])], exports.DefaultCanvasPathRender);
|
|
16961
17023
|
|
|
16962
|
-
var __decorate$
|
|
17024
|
+
var __decorate$1v = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
16963
17025
|
var d,
|
|
16964
17026
|
c = arguments.length,
|
|
16965
17027
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
16966
17028
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
16967
17029
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16968
17030
|
},
|
|
16969
|
-
__metadata$
|
|
17031
|
+
__metadata$18 = undefined && undefined.__metadata || function (k, v) {
|
|
16970
17032
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
16971
17033
|
},
|
|
16972
|
-
__param$
|
|
17034
|
+
__param$M = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
16973
17035
|
return function (target, key) {
|
|
16974
17036
|
decorator(target, key, paramIndex);
|
|
16975
17037
|
};
|
|
@@ -17029,19 +17091,19 @@
|
|
|
17029
17091
|
this.tempTheme = rectAttribute, this._draw(rect, rectAttribute, !1, drawContext, params), this.tempTheme = null;
|
|
17030
17092
|
}
|
|
17031
17093
|
};
|
|
17032
|
-
exports.DefaultCanvasRectRender = __decorate$
|
|
17094
|
+
exports.DefaultCanvasRectRender = __decorate$1v([injectable(), __param$M(0, inject(ContributionProvider)), __param$M(0, named(RectRenderContribution)), __metadata$18("design:paramtypes", [Object])], exports.DefaultCanvasRectRender);
|
|
17033
17095
|
|
|
17034
|
-
var __decorate$
|
|
17096
|
+
var __decorate$1u = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17035
17097
|
var d,
|
|
17036
17098
|
c = arguments.length,
|
|
17037
17099
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17038
17100
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17039
17101
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17040
17102
|
},
|
|
17041
|
-
__metadata$
|
|
17103
|
+
__metadata$17 = undefined && undefined.__metadata || function (k, v) {
|
|
17042
17104
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17043
17105
|
},
|
|
17044
|
-
__param$
|
|
17106
|
+
__param$L = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17045
17107
|
return function (target, key) {
|
|
17046
17108
|
decorator(target, key, paramIndex);
|
|
17047
17109
|
};
|
|
@@ -17112,7 +17174,7 @@
|
|
|
17112
17174
|
this._draw(symbol, symbolAttribute, !1, drawContext, params);
|
|
17113
17175
|
}
|
|
17114
17176
|
};
|
|
17115
|
-
exports.DefaultCanvasSymbolRender = __decorate$
|
|
17177
|
+
exports.DefaultCanvasSymbolRender = __decorate$1u([injectable(), __param$L(0, inject(ContributionProvider)), __param$L(0, named(SymbolRenderContribution)), __metadata$17("design:paramtypes", [Object])], exports.DefaultCanvasSymbolRender);
|
|
17116
17178
|
|
|
17117
17179
|
class DefaultBoundsAllocate {
|
|
17118
17180
|
constructor() {
|
|
@@ -17201,17 +17263,17 @@
|
|
|
17201
17263
|
}
|
|
17202
17264
|
const defaultTextBackgroundRenderContribution = new DefaultTextBackgroundRenderContribution();
|
|
17203
17265
|
|
|
17204
|
-
var __decorate$
|
|
17266
|
+
var __decorate$1t = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17205
17267
|
var d,
|
|
17206
17268
|
c = arguments.length,
|
|
17207
17269
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17208
17270
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17209
17271
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17210
17272
|
},
|
|
17211
|
-
__metadata$
|
|
17273
|
+
__metadata$16 = undefined && undefined.__metadata || function (k, v) {
|
|
17212
17274
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17213
17275
|
},
|
|
17214
|
-
__param$
|
|
17276
|
+
__param$K = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17215
17277
|
return function (target, key) {
|
|
17216
17278
|
decorator(target, key, paramIndex);
|
|
17217
17279
|
};
|
|
@@ -17350,9 +17412,9 @@
|
|
|
17350
17412
|
}
|
|
17351
17413
|
}
|
|
17352
17414
|
};
|
|
17353
|
-
exports.DefaultCanvasTextRender = __decorate$
|
|
17415
|
+
exports.DefaultCanvasTextRender = __decorate$1t([injectable(), __param$K(0, inject(ContributionProvider)), __param$K(0, named(TextRenderContribution)), __metadata$16("design:paramtypes", [Object])], exports.DefaultCanvasTextRender);
|
|
17354
17416
|
|
|
17355
|
-
var __decorate$
|
|
17417
|
+
var __decorate$1s = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17356
17418
|
var d,
|
|
17357
17419
|
c = arguments.length,
|
|
17358
17420
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -17360,7 +17422,7 @@
|
|
|
17360
17422
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17361
17423
|
};
|
|
17362
17424
|
exports.AbstractGraphicRender = class AbstractGraphicRender {};
|
|
17363
|
-
exports.AbstractGraphicRender = __decorate$
|
|
17425
|
+
exports.AbstractGraphicRender = __decorate$1s([injectable()], exports.AbstractGraphicRender);
|
|
17364
17426
|
|
|
17365
17427
|
function drawPolygon(path, points, x, y) {
|
|
17366
17428
|
path.moveTo(points[0].x + x, points[0].y + y);
|
|
@@ -17416,17 +17478,17 @@
|
|
|
17416
17478
|
const defaultPolygonTextureRenderContribution = defaultBaseTextureRenderContribution;
|
|
17417
17479
|
const defaultPolygonBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
|
|
17418
17480
|
|
|
17419
|
-
var __decorate$
|
|
17481
|
+
var __decorate$1r = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17420
17482
|
var d,
|
|
17421
17483
|
c = arguments.length,
|
|
17422
17484
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17423
17485
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17424
17486
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17425
17487
|
},
|
|
17426
|
-
__metadata$
|
|
17488
|
+
__metadata$15 = undefined && undefined.__metadata || function (k, v) {
|
|
17427
17489
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17428
17490
|
},
|
|
17429
|
-
__param$
|
|
17491
|
+
__param$J = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17430
17492
|
return function (target, key) {
|
|
17431
17493
|
decorator(target, key, paramIndex);
|
|
17432
17494
|
};
|
|
@@ -17467,19 +17529,19 @@
|
|
|
17467
17529
|
this._draw(polygon, polygonAttribute, !1, drawContext, params);
|
|
17468
17530
|
}
|
|
17469
17531
|
};
|
|
17470
|
-
exports.DefaultCanvasPolygonRender = __decorate$
|
|
17532
|
+
exports.DefaultCanvasPolygonRender = __decorate$1r([injectable(), __param$J(0, inject(ContributionProvider)), __param$J(0, named(PolygonRenderContribution)), __metadata$15("design:paramtypes", [Object])], exports.DefaultCanvasPolygonRender);
|
|
17471
17533
|
|
|
17472
|
-
var __decorate$
|
|
17534
|
+
var __decorate$1q = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17473
17535
|
var d,
|
|
17474
17536
|
c = arguments.length,
|
|
17475
17537
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17476
17538
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17477
17539
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17478
17540
|
},
|
|
17479
|
-
__metadata$
|
|
17541
|
+
__metadata$14 = undefined && undefined.__metadata || function (k, v) {
|
|
17480
17542
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17481
17543
|
},
|
|
17482
|
-
__param$
|
|
17544
|
+
__param$I = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17483
17545
|
return function (target, key) {
|
|
17484
17546
|
decorator(target, key, paramIndex);
|
|
17485
17547
|
};
|
|
@@ -17574,19 +17636,19 @@
|
|
|
17574
17636
|
}) : clip ? context.restore() : context.highPerformanceRestore();
|
|
17575
17637
|
}
|
|
17576
17638
|
};
|
|
17577
|
-
exports.DefaultCanvasGroupRender = __decorate$
|
|
17639
|
+
exports.DefaultCanvasGroupRender = __decorate$1q([injectable(), __param$I(0, inject(ContributionProvider)), __param$I(0, named(GroupRenderContribution)), __metadata$14("design:paramtypes", [Object])], exports.DefaultCanvasGroupRender);
|
|
17578
17640
|
|
|
17579
|
-
var __decorate$
|
|
17641
|
+
var __decorate$1p = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17580
17642
|
var d,
|
|
17581
17643
|
c = arguments.length,
|
|
17582
17644
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17583
17645
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17584
17646
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17585
17647
|
},
|
|
17586
|
-
__metadata$
|
|
17648
|
+
__metadata$13 = undefined && undefined.__metadata || function (k, v) {
|
|
17587
17649
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17588
17650
|
},
|
|
17589
|
-
__param$
|
|
17651
|
+
__param$H = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17590
17652
|
return function (target, key) {
|
|
17591
17653
|
decorator(target, key, paramIndex);
|
|
17592
17654
|
};
|
|
@@ -17654,7 +17716,7 @@
|
|
|
17654
17716
|
this._draw(image, imageAttribute, !1, drawContext);
|
|
17655
17717
|
}
|
|
17656
17718
|
};
|
|
17657
|
-
exports.DefaultCanvasImageRender = __decorate$
|
|
17719
|
+
exports.DefaultCanvasImageRender = __decorate$1p([injectable(), __param$H(0, inject(ContributionProvider)), __param$H(0, named(ImageRenderContribution)), __metadata$13("design:paramtypes", [Object])], exports.DefaultCanvasImageRender);
|
|
17658
17720
|
|
|
17659
17721
|
const IncrementalDrawContribution = Symbol.for("IncrementalDrawContribution");
|
|
17660
17722
|
const ArcRender = Symbol.for("ArcRender");
|
|
@@ -17722,14 +17784,14 @@
|
|
|
17722
17784
|
return result;
|
|
17723
17785
|
};
|
|
17724
17786
|
|
|
17725
|
-
var __decorate$
|
|
17787
|
+
var __decorate$1o = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17726
17788
|
var d,
|
|
17727
17789
|
c = arguments.length,
|
|
17728
17790
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17729
17791
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17730
17792
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17731
17793
|
},
|
|
17732
|
-
__metadata$
|
|
17794
|
+
__metadata$12 = undefined && undefined.__metadata || function (k, v) {
|
|
17733
17795
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17734
17796
|
};
|
|
17735
17797
|
const DrawItemInterceptor = Symbol.for("DrawItemInterceptor");
|
|
@@ -17789,7 +17851,7 @@
|
|
|
17789
17851
|
return !1;
|
|
17790
17852
|
}
|
|
17791
17853
|
};
|
|
17792
|
-
exports.CommonDrawItemInterceptorContribution = __decorate$
|
|
17854
|
+
exports.CommonDrawItemInterceptorContribution = __decorate$1o([injectable(), __metadata$12("design:paramtypes", [])], exports.CommonDrawItemInterceptorContribution);
|
|
17793
17855
|
class InteractiveDrawItemInterceptorContribution {
|
|
17794
17856
|
constructor() {
|
|
17795
17857
|
this.order = 1;
|
|
@@ -17880,17 +17942,17 @@
|
|
|
17880
17942
|
}
|
|
17881
17943
|
}
|
|
17882
17944
|
|
|
17883
|
-
var __decorate$
|
|
17945
|
+
var __decorate$1n = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17884
17946
|
var d,
|
|
17885
17947
|
c = arguments.length,
|
|
17886
17948
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
17887
17949
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
17888
17950
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
17889
17951
|
},
|
|
17890
|
-
__metadata$
|
|
17952
|
+
__metadata$11 = undefined && undefined.__metadata || function (k, v) {
|
|
17891
17953
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
17892
17954
|
},
|
|
17893
|
-
__param$
|
|
17955
|
+
__param$G = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
17894
17956
|
return function (target, key) {
|
|
17895
17957
|
decorator(target, key, paramIndex);
|
|
17896
17958
|
};
|
|
@@ -17928,7 +17990,7 @@
|
|
|
17928
17990
|
this.prepare(updateBounds), this.prepareRenderList(), this.beforeDraw(params), this.draw(params), this.afterDraw(params), this.drawParams = null;
|
|
17929
17991
|
}
|
|
17930
17992
|
};
|
|
17931
|
-
exports.DefaultRenderService = __decorate$
|
|
17993
|
+
exports.DefaultRenderService = __decorate$1n([injectable(), __param$G(0, inject(DrawContribution)), __metadata$11("design:paramtypes", [Object])], exports.DefaultRenderService);
|
|
17932
17994
|
|
|
17933
17995
|
var renderModule$1 = new ContainerModule(bind => {
|
|
17934
17996
|
bind(RenderService).to(exports.DefaultRenderService);
|
|
@@ -17941,7 +18003,7 @@
|
|
|
17941
18003
|
const PickItemInterceptor = Symbol.for("PickItemInterceptor");
|
|
17942
18004
|
const PickServiceInterceptor = Symbol.for("PickServiceInterceptor");
|
|
17943
18005
|
|
|
17944
|
-
var __decorate$
|
|
18006
|
+
var __decorate$1m = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
17945
18007
|
var d,
|
|
17946
18008
|
c = arguments.length,
|
|
17947
18009
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -17963,7 +18025,7 @@
|
|
|
17963
18025
|
return result;
|
|
17964
18026
|
}
|
|
17965
18027
|
};
|
|
17966
|
-
exports.ShadowPickServiceInterceptorContribution = __decorate$
|
|
18028
|
+
exports.ShadowPickServiceInterceptorContribution = __decorate$1m([injectable()], exports.ShadowPickServiceInterceptorContribution);
|
|
17967
18029
|
exports.ShadowRootPickItemInterceptorContribution = class ShadowRootPickItemInterceptorContribution {
|
|
17968
18030
|
constructor() {
|
|
17969
18031
|
this.order = 1;
|
|
@@ -17994,7 +18056,7 @@
|
|
|
17994
18056
|
return context.highPerformanceRestore(), !result.graphic && result.group && "full" === shadowPickMode && (result.graphic = result.group), result;
|
|
17995
18057
|
}
|
|
17996
18058
|
};
|
|
17997
|
-
exports.ShadowRootPickItemInterceptorContribution = __decorate$
|
|
18059
|
+
exports.ShadowRootPickItemInterceptorContribution = __decorate$1m([injectable()], exports.ShadowRootPickItemInterceptorContribution);
|
|
17998
18060
|
exports.InteractivePickItemInterceptorContribution = class InteractivePickItemInterceptorContribution {
|
|
17999
18061
|
constructor() {
|
|
18000
18062
|
this.order = 1;
|
|
@@ -18013,7 +18075,7 @@
|
|
|
18013
18075
|
return null;
|
|
18014
18076
|
}
|
|
18015
18077
|
};
|
|
18016
|
-
exports.InteractivePickItemInterceptorContribution = __decorate$
|
|
18078
|
+
exports.InteractivePickItemInterceptorContribution = __decorate$1m([injectable()], exports.InteractivePickItemInterceptorContribution);
|
|
18017
18079
|
exports.Canvas3DPickItemInterceptor = class Canvas3DPickItemInterceptor {
|
|
18018
18080
|
constructor() {
|
|
18019
18081
|
this.order = 1;
|
|
@@ -18033,7 +18095,7 @@
|
|
|
18033
18095
|
context.setTransformForCurrent();
|
|
18034
18096
|
}
|
|
18035
18097
|
};
|
|
18036
|
-
exports.Canvas3DPickItemInterceptor = __decorate$
|
|
18098
|
+
exports.Canvas3DPickItemInterceptor = __decorate$1m([injectable()], exports.Canvas3DPickItemInterceptor);
|
|
18037
18099
|
|
|
18038
18100
|
var pickModule = new ContainerModule((bind, unbind, isBound) => {
|
|
18039
18101
|
isBound(PickerService) || (bind(GlobalPickerService).toSelf(), bind(PickerService).toService(GlobalPickerService)), bind(exports.Canvas3DPickItemInterceptor).toSelf().inSingletonScope(), bind(PickItemInterceptor).toService(exports.Canvas3DPickItemInterceptor), bind(exports.ShadowRootPickItemInterceptorContribution).toSelf().inSingletonScope(), bind(PickItemInterceptor).toService(exports.ShadowRootPickItemInterceptorContribution), bind(exports.InteractivePickItemInterceptorContribution).toSelf().inSingletonScope(), bind(PickItemInterceptor).toService(exports.InteractivePickItemInterceptorContribution), bindContributionProvider(bind, PickItemInterceptor), bind(exports.ShadowPickServiceInterceptorContribution).toSelf().inSingletonScope(), bind(PickServiceInterceptor).toService(exports.ShadowPickServiceInterceptorContribution), bindContributionProvider(bind, PickServiceInterceptor);
|
|
@@ -18046,17 +18108,17 @@
|
|
|
18046
18108
|
const AutoEnablePlugins = Symbol.for("AutoEnablePlugins");
|
|
18047
18109
|
const PluginService = Symbol.for("PluginService");
|
|
18048
18110
|
|
|
18049
|
-
var __decorate$
|
|
18111
|
+
var __decorate$1l = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18050
18112
|
var d,
|
|
18051
18113
|
c = arguments.length,
|
|
18052
18114
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
18053
18115
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
18054
18116
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
18055
18117
|
},
|
|
18056
|
-
__metadata$
|
|
18118
|
+
__metadata$10 = undefined && undefined.__metadata || function (k, v) {
|
|
18057
18119
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
18058
18120
|
},
|
|
18059
|
-
__param$
|
|
18121
|
+
__param$F = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
18060
18122
|
return function (target, key) {
|
|
18061
18123
|
decorator(target, key, paramIndex);
|
|
18062
18124
|
};
|
|
@@ -18096,7 +18158,7 @@
|
|
|
18096
18158
|
}), this.onRegisterPlugin = [];
|
|
18097
18159
|
}
|
|
18098
18160
|
};
|
|
18099
|
-
DefaultPluginService = __decorate$
|
|
18161
|
+
DefaultPluginService = __decorate$1l([injectable(), __param$F(0, inject(ContributionProvider)), __param$F(0, named(AutoEnablePlugins)), __metadata$10("design:paramtypes", [Object])], DefaultPluginService);
|
|
18100
18162
|
|
|
18101
18163
|
var pluginModule = new ContainerModule(bind => {
|
|
18102
18164
|
bind(PluginService).to(DefaultPluginService), bindContributionProviderNoSingletonScope(bind, AutoEnablePlugins);
|
|
@@ -18110,14 +18172,14 @@
|
|
|
18110
18172
|
bind(TextMeasureContribution).to(exports.DefaultTextMeasureContribution).inSingletonScope(), bindContributionProvider(bind, TextMeasureContribution);
|
|
18111
18173
|
});
|
|
18112
18174
|
|
|
18113
|
-
var __decorate$
|
|
18175
|
+
var __decorate$1k = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18114
18176
|
var d,
|
|
18115
18177
|
c = arguments.length,
|
|
18116
18178
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
18117
18179
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
18118
18180
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
18119
18181
|
},
|
|
18120
|
-
__metadata
|
|
18182
|
+
__metadata$$ = undefined && undefined.__metadata || function (k, v) {
|
|
18121
18183
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
18122
18184
|
};
|
|
18123
18185
|
let CanvasLayerHandlerContribution = class {
|
|
@@ -18187,7 +18249,7 @@
|
|
|
18187
18249
|
this.canvas.release();
|
|
18188
18250
|
}
|
|
18189
18251
|
};
|
|
18190
|
-
CanvasLayerHandlerContribution = __decorate$
|
|
18252
|
+
CanvasLayerHandlerContribution = __decorate$1k([injectable(), __metadata$$("design:paramtypes", [])], CanvasLayerHandlerContribution);
|
|
18191
18253
|
|
|
18192
18254
|
var layerHandlerModules = new ContainerModule(bind => {
|
|
18193
18255
|
bind(CanvasLayerHandlerContribution).toSelf(), bind(StaticLayerHandlerContribution).toService(CanvasLayerHandlerContribution);
|
|
@@ -18306,17 +18368,17 @@
|
|
|
18306
18368
|
return result;
|
|
18307
18369
|
}
|
|
18308
18370
|
|
|
18309
|
-
var __decorate$
|
|
18371
|
+
var __decorate$1j = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18310
18372
|
var d,
|
|
18311
18373
|
c = arguments.length,
|
|
18312
18374
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
18313
18375
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
18314
18376
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
18315
18377
|
},
|
|
18316
|
-
__metadata
|
|
18378
|
+
__metadata$_ = undefined && undefined.__metadata || function (k, v) {
|
|
18317
18379
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
18318
18380
|
},
|
|
18319
|
-
__param$
|
|
18381
|
+
__param$E = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
18320
18382
|
return function (target, key) {
|
|
18321
18383
|
decorator(target, key, paramIndex);
|
|
18322
18384
|
};
|
|
@@ -18455,7 +18517,7 @@
|
|
|
18455
18517
|
} = graphic.parent.attribute;
|
|
18456
18518
|
(scrollX || scrollY) && (retrans = !0, this.scrollMatrix || (this.scrollMatrix = matrixAllocate.allocate(1, 0, 0, 1, 0, 0)), this.scrollMatrix.translate(-scrollX, -scrollY));
|
|
18457
18519
|
}
|
|
18458
|
-
if (retrans && (tempBounds = this.dirtyBounds.clone().transformWithMatrix(this.scrollMatrix)), this.useDirtyBounds && !graphic.isContainer && !isRectIntersect(graphic.AABBBounds, null != tempBounds ? tempBounds : this.dirtyBounds, !1)) {
|
|
18520
|
+
if (retrans && (tempBounds = this.dirtyBounds.clone().transformWithMatrix(this.scrollMatrix)), this.useDirtyBounds && !graphic.isContainer && "empty" !== graphic.attribute.boundsMode && !isRectIntersect(graphic.AABBBounds, null != tempBounds ? tempBounds : this.dirtyBounds, !1)) {
|
|
18459
18521
|
if (retrans && graphic.parent) {
|
|
18460
18522
|
const {
|
|
18461
18523
|
scrollX = 0,
|
|
@@ -18515,9 +18577,9 @@
|
|
|
18515
18577
|
}
|
|
18516
18578
|
afterDraw(renderService, drawParams) {}
|
|
18517
18579
|
};
|
|
18518
|
-
DefaultDrawContribution = __decorate$
|
|
18580
|
+
DefaultDrawContribution = __decorate$1j([injectable(), __param$E(0, multiInject(GraphicRender)), __param$E(1, inject(ContributionProvider)), __param$E(1, named(DrawItemInterceptor)), __metadata$_("design:paramtypes", [Array, Object])], DefaultDrawContribution);
|
|
18519
18581
|
|
|
18520
|
-
var __decorate$
|
|
18582
|
+
var __decorate$1i = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18521
18583
|
var d,
|
|
18522
18584
|
c = arguments.length,
|
|
18523
18585
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -18568,9 +18630,9 @@
|
|
|
18568
18630
|
}), context.setShadowBlendStyle && context.setShadowBlendStyle(line, attribute, defaultAttribute), context.setStrokeStyle(line, attribute, offsetX, offsetY, defaultAttribute), context.stroke());
|
|
18569
18631
|
}
|
|
18570
18632
|
};
|
|
18571
|
-
DefaultIncrementalCanvasLineRender = __decorate$
|
|
18633
|
+
DefaultIncrementalCanvasLineRender = __decorate$1i([injectable()], DefaultIncrementalCanvasLineRender);
|
|
18572
18634
|
|
|
18573
|
-
var __decorate$
|
|
18635
|
+
var __decorate$1h = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18574
18636
|
var d,
|
|
18575
18637
|
c = arguments.length,
|
|
18576
18638
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -18613,20 +18675,20 @@
|
|
|
18613
18675
|
}), context.setShadowBlendStyle && context.setShadowBlendStyle(area, attribute, defaultAttribute), context.setCommonStyle(area, attribute, offsetX, offsetY, defaultAttribute), context.fill());
|
|
18614
18676
|
}
|
|
18615
18677
|
};
|
|
18616
|
-
DefaultIncrementalCanvasAreaRender = __decorate$
|
|
18678
|
+
DefaultIncrementalCanvasAreaRender = __decorate$1h([injectable()], DefaultIncrementalCanvasAreaRender);
|
|
18617
18679
|
|
|
18618
18680
|
var STATUS,
|
|
18619
|
-
__decorate$
|
|
18681
|
+
__decorate$1g = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
18620
18682
|
var d,
|
|
18621
18683
|
c = arguments.length,
|
|
18622
18684
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
18623
18685
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
18624
18686
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
18625
18687
|
},
|
|
18626
|
-
__metadata$
|
|
18688
|
+
__metadata$Z = undefined && undefined.__metadata || function (k, v) {
|
|
18627
18689
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
18628
18690
|
},
|
|
18629
|
-
__param$
|
|
18691
|
+
__param$D = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
18630
18692
|
return function (target, key) {
|
|
18631
18693
|
decorator(target, key, paramIndex);
|
|
18632
18694
|
};
|
|
@@ -18756,7 +18818,7 @@
|
|
|
18756
18818
|
});
|
|
18757
18819
|
}
|
|
18758
18820
|
};
|
|
18759
|
-
DefaultIncrementalDrawContribution = __decorate$
|
|
18821
|
+
DefaultIncrementalDrawContribution = __decorate$1g([injectable(), __param$D(0, multiInject(GraphicRender)), __param$D(1, inject(DefaultIncrementalCanvasLineRender)), __param$D(2, inject(DefaultIncrementalCanvasAreaRender)), __param$D(3, inject(ContributionProvider)), __param$D(3, named(DrawItemInterceptor)), __metadata$Z("design:paramtypes", [Array, Object, Object, Object])], DefaultIncrementalDrawContribution);
|
|
18760
18822
|
|
|
18761
18823
|
var renderModule = new ContainerModule(bind => {
|
|
18762
18824
|
bind(DefaultBaseBackgroundRenderContribution).toSelf().inSingletonScope(), bind(DefaultBaseTextureRenderContribution).toSelf().inSingletonScope(), bind(DrawContribution).to(DefaultDrawContribution), bind(IncrementalDrawContribution).to(DefaultIncrementalDrawContribution), bind(GroupRender).to(exports.DefaultCanvasGroupRender).inSingletonScope(), bind(GraphicRender).toService(GroupRender), bindContributionProvider(bind, GroupRenderContribution), bind(exports.DefaultBaseInteractiveRenderContribution).toSelf().inSingletonScope(), bindContributionProvider(bind, InteractiveSubRenderContribution), bindContributionProvider(bind, GraphicRender), bind(exports.CommonDrawItemInterceptorContribution).toSelf().inSingletonScope(), bind(DrawItemInterceptor).toService(exports.CommonDrawItemInterceptorContribution), bindContributionProvider(bind, DrawItemInterceptor);
|
|
@@ -19452,14 +19514,14 @@
|
|
|
19452
19514
|
return new Stage(params);
|
|
19453
19515
|
}
|
|
19454
19516
|
|
|
19455
|
-
var __decorate$
|
|
19517
|
+
var __decorate$1f = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
19456
19518
|
var d,
|
|
19457
19519
|
c = arguments.length,
|
|
19458
19520
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
19459
19521
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
19460
19522
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19461
19523
|
},
|
|
19462
|
-
__metadata$
|
|
19524
|
+
__metadata$Y = undefined && undefined.__metadata || function (k, v) {
|
|
19463
19525
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
19464
19526
|
};
|
|
19465
19527
|
const initMatrix = new Matrix(1, 0, 0, 1, 0, 0),
|
|
@@ -19669,7 +19731,7 @@
|
|
|
19669
19731
|
this.stack.forEach(m => matrixAllocate.free(m)), this.stack.length = 0;
|
|
19670
19732
|
}
|
|
19671
19733
|
};
|
|
19672
|
-
exports.EmptyContext2d = __decorate$
|
|
19734
|
+
exports.EmptyContext2d = __decorate$1f([injectable(), __metadata$Y("design:paramtypes", [Object, Number])], exports.EmptyContext2d);
|
|
19673
19735
|
|
|
19674
19736
|
const DefaultConfig = {
|
|
19675
19737
|
WIDTH: 500,
|
|
@@ -19768,7 +19830,7 @@
|
|
|
19768
19830
|
}
|
|
19769
19831
|
BaseCanvas.env = "browser";
|
|
19770
19832
|
|
|
19771
|
-
var __decorate$
|
|
19833
|
+
var __decorate$1e = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
19772
19834
|
var d,
|
|
19773
19835
|
c = arguments.length,
|
|
19774
19836
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -19882,16 +19944,16 @@
|
|
|
19882
19944
|
return Promise.resolve(null);
|
|
19883
19945
|
}
|
|
19884
19946
|
};
|
|
19885
|
-
exports.BaseEnvContribution = __decorate$
|
|
19947
|
+
exports.BaseEnvContribution = __decorate$1e([injectable()], exports.BaseEnvContribution);
|
|
19886
19948
|
|
|
19887
|
-
var __decorate$
|
|
19949
|
+
var __decorate$1d = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
19888
19950
|
var d,
|
|
19889
19951
|
c = arguments.length,
|
|
19890
19952
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
19891
19953
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
19892
19954
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19893
19955
|
},
|
|
19894
|
-
__metadata$
|
|
19956
|
+
__metadata$X = undefined && undefined.__metadata || function (k, v) {
|
|
19895
19957
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
19896
19958
|
};
|
|
19897
19959
|
exports.BaseWindowHandlerContribution = class BaseWindowHandlerContribution {
|
|
@@ -19930,7 +19992,7 @@
|
|
|
19930
19992
|
return this.modelMatrix;
|
|
19931
19993
|
}
|
|
19932
19994
|
};
|
|
19933
|
-
exports.BaseWindowHandlerContribution = __decorate$
|
|
19995
|
+
exports.BaseWindowHandlerContribution = __decorate$1d([injectable(), __metadata$X("design:paramtypes", [])], exports.BaseWindowHandlerContribution);
|
|
19934
19996
|
|
|
19935
19997
|
class DirectionalLight {
|
|
19936
19998
|
constructor(dir, color) {
|
|
@@ -20021,17 +20083,17 @@
|
|
|
20021
20083
|
Factory.registerPlugin("OrthoCamera", OrthoCamera);
|
|
20022
20084
|
};
|
|
20023
20085
|
|
|
20024
|
-
var __decorate$
|
|
20086
|
+
var __decorate$1c = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
20025
20087
|
var d,
|
|
20026
20088
|
c = arguments.length,
|
|
20027
20089
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
20028
20090
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
20029
20091
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
20030
20092
|
},
|
|
20031
|
-
__metadata$
|
|
20093
|
+
__metadata$W = undefined && undefined.__metadata || function (k, v) {
|
|
20032
20094
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
20033
20095
|
},
|
|
20034
|
-
__param$
|
|
20096
|
+
__param$C = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
20035
20097
|
return function (target, key) {
|
|
20036
20098
|
decorator(target, key, paramIndex);
|
|
20037
20099
|
};
|
|
@@ -20136,16 +20198,16 @@
|
|
|
20136
20198
|
return picker || null;
|
|
20137
20199
|
}
|
|
20138
20200
|
};
|
|
20139
|
-
exports.DefaultPickService = __decorate$
|
|
20201
|
+
exports.DefaultPickService = __decorate$1c([injectable(), __param$C(0, inject(ContributionProvider)), __param$C(0, named(PickItemInterceptor)), __param$C(1, inject(ContributionProvider)), __param$C(1, named(PickServiceInterceptor)), __metadata$W("design:paramtypes", [Object, Object])], exports.DefaultPickService);
|
|
20140
20202
|
|
|
20141
|
-
var __decorate$
|
|
20203
|
+
var __decorate$1b = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
20142
20204
|
var d,
|
|
20143
20205
|
c = arguments.length,
|
|
20144
20206
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
20145
20207
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
20146
20208
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
20147
20209
|
},
|
|
20148
|
-
__metadata$
|
|
20210
|
+
__metadata$V = undefined && undefined.__metadata || function (k, v) {
|
|
20149
20211
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
20150
20212
|
};
|
|
20151
20213
|
exports.DefaultGlobalPickerService = class DefaultGlobalPickerService {
|
|
@@ -20210,7 +20272,7 @@
|
|
|
20210
20272
|
} : null;
|
|
20211
20273
|
}
|
|
20212
20274
|
};
|
|
20213
|
-
exports.DefaultGlobalPickerService = __decorate$
|
|
20275
|
+
exports.DefaultGlobalPickerService = __decorate$1b([injectable(), __metadata$V("design:paramtypes", [])], exports.DefaultGlobalPickerService);
|
|
20214
20276
|
|
|
20215
20277
|
function simplifyRadialDist(points, sqTolerance) {
|
|
20216
20278
|
let deltaX,
|
|
@@ -20235,6 +20297,24 @@
|
|
|
20235
20297
|
}
|
|
20236
20298
|
return t;
|
|
20237
20299
|
};
|
|
20300
|
+
function getDefaultCharacterConfig(attribute) {
|
|
20301
|
+
const {
|
|
20302
|
+
fill = "black",
|
|
20303
|
+
stroke = !1,
|
|
20304
|
+
fontWeight = "normal",
|
|
20305
|
+
fontFamily = "Arial"
|
|
20306
|
+
} = attribute;
|
|
20307
|
+
let {
|
|
20308
|
+
fontSize = 12
|
|
20309
|
+
} = attribute;
|
|
20310
|
+
return isFinite(fontSize) || (fontSize = 12), {
|
|
20311
|
+
fill: fill,
|
|
20312
|
+
stroke: stroke,
|
|
20313
|
+
fontSize: fontSize,
|
|
20314
|
+
fontWeight: fontWeight,
|
|
20315
|
+
fontFamily: fontFamily
|
|
20316
|
+
};
|
|
20317
|
+
}
|
|
20238
20318
|
function findConfigIndexByCursorIdx(textConfig, cursorIndex) {
|
|
20239
20319
|
if (cursorIndex < 0) return 0;
|
|
20240
20320
|
const intCursorIndex = Math.round(cursorIndex);
|
|
@@ -20273,9 +20353,7 @@
|
|
|
20273
20353
|
} = this.currRt.attribute;
|
|
20274
20354
|
if (this.composingConfigIdx = this.cursorIndex < 0 ? 0 : findConfigIndexByCursorIdx(textConfig, this.cursorIndex), this.cursorIndex < 0) {
|
|
20275
20355
|
const config = textConfig[0];
|
|
20276
|
-
textConfig.unshift(Object.assign(Object.assign({
|
|
20277
|
-
fill: "black"
|
|
20278
|
-
}, config), {
|
|
20356
|
+
textConfig.unshift(Object.assign(Object.assign(Object.assign({}, getDefaultCharacterConfig(this.currRt.attribute)), config), {
|
|
20279
20357
|
text: ""
|
|
20280
20358
|
}));
|
|
20281
20359
|
} else {
|
|
@@ -20292,26 +20370,20 @@
|
|
|
20292
20370
|
cb(text, this.isComposing, this.cursorIndex, this.currRt);
|
|
20293
20371
|
});
|
|
20294
20372
|
}, this.handleInput = ev => {
|
|
20295
|
-
var _a, _b, _c, _d;
|
|
20296
20373
|
if (!this.currRt) return;
|
|
20297
20374
|
if ("historyUndo" === ev.inputType) return;
|
|
20298
|
-
const
|
|
20375
|
+
const _a = this.currRt.attribute,
|
|
20299
20376
|
{
|
|
20300
20377
|
textConfig = []
|
|
20301
|
-
} =
|
|
20302
|
-
rest = __rest$1(
|
|
20378
|
+
} = _a,
|
|
20379
|
+
rest = __rest$1(_a, ["textConfig"]);
|
|
20303
20380
|
if ("Backspace" === ev.type && !textConfig.length) return;
|
|
20304
20381
|
let str = ev.data;
|
|
20305
20382
|
this.isComposing || "Backspace" === ev.type || str || (str = "\n"), this.selectionStartCursorIdx > this.cursorIndex && ([this.cursorIndex, this.selectionStartCursorIdx] = [this.selectionStartCursorIdx, this.cursorIndex]);
|
|
20306
20383
|
const startIdx = findConfigIndexByCursorIdx(textConfig, this.selectionStartCursorIdx),
|
|
20307
20384
|
endIdx = findConfigIndexByCursorIdx(textConfig, this.cursorIndex);
|
|
20308
20385
|
let lastConfig = textConfig[this.isComposing ? this.composingConfigIdx : Math.max(startIdx - 1, 0)];
|
|
20309
|
-
lastConfig || (lastConfig =
|
|
20310
|
-
fill: null !== (_a = rest.fill) && void 0 !== _a ? _a : "black",
|
|
20311
|
-
stroke: null !== (_b = rest.stroke) && void 0 !== _b && _b,
|
|
20312
|
-
fontSize: null !== (_c = rest.fontSize) && void 0 !== _c ? _c : 12,
|
|
20313
|
-
fontWeight: null !== (_d = rest.fontWeight) && void 0 !== _d ? _d : "normal"
|
|
20314
|
-
});
|
|
20386
|
+
lastConfig || (lastConfig = getDefaultCharacterConfig(rest));
|
|
20315
20387
|
let nextConfig = lastConfig;
|
|
20316
20388
|
startIdx !== endIdx && (textConfig.splice(startIdx, endIdx - startIdx), this.isComposing && (this.composingConfigIdx = startIdx));
|
|
20317
20389
|
let nextConfigIdx = startIdx;
|
|
@@ -20407,6 +20479,7 @@
|
|
|
20407
20479
|
if (!this.rt) return null;
|
|
20408
20480
|
let idx = Math.round(cursorIdx);
|
|
20409
20481
|
const config = this.rt.attribute.textConfig;
|
|
20482
|
+
if (!config.length) return null;
|
|
20410
20483
|
for (let i = 0; i < config.length; i++) if ("\n" !== config[i].text && (idx--, idx < 0)) return config[i][key];
|
|
20411
20484
|
return null !== (_a = config[Math.min(idx, config.length - 1)][key]) && void 0 !== _a ? _a : this.rt.attribute[key];
|
|
20412
20485
|
}
|
|
@@ -20426,6 +20499,7 @@
|
|
|
20426
20499
|
}
|
|
20427
20500
|
}
|
|
20428
20501
|
const FORMAT_TEXT_COMMAND = "FORMAT_TEXT_COMMAND";
|
|
20502
|
+
const FORMAT_ALL_TEXT_COMMAND = "FORMAT_ALL_TEXT_COMMAND";
|
|
20429
20503
|
const FORMAT_ELEMENT_COMMAND = "FORMAT_ELEMENT_COMMAND";
|
|
20430
20504
|
class RichTextEditPlugin {
|
|
20431
20505
|
static tryUpdateRichtext(richtext) {
|
|
@@ -20445,16 +20519,39 @@
|
|
|
20445
20519
|
return new Selection(0, textConfig.length - 1, rt);
|
|
20446
20520
|
}
|
|
20447
20521
|
constructor() {
|
|
20448
|
-
this.name = "RichTextEditPlugin", this.activeEvent = "onRegister", this._uid = Generator.GenAutoIncrementId(), this.key = this.name + this._uid, this.editing = !1, this.pointerDown = !1, this.
|
|
20522
|
+
this.name = "RichTextEditPlugin", this.activeEvent = "onRegister", this._uid = Generator.GenAutoIncrementId(), this.key = this.name + this._uid, this.editing = !1, this.focusing = !1, this.pointerDown = !1, this.formatTextCommandCb = (payload, p) => {
|
|
20523
|
+
const rt = p.currRt;
|
|
20524
|
+
if (!rt) return;
|
|
20525
|
+
const selectionData = p.getSelection();
|
|
20526
|
+
if (!selectionData) return;
|
|
20527
|
+
const {
|
|
20528
|
+
selectionStartCursorIdx: selectionStartCursorIdx,
|
|
20529
|
+
curCursorIdx: curCursorIdx
|
|
20530
|
+
} = selectionData,
|
|
20531
|
+
minCursorIdx = Math.min(selectionStartCursorIdx, curCursorIdx),
|
|
20532
|
+
maxCursorIdx = Math.max(selectionStartCursorIdx, curCursorIdx),
|
|
20533
|
+
minConfigIdx = findConfigIndexByCursorIdx(rt.attribute.textConfig, minCursorIdx),
|
|
20534
|
+
maxConfigIdx = findConfigIndexByCursorIdx(rt.attribute.textConfig, maxCursorIdx),
|
|
20535
|
+
config = rt.attribute.textConfig.slice(minConfigIdx, maxConfigIdx);
|
|
20536
|
+
this._formatTextCommand(payload, config, rt);
|
|
20537
|
+
}, this.formatAllTextCommandCb = (payload, p) => {
|
|
20538
|
+
const rt = p.currRt;
|
|
20539
|
+
if (!rt) return;
|
|
20540
|
+
const config = rt.attribute.textConfig;
|
|
20541
|
+
this._formatTextCommand(payload, config, rt);
|
|
20542
|
+
}, this.handleKeyDown = e => {
|
|
20449
20543
|
this.currRt && this.editing && (this.copyToClipboard(e) || this.fullSelection(e) || this.directKey(e));
|
|
20450
20544
|
}, this.handleInput = (text, isComposing, cursorIdx, rt) => {
|
|
20451
|
-
this.hideSelection(), this.updateCbs.forEach(cb => cb("input", this));
|
|
20545
|
+
this.currRt && (this.tryShowShadowPlaceholder(), this.tryShowInputBounds(), this.hideSelection(), this.updateCbs.forEach(cb => cb("input", this)));
|
|
20452
20546
|
}, this.handleChange = (text, isComposing, cursorIdx, rt) => {
|
|
20453
|
-
|
|
20547
|
+
if (!this.currRt) return;
|
|
20548
|
+
this.tryShowShadowPlaceholder(), this.tryShowInputBounds(), this.curCursorIdx = cursorIdx, this.selectionStartCursorIdx = cursorIdx;
|
|
20454
20549
|
const p = this.computedCursorPosByCursorIdx(cursorIdx, rt);
|
|
20455
20550
|
this.setCursorAndTextArea(p.x, p.y1, p.y2, rt), this.hideSelection(), this.updateCbs.forEach(cb => cb("change", this));
|
|
20456
|
-
}, this.handleFocusIn = () => {
|
|
20457
|
-
|
|
20551
|
+
}, this.handleFocusIn = () => {
|
|
20552
|
+
throw new Error("不会走到这里 handleFocusIn");
|
|
20553
|
+
}, this.handleFocusOut = () => {
|
|
20554
|
+
throw new Error("不会走到这里 handleFocusOut");
|
|
20458
20555
|
}, this.handleMove = e => {
|
|
20459
20556
|
this.isRichtext(e) && (this.currRt = e.target, this.handleEnter(e), e.target.once("pointerleave", this.handleLeave), this.tryShowSelection(e, !1));
|
|
20460
20557
|
}, this.handleEnter = e => {
|
|
@@ -20462,28 +20559,17 @@
|
|
|
20462
20559
|
}, this.handleLeave = e => {
|
|
20463
20560
|
this.editing = !1, this.pluginService.stage.setCursor("default");
|
|
20464
20561
|
}, this.handlePointerDown = e => {
|
|
20465
|
-
this.editing ? this.onFocus(e) : this.deFocus(), this.triggerRender(), this.pointerDown = !0, this.updateCbs.forEach(cb => cb(this.editing ? "onfocus" : "defocus", this));
|
|
20562
|
+
this.editing ? this.onFocus(e) : this.deFocus(!0), this.triggerRender(), this.pointerDown = !0, this.updateCbs.forEach(cb => cb(this.editing ? "onfocus" : "defocus", this));
|
|
20466
20563
|
}, this.handlePointerUp = e => {
|
|
20467
20564
|
this.pointerDown = !1;
|
|
20468
20565
|
}, this.handleDBLClick = e => {
|
|
20469
20566
|
this.editing && this.tryShowSelection(e, !0);
|
|
20470
|
-
}, this.commandCbs = new Map(), this.commandCbs.set(FORMAT_TEXT_COMMAND, [this.formatTextCommandCb]), this.updateCbs = [], this.timeline = new DefaultTimeline(), this.ticker = new DefaultTicker([this.timeline]), this.deltaX = 0, this.deltaY = 0;
|
|
20567
|
+
}, this.commandCbs = new Map(), this.commandCbs.set(FORMAT_TEXT_COMMAND, [this.formatTextCommandCb]), this.commandCbs.set(FORMAT_ALL_TEXT_COMMAND, [this.formatAllTextCommandCb]), this.updateCbs = [], this.timeline = new DefaultTimeline(), this.ticker = new DefaultTicker([this.timeline]), this.deltaX = 0, this.deltaY = 0;
|
|
20471
20568
|
}
|
|
20472
|
-
|
|
20473
|
-
const rt = p.currRt;
|
|
20474
|
-
if (!rt) return;
|
|
20475
|
-
const selectionData = p.getSelection();
|
|
20476
|
-
if (!selectionData) return;
|
|
20477
|
-
const {
|
|
20478
|
-
selectionStartCursorIdx: selectionStartCursorIdx,
|
|
20479
|
-
curCursorIdx: curCursorIdx
|
|
20480
|
-
} = selectionData,
|
|
20481
|
-
minCursorIdx = Math.min(selectionStartCursorIdx, curCursorIdx),
|
|
20482
|
-
maxCursorIdx = Math.max(selectionStartCursorIdx, curCursorIdx),
|
|
20483
|
-
minConfigIdx = findConfigIndexByCursorIdx(rt.attribute.textConfig, minCursorIdx),
|
|
20484
|
-
maxConfigIdx = findConfigIndexByCursorIdx(rt.attribute.textConfig, maxCursorIdx),
|
|
20485
|
-
config = rt.attribute.textConfig.slice(minConfigIdx, maxConfigIdx);
|
|
20569
|
+
_formatTextCommand(payload, config, rt) {
|
|
20486
20570
|
"bold" === payload ? config.forEach(item => item.fontWeight = "bold") : "italic" === payload ? config.forEach(item => item.fontStyle = "italic") : "underline" === payload ? config.forEach(item => item.underline = !0) : "lineThrough" === payload ? config.forEach(item => item.lineThrough = !0) : isObject$1(payload) && config.forEach(item => merge(item, payload)), rt.setAttributes(rt.attribute);
|
|
20571
|
+
const cache = rt.getFrameCache();
|
|
20572
|
+
cache && (this.selectionRangeByCursorIdx(this.selectionStartCursorIdx, this.curCursorIdx, cache), this.tryShowInputBounds());
|
|
20487
20573
|
}
|
|
20488
20574
|
dispatchCommand(command, payload) {
|
|
20489
20575
|
const cbs = this.commandCbs.get(command);
|
|
@@ -20492,9 +20578,19 @@
|
|
|
20492
20578
|
registerCommand(command, cb) {
|
|
20493
20579
|
(this.commandCbs.get(command) || []).push(cb);
|
|
20494
20580
|
}
|
|
20581
|
+
removeCommand(command, cb) {
|
|
20582
|
+
const cbs = this.commandCbs.get(command) || [],
|
|
20583
|
+
idx = cbs.indexOf(cb);
|
|
20584
|
+
idx > -1 && cbs.splice(idx, 1);
|
|
20585
|
+
}
|
|
20495
20586
|
registerUpdateListener(cb) {
|
|
20496
20587
|
(this.updateCbs || []).push(cb);
|
|
20497
20588
|
}
|
|
20589
|
+
removeUpdateListener(cb) {
|
|
20590
|
+
const cbs = this.updateCbs || [],
|
|
20591
|
+
idx = cbs.indexOf(cb);
|
|
20592
|
+
idx > -1 && cbs.splice(idx, 1);
|
|
20593
|
+
}
|
|
20498
20594
|
activate(context) {
|
|
20499
20595
|
this.pluginService = context, this.editModule = new EditModule(), context.stage.on("pointermove", this.handleMove), context.stage.on("pointerdown", this.handlePointerDown), context.stage.on("pointerup", this.handlePointerUp), context.stage.on("pointerleave", this.handlePointerUp), context.stage.on("dblclick", this.handleDBLClick), application.global.addEventListener("keydown", this.handleKeyDown), this.editModule.onInput(this.handleInput), this.editModule.onChange(this.handleChange), this.editModule.onFocusOut(this.handleFocusOut);
|
|
20500
20596
|
}
|
|
@@ -20514,7 +20610,10 @@
|
|
|
20514
20610
|
lines: lines
|
|
20515
20611
|
} = cache,
|
|
20516
20612
|
totalCursorCount = lines.reduce((total, line) => total + line.paragraphs.length, 0) - 1;
|
|
20517
|
-
startIdx > endIdx && ([startIdx, endIdx] = [endIdx, startIdx]), startIdx = Math.min(Math.max(startIdx, -.1), totalCursorCount + .1), endIdx = Math.min(Math.max(endIdx, -.1), totalCursorCount + .1), this.
|
|
20613
|
+
startIdx > endIdx && ([startIdx, endIdx] = [endIdx, startIdx]), startIdx = Math.min(Math.max(startIdx, -.1), totalCursorCount + .1), endIdx = Math.min(Math.max(endIdx, -.1), totalCursorCount + .1), this.selectionRangeByCursorIdx(startIdx, endIdx, cache);
|
|
20614
|
+
}
|
|
20615
|
+
selectionRangeByCursorIdx(startCursorIdx, endCursorIdx, cache) {
|
|
20616
|
+
this.curCursorIdx = endCursorIdx, this.selectionStartCursorIdx = startCursorIdx;
|
|
20518
20617
|
const {
|
|
20519
20618
|
x: x,
|
|
20520
20619
|
y1: y1,
|
|
@@ -20585,61 +20684,192 @@
|
|
|
20585
20684
|
}
|
|
20586
20685
|
return !0;
|
|
20587
20686
|
}
|
|
20687
|
+
tryShowShadowPlaceholder() {
|
|
20688
|
+
if (!this.currRt) return;
|
|
20689
|
+
const shadowRoot = this.currRt.shadowRoot;
|
|
20690
|
+
if (shadowRoot) {
|
|
20691
|
+
const placeholder = shadowRoot.getElementsByType("richtext")[0];
|
|
20692
|
+
placeholder && shadowRoot.removeChild(placeholder);
|
|
20693
|
+
}
|
|
20694
|
+
const {
|
|
20695
|
+
textConfig: textConfig,
|
|
20696
|
+
editOptions: editOptions
|
|
20697
|
+
} = this.currRt.attribute;
|
|
20698
|
+
if (textConfig && textConfig.length) return;
|
|
20699
|
+
if (!editOptions || !editOptions.placeholder) return;
|
|
20700
|
+
const {
|
|
20701
|
+
placeholder: placeholder,
|
|
20702
|
+
placeholderColor = "rgba(0, 0, 0, 0.6)",
|
|
20703
|
+
placeholderFontFamily: placeholderFontFamily,
|
|
20704
|
+
placeholderFontSize: placeholderFontSize
|
|
20705
|
+
} = editOptions,
|
|
20706
|
+
shadow = this.currRt.shadowRoot || this.currRt.attachShadow();
|
|
20707
|
+
this.shadowPlaceHolder = createRichText(Object.assign(Object.assign({}, this.currRt.attribute), {
|
|
20708
|
+
x: 0,
|
|
20709
|
+
y: 0,
|
|
20710
|
+
angle: 0,
|
|
20711
|
+
_debug_bounds: !1,
|
|
20712
|
+
textConfig: [{
|
|
20713
|
+
text: placeholder,
|
|
20714
|
+
fill: placeholderColor,
|
|
20715
|
+
fontFamily: placeholderFontFamily,
|
|
20716
|
+
fontSize: placeholderFontSize
|
|
20717
|
+
}]
|
|
20718
|
+
})), shadow.add(this.shadowPlaceHolder);
|
|
20719
|
+
}
|
|
20720
|
+
tryShowInputBounds() {
|
|
20721
|
+
if (!this.currRt || !this.focusing) return;
|
|
20722
|
+
const {
|
|
20723
|
+
editOptions = {}
|
|
20724
|
+
} = this.currRt.attribute,
|
|
20725
|
+
{
|
|
20726
|
+
boundsStrokeWhenInput: boundsStrokeWhenInput
|
|
20727
|
+
} = editOptions;
|
|
20728
|
+
if (!editOptions || !boundsStrokeWhenInput) return;
|
|
20729
|
+
const {
|
|
20730
|
+
attribute: attribute
|
|
20731
|
+
} = this.currRt,
|
|
20732
|
+
b = this.currRt.AABBBounds;
|
|
20733
|
+
let h = b.height();
|
|
20734
|
+
if (!attribute.textConfig.length && this.editLine) {
|
|
20735
|
+
const {
|
|
20736
|
+
points: points
|
|
20737
|
+
} = this.editLine.attribute;
|
|
20738
|
+
h = points[1].y - points[0].y;
|
|
20739
|
+
}
|
|
20740
|
+
this.shadowBounds = this.shadowBounds || createRect({}), this.shadowBounds.setAttributes({
|
|
20741
|
+
x: 0,
|
|
20742
|
+
y: 0,
|
|
20743
|
+
width: b.width(),
|
|
20744
|
+
height: h,
|
|
20745
|
+
fill: !1,
|
|
20746
|
+
stroke: boundsStrokeWhenInput,
|
|
20747
|
+
lineWidth: 1,
|
|
20748
|
+
boundsMode: "empty",
|
|
20749
|
+
zIndex: -1
|
|
20750
|
+
});
|
|
20751
|
+
(this.currRt.shadowRoot || this.currRt.attachShadow()).add(this.shadowBounds), this.offsetLineBgAndShadowBounds();
|
|
20752
|
+
}
|
|
20753
|
+
trySyncPlaceholderToTextConfig() {
|
|
20754
|
+
if (!this.currRt) return;
|
|
20755
|
+
const {
|
|
20756
|
+
textConfig: textConfig,
|
|
20757
|
+
editOptions: editOptions
|
|
20758
|
+
} = this.currRt.attribute;
|
|
20759
|
+
if (textConfig && textConfig.length) return;
|
|
20760
|
+
if (!editOptions || !editOptions.placeholder) return;
|
|
20761
|
+
const {
|
|
20762
|
+
placeholder: placeholder
|
|
20763
|
+
} = editOptions;
|
|
20764
|
+
this.currRt.setAttributes({
|
|
20765
|
+
textConfig: [Object.assign({
|
|
20766
|
+
text: placeholder
|
|
20767
|
+
}, getDefaultCharacterConfig(this.currRt.attribute))]
|
|
20768
|
+
});
|
|
20769
|
+
}
|
|
20588
20770
|
deactivate(context) {
|
|
20589
20771
|
context.stage.off("pointermove", this.handleMove), context.stage.off("pointerdown", this.handlePointerDown), context.stage.off("pointerup", this.handlePointerUp), context.stage.off("pointerleave", this.handlePointerUp), context.stage.off("dblclick", this.handleDBLClick), application.global.addEventListener("keydown", this.handleKeyDown);
|
|
20590
20772
|
}
|
|
20591
|
-
onFocus(e) {
|
|
20592
|
-
this.deFocus(), this.
|
|
20773
|
+
onFocus(e, data) {
|
|
20774
|
+
this.deFocus(!1), this.focusing = !0;
|
|
20593
20775
|
const target = e.target;
|
|
20594
|
-
|
|
20595
|
-
|
|
20776
|
+
if (!target || "richtext" !== target.type) return;
|
|
20777
|
+
this.currRt = target, RichTextEditPlugin.tryUpdateRichtext(target);
|
|
20778
|
+
const shadowRoot = target.shadowRoot || target.attachShadow(),
|
|
20596
20779
|
cache = target.getFrameCache();
|
|
20597
|
-
if (
|
|
20598
|
-
|
|
20599
|
-
|
|
20600
|
-
|
|
20601
|
-
|
|
20602
|
-
|
|
20603
|
-
|
|
20604
|
-
|
|
20605
|
-
|
|
20606
|
-
|
|
20607
|
-
|
|
20608
|
-
|
|
20609
|
-
|
|
20610
|
-
|
|
20611
|
-
|
|
20612
|
-
|
|
20613
|
-
|
|
20614
|
-
|
|
20615
|
-
|
|
20616
|
-
|
|
20617
|
-
|
|
20618
|
-
|
|
20619
|
-
|
|
20620
|
-
|
|
20621
|
-
|
|
20622
|
-
|
|
20623
|
-
|
|
20624
|
-
|
|
20625
|
-
|
|
20626
|
-
|
|
20627
|
-
|
|
20628
|
-
|
|
20629
|
-
|
|
20630
|
-
|
|
20780
|
+
if (cache) {
|
|
20781
|
+
if (this.computeGlobalDelta(cache), shadowRoot.setAttributes({
|
|
20782
|
+
shadowRootIdx: 1,
|
|
20783
|
+
pickable: !1,
|
|
20784
|
+
x: this.deltaX,
|
|
20785
|
+
y: this.deltaY
|
|
20786
|
+
}), !this.editLine) {
|
|
20787
|
+
const line = createLine({
|
|
20788
|
+
x: 0,
|
|
20789
|
+
y: 0,
|
|
20790
|
+
lineWidth: 1,
|
|
20791
|
+
stroke: "black",
|
|
20792
|
+
boundsMode: "empty"
|
|
20793
|
+
});
|
|
20794
|
+
this.addAnimateToLine(line), this.editLine = line, this.ticker.start(!0);
|
|
20795
|
+
const g = createGroup({
|
|
20796
|
+
x: 0,
|
|
20797
|
+
y: 0,
|
|
20798
|
+
width: 0,
|
|
20799
|
+
height: 0,
|
|
20800
|
+
boundsMode: "empty"
|
|
20801
|
+
});
|
|
20802
|
+
this.editBg = g, shadowRoot.add(this.editLine), shadowRoot.add(this.editBg);
|
|
20803
|
+
}
|
|
20804
|
+
if (data = data || this.computedCursorPosByEvent(e, cache)) {
|
|
20805
|
+
const {
|
|
20806
|
+
x: x,
|
|
20807
|
+
y1: y1,
|
|
20808
|
+
y2: y2,
|
|
20809
|
+
cursorIndex: cursorIndex
|
|
20810
|
+
} = data;
|
|
20811
|
+
this.startCursorPos = {
|
|
20812
|
+
x: x,
|
|
20813
|
+
y: (y1 + y2) / 2
|
|
20814
|
+
}, this.curCursorIdx = cursorIndex, this.selectionStartCursorIdx = cursorIndex, this.setCursorAndTextArea(x, y1, y2, target);
|
|
20815
|
+
} else {
|
|
20816
|
+
const x = 0,
|
|
20817
|
+
y1 = 0,
|
|
20818
|
+
y2 = getRichTextBounds(Object.assign(Object.assign({}, target.attribute), {
|
|
20819
|
+
textConfig: [{
|
|
20820
|
+
text: "a"
|
|
20821
|
+
}]
|
|
20822
|
+
})).height();
|
|
20823
|
+
this.startCursorPos = {
|
|
20824
|
+
x: x,
|
|
20825
|
+
y: (y1 + y2) / 2
|
|
20826
|
+
}, this.curCursorIdx = -.1, this.selectionStartCursorIdx = -.1, this.setCursorAndTextArea(x, y1, y2, target);
|
|
20827
|
+
}
|
|
20828
|
+
this.tryShowShadowPlaceholder(), this.tryShowInputBounds(), this.currRt.addUpdateBoundTag();
|
|
20631
20829
|
}
|
|
20632
20830
|
}
|
|
20831
|
+
offsetLineBgAndShadowBounds() {
|
|
20832
|
+
const rt = this.currRt,
|
|
20833
|
+
{
|
|
20834
|
+
textBaseline: textBaseline
|
|
20835
|
+
} = rt.attribute;
|
|
20836
|
+
let b,
|
|
20837
|
+
dy = 0,
|
|
20838
|
+
attr = rt.attribute;
|
|
20839
|
+
"middle" !== textBaseline && "bottom" !== textBaseline || (attr.textConfig.length || (attr = Object.assign(Object.assign({}, attr), {
|
|
20840
|
+
textConfig: [{
|
|
20841
|
+
text: "a"
|
|
20842
|
+
}]
|
|
20843
|
+
})), b = getRichTextBounds(attr)), "middle" === textBaseline ? dy = -b.height() / 2 : "bottom" === textBaseline && (dy = -b.height()), this.editLine && this.editLine.setAttributes({
|
|
20844
|
+
dy: dy
|
|
20845
|
+
}), this.editBg && this.editBg.setAttributes({
|
|
20846
|
+
dy: dy
|
|
20847
|
+
}), this.shadowBounds && this.shadowBounds.setAttributes({
|
|
20848
|
+
dy: dy
|
|
20849
|
+
});
|
|
20850
|
+
}
|
|
20633
20851
|
deFocus() {
|
|
20852
|
+
let trulyDeFocus = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
|
|
20634
20853
|
const target = this.currRt;
|
|
20635
|
-
|
|
20854
|
+
if (!target) return;
|
|
20855
|
+
trulyDeFocus && (this.trySyncPlaceholderToTextConfig(), target.detachShadow());
|
|
20856
|
+
const currRt = this.currRt;
|
|
20857
|
+
this.currRt = null, this.editLine && (this.editLine.parent && this.editLine.parent.removeChild(this.editLine), this.editLine.release(), this.editLine = null, this.editBg.parent && this.editBg.parent.removeChild(this.editBg), this.editBg.release(), this.editBg = null), trulyDeFocus && (this.shadowBounds && (this.shadowBounds.parent && this.shadowBounds.parent.removeChild(this.shadowBounds), this.shadowBounds.release(), this.shadowBounds = null), this.shadowPlaceHolder && (this.shadowPlaceHolder.parent && this.shadowPlaceHolder.parent.removeChild(this.shadowPlaceHolder), this.shadowPlaceHolder.release(), this.shadowPlaceHolder = null)), this.focusing = !1;
|
|
20858
|
+
const textConfig = currRt.attribute.textConfig;
|
|
20859
|
+
let lastConfig = textConfig[textConfig.length - 1],
|
|
20860
|
+
cleared = !1;
|
|
20861
|
+
for (; lastConfig && "\n" === lastConfig.text;) textConfig.pop(), lastConfig = textConfig[textConfig.length - 1], cleared = !0;
|
|
20862
|
+
cleared && currRt.setAttributes({
|
|
20863
|
+
textConfig: textConfig
|
|
20864
|
+
});
|
|
20636
20865
|
}
|
|
20637
20866
|
addAnimateToLine(line) {
|
|
20638
20867
|
line.animates && line.animates.forEach(animate => {
|
|
20639
20868
|
animate.stop(), animate.release();
|
|
20640
20869
|
});
|
|
20641
|
-
|
|
20642
|
-
|
|
20870
|
+
line.animate({
|
|
20871
|
+
timeline: this.timeline
|
|
20872
|
+
}).to({
|
|
20643
20873
|
opacity: 1
|
|
20644
20874
|
}, 10, "linear").wait(700).to({
|
|
20645
20875
|
opacity: 0
|
|
@@ -20733,7 +20963,7 @@
|
|
|
20733
20963
|
y += line.height;
|
|
20734
20964
|
}
|
|
20735
20965
|
}
|
|
20736
|
-
this.setCursorAndTextArea(currCursorData.x, currCursorData.y1
|
|
20966
|
+
this.setCursorAndTextArea(currCursorData.x, currCursorData.y1, currCursorData.y2, this.currRt), this.triggerRender(), this.updateCbs.forEach(cb => cb("selection", this));
|
|
20737
20967
|
}
|
|
20738
20968
|
hideSelection() {
|
|
20739
20969
|
this.editBg && (this.editBg.removeAllChild(), this.editBg.setAttributes({
|
|
@@ -20789,7 +21019,18 @@
|
|
|
20789
21019
|
x: 0,
|
|
20790
21020
|
y: 0
|
|
20791
21021
|
};
|
|
20792
|
-
|
|
21022
|
+
e.target.globalTransMatrix.transformPoint(p, p1), p1.x -= this.deltaX, p1.y -= this.deltaY;
|
|
21023
|
+
const rt = this.currRt,
|
|
21024
|
+
{
|
|
21025
|
+
textBaseline: textBaseline
|
|
21026
|
+
} = rt.attribute;
|
|
21027
|
+
let dy = 0;
|
|
21028
|
+
if ("middle" === textBaseline) {
|
|
21029
|
+
dy = getRichTextBounds(rt.attribute).height() / 2;
|
|
21030
|
+
} else if ("bottom" === textBaseline) {
|
|
21031
|
+
dy = getRichTextBounds(rt.attribute).height();
|
|
21032
|
+
}
|
|
21033
|
+
return p1.y += dy, p1;
|
|
20793
21034
|
}
|
|
20794
21035
|
setCursorAndTextArea(x, y1, y2, rt) {
|
|
20795
21036
|
this.editLine.setAttributes({
|
|
@@ -20813,7 +21054,7 @@
|
|
|
20813
21054
|
left: left,
|
|
20814
21055
|
top: top
|
|
20815
21056
|
} = this.pluginService.stage.window.getBoundingClientRect();
|
|
20816
|
-
out.x += left, out.y += top, this.editModule.moveTo(out.x, out.y, rt, this.curCursorIdx, this.selectionStartCursorIdx);
|
|
21057
|
+
out.x += left, out.y += top, this.offsetLineBgAndShadowBounds(), this.editModule.moveTo(out.x, out.y, rt, this.curCursorIdx, this.selectionStartCursorIdx);
|
|
20817
21058
|
}
|
|
20818
21059
|
computedCursorPosByEvent(e, cache) {
|
|
20819
21060
|
const p1 = this.getEventPosition(e),
|
|
@@ -20824,9 +21065,8 @@
|
|
|
20824
21065
|
delta: delta
|
|
20825
21066
|
} = this.getColumnAndIndexByLinePoint(lineInfo, p1);
|
|
20826
21067
|
if (!columnInfo) return;
|
|
20827
|
-
|
|
21068
|
+
const y1 = lineInfo.top,
|
|
20828
21069
|
y2 = lineInfo.top + lineInfo.height;
|
|
20829
|
-
y1 += 2, y2 -= 2;
|
|
20830
21070
|
let cursorIndex = this.getColumnIndex(cache, columnInfo);
|
|
20831
21071
|
cursorIndex += delta;
|
|
20832
21072
|
return {
|
|
@@ -20845,21 +21085,36 @@
|
|
|
20845
21085
|
cache = rt.getFrameCache(),
|
|
20846
21086
|
column = this.getColumnByIndex(cache, idx),
|
|
20847
21087
|
height = null !== (_a = rt.attribute.fontSize) && void 0 !== _a ? _a : null === (_c = null === (_b = rt.attribute.textConfig) || void 0 === _b ? void 0 : _b[0]) || void 0 === _c ? void 0 : _c.fontSize;
|
|
20848
|
-
if (!column)
|
|
20849
|
-
|
|
20850
|
-
|
|
20851
|
-
|
|
20852
|
-
|
|
21088
|
+
if (!column) {
|
|
21089
|
+
if (!cache.lines.length) {
|
|
21090
|
+
return {
|
|
21091
|
+
x: 0,
|
|
21092
|
+
y1: 0,
|
|
21093
|
+
y2: getRichTextBounds(Object.assign(Object.assign({}, rt.attribute), {
|
|
21094
|
+
textConfig: [{
|
|
21095
|
+
text: "a"
|
|
21096
|
+
}]
|
|
21097
|
+
})).height()
|
|
21098
|
+
};
|
|
21099
|
+
}
|
|
21100
|
+
return {
|
|
21101
|
+
x: 0,
|
|
21102
|
+
y1: 0,
|
|
21103
|
+
y2: height
|
|
21104
|
+
};
|
|
21105
|
+
}
|
|
20853
21106
|
const {
|
|
20854
|
-
|
|
20855
|
-
|
|
20856
|
-
|
|
20857
|
-
|
|
21107
|
+
lineInfo: lineInfo,
|
|
21108
|
+
columnInfo: columnInfo
|
|
21109
|
+
} = column,
|
|
21110
|
+
y1 = lineInfo.top,
|
|
20858
21111
|
y2 = lineInfo.top + lineInfo.height;
|
|
20859
|
-
return
|
|
21112
|
+
return {
|
|
20860
21113
|
x: columnInfo.left + (leftRight < 0 ? 0 : columnInfo.width),
|
|
20861
21114
|
y1: y1,
|
|
20862
|
-
y2: y2
|
|
21115
|
+
y2: y2,
|
|
21116
|
+
lineInfo: lineInfo,
|
|
21117
|
+
columnInfo: columnInfo
|
|
20863
21118
|
};
|
|
20864
21119
|
}
|
|
20865
21120
|
getColumnByIndex(cache, index) {
|
|
@@ -20883,6 +21138,37 @@
|
|
|
20883
21138
|
let defaultAll = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
|
|
20884
21139
|
return this.currRt ? null != this.selectionStartCursorIdx && null != this.curCursorIdx ? new Selection(this.selectionStartCursorIdx, this.curCursorIdx, this.currRt) : defaultAll ? RichTextEditPlugin.CreateSelection(this.currRt) : null : null;
|
|
20885
21140
|
}
|
|
21141
|
+
forceFocus(params) {
|
|
21142
|
+
const {
|
|
21143
|
+
target: target,
|
|
21144
|
+
e: e,
|
|
21145
|
+
cursorIndex: cursorIndex
|
|
21146
|
+
} = params;
|
|
21147
|
+
target && (this.currRt = target, e ? this._forceFocusByEvent(e) : this._forceFocusByCursorIndex(null != cursorIndex ? cursorIndex : -.1));
|
|
21148
|
+
}
|
|
21149
|
+
_forceFocusByEvent(e) {
|
|
21150
|
+
this.handleEnter(e), this.handlePointerDown(e), this.handlePointerUp(e);
|
|
21151
|
+
}
|
|
21152
|
+
_forceFocusByCursorIndex(cursorIndex) {
|
|
21153
|
+
const richtext = this.currRt;
|
|
21154
|
+
if (!richtext) return;
|
|
21155
|
+
let x = 0,
|
|
21156
|
+
y1 = 0,
|
|
21157
|
+
y2 = 2,
|
|
21158
|
+
lineInfo = null,
|
|
21159
|
+
columnInfo = null;
|
|
21160
|
+
const data = this.computedCursorPosByCursorIdx(cursorIndex, richtext);
|
|
21161
|
+
x = data.x, y1 = data.y1, y2 = data.y2, lineInfo = data.lineInfo, columnInfo = data.columnInfo, this.onFocus({
|
|
21162
|
+
target: this.currRt
|
|
21163
|
+
}, {
|
|
21164
|
+
x: x,
|
|
21165
|
+
y1: y1,
|
|
21166
|
+
y2: y2,
|
|
21167
|
+
cursorIndex: cursorIndex,
|
|
21168
|
+
lineInfo: lineInfo,
|
|
21169
|
+
columnInfo: columnInfo
|
|
21170
|
+
});
|
|
21171
|
+
}
|
|
20886
21172
|
}
|
|
20887
21173
|
|
|
20888
21174
|
class DefaultGraphicAllocate {
|
|
@@ -21065,7 +21351,7 @@
|
|
|
21065
21351
|
loadPolygonModule || (loadPolygonModule = !0, bind(PolygonRender).to(exports.DefaultCanvasPolygonRender).inSingletonScope(), bind(GraphicRender).toService(PolygonRender), bind(PolygonRenderContribution).toService(exports.DefaultBaseInteractiveRenderContribution), bindContributionProvider(bind, PolygonRenderContribution));
|
|
21066
21352
|
});
|
|
21067
21353
|
|
|
21068
|
-
var __decorate$
|
|
21354
|
+
var __decorate$1a = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
21069
21355
|
var d,
|
|
21070
21356
|
c = arguments.length,
|
|
21071
21357
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -21097,21 +21383,21 @@
|
|
|
21097
21383
|
}), context.highPerformanceRestore();
|
|
21098
21384
|
}
|
|
21099
21385
|
};
|
|
21100
|
-
DefaultCanvasGlyphRender = __decorate$
|
|
21386
|
+
DefaultCanvasGlyphRender = __decorate$1a([injectable()], DefaultCanvasGlyphRender);
|
|
21101
21387
|
|
|
21102
21388
|
let loadGlyphModule = !1;
|
|
21103
21389
|
const glyphModule = new ContainerModule(bind => {
|
|
21104
21390
|
loadGlyphModule || (loadGlyphModule = !0, bind(GlyphRender).to(DefaultCanvasGlyphRender).inSingletonScope(), bind(GraphicRender).toService(GlyphRender));
|
|
21105
21391
|
});
|
|
21106
21392
|
|
|
21107
|
-
var __decorate$
|
|
21393
|
+
var __decorate$19 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
21108
21394
|
var d,
|
|
21109
21395
|
c = arguments.length,
|
|
21110
21396
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
21111
21397
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
21112
21398
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
21113
21399
|
},
|
|
21114
|
-
__metadata$
|
|
21400
|
+
__metadata$U = undefined && undefined.__metadata || function (k, v) {
|
|
21115
21401
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
21116
21402
|
};
|
|
21117
21403
|
let DefaultCanvasRichTextRender = class extends BaseRender {
|
|
@@ -21165,7 +21451,7 @@
|
|
|
21165
21451
|
this._draw(richtext, richtextAttribute, !1, drawContext);
|
|
21166
21452
|
}
|
|
21167
21453
|
};
|
|
21168
|
-
DefaultCanvasRichTextRender = __decorate$
|
|
21454
|
+
DefaultCanvasRichTextRender = __decorate$19([injectable(), __metadata$U("design:paramtypes", [])], DefaultCanvasRichTextRender);
|
|
21169
21455
|
|
|
21170
21456
|
let loadRichtextModule = !1;
|
|
21171
21457
|
const richtextModule = new ContainerModule(bind => {
|
|
@@ -21249,7 +21535,7 @@
|
|
|
21249
21535
|
}
|
|
21250
21536
|
}
|
|
21251
21537
|
|
|
21252
|
-
var __decorate$
|
|
21538
|
+
var __decorate$18 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
21253
21539
|
var d,
|
|
21254
21540
|
c = arguments.length,
|
|
21255
21541
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -21305,14 +21591,14 @@
|
|
|
21305
21591
|
this._draw(rect, rectAttribute, !1, drawContext);
|
|
21306
21592
|
}
|
|
21307
21593
|
};
|
|
21308
|
-
DefaultCanvasRect3dRender = __decorate$
|
|
21594
|
+
DefaultCanvasRect3dRender = __decorate$18([injectable()], DefaultCanvasRect3dRender);
|
|
21309
21595
|
|
|
21310
21596
|
let loadRect3dModule = !1;
|
|
21311
21597
|
const rect3dModule = new ContainerModule(bind => {
|
|
21312
21598
|
loadRect3dModule || (loadRect3dModule = !0, bind(Rect3DRender).to(DefaultCanvasRect3dRender).inSingletonScope(), bind(GraphicRender).toService(Rect3DRender));
|
|
21313
21599
|
});
|
|
21314
21600
|
|
|
21315
|
-
var __decorate$
|
|
21601
|
+
var __decorate$17 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
21316
21602
|
var d,
|
|
21317
21603
|
c = arguments.length,
|
|
21318
21604
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -21439,14 +21725,14 @@
|
|
|
21439
21725
|
this._draw(arc, arcAttribute, !1, drawContext, params);
|
|
21440
21726
|
}
|
|
21441
21727
|
};
|
|
21442
|
-
DefaultCanvasArc3DRender = __decorate$
|
|
21728
|
+
DefaultCanvasArc3DRender = __decorate$17([injectable()], DefaultCanvasArc3DRender);
|
|
21443
21729
|
|
|
21444
21730
|
let loadArc3dModule = !1;
|
|
21445
21731
|
const arc3dModule = new ContainerModule(bind => {
|
|
21446
21732
|
loadArc3dModule || (loadArc3dModule = !0, bind(Arc3dRender).to(DefaultCanvasArc3DRender).inSingletonScope(), bind(GraphicRender).toService(Arc3dRender));
|
|
21447
21733
|
});
|
|
21448
21734
|
|
|
21449
|
-
var __decorate$
|
|
21735
|
+
var __decorate$16 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
21450
21736
|
var d,
|
|
21451
21737
|
c = arguments.length,
|
|
21452
21738
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -21483,7 +21769,7 @@
|
|
|
21483
21769
|
this._draw(pyramid3d, pyramid3dAttribute, !1, drawContext);
|
|
21484
21770
|
}
|
|
21485
21771
|
};
|
|
21486
|
-
DefaultCanvasPyramid3dRender = __decorate$
|
|
21772
|
+
DefaultCanvasPyramid3dRender = __decorate$16([injectable()], DefaultCanvasPyramid3dRender);
|
|
21487
21773
|
|
|
21488
21774
|
let loadPyramid3dModule = !1;
|
|
21489
21775
|
const pyramid3dModule = new ContainerModule(bind => {
|
|
@@ -23606,17 +23892,17 @@
|
|
|
23606
23892
|
}
|
|
23607
23893
|
}
|
|
23608
23894
|
|
|
23609
|
-
var __decorate$
|
|
23895
|
+
var __decorate$15 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
23610
23896
|
var d,
|
|
23611
23897
|
c = arguments.length,
|
|
23612
23898
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
23613
23899
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
23614
23900
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
23615
23901
|
},
|
|
23616
|
-
__metadata$
|
|
23902
|
+
__metadata$T = undefined && undefined.__metadata || function (k, v) {
|
|
23617
23903
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
23618
23904
|
},
|
|
23619
|
-
__param$
|
|
23905
|
+
__param$B = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
23620
23906
|
return function (target, key) {
|
|
23621
23907
|
decorator(target, key, paramIndex);
|
|
23622
23908
|
};
|
|
@@ -23702,9 +23988,9 @@
|
|
|
23702
23988
|
}), context.highPerformanceRestore();
|
|
23703
23989
|
}
|
|
23704
23990
|
};
|
|
23705
|
-
RoughCanvasArcRender = __decorate$
|
|
23991
|
+
RoughCanvasArcRender = __decorate$15([injectable(), __param$B(0, inject(exports.DefaultCanvasArcRender)), __metadata$T("design:paramtypes", [Object])], RoughCanvasArcRender);
|
|
23706
23992
|
|
|
23707
|
-
var __decorate$
|
|
23993
|
+
var __decorate$14 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
23708
23994
|
var d,
|
|
23709
23995
|
c = arguments.length,
|
|
23710
23996
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -23782,19 +24068,19 @@
|
|
|
23782
24068
|
}), context.highPerformanceRestore(), !1;
|
|
23783
24069
|
}
|
|
23784
24070
|
};
|
|
23785
|
-
RoughCanvasAreaRender = __decorate$
|
|
24071
|
+
RoughCanvasAreaRender = __decorate$14([injectable()], RoughCanvasAreaRender);
|
|
23786
24072
|
|
|
23787
|
-
var __decorate$
|
|
24073
|
+
var __decorate$13 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
23788
24074
|
var d,
|
|
23789
24075
|
c = arguments.length,
|
|
23790
24076
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
23791
24077
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
23792
24078
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
23793
24079
|
},
|
|
23794
|
-
__metadata$
|
|
24080
|
+
__metadata$S = undefined && undefined.__metadata || function (k, v) {
|
|
23795
24081
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
23796
24082
|
},
|
|
23797
|
-
__param$
|
|
24083
|
+
__param$A = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
23798
24084
|
return function (target, key) {
|
|
23799
24085
|
decorator(target, key, paramIndex);
|
|
23800
24086
|
};
|
|
@@ -23831,9 +24117,9 @@
|
|
|
23831
24117
|
});
|
|
23832
24118
|
}
|
|
23833
24119
|
};
|
|
23834
|
-
RoughCanvasCircleRender = __decorate$
|
|
24120
|
+
RoughCanvasCircleRender = __decorate$13([injectable(), __param$A(0, inject(exports.DefaultCanvasCircleRender)), __metadata$S("design:paramtypes", [Object])], RoughCanvasCircleRender);
|
|
23835
24121
|
|
|
23836
|
-
var __decorate$
|
|
24122
|
+
var __decorate$12 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
23837
24123
|
var d,
|
|
23838
24124
|
c = arguments.length,
|
|
23839
24125
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -23912,19 +24198,19 @@
|
|
|
23912
24198
|
}), context.highPerformanceRestore(), !1;
|
|
23913
24199
|
}
|
|
23914
24200
|
};
|
|
23915
|
-
RoughCanvasLineRender = __decorate$
|
|
24201
|
+
RoughCanvasLineRender = __decorate$12([injectable()], RoughCanvasLineRender);
|
|
23916
24202
|
|
|
23917
|
-
var __decorate$
|
|
24203
|
+
var __decorate$11 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
23918
24204
|
var d,
|
|
23919
24205
|
c = arguments.length,
|
|
23920
24206
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
23921
24207
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
23922
24208
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
23923
24209
|
},
|
|
23924
|
-
__metadata$
|
|
24210
|
+
__metadata$R = undefined && undefined.__metadata || function (k, v) {
|
|
23925
24211
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
23926
24212
|
},
|
|
23927
|
-
__param$
|
|
24213
|
+
__param$z = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
23928
24214
|
return function (target, key) {
|
|
23929
24215
|
decorator(target, key, paramIndex);
|
|
23930
24216
|
};
|
|
@@ -23998,19 +24284,19 @@
|
|
|
23998
24284
|
}), context.highPerformanceRestore();
|
|
23999
24285
|
}
|
|
24000
24286
|
};
|
|
24001
|
-
RoughCanvasPathRender = __decorate$
|
|
24287
|
+
RoughCanvasPathRender = __decorate$11([injectable(), __param$z(0, inject(exports.DefaultCanvasPathRender)), __metadata$R("design:paramtypes", [Object])], RoughCanvasPathRender);
|
|
24002
24288
|
|
|
24003
|
-
var __decorate$
|
|
24289
|
+
var __decorate$10 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
24004
24290
|
var d,
|
|
24005
24291
|
c = arguments.length,
|
|
24006
24292
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
24007
24293
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
24008
24294
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
24009
24295
|
},
|
|
24010
|
-
__metadata$
|
|
24296
|
+
__metadata$Q = undefined && undefined.__metadata || function (k, v) {
|
|
24011
24297
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
24012
24298
|
},
|
|
24013
|
-
__param$
|
|
24299
|
+
__param$y = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
24014
24300
|
return function (target, key) {
|
|
24015
24301
|
decorator(target, key, paramIndex);
|
|
24016
24302
|
};
|
|
@@ -24101,19 +24387,19 @@
|
|
|
24101
24387
|
}), context.highPerformanceRestore();
|
|
24102
24388
|
}
|
|
24103
24389
|
};
|
|
24104
|
-
RoughCanvasRectRender = __decorate$
|
|
24390
|
+
RoughCanvasRectRender = __decorate$10([injectable(), __param$y(0, inject(exports.DefaultCanvasRectRender)), __metadata$Q("design:paramtypes", [Object])], RoughCanvasRectRender);
|
|
24105
24391
|
|
|
24106
|
-
var __decorate
|
|
24392
|
+
var __decorate$$ = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
24107
24393
|
var d,
|
|
24108
24394
|
c = arguments.length,
|
|
24109
24395
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
24110
24396
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
24111
24397
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
24112
24398
|
},
|
|
24113
|
-
__metadata$
|
|
24399
|
+
__metadata$P = undefined && undefined.__metadata || function (k, v) {
|
|
24114
24400
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
24115
24401
|
},
|
|
24116
|
-
__param$
|
|
24402
|
+
__param$x = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
24117
24403
|
return function (target, key) {
|
|
24118
24404
|
decorator(target, key, paramIndex);
|
|
24119
24405
|
};
|
|
@@ -24205,7 +24491,7 @@
|
|
|
24205
24491
|
if (this.canvasRenderer.drawShape) return this.canvasRenderer.drawShape(graphic, ctx, x, y, drawContext, params, fillCb, strokeCb);
|
|
24206
24492
|
}
|
|
24207
24493
|
};
|
|
24208
|
-
RoughCanvasSymbolRender = __decorate
|
|
24494
|
+
RoughCanvasSymbolRender = __decorate$$([injectable(), __param$x(0, inject(exports.DefaultCanvasSymbolRender)), __metadata$P("design:paramtypes", [Object])], RoughCanvasSymbolRender);
|
|
24209
24495
|
|
|
24210
24496
|
var _roughModule = new ContainerModule(bind => {
|
|
24211
24497
|
bind(RoughCanvasCircleRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasCircleRender), bind(RoughCanvasRectRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasRectRender), bind(RoughCanvasPathRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasPathRender), bind(RoughCanvasSymbolRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasSymbolRender), bind(RoughCanvasLineRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasLineRender), bind(RoughCanvasAreaRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasAreaRender), bind(RoughCanvasArcRender).toSelf().inSingletonScope(), bind(GraphicRender).to(RoughCanvasArcRender);
|
|
@@ -24228,7 +24514,6 @@
|
|
|
24228
24514
|
const CanvasAreaPicker = Symbol.for("CanvasAreaPicker");
|
|
24229
24515
|
const CanvasCirclePicker = Symbol.for("CanvasCirclePicker");
|
|
24230
24516
|
const CanvasImagePicker = Symbol.for("CanvasImagePicker");
|
|
24231
|
-
const CanvasGifImagePicker = Symbol.for("CanvasGifImagePicker");
|
|
24232
24517
|
const CanvasLinePicker = Symbol.for("CanvasLinePicker");
|
|
24233
24518
|
const CanvasLottiePicker = Symbol.for("CanvasLottiePicker");
|
|
24234
24519
|
const CanvasPathPicker = Symbol.for("CanvasPathPicker");
|
|
@@ -24369,11 +24654,9 @@
|
|
|
24369
24654
|
name: name,
|
|
24370
24655
|
id: id,
|
|
24371
24656
|
attribute: attribute,
|
|
24372
|
-
stateProxy: stateProxy
|
|
24373
|
-
animation: animation,
|
|
24374
|
-
timeline: timeline
|
|
24657
|
+
stateProxy: stateProxy
|
|
24375
24658
|
} = _a,
|
|
24376
|
-
props = __rest(_a, ["key", "name", "id", "attribute", "stateProxy"
|
|
24659
|
+
props = __rest(_a, ["key", "name", "id", "attribute", "stateProxy"]);
|
|
24377
24660
|
let c = type;
|
|
24378
24661
|
isString$1(type) && (c = graphicCreator[type]);
|
|
24379
24662
|
const childrenList = [];
|
|
@@ -24382,13 +24665,7 @@
|
|
|
24382
24665
|
}
|
|
24383
24666
|
children.length && flatten(1 === children.length ? children[0] : children, childrenList);
|
|
24384
24667
|
const g = "Group" === c.name ? new c(attribute) : c(config);
|
|
24385
|
-
|
|
24386
|
-
const animate = g.animate();
|
|
24387
|
-
timeline && animate.setTimeline(timeline), animation.forEach(item => {
|
|
24388
|
-
animate[item[0]](...item.slice(1));
|
|
24389
|
-
});
|
|
24390
|
-
}
|
|
24391
|
-
return g;
|
|
24668
|
+
return parseToGraphic$1(g, childrenList, props), stateProxy && (g.stateProxy = stateProxy), g;
|
|
24392
24669
|
}
|
|
24393
24670
|
function parseToGraphic$1(g, childrenList, props) {
|
|
24394
24671
|
let out,
|
|
@@ -24718,14 +24995,14 @@
|
|
|
24718
24995
|
}
|
|
24719
24996
|
}
|
|
24720
24997
|
|
|
24721
|
-
var __decorate$
|
|
24998
|
+
var __decorate$_ = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
24722
24999
|
var d,
|
|
24723
25000
|
c = arguments.length,
|
|
24724
25001
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
24725
25002
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
24726
25003
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
24727
25004
|
},
|
|
24728
|
-
__metadata$
|
|
25005
|
+
__metadata$O = undefined && undefined.__metadata || function (k, v) {
|
|
24729
25006
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
24730
25007
|
};
|
|
24731
25008
|
const outP = [0, 0, 0],
|
|
@@ -25237,16 +25514,16 @@
|
|
|
25237
25514
|
this.stack.forEach(m => matrixAllocate.free(m)), this.stack.length = 0;
|
|
25238
25515
|
}
|
|
25239
25516
|
};
|
|
25240
|
-
BrowserContext2d.env = "browser", BrowserContext2d = __decorate$
|
|
25517
|
+
BrowserContext2d.env = "browser", BrowserContext2d = __decorate$_([injectable(), __metadata$O("design:paramtypes", [Object, Number])], BrowserContext2d);
|
|
25241
25518
|
|
|
25242
|
-
var __decorate
|
|
25519
|
+
var __decorate$Z = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25243
25520
|
var d,
|
|
25244
25521
|
c = arguments.length,
|
|
25245
25522
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25246
25523
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25247
25524
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25248
25525
|
},
|
|
25249
|
-
__metadata$
|
|
25526
|
+
__metadata$N = undefined && undefined.__metadata || function (k, v) {
|
|
25250
25527
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25251
25528
|
};
|
|
25252
25529
|
let BrowserCanvas = class extends BaseCanvas {
|
|
@@ -25308,7 +25585,7 @@
|
|
|
25308
25585
|
this._context.dpr = this._dpr;
|
|
25309
25586
|
}
|
|
25310
25587
|
};
|
|
25311
|
-
BrowserCanvas.env = "browser", BrowserCanvas = __decorate
|
|
25588
|
+
BrowserCanvas.env = "browser", BrowserCanvas = __decorate$Z([injectable(), __metadata$N("design:paramtypes", [Object])], BrowserCanvas);
|
|
25312
25589
|
|
|
25313
25590
|
function createModule(CanvasConstructor, ContextConstructor) {
|
|
25314
25591
|
return new ContainerModule(bind => {
|
|
@@ -25318,17 +25595,17 @@
|
|
|
25318
25595
|
|
|
25319
25596
|
const browserCanvasModule = createModule(BrowserCanvas, BrowserContext2d);
|
|
25320
25597
|
|
|
25321
|
-
var __decorate$
|
|
25598
|
+
var __decorate$Y = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25322
25599
|
var d,
|
|
25323
25600
|
c = arguments.length,
|
|
25324
25601
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25325
25602
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25326
25603
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25327
25604
|
},
|
|
25328
|
-
__metadata$
|
|
25605
|
+
__metadata$M = undefined && undefined.__metadata || function (k, v) {
|
|
25329
25606
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25330
25607
|
},
|
|
25331
|
-
__param$
|
|
25608
|
+
__param$w = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
25332
25609
|
return function (target, key) {
|
|
25333
25610
|
decorator(target, key, paramIndex);
|
|
25334
25611
|
};
|
|
@@ -25379,9 +25656,9 @@
|
|
|
25379
25656
|
return data;
|
|
25380
25657
|
}
|
|
25381
25658
|
};
|
|
25382
|
-
DefaultCanvasPickerService = __decorate$
|
|
25659
|
+
DefaultCanvasPickerService = __decorate$Y([injectable(), __param$w(0, inject(ContributionProvider)), __param$w(0, named(CanvasPickerContribution)), __param$w(1, inject(DrawContribution)), __param$w(2, inject(ContributionProvider)), __param$w(2, named(PickItemInterceptor)), __param$w(3, inject(ContributionProvider)), __param$w(3, named(PickServiceInterceptor)), __metadata$M("design:paramtypes", [Object, Object, Object, Object])], DefaultCanvasPickerService);
|
|
25383
25660
|
|
|
25384
|
-
var __decorate$
|
|
25661
|
+
var __decorate$X = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25385
25662
|
var d,
|
|
25386
25663
|
c = arguments.length,
|
|
25387
25664
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -25396,7 +25673,7 @@
|
|
|
25396
25673
|
return !1;
|
|
25397
25674
|
}
|
|
25398
25675
|
};
|
|
25399
|
-
DefaultCanvasGroupPicker = __decorate$
|
|
25676
|
+
DefaultCanvasGroupPicker = __decorate$X([injectable()], DefaultCanvasGroupPicker);
|
|
25400
25677
|
|
|
25401
25678
|
const m$1 = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
25402
25679
|
m$1.__vloaded || (m$1.__vloaded = !0, bind(CanvasGroupPicker).to(DefaultCanvasGroupPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasGroupPicker), bindContributionProvider(bind, CanvasPickerContribution));
|
|
@@ -25412,14 +25689,14 @@
|
|
|
25412
25689
|
}
|
|
25413
25690
|
|
|
25414
25691
|
var BrowserWindowHandlerContribution_1,
|
|
25415
|
-
__decorate$
|
|
25692
|
+
__decorate$W = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25416
25693
|
var d,
|
|
25417
25694
|
c = arguments.length,
|
|
25418
25695
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25419
25696
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25420
25697
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25421
25698
|
},
|
|
25422
|
-
__metadata$
|
|
25699
|
+
__metadata$L = undefined && undefined.__metadata || function (k, v) {
|
|
25423
25700
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25424
25701
|
};
|
|
25425
25702
|
let BrowserWindowHandlerContribution = BrowserWindowHandlerContribution_1 = class extends exports.BaseWindowHandlerContribution {
|
|
@@ -25577,19 +25854,19 @@
|
|
|
25577
25854
|
return this.global.getElementTopLeft(this.canvas.nativeCanvas, baseWindow);
|
|
25578
25855
|
}
|
|
25579
25856
|
};
|
|
25580
|
-
BrowserWindowHandlerContribution.env = "browser", BrowserWindowHandlerContribution.idprefix = "visactor_window", BrowserWindowHandlerContribution.prefix_count = 0, BrowserWindowHandlerContribution = BrowserWindowHandlerContribution_1 = __decorate$
|
|
25857
|
+
BrowserWindowHandlerContribution.env = "browser", BrowserWindowHandlerContribution.idprefix = "visactor_window", BrowserWindowHandlerContribution.prefix_count = 0, BrowserWindowHandlerContribution = BrowserWindowHandlerContribution_1 = __decorate$W([injectable(), __metadata$L("design:paramtypes", [])], BrowserWindowHandlerContribution);
|
|
25581
25858
|
const browserWindowModule = new ContainerModule(bind => {
|
|
25582
25859
|
bind(BrowserWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(BrowserWindowHandlerContribution)).whenTargetNamed(BrowserWindowHandlerContribution.env);
|
|
25583
25860
|
});
|
|
25584
25861
|
|
|
25585
|
-
var __decorate$
|
|
25862
|
+
var __decorate$V = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25586
25863
|
var d,
|
|
25587
25864
|
c = arguments.length,
|
|
25588
25865
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25589
25866
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25590
25867
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25591
25868
|
},
|
|
25592
|
-
__metadata$
|
|
25869
|
+
__metadata$K = undefined && undefined.__metadata || function (k, v) {
|
|
25593
25870
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25594
25871
|
},
|
|
25595
25872
|
__awaiter$2 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
|
|
@@ -25643,7 +25920,7 @@
|
|
|
25643
25920
|
function createImageElement$1(src) {
|
|
25644
25921
|
let isSvg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : !1;
|
|
25645
25922
|
const img = document.createElement("img");
|
|
25646
|
-
if (
|
|
25923
|
+
if (img.crossOrigin = "anonymous", isSvg) {
|
|
25647
25924
|
const data = new Blob([src], {
|
|
25648
25925
|
type: "image/svg+xml"
|
|
25649
25926
|
});
|
|
@@ -25836,7 +26113,7 @@
|
|
|
25836
26113
|
return navigator.clipboard.writeText(text).then(() => {}).catch(err => {});
|
|
25837
26114
|
}
|
|
25838
26115
|
};
|
|
25839
|
-
exports.BrowserEnvContribution = __decorate$
|
|
26116
|
+
exports.BrowserEnvContribution = __decorate$V([injectable(), __metadata$K("design:paramtypes", [])], exports.BrowserEnvContribution);
|
|
25840
26117
|
|
|
25841
26118
|
const browserEnvModule = new ContainerModule(bind => {
|
|
25842
26119
|
browserEnvModule.isBrowserBound || (browserEnvModule.isBrowserBound = !0, bind(exports.BrowserEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(exports.BrowserEnvContribution));
|
|
@@ -25851,7 +26128,7 @@
|
|
|
25851
26128
|
loadBrowserEnv(container);
|
|
25852
26129
|
}
|
|
25853
26130
|
|
|
25854
|
-
var __decorate$
|
|
26131
|
+
var __decorate$U = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25855
26132
|
var d,
|
|
25856
26133
|
c = arguments.length,
|
|
25857
26134
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -25896,16 +26173,16 @@
|
|
|
25896
26173
|
return null;
|
|
25897
26174
|
}
|
|
25898
26175
|
};
|
|
25899
|
-
FeishuContext2d.env = "feishu", FeishuContext2d = __decorate$
|
|
26176
|
+
FeishuContext2d.env = "feishu", FeishuContext2d = __decorate$U([injectable()], FeishuContext2d);
|
|
25900
26177
|
|
|
25901
|
-
var __decorate$
|
|
26178
|
+
var __decorate$T = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25902
26179
|
var d,
|
|
25903
26180
|
c = arguments.length,
|
|
25904
26181
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25905
26182
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25906
26183
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25907
26184
|
},
|
|
25908
|
-
__metadata$
|
|
26185
|
+
__metadata$J = undefined && undefined.__metadata || function (k, v) {
|
|
25909
26186
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25910
26187
|
};
|
|
25911
26188
|
let FeishuCanvas = class extends BaseCanvas {
|
|
@@ -25917,21 +26194,21 @@
|
|
|
25917
26194
|
}
|
|
25918
26195
|
release() {}
|
|
25919
26196
|
};
|
|
25920
|
-
FeishuCanvas.env = "feishu", FeishuCanvas = __decorate$
|
|
26197
|
+
FeishuCanvas.env = "feishu", FeishuCanvas = __decorate$T([injectable(), __metadata$J("design:paramtypes", [Object])], FeishuCanvas);
|
|
25921
26198
|
|
|
25922
26199
|
const feishuCanvasModule = createModule(FeishuCanvas, FeishuContext2d);
|
|
25923
26200
|
|
|
25924
|
-
var __decorate$
|
|
26201
|
+
var __decorate$S = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
25925
26202
|
var d,
|
|
25926
26203
|
c = arguments.length,
|
|
25927
26204
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
25928
26205
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
25929
26206
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
25930
26207
|
},
|
|
25931
|
-
__metadata$
|
|
26208
|
+
__metadata$I = undefined && undefined.__metadata || function (k, v) {
|
|
25932
26209
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
25933
26210
|
},
|
|
25934
|
-
__param$
|
|
26211
|
+
__param$v = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
25935
26212
|
return function (target, key) {
|
|
25936
26213
|
decorator(target, key, paramIndex);
|
|
25937
26214
|
};
|
|
@@ -26067,22 +26344,22 @@
|
|
|
26067
26344
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
26068
26345
|
}
|
|
26069
26346
|
};
|
|
26070
|
-
FeishuWindowHandlerContribution.env = "feishu", FeishuWindowHandlerContribution = __decorate$
|
|
26347
|
+
FeishuWindowHandlerContribution.env = "feishu", FeishuWindowHandlerContribution = __decorate$S([injectable(), __param$v(0, inject(VGlobal)), __metadata$I("design:paramtypes", [Object])], FeishuWindowHandlerContribution);
|
|
26071
26348
|
const feishuWindowModule = new ContainerModule(bind => {
|
|
26072
26349
|
bind(FeishuWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(FeishuWindowHandlerContribution)).whenTargetNamed(FeishuWindowHandlerContribution.env);
|
|
26073
26350
|
});
|
|
26074
26351
|
|
|
26075
|
-
var __decorate$
|
|
26352
|
+
var __decorate$R = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26076
26353
|
var d,
|
|
26077
26354
|
c = arguments.length,
|
|
26078
26355
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26079
26356
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26080
26357
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26081
26358
|
},
|
|
26082
|
-
__metadata$
|
|
26359
|
+
__metadata$H = undefined && undefined.__metadata || function (k, v) {
|
|
26083
26360
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26084
26361
|
},
|
|
26085
|
-
__param$
|
|
26362
|
+
__param$u = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26086
26363
|
return function (target, key) {
|
|
26087
26364
|
decorator(target, key, paramIndex);
|
|
26088
26365
|
};
|
|
@@ -26113,7 +26390,7 @@
|
|
|
26113
26390
|
} : null;
|
|
26114
26391
|
}
|
|
26115
26392
|
};
|
|
26116
|
-
DefaultMathPickerService = __decorate$
|
|
26393
|
+
DefaultMathPickerService = __decorate$R([injectable(), __param$u(0, inject(ContributionProvider)), __param$u(0, named(MathPickerContribution)), __param$u(1, inject(ContributionProvider)), __param$u(1, named(PickItemInterceptor)), __param$u(2, inject(ContributionProvider)), __param$u(2, named(PickServiceInterceptor)), __metadata$H("design:paramtypes", [Object, Object, Object])], DefaultMathPickerService);
|
|
26117
26394
|
|
|
26118
26395
|
const m = new ContainerModule(bind => {
|
|
26119
26396
|
m.__vloaded || (m.__vloaded = !0, bindContributionProvider(bind, MathPickerContribution));
|
|
@@ -26150,17 +26427,17 @@
|
|
|
26150
26427
|
}
|
|
26151
26428
|
}
|
|
26152
26429
|
|
|
26153
|
-
var __decorate$
|
|
26430
|
+
var __decorate$Q = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26154
26431
|
var d,
|
|
26155
26432
|
c = arguments.length,
|
|
26156
26433
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26157
26434
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26158
26435
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26159
26436
|
},
|
|
26160
|
-
__metadata$
|
|
26437
|
+
__metadata$G = undefined && undefined.__metadata || function (k, v) {
|
|
26161
26438
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26162
26439
|
},
|
|
26163
|
-
__param$
|
|
26440
|
+
__param$t = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26164
26441
|
return function (target, key) {
|
|
26165
26442
|
decorator(target, key, paramIndex);
|
|
26166
26443
|
};
|
|
@@ -26170,24 +26447,24 @@
|
|
|
26170
26447
|
super(), this.canvasRenderer = canvasRenderer, this.type = "arc", this.numberType = ARC_NUMBER_TYPE;
|
|
26171
26448
|
}
|
|
26172
26449
|
};
|
|
26173
|
-
DefaultMathArcPicker = __decorate$
|
|
26450
|
+
DefaultMathArcPicker = __decorate$Q([injectable(), __param$t(0, inject(ArcRender)), __metadata$G("design:paramtypes", [Object])], DefaultMathArcPicker);
|
|
26174
26451
|
|
|
26175
26452
|
let loadArcPick$1 = !1;
|
|
26176
26453
|
const arcMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26177
26454
|
loadArcPick$1 || (loadArcPick$1 = !0, bind(MathArcPicker).to(DefaultMathArcPicker).inSingletonScope(), bind(MathPickerContribution).toService(MathArcPicker));
|
|
26178
26455
|
});
|
|
26179
26456
|
|
|
26180
|
-
var __decorate$
|
|
26457
|
+
var __decorate$P = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26181
26458
|
var d,
|
|
26182
26459
|
c = arguments.length,
|
|
26183
26460
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26184
26461
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26185
26462
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26186
26463
|
},
|
|
26187
|
-
__metadata$
|
|
26464
|
+
__metadata$F = undefined && undefined.__metadata || function (k, v) {
|
|
26188
26465
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26189
26466
|
},
|
|
26190
|
-
__param$
|
|
26467
|
+
__param$s = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26191
26468
|
return function (target, key) {
|
|
26192
26469
|
decorator(target, key, paramIndex);
|
|
26193
26470
|
};
|
|
@@ -26197,24 +26474,24 @@
|
|
|
26197
26474
|
super(), this.canvasRenderer = canvasRenderer, this.type = "area", this.numberType = AREA_NUMBER_TYPE;
|
|
26198
26475
|
}
|
|
26199
26476
|
};
|
|
26200
|
-
DefaultMathAreaPicker = __decorate$
|
|
26477
|
+
DefaultMathAreaPicker = __decorate$P([injectable(), __param$s(0, inject(AreaRender)), __metadata$F("design:paramtypes", [Object])], DefaultMathAreaPicker);
|
|
26201
26478
|
|
|
26202
26479
|
let loadAreaPick$1 = !1;
|
|
26203
26480
|
const areaMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26204
26481
|
loadAreaPick$1 || (loadAreaPick$1 = !0, bind(MathAreaPicker).to(DefaultMathAreaPicker).inSingletonScope(), bind(MathPickerContribution).toService(MathAreaPicker));
|
|
26205
26482
|
});
|
|
26206
26483
|
|
|
26207
|
-
var __decorate$
|
|
26484
|
+
var __decorate$O = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26208
26485
|
var d,
|
|
26209
26486
|
c = arguments.length,
|
|
26210
26487
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26211
26488
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26212
26489
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26213
26490
|
},
|
|
26214
|
-
__metadata$
|
|
26491
|
+
__metadata$E = undefined && undefined.__metadata || function (k, v) {
|
|
26215
26492
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26216
26493
|
},
|
|
26217
|
-
__param$
|
|
26494
|
+
__param$r = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26218
26495
|
return function (target, key) {
|
|
26219
26496
|
decorator(target, key, paramIndex);
|
|
26220
26497
|
};
|
|
@@ -26224,7 +26501,7 @@
|
|
|
26224
26501
|
super(), this.canvasRenderer = canvasRenderer, this.type = "circle", this.numberType = CIRCLE_NUMBER_TYPE;
|
|
26225
26502
|
}
|
|
26226
26503
|
};
|
|
26227
|
-
DefaultMathCirclePicker = __decorate$
|
|
26504
|
+
DefaultMathCirclePicker = __decorate$O([injectable(), __param$r(0, inject(CircleRender)), __metadata$E("design:paramtypes", [Object])], DefaultMathCirclePicker);
|
|
26228
26505
|
|
|
26229
26506
|
let loadCirclePick$1 = !1;
|
|
26230
26507
|
const circleMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -26255,17 +26532,17 @@
|
|
|
26255
26532
|
}
|
|
26256
26533
|
}
|
|
26257
26534
|
|
|
26258
|
-
var __decorate$
|
|
26535
|
+
var __decorate$N = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26259
26536
|
var d,
|
|
26260
26537
|
c = arguments.length,
|
|
26261
26538
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26262
26539
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26263
26540
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26264
26541
|
},
|
|
26265
|
-
__metadata$
|
|
26542
|
+
__metadata$D = undefined && undefined.__metadata || function (k, v) {
|
|
26266
26543
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26267
26544
|
},
|
|
26268
|
-
__param$
|
|
26545
|
+
__param$q = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26269
26546
|
return function (target, key) {
|
|
26270
26547
|
decorator(target, key, paramIndex);
|
|
26271
26548
|
};
|
|
@@ -26275,14 +26552,14 @@
|
|
|
26275
26552
|
super(), this.canvasRenderer = canvasRenderer;
|
|
26276
26553
|
}
|
|
26277
26554
|
};
|
|
26278
|
-
DefaultMathGlyphPicker = __decorate$
|
|
26555
|
+
DefaultMathGlyphPicker = __decorate$N([injectable(), __param$q(0, inject(GlyphRender)), __metadata$D("design:paramtypes", [Object])], DefaultMathGlyphPicker);
|
|
26279
26556
|
|
|
26280
26557
|
let loadGlyphPick$1 = !1;
|
|
26281
26558
|
const glyphMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26282
26559
|
loadGlyphPick$1 || (loadGlyphPick$1 = !0, bind(MathGlyphPicker).to(DefaultMathGlyphPicker).inSingletonScope(), bind(DefaultMathGlyphPicker).toService(MathGlyphPicker));
|
|
26283
26560
|
});
|
|
26284
26561
|
|
|
26285
|
-
var __decorate$
|
|
26562
|
+
var __decorate$M = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26286
26563
|
var d,
|
|
26287
26564
|
c = arguments.length,
|
|
26288
26565
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -26300,24 +26577,24 @@
|
|
|
26300
26577
|
return !!pickContext && !!image.AABBBounds.containsPoint(point);
|
|
26301
26578
|
}
|
|
26302
26579
|
};
|
|
26303
|
-
DefaultMathImagePicker = __decorate$
|
|
26580
|
+
DefaultMathImagePicker = __decorate$M([injectable()], DefaultMathImagePicker);
|
|
26304
26581
|
|
|
26305
26582
|
let loadImagePick$1 = !1;
|
|
26306
26583
|
const imageMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26307
26584
|
loadImagePick$1 || (loadImagePick$1 = !0, bind(MathImagePicker).to(DefaultMathImagePicker).inSingletonScope(), bind(DefaultMathImagePicker).toService(MathImagePicker));
|
|
26308
26585
|
});
|
|
26309
26586
|
|
|
26310
|
-
var __decorate$
|
|
26587
|
+
var __decorate$L = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26311
26588
|
var d,
|
|
26312
26589
|
c = arguments.length,
|
|
26313
26590
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26314
26591
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26315
26592
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26316
26593
|
},
|
|
26317
|
-
__metadata$
|
|
26594
|
+
__metadata$C = undefined && undefined.__metadata || function (k, v) {
|
|
26318
26595
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26319
26596
|
},
|
|
26320
|
-
__param$
|
|
26597
|
+
__param$p = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26321
26598
|
return function (target, key) {
|
|
26322
26599
|
decorator(target, key, paramIndex);
|
|
26323
26600
|
};
|
|
@@ -26327,24 +26604,24 @@
|
|
|
26327
26604
|
super(), this.canvasRenderer = canvasRenderer, this.type = "line", this.numberType = LINE_NUMBER_TYPE;
|
|
26328
26605
|
}
|
|
26329
26606
|
};
|
|
26330
|
-
DefaultMathLinePicker = __decorate$
|
|
26607
|
+
DefaultMathLinePicker = __decorate$L([injectable(), __param$p(0, inject(LineRender)), __metadata$C("design:paramtypes", [Object])], DefaultMathLinePicker);
|
|
26331
26608
|
|
|
26332
26609
|
let loadLinePick$1 = !1;
|
|
26333
26610
|
const lineMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26334
26611
|
loadLinePick$1 || (loadLinePick$1 = !0, bind(MathLinePicker).to(DefaultMathLinePicker).inSingletonScope(), bind(MathPickerContribution).toService(MathLinePicker));
|
|
26335
26612
|
});
|
|
26336
26613
|
|
|
26337
|
-
var __decorate$
|
|
26614
|
+
var __decorate$K = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26338
26615
|
var d,
|
|
26339
26616
|
c = arguments.length,
|
|
26340
26617
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26341
26618
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26342
26619
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26343
26620
|
},
|
|
26344
|
-
__metadata$
|
|
26621
|
+
__metadata$B = undefined && undefined.__metadata || function (k, v) {
|
|
26345
26622
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26346
26623
|
},
|
|
26347
|
-
__param$
|
|
26624
|
+
__param$o = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26348
26625
|
return function (target, key) {
|
|
26349
26626
|
decorator(target, key, paramIndex);
|
|
26350
26627
|
};
|
|
@@ -26354,24 +26631,24 @@
|
|
|
26354
26631
|
super(), this.canvasRenderer = canvasRenderer, this.type = "polygon", this.numberType = POLYGON_NUMBER_TYPE;
|
|
26355
26632
|
}
|
|
26356
26633
|
};
|
|
26357
|
-
DefaultMathPolygonPicker = __decorate$
|
|
26634
|
+
DefaultMathPolygonPicker = __decorate$K([injectable(), __param$o(0, inject(PolygonRender)), __metadata$B("design:paramtypes", [Object])], DefaultMathPolygonPicker);
|
|
26358
26635
|
|
|
26359
26636
|
let loadPolygonPick$1 = !1;
|
|
26360
26637
|
const polygonMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26361
26638
|
loadPolygonPick$1 || (loadPolygonPick$1 = !0, bind(MathPolygonPicker).to(DefaultMathPolygonPicker).inSingletonScope(), bind(MathPickerContribution).toService(MathPolygonPicker));
|
|
26362
26639
|
});
|
|
26363
26640
|
|
|
26364
|
-
var __decorate$
|
|
26641
|
+
var __decorate$J = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26365
26642
|
var d,
|
|
26366
26643
|
c = arguments.length,
|
|
26367
26644
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26368
26645
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26369
26646
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26370
26647
|
},
|
|
26371
|
-
__metadata$
|
|
26648
|
+
__metadata$A = undefined && undefined.__metadata || function (k, v) {
|
|
26372
26649
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26373
26650
|
},
|
|
26374
|
-
__param$
|
|
26651
|
+
__param$n = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26375
26652
|
return function (target, key) {
|
|
26376
26653
|
decorator(target, key, paramIndex);
|
|
26377
26654
|
};
|
|
@@ -26381,7 +26658,7 @@
|
|
|
26381
26658
|
super(), this.canvasRenderer = canvasRenderer, this.type = "path", this.numberType = PATH_NUMBER_TYPE;
|
|
26382
26659
|
}
|
|
26383
26660
|
};
|
|
26384
|
-
DefaultMathPathPicker = __decorate$
|
|
26661
|
+
DefaultMathPathPicker = __decorate$J([injectable(), __param$n(0, inject(PathRender)), __metadata$A("design:paramtypes", [Object])], DefaultMathPathPicker);
|
|
26385
26662
|
|
|
26386
26663
|
let loadPathPick$1 = !1;
|
|
26387
26664
|
const pathMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -26436,17 +26713,17 @@
|
|
|
26436
26713
|
}
|
|
26437
26714
|
}
|
|
26438
26715
|
|
|
26439
|
-
var __decorate$
|
|
26716
|
+
var __decorate$I = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26440
26717
|
var d,
|
|
26441
26718
|
c = arguments.length,
|
|
26442
26719
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26443
26720
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26444
26721
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26445
26722
|
},
|
|
26446
|
-
__metadata$
|
|
26723
|
+
__metadata$z = undefined && undefined.__metadata || function (k, v) {
|
|
26447
26724
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26448
26725
|
},
|
|
26449
|
-
__param$
|
|
26726
|
+
__param$m = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26450
26727
|
return function (target, key) {
|
|
26451
26728
|
decorator(target, key, paramIndex);
|
|
26452
26729
|
};
|
|
@@ -26456,7 +26733,7 @@
|
|
|
26456
26733
|
super(), this.canvasRenderer = canvasRenderer;
|
|
26457
26734
|
}
|
|
26458
26735
|
};
|
|
26459
|
-
DefaultMathRectPicker = __decorate$
|
|
26736
|
+
DefaultMathRectPicker = __decorate$I([injectable(), __param$m(0, inject(RectRender)), __metadata$z("design:paramtypes", [Object])], DefaultMathRectPicker);
|
|
26460
26737
|
|
|
26461
26738
|
let loadRectPick$1 = !1;
|
|
26462
26739
|
const rectMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -26468,17 +26745,17 @@
|
|
|
26468
26745
|
loadRichTextPick || (loadRichTextPick = !0, bind(MathImagePicker).to(DefaultMathImagePicker).inSingletonScope(), bind(DefaultMathImagePicker).toService(MathImagePicker));
|
|
26469
26746
|
});
|
|
26470
26747
|
|
|
26471
|
-
var __decorate$
|
|
26748
|
+
var __decorate$H = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26472
26749
|
var d,
|
|
26473
26750
|
c = arguments.length,
|
|
26474
26751
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26475
26752
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26476
26753
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26477
26754
|
},
|
|
26478
|
-
__metadata$
|
|
26755
|
+
__metadata$y = undefined && undefined.__metadata || function (k, v) {
|
|
26479
26756
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26480
26757
|
},
|
|
26481
|
-
__param$
|
|
26758
|
+
__param$l = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26482
26759
|
return function (target, key) {
|
|
26483
26760
|
decorator(target, key, paramIndex);
|
|
26484
26761
|
};
|
|
@@ -26488,14 +26765,14 @@
|
|
|
26488
26765
|
super(), this.canvasRenderer = canvasRenderer, this.type = "symbol", this.numberType = SYMBOL_NUMBER_TYPE;
|
|
26489
26766
|
}
|
|
26490
26767
|
};
|
|
26491
|
-
DefaultMathSymbolPicker = __decorate$
|
|
26768
|
+
DefaultMathSymbolPicker = __decorate$H([injectable(), __param$l(0, inject(SymbolRender)), __metadata$y("design:paramtypes", [Object])], DefaultMathSymbolPicker);
|
|
26492
26769
|
|
|
26493
26770
|
let loadSymbolPick$1 = !1;
|
|
26494
26771
|
const symbolMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
26495
26772
|
loadSymbolPick$1 || (loadSymbolPick$1 = !0, bind(MathSymbolPicker).to(DefaultMathSymbolPicker).inSingletonScope(), bind(MathPickerContribution).toService(MathSymbolPicker));
|
|
26496
26773
|
});
|
|
26497
26774
|
|
|
26498
|
-
var __decorate$
|
|
26775
|
+
var __decorate$G = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26499
26776
|
var d,
|
|
26500
26777
|
c = arguments.length,
|
|
26501
26778
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -26510,7 +26787,7 @@
|
|
|
26510
26787
|
return !!text.AABBBounds.containsPoint(point);
|
|
26511
26788
|
}
|
|
26512
26789
|
};
|
|
26513
|
-
DefaultMathTextPicker = __decorate$
|
|
26790
|
+
DefaultMathTextPicker = __decorate$G([injectable()], DefaultMathTextPicker);
|
|
26514
26791
|
|
|
26515
26792
|
let loadTextPick$1 = !1;
|
|
26516
26793
|
const textMathPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -26593,14 +26870,14 @@
|
|
|
26593
26870
|
}
|
|
26594
26871
|
}
|
|
26595
26872
|
|
|
26596
|
-
var __decorate$
|
|
26873
|
+
var __decorate$F = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26597
26874
|
var d,
|
|
26598
26875
|
c = arguments.length,
|
|
26599
26876
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26600
26877
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26601
26878
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26602
26879
|
},
|
|
26603
|
-
__metadata$
|
|
26880
|
+
__metadata$x = undefined && undefined.__metadata || function (k, v) {
|
|
26604
26881
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26605
26882
|
};
|
|
26606
26883
|
function makeUpCanvas$4(domref, canvasIdLists, canvasMap, freeCanvasIdx, freeCanvasList, pixelRatio) {
|
|
@@ -26682,7 +26959,7 @@
|
|
|
26682
26959
|
return null === (_a = null == event ? void 0 : event.type) || void 0 === _a || _a.startsWith("mouse"), event;
|
|
26683
26960
|
}
|
|
26684
26961
|
};
|
|
26685
|
-
FeishuEnvContribution = __decorate$
|
|
26962
|
+
FeishuEnvContribution = __decorate$F([injectable(), __metadata$x("design:paramtypes", [])], FeishuEnvContribution);
|
|
26686
26963
|
|
|
26687
26964
|
const feishuEnvModule = new ContainerModule(bind => {
|
|
26688
26965
|
feishuEnvModule.isFeishuBound || (feishuEnvModule.isFeishuBound = !0, bind(FeishuEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(FeishuEnvContribution));
|
|
@@ -26697,7 +26974,7 @@
|
|
|
26697
26974
|
loadFeishuEnv(container);
|
|
26698
26975
|
}
|
|
26699
26976
|
|
|
26700
|
-
var __decorate$
|
|
26977
|
+
var __decorate$E = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26701
26978
|
var d,
|
|
26702
26979
|
c = arguments.length,
|
|
26703
26980
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -26758,16 +27035,16 @@
|
|
|
26758
27035
|
}));
|
|
26759
27036
|
}
|
|
26760
27037
|
};
|
|
26761
|
-
LynxContext2d.env = "lynx", LynxContext2d = __decorate$
|
|
27038
|
+
LynxContext2d.env = "lynx", LynxContext2d = __decorate$E([injectable()], LynxContext2d);
|
|
26762
27039
|
|
|
26763
|
-
var __decorate$
|
|
27040
|
+
var __decorate$D = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26764
27041
|
var d,
|
|
26765
27042
|
c = arguments.length,
|
|
26766
27043
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26767
27044
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26768
27045
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26769
27046
|
},
|
|
26770
|
-
__metadata$
|
|
27047
|
+
__metadata$w = undefined && undefined.__metadata || function (k, v) {
|
|
26771
27048
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26772
27049
|
};
|
|
26773
27050
|
let LynxCanvas = class extends BaseCanvas {
|
|
@@ -26783,19 +27060,19 @@
|
|
|
26783
27060
|
}
|
|
26784
27061
|
release() {}
|
|
26785
27062
|
};
|
|
26786
|
-
LynxCanvas.env = "lynx", LynxCanvas = __decorate$
|
|
27063
|
+
LynxCanvas.env = "lynx", LynxCanvas = __decorate$D([injectable(), __metadata$w("design:paramtypes", [Object])], LynxCanvas);
|
|
26787
27064
|
|
|
26788
|
-
var __decorate$
|
|
27065
|
+
var __decorate$C = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26789
27066
|
var d,
|
|
26790
27067
|
c = arguments.length,
|
|
26791
27068
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26792
27069
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26793
27070
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26794
27071
|
},
|
|
26795
|
-
__metadata$
|
|
27072
|
+
__metadata$v = undefined && undefined.__metadata || function (k, v) {
|
|
26796
27073
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26797
27074
|
},
|
|
26798
|
-
__param$
|
|
27075
|
+
__param$k = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
26799
27076
|
return function (target, key) {
|
|
26800
27077
|
decorator(target, key, paramIndex);
|
|
26801
27078
|
};
|
|
@@ -26933,21 +27210,21 @@
|
|
|
26933
27210
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
26934
27211
|
}
|
|
26935
27212
|
};
|
|
26936
|
-
LynxWindowHandlerContribution.env = "lynx", LynxWindowHandlerContribution = __decorate$
|
|
27213
|
+
LynxWindowHandlerContribution.env = "lynx", LynxWindowHandlerContribution = __decorate$C([injectable(), __param$k(0, inject(VGlobal)), __metadata$v("design:paramtypes", [Object])], LynxWindowHandlerContribution);
|
|
26937
27214
|
const lynxWindowModule = new ContainerModule(bind => {
|
|
26938
27215
|
bind(LynxWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(LynxWindowHandlerContribution)).whenTargetNamed(LynxWindowHandlerContribution.env);
|
|
26939
27216
|
});
|
|
26940
27217
|
|
|
26941
27218
|
const lynxCanvasModule = createModule(LynxCanvas, LynxContext2d);
|
|
26942
27219
|
|
|
26943
|
-
var __decorate$
|
|
27220
|
+
var __decorate$B = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
26944
27221
|
var d,
|
|
26945
27222
|
c = arguments.length,
|
|
26946
27223
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
26947
27224
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
26948
27225
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
26949
27226
|
},
|
|
26950
|
-
__metadata$
|
|
27227
|
+
__metadata$u = undefined && undefined.__metadata || function (k, v) {
|
|
26951
27228
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
26952
27229
|
};
|
|
26953
27230
|
let ng = !1;
|
|
@@ -27057,7 +27334,7 @@
|
|
|
27057
27334
|
}
|
|
27058
27335
|
release() {}
|
|
27059
27336
|
};
|
|
27060
|
-
LynxEnvContribution = __decorate$
|
|
27337
|
+
LynxEnvContribution = __decorate$B([injectable(), __metadata$u("design:paramtypes", [])], LynxEnvContribution);
|
|
27061
27338
|
|
|
27062
27339
|
const lynxEnvModule = new ContainerModule(bind => {
|
|
27063
27340
|
lynxEnvModule.isLynxBound || (lynxEnvModule.isLynxBound = !0, bind(LynxEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(LynxEnvContribution));
|
|
@@ -27072,14 +27349,14 @@
|
|
|
27072
27349
|
loadLynxEnv(container);
|
|
27073
27350
|
}
|
|
27074
27351
|
|
|
27075
|
-
var __decorate$
|
|
27352
|
+
var __decorate$A = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27076
27353
|
var d,
|
|
27077
27354
|
c = arguments.length,
|
|
27078
27355
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27079
27356
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27080
27357
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27081
27358
|
},
|
|
27082
|
-
__metadata$
|
|
27359
|
+
__metadata$t = undefined && undefined.__metadata || function (k, v) {
|
|
27083
27360
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27084
27361
|
};
|
|
27085
27362
|
let NodeContext2d = class extends BrowserContext2d {
|
|
@@ -27091,16 +27368,16 @@
|
|
|
27091
27368
|
}
|
|
27092
27369
|
release() {}
|
|
27093
27370
|
};
|
|
27094
|
-
NodeContext2d.env = "node", NodeContext2d = __decorate$
|
|
27371
|
+
NodeContext2d.env = "node", NodeContext2d = __decorate$A([injectable(), __metadata$t("design:paramtypes", [Object, Number])], NodeContext2d);
|
|
27095
27372
|
|
|
27096
|
-
var __decorate$
|
|
27373
|
+
var __decorate$z = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27097
27374
|
var d,
|
|
27098
27375
|
c = arguments.length,
|
|
27099
27376
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27100
27377
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27101
27378
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27102
27379
|
},
|
|
27103
|
-
__metadata$
|
|
27380
|
+
__metadata$s = undefined && undefined.__metadata || function (k, v) {
|
|
27104
27381
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27105
27382
|
};
|
|
27106
27383
|
let NodeCanvas = class extends BaseCanvas {
|
|
@@ -27114,21 +27391,21 @@
|
|
|
27114
27391
|
this._nativeCanvas.release && isFunction$1(this._nativeCanvas.release) && this._nativeCanvas.release();
|
|
27115
27392
|
}
|
|
27116
27393
|
};
|
|
27117
|
-
NodeCanvas.env = "node", NodeCanvas = __decorate$
|
|
27394
|
+
NodeCanvas.env = "node", NodeCanvas = __decorate$z([injectable(), __metadata$s("design:paramtypes", [Object])], NodeCanvas);
|
|
27118
27395
|
|
|
27119
27396
|
const nodeCanvasModule = createModule(NodeCanvas, NodeContext2d);
|
|
27120
27397
|
|
|
27121
|
-
var __decorate$
|
|
27398
|
+
var __decorate$y = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27122
27399
|
var d,
|
|
27123
27400
|
c = arguments.length,
|
|
27124
27401
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27125
27402
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27126
27403
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27127
27404
|
},
|
|
27128
|
-
__metadata$
|
|
27405
|
+
__metadata$r = undefined && undefined.__metadata || function (k, v) {
|
|
27129
27406
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27130
27407
|
},
|
|
27131
|
-
__param$
|
|
27408
|
+
__param$j = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
27132
27409
|
return function (target, key) {
|
|
27133
27410
|
decorator(target, key, paramIndex);
|
|
27134
27411
|
};
|
|
@@ -27219,12 +27496,12 @@
|
|
|
27219
27496
|
}
|
|
27220
27497
|
clearViewBox(color) {}
|
|
27221
27498
|
};
|
|
27222
|
-
NodeWindowHandlerContribution.env = "node", NodeWindowHandlerContribution = __decorate$
|
|
27499
|
+
NodeWindowHandlerContribution.env = "node", NodeWindowHandlerContribution = __decorate$y([injectable(), __param$j(0, inject(VGlobal)), __metadata$r("design:paramtypes", [Object])], NodeWindowHandlerContribution);
|
|
27223
27500
|
const nodeWindowModule = new ContainerModule(bind => {
|
|
27224
27501
|
bind(NodeWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(NodeWindowHandlerContribution)).whenTargetNamed(NodeWindowHandlerContribution.env);
|
|
27225
27502
|
});
|
|
27226
27503
|
|
|
27227
|
-
var __decorate$
|
|
27504
|
+
var __decorate$x = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27228
27505
|
var d,
|
|
27229
27506
|
c = arguments.length,
|
|
27230
27507
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -27310,7 +27587,7 @@
|
|
|
27310
27587
|
release() {}
|
|
27311
27588
|
createOffscreenCanvas(params) {}
|
|
27312
27589
|
};
|
|
27313
|
-
NodeEnvContribution = __decorate$
|
|
27590
|
+
NodeEnvContribution = __decorate$x([injectable()], NodeEnvContribution);
|
|
27314
27591
|
|
|
27315
27592
|
const nodeEnvModule = new ContainerModule(bind => {
|
|
27316
27593
|
nodeEnvModule.isNodeBound || (nodeEnvModule.isNodeBound = !0, bind(NodeEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(NodeEnvContribution));
|
|
@@ -27324,7 +27601,7 @@
|
|
|
27324
27601
|
loadNodeEnv(container);
|
|
27325
27602
|
}
|
|
27326
27603
|
|
|
27327
|
-
var __decorate$
|
|
27604
|
+
var __decorate$w = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27328
27605
|
var d,
|
|
27329
27606
|
c = arguments.length,
|
|
27330
27607
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -27413,16 +27690,16 @@
|
|
|
27413
27690
|
return this.nativeContext.createCircularGradient && this.nativeContext.createCircularGradient(x0, y0, r0, x1, y1, r1);
|
|
27414
27691
|
}
|
|
27415
27692
|
};
|
|
27416
|
-
TaroContext2d.env = "taro", TaroContext2d = __decorate$
|
|
27693
|
+
TaroContext2d.env = "taro", TaroContext2d = __decorate$w([injectable()], TaroContext2d);
|
|
27417
27694
|
|
|
27418
|
-
var __decorate$
|
|
27695
|
+
var __decorate$v = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27419
27696
|
var d,
|
|
27420
27697
|
c = arguments.length,
|
|
27421
27698
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27422
27699
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27423
27700
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27424
27701
|
},
|
|
27425
|
-
__metadata$
|
|
27702
|
+
__metadata$q = undefined && undefined.__metadata || function (k, v) {
|
|
27426
27703
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27427
27704
|
};
|
|
27428
27705
|
let TaroCanvas = class extends BaseCanvas {
|
|
@@ -27434,21 +27711,21 @@
|
|
|
27434
27711
|
}
|
|
27435
27712
|
release() {}
|
|
27436
27713
|
};
|
|
27437
|
-
TaroCanvas.env = "taro", TaroCanvas = __decorate$
|
|
27714
|
+
TaroCanvas.env = "taro", TaroCanvas = __decorate$v([injectable(), __metadata$q("design:paramtypes", [Object])], TaroCanvas);
|
|
27438
27715
|
|
|
27439
27716
|
const taroCanvasModule = createModule(TaroCanvas, TaroContext2d);
|
|
27440
27717
|
|
|
27441
|
-
var __decorate$
|
|
27718
|
+
var __decorate$u = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27442
27719
|
var d,
|
|
27443
27720
|
c = arguments.length,
|
|
27444
27721
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27445
27722
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27446
27723
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27447
27724
|
},
|
|
27448
|
-
__metadata$
|
|
27725
|
+
__metadata$p = undefined && undefined.__metadata || function (k, v) {
|
|
27449
27726
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27450
27727
|
},
|
|
27451
|
-
__param$
|
|
27728
|
+
__param$i = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
27452
27729
|
return function (target, key) {
|
|
27453
27730
|
decorator(target, key, paramIndex);
|
|
27454
27731
|
};
|
|
@@ -27594,19 +27871,19 @@
|
|
|
27594
27871
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
27595
27872
|
}
|
|
27596
27873
|
};
|
|
27597
|
-
TaroWindowHandlerContribution.env = "taro", TaroWindowHandlerContribution = __decorate$
|
|
27874
|
+
TaroWindowHandlerContribution.env = "taro", TaroWindowHandlerContribution = __decorate$u([injectable(), __param$i(0, inject(VGlobal)), __metadata$p("design:paramtypes", [Object])], TaroWindowHandlerContribution);
|
|
27598
27875
|
const taroWindowModule = new ContainerModule(bind => {
|
|
27599
27876
|
bind(TaroWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(TaroWindowHandlerContribution)).whenTargetNamed(TaroWindowHandlerContribution.env);
|
|
27600
27877
|
});
|
|
27601
27878
|
|
|
27602
|
-
var __decorate$
|
|
27879
|
+
var __decorate$t = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27603
27880
|
var d,
|
|
27604
27881
|
c = arguments.length,
|
|
27605
27882
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27606
27883
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27607
27884
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27608
27885
|
},
|
|
27609
|
-
__metadata$
|
|
27886
|
+
__metadata$o = undefined && undefined.__metadata || function (k, v) {
|
|
27610
27887
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27611
27888
|
};
|
|
27612
27889
|
function makeUpCanvas$2(domref, canvasIdLists, canvasMap, freeCanvasIdx, freeCanvasList, taro, dpr) {
|
|
@@ -27703,7 +27980,7 @@
|
|
|
27703
27980
|
}
|
|
27704
27981
|
release() {}
|
|
27705
27982
|
};
|
|
27706
|
-
TaroEnvContribution = __decorate$
|
|
27983
|
+
TaroEnvContribution = __decorate$t([injectable(), __metadata$o("design:paramtypes", [])], TaroEnvContribution);
|
|
27707
27984
|
|
|
27708
27985
|
const taroEnvModule = new ContainerModule(bind => {
|
|
27709
27986
|
taroEnvModule.isTaroBound || (taroEnvModule.isTaroBound = !0, bind(TaroEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(TaroEnvContribution));
|
|
@@ -27718,7 +27995,7 @@
|
|
|
27718
27995
|
loadTaroEnv(container);
|
|
27719
27996
|
}
|
|
27720
27997
|
|
|
27721
|
-
var __decorate$
|
|
27998
|
+
var __decorate$s = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27722
27999
|
var d,
|
|
27723
28000
|
c = arguments.length,
|
|
27724
28001
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -27731,16 +28008,16 @@
|
|
|
27731
28008
|
return null;
|
|
27732
28009
|
}
|
|
27733
28010
|
};
|
|
27734
|
-
WxContext2d.env = "wx", WxContext2d = __decorate$
|
|
28011
|
+
WxContext2d.env = "wx", WxContext2d = __decorate$s([injectable()], WxContext2d);
|
|
27735
28012
|
|
|
27736
|
-
var __decorate$
|
|
28013
|
+
var __decorate$r = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27737
28014
|
var d,
|
|
27738
28015
|
c = arguments.length,
|
|
27739
28016
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27740
28017
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27741
28018
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27742
28019
|
},
|
|
27743
|
-
__metadata$
|
|
28020
|
+
__metadata$n = undefined && undefined.__metadata || function (k, v) {
|
|
27744
28021
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27745
28022
|
};
|
|
27746
28023
|
let WxCanvas = class extends BaseCanvas {
|
|
@@ -27752,21 +28029,21 @@
|
|
|
27752
28029
|
}
|
|
27753
28030
|
release() {}
|
|
27754
28031
|
};
|
|
27755
|
-
WxCanvas.env = "wx", WxCanvas = __decorate$
|
|
28032
|
+
WxCanvas.env = "wx", WxCanvas = __decorate$r([injectable(), __metadata$n("design:paramtypes", [Object])], WxCanvas);
|
|
27756
28033
|
|
|
27757
28034
|
const wxCanvasModule = createModule(WxCanvas, WxContext2d);
|
|
27758
28035
|
|
|
27759
|
-
var __decorate$
|
|
28036
|
+
var __decorate$q = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27760
28037
|
var d,
|
|
27761
28038
|
c = arguments.length,
|
|
27762
28039
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27763
28040
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27764
28041
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27765
28042
|
},
|
|
27766
|
-
__metadata$
|
|
28043
|
+
__metadata$m = undefined && undefined.__metadata || function (k, v) {
|
|
27767
28044
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27768
28045
|
},
|
|
27769
|
-
__param$
|
|
28046
|
+
__param$h = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
27770
28047
|
return function (target, key) {
|
|
27771
28048
|
decorator(target, key, paramIndex);
|
|
27772
28049
|
};
|
|
@@ -27903,19 +28180,19 @@
|
|
|
27903
28180
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
27904
28181
|
}
|
|
27905
28182
|
};
|
|
27906
|
-
WxWindowHandlerContribution.env = "wx", WxWindowHandlerContribution = __decorate$
|
|
28183
|
+
WxWindowHandlerContribution.env = "wx", WxWindowHandlerContribution = __decorate$q([injectable(), __param$h(0, inject(VGlobal)), __metadata$m("design:paramtypes", [Object])], WxWindowHandlerContribution);
|
|
27907
28184
|
const wxWindowModule = new ContainerModule(bind => {
|
|
27908
28185
|
bind(WxWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(WxWindowHandlerContribution)).whenTargetNamed(WxWindowHandlerContribution.env);
|
|
27909
28186
|
});
|
|
27910
28187
|
|
|
27911
|
-
var __decorate$
|
|
28188
|
+
var __decorate$p = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
27912
28189
|
var d,
|
|
27913
28190
|
c = arguments.length,
|
|
27914
28191
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
27915
28192
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
27916
28193
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
27917
28194
|
},
|
|
27918
|
-
__metadata$
|
|
28195
|
+
__metadata$l = undefined && undefined.__metadata || function (k, v) {
|
|
27919
28196
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
27920
28197
|
},
|
|
27921
28198
|
__awaiter$1 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
|
|
@@ -28029,7 +28306,7 @@
|
|
|
28029
28306
|
return null === (_a = null == event ? void 0 : event.type) || void 0 === _a || _a.startsWith("mouse"), event;
|
|
28030
28307
|
}
|
|
28031
28308
|
};
|
|
28032
|
-
WxEnvContribution = __decorate$
|
|
28309
|
+
WxEnvContribution = __decorate$p([injectable(), __metadata$l("design:paramtypes", [])], WxEnvContribution);
|
|
28033
28310
|
|
|
28034
28311
|
const wxEnvModule = new ContainerModule(bind => {
|
|
28035
28312
|
wxEnvModule._isWxBound || (wxEnvModule._isWxBound = !0, bind(WxEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(WxEnvContribution));
|
|
@@ -28057,7 +28334,7 @@
|
|
|
28057
28334
|
loadAllEnv(container);
|
|
28058
28335
|
}
|
|
28059
28336
|
|
|
28060
|
-
var __decorate$
|
|
28337
|
+
var __decorate$o = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28061
28338
|
var d,
|
|
28062
28339
|
c = arguments.length,
|
|
28063
28340
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -28065,16 +28342,16 @@
|
|
|
28065
28342
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28066
28343
|
};
|
|
28067
28344
|
let TTContext2d = class extends FeishuContext2d {};
|
|
28068
|
-
TTContext2d.env = "tt", TTContext2d = __decorate$
|
|
28345
|
+
TTContext2d.env = "tt", TTContext2d = __decorate$o([injectable()], TTContext2d);
|
|
28069
28346
|
|
|
28070
|
-
var __decorate$
|
|
28347
|
+
var __decorate$n = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28071
28348
|
var d,
|
|
28072
28349
|
c = arguments.length,
|
|
28073
28350
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28074
28351
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28075
28352
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28076
28353
|
},
|
|
28077
|
-
__metadata$
|
|
28354
|
+
__metadata$k = undefined && undefined.__metadata || function (k, v) {
|
|
28078
28355
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28079
28356
|
};
|
|
28080
28357
|
let TTCanvas = class extends BaseCanvas {
|
|
@@ -28086,21 +28363,21 @@
|
|
|
28086
28363
|
}
|
|
28087
28364
|
release() {}
|
|
28088
28365
|
};
|
|
28089
|
-
TTCanvas.env = "tt", TTCanvas = __decorate$
|
|
28366
|
+
TTCanvas.env = "tt", TTCanvas = __decorate$n([injectable(), __metadata$k("design:paramtypes", [Object])], TTCanvas);
|
|
28090
28367
|
|
|
28091
28368
|
const ttCanvasModule = createModule(TTCanvas, TTContext2d);
|
|
28092
28369
|
|
|
28093
|
-
var __decorate$
|
|
28370
|
+
var __decorate$m = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28094
28371
|
var d,
|
|
28095
28372
|
c = arguments.length,
|
|
28096
28373
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28097
28374
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28098
28375
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28099
28376
|
},
|
|
28100
|
-
__metadata$
|
|
28377
|
+
__metadata$j = undefined && undefined.__metadata || function (k, v) {
|
|
28101
28378
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28102
28379
|
},
|
|
28103
|
-
__param$
|
|
28380
|
+
__param$g = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28104
28381
|
return function (target, key) {
|
|
28105
28382
|
decorator(target, key, paramIndex);
|
|
28106
28383
|
};
|
|
@@ -28236,19 +28513,19 @@
|
|
|
28236
28513
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
28237
28514
|
}
|
|
28238
28515
|
};
|
|
28239
|
-
TTWindowHandlerContribution.env = "tt", TTWindowHandlerContribution = __decorate$
|
|
28516
|
+
TTWindowHandlerContribution.env = "tt", TTWindowHandlerContribution = __decorate$m([injectable(), __param$g(0, inject(VGlobal)), __metadata$j("design:paramtypes", [Object])], TTWindowHandlerContribution);
|
|
28240
28517
|
const ttWindowModule = new ContainerModule(bind => {
|
|
28241
28518
|
bind(TTWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(TTWindowHandlerContribution)).whenTargetNamed(TTWindowHandlerContribution.env);
|
|
28242
28519
|
});
|
|
28243
28520
|
|
|
28244
|
-
var __decorate$
|
|
28521
|
+
var __decorate$l = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28245
28522
|
var d,
|
|
28246
28523
|
c = arguments.length,
|
|
28247
28524
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28248
28525
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28249
28526
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28250
28527
|
},
|
|
28251
|
-
__metadata$
|
|
28528
|
+
__metadata$i = undefined && undefined.__metadata || function (k, v) {
|
|
28252
28529
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28253
28530
|
},
|
|
28254
28531
|
__awaiter = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
|
|
@@ -28358,7 +28635,7 @@
|
|
|
28358
28635
|
return null === (_a = null == event ? void 0 : event.type) || void 0 === _a || _a.startsWith("mouse"), event;
|
|
28359
28636
|
}
|
|
28360
28637
|
};
|
|
28361
|
-
TTEnvContribution = __decorate$
|
|
28638
|
+
TTEnvContribution = __decorate$l([injectable(), __metadata$i("design:paramtypes", [])], TTEnvContribution);
|
|
28362
28639
|
|
|
28363
28640
|
const ttEnvModule = new ContainerModule(bind => {
|
|
28364
28641
|
ttEnvModule.isTTBound || (ttEnvModule.isTTBound = !0, bind(TTEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(TTEnvContribution));
|
|
@@ -28373,7 +28650,7 @@
|
|
|
28373
28650
|
loadTTEnv(container);
|
|
28374
28651
|
}
|
|
28375
28652
|
|
|
28376
|
-
var __decorate$
|
|
28653
|
+
var __decorate$k = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28377
28654
|
var d,
|
|
28378
28655
|
c = arguments.length,
|
|
28379
28656
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -28458,16 +28735,16 @@
|
|
|
28458
28735
|
}
|
|
28459
28736
|
draw() {}
|
|
28460
28737
|
};
|
|
28461
|
-
HarmonyContext2d.env = "harmony", HarmonyContext2d = __decorate$
|
|
28738
|
+
HarmonyContext2d.env = "harmony", HarmonyContext2d = __decorate$k([injectable()], HarmonyContext2d);
|
|
28462
28739
|
|
|
28463
|
-
var __decorate$
|
|
28740
|
+
var __decorate$j = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28464
28741
|
var d,
|
|
28465
28742
|
c = arguments.length,
|
|
28466
28743
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28467
28744
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28468
28745
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28469
28746
|
},
|
|
28470
|
-
__metadata$
|
|
28747
|
+
__metadata$h = undefined && undefined.__metadata || function (k, v) {
|
|
28471
28748
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28472
28749
|
};
|
|
28473
28750
|
let HarmonyCanvas = class extends BaseCanvas {
|
|
@@ -28480,19 +28757,19 @@
|
|
|
28480
28757
|
resize(width, height) {}
|
|
28481
28758
|
release() {}
|
|
28482
28759
|
};
|
|
28483
|
-
HarmonyCanvas.env = "harmony", HarmonyCanvas = __decorate$
|
|
28760
|
+
HarmonyCanvas.env = "harmony", HarmonyCanvas = __decorate$j([injectable(), __metadata$h("design:paramtypes", [Object])], HarmonyCanvas);
|
|
28484
28761
|
|
|
28485
|
-
var __decorate$
|
|
28762
|
+
var __decorate$i = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28486
28763
|
var d,
|
|
28487
28764
|
c = arguments.length,
|
|
28488
28765
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28489
28766
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28490
28767
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28491
28768
|
},
|
|
28492
|
-
__metadata$
|
|
28769
|
+
__metadata$g = undefined && undefined.__metadata || function (k, v) {
|
|
28493
28770
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28494
28771
|
},
|
|
28495
|
-
__param$
|
|
28772
|
+
__param$f = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28496
28773
|
return function (target, key) {
|
|
28497
28774
|
decorator(target, key, paramIndex);
|
|
28498
28775
|
};
|
|
@@ -28629,21 +28906,21 @@
|
|
|
28629
28906
|
context.nativeContext.save(), context.nativeContext.setTransform(dpr, 0, 0, dpr, 0, 0), context.clearRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1), color && (context.fillStyle = color, context.fillRect(vb.x1, vb.y1, vb.x2 - vb.x1, vb.y2 - vb.y1)), context.nativeContext.restore();
|
|
28630
28907
|
}
|
|
28631
28908
|
};
|
|
28632
|
-
HarmonyWindowHandlerContribution.env = "harmony", HarmonyWindowHandlerContribution = __decorate$
|
|
28909
|
+
HarmonyWindowHandlerContribution.env = "harmony", HarmonyWindowHandlerContribution = __decorate$i([injectable(), __param$f(0, inject(VGlobal)), __metadata$g("design:paramtypes", [Object])], HarmonyWindowHandlerContribution);
|
|
28633
28910
|
const harmonyWindowModule = new ContainerModule(bind => {
|
|
28634
28911
|
bind(HarmonyWindowHandlerContribution).toSelf(), bind(WindowHandlerContribution).toDynamicValue(ctx => ctx.container.get(HarmonyWindowHandlerContribution)).whenTargetNamed(HarmonyWindowHandlerContribution.env);
|
|
28635
28912
|
});
|
|
28636
28913
|
|
|
28637
28914
|
const harmonyCanvasModule = createModule(HarmonyCanvas, HarmonyContext2d);
|
|
28638
28915
|
|
|
28639
|
-
var __decorate$
|
|
28916
|
+
var __decorate$h = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28640
28917
|
var d,
|
|
28641
28918
|
c = arguments.length,
|
|
28642
28919
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28643
28920
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28644
28921
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28645
28922
|
},
|
|
28646
|
-
__metadata$
|
|
28923
|
+
__metadata$f = undefined && undefined.__metadata || function (k, v) {
|
|
28647
28924
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28648
28925
|
};
|
|
28649
28926
|
function createCanvas(width, height, id) {
|
|
@@ -28724,7 +29001,7 @@
|
|
|
28724
29001
|
}
|
|
28725
29002
|
release() {}
|
|
28726
29003
|
};
|
|
28727
|
-
HarmonyEnvContribution = __decorate$
|
|
29004
|
+
HarmonyEnvContribution = __decorate$h([injectable(), __metadata$f("design:paramtypes", [])], HarmonyEnvContribution);
|
|
28728
29005
|
|
|
28729
29006
|
const harmonyEnvModule = new ContainerModule(bind => {
|
|
28730
29007
|
harmonyEnvModule.isHarmonyBound || (harmonyEnvModule.isHarmonyBound = !0, bind(HarmonyEnvContribution).toSelf().inSingletonScope(), bind(EnvContribution).toService(HarmonyEnvContribution));
|
|
@@ -28739,17 +29016,17 @@
|
|
|
28739
29016
|
loadHarmonyEnv(container);
|
|
28740
29017
|
}
|
|
28741
29018
|
|
|
28742
|
-
var __decorate$
|
|
29019
|
+
var __decorate$g = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28743
29020
|
var d,
|
|
28744
29021
|
c = arguments.length,
|
|
28745
29022
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28746
29023
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28747
29024
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28748
29025
|
},
|
|
28749
|
-
__metadata$
|
|
29026
|
+
__metadata$e = undefined && undefined.__metadata || function (k, v) {
|
|
28750
29027
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28751
29028
|
},
|
|
28752
|
-
__param$
|
|
29029
|
+
__param$e = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28753
29030
|
return function (target, key) {
|
|
28754
29031
|
decorator(target, key, paramIndex);
|
|
28755
29032
|
};
|
|
@@ -28759,24 +29036,24 @@
|
|
|
28759
29036
|
super(), this.canvasRenderer = canvasRenderer, this.type = "arc", this.numberType = ARC_NUMBER_TYPE;
|
|
28760
29037
|
}
|
|
28761
29038
|
};
|
|
28762
|
-
DefaultCanvasArcPicker = __decorate$
|
|
29039
|
+
DefaultCanvasArcPicker = __decorate$g([injectable(), __param$e(0, inject(ArcRender)), __metadata$e("design:paramtypes", [Object])], DefaultCanvasArcPicker);
|
|
28763
29040
|
|
|
28764
29041
|
let loadArcPick = !1;
|
|
28765
29042
|
const arcCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
28766
29043
|
loadArcPick || (loadArcPick = !0, bind(CanvasArcPicker).to(DefaultCanvasArcPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasArcPicker));
|
|
28767
29044
|
});
|
|
28768
29045
|
|
|
28769
|
-
var __decorate$
|
|
29046
|
+
var __decorate$f = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28770
29047
|
var d,
|
|
28771
29048
|
c = arguments.length,
|
|
28772
29049
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28773
29050
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28774
29051
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28775
29052
|
},
|
|
28776
|
-
__metadata$
|
|
29053
|
+
__metadata$d = undefined && undefined.__metadata || function (k, v) {
|
|
28777
29054
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28778
29055
|
},
|
|
28779
|
-
__param$
|
|
29056
|
+
__param$d = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28780
29057
|
return function (target, key) {
|
|
28781
29058
|
decorator(target, key, paramIndex);
|
|
28782
29059
|
};
|
|
@@ -28786,7 +29063,7 @@
|
|
|
28786
29063
|
super(), this.canvasRenderer = canvasRenderer;
|
|
28787
29064
|
}
|
|
28788
29065
|
};
|
|
28789
|
-
DefaultCanvasRectPicker = __decorate$
|
|
29066
|
+
DefaultCanvasRectPicker = __decorate$f([injectable(), __param$d(0, inject(RectRender)), __metadata$d("design:paramtypes", [Object])], DefaultCanvasRectPicker);
|
|
28790
29067
|
|
|
28791
29068
|
let loadRectPick = !1;
|
|
28792
29069
|
const rectCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -28828,17 +29105,17 @@
|
|
|
28828
29105
|
}
|
|
28829
29106
|
}
|
|
28830
29107
|
|
|
28831
|
-
var __decorate$
|
|
29108
|
+
var __decorate$e = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28832
29109
|
var d,
|
|
28833
29110
|
c = arguments.length,
|
|
28834
29111
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28835
29112
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28836
29113
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28837
29114
|
},
|
|
28838
|
-
__metadata$
|
|
29115
|
+
__metadata$c = undefined && undefined.__metadata || function (k, v) {
|
|
28839
29116
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28840
29117
|
},
|
|
28841
|
-
__param$
|
|
29118
|
+
__param$c = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28842
29119
|
return function (target, key) {
|
|
28843
29120
|
decorator(target, key, paramIndex);
|
|
28844
29121
|
};
|
|
@@ -28848,24 +29125,24 @@
|
|
|
28848
29125
|
super(), this.canvasRenderer = canvasRenderer, this.type = "line", this.numberType = LINE_NUMBER_TYPE;
|
|
28849
29126
|
}
|
|
28850
29127
|
};
|
|
28851
|
-
DefaultCanvasLinePicker = __decorate$
|
|
29128
|
+
DefaultCanvasLinePicker = __decorate$e([injectable(), __param$c(0, inject(LineRender)), __metadata$c("design:paramtypes", [Object])], DefaultCanvasLinePicker);
|
|
28852
29129
|
|
|
28853
29130
|
let loadLinePick = !1;
|
|
28854
29131
|
const lineCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
28855
29132
|
loadLinePick || (loadLinePick = !0, bind(CanvasLinePicker).to(DefaultCanvasLinePicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasLinePicker));
|
|
28856
29133
|
});
|
|
28857
29134
|
|
|
28858
|
-
var __decorate$
|
|
29135
|
+
var __decorate$d = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28859
29136
|
var d,
|
|
28860
29137
|
c = arguments.length,
|
|
28861
29138
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28862
29139
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28863
29140
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28864
29141
|
},
|
|
28865
|
-
__metadata$
|
|
29142
|
+
__metadata$b = undefined && undefined.__metadata || function (k, v) {
|
|
28866
29143
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28867
29144
|
},
|
|
28868
|
-
__param$
|
|
29145
|
+
__param$b = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28869
29146
|
return function (target, key) {
|
|
28870
29147
|
decorator(target, key, paramIndex);
|
|
28871
29148
|
};
|
|
@@ -28875,7 +29152,7 @@
|
|
|
28875
29152
|
super(), this.canvasRenderer = canvasRenderer, this.type = "area", this.numberType = AREA_NUMBER_TYPE;
|
|
28876
29153
|
}
|
|
28877
29154
|
};
|
|
28878
|
-
DefaultCanvasAreaPicker = __decorate$
|
|
29155
|
+
DefaultCanvasAreaPicker = __decorate$d([injectable(), __param$b(0, inject(AreaRender)), __metadata$b("design:paramtypes", [Object])], DefaultCanvasAreaPicker);
|
|
28879
29156
|
|
|
28880
29157
|
let loadAreaPick = !1;
|
|
28881
29158
|
const areaCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
@@ -28909,17 +29186,17 @@
|
|
|
28909
29186
|
}
|
|
28910
29187
|
}
|
|
28911
29188
|
|
|
28912
|
-
var __decorate$
|
|
29189
|
+
var __decorate$c = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28913
29190
|
var d,
|
|
28914
29191
|
c = arguments.length,
|
|
28915
29192
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28916
29193
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28917
29194
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28918
29195
|
},
|
|
28919
|
-
__metadata$
|
|
29196
|
+
__metadata$a = undefined && undefined.__metadata || function (k, v) {
|
|
28920
29197
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28921
29198
|
},
|
|
28922
|
-
__param$
|
|
29199
|
+
__param$a = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28923
29200
|
return function (target, key) {
|
|
28924
29201
|
decorator(target, key, paramIndex);
|
|
28925
29202
|
};
|
|
@@ -28964,24 +29241,24 @@
|
|
|
28964
29241
|
}), this.canvasRenderer.z = 0, pickContext.modelMatrix !== lastModelMatrix && mat4Allocate.free(pickContext.modelMatrix), pickContext.modelMatrix = lastModelMatrix, pickContext.highPerformanceRestore(), picked;
|
|
28965
29242
|
}
|
|
28966
29243
|
};
|
|
28967
|
-
DefaultCanvasSymbolPicker = __decorate$
|
|
29244
|
+
DefaultCanvasSymbolPicker = __decorate$c([injectable(), __param$a(0, inject(SymbolRender)), __metadata$a("design:paramtypes", [Object])], DefaultCanvasSymbolPicker);
|
|
28968
29245
|
|
|
28969
29246
|
let loadSymbolPick = !1;
|
|
28970
29247
|
const symbolCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
28971
29248
|
loadSymbolPick || (loadSymbolPick = !0, bind(CanvasSymbolPicker).to(DefaultCanvasSymbolPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasSymbolPicker));
|
|
28972
29249
|
});
|
|
28973
29250
|
|
|
28974
|
-
var __decorate$
|
|
29251
|
+
var __decorate$b = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
28975
29252
|
var d,
|
|
28976
29253
|
c = arguments.length,
|
|
28977
29254
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
28978
29255
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
28979
29256
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28980
29257
|
},
|
|
28981
|
-
__metadata$
|
|
29258
|
+
__metadata$9 = undefined && undefined.__metadata || function (k, v) {
|
|
28982
29259
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
28983
29260
|
},
|
|
28984
|
-
__param$
|
|
29261
|
+
__param$9 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
28985
29262
|
return function (target, key) {
|
|
28986
29263
|
decorator(target, key, paramIndex);
|
|
28987
29264
|
};
|
|
@@ -28991,24 +29268,24 @@
|
|
|
28991
29268
|
super(), this.canvasRenderer = canvasRenderer, this.type = "circle", this.numberType = CIRCLE_NUMBER_TYPE;
|
|
28992
29269
|
}
|
|
28993
29270
|
};
|
|
28994
|
-
DefaultCanvasCirclePicker = __decorate$
|
|
29271
|
+
DefaultCanvasCirclePicker = __decorate$b([injectable(), __param$9(0, inject(CircleRender)), __metadata$9("design:paramtypes", [Object])], DefaultCanvasCirclePicker);
|
|
28995
29272
|
|
|
28996
29273
|
let loadCirclePick = !1;
|
|
28997
29274
|
const circleCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
28998
29275
|
loadCirclePick || (loadCirclePick = !0, bind(CanvasCirclePicker).to(DefaultCanvasCirclePicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasCirclePicker));
|
|
28999
29276
|
});
|
|
29000
29277
|
|
|
29001
|
-
var __decorate$
|
|
29278
|
+
var __decorate$a = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29002
29279
|
var d,
|
|
29003
29280
|
c = arguments.length,
|
|
29004
29281
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29005
29282
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29006
29283
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29007
29284
|
},
|
|
29008
|
-
__metadata$
|
|
29285
|
+
__metadata$8 = undefined && undefined.__metadata || function (k, v) {
|
|
29009
29286
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29010
29287
|
},
|
|
29011
|
-
__param$
|
|
29288
|
+
__param$8 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29012
29289
|
return function (target, key) {
|
|
29013
29290
|
decorator(target, key, paramIndex);
|
|
29014
29291
|
};
|
|
@@ -29061,24 +29338,24 @@
|
|
|
29061
29338
|
}, (context, symbolAttribute, themeAttribute) => picked), this.canvasRenderer.z = 0, pickContext.modelMatrix !== lastModelMatrix && mat4Allocate.free(pickContext.modelMatrix), pickContext.modelMatrix = lastModelMatrix, pickContext.highPerformanceRestore(), picked;
|
|
29062
29339
|
}
|
|
29063
29340
|
};
|
|
29064
|
-
DefaultCanvasTextPicker = __decorate$
|
|
29341
|
+
DefaultCanvasTextPicker = __decorate$a([injectable(), __param$8(0, inject(TextRender)), __metadata$8("design:paramtypes", [Object])], DefaultCanvasTextPicker);
|
|
29065
29342
|
|
|
29066
29343
|
let loadTextPick = !1;
|
|
29067
29344
|
const textCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29068
29345
|
loadTextPick || (loadTextPick = !0, bind(CanvasTextPicker).to(DefaultCanvasTextPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasTextPicker));
|
|
29069
29346
|
});
|
|
29070
29347
|
|
|
29071
|
-
var __decorate$
|
|
29348
|
+
var __decorate$9 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29072
29349
|
var d,
|
|
29073
29350
|
c = arguments.length,
|
|
29074
29351
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29075
29352
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29076
29353
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29077
29354
|
},
|
|
29078
|
-
__metadata$
|
|
29355
|
+
__metadata$7 = undefined && undefined.__metadata || function (k, v) {
|
|
29079
29356
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29080
29357
|
},
|
|
29081
|
-
__param$
|
|
29358
|
+
__param$7 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29082
29359
|
return function (target, key) {
|
|
29083
29360
|
decorator(target, key, paramIndex);
|
|
29084
29361
|
};
|
|
@@ -29088,24 +29365,24 @@
|
|
|
29088
29365
|
super(), this.canvasRenderer = canvasRenderer, this.type = "path", this.numberType = PATH_NUMBER_TYPE;
|
|
29089
29366
|
}
|
|
29090
29367
|
};
|
|
29091
|
-
DefaultCanvasPathPicker = __decorate$
|
|
29368
|
+
DefaultCanvasPathPicker = __decorate$9([injectable(), __param$7(0, inject(PathRender)), __metadata$7("design:paramtypes", [Object])], DefaultCanvasPathPicker);
|
|
29092
29369
|
|
|
29093
29370
|
let loadPathPick = !1;
|
|
29094
29371
|
const pathCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29095
29372
|
loadPathPick || (loadPathPick = !0, bind(CanvasPathPicker).to(DefaultCanvasPathPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasPathPicker));
|
|
29096
29373
|
});
|
|
29097
29374
|
|
|
29098
|
-
var __decorate$
|
|
29375
|
+
var __decorate$8 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29099
29376
|
var d,
|
|
29100
29377
|
c = arguments.length,
|
|
29101
29378
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29102
29379
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29103
29380
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29104
29381
|
},
|
|
29105
|
-
__metadata$
|
|
29382
|
+
__metadata$6 = undefined && undefined.__metadata || function (k, v) {
|
|
29106
29383
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29107
29384
|
},
|
|
29108
|
-
__param$
|
|
29385
|
+
__param$6 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29109
29386
|
return function (target, key) {
|
|
29110
29387
|
decorator(target, key, paramIndex);
|
|
29111
29388
|
};
|
|
@@ -29115,24 +29392,24 @@
|
|
|
29115
29392
|
super(), this.canvasRenderer = canvasRenderer, this.type = "polygon", this.numberType = POLYGON_NUMBER_TYPE;
|
|
29116
29393
|
}
|
|
29117
29394
|
};
|
|
29118
|
-
DefaultCanvasPolygonPicker = __decorate$
|
|
29395
|
+
DefaultCanvasPolygonPicker = __decorate$8([injectable(), __param$6(0, inject(PolygonRender)), __metadata$6("design:paramtypes", [Object])], DefaultCanvasPolygonPicker);
|
|
29119
29396
|
|
|
29120
29397
|
let loadPolygonPick = !1;
|
|
29121
29398
|
const polygonCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29122
29399
|
loadPolygonPick || (loadPolygonPick = !0, bind(CanvasPolygonPicker).to(DefaultCanvasPolygonPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasPolygonPicker));
|
|
29123
29400
|
});
|
|
29124
29401
|
|
|
29125
|
-
var __decorate$
|
|
29402
|
+
var __decorate$7 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29126
29403
|
var d,
|
|
29127
29404
|
c = arguments.length,
|
|
29128
29405
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29129
29406
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29130
29407
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29131
29408
|
},
|
|
29132
|
-
__metadata$
|
|
29409
|
+
__metadata$5 = undefined && undefined.__metadata || function (k, v) {
|
|
29133
29410
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29134
29411
|
},
|
|
29135
|
-
__param$
|
|
29412
|
+
__param$5 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29136
29413
|
return function (target, key) {
|
|
29137
29414
|
decorator(target, key, paramIndex);
|
|
29138
29415
|
};
|
|
@@ -29142,24 +29419,24 @@
|
|
|
29142
29419
|
super(), this.canvasRenderer = canvasRenderer;
|
|
29143
29420
|
}
|
|
29144
29421
|
};
|
|
29145
|
-
DefaultCanvasGlyphPicker = __decorate$
|
|
29422
|
+
DefaultCanvasGlyphPicker = __decorate$7([injectable(), __param$5(0, inject(GlyphRender)), __metadata$5("design:paramtypes", [Object])], DefaultCanvasGlyphPicker);
|
|
29146
29423
|
|
|
29147
29424
|
let loadGlyphPick = !1;
|
|
29148
29425
|
const glyphCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29149
29426
|
loadGlyphPick || (loadGlyphPick = !0, bind(CanvasGlyphPicker).to(DefaultCanvasGlyphPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasGlyphPicker));
|
|
29150
29427
|
});
|
|
29151
29428
|
|
|
29152
|
-
var __decorate$
|
|
29429
|
+
var __decorate$6 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29153
29430
|
var d,
|
|
29154
29431
|
c = arguments.length,
|
|
29155
29432
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29156
29433
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29157
29434
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29158
29435
|
},
|
|
29159
|
-
__metadata$
|
|
29436
|
+
__metadata$4 = undefined && undefined.__metadata || function (k, v) {
|
|
29160
29437
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29161
29438
|
},
|
|
29162
|
-
__param$
|
|
29439
|
+
__param$4 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29163
29440
|
return function (target, key) {
|
|
29164
29441
|
decorator(target, key, paramIndex);
|
|
29165
29442
|
};
|
|
@@ -29172,14 +29449,14 @@
|
|
|
29172
29449
|
return !!richtext.AABBBounds.containsPoint(point);
|
|
29173
29450
|
}
|
|
29174
29451
|
};
|
|
29175
|
-
DefaultCanvasRichTextPicker = __decorate$
|
|
29452
|
+
DefaultCanvasRichTextPicker = __decorate$6([injectable(), __param$4(0, inject(RichTextRender)), __metadata$4("design:paramtypes", [Object])], DefaultCanvasRichTextPicker);
|
|
29176
29453
|
|
|
29177
29454
|
let loadRichtextPick = !1;
|
|
29178
29455
|
const richtextCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29179
29456
|
loadRichtextPick || (loadRichtextPick = !0, bind(CanvasRichTextPicker).to(DefaultCanvasRichTextPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasRichTextPicker));
|
|
29180
29457
|
});
|
|
29181
29458
|
|
|
29182
|
-
var __decorate$
|
|
29459
|
+
var __decorate$5 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29183
29460
|
var d,
|
|
29184
29461
|
c = arguments.length,
|
|
29185
29462
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
@@ -29197,24 +29474,24 @@
|
|
|
29197
29474
|
return !!pickContext && !!image.AABBBounds.containsPoint(point);
|
|
29198
29475
|
}
|
|
29199
29476
|
};
|
|
29200
|
-
DefaultCanvasImagePicker = __decorate$
|
|
29477
|
+
DefaultCanvasImagePicker = __decorate$5([injectable()], DefaultCanvasImagePicker);
|
|
29201
29478
|
|
|
29202
29479
|
let loadImagePick = !1;
|
|
29203
29480
|
const imageCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29204
29481
|
loadImagePick || (loadImagePick = !0, bind(CanvasImagePicker).to(DefaultCanvasImagePicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasImagePicker));
|
|
29205
29482
|
});
|
|
29206
29483
|
|
|
29207
|
-
var __decorate$
|
|
29484
|
+
var __decorate$4 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29208
29485
|
var d,
|
|
29209
29486
|
c = arguments.length,
|
|
29210
29487
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29211
29488
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29212
29489
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29213
29490
|
},
|
|
29214
|
-
__metadata$
|
|
29491
|
+
__metadata$3 = undefined && undefined.__metadata || function (k, v) {
|
|
29215
29492
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29216
29493
|
},
|
|
29217
|
-
__param$
|
|
29494
|
+
__param$3 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29218
29495
|
return function (target, key) {
|
|
29219
29496
|
decorator(target, key, paramIndex);
|
|
29220
29497
|
};
|
|
@@ -29224,24 +29501,24 @@
|
|
|
29224
29501
|
super(), this.canvasRenderer = canvasRenderer, this.type = "rect3d", this.numberType = RECT3D_NUMBER_TYPE, this.themeType = "rect";
|
|
29225
29502
|
}
|
|
29226
29503
|
};
|
|
29227
|
-
DefaultCanvasRect3dPicker = __decorate$
|
|
29504
|
+
DefaultCanvasRect3dPicker = __decorate$4([injectable(), __param$3(0, inject(Rect3DRender)), __metadata$3("design:paramtypes", [Object])], DefaultCanvasRect3dPicker);
|
|
29228
29505
|
|
|
29229
29506
|
let loadRect3dPick = !1;
|
|
29230
29507
|
const rect3dCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29231
29508
|
loadRect3dPick || (loadRect3dPick = !0, bind(CanvasRect3dPicker).to(DefaultCanvasRect3dPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasRect3dPicker));
|
|
29232
29509
|
});
|
|
29233
29510
|
|
|
29234
|
-
var __decorate$
|
|
29511
|
+
var __decorate$3 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29235
29512
|
var d,
|
|
29236
29513
|
c = arguments.length,
|
|
29237
29514
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29238
29515
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29239
29516
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29240
29517
|
},
|
|
29241
|
-
__metadata$
|
|
29518
|
+
__metadata$2 = undefined && undefined.__metadata || function (k, v) {
|
|
29242
29519
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29243
29520
|
},
|
|
29244
|
-
__param$
|
|
29521
|
+
__param$2 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29245
29522
|
return function (target, key) {
|
|
29246
29523
|
decorator(target, key, paramIndex);
|
|
29247
29524
|
};
|
|
@@ -29251,24 +29528,24 @@
|
|
|
29251
29528
|
super(), this.canvasRenderer = canvasRenderer, this.type = "arc3d", this.numberType = ARC3D_NUMBER_TYPE, this.themeType = "arc";
|
|
29252
29529
|
}
|
|
29253
29530
|
};
|
|
29254
|
-
DefaultCanvasArc3dPicker = __decorate$
|
|
29531
|
+
DefaultCanvasArc3dPicker = __decorate$3([injectable(), __param$2(0, inject(Arc3dRender)), __metadata$2("design:paramtypes", [Object])], DefaultCanvasArc3dPicker);
|
|
29255
29532
|
|
|
29256
29533
|
let loadArc3dPick = !1;
|
|
29257
29534
|
const arc3dCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29258
29535
|
loadArc3dPick || (loadArc3dPick = !0, bind(CanvasArc3dPicker).to(DefaultCanvasArc3dPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasArc3dPicker));
|
|
29259
29536
|
});
|
|
29260
29537
|
|
|
29261
|
-
var __decorate$
|
|
29538
|
+
var __decorate$2 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29262
29539
|
var d,
|
|
29263
29540
|
c = arguments.length,
|
|
29264
29541
|
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29265
29542
|
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29266
29543
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29267
29544
|
},
|
|
29268
|
-
__metadata$
|
|
29545
|
+
__metadata$1 = undefined && undefined.__metadata || function (k, v) {
|
|
29269
29546
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29270
29547
|
},
|
|
29271
|
-
__param$
|
|
29548
|
+
__param$1 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29272
29549
|
return function (target, key) {
|
|
29273
29550
|
decorator(target, key, paramIndex);
|
|
29274
29551
|
};
|
|
@@ -29278,724 +29555,15 @@
|
|
|
29278
29555
|
super(), this.canvasRenderer = canvasRenderer, this.type = "pyramid3d", this.numberType = PYRAMID3D_NUMBER_TYPE, this.themeType = "polygon";
|
|
29279
29556
|
}
|
|
29280
29557
|
};
|
|
29281
|
-
DefaultCanvasPyramid3dPicker = __decorate$
|
|
29558
|
+
DefaultCanvasPyramid3dPicker = __decorate$2([injectable(), __param$1(0, inject(Pyramid3dRender)), __metadata$1("design:paramtypes", [Object])], DefaultCanvasPyramid3dPicker);
|
|
29282
29559
|
|
|
29283
29560
|
let loadPyramid3dPick = !1;
|
|
29284
29561
|
const pyramid3dCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29285
29562
|
loadPyramid3dPick || (loadPyramid3dPick = !0, bind(CanvasPyramid3dPicker).to(DefaultCanvasPyramid3dPicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasPyramid3dPicker));
|
|
29286
29563
|
});
|
|
29287
29564
|
|
|
29288
|
-
var lib$1 = {};
|
|
29289
|
-
|
|
29290
|
-
var gif = {};
|
|
29291
|
-
|
|
29292
|
-
var lib = {};
|
|
29293
|
-
|
|
29294
|
-
Object.defineProperty(lib, "__esModule", {
|
|
29295
|
-
value: true
|
|
29296
|
-
});
|
|
29297
|
-
lib.loop = lib.conditional = lib.parse = void 0;
|
|
29298
|
-
var parse = function parse(stream, schema) {
|
|
29299
|
-
var result = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
29300
|
-
var parent = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : result;
|
|
29301
|
-
if (Array.isArray(schema)) {
|
|
29302
|
-
schema.forEach(function (partSchema) {
|
|
29303
|
-
return parse(stream, partSchema, result, parent);
|
|
29304
|
-
});
|
|
29305
|
-
} else if (typeof schema === 'function') {
|
|
29306
|
-
schema(stream, result, parent, parse);
|
|
29307
|
-
} else {
|
|
29308
|
-
var key = Object.keys(schema)[0];
|
|
29309
|
-
if (Array.isArray(schema[key])) {
|
|
29310
|
-
parent[key] = {};
|
|
29311
|
-
parse(stream, schema[key], result, parent[key]);
|
|
29312
|
-
} else {
|
|
29313
|
-
parent[key] = schema[key](stream, result, parent, parse);
|
|
29314
|
-
}
|
|
29315
|
-
}
|
|
29316
|
-
return result;
|
|
29317
|
-
};
|
|
29318
|
-
lib.parse = parse;
|
|
29319
|
-
var conditional = function conditional(schema, conditionFunc) {
|
|
29320
|
-
return function (stream, result, parent, parse) {
|
|
29321
|
-
if (conditionFunc(stream, result, parent)) {
|
|
29322
|
-
parse(stream, schema, result, parent);
|
|
29323
|
-
}
|
|
29324
|
-
};
|
|
29325
|
-
};
|
|
29326
|
-
lib.conditional = conditional;
|
|
29327
|
-
var loop = function loop(schema, continueFunc) {
|
|
29328
|
-
return function (stream, result, parent, parse) {
|
|
29329
|
-
var arr = [];
|
|
29330
|
-
var lastStreamPos = stream.pos;
|
|
29331
|
-
while (continueFunc(stream, result, parent)) {
|
|
29332
|
-
var newParent = {};
|
|
29333
|
-
parse(stream, schema, result, newParent); // cases when whole file is parsed but no termination is there and stream position is not getting updated as well
|
|
29334
|
-
// it falls into infinite recursion, null check to avoid the same
|
|
29335
|
-
|
|
29336
|
-
if (stream.pos === lastStreamPos) {
|
|
29337
|
-
break;
|
|
29338
|
-
}
|
|
29339
|
-
lastStreamPos = stream.pos;
|
|
29340
|
-
arr.push(newParent);
|
|
29341
|
-
}
|
|
29342
|
-
return arr;
|
|
29343
|
-
};
|
|
29344
|
-
};
|
|
29345
|
-
lib.loop = loop;
|
|
29346
|
-
|
|
29347
|
-
var uint8 = {};
|
|
29348
|
-
|
|
29349
|
-
Object.defineProperty(uint8, "__esModule", {
|
|
29350
|
-
value: true
|
|
29351
|
-
});
|
|
29352
|
-
uint8.readBits = uint8.readArray = uint8.readUnsigned = uint8.readString = uint8.peekBytes = uint8.readBytes = uint8.peekByte = uint8.readByte = uint8.buildStream = void 0;
|
|
29353
|
-
|
|
29354
|
-
// Default stream and parsers for Uint8TypedArray data type
|
|
29355
|
-
var buildStream = function buildStream(uint8Data) {
|
|
29356
|
-
return {
|
|
29357
|
-
data: uint8Data,
|
|
29358
|
-
pos: 0
|
|
29359
|
-
};
|
|
29360
|
-
};
|
|
29361
|
-
uint8.buildStream = buildStream;
|
|
29362
|
-
var readByte = function readByte() {
|
|
29363
|
-
return function (stream) {
|
|
29364
|
-
return stream.data[stream.pos++];
|
|
29365
|
-
};
|
|
29366
|
-
};
|
|
29367
|
-
uint8.readByte = readByte;
|
|
29368
|
-
var peekByte = function peekByte() {
|
|
29369
|
-
var offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
|
|
29370
|
-
return function (stream) {
|
|
29371
|
-
return stream.data[stream.pos + offset];
|
|
29372
|
-
};
|
|
29373
|
-
};
|
|
29374
|
-
uint8.peekByte = peekByte;
|
|
29375
|
-
var readBytes = function readBytes(length) {
|
|
29376
|
-
return function (stream) {
|
|
29377
|
-
return stream.data.subarray(stream.pos, stream.pos += length);
|
|
29378
|
-
};
|
|
29379
|
-
};
|
|
29380
|
-
uint8.readBytes = readBytes;
|
|
29381
|
-
var peekBytes = function peekBytes(length) {
|
|
29382
|
-
return function (stream) {
|
|
29383
|
-
return stream.data.subarray(stream.pos, stream.pos + length);
|
|
29384
|
-
};
|
|
29385
|
-
};
|
|
29386
|
-
uint8.peekBytes = peekBytes;
|
|
29387
|
-
var readString = function readString(length) {
|
|
29388
|
-
return function (stream) {
|
|
29389
|
-
return Array.from(readBytes(length)(stream)).map(function (value) {
|
|
29390
|
-
return String.fromCharCode(value);
|
|
29391
|
-
}).join('');
|
|
29392
|
-
};
|
|
29393
|
-
};
|
|
29394
|
-
uint8.readString = readString;
|
|
29395
|
-
var readUnsigned = function readUnsigned(littleEndian) {
|
|
29396
|
-
return function (stream) {
|
|
29397
|
-
var bytes = readBytes(2)(stream);
|
|
29398
|
-
return littleEndian ? (bytes[1] << 8) + bytes[0] : (bytes[0] << 8) + bytes[1];
|
|
29399
|
-
};
|
|
29400
|
-
};
|
|
29401
|
-
uint8.readUnsigned = readUnsigned;
|
|
29402
|
-
var readArray = function readArray(byteSize, totalOrFunc) {
|
|
29403
|
-
return function (stream, result, parent) {
|
|
29404
|
-
var total = typeof totalOrFunc === 'function' ? totalOrFunc(stream, result, parent) : totalOrFunc;
|
|
29405
|
-
var parser = readBytes(byteSize);
|
|
29406
|
-
var arr = new Array(total);
|
|
29407
|
-
for (var i = 0; i < total; i++) {
|
|
29408
|
-
arr[i] = parser(stream);
|
|
29409
|
-
}
|
|
29410
|
-
return arr;
|
|
29411
|
-
};
|
|
29412
|
-
};
|
|
29413
|
-
uint8.readArray = readArray;
|
|
29414
|
-
var subBitsTotal = function subBitsTotal(bits, startIndex, length) {
|
|
29415
|
-
var result = 0;
|
|
29416
|
-
for (var i = 0; i < length; i++) {
|
|
29417
|
-
result += bits[startIndex + i] && Math.pow(2, length - i - 1);
|
|
29418
|
-
}
|
|
29419
|
-
return result;
|
|
29420
|
-
};
|
|
29421
|
-
var readBits = function readBits(schema) {
|
|
29422
|
-
return function (stream) {
|
|
29423
|
-
var _byte = readByte()(stream); // convert the byte to bit array
|
|
29424
|
-
|
|
29425
|
-
var bits = new Array(8);
|
|
29426
|
-
for (var i = 0; i < 8; i++) {
|
|
29427
|
-
bits[7 - i] = !!(_byte & 1 << i);
|
|
29428
|
-
} // convert the bit array to values based on the schema
|
|
29429
|
-
|
|
29430
|
-
return Object.keys(schema).reduce(function (res, key) {
|
|
29431
|
-
var def = schema[key];
|
|
29432
|
-
if (def.length) {
|
|
29433
|
-
res[key] = subBitsTotal(bits, def.index, def.length);
|
|
29434
|
-
} else {
|
|
29435
|
-
res[key] = bits[def.index];
|
|
29436
|
-
}
|
|
29437
|
-
return res;
|
|
29438
|
-
}, {});
|
|
29439
|
-
};
|
|
29440
|
-
};
|
|
29441
|
-
uint8.readBits = readBits;
|
|
29442
|
-
|
|
29443
|
-
(function (exports) {
|
|
29444
|
-
|
|
29445
|
-
Object.defineProperty(exports, "__esModule", {
|
|
29446
|
-
value: true
|
|
29447
|
-
});
|
|
29448
|
-
exports["default"] = void 0;
|
|
29449
|
-
var _ = lib;
|
|
29450
|
-
var _uint = uint8;
|
|
29451
|
-
|
|
29452
|
-
// a set of 0x00 terminated subblocks
|
|
29453
|
-
var subBlocksSchema = {
|
|
29454
|
-
blocks: function blocks(stream) {
|
|
29455
|
-
var terminator = 0x00;
|
|
29456
|
-
var chunks = [];
|
|
29457
|
-
var streamSize = stream.data.length;
|
|
29458
|
-
var total = 0;
|
|
29459
|
-
for (var size = (0, _uint.readByte)()(stream); size !== terminator; size = (0, _uint.readByte)()(stream)) {
|
|
29460
|
-
// size becomes undefined for some case when file is corrupted and terminator is not proper
|
|
29461
|
-
// null check to avoid recursion
|
|
29462
|
-
if (!size) break; // catch corrupted files with no terminator
|
|
29463
|
-
|
|
29464
|
-
if (stream.pos + size >= streamSize) {
|
|
29465
|
-
var availableSize = streamSize - stream.pos;
|
|
29466
|
-
chunks.push((0, _uint.readBytes)(availableSize)(stream));
|
|
29467
|
-
total += availableSize;
|
|
29468
|
-
break;
|
|
29469
|
-
}
|
|
29470
|
-
chunks.push((0, _uint.readBytes)(size)(stream));
|
|
29471
|
-
total += size;
|
|
29472
|
-
}
|
|
29473
|
-
var result = new Uint8Array(total);
|
|
29474
|
-
var offset = 0;
|
|
29475
|
-
for (var i = 0; i < chunks.length; i++) {
|
|
29476
|
-
result.set(chunks[i], offset);
|
|
29477
|
-
offset += chunks[i].length;
|
|
29478
|
-
}
|
|
29479
|
-
return result;
|
|
29480
|
-
}
|
|
29481
|
-
}; // global control extension
|
|
29482
|
-
|
|
29483
|
-
var gceSchema = (0, _.conditional)({
|
|
29484
|
-
gce: [{
|
|
29485
|
-
codes: (0, _uint.readBytes)(2)
|
|
29486
|
-
}, {
|
|
29487
|
-
byteSize: (0, _uint.readByte)()
|
|
29488
|
-
}, {
|
|
29489
|
-
extras: (0, _uint.readBits)({
|
|
29490
|
-
future: {
|
|
29491
|
-
index: 0,
|
|
29492
|
-
length: 3
|
|
29493
|
-
},
|
|
29494
|
-
disposal: {
|
|
29495
|
-
index: 3,
|
|
29496
|
-
length: 3
|
|
29497
|
-
},
|
|
29498
|
-
userInput: {
|
|
29499
|
-
index: 6
|
|
29500
|
-
},
|
|
29501
|
-
transparentColorGiven: {
|
|
29502
|
-
index: 7
|
|
29503
|
-
}
|
|
29504
|
-
})
|
|
29505
|
-
}, {
|
|
29506
|
-
delay: (0, _uint.readUnsigned)(true)
|
|
29507
|
-
}, {
|
|
29508
|
-
transparentColorIndex: (0, _uint.readByte)()
|
|
29509
|
-
}, {
|
|
29510
|
-
terminator: (0, _uint.readByte)()
|
|
29511
|
-
}]
|
|
29512
|
-
}, function (stream) {
|
|
29513
|
-
var codes = (0, _uint.peekBytes)(2)(stream);
|
|
29514
|
-
return codes[0] === 0x21 && codes[1] === 0xf9;
|
|
29515
|
-
}); // image pipeline block
|
|
29516
|
-
|
|
29517
|
-
var imageSchema = (0, _.conditional)({
|
|
29518
|
-
image: [{
|
|
29519
|
-
code: (0, _uint.readByte)()
|
|
29520
|
-
}, {
|
|
29521
|
-
descriptor: [{
|
|
29522
|
-
left: (0, _uint.readUnsigned)(true)
|
|
29523
|
-
}, {
|
|
29524
|
-
top: (0, _uint.readUnsigned)(true)
|
|
29525
|
-
}, {
|
|
29526
|
-
width: (0, _uint.readUnsigned)(true)
|
|
29527
|
-
}, {
|
|
29528
|
-
height: (0, _uint.readUnsigned)(true)
|
|
29529
|
-
}, {
|
|
29530
|
-
lct: (0, _uint.readBits)({
|
|
29531
|
-
exists: {
|
|
29532
|
-
index: 0
|
|
29533
|
-
},
|
|
29534
|
-
interlaced: {
|
|
29535
|
-
index: 1
|
|
29536
|
-
},
|
|
29537
|
-
sort: {
|
|
29538
|
-
index: 2
|
|
29539
|
-
},
|
|
29540
|
-
future: {
|
|
29541
|
-
index: 3,
|
|
29542
|
-
length: 2
|
|
29543
|
-
},
|
|
29544
|
-
size: {
|
|
29545
|
-
index: 5,
|
|
29546
|
-
length: 3
|
|
29547
|
-
}
|
|
29548
|
-
})
|
|
29549
|
-
}]
|
|
29550
|
-
}, (0, _.conditional)({
|
|
29551
|
-
lct: (0, _uint.readArray)(3, function (stream, result, parent) {
|
|
29552
|
-
return Math.pow(2, parent.descriptor.lct.size + 1);
|
|
29553
|
-
})
|
|
29554
|
-
}, function (stream, result, parent) {
|
|
29555
|
-
return parent.descriptor.lct.exists;
|
|
29556
|
-
}), {
|
|
29557
|
-
data: [{
|
|
29558
|
-
minCodeSize: (0, _uint.readByte)()
|
|
29559
|
-
}, subBlocksSchema]
|
|
29560
|
-
}]
|
|
29561
|
-
}, function (stream) {
|
|
29562
|
-
return (0, _uint.peekByte)()(stream) === 0x2c;
|
|
29563
|
-
}); // plain text block
|
|
29564
|
-
|
|
29565
|
-
var textSchema = (0, _.conditional)({
|
|
29566
|
-
text: [{
|
|
29567
|
-
codes: (0, _uint.readBytes)(2)
|
|
29568
|
-
}, {
|
|
29569
|
-
blockSize: (0, _uint.readByte)()
|
|
29570
|
-
}, {
|
|
29571
|
-
preData: function preData(stream, result, parent) {
|
|
29572
|
-
return (0, _uint.readBytes)(parent.text.blockSize)(stream);
|
|
29573
|
-
}
|
|
29574
|
-
}, subBlocksSchema]
|
|
29575
|
-
}, function (stream) {
|
|
29576
|
-
var codes = (0, _uint.peekBytes)(2)(stream);
|
|
29577
|
-
return codes[0] === 0x21 && codes[1] === 0x01;
|
|
29578
|
-
}); // application block
|
|
29579
|
-
|
|
29580
|
-
var applicationSchema = (0, _.conditional)({
|
|
29581
|
-
application: [{
|
|
29582
|
-
codes: (0, _uint.readBytes)(2)
|
|
29583
|
-
}, {
|
|
29584
|
-
blockSize: (0, _uint.readByte)()
|
|
29585
|
-
}, {
|
|
29586
|
-
id: function id(stream, result, parent) {
|
|
29587
|
-
return (0, _uint.readString)(parent.blockSize)(stream);
|
|
29588
|
-
}
|
|
29589
|
-
}, subBlocksSchema]
|
|
29590
|
-
}, function (stream) {
|
|
29591
|
-
var codes = (0, _uint.peekBytes)(2)(stream);
|
|
29592
|
-
return codes[0] === 0x21 && codes[1] === 0xff;
|
|
29593
|
-
}); // comment block
|
|
29594
|
-
|
|
29595
|
-
var commentSchema = (0, _.conditional)({
|
|
29596
|
-
comment: [{
|
|
29597
|
-
codes: (0, _uint.readBytes)(2)
|
|
29598
|
-
}, subBlocksSchema]
|
|
29599
|
-
}, function (stream) {
|
|
29600
|
-
var codes = (0, _uint.peekBytes)(2)(stream);
|
|
29601
|
-
return codes[0] === 0x21 && codes[1] === 0xfe;
|
|
29602
|
-
});
|
|
29603
|
-
var schema = [{
|
|
29604
|
-
header: [{
|
|
29605
|
-
signature: (0, _uint.readString)(3)
|
|
29606
|
-
}, {
|
|
29607
|
-
version: (0, _uint.readString)(3)
|
|
29608
|
-
}]
|
|
29609
|
-
}, {
|
|
29610
|
-
lsd: [{
|
|
29611
|
-
width: (0, _uint.readUnsigned)(true)
|
|
29612
|
-
}, {
|
|
29613
|
-
height: (0, _uint.readUnsigned)(true)
|
|
29614
|
-
}, {
|
|
29615
|
-
gct: (0, _uint.readBits)({
|
|
29616
|
-
exists: {
|
|
29617
|
-
index: 0
|
|
29618
|
-
},
|
|
29619
|
-
resolution: {
|
|
29620
|
-
index: 1,
|
|
29621
|
-
length: 3
|
|
29622
|
-
},
|
|
29623
|
-
sort: {
|
|
29624
|
-
index: 4
|
|
29625
|
-
},
|
|
29626
|
-
size: {
|
|
29627
|
-
index: 5,
|
|
29628
|
-
length: 3
|
|
29629
|
-
}
|
|
29630
|
-
})
|
|
29631
|
-
}, {
|
|
29632
|
-
backgroundColorIndex: (0, _uint.readByte)()
|
|
29633
|
-
}, {
|
|
29634
|
-
pixelAspectRatio: (0, _uint.readByte)()
|
|
29635
|
-
}]
|
|
29636
|
-
}, (0, _.conditional)({
|
|
29637
|
-
gct: (0, _uint.readArray)(3, function (stream, result) {
|
|
29638
|
-
return Math.pow(2, result.lsd.gct.size + 1);
|
|
29639
|
-
})
|
|
29640
|
-
}, function (stream, result) {
|
|
29641
|
-
return result.lsd.gct.exists;
|
|
29642
|
-
}),
|
|
29643
|
-
// content frames
|
|
29644
|
-
{
|
|
29645
|
-
frames: (0, _.loop)([gceSchema, applicationSchema, commentSchema, imageSchema, textSchema], function (stream) {
|
|
29646
|
-
var nextCode = (0, _uint.peekByte)()(stream); // rather than check for a terminator, we should check for the existence
|
|
29647
|
-
// of an ext or image block to avoid infinite loops
|
|
29648
|
-
//var terminator = 0x3B;
|
|
29649
|
-
//return nextCode !== terminator;
|
|
29650
|
-
|
|
29651
|
-
return nextCode === 0x21 || nextCode === 0x2c;
|
|
29652
|
-
})
|
|
29653
|
-
}];
|
|
29654
|
-
var _default = schema;
|
|
29655
|
-
exports["default"] = _default;
|
|
29656
|
-
})(gif);
|
|
29657
|
-
|
|
29658
|
-
var deinterlace$1 = {};
|
|
29659
|
-
|
|
29660
|
-
Object.defineProperty(deinterlace$1, "__esModule", {
|
|
29661
|
-
value: true
|
|
29662
|
-
});
|
|
29663
|
-
deinterlace$1.deinterlace = void 0;
|
|
29664
|
-
|
|
29665
|
-
/**
|
|
29666
|
-
* Deinterlace function from https://github.com/shachaf/jsgif
|
|
29667
|
-
*/
|
|
29668
|
-
var deinterlace = function deinterlace(pixels, width) {
|
|
29669
|
-
var newPixels = new Array(pixels.length);
|
|
29670
|
-
var rows = pixels.length / width;
|
|
29671
|
-
var cpRow = function cpRow(toRow, fromRow) {
|
|
29672
|
-
var fromPixels = pixels.slice(fromRow * width, (fromRow + 1) * width);
|
|
29673
|
-
newPixels.splice.apply(newPixels, [toRow * width, width].concat(fromPixels));
|
|
29674
|
-
}; // See appendix E.
|
|
29675
|
-
|
|
29676
|
-
var offsets = [0, 4, 2, 1];
|
|
29677
|
-
var steps = [8, 8, 4, 2];
|
|
29678
|
-
var fromRow = 0;
|
|
29679
|
-
for (var pass = 0; pass < 4; pass++) {
|
|
29680
|
-
for (var toRow = offsets[pass]; toRow < rows; toRow += steps[pass]) {
|
|
29681
|
-
cpRow(toRow, fromRow);
|
|
29682
|
-
fromRow++;
|
|
29683
|
-
}
|
|
29684
|
-
}
|
|
29685
|
-
return newPixels;
|
|
29686
|
-
};
|
|
29687
|
-
deinterlace$1.deinterlace = deinterlace;
|
|
29688
|
-
|
|
29689
|
-
var lzw$1 = {};
|
|
29690
|
-
|
|
29691
|
-
Object.defineProperty(lzw$1, "__esModule", {
|
|
29692
|
-
value: true
|
|
29693
|
-
});
|
|
29694
|
-
lzw$1.lzw = void 0;
|
|
29695
|
-
|
|
29696
|
-
/**
|
|
29697
|
-
* javascript port of java LZW decompression
|
|
29698
|
-
* Original java author url: https://gist.github.com/devunwired/4479231
|
|
29699
|
-
*/
|
|
29700
|
-
var lzw = function lzw(minCodeSize, data, pixelCount) {
|
|
29701
|
-
var MAX_STACK_SIZE = 4096;
|
|
29702
|
-
var nullCode = -1;
|
|
29703
|
-
var npix = pixelCount;
|
|
29704
|
-
var available, clear, code_mask, code_size, end_of_information, in_code, old_code, bits, code, i, datum, data_size, first, top, bi, pi;
|
|
29705
|
-
var dstPixels = new Array(pixelCount);
|
|
29706
|
-
var prefix = new Array(MAX_STACK_SIZE);
|
|
29707
|
-
var suffix = new Array(MAX_STACK_SIZE);
|
|
29708
|
-
var pixelStack = new Array(MAX_STACK_SIZE + 1); // Initialize GIF data stream decoder.
|
|
29709
|
-
|
|
29710
|
-
data_size = minCodeSize;
|
|
29711
|
-
clear = 1 << data_size;
|
|
29712
|
-
end_of_information = clear + 1;
|
|
29713
|
-
available = clear + 2;
|
|
29714
|
-
old_code = nullCode;
|
|
29715
|
-
code_size = data_size + 1;
|
|
29716
|
-
code_mask = (1 << code_size) - 1;
|
|
29717
|
-
for (code = 0; code < clear; code++) {
|
|
29718
|
-
prefix[code] = 0;
|
|
29719
|
-
suffix[code] = code;
|
|
29720
|
-
} // Decode GIF pixel stream.
|
|
29721
|
-
|
|
29722
|
-
var datum, bits, first, top, pi, bi;
|
|
29723
|
-
datum = bits = first = top = pi = bi = 0;
|
|
29724
|
-
for (i = 0; i < npix;) {
|
|
29725
|
-
if (top === 0) {
|
|
29726
|
-
if (bits < code_size) {
|
|
29727
|
-
// get the next byte
|
|
29728
|
-
datum += data[bi] << bits;
|
|
29729
|
-
bits += 8;
|
|
29730
|
-
bi++;
|
|
29731
|
-
continue;
|
|
29732
|
-
} // Get the next code.
|
|
29733
|
-
|
|
29734
|
-
code = datum & code_mask;
|
|
29735
|
-
datum >>= code_size;
|
|
29736
|
-
bits -= code_size; // Interpret the code
|
|
29737
|
-
|
|
29738
|
-
if (code > available || code == end_of_information) {
|
|
29739
|
-
break;
|
|
29740
|
-
}
|
|
29741
|
-
if (code == clear) {
|
|
29742
|
-
// Reset decoder.
|
|
29743
|
-
code_size = data_size + 1;
|
|
29744
|
-
code_mask = (1 << code_size) - 1;
|
|
29745
|
-
available = clear + 2;
|
|
29746
|
-
old_code = nullCode;
|
|
29747
|
-
continue;
|
|
29748
|
-
}
|
|
29749
|
-
if (old_code == nullCode) {
|
|
29750
|
-
pixelStack[top++] = suffix[code];
|
|
29751
|
-
old_code = code;
|
|
29752
|
-
first = code;
|
|
29753
|
-
continue;
|
|
29754
|
-
}
|
|
29755
|
-
in_code = code;
|
|
29756
|
-
if (code == available) {
|
|
29757
|
-
pixelStack[top++] = first;
|
|
29758
|
-
code = old_code;
|
|
29759
|
-
}
|
|
29760
|
-
while (code > clear) {
|
|
29761
|
-
pixelStack[top++] = suffix[code];
|
|
29762
|
-
code = prefix[code];
|
|
29763
|
-
}
|
|
29764
|
-
first = suffix[code] & 0xff;
|
|
29765
|
-
pixelStack[top++] = first; // add a new string to the table, but only if space is available
|
|
29766
|
-
// if not, just continue with current table until a clear code is found
|
|
29767
|
-
// (deferred clear code implementation as per GIF spec)
|
|
29768
|
-
|
|
29769
|
-
if (available < MAX_STACK_SIZE) {
|
|
29770
|
-
prefix[available] = old_code;
|
|
29771
|
-
suffix[available] = first;
|
|
29772
|
-
available++;
|
|
29773
|
-
if ((available & code_mask) === 0 && available < MAX_STACK_SIZE) {
|
|
29774
|
-
code_size++;
|
|
29775
|
-
code_mask += available;
|
|
29776
|
-
}
|
|
29777
|
-
}
|
|
29778
|
-
old_code = in_code;
|
|
29779
|
-
} // Pop a pixel off the pixel stack.
|
|
29780
|
-
|
|
29781
|
-
top--;
|
|
29782
|
-
dstPixels[pi++] = pixelStack[top];
|
|
29783
|
-
i++;
|
|
29784
|
-
}
|
|
29785
|
-
for (i = pi; i < npix; i++) {
|
|
29786
|
-
dstPixels[i] = 0; // clear missing pixels
|
|
29787
|
-
}
|
|
29788
|
-
|
|
29789
|
-
return dstPixels;
|
|
29790
|
-
};
|
|
29791
|
-
lzw$1.lzw = lzw;
|
|
29792
|
-
|
|
29793
|
-
Object.defineProperty(lib$1, "__esModule", {
|
|
29794
|
-
value: true
|
|
29795
|
-
});
|
|
29796
|
-
var decompressFrames_1 = lib$1.decompressFrames = lib$1.decompressFrame = parseGIF_1 = lib$1.parseGIF = void 0;
|
|
29797
|
-
var _gif = _interopRequireDefault(gif);
|
|
29798
|
-
var _jsBinarySchemaParser = lib;
|
|
29799
|
-
var _uint = uint8;
|
|
29800
|
-
var _deinterlace = deinterlace$1;
|
|
29801
|
-
var _lzw = lzw$1;
|
|
29802
|
-
function _interopRequireDefault(obj) {
|
|
29803
|
-
return obj && obj.__esModule ? obj : {
|
|
29804
|
-
"default": obj
|
|
29805
|
-
};
|
|
29806
|
-
}
|
|
29807
|
-
var parseGIF = function parseGIF(arrayBuffer) {
|
|
29808
|
-
var byteData = new Uint8Array(arrayBuffer);
|
|
29809
|
-
return (0, _jsBinarySchemaParser.parse)((0, _uint.buildStream)(byteData), _gif["default"]);
|
|
29810
|
-
};
|
|
29811
|
-
var parseGIF_1 = lib$1.parseGIF = parseGIF;
|
|
29812
|
-
var generatePatch = function generatePatch(image) {
|
|
29813
|
-
var totalPixels = image.pixels.length;
|
|
29814
|
-
var patchData = new Uint8ClampedArray(totalPixels * 4);
|
|
29815
|
-
for (var i = 0; i < totalPixels; i++) {
|
|
29816
|
-
var pos = i * 4;
|
|
29817
|
-
var colorIndex = image.pixels[i];
|
|
29818
|
-
var color = image.colorTable[colorIndex] || [0, 0, 0];
|
|
29819
|
-
patchData[pos] = color[0];
|
|
29820
|
-
patchData[pos + 1] = color[1];
|
|
29821
|
-
patchData[pos + 2] = color[2];
|
|
29822
|
-
patchData[pos + 3] = colorIndex !== image.transparentIndex ? 255 : 0;
|
|
29823
|
-
}
|
|
29824
|
-
return patchData;
|
|
29825
|
-
};
|
|
29826
|
-
var decompressFrame = function decompressFrame(frame, gct, buildImagePatch) {
|
|
29827
|
-
if (!frame.image) {
|
|
29828
|
-
console.warn('gif frame does not have associated image.');
|
|
29829
|
-
return;
|
|
29830
|
-
}
|
|
29831
|
-
var image = frame.image; // get the number of pixels
|
|
29832
|
-
|
|
29833
|
-
var totalPixels = image.descriptor.width * image.descriptor.height; // do lzw decompression
|
|
29834
|
-
|
|
29835
|
-
var pixels = (0, _lzw.lzw)(image.data.minCodeSize, image.data.blocks, totalPixels); // deal with interlacing if necessary
|
|
29836
|
-
|
|
29837
|
-
if (image.descriptor.lct.interlaced) {
|
|
29838
|
-
pixels = (0, _deinterlace.deinterlace)(pixels, image.descriptor.width);
|
|
29839
|
-
}
|
|
29840
|
-
var resultImage = {
|
|
29841
|
-
pixels: pixels,
|
|
29842
|
-
dims: {
|
|
29843
|
-
top: frame.image.descriptor.top,
|
|
29844
|
-
left: frame.image.descriptor.left,
|
|
29845
|
-
width: frame.image.descriptor.width,
|
|
29846
|
-
height: frame.image.descriptor.height
|
|
29847
|
-
}
|
|
29848
|
-
}; // color table
|
|
29849
|
-
|
|
29850
|
-
if (image.descriptor.lct && image.descriptor.lct.exists) {
|
|
29851
|
-
resultImage.colorTable = image.lct;
|
|
29852
|
-
} else {
|
|
29853
|
-
resultImage.colorTable = gct;
|
|
29854
|
-
} // add per frame relevant gce information
|
|
29855
|
-
|
|
29856
|
-
if (frame.gce) {
|
|
29857
|
-
resultImage.delay = (frame.gce.delay || 10) * 10; // convert to ms
|
|
29858
|
-
|
|
29859
|
-
resultImage.disposalType = frame.gce.extras.disposal; // transparency
|
|
29860
|
-
|
|
29861
|
-
if (frame.gce.extras.transparentColorGiven) {
|
|
29862
|
-
resultImage.transparentIndex = frame.gce.transparentColorIndex;
|
|
29863
|
-
}
|
|
29864
|
-
} // create canvas usable imagedata if desired
|
|
29865
|
-
|
|
29866
|
-
if (buildImagePatch) {
|
|
29867
|
-
resultImage.patch = generatePatch(resultImage);
|
|
29868
|
-
}
|
|
29869
|
-
return resultImage;
|
|
29870
|
-
};
|
|
29871
|
-
lib$1.decompressFrame = decompressFrame;
|
|
29872
|
-
var decompressFrames = function decompressFrames(parsedGif, buildImagePatches) {
|
|
29873
|
-
return parsedGif.frames.filter(function (f) {
|
|
29874
|
-
return f.image;
|
|
29875
|
-
}).map(function (f) {
|
|
29876
|
-
return decompressFrame(f, parsedGif.gct, buildImagePatches);
|
|
29877
|
-
});
|
|
29878
|
-
};
|
|
29879
|
-
decompressFrames_1 = lib$1.decompressFrames = decompressFrames;
|
|
29880
|
-
|
|
29881
|
-
const GIFIMAGE_NUMBER_TYPE = Generator.GenAutoIncrementId();
|
|
29882
29565
|
const LOTTIE_NUMBER_TYPE = Generator.GenAutoIncrementId();
|
|
29883
29566
|
|
|
29884
|
-
class GifImage extends Image$1 {
|
|
29885
|
-
constructor(params) {
|
|
29886
|
-
super(params), this.type = "gif-image", this.numberType = GIFIMAGE_NUMBER_TYPE, this.loadGif();
|
|
29887
|
-
}
|
|
29888
|
-
loadGif() {
|
|
29889
|
-
if (isString$1(this.attribute.gifImage)) ResourceLoader.GetFile(this.attribute.gifImage, "arrayBuffer").then(res => {
|
|
29890
|
-
const gif = parseGIF_1(res),
|
|
29891
|
-
frames = decompressFrames_1(gif, !0);
|
|
29892
|
-
this.renderGIF(frames);
|
|
29893
|
-
}).catch(e => {
|
|
29894
|
-
console.error("Gif load error: ", e);
|
|
29895
|
-
});else if (this.attribute.gifImage instanceof ArrayBuffer) {
|
|
29896
|
-
const gif = parseGIF_1(this.attribute.gifImage),
|
|
29897
|
-
frames = decompressFrames_1(gif, !0);
|
|
29898
|
-
this.renderGIF(frames);
|
|
29899
|
-
}
|
|
29900
|
-
}
|
|
29901
|
-
renderGIF(frames) {
|
|
29902
|
-
this.loadedFrames = frames, this.frameIndex = 0, this.tempCanvas || (this.tempCanvas = application.global.createCanvas({}), this.tempCtx = this.tempCanvas.getContext("2d")), this.gifCanvas || (this.gifCanvas = application.global.createCanvas({}), this.gifCtx = this.gifCanvas.getContext("2d")), this.gifCanvas.width = frames[0].dims.width, this.gifCanvas.height = frames[0].dims.height, this.playing = !0, this.lastTime = new Date().getTime();
|
|
29903
|
-
const animation = this.animate();
|
|
29904
|
-
this.attribute.timeline && animation.setTimeline(this.attribute.timeline), animation.to({}, 1e3, "linear").loop(1 / 0);
|
|
29905
|
-
}
|
|
29906
|
-
renderFrame(context, x, y) {
|
|
29907
|
-
const frame = this.loadedFrames[this.frameIndex || 0];
|
|
29908
|
-
2 === frame.disposalType && this.gifCtx.clearRect(0, 0, this.gifCanvas.width, this.gifCanvas.height), this.drawPatch(frame), this.manipulate(context, x, y);
|
|
29909
|
-
const diff = new Date().getTime() - this.lastTime;
|
|
29910
|
-
frame.delay < diff && (this.frameIndex++, this.lastTime = new Date().getTime()), this.frameIndex >= this.loadedFrames.length && (this.frameIndex = 0);
|
|
29911
|
-
}
|
|
29912
|
-
drawPatch(frame) {
|
|
29913
|
-
const dims = frame.dims;
|
|
29914
|
-
this.frameImageData && dims.width === this.frameImageData.width && dims.height === this.frameImageData.height || (this.tempCanvas.width = dims.width, this.tempCanvas.height = dims.height, this.frameImageData = this.tempCtx.createImageData(dims.width, dims.height)), this.frameImageData.data.set(frame.patch), this.tempCtx.putImageData(this.frameImageData, 0, 0), this.gifCtx.drawImage(this.tempCanvas, dims.left, dims.top);
|
|
29915
|
-
}
|
|
29916
|
-
manipulate(context, x, y) {
|
|
29917
|
-
context.drawImage(this.gifCanvas, 0, 0, this.gifCanvas.width, this.gifCanvas.height, x, y, this.attribute.width, this.attribute.height);
|
|
29918
|
-
}
|
|
29919
|
-
setAttribute(key, value, forceUpdateTag, context) {
|
|
29920
|
-
super.setAttribute(key, value, forceUpdateTag, context), "gifImage" === key && this.loadGif();
|
|
29921
|
-
}
|
|
29922
|
-
setAttributes(params, forceUpdateTag, context) {
|
|
29923
|
-
super.setAttributes(params, forceUpdateTag, context), params.gifImage && this.loadGif();
|
|
29924
|
-
}
|
|
29925
|
-
}
|
|
29926
|
-
function createGifImage(attributes) {
|
|
29927
|
-
return new GifImage(attributes);
|
|
29928
|
-
}
|
|
29929
|
-
|
|
29930
|
-
var __decorate$3 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29931
|
-
var d,
|
|
29932
|
-
c = arguments.length,
|
|
29933
|
-
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29934
|
-
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29935
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29936
|
-
};
|
|
29937
|
-
let DefaultCanvasGifImagePicker = class {
|
|
29938
|
-
constructor() {
|
|
29939
|
-
this.type = "gif-image", this.numberType = GIFIMAGE_NUMBER_TYPE;
|
|
29940
|
-
}
|
|
29941
|
-
contains(gifImage, point, params) {
|
|
29942
|
-
const {
|
|
29943
|
-
pickContext: pickContext
|
|
29944
|
-
} = null != params ? params : {};
|
|
29945
|
-
return !!pickContext && !!gifImage.AABBBounds.containsPoint(point);
|
|
29946
|
-
}
|
|
29947
|
-
};
|
|
29948
|
-
DefaultCanvasGifImagePicker = __decorate$3([injectable()], DefaultCanvasGifImagePicker);
|
|
29949
|
-
|
|
29950
|
-
let loadGifImagePick = !1;
|
|
29951
|
-
const gifImageCanvasPickModule = new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
29952
|
-
loadGifImagePick || (loadGifImagePick = !0, bind(CanvasGifImagePicker).to(DefaultCanvasGifImagePicker).inSingletonScope(), bind(CanvasPickerContribution).toService(CanvasGifImagePicker));
|
|
29953
|
-
});
|
|
29954
|
-
|
|
29955
|
-
var __decorate$2 = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
29956
|
-
var d,
|
|
29957
|
-
c = arguments.length,
|
|
29958
|
-
r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
|
|
29959
|
-
if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
|
|
29960
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29961
|
-
},
|
|
29962
|
-
__metadata$1 = undefined && undefined.__metadata || function (k, v) {
|
|
29963
|
-
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
|
|
29964
|
-
},
|
|
29965
|
-
__param$1 = undefined && undefined.__param || function (paramIndex, decorator) {
|
|
29966
|
-
return function (target, key) {
|
|
29967
|
-
decorator(target, key, paramIndex);
|
|
29968
|
-
};
|
|
29969
|
-
};
|
|
29970
|
-
let DefaultCanvasGifImageRender = class extends exports.DefaultCanvasImageRender {
|
|
29971
|
-
constructor(imageRenderContribitions) {
|
|
29972
|
-
super(imageRenderContribitions), this.imageRenderContribitions = imageRenderContribitions, this.numberType = GIFIMAGE_NUMBER_TYPE, this._renderContribitions = void 0, this.builtinContributions = [defaultGifImageRenderContribution], this.init(imageRenderContribitions);
|
|
29973
|
-
}
|
|
29974
|
-
draw(image, renderService, drawContext) {
|
|
29975
|
-
const {
|
|
29976
|
-
context: context
|
|
29977
|
-
} = renderService.drawParams;
|
|
29978
|
-
if (!context) return;
|
|
29979
|
-
const imageAttribute = getTheme(image).image;
|
|
29980
|
-
this._draw(image, imageAttribute, !1, drawContext);
|
|
29981
|
-
}
|
|
29982
|
-
};
|
|
29983
|
-
DefaultCanvasGifImageRender = __decorate$2([injectable(), __param$1(0, inject(ContributionProvider)), __param$1(0, named(ImageRenderContribution)), __metadata$1("design:paramtypes", [Object])], DefaultCanvasGifImageRender);
|
|
29984
|
-
class DefaultGifImageRenderContribution extends DefaultRectRenderContribution {
|
|
29985
|
-
constructor() {
|
|
29986
|
-
super(...arguments), this.time = exports.BaseRenderContributionTime.afterFillStroke, this.useStyle = !0, this.order = 0;
|
|
29987
|
-
}
|
|
29988
|
-
drawShape(image, context, x, y, doFill, doStroke, fVisible, sVisible, rectAttribute, drawContext, fillCb, strokeCb) {
|
|
29989
|
-
image.renderFrame && image.playing && image.renderFrame(context, x, y);
|
|
29990
|
-
}
|
|
29991
|
-
}
|
|
29992
|
-
const defaultGifImageRenderContribution = new DefaultGifImageRenderContribution();
|
|
29993
|
-
|
|
29994
|
-
let loadGifImageModule = !1;
|
|
29995
|
-
const gifImageModule = new ContainerModule(bind => {
|
|
29996
|
-
loadGifImageModule || (loadGifImageModule = !0, bind(DefaultCanvasGifImageRender).toSelf().inSingletonScope(), bind(GraphicRender).toService(DefaultCanvasGifImageRender));
|
|
29997
|
-
});
|
|
29998
|
-
|
|
29999
29567
|
var lottie = {exports: {}};
|
|
30000
29568
|
|
|
30001
29569
|
(function(module,exports){typeof navigator!=="undefined"&&function(global,factory){module.exports=factory();}(commonjsGlobal,function(){var svgNS='http://www.w3.org/2000/svg';var locationHref='';var _useWebWorker=false;var initialDefaultFrame=-999999;var setWebWorker=function setWebWorker(flag){_useWebWorker=!!flag;};var getWebWorker=function getWebWorker(){return _useWebWorker;};var setLocationHref=function setLocationHref(value){locationHref=value;};var getLocationHref=function getLocationHref(){return locationHref;};function createTag(type){// return {appendChild:function(){},setAttribute:function(){},style:{}}
|
|
@@ -30897,7 +30465,7 @@
|
|
|
30897
30465
|
|
|
30898
30466
|
const roughModule = _roughModule;
|
|
30899
30467
|
|
|
30900
|
-
const version = "0.22.0-vstory.
|
|
30468
|
+
const version = "0.22.0-vstory.3";
|
|
30901
30469
|
preLoadAllModule();
|
|
30902
30470
|
if (isBrowserEnv()) {
|
|
30903
30471
|
loadBrowserEnv(container);
|
|
@@ -30961,7 +30529,6 @@
|
|
|
30961
30529
|
exports.CanvasAreaPicker = CanvasAreaPicker;
|
|
30962
30530
|
exports.CanvasCirclePicker = CanvasCirclePicker;
|
|
30963
30531
|
exports.CanvasFactory = CanvasFactory;
|
|
30964
|
-
exports.CanvasGifImagePicker = CanvasGifImagePicker;
|
|
30965
30532
|
exports.CanvasGlyphPicker = CanvasGlyphPicker;
|
|
30966
30533
|
exports.CanvasGroupPicker = CanvasGroupPicker;
|
|
30967
30534
|
exports.CanvasImagePicker = CanvasImagePicker;
|
|
@@ -31061,6 +30628,7 @@
|
|
|
31061
30628
|
exports.EventManager = EventManager;
|
|
31062
30629
|
exports.EventSystem = EventSystem;
|
|
31063
30630
|
exports.EventTarget = EventTarget;
|
|
30631
|
+
exports.FORMAT_ALL_TEXT_COMMAND = FORMAT_ALL_TEXT_COMMAND;
|
|
31064
30632
|
exports.FORMAT_ELEMENT_COMMAND = FORMAT_ELEMENT_COMMAND;
|
|
31065
30633
|
exports.FORMAT_TEXT_COMMAND = FORMAT_TEXT_COMMAND;
|
|
31066
30634
|
exports.Factory = Factory;
|
|
@@ -31076,7 +30644,6 @@
|
|
|
31076
30644
|
exports.GROUP_NUMBER_TYPE = GROUP_NUMBER_TYPE;
|
|
31077
30645
|
exports.Generator = Generator;
|
|
31078
30646
|
exports.Gesture = Gesture;
|
|
31079
|
-
exports.GifImage = GifImage;
|
|
31080
30647
|
exports.GlobalPickerService = GlobalPickerService;
|
|
31081
30648
|
exports.Glyph = Glyph;
|
|
31082
30649
|
exports.GlyphRender = GlyphRender;
|
|
@@ -31269,7 +30836,6 @@
|
|
|
31269
30836
|
exports.createCircle = createCircle;
|
|
31270
30837
|
exports.createColor = createColor;
|
|
31271
30838
|
exports.createConicalGradient = createConicalGradient;
|
|
31272
|
-
exports.createGifImage = createGifImage;
|
|
31273
30839
|
exports.createGlyph = createGlyph;
|
|
31274
30840
|
exports.createGroup = createGroup;
|
|
31275
30841
|
exports.createImage = createImage;
|
|
@@ -31356,6 +30922,7 @@
|
|
|
31356
30922
|
exports.getAttributeFromDefaultAttrList = getAttributeFromDefaultAttrList;
|
|
31357
30923
|
exports.getConicGradientAt = getConicGradientAt;
|
|
31358
30924
|
exports.getCurrentEnv = getCurrentEnv;
|
|
30925
|
+
exports.getDefaultCharacterConfig = getDefaultCharacterConfig;
|
|
31359
30926
|
exports.getExtraModelMatrix = getExtraModelMatrix;
|
|
31360
30927
|
exports.getModelMatrix = getModelMatrix;
|
|
31361
30928
|
exports.getRichTextBounds = getRichTextBounds;
|
|
@@ -31363,8 +30930,6 @@
|
|
|
31363
30930
|
exports.getTextBounds = getTextBounds;
|
|
31364
30931
|
exports.getTheme = getTheme;
|
|
31365
30932
|
exports.getThemeFromGroup = getThemeFromGroup;
|
|
31366
|
-
exports.gifImageCanvasPickModule = gifImageCanvasPickModule;
|
|
31367
|
-
exports.gifImageModule = gifImageModule;
|
|
31368
30933
|
exports.globalTheme = globalTheme;
|
|
31369
30934
|
exports.glyphCanvasPickModule = glyphCanvasPickModule;
|
|
31370
30935
|
exports.glyphMathPickModule = glyphMathPickModule;
|