@visactor/vrender 1.0.46-alpha.2 → 1.0.46
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 +10 -11
- package/cjs/index.js.map +1 -1
- package/dist/index.es.js +7 -8
- package/dist/index.js +7 -8
- 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 +7 -7
package/cjs/index.d.ts
CHANGED
package/cjs/index.js
CHANGED
|
@@ -21,17 +21,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
21
21
|
|
|
22
22
|
const vrender_core_1 = require("@visactor/vrender-core"), vrender_kits_1 = require("@visactor/vrender-kits"), vrender_kits_2 = require("@visactor/vrender-kits"), vrender_animate_1 = require("@visactor/vrender-animate");
|
|
23
23
|
|
|
24
|
-
exports.version = "1.0.46
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
(0, vrender_kits_2.
|
|
28
|
-
(0, vrender_kits_2.
|
|
29
|
-
(0, vrender_kits_2.
|
|
30
|
-
(0, vrender_kits_2.
|
|
31
|
-
|
|
32
|
-
(0, vrender_kits_2.
|
|
33
|
-
(0,
|
|
34
|
-
vrender_kits_1.registerStar)(), (0, vrender_core_1.registerFlexLayoutPlugin)(),
|
|
24
|
+
exports.version = "1.0.46", (0, vrender_core_1.preLoadAllModule)(), (0, vrender_core_1.isBrowserEnv)() ? (0,
|
|
25
|
+
vrender_kits_1.loadBrowserEnv)(vrender_core_1.container) : (0, vrender_core_1.isNodeEnv)() && (0,
|
|
26
|
+
vrender_kits_1.loadNodeEnv)(vrender_core_1.container), (0, vrender_kits_2.registerArc)(),
|
|
27
|
+
(0, vrender_kits_2.registerArc3d)(), (0, vrender_kits_2.registerArea)(), (0, vrender_kits_2.registerCircle)(),
|
|
28
|
+
(0, vrender_kits_2.registerGlyph)(), (0, vrender_kits_2.registerGroup)(), (0, vrender_kits_2.registerImage)(),
|
|
29
|
+
(0, vrender_kits_2.registerLine)(), (0, vrender_kits_2.registerPath)(), (0, vrender_kits_2.registerPolygon)(),
|
|
30
|
+
(0, vrender_kits_2.registerPyramid3d)(), (0, vrender_kits_2.registerRect)(), (0,
|
|
31
|
+
vrender_kits_2.registerRect3d)(), (0, vrender_kits_2.registerRichtext)(), (0, vrender_kits_2.registerShadowRoot)(),
|
|
32
|
+
(0, vrender_kits_2.registerSymbol)(), (0, vrender_kits_2.registerText)(), (0, vrender_kits_2.registerWrapText)(),
|
|
33
|
+
(0, vrender_kits_1.registerStar)(), (0, vrender_core_1.registerFlexLayoutPlugin)(),
|
|
35
34
|
(0, vrender_core_1.registerViewTransform3dPlugin)(), (0, vrender_core_1.registerHtmlAttributePlugin)(),
|
|
36
35
|
(0, vrender_core_1.registerReactAttributePlugin)(), (0, vrender_core_1.registerDirectionalLight)(),
|
|
37
36
|
(0, vrender_core_1.registerOrthoCamera)(), (0, vrender_animate_1.registerCustomAnimate)(),
|
package/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,kCAAgC;AAChC,yDAWgC;AAChC,yDAAmF;AACnF,yDAmBgC;AAChC,+DAAmF;AAEtE,QAAA,OAAO,GAAG,
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,kCAAgC;AAChC,yDAWgC;AAChC,yDAAmF;AACnF,yDAmBgC;AAChC,+DAAmF;AAEtE,QAAA,OAAO,GAAG,QAAQ,CAAC;AAEhC,IAAA,+BAAgB,GAAE,CAAC;AAEnB,IAAI,IAAA,2BAAY,GAAE,EAAE;IAClB,IAAA,6BAAc,EAAC,wBAAS,CAAC,CAAC;CAC3B;KAAM,IAAI,IAAA,wBAAS,GAAE,EAAE;IACtB,IAAA,0BAAW,EAAC,wBAAS,CAAC,CAAC;CACxB;AACD,IAAA,0BAAW,GAAE,CAAC;AACd,IAAA,4BAAa,GAAE,CAAC;AAChB,IAAA,2BAAY,GAAE,CAAC;AACf,IAAA,6BAAc,GAAE,CAAC;AACjB,IAAA,4BAAa,GAAE,CAAC;AAChB,IAAA,4BAAa,GAAE,CAAC;AAChB,IAAA,4BAAa,GAAE,CAAC;AAChB,IAAA,2BAAY,GAAE,CAAC;AACf,IAAA,2BAAY,GAAE,CAAC;AACf,IAAA,8BAAe,GAAE,CAAC;AAClB,IAAA,gCAAiB,GAAE,CAAC;AACpB,IAAA,2BAAY,GAAE,CAAC;AACf,IAAA,6BAAc,GAAE,CAAC;AACjB,IAAA,+BAAgB,GAAE,CAAC;AACnB,IAAA,iCAAkB,GAAE,CAAC;AACrB,IAAA,6BAAc,GAAE,CAAC;AACjB,IAAA,2BAAY,GAAE,CAAC;AACf,IAAA,+BAAgB,GAAE,CAAC;AACnB,IAAA,2BAAY,GAAE,CAAC;AAEf,IAAA,uCAAwB,GAAE,CAAC;AAC3B,IAAA,4CAA6B,GAAE,CAAC;AAChC,IAAA,0CAA2B,GAAE,CAAC;AAC9B,IAAA,2CAA4B,GAAE,CAAC;AAC/B,IAAA,uCAAwB,GAAE,CAAC;AAC3B,IAAA,kCAAmB,GAAE,CAAC;AAEtB,IAAA,uCAAqB,GAAE,CAAC;AACxB,IAAA,iCAAe,GAAE,CAAC;AAElB,yDAAuC;AACvC,yDAAuC;AACvC,4DAA0C;AAC1C,+DAA6C;AAG7C,6DAAkD;AAAzC,wGAAA,KAAK,OAAA;AACd,uDAAmD;AAA1C,yGAAA,SAAS,OAAA","file":"index.js","sourcesContent":["import '@visactor/vrender-core';\nimport {\n container,\n isBrowserEnv,\n isNodeEnv,\n preLoadAllModule,\n registerFlexLayoutPlugin,\n registerViewTransform3dPlugin,\n registerHtmlAttributePlugin,\n registerReactAttributePlugin,\n registerDirectionalLight,\n registerOrthoCamera\n} from '@visactor/vrender-core';\nimport { loadBrowserEnv, loadNodeEnv, registerStar } from '@visactor/vrender-kits';\nimport {\n registerArc,\n registerArc3d,\n registerArea,\n registerCircle,\n registerGlyph,\n registerGroup,\n registerImage,\n registerLine,\n registerPath,\n registerPolygon,\n registerPyramid3d,\n registerRect,\n registerRect3d,\n registerRichtext,\n registerShadowRoot,\n registerSymbol,\n registerText,\n registerWrapText\n} from '@visactor/vrender-kits';\nimport { registerCustomAnimate, registerAnimate } from '@visactor/vrender-animate';\n// 导出版本号\nexport const version = \"1.0.46\";\n\npreLoadAllModule();\n\nif (isBrowserEnv()) {\n loadBrowserEnv(container);\n} else if (isNodeEnv()) {\n loadNodeEnv(container);\n}\nregisterArc();\nregisterArc3d();\nregisterArea();\nregisterCircle();\nregisterGlyph();\nregisterGroup();\nregisterImage();\nregisterLine();\nregisterPath();\nregisterPolygon();\nregisterPyramid3d();\nregisterRect();\nregisterRect3d();\nregisterRichtext();\nregisterShadowRoot();\nregisterSymbol();\nregisterText();\nregisterWrapText();\nregisterStar();\n\nregisterFlexLayoutPlugin();\nregisterViewTransform3dPlugin();\nregisterHtmlAttributePlugin();\nregisterReactAttributePlugin();\nregisterDirectionalLight();\nregisterOrthoCamera();\n\nregisterCustomAnimate();\nregisterAnimate();\n\nexport * from '@visactor/vrender-core';\nexport * from '@visactor/vrender-kits';\nexport * from '@visactor/vrender-animate';\nexport * from '@visactor/vrender-components';\n\n// avoid naming conflicts with 'State' & 'Direction' in '@visactor/vrender-components'\nexport { State } from '@visactor/vrender-animate';\nexport { Direction } from '@visactor/vrender-core';\n"]}
|
package/dist/index.es.js
CHANGED
|
@@ -4685,9 +4685,7 @@ const DefaultStyle = Object.assign(Object.assign(Object.assign(Object.assign({
|
|
|
4685
4685
|
background: null,
|
|
4686
4686
|
autoAnimateTexture: !1,
|
|
4687
4687
|
textureRatio: 1,
|
|
4688
|
-
textureOptions:
|
|
4689
|
-
alignToGraphic: !0
|
|
4690
|
-
},
|
|
4688
|
+
textureOptions: null,
|
|
4691
4689
|
backgroundOpacity: 1,
|
|
4692
4690
|
backgroundCornerRadius: 0,
|
|
4693
4691
|
texture: null,
|
|
@@ -9514,7 +9512,7 @@ class Graphic extends Node {
|
|
|
9514
9512
|
}
|
|
9515
9513
|
constructor(params = {}) {
|
|
9516
9514
|
var _a;
|
|
9517
|
-
super(), this._AABBBounds = new AABBBounds(), this._updateTag = UpdateTag.INIT, this.attribute = params, this.valid = this.isValid(), this.updateAABBBoundsStamp = 0, params.background && this.loadImage(null !== (_a = params.background.background) && void 0 !== _a ? _a : params.background, !0), isExternalTexture(params.texture)
|
|
9515
|
+
super(), this._AABBBounds = new AABBBounds(), this._updateTag = UpdateTag.INIT, this.attribute = params, this.valid = this.isValid(), this.updateAABBBoundsStamp = 0, params.background && this.loadImage(null !== (_a = params.background.background) && void 0 !== _a ? _a : params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic);
|
|
9518
9516
|
}
|
|
9519
9517
|
getGraphicService() {
|
|
9520
9518
|
var _a, _b;
|
|
@@ -9703,7 +9701,7 @@ class Graphic extends Node {
|
|
|
9703
9701
|
});
|
|
9704
9702
|
}
|
|
9705
9703
|
setAttributes(params, forceUpdateTag = !1, context) {
|
|
9706
|
-
params && ((params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params).background && this.loadImage(params.background, !0), isExternalTexture(params.texture)
|
|
9704
|
+
params && ((params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params).background && this.loadImage(params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic), this._setAttributes(params, forceUpdateTag, context));
|
|
9707
9705
|
}
|
|
9708
9706
|
_setAttributes(params, forceUpdateTag = !1, context) {
|
|
9709
9707
|
const keys = Object.keys(params);
|
|
@@ -9737,7 +9735,7 @@ class Graphic extends Node {
|
|
|
9737
9735
|
const context = {
|
|
9738
9736
|
type: AttributeUpdateType.INIT
|
|
9739
9737
|
};
|
|
9740
|
-
params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params, this.attribute = params, params.background && this.loadImage(params.background, !0), isExternalTexture(params.texture)
|
|
9738
|
+
params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params, this.attribute = params, params.background && this.loadImage(params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic), this._updateTag = UpdateTag.INIT, this.valid = this.isValid(), this.onAttributeUpdate(context);
|
|
9741
9739
|
}
|
|
9742
9740
|
translate(x, y) {
|
|
9743
9741
|
var _a, _b;
|
|
@@ -14058,6 +14056,7 @@ class DefaultBaseClipRenderAfterContribution {
|
|
|
14058
14056
|
}
|
|
14059
14057
|
const defaultBaseClipRenderAfterContribution = new DefaultBaseClipRenderAfterContribution();
|
|
14060
14058
|
|
|
14059
|
+
const builtinProceduralTextureTypes = new Set(["circle", "diamond", "rect", "vertical-line", "horizontal-line", "bias-lr", "bias-rl", "grid"]);
|
|
14061
14060
|
function formatRatio(ratio) {
|
|
14062
14061
|
return ratio <= .5 ? 4 * ratio - 1 : -4 * ratio + 3;
|
|
14063
14062
|
}
|
|
@@ -14278,7 +14277,7 @@ class DefaultBaseTextureRenderContribution {
|
|
|
14278
14277
|
}
|
|
14279
14278
|
}
|
|
14280
14279
|
getPatternCacheKey(texture, textureSize, texturePadding, textureColor, dpr, textureRadius) {
|
|
14281
|
-
return "string" != typeof texture ? texturePadding > 0 || textureRadius > 0 ? null : texture : "wave" === texture ? null :
|
|
14280
|
+
return "string" != typeof texture ? texturePadding > 0 || textureRadius > 0 ? null : texture : "wave" === texture ? null : builtinProceduralTextureTypes.has(texture) ? `builtin:${texture}|size:${textureSize}|padding:${texturePadding}|color:${textureColor}|dpr:${dpr}` : `resource:${texture}|padding:${texturePadding}|radius:${textureRadius}|dpr:${dpr}`;
|
|
14282
14281
|
}
|
|
14283
14282
|
createResourcePattern(texture, graphic, context, texturePadding, textureRadius) {
|
|
14284
14283
|
var _a;
|
|
@@ -52992,7 +52991,7 @@ TableSeriesNumber.defaultAttributes = {
|
|
|
52992
52991
|
select: !0
|
|
52993
52992
|
};
|
|
52994
52993
|
|
|
52995
|
-
const version = "1.0.46
|
|
52994
|
+
const version = "1.0.46";
|
|
52996
52995
|
preLoadAllModule();
|
|
52997
52996
|
if (isBrowserEnv()) {
|
|
52998
52997
|
loadBrowserEnv(container);
|
package/dist/index.js
CHANGED
|
@@ -4691,9 +4691,7 @@
|
|
|
4691
4691
|
background: null,
|
|
4692
4692
|
autoAnimateTexture: !1,
|
|
4693
4693
|
textureRatio: 1,
|
|
4694
|
-
textureOptions:
|
|
4695
|
-
alignToGraphic: !0
|
|
4696
|
-
},
|
|
4694
|
+
textureOptions: null,
|
|
4697
4695
|
backgroundOpacity: 1,
|
|
4698
4696
|
backgroundCornerRadius: 0,
|
|
4699
4697
|
texture: null,
|
|
@@ -9520,7 +9518,7 @@
|
|
|
9520
9518
|
}
|
|
9521
9519
|
constructor(params = {}) {
|
|
9522
9520
|
var _a;
|
|
9523
|
-
super(), this._AABBBounds = new AABBBounds(), this._updateTag = exports.UpdateTag.INIT, this.attribute = params, this.valid = this.isValid(), this.updateAABBBoundsStamp = 0, params.background && this.loadImage(null !== (_a = params.background.background) && void 0 !== _a ? _a : params.background, !0), isExternalTexture(params.texture)
|
|
9521
|
+
super(), this._AABBBounds = new AABBBounds(), this._updateTag = exports.UpdateTag.INIT, this.attribute = params, this.valid = this.isValid(), this.updateAABBBoundsStamp = 0, params.background && this.loadImage(null !== (_a = params.background.background) && void 0 !== _a ? _a : params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic);
|
|
9524
9522
|
}
|
|
9525
9523
|
getGraphicService() {
|
|
9526
9524
|
var _a, _b;
|
|
@@ -9709,7 +9707,7 @@
|
|
|
9709
9707
|
});
|
|
9710
9708
|
}
|
|
9711
9709
|
setAttributes(params, forceUpdateTag = !1, context) {
|
|
9712
|
-
params && ((params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params).background && this.loadImage(params.background, !0), isExternalTexture(params.texture)
|
|
9710
|
+
params && ((params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params).background && this.loadImage(params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic), this._setAttributes(params, forceUpdateTag, context));
|
|
9713
9711
|
}
|
|
9714
9712
|
_setAttributes(params, forceUpdateTag = !1, context) {
|
|
9715
9713
|
const keys = Object.keys(params);
|
|
@@ -9743,7 +9741,7 @@
|
|
|
9743
9741
|
const context = {
|
|
9744
9742
|
type: exports.AttributeUpdateType.INIT
|
|
9745
9743
|
};
|
|
9746
|
-
params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params, this.attribute = params, params.background && this.loadImage(params.background, !0), isExternalTexture(params.texture)
|
|
9744
|
+
params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params, this.attribute = params, params.background && this.loadImage(params.background, !0), isExternalTexture(params.texture) && this.loadImage(params.texture, !1), params.shadowGraphic && this.setShadowGraphic(params.shadowGraphic), this._updateTag = exports.UpdateTag.INIT, this.valid = this.isValid(), this.onAttributeUpdate(context);
|
|
9747
9745
|
}
|
|
9748
9746
|
translate(x, y) {
|
|
9749
9747
|
var _a, _b;
|
|
@@ -14064,6 +14062,7 @@
|
|
|
14064
14062
|
}
|
|
14065
14063
|
const defaultBaseClipRenderAfterContribution = new DefaultBaseClipRenderAfterContribution();
|
|
14066
14064
|
|
|
14065
|
+
const builtinProceduralTextureTypes = new Set(["circle", "diamond", "rect", "vertical-line", "horizontal-line", "bias-lr", "bias-rl", "grid"]);
|
|
14067
14066
|
function formatRatio(ratio) {
|
|
14068
14067
|
return ratio <= .5 ? 4 * ratio - 1 : -4 * ratio + 3;
|
|
14069
14068
|
}
|
|
@@ -14284,7 +14283,7 @@
|
|
|
14284
14283
|
}
|
|
14285
14284
|
}
|
|
14286
14285
|
getPatternCacheKey(texture, textureSize, texturePadding, textureColor, dpr, textureRadius) {
|
|
14287
|
-
return "string" != typeof texture ? texturePadding > 0 || textureRadius > 0 ? null : texture : "wave" === texture ? null :
|
|
14286
|
+
return "string" != typeof texture ? texturePadding > 0 || textureRadius > 0 ? null : texture : "wave" === texture ? null : builtinProceduralTextureTypes.has(texture) ? `builtin:${texture}|size:${textureSize}|padding:${texturePadding}|color:${textureColor}|dpr:${dpr}` : `resource:${texture}|padding:${texturePadding}|radius:${textureRadius}|dpr:${dpr}`;
|
|
14288
14287
|
}
|
|
14289
14288
|
createResourcePattern(texture, graphic, context, texturePadding, textureRadius) {
|
|
14290
14289
|
var _a;
|
|
@@ -52998,7 +52997,7 @@
|
|
|
52998
52997
|
select: !0
|
|
52999
52998
|
};
|
|
53000
52999
|
|
|
53001
|
-
const version = "1.0.46
|
|
53000
|
+
const version = "1.0.46";
|
|
53002
53001
|
preLoadAllModule();
|
|
53003
53002
|
if (isBrowserEnv()) {
|
|
53004
53003
|
loadBrowserEnv(container);
|