e-virt-table 1.3.8 → 1.3.10
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/dist/index.cjs.js +4 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +202 -186
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +4 -4
- package/dist/index.umd.js.map +1 -1
- package/dist/lib/Config.d.ts +2 -2
- package/dist/lib/Config.js +7 -7
- package/dist/lib/Config.js.map +1 -1
- package/dist/lib/Context.d.ts +0 -1
- package/dist/lib/Context.js +0 -6
- package/dist/lib/Context.js.map +1 -1
- package/dist/lib/Database.d.ts +1 -0
- package/dist/lib/Database.js +7 -1
- package/dist/lib/Database.js.map +1 -1
- package/dist/lib/EVirtTable.d.ts +1 -0
- package/dist/lib/EVirtTable.js +10 -11
- package/dist/lib/EVirtTable.js.map +1 -1
- package/dist/lib/Editor.js +7 -6
- package/dist/lib/Editor.js.map +1 -1
- package/dist/lib/EventTable.js +1 -1
- package/dist/lib/EventTable.js.map +1 -1
- package/dist/lib/Header.d.ts +1 -1
- package/dist/lib/Header.js +11 -10
- package/dist/lib/Header.js.map +1 -1
- package/dist/lib/Overlayer.d.ts +2 -1
- package/dist/lib/Overlayer.js +45 -10
- package/dist/lib/Overlayer.js.map +1 -1
- package/dist/lib/Selector.js +3 -8
- package/dist/lib/Selector.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -66,7 +66,7 @@ function zt() {
|
|
|
66
66
|
return (h === "x" ? t : t & 3 | 8).toString(16);
|
|
67
67
|
});
|
|
68
68
|
}
|
|
69
|
-
function
|
|
69
|
+
function yt(h, t) {
|
|
70
70
|
let e = 0, i;
|
|
71
71
|
return function(...s) {
|
|
72
72
|
const o = (/* @__PURE__ */ new Date()).getTime(), r = o - e, a = typeof t == "function" ? t() : t;
|
|
@@ -75,8 +75,8 @@ function J(h, t) {
|
|
|
75
75
|
}, a - r));
|
|
76
76
|
};
|
|
77
77
|
}
|
|
78
|
-
function
|
|
79
|
-
return h.length ? h.map((t) =>
|
|
78
|
+
function ot(h = []) {
|
|
79
|
+
return h.length ? h.map((t) => ot(t.children) + 1).sort((t, e) => e - t)[0] : 0;
|
|
80
80
|
}
|
|
81
81
|
function ue(h = []) {
|
|
82
82
|
let t = [], e = [], i = [];
|
|
@@ -88,14 +88,14 @@ function ue(h = []) {
|
|
|
88
88
|
...i.sort((s, o) => (s.sort ?? 0) - (o.sort ?? 0))
|
|
89
89
|
];
|
|
90
90
|
}
|
|
91
|
-
function
|
|
91
|
+
function rt(h = [], t = 1, e = 0, i = "") {
|
|
92
92
|
return h.sort((s, o) => (s.sort ?? 0) - (o.sort ?? 0)).map((s) => {
|
|
93
93
|
if (s.children) {
|
|
94
94
|
let o = 0, r = s.fixed;
|
|
95
95
|
s.children.forEach((l) => {
|
|
96
96
|
l.fixed = r;
|
|
97
97
|
});
|
|
98
|
-
const a =
|
|
98
|
+
const a = rt(s.children, t - 1, e + 1, s.key);
|
|
99
99
|
return a && a.forEach((l) => {
|
|
100
100
|
o += l.colspan ?? 0;
|
|
101
101
|
}), {
|
|
@@ -117,10 +117,10 @@ function nt(h = [], t = 1, e = 0, i = "") {
|
|
|
117
117
|
};
|
|
118
118
|
});
|
|
119
119
|
}
|
|
120
|
-
function
|
|
120
|
+
function J(h = []) {
|
|
121
121
|
let t = [];
|
|
122
122
|
return h.forEach((e) => {
|
|
123
|
-
e.children ? t = t.concat(
|
|
123
|
+
e.children ? t = t.concat(J(e.children)) : t.push(e);
|
|
124
124
|
}), t;
|
|
125
125
|
}
|
|
126
126
|
function $t(h) {
|
|
@@ -1052,7 +1052,7 @@ class ye {
|
|
|
1052
1052
|
// 初始化默认不忽略清空改变值和校验map
|
|
1053
1053
|
init(t = !0) {
|
|
1054
1054
|
this.ctx.paint.clearTextCache(), this.clearBufferData(), this.rowKeyMap.clear(), this.checkboxKeyMap.clear(), this.colIndexKeyMap.clear(), this.rowIndexRowKeyMap.clear(), this.rowKeyRowIndexMap.clear(), this.maxRowHeightMap.clear();
|
|
1055
|
-
const e = this.getColumns(), i =
|
|
1055
|
+
const e = this.getColumns(), i = J(e);
|
|
1056
1056
|
if (this.ctx.hasSelection = i.some((s) => s.type === "selection"), this.ctx.hasTree = i.some((s) => s.type === "tree"), t) {
|
|
1057
1057
|
this.originalDataMap.clear(), this.changedDataMap.clear(), this.validationErrorMap.clear();
|
|
1058
1058
|
const { ROW_KEY: s } = this.ctx.config;
|
|
@@ -1072,45 +1072,53 @@ class ye {
|
|
|
1072
1072
|
* @param level
|
|
1073
1073
|
*/
|
|
1074
1074
|
initData(t, e = 0, i = []) {
|
|
1075
|
-
const s = t.length
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1075
|
+
const s = t.length, {
|
|
1076
|
+
ROW_KEY: o = "",
|
|
1077
|
+
DEFAULT_EXPAND_ALL: r,
|
|
1078
|
+
CELL_HEIGHT: a,
|
|
1079
|
+
SELECTABLE_METHOD: l,
|
|
1080
|
+
CHECKBOX_KEY: c,
|
|
1081
|
+
TREE_CHILDREN_KEY: d
|
|
1082
|
+
} = this.ctx.config;
|
|
1083
|
+
t.forEach((f, x) => {
|
|
1084
|
+
var C;
|
|
1085
|
+
d !== "children" && (f.children = f[d]);
|
|
1086
|
+
const u = f[o], g = u != null ? `${u}` : zt();
|
|
1087
|
+
this.itemRowKeyMap.set(f, g);
|
|
1088
|
+
const m = f._height || a, w = f._readonly;
|
|
1089
|
+
let E = !0;
|
|
1090
|
+
if (typeof l == "function" && (E = l), c) {
|
|
1091
|
+
const b = f[c];
|
|
1092
|
+
if (this.checkboxKeyMap.has(b)) {
|
|
1093
|
+
const y = this.checkboxKeyMap.get(b) || [];
|
|
1094
|
+
y.push(g), this.checkboxKeyMap.set(b, y);
|
|
1087
1095
|
} else
|
|
1088
|
-
this.checkboxKeyMap.set(
|
|
1096
|
+
this.checkboxKeyMap.set(b, [g]);
|
|
1089
1097
|
}
|
|
1090
|
-
this.selectionMap.set(
|
|
1091
|
-
key:
|
|
1092
|
-
row:
|
|
1093
|
-
check: ((
|
|
1098
|
+
this.selectionMap.set(g, {
|
|
1099
|
+
key: c ? f[c] : g,
|
|
1100
|
+
row: f,
|
|
1101
|
+
check: ((C = this.selectionMap.get(g)) == null ? void 0 : C.check) || !1
|
|
1094
1102
|
});
|
|
1095
|
-
const
|
|
1096
|
-
this.expandMap.set(
|
|
1097
|
-
readonly:
|
|
1098
|
-
index:
|
|
1099
|
-
rowIndex:
|
|
1103
|
+
const p = r || this.expandMap.get(g) || f._expand || !1;
|
|
1104
|
+
this.expandMap.set(g, p), this.rowKeyMap.set(g, {
|
|
1105
|
+
readonly: w,
|
|
1106
|
+
index: x,
|
|
1107
|
+
rowIndex: x,
|
|
1100
1108
|
level: e,
|
|
1101
|
-
height:
|
|
1109
|
+
height: m,
|
|
1102
1110
|
calculatedHeight: -1,
|
|
1103
1111
|
check: !1,
|
|
1104
|
-
selectable:
|
|
1105
|
-
expand:
|
|
1112
|
+
selectable: E,
|
|
1113
|
+
expand: p,
|
|
1106
1114
|
expandLazy: !1,
|
|
1107
|
-
hasChildren:
|
|
1115
|
+
hasChildren: f._hasChildren || (Array.isArray(f.children) ? f.children.length > 0 : !1),
|
|
1108
1116
|
expandLoading: !1,
|
|
1109
|
-
item:
|
|
1117
|
+
item: f,
|
|
1110
1118
|
parentRowKeys: i,
|
|
1111
1119
|
parentRowKey: i[i.length - 1] || "",
|
|
1112
|
-
isLastChild:
|
|
1113
|
-
}), Array.isArray(
|
|
1120
|
+
isLastChild: x === s - 1
|
|
1121
|
+
}), Array.isArray(f.children) && f.children.length && this.initData(f.children, e + 1, [...i, g]);
|
|
1114
1122
|
});
|
|
1115
1123
|
}
|
|
1116
1124
|
/**
|
|
@@ -2229,6 +2237,9 @@ class ye {
|
|
|
2229
2237
|
let i = {};
|
|
2230
2238
|
return e(t, i), i;
|
|
2231
2239
|
}
|
|
2240
|
+
clearChangeData() {
|
|
2241
|
+
this.changedDataMap.clear();
|
|
2242
|
+
}
|
|
2232
2243
|
}
|
|
2233
2244
|
class be {
|
|
2234
2245
|
constructor(t) {
|
|
@@ -2638,8 +2649,6 @@ class Dt {
|
|
|
2638
2649
|
n(this, "_config", {});
|
|
2639
2650
|
/** CSS 类名前缀 */
|
|
2640
2651
|
n(this, "CSS_PREFIX", "e-virt-table");
|
|
2641
|
-
/** 绘制时间 */
|
|
2642
|
-
n(this, "DRAW_TIME_MULTIPLIER", 2);
|
|
2643
2652
|
/** 图标集合 */
|
|
2644
2653
|
n(this, "ICONS", []);
|
|
2645
2654
|
/** 行的唯一标识键 */
|
|
@@ -2808,6 +2817,8 @@ class Dt {
|
|
|
2808
2817
|
n(this, "ENABLE_SELECTOR", !0);
|
|
2809
2818
|
/** 树形选择模式 */
|
|
2810
2819
|
n(this, "TREE_SELECT_MODE", "auto");
|
|
2820
|
+
/** 树形子项key名称 */
|
|
2821
|
+
n(this, "TREE_CHILDREN_KEY", "children");
|
|
2811
2822
|
/** 树形缩进宽度 */
|
|
2812
2823
|
n(this, "TREE_INDENT", 20);
|
|
2813
2824
|
/** 树形图标大小 */
|
|
@@ -3146,7 +3157,7 @@ class Te {
|
|
|
3146
3157
|
return this.list.find((e) => e.name === t);
|
|
3147
3158
|
}
|
|
3148
3159
|
}
|
|
3149
|
-
class
|
|
3160
|
+
class wt extends jt {
|
|
3150
3161
|
constructor(e, i, s, o, r, a, l) {
|
|
3151
3162
|
super(e, s, o, r, a, "header", l.fixed);
|
|
3152
3163
|
n(this, "align");
|
|
@@ -3449,7 +3460,7 @@ class Oe {
|
|
|
3449
3460
|
!0
|
|
3450
3461
|
), this.handleBodyEvent(i, e, this.ctx.body.renderRows, (s) => {
|
|
3451
3462
|
var o;
|
|
3452
|
-
this.imageEnterAndLeave(s, t), this.ctx.emit("cellMouseenter", s, t), this.ctx.hoverCell && this.ctx.hoverCell !== s && this.ctx.emit("cellMouseleave", s, t), this.ctx.hoverCell !== s && (((o = this.ctx.hoverCell) == null ? void 0 : o.rowKey) !== s.rowKey && (this.ctx.hoverCell = s, this.ctx.hoverRow = this.ctx.body.renderRows.find((r) => r.rowKey === s.rowKey), this.ctx.emit("rowHoverChange", this.ctx.hoverRow, s, t), this.ctx.emit("
|
|
3463
|
+
this.imageEnterAndLeave(s, t), this.ctx.emit("cellMouseenter", s, t), this.ctx.hoverCell && this.ctx.hoverCell !== s && this.ctx.emit("cellMouseleave", s, t), this.ctx.hoverCell !== s && (((o = this.ctx.hoverCell) == null ? void 0 : o.rowKey) !== s.rowKey && (this.ctx.hoverCell = s, this.ctx.hoverRow = this.ctx.body.renderRows.find((r) => r.rowKey === s.rowKey), this.ctx.emit("rowHoverChange", this.ctx.hoverRow, s, t), this.ctx.emit("draw")), this.ctx.hoverCell = s, this.ctx.emit("cellHoverChange", s, t));
|
|
3453
3464
|
}), this.handleFooterEvent(i, e, this.ctx.footer.renderRows, (s) => {
|
|
3454
3465
|
this.ctx.emit("cellFooterMouseenter", s, t), this.ctx.hoverCell && this.ctx.hoverCell !== s && this.ctx.emit("cellFooterMouseleave", s, t), this.ctx.emit("cellFooterHoverChange", s, t);
|
|
3455
3466
|
});
|
|
@@ -3474,7 +3485,7 @@ class Oe {
|
|
|
3474
3485
|
t.drawSelectionImageWidth,
|
|
3475
3486
|
t.drawSelectionImageHeight
|
|
3476
3487
|
))
|
|
3477
|
-
if (t instanceof
|
|
3488
|
+
if (t instanceof wt)
|
|
3478
3489
|
t.drawSelectionImageName === "checkbox-uncheck" || t.drawSelectionImageName === "checkbox-indeterminate" ? this.ctx.database.toggleAllSelection() : t.drawSelectionImageName === "checkbox-check" && this.ctx.database.clearSelection(!0);
|
|
3479
3490
|
else {
|
|
3480
3491
|
if (!this.ctx.database.getRowSelectable(t.rowKey))
|
|
@@ -3539,7 +3550,7 @@ class Oe {
|
|
|
3539
3550
|
*/
|
|
3540
3551
|
imageEnterAndLeave(t, e) {
|
|
3541
3552
|
const { offsetY: i, offsetX: s } = this.ctx.getOffset(e), o = i, r = s;
|
|
3542
|
-
if (t instanceof
|
|
3553
|
+
if (t instanceof wt) {
|
|
3543
3554
|
if (t.drawSelectionImageSource && this.isInsideElement(
|
|
3544
3555
|
r,
|
|
3545
3556
|
o,
|
|
@@ -3789,7 +3800,6 @@ class Le {
|
|
|
3789
3800
|
n(this, "database");
|
|
3790
3801
|
n(this, "history");
|
|
3791
3802
|
n(this, "config");
|
|
3792
|
-
n(this, "drawTime", 0);
|
|
3793
3803
|
const {
|
|
3794
3804
|
containerElement: i,
|
|
3795
3805
|
stageElement: s,
|
|
@@ -4257,28 +4267,32 @@ class He {
|
|
|
4257
4267
|
n(this, "renderFixedCellHeaders", []);
|
|
4258
4268
|
this.ctx = t, this.ctx.on(
|
|
4259
4269
|
"resetHeader",
|
|
4260
|
-
|
|
4270
|
+
yt(() => {
|
|
4261
4271
|
this.init(), this.ctx.clearSelector(), this.ctx.emit("draw");
|
|
4262
4272
|
}, 100)
|
|
4263
4273
|
), this.init(), this.initResizeColumn(), this.initDragColumn();
|
|
4264
4274
|
}
|
|
4265
|
-
init() {
|
|
4275
|
+
init(t = !1) {
|
|
4266
4276
|
const {
|
|
4267
|
-
config: { HEADER_HEIGHT:
|
|
4268
|
-
} = this.ctx
|
|
4269
|
-
|
|
4270
|
-
|
|
4271
|
-
|
|
4277
|
+
config: { HEADER_HEIGHT: e, SCROLLER_TRACK_SIZE: i }
|
|
4278
|
+
} = this.ctx;
|
|
4279
|
+
if (!t) {
|
|
4280
|
+
const f = this.ctx.database.getColumns();
|
|
4281
|
+
this.columns = f;
|
|
4282
|
+
}
|
|
4283
|
+
this.allCellHeaders = [], this.leafCellHeaders = [], this.fixedLeftCellHeaders = [], this.fixedRightCellHeaders = [], this.centerCellHeaders = [], this.visibleColumns = $t(this.columns);
|
|
4284
|
+
const s = ot(this.visibleColumns), o = J(this.visibleColumns);
|
|
4285
|
+
this.height = e * s, this.visibleHeight = this.height, this.width = o.reduce((f, x) => {
|
|
4272
4286
|
const u = x.width || 100, { maxWidth: g, minWidth: m } = x;
|
|
4273
4287
|
return g && u > g ? f + g : m && u < m ? f + m : f + u;
|
|
4274
4288
|
}, 0), this.columnIndex = 0, this.resizeNum = 0;
|
|
4275
|
-
const r = ue(
|
|
4289
|
+
const r = ue(rt(this.visibleColumns, s));
|
|
4276
4290
|
this.render(r, 0), this.ctx.database.updateColIndexKeyMap(this.leafCellHeaders);
|
|
4277
4291
|
const a = this.ctx.containerElement.getBoundingClientRect();
|
|
4278
4292
|
this.resizeNum > 0 ? this.ctx.stageWidth = Math.floor(a.width) : this.ctx.stageWidth = Math.min(
|
|
4279
|
-
Math.floor(this.width +
|
|
4293
|
+
Math.floor(this.width + i),
|
|
4280
4294
|
Math.floor(a.width)
|
|
4281
|
-
), this.ctx.stageElement.style.width = this.ctx.stageWidth + "px", this.visibleWidth = this.ctx.stageWidth -
|
|
4295
|
+
), this.ctx.stageElement.style.width = this.ctx.stageWidth + "px", this.visibleWidth = this.ctx.stageWidth - i;
|
|
4282
4296
|
const l = this.visibleWidth - this.width;
|
|
4283
4297
|
if (this.resizeNum && l > 0) {
|
|
4284
4298
|
const f = Math.floor(l / this.resizeNum * 100) / 100;
|
|
@@ -4287,7 +4301,7 @@ class He {
|
|
|
4287
4301
|
const c = this.fixedLeftCellHeaders.filter((f) => !f.hasChildren);
|
|
4288
4302
|
this.ctx.fixedLeftWidth = c.reduce((f, x) => f + x.width, 0);
|
|
4289
4303
|
const d = this.fixedRightCellHeaders.filter((f) => !f.hasChildren);
|
|
4290
|
-
this.ctx.fixedRightWidth = d.reduce((f, x) => f + x.width,
|
|
4304
|
+
this.ctx.fixedRightWidth = d.reduce((f, x) => f + x.width, i), this.ctx.maxColIndex = this.leafCellHeaders.length - 1, this.ctx.header.x = this.x, this.ctx.header.y = this.y, this.ctx.header.width = this.width, this.ctx.header.height = this.height, this.ctx.header.allCellHeaders = this.allCellHeaders, this.ctx.header.visibleWidth = this.visibleWidth, this.ctx.header.visibleHeight = this.visibleHeight;
|
|
4291
4305
|
}
|
|
4292
4306
|
// 调整表头的宽度
|
|
4293
4307
|
initResizeColumn() {
|
|
@@ -4337,7 +4351,7 @@ class He {
|
|
|
4337
4351
|
if (this.dragingCell && this.dragTarget) {
|
|
4338
4352
|
const t = (c, d = {}) => (c.forEach((f, x) => {
|
|
4339
4353
|
f.children && t(f.children, d), d[f.key] = x;
|
|
4340
|
-
}), d), e = this.ctx.database.getColumns(), i =
|
|
4354
|
+
}), d), e = this.ctx.database.getColumns(), i = rt(e, ot(e)), s = new Ae(i, {
|
|
4341
4355
|
key: "key",
|
|
4342
4356
|
// 节点唯一标识字段(对应我们之前的field)
|
|
4343
4357
|
childrenKey: "children"
|
|
@@ -4389,7 +4403,7 @@ class He {
|
|
|
4389
4403
|
}
|
|
4390
4404
|
});
|
|
4391
4405
|
};
|
|
4392
|
-
i(this.columns)
|
|
4406
|
+
i(this.columns);
|
|
4393
4407
|
let s = 0;
|
|
4394
4408
|
if (this.width < this.visibleWidth) {
|
|
4395
4409
|
const r = this.visibleWidth - this.width;
|
|
@@ -4403,7 +4417,7 @@ class He {
|
|
|
4403
4417
|
width: o,
|
|
4404
4418
|
column: t.column,
|
|
4405
4419
|
columns: this.columns
|
|
4406
|
-
}), this.ctx.database.setCustomHeaderResizableData(t.key, o), this.init(), this.ctx.emit("draw");
|
|
4420
|
+
}), this.ctx.database.setCustomHeaderResizableData(t.key, o), this.init(!0), this.ctx.emit("draw");
|
|
4407
4421
|
}
|
|
4408
4422
|
resizeAllColumn(t) {
|
|
4409
4423
|
if (t === 0) return;
|
|
@@ -4423,7 +4437,7 @@ class He {
|
|
|
4423
4437
|
e.has(r.key) && (r.width = e.get(r.key)), r.children && r.children.length > 0 && s(r.children);
|
|
4424
4438
|
});
|
|
4425
4439
|
};
|
|
4426
|
-
s(this.columns), this.
|
|
4440
|
+
s(this.columns), this.init(!0), this.ctx.emit("draw");
|
|
4427
4441
|
}
|
|
4428
4442
|
getCustomHeader() {
|
|
4429
4443
|
const t = this.ctx.database.getColumns(), e = this.ctx.database.getCustomHeader(), { sortData: i = {} } = e;
|
|
@@ -4431,7 +4445,7 @@ class He {
|
|
|
4431
4445
|
columns: t,
|
|
4432
4446
|
customHeader: e
|
|
4433
4447
|
} : {
|
|
4434
|
-
columns:
|
|
4448
|
+
columns: rt(t, ot(t)),
|
|
4435
4449
|
customHeader: e
|
|
4436
4450
|
};
|
|
4437
4451
|
}
|
|
@@ -4442,8 +4456,8 @@ class He {
|
|
|
4442
4456
|
for (let r = 0; r < i; r++) {
|
|
4443
4457
|
const a = t[r], l = o * (a.rowspan || 0), c = o * (a.level || 0);
|
|
4444
4458
|
let { minWidth: d, maxWidth: f } = a, x = a.width || 100;
|
|
4445
|
-
d && x < d && (x = d), f && x > f && (x = f), a.children && (x =
|
|
4446
|
-
const u = new
|
|
4459
|
+
d && x < d && (x = d), f && x > f && (x = f), a.children && (x = J(a.children).reduce((m, w) => m + ((w == null ? void 0 : w.width) || 100), 0));
|
|
4460
|
+
const u = new wt(this.ctx, this.columnIndex, s, c, x, l, a);
|
|
4447
4461
|
this.ctx.database.setHeader(a.key, u), this.allCellHeaders.push(u), a.children || (this.leafCellHeaders.push(u), u.column.widthFillDisable || this.resizeNum++), a.fixed === "left" ? this.fixedLeftCellHeaders.push(u) : a.fixed === "right" ? this.fixedRightCellHeaders.push(u) : this.centerCellHeaders.push(u), !a.children && this.columnIndex++, a.children && this.render(a.children, s), s += x;
|
|
4448
4462
|
}
|
|
4449
4463
|
}
|
|
@@ -4945,7 +4959,7 @@ class ke {
|
|
|
4945
4959
|
this.moveFocus(t);
|
|
4946
4960
|
}), this.ctx.on(
|
|
4947
4961
|
"mousemove",
|
|
4948
|
-
|
|
4962
|
+
yt((t) => {
|
|
4949
4963
|
var e, i;
|
|
4950
4964
|
(e = this.ctx.focusCell) != null && e.fixed || (i = this.ctx.focusCellHeader) != null && i.fixed || !this.ctx.dragHeaderIng && this.ctx.selectorMove && this.ctx.startAdjustPosition(t);
|
|
4951
4965
|
}, 100)
|
|
@@ -4966,10 +4980,7 @@ class ke {
|
|
|
4966
4980
|
}
|
|
4967
4981
|
window.getComputedStyle(e.target).userSelect !== "text" && e.preventDefault(), this.isMultipleRow = !1, this.click(e.shiftKey), this.ctx.emit("selectorClick", t);
|
|
4968
4982
|
}), this.ctx.on("mouseup", () => {
|
|
4969
|
-
this.ctx.selectorMove = !1, this.ctx.stopAdjustPosition();
|
|
4970
|
-
const t = setTimeout(() => {
|
|
4971
|
-
this.ctx.adjustPositioning = !1, this.ctx.disableHoverIconClick = !1, clearTimeout(t);
|
|
4972
|
-
}, 0);
|
|
4983
|
+
this.ctx.selectorMove = !1, this.ctx.stopAdjustPosition(), this.ctx.adjustPositioning = !1, this.ctx.disableHoverIconClick = !1;
|
|
4973
4984
|
}), this.ctx.on("cellHeaderHoverChange", (t) => {
|
|
4974
4985
|
this.ctx.mousedown && this.selectCols(t);
|
|
4975
4986
|
}), this.ctx.on("cellHoverChange", (t) => {
|
|
@@ -5426,7 +5437,7 @@ class ke {
|
|
|
5426
5437
|
x && (u === "top" ? v = r.height + a.height - w : S = a.visibleHeight);
|
|
5427
5438
|
const R = w + _ - (t - S - f);
|
|
5428
5439
|
let I = c, T = d;
|
|
5429
|
-
y > 0 && !C ? I = Math.floor(c + y) : b > 0 && !C && (I = Math.floor(c - b)), v > 0 ? T = Math.floor(d - v) : R > 0 && (T = Math.floor(d + R)), (Math.abs(c - I) > 2 || Math.abs(d - T) > 2) && (this.ctx.adjustPositioning = !0, this.ctx.
|
|
5440
|
+
y > 0 && !C ? I = Math.floor(c + y) : b > 0 && !C && (I = Math.floor(c - b)), v > 0 ? T = Math.floor(d - v) : R > 0 && (T = Math.floor(d + R)), (Math.abs(c - I) > 2 || Math.abs(d - T) > 2) && (this.ctx.adjustPositioning = !0, this.ctx.emit("adjustBoundaryPosition", i), this.ctx.setScroll(I, T));
|
|
5430
5441
|
}
|
|
5431
5442
|
destroy() {
|
|
5432
5443
|
}
|
|
@@ -5569,7 +5580,7 @@ class Xe {
|
|
|
5569
5580
|
destroy() {
|
|
5570
5581
|
}
|
|
5571
5582
|
}
|
|
5572
|
-
const j = Math.min, z = Math.max,
|
|
5583
|
+
const j = Math.min, z = Math.max, nt = Math.round, st = Math.floor, Y = (h) => ({
|
|
5573
5584
|
x: h,
|
|
5574
5585
|
y: h
|
|
5575
5586
|
}), Be = {
|
|
@@ -5581,16 +5592,16 @@ const j = Math.min, z = Math.max, at = Math.round, ot = Math.floor, Y = (h) => (
|
|
|
5581
5592
|
start: "end",
|
|
5582
5593
|
end: "start"
|
|
5583
5594
|
};
|
|
5584
|
-
function
|
|
5595
|
+
function mt(h, t, e) {
|
|
5585
5596
|
return z(h, j(t, e));
|
|
5586
5597
|
}
|
|
5587
|
-
function
|
|
5598
|
+
function tt(h, t) {
|
|
5588
5599
|
return typeof h == "function" ? h(t) : h;
|
|
5589
5600
|
}
|
|
5590
5601
|
function $(h) {
|
|
5591
5602
|
return h.split("-")[0];
|
|
5592
5603
|
}
|
|
5593
|
-
function
|
|
5604
|
+
function et(h) {
|
|
5594
5605
|
return h.split("-")[1];
|
|
5595
5606
|
}
|
|
5596
5607
|
function Jt(h) {
|
|
@@ -5608,15 +5619,15 @@ function vt(h) {
|
|
|
5608
5619
|
}
|
|
5609
5620
|
function Fe(h, t, e) {
|
|
5610
5621
|
e === void 0 && (e = !1);
|
|
5611
|
-
const i =
|
|
5622
|
+
const i = et(h), s = vt(h), o = It(s);
|
|
5612
5623
|
let r = s === "x" ? i === (e ? "end" : "start") ? "right" : "left" : i === "start" ? "bottom" : "top";
|
|
5613
|
-
return t.reference[o] > t.floating[o] && (r =
|
|
5624
|
+
return t.reference[o] > t.floating[o] && (r = at(r)), [r, at(r)];
|
|
5614
5625
|
}
|
|
5615
5626
|
function We(h) {
|
|
5616
|
-
const t =
|
|
5617
|
-
return [
|
|
5627
|
+
const t = at(h);
|
|
5628
|
+
return [Et(h), t, Et(t)];
|
|
5618
5629
|
}
|
|
5619
|
-
function
|
|
5630
|
+
function Et(h) {
|
|
5620
5631
|
return h.replace(/start|end/g, (t) => Ye[t]);
|
|
5621
5632
|
}
|
|
5622
5633
|
const Bt = ["left", "right"], Yt = ["right", "left"], Ve = ["top", "bottom"], Pe = ["bottom", "top"];
|
|
@@ -5633,11 +5644,11 @@ function ze(h, t, e) {
|
|
|
5633
5644
|
}
|
|
5634
5645
|
}
|
|
5635
5646
|
function $e(h, t, e, i) {
|
|
5636
|
-
const s =
|
|
5647
|
+
const s = et(h);
|
|
5637
5648
|
let o = ze($(h), e === "start", i);
|
|
5638
|
-
return s && (o = o.map((r) => r + "-" + s), t && (o = o.concat(o.map(
|
|
5649
|
+
return s && (o = o.map((r) => r + "-" + s), t && (o = o.concat(o.map(Et)))), o;
|
|
5639
5650
|
}
|
|
5640
|
-
function
|
|
5651
|
+
function at(h) {
|
|
5641
5652
|
return h.replace(/left|right|bottom|top/g, (t) => Be[t]);
|
|
5642
5653
|
}
|
|
5643
5654
|
function Ge(h) {
|
|
@@ -5657,7 +5668,7 @@ function Qt(h) {
|
|
|
5657
5668
|
left: h
|
|
5658
5669
|
};
|
|
5659
5670
|
}
|
|
5660
|
-
function
|
|
5671
|
+
function lt(h) {
|
|
5661
5672
|
const {
|
|
5662
5673
|
x: t,
|
|
5663
5674
|
y: e,
|
|
@@ -5713,7 +5724,7 @@ function Kt(h, t, e) {
|
|
|
5713
5724
|
y: i.y
|
|
5714
5725
|
};
|
|
5715
5726
|
}
|
|
5716
|
-
switch (
|
|
5727
|
+
switch (et(t)) {
|
|
5717
5728
|
case "start":
|
|
5718
5729
|
u[r] -= x * (e && c ? -1 : 1);
|
|
5719
5730
|
break;
|
|
@@ -5800,7 +5811,7 @@ async function te(h, t) {
|
|
|
5800
5811
|
elementContext: f = "floating",
|
|
5801
5812
|
altBoundary: x = !1,
|
|
5802
5813
|
padding: u = 0
|
|
5803
|
-
} =
|
|
5814
|
+
} = tt(t, h), g = Qt(u), w = a[x ? f === "floating" ? "reference" : "floating" : f], E = lt(await o.getClippingRect({
|
|
5804
5815
|
element: (e = await (o.isElement == null ? void 0 : o.isElement(w))) == null || e ? w : w.contextElement || await (o.getDocumentElement == null ? void 0 : o.getDocumentElement(a.floating)),
|
|
5805
5816
|
boundary: c,
|
|
5806
5817
|
rootBoundary: d,
|
|
@@ -5816,7 +5827,7 @@ async function te(h, t) {
|
|
|
5816
5827
|
} : {
|
|
5817
5828
|
x: 1,
|
|
5818
5829
|
y: 1
|
|
5819
|
-
}, y =
|
|
5830
|
+
}, y = lt(o.convertOffsetParentRelativeRectToViewportRelativeRect ? await o.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
5820
5831
|
elements: a,
|
|
5821
5832
|
rect: p,
|
|
5822
5833
|
offsetParent: C,
|
|
@@ -5844,7 +5855,7 @@ const je = (h) => ({
|
|
|
5844
5855
|
} = t, {
|
|
5845
5856
|
element: c,
|
|
5846
5857
|
padding: d = 0
|
|
5847
|
-
} =
|
|
5858
|
+
} = tt(h, t) || {};
|
|
5848
5859
|
if (c == null)
|
|
5849
5860
|
return {};
|
|
5850
5861
|
const f = Qt(d), x = {
|
|
@@ -5853,7 +5864,7 @@ const je = (h) => ({
|
|
|
5853
5864
|
}, u = vt(s), g = It(u), m = await r.getDimensions(c), w = u === "y", E = w ? "top" : "left", p = w ? "bottom" : "right", C = w ? "clientHeight" : "clientWidth", b = o.reference[g] + o.reference[u] - x[u] - o.floating[g], y = x[u] - o.reference[u], v = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(c));
|
|
5854
5865
|
let _ = v ? v[C] : 0;
|
|
5855
5866
|
(!_ || !await (r.isElement == null ? void 0 : r.isElement(v))) && (_ = a.floating[C] || o.floating[g]);
|
|
5856
|
-
const S = b / 2 - y / 2, R = _ / 2 - m[g] / 2 - 1, I = j(f[E], R), T = j(f[p], R), O = I, M = _ - m[g] - T, L = _ / 2 - m[g] / 2 + S, A =
|
|
5867
|
+
const S = b / 2 - y / 2, R = _ / 2 - m[g] / 2 - 1, I = j(f[E], R), T = j(f[p], R), O = I, M = _ - m[g] - T, L = _ / 2 - m[g] / 2 + S, A = mt(O, L, M), D = !l.arrow && et(s) != null && L !== A && o.reference[g] / 2 - (L < O ? I : T) - m[g] / 2 < 0, H = D ? L < O ? L - O : L - M : 0;
|
|
5857
5868
|
return {
|
|
5858
5869
|
[u]: x[u] + H,
|
|
5859
5870
|
data: {
|
|
@@ -5887,10 +5898,10 @@ const je = (h) => ({
|
|
|
5887
5898
|
fallbackAxisSideDirection: g = "none",
|
|
5888
5899
|
flipAlignment: m = !0,
|
|
5889
5900
|
...w
|
|
5890
|
-
} =
|
|
5901
|
+
} = tt(h, t);
|
|
5891
5902
|
if ((e = o.arrow) != null && e.alignmentOffset)
|
|
5892
5903
|
return {};
|
|
5893
|
-
const E = $(s), p = V(a), C = $(a) === a, b = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), y = x || (C || !m ? [
|
|
5904
|
+
const E = $(s), p = V(a), C = $(a) === a, b = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), y = x || (C || !m ? [at(a)] : We(a)), v = g !== "none";
|
|
5894
5905
|
!x && v && y.push(...$e(a, m, g, b));
|
|
5895
5906
|
const _ = [a, ...y], S = await te(t, w), R = [];
|
|
5896
5907
|
let I = ((i = o.flip) == null ? void 0 : i.overflows) || [];
|
|
@@ -5953,7 +5964,7 @@ async function Je(h, t) {
|
|
|
5953
5964
|
placement: e,
|
|
5954
5965
|
platform: i,
|
|
5955
5966
|
elements: s
|
|
5956
|
-
} = h, o = await (i.isRTL == null ? void 0 : i.isRTL(s.floating)), r = $(e), a =
|
|
5967
|
+
} = h, o = await (i.isRTL == null ? void 0 : i.isRTL(s.floating)), r = $(e), a = et(e), l = V(e) === "y", c = Ze.has(r) ? -1 : 1, d = o && l ? -1 : 1, f = tt(t, h);
|
|
5957
5968
|
let {
|
|
5958
5969
|
mainAxis: x,
|
|
5959
5970
|
crossAxis: u,
|
|
@@ -6022,18 +6033,18 @@ const Qe = function(h) {
|
|
|
6022
6033
|
}
|
|
6023
6034
|
},
|
|
6024
6035
|
...l
|
|
6025
|
-
} =
|
|
6036
|
+
} = tt(h, t), c = {
|
|
6026
6037
|
x: e,
|
|
6027
6038
|
y: i
|
|
6028
6039
|
}, d = await te(t, l), f = V($(s)), x = Jt(f);
|
|
6029
6040
|
let u = c[x], g = c[f];
|
|
6030
6041
|
if (o) {
|
|
6031
6042
|
const w = x === "y" ? "top" : "left", E = x === "y" ? "bottom" : "right", p = u + d[w], C = u - d[E];
|
|
6032
|
-
u =
|
|
6043
|
+
u = mt(p, u, C);
|
|
6033
6044
|
}
|
|
6034
6045
|
if (r) {
|
|
6035
6046
|
const w = f === "y" ? "top" : "left", E = f === "y" ? "bottom" : "right", p = g + d[w], C = g - d[E];
|
|
6036
|
-
g =
|
|
6047
|
+
g = mt(p, g, C);
|
|
6037
6048
|
}
|
|
6038
6049
|
const m = a.fn({
|
|
6039
6050
|
...t,
|
|
@@ -6054,7 +6065,7 @@ const Qe = function(h) {
|
|
|
6054
6065
|
}
|
|
6055
6066
|
};
|
|
6056
6067
|
};
|
|
6057
|
-
function
|
|
6068
|
+
function ft() {
|
|
6058
6069
|
return typeof window < "u";
|
|
6059
6070
|
}
|
|
6060
6071
|
function Z(h) {
|
|
@@ -6069,19 +6080,19 @@ function F(h) {
|
|
|
6069
6080
|
return (t = (ee(h) ? h.ownerDocument : h.document) || window.document) == null ? void 0 : t.documentElement;
|
|
6070
6081
|
}
|
|
6071
6082
|
function ee(h) {
|
|
6072
|
-
return
|
|
6083
|
+
return ft() ? h instanceof Node || h instanceof N(h).Node : !1;
|
|
6073
6084
|
}
|
|
6074
6085
|
function X(h) {
|
|
6075
|
-
return
|
|
6086
|
+
return ft() ? h instanceof Element || h instanceof N(h).Element : !1;
|
|
6076
6087
|
}
|
|
6077
6088
|
function K(h) {
|
|
6078
|
-
return
|
|
6089
|
+
return ft() ? h instanceof HTMLElement || h instanceof N(h).HTMLElement : !1;
|
|
6079
6090
|
}
|
|
6080
6091
|
function Ft(h) {
|
|
6081
|
-
return !
|
|
6092
|
+
return !ft() || typeof ShadowRoot > "u" ? !1 : h instanceof ShadowRoot || h instanceof N(h).ShadowRoot;
|
|
6082
6093
|
}
|
|
6083
6094
|
const ei = /* @__PURE__ */ new Set(["inline", "contents"]);
|
|
6084
|
-
function
|
|
6095
|
+
function it(h) {
|
|
6085
6096
|
const {
|
|
6086
6097
|
overflow: t,
|
|
6087
6098
|
overflowX: e,
|
|
@@ -6095,7 +6106,7 @@ function si(h) {
|
|
|
6095
6106
|
return ii.has(Z(h));
|
|
6096
6107
|
}
|
|
6097
6108
|
const oi = [":popover-open", ":modal"];
|
|
6098
|
-
function
|
|
6109
|
+
function ut(h) {
|
|
6099
6110
|
return oi.some((t) => {
|
|
6100
6111
|
try {
|
|
6101
6112
|
return h.matches(t);
|
|
@@ -6114,7 +6125,7 @@ function li(h) {
|
|
|
6114
6125
|
for (; K(t) && !q(t); ) {
|
|
6115
6126
|
if (_t(t))
|
|
6116
6127
|
return t;
|
|
6117
|
-
if (
|
|
6128
|
+
if (ut(t))
|
|
6118
6129
|
return null;
|
|
6119
6130
|
t = P(t);
|
|
6120
6131
|
}
|
|
@@ -6130,7 +6141,7 @@ function q(h) {
|
|
|
6130
6141
|
function B(h) {
|
|
6131
6142
|
return N(h).getComputedStyle(h);
|
|
6132
6143
|
}
|
|
6133
|
-
function
|
|
6144
|
+
function xt(h) {
|
|
6134
6145
|
return X(h) ? {
|
|
6135
6146
|
scrollLeft: h.scrollLeft,
|
|
6136
6147
|
scrollTop: h.scrollTop
|
|
@@ -6153,25 +6164,25 @@ function P(h) {
|
|
|
6153
6164
|
}
|
|
6154
6165
|
function ie(h) {
|
|
6155
6166
|
const t = P(h);
|
|
6156
|
-
return q(t) ? h.ownerDocument ? h.ownerDocument.body : h.body : K(t) &&
|
|
6167
|
+
return q(t) ? h.ownerDocument ? h.ownerDocument.body : h.body : K(t) && it(t) ? t : ie(t);
|
|
6157
6168
|
}
|
|
6158
|
-
function
|
|
6169
|
+
function Q(h, t, e) {
|
|
6159
6170
|
var i;
|
|
6160
6171
|
t === void 0 && (t = []), e === void 0 && (e = !0);
|
|
6161
6172
|
const s = ie(h), o = s === ((i = h.ownerDocument) == null ? void 0 : i.body), r = N(s);
|
|
6162
6173
|
if (o) {
|
|
6163
|
-
const a =
|
|
6164
|
-
return t.concat(r, r.visualViewport || [],
|
|
6174
|
+
const a = pt(r);
|
|
6175
|
+
return t.concat(r, r.visualViewport || [], it(s) ? s : [], a && e ? Q(a) : []);
|
|
6165
6176
|
}
|
|
6166
|
-
return t.concat(s,
|
|
6177
|
+
return t.concat(s, Q(s, [], e));
|
|
6167
6178
|
}
|
|
6168
|
-
function
|
|
6179
|
+
function pt(h) {
|
|
6169
6180
|
return h.parent && Object.getPrototypeOf(h.parent) ? h.frameElement : null;
|
|
6170
6181
|
}
|
|
6171
6182
|
function se(h) {
|
|
6172
6183
|
const t = B(h);
|
|
6173
6184
|
let e = parseFloat(t.width) || 0, i = parseFloat(t.height) || 0;
|
|
6174
|
-
const s = K(h), o = s ? h.offsetWidth : e, r = s ? h.offsetHeight : i, a =
|
|
6185
|
+
const s = K(h), o = s ? h.offsetWidth : e, r = s ? h.offsetHeight : i, a = nt(e) !== o || nt(i) !== r;
|
|
6175
6186
|
return a && (e = o, i = r), {
|
|
6176
6187
|
width: e,
|
|
6177
6188
|
height: i,
|
|
@@ -6190,7 +6201,7 @@ function U(h) {
|
|
|
6190
6201
|
height: s,
|
|
6191
6202
|
$: o
|
|
6192
6203
|
} = se(t);
|
|
6193
|
-
let r = (o ?
|
|
6204
|
+
let r = (o ? nt(e.width) : e.width) / i, a = (o ? nt(e.height) : e.height) / s;
|
|
6194
6205
|
return (!r || !Number.isFinite(r)) && (r = 1), (!a || !Number.isFinite(a)) && (a = 1), {
|
|
6195
6206
|
x: r,
|
|
6196
6207
|
y: a
|
|
@@ -6216,13 +6227,13 @@ function G(h, t, e, i) {
|
|
|
6216
6227
|
let l = (s.left + a.x) / r.x, c = (s.top + a.y) / r.y, d = s.width / r.x, f = s.height / r.y;
|
|
6217
6228
|
if (o) {
|
|
6218
6229
|
const x = N(o), u = i && X(i) ? N(i) : i;
|
|
6219
|
-
let g = x, m =
|
|
6230
|
+
let g = x, m = pt(g);
|
|
6220
6231
|
for (; m && i && u !== g; ) {
|
|
6221
6232
|
const w = U(m), E = m.getBoundingClientRect(), p = B(m), C = E.left + (m.clientLeft + parseFloat(p.paddingLeft)) * w.x, b = E.top + (m.clientTop + parseFloat(p.paddingTop)) * w.y;
|
|
6222
|
-
l *= w.x, c *= w.y, d *= w.x, f *= w.y, l += C, c += b, g = N(m), m =
|
|
6233
|
+
l *= w.x, c *= w.y, d *= w.x, f *= w.y, l += C, c += b, g = N(m), m = pt(g);
|
|
6223
6234
|
}
|
|
6224
6235
|
}
|
|
6225
|
-
return
|
|
6236
|
+
return lt({
|
|
6226
6237
|
width: d,
|
|
6227
6238
|
height: f,
|
|
6228
6239
|
x: l,
|
|
@@ -6230,7 +6241,7 @@ function G(h, t, e, i) {
|
|
|
6230
6241
|
});
|
|
6231
6242
|
}
|
|
6232
6243
|
function Ot(h, t) {
|
|
6233
|
-
const e =
|
|
6244
|
+
const e = xt(h).scrollLeft;
|
|
6234
6245
|
return t ? t.left + e : G(F(h)).left + e;
|
|
6235
6246
|
}
|
|
6236
6247
|
function re(h, t, e) {
|
|
@@ -6251,7 +6262,7 @@ function fi(h) {
|
|
|
6251
6262
|
offsetParent: i,
|
|
6252
6263
|
strategy: s
|
|
6253
6264
|
} = h;
|
|
6254
|
-
const o = s === "fixed", r = F(i), a = t ?
|
|
6265
|
+
const o = s === "fixed", r = F(i), a = t ? ut(t.floating) : !1;
|
|
6255
6266
|
if (i === r || a && o)
|
|
6256
6267
|
return e;
|
|
6257
6268
|
let l = {
|
|
@@ -6259,7 +6270,7 @@ function fi(h) {
|
|
|
6259
6270
|
scrollTop: 0
|
|
6260
6271
|
}, c = Y(1);
|
|
6261
6272
|
const d = Y(0), f = K(i);
|
|
6262
|
-
if ((f || !f && !o) && ((Z(i) !== "body" ||
|
|
6273
|
+
if ((f || !f && !o) && ((Z(i) !== "body" || it(r)) && (l = xt(i)), K(i))) {
|
|
6263
6274
|
const u = G(i);
|
|
6264
6275
|
c = U(i), d.x = u.x + i.clientLeft, d.y = u.y + i.clientTop;
|
|
6265
6276
|
}
|
|
@@ -6275,7 +6286,7 @@ function ui(h) {
|
|
|
6275
6286
|
return Array.from(h.getClientRects());
|
|
6276
6287
|
}
|
|
6277
6288
|
function xi(h) {
|
|
6278
|
-
const t = F(h), e =
|
|
6289
|
+
const t = F(h), e = xt(h), i = h.ownerDocument.body, s = z(t.scrollWidth, t.clientWidth, i.scrollWidth, i.clientWidth), o = z(t.scrollHeight, t.clientHeight, i.scrollHeight, i.clientHeight);
|
|
6279
6290
|
let r = -e.scrollLeft + Ot(h);
|
|
6280
6291
|
const a = -e.scrollTop;
|
|
6281
6292
|
return B(i).direction === "rtl" && (r += z(t.clientWidth, i.clientWidth) - s), {
|
|
@@ -6327,7 +6338,7 @@ function Wt(h, t, e) {
|
|
|
6327
6338
|
height: t.height
|
|
6328
6339
|
};
|
|
6329
6340
|
}
|
|
6330
|
-
return
|
|
6341
|
+
return lt(i);
|
|
6331
6342
|
}
|
|
6332
6343
|
function ne(h, t) {
|
|
6333
6344
|
const e = P(h);
|
|
@@ -6337,12 +6348,12 @@ function Ei(h, t) {
|
|
|
6337
6348
|
const e = t.get(h);
|
|
6338
6349
|
if (e)
|
|
6339
6350
|
return e;
|
|
6340
|
-
let i =
|
|
6351
|
+
let i = Q(h, [], !1).filter((a) => X(a) && Z(a) !== "body"), s = null;
|
|
6341
6352
|
const o = B(h).position === "fixed";
|
|
6342
6353
|
let r = o ? P(h) : h;
|
|
6343
6354
|
for (; X(r) && !q(r); ) {
|
|
6344
6355
|
const a = B(r), l = _t(r);
|
|
6345
|
-
!l && a.position === "fixed" && (s = null), (o ? !l && !s : !l && a.position === "static" && !!s && wi.has(s.position) ||
|
|
6356
|
+
!l && a.position === "fixed" && (s = null), (o ? !l && !s : !l && a.position === "static" && !!s && wi.has(s.position) || it(r) && !l && ne(h, r)) ? i = i.filter((d) => d !== r) : s = a, r = P(r);
|
|
6346
6357
|
}
|
|
6347
6358
|
return t.set(h, i), i;
|
|
6348
6359
|
}
|
|
@@ -6353,7 +6364,7 @@ function pi(h) {
|
|
|
6353
6364
|
rootBoundary: i,
|
|
6354
6365
|
strategy: s
|
|
6355
6366
|
} = h;
|
|
6356
|
-
const r = [...e === "clippingAncestors" ?
|
|
6367
|
+
const r = [...e === "clippingAncestors" ? ut(t) ? [] : Ei(t, this._c) : [].concat(e), i], a = r[0], l = r.reduce((c, d) => {
|
|
6357
6368
|
const f = Wt(t, d, s);
|
|
6358
6369
|
return c.top = z(f.top, c.top), c.right = j(f.right, c.right), c.bottom = j(f.bottom, c.bottom), c.left = z(f.left, c.left), c;
|
|
6359
6370
|
}, Wt(t, a, s));
|
|
@@ -6385,7 +6396,7 @@ function yi(h, t, e) {
|
|
|
6385
6396
|
l.x = Ot(s);
|
|
6386
6397
|
}
|
|
6387
6398
|
if (i || !i && !o)
|
|
6388
|
-
if ((Z(t) !== "body" ||
|
|
6399
|
+
if ((Z(t) !== "body" || it(s)) && (a = xt(t)), i) {
|
|
6389
6400
|
const u = G(t, !0, o, t);
|
|
6390
6401
|
l.x = u.x + t.clientLeft, l.y = u.y + t.clientTop;
|
|
6391
6402
|
} else s && c();
|
|
@@ -6398,7 +6409,7 @@ function yi(h, t, e) {
|
|
|
6398
6409
|
height: r.height
|
|
6399
6410
|
};
|
|
6400
6411
|
}
|
|
6401
|
-
function
|
|
6412
|
+
function gt(h) {
|
|
6402
6413
|
return B(h).position === "static";
|
|
6403
6414
|
}
|
|
6404
6415
|
function Vt(h, t) {
|
|
@@ -6411,21 +6422,21 @@ function Vt(h, t) {
|
|
|
6411
6422
|
}
|
|
6412
6423
|
function ae(h, t) {
|
|
6413
6424
|
const e = N(h);
|
|
6414
|
-
if (
|
|
6425
|
+
if (ut(h))
|
|
6415
6426
|
return e;
|
|
6416
6427
|
if (!K(h)) {
|
|
6417
6428
|
let s = P(h);
|
|
6418
6429
|
for (; s && !q(s); ) {
|
|
6419
|
-
if (X(s) && !
|
|
6430
|
+
if (X(s) && !gt(s))
|
|
6420
6431
|
return s;
|
|
6421
6432
|
s = P(s);
|
|
6422
6433
|
}
|
|
6423
6434
|
return e;
|
|
6424
6435
|
}
|
|
6425
6436
|
let i = Vt(h, t);
|
|
6426
|
-
for (; i && si(i) &&
|
|
6437
|
+
for (; i && si(i) && gt(i); )
|
|
6427
6438
|
i = Vt(i, t);
|
|
6428
|
-
return i && q(i) &&
|
|
6439
|
+
return i && q(i) && gt(i) && !_t(i) ? e : i || li(h) || e;
|
|
6429
6440
|
}
|
|
6430
6441
|
const bi = async function(h) {
|
|
6431
6442
|
const t = this.getOffsetParent || ae, e = this.getDimensions, i = await e(h.floating);
|
|
@@ -6474,7 +6485,7 @@ function vi(h, t) {
|
|
|
6474
6485
|
} = c;
|
|
6475
6486
|
if (a || t(), !x || !u)
|
|
6476
6487
|
return;
|
|
6477
|
-
const g =
|
|
6488
|
+
const g = st(f), m = st(s.clientWidth - (d + x)), w = st(s.clientHeight - (f + u)), E = st(d), C = {
|
|
6478
6489
|
rootMargin: -g + "px " + -m + "px " + -w + "px " + -E + "px",
|
|
6479
6490
|
threshold: z(0, j(1, l)) || 1
|
|
6480
6491
|
};
|
|
@@ -6503,7 +6514,7 @@ function vi(h, t) {
|
|
|
6503
6514
|
}
|
|
6504
6515
|
return r(!0), o;
|
|
6505
6516
|
}
|
|
6506
|
-
function
|
|
6517
|
+
function Ct(h, t, e, i) {
|
|
6507
6518
|
i === void 0 && (i = {});
|
|
6508
6519
|
const {
|
|
6509
6520
|
ancestorScroll: s = !0,
|
|
@@ -6511,7 +6522,7 @@ function yt(h, t, e, i) {
|
|
|
6511
6522
|
elementResize: r = typeof ResizeObserver == "function",
|
|
6512
6523
|
layoutShift: a = typeof IntersectionObserver == "function",
|
|
6513
6524
|
animationFrame: l = !1
|
|
6514
|
-
} = i, c = Tt(h), d = s || o ? [...c ?
|
|
6525
|
+
} = i, c = Tt(h), d = s || o ? [...c ? Q(c) : [], ...Q(t)] : [];
|
|
6515
6526
|
d.forEach((E) => {
|
|
6516
6527
|
s && E.addEventListener("scroll", e, {
|
|
6517
6528
|
passive: !0
|
|
@@ -6539,7 +6550,7 @@ function yt(h, t, e, i) {
|
|
|
6539
6550
|
}), f == null || f(), (E = u) == null || E.disconnect(), u = null, l && cancelAnimationFrame(g);
|
|
6540
6551
|
};
|
|
6541
6552
|
}
|
|
6542
|
-
const
|
|
6553
|
+
const ct = Qe, ht = ti, Lt = qe, _i = je, dt = (h, t, e) => {
|
|
6543
6554
|
const i = /* @__PURE__ */ new Map(), s = {
|
|
6544
6555
|
platform: Ii,
|
|
6545
6556
|
...e
|
|
@@ -6618,7 +6629,7 @@ let Si = class {
|
|
|
6618
6629
|
return;
|
|
6619
6630
|
this.enable = !0, this.contentEl.style.maxWidth = `${t.overflowTooltipMaxWidth || 500}px`, this.contentEl.style.minWidth = "100px", this.contentEl.style.width = "100%", this.contentEl.style.display = "inline-block", this.contentEl.style.wordBreak = "break-all", this.contentEl.style.lineHeight = "1.5", this.contentEl.innerText = e;
|
|
6620
6631
|
const s = t.drawX + i.x, o = t.drawY + i.y;
|
|
6621
|
-
|
|
6632
|
+
dt({
|
|
6622
6633
|
getBoundingClientRect() {
|
|
6623
6634
|
return {
|
|
6624
6635
|
width: t.visibleWidth,
|
|
@@ -6633,7 +6644,7 @@ let Si = class {
|
|
|
6633
6644
|
}
|
|
6634
6645
|
}, this.floatingEl, {
|
|
6635
6646
|
placement: t.overflowTooltipPlacement,
|
|
6636
|
-
middleware: [
|
|
6647
|
+
middleware: [ht(), Lt(), ct(6), _i({ element: this.arrowEl })]
|
|
6637
6648
|
}).then((a) => {
|
|
6638
6649
|
const { x: l, y: c, placement: d, middlewareData: f } = a;
|
|
6639
6650
|
if (Object.assign(this.floatingEl.style, {
|
|
@@ -6766,7 +6777,7 @@ class Ti {
|
|
|
6766
6777
|
"F12"
|
|
6767
6778
|
].includes(e) || this.startEdit(!0);
|
|
6768
6779
|
}), this.ctx.on("cellMouseup", (t) => {
|
|
6769
|
-
if (this.ctx.
|
|
6780
|
+
if (this.ctx.isPointer || !this.isInSelectorRange(t.rowIndex, t.colIndex))
|
|
6770
6781
|
return;
|
|
6771
6782
|
const { xArr: e, yArr: i } = this.ctx.selector, s = JSON.stringify(e) + JSON.stringify(i);
|
|
6772
6783
|
if (this.selectorArrStr === s && this.cellTarget) {
|
|
@@ -6819,7 +6830,7 @@ class Ti {
|
|
|
6819
6830
|
header: d
|
|
6820
6831
|
} = this.ctx;
|
|
6821
6832
|
let f = this.ctx.body.visibleHeight;
|
|
6822
|
-
o > f && (o = f), this.editorEl.style.display = "inline-block", this.editorEl.style.zIndex = "100", this.editorEl.style.left = `${this.drawX - 1}px`, this.editorEl.style.top = `${this.drawY - 1}px`, this.editorEl.style.bottom = "auto", this.editorEl.style.maxHeight = `${f}px`, s === "text" ? (this.inputEl.style.display = "inline-block", this.inputEl.style.minWidth = `${r - 1}px`, this.inputEl.style.minHeight = `${o - 1}px`, this.inputEl.style.maxHeight = `${f}px`, this.inputEl.style.width = `${r - 1}px`, this.inputEl.style.height = "auto", this.inputEl.style.padding = `${c}px`, this.inputEl.value = "", i !== null && (this.inputEl.value = i)) : this.inputEl.style.display = "none", (this.inputEl.scrollHeight > o || this.drawY < d.height) && this.autoSize();
|
|
6833
|
+
o > f && (o = f), this.editorEl.style.display = "inline-block", this.editorEl.style.zIndex = "100", this.editorEl.style.left = `${this.drawX - 1}px`, this.editorEl.style.top = `${this.drawY - 1}px`, this.editorEl.style.bottom = "auto", this.editorEl.style.maxHeight = `${f}px`, s === "text" ? (this.inputEl.style.display = "inline-block", this.inputEl.style.minWidth = `${r - 1}px`, this.inputEl.style.minHeight = `${o - 1}px`, this.inputEl.style.maxHeight = `${f}px`, this.inputEl.style.width = `${r - 1}px`, this.inputEl.style.height = "auto", this.inputEl.style.padding = `${c}px`, this.inputEl.value = "", i !== null && (this.inputEl.value = i, this.inputEl.focus({ preventScroll: !0 }))) : this.inputEl.style.display = "none", (this.inputEl.scrollHeight > o || this.drawY < d.height) && this.autoSize();
|
|
6823
6834
|
}
|
|
6824
6835
|
doneEditByInput() {
|
|
6825
6836
|
if (this.cellTarget && this.cellTarget.editorType === "text") {
|
|
@@ -6830,13 +6841,13 @@ class Ti {
|
|
|
6830
6841
|
startEdit(t = !1) {
|
|
6831
6842
|
this.cancel = !1;
|
|
6832
6843
|
const { ENABLE_EDIT_CLICK_SELECTOR: e } = this.ctx.config;
|
|
6833
|
-
if (!e)
|
|
6844
|
+
if (!e || this.ctx.adjustPositioning)
|
|
6834
6845
|
return;
|
|
6835
6846
|
const i = this.ctx.focusCell;
|
|
6836
6847
|
if (!i || ["index", "index-selection", "selection"].includes(i.type) || this.enable || !(i.isVerticalVisible() && i.isHorizontalVisible()))
|
|
6837
6848
|
return;
|
|
6838
6849
|
const { rowKey: o, key: r } = i, a = this.ctx.database.getReadonly(o, r);
|
|
6839
|
-
i && !a && (this.enable = !0, this.ctx.editing = !0, this.cellTarget = i, this.startEditByInput(this.cellTarget, t), this.ctx.emit("startEdit", this.cellTarget), this.ctx.emit("
|
|
6850
|
+
i && !a && (this.enable = !0, this.ctx.editing = !0, this.cellTarget = i, this.startEditByInput(this.cellTarget, t), this.ctx.emit("startEdit", this.cellTarget), this.ctx.emit("draw"));
|
|
6840
6851
|
}
|
|
6841
6852
|
editCell(t, e) {
|
|
6842
6853
|
const i = this.ctx.body.renderRows.find((c) => c.rowIndex === t);
|
|
@@ -6850,7 +6861,7 @@ class Ti {
|
|
|
6850
6861
|
if (!o || ["index", "index-selection", "selection"].includes(o.type) || this.enable)
|
|
6851
6862
|
return;
|
|
6852
6863
|
const { rowKey: r, key: a } = o, l = this.ctx.database.getReadonly(r, a);
|
|
6853
|
-
o && !l && (this.enable = !0, this.ctx.editing = !0, this.cellTarget = o, this.startEditByInput(this.cellTarget), this.ctx.emit("startEdit", this.cellTarget), this.ctx.emit("
|
|
6864
|
+
o && !l && (this.enable = !0, this.ctx.editing = !0, this.cellTarget = o, this.startEditByInput(this.cellTarget), this.ctx.emit("startEdit", this.cellTarget), this.ctx.emit("draw"));
|
|
6854
6865
|
}
|
|
6855
6866
|
doneEdit() {
|
|
6856
6867
|
this.enable && (this.doneEditByInput(), this.ctx.emit("doneEdit", this.cellTarget), this.enable = !1, this.ctx.editing = !1, this.inputEl.style.display = "inline-block", this.editorEl.style.zIndex = "-1", setTimeout(() => {
|
|
@@ -6893,24 +6904,7 @@ class Li {
|
|
|
6893
6904
|
constructor(t) {
|
|
6894
6905
|
n(this, "ctx");
|
|
6895
6906
|
n(this, "observer");
|
|
6896
|
-
this.ctx = t, this.
|
|
6897
|
-
J(() => {
|
|
6898
|
-
const e = this.ctx.overlayerElement.querySelectorAll('[data-auto-height="true"]'), i = /* @__PURE__ */ new Map();
|
|
6899
|
-
e.forEach((r) => {
|
|
6900
|
-
const a = Number(r.getAttribute("data-row-index")), l = Number(r.getAttribute("data-col-index"));
|
|
6901
|
-
if (isNaN(a) || isNaN(l) || !(r instanceof HTMLElement) || r.offsetWidth === 0)
|
|
6902
|
-
return;
|
|
6903
|
-
const c = `${a}_${l}`;
|
|
6904
|
-
i.set(c, Math.round(r.offsetHeight));
|
|
6905
|
-
});
|
|
6906
|
-
const s = this.ctx.database.getOverlayerAutoHeightMap();
|
|
6907
|
-
if (!this.arerMapsEqual(s, i)) {
|
|
6908
|
-
if (this.ctx.database.setOverlayerAutoHeightMap(i), s.size === 0 && i.size === 0)
|
|
6909
|
-
return;
|
|
6910
|
-
this.ctx.emit("draw");
|
|
6911
|
-
}
|
|
6912
|
-
}, 16.67)
|
|
6913
|
-
), this.observer.observe(this.ctx.overlayerElement, { childList: !0, subtree: !0, attributes: !0 });
|
|
6907
|
+
this.ctx = t, this.init();
|
|
6914
6908
|
}
|
|
6915
6909
|
arerMapsEqual(t, e) {
|
|
6916
6910
|
if (t.size !== e.size) return !1;
|
|
@@ -6918,6 +6912,40 @@ class Li {
|
|
|
6918
6912
|
if (!e.has(i) || e.get(i) !== s) return !1;
|
|
6919
6913
|
return !0;
|
|
6920
6914
|
}
|
|
6915
|
+
init() {
|
|
6916
|
+
this.observer = new MutationObserver(
|
|
6917
|
+
yt(() => {
|
|
6918
|
+
const t = this.ctx.overlayerElement.querySelectorAll('[data-auto-height="true"]'), e = /* @__PURE__ */ new Map();
|
|
6919
|
+
t.forEach((o) => {
|
|
6920
|
+
const r = Number(o.getAttribute("data-row-index")), a = Number(o.getAttribute("data-col-index"));
|
|
6921
|
+
if (isNaN(r) || isNaN(a) || !(o instanceof HTMLElement) || o.offsetWidth === 0)
|
|
6922
|
+
return;
|
|
6923
|
+
const l = `${r}_${a}`;
|
|
6924
|
+
e.set(l, Math.round(o.offsetHeight));
|
|
6925
|
+
});
|
|
6926
|
+
const i = this.ctx.database.getOverlayerAutoHeightMap();
|
|
6927
|
+
if (!this.arerMapsEqual(i, e)) {
|
|
6928
|
+
if (this.ctx.database.setOverlayerAutoHeightMap(e), i.size === 0 && e.size === 0)
|
|
6929
|
+
return;
|
|
6930
|
+
this.ctx.emit("draw");
|
|
6931
|
+
}
|
|
6932
|
+
}, 16.67)
|
|
6933
|
+
), this.observer.observe(this.ctx.overlayerElement, { childList: !0, subtree: !0, attributes: !0 }), this.ctx.overlayerElement.getAttribute("data-overlayer") === "default" && this.ctx.on("overlayerChange", (t) => {
|
|
6934
|
+
const e = this.ctx.overlayerElement;
|
|
6935
|
+
e.replaceChildren(), Object.assign(e.style, t.style), t.views.forEach((i) => {
|
|
6936
|
+
const s = document.createElement("div");
|
|
6937
|
+
s.className = i.class, Object.assign(s.style, i.style), i.views.forEach((o) => {
|
|
6938
|
+
const r = document.createElement("div");
|
|
6939
|
+
Object.assign(r.style, o.style), o.cells.forEach((a) => {
|
|
6940
|
+
const l = document.createElement("div");
|
|
6941
|
+
Object.assign(l.style, a.style), Object.keys(a.domDataset).forEach((c) => {
|
|
6942
|
+
l.setAttribute(c, a.domDataset[c]);
|
|
6943
|
+
}), typeof a.render == "function" && a.render(l, a), r.appendChild(l);
|
|
6944
|
+
}), s.appendChild(r);
|
|
6945
|
+
}), e.appendChild(s);
|
|
6946
|
+
});
|
|
6947
|
+
});
|
|
6948
|
+
}
|
|
6921
6949
|
draw() {
|
|
6922
6950
|
const t = this.getContainer();
|
|
6923
6951
|
this.ctx.emit("overlayerChange", t);
|
|
@@ -7196,10 +7224,10 @@ class Pt {
|
|
|
7196
7224
|
async showSubmenu(t, e) {
|
|
7197
7225
|
if (this.activeSubmenus.has(e)) return;
|
|
7198
7226
|
this.activeSubmenus.add(e), e.classList.add("show");
|
|
7199
|
-
const i =
|
|
7200
|
-
const s = this.container.getBoundingClientRect(), o = window.innerWidth, r = e.offsetWidth || 200, a = o - s.right, l = s.left, c = a >= r || a >= l ? "right-start" : "left-start", { x: d, y: f } = await
|
|
7227
|
+
const i = Ct(t, e, async () => {
|
|
7228
|
+
const s = this.container.getBoundingClientRect(), o = window.innerWidth, r = e.offsetWidth || 200, a = o - s.right, l = s.left, c = a >= r || a >= l ? "right-start" : "left-start", { x: d, y: f } = await dt(t, e, {
|
|
7201
7229
|
placement: c,
|
|
7202
|
-
middleware: [
|
|
7230
|
+
middleware: [ct(8), ht({ padding: 8 })]
|
|
7203
7231
|
});
|
|
7204
7232
|
Object.assign(e.style, {
|
|
7205
7233
|
left: `${d}px`,
|
|
@@ -7266,10 +7294,10 @@ class Pt {
|
|
|
7266
7294
|
}),
|
|
7267
7295
|
contextElement: document.body
|
|
7268
7296
|
};
|
|
7269
|
-
|
|
7270
|
-
|
|
7297
|
+
Ct(e, this.container, () => {
|
|
7298
|
+
dt(e, this.container, {
|
|
7271
7299
|
placement: "right-start",
|
|
7272
|
-
middleware: [
|
|
7300
|
+
middleware: [ct(), ht(), Lt()]
|
|
7273
7301
|
}).then(({ x: i, y: s }) => {
|
|
7274
7302
|
this.container && Object.assign(this.container.style, {
|
|
7275
7303
|
left: `${i}px`,
|
|
@@ -7392,7 +7420,7 @@ class Mi {
|
|
|
7392
7420
|
const S = b.replace("visible_", "");
|
|
7393
7421
|
this.ctx.database.setCustomHeaderHideData([S], !1), this.currentDOMTreeMenu && this.currentDOMTreeMenu.removeSubMenuItem(b);
|
|
7394
7422
|
const R = this.ctx.database.getColumns();
|
|
7395
|
-
|
|
7423
|
+
J(R).filter((O) => O.hide).length === 0 && this.hide();
|
|
7396
7424
|
} else b === "resetHeader" && (this.ctx.database.resetCustomHeader(), this.hide());
|
|
7397
7425
|
}
|
|
7398
7426
|
}), this.positionMenu(e);
|
|
@@ -7414,10 +7442,10 @@ class Mi {
|
|
|
7414
7442
|
}),
|
|
7415
7443
|
contextElement: document.body
|
|
7416
7444
|
};
|
|
7417
|
-
|
|
7418
|
-
|
|
7445
|
+
Ct(e, this.contextMenuEl, () => {
|
|
7446
|
+
dt(e, this.contextMenuEl, {
|
|
7419
7447
|
placement: "right-start",
|
|
7420
|
-
middleware: [
|
|
7448
|
+
middleware: [ct(), ht(), Lt()]
|
|
7421
7449
|
}).then(({ x: i, y: s }) => {
|
|
7422
7450
|
this.contextMenuEl && Object.assign(this.contextMenuEl.style, {
|
|
7423
7451
|
left: `${i}px`,
|
|
@@ -7505,28 +7533,16 @@ class ki {
|
|
|
7505
7533
|
o,
|
|
7506
7534
|
r
|
|
7507
7535
|
);
|
|
7508
|
-
this.ctx = new Le(a, this.options), this.header = new He(this.ctx), this.footer = new Ne(this.ctx), this.body = new De(this.ctx), this.scroller = new Me(this.ctx), this.selector = new ke(this.ctx), this.autofill = new Xe(this.ctx), this.tooltip = new Si(this.ctx), this.empty = new Oi(this.ctx), this.editor = new Ti(this.ctx), this.overlayer = new Li(this.ctx), this.contextMenu = new Mi(this.ctx), this.loading = new Ai(this.ctx), this.ctx.on(
|
|
7509
|
-
|
|
7510
|
-
|
|
7511
|
-
|
|
7512
|
-
|
|
7513
|
-
},
|
|
7514
|
-
() => this.ctx.drawTime
|
|
7515
|
-
)
|
|
7516
|
-
), this.ctx.on(
|
|
7517
|
-
"drawView",
|
|
7518
|
-
J(
|
|
7519
|
-
() => {
|
|
7520
|
-
this.draw(!0);
|
|
7521
|
-
},
|
|
7522
|
-
() => this.ctx.drawTime
|
|
7523
|
-
)
|
|
7524
|
-
), this.draw();
|
|
7536
|
+
this.ctx = new Le(a, this.options), this.header = new He(this.ctx), this.footer = new Ne(this.ctx), this.body = new De(this.ctx), this.scroller = new Me(this.ctx), this.selector = new ke(this.ctx), this.autofill = new Xe(this.ctx), this.tooltip = new Si(this.ctx), this.empty = new Oi(this.ctx), this.editor = new Ti(this.ctx), this.overlayer = new Li(this.ctx), this.contextMenu = new Mi(this.ctx), this.loading = new Ai(this.ctx), this.ctx.on("draw", () => {
|
|
7537
|
+
this.draw();
|
|
7538
|
+
}), this.ctx.on("drawView", () => {
|
|
7539
|
+
this.draw(!0);
|
|
7540
|
+
}), this.draw();
|
|
7525
7541
|
}
|
|
7526
7542
|
createContainer(t, e, i, s, o) {
|
|
7527
7543
|
t.className = "e-virt-table-container";
|
|
7528
7544
|
const r = document.createElement("div"), a = document.createElement("canvas"), l = e || document.createElement("div");
|
|
7529
|
-
r.className = "e-virt-table-stage", t.tabIndex = 0, a.className = "e-virt-table-canvas", l.className = "e-virt-table-overlayer";
|
|
7545
|
+
r.className = "e-virt-table-stage", t.tabIndex = 0, a.className = "e-virt-table-canvas", l.className = "e-virt-table-overlayer", l.setAttribute("data-overlayer", e ? "custom" : "default");
|
|
7530
7546
|
const c = i || document.createElement("div");
|
|
7531
7547
|
c.className = "e-virt-table-editor";
|
|
7532
7548
|
const d = s, f = o;
|
|
@@ -7542,12 +7558,9 @@ class ki {
|
|
|
7542
7558
|
}
|
|
7543
7559
|
draw(t = !1) {
|
|
7544
7560
|
this.animationFrameId && cancelAnimationFrame(this.animationFrameId), this.animationFrameId = requestAnimationFrame(() => {
|
|
7545
|
-
const e = performance.now();
|
|
7546
7561
|
this.header.update(), this.footer.update(), this.body.update(), this.ctx.paint.clear(), this.body.draw(), this.footer.draw(), this.header.draw(), this.scroller.draw(), t || this.overlayer.draw(), this.animationFrameId2 && cancelAnimationFrame(this.animationFrameId2), this.animationFrameId2 = requestAnimationFrame(() => {
|
|
7547
7562
|
this.body.updateAutoHeight();
|
|
7548
7563
|
});
|
|
7549
|
-
const i = performance.now(), s = Math.round(i - e);
|
|
7550
|
-
this.ctx.drawTime = s * this.ctx.config.DRAW_TIME_MULTIPLIER;
|
|
7551
7564
|
});
|
|
7552
7565
|
}
|
|
7553
7566
|
loadConfig(t) {
|
|
@@ -7790,6 +7803,9 @@ class ki {
|
|
|
7790
7803
|
var e;
|
|
7791
7804
|
return (e = this.ctx.database.getColumnByKey(t)) == null ? void 0 : e.column;
|
|
7792
7805
|
}
|
|
7806
|
+
clearChangeData() {
|
|
7807
|
+
this.ctx.database.clearChangeData(), this.ctx.emit("draw");
|
|
7808
|
+
}
|
|
7793
7809
|
/**
|
|
7794
7810
|
* 销毁
|
|
7795
7811
|
*/
|