vxe-table 4.10.6-beta.25 → 4.10.6-beta.26
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/src/body.js +10 -11
- package/es/table/src/table.js +44 -45
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +56 -66
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/table/src/body.js +7 -10
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/table.js +47 -54
- 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/src/body.ts +10 -11
- package/packages/table/src/table.ts +47 -46
- /package/es/{iconfont.1737356819937.ttf → iconfont.1737366161311.ttf} +0 -0
- /package/es/{iconfont.1737356819937.woff → iconfont.1737366161311.woff} +0 -0
- /package/es/{iconfont.1737356819937.woff2 → iconfont.1737366161311.woff2} +0 -0
- /package/lib/{iconfont.1737356819937.ttf → iconfont.1737366161311.ttf} +0 -0
- /package/lib/{iconfont.1737356819937.woff → iconfont.1737366161311.woff} +0 -0
- /package/lib/{iconfont.1737356819937.woff2 → iconfont.1737366161311.woff2} +0 -0
package/lib/ui/index.js
CHANGED
|
@@ -13,7 +13,7 @@ Object.defineProperty(exports, "VxeUI", {
|
|
|
13
13
|
exports.version = exports.validators = exports.use = exports.t = exports.setup = exports.setTheme = exports.setLanguage = exports.setIcon = exports.setI18n = exports.setConfig = exports.saveFile = exports.renderer = exports.readFile = exports.print = exports.modal = exports.menus = exports.log = exports.interceptor = exports.hooks = exports.globalResize = exports.globalEvents = exports.getTheme = exports.getIcon = exports.getI18n = exports.getConfig = exports.formats = exports.default = exports.config = exports.commands = exports.clipboard = exports._t = void 0;
|
|
14
14
|
var _core = require("@vxe-ui/core");
|
|
15
15
|
var _utils = require("./src/utils");
|
|
16
|
-
const version = exports.version = "4.10.6-beta.
|
|
16
|
+
const version = exports.version = "4.10.6-beta.26";
|
|
17
17
|
_core.VxeUI.version = version;
|
|
18
18
|
_core.VxeUI.tableVersion = version;
|
|
19
19
|
_core.VxeUI.setConfig({
|
package/lib/ui/index.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:!0}),exports.VXETable=void 0,Object.defineProperty(exports,"VxeUI",{enumerable:!0,get:function(){return _core.VxeUI}}),exports.version=exports.validators=exports.use=exports.t=exports.setup=exports.setTheme=exports.setLanguage=exports.setIcon=exports.setI18n=exports.setConfig=exports.saveFile=exports.renderer=exports.readFile=exports.print=exports.modal=exports.menus=exports.log=exports.interceptor=exports.hooks=exports.globalResize=exports.globalEvents=exports.getTheme=exports.getIcon=exports.getI18n=exports.getConfig=exports.formats=exports.default=exports.config=exports.commands=exports.clipboard=exports._t=void 0;var _core=require("@vxe-ui/core"),_utils=require("./src/utils");let version=exports.version="4.10.6-beta.
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.VXETable=void 0,Object.defineProperty(exports,"VxeUI",{enumerable:!0,get:function(){return _core.VxeUI}}),exports.version=exports.validators=exports.use=exports.t=exports.setup=exports.setTheme=exports.setLanguage=exports.setIcon=exports.setI18n=exports.setConfig=exports.saveFile=exports.renderer=exports.readFile=exports.print=exports.modal=exports.menus=exports.log=exports.interceptor=exports.hooks=exports.globalResize=exports.globalEvents=exports.getTheme=exports.getIcon=exports.getI18n=exports.getConfig=exports.formats=exports.default=exports.config=exports.commands=exports.clipboard=exports._t=void 0;var _core=require("@vxe-ui/core"),_utils=require("./src/utils");let version=exports.version="4.10.6-beta.26",iconPrefix=(_core.VxeUI.version=version,_core.VxeUI.tableVersion=version,_core.VxeUI.setConfig({emptyCell:" ",table:{fit:!0,showHeader:!0,animat:!0,delayHover:250,autoResize:!0,minHeight:144,resizeConfig:{},resizableConfig:{dragMode:"auto",showDragTip:!0,isSyncAutoHeight:!0,isSyncAutoWidth:!0,minHeight:18},radioConfig:{strict:!0},rowDragConfig:{showIcon:!0,animation:!0,showGuidesStatus:!0},columnDragConfig:{showIcon:!0,animation:!0,showGuidesStatus:!0},checkboxConfig:{strict:!0},tooltipConfig:{enterable:!0},validConfig:{showMessage:!0,autoClear:!0,autoPos:!0,message:"inline",msgMode:"single",theme:"beautify"},columnConfig:{maxFixedSize:4},cellConfig:{padding:!0},headerCellConfig:{},footerCellConfig:{},customConfig:{allowVisible:!0,allowResizable:!0,allowFixed:!0,allowSort:!0,showFooter:!0,placement:"top-right",modalOptions:{showMaximize:!0,mask:!0,lockView:!0,resize:!0,escClosable:!0},drawerOptions:{mask:!0,lockView:!0,escClosable:!0,resize:!0}},sortConfig:{showIcon:!0,iconLayout:"vertical"},filterConfig:{showIcon:!0},treeConfig:{rowField:"id",parentField:"parentId",childrenField:"children",hasChildField:"hasChild",mapChildrenField:"_X_ROW_CHILD",indent:20,showIcon:!0},expandConfig:{showIcon:!0},editConfig:{showIcon:!0,showAsterisk:!0,autoFocus:!0},importConfig:{_typeMaps:{csv:1,html:1,xml:1,txt:1}},exportConfig:{_typeMaps:{csv:1,html:1,xml:1,txt:1}},printConfig:{},mouseConfig:{extension:!0},keyboardConfig:{isEsc:!0},areaConfig:{autoClear:!0,selectCellByHeader:!0,selectCellByBody:!0,extendDirection:{top:!0,left:!0,bottom:!0,right:!0}},clipConfig:{isCopy:!0,isCut:!0,isPaste:!0},fnrConfig:{isFind:!0,isReplace:!0},virtualXConfig:{enabled:!0,gt:60,preSize:0,oSize:1},virtualYConfig:{enabled:!0,gt:100,preSize:1,oSize:2},scrollbarConfig:{}},grid:{formConfig:{enabled:!0},pagerConfig:{enabled:!0},toolbarConfig:{enabled:!0},proxyConfig:{enabled:!0,autoLoad:!0,showResponseMsg:!0,showActiveMsg:!0,props:{list:null,result:"result",total:"page.total",message:"message"}}},toolbar:{}}),"vxe-table-icon-"),setTheme=(_core.VxeUI.setIcon({TABLE_SORT_ASC:iconPrefix+"caret-up",TABLE_SORT_DESC:iconPrefix+"caret-down",TABLE_FILTER_NONE:iconPrefix+"funnel",TABLE_FILTER_MATCH:iconPrefix+"funnel",TABLE_EDIT:iconPrefix+"edit",TABLE_TITLE_PREFIX:iconPrefix+"question-circle-fill",TABLE_TITLE_SUFFIX:iconPrefix+"question-circle-fill",TABLE_TREE_LOADED:iconPrefix+"spinner roll",TABLE_TREE_OPEN:iconPrefix+"caret-right rotate90",TABLE_TREE_CLOSE:iconPrefix+"caret-right",TABLE_EXPAND_LOADED:iconPrefix+"spinner roll",TABLE_EXPAND_OPEN:iconPrefix+"arrow-right rotate90",TABLE_EXPAND_CLOSE:iconPrefix+"arrow-right",TABLE_CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",TABLE_CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",TABLE_CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",TABLE_RADIO_CHECKED:iconPrefix+"radio-checked-fill",TABLE_RADIO_UNCHECKED:iconPrefix+"radio-unchecked",TABLE_CUSTOM_SORT:iconPrefix+"drag-handle",TABLE_MENU_OPTIONS:iconPrefix+"arrow-right",TABLE_DRAG_ROW:iconPrefix+"drag-handle",TABLE_DRAG_COLUMN:iconPrefix+"drag-handle",TABLE_DRAG_STATUS_ROW:iconPrefix+"sort",TABLE_DRAG_STATUS_SUB_ROW:iconPrefix+"add-sub",TABLE_DRAG_STATUS_COLUMN:iconPrefix+"swap",TABLE_DRAG_DISABLED:iconPrefix+"no-drop",TOOLBAR_TOOLS_REFRESH:iconPrefix+"repeat",TOOLBAR_TOOLS_REFRESH_LOADING:iconPrefix+"repeat roll",TOOLBAR_TOOLS_IMPORT:iconPrefix+"upload",TOOLBAR_TOOLS_EXPORT:iconPrefix+"download",TOOLBAR_TOOLS_PRINT:iconPrefix+"print",TOOLBAR_TOOLS_FULLSCREEN:iconPrefix+"fullscreen",TOOLBAR_TOOLS_MINIMIZE:iconPrefix+"minimize",TOOLBAR_TOOLS_CUSTOM:iconPrefix+"custom-column",TOOLBAR_TOOLS_FIXED_LEFT:iconPrefix+"fixed-left",TOOLBAR_TOOLS_FIXED_LEFT_ACTIVE:iconPrefix+"fixed-left-fill",TOOLBAR_TOOLS_FIXED_RIGHT:iconPrefix+"fixed-right",TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVE:iconPrefix+"fixed-right-fill"}),exports.setTheme=_core.VxeUI.setTheme),getTheme=exports.getTheme=_core.VxeUI.getTheme,setConfig=exports.setConfig=_core.VxeUI.setConfig,getConfig=exports.getConfig=_core.VxeUI.getConfig,setIcon=exports.setIcon=_core.VxeUI.setIcon,getIcon=exports.getIcon=_core.VxeUI.getIcon,setLanguage=exports.setLanguage=_core.VxeUI.setLanguage,setI18n=exports.setI18n=_core.VxeUI.setI18n,getI18n=exports.getI18n=_core.VxeUI.getI18n,globalEvents=exports.globalEvents=_core.VxeUI.globalEvents,globalResize=exports.globalResize=_core.VxeUI.globalResize,renderer=exports.renderer=_core.VxeUI.renderer,validators=exports.validators=_core.VxeUI.validators,menus=exports.menus=_core.VxeUI.menus,formats=exports.formats=_core.VxeUI.formats,commands=exports.commands=_core.VxeUI.commands,interceptor=exports.interceptor=_core.VxeUI.interceptor,clipboard=exports.clipboard=_core.VxeUI.clipboard,log=exports.log=_core.VxeUI.log,hooks=exports.hooks=_core.VxeUI.hooks,use=exports.use=_core.VxeUI.use,setup=e=>_core.VxeUI.setConfig(e),config=(exports.setup=setup,_core.VxeUI.setup=setup,e=>_core.VxeUI.setConfig(e)),t=(exports.config=config,_core.VxeUI.config=config,(e,o)=>_core.VxeUI.getI18n(e,o)),_t=(exports.t=t,_core.VxeUI.t=t,(e,o)=>(0,_utils.getFuncText)(e,o)),VXETable=(exports._t=_t,_core.VxeUI._t=_t,exports.VXETable=_core.VxeUI),saveFile=e=>_core.VxeUI.saveFile(e),readFile=(exports.saveFile=saveFile,e=>_core.VxeUI.readFile(e)),print=(exports.readFile=readFile,e=>_core.VxeUI.print(e)),modal=(exports.print=print,exports.modal={get(e){return _core.VxeUI.modal.get(e)},close(e){return _core.VxeUI.modal.close(e)},open(e){return _core.VxeUI.modal.open(e)},alert(e,o,r){return _core.VxeUI.modal.alert(e,o,r)},confirm(e,o,r){return _core.VxeUI.modal.confirm(e,o,r)},message(e,o){return _core.VxeUI.modal.message(e,o)},notification(e,o,r){return _core.VxeUI.modal.notification(e,o,r)}});var _default=exports.default=_core.VxeUI;
|
package/lib/ui/src/log.js
CHANGED
|
@@ -8,6 +8,6 @@ var _core = require("@vxe-ui/core");
|
|
|
8
8
|
const {
|
|
9
9
|
log
|
|
10
10
|
} = _core.VxeUI;
|
|
11
|
-
const version = `table v${"4.10.6-beta.
|
|
11
|
+
const version = `table v${"4.10.6-beta.26"}`;
|
|
12
12
|
const warnLog = exports.warnLog = log.create('warn', version);
|
|
13
13
|
const errLog = exports.errLog = log.create('error', version);
|
package/lib/ui/src/log.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");let log=_core.VxeUI.log,version="table v4.10.6-beta.
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");let log=_core.VxeUI.log,version="table v4.10.6-beta.26",warnLog=exports.warnLog=log.create("warn",version),errLog=exports.errLog=log.create("error",version);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vxe-table",
|
|
3
|
-
"version": "4.10.6-beta.
|
|
3
|
+
"version": "4.10.6-beta.26",
|
|
4
4
|
"description": "一个基于 vue 的 PC 端表格组件,支持增删改查、虚拟树、拖拽排序,懒加载、快捷菜单、数据校验、树形结构、打印、导入导出、自定义模板、渲染器、JSON 配置式...",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"update": "npm install --legacy-peer-deps",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"style": "lib/style.css",
|
|
29
29
|
"typings": "types/index.d.ts",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"vxe-pc-ui": "^4.3.
|
|
31
|
+
"vxe-pc-ui": "^4.3.76"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@types/resize-observer-browser": "^0.1.11",
|
|
@@ -103,7 +103,7 @@ export default defineComponent({
|
|
|
103
103
|
items: any[]
|
|
104
104
|
) => {
|
|
105
105
|
const { fullAllDataRowIdData } = tableInternalData
|
|
106
|
-
const { columnKey, height,
|
|
106
|
+
const { columnKey, height, cellClassName: allCellClassName, cellStyle, align: allAlign, spanMethod, mouseConfig, editConfig, editRules, tooltipConfig, padding: allPadding } = tableProps
|
|
107
107
|
const { tableData, overflowX, currentColumn, scrollXLoad, scrollYLoad, calcCellHeightFlag, resizeHeightFlag, mergeList, editStore, isAllOverflow, validErrorMaps } = tableReactData
|
|
108
108
|
const { afterFullData, scrollXStore, scrollYStore } = tableInternalData
|
|
109
109
|
const cellOpts = computeCellOpts.value
|
|
@@ -136,12 +136,11 @@ export default defineComponent({
|
|
|
136
136
|
const resizeHeight = resizeHeightFlag ? rowRest.resizeHeight : 0
|
|
137
137
|
let fixedHiddenColumn = fixedType ? column.fixed !== fixedType : column.fixed && overflowX
|
|
138
138
|
const isPadding = allPadding === null ? cellOpts.padding : allPadding
|
|
139
|
-
const cellOverflow = (XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow)) ?
|
|
139
|
+
const cellOverflow = (XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow)) ? isAllOverflow : showOverflow
|
|
140
140
|
const showEllipsis = cellOverflow === 'ellipsis'
|
|
141
141
|
const showTitle = cellOverflow === 'title'
|
|
142
142
|
const showTooltip = cellOverflow === true || cellOverflow === 'tooltip'
|
|
143
|
-
|
|
144
|
-
const hasEllipsis = allColumnOverflow || showTitle || showTooltip || showEllipsis || resizeHeight > 0
|
|
143
|
+
const hasEllipsis = isAllOverflow || showTitle || showTooltip || showEllipsis || resizeHeight > 0
|
|
145
144
|
let isDirty
|
|
146
145
|
const tdOns: any = {}
|
|
147
146
|
const cellAlign = align || (compConf ? compConf.tableCellAlign : '') || allAlign
|
|
@@ -288,14 +287,14 @@ export default defineComponent({
|
|
|
288
287
|
}
|
|
289
288
|
|
|
290
289
|
const tcStyle: Record<string, string> = {}
|
|
291
|
-
if (hasEllipsis) {
|
|
290
|
+
if (scrollYLoad || hasEllipsis) {
|
|
292
291
|
tcStyle.height = `${cellHeight}px`
|
|
293
292
|
} else {
|
|
294
293
|
tcStyle.minHeight = `${cellHeight}px`
|
|
295
294
|
}
|
|
296
295
|
|
|
297
296
|
const tdVNs: any[] = []
|
|
298
|
-
if (fixedHiddenColumn &&
|
|
297
|
+
if (fixedHiddenColumn && isAllOverflow) {
|
|
299
298
|
tdVNs.push(
|
|
300
299
|
h('div', {
|
|
301
300
|
key: 'tc',
|
|
@@ -417,8 +416,8 @@ export default defineComponent({
|
|
|
417
416
|
}
|
|
418
417
|
|
|
419
418
|
const renderRows = (fixedType: VxeColumnPropTypes.Fixed, isOptimizeMode: boolean, tableData: any[], tableColumn: VxeTableDefines.ColumnInfo[]) => {
|
|
420
|
-
const { stripe, rowKey, highlightHoverRow, rowClassName, rowStyle,
|
|
421
|
-
const { hasFixedColumn, treeExpandedMaps, scrollXLoad, scrollYLoad, rowExpandedMaps, expandColumn, selectRadioRow, pendingRowMaps, isDragColMove } = tableReactData
|
|
419
|
+
const { stripe, rowKey, highlightHoverRow, rowClassName, rowStyle, editConfig, treeConfig } = tableProps
|
|
420
|
+
const { hasFixedColumn, treeExpandedMaps, scrollXLoad, scrollYLoad, isAllOverflow, rowExpandedMaps, expandColumn, selectRadioRow, pendingRowMaps, isDragColMove } = tableReactData
|
|
422
421
|
const { fullAllDataRowIdData } = tableInternalData
|
|
423
422
|
const checkboxOpts = computeCheckboxOpts.value
|
|
424
423
|
const radioOpts = computeRadioOpts.value
|
|
@@ -535,7 +534,7 @@ export default defineComponent({
|
|
|
535
534
|
cellStyle.paddingLeft = `${(rowLevel * treeOpts.indent) + 30}px`
|
|
536
535
|
}
|
|
537
536
|
const { showOverflow } = expandColumn
|
|
538
|
-
const hasEllipsis = (XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow)) ?
|
|
537
|
+
const hasEllipsis = (XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow)) ? isAllOverflow : showOverflow
|
|
539
538
|
const expandParams = { $table: $xeTable, seq, column: expandColumn, fixed: fixedType, type: renderType, level: rowLevel, row, rowIndex, $rowIndex, _rowIndex }
|
|
540
539
|
rows.push(
|
|
541
540
|
h('tr', {
|
|
@@ -609,7 +608,7 @@ export default defineComponent({
|
|
|
609
608
|
const { slots } = tableContext
|
|
610
609
|
|
|
611
610
|
const { fixedColumn, fixedType, tableColumn } = props
|
|
612
|
-
const {
|
|
611
|
+
const { spanMethod, footerSpanMethod, mouseConfig } = tableProps
|
|
613
612
|
const { isGroup, tableData, scrollXLoad, scrollYLoad, isAllOverflow, isDragRowMove, expandColumn, dragRow, dragCol } = tableReactData
|
|
614
613
|
const { visibleColumn, fullAllDataRowIdData, fullColumnIdData } = tableInternalData
|
|
615
614
|
const rowOpts = computeRowOpts.value
|
|
@@ -623,7 +622,7 @@ export default defineComponent({
|
|
|
623
622
|
let renderColumnList = tableColumn as VxeTableDefines.ColumnInfo[]
|
|
624
623
|
let isOptimizeMode = false
|
|
625
624
|
// 如果是使用优化模式
|
|
626
|
-
if (scrollXLoad || scrollYLoad ||
|
|
625
|
+
if (scrollXLoad || scrollYLoad || isAllOverflow) {
|
|
627
626
|
if (expandColumn || spanMethod || footerSpanMethod) {
|
|
628
627
|
// 如果不支持优化模式
|
|
629
628
|
} else {
|
|
@@ -937,13 +937,13 @@ export default defineComponent({
|
|
|
937
937
|
}
|
|
938
938
|
|
|
939
939
|
const computeRowHeight = () => {
|
|
940
|
-
const {
|
|
940
|
+
const { isAllOverflow } = reactData
|
|
941
941
|
const tableHeader = refTableHeader.value
|
|
942
942
|
const tableBody = refTableBody.value
|
|
943
943
|
const tableBodyElem = tableBody ? tableBody.$el as HTMLDivElement : null
|
|
944
944
|
const defaultRowHeight = computeDefaultRowHeight.value
|
|
945
945
|
let rowHeight = 0
|
|
946
|
-
if (
|
|
946
|
+
if (isAllOverflow) {
|
|
947
947
|
if (tableBodyElem) {
|
|
948
948
|
const tableHeaderElem = tableHeader ? tableHeader.$el as HTMLDivElement : null
|
|
949
949
|
let firstTrElem
|
|
@@ -966,7 +966,7 @@ export default defineComponent({
|
|
|
966
966
|
}
|
|
967
967
|
|
|
968
968
|
const handleVirtualYVisible = (currScrollTop?: number) => {
|
|
969
|
-
const {
|
|
969
|
+
const { isAllOverflow } = reactData
|
|
970
970
|
const { elemStore, isResizeCellHeight, afterFullData, fullAllDataRowIdData } = internalData
|
|
971
971
|
const rowOpts = computeRowOpts.value
|
|
972
972
|
const cellOpts = computeCellOpts.value
|
|
@@ -980,7 +980,7 @@ export default defineComponent({
|
|
|
980
980
|
let offsetTop = 0
|
|
981
981
|
let visibleSize = 0
|
|
982
982
|
const isCustomCellHeight = isResizeCellHeight || cellOpts.height || rowOpts.height
|
|
983
|
-
if (!isCustomCellHeight &&
|
|
983
|
+
if (!isCustomCellHeight && isAllOverflow) {
|
|
984
984
|
toVisibleIndex = Math.floor(scrollTop / defaultRowHeight)
|
|
985
985
|
visibleSize = Math.ceil(clientHeight / defaultRowHeight) + 1
|
|
986
986
|
} else {
|
|
@@ -1511,12 +1511,11 @@ export default defineComponent({
|
|
|
1511
1511
|
}
|
|
1512
1512
|
|
|
1513
1513
|
const calcCellHeight = () => {
|
|
1514
|
-
const {
|
|
1515
|
-
const { tableData, scrollYLoad, scrollXLoad } = reactData
|
|
1514
|
+
const { tableData, isAllOverflow, scrollYLoad, scrollXLoad } = reactData
|
|
1516
1515
|
const { fullAllDataRowIdData } = internalData
|
|
1517
1516
|
const defaultRowHeight = computeDefaultRowHeight.value
|
|
1518
1517
|
const el = refElem.value
|
|
1519
|
-
if (!
|
|
1518
|
+
if (!isAllOverflow && scrollYLoad && el) {
|
|
1520
1519
|
tableData.forEach(row => {
|
|
1521
1520
|
const rowid = getRowid($xeTable, row)
|
|
1522
1521
|
const rowRest = fullAllDataRowIdData[rowid]
|
|
@@ -1778,7 +1777,7 @@ export default defineComponent({
|
|
|
1778
1777
|
}
|
|
1779
1778
|
|
|
1780
1779
|
const updateStyle = () => {
|
|
1781
|
-
const { border,
|
|
1780
|
+
const { border, showHeaderOverflow: allColumnHeaderOverflow, showFooterOverflow: allColumnFooterOverflow, mouseConfig, spanMethod, footerSpanMethod } = props
|
|
1782
1781
|
const { isGroup, currentRow, tableColumn, scrollXLoad, scrollYLoad, overflowX, scrollbarWidth, overflowY, scrollbarHeight, columnStore, editStore, isAllOverflow, expandColumn } = reactData
|
|
1783
1782
|
const { visibleColumn, fullColumnIdData, tableHeight, tableWidth, headerHeight, footerHeight, elemStore, customHeight, customMinHeight, customMaxHeight } = internalData
|
|
1784
1783
|
const el = refElem.value
|
|
@@ -1980,7 +1979,7 @@ export default defineComponent({
|
|
|
1980
1979
|
|
|
1981
1980
|
let isOptimizeMode = false
|
|
1982
1981
|
// 如果是使用优化模式
|
|
1983
|
-
if (scrollXLoad || scrollYLoad ||
|
|
1982
|
+
if (scrollXLoad || scrollYLoad || isAllOverflow) {
|
|
1984
1983
|
if (expandColumn || spanMethod || footerSpanMethod) {
|
|
1985
1984
|
// 如果不支持优化模式
|
|
1986
1985
|
} else {
|
|
@@ -2069,7 +2068,7 @@ export default defineComponent({
|
|
|
2069
2068
|
} else if (layout === 'footer') {
|
|
2070
2069
|
cellOverflow = XEUtils.isUndefined(showFooterOverflow) || XEUtils.isNull(showFooterOverflow) ? allColumnFooterOverflow : showFooterOverflow
|
|
2071
2070
|
} else {
|
|
2072
|
-
cellOverflow = XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow) ?
|
|
2071
|
+
cellOverflow = XEUtils.isUndefined(showOverflow) || XEUtils.isNull(showOverflow) ? isAllOverflow : showOverflow
|
|
2073
2072
|
}
|
|
2074
2073
|
const showEllipsis = cellOverflow === 'ellipsis'
|
|
2075
2074
|
const showTitle = cellOverflow === 'title'
|
|
@@ -2663,11 +2662,10 @@ export default defineComponent({
|
|
|
2663
2662
|
* @param {Array} datas 数据
|
|
2664
2663
|
*/
|
|
2665
2664
|
const loadTableData = (datas: any[], isReset: boolean) => {
|
|
2666
|
-
const { keepSource, treeConfig
|
|
2665
|
+
const { keepSource, treeConfig } = props
|
|
2667
2666
|
const { editStore, scrollYLoad: oldScrollYLoad } = reactData
|
|
2668
2667
|
const { scrollYStore, scrollXStore, lastScrollLeft, lastScrollTop } = internalData
|
|
2669
2668
|
const treeOpts = computeTreeOpts.value
|
|
2670
|
-
const rowOpts = computeRowOpts.value
|
|
2671
2669
|
const { transform } = treeOpts
|
|
2672
2670
|
const childrenField = treeOpts.children || treeOpts.childrenField
|
|
2673
2671
|
let treeData = []
|
|
@@ -2726,33 +2724,15 @@ export default defineComponent({
|
|
|
2726
2724
|
internalData.tableSynchData = datas
|
|
2727
2725
|
if (isReset) {
|
|
2728
2726
|
internalData.isResizeCellHeight = false
|
|
2727
|
+
reactData.rowExpandedMaps = {}
|
|
2728
|
+
reactData.rowExpandLazyLoadedMaps = {}
|
|
2729
|
+
reactData.treeExpandedMaps = {}
|
|
2730
|
+
reactData.treeExpandLazyLoadedMaps = {}
|
|
2729
2731
|
}
|
|
2730
2732
|
// 克隆原数据,用于显示编辑状态,与编辑值做对比
|
|
2731
2733
|
if (keepSource) {
|
|
2732
2734
|
tablePrivateMethods.cacheSourceMap(fullData)
|
|
2733
2735
|
}
|
|
2734
|
-
if (sYLoad) {
|
|
2735
|
-
if (showOverflow) {
|
|
2736
|
-
if (!rowOpts.height) {
|
|
2737
|
-
const errColumn = internalData.tableFullColumn.find(column => column.showOverflow === false)
|
|
2738
|
-
if (errColumn) {
|
|
2739
|
-
errLog('vxe.error.errProp', [`column[field="${errColumn.field}"].show-overflow=false`, 'show-overflow=true'])
|
|
2740
|
-
}
|
|
2741
|
-
}
|
|
2742
|
-
}
|
|
2743
|
-
|
|
2744
|
-
if (process.env.VUE_APP_VXE_ENV === 'development') {
|
|
2745
|
-
if (!(props.height || props.maxHeight)) {
|
|
2746
|
-
errLog('vxe.error.reqProp', ['table.height | table.max-height | table.scroll-y={enabled: false}'])
|
|
2747
|
-
}
|
|
2748
|
-
// if (!props.showOverflow) {
|
|
2749
|
-
// warnLog('vxe.error.reqProp', ['table.show-overflow'])
|
|
2750
|
-
// }
|
|
2751
|
-
if (props.spanMethod) {
|
|
2752
|
-
warnLog('vxe.error.scrollErrProp', ['table.span-method'])
|
|
2753
|
-
}
|
|
2754
|
-
}
|
|
2755
|
-
}
|
|
2756
2736
|
if ($xeTable.clearCellAreas && props.mouseConfig) {
|
|
2757
2737
|
$xeTable.clearCellAreas()
|
|
2758
2738
|
$xeTable.clearCopyCellArea()
|
|
@@ -2771,6 +2751,30 @@ export default defineComponent({
|
|
|
2771
2751
|
if (sYLoad) {
|
|
2772
2752
|
scrollYStore.endIndex = scrollYStore.visibleSize
|
|
2773
2753
|
}
|
|
2754
|
+
|
|
2755
|
+
if (sYLoad) {
|
|
2756
|
+
// if (showOverflow) {
|
|
2757
|
+
// if (!rowOpts.height) {
|
|
2758
|
+
// const errColumn = internalData.tableFullColumn.find(column => column.showOverflow === false)
|
|
2759
|
+
// if (errColumn) {
|
|
2760
|
+
// errLog('vxe.error.errProp', [`column[field="${errColumn.field}"].show-overflow=false`, 'show-overflow=true'])
|
|
2761
|
+
// }
|
|
2762
|
+
// }
|
|
2763
|
+
// }
|
|
2764
|
+
|
|
2765
|
+
if (process.env.VUE_APP_VXE_ENV === 'development') {
|
|
2766
|
+
if (!(props.height || props.maxHeight)) {
|
|
2767
|
+
errLog('vxe.error.reqProp', ['table.height | table.max-height | table.scroll-y={enabled: false}'])
|
|
2768
|
+
}
|
|
2769
|
+
// if (!props.showOverflow) {
|
|
2770
|
+
// warnLog('vxe.error.reqProp', ['table.show-overflow'])
|
|
2771
|
+
// }
|
|
2772
|
+
if (props.spanMethod) {
|
|
2773
|
+
warnLog('vxe.error.scrollErrProp', ['table.span-method'])
|
|
2774
|
+
}
|
|
2775
|
+
}
|
|
2776
|
+
}
|
|
2777
|
+
|
|
2774
2778
|
handleReserveStatus()
|
|
2775
2779
|
tablePrivateMethods.checkSelectionStatus()
|
|
2776
2780
|
return new Promise<void>(resolve => {
|
|
@@ -3173,11 +3177,10 @@ export default defineComponent({
|
|
|
3173
3177
|
* 纵向 Y 可视渲染处理
|
|
3174
3178
|
*/
|
|
3175
3179
|
const loadScrollYData = (scrollTop?: number) => {
|
|
3176
|
-
const {
|
|
3177
|
-
const { mergeList } = reactData
|
|
3180
|
+
const { mergeList, isAllOverflow } = reactData
|
|
3178
3181
|
const { scrollYStore } = internalData
|
|
3179
3182
|
const { preloadSize, startIndex, endIndex, offsetSize } = scrollYStore
|
|
3180
|
-
const autoOffsetYSize =
|
|
3183
|
+
const autoOffsetYSize = isAllOverflow ? offsetSize : offsetSize + 1
|
|
3181
3184
|
const { toVisibleIndex, visibleSize } = handleVirtualYVisible(scrollTop)
|
|
3182
3185
|
const offsetItem = {
|
|
3183
3186
|
startIndex: Math.max(0, toVisibleIndex - 1 - offsetSize - preloadSize),
|
|
@@ -5403,8 +5406,7 @@ export default defineComponent({
|
|
|
5403
5406
|
* @param {ColumnInfo} fieldOrColumn 列配置
|
|
5404
5407
|
*/
|
|
5405
5408
|
scrollToRow (row, fieldOrColumn) {
|
|
5406
|
-
const {
|
|
5407
|
-
const { scrollYLoad, scrollXLoad } = reactData
|
|
5409
|
+
const { isAllOverflow, scrollYLoad, scrollXLoad } = reactData
|
|
5408
5410
|
const rest = []
|
|
5409
5411
|
if (row) {
|
|
5410
5412
|
if (props.treeConfig) {
|
|
@@ -5418,7 +5420,7 @@ export default defineComponent({
|
|
|
5418
5420
|
}
|
|
5419
5421
|
return Promise.all(rest).then(() => {
|
|
5420
5422
|
if (row) {
|
|
5421
|
-
if (!
|
|
5423
|
+
if (!isAllOverflow && (scrollYLoad || scrollXLoad)) {
|
|
5422
5424
|
calcCellHeight()
|
|
5423
5425
|
calcCellWidth()
|
|
5424
5426
|
}
|
|
@@ -8908,8 +8910,7 @@ export default defineComponent({
|
|
|
8908
8910
|
},
|
|
8909
8911
|
// 更新纵向 Y 可视渲染上下剩余空间大小
|
|
8910
8912
|
updateScrollYSpace () {
|
|
8911
|
-
const {
|
|
8912
|
-
const { scrollYLoad } = reactData
|
|
8913
|
+
const { isAllOverflow, scrollYLoad } = reactData
|
|
8913
8914
|
const { scrollYStore, elemStore, isResizeCellHeight, afterFullData, fullAllDataRowIdData } = internalData
|
|
8914
8915
|
const { startIndex } = scrollYStore
|
|
8915
8916
|
const rowOpts = computeRowOpts.value
|
|
@@ -8922,7 +8923,7 @@ export default defineComponent({
|
|
|
8922
8923
|
|
|
8923
8924
|
if (scrollYLoad) {
|
|
8924
8925
|
const isCustomCellHeight = isResizeCellHeight || cellOpts.height || rowOpts.height
|
|
8925
|
-
if (!isCustomCellHeight &&
|
|
8926
|
+
if (!isCustomCellHeight && isAllOverflow) {
|
|
8926
8927
|
ySpaceHeight = afterFullData.length * defaultRowHeight
|
|
8927
8928
|
topSpaceHeight = Math.max(0, startIndex * defaultRowHeight)
|
|
8928
8929
|
} else {
|
|
@@ -8966,12 +8967,12 @@ export default defineComponent({
|
|
|
8966
8967
|
})
|
|
8967
8968
|
},
|
|
8968
8969
|
updateScrollXData () {
|
|
8969
|
-
const {
|
|
8970
|
+
const { isAllOverflow } = reactData
|
|
8970
8971
|
handleTableColumn()
|
|
8971
8972
|
return nextTick().then(() => {
|
|
8972
8973
|
handleTableColumn()
|
|
8973
8974
|
$xeTable.updateScrollXSpace()
|
|
8974
|
-
if (!
|
|
8975
|
+
if (!isAllOverflow) {
|
|
8975
8976
|
$xeTable.updateScrollYSpace()
|
|
8976
8977
|
}
|
|
8977
8978
|
})
|
|
@@ -9594,7 +9595,7 @@ export default defineComponent({
|
|
|
9594
9595
|
if (value && value.length >= 50000) {
|
|
9595
9596
|
warnLog('vxe.error.errLargeData', ['loadData(data), reloadData(data)'])
|
|
9596
9597
|
}
|
|
9597
|
-
loadTableData(value,
|
|
9598
|
+
loadTableData(value, true).then(() => {
|
|
9598
9599
|
const { scrollXLoad, scrollYLoad, expandColumn } = reactData
|
|
9599
9600
|
internalData.inited = true
|
|
9600
9601
|
internalData.initStatus = true
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|