vxe-table 3.15.10 → 3.15.12
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/es/locale/lang/ar-EG.js +511 -511
- package/es/locale/lang/de-DE.js +280 -280
- package/es/locale/lang/en-US.js +206 -206
- package/es/locale/lang/es-ES.js +494 -501
- package/es/locale/lang/fr-FR.js +517 -517
- package/es/locale/lang/hu-HU.js +372 -372
- package/es/locale/lang/id-ID.js +529 -529
- package/es/locale/lang/it-IT.js +297 -297
- package/es/locale/lang/ja-JP.js +454 -454
- package/es/locale/lang/ko-KR.js +415 -415
- package/es/locale/lang/nb-NO.js +515 -515
- package/es/locale/lang/pt-BR.js +505 -505
- package/es/locale/lang/ru-RU.js +326 -326
- package/es/locale/lang/th-TH.js +255 -255
- package/es/locale/lang/uk-UA.js +450 -450
- package/es/locale/lang/vi-VN.js +528 -528
- package/es/locale/lang/zh-CHT.js +155 -155
- package/es/style.css +1 -1
- package/es/table/src/methods.js +48 -48
- package/es/table/src/util.js +12 -16
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +63 -75
- package/lib/index.umd.min.js +1 -1
- package/lib/locale/lang/ar-EG.js +511 -511
- package/lib/locale/lang/ar-EG.min.js +1 -1
- package/lib/locale/lang/de-DE.js +280 -280
- package/lib/locale/lang/de-DE.min.js +1 -1
- package/lib/locale/lang/en-US.js +206 -206
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +206 -206
- package/lib/locale/lang/es-ES.js +494 -501
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +494 -501
- package/lib/locale/lang/fr-FR.js +517 -517
- package/lib/locale/lang/fr-FR.min.js +1 -1
- package/lib/locale/lang/hu-HU.js +372 -372
- package/lib/locale/lang/hu-HU.min.js +1 -1
- package/lib/locale/lang/hu-HU.umd.js +372 -372
- package/lib/locale/lang/id-ID.js +529 -529
- package/lib/locale/lang/id-ID.min.js +1 -1
- package/lib/locale/lang/it-IT.js +297 -297
- package/lib/locale/lang/it-IT.min.js +1 -1
- package/lib/locale/lang/ja-JP.js +454 -454
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +454 -454
- package/lib/locale/lang/ko-KR.js +415 -415
- package/lib/locale/lang/ko-KR.min.js +1 -1
- package/lib/locale/lang/ko-KR.umd.js +415 -415
- package/lib/locale/lang/nb-NO.js +515 -515
- package/lib/locale/lang/nb-NO.min.js +1 -1
- package/lib/locale/lang/pt-BR.js +505 -505
- package/lib/locale/lang/pt-BR.min.js +1 -1
- package/lib/locale/lang/pt-BR.umd.js +505 -505
- package/lib/locale/lang/ru-RU.js +326 -326
- package/lib/locale/lang/ru-RU.min.js +1 -1
- package/lib/locale/lang/ru-RU.umd.js +326 -326
- package/lib/locale/lang/th-TH.js +255 -255
- package/lib/locale/lang/th-TH.min.js +1 -1
- package/lib/locale/lang/uk-UA.js +450 -450
- package/lib/locale/lang/uk-UA.min.js +1 -1
- package/lib/locale/lang/uk-UA.umd.js +450 -450
- package/lib/locale/lang/vi-VN.js +528 -528
- package/lib/locale/lang/vi-VN.min.js +1 -1
- package/lib/locale/lang/zh-CHT.js +155 -155
- package/lib/locale/lang/zh-CHT.min.js +1 -1
- package/lib/locale/lang/zh-CHT.umd.js +155 -155
- package/lib/style.css +1 -1
- package/lib/table/src/methods.js +49 -57
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/util.js +12 -16
- package/lib/table/src/util.min.js +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/package.json +2 -2
- package/packages/locale/lang/ar-EG.ts +511 -511
- package/packages/locale/lang/de-DE.ts +281 -282
- package/packages/locale/lang/en-US.ts +206 -206
- package/packages/locale/lang/es-ES.ts +494 -503
- package/packages/locale/lang/fr-FR.ts +517 -517
- package/packages/locale/lang/hu-HU.ts +372 -372
- package/packages/locale/lang/id-ID.ts +529 -529
- package/packages/locale/lang/it-IT.ts +297 -297
- package/packages/locale/lang/ja-JP.ts +454 -454
- package/packages/locale/lang/ko-KR.ts +415 -415
- package/packages/locale/lang/nb-NO.ts +515 -515
- package/packages/locale/lang/pt-BR.ts +505 -505
- package/packages/locale/lang/ru-RU.ts +326 -326
- package/packages/locale/lang/th-TH.ts +255 -255
- package/packages/locale/lang/uk-UA.ts +450 -450
- package/packages/locale/lang/vi-VN.ts +528 -528
- package/packages/locale/lang/zh-CHT.ts +155 -155
- package/packages/table/src/methods.ts +59 -55
- package/packages/table/src/util.ts +12 -17
- /package/es/{iconfont.1745546354510.ttf → iconfont.1745723938260.ttf} +0 -0
- /package/es/{iconfont.1745546354510.woff → iconfont.1745723938260.woff} +0 -0
- /package/es/{iconfont.1745546354510.woff2 → iconfont.1745723938260.woff2} +0 -0
- /package/lib/{iconfont.1745546354510.ttf → iconfont.1745723938260.ttf} +0 -0
- /package/lib/{iconfont.1745546354510.woff → iconfont.1745723938260.woff} +0 -0
- /package/lib/{iconfont.1745546354510.woff2 → iconfont.1745723938260.woff2} +0 -0
package/lib/table/src/methods.js
CHANGED
|
@@ -8505,10 +8505,10 @@ const Methods = {
|
|
|
8505
8505
|
if (!actived.args || evnt.currentTarget !== actived.args.cell) {
|
|
8506
8506
|
if (editOpts.mode === 'row') {
|
|
8507
8507
|
checkValidate($xeTable, 'blur').catch(e => e).then(() => {
|
|
8508
|
-
|
|
8508
|
+
$xeTable.handleEdit(params, evnt).then(() => checkValidate($xeTable, 'change')).catch(e => e);
|
|
8509
8509
|
});
|
|
8510
8510
|
} else if (editOpts.mode === 'cell') {
|
|
8511
|
-
|
|
8511
|
+
$xeTable.handleEdit(params, evnt).then(() => checkValidate($xeTable, 'change')).catch(e => e);
|
|
8512
8512
|
}
|
|
8513
8513
|
}
|
|
8514
8514
|
}
|
|
@@ -9505,9 +9505,7 @@ const Methods = {
|
|
|
9505
9505
|
},
|
|
9506
9506
|
sort(sortConfs, sortOrder) {
|
|
9507
9507
|
const $xeTable = this;
|
|
9508
|
-
const
|
|
9509
|
-
sortOpts
|
|
9510
|
-
} = this;
|
|
9508
|
+
const sortOpts = $xeTable.computeSortOpts;
|
|
9511
9509
|
const {
|
|
9512
9510
|
multiple,
|
|
9513
9511
|
remote,
|
|
@@ -9527,7 +9525,7 @@ const Methods = {
|
|
|
9527
9525
|
if (sortConfs.length) {
|
|
9528
9526
|
let firstSortColumn;
|
|
9529
9527
|
if (!multiple) {
|
|
9530
|
-
clearAllSort(
|
|
9528
|
+
clearAllSort($xeTable);
|
|
9531
9529
|
}
|
|
9532
9530
|
(multiple ? sortConfs : [sortConfs[0]]).forEach((confs, index) => {
|
|
9533
9531
|
let {
|
|
@@ -9536,14 +9534,14 @@ const Methods = {
|
|
|
9536
9534
|
} = confs;
|
|
9537
9535
|
let column = field;
|
|
9538
9536
|
if (_xeUtils.default.isString(field)) {
|
|
9539
|
-
column =
|
|
9537
|
+
column = $xeTable.getColumnByField(field);
|
|
9540
9538
|
}
|
|
9541
9539
|
if (column && (column.sortable || column.remoteSort)) {
|
|
9542
9540
|
if (!firstSortColumn) {
|
|
9543
9541
|
firstSortColumn = column;
|
|
9544
9542
|
}
|
|
9545
|
-
if (orders.indexOf(order) === -1) {
|
|
9546
|
-
order = getNextSortOrder(
|
|
9543
|
+
if (orders && orders.indexOf(order) === -1) {
|
|
9544
|
+
order = getNextSortOrder($xeTable, column);
|
|
9547
9545
|
}
|
|
9548
9546
|
if (column.order !== order) {
|
|
9549
9547
|
column.order = order;
|
|
@@ -9553,14 +9551,15 @@ const Methods = {
|
|
|
9553
9551
|
});
|
|
9554
9552
|
// 如果是服务端排序,则跳过本地排序处理
|
|
9555
9553
|
if (!remote || firstSortColumn && firstSortColumn.remoteSort) {
|
|
9556
|
-
|
|
9554
|
+
$xeTable.handleTableData(true);
|
|
9557
9555
|
}
|
|
9558
|
-
return
|
|
9559
|
-
|
|
9556
|
+
return $xeTable.$nextTick().then(() => {
|
|
9557
|
+
updateRowOffsetTop($xeTable);
|
|
9558
|
+
$xeTable.updateCellAreas();
|
|
9560
9559
|
return updateStyle($xeTable);
|
|
9561
9560
|
});
|
|
9562
9561
|
}
|
|
9563
|
-
return
|
|
9562
|
+
return $xeTable.$nextTick();
|
|
9564
9563
|
},
|
|
9565
9564
|
setSort(sortConfs, isUpdate) {
|
|
9566
9565
|
const $xeTable = this;
|
|
@@ -9592,7 +9591,7 @@ const Methods = {
|
|
|
9592
9591
|
firstColumn = column;
|
|
9593
9592
|
}
|
|
9594
9593
|
if (column && column.sortable) {
|
|
9595
|
-
if (orders.indexOf(order) === -1) {
|
|
9594
|
+
if (orders && orders.indexOf(order) === -1) {
|
|
9596
9595
|
order = getNextSortOrder($xeTable, column);
|
|
9597
9596
|
}
|
|
9598
9597
|
if (column.order !== order) {
|
|
@@ -9608,6 +9607,7 @@ const Methods = {
|
|
|
9608
9607
|
$xeTable.handleColumnSortEvent(new Event('click'), firstColumn);
|
|
9609
9608
|
}
|
|
9610
9609
|
return $xeTable.$nextTick().then(() => {
|
|
9610
|
+
updateRowOffsetTop($xeTable);
|
|
9611
9611
|
$xeTable.updateCellAreas();
|
|
9612
9612
|
return updateStyle($xeTable);
|
|
9613
9613
|
});
|
|
@@ -9621,21 +9621,22 @@ const Methods = {
|
|
|
9621
9621
|
*/
|
|
9622
9622
|
clearSort(fieldOrColumn) {
|
|
9623
9623
|
const $xeTable = this;
|
|
9624
|
-
const
|
|
9625
|
-
sortOpts
|
|
9626
|
-
} = this;
|
|
9624
|
+
const sortOpts = $xeTable.computeSortOpts;
|
|
9627
9625
|
if (fieldOrColumn) {
|
|
9628
|
-
const column = (0, _util.handleFieldOrColumn)(
|
|
9626
|
+
const column = (0, _util.handleFieldOrColumn)($xeTable, fieldOrColumn);
|
|
9629
9627
|
if (column) {
|
|
9630
9628
|
column.order = null;
|
|
9631
9629
|
}
|
|
9632
9630
|
} else {
|
|
9633
|
-
clearAllSort(
|
|
9631
|
+
clearAllSort($xeTable);
|
|
9634
9632
|
}
|
|
9635
9633
|
if (!sortOpts.remote) {
|
|
9636
|
-
|
|
9634
|
+
$xeTable.handleTableData(true);
|
|
9637
9635
|
}
|
|
9638
|
-
return
|
|
9636
|
+
return $xeTable.$nextTick().then(() => {
|
|
9637
|
+
updateRowOffsetTop($xeTable);
|
|
9638
|
+
return updateStyle($xeTable);
|
|
9639
|
+
});
|
|
9639
9640
|
},
|
|
9640
9641
|
// 在 v3 中废弃
|
|
9641
9642
|
getSortColumn() {
|
|
@@ -11211,54 +11212,44 @@ const Methods = {
|
|
|
11211
11212
|
*/
|
|
11212
11213
|
scrollTo(scrollLeft, scrollTop) {
|
|
11213
11214
|
const $xeTable = this;
|
|
11215
|
+
const reactData = $xeTable;
|
|
11214
11216
|
const internalData = $xeTable;
|
|
11215
11217
|
const {
|
|
11216
|
-
|
|
11217
|
-
} =
|
|
11218
|
-
const
|
|
11219
|
-
|
|
11220
|
-
|
|
11221
|
-
|
|
11222
|
-
|
|
11223
|
-
|
|
11224
|
-
|
|
11225
|
-
const tableBodyElem = refTableBody ? refTableBody.$el : null;
|
|
11226
|
-
const leftBodyElem = leftBody ? leftBody.$el : null;
|
|
11227
|
-
const rightBodyElem = rightBody ? rightBody.$el : null;
|
|
11228
|
-
const tableHeaderElem = refTableHeader ? refTableHeader.$el : null;
|
|
11229
|
-
const tableFooterElem = refTableFooter ? refTableFooter.$el : null;
|
|
11218
|
+
elemStore
|
|
11219
|
+
} = internalData;
|
|
11220
|
+
const headerScrollElem = (0, _util.getRefElem)(elemStore['main-header-scroll']);
|
|
11221
|
+
const bodyScrollElem = (0, _util.getRefElem)(elemStore['main-body-scroll']);
|
|
11222
|
+
const footerScrollElem = (0, _util.getRefElem)(elemStore['main-footer-scroll']);
|
|
11223
|
+
const leftScrollElem = (0, _util.getRefElem)(elemStore['left-body-scroll']);
|
|
11224
|
+
const rightScrollElem = (0, _util.getRefElem)(elemStore['right-body-scroll']);
|
|
11225
|
+
const xHandleEl = $xeTable.$refs.refScrollXHandleElem;
|
|
11226
|
+
const yHandleEl = $xeTable.$refs.refScrollYHandleElem;
|
|
11230
11227
|
internalData.intoRunScroll = true;
|
|
11231
11228
|
if (_xeUtils.default.isNumber(scrollLeft)) {
|
|
11232
|
-
|
|
11233
|
-
|
|
11234
|
-
|
|
11235
|
-
|
|
11236
|
-
|
|
11237
|
-
(0, _dom.setScrollLeft)(tableHeaderElem, scrollLeft);
|
|
11238
|
-
(0, _dom.setScrollLeft)(tableFooterElem, scrollLeft);
|
|
11239
|
-
}
|
|
11229
|
+
(0, _dom.setScrollLeft)(xHandleEl, scrollLeft);
|
|
11230
|
+
(0, _dom.setScrollLeft)(bodyScrollElem, scrollLeft);
|
|
11231
|
+
(0, _dom.setScrollLeft)(headerScrollElem, scrollLeft);
|
|
11232
|
+
(0, _dom.setScrollLeft)(footerScrollElem, scrollLeft);
|
|
11233
|
+
loadScrollXData($xeTable);
|
|
11240
11234
|
}
|
|
11241
11235
|
if (_xeUtils.default.isNumber(scrollTop)) {
|
|
11242
|
-
|
|
11243
|
-
|
|
11244
|
-
|
|
11245
|
-
|
|
11246
|
-
|
|
11247
|
-
(0, _dom.setScrollTop)(leftBodyElem, scrollTop);
|
|
11248
|
-
(0, _dom.setScrollTop)(rightBodyElem, scrollTop);
|
|
11249
|
-
}
|
|
11236
|
+
(0, _dom.setScrollTop)(yHandleEl, scrollTop);
|
|
11237
|
+
(0, _dom.setScrollTop)(bodyScrollElem, scrollTop);
|
|
11238
|
+
(0, _dom.setScrollTop)(leftScrollElem, scrollTop);
|
|
11239
|
+
(0, _dom.setScrollTop)(rightScrollElem, scrollTop);
|
|
11240
|
+
loadScrollYData($xeTable);
|
|
11250
11241
|
}
|
|
11251
|
-
if (
|
|
11242
|
+
if (reactData.scrollXLoad || reactData.scrollYLoad) {
|
|
11252
11243
|
return new Promise(resolve => {
|
|
11253
11244
|
setTimeout(() => {
|
|
11254
11245
|
$xeTable.$nextTick(() => {
|
|
11255
11246
|
internalData.intoRunScroll = false;
|
|
11256
11247
|
resolve();
|
|
11257
11248
|
});
|
|
11258
|
-
});
|
|
11249
|
+
}, 30);
|
|
11259
11250
|
});
|
|
11260
11251
|
}
|
|
11261
|
-
return
|
|
11252
|
+
return $xeTable.$nextTick();
|
|
11262
11253
|
},
|
|
11263
11254
|
/**
|
|
11264
11255
|
* 如果有滚动条,则滚动到对应的行
|
|
@@ -11267,6 +11258,7 @@ const Methods = {
|
|
|
11267
11258
|
*/
|
|
11268
11259
|
scrollToRow(row, fieldOrColumn) {
|
|
11269
11260
|
const $xeTable = this;
|
|
11261
|
+
const props = $xeTable;
|
|
11270
11262
|
const reactData = $xeTable;
|
|
11271
11263
|
const {
|
|
11272
11264
|
isAllOverflow,
|
|
@@ -11275,10 +11267,10 @@ const Methods = {
|
|
|
11275
11267
|
} = reactData;
|
|
11276
11268
|
const rest = [];
|
|
11277
11269
|
if (row) {
|
|
11278
|
-
if (
|
|
11279
|
-
rest.push(
|
|
11270
|
+
if (props.treeConfig) {
|
|
11271
|
+
rest.push($xeTable.scrollToTreeRow(row));
|
|
11280
11272
|
} else {
|
|
11281
|
-
rest.push((0, _util.rowToVisible)(
|
|
11273
|
+
rest.push((0, _util.rowToVisible)($xeTable, row));
|
|
11282
11274
|
}
|
|
11283
11275
|
}
|
|
11284
11276
|
if (fieldOrColumn) {
|