@visactor/vrender-components 1.1.4-alpha.0 → 1.1.4-alpha.2
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/animation/animate-component.js +1 -1
- package/cjs/animation/axis-animate.js +1 -1
- package/cjs/animation/exit-release.js +1 -1
- package/cjs/animation/label-animate.js +1 -1
- package/cjs/animation/static-truth.js +1 -1
- package/cjs/axis/util.js +1 -2
- package/cjs/brush/type.js +2 -1
- package/cjs/checkbox/register.js +2 -1
- package/cjs/crosshair/polygon-sector.js +1 -2
- package/cjs/data-zoom/interaction.js +2 -1
- package/cjs/empty-tip/register.js +1 -2
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/jsx/index.js +1 -1
- package/cjs/label/arc.js +1 -1
- package/cjs/label/base.js +1 -1
- package/cjs/label/data-label-register.js +1 -1
- package/cjs/label/dataLabel.js +1 -1
- package/cjs/legend/discrete/discrete.d.ts +1 -0
- package/cjs/legend/discrete/discrete.js +54 -27
- package/cjs/legend/discrete/discrete.js.map +1 -1
- package/cjs/legend/discrete/type.d.ts +1 -0
- package/cjs/legend/discrete/type.js.map +1 -1
- package/dist/index.es.js +172 -58
- package/es/animation/animate-component.js +1 -1
- package/es/animation/axis-animate.js +1 -1
- package/es/animation/exit-release.js +1 -1
- package/es/animation/label-animate.js +1 -1
- package/es/animation/static-truth.js +1 -1
- package/es/axis/util.js +1 -2
- package/es/brush/type.js +2 -1
- package/es/checkbox/register.js +2 -1
- package/es/crosshair/polygon-sector.js +1 -2
- package/es/data-zoom/interaction.js +2 -1
- package/es/empty-tip/register.js +1 -2
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/jsx/index.js +1 -1
- package/es/label/arc.js +1 -1
- package/es/label/base.js +1 -1
- package/es/label/data-label-register.js +1 -1
- package/es/label/dataLabel.js +1 -1
- package/es/legend/discrete/discrete.d.ts +1 -0
- package/es/legend/discrete/discrete.js +51 -25
- package/es/legend/discrete/discrete.js.map +1 -1
- package/es/legend/discrete/type.d.ts +1 -0
- package/es/legend/discrete/type.js.map +1 -1
- package/package.json +6 -6
package/dist/index.es.js
CHANGED
|
@@ -208,7 +208,7 @@ class Node extends EventEmitter {
|
|
|
208
208
|
constructor() {
|
|
209
209
|
super(), this._uid = Generator.GenAutoIncrementId(), this._firstChild = null, this._lastChild = null, this.parent = null, this._count = 1;
|
|
210
210
|
}
|
|
211
|
-
onParentSharedStateTreeChanged(_stage, _layer) {}
|
|
211
|
+
onParentSharedStateTreeChanged(_stage, _layer, _inheritedSharedStateScope) {}
|
|
212
212
|
forEachChildren(cb, reverse = !1) {
|
|
213
213
|
if (reverse) {
|
|
214
214
|
let child = this._lastChild,
|
|
@@ -4449,6 +4449,8 @@ class StateEngine {
|
|
|
4449
4449
|
this.graphic === graphic && this.baseAttributes === baseAttributes || this.invalidateResolverCache(), this.graphic = graphic, this.baseAttributes = baseAttributes;
|
|
4450
4450
|
}
|
|
4451
4451
|
applyStates(stateNames) {
|
|
4452
|
+
const singleStaticStateResult = this.tryApplySingleStaticState(stateNames);
|
|
4453
|
+
if (singleStaticStateResult) return singleStaticStateResult;
|
|
4452
4454
|
const uniqueStates = Array.from(new Set(stateNames)),
|
|
4453
4455
|
sortedStates = this.sortStates(uniqueStates),
|
|
4454
4456
|
adjudicated = this.adjudicate(sortedStates),
|
|
@@ -4463,6 +4465,19 @@ class StateEngine {
|
|
|
4463
4465
|
suppressed: [...this._suppressed]
|
|
4464
4466
|
};
|
|
4465
4467
|
}
|
|
4468
|
+
tryApplySingleStaticState(stateNames) {
|
|
4469
|
+
if (1 !== stateNames.length || "shallow" !== this.mergeMode) return;
|
|
4470
|
+
const stateName = stateNames[0],
|
|
4471
|
+
definition = this.compiledDefinitions.get(stateName);
|
|
4472
|
+
if (definition && (definition.hasResolver || definition.exclude.size || definition.suppress.size)) return;
|
|
4473
|
+
const changed = 1 !== this._activeStates.length || this._activeStates[0] !== stateName || 1 !== this._effectiveStates.length || this._effectiveStates[0] !== stateName || 0 !== this._suppressed.length;
|
|
4474
|
+
return this._activeStates = [stateName], this._effectiveStates = [stateName], this._suppressed = [], !changed && this.resolverCacheValid || (this.resolverPatchCache.clear(), this.resolverCacheKey = stateName, this.resolverCacheValid = !0, this._resolvedPatch = (null == definition ? void 0 : definition.patch) ? cloneValue(definition.patch) : {}), {
|
|
4475
|
+
changed: changed,
|
|
4476
|
+
activeStates: [...this._activeStates],
|
|
4477
|
+
effectiveStates: [...this._effectiveStates],
|
|
4478
|
+
suppressed: []
|
|
4479
|
+
};
|
|
4480
|
+
}
|
|
4466
4481
|
addState(stateName, keepCurrentStates) {
|
|
4467
4482
|
if (this._activeStates.includes(stateName) && (keepCurrentStates || 1 === this._activeStates.length)) return {
|
|
4468
4483
|
changed: !1,
|
|
@@ -4814,12 +4829,12 @@ const NOWORK_ANIMATE_ATTR = {
|
|
|
4814
4829
|
cursor: 1,
|
|
4815
4830
|
html: 1
|
|
4816
4831
|
};
|
|
4817
|
-
class
|
|
4832
|
+
class GraphicImpl extends Node {
|
|
4818
4833
|
static mixin(source) {
|
|
4819
4834
|
const keys = Object.keys(source);
|
|
4820
4835
|
for (let i = 0; i < keys.length; ++i) {
|
|
4821
4836
|
const propertyName = keys[i];
|
|
4822
|
-
Object.defineProperty(
|
|
4837
|
+
Object.defineProperty(this.prototype, propertyName, Object.getOwnPropertyDescriptor(source, propertyName));
|
|
4823
4838
|
}
|
|
4824
4839
|
}
|
|
4825
4840
|
get AABBBounds() {
|
|
@@ -4875,14 +4890,17 @@ class Graphic extends Node {
|
|
|
4875
4890
|
}
|
|
4876
4891
|
return null === (_a = this.stage) || void 0 === _a ? void 0 : _a.rootSharedStateScope;
|
|
4877
4892
|
}
|
|
4878
|
-
|
|
4893
|
+
syncSharedStateScopeBinding(nextScope, markDirty = !0) {
|
|
4879
4894
|
var _a;
|
|
4880
|
-
const nextScope = this.resolveBoundSharedStateScope();
|
|
4881
4895
|
return this.boundSharedStateScope === nextScope ? (this.syncSharedStateActiveRegistrations(), !1) : (this.boundSharedStateScope = nextScope, this.boundSharedStateRevision = void 0, this.compiledStateDefinitions = void 0, this.compiledStateDefinitionsCacheKey = void 0, this.stateEngine = void 0, this.stateEngineCompiledDefinitions = void 0, this.syncSharedStateActiveRegistrations(), markDirty && (null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length) && this.markSharedStateDirty(), !0);
|
|
4882
4896
|
}
|
|
4883
|
-
|
|
4897
|
+
syncSharedStateScopeBindingFromTree(markDirty = !0, inheritedSharedStateScope) {
|
|
4898
|
+
const nextScope = void 0 === inheritedSharedStateScope ? this.resolveBoundSharedStateScope() : null != inheritedSharedStateScope ? inheritedSharedStateScope : void 0;
|
|
4899
|
+
return this.syncSharedStateScopeBinding(nextScope, markDirty);
|
|
4900
|
+
}
|
|
4901
|
+
syncSharedStateScopeBindingOnTreeChange(markDirty = !0, inheritedSharedStateScope) {
|
|
4884
4902
|
var _a, _b;
|
|
4885
|
-
return !!((null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length) || this.boundSharedStateScope || (null === (_b = this.registeredActiveScopes) || void 0 === _b ? void 0 : _b.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingFromTree(markDirty);
|
|
4903
|
+
return !!((null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length) || this.boundSharedStateScope || (null === (_b = this.registeredActiveScopes) || void 0 === _b ? void 0 : _b.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingFromTree(markDirty, inheritedSharedStateScope);
|
|
4886
4904
|
}
|
|
4887
4905
|
syncSharedStateActiveRegistrations() {
|
|
4888
4906
|
var _a;
|
|
@@ -4890,6 +4908,7 @@ class Graphic extends Node {
|
|
|
4890
4908
|
if (!(null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length) || !this.boundSharedStateScope) return (null == previousScopes ? void 0 : previousScopes.size) && (previousScopes.forEach(scope => {
|
|
4891
4909
|
scope.subtreeActiveDescendants.delete(this);
|
|
4892
4910
|
}), previousScopes.clear()), void (this.registeredActiveScopes = void 0);
|
|
4911
|
+
if ((null == previousScopes ? void 0 : previousScopes.size) && this.isSharedStateScopeChainRegistered(previousScopes)) return;
|
|
4893
4912
|
const nextScopes = new Set(collectSharedStateScopeChain(this.boundSharedStateScope));
|
|
4894
4913
|
null == previousScopes || previousScopes.forEach(scope => {
|
|
4895
4914
|
nextScopes.has(scope) || scope.subtreeActiveDescendants.delete(this);
|
|
@@ -4897,6 +4916,15 @@ class Graphic extends Node {
|
|
|
4897
4916
|
scope.subtreeActiveDescendants.add(this);
|
|
4898
4917
|
}), this.registeredActiveScopes = nextScopes;
|
|
4899
4918
|
}
|
|
4919
|
+
isSharedStateScopeChainRegistered(previousScopes) {
|
|
4920
|
+
let scope = this.boundSharedStateScope,
|
|
4921
|
+
scopeCount = 0;
|
|
4922
|
+
for (; scope;) {
|
|
4923
|
+
if (!previousScopes.has(scope)) return !1;
|
|
4924
|
+
scopeCount += 1, scope = scope.parentScope;
|
|
4925
|
+
}
|
|
4926
|
+
return scopeCount === previousScopes.size;
|
|
4927
|
+
}
|
|
4900
4928
|
clearSharedStateActiveRegistrations() {
|
|
4901
4929
|
const previousScopes = this.registeredActiveScopes;
|
|
4902
4930
|
previousScopes && (previousScopes.forEach(scope => {
|
|
@@ -4906,8 +4934,8 @@ class Graphic extends Node {
|
|
|
4906
4934
|
markSharedStateDirty() {
|
|
4907
4935
|
this.sharedStateDirty = !0, enqueueGraphicSharedStateRefresh(this.stage, this), scheduleStageSharedStateRefresh(this.stage);
|
|
4908
4936
|
}
|
|
4909
|
-
onParentSharedStateTreeChanged(stage, layer) {
|
|
4910
|
-
this.stage === stage && this.layer === layer ? this.syncSharedStateScopeBindingOnTreeChange() : this.setStage(stage, layer);
|
|
4937
|
+
onParentSharedStateTreeChanged(stage, layer, inheritedSharedStateScope) {
|
|
4938
|
+
this.stage === stage && this.layer === layer ? this.syncSharedStateScopeBindingOnTreeChange(!0, inheritedSharedStateScope) : this.setStage(stage, layer, inheritedSharedStateScope);
|
|
4911
4939
|
}
|
|
4912
4940
|
refreshSharedStateBeforeRender() {
|
|
4913
4941
|
var _a;
|
|
@@ -5558,6 +5586,10 @@ class Graphic extends Node {
|
|
|
5558
5586
|
var _a;
|
|
5559
5587
|
return null === (_a = this.states) || void 0 === _a ? void 0 : _a[stateName];
|
|
5560
5588
|
}
|
|
5589
|
+
setStateDefinitionsWithCompiled(definitions, compiledDefinitions) {
|
|
5590
|
+
var _a;
|
|
5591
|
+
this.states = definitions, this.localStateDefinitionsSource !== definitions && (this.localStateDefinitionsSource = definitions, this.localStateDefinitionsVersion = (null !== (_a = this.localStateDefinitionsVersion) && void 0 !== _a ? _a : 0) + 1), this.compiledStateDefinitions = compiledDefinitions, this.compiledStateDefinitionsCacheKey = `local:${this.localStateDefinitionsVersion}`;
|
|
5592
|
+
}
|
|
5561
5593
|
getStateResolveBaseAttrs() {
|
|
5562
5594
|
var _a;
|
|
5563
5595
|
return null !== (_a = this.baseAttributes) && void 0 !== _a ? _a : this.attribute;
|
|
@@ -5751,8 +5783,10 @@ class Graphic extends Node {
|
|
|
5751
5783
|
transition.changed && this.useStates(transition.states, hasAnimation);
|
|
5752
5784
|
}
|
|
5753
5785
|
addState(stateName, keepCurrentStates, hasAnimation) {
|
|
5754
|
-
const
|
|
5755
|
-
|
|
5786
|
+
const currentStates = this.currentStates;
|
|
5787
|
+
if ((null == currentStates ? void 0 : currentStates.includes(stateName)) && (keepCurrentStates || 1 === currentStates.length)) return;
|
|
5788
|
+
const nextStates = keepCurrentStates && (null == currentStates ? void 0 : currentStates.length) ? currentStates.concat([stateName]) : [stateName];
|
|
5789
|
+
this.useStates(nextStates, hasAnimation);
|
|
5756
5790
|
}
|
|
5757
5791
|
setStates(states, options) {
|
|
5758
5792
|
var _a, _b, _c;
|
|
@@ -5905,12 +5939,12 @@ class Graphic extends Node {
|
|
|
5905
5939
|
this._globalTransMatrix.translate(scrollX, scrollY);
|
|
5906
5940
|
}
|
|
5907
5941
|
}
|
|
5908
|
-
setStage(stage, layer) {
|
|
5942
|
+
setStage(stage, layer, inheritedSharedStateScope) {
|
|
5909
5943
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
5910
5944
|
const graphicService = null !== (_c = null !== (_a = null == stage ? void 0 : stage.graphicService) && void 0 !== _a ? _a : null === (_b = this.stage) || void 0 === _b ? void 0 : _b.graphicService) && void 0 !== _c ? _c : application.graphicService,
|
|
5911
5945
|
previousStage = this.stage;
|
|
5912
5946
|
if (this.stage !== stage || this.layer !== layer) {
|
|
5913
|
-
if (this.stage = stage, this.layer = layer, ((null === (_d = this.currentStates) || void 0 === _d ? void 0 : _d.length) || this.boundSharedStateScope || (null === (_e = this.registeredActiveScopes) || void 0 === _e ? void 0 : _e.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingOnTreeChange(!0), this.setStageToShadowRoot(stage, layer), this.mayHaveTrackedAnimates() && this.hasAnyTrackedAnimate()) {
|
|
5947
|
+
if (this.stage = stage, this.layer = layer, ((null === (_d = this.currentStates) || void 0 === _d ? void 0 : _d.length) || this.boundSharedStateScope || (null === (_e = this.registeredActiveScopes) || void 0 === _e ? void 0 : _e.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingOnTreeChange(!0, inheritedSharedStateScope), this.setStageToShadowRoot(stage, layer), this.mayHaveTrackedAnimates() && this.hasAnyTrackedAnimate()) {
|
|
5914
5948
|
const previousTimeline = null === (_f = null == previousStage ? void 0 : previousStage.getTimeline) || void 0 === _f ? void 0 : _f.call(previousStage),
|
|
5915
5949
|
nextTimeline = null === (_g = null == stage ? void 0 : stage.getTimeline) || void 0 === _g ? void 0 : _g.call(stage),
|
|
5916
5950
|
detachedStageAnimates = [];
|
|
@@ -5927,7 +5961,7 @@ class Graphic extends Node {
|
|
|
5927
5961
|
}
|
|
5928
5962
|
return this._onSetStage && this._onSetStage(this, stage, layer), void (null === (_h = null == graphicService ? void 0 : graphicService.onSetStage) || void 0 === _h || _h.call(graphicService, this, stage));
|
|
5929
5963
|
}
|
|
5930
|
-
((null === (_j = this.currentStates) || void 0 === _j ? void 0 : _j.length) || this.boundSharedStateScope || (null === (_k = this.registeredActiveScopes) || void 0 === _k ? void 0 : _k.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingOnTreeChange(!0);
|
|
5964
|
+
((null === (_j = this.currentStates) || void 0 === _j ? void 0 : _j.length) || this.boundSharedStateScope || (null === (_k = this.registeredActiveScopes) || void 0 === _k ? void 0 : _k.size) || this.sharedStateDirty) && this.syncSharedStateScopeBindingOnTreeChange(!0, inheritedSharedStateScope);
|
|
5931
5965
|
}
|
|
5932
5966
|
detachStageForRelease() {
|
|
5933
5967
|
var _a, _b, _c;
|
|
@@ -6058,13 +6092,26 @@ class Graphic extends Node {
|
|
|
6058
6092
|
return null;
|
|
6059
6093
|
}
|
|
6060
6094
|
}
|
|
6095
|
+
GraphicImpl.userSymbolMap = {};
|
|
6096
|
+
const GRAPHIC_CLASS_SYMBOL = Symbol.for("@visactor/vrender-core/graphic-class");
|
|
6097
|
+
function createGraphicClassState() {
|
|
6098
|
+
return {
|
|
6099
|
+
Graphic: GraphicImpl
|
|
6100
|
+
};
|
|
6101
|
+
}
|
|
6102
|
+
function getGraphicClassState() {
|
|
6103
|
+
var _a;
|
|
6104
|
+
const globalScope = globalThis;
|
|
6105
|
+
return null !== (_a = globalScope[GRAPHIC_CLASS_SYMBOL]) && void 0 !== _a || (globalScope[GRAPHIC_CLASS_SYMBOL] = createGraphicClassState()), globalScope[GRAPHIC_CLASS_SYMBOL];
|
|
6106
|
+
}
|
|
6107
|
+
const Graphic = getGraphicClassState().Graphic;
|
|
6061
6108
|
function backgroundNotImage(image) {
|
|
6062
6109
|
return "string" == typeof image ? !(image.startsWith("<svg") || isValidUrl(image) || image.includes("/") || isBase64(image)) : !(!image.fill && !image.stroke) || !("string" != typeof image.gradient || !Array.isArray(image.stops));
|
|
6063
6110
|
}
|
|
6064
6111
|
function isExternalTexture(texture) {
|
|
6065
6112
|
return !!texture && ("string" == typeof texture ? !builtinTextureTypes.has(texture) && (texture.startsWith("<svg") || isValidUrl(texture) || texture.includes("/") || isBase64(texture)) : isObject(texture));
|
|
6066
6113
|
}
|
|
6067
|
-
Graphic.
|
|
6114
|
+
Graphic.mixin(EventTarget);
|
|
6068
6115
|
|
|
6069
6116
|
const defaultThemeObj = {
|
|
6070
6117
|
arc: DefaultArcAttribute,
|
|
@@ -6303,17 +6350,17 @@ class Group extends Graphic {
|
|
|
6303
6350
|
}
|
|
6304
6351
|
incrementalAppendChild(node) {
|
|
6305
6352
|
const data = super.appendChild(node);
|
|
6306
|
-
return data && this.syncChildSharedStateTreeBinding(data), this.addUpdateBoundTag(), this.getGraphicService().onAddIncremental(node, this, this.stage), data;
|
|
6353
|
+
return data && this.shouldSyncChildSharedStateTreeBinding(data) && this.syncChildSharedStateTreeBinding(data), this.addUpdateBoundTag(), this.getGraphicService().onAddIncremental(node, this, this.stage), data;
|
|
6307
6354
|
}
|
|
6308
6355
|
incrementalClearChild() {
|
|
6309
6356
|
super.removeAllChild(), this.addUpdateBoundTag(), this.getGraphicService().onClearIncremental(this, this.stage);
|
|
6310
6357
|
}
|
|
6311
6358
|
_updateChildToStage(child) {
|
|
6312
|
-
return child && this.syncChildSharedStateTreeBinding(child), this.addUpdateBoundTag(), child;
|
|
6359
|
+
return child && this.shouldSyncChildSharedStateTreeBinding(child) && this.syncChildSharedStateTreeBinding(child), this.addUpdateBoundTag(), child;
|
|
6313
6360
|
}
|
|
6314
6361
|
appendChild(node, addStage = !0) {
|
|
6315
6362
|
const data = super.appendChild(node);
|
|
6316
|
-
return data && addStage && this.syncChildSharedStateTreeBinding(data), this.addUpdateBoundTag(), data;
|
|
6363
|
+
return data && addStage && this.shouldSyncChildSharedStateTreeBinding(data) && this.syncChildSharedStateTreeBinding(data), this.addUpdateBoundTag(), data;
|
|
6317
6364
|
}
|
|
6318
6365
|
insertBefore(newNode, referenceNode) {
|
|
6319
6366
|
return this._updateChildToStage(super.insertBefore(newNode, referenceNode));
|
|
@@ -6336,13 +6383,13 @@ class Group extends Graphic {
|
|
|
6336
6383
|
child.setStage(null, null);
|
|
6337
6384
|
}), this.addUpdateBoundTag();
|
|
6338
6385
|
}
|
|
6339
|
-
setStage(stage, layer) {
|
|
6386
|
+
setStage(stage, layer, inheritedSharedStateScope) {
|
|
6340
6387
|
var _a, _b, _c, _d, _e, _f;
|
|
6341
6388
|
const graphicService = null !== (_c = null !== (_a = null == stage ? void 0 : stage.graphicService) && void 0 !== _a ? _a : null === (_b = this.stage) || void 0 === _b ? void 0 : _b.graphicService) && void 0 !== _c ? _c : application.graphicService,
|
|
6342
6389
|
needsSharedStateTreeSync = this.hasSharedStateDefinitions() || this.sharedStateScope || (null === (_d = this.currentStates) || void 0 === _d ? void 0 : _d.length) || this.boundSharedStateScope || (null === (_e = this.registeredActiveScopes) || void 0 === _e ? void 0 : _e.size) || this.sharedStateDirty;
|
|
6343
|
-
if (this.stage !== stage) return this.stage = stage, this.layer = layer, needsSharedStateTreeSync && (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!0)), this.setStageToShadowRoot(stage, layer), this._onSetStage && this._onSetStage(this, stage, layer), null === (_f = null == graphicService ? void 0 : graphicService.onSetStage) || void 0 === _f || _f.call(graphicService, this, stage), void this.notifyChildrenSharedStateTreeChanged();
|
|
6390
|
+
if (this.stage !== stage) return this.stage = stage, this.layer = layer, needsSharedStateTreeSync && (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!0, inheritedSharedStateScope)), this.setStageToShadowRoot(stage, layer), this._onSetStage && this._onSetStage(this, stage, layer), null === (_f = null == graphicService ? void 0 : graphicService.onSetStage) || void 0 === _f || _f.call(graphicService, this, stage), void this.notifyChildrenSharedStateTreeChanged(inheritedSharedStateScope);
|
|
6344
6391
|
const layerChanged = this.layer !== layer;
|
|
6345
|
-
layerChanged && (this.layer = layer), needsSharedStateTreeSync ? (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!0), this.notifyChildrenSharedStateTreeChanged()) : layerChanged && this.notifyChildrenSharedStateTreeChanged();
|
|
6392
|
+
layerChanged && (this.layer = layer), needsSharedStateTreeSync ? (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!0, inheritedSharedStateScope), this.notifyChildrenSharedStateTreeChanged(inheritedSharedStateScope)) : layerChanged && this.notifyChildrenSharedStateTreeChanged(inheritedSharedStateScope);
|
|
6346
6393
|
}
|
|
6347
6394
|
addUpdatePositionTag() {
|
|
6348
6395
|
super.addUpdatePositionTag(), this.forEachChildren(g => {
|
|
@@ -6401,17 +6448,29 @@ class Group extends Graphic {
|
|
|
6401
6448
|
hasSharedStateDefinitions() {
|
|
6402
6449
|
return !!this._sharedStateDefinitions && Object.keys(this._sharedStateDefinitions).length > 0;
|
|
6403
6450
|
}
|
|
6404
|
-
|
|
6451
|
+
resolveChildSharedStateScope(inheritedSharedStateScope) {
|
|
6452
|
+
var _a;
|
|
6453
|
+
return this.sharedStateScope ? this.sharedStateScope : void 0 !== inheritedSharedStateScope ? inheritedSharedStateScope : null !== (_a = this.resolveBoundSharedStateScope()) && void 0 !== _a ? _a : null;
|
|
6454
|
+
}
|
|
6455
|
+
notifyChildrenSharedStateTreeChanged(inheritedSharedStateScope) {
|
|
6456
|
+
const childSharedStateScope = this.resolveChildSharedStateScope(inheritedSharedStateScope);
|
|
6405
6457
|
this.forEachChildren(item => {
|
|
6406
|
-
this.
|
|
6458
|
+
this.setStageToChild(item, childSharedStateScope);
|
|
6407
6459
|
});
|
|
6408
6460
|
}
|
|
6409
|
-
|
|
6410
|
-
|
|
6461
|
+
shouldSyncChildSharedStateTreeBinding(child) {
|
|
6462
|
+
return !(!this.stage && !this.layer) || child.onParentSharedStateTreeChanged !== Graphic.prototype.onParentSharedStateTreeChanged && child.onParentSharedStateTreeChanged !== Group.prototype.onParentSharedStateTreeChanged;
|
|
6463
|
+
}
|
|
6464
|
+
setStageToChild(child, inheritedSharedStateScope) {
|
|
6465
|
+
const graphic = child;
|
|
6466
|
+
"function" != typeof graphic.setStage || child.onParentSharedStateTreeChanged !== Graphic.prototype.onParentSharedStateTreeChanged && child.onParentSharedStateTreeChanged !== Group.prototype.onParentSharedStateTreeChanged || graphic.stage === this.stage && graphic.layer === this.layer ? child.onParentSharedStateTreeChanged(this.stage, this.layer, inheritedSharedStateScope) : graphic.setStage(this.stage, this.layer, inheritedSharedStateScope);
|
|
6411
6467
|
}
|
|
6412
|
-
|
|
6468
|
+
syncChildSharedStateTreeBinding(child, inheritedSharedStateScope) {
|
|
6469
|
+
void 0 === inheritedSharedStateScope && (inheritedSharedStateScope = this.resolveChildSharedStateScope()), this.setStageToChild(child, inheritedSharedStateScope);
|
|
6470
|
+
}
|
|
6471
|
+
onParentSharedStateTreeChanged(stage, layer, inheritedSharedStateScope) {
|
|
6413
6472
|
var _a;
|
|
6414
|
-
this.stage === stage && this.layer === layer ? (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!!(null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length)), this.notifyChildrenSharedStateTreeChanged()) : this.setStage(stage, layer);
|
|
6473
|
+
this.stage === stage && this.layer === layer ? (this.ensureSharedStateScopeBound(), this.syncSharedStateScopeBindingOnTreeChange(!!(null === (_a = this.currentStates) || void 0 === _a ? void 0 : _a.length), inheritedSharedStateScope), this.notifyChildrenSharedStateTreeChanged(inheritedSharedStateScope)) : this.setStage(stage, layer, inheritedSharedStateScope);
|
|
6415
6474
|
}
|
|
6416
6475
|
}
|
|
6417
6476
|
Group.NOWORK_ANIMATE_ATTR = NOWORK_ANIMATE_ATTR;
|
|
@@ -8074,13 +8133,14 @@ function applyFillStyle(ctx, character, b) {
|
|
|
8074
8133
|
}) : fillStyle, setTextStyle(ctx, character);
|
|
8075
8134
|
}
|
|
8076
8135
|
function applyStrokeStyle(ctx, character) {
|
|
8136
|
+
var _a, _b;
|
|
8077
8137
|
const strokeStyle = character && character.stroke || defaultFormatting.stroke;
|
|
8078
8138
|
if (!strokeStyle) return void (ctx.globalAlpha = 0);
|
|
8079
8139
|
const {
|
|
8080
8140
|
strokeOpacity = 1,
|
|
8081
8141
|
opacity = 1
|
|
8082
8142
|
} = character;
|
|
8083
|
-
ctx.globalAlpha = strokeOpacity * opacity, ctx.lineWidth = character && "number" == typeof character.lineWidth ? character.lineWidth : 1, ctx.strokeStyle = strokeStyle, setTextStyle(ctx, character);
|
|
8143
|
+
ctx.globalAlpha = strokeOpacity * opacity, ctx.lineWidth = character && "number" == typeof character.lineWidth ? character.lineWidth : 1, ctx.setLineDash(null !== (_a = character.lineDash) && void 0 !== _a ? _a : []), ctx.lineDashOffset = null !== (_b = character.lineDashOffset) && void 0 !== _b ? _b : 0, ctx.strokeStyle = strokeStyle, setTextStyle(ctx, character);
|
|
8084
8144
|
}
|
|
8085
8145
|
function getStrByWithCanvas(desc, width, character, guessIndex, needTestLetter) {
|
|
8086
8146
|
if (desc.length <= 1) return 0;
|
|
@@ -9013,8 +9073,8 @@ class RichText extends Graphic {
|
|
|
9013
9073
|
clone() {
|
|
9014
9074
|
return new RichText(Object.assign({}, this.attribute));
|
|
9015
9075
|
}
|
|
9016
|
-
setStage(stage, layer) {
|
|
9017
|
-
super.setStage(stage, layer);
|
|
9076
|
+
setStage(stage, layer, inheritedSharedStateScope) {
|
|
9077
|
+
super.setStage(stage, layer, inheritedSharedStateScope);
|
|
9018
9078
|
this.getFrameCache().icons.forEach(icon => {
|
|
9019
9079
|
icon.setStage(stage, layer);
|
|
9020
9080
|
});
|
|
@@ -29990,6 +30050,7 @@ class DiscreteLegend extends LegendBase {
|
|
|
29990
30050
|
this._itemHeight = 0;
|
|
29991
30051
|
this._itemMaxWidth = 0;
|
|
29992
30052
|
this._contentMaxHeight = 0;
|
|
30053
|
+
this._stateDefinitionsCache = new WeakMap();
|
|
29993
30054
|
this._onHover = (e) => {
|
|
29994
30055
|
const target = e.target;
|
|
29995
30056
|
if (target && target.name && target.name.startsWith(LEGEND_ELEMENT_NAME.item)) {
|
|
@@ -30076,6 +30137,7 @@ class DiscreteLegend extends LegendBase {
|
|
|
30076
30137
|
};
|
|
30077
30138
|
}
|
|
30078
30139
|
render() {
|
|
30140
|
+
this._stateDefinitionsCache = new WeakMap();
|
|
30079
30141
|
super.render();
|
|
30080
30142
|
this._lastActiveItem = null;
|
|
30081
30143
|
}
|
|
@@ -30354,7 +30416,7 @@ class DiscreteLegend extends LegendBase {
|
|
|
30354
30416
|
}
|
|
30355
30417
|
else {
|
|
30356
30418
|
itemGroup = graphicCreator.group(Object.assign({ x: 0, y: 0 }, backgroundStyle.style));
|
|
30357
|
-
this._appendDataToShape(itemGroup, LEGEND_ELEMENT_NAME.item, item, itemGroup, backgroundStyle.state);
|
|
30419
|
+
this._appendDataToShape(itemGroup, LEGEND_ELEMENT_NAME.item, item, itemGroup, backgroundStyle.state, backgroundStyle.reuseStateDefinitions);
|
|
30358
30420
|
}
|
|
30359
30421
|
itemGroup.id = `${id !== null && id !== void 0 ? id : label}-${index}`;
|
|
30360
30422
|
itemGroup.addState(isSelected ? LegendStateValue.selected : LegendStateValue.unSelected);
|
|
@@ -30377,17 +30439,23 @@ class DiscreteLegend extends LegendBase {
|
|
|
30377
30439
|
}
|
|
30378
30440
|
shapeSpace = get(shapeAttr, 'space', DEFAULT_SHAPE_SPACE);
|
|
30379
30441
|
const itemShape = graphicCreator.symbol(Object.assign(Object.assign({ x: 0, y: 0, symbolType: 'circle', strokeBoundsBuffer: 0 }, shape), shapeStyle.style));
|
|
30380
|
-
Object.keys(shapeStyle.state || {}).
|
|
30381
|
-
const
|
|
30382
|
-
|
|
30383
|
-
|
|
30384
|
-
|
|
30442
|
+
const shapeStateNeedsItemColor = Object.keys(shapeStyle.state || {}).some(key => {
|
|
30443
|
+
const state = shapeStyle.state[key];
|
|
30444
|
+
const color = state.fill || state.stroke;
|
|
30445
|
+
return !!color && ((!!shape.fill && isNil(state.fill)) || (!!shape.stroke && isNil(state.stroke)));
|
|
30446
|
+
});
|
|
30447
|
+
const shapeStates = shapeStateNeedsItemColor ? merge({}, shapeStyle.state) : shapeStyle.state;
|
|
30448
|
+
Object.keys(shapeStates || {}).forEach(key => {
|
|
30449
|
+
const state = shapeStates[key];
|
|
30450
|
+
const color = state.fill || state.stroke;
|
|
30451
|
+
if (shape.fill && isNil(state.fill) && color) {
|
|
30452
|
+
state.fill = color;
|
|
30385
30453
|
}
|
|
30386
|
-
if (shape.stroke && isNil(
|
|
30387
|
-
|
|
30454
|
+
if (shape.stroke && isNil(state.stroke) && color) {
|
|
30455
|
+
state.stroke = color;
|
|
30388
30456
|
}
|
|
30389
30457
|
});
|
|
30390
|
-
this._appendDataToShape(itemShape, LEGEND_ELEMENT_NAME.itemShape, item, itemGroup, shapeStyle.
|
|
30458
|
+
this._appendDataToShape(itemShape, LEGEND_ELEMENT_NAME.itemShape, item, itemGroup, shapeStates, !shapeStateNeedsItemColor && shapeStyle.reuseStateDefinitions !== false);
|
|
30391
30459
|
itemShape.addState(isSelected ? LegendStateValue.selected : LegendStateValue.unSelected);
|
|
30392
30460
|
innerGroup.add(itemShape);
|
|
30393
30461
|
}
|
|
@@ -30402,7 +30470,7 @@ class DiscreteLegend extends LegendBase {
|
|
|
30402
30470
|
const text = labelAttr.formatMethod ? labelAttr.formatMethod(label, item, index) : label;
|
|
30403
30471
|
const labelAttributes = Object.assign(Object.assign({ x: shapeSize / 2 + shapeSpace, y: 0, textAlign: 'start', textBaseline: 'middle', lineHeight: (_b = labelStyle.style) === null || _b === void 0 ? void 0 : _b.fontSize }, labelStyle.style), { text, _originText: labelAttr.formatMethod ? label : undefined });
|
|
30404
30472
|
const labelShape = createTextGraphicByType(labelAttributes);
|
|
30405
|
-
this._appendDataToShape(labelShape, LEGEND_ELEMENT_NAME.itemLabel, item, itemGroup, labelStyle.state);
|
|
30473
|
+
this._appendDataToShape(labelShape, LEGEND_ELEMENT_NAME.itemLabel, item, itemGroup, labelStyle.state, labelStyle.reuseStateDefinitions);
|
|
30406
30474
|
labelShape.addState(isSelected ? LegendStateValue.selected : LegendStateValue.unSelected);
|
|
30407
30475
|
innerGroup.add(labelShape);
|
|
30408
30476
|
const labelSpace = get(labelAttr, 'space', DEFAULT_LABEL_SPACE);
|
|
@@ -30411,7 +30479,7 @@ class DiscreteLegend extends LegendBase {
|
|
|
30411
30479
|
const valueText = valueAttr.formatMethod ? valueAttr.formatMethod(value, item, index) : value;
|
|
30412
30480
|
const valueAttributes = Object.assign(Object.assign({ x: 0, y: 0, textAlign: 'start', textBaseline: 'middle', lineHeight: valueStyle.style.fontSize }, valueStyle.style), { text: valueText, _originText: valueAttr.formatMethod ? value : undefined });
|
|
30413
30481
|
const valueShape = createTextGraphicByType(valueAttributes);
|
|
30414
|
-
this._appendDataToShape(valueShape, LEGEND_ELEMENT_NAME.itemValue, item, itemGroup, valueStyle.state);
|
|
30482
|
+
this._appendDataToShape(valueShape, LEGEND_ELEMENT_NAME.itemValue, item, itemGroup, valueStyle.state, valueStyle.reuseStateDefinitions);
|
|
30415
30483
|
valueShape.addState(isSelected ? LegendStateValue.selected : LegendStateValue.unSelected);
|
|
30416
30484
|
if (this._itemWidthByUser) {
|
|
30417
30485
|
const layoutWidth = this._itemWidthByUser -
|
|
@@ -30509,9 +30577,12 @@ class DiscreteLegend extends LegendBase {
|
|
|
30509
30577
|
: new ScrollBar(Object.assign(Object.assign({ direction: 'vertical', width: compStyle.visible === false ? 0 : 12, range: [0, 0.5] }, compStyle), { height: compSize, disableTriggerEvent }));
|
|
30510
30578
|
}
|
|
30511
30579
|
_updatePositionOfPager(renderStartY, compWidth, compHeight) {
|
|
30580
|
+
var _a;
|
|
30512
30581
|
const { pager } = this.attribute;
|
|
30513
30582
|
const { totalPage, isHorizontal } = this._itemContext;
|
|
30514
30583
|
const position = (pager && pager.position) || 'middle';
|
|
30584
|
+
const hugContent = !!(pager && pager.hugContent);
|
|
30585
|
+
const pagerSpace = (_a = (pager && pager.space)) !== null && _a !== void 0 ? _a : DEFAULT_PAGER_SPACE;
|
|
30515
30586
|
this._pagerComponent.setTotal(totalPage);
|
|
30516
30587
|
if (isHorizontal) {
|
|
30517
30588
|
let y;
|
|
@@ -30524,8 +30595,12 @@ class DiscreteLegend extends LegendBase {
|
|
|
30524
30595
|
else {
|
|
30525
30596
|
y = renderStartY + compHeight / 2 - this._pagerComponent.AABBBounds.height() / 2;
|
|
30526
30597
|
}
|
|
30598
|
+
let x = compWidth - this._pagerComponent.AABBBounds.width();
|
|
30599
|
+
if (hugContent) {
|
|
30600
|
+
x = Math.max(0, Math.min(this._itemsContainer.AABBBounds.width() + pagerSpace, x));
|
|
30601
|
+
}
|
|
30527
30602
|
this._pagerComponent.setAttributes({
|
|
30528
|
-
x
|
|
30603
|
+
x,
|
|
30529
30604
|
y
|
|
30530
30605
|
});
|
|
30531
30606
|
}
|
|
@@ -30540,9 +30615,13 @@ class DiscreteLegend extends LegendBase {
|
|
|
30540
30615
|
else {
|
|
30541
30616
|
x = (compWidth - this._pagerComponent.AABBBounds.width()) / 2;
|
|
30542
30617
|
}
|
|
30618
|
+
let y = compHeight - this._pagerComponent.AABBBounds.height();
|
|
30619
|
+
if (hugContent) {
|
|
30620
|
+
y = Math.max(0, Math.min(renderStartY + this._itemsContainer.AABBBounds.height() + pagerSpace, y));
|
|
30621
|
+
}
|
|
30543
30622
|
this._pagerComponent.setAttributes({
|
|
30544
30623
|
x,
|
|
30545
|
-
y
|
|
30624
|
+
y
|
|
30546
30625
|
});
|
|
30547
30626
|
}
|
|
30548
30627
|
}
|
|
@@ -30758,11 +30837,22 @@ class DiscreteLegend extends LegendBase {
|
|
|
30758
30837
|
itemsContainer.setAttribute('x', -(defaultCurrent - 1) * (compWidth + spaceCol));
|
|
30759
30838
|
}
|
|
30760
30839
|
}
|
|
30840
|
+
const hugContent = !!pager.hugContent;
|
|
30841
|
+
let clipWidth = isHorizontal ? contentWidth : compWidth;
|
|
30842
|
+
let clipHeight = isHorizontal ? compHeight : contentHeight;
|
|
30843
|
+
if (hugContent) {
|
|
30844
|
+
if (isHorizontal) {
|
|
30845
|
+
clipWidth = Math.max(0, Math.min(clipWidth, itemsContainer.AABBBounds.width()));
|
|
30846
|
+
}
|
|
30847
|
+
else {
|
|
30848
|
+
clipHeight = Math.max(0, Math.min(clipHeight, itemsContainer.AABBBounds.height()));
|
|
30849
|
+
}
|
|
30850
|
+
}
|
|
30761
30851
|
const clipGroup = graphicCreator.group({
|
|
30762
30852
|
x: 0,
|
|
30763
30853
|
y: renderStartY,
|
|
30764
|
-
width:
|
|
30765
|
-
height:
|
|
30854
|
+
width: clipWidth,
|
|
30855
|
+
height: clipHeight,
|
|
30766
30856
|
clip: true,
|
|
30767
30857
|
pickable: false
|
|
30768
30858
|
});
|
|
@@ -31041,11 +31131,29 @@ class DiscreteLegend extends LegendBase {
|
|
|
31041
31131
|
});
|
|
31042
31132
|
return selectedData;
|
|
31043
31133
|
}
|
|
31044
|
-
_appendDataToShape(shape, name, data, delegateShape, states =
|
|
31134
|
+
_appendDataToShape(shape, name, data, delegateShape, states, reuseStateDefinitions = true) {
|
|
31045
31135
|
shape.name = name;
|
|
31046
31136
|
shape.data = data;
|
|
31047
31137
|
shape.delegate = delegateShape;
|
|
31048
|
-
|
|
31138
|
+
if (!reuseStateDefinitions) {
|
|
31139
|
+
shape.states = merge({}, DEFAULT_STATES, states);
|
|
31140
|
+
return;
|
|
31141
|
+
}
|
|
31142
|
+
const source = states !== null && states !== void 0 ? states : DEFAULT_STATES;
|
|
31143
|
+
const cached = this._stateDefinitionsCache.get(source);
|
|
31144
|
+
if (cached) {
|
|
31145
|
+
shape.states = cached.definitions;
|
|
31146
|
+
shape.setStateDefinitionsWithCompiled(cached.definitions, cached.compiledDefinitions);
|
|
31147
|
+
return;
|
|
31148
|
+
}
|
|
31149
|
+
const definitions = states ? merge({}, DEFAULT_STATES, states) : DEFAULT_STATES;
|
|
31150
|
+
const entry = {
|
|
31151
|
+
definitions,
|
|
31152
|
+
compiledDefinitions: new StateDefinitionCompiler().compile(definitions)
|
|
31153
|
+
};
|
|
31154
|
+
this._stateDefinitionsCache.set(source, entry);
|
|
31155
|
+
shape.states = entry.definitions;
|
|
31156
|
+
shape.setStateDefinitionsWithCompiled(entry.definitions, entry.compiledDefinitions);
|
|
31049
31157
|
}
|
|
31050
31158
|
_dispatchLegendEvent(eventName, legendItem, event) {
|
|
31051
31159
|
const currentSelectedItems = this._getSelectedLegends();
|
|
@@ -31071,21 +31179,27 @@ class DiscreteLegend extends LegendBase {
|
|
|
31071
31179
|
}
|
|
31072
31180
|
}
|
|
31073
31181
|
if (config.state) {
|
|
31074
|
-
|
|
31075
|
-
|
|
31076
|
-
|
|
31077
|
-
|
|
31078
|
-
|
|
31079
|
-
|
|
31080
|
-
|
|
31081
|
-
|
|
31182
|
+
const stateKeys = Object.keys(config.state);
|
|
31183
|
+
const hasStateFunction = stateKeys.some(key => isFunction(config.state[key]));
|
|
31184
|
+
newConfig.reuseStateDefinitions = !hasStateFunction;
|
|
31185
|
+
if (!hasStateFunction) {
|
|
31186
|
+
newConfig.state = config.state;
|
|
31187
|
+
}
|
|
31188
|
+
else {
|
|
31189
|
+
newConfig.state = {};
|
|
31190
|
+
stateKeys.forEach(key => {
|
|
31191
|
+
if (config.state[key]) {
|
|
31192
|
+
newConfig.state[key] = isFunction(config.state[key])
|
|
31193
|
+
? config.state[key](item, isSelected, index, items)
|
|
31194
|
+
: config.state[key];
|
|
31082
31195
|
}
|
|
31083
|
-
}
|
|
31084
|
-
}
|
|
31196
|
+
});
|
|
31197
|
+
}
|
|
31085
31198
|
}
|
|
31086
31199
|
return newConfig;
|
|
31087
31200
|
}
|
|
31088
31201
|
release() {
|
|
31202
|
+
this._stateDefinitionsCache = new WeakMap();
|
|
31089
31203
|
super.release();
|
|
31090
31204
|
this.removeAllEventListeners();
|
|
31091
31205
|
}
|
|
@@ -36588,6 +36702,6 @@ TableSeriesNumber.defaultAttributes = {
|
|
|
36588
36702
|
select: true
|
|
36589
36703
|
};
|
|
36590
36704
|
|
|
36591
|
-
const version = "1.1.4-alpha.
|
|
36705
|
+
const version = "1.1.4-alpha.2";
|
|
36592
36706
|
|
|
36593
36707
|
export { AXIS_ELEMENT_NAME, AbstractComponent, ArcInfo, ArcLabel, ArcSegment, AxisStateValue, BasePlayer, Brush, CheckBox, CircleAxis, CircleAxisGrid, CircleCrosshair, ColorContinuousLegend, ContinuousPlayer, DEFAULT_ITEM_SPACE_COL, DEFAULT_ITEM_SPACE_ROW, DEFAULT_LABEL_SPACE, DEFAULT_PAGER_SPACE, DEFAULT_SHAPE_SIZE, DEFAULT_SHAPE_SPACE, DEFAULT_STATES$1 as DEFAULT_STATES, DEFAULT_TITLE_SPACE, DEFAULT_VALUE_SPACE, DataLabel, DataZoom, DataZoomActiveTag, DirectionEnum, DiscreteLegend, DiscretePlayer, EmptyTip, GroupTransition, IDataZoomEvent, IDataZoomInteractiveEvent, IMarkAreaLabelPosition, IMarkCommonArcLabelPosition, IMarkLineLabelPosition, IMarkPointItemPosition, IOperateType, Indicator, LEGEND_ELEMENT_NAME, LabelBase, LegendEvent, LegendStateValue, LineAxis, LineAxisGrid, LineCrosshair, LineLabel, LinkPath, MarkArcArea, MarkArcLine, MarkArea, MarkLine, MarkPoint, Pager, PlayerEventEnum, PolygonCrosshair, PolygonSectorCrosshair, PopTip, Radio, RectCrosshair, RectLabel, SLIDER_ELEMENT_NAME, ScrollBar, SectorCrosshair, Segment, SeriesNumberCellStateValue, SeriesNumberEvent, SizeContinuousLegend, Slider, StoryLabelItem, Switch, SymbolLabel, TableSeriesNumber, Tag, Timeline, Title, Tooltip, TopZIndex, VTag, WeatherBox, alignTextInLine, angle, angleLabelOrientAttribute, angleTo, cartesianTicks, clampRadian, computeOffsetForlimit, continuousTicks, contrastAccessibilityChecker, convertDomainToTickData, createTextGraphicByType, deltaXYToAngle, fuzzyEqualNumber, getAxisBreakSymbolAttrs, getCircleLabelPosition, getCirclePoints, getCircleVerticalVector, getElMap, getHorizontalPath, getMarksByName, getNoneGroupMarksByName, getPolarAngleLabelPosition, getPolygonPath, getSizeHandlerPath, getTextAlignAttrOfVerticalDir, getTextType, getVerticalCoord, getVerticalPath, hasOverlap, htmlAttributeTransform, initTextMeasure, installPoptipToApp, installScrollbarToApp, isInRange, isPostiveXAxis, isRichText, isVisible, labelSmartInvert, length, limitShapeInBounds, linearDiscreteTicks, loadPoptip, loadScrollbar, measureTextSize, normalize, polarAngleAxisDiscreteTicks, polarTicks, reactAttributeTransform, registerArcDataLabel, registerLineDataLabel, registerMarkArcAreaAnimate, registerMarkArcLineAnimate, registerMarkAreaAnimate, registerMarkLineAnimate, registerMarkPointAnimate, registerRectDataLabel, registerSymbolDataLabel, removeRepeatPoint, richTextAttributeTransform, scale, setPoptipTheme, smartInvertStrategy, tan2AngleToAngle, textIntersect, ticks, traverseGroup, version };
|
|
@@ -69,4 +69,4 @@ export class AxisUpdate extends AComponentAnimate {
|
|
|
69
69
|
export function registerAxisAnimate() {
|
|
70
70
|
AnimateExecutor.registerBuiltInAnimate("axisEnter", AxisEnter), AnimateExecutor.registerBuiltInAnimate("axisUpdate", AxisUpdate);
|
|
71
71
|
}
|
|
72
|
-
//# sourceMappingURL=axis-animate.js.map
|
|
72
|
+
//# sourceMappingURL=axis-animate.js.map
|
|
@@ -63,4 +63,4 @@ export function registerLabelAnimate() {
|
|
|
63
63
|
AnimateExecutor.registerBuiltInAnimate("increaseCount", IncreaseCount), AnimateExecutor.registerBuiltInAnimate("labelUpdate", LabelUpdate),
|
|
64
64
|
AnimateExecutor.registerBuiltInAnimate("labelEnter", LabelEnter);
|
|
65
65
|
}
|
|
66
|
-
//# sourceMappingURL=label-animate.js.map
|
|
66
|
+
//# sourceMappingURL=label-animate.js.map
|
package/es/axis/util.js
CHANGED
package/es/brush/type.js
CHANGED
|
@@ -4,4 +4,5 @@ export var IOperateType;
|
|
|
4
4
|
IOperateType.drawStart = "drawStart", IOperateType.drawEnd = "drawEnd", IOperateType.drawing = "drawing",
|
|
5
5
|
IOperateType.moving = "moving", IOperateType.moveStart = "moveStart", IOperateType.moveEnd = "moveEnd",
|
|
6
6
|
IOperateType.brushActive = "brushActive", IOperateType.brushClear = "brushClear";
|
|
7
|
-
}(IOperateType || (IOperateType = {}));
|
|
7
|
+
}(IOperateType || (IOperateType = {}));
|
|
8
|
+
//# sourceMappingURL=type.js.map
|
package/es/checkbox/register.js
CHANGED
package/es/empty-tip/register.js
CHANGED
package/es/index.d.ts
CHANGED
package/es/index.js
CHANGED
package/es/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"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","file":"index.js","sourcesContent":["// 导出版本号\nexport const version = \"1.1.4-alpha.
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"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","file":"index.js","sourcesContent":["// 导出版本号\nexport const version = \"1.1.4-alpha.2\";\n\nexport * from './core/base';\nexport { AbstractComponent } from './core/base';\nexport * from './core/type';\nexport * from './scrollbar';\nexport { ScrollBar } from './scrollbar/scrollbar';\nexport { loadScrollbar } from './scrollbar/module';\nexport * from './tag';\nexport * from './poptip';\nexport { loadPoptip } from './poptip/module';\nexport * from './crosshair';\nexport { LineCrosshair } from './crosshair/line';\nexport { CircleCrosshair } from './crosshair/circle';\nexport { SectorCrosshair } from './crosshair/sector';\nexport { PolygonCrosshair } from './crosshair/polygon';\nexport * from './label';\nexport { DataLabel } from './label/dataLabel';\nexport { registerSymbolDataLabel } from './label/symbol';\nexport * from './axis';\nexport { LineAxis } from './axis/line';\nexport { CircleAxis } from './axis/circle';\nexport { continuousTicks } from './axis/tick-data/continuous';\nexport { polarAngleAxisDiscreteTicks } from './axis/tick-data/discrete/polar-angle';\nexport * from './axis/grid';\nexport { LineAxisGrid } from './axis/grid/line';\nexport { CircleAxisGrid } from './axis/grid/circle';\nexport * from './segment';\nexport { Segment } from './segment/segment';\nexport * from './data-zoom';\nexport { DataZoom } from './data-zoom/data-zoom';\nexport * from './marker';\nexport { MarkLine, registerMarkLineAnimate } from './marker/line';\nexport { MarkArea, registerMarkAreaAnimate } from './marker/area';\nexport { MarkArcLine, registerMarkArcLineAnimate } from './marker/arc-line';\nexport { MarkArcArea, registerMarkArcAreaAnimate } from './marker/arc-area';\nexport { MarkPoint, registerMarkPointAnimate } from './marker/point';\nexport * from './pager';\nexport * from './legend';\nexport { ColorContinuousLegend } from './legend/color/color';\nexport { SizeContinuousLegend } from './legend/size/size';\nexport * from './title';\nexport { Title } from './title/title';\nexport * from './indicator';\nexport { Indicator } from './indicator/indicator';\nexport * from './slider';\nexport * from './link-path';\nexport * from './player';\nexport { DiscretePlayer } from './player/discrete-player';\nexport { ContinuousPlayer } from './player/continuous-player';\nexport { PlayerEventEnum } from './player/type/event';\nexport * from './brush';\nexport { Brush } from './brush/brush';\nexport { IOperateType } from './brush/type';\nexport * from './tooltip';\nexport * from './timeline';\nexport * from './interface';\nexport * from './jsx';\nexport * from './checkbox';\nexport * from './radio';\nexport * from './empty-tip';\nexport * from './weather';\nexport * from './util';\nexport { labelSmartInvert } from './util/label-smartInvert';\nexport * from './switch';\nexport * from './label-item';\nexport * from './table-series-number';\n"]}
|