@visactor/vchart-extension 2.1.3-alpha.2 → 2.1.3-alpha.4

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.
Files changed (151) hide show
  1. package/build/index.js +69 -14
  2. package/build/index.min.js +1 -1
  3. package/cjs/charts/3d/arc-3d.js +3 -3
  4. package/cjs/charts/3d/arc-3d.js.map +1 -1
  5. package/cjs/charts/3d/pyramid-3d.js +3 -3
  6. package/cjs/charts/3d/pyramid-3d.js.map +1 -1
  7. package/cjs/charts/3d/rect-3d.js +3 -4
  8. package/cjs/charts/3d/rect-3d.js.map +1 -1
  9. package/cjs/charts/axis-3d/band-axis.js +1 -2
  10. package/cjs/charts/axis-3d/index.js +2 -1
  11. package/cjs/charts/bar-3d/animation.js +1 -1
  12. package/cjs/charts/bar-3d/chart-spec-transformer.js +1 -1
  13. package/cjs/charts/bar-3d/chart.js +1 -1
  14. package/cjs/charts/bar-3d/constant.js +1 -1
  15. package/cjs/charts/bar-3d/index.js +1 -1
  16. package/cjs/charts/bar-3d/interface.js +1 -1
  17. package/cjs/charts/bar-3d/series-spec-transformer.js +1 -1
  18. package/cjs/charts/bar-3d/series.js +1 -1
  19. package/cjs/charts/bar-3d/theme.js +1 -1
  20. package/cjs/charts/candlestick/candlestick-transformer.js +1 -1
  21. package/cjs/charts/candlestick/candlestick.js +1 -1
  22. package/cjs/charts/candlestick/index.js +1 -1
  23. package/cjs/charts/candlestick/interface.js +1 -1
  24. package/cjs/charts/candlestick/util.js +1 -1
  25. package/cjs/charts/combination-candlestick/combination-candlestick-transformer.js +2 -1
  26. package/cjs/charts/combination-candlestick/combination-candlestick.js +1 -1
  27. package/cjs/charts/combination-candlestick/constant.js +1 -1
  28. package/cjs/charts/combination-candlestick/index.js +1 -1
  29. package/cjs/charts/combination-candlestick/interface.js +1 -1
  30. package/cjs/charts/conversion-funnel/arrow-data-transform.js +1 -1
  31. package/cjs/charts/conversion-funnel/constants.js +1 -1
  32. package/cjs/charts/conversion-funnel/conversion-funnel-transformer.js +1 -1
  33. package/cjs/charts/conversion-funnel/conversion-funnel.js +1 -1
  34. package/cjs/charts/conversion-funnel/index.js +1 -1
  35. package/cjs/charts/conversion-funnel/interface.js +1 -1
  36. package/cjs/charts/conversion-funnel/util.js +2 -1
  37. package/cjs/charts/funnel-3d/chart.js +1 -1
  38. package/cjs/charts/funnel-3d/constant.js +1 -1
  39. package/cjs/charts/funnel-3d/index.js +1 -1
  40. package/cjs/charts/funnel-3d/interface.js +1 -1
  41. package/cjs/charts/funnel-3d/series-spec-transformer.js +1 -1
  42. package/cjs/charts/funnel-3d/series.js +1 -1
  43. package/cjs/charts/funnel-3d/theme.js +1 -1
  44. package/cjs/components/bar-link/bar-link.js +1 -1
  45. package/cjs/components/bar-link/constant.js +1 -1
  46. package/cjs/components/bar-link/index.js +1 -1
  47. package/cjs/components/bar-link/type.js +1 -1
  48. package/cjs/components/bar-link/util.js +1 -1
  49. package/cjs/components/bar-regression-line/index.js +1 -1
  50. package/cjs/components/bar-regression-line/type.js +1 -1
  51. package/cjs/components/extension-mark-sync-state/extension-mark-sync-state.js +1 -1
  52. package/cjs/components/extension-mark-sync-state/index.js +1 -1
  53. package/cjs/components/extension-mark-sync-state/type.js +1 -1
  54. package/cjs/components/histogram-regression-line/index.js +1 -1
  55. package/cjs/components/histogram-regression-line/type.js +1 -2
  56. package/cjs/components/map-label/index.js +1 -1
  57. package/cjs/components/map-label/layout.js +1 -1
  58. package/cjs/components/map-label/map-label-transformer.js +1 -1
  59. package/cjs/components/map-label/map-label.js +1 -1
  60. package/cjs/components/map-label/theme.js +1 -1
  61. package/cjs/components/map-label/type.js +1 -1
  62. package/cjs/components/regression-line/index.js +1 -1
  63. package/cjs/components/regression-line/regression-line.js +1 -1
  64. package/cjs/components/regression-line/type.js +1 -1
  65. package/cjs/components/scatter-regression-line/index.js +1 -1
  66. package/cjs/components/scatter-regression-line/type.js +1 -1
  67. package/cjs/components/series-break/constant.js +1 -1
  68. package/cjs/components/series-break/index.js +1 -1
  69. package/cjs/components/series-break/series-break.js +1 -1
  70. package/cjs/components/series-break/type.js +1 -1
  71. package/cjs/components/series-break/util.js +1 -2
  72. package/cjs/components/series-label/constant.js +1 -1
  73. package/cjs/components/series-label/index.js +1 -1
  74. package/cjs/components/series-label/series-label.js +1 -1
  75. package/cjs/components/series-label/type.js +1 -1
  76. package/cjs/components/series-label/util.js +1 -1
  77. package/esm/charts/3d/arc-3d.js +2 -4
  78. package/esm/charts/3d/arc-3d.js.map +1 -1
  79. package/esm/charts/3d/pyramid-3d.js +2 -4
  80. package/esm/charts/3d/pyramid-3d.js.map +1 -1
  81. package/esm/charts/3d/rect-3d.js +2 -4
  82. package/esm/charts/3d/rect-3d.js.map +1 -1
  83. package/esm/charts/axis-3d/band-axis.js +1 -2
  84. package/esm/charts/axis-3d/index.js +2 -1
  85. package/esm/charts/bar-3d/animation.js +1 -1
  86. package/esm/charts/bar-3d/chart-spec-transformer.js +1 -1
  87. package/esm/charts/bar-3d/chart.js +1 -1
  88. package/esm/charts/bar-3d/constant.js +1 -1
  89. package/esm/charts/bar-3d/index.js +1 -1
  90. package/esm/charts/bar-3d/interface.js +1 -1
  91. package/esm/charts/bar-3d/series-spec-transformer.js +1 -1
  92. package/esm/charts/bar-3d/series.js +1 -1
  93. package/esm/charts/bar-3d/theme.js +1 -1
  94. package/esm/charts/candlestick/candlestick-transformer.js +1 -1
  95. package/esm/charts/candlestick/candlestick.js +1 -1
  96. package/esm/charts/candlestick/index.js +1 -1
  97. package/esm/charts/candlestick/interface.js +1 -1
  98. package/esm/charts/candlestick/util.js +1 -1
  99. package/esm/charts/combination-candlestick/combination-candlestick-transformer.js +2 -1
  100. package/esm/charts/combination-candlestick/combination-candlestick.js +1 -1
  101. package/esm/charts/combination-candlestick/constant.js +1 -1
  102. package/esm/charts/combination-candlestick/index.js +1 -1
  103. package/esm/charts/combination-candlestick/interface.js +1 -1
  104. package/esm/charts/conversion-funnel/arrow-data-transform.js +1 -1
  105. package/esm/charts/conversion-funnel/constants.js +1 -1
  106. package/esm/charts/conversion-funnel/conversion-funnel-transformer.js +1 -1
  107. package/esm/charts/conversion-funnel/conversion-funnel.js +1 -1
  108. package/esm/charts/conversion-funnel/index.js +1 -1
  109. package/esm/charts/conversion-funnel/interface.js +1 -1
  110. package/esm/charts/conversion-funnel/util.js +2 -1
  111. package/esm/charts/funnel-3d/chart.js +1 -1
  112. package/esm/charts/funnel-3d/constant.js +1 -1
  113. package/esm/charts/funnel-3d/index.js +1 -1
  114. package/esm/charts/funnel-3d/interface.js +1 -1
  115. package/esm/charts/funnel-3d/series-spec-transformer.js +1 -1
  116. package/esm/charts/funnel-3d/series.js +1 -1
  117. package/esm/charts/funnel-3d/theme.js +1 -1
  118. package/esm/components/bar-link/bar-link.js +1 -1
  119. package/esm/components/bar-link/constant.js +1 -1
  120. package/esm/components/bar-link/index.js +1 -1
  121. package/esm/components/bar-link/type.js +1 -1
  122. package/esm/components/bar-link/util.js +1 -1
  123. package/esm/components/bar-regression-line/index.js +1 -1
  124. package/esm/components/bar-regression-line/type.js +1 -1
  125. package/esm/components/extension-mark-sync-state/extension-mark-sync-state.js +1 -1
  126. package/esm/components/extension-mark-sync-state/index.js +1 -1
  127. package/esm/components/extension-mark-sync-state/type.js +1 -1
  128. package/esm/components/histogram-regression-line/index.js +1 -1
  129. package/esm/components/histogram-regression-line/type.js +1 -2
  130. package/esm/components/map-label/index.js +1 -1
  131. package/esm/components/map-label/layout.js +1 -1
  132. package/esm/components/map-label/map-label-transformer.js +1 -1
  133. package/esm/components/map-label/map-label.js +1 -1
  134. package/esm/components/map-label/theme.js +1 -1
  135. package/esm/components/map-label/type.js +1 -1
  136. package/esm/components/regression-line/index.js +1 -1
  137. package/esm/components/regression-line/regression-line.js +1 -1
  138. package/esm/components/regression-line/type.js +1 -1
  139. package/esm/components/scatter-regression-line/index.js +1 -1
  140. package/esm/components/scatter-regression-line/type.js +1 -1
  141. package/esm/components/series-break/constant.js +1 -1
  142. package/esm/components/series-break/index.js +1 -1
  143. package/esm/components/series-break/series-break.js +1 -1
  144. package/esm/components/series-break/type.js +1 -1
  145. package/esm/components/series-break/util.js +1 -2
  146. package/esm/components/series-label/constant.js +1 -1
  147. package/esm/components/series-label/index.js +1 -1
  148. package/esm/components/series-label/series-label.js +1 -1
  149. package/esm/components/series-label/type.js +1 -1
  150. package/esm/components/series-label/util.js +1 -1
  151. package/package.json +8 -8
package/build/index.js CHANGED
@@ -2456,6 +2456,17 @@
2456
2456
  return ColorStore.Get(fromColor, ColorType.Color255, _fromColorRGB), ColorStore.Get(toColor, ColorType.Color255, _toColorRGB), `rgba(${Math.round(_fromColorRGB[0] + (_toColorRGB[0] - _fromColorRGB[0]) * ratio)},${Math.round(_fromColorRGB[1] + (_toColorRGB[1] - _fromColorRGB[1]) * ratio)},${Math.round(_fromColorRGB[2] + (_toColorRGB[2] - _fromColorRGB[2]) * ratio)},${_fromColorRGB[3] + (_toColorRGB[3] - _fromColorRGB[3]) * ratio})`;
2457
2457
  }
2458
2458
 
2459
+ const FACTORY_STATE_SYMBOL = Symbol.for("@visactor/vrender-core/factory-state");
2460
+ function createFactoryState() {
2461
+ return {
2462
+ pluginClasses: {}
2463
+ };
2464
+ }
2465
+ function getFactoryState() {
2466
+ const scope = globalThis;
2467
+ return scope[FACTORY_STATE_SYMBOL] || (scope[FACTORY_STATE_SYMBOL] = createFactoryState()), scope[FACTORY_STATE_SYMBOL];
2468
+ }
2469
+
2459
2470
  class Generator {
2460
2471
  static GenAutoIncrementId() {
2461
2472
  return Generator.auto_increment_id++;
@@ -2522,7 +2533,17 @@
2522
2533
  }
2523
2534
 
2524
2535
  class Application {}
2525
- const application = new Application();
2536
+ const APPLICATION_STATE_SYMBOL = Symbol.for("@visactor/vrender-core/application-state");
2537
+ function createApplicationState() {
2538
+ return {
2539
+ application: new Application()
2540
+ };
2541
+ }
2542
+ function getApplicationState() {
2543
+ const scope = globalThis;
2544
+ return scope[APPLICATION_STATE_SYMBOL] || (scope[APPLICATION_STATE_SYMBOL] = createApplicationState()), scope[APPLICATION_STATE_SYMBOL];
2545
+ }
2546
+ const application = getApplicationState().application;
2526
2547
 
2527
2548
  class EventListenerManager {
2528
2549
  constructor() {
@@ -9805,7 +9826,6 @@
9805
9826
  }
9806
9827
  };
9807
9828
  }
9808
- const sharedGraphicFactory = new GraphicFactory();
9809
9829
  class GraphicCreator {
9810
9830
  constructor() {
9811
9831
  this.store = new Map();
@@ -9820,13 +9840,25 @@
9820
9840
  return this.store.has(name) ? createGraphic(name, attributes) : null;
9821
9841
  }
9822
9842
  }
9823
- const graphicCreator = new GraphicCreator();
9843
+ const GRAPHIC_REGISTRY_SYMBOL = Symbol.for("@visactor/vrender-core/graphic-registry");
9844
+ function createGraphicRegistryState() {
9845
+ return {
9846
+ graphicCreator: new GraphicCreator(),
9847
+ graphicFactory: new GraphicFactory()
9848
+ };
9849
+ }
9850
+ function getGraphicRegistryState() {
9851
+ const scope = globalThis;
9852
+ return scope[GRAPHIC_REGISTRY_SYMBOL] || (scope[GRAPHIC_REGISTRY_SYMBOL] = createGraphicRegistryState()), scope[GRAPHIC_REGISTRY_SYMBOL];
9853
+ }
9854
+ const sharedGraphicRegistry = getGraphicRegistryState();
9855
+ const graphicCreator = sharedGraphicRegistry.graphicCreator;
9824
9856
  function registerGraphic(name, creator) {
9825
9857
  if (!name) throw new Error("Graphic registration requires a non-empty graphic type");
9826
- graphicCreator.registerStore(name, creator), sharedGraphicFactory.register(name, createGraphicCtor(creator));
9858
+ graphicCreator.registerStore(name, creator), sharedGraphicRegistry.graphicFactory.register(name, createGraphicCtor(creator));
9827
9859
  }
9828
9860
  function createGraphic(name, attributes) {
9829
- return sharedGraphicFactory.create(name, attributes);
9861
+ return sharedGraphicRegistry.graphicFactory.create(name, attributes);
9830
9862
  }
9831
9863
 
9832
9864
  function getModelMatrix(out, graphic, theme) {
@@ -10127,7 +10159,7 @@
10127
10159
  return Factory._pluginClasses[pluginKey];
10128
10160
  }
10129
10161
  };
10130
- Factory$1._pluginClasses = {};
10162
+ Factory$1._pluginClasses = getFactoryState().pluginClasses;
10131
10163
 
10132
10164
  class DirectionalLight {
10133
10165
  constructor(dir, color, ambient = .8) {
@@ -11530,6 +11562,17 @@
11530
11562
  const LayerService = Symbol.for("LayerService");
11531
11563
  const StaticLayerHandlerContribution = Symbol.for("StaticLayerHandlerContribution");
11532
11564
 
11565
+ const CONTRIBUTION_STORE_STATE_SYMBOL = Symbol.for("@visactor/vrender-core/contribution-store-state");
11566
+ function createContributionStoreState() {
11567
+ return {
11568
+ store: new Map()
11569
+ };
11570
+ }
11571
+ function getContributionStoreState() {
11572
+ const scope = globalThis;
11573
+ return scope[CONTRIBUTION_STORE_STATE_SYMBOL] || (scope[CONTRIBUTION_STORE_STATE_SYMBOL] = createContributionStoreState()), scope[CONTRIBUTION_STORE_STATE_SYMBOL];
11574
+ }
11575
+
11533
11576
  const ContributionProvider = Symbol("ContributionProvider");
11534
11577
  class ContributionProviderCache {
11535
11578
  constructor(serviceIdentifier, container) {
@@ -11572,7 +11615,7 @@
11572
11615
  });
11573
11616
  }
11574
11617
  }
11575
- ContributionStore.store = new Map();
11618
+ ContributionStore.store = getContributionStoreState().store;
11576
11619
 
11577
11620
  class ATextMeasure {
11578
11621
  constructor() {
@@ -13299,13 +13342,26 @@
13299
13342
  return new LegacyBindingContext();
13300
13343
  }
13301
13344
 
13302
- const legacyBindingContext = createLegacyBindingContext();
13345
+ const LEGACY_BOOTSTRAP_STATE_SYMBOL = Symbol.for("@visactor/vrender-core/legacy-bootstrap-state");
13346
+ function createLegacyBootstrapState() {
13347
+ return {
13348
+ legacyBindingContext: createLegacyBindingContext(),
13349
+ preloaded: !1
13350
+ };
13351
+ }
13352
+ function getLegacyBootstrapState() {
13353
+ const scope = globalThis;
13354
+ return scope[LEGACY_BOOTSTRAP_STATE_SYMBOL] || (scope[LEGACY_BOOTSTRAP_STATE_SYMBOL] = createLegacyBootstrapState()), scope[LEGACY_BOOTSTRAP_STATE_SYMBOL];
13355
+ }
13356
+
13357
+ const legacyBootstrapState = getLegacyBootstrapState(),
13358
+ legacyBindingContext = legacyBootstrapState.legacyBindingContext;
13303
13359
  function getLegacyTarget(resolver) {
13304
13360
  let target;
13305
13361
  return () => (void 0 === target && (target = resolver()), target);
13306
13362
  }
13307
13363
  function preLoadAllModule() {
13308
- preLoadAllModule.__loaded || (preLoadAllModule.__loaded = !0, bindCoreModules({
13364
+ legacyBootstrapState.preloaded || (legacyBootstrapState.preloaded = !0, bindCoreModules({
13309
13365
  bind: legacyBindingContext.bind
13310
13366
  }), bindGraphicModules({
13311
13367
  bind: legacyBindingContext.bind
@@ -13318,7 +13374,6 @@
13318
13374
  bind: legacyBindingContext.bind
13319
13375
  }), load$1(legacyBindingContext), load(legacyBindingContext));
13320
13376
  }
13321
- preLoadAllModule.__loaded = !1;
13322
13377
  function getLegacyBindingContext() {
13323
13378
  return legacyBindingContext;
13324
13379
  }
@@ -15750,16 +15805,16 @@
15750
15805
  _registerRect3d.__loaded = !1;
15751
15806
  const registerRect3d = _registerRect3d;
15752
15807
 
15753
- const createArc3d = attributes => (registerArc3d(), createGraphic("arc3d", attributes));
15754
- const createPyramid3d = attributes => (registerPyramid3d(), createGraphic("pyramid3d", attributes));
15755
- const createRect3d = attributes => (registerRect3d(), createGraphic("rect3d", attributes));
15756
-
15757
15808
  function _registerShadowRoot() {
15758
15809
  _registerShadowRoot.__loaded || (_registerShadowRoot.__loaded = !0, registerShadowRootGraphic());
15759
15810
  }
15760
15811
  _registerShadowRoot.__loaded = !1;
15761
15812
  const registerShadowRoot = _registerShadowRoot;
15762
15813
 
15814
+ const createArc3d = attributes => (registerArc3d(), createGraphic("arc3d", attributes));
15815
+ const createPyramid3d = attributes => (registerPyramid3d(), createGraphic("pyramid3d", attributes));
15816
+ const createRect3d = attributes => (registerRect3d(), createGraphic("rect3d", attributes));
15817
+
15763
15818
  class CommonIn extends ACustomAnimate {
15764
15819
  constructor(from, to, duration, easing, params) {
15765
15820
  super(from, to, duration, easing, params);