@visactor/vchart 2.0.4 → 2.0.5-alpha.1

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/build/index.es.js CHANGED
@@ -50772,6 +50772,7 @@ var ChartEvent;
50772
50772
  ChartEvent["afterRender"] = "afterRender";
50773
50773
  ChartEvent["afterLayout"] = "afterLayout";
50774
50774
  ChartEvent["afterMarkLayoutEnd"] = "afterMarkLayoutEnd";
50775
+ ChartEvent["afterWordcloudShapeDraw"] = "afterWordcloudShapeDraw";
50775
50776
  })(ChartEvent || (ChartEvent = {}));
50776
50777
  var Event_Source_Type;
50777
50778
  (function (Event_Source_Type) {
@@ -56943,6 +56944,9 @@ class VChart {
56943
56944
  getSpecInfo() {
56944
56945
  return this._specInfo;
56945
56946
  }
56947
+ get event() {
56948
+ return this._event;
56949
+ }
56946
56950
  getDataSet() {
56947
56951
  return this._dataSet;
56948
56952
  }
@@ -58305,7 +58309,7 @@ const lookup = (data, opt) => {
58305
58309
  });
58306
58310
  };
58307
58311
 
58308
- const version = "2.0.4";
58312
+ const version = "2.0.5-alpha.1";
58309
58313
 
58310
58314
  const addVChartProperty = (data, op) => {
58311
58315
  const context = op.beforeCall();
@@ -66239,7 +66243,7 @@ class BaseChart extends CompilableBase {
66239
66243
  this._event = new Event$1(option.eventDispatcher, option.mode);
66240
66244
  this._dataSet = option.dataSet;
66241
66245
  this._chartData = new ChartData(this._dataSet);
66242
- this._modelOption = Object.assign(Object.assign({}, option), { mode: this._option.mode, map: this._idMap, getChartLayoutRect: () => this._layoutRect, getChartViewRect: () => this._viewRect, getChart: () => this, globalScale: this._globalScale, onError: (_b = this._option) === null || _b === void 0 ? void 0 : _b.onError, disableTriggerEvent: ((_c = this._option) === null || _c === void 0 ? void 0 : _c.disableTriggerEvent) === true, getSeriesData: this._chartData.getSeriesData.bind(this._chartData) });
66246
+ this._modelOption = Object.assign(Object.assign({}, option), { mode: this._option.mode, map: this._idMap, getChartLayoutRect: () => this._layoutRect, getChartViewRect: () => this._viewRect, getChart: () => this, globalScale: this._globalScale, onError: (_b = this._option) === null || _b === void 0 ? void 0 : _b.onError, disableTriggerEvent: ((_c = this._option) === null || _c === void 0 ? void 0 : _c.disableTriggerEvent) === true, getSeriesData: this._chartData.getSeriesData.bind(this._chartData), dispatchEvent: (eType, params) => this._option.globalInstance.event.emit(eType, params) });
66243
66247
  if (this._setModelOption) {
66244
66248
  this._setModelOption();
66245
66249
  }
@@ -77857,11 +77861,24 @@ class BaseWordCloudSeries extends BaseSeries {
77857
77861
  ? Object.assign({ fontFamily: this._option.getTheme('fontFamily') }, this._maskShape) : this._maskShape,
77858
77862
  onUpdateMaskCanvas: this.handleMaskCanvasUpdate,
77859
77863
  onLayoutFinished: () => {
77860
- var _a, _b;
77861
- return (_b = (_a = this._option.globalInstance
77862
- .getChart()
77863
- .getOption()
77864
- .performanceHook) === null || _a === void 0 ? void 0 : _a.afterWordcloudShapeDraw) === null || _b === void 0 ? void 0 : _b.call(_a, this._option.globalInstance);
77864
+ const afterWordcloudShapeDraw = () => {
77865
+ var _a, _b, _c, _d;
77866
+ this._option.globalInstance.getStage().hooks.afterRender.taps = this._option.globalInstance
77867
+ .getStage()
77868
+ .hooks.afterRender.taps.filter(tap => tap.fn !== afterWordcloudShapeDraw);
77869
+ (_b = (_a = this._option).dispatchEvent) === null || _b === void 0 ? void 0 : _b.call(_a, ChartEvent.afterWordcloudShapeDraw, {
77870
+ instance: this._option.globalInstance
77871
+ });
77872
+ (_d = (_c = this._option.globalInstance
77873
+ .getChart()
77874
+ .getOption()
77875
+ .performanceHook) === null || _c === void 0 ? void 0 : _c.afterWordcloudShapeDraw) === null || _d === void 0 ? void 0 : _d.call(_c, this._option.globalInstance);
77876
+ };
77877
+ this._option.globalInstance.getStage().hooks.afterRender.taps.push({
77878
+ type: 'sync',
77879
+ name: 'afterWordcloudShapeDraw',
77880
+ fn: afterWordcloudShapeDraw
77881
+ });
77865
77882
  },
77866
77883
  dataIndexKey: DEFAULT_DATA_KEY,
77867
77884
  text: wordSpec.formatMethod
package/build/index.js CHANGED
@@ -50778,6 +50778,7 @@
50778
50778
  ChartEvent["afterRender"] = "afterRender";
50779
50779
  ChartEvent["afterLayout"] = "afterLayout";
50780
50780
  ChartEvent["afterMarkLayoutEnd"] = "afterMarkLayoutEnd";
50781
+ ChartEvent["afterWordcloudShapeDraw"] = "afterWordcloudShapeDraw";
50781
50782
  })(exports.ChartEvent || (exports.ChartEvent = {}));
50782
50783
  var Event_Source_Type;
50783
50784
  (function (Event_Source_Type) {
@@ -56949,6 +56950,9 @@
56949
56950
  getSpecInfo() {
56950
56951
  return this._specInfo;
56951
56952
  }
56953
+ get event() {
56954
+ return this._event;
56955
+ }
56952
56956
  getDataSet() {
56953
56957
  return this._dataSet;
56954
56958
  }
@@ -58311,7 +58315,7 @@
58311
58315
  });
58312
58316
  };
58313
58317
 
58314
- const version = "2.0.4";
58318
+ const version = "2.0.5-alpha.1";
58315
58319
 
58316
58320
  const addVChartProperty = (data, op) => {
58317
58321
  const context = op.beforeCall();
@@ -66245,7 +66249,7 @@
66245
66249
  this._event = new Event$1(option.eventDispatcher, option.mode);
66246
66250
  this._dataSet = option.dataSet;
66247
66251
  this._chartData = new ChartData(this._dataSet);
66248
- this._modelOption = Object.assign(Object.assign({}, option), { mode: this._option.mode, map: this._idMap, getChartLayoutRect: () => this._layoutRect, getChartViewRect: () => this._viewRect, getChart: () => this, globalScale: this._globalScale, onError: (_b = this._option) === null || _b === void 0 ? void 0 : _b.onError, disableTriggerEvent: ((_c = this._option) === null || _c === void 0 ? void 0 : _c.disableTriggerEvent) === true, getSeriesData: this._chartData.getSeriesData.bind(this._chartData) });
66252
+ this._modelOption = Object.assign(Object.assign({}, option), { mode: this._option.mode, map: this._idMap, getChartLayoutRect: () => this._layoutRect, getChartViewRect: () => this._viewRect, getChart: () => this, globalScale: this._globalScale, onError: (_b = this._option) === null || _b === void 0 ? void 0 : _b.onError, disableTriggerEvent: ((_c = this._option) === null || _c === void 0 ? void 0 : _c.disableTriggerEvent) === true, getSeriesData: this._chartData.getSeriesData.bind(this._chartData), dispatchEvent: (eType, params) => this._option.globalInstance.event.emit(eType, params) });
66249
66253
  if (this._setModelOption) {
66250
66254
  this._setModelOption();
66251
66255
  }
@@ -77863,11 +77867,24 @@
77863
77867
  ? Object.assign({ fontFamily: this._option.getTheme('fontFamily') }, this._maskShape) : this._maskShape,
77864
77868
  onUpdateMaskCanvas: this.handleMaskCanvasUpdate,
77865
77869
  onLayoutFinished: () => {
77866
- var _a, _b;
77867
- return (_b = (_a = this._option.globalInstance
77868
- .getChart()
77869
- .getOption()
77870
- .performanceHook) === null || _a === void 0 ? void 0 : _a.afterWordcloudShapeDraw) === null || _b === void 0 ? void 0 : _b.call(_a, this._option.globalInstance);
77870
+ const afterWordcloudShapeDraw = () => {
77871
+ var _a, _b, _c, _d;
77872
+ this._option.globalInstance.getStage().hooks.afterRender.taps = this._option.globalInstance
77873
+ .getStage()
77874
+ .hooks.afterRender.taps.filter(tap => tap.fn !== afterWordcloudShapeDraw);
77875
+ (_b = (_a = this._option).dispatchEvent) === null || _b === void 0 ? void 0 : _b.call(_a, exports.ChartEvent.afterWordcloudShapeDraw, {
77876
+ instance: this._option.globalInstance
77877
+ });
77878
+ (_d = (_c = this._option.globalInstance
77879
+ .getChart()
77880
+ .getOption()
77881
+ .performanceHook) === null || _c === void 0 ? void 0 : _c.afterWordcloudShapeDraw) === null || _d === void 0 ? void 0 : _d.call(_c, this._option.globalInstance);
77882
+ };
77883
+ this._option.globalInstance.getStage().hooks.afterRender.taps.push({
77884
+ type: 'sync',
77885
+ name: 'afterWordcloudShapeDraw',
77886
+ fn: afterWordcloudShapeDraw
77887
+ });
77871
77888
  },
77872
77889
  dataIndexKey: DEFAULT_DATA_KEY,
77873
77890
  text: wordSpec.formatMethod