@visactor/vtable 1.1.3-alpha.2 → 1.2.0-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/cjs/core/BaseTable.d.ts +1 -0
- package/cjs/core/BaseTable.js +6 -3
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/event/util.d.ts +1 -0
- package/cjs/event/util.js +3 -2
- package/cjs/event/util.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/plugins/custom-cell-style.d.ts +1 -0
- package/cjs/plugins/custom-cell-style.js +6 -2
- package/cjs/plugins/custom-cell-style.js.map +1 -1
- package/cjs/scenegraph/animation/appear.d.ts +2 -0
- package/cjs/scenegraph/animation/appear.js +26 -0
- package/cjs/scenegraph/animation/appear.js.map +1 -0
- package/cjs/scenegraph/component/custom.d.ts +5 -2
- package/cjs/scenegraph/component/custom.js +36 -8
- package/cjs/scenegraph/component/custom.js.map +1 -1
- package/cjs/scenegraph/graphic/contributions/group-contribution-render.js +33 -22
- package/cjs/scenegraph/graphic/contributions/group-contribution-render.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-helper.js +6 -5
- package/cjs/scenegraph/group-creater/cell-helper.js.map +1 -1
- package/cjs/scenegraph/group-creater/column-helper.js +1 -1
- package/cjs/scenegraph/group-creater/column-helper.js.map +1 -1
- package/cjs/scenegraph/layout/compute-col-width.js +2 -2
- package/cjs/scenegraph/layout/compute-col-width.js.map +1 -1
- package/cjs/scenegraph/layout/compute-row-height.js +1 -1
- package/cjs/scenegraph/layout/compute-row-height.js.map +1 -1
- package/cjs/scenegraph/layout/update-height.js +13 -3
- package/cjs/scenegraph/layout/update-height.js.map +1 -1
- package/cjs/scenegraph/layout/update-width.js +13 -3
- package/cjs/scenegraph/layout/update-width.js.map +1 -1
- package/cjs/scenegraph/scenegraph.js +8 -5
- package/cjs/scenegraph/scenegraph.js.map +1 -1
- package/cjs/scenegraph/utils/break-string.d.ts +4 -1
- package/cjs/scenegraph/utils/break-string.js +8 -4
- package/cjs/scenegraph/utils/break-string.js.map +1 -1
- package/cjs/scenegraph/utils/text-icon-layout.js +4 -2
- package/cjs/scenegraph/utils/text-icon-layout.js.map +1 -1
- package/cjs/state/select/is-cell-select-highlight.d.ts +5 -0
- package/cjs/state/select/is-cell-select-highlight.js +51 -0
- package/cjs/state/select/is-cell-select-highlight.js.map +1 -0
- package/cjs/state/select/update-position.js +10 -5
- package/cjs/state/select/update-position.js.map +1 -1
- package/cjs/state/state.js +4 -3
- package/cjs/state/state.js.map +1 -1
- package/cjs/themes/DEFAULT.js +0 -2
- package/cjs/themes/DEFAULT.js.map +1 -1
- package/cjs/themes/theme.js +37 -1
- package/cjs/themes/theme.js.map +1 -1
- package/cjs/ts-types/animation/appear.d.ts +6 -0
- package/cjs/ts-types/animation/appear.js +6 -0
- package/cjs/ts-types/animation/appear.js.map +1 -0
- package/cjs/ts-types/base-table.d.ts +4 -0
- package/cjs/ts-types/base-table.js.map +1 -1
- package/cjs/ts-types/table-engine.d.ts +5 -1
- package/cjs/ts-types/table-engine.js.map +1 -1
- package/cjs/ts-types/theme.d.ts +6 -0
- package/cjs/ts-types/theme.js.map +1 -1
- package/cjs/vrender.js.map +1 -1
- package/dist/vtable.js +428 -96
- package/dist/vtable.min.js +2 -2
- package/es/core/BaseTable.d.ts +1 -0
- package/es/core/BaseTable.js +6 -3
- package/es/core/BaseTable.js.map +1 -1
- package/es/event/util.d.ts +1 -0
- package/es/event/util.js +1 -1
- package/es/event/util.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/plugins/custom-cell-style.d.ts +1 -0
- package/es/plugins/custom-cell-style.js +6 -2
- package/es/plugins/custom-cell-style.js.map +1 -1
- package/es/scenegraph/animation/appear.d.ts +2 -0
- package/es/scenegraph/animation/appear.js +20 -0
- package/es/scenegraph/animation/appear.js.map +1 -0
- package/es/scenegraph/component/custom.d.ts +5 -2
- package/es/scenegraph/component/custom.js +38 -4
- package/es/scenegraph/component/custom.js.map +1 -1
- package/es/scenegraph/graphic/contributions/group-contribution-render.js +34 -21
- package/es/scenegraph/graphic/contributions/group-contribution-render.js.map +1 -1
- package/es/scenegraph/group-creater/cell-helper.js +5 -4
- package/es/scenegraph/group-creater/cell-helper.js.map +1 -1
- package/es/scenegraph/group-creater/column-helper.js +1 -1
- package/es/scenegraph/group-creater/column-helper.js.map +1 -1
- package/es/scenegraph/layout/compute-col-width.js +2 -2
- package/es/scenegraph/layout/compute-col-width.js.map +1 -1
- package/es/scenegraph/layout/compute-row-height.js +1 -1
- package/es/scenegraph/layout/compute-row-height.js.map +1 -1
- package/es/scenegraph/layout/update-height.js +13 -4
- package/es/scenegraph/layout/update-height.js.map +1 -1
- package/es/scenegraph/layout/update-width.js +13 -4
- package/es/scenegraph/layout/update-width.js.map +1 -1
- package/es/scenegraph/scenegraph.js +9 -5
- package/es/scenegraph/scenegraph.js.map +1 -1
- package/es/scenegraph/utils/break-string.d.ts +4 -1
- package/es/scenegraph/utils/break-string.js +9 -3
- package/es/scenegraph/utils/break-string.js.map +1 -1
- package/es/scenegraph/utils/text-icon-layout.js +4 -2
- package/es/scenegraph/utils/text-icon-layout.js.map +1 -1
- package/es/state/select/is-cell-select-highlight.d.ts +5 -0
- package/es/state/select/is-cell-select-highlight.js +46 -0
- package/es/state/select/is-cell-select-highlight.js.map +1 -0
- package/es/state/select/update-position.js +10 -5
- package/es/state/select/update-position.js.map +1 -1
- package/es/state/state.js +4 -3
- package/es/state/state.js.map +1 -1
- package/es/themes/DEFAULT.js +0 -2
- package/es/themes/DEFAULT.js.map +1 -1
- package/es/themes/theme.js +33 -1
- package/es/themes/theme.js.map +1 -1
- package/es/ts-types/animation/appear.d.ts +6 -0
- package/es/ts-types/animation/appear.js +2 -0
- package/es/ts-types/animation/appear.js.map +1 -0
- package/es/ts-types/base-table.d.ts +4 -0
- package/es/ts-types/base-table.js.map +1 -1
- package/es/ts-types/table-engine.d.ts +5 -1
- package/es/ts-types/table-engine.js.map +1 -1
- package/es/ts-types/theme.d.ts +6 -0
- package/es/ts-types/theme.js.map +1 -1
- package/es/vrender.js.map +1 -1
- package/package.json +2 -2
package/cjs/core/BaseTable.d.ts
CHANGED
|
@@ -404,6 +404,7 @@ export declare abstract class BaseTable extends EventTarget implements BaseTable
|
|
|
404
404
|
offVChartEvent(type: string, callback?: AnyFunction): void;
|
|
405
405
|
_bindChartEvent(activeChartInstance: any): void;
|
|
406
406
|
changeRecordOrder(source: number, target: number): void;
|
|
407
|
+
hasCustomCellStyle(customStyleId: string): boolean;
|
|
407
408
|
registerCustomCellStyle(customStyleId: string, customStyle: ColumnStyleOption | undefined | null): void;
|
|
408
409
|
arrangeCustomCellStyle(cellPos: {
|
|
409
410
|
col?: number;
|
package/cjs/core/BaseTable.js
CHANGED
|
@@ -45,7 +45,7 @@ class BaseTable extends EventTarget_1.EventTarget {
|
|
|
45
45
|
}
|
|
46
46
|
constructor(container, options = {}) {
|
|
47
47
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
48
|
-
if (super(), this.showFrozenIcon = !0, this.version = "1.
|
|
48
|
+
if (super(), this.showFrozenIcon = !0, this.version = "1.2.0-alpha.1", this.id = `VTable${Date.now()}`,
|
|
49
49
|
this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = (0, util_1.throttle2)(this.render.bind(this), 200),
|
|
50
50
|
!container && "node" !== options.mode) throw new Error("vtable's container is undefined");
|
|
51
51
|
const {frozenColCount: frozenColCount = 0, defaultRowHeight: defaultRowHeight = 40, defaultHeaderRowHeight: defaultHeaderRowHeight, defaultColWidth: defaultColWidth = 80, defaultHeaderColWidth: defaultHeaderColWidth, widthMode: widthMode = "standard", heightMode: heightMode = "standard", autoFillWidth: autoFillWidth = !1, autoFillHeight: autoFillHeight = !1, widthAdaptiveMode: widthAdaptiveMode = "only-body", heightAdaptiveMode: heightAdaptiveMode = "only-body", keyboardOptions: keyboardOptions, eventOptions: eventOptions, rowSeriesNumber: rowSeriesNumber, columnResizeMode: columnResizeMode, rowResizeMode: rowResizeMode = "none", dragHeaderMode: dragHeaderMode, showFrozenIcon: showFrozenIcon, allowFrozenColCount: allowFrozenColCount, padding: padding, hover: hover, menu: menu, select: click, customRender: customRender, pixelRatio: pixelRatio = pixel_ratio_1.defaultPixelRatio, renderChartAsync: renderChartAsync, renderChartAsyncBatchCount: renderChartAsyncBatchCount, mode: mode, modeParams: modeParams, canvasWidth: canvasWidth, canvasHeight: canvasHeight, overscrollBehavior: overscrollBehavior, limitMinWidth: limitMinWidth, limitMinHeight: limitMinHeight, clearDOM: clearDOM = !0} = options;
|
|
@@ -759,7 +759,7 @@ class BaseTable extends EventTarget_1.EventTarget {
|
|
|
759
759
|
null === (_d = null === (_c = internalProps.menuHandler) || void 0 === _c ? void 0 : _c.release) || void 0 === _d || _d.call(_c),
|
|
760
760
|
icons_1.IconCache.clearAll(), null === (_e = super.release) || void 0 === _e || _e.call(this),
|
|
761
761
|
null === (_g = null === (_f = internalProps.handler) || void 0 === _f ? void 0 : _f.release) || void 0 === _g || _g.call(_f),
|
|
762
|
-
null === (_j = null === (_h = internalProps.focusControl) || void 0 === _h ? void 0 : _h.release) || void 0 === _j || _j.call(_h),
|
|
762
|
+
this.eventManager.release(), null === (_j = null === (_h = internalProps.focusControl) || void 0 === _h ? void 0 : _h.release) || void 0 === _j || _j.call(_h),
|
|
763
763
|
null === (_k = internalProps.legends) || void 0 === _k || _k.forEach((legend => {
|
|
764
764
|
null == legend || legend.release();
|
|
765
765
|
})), null === (_l = internalProps.title) || void 0 === _l || _l.release(), internalProps.title = null,
|
|
@@ -770,7 +770,7 @@ class BaseTable extends EventTarget_1.EventTarget {
|
|
|
770
770
|
})), internalProps.releaseList = null), this.scenegraph.stage.release(), this.scenegraph.proxy.release();
|
|
771
771
|
const {parentElement: parentElement} = internalProps.element;
|
|
772
772
|
parentElement && parentElement.removeChild(internalProps.element), null === (_q = null === (_p = null === (_o = this.editorManager) || void 0 === _o ? void 0 : _o.editingEditor) || void 0 === _p ? void 0 : _p.onEnd) || void 0 === _q || _q.call(_p),
|
|
773
|
-
this.isReleased = !0;
|
|
773
|
+
this.isReleased = !0, this.scenegraph = null, this.internalProps = null;
|
|
774
774
|
}
|
|
775
775
|
fireListeners(type, event) {
|
|
776
776
|
return super.fireListeners(type, event);
|
|
@@ -1793,6 +1793,9 @@ class BaseTable extends EventTarget_1.EventTarget {
|
|
|
1793
1793
|
}));
|
|
1794
1794
|
}
|
|
1795
1795
|
changeRecordOrder(source, target) {}
|
|
1796
|
+
hasCustomCellStyle(customStyleId) {
|
|
1797
|
+
return this.customCellStylePlugin.hasCustomCellStyle(customStyleId);
|
|
1798
|
+
}
|
|
1796
1799
|
registerCustomCellStyle(customStyleId, customStyle) {
|
|
1797
1800
|
this.customCellStylePlugin.registerCustomCellStyle(customStyleId, customStyle);
|
|
1798
1801
|
}
|