vxe-table 4.11.0-beta.2 → 4.11.0-beta.4
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/README.md +18 -13
- package/es/index.css +1 -1
- package/es/index.min.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/module/edit/hook.js +1 -7
- package/es/table/src/body.js +4 -2
- package/es/table/src/cell.js +3 -0
- package/es/table/src/footer.js +4 -2
- package/es/table/src/header.js +4 -2
- package/es/table/src/table.js +24 -13
- package/es/table/style.css +1 -1
- package/es/table/style.min.css +1 -1
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/es/vxe-table/style.css +1 -1
- package/es/vxe-table/style.min.css +1 -1
- package/lib/index.css +1 -1
- package/lib/index.min.css +1 -1
- package/lib/index.umd.js +38 -27
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/module/edit/hook.js +1 -9
- package/lib/table/module/edit/hook.min.js +1 -1
- package/lib/table/src/body.js +4 -1
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/cell.js +3 -0
- package/lib/table/src/cell.min.js +1 -1
- package/lib/table/src/footer.js +4 -1
- package/lib/table/src/footer.min.js +1 -1
- package/lib/table/src/header.js +4 -1
- package/lib/table/src/header.min.js +1 -1
- package/lib/table/src/table.js +20 -13
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/style/style.css +1 -1
- package/lib/table/style/style.min.css +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/vxe-table/style/style.css +1 -1
- package/lib/vxe-table/style/style.min.css +1 -1
- package/package.json +1 -1
- package/packages/table/module/edit/hook.ts +1 -7
- package/packages/table/src/body.ts +5 -2
- package/packages/table/src/cell.ts +3 -0
- package/packages/table/src/footer.ts +5 -2
- package/packages/table/src/header.ts +5 -2
- package/packages/table/src/table.ts +25 -14
- package/styles/components/table.scss +1 -1
- /package/es/{iconfont.1739506388714.ttf → iconfont.1739527666244.ttf} +0 -0
- /package/es/{iconfont.1739506388714.woff → iconfont.1739527666244.woff} +0 -0
- /package/es/{iconfont.1739506388714.woff2 → iconfont.1739527666244.woff2} +0 -0
- /package/lib/{iconfont.1739506388714.ttf → iconfont.1739527666244.ttf} +0 -0
- /package/lib/{iconfont.1739506388714.woff → iconfont.1739527666244.woff} +0 -0
- /package/lib/{iconfont.1739506388714.woff2 → iconfont.1739527666244.woff2} +0 -0
package/es/table/src/footer.js
CHANGED
|
@@ -245,7 +245,7 @@ export default defineComponent({
|
|
|
245
245
|
const { fixedType, fixedColumn, tableColumn } = props;
|
|
246
246
|
const { spanMethod, footerSpanMethod, showFooterOverflow: allColumnFooterOverflow } = tableProps;
|
|
247
247
|
const { visibleColumn, fullColumnIdData } = tableInternalData;
|
|
248
|
-
const { isGroup, scrollXLoad, scrollYLoad, dragCol } = tableReactData;
|
|
248
|
+
const { isGroup, overflowX, scrollXLoad, scrollYLoad, dragCol } = tableReactData;
|
|
249
249
|
let renderColumnList = tableColumn;
|
|
250
250
|
let isOptimizeMode = false;
|
|
251
251
|
// 如果是使用优化模式
|
|
@@ -257,8 +257,10 @@ export default defineComponent({
|
|
|
257
257
|
isOptimizeMode = true;
|
|
258
258
|
}
|
|
259
259
|
}
|
|
260
|
-
if (fixedType) {
|
|
260
|
+
if (fixedType || !overflowX) {
|
|
261
261
|
renderColumnList = visibleColumn;
|
|
262
|
+
}
|
|
263
|
+
if (fixedType) {
|
|
262
264
|
if (isOptimizeMode) {
|
|
263
265
|
renderColumnList = fixedColumn || [];
|
|
264
266
|
}
|
package/es/table/src/header.js
CHANGED
|
@@ -199,7 +199,7 @@ export default defineComponent({
|
|
|
199
199
|
const renderVN = () => {
|
|
200
200
|
const { fixedType, fixedColumn, tableColumn } = props;
|
|
201
201
|
const { mouseConfig, showHeaderOverflow: allColumnHeaderOverflow, spanMethod, footerSpanMethod } = tableProps;
|
|
202
|
-
const { isGroup, scrollXLoad, scrollYLoad, dragCol } = tableReactData;
|
|
202
|
+
const { isGroup, overflowX, scrollXLoad, scrollYLoad, dragCol } = tableReactData;
|
|
203
203
|
const { visibleColumn, fullColumnIdData } = tableInternalData;
|
|
204
204
|
const mouseOpts = computeMouseOpts.value;
|
|
205
205
|
let renderHeaderList = headerColumn.value;
|
|
@@ -218,8 +218,10 @@ export default defineComponent({
|
|
|
218
218
|
isOptimizeMode = true;
|
|
219
219
|
}
|
|
220
220
|
}
|
|
221
|
-
if (fixedType) {
|
|
221
|
+
if (fixedType || !overflowX) {
|
|
222
222
|
renderColumnList = visibleColumn;
|
|
223
|
+
}
|
|
224
|
+
if (fixedType) {
|
|
223
225
|
// 如果是使用优化模式
|
|
224
226
|
if (isOptimizeMode) {
|
|
225
227
|
renderColumnList = fixedColumn || [];
|
package/es/table/src/table.js
CHANGED
|
@@ -1141,7 +1141,7 @@ export default defineComponent({
|
|
|
1141
1141
|
const { tableFullColumn, collectColumn } = internalData;
|
|
1142
1142
|
const fullColumnIdData = internalData.fullColumnIdData = {};
|
|
1143
1143
|
const fullColumnFieldData = internalData.fullColumnFieldData = {};
|
|
1144
|
-
const mouseOpts = computeMouseOpts.value
|
|
1144
|
+
// const mouseOpts = computeMouseOpts.value
|
|
1145
1145
|
const columnOpts = computeColumnOpts.value;
|
|
1146
1146
|
const columnDragOpts = computeColumnDragOpts.value;
|
|
1147
1147
|
const { isCrossDrag, isSelfToChildDrag } = columnDragOpts;
|
|
@@ -1231,11 +1231,11 @@ export default defineComponent({
|
|
|
1231
1231
|
else {
|
|
1232
1232
|
tableFullColumn.forEach(handleFunc);
|
|
1233
1233
|
}
|
|
1234
|
-
if (process.env.NODE_ENV === 'development') {
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
}
|
|
1234
|
+
// if (process.env.NODE_ENV === 'development') {
|
|
1235
|
+
// if (expandColumn && mouseOpts.area) {
|
|
1236
|
+
// errLog('vxe.error.errConflicts', ['mouse-config.area', 'column.type=expand'])
|
|
1237
|
+
// }
|
|
1238
|
+
// }
|
|
1239
1239
|
if (process.env.NODE_ENV === 'development') {
|
|
1240
1240
|
if (htmlColumn) {
|
|
1241
1241
|
if (!columnOpts.useKey) {
|
|
@@ -2472,7 +2472,10 @@ export default defineComponent({
|
|
|
2472
2472
|
delete rExpandLazyLoadedMaps[rowid];
|
|
2473
2473
|
}
|
|
2474
2474
|
reactData.rowExpandLazyLoadedMaps = rExpandLazyLoadedMaps;
|
|
2475
|
-
nextTick()
|
|
2475
|
+
nextTick()
|
|
2476
|
+
.then(() => $xeTable.recalculate())
|
|
2477
|
+
.then(() => $xeTable.updateCellAreas())
|
|
2478
|
+
.then(() => resolve());
|
|
2476
2479
|
});
|
|
2477
2480
|
}
|
|
2478
2481
|
else {
|
|
@@ -5122,7 +5125,9 @@ export default defineComponent({
|
|
|
5122
5125
|
}
|
|
5123
5126
|
}
|
|
5124
5127
|
reactData.rowExpandedMaps = rExpandedMaps;
|
|
5125
|
-
return Promise.all(lazyRests)
|
|
5128
|
+
return Promise.all(lazyRests)
|
|
5129
|
+
.then(() => $xeTable.recalculate())
|
|
5130
|
+
.then(() => $xeTable.updateCellAreas());
|
|
5126
5131
|
},
|
|
5127
5132
|
/**
|
|
5128
5133
|
* 判断行是否为展开状态
|
|
@@ -5156,7 +5161,7 @@ export default defineComponent({
|
|
|
5156
5161
|
if (expList.length) {
|
|
5157
5162
|
tableMethods.recalculate();
|
|
5158
5163
|
}
|
|
5159
|
-
});
|
|
5164
|
+
}).then(() => $xeTable.updateCellAreas());
|
|
5160
5165
|
},
|
|
5161
5166
|
clearRowExpandReserve() {
|
|
5162
5167
|
internalData.rowExpandedReserveRowMap = {};
|
|
@@ -5576,8 +5581,8 @@ export default defineComponent({
|
|
|
5576
5581
|
updateCellAreas() {
|
|
5577
5582
|
const { mouseConfig } = props;
|
|
5578
5583
|
const mouseOpts = computeMouseOpts.value;
|
|
5579
|
-
if (mouseConfig && mouseOpts.area && $xeTable.
|
|
5580
|
-
return $xeTable.
|
|
5584
|
+
if (mouseConfig && mouseOpts.area && $xeTable.handleRecalculateCellAreaEvent) {
|
|
5585
|
+
return $xeTable.handleRecalculateCellAreaEvent();
|
|
5581
5586
|
}
|
|
5582
5587
|
return nextTick();
|
|
5583
5588
|
},
|
|
@@ -8926,7 +8931,7 @@ export default defineComponent({
|
|
|
8926
8931
|
updateScrollYStatus,
|
|
8927
8932
|
// 更新横向 X 可视渲染上下剩余空间大小
|
|
8928
8933
|
updateScrollXSpace() {
|
|
8929
|
-
const { isGroup, scrollXLoad } = reactData;
|
|
8934
|
+
const { isGroup, scrollXLoad, overflowX } = reactData;
|
|
8930
8935
|
const { visibleColumn, scrollXStore, elemStore, tableWidth } = internalData;
|
|
8931
8936
|
const tableHeader = refTableHeader.value;
|
|
8932
8937
|
const tableBody = refTableBody.value;
|
|
@@ -8940,7 +8945,7 @@ export default defineComponent({
|
|
|
8940
8945
|
const footerElem = tableFooterElem ? tableFooterElem.querySelector('.vxe-table--footer') : null;
|
|
8941
8946
|
const leftSpaceWidth = visibleColumn.slice(0, scrollXStore.startIndex).reduce((previous, column) => previous + column.renderWidth, 0);
|
|
8942
8947
|
let marginLeft = '';
|
|
8943
|
-
if (scrollXLoad) {
|
|
8948
|
+
if (scrollXLoad && overflowX) {
|
|
8944
8949
|
marginLeft = `${leftSpaceWidth}px`;
|
|
8945
8950
|
}
|
|
8946
8951
|
if (headerElem) {
|
|
@@ -9806,6 +9811,12 @@ export default defineComponent({
|
|
|
9806
9811
|
watch(() => props.showFooter, () => {
|
|
9807
9812
|
reScrollFlag.value++;
|
|
9808
9813
|
});
|
|
9814
|
+
watch(() => reactData.overflowX, () => {
|
|
9815
|
+
reScrollFlag.value++;
|
|
9816
|
+
});
|
|
9817
|
+
watch(() => reactData.overflowY, () => {
|
|
9818
|
+
reScrollFlag.value++;
|
|
9819
|
+
});
|
|
9809
9820
|
watch(reScrollFlag, () => {
|
|
9810
9821
|
nextTick(() => {
|
|
9811
9822
|
tableMethods.recalculate(true).then(() => tableMethods.refreshScroll());
|