vxe-table 3.8.20 → 3.8.22
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/lib/button/style/style.css +2 -0
- package/lib/button/style/style.min.css +1 -1
- package/lib/button-group/style/style.css +1 -0
- package/lib/checkbox/style/style.css +1 -0
- package/lib/checkbox-group/style/style.css +1 -0
- package/lib/colgroup/style/style.css +1 -0
- package/lib/column/style/style.css +1 -0
- package/lib/custom/style/style.css +3 -0
- package/lib/custom/style/style.min.css +1 -1
- package/lib/edit/src/mixin.js +2 -2
- package/lib/edit/src/mixin.min.js +1 -1
- package/lib/edit/style/style.css +1 -0
- package/lib/export/src/mixin.js +1 -1
- package/lib/export/src/mixin.min.js +1 -1
- package/lib/export/style/style.css +1 -0
- package/lib/filter/style/style.css +1 -0
- package/lib/form/style/style.css +1 -0
- package/lib/form-gather/style/style.css +1 -0
- package/lib/form-item/style/style.css +1 -0
- package/lib/grid/style/style.css +2 -0
- package/lib/grid/style/style.min.css +1 -1
- package/lib/icon/style/style.css +4 -2
- package/lib/icon/style/style.min.css +4 -2
- package/lib/index.css +1 -1
- package/lib/index.umd.js +173 -148
- package/lib/index.umd.min.js +1 -1
- package/lib/input/style/style.css +4 -3
- package/lib/input/style/style.min.css +1 -1
- package/lib/keyboard/style/style.css +1 -0
- package/lib/list/style/style.css +1 -0
- package/lib/loading/style/style.css +1 -0
- package/lib/locale/lang/en-US.js +1 -0
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +1 -0
- package/lib/locale/lang/es-ES.js +1 -0
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +1 -0
- package/lib/locale/lang/ja-JP.js +1 -0
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +1 -0
- package/lib/locale/lang/pt-BR.js +1 -0
- package/lib/locale/lang/pt-BR.min.js +1 -1
- package/lib/locale/lang/pt-BR.umd.js +1 -0
- package/lib/locale/lang/zh-CN.js +1 -0
- package/lib/locale/lang/zh-CN.min.js +1 -1
- package/lib/locale/lang/zh-CN.umd.js +1 -0
- package/lib/locale/lang/zh-HK.min.js +1 -1
- package/lib/locale/lang/zh-HK.umd.js +1 -0
- package/lib/locale/lang/zh-MO.min.js +1 -1
- package/lib/locale/lang/zh-MO.umd.js +1 -0
- package/lib/locale/lang/zh-TC.js +1 -0
- package/lib/locale/lang/zh-TC.min.js +1 -1
- package/lib/locale/lang/zh-TC.umd.js +1 -0
- package/lib/locale/lang/zh-TW.min.js +1 -1
- package/lib/locale/lang/zh-TW.umd.js +1 -0
- package/lib/menu/style/style.css +1 -0
- package/lib/modal/style/style.css +4 -0
- package/lib/modal/style/style.min.css +1 -1
- package/lib/optgroup/style/style.css +1 -0
- package/lib/option/style/style.css +1 -0
- package/lib/pager/src/pager.js +29 -25
- package/lib/pager/src/pager.min.js +1 -1
- package/lib/pager/style/style.css +2 -19
- package/lib/pager/style/style.min.css +1 -1
- package/lib/pulldown/style/style.css +3 -1
- package/lib/pulldown/style/style.min.css +1 -1
- package/lib/radio/style/style.css +1 -0
- package/lib/radio-button/style/style.css +1 -0
- package/lib/radio-group/style/style.css +1 -0
- package/lib/select/style/style.css +2 -0
- package/lib/select/style/style.min.css +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/switch/style/style.css +1 -0
- package/lib/table/src/header.js +4 -3
- package/lib/table/src/header.min.js +1 -1
- package/lib/table/src/methods.js +56 -37
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/style/style.css +17 -10
- package/lib/table/style/style.min.css +1 -1
- package/lib/textarea/style/style.css +1 -0
- package/lib/toolbar/style/style.css +1 -0
- package/lib/tools/log.js +1 -1
- package/lib/tools/log.min.js +1 -1
- package/lib/tooltip/style/style.css +1 -0
- package/lib/v-x-e-table/index.js +1 -1
- package/lib/v-x-e-table/index.min.js +1 -1
- package/lib/v-x-e-table/src/renderer.js +78 -78
- package/lib/v-x-e-table/src/renderer.min.js +1 -1
- package/lib/v-x-e-table/style/style.css +3 -1
- package/lib/v-x-e-table/style/style.min.css +1 -1
- package/lib/validator/style/style.css +1 -0
- package/lib/vxe-button/style/style.css +2 -0
- package/lib/vxe-button/style/style.min.css +1 -1
- package/lib/vxe-button-group/style/style.css +1 -0
- package/lib/vxe-checkbox/style/style.css +1 -0
- package/lib/vxe-checkbox-group/style/style.css +1 -0
- package/lib/vxe-colgroup/style/style.css +1 -0
- package/lib/vxe-column/style/style.css +1 -0
- package/lib/vxe-form/style/style.css +1 -0
- package/lib/vxe-form-gather/style/style.css +1 -0
- package/lib/vxe-form-item/style/style.css +1 -0
- package/lib/vxe-grid/style/style.css +2 -0
- package/lib/vxe-grid/style/style.min.css +1 -1
- package/lib/vxe-icon/style/style.css +3 -1
- package/lib/vxe-icon/style/style.min.css +1 -1
- package/lib/vxe-input/style/style.css +4 -3
- package/lib/vxe-input/style/style.min.css +1 -1
- package/lib/vxe-list/style/style.css +1 -0
- package/lib/vxe-loading/style/style.css +1 -0
- package/lib/vxe-modal/style/style.css +4 -0
- package/lib/vxe-modal/style/style.min.css +1 -1
- package/lib/vxe-optgroup/style/style.css +1 -0
- package/lib/vxe-option/style/style.css +1 -0
- package/lib/vxe-pager/style/style.css +2 -19
- package/lib/vxe-pager/style/style.min.css +1 -1
- package/lib/vxe-pulldown/style/style.css +3 -1
- package/lib/vxe-pulldown/style/style.min.css +1 -1
- package/lib/vxe-radio/style/style.css +1 -0
- package/lib/vxe-radio-button/style/style.css +1 -0
- package/lib/vxe-radio-group/style/style.css +1 -0
- package/lib/vxe-select/style/style.css +2 -0
- package/lib/vxe-select/style/style.min.css +1 -1
- package/lib/vxe-switch/style/style.css +1 -0
- package/lib/vxe-table/style/style.css +17 -10
- package/lib/vxe-table/style/style.min.css +1 -1
- package/lib/vxe-table-custom-module/style/style.css +3 -0
- package/lib/vxe-table-custom-module/style/style.min.css +1 -1
- package/lib/vxe-table-edit-module/style/style.css +1 -0
- package/lib/vxe-table-export-module/style/style.css +1 -0
- package/lib/vxe-table-filter-module/style/style.css +1 -0
- package/lib/vxe-table-keyboard-module/style/style.css +1 -0
- package/lib/vxe-table-menu-module/style/style.css +1 -0
- package/lib/vxe-table-validator-module/style/style.css +1 -0
- package/lib/vxe-textarea/style/style.css +1 -0
- package/lib/vxe-toolbar/style/style.css +1 -0
- package/lib/vxe-tooltip/style/style.css +1 -0
- package/package.json +1 -1
- package/packages/edit/src/mixin.js +2 -2
- package/packages/export/src/mixin.js +1 -1
- package/packages/locale/lang/en-US.js +1 -0
- package/packages/locale/lang/es-ES.js +1 -0
- package/packages/locale/lang/ja-JP.js +1 -0
- package/packages/locale/lang/pt-BR.js +1 -0
- package/packages/locale/lang/zh-CN.js +1 -0
- package/packages/locale/lang/zh-TC.js +1 -0
- package/packages/pager/src/pager.js +24 -21
- package/packages/table/src/header.js +4 -3
- package/packages/table/src/methods.js +46 -23
- package/packages/v-x-e-table/src/renderer.js +78 -78
- package/styles/button.scss +1 -0
- package/styles/custom.scss +2 -0
- package/styles/grid.scss +1 -0
- package/styles/input.scss +3 -3
- package/styles/modal.scss +3 -0
- package/styles/old-icon.scss +1 -1
- package/styles/pager.scss +1 -19
- package/styles/pulldown.scss +2 -1
- package/styles/select.scss +1 -0
- package/styles/table.scss +14 -8
- package/styles/variable.scss +4 -0
- /package/lib/icon/style/{iconfont.1724204493937.ttf → iconfont.1724292682903.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1724204493937.woff → iconfont.1724292682903.woff} +0 -0
- /package/lib/icon/style/{iconfont.1724204493937.woff2 → iconfont.1724292682903.woff2} +0 -0
- /package/lib/{iconfont.1724204493937.ttf → iconfont.1724292682903.ttf} +0 -0
- /package/lib/{iconfont.1724204493937.woff → iconfont.1724292682903.woff} +0 -0
- /package/lib/{iconfont.1724204493937.woff2 → iconfont.1724292682903.woff2} +0 -0
package/package.json
CHANGED
|
@@ -623,10 +623,10 @@ export default {
|
|
|
623
623
|
let autoSelect = editRender.autoSelect || editRender.autoselect
|
|
624
624
|
let inputElem
|
|
625
625
|
if (!autoFocus && compRender) {
|
|
626
|
-
autoFocus = compRender.tableAutoFocus || compRender.tableAutofocus || compRender.autofocus
|
|
626
|
+
autoFocus = compRender.tableAutoFocus || compRender.tableAutofocus || compRender.autoFocus || compRender.autofocus
|
|
627
627
|
}
|
|
628
628
|
if (!autoSelect && compRender) {
|
|
629
|
-
autoSelect = compRender.tableAutoSelect || compRender.autoselect
|
|
629
|
+
autoSelect = compRender.tableAutoSelect || compRender.autoSelect || compRender.autoselect
|
|
630
630
|
}
|
|
631
631
|
// 如果指定了聚焦 class
|
|
632
632
|
if (XEUtils.isFunction(autoFocus)) {
|
|
@@ -166,7 +166,7 @@ function getLabelData ($xetable, opts, columns, datas) {
|
|
|
166
166
|
if (!exportLabelMethod && renderOpts && renderOpts.name) {
|
|
167
167
|
const compConf = VXETable.renderer.get(renderOpts.name)
|
|
168
168
|
if (compConf) {
|
|
169
|
-
exportLabelMethod = compConf.exportMethod || compConf.cellExportMethod
|
|
169
|
+
exportLabelMethod = compConf.tableExportMethod || compConf.exportMethod || compConf.cellExportMethod
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
172
|
if (exportLabelMethod) {
|
|
@@ -298,17 +298,21 @@ export default {
|
|
|
298
298
|
isFull ? h('span', {
|
|
299
299
|
class: 'vxe-pager--goto-text'
|
|
300
300
|
}, GlobalConfig.i18n('vxe.pager.goto')) : null,
|
|
301
|
-
h('input', {
|
|
301
|
+
h('vxe-input', {
|
|
302
302
|
class: 'vxe-pager--goto',
|
|
303
|
-
|
|
304
|
-
value: this.inpCurrPage
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
type: '
|
|
308
|
-
|
|
303
|
+
props: {
|
|
304
|
+
value: this.inpCurrPage,
|
|
305
|
+
placeholder: GlobalConfig.i18n('vxe.pager.gotoTitle'),
|
|
306
|
+
align: 'center',
|
|
307
|
+
type: 'integer',
|
|
308
|
+
max: this.pageCount,
|
|
309
|
+
min: 1,
|
|
310
|
+
controls: false
|
|
309
311
|
},
|
|
310
312
|
on: {
|
|
311
|
-
|
|
313
|
+
modelValue: (val) => {
|
|
314
|
+
this.inpCurrPage = val
|
|
315
|
+
},
|
|
312
316
|
keydown: this.jumpKeydownEvent,
|
|
313
317
|
blur: this.triggerJumpEvent
|
|
314
318
|
}
|
|
@@ -448,25 +452,24 @@ export default {
|
|
|
448
452
|
this.$emit('update:pageSize', pageSize)
|
|
449
453
|
this.$emit('page-change', { type: 'size', pageSize, currentPage })
|
|
450
454
|
},
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
if (
|
|
456
|
-
|
|
457
|
-
} else if (evnt.keyCode === 38) {
|
|
458
|
-
evnt.preventDefault()
|
|
455
|
+
jumpKeydownEvent (params) {
|
|
456
|
+
const { $event } = params
|
|
457
|
+
if ($event.keyCode === 13) {
|
|
458
|
+
this.triggerJumpEvent(params)
|
|
459
|
+
} else if ($event.keyCode === 38) {
|
|
460
|
+
$event.preventDefault()
|
|
459
461
|
this.nextPage()
|
|
460
|
-
} else if (
|
|
461
|
-
|
|
462
|
+
} else if ($event.keyCode === 40) {
|
|
463
|
+
$event.preventDefault()
|
|
462
464
|
this.prevPage()
|
|
463
465
|
}
|
|
464
466
|
},
|
|
465
|
-
triggerJumpEvent (
|
|
466
|
-
const
|
|
467
|
+
triggerJumpEvent (params) {
|
|
468
|
+
const { $event } = params
|
|
469
|
+
const value = XEUtils.toInteger($event.target.value)
|
|
467
470
|
const current = value <= 0 ? 1 : value >= this.pageCount ? this.pageCount : value
|
|
468
471
|
const currPage = XEUtils.toValueString(current)
|
|
469
|
-
|
|
472
|
+
$event.target.value = currPage
|
|
470
473
|
this.inpCurrPage = currPage
|
|
471
474
|
this.jumpPage(current)
|
|
472
475
|
}
|
|
@@ -117,6 +117,7 @@ export default {
|
|
|
117
117
|
}, cols.map((column, $columnIndex) => {
|
|
118
118
|
const { type, showHeaderOverflow, headerAlign, align, headerClassName } = column
|
|
119
119
|
// const { enabled } = tooltipOpts
|
|
120
|
+
const colid = column.id
|
|
120
121
|
const isColGroup = column.children && column.children.length
|
|
121
122
|
const fixedHiddenColumn = fixedType ? column.fixed !== fixedType && !isColGroup : column.fixed && overflowX
|
|
122
123
|
const headOverflow = XEUtils.isUndefined(showHeaderOverflow) || XEUtils.isNull(showHeaderOverflow) ? allColumnHeaderOverflow : showHeaderOverflow
|
|
@@ -145,7 +146,7 @@ export default {
|
|
|
145
146
|
thOns.mousedown = evnt => $xetable.triggerHeaderCellMousedownEvent(evnt, params)
|
|
146
147
|
}
|
|
147
148
|
return h('th', {
|
|
148
|
-
class: ['vxe-header--column',
|
|
149
|
+
class: ['vxe-header--column', colid, {
|
|
149
150
|
[`col--${headAlign}`]: headAlign,
|
|
150
151
|
[`col--${type}`]: type,
|
|
151
152
|
'col--last': $columnIndex === cols.length - 1,
|
|
@@ -159,13 +160,13 @@ export default {
|
|
|
159
160
|
'col--current': currentColumn === column
|
|
160
161
|
}, UtilTools.getClass(headerClassName, params), UtilTools.getClass(headerCellClassName, params)],
|
|
161
162
|
attrs: {
|
|
162
|
-
colid
|
|
163
|
+
colid,
|
|
163
164
|
colspan: column.colSpan > 1 ? column.colSpan : null,
|
|
164
165
|
rowspan: column.rowSpan > 1 ? column.rowSpan : null
|
|
165
166
|
},
|
|
166
167
|
style: headerCellStyle ? (XEUtils.isFunction(headerCellStyle) ? headerCellStyle(params) : headerCellStyle) : null,
|
|
167
168
|
on: thOns,
|
|
168
|
-
key: columnKey || columnOpts.useKey || isColGroup ?
|
|
169
|
+
key: columnKey || columnOpts.useKey || isColGroup ? colid : $columnIndex
|
|
169
170
|
}, [
|
|
170
171
|
h('div', {
|
|
171
172
|
class: ['vxe-cell', {
|
|
@@ -2761,7 +2761,7 @@ const Methods = {
|
|
|
2761
2761
|
const isUpArrow = keyCode === 38
|
|
2762
2762
|
const isRightArrow = keyCode === 39
|
|
2763
2763
|
const isDwArrow = keyCode === 40
|
|
2764
|
-
const
|
|
2764
|
+
const hasDeleteKey = keyCode === 46
|
|
2765
2765
|
const isF2 = keyCode === 113
|
|
2766
2766
|
const isContextMenu = keyCode === 93
|
|
2767
2767
|
const hasMetaKey = evnt.metaKey
|
|
@@ -2772,6 +2772,7 @@ const Methods = {
|
|
|
2772
2772
|
const operCtxMenu = isCtxMenu && ctxMenuStore.visible && (isEnter || isSpacebar || operArrow)
|
|
2773
2773
|
const isEditStatus = isEnableConf(editConfig) && actived.column && actived.row
|
|
2774
2774
|
const childrenField = treeOpts.children || treeOpts.childrenField
|
|
2775
|
+
const beforeEditMethod = editOpts.beforeEditMethod || editOpts.activeMethod
|
|
2775
2776
|
let params
|
|
2776
2777
|
if (filterStore.visible) {
|
|
2777
2778
|
if (isEsc) {
|
|
@@ -2872,9 +2873,32 @@ const Methods = {
|
|
|
2872
2873
|
} else if (actived.row || actived.column) {
|
|
2873
2874
|
this.moveTabSelected(actived.args, hasShiftKey, evnt)
|
|
2874
2875
|
}
|
|
2875
|
-
} else if (keyboardConfig &&
|
|
2876
|
+
} else if (keyboardConfig && keyboardOpts.isDel && hasDeleteKey && isEnableConf(editConfig) && (selected.row || selected.column)) {
|
|
2877
|
+
// 如果是删除键
|
|
2876
2878
|
if (!isEditStatus) {
|
|
2877
|
-
const { delMethod
|
|
2879
|
+
const { delMethod } = keyboardOpts
|
|
2880
|
+
const delPaqrams = {
|
|
2881
|
+
row: selected.row,
|
|
2882
|
+
rowIndex: this.getRowIndex(selected.row),
|
|
2883
|
+
column: selected.column,
|
|
2884
|
+
columnIndex: this.getColumnIndex(selected.column),
|
|
2885
|
+
$table: this
|
|
2886
|
+
}
|
|
2887
|
+
// 是否被禁用
|
|
2888
|
+
if (!beforeEditMethod || beforeEditMethod(params)) {
|
|
2889
|
+
if (delMethod) {
|
|
2890
|
+
delMethod(delPaqrams)
|
|
2891
|
+
} else {
|
|
2892
|
+
setCellValue(selected.row, selected.column, null)
|
|
2893
|
+
}
|
|
2894
|
+
// 如果按下 del 键,更新表尾数据
|
|
2895
|
+
this.updateFooter()
|
|
2896
|
+
this.emitEvent('cell-delete-value', delPaqrams, evnt)
|
|
2897
|
+
}
|
|
2898
|
+
}
|
|
2899
|
+
} else if (hasBackspaceKey && keyboardConfig && keyboardOpts.isBack && isEnableConf(editConfig) && (selected.row || selected.column)) {
|
|
2900
|
+
if (!isEditStatus) {
|
|
2901
|
+
const { backMethod } = keyboardOpts
|
|
2878
2902
|
// 如果是删除键
|
|
2879
2903
|
if (keyboardOpts.isDel && isEnableConf(editConfig) && (selected.row || selected.column)) {
|
|
2880
2904
|
const delPaqrams = {
|
|
@@ -2884,12 +2908,8 @@ const Methods = {
|
|
|
2884
2908
|
columnIndex: this.getColumnIndex(selected.column),
|
|
2885
2909
|
$table: this
|
|
2886
2910
|
}
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
} else {
|
|
2890
|
-
setCellValue(selected.row, selected.column, null)
|
|
2891
|
-
}
|
|
2892
|
-
if (hasBackspaceKey) {
|
|
2911
|
+
// 是否被禁用
|
|
2912
|
+
if (!beforeEditMethod || beforeEditMethod(params)) {
|
|
2893
2913
|
if (backMethod) {
|
|
2894
2914
|
backMethod({
|
|
2895
2915
|
row: selected.row,
|
|
@@ -2899,25 +2919,28 @@ const Methods = {
|
|
|
2899
2919
|
$table: this
|
|
2900
2920
|
})
|
|
2901
2921
|
} else {
|
|
2922
|
+
setCellValue(selected.row, selected.column, null)
|
|
2902
2923
|
this.handleActived(selected.args, evnt)
|
|
2903
2924
|
}
|
|
2904
|
-
|
|
2905
|
-
// 如果按下 del 键,更新表尾数据
|
|
2906
|
-
this.updateFooter()
|
|
2907
|
-
}
|
|
2908
|
-
this.emitEvent('cell-delete-value', delPaqrams, evnt)
|
|
2909
|
-
} else if (hasBackspaceKey && keyboardOpts.isArrow && treeConfig && (rowOpts.isCurrent || highlightCurrentRow) && currentRow) {
|
|
2910
|
-
// 如果树形表格回退键关闭当前行返回父节点
|
|
2911
|
-
const { parent: parentRow } = XEUtils.findTree(this.afterFullData, item => item === currentRow, { children: childrenField })
|
|
2912
|
-
if (parentRow) {
|
|
2913
|
-
evnt.preventDefault()
|
|
2914
|
-
params = { $table: this, row: parentRow }
|
|
2915
|
-
this.setTreeExpand(parentRow, false)
|
|
2916
|
-
.then(() => this.scrollToRow(parentRow))
|
|
2917
|
-
.then(() => this.triggerCurrentRowEvent(evnt, params))
|
|
2925
|
+
this.emitEvent('cell-backspace-value', delPaqrams, evnt)
|
|
2918
2926
|
}
|
|
2919
2927
|
}
|
|
2920
2928
|
}
|
|
2929
|
+
} else if (hasBackspaceKey && keyboardConfig && treeConfig && keyboardOpts.isBack && (rowOpts.isCurrent || highlightCurrentRow) && currentRow) {
|
|
2930
|
+
// 如果树形表格回退键关闭当前行返回父节点
|
|
2931
|
+
const { parent: parentRow } = XEUtils.findTree(this.afterTreeFullData, item => item === currentRow, { children: childrenField })
|
|
2932
|
+
if (parentRow) {
|
|
2933
|
+
evnt.preventDefault()
|
|
2934
|
+
params = {
|
|
2935
|
+
$table: this,
|
|
2936
|
+
row: parentRow,
|
|
2937
|
+
rowIndex: this.getRowIndex(parentRow),
|
|
2938
|
+
$rowIndex: this.getVMRowIndex(parentRow)
|
|
2939
|
+
}
|
|
2940
|
+
this.setTreeExpand(parentRow, false)
|
|
2941
|
+
.then(() => this.scrollToRow(parentRow))
|
|
2942
|
+
.then(() => this.triggerCurrentRowEvent(evnt, params))
|
|
2943
|
+
}
|
|
2921
2944
|
} else if (keyboardConfig && keyboardOpts.isEdit && !hasCtrlKey && !hasMetaKey && (isSpacebar || (keyCode >= 48 && keyCode <= 57) || (keyCode >= 65 && keyCode <= 90) || (keyCode >= 96 && keyCode <= 111) || (keyCode >= 186 && keyCode <= 192) || (keyCode >= 219 && keyCode <= 222))) {
|
|
2922
2945
|
const { editMethod } = keyboardOpts
|
|
2923
2946
|
// 启用编辑后,空格键功能将失效
|
|
@@ -665,25 +665,25 @@ function oldFormItemRadioAndCheckboxRender (h, renderOpts, params) {
|
|
|
665
665
|
*/
|
|
666
666
|
const renderMap = {
|
|
667
667
|
input: {
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
668
|
+
tableAutofocus: 'input',
|
|
669
|
+
renderTableEdit: nativeEditRender,
|
|
670
|
+
renderTableDefault: nativeEditRender,
|
|
671
|
+
renderTableFilter: nativeFilterRender,
|
|
672
|
+
defaultTableFilterMethod: handleInputFilterMethod,
|
|
673
|
+
renderFormItemContent: nativeItemRender
|
|
674
674
|
},
|
|
675
675
|
textarea: {
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
676
|
+
tableAutofocus: 'textarea',
|
|
677
|
+
renderTableEdit: nativeEditRender,
|
|
678
|
+
renderFormItemContent: nativeItemRender
|
|
679
679
|
},
|
|
680
680
|
select: {
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
681
|
+
renderTableEdit: nativeSelectEditRender,
|
|
682
|
+
renderTableDefault: nativeSelectEditRender,
|
|
683
|
+
renderTableCell (h, renderOpts, params) {
|
|
684
684
|
return getCellLabelVNs(h, renderOpts, params, getSelectCellValue(renderOpts, params))
|
|
685
685
|
},
|
|
686
|
-
|
|
686
|
+
renderTableFilter (h, renderOpts, params) {
|
|
687
687
|
const { column } = params
|
|
688
688
|
return column.filters.map((option, oIndex) => {
|
|
689
689
|
return h('select', {
|
|
@@ -695,8 +695,8 @@ const renderMap = {
|
|
|
695
695
|
renderOpts.optionGroups ? renderNativeOptgroups(h, renderOpts, params, renderNativeOptions) : renderNativeOptions(h, renderOpts.options, renderOpts, params))
|
|
696
696
|
})
|
|
697
697
|
},
|
|
698
|
-
|
|
699
|
-
|
|
698
|
+
defaultTableFilterMethod: handleFilterMethod,
|
|
699
|
+
renderFormItemContent (h, renderOpts, params) {
|
|
700
700
|
return [
|
|
701
701
|
h('select', {
|
|
702
702
|
class: 'vxe-default-select',
|
|
@@ -706,12 +706,12 @@ const renderMap = {
|
|
|
706
706
|
renderOpts.optionGroups ? renderNativeOptgroups(h, renderOpts, params, renderNativeFormOptions) : renderNativeFormOptions(h, renderOpts.options, renderOpts, params))
|
|
707
707
|
]
|
|
708
708
|
},
|
|
709
|
-
|
|
709
|
+
tableExportMethod: handleExportSelectMethod
|
|
710
710
|
},
|
|
711
711
|
VxeInput: {
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
712
|
+
tableAutofocus: '.vxe-input--inner',
|
|
713
|
+
renderTableEdit: defaultEditRender,
|
|
714
|
+
renderTableCell (h, renderOpts, params) {
|
|
715
715
|
const { props = {} } = renderOpts
|
|
716
716
|
const { row, column } = params
|
|
717
717
|
const digits = props.digits || GlobalConfig.input.digits
|
|
@@ -732,22 +732,22 @@ const renderMap = {
|
|
|
732
732
|
}
|
|
733
733
|
return getCellLabelVNs(h, renderOpts, params, cellValue)
|
|
734
734
|
},
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
735
|
+
renderTableDefault: defaultEditRender,
|
|
736
|
+
renderTableFilter: defaultFilterRender,
|
|
737
|
+
defaultTableFilterMethod: handleInputFilterMethod,
|
|
738
|
+
renderFormItemContent: defaultItemRender
|
|
739
739
|
},
|
|
740
740
|
VxeTextarea: {
|
|
741
|
-
|
|
742
|
-
|
|
741
|
+
tableAutofocus: '.vxe-textarea--inner',
|
|
742
|
+
renderFormItemContent: defaultItemRender
|
|
743
743
|
},
|
|
744
744
|
VxeButton: {
|
|
745
|
-
|
|
746
|
-
|
|
745
|
+
renderTableDefault: defaultCellRender,
|
|
746
|
+
renderFormItemContent: defaultFormItemRender
|
|
747
747
|
},
|
|
748
748
|
VxeButtonGroup: {
|
|
749
|
-
|
|
750
|
-
|
|
749
|
+
renderTableDefault: defaultCellRender,
|
|
750
|
+
renderFormItemContent (h, renderOpts, params) {
|
|
751
751
|
const { options } = renderOpts
|
|
752
752
|
const { data, property } = params
|
|
753
753
|
const itemValue = XEUtils.get(data, property)
|
|
@@ -761,13 +761,13 @@ const renderMap = {
|
|
|
761
761
|
}
|
|
762
762
|
},
|
|
763
763
|
VxeSelect: {
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
764
|
+
tableAutofocus: '.vxe-input--inner',
|
|
765
|
+
renderTableEdit: defaultSelectEditRender,
|
|
766
|
+
renderTableDefault: defaultSelectEditRender,
|
|
767
|
+
renderTableCell (h, renderOpts, params) {
|
|
768
768
|
return getCellLabelVNs(h, renderOpts, params, getSelectCellValue(renderOpts, params))
|
|
769
769
|
},
|
|
770
|
-
|
|
770
|
+
renderTableFilter (h, renderOpts, params) {
|
|
771
771
|
const { column } = params
|
|
772
772
|
const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
|
|
773
773
|
const nativeOn = getNativeOns(renderOpts, params)
|
|
@@ -781,8 +781,8 @@ const renderMap = {
|
|
|
781
781
|
})
|
|
782
782
|
})
|
|
783
783
|
},
|
|
784
|
-
|
|
785
|
-
|
|
784
|
+
defaultTableFilterMethod: handleFilterMethod,
|
|
785
|
+
renderFormItemContent (h, renderOpts, params) {
|
|
786
786
|
const { data, property } = params
|
|
787
787
|
const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
|
|
788
788
|
const itemValue = XEUtils.get(data, property)
|
|
@@ -794,36 +794,36 @@ const renderMap = {
|
|
|
794
794
|
})
|
|
795
795
|
]
|
|
796
796
|
},
|
|
797
|
-
|
|
797
|
+
tableExportMethod: handleExportSelectMethod
|
|
798
798
|
},
|
|
799
799
|
VxeRadio: {
|
|
800
|
-
|
|
801
|
-
|
|
800
|
+
tableAutofocus: '.vxe-radio--input',
|
|
801
|
+
renderFormItemContent: defaultFormItemRender
|
|
802
802
|
},
|
|
803
803
|
VxeRadioGroup: {
|
|
804
|
-
|
|
805
|
-
|
|
804
|
+
tableAutofocus: '.vxe-radio--input',
|
|
805
|
+
renderFormItemContent: formItemRadioAndCheckboxRender
|
|
806
806
|
},
|
|
807
807
|
VxeCheckbox: {
|
|
808
|
-
|
|
809
|
-
|
|
808
|
+
tableAutofocus: '.vxe-checkbox--input',
|
|
809
|
+
renderFormItemContent: defaultFormItemRender
|
|
810
810
|
},
|
|
811
811
|
VxeCheckboxGroup: {
|
|
812
|
-
|
|
813
|
-
|
|
812
|
+
tableAutofocus: '.vxe-checkbox--input',
|
|
813
|
+
renderFormItemContent: formItemRadioAndCheckboxRender
|
|
814
814
|
},
|
|
815
815
|
VxeSwitch: {
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
816
|
+
tableAutofocus: '.vxe-switch--button',
|
|
817
|
+
renderTableEdit: defaultEditRender,
|
|
818
|
+
renderTableDefault: defaultEditRender,
|
|
819
|
+
renderFormItemContent: defaultItemRender
|
|
820
820
|
},
|
|
821
821
|
|
|
822
822
|
// 以下已废弃
|
|
823
823
|
$input: {
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
824
|
+
tableAutofocus: '.vxe-input--inner',
|
|
825
|
+
renderTableEdit: oldEditRender,
|
|
826
|
+
renderTableCell (h, renderOpts, params) {
|
|
827
827
|
const { props = {} } = renderOpts
|
|
828
828
|
const { row, column } = params
|
|
829
829
|
const digits = props.digits || GlobalConfig.input.digits
|
|
@@ -843,31 +843,31 @@ const renderMap = {
|
|
|
843
843
|
}
|
|
844
844
|
return getCellLabelVNs(h, renderOpts, params, cellValue)
|
|
845
845
|
},
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
846
|
+
renderTableDefault: oldEditRender,
|
|
847
|
+
renderTableFilter: oldFilterRender,
|
|
848
|
+
defaultTableFilterMethod: handleInputFilterMethod,
|
|
849
|
+
renderFormItemContent: oldItemRender
|
|
850
850
|
},
|
|
851
851
|
$textarea: {
|
|
852
|
-
|
|
853
|
-
|
|
852
|
+
tableAutofocus: '.vxe-textarea--inner',
|
|
853
|
+
renderFormItemContent: oldItemRender
|
|
854
854
|
},
|
|
855
855
|
$button: {
|
|
856
|
-
|
|
857
|
-
|
|
856
|
+
renderTableDefault: oldButtonEditRender,
|
|
857
|
+
renderFormItemContent: oldButtonItemRender
|
|
858
858
|
},
|
|
859
859
|
$buttons: {
|
|
860
|
-
|
|
861
|
-
|
|
860
|
+
renderTableDefault: oldButtonsEditRender,
|
|
861
|
+
renderFormItemContent: oldButtonsItemRender
|
|
862
862
|
},
|
|
863
863
|
$select: {
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
864
|
+
tableAutofocus: '.vxe-input--inner',
|
|
865
|
+
renderTableEdit: oldSelectEditRender,
|
|
866
|
+
renderTableDefault: oldSelectEditRender,
|
|
867
|
+
renderTableCell (h, renderOpts, params) {
|
|
868
868
|
return getCellLabelVNs(h, renderOpts, params, getSelectCellValue(renderOpts, params))
|
|
869
869
|
},
|
|
870
|
-
|
|
870
|
+
renderTableFilter (h, renderOpts, params) {
|
|
871
871
|
const { column } = params
|
|
872
872
|
const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
|
|
873
873
|
const nativeOn = getNativeOns(renderOpts, params)
|
|
@@ -881,8 +881,8 @@ const renderMap = {
|
|
|
881
881
|
})
|
|
882
882
|
})
|
|
883
883
|
},
|
|
884
|
-
|
|
885
|
-
|
|
884
|
+
defaultTableFilterMethod: handleFilterMethod,
|
|
885
|
+
renderFormItemContent (h, renderOpts, params) {
|
|
886
886
|
const { data, property } = params
|
|
887
887
|
const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
|
|
888
888
|
const itemValue = XEUtils.get(data, property)
|
|
@@ -894,21 +894,21 @@ const renderMap = {
|
|
|
894
894
|
})
|
|
895
895
|
]
|
|
896
896
|
},
|
|
897
|
-
|
|
897
|
+
tableExportMethod: handleExportSelectMethod
|
|
898
898
|
},
|
|
899
899
|
$radio: {
|
|
900
|
-
|
|
901
|
-
|
|
900
|
+
tableAutofocus: '.vxe-radio--input',
|
|
901
|
+
renderFormItemContent: oldFormItemRadioAndCheckboxRender
|
|
902
902
|
},
|
|
903
903
|
$checkbox: {
|
|
904
|
-
|
|
905
|
-
|
|
904
|
+
tableAutofocus: '.vxe-checkbox--input',
|
|
905
|
+
renderFormItemContent: oldFormItemRadioAndCheckboxRender
|
|
906
906
|
},
|
|
907
907
|
$switch: {
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
908
|
+
tableAutofocus: '.vxe-switch--button',
|
|
909
|
+
renderTableEdit: oldEditRender,
|
|
910
|
+
renderTableDefault: oldEditRender,
|
|
911
|
+
renderFormItemContent: oldItemRender
|
|
912
912
|
}
|
|
913
913
|
// 以上已废弃
|
|
914
914
|
}
|
package/styles/button.scss
CHANGED
package/styles/custom.scss
CHANGED
|
@@ -100,6 +100,7 @@
|
|
|
100
100
|
flex-grow: 1;
|
|
101
101
|
overflow-x: hidden;
|
|
102
102
|
overflow-y: auto;
|
|
103
|
+
outline: 0;
|
|
103
104
|
}
|
|
104
105
|
|
|
105
106
|
.vxe-table-custom--header,
|
|
@@ -221,6 +222,7 @@
|
|
|
221
222
|
.vxe-table-custom-popup--body {
|
|
222
223
|
overflow: auto;
|
|
223
224
|
height: 100%;
|
|
225
|
+
outline: 0;
|
|
224
226
|
}
|
|
225
227
|
|
|
226
228
|
.vxe-table-custom-popup--table-wrapper {
|
package/styles/grid.scss
CHANGED
package/styles/input.scss
CHANGED
|
@@ -86,10 +86,10 @@ $iconWidth: 1.6em;
|
|
|
86
86
|
top: 1px;
|
|
87
87
|
right: 0.5em;
|
|
88
88
|
height: calc(100% - 2px);
|
|
89
|
-
color:
|
|
90
|
-
background-color:
|
|
89
|
+
color: $vxe-input-count-color;
|
|
90
|
+
background-color: $vxe-input-count-background-color;
|
|
91
91
|
&.is--error {
|
|
92
|
-
color:
|
|
92
|
+
color: $vxe-input-count-error-color;
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
|
package/styles/modal.scss
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
color: $vxe-font-color;
|
|
13
13
|
font-family: $vxe-font-family;
|
|
14
14
|
transition: top .4s ease-in-out;
|
|
15
|
+
outline: 0;
|
|
15
16
|
&.is--active {
|
|
16
17
|
display: block;
|
|
17
18
|
}
|
|
@@ -166,6 +167,7 @@
|
|
|
166
167
|
text-align: left;
|
|
167
168
|
pointer-events: auto;
|
|
168
169
|
opacity: 0;
|
|
170
|
+
outline: 0;
|
|
169
171
|
&.is--drag {
|
|
170
172
|
cursor: move;
|
|
171
173
|
.vxe-modal--body,
|
|
@@ -231,6 +233,7 @@
|
|
|
231
233
|
.vxe-modal--body {
|
|
232
234
|
display: flex;
|
|
233
235
|
flex-grow: 1;
|
|
236
|
+
outline: 0;
|
|
234
237
|
}
|
|
235
238
|
.vxe-modal--header {
|
|
236
239
|
display: flex;
|