@visactor/vtable 1.3.2-alpha.2 → 1.3.2-alpha.3

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.
@@ -86,7 +86,7 @@ export class BaseTable extends EventTarget {
86
86
  }
87
87
  constructor(container, options = {}) {
88
88
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
89
- if (super(), this.showFrozenIcon = !0, this.version = "1.3.2-alpha.2", this.id = `VTable${Date.now()}`,
89
+ if (super(), this.showFrozenIcon = !0, this.version = "1.3.2-alpha.3", this.id = `VTable${Date.now()}`,
90
90
  this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200),
91
91
  !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
92
92
  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 = defaultPixelRatio, renderChartAsync: renderChartAsync, renderChartAsyncBatchCount: renderChartAsyncBatchCount, mode: mode, modeParams: modeParams, canvasWidth: canvasWidth, canvasHeight: canvasHeight, overscrollBehavior: overscrollBehavior, limitMinWidth: limitMinWidth, limitMinHeight: limitMinHeight, clearDOM: clearDOM = !0} = options;
@@ -817,7 +817,7 @@ export class BaseTable extends EventTarget {
817
817
  this.autoFillWidth = null != autoFillWidth && autoFillWidth, this.autoFillHeight = null != autoFillHeight && autoFillHeight,
818
818
  this.customRender = customRender;
819
819
  const internalProps = this.internalProps;
820
- if ("node" !== Env.mode && updateRootElementPadding(internalProps.element, this.padding),
820
+ if ("node" === Env.mode || options.canvas || updateRootElementPadding(internalProps.element, this.padding),
821
821
  this.columnWidthComputeMode = null !== (_a = options.columnWidthComputeMode) && void 0 !== _a ? _a : "normal",
822
822
  internalProps.frozenColCount = frozenColCount, internalProps.defaultRowHeight = defaultRowHeight,
823
823
  internalProps.defaultHeaderRowHeight = null != defaultHeaderRowHeight ? defaultHeaderRowHeight : defaultRowHeight,