vxe-table 4.16.18 → 4.16.20
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/style.css +1 -1
- package/es/table/module/filter/hook.js +21 -5
- package/es/table/module/filter/panel.js +4 -4
- package/es/table/module/menu/panel.js +27 -14
- package/es/table/src/cell.js +19 -10
- package/es/table/src/table.js +22 -22
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/helper/vetur/attributes.json +1 -1
- package/helper/vetur/tags.json +1 -1
- package/lib/index.umd.js +88 -28
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/table/module/filter/hook.js +21 -5
- package/lib/table/module/filter/hook.min.js +1 -1
- package/lib/table/module/filter/panel.js +3 -3
- package/lib/table/module/filter/panel.min.js +1 -1
- package/lib/table/module/menu/panel.js +15 -10
- package/lib/table/module/menu/panel.min.js +1 -1
- package/lib/table/src/cell.js +24 -7
- package/lib/table/src/cell.min.js +1 -1
- package/lib/table/src/table.js +24 -2
- package/lib/table/src/table.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/table/module/filter/hook.ts +23 -6
- package/packages/table/module/filter/panel.ts +4 -4
- package/packages/table/module/menu/panel.ts +29 -16
- package/packages/table/src/cell.ts +19 -10
- package/packages/table/src/table.ts +22 -22
- /package/es/{iconfont.1758510533325.ttf → iconfont.1758850674944.ttf} +0 -0
- /package/es/{iconfont.1758510533325.woff → iconfont.1758850674944.woff} +0 -0
- /package/es/{iconfont.1758510533325.woff2 → iconfont.1758850674944.woff2} +0 -0
- /package/lib/{iconfont.1758510533325.ttf → iconfont.1758850674944.ttf} +0 -0
- /package/lib/{iconfont.1758510533325.woff → iconfont.1758850674944.woff} +0 -0
- /package/lib/{iconfont.1758510533325.woff2 → iconfont.1758850674944.woff2} +0 -0
package/lib/index.umd.js
CHANGED
|
@@ -3138,7 +3138,7 @@ function eqEmptyValue(cellValue) {
|
|
|
3138
3138
|
;// ./packages/ui/index.ts
|
|
3139
3139
|
|
|
3140
3140
|
|
|
3141
|
-
const version = "4.16.
|
|
3141
|
+
const version = "4.16.19";
|
|
3142
3142
|
core_.VxeUI.version = version;
|
|
3143
3143
|
core_.VxeUI.tableVersion = version;
|
|
3144
3144
|
core_.VxeUI.setConfig({
|
|
@@ -3647,7 +3647,7 @@ var esnext_iterator_some = __webpack_require__(7550);
|
|
|
3647
3647
|
const {
|
|
3648
3648
|
log: log_log
|
|
3649
3649
|
} = core_.VxeUI;
|
|
3650
|
-
const log_version = `table v${"4.16.
|
|
3650
|
+
const log_version = `table v${"4.16.19"}`;
|
|
3651
3651
|
const warnLog = log_log.create('warn', log_version);
|
|
3652
3652
|
const errLog = log_log.create('error', log_version);
|
|
3653
3653
|
;// ./packages/table/src/columnInfo.ts
|
|
@@ -5343,7 +5343,7 @@ function renderCellHandle(params) {
|
|
|
5343
5343
|
case 'html':
|
|
5344
5344
|
return isDeepCell ? Cell.renderDeepHTMLCell(params) : Cell.renderHTMLCell(params);
|
|
5345
5345
|
}
|
|
5346
|
-
if (isEnableConf(
|
|
5346
|
+
if (editConfig && isEnableConf(editOpts) && editRender) {
|
|
5347
5347
|
return editOpts.mode === 'cell' ? isDeepCell ? Cell.renderDeepCellEdit(params) : Cell.renderCellEdit(params) : isDeepCell ? Cell.renderDeepRowEdit(params) : Cell.renderRowEdit(params);
|
|
5348
5348
|
}
|
|
5349
5349
|
return isDeepCell ? Cell.renderDeepCell(params) : Cell.renderDefaultCell(params);
|
|
@@ -5354,9 +5354,13 @@ function renderHeaderHandle(params) {
|
|
|
5354
5354
|
$table
|
|
5355
5355
|
} = params;
|
|
5356
5356
|
const tableProps = $table.props;
|
|
5357
|
+
const {
|
|
5358
|
+
computeEditOpts
|
|
5359
|
+
} = $table.getComputeMaps();
|
|
5357
5360
|
const {
|
|
5358
5361
|
editConfig
|
|
5359
5362
|
} = tableProps;
|
|
5363
|
+
const editOpts = computeEditOpts.value;
|
|
5360
5364
|
const {
|
|
5361
5365
|
type,
|
|
5362
5366
|
filters,
|
|
@@ -5380,7 +5384,7 @@ function renderHeaderHandle(params) {
|
|
|
5380
5384
|
}
|
|
5381
5385
|
break;
|
|
5382
5386
|
}
|
|
5383
|
-
if (editConfig && editRender) {
|
|
5387
|
+
if (editConfig && isEnableConf(editOpts) && editRender) {
|
|
5384
5388
|
return Cell.renderEditHeader(params);
|
|
5385
5389
|
} else if (filters && sortable) {
|
|
5386
5390
|
return Cell.renderSortAndFilterHeader(params);
|
|
@@ -5447,11 +5451,19 @@ const Cell = {
|
|
|
5447
5451
|
row,
|
|
5448
5452
|
column
|
|
5449
5453
|
} = params;
|
|
5454
|
+
const tableProps = $table.props;
|
|
5450
5455
|
const tableReactData = $table.reactData;
|
|
5451
5456
|
const tableInternalData = $table.internalData;
|
|
5452
5457
|
const {
|
|
5453
5458
|
isRowGroupStatus
|
|
5454
5459
|
} = tableReactData;
|
|
5460
|
+
const {
|
|
5461
|
+
computeEditOpts
|
|
5462
|
+
} = $table.getComputeMaps();
|
|
5463
|
+
const {
|
|
5464
|
+
editConfig
|
|
5465
|
+
} = tableProps;
|
|
5466
|
+
const editOpts = computeEditOpts.value;
|
|
5455
5467
|
const {
|
|
5456
5468
|
field,
|
|
5457
5469
|
slots,
|
|
@@ -5460,7 +5472,7 @@ const Cell = {
|
|
|
5460
5472
|
rowGroupNode,
|
|
5461
5473
|
aggFunc
|
|
5462
5474
|
} = column;
|
|
5463
|
-
const renderOpts = editRender
|
|
5475
|
+
const renderOpts = editConfig && isEnableConf(editOpts) && editRender ? editRender : cellRender;
|
|
5464
5476
|
const defaultSlot = slots ? slots.default : null;
|
|
5465
5477
|
const gcSlot = slots ? slots.groupContent || slots['group-content'] : null;
|
|
5466
5478
|
let cellValue = '';
|
|
@@ -6402,12 +6414,17 @@ const Cell = {
|
|
|
6402
6414
|
}
|
|
6403
6415
|
let editIconVNs = [];
|
|
6404
6416
|
if (isEnableConf(editConfig)) {
|
|
6405
|
-
|
|
6417
|
+
const {
|
|
6418
|
+
showAsterisk,
|
|
6419
|
+
showIcon,
|
|
6420
|
+
icon
|
|
6421
|
+
} = editOpts;
|
|
6422
|
+
editIconVNs = [isRequired && showAsterisk ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6406
6423
|
class: 'vxe-cell--required-icon'
|
|
6407
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i')]) : renderEmptyElement($table), isEnableConf(editRender) &&
|
|
6424
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i')]) : renderEmptyElement($table), isEnableConf(editRender) && showIcon ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6408
6425
|
class: 'vxe-cell--edit-icon'
|
|
6409
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
6410
|
-
class:
|
|
6426
|
+
}, external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(icon) ? getSlotVNs(icon({})) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
6427
|
+
class: icon || cell_getIcon().TABLE_EDIT
|
|
6411
6428
|
})]) : renderEmptyElement($table)];
|
|
6412
6429
|
}
|
|
6413
6430
|
return renderHeaderCellBaseVNs(params, editIconVNs.concat(Cell.renderHeaderTitle(params)).concat(sortable ? Cell.renderSortIcon(params) : []).concat(filters ? Cell.renderFilterIcon(params) : []));
|
|
@@ -10442,14 +10459,14 @@ const {
|
|
|
10442
10459
|
return [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
10443
10460
|
class: 'vxe-table--filter-template',
|
|
10444
10461
|
style: maxHeight ? {
|
|
10445
|
-
maxHeight:
|
|
10462
|
+
maxHeight: toCssUnit(maxHeight)
|
|
10446
10463
|
} : {}
|
|
10447
10464
|
}, $xeTable.callSlot(filterSlot, params))];
|
|
10448
10465
|
} else if (rtFilter) {
|
|
10449
10466
|
return [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
10450
10467
|
class: 'vxe-table--filter-template',
|
|
10451
10468
|
style: maxHeight ? {
|
|
10452
|
-
maxHeight:
|
|
10469
|
+
maxHeight: toCssUnit(maxHeight)
|
|
10453
10470
|
} : {}
|
|
10454
10471
|
}, getSlotVNs(rtFilter(filterRender, params)))];
|
|
10455
10472
|
}
|
|
@@ -10473,7 +10490,7 @@ const {
|
|
|
10473
10490
|
}, filter_panel_getI18n('vxe.table.allFilter'))]))]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('ul', {
|
|
10474
10491
|
class: 'vxe-table--filter-body',
|
|
10475
10492
|
style: maxHeight ? {
|
|
10476
|
-
maxHeight:
|
|
10493
|
+
maxHeight: toCssUnit(maxHeight)
|
|
10477
10494
|
} : {}
|
|
10478
10495
|
}, filterStore.options.map(item => {
|
|
10479
10496
|
const isChecked = item._checked;
|
|
@@ -11272,6 +11289,7 @@ const {
|
|
|
11272
11289
|
|
|
11273
11290
|
|
|
11274
11291
|
|
|
11292
|
+
|
|
11275
11293
|
const {
|
|
11276
11294
|
getIcon: menu_panel_getIcon,
|
|
11277
11295
|
renderEmptyElement: menu_panel_renderEmptyElement
|
|
@@ -11327,7 +11345,9 @@ const {
|
|
|
11327
11345
|
}, options.map((item, index) => {
|
|
11328
11346
|
const hasChildMenus = item.children && item.children.some(child => child.visible !== false);
|
|
11329
11347
|
const prefixOpts = Object.assign({}, item.prefixConfig);
|
|
11348
|
+
const prefixIcon = prefixOpts.icon || item.prefixIcon;
|
|
11330
11349
|
const suffixOpts = Object.assign({}, item.suffixConfig);
|
|
11350
|
+
const suffixIcon = suffixOpts.icon || item.suffixIcon;
|
|
11331
11351
|
const menuContent = getFuncText(item.name);
|
|
11332
11352
|
return item.visible === false ? menu_panel_renderEmptyElement($xeTable) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('li', {
|
|
11333
11353
|
class: [item.className, {
|
|
@@ -11348,22 +11368,24 @@ const {
|
|
|
11348
11368
|
}
|
|
11349
11369
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11350
11370
|
class: ['vxe-context-menu--link-prefix', prefixOpts.className || '']
|
|
11351
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11352
|
-
class:
|
|
11371
|
+
}, [prefixIcon && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(prefixIcon) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {}, getSlotVNs(prefixIcon({}))) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11372
|
+
class: prefixIcon
|
|
11353
11373
|
}), prefixOpts.content ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {}, `${prefixOpts.content}`) : menu_panel_renderEmptyElement($xeTable)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11354
11374
|
class: 'vxe-context-menu--link-content',
|
|
11355
11375
|
title: menuContent
|
|
11356
11376
|
}, menuContent), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11357
11377
|
class: ['vxe-context-menu--link-suffix', suffixOpts.className || '']
|
|
11358
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11359
|
-
class:
|
|
11360
|
-
}), suffixOpts.content ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', `${suffixOpts.content}`) : menu_panel_renderEmptyElement($xeTable)])]), hasChildMenus ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('ul', {
|
|
11378
|
+
}, [suffixIcon && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(suffixIcon) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {}, getSlotVNs(suffixIcon({}))) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11379
|
+
class: suffixIcon || (hasChildMenus ? menu_panel_getIcon().TABLE_MENU_OPTIONS : '')
|
|
11380
|
+
}), suffixOpts.content ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', `${suffixOpts.content}`) : menu_panel_renderEmptyElement($xeTable)])]), hasChildMenus && item.children ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('ul', {
|
|
11361
11381
|
class: ['vxe-table--context-menu-clild-wrapper', {
|
|
11362
11382
|
'is--show': item === ctxMenuStore.selected && ctxMenuStore.showChild
|
|
11363
11383
|
}]
|
|
11364
11384
|
}, item.children.map((child, cIndex) => {
|
|
11365
11385
|
const childPrefixOpts = Object.assign({}, child.prefixConfig);
|
|
11386
|
+
const childPrefixIcon = childPrefixOpts.icon || child.prefixIcon;
|
|
11366
11387
|
const childSuffixOpts = Object.assign({}, child.suffixConfig);
|
|
11388
|
+
const childSuffixIcon = childSuffixOpts.icon || child.suffixIcon;
|
|
11367
11389
|
const childMenuContent = getFuncText(child.name);
|
|
11368
11390
|
return child.visible === false ? null : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('li', {
|
|
11369
11391
|
class: [child.className, {
|
|
@@ -11384,15 +11406,15 @@ const {
|
|
|
11384
11406
|
}
|
|
11385
11407
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11386
11408
|
class: ['vxe-context-menu--link-prefix', childPrefixOpts.className || '']
|
|
11387
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11388
|
-
class:
|
|
11409
|
+
}, [childPrefixIcon && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(childPrefixIcon) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {}, getSlotVNs(childPrefixIcon({}))) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11410
|
+
class: childPrefixIcon
|
|
11389
11411
|
}), childPrefixOpts.content ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', `${childPrefixOpts.content}`) : menu_panel_renderEmptyElement($xeTable)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11390
11412
|
class: 'vxe-context-menu--link-content',
|
|
11391
11413
|
title: childMenuContent
|
|
11392
11414
|
}, childMenuContent), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
11393
11415
|
class: ['vxe-context-menu--link-suffix', childSuffixOpts.className || '']
|
|
11394
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11395
|
-
class:
|
|
11416
|
+
}, [childSuffixIcon && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(childSuffixIcon) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {}, getSlotVNs(childSuffixIcon({}))) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
11417
|
+
class: childSuffixIcon
|
|
11396
11418
|
}), childSuffixOpts.content ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', `${childSuffixOpts.content}`) : menu_panel_renderEmptyElement($xeTable)])])]);
|
|
11397
11419
|
})) : null]);
|
|
11398
11420
|
}));
|
|
@@ -11425,6 +11447,9 @@ const {
|
|
|
11425
11447
|
const tableFilterMethodKeys = ['openFilter', 'setFilter', 'clearFilter', 'saveFilterPanel', 'saveFilterPanelByEvent', 'resetFilterPanel', 'resetFilterPanelByEvent', 'getCheckedFilters', 'updateFilterOptionStatus'];
|
|
11426
11448
|
hook_hooks.add('tableFilterModule', {
|
|
11427
11449
|
setupTable($xeTable) {
|
|
11450
|
+
const $xeGrid = $xeTable.xeGrid;
|
|
11451
|
+
const $xeGantt = $xeTable.xeGantt;
|
|
11452
|
+
const $xeGGWrapper = $xeGrid || $xeGantt;
|
|
11428
11453
|
const {
|
|
11429
11454
|
props,
|
|
11430
11455
|
reactData,
|
|
@@ -11510,7 +11535,7 @@ hook_hooks.add('tableFilterModule', {
|
|
|
11510
11535
|
if (filterStore.column === column && filterStore.visible) {
|
|
11511
11536
|
filterStore.visible = false;
|
|
11512
11537
|
} else {
|
|
11513
|
-
const
|
|
11538
|
+
const tableEl = refElem.value;
|
|
11514
11539
|
const {
|
|
11515
11540
|
scrollTop,
|
|
11516
11541
|
scrollLeft,
|
|
@@ -11521,8 +11546,10 @@ hook_hooks.add('tableFilterModule', {
|
|
|
11521
11546
|
const {
|
|
11522
11547
|
transfer
|
|
11523
11548
|
} = filterOpts;
|
|
11524
|
-
const tableRect =
|
|
11549
|
+
const tableRect = tableEl.getBoundingClientRect();
|
|
11525
11550
|
const btnElem = evnt.currentTarget;
|
|
11551
|
+
const filterRender = column ? column.filterRender : null;
|
|
11552
|
+
const compConf = filterRender && isEnableConf(filterRender) ? hook_renderer.get(filterRender.name) : null;
|
|
11526
11553
|
$xeTable.handleFilterOptions(column);
|
|
11527
11554
|
internalData._currFilterParams = params;
|
|
11528
11555
|
filterStore.style = null;
|
|
@@ -11558,17 +11585,28 @@ hook_hooks.add('tableFilterModule', {
|
|
|
11558
11585
|
} else {
|
|
11559
11586
|
left = btnRect.left - tableRect.left - centerWidth;
|
|
11560
11587
|
top = btnRect.top - tableRect.top + btnElem.clientHeight;
|
|
11561
|
-
maxHeight = Math.max(40,
|
|
11588
|
+
maxHeight = Math.max(40, tableEl.clientHeight - top - (filterHeadElem ? filterHeadElem.clientHeight : 0) - (filterFootElem ? filterFootElem.clientHeight : 0) - 14);
|
|
11562
11589
|
if (left < 1) {
|
|
11563
11590
|
left = 1;
|
|
11564
|
-
} else if (left >
|
|
11565
|
-
left =
|
|
11591
|
+
} else if (left > tableEl.clientWidth - filterWidth - 1) {
|
|
11592
|
+
left = tableEl.clientWidth - filterWidth - 1;
|
|
11593
|
+
}
|
|
11594
|
+
if ($xeGGWrapper) {
|
|
11595
|
+
const wrapperEl = $xeGGWrapper.getRefMaps().refElem.value;
|
|
11596
|
+
if (wrapperEl) {
|
|
11597
|
+
const wrapperRect = wrapperEl.getBoundingClientRect();
|
|
11598
|
+
top += tableRect.top - wrapperRect.top;
|
|
11599
|
+
}
|
|
11566
11600
|
}
|
|
11567
11601
|
}
|
|
11568
11602
|
filterStore.style = {
|
|
11569
11603
|
top: toCssUnit(top),
|
|
11570
11604
|
left: toCssUnit(left)
|
|
11571
11605
|
};
|
|
11606
|
+
// 筛选面板是自适应表格高度
|
|
11607
|
+
if (compConf ? !compConf.tableFilterAutoHeight : false) {
|
|
11608
|
+
maxHeight = 0;
|
|
11609
|
+
}
|
|
11572
11610
|
// 判断面板不能大于表格高度
|
|
11573
11611
|
filterStore.maxHeight = maxHeight;
|
|
11574
11612
|
});
|
|
@@ -19401,7 +19439,17 @@ if(bodyScrollElem&&bodyTableElem&&bodyScrollElem.scrollTop+clientHeight>=maxYHei
|
|
|
19401
19439
|
* 已废弃,被 getCellElement 替换
|
|
19402
19440
|
* @deprecated
|
|
19403
19441
|
*/getCell(row,column){return tableMethods.getCellElement(row,column);},findRowIndexOf(list,row){return row?external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().findIndexOf(list,item=>$xeTable.eqRow(item,row)):-1;},eqRow(row1,row2){if(row1&&row2){if(row1===row2){return true;}return getRowid($xeTable,row1)===getRowid($xeTable,row2);}return false;},handleConnectGanttView($ganttView){if($ganttView&&$ganttView.connectUpdate){$ganttView.connectUpdate({$table:$xeTable});internalData.xeGanttView=$ganttView;}return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();}};// 检测对应模块是否安装
|
|
19404
|
-
'openExport,openPrint,exportData,openImport,importData,saveFile,readFile,importByFile,print'.split(',').forEach(name=>{
|
|
19442
|
+
// 'openExport,openPrint,exportData,openImport,importData,saveFile,readFile,importByFile,print'.split(',').forEach(name => {
|
|
19443
|
+
// ($xeTable as any)[name] = function () {
|
|
19444
|
+
// errLog('vxe.error.reqModule', ['Export'])
|
|
19445
|
+
// }
|
|
19446
|
+
// })
|
|
19447
|
+
// 'clearValidate,fullValidate,validate'.split(',').forEach(name => {
|
|
19448
|
+
// ($xeTable as any)[name] = function () {
|
|
19449
|
+
// errLog('vxe.error.reqModule', ['Validator'])
|
|
19450
|
+
// }
|
|
19451
|
+
// })
|
|
19452
|
+
Object.assign($xeTable,tableMethods,tablePrivateMethods);/**
|
|
19405
19453
|
* 渲染浮固定列
|
|
19406
19454
|
* 分别渲染左边固定列和右边固定列
|
|
19407
19455
|
* 如果宽度足够情况下,则不需要渲染固定列
|
|
@@ -19472,7 +19520,19 @@ if(importConfig&&importOpts.types&&!importOpts.importMethod&&!external_root_XEUt
|
|
|
19472
19520
|
// }
|
|
19473
19521
|
// }
|
|
19474
19522
|
// 检查是否有安装需要的模块
|
|
19475
|
-
if(props.editConfig
|
|
19523
|
+
// if (props.editConfig && !$xeTable.insert) {
|
|
19524
|
+
// errLog('vxe.error.reqModule', ['Edit'])
|
|
19525
|
+
// }
|
|
19526
|
+
// if (props.editRules && !$xeTable.validate) {
|
|
19527
|
+
// errLog('vxe.error.reqModule', ['Validator'])
|
|
19528
|
+
// }
|
|
19529
|
+
// if ((checkboxOpts.range || props.keyboardConfig || props.mouseConfig) && !$xeTable.handleCellMousedownEvent) {
|
|
19530
|
+
// errLog('vxe.error.reqModule', ['Keyboard'])
|
|
19531
|
+
// }
|
|
19532
|
+
// if ((props.printConfig || props.importConfig || props.exportConfig) && !$xeTable.exportData) {
|
|
19533
|
+
// errLog('vxe.error.reqModule', ['Export'])
|
|
19534
|
+
// }
|
|
19535
|
+
Object.assign(scrollYStore,{startIndex:0,endIndex:0,visibleSize:0});Object.assign(scrollXStore,{startIndex:0,endIndex:0,visibleSize:0});loadTableData(data||[],true).then(()=>{if(data&&data.length){internalData.inited=true;internalData.initStatus=true;handleLoadDefaults();}handleInitDefaults();updateStyle();});if(props.autoResize){const el=refElem.value;const parentEl=tablePrivateMethods.getParentElem();resizeObserver=table_globalResize.create(()=>{if(props.autoResize){handleResizeEvent();}});if(el){resizeObserver.observe(el);}if(parentEl){resizeObserver.observe(parentEl);}}});if(virtualYOpts.mode!=='scroll'){const tableViewportEl=refTableViewportElem.value;if(tableViewportEl){tableViewportEl.addEventListener('wheel',$xeTable.triggerBodyWheelEvent,{passive:false});}}table_globalEvents.on($xeTable,'paste',handleGlobalPasteEvent);table_globalEvents.on($xeTable,'copy',handleGlobalCopyEvent);table_globalEvents.on($xeTable,'cut',handleGlobalCutEvent);table_globalEvents.on($xeTable,'mousedown',handleGlobalMousedownEvent);table_globalEvents.on($xeTable,'blur',handleGlobalBlurEvent);table_globalEvents.on($xeTable,'mousewheel',handleGlobalMousewheelEvent);table_globalEvents.on($xeTable,'keydown',handleGlobalKeydownEvent);table_globalEvents.on($xeTable,'resize',handleGlobalResizeEvent);table_globalEvents.on($xeTable,'contextmenu',$xeTable.handleGlobalContextmenuEvent);$xeTable.preventEvent(null,'mounted',{$table:$xeTable});});(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onBeforeUnmount)(()=>{const tableViewportEl=refTableViewportElem.value;if(tableViewportEl){tableViewportEl.removeEventListener('wheel',$xeTable.triggerBodyWheelEvent);}internalData.cvCacheMaps={};internalData.prevDragRow=null;internalData.prevDragCol=null;if(resizeObserver){resizeObserver.disconnect();}tableMethods.closeFilter();if($xeTable.closeMenu){$xeTable.closeMenu();}table_globalEvents.off($xeTable,'paste');table_globalEvents.off($xeTable,'copy');table_globalEvents.off($xeTable,'cut');table_globalEvents.off($xeTable,'mousedown');table_globalEvents.off($xeTable,'blur');table_globalEvents.off($xeTable,'mousewheel');table_globalEvents.off($xeTable,'keydown');table_globalEvents.off($xeTable,'resize');table_globalEvents.off($xeTable,'contextmenu');tablePrivateMethods.preventEvent(null,'beforeUnmount',{$table:$xeTable});});(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(()=>{tablePrivateMethods.preventEvent(null,'unmounted',{$table:$xeTable});external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(internalData,createInternalData());});(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(()=>{if(props.loading){if(!VxeUILoadingComponent&&!slots.loading){errLog('vxe.error.errProp',['loading=true','loading=false | <template #loading>...</template>']);errLog('vxe.error.reqComp',['vxe-loading']);}}if(props.showOverflow===true||props.showOverflow==='tooltip'||props.showHeaderOverflow===true||props.showHeaderOverflow==='tooltip'||props.showFooterOverflow===true||props.showFooterOverflow==='tooltip'||props.tooltipConfig||props.editRules){if(!VxeUITooltipComponent){if(props.showOverflow===true){errLog('vxe.error.errProp',['show-overflow=true','show-overflow=title']);}if(props.showOverflow==='tooltip'){errLog('vxe.error.errProp',['show-overflow=tooltip','show-overflow=title']);}if(props.showHeaderOverflow===true){errLog('vxe.error.errProp',['show-header-overflow=true','show-header-overflow=title']);}if(props.showHeaderOverflow==='tooltip'){errLog('vxe.error.errProp',['show-header-overflow=tooltip','show-header-overflow=title']);}if(props.showFooterOverflow===true){errLog('vxe.error.errProp',['show-footer-overflow=true','show-footer-overflow=title']);}if(props.showFooterOverflow==='tooltip'){errLog('vxe.error.errProp',['show-footer-overflow=tooltip','show-footer-overflow=title']);}errLog('vxe.error.reqComp',['vxe-tooltip']);}}});(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeColgroup',null);(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeTable',$xeTable);$xeTable.renderVN=renderVN;return $xeTable;},render(){return this.renderVN();}}));
|
|
19476
19536
|
;// ./packages/toolbar/src/toolbar.ts
|
|
19477
19537
|
|
|
19478
19538
|
|