@visactor/vtable 0.17.8 → 0.17.9-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.js +2 -2
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/event/listener/container-dom.js +2 -2
- package/cjs/event/listener/container-dom.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/themes/BRIGHT.js +1 -2
- package/cjs/themes/DARK.js +2 -1
- package/dist/vtable.js +8 -5
- package/dist/vtable.min.js +1 -1
- package/es/core/BaseTable.js +2 -2
- package/es/core/BaseTable.js.map +1 -1
- package/es/event/listener/container-dom.js +2 -2
- package/es/event/listener/container-dom.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/themes/BRIGHT.js +1 -2
- package/es/themes/DARK.js +2 -1
- package/package.json +5 -5
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;
|
|
48
|
-
if (super(), this.showFrozenIcon = !0, this.showSort = !0, this.version = "0.17.
|
|
48
|
+
if (super(), this.showFrozenIcon = !0, this.showSort = !0, this.version = "0.17.9-alpha.1",
|
|
49
49
|
this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {},
|
|
50
50
|
this.throttleInvalidate = (0, util_1.throttle2)(this.render.bind(this), 200), !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, keyboardOptions: keyboardOptions, columnResizeMode: columnResizeMode, 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} = options;
|
|
@@ -293,7 +293,7 @@ class BaseTable extends EventTarget_1.EventTarget {
|
|
|
293
293
|
const {padding: padding} = this;
|
|
294
294
|
let widthP = 0, heightP = 0;
|
|
295
295
|
if ("browser" === env_1.Env.mode) {
|
|
296
|
-
const element = this.getElement(), width1 = null !== (_b = null === (_a = element.parentElement) || void 0 === _a ? void 0 : _a.offsetWidth) && void 0 !== _b ? _b :
|
|
296
|
+
const element = this.getElement(), width1 = (null !== (_b = null === (_a = element.parentElement) || void 0 === _a ? void 0 : _a.offsetWidth) && void 0 !== _b ? _b : 1) - 1, height1 = (null !== (_d = null === (_c = element.parentElement) || void 0 === _c ? void 0 : _c.offsetHeight) && void 0 !== _d ? _d : 1) - 1;
|
|
297
297
|
element.style.width = width1 && width1 - padding.left - padding.right + "px" || "0px",
|
|
298
298
|
element.style.height = height1 && height1 - padding.top - padding.bottom + "px" || "0px";
|
|
299
299
|
const {canvas: canvas} = this.internalProps;
|