@visactor/vtable 1.23.1-alpha.0 → 1.23.1-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/ListTable.js +14 -10
- package/cjs/ListTable.js.map +1 -1
- package/cjs/PivotChart.js +15 -8
- package/cjs/PivotChart.js.map +1 -1
- package/cjs/PivotTable.js +18 -11
- package/cjs/PivotTable.js.map +1 -1
- package/cjs/core/BaseTable.js +11 -5
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/vrender.js.map +1 -1
- package/dist/vtable.js +73 -17
- package/dist/vtable.min.js +2 -2
- package/es/ListTable.js +14 -10
- package/es/ListTable.js.map +1 -1
- package/es/PivotChart.js +15 -8
- package/es/PivotChart.js.map +1 -1
- package/es/PivotTable.js +18 -11
- package/es/PivotTable.js.map +1 -1
- package/es/core/BaseTable.js +11 -5
- package/es/core/BaseTable.js.map +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/vrender.js.map +1 -1
- package/package.json +2 -2
package/cjs/ListTable.js
CHANGED
|
@@ -62,8 +62,8 @@ class ListTable extends core_1.BaseTable {
|
|
|
62
62
|
const ListTreeStickCellPlugin = factory_1.Factory.getComponent("listTreeStickCellPlugin");
|
|
63
63
|
this.listTreeStickCellPlugin = new ListTreeStickCellPlugin(this);
|
|
64
64
|
}
|
|
65
|
-
setTimeout((() => {
|
|
66
|
-
this.isReleased ||
|
|
65
|
+
this.resize(), setTimeout((() => {
|
|
66
|
+
this.isReleased || this.fireListeners(TABLE_EVENT_TYPE_1.TABLE_EVENT_TYPE.INITIALIZED, null);
|
|
67
67
|
}), 0);
|
|
68
68
|
}
|
|
69
69
|
isListTable() {
|
|
@@ -336,13 +336,13 @@ class ListTable extends core_1.BaseTable {
|
|
|
336
336
|
}) : (this.refreshRowColCount(), this._resetFrozenColCount(), this.scenegraph.createSceneGraph(),
|
|
337
337
|
this.render()), options.title) {
|
|
338
338
|
const Title = factory_1.Factory.getComponent("title");
|
|
339
|
-
internalProps.title = new Title(options.title, this)
|
|
339
|
+
internalProps.title = new Title(options.title, this);
|
|
340
340
|
}
|
|
341
341
|
if (this.options.emptyTip) if (this.internalProps.emptyTip) null === (_h = this.internalProps.emptyTip) || void 0 === _h || _h.resetVisible(); else {
|
|
342
342
|
const EmptyTip = factory_1.Factory.getComponent("emptyTip");
|
|
343
343
|
this.internalProps.emptyTip = new EmptyTip(this.options.emptyTip, this), null === (_j = this.internalProps.emptyTip) || void 0 === _j || _j.resetVisible();
|
|
344
344
|
}
|
|
345
|
-
return this.pluginManager.updatePlugins(options.plugins), setTimeout((() => {
|
|
345
|
+
return this.pluginManager.updatePlugins(options.plugins), this.resize(), setTimeout((() => {
|
|
346
346
|
this.fireListeners(TABLE_EVENT_TYPE_1.TABLE_EVENT_TYPE.UPDATED, null);
|
|
347
347
|
}), 0), new Promise((resolve => {
|
|
348
348
|
setTimeout(resolve, 0);
|
|
@@ -622,7 +622,7 @@ class ListTable extends core_1.BaseTable {
|
|
|
622
622
|
this.setCellCheckboxState(col, row, checked);
|
|
623
623
|
}
|
|
624
624
|
setRecords(records, option) {
|
|
625
|
-
var _a, _b, _c, _d;
|
|
625
|
+
var _a, _b, _c, _d, _e;
|
|
626
626
|
let sort;
|
|
627
627
|
(0, chart_render_helper_1.clearChartRenderQueue)(), null === (_a = this.internalProps.dataSource) || void 0 === _a || _a.release(),
|
|
628
628
|
this.internalProps.releaseList = null === (_b = this.internalProps.releaseList) || void 0 === _b ? void 0 : _b.filter((item => !item.dataSourceObj)),
|
|
@@ -649,12 +649,16 @@ class ListTable extends core_1.BaseTable {
|
|
|
649
649
|
}
|
|
650
650
|
this.refreshRowColCount();
|
|
651
651
|
} else (0, tableHelper_1._setRecords)(this, records);
|
|
652
|
-
|
|
653
|
-
this.stateManager.updateHoverPos(oldHoverState.col, oldHoverState.row), this._updateSize()
|
|
654
|
-
|
|
655
|
-
|
|
652
|
+
this.stateManager.initCheckedState(records), this.clearCellStyleCache(), this.scenegraph.createSceneGraph(),
|
|
653
|
+
this.stateManager.updateHoverPos(oldHoverState.col, oldHoverState.row), this._updateSize();
|
|
654
|
+
if ((null !== (_c = this.options.componentLayoutOrder) && void 0 !== _c ? _c : [ "legend", "title" ]).forEach((component => {
|
|
655
|
+
var _a, _b;
|
|
656
|
+
"legend" === component ? null === (_a = this.internalProps.legends) || void 0 === _a || _a.forEach((legend => {
|
|
657
|
+
null == legend || legend.resize();
|
|
658
|
+
})) : "title" === component && (null === (_b = this.internalProps.title) || void 0 === _b || _b.resize());
|
|
659
|
+
})), this.scenegraph.resize(), this.options.emptyTip) if (this.internalProps.emptyTip) null === (_d = this.internalProps.emptyTip) || void 0 === _d || _d.resetVisible(); else {
|
|
656
660
|
const EmptyTip = factory_1.Factory.getComponent("emptyTip");
|
|
657
|
-
this.internalProps.emptyTip = new EmptyTip(this.options.emptyTip, this), null === (
|
|
661
|
+
this.internalProps.emptyTip = new EmptyTip(this.options.emptyTip, this), null === (_e = this.internalProps.emptyTip) || void 0 === _e || _e.resetVisible();
|
|
658
662
|
}
|
|
659
663
|
this.render(), (0, vutils_1.isValid)(oldHoverState.col) && (0, vutils_1.isValid)(oldHoverState.row) && oldHoverState.col >= 0 && oldHoverState.row >= 0 && setTimeout((() => {
|
|
660
664
|
var _a;
|