vxe-pc-ui 4.6.8 → 4.6.10
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/alert/src/alert.js +5 -5
- package/es/anchor/src/anchor-link.js +3 -2
- package/es/anchor/src/anchor.js +3 -3
- package/es/breadcrumb/src/breadcrumb-item.js +3 -2
- package/es/button/src/button-group.js +3 -3
- package/es/button/src/button.js +7 -8
- package/es/card/src/card.js +7 -7
- package/es/carousel/src/carousel.js +3 -3
- package/es/countdown/src/countdown.js +4 -4
- package/es/form/render/index.js +2 -4
- package/es/form/src/form-group.js +5 -3
- package/es/form/src/form-item.js +6 -4
- package/es/form/src/form.js +97 -37
- package/es/form-design/src/default-setting-form.js +1 -1
- package/es/form-design/src/form-view.js +7 -9
- package/es/icon/style.css +1 -1
- package/es/icon-picker/src/icon-picker.js +4 -4
- package/es/image/src/group.js +3 -1
- package/es/image/src/image.js +3 -1
- package/es/image/src/preview.js +33 -19
- package/es/image/src/util.js +1 -0
- package/es/list-design/src/layout-preview.js +5 -7
- package/es/list-design/src/list-view.js +8 -10
- package/es/loading/src/loading.js +3 -3
- package/es/menu/src/menu.js +9 -9
- package/es/modal/src/modal.js +16 -18
- package/es/pager/src/pager.js +1 -3
- package/es/password-input/src/password-input.js +7 -7
- package/es/print/src/print.js +6 -6
- package/es/pulldown/src/pulldown.js +4 -4
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/switch/src/switch.js +4 -4
- package/es/table-select/src/table-select.js +5 -7
- package/es/tabs/src/tabs.js +11 -15
- package/es/tag/src/tag.js +3 -3
- package/es/tip/src/tip.js +5 -5
- package/es/tree/src/tree.js +245 -180
- package/es/ui/index.js +3 -7
- package/es/ui/src/log.js +1 -1
- package/es/upload/src/upload.js +31 -33
- package/lib/alert/src/alert.js +3 -3
- package/lib/alert/src/alert.min.js +1 -1
- package/lib/anchor/src/anchor-link.js +2 -1
- package/lib/anchor/src/anchor-link.min.js +1 -1
- package/lib/anchor/src/anchor.js +3 -3
- package/lib/anchor/src/anchor.min.js +1 -1
- package/lib/breadcrumb/src/breadcrumb-item.js +2 -1
- package/lib/breadcrumb/src/breadcrumb-item.min.js +1 -1
- package/lib/button/src/button-group.js +6 -6
- package/lib/button/src/button-group.min.js +1 -1
- package/lib/button/src/button.js +4 -6
- package/lib/button/src/button.min.js +1 -1
- package/lib/card/src/card.js +4 -4
- package/lib/card/src/card.min.js +1 -1
- package/lib/carousel/src/carousel.js +1 -1
- package/lib/carousel/src/carousel.min.js +1 -1
- package/lib/countdown/src/countdown.js +2 -2
- package/lib/countdown/src/countdown.min.js +1 -1
- package/lib/form/render/index.js +2 -4
- package/lib/form/render/index.min.js +1 -1
- package/lib/form/src/form-group.js +3 -1
- package/lib/form/src/form-group.min.js +1 -1
- package/lib/form/src/form-item.js +4 -2
- package/lib/form/src/form-item.min.js +1 -1
- package/lib/form/src/form.js +95 -36
- package/lib/form/src/form.min.js +1 -1
- package/lib/form-design/src/default-setting-form.js +12 -12
- package/lib/form-design/src/default-setting-form.min.js +1 -1
- package/lib/form-design/src/form-view.js +5 -7
- package/lib/form-design/src/form-view.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/icon-picker/src/icon-picker.js +2 -2
- package/lib/icon-picker/src/icon-picker.min.js +1 -1
- package/lib/image/src/group.js +3 -0
- package/lib/image/src/group.min.js +1 -1
- package/lib/image/src/image.js +3 -0
- package/lib/image/src/image.min.js +1 -1
- package/lib/image/src/preview.js +20 -8
- package/lib/image/src/preview.min.js +1 -1
- package/lib/image/src/util.js +1 -0
- package/lib/image/src/util.min.js +1 -1
- package/lib/index.umd.js +549 -377
- package/lib/index.umd.min.js +1 -1
- package/lib/list-design/src/layout-preview.js +5 -7
- package/lib/list-design/src/layout-preview.min.js +1 -1
- package/lib/list-design/src/list-view.js +6 -8
- package/lib/list-design/src/list-view.min.js +1 -1
- package/lib/loading/src/loading.js +1 -1
- package/lib/loading/src/loading.min.js +1 -1
- package/lib/menu/src/menu.js +6 -6
- package/lib/menu/src/menu.min.js +1 -1
- package/lib/modal/src/modal.js +12 -14
- package/lib/modal/src/modal.min.js +1 -1
- package/lib/pager/src/pager.js +1 -3
- package/lib/pager/src/pager.min.js +1 -1
- package/lib/password-input/src/password-input.js +4 -4
- package/lib/password-input/src/password-input.min.js +1 -1
- package/lib/print/src/print.js +4 -4
- package/lib/print/src/print.min.js +1 -1
- package/lib/pulldown/src/pulldown.js +2 -2
- package/lib/pulldown/src/pulldown.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/switch/src/switch.js +2 -2
- package/lib/switch/src/switch.min.js +1 -1
- package/lib/table-select/src/table-select.js +5 -7
- package/lib/table-select/src/table-select.min.js +1 -1
- package/lib/tabs/src/tabs.js +10 -14
- package/lib/tabs/src/tabs.min.js +1 -1
- package/lib/tag/src/tag.js +1 -1
- package/lib/tag/src/tag.min.js +1 -1
- package/lib/tip/src/tip.js +3 -3
- package/lib/tip/src/tip.min.js +1 -1
- package/lib/tree/src/tree.js +298 -184
- package/lib/tree/src/tree.min.js +1 -1
- package/lib/ui/index.js +3 -7
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/upload/src/upload.js +27 -29
- package/lib/upload/src/upload.min.js +1 -1
- package/package.json +1 -1
- package/packages/alert/src/alert.ts +5 -5
- package/packages/anchor/src/anchor-link.ts +3 -2
- package/packages/anchor/src/anchor.ts +3 -3
- package/packages/breadcrumb/src/breadcrumb-item.ts +3 -2
- package/packages/button/src/button-group.ts +3 -3
- package/packages/button/src/button.ts +7 -8
- package/packages/card/src/card.ts +7 -7
- package/packages/carousel/src/carousel.ts +3 -3
- package/packages/countdown/src/countdown.ts +4 -4
- package/packages/form/render/index.ts +2 -4
- package/packages/form/src/form-group.ts +7 -3
- package/packages/form/src/form-item.ts +7 -4
- package/packages/form/src/form.ts +98 -35
- package/packages/form-design/src/default-setting-form.ts +1 -1
- package/packages/form-design/src/form-view.ts +7 -9
- package/packages/icon-picker/src/icon-picker.ts +4 -4
- package/packages/image/src/group.ts +3 -1
- package/packages/image/src/image.ts +3 -1
- package/packages/image/src/preview.ts +37 -22
- package/packages/image/src/util.ts +1 -0
- package/packages/list-design/src/layout-preview.ts +5 -7
- package/packages/list-design/src/list-view.ts +8 -10
- package/packages/loading/src/loading.ts +3 -3
- package/packages/menu/src/menu.ts +9 -9
- package/packages/modal/src/modal.ts +16 -18
- package/packages/pager/src/pager.ts +1 -3
- package/packages/password-input/src/password-input.ts +7 -7
- package/packages/print/src/print.ts +6 -6
- package/packages/pulldown/src/pulldown.ts +5 -5
- package/packages/switch/src/switch.ts +4 -4
- package/packages/table-select/src/table-select.ts +5 -7
- package/packages/tabs/src/tabs.ts +11 -15
- package/packages/tag/src/tag.ts +3 -3
- package/packages/tip/src/tip.ts +5 -5
- package/packages/tree/src/tree.ts +242 -179
- package/packages/ui/index.ts +2 -6
- package/packages/upload/src/upload.ts +31 -33
- package/types/components/button.d.ts +2 -1
- package/types/components/image-group.d.ts +3 -0
- package/types/components/image-preview.d.ts +32 -0
- package/types/components/image.d.ts +2 -0
- package/types/components/tree.d.ts +7 -5
- /package/es/icon/{iconfont.1747192660271.ttf → iconfont.1747318422186.ttf} +0 -0
- /package/es/icon/{iconfont.1747192660271.woff → iconfont.1747318422186.woff} +0 -0
- /package/es/icon/{iconfont.1747192660271.woff2 → iconfont.1747318422186.woff2} +0 -0
- /package/es/{iconfont.1747192660271.ttf → iconfont.1747318422186.ttf} +0 -0
- /package/es/{iconfont.1747192660271.woff → iconfont.1747318422186.woff} +0 -0
- /package/es/{iconfont.1747192660271.woff2 → iconfont.1747318422186.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1747192660271.ttf → iconfont.1747318422186.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1747192660271.woff → iconfont.1747318422186.woff} +0 -0
- /package/lib/icon/style/{iconfont.1747192660271.woff2 → iconfont.1747318422186.woff2} +0 -0
- /package/lib/{iconfont.1747192660271.ttf → iconfont.1747318422186.ttf} +0 -0
- /package/lib/{iconfont.1747192660271.woff → iconfont.1747318422186.woff} +0 -0
- /package/lib/{iconfont.1747192660271.woff2 → iconfont.1747318422186.woff2} +0 -0
package/lib/index.umd.js
CHANGED
|
@@ -4213,26 +4213,22 @@ function checkDynamic() {
|
|
|
4213
4213
|
}
|
|
4214
4214
|
;// CONCATENATED MODULE: ./packages/ui/src/log.ts
|
|
4215
4215
|
|
|
4216
|
-
const log_version = `ui v${"4.6.
|
|
4216
|
+
const log_version = `ui v${"4.6.10"}`;
|
|
4217
4217
|
const warnLog = log.create('warn', log_version);
|
|
4218
4218
|
const errLog = log.create('error', log_version);
|
|
4219
4219
|
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
4220
4220
|
|
|
4221
4221
|
|
|
4222
4222
|
|
|
4223
|
-
const ui_version = "4.6.
|
|
4223
|
+
const ui_version = "4.6.10";
|
|
4224
4224
|
index_esm_VxeUI.uiVersion = ui_version;
|
|
4225
4225
|
index_esm_VxeUI.dynamicApp = dynamicApp;
|
|
4226
4226
|
function config(options) {
|
|
4227
|
-
|
|
4228
|
-
warnLog('vxe.error.delFunc', ['config', 'setConfig']);
|
|
4229
|
-
}
|
|
4227
|
+
warnLog('vxe.error.delFunc', ['config', 'setConfig']);
|
|
4230
4228
|
return setConfig(options);
|
|
4231
4229
|
}
|
|
4232
4230
|
function setup(options) {
|
|
4233
|
-
|
|
4234
|
-
warnLog('vxe.error.delFunc', ['setup', 'setConfig']);
|
|
4235
|
-
}
|
|
4231
|
+
warnLog('vxe.error.delFunc', ['setup', 'setConfig']);
|
|
4236
4232
|
return setConfig(options);
|
|
4237
4233
|
}
|
|
4238
4234
|
index_esm_VxeUI.config = config;
|
|
@@ -4892,18 +4888,18 @@ function getSlotVNs(vns) {
|
|
|
4892
4888
|
class: 'vxe-alert--icon'
|
|
4893
4889
|
}, iconSlot ? getSlotVNs(iconSlot({})) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
4894
4890
|
class: icon || getIcon()[`ALERT_${status?.toUpperCase()}`]
|
|
4895
|
-
})]) : (
|
|
4891
|
+
})]) : renderEmptyElement($xeAlert), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
4896
4892
|
class: 'vxe-alert--body'
|
|
4897
4893
|
}, [titleSlot || title ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
4898
4894
|
class: 'vxe-alert--title'
|
|
4899
|
-
}, titleSlot ? getSlotVNs(titleSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(title)) : (
|
|
4895
|
+
}, titleSlot ? getSlotVNs(titleSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(title)) : renderEmptyElement($xeAlert), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
4900
4896
|
class: 'vxe-alert--content'
|
|
4901
4897
|
}, defaultSlot ? getSlotVNs(defaultSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(content))]), showClose ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
4902
4898
|
class: 'vxe-alert--close-btn',
|
|
4903
4899
|
onClick: closeEvent
|
|
4904
4900
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
4905
4901
|
class: getIcon().ALERT_CLOSE
|
|
4906
|
-
})]) : (
|
|
4902
|
+
})]) : renderEmptyElement($xeAlert)]);
|
|
4907
4903
|
};
|
|
4908
4904
|
$xeAlert.renderVN = renderVN;
|
|
4909
4905
|
return $xeAlert;
|
|
@@ -5193,6 +5189,7 @@ function destroyAnchorLink($xeAnchor, linkConfig) {
|
|
|
5193
5189
|
|
|
5194
5190
|
|
|
5195
5191
|
|
|
5192
|
+
|
|
5196
5193
|
/* harmony default export */ var anchor_link = ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
|
|
5197
5194
|
name: 'VxeAnchorLink',
|
|
5198
5195
|
props: {
|
|
@@ -5280,7 +5277,7 @@ function destroyAnchorLink($xeAnchor, linkConfig) {
|
|
|
5280
5277
|
onClick: clickEvent
|
|
5281
5278
|
}, defaultSlot ? defaultSlot({}) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(content)), subSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
5282
5279
|
class: 'vxe-anchor-link--sub-items'
|
|
5283
|
-
}, subSlot({})) : (
|
|
5280
|
+
}, subSlot({})) : renderEmptyElement($xeAnchorLink)]);
|
|
5284
5281
|
};
|
|
5285
5282
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeAnchorLink', $xeAnchorLink);
|
|
5286
5283
|
$xeAnchorLink.renderVN = renderVN;
|
|
@@ -5484,7 +5481,7 @@ function destroyAnchorLink($xeAnchor, linkConfig) {
|
|
|
5484
5481
|
}, defaultSlot ? defaultSlot({}) : renderSubItems(options)), showMarker ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
5485
5482
|
ref: refMarkerElem,
|
|
5486
5483
|
class: 'vxe-anchor--marker'
|
|
5487
|
-
}) : (
|
|
5484
|
+
}) : renderEmptyElement($xeAnchor)]);
|
|
5488
5485
|
};
|
|
5489
5486
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.modelValue, val => {
|
|
5490
5487
|
reactData.activeHref = val;
|
|
@@ -5785,6 +5782,7 @@ const Badge = VxeBadge;
|
|
|
5785
5782
|
;// CONCATENATED MODULE: ./packages/breadcrumb/src/breadcrumb-item.ts
|
|
5786
5783
|
|
|
5787
5784
|
|
|
5785
|
+
|
|
5788
5786
|
/* harmony default export */ var breadcrumb_item = ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
|
|
5789
5787
|
name: 'VxeBreadcrumbItem',
|
|
5790
5788
|
props: {
|
|
@@ -5854,7 +5852,7 @@ const Badge = VxeBadge;
|
|
|
5854
5852
|
class: 'vxe-breadcrumb-item--content-text'
|
|
5855
5853
|
}, defaultSlot ? defaultSlot({}) : `${title || ''}`)]), separator ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
5856
5854
|
class: 'vxe-breadcrumb-item--separator'
|
|
5857
|
-
}, `${separator}`) : (
|
|
5855
|
+
}, `${separator}`) : renderEmptyElement($xeBreadcrumbItem)]);
|
|
5858
5856
|
};
|
|
5859
5857
|
$xeBreadcrumbItem.renderVN = renderVN;
|
|
5860
5858
|
return $xeBreadcrumbItem;
|
|
@@ -6540,7 +6538,7 @@ const VxeButtonComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defi
|
|
|
6540
6538
|
default: null
|
|
6541
6539
|
}
|
|
6542
6540
|
},
|
|
6543
|
-
emits: ['click', 'mouseenter', 'mouseleave', 'dropdown-click'],
|
|
6541
|
+
emits: ['click', 'mouseenter', 'mouseleave', 'dropdown-click', 'dropdownClick'],
|
|
6544
6542
|
setup(props, context) {
|
|
6545
6543
|
const {
|
|
6546
6544
|
slots,
|
|
@@ -7005,7 +7003,7 @@ const VxeButtonComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defi
|
|
|
7005
7003
|
const vSize = computeSize.value;
|
|
7006
7004
|
const dropdownsSlot = slots.dropdowns;
|
|
7007
7005
|
if (!permissionInfo.visible) {
|
|
7008
|
-
return (
|
|
7006
|
+
return renderEmptyElement($xeButton);
|
|
7009
7007
|
}
|
|
7010
7008
|
if (dropdownsSlot || downBtnList.length) {
|
|
7011
7009
|
const btnOns = {};
|
|
@@ -7166,10 +7164,8 @@ const VxeButtonComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defi
|
|
|
7166
7164
|
};
|
|
7167
7165
|
$xeButton.renderVN = renderVN;
|
|
7168
7166
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
7169
|
-
if (
|
|
7170
|
-
|
|
7171
|
-
warnLog('vxe.error.delProp', ['type=text', 'mode=text']);
|
|
7172
|
-
}
|
|
7167
|
+
if (props.type === 'text') {
|
|
7168
|
+
warnLog('vxe.error.delProp', ['type=text', 'mode=text']);
|
|
7173
7169
|
}
|
|
7174
7170
|
globalEvents.on($xeButton, 'mousewheel', handleGlobalMousewheelEvent);
|
|
7175
7171
|
globalEvents.on($xeButton, 'mousedown', handleGlobalMousedownEvent);
|
|
@@ -7273,7 +7269,7 @@ const Button = VxeButton;
|
|
|
7273
7269
|
const permissionInfo = computePermissionInfo.value;
|
|
7274
7270
|
const defaultSlot = slots.default;
|
|
7275
7271
|
if (!permissionInfo.visible) {
|
|
7276
|
-
return (
|
|
7272
|
+
return renderEmptyElement($xeButtonGroup);
|
|
7277
7273
|
}
|
|
7278
7274
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
7279
7275
|
class: ['vxe-button-group', className ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(className) ? className({
|
|
@@ -8815,7 +8811,7 @@ const Calendar = VxeCalendar;
|
|
|
8815
8811
|
const loadingIcon = computeLoadingIcon.value;
|
|
8816
8812
|
const loadingText = computeLoadingText.value;
|
|
8817
8813
|
if (!initialized && !modelValue) {
|
|
8818
|
-
return (
|
|
8814
|
+
return renderEmptyElement($xeLoading);
|
|
8819
8815
|
}
|
|
8820
8816
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8821
8817
|
class: ['vxe-loading', {
|
|
@@ -8957,17 +8953,17 @@ const Calendar = VxeCalendar;
|
|
|
8957
8953
|
}]
|
|
8958
8954
|
}, titleSlot ? getSlotVNs(titleSlot({})) : `${title || ''}`), extraSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8959
8955
|
class: 'vxe-card--header-extra'
|
|
8960
|
-
}, getSlotVNs(extraSlot({}))) : (
|
|
8956
|
+
}, getSlotVNs(extraSlot({}))) : renderEmptyElement($xeCard)]) : renderEmptyElement($xeCard), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8961
8957
|
class: 'vxe-card--body'
|
|
8962
8958
|
}, [leftSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8963
8959
|
class: 'vxe-card--body-left'
|
|
8964
|
-
}, getSlotVNs(leftSlot({}))) : (
|
|
8960
|
+
}, getSlotVNs(leftSlot({}))) : renderEmptyElement($xeCard), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8965
8961
|
class: 'vxe-card--body-content'
|
|
8966
8962
|
}, defaultSlot ? getSlotVNs(defaultSlot({})) : []), rightSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8967
8963
|
class: 'vxe-card--body-right'
|
|
8968
|
-
}, getSlotVNs(rightSlot({}))) : (
|
|
8964
|
+
}, getSlotVNs(rightSlot({}))) : renderEmptyElement($xeCard)]), footerSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
8969
8965
|
class: 'vxe-card--footer'
|
|
8970
|
-
}, getSlotVNs(footerSlot({}))) : (
|
|
8966
|
+
}, getSlotVNs(footerSlot({}))) : renderEmptyElement($xeCard),
|
|
8971
8967
|
/**
|
|
8972
8968
|
* 加载中
|
|
8973
8969
|
*/
|
|
@@ -9333,7 +9329,7 @@ const Card = VxeCard;
|
|
|
9333
9329
|
style: height ? {
|
|
9334
9330
|
height: toCssUnit(height)
|
|
9335
9331
|
} : null
|
|
9336
|
-
}, [renderItemWrapper(list)]), showIndicators ? renderIndicators(list) : (
|
|
9332
|
+
}, [renderItemWrapper(list)]), showIndicators ? renderIndicators(list) : renderEmptyElement($xeCarousel), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
9337
9333
|
class: 'vxe-carousel--btn-wrapper'
|
|
9338
9334
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
9339
9335
|
class: 'vxe-carousel--previous-btn',
|
|
@@ -14590,7 +14586,7 @@ const ColorPicker = VxeColorPicker;
|
|
|
14590
14586
|
content: prefixOpts.content,
|
|
14591
14587
|
icon: prefixOpts.icon,
|
|
14592
14588
|
status: prefixOpts.status
|
|
14593
|
-
})]) : (
|
|
14589
|
+
})]) : renderEmptyElement($xeCountdown), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
14594
14590
|
class: 'vxe-countdown--content'
|
|
14595
14591
|
}, defaultSlot ? getSlotVNs(defaultSlot({
|
|
14596
14592
|
currentValue: currNum,
|
|
@@ -14604,7 +14600,7 @@ const ColorPicker = VxeColorPicker;
|
|
|
14604
14600
|
content: suffixOpts.content,
|
|
14605
14601
|
icon: suffixOpts.icon,
|
|
14606
14602
|
status: suffixOpts.status
|
|
14607
|
-
})]) : (
|
|
14603
|
+
})]) : renderEmptyElement($xeCountdown)]);
|
|
14608
14604
|
};
|
|
14609
14605
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.modelValue, () => {
|
|
14610
14606
|
updateCount();
|
|
@@ -19964,33 +19960,108 @@ class Rule {
|
|
|
19964
19960
|
return this.content;
|
|
19965
19961
|
}
|
|
19966
19962
|
}
|
|
19967
|
-
|
|
19963
|
+
// 如果存在 pattern,判断正则
|
|
19964
|
+
function validREValue(pattern, val) {
|
|
19965
|
+
if (pattern && !(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isRegExp(pattern) ? pattern : new RegExp(pattern)).test(val)) {
|
|
19966
|
+
return false;
|
|
19967
|
+
}
|
|
19968
|
+
return true;
|
|
19969
|
+
}
|
|
19970
|
+
// 如果存在 max,判断最大值
|
|
19971
|
+
function validMaxValue(max, num) {
|
|
19972
|
+
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(max) && num > external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(max)) {
|
|
19973
|
+
return false;
|
|
19974
|
+
}
|
|
19975
|
+
return true;
|
|
19976
|
+
}
|
|
19977
|
+
// 如果存在 min,判断最小值
|
|
19978
|
+
function validMinValue(min, num) {
|
|
19979
|
+
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(min) && num < external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(min)) {
|
|
19980
|
+
return false;
|
|
19981
|
+
}
|
|
19982
|
+
return true;
|
|
19983
|
+
}
|
|
19984
|
+
function validRuleValue(rule, val, required) {
|
|
19968
19985
|
const {
|
|
19969
19986
|
type,
|
|
19970
19987
|
min,
|
|
19971
19988
|
max,
|
|
19972
19989
|
pattern
|
|
19973
19990
|
} = rule;
|
|
19991
|
+
const isArrType = type === 'array';
|
|
19974
19992
|
const isNumType = type === 'number';
|
|
19975
|
-
const
|
|
19976
|
-
|
|
19977
|
-
if (
|
|
19978
|
-
return
|
|
19979
|
-
}
|
|
19980
|
-
// 如果存在 min,判断最小值
|
|
19981
|
-
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(min) && numVal < external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(min)) {
|
|
19982
|
-
return true;
|
|
19993
|
+
const isStrType = type === 'string';
|
|
19994
|
+
const strVal = `${val}`;
|
|
19995
|
+
if (!validREValue(pattern, strVal)) {
|
|
19996
|
+
return false;
|
|
19983
19997
|
}
|
|
19984
|
-
|
|
19985
|
-
|
|
19986
|
-
|
|
19998
|
+
if (isArrType) {
|
|
19999
|
+
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(val)) {
|
|
20000
|
+
return false;
|
|
20001
|
+
}
|
|
20002
|
+
if (required) {
|
|
20003
|
+
if (!val.length) {
|
|
20004
|
+
return false;
|
|
20005
|
+
}
|
|
20006
|
+
}
|
|
20007
|
+
if (!validMinValue(min, val.length)) {
|
|
20008
|
+
return false;
|
|
20009
|
+
}
|
|
20010
|
+
if (!validMaxValue(max, val.length)) {
|
|
20011
|
+
return false;
|
|
20012
|
+
}
|
|
20013
|
+
} else if (isNumType) {
|
|
20014
|
+
const numVal = Number(val);
|
|
20015
|
+
if (isNaN(numVal)) {
|
|
20016
|
+
return false;
|
|
20017
|
+
}
|
|
20018
|
+
if (!validMinValue(min, numVal)) {
|
|
20019
|
+
return false;
|
|
20020
|
+
}
|
|
20021
|
+
if (!validMaxValue(max, numVal)) {
|
|
20022
|
+
return false;
|
|
20023
|
+
}
|
|
20024
|
+
} else {
|
|
20025
|
+
if (isStrType) {
|
|
20026
|
+
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(val)) {
|
|
20027
|
+
return false;
|
|
20028
|
+
}
|
|
20029
|
+
}
|
|
20030
|
+
if (required) {
|
|
20031
|
+
if (!strVal) {
|
|
20032
|
+
return false;
|
|
20033
|
+
}
|
|
20034
|
+
}
|
|
20035
|
+
if (!validMinValue(min, strVal.length)) {
|
|
20036
|
+
return false;
|
|
20037
|
+
}
|
|
20038
|
+
if (!validMaxValue(max, strVal.length)) {
|
|
20039
|
+
return false;
|
|
20040
|
+
}
|
|
19987
20041
|
}
|
|
19988
|
-
|
|
19989
|
-
|
|
19990
|
-
|
|
20042
|
+
return true;
|
|
20043
|
+
}
|
|
20044
|
+
function checkRuleStatus(rule, val) {
|
|
20045
|
+
const {
|
|
20046
|
+
required
|
|
20047
|
+
} = rule;
|
|
20048
|
+
const isEmptyVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(val);
|
|
20049
|
+
if (required) {
|
|
20050
|
+
if (isEmptyVal) {
|
|
20051
|
+
return false;
|
|
20052
|
+
}
|
|
20053
|
+
if (!validRuleValue(rule, val, required)) {
|
|
20054
|
+
return false;
|
|
20055
|
+
}
|
|
20056
|
+
} else {
|
|
20057
|
+
if (!isEmptyVal) {
|
|
20058
|
+
if (!validRuleValue(rule, val, required)) {
|
|
20059
|
+
return false;
|
|
20060
|
+
}
|
|
20061
|
+
}
|
|
19991
20062
|
}
|
|
19992
|
-
return
|
|
19993
|
-
}
|
|
20063
|
+
return true;
|
|
20064
|
+
}
|
|
19994
20065
|
/* harmony default export */ var src_form = ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
|
|
19995
20066
|
name: 'VxeForm',
|
|
19996
20067
|
props: {
|
|
@@ -20368,9 +20439,7 @@ const validErrorRuleValue = (rule, val) => {
|
|
|
20368
20439
|
const itemValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isUndefined(val) ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(data, property) : val;
|
|
20369
20440
|
rules.forEach(rule => {
|
|
20370
20441
|
const {
|
|
20371
|
-
type,
|
|
20372
20442
|
trigger,
|
|
20373
|
-
required,
|
|
20374
20443
|
validator
|
|
20375
20444
|
} = rule;
|
|
20376
20445
|
if (validType === 'all' || !trigger || validType === trigger) {
|
|
@@ -20392,14 +20461,10 @@ const validErrorRuleValue = (rule, val) => {
|
|
|
20392
20461
|
if (validatorMethod) {
|
|
20393
20462
|
customValid = validatorMethod(validParams);
|
|
20394
20463
|
} else {
|
|
20395
|
-
|
|
20396
|
-
warnLog('vxe.error.notValidators', [validator]);
|
|
20397
|
-
}
|
|
20464
|
+
warnLog('vxe.error.notValidators', [validator]);
|
|
20398
20465
|
}
|
|
20399
20466
|
} else {
|
|
20400
|
-
|
|
20401
|
-
errLog('vxe.error.notValidators', [validator]);
|
|
20402
|
-
}
|
|
20467
|
+
errLog('vxe.error.notValidators', [validator]);
|
|
20403
20468
|
}
|
|
20404
20469
|
} else {
|
|
20405
20470
|
customValid = validator(validParams);
|
|
@@ -20425,17 +20490,7 @@ const validErrorRuleValue = (rule, val) => {
|
|
|
20425
20490
|
}
|
|
20426
20491
|
}
|
|
20427
20492
|
} else {
|
|
20428
|
-
|
|
20429
|
-
const isArrVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(itemValue);
|
|
20430
|
-
let hasEmpty = true;
|
|
20431
|
-
if (isArrType || isArrVal) {
|
|
20432
|
-
hasEmpty = !isArrVal || !itemValue.length;
|
|
20433
|
-
} else if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(itemValue)) {
|
|
20434
|
-
hasEmpty = eqEmptyValue(itemValue.trim());
|
|
20435
|
-
} else {
|
|
20436
|
-
hasEmpty = eqEmptyValue(itemValue);
|
|
20437
|
-
}
|
|
20438
|
-
if (required ? hasEmpty || validErrorRuleValue(rule, itemValue) : !hasEmpty && validErrorRuleValue(rule, itemValue)) {
|
|
20493
|
+
if (!checkRuleStatus(rule, itemValue)) {
|
|
20439
20494
|
errorRules.push(new Rule(rule));
|
|
20440
20495
|
}
|
|
20441
20496
|
}
|
|
@@ -20900,10 +20955,8 @@ function getComponentOns(renderOpts, params, eFns, eventOns) {
|
|
|
20900
20955
|
const ons = {};
|
|
20901
20956
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().objectEach(events, (func, key) => {
|
|
20902
20957
|
ons[getOnName(key)] = function (...args) {
|
|
20903
|
-
if (
|
|
20904
|
-
|
|
20905
|
-
errLog('vxe.error.errFunc', [func]);
|
|
20906
|
-
}
|
|
20958
|
+
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
|
|
20959
|
+
errLog('vxe.error.errFunc', [func]);
|
|
20907
20960
|
}
|
|
20908
20961
|
func(params, ...args);
|
|
20909
20962
|
};
|
|
@@ -22606,15 +22659,11 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22606
22659
|
return handlePrevNext(true);
|
|
22607
22660
|
},
|
|
22608
22661
|
prevTab() {
|
|
22609
|
-
|
|
22610
|
-
warnLog('vxe.error.delFunc', ['prevTab', 'prev']);
|
|
22611
|
-
}
|
|
22662
|
+
warnLog('vxe.error.delFunc', ['prevTab', 'prev']);
|
|
22612
22663
|
return tabsMethods.prev();
|
|
22613
22664
|
},
|
|
22614
22665
|
nextTab() {
|
|
22615
|
-
|
|
22616
|
-
warnLog('vxe.error.delFunc', ['nextTab', 'next']);
|
|
22617
|
-
}
|
|
22666
|
+
warnLog('vxe.error.delFunc', ['nextTab', 'next']);
|
|
22618
22667
|
return tabsMethods.next();
|
|
22619
22668
|
}
|
|
22620
22669
|
};
|
|
@@ -22648,7 +22697,7 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22648
22697
|
onClick: scrollLeftEvent
|
|
22649
22698
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
22650
22699
|
class: getIcon().TABS_TAB_BUTTON_LEFT
|
|
22651
|
-
})]) : (
|
|
22700
|
+
})]) : renderEmptyElement($xeTabs), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
22652
22701
|
class: 'vxe-tabs-header--wrapper'
|
|
22653
22702
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
22654
22703
|
ref: refHeadWrapperElem,
|
|
@@ -22693,7 +22742,7 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22693
22742
|
class: 'vxe-tabs-header--item-icon'
|
|
22694
22743
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
22695
22744
|
class: icon
|
|
22696
|
-
})]) : (
|
|
22745
|
+
})]) : renderEmptyElement($xeTabs), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
22697
22746
|
class: 'vxe-tabs-header--item-name'
|
|
22698
22747
|
}, titleSlot ? callSlot(titleSlot, {
|
|
22699
22748
|
name,
|
|
@@ -22705,14 +22754,14 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22705
22754
|
}
|
|
22706
22755
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
22707
22756
|
class: isLoading ? getIcon().TABS_TAB_REFRESH_LOADING : getIcon().TABS_TAB_REFRESH
|
|
22708
|
-
})]) : (
|
|
22757
|
+
})]) : renderEmptyElement($xeTabs), (showClose || isEnableConf(closeConfig) || closeOpts.enabled) && (!closeVisibleMethod || closeVisibleMethod(params)) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
22709
22758
|
class: 'vxe-tabs-header--close-btn',
|
|
22710
22759
|
onClick(evnt) {
|
|
22711
22760
|
handleCloseTabEvent(evnt, item, index, tabList);
|
|
22712
22761
|
}
|
|
22713
22762
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
22714
22763
|
class: getIcon().TABS_TAB_CLOSE
|
|
22715
|
-
})]) : (
|
|
22764
|
+
})]) : renderEmptyElement($xeTabs)])]);
|
|
22716
22765
|
}).concat([(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
22717
22766
|
key: 'line',
|
|
22718
22767
|
class: `vxe-tabs-header--active-line type--${type || 'default'}`,
|
|
@@ -22725,9 +22774,9 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22725
22774
|
onClick: scrollRightEvent
|
|
22726
22775
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
22727
22776
|
class: getIcon().TABS_TAB_BUTTON_RIGHT
|
|
22728
|
-
})]) : (
|
|
22777
|
+
})]) : renderEmptyElement($xeTabs), extraSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
22729
22778
|
class: 'vxe-tabs-header--extra'
|
|
22730
|
-
}, getSlotVNs(extraSlot({}))) : (
|
|
22779
|
+
}, getSlotVNs(extraSlot({}))) : renderEmptyElement($xeTabs)]);
|
|
22731
22780
|
};
|
|
22732
22781
|
const renderTabPane = item => {
|
|
22733
22782
|
const {
|
|
@@ -22747,7 +22796,7 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22747
22796
|
}]
|
|
22748
22797
|
}, defaultSlot ? callSlot(defaultSlot, {
|
|
22749
22798
|
name
|
|
22750
|
-
}) : []) : (
|
|
22799
|
+
}) : []) : renderEmptyElement($xeTabs);
|
|
22751
22800
|
};
|
|
22752
22801
|
const renderTabContent = tabList => {
|
|
22753
22802
|
const {
|
|
@@ -22758,7 +22807,7 @@ const ViewItemComponent = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defin
|
|
|
22758
22807
|
} = reactData;
|
|
22759
22808
|
const activeDefaultTab = tabList.find(item => item.name === activeName);
|
|
22760
22809
|
if (destroyOnClose) {
|
|
22761
|
-
return [activeDefaultTab ? renderTabPane(activeDefaultTab) : (
|
|
22810
|
+
return [activeDefaultTab ? renderTabPane(activeDefaultTab) : renderEmptyElement($xeTabs)];
|
|
22762
22811
|
}
|
|
22763
22812
|
return tabList.map(item => renderTabPane(item));
|
|
22764
22813
|
};
|
|
@@ -23057,6 +23106,7 @@ const formItemProps = {
|
|
|
23057
23106
|
setup(props, {
|
|
23058
23107
|
slots
|
|
23059
23108
|
}) {
|
|
23109
|
+
const xID = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId();
|
|
23060
23110
|
const refElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
23061
23111
|
const $xeForm = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeForm', {});
|
|
23062
23112
|
const $xeFormGroup = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeFormGroup', null);
|
|
@@ -23095,14 +23145,14 @@ const formItemProps = {
|
|
|
23095
23145
|
$grid: $xeGrid
|
|
23096
23146
|
};
|
|
23097
23147
|
if (visible === false) {
|
|
23098
|
-
return (
|
|
23148
|
+
return renderEmptyElement($xeFormitem);
|
|
23099
23149
|
}
|
|
23100
23150
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
23101
23151
|
ref: refElem,
|
|
23102
23152
|
key: item.id,
|
|
23103
23153
|
class: getItemClass($xeForm, item),
|
|
23104
23154
|
style: external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(itemStyle) ? itemStyle(params) : itemStyle
|
|
23105
|
-
}, [renderTitle($xeForm, item), showContent === false ? (
|
|
23155
|
+
}, [renderTitle($xeForm, item), showContent === false ? renderEmptyElement($xeFormitem) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
23106
23156
|
class: getItemContentClass($xeForm, item),
|
|
23107
23157
|
style: Object.assign({}, external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(itemContentStyle) ? itemContentStyle(params) : itemContentStyle, external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(contentStyle) ? contentStyle(params) : contentStyle)
|
|
23108
23158
|
}, [renderItemContent($xeForm, item)])]);
|
|
@@ -23115,6 +23165,7 @@ const formItemProps = {
|
|
|
23115
23165
|
});
|
|
23116
23166
|
};
|
|
23117
23167
|
const $xeFormitem = {
|
|
23168
|
+
xID,
|
|
23118
23169
|
formItem,
|
|
23119
23170
|
renderVN
|
|
23120
23171
|
};
|
|
@@ -23323,11 +23374,11 @@ const formItemProps = {
|
|
|
23323
23374
|
class: 'vxe-switch--label vxe-switch--label-on'
|
|
23324
23375
|
}, [openIcon ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
23325
23376
|
class: ['vxe-switch--label-icon', openIcon]
|
|
23326
|
-
}) : (
|
|
23377
|
+
}) : renderEmptyElement($xeSwitch), onShowLabel]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
23327
23378
|
class: 'vxe-switch--label vxe-switch--label-off'
|
|
23328
23379
|
}, [closeIcon ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
23329
23380
|
class: ['vxe-switch--label-icon', closeIcon]
|
|
23330
|
-
}) : (
|
|
23381
|
+
}) : renderEmptyElement($xeSwitch), offShowLabel]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
23331
23382
|
class: ['vxe-switch--icon']
|
|
23332
23383
|
}, openActiveIcon || closeActiveIcon ? [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
23333
23384
|
class: isChecked ? openActiveIcon : closeActiveIcon
|
|
@@ -24739,25 +24790,25 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24739
24790
|
class: 'vxe-modal--corner-wrapper'
|
|
24740
24791
|
}, getSlotVNs(cornerSlot({
|
|
24741
24792
|
$modal: $xeModal
|
|
24742
|
-
}))) : (
|
|
24793
|
+
}))) : renderEmptyElement($xeModal), (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(showMinimize) ? showMinimize : showZoom) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24743
24794
|
class: ['vxe-modal--zoom-btn', 'trigger--btn'],
|
|
24744
24795
|
title: i18n_getI18n(`vxe.modal.zoom${zoomStatus === 'minimize' ? 'Out' : 'Min'}`),
|
|
24745
24796
|
onClick: toggleZoomMinEvent
|
|
24746
24797
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
24747
24798
|
class: zoomStatus === 'minimize' ? getIcon().MODAL_ZOOM_REVERT : getIcon().MODAL_ZOOM_MIN
|
|
24748
|
-
})]) : (
|
|
24799
|
+
})]) : renderEmptyElement($xeModal), (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(showMaximize) ? showMaximize : showZoom) && zoomStatus !== 'minimize' ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24749
24800
|
class: ['vxe-modal--zoom-btn', 'trigger--btn'],
|
|
24750
24801
|
title: i18n_getI18n(`vxe.modal.zoom${zoomStatus === 'maximize' ? 'Out' : 'In'}`),
|
|
24751
24802
|
onClick: toggleZoomMaxEvent
|
|
24752
24803
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
24753
24804
|
class: zoomStatus === 'maximize' ? getIcon().MODAL_ZOOM_OUT : getIcon().MODAL_ZOOM_IN
|
|
24754
|
-
})]) : (
|
|
24805
|
+
})]) : renderEmptyElement($xeModal), showClose ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24755
24806
|
class: ['vxe-modal--close-btn', 'trigger--btn'],
|
|
24756
24807
|
title: i18n_getI18n('vxe.modal.close'),
|
|
24757
24808
|
onClick: closeEvent
|
|
24758
24809
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
24759
24810
|
class: getIcon().MODAL_CLOSE
|
|
24760
|
-
})]) : (
|
|
24811
|
+
})]) : renderEmptyElement($xeModal)])];
|
|
24761
24812
|
};
|
|
24762
24813
|
const renderHeader = () => {
|
|
24763
24814
|
const {
|
|
@@ -24785,7 +24836,7 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24785
24836
|
$modal: $xeModal
|
|
24786
24837
|
})) : renderTitles());
|
|
24787
24838
|
}
|
|
24788
|
-
return (
|
|
24839
|
+
return renderEmptyElement($xeModal);
|
|
24789
24840
|
};
|
|
24790
24841
|
const renderBody = () => {
|
|
24791
24842
|
const {
|
|
@@ -24818,13 +24869,13 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24818
24869
|
class: 'vxe-modal--body-left'
|
|
24819
24870
|
}, getSlotVNs(leftSlot({
|
|
24820
24871
|
$modal: $xeModal
|
|
24821
|
-
}))) : (
|
|
24872
|
+
}))) : renderEmptyElement($xeModal), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24822
24873
|
class: 'vxe-modal--body-default'
|
|
24823
24874
|
}, contVNs), rightSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24824
24875
|
class: 'vxe-modal--body-right'
|
|
24825
24876
|
}, getSlotVNs(rightSlot({
|
|
24826
24877
|
$modal: $xeModal
|
|
24827
|
-
}))) : (
|
|
24878
|
+
}))) : renderEmptyElement($xeModal), isMsg ? renderEmptyElement($xeModal) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(loading, {
|
|
24828
24879
|
class: 'vxe-modal--loading',
|
|
24829
24880
|
modelValue: props.loading
|
|
24830
24881
|
})]);
|
|
@@ -24882,7 +24933,7 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24882
24933
|
$modal: $xeModal
|
|
24883
24934
|
})) : [renderDefaultFooter()]);
|
|
24884
24935
|
}
|
|
24885
|
-
return (
|
|
24936
|
+
return renderEmptyElement($xeModal);
|
|
24886
24937
|
};
|
|
24887
24938
|
const renderVN = () => {
|
|
24888
24939
|
const {
|
|
@@ -24956,7 +25007,7 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24956
25007
|
class: 'vxe-modal--status-wrapper'
|
|
24957
25008
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
24958
25009
|
class: ['vxe-modal--status-icon', iconStatus || getIcon()[`MODAL_${status}`.toLocaleUpperCase()]]
|
|
24959
|
-
})]) : (
|
|
25010
|
+
})]) : renderEmptyElement($xeModal)]) : renderEmptyElement($xeModal), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
24960
25011
|
class: 'vxe-modal--container'
|
|
24961
25012
|
}, !reactData.initialized || destroyOnClose && !reactData.visible ? [] : [renderHeader(), renderBody(), renderFooter(), !isMsg && resize ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
24962
25013
|
class: 'vxe-modal--resize'
|
|
@@ -24966,7 +25017,7 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24966
25017
|
type: type,
|
|
24967
25018
|
onMousedown: dragEvent
|
|
24968
25019
|
});
|
|
24969
|
-
})) : (
|
|
25020
|
+
})) : renderEmptyElement($xeModal)])])])]);
|
|
24970
25021
|
};
|
|
24971
25022
|
$xeModal.renderVN = renderVN;
|
|
24972
25023
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.width, recalculate);
|
|
@@ -24979,10 +25030,8 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
|
|
|
24979
25030
|
}
|
|
24980
25031
|
});
|
|
24981
25032
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
24982
|
-
if (
|
|
24983
|
-
|
|
24984
|
-
warnLog('vxe.modal.footPropErr');
|
|
24985
|
-
}
|
|
25033
|
+
if (props.type === 'modal' && props.showFooter && !(props.showConfirmButton || props.showCancelButton || slots.footer)) {
|
|
25034
|
+
warnLog('vxe.modal.footPropErr');
|
|
24986
25035
|
}
|
|
24987
25036
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
24988
25037
|
if (props.storage && !props.id) {
|
|
@@ -25068,6 +25117,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25068
25117
|
const {
|
|
25069
25118
|
slots
|
|
25070
25119
|
} = context;
|
|
25120
|
+
const xID = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId();
|
|
25071
25121
|
const refElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25072
25122
|
const $xeForm = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeForm', {});
|
|
25073
25123
|
const $xeParentFormGroup = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeFormGroup', null);
|
|
@@ -25108,7 +25158,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25108
25158
|
$grid: $xeGrid
|
|
25109
25159
|
};
|
|
25110
25160
|
if (visible === false) {
|
|
25111
|
-
return (
|
|
25161
|
+
return renderEmptyElement($xeFormGroup);
|
|
25112
25162
|
}
|
|
25113
25163
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
25114
25164
|
ref: refElem,
|
|
@@ -25121,6 +25171,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25121
25171
|
}, defaultSlot ? defaultSlot({}) : [])]);
|
|
25122
25172
|
};
|
|
25123
25173
|
const $xeFormGroup = {
|
|
25174
|
+
xID,
|
|
25124
25175
|
formItem,
|
|
25125
25176
|
renderVN
|
|
25126
25177
|
};
|
|
@@ -25413,9 +25464,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25413
25464
|
* @deprecated
|
|
25414
25465
|
*/
|
|
25415
25466
|
updateItemStatus(widget, value) {
|
|
25416
|
-
|
|
25417
|
-
warnLog('vxe.error.delFunc', ['updateItemStatus', 'updateWidgetStatus']);
|
|
25418
|
-
}
|
|
25467
|
+
warnLog('vxe.error.delFunc', ['updateItemStatus', 'updateWidgetStatus']);
|
|
25419
25468
|
return updateWidgetStatus(widget, value);
|
|
25420
25469
|
}
|
|
25421
25470
|
};
|
|
@@ -25452,7 +25501,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25452
25501
|
class: 'vxe-form-view--top'
|
|
25453
25502
|
}, getSlotVNs(topSlot({
|
|
25454
25503
|
$formView: $xeFormView
|
|
25455
|
-
}))) : (
|
|
25504
|
+
}))) : renderEmptyElement($xeFormView), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(src_form, {
|
|
25456
25505
|
ref: formRef,
|
|
25457
25506
|
...formConfig,
|
|
25458
25507
|
data: modelValue,
|
|
@@ -25473,7 +25522,7 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25473
25522
|
default() {
|
|
25474
25523
|
return headerSlot({});
|
|
25475
25524
|
}
|
|
25476
|
-
}) : (
|
|
25525
|
+
}) : renderEmptyElement($xeFormView), ...widgetObjList.map(widget => {
|
|
25477
25526
|
const {
|
|
25478
25527
|
name
|
|
25479
25528
|
} = widget;
|
|
@@ -25517,13 +25566,13 @@ const createDefaultFormViewMobileFormConfig = params => {
|
|
|
25517
25566
|
default() {
|
|
25518
25567
|
return footerSlot({});
|
|
25519
25568
|
}
|
|
25520
|
-
}) : (
|
|
25569
|
+
}) : renderEmptyElement($xeFormView)];
|
|
25521
25570
|
}
|
|
25522
25571
|
}), bottomSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
25523
25572
|
class: 'vxe-form-view--bottom'
|
|
25524
25573
|
}, getSlotVNs(bottomSlot({
|
|
25525
25574
|
$formView: $xeFormView
|
|
25526
|
-
}))) : (
|
|
25575
|
+
}))) : renderEmptyElement($xeFormView)]);
|
|
25527
25576
|
};
|
|
25528
25577
|
$xeFormView.renderVN = renderVN;
|
|
25529
25578
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.config, value => {
|
|
@@ -28957,7 +29006,7 @@ let autoTxtElem;
|
|
|
28957
29006
|
const permissionInfo = computePermissionInfo.value;
|
|
28958
29007
|
const vSize = computeSize.value;
|
|
28959
29008
|
if (!permissionInfo.visible) {
|
|
28960
|
-
return (
|
|
29009
|
+
return renderEmptyElement($xeTip);
|
|
28961
29010
|
}
|
|
28962
29011
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
28963
29012
|
ref: refElem,
|
|
@@ -28970,11 +29019,11 @@ let autoTxtElem;
|
|
|
28970
29019
|
class: 'vxe-tip--icon'
|
|
28971
29020
|
}, iconSlot ? getSlotVNs(iconSlot({})) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
28972
29021
|
class: icon
|
|
28973
|
-
})]) : (
|
|
29022
|
+
})]) : renderEmptyElement($xeTip), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
28974
29023
|
class: 'vxe-tip--body'
|
|
28975
29024
|
}, [titleSlot || title ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
28976
29025
|
class: 'vxe-tip--title'
|
|
28977
|
-
}, titleSlot ? getSlotVNs(titleSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(title)) : (
|
|
29026
|
+
}, titleSlot ? getSlotVNs(titleSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(title)) : renderEmptyElement($xeTip), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
28978
29027
|
class: 'vxe-tip--content'
|
|
28979
29028
|
}, defaultSlot ? getSlotVNs(defaultSlot({})) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(content))])]);
|
|
28980
29029
|
};
|
|
@@ -33511,10 +33560,10 @@ function getNodeUniqueId() {
|
|
|
33511
33560
|
type: String,
|
|
33512
33561
|
default: () => getConfig().tree.hasChildField
|
|
33513
33562
|
},
|
|
33514
|
-
|
|
33515
|
-
|
|
33516
|
-
|
|
33517
|
-
|
|
33563
|
+
mapChildrenField: {
|
|
33564
|
+
type: String,
|
|
33565
|
+
default: () => getConfig().tree.mapChildrenField
|
|
33566
|
+
},
|
|
33518
33567
|
transform: Boolean,
|
|
33519
33568
|
// 已废弃
|
|
33520
33569
|
isCurrent: Boolean,
|
|
@@ -33586,16 +33635,18 @@ function getNodeUniqueId() {
|
|
|
33586
33635
|
const refElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
33587
33636
|
const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({
|
|
33588
33637
|
currentNode: null,
|
|
33589
|
-
nodeMaps: {},
|
|
33590
33638
|
selectRadioKey: props.checkNodeKey,
|
|
33591
33639
|
treeList: [],
|
|
33592
|
-
|
|
33593
|
-
|
|
33594
|
-
selectCheckboxMaps: {},
|
|
33595
|
-
indeterminateCheckboxMaps: {}
|
|
33640
|
+
updateExpandedFlag: 1,
|
|
33641
|
+
updateCheckboxFlag: 1
|
|
33596
33642
|
});
|
|
33597
33643
|
const internalData = {
|
|
33598
|
-
// initialized: false
|
|
33644
|
+
// initialized: false,
|
|
33645
|
+
nodeMaps: {},
|
|
33646
|
+
selectCheckboxMaps: {},
|
|
33647
|
+
indeterminateRowMaps: {},
|
|
33648
|
+
treeExpandedMaps: {},
|
|
33649
|
+
treeExpandLazyLoadedMaps: {}
|
|
33599
33650
|
};
|
|
33600
33651
|
const refMaps = {
|
|
33601
33652
|
refElem
|
|
@@ -33616,6 +33667,9 @@ function getNodeUniqueId() {
|
|
|
33616
33667
|
const computeChildrenField = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
33617
33668
|
return props.childrenField || 'children';
|
|
33618
33669
|
});
|
|
33670
|
+
const computeMapChildrenField = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
33671
|
+
return props.mapChildrenField || 'mapChildren';
|
|
33672
|
+
});
|
|
33619
33673
|
const computeHasChildField = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
33620
33674
|
return props.hasChildField || 'hasChild';
|
|
33621
33675
|
});
|
|
@@ -33690,10 +33744,13 @@ function getNodeUniqueId() {
|
|
|
33690
33744
|
};
|
|
33691
33745
|
const isExpandByNode = node => {
|
|
33692
33746
|
const {
|
|
33693
|
-
|
|
33747
|
+
updateExpandedFlag
|
|
33694
33748
|
} = reactData;
|
|
33749
|
+
const {
|
|
33750
|
+
treeExpandedMaps
|
|
33751
|
+
} = internalData;
|
|
33695
33752
|
const nodeid = getNodeId(node);
|
|
33696
|
-
return !!treeExpandedMaps[nodeid];
|
|
33753
|
+
return !!(updateExpandedFlag && treeExpandedMaps[nodeid]);
|
|
33697
33754
|
};
|
|
33698
33755
|
const isCheckedByRadioNodeId = nodeid => {
|
|
33699
33756
|
const {
|
|
@@ -33706,18 +33763,24 @@ function getNodeUniqueId() {
|
|
|
33706
33763
|
};
|
|
33707
33764
|
const isCheckedByCheckboxNodeId = nodeid => {
|
|
33708
33765
|
const {
|
|
33709
|
-
|
|
33766
|
+
updateCheckboxFlag
|
|
33710
33767
|
} = reactData;
|
|
33711
|
-
|
|
33768
|
+
const {
|
|
33769
|
+
selectCheckboxMaps
|
|
33770
|
+
} = internalData;
|
|
33771
|
+
return !!(updateCheckboxFlag && selectCheckboxMaps[nodeid]);
|
|
33712
33772
|
};
|
|
33713
33773
|
const isCheckedByCheckboxNode = node => {
|
|
33714
33774
|
return isCheckedByCheckboxNodeId(getNodeId(node));
|
|
33715
33775
|
};
|
|
33716
33776
|
const isIndeterminateByCheckboxNodeid = nodeid => {
|
|
33717
33777
|
const {
|
|
33718
|
-
|
|
33778
|
+
updateCheckboxFlag
|
|
33719
33779
|
} = reactData;
|
|
33720
|
-
|
|
33780
|
+
const {
|
|
33781
|
+
indeterminateRowMaps
|
|
33782
|
+
} = internalData;
|
|
33783
|
+
return !!(updateCheckboxFlag && indeterminateRowMaps[nodeid]);
|
|
33721
33784
|
};
|
|
33722
33785
|
const isIndeterminateByCheckboxNode = node => {
|
|
33723
33786
|
return isIndeterminateByCheckboxNodeid(getNodeId(node));
|
|
@@ -33739,38 +33802,66 @@ function getNodeUniqueId() {
|
|
|
33739
33802
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodeList)) {
|
|
33740
33803
|
nodeList = [nodeList];
|
|
33741
33804
|
}
|
|
33742
|
-
handleCheckedCheckboxNode(nodeList
|
|
33805
|
+
handleCheckedCheckboxNode(nodeList, checked);
|
|
33743
33806
|
}
|
|
33744
33807
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33745
33808
|
};
|
|
33746
33809
|
const setCheckboxByNodeId = (nodeIds, checked) => {
|
|
33810
|
+
const {
|
|
33811
|
+
nodeMaps
|
|
33812
|
+
} = internalData;
|
|
33747
33813
|
if (nodeIds) {
|
|
33748
33814
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodeIds)) {
|
|
33749
33815
|
nodeIds = [nodeIds];
|
|
33750
33816
|
}
|
|
33751
|
-
|
|
33817
|
+
const nodeList = [];
|
|
33818
|
+
nodeIds.forEach(nodeid => {
|
|
33819
|
+
const nodeItem = nodeMaps[nodeid];
|
|
33820
|
+
if (nodeItem) {
|
|
33821
|
+
nodeList.push(nodeItem.item);
|
|
33822
|
+
}
|
|
33823
|
+
});
|
|
33824
|
+
handleCheckedCheckboxNode(nodeList, checked);
|
|
33752
33825
|
}
|
|
33753
33826
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33754
33827
|
};
|
|
33755
|
-
const handleCheckedCheckboxNode = (
|
|
33756
|
-
const
|
|
33757
|
-
|
|
33828
|
+
const handleCheckedCheckboxNode = (nodeList, checked) => {
|
|
33829
|
+
const {
|
|
33830
|
+
transform
|
|
33831
|
+
} = props;
|
|
33832
|
+
const {
|
|
33833
|
+
selectCheckboxMaps
|
|
33834
|
+
} = internalData;
|
|
33835
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
33836
|
+
const childrenField = computeChildrenField.value;
|
|
33837
|
+
const checkboxOpts = computeCheckboxOpts.value;
|
|
33838
|
+
const {
|
|
33839
|
+
checkStrictly
|
|
33840
|
+
} = checkboxOpts;
|
|
33841
|
+
const handleSelect = node => {
|
|
33842
|
+
const nodeid = getNodeId(node);
|
|
33758
33843
|
if (checked) {
|
|
33759
|
-
|
|
33760
|
-
|
|
33761
|
-
|
|
33844
|
+
if (!selectCheckboxMaps[nodeid]) {
|
|
33845
|
+
selectCheckboxMaps[nodeid] = node;
|
|
33846
|
+
}
|
|
33847
|
+
} else {
|
|
33848
|
+
if (selectCheckboxMaps[nodeid]) {
|
|
33849
|
+
delete selectCheckboxMaps[nodeid];
|
|
33850
|
+
}
|
|
33762
33851
|
}
|
|
33763
|
-
}
|
|
33764
|
-
|
|
33765
|
-
|
|
33766
|
-
|
|
33767
|
-
|
|
33768
|
-
|
|
33769
|
-
nodeIds.forEach(key => {
|
|
33770
|
-
selectKeyMaps[key] = true;
|
|
33852
|
+
};
|
|
33853
|
+
if (checkStrictly) {
|
|
33854
|
+
nodeList.forEach(handleSelect);
|
|
33855
|
+
} else {
|
|
33856
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(nodeList, handleSelect, {
|
|
33857
|
+
children: transform ? mapChildrenField : childrenField
|
|
33771
33858
|
});
|
|
33772
33859
|
}
|
|
33773
|
-
reactData.
|
|
33860
|
+
reactData.updateCheckboxFlag++;
|
|
33861
|
+
updateCheckboxStatus();
|
|
33862
|
+
};
|
|
33863
|
+
const updateCheckboxChecked = nodeIds => {
|
|
33864
|
+
setCheckboxByNodeId(nodeIds, true);
|
|
33774
33865
|
};
|
|
33775
33866
|
const handleSetExpand = (nodeid, expanded, expandedMaps) => {
|
|
33776
33867
|
if (expanded) {
|
|
@@ -33819,9 +33910,11 @@ function getNodeUniqueId() {
|
|
|
33819
33910
|
},
|
|
33820
33911
|
getCurrentNode() {
|
|
33821
33912
|
const {
|
|
33822
|
-
currentNode
|
|
33823
|
-
nodeMaps
|
|
33913
|
+
currentNode
|
|
33824
33914
|
} = reactData;
|
|
33915
|
+
const {
|
|
33916
|
+
nodeMaps
|
|
33917
|
+
} = internalData;
|
|
33825
33918
|
if (currentNode) {
|
|
33826
33919
|
const nodeItem = nodeMaps[getNodeId(currentNode)];
|
|
33827
33920
|
if (nodeItem) {
|
|
@@ -33833,7 +33926,7 @@ function getNodeUniqueId() {
|
|
|
33833
33926
|
setCurrentNodeId(nodeKey) {
|
|
33834
33927
|
const {
|
|
33835
33928
|
nodeMaps
|
|
33836
|
-
} =
|
|
33929
|
+
} = internalData;
|
|
33837
33930
|
const nodeItem = nodeMaps[nodeKey];
|
|
33838
33931
|
reactData.currentNode = nodeItem ? nodeItem.item : null;
|
|
33839
33932
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
@@ -33851,9 +33944,11 @@ function getNodeUniqueId() {
|
|
|
33851
33944
|
},
|
|
33852
33945
|
getRadioNode() {
|
|
33853
33946
|
const {
|
|
33854
|
-
selectRadioKey
|
|
33855
|
-
nodeMaps
|
|
33947
|
+
selectRadioKey
|
|
33856
33948
|
} = reactData;
|
|
33949
|
+
const {
|
|
33950
|
+
nodeMaps
|
|
33951
|
+
} = internalData;
|
|
33857
33952
|
if (selectRadioKey) {
|
|
33858
33953
|
const nodeItem = nodeMaps[selectRadioKey];
|
|
33859
33954
|
if (nodeItem) {
|
|
@@ -33872,14 +33967,14 @@ function getNodeUniqueId() {
|
|
|
33872
33967
|
getCheckboxNodeIds() {
|
|
33873
33968
|
const {
|
|
33874
33969
|
selectCheckboxMaps
|
|
33875
|
-
} =
|
|
33970
|
+
} = internalData;
|
|
33876
33971
|
return Object.keys(selectCheckboxMaps);
|
|
33877
33972
|
},
|
|
33878
33973
|
getCheckboxNodes() {
|
|
33879
33974
|
const {
|
|
33880
33975
|
nodeMaps,
|
|
33881
33976
|
selectCheckboxMaps
|
|
33882
|
-
} =
|
|
33977
|
+
} = internalData;
|
|
33883
33978
|
const list = [];
|
|
33884
33979
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(selectCheckboxMaps, (item, nodeid) => {
|
|
33885
33980
|
const nodeItem = nodeMaps[nodeid];
|
|
@@ -33890,57 +33985,69 @@ function getNodeUniqueId() {
|
|
|
33890
33985
|
return list;
|
|
33891
33986
|
},
|
|
33892
33987
|
clearCheckboxNode() {
|
|
33893
|
-
|
|
33988
|
+
internalData.selectCheckboxMaps = {};
|
|
33989
|
+
reactData.updateCheckboxFlag++;
|
|
33894
33990
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33895
33991
|
},
|
|
33896
33992
|
setAllCheckboxNode(checked) {
|
|
33993
|
+
const {
|
|
33994
|
+
transform
|
|
33995
|
+
} = props;
|
|
33897
33996
|
const selectMaps = {};
|
|
33898
33997
|
const childrenField = computeChildrenField.value;
|
|
33998
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
33899
33999
|
if (checked) {
|
|
33900
34000
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(reactData.treeList, node => {
|
|
33901
34001
|
const nodeid = getNodeId(node);
|
|
33902
34002
|
selectMaps[nodeid] = true;
|
|
33903
34003
|
}, {
|
|
33904
|
-
children: childrenField
|
|
34004
|
+
children: transform ? mapChildrenField : childrenField
|
|
33905
34005
|
});
|
|
33906
34006
|
}
|
|
33907
|
-
|
|
34007
|
+
internalData.selectCheckboxMaps = selectMaps;
|
|
34008
|
+
reactData.updateCheckboxFlag++;
|
|
33908
34009
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33909
34010
|
},
|
|
33910
34011
|
clearExpandNode() {
|
|
33911
34012
|
return treeMethods.clearAllExpandNode();
|
|
33912
34013
|
},
|
|
33913
34014
|
clearAllExpandNode() {
|
|
33914
|
-
|
|
34015
|
+
const {
|
|
34016
|
+
nodeMaps
|
|
34017
|
+
} = internalData;
|
|
34018
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(nodeMaps, nodeItem => {
|
|
33915
34019
|
nodeItem.treeLoaded = false;
|
|
33916
34020
|
});
|
|
33917
|
-
|
|
34021
|
+
internalData.treeExpandedMaps = {};
|
|
34022
|
+
reactData.updateExpandedFlag++;
|
|
33918
34023
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33919
34024
|
},
|
|
33920
34025
|
setExpandByNodeId(nodeids, expanded) {
|
|
33921
|
-
const
|
|
34026
|
+
const {
|
|
34027
|
+
treeExpandedMaps
|
|
34028
|
+
} = internalData;
|
|
33922
34029
|
if (nodeids) {
|
|
33923
34030
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodeids)) {
|
|
33924
34031
|
nodeids = [nodeids];
|
|
33925
34032
|
}
|
|
33926
34033
|
nodeids.forEach(nodeid => {
|
|
33927
|
-
handleSetExpand(nodeid, expanded,
|
|
34034
|
+
handleSetExpand(nodeid, expanded, treeExpandedMaps);
|
|
33928
34035
|
});
|
|
33929
|
-
reactData.
|
|
34036
|
+
reactData.updateExpandedFlag++;
|
|
33930
34037
|
}
|
|
33931
34038
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33932
34039
|
},
|
|
33933
34040
|
getExpandNodeIds() {
|
|
33934
34041
|
const {
|
|
33935
34042
|
treeExpandedMaps
|
|
33936
|
-
} =
|
|
33937
|
-
return
|
|
34043
|
+
} = internalData;
|
|
34044
|
+
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().keys(treeExpandedMaps);
|
|
33938
34045
|
},
|
|
33939
34046
|
getExpandNodes() {
|
|
33940
34047
|
const {
|
|
33941
34048
|
nodeMaps,
|
|
33942
34049
|
treeExpandedMaps
|
|
33943
|
-
} =
|
|
34050
|
+
} = internalData;
|
|
33944
34051
|
const list = [];
|
|
33945
34052
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(treeExpandedMaps, (item, nodeid) => {
|
|
33946
34053
|
const nodeItem = nodeMaps[nodeid];
|
|
@@ -33951,62 +34058,74 @@ function getNodeUniqueId() {
|
|
|
33951
34058
|
return list;
|
|
33952
34059
|
},
|
|
33953
34060
|
setExpandNode(nodes, expanded) {
|
|
33954
|
-
const
|
|
34061
|
+
const {
|
|
34062
|
+
treeExpandedMaps
|
|
34063
|
+
} = internalData;
|
|
33955
34064
|
if (nodes) {
|
|
33956
34065
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodes)) {
|
|
33957
34066
|
nodes = [nodes];
|
|
33958
34067
|
}
|
|
33959
34068
|
nodes.forEach(node => {
|
|
33960
34069
|
const nodeid = getNodeId(node);
|
|
33961
|
-
handleSetExpand(nodeid, expanded,
|
|
34070
|
+
handleSetExpand(nodeid, expanded, treeExpandedMaps);
|
|
33962
34071
|
});
|
|
33963
|
-
reactData.
|
|
34072
|
+
reactData.updateExpandedFlag++;
|
|
33964
34073
|
}
|
|
33965
34074
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33966
34075
|
},
|
|
33967
34076
|
toggleExpandByNodeId(nodeids) {
|
|
33968
|
-
const
|
|
34077
|
+
const {
|
|
34078
|
+
treeExpandedMaps
|
|
34079
|
+
} = internalData;
|
|
33969
34080
|
if (nodeids) {
|
|
33970
34081
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodeids)) {
|
|
33971
34082
|
nodeids = [nodeids];
|
|
33972
34083
|
}
|
|
33973
34084
|
nodeids.forEach(nodeid => {
|
|
33974
|
-
handleSetExpand(nodeid, !
|
|
34085
|
+
handleSetExpand(nodeid, !treeExpandedMaps[nodeid], treeExpandedMaps);
|
|
33975
34086
|
});
|
|
33976
|
-
reactData.
|
|
34087
|
+
reactData.updateExpandedFlag++;
|
|
33977
34088
|
}
|
|
33978
34089
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33979
34090
|
},
|
|
33980
34091
|
toggleExpandNode(nodes) {
|
|
33981
|
-
const
|
|
34092
|
+
const {
|
|
34093
|
+
treeExpandedMaps
|
|
34094
|
+
} = internalData;
|
|
33982
34095
|
if (nodes) {
|
|
33983
34096
|
if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(nodes)) {
|
|
33984
34097
|
nodes = [nodes];
|
|
33985
34098
|
}
|
|
33986
34099
|
nodes.forEach(node => {
|
|
33987
34100
|
const nodeid = getNodeId(node);
|
|
33988
|
-
handleSetExpand(nodeid, !
|
|
34101
|
+
handleSetExpand(nodeid, !treeExpandedMaps[nodeid], treeExpandedMaps);
|
|
33989
34102
|
});
|
|
33990
|
-
reactData.
|
|
34103
|
+
reactData.updateExpandedFlag++;
|
|
33991
34104
|
}
|
|
33992
34105
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
33993
34106
|
},
|
|
33994
34107
|
setAllExpandNode(expanded) {
|
|
33995
|
-
const
|
|
34108
|
+
const {
|
|
34109
|
+
transform
|
|
34110
|
+
} = props;
|
|
34111
|
+
const {
|
|
34112
|
+
treeExpandedMaps
|
|
34113
|
+
} = internalData;
|
|
33996
34114
|
const childrenField = computeChildrenField.value;
|
|
34115
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
33997
34116
|
if (expanded) {
|
|
33998
34117
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(reactData.treeList, node => {
|
|
33999
34118
|
const childList = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(node, childrenField);
|
|
34000
34119
|
const hasChild = childList && childList.length;
|
|
34001
34120
|
if (hasChild) {
|
|
34002
34121
|
const nodeid = getNodeId(node);
|
|
34003
|
-
|
|
34122
|
+
treeExpandedMaps[nodeid] = true;
|
|
34004
34123
|
}
|
|
34005
34124
|
}, {
|
|
34006
|
-
children: childrenField
|
|
34125
|
+
children: transform ? mapChildrenField : childrenField
|
|
34007
34126
|
});
|
|
34008
34127
|
}
|
|
34009
|
-
reactData.
|
|
34128
|
+
reactData.updateExpandedFlag++;
|
|
34010
34129
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
34011
34130
|
},
|
|
34012
34131
|
reloadExpandNode(node) {
|
|
@@ -34025,7 +34144,7 @@ function getNodeUniqueId() {
|
|
|
34025
34144
|
} = props;
|
|
34026
34145
|
const {
|
|
34027
34146
|
nodeMaps
|
|
34028
|
-
} =
|
|
34147
|
+
} = internalData;
|
|
34029
34148
|
if (lazy) {
|
|
34030
34149
|
const nodeItem = nodeMaps[getNodeId(node)];
|
|
34031
34150
|
if (nodeItem) {
|
|
@@ -34044,7 +34163,7 @@ function getNodeUniqueId() {
|
|
|
34044
34163
|
} = props;
|
|
34045
34164
|
const {
|
|
34046
34165
|
nodeMaps
|
|
34047
|
-
} =
|
|
34166
|
+
} = internalData;
|
|
34048
34167
|
if (!lazy) {
|
|
34049
34168
|
return Promise.resolve([]);
|
|
34050
34169
|
}
|
|
@@ -34084,24 +34203,29 @@ function getNodeUniqueId() {
|
|
|
34084
34203
|
isCheckedByCheckboxNode,
|
|
34085
34204
|
getCheckboxIndeterminateNodes() {
|
|
34086
34205
|
const {
|
|
34087
|
-
|
|
34088
|
-
|
|
34089
|
-
} =
|
|
34090
|
-
const
|
|
34091
|
-
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().
|
|
34092
|
-
|
|
34093
|
-
|
|
34206
|
+
nodeMaps,
|
|
34207
|
+
indeterminateRowMaps
|
|
34208
|
+
} = internalData;
|
|
34209
|
+
const list = [];
|
|
34210
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(indeterminateRowMaps, (item, nodeid) => {
|
|
34211
|
+
const nodeItem = nodeMaps[nodeid];
|
|
34212
|
+
if (nodeItem) {
|
|
34213
|
+
list.push(nodeItem.item);
|
|
34094
34214
|
}
|
|
34095
34215
|
});
|
|
34096
|
-
return
|
|
34216
|
+
return list;
|
|
34097
34217
|
}
|
|
34098
34218
|
};
|
|
34099
34219
|
const cacheNodeMap = () => {
|
|
34220
|
+
const {
|
|
34221
|
+
transform
|
|
34222
|
+
} = props;
|
|
34100
34223
|
const {
|
|
34101
34224
|
treeList
|
|
34102
34225
|
} = reactData;
|
|
34103
34226
|
const valueField = computeValueField.value;
|
|
34104
34227
|
const childrenField = computeChildrenField.value;
|
|
34228
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
34105
34229
|
const keyMaps = {};
|
|
34106
34230
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(treeList, (item, itemIndex, items, path, parent, nodes) => {
|
|
34107
34231
|
let nodeid = getNodeId(item);
|
|
@@ -34120,11 +34244,11 @@ function getNodeUniqueId() {
|
|
|
34120
34244
|
treeLoaded: false
|
|
34121
34245
|
};
|
|
34122
34246
|
}, {
|
|
34123
|
-
children: childrenField
|
|
34247
|
+
children: transform ? mapChildrenField : childrenField
|
|
34124
34248
|
});
|
|
34125
|
-
|
|
34249
|
+
internalData.nodeMaps = keyMaps;
|
|
34126
34250
|
};
|
|
34127
|
-
const
|
|
34251
|
+
const loadTreeData = list => {
|
|
34128
34252
|
const {
|
|
34129
34253
|
expandAll,
|
|
34130
34254
|
transform
|
|
@@ -34134,28 +34258,31 @@ function getNodeUniqueId() {
|
|
|
34134
34258
|
} = internalData;
|
|
34135
34259
|
const keyField = computeKeyField.value;
|
|
34136
34260
|
const parentField = computeParentField.value;
|
|
34137
|
-
const
|
|
34261
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
34138
34262
|
if (transform) {
|
|
34139
34263
|
reactData.treeList = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toArrayTree(list, {
|
|
34140
34264
|
key: keyField,
|
|
34141
34265
|
parentKey: parentField,
|
|
34142
|
-
mapChildren:
|
|
34266
|
+
mapChildren: mapChildrenField
|
|
34143
34267
|
});
|
|
34144
34268
|
} else {
|
|
34145
34269
|
reactData.treeList = list ? list.slice(0) : [];
|
|
34146
34270
|
}
|
|
34147
34271
|
cacheNodeMap();
|
|
34148
|
-
if (
|
|
34272
|
+
if (!initialized) {
|
|
34149
34273
|
if (list && list.length) {
|
|
34150
34274
|
internalData.initialized = true;
|
|
34151
|
-
|
|
34275
|
+
if (expandAll) {
|
|
34276
|
+
$xeTree.setAllExpandNode(true);
|
|
34277
|
+
}
|
|
34278
|
+
$xeTree.setCheckboxByNodeId(props.checkNodeKeys || [], true);
|
|
34152
34279
|
}
|
|
34153
34280
|
}
|
|
34154
34281
|
};
|
|
34155
34282
|
const handleCountLine = (item, isRoot, nodeItem) => {
|
|
34156
34283
|
const {
|
|
34157
34284
|
treeExpandedMaps
|
|
34158
|
-
} =
|
|
34285
|
+
} = internalData;
|
|
34159
34286
|
const childrenField = computeChildrenField.value;
|
|
34160
34287
|
const nodeid = getNodeId(item);
|
|
34161
34288
|
nodeItem.lineCount++;
|
|
@@ -34170,7 +34297,7 @@ function getNodeUniqueId() {
|
|
|
34170
34297
|
const updateNodeLine = node => {
|
|
34171
34298
|
const {
|
|
34172
34299
|
nodeMaps
|
|
34173
|
-
} =
|
|
34300
|
+
} = internalData;
|
|
34174
34301
|
if (node) {
|
|
34175
34302
|
const nodeid = getNodeId(node);
|
|
34176
34303
|
const nodeItem = nodeMaps[nodeid];
|
|
@@ -34240,21 +34367,19 @@ function getNodeUniqueId() {
|
|
|
34240
34367
|
} = checkboxOpts;
|
|
34241
34368
|
return new Promise(resolve => {
|
|
34242
34369
|
if (loadMethod) {
|
|
34243
|
-
const tempExpandLazyLoadedMaps = Object.assign({}, reactData.treeExpandLazyLoadedMaps);
|
|
34244
34370
|
const {
|
|
34245
34371
|
nodeMaps
|
|
34246
|
-
} =
|
|
34372
|
+
} = internalData;
|
|
34247
34373
|
const nodeid = getNodeId(node);
|
|
34248
34374
|
const nodeItem = nodeMaps[nodeid];
|
|
34249
|
-
|
|
34250
|
-
reactData.treeExpandLazyLoadedMaps = tempExpandLazyLoadedMaps;
|
|
34375
|
+
internalData.treeExpandLazyLoadedMaps[nodeid] = true;
|
|
34251
34376
|
Promise.resolve(loadMethod({
|
|
34252
34377
|
$tree: $xeTree,
|
|
34253
34378
|
node
|
|
34254
34379
|
})).then(childRecords => {
|
|
34255
34380
|
const {
|
|
34256
34381
|
treeExpandLazyLoadedMaps
|
|
34257
|
-
} =
|
|
34382
|
+
} = internalData;
|
|
34258
34383
|
nodeItem.treeLoaded = true;
|
|
34259
34384
|
if (treeExpandLazyLoadedMaps[nodeid]) {
|
|
34260
34385
|
treeExpandLazyLoadedMaps[nodeid] = false;
|
|
@@ -34263,15 +34388,17 @@ function getNodeUniqueId() {
|
|
|
34263
34388
|
childRecords = [];
|
|
34264
34389
|
}
|
|
34265
34390
|
if (childRecords) {
|
|
34266
|
-
return
|
|
34267
|
-
const
|
|
34268
|
-
|
|
34269
|
-
|
|
34391
|
+
return $xeTree.loadChildrenNode(node, childRecords).then(childRows => {
|
|
34392
|
+
const {
|
|
34393
|
+
treeExpandedMaps
|
|
34394
|
+
} = internalData;
|
|
34395
|
+
if (childRows.length && !treeExpandedMaps[nodeid]) {
|
|
34396
|
+
treeExpandedMaps[nodeid] = true;
|
|
34270
34397
|
}
|
|
34271
|
-
reactData.
|
|
34398
|
+
reactData.updateExpandedFlag++;
|
|
34272
34399
|
// 如果当前节点已选中,则展开后子节点也被选中
|
|
34273
|
-
if (!checkStrictly &&
|
|
34274
|
-
handleCheckedCheckboxNode(childRows
|
|
34400
|
+
if (!checkStrictly && $xeTree.isCheckedByCheckboxNodeId(nodeid)) {
|
|
34401
|
+
handleCheckedCheckboxNode(childRows, true);
|
|
34275
34402
|
}
|
|
34276
34403
|
updateNodeLine(node);
|
|
34277
34404
|
dispatchEvent('load-success', {
|
|
@@ -34290,7 +34417,7 @@ function getNodeUniqueId() {
|
|
|
34290
34417
|
}).catch(e => {
|
|
34291
34418
|
const {
|
|
34292
34419
|
treeExpandLazyLoadedMaps
|
|
34293
|
-
} =
|
|
34420
|
+
} = internalData;
|
|
34294
34421
|
nodeItem.treeLoaded = false;
|
|
34295
34422
|
if (treeExpandLazyLoadedMaps[nodeid]) {
|
|
34296
34423
|
treeExpandLazyLoadedMaps[nodeid] = false;
|
|
@@ -34321,10 +34448,12 @@ function getNodeUniqueId() {
|
|
|
34321
34448
|
toggleMethod
|
|
34322
34449
|
} = props;
|
|
34323
34450
|
const {
|
|
34324
|
-
|
|
34325
|
-
|
|
34326
|
-
} =
|
|
34327
|
-
const
|
|
34451
|
+
treeExpandLazyLoadedMaps,
|
|
34452
|
+
treeExpandedMaps
|
|
34453
|
+
} = internalData;
|
|
34454
|
+
const {
|
|
34455
|
+
nodeMaps
|
|
34456
|
+
} = internalData;
|
|
34328
34457
|
const childrenField = computeChildrenField.value;
|
|
34329
34458
|
const hasChildField = computeHasChildField.value;
|
|
34330
34459
|
const result = [];
|
|
@@ -34341,8 +34470,8 @@ function getNodeUniqueId() {
|
|
|
34341
34470
|
if (nodeItem) {
|
|
34342
34471
|
nodeItem.items.forEach(item => {
|
|
34343
34472
|
const itemNodeId = getNodeId(item);
|
|
34344
|
-
if (
|
|
34345
|
-
delete
|
|
34473
|
+
if (treeExpandedMaps[itemNodeId]) {
|
|
34474
|
+
delete treeExpandedMaps[itemNodeId];
|
|
34346
34475
|
}
|
|
34347
34476
|
});
|
|
34348
34477
|
}
|
|
@@ -34351,7 +34480,7 @@ function getNodeUniqueId() {
|
|
|
34351
34480
|
if (expanded) {
|
|
34352
34481
|
validNodes.forEach(item => {
|
|
34353
34482
|
const itemNodeId = getNodeId(item);
|
|
34354
|
-
if (!
|
|
34483
|
+
if (!treeExpandedMaps[itemNodeId]) {
|
|
34355
34484
|
const nodeItem = nodeMaps[itemNodeId];
|
|
34356
34485
|
const isLoad = lazy && item[hasChildField] && !nodeItem.treeLoaded && !treeExpandLazyLoadedMaps[itemNodeId];
|
|
34357
34486
|
// 是否使用懒加载
|
|
@@ -34359,7 +34488,7 @@ function getNodeUniqueId() {
|
|
|
34359
34488
|
result.push(handleAsyncTreeExpandChilds(item));
|
|
34360
34489
|
} else {
|
|
34361
34490
|
if (item[childrenField] && item[childrenField].length) {
|
|
34362
|
-
|
|
34491
|
+
treeExpandedMaps[itemNodeId] = true;
|
|
34363
34492
|
expandNodes.push(item);
|
|
34364
34493
|
}
|
|
34365
34494
|
}
|
|
@@ -34368,13 +34497,13 @@ function getNodeUniqueId() {
|
|
|
34368
34497
|
} else {
|
|
34369
34498
|
validNodes.forEach(item => {
|
|
34370
34499
|
const itemNodeId = getNodeId(item);
|
|
34371
|
-
if (
|
|
34372
|
-
delete
|
|
34500
|
+
if (treeExpandedMaps[itemNodeId]) {
|
|
34501
|
+
delete treeExpandedMaps[itemNodeId];
|
|
34373
34502
|
expandNodes.push(item);
|
|
34374
34503
|
}
|
|
34375
34504
|
});
|
|
34376
34505
|
}
|
|
34377
|
-
reactData.
|
|
34506
|
+
reactData.updateExpandedFlag++;
|
|
34378
34507
|
expandNodes.forEach(updateNodeLine);
|
|
34379
34508
|
return Promise.all(result);
|
|
34380
34509
|
};
|
|
@@ -34385,7 +34514,7 @@ function getNodeUniqueId() {
|
|
|
34385
34514
|
const {
|
|
34386
34515
|
treeExpandedMaps,
|
|
34387
34516
|
treeExpandLazyLoadedMaps
|
|
34388
|
-
} =
|
|
34517
|
+
} = internalData;
|
|
34389
34518
|
const nodeid = getNodeId(node);
|
|
34390
34519
|
const expanded = !treeExpandedMaps[nodeid];
|
|
34391
34520
|
evnt.stopPropagation();
|
|
@@ -34393,74 +34522,107 @@ function getNodeUniqueId() {
|
|
|
34393
34522
|
handleBaseTreeExpand([node], expanded);
|
|
34394
34523
|
}
|
|
34395
34524
|
};
|
|
34396
|
-
const handleNodeCheckboxStatus = (node, selectKeyMaps, indeterminateMaps) => {
|
|
34397
|
-
const childrenField = computeChildrenField.value;
|
|
34398
|
-
const childList = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(node, childrenField);
|
|
34399
|
-
const nodeid = getNodeId(node);
|
|
34400
|
-
if (childList && childList.length) {
|
|
34401
|
-
let checkSome = false;
|
|
34402
|
-
let checkSize = 0;
|
|
34403
|
-
childList.forEach(childNode => {
|
|
34404
|
-
const childNodeid = getNodeId(childNode);
|
|
34405
|
-
const isChecked = selectKeyMaps[childNodeid];
|
|
34406
|
-
if (isChecked || indeterminateMaps[childNodeid]) {
|
|
34407
|
-
if (isChecked) {
|
|
34408
|
-
checkSize++;
|
|
34409
|
-
}
|
|
34410
|
-
checkSome = true;
|
|
34411
|
-
}
|
|
34412
|
-
});
|
|
34413
|
-
const checkAll = checkSize === childList.length;
|
|
34414
|
-
if (checkAll) {
|
|
34415
|
-
if (!selectKeyMaps[nodeid]) {
|
|
34416
|
-
selectKeyMaps[nodeid] = true;
|
|
34417
|
-
}
|
|
34418
|
-
if (indeterminateMaps[nodeid]) {
|
|
34419
|
-
delete indeterminateMaps[nodeid];
|
|
34420
|
-
}
|
|
34421
|
-
} else {
|
|
34422
|
-
if (selectKeyMaps[nodeid]) {
|
|
34423
|
-
delete selectKeyMaps[nodeid];
|
|
34424
|
-
}
|
|
34425
|
-
indeterminateMaps[nodeid] = checkSome;
|
|
34426
|
-
}
|
|
34427
|
-
} else {
|
|
34428
|
-
if (indeterminateMaps[nodeid]) {
|
|
34429
|
-
delete indeterminateMaps[nodeid];
|
|
34430
|
-
}
|
|
34431
|
-
}
|
|
34432
|
-
};
|
|
34433
34525
|
const updateCheckboxStatus = () => {
|
|
34526
|
+
const {
|
|
34527
|
+
transform
|
|
34528
|
+
} = props;
|
|
34434
34529
|
const {
|
|
34435
34530
|
treeList
|
|
34436
34531
|
} = reactData;
|
|
34532
|
+
const {
|
|
34533
|
+
selectCheckboxMaps,
|
|
34534
|
+
indeterminateRowMaps
|
|
34535
|
+
} = internalData;
|
|
34437
34536
|
const childrenField = computeChildrenField.value;
|
|
34537
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
34438
34538
|
const checkboxOpts = computeCheckboxOpts.value;
|
|
34439
34539
|
const {
|
|
34440
|
-
checkStrictly
|
|
34540
|
+
checkStrictly,
|
|
34541
|
+
checkMethod
|
|
34441
34542
|
} = checkboxOpts;
|
|
34442
34543
|
if (!checkStrictly) {
|
|
34443
|
-
const
|
|
34444
|
-
const
|
|
34445
|
-
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(treeList,
|
|
34446
|
-
const
|
|
34447
|
-
|
|
34448
|
-
|
|
34544
|
+
const childRowMaps = {};
|
|
34545
|
+
const childRowList = [];
|
|
34546
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(treeList, node => {
|
|
34547
|
+
const nodeid = getNodeId(node);
|
|
34548
|
+
const childList = node[childrenField];
|
|
34549
|
+
if (childList && childList.length && !childRowMaps[nodeid]) {
|
|
34550
|
+
childRowMaps[nodeid] = 1;
|
|
34551
|
+
childRowList.unshift([node, nodeid, childList]);
|
|
34449
34552
|
}
|
|
34450
|
-
|
|
34451
|
-
|
|
34452
|
-
|
|
34453
|
-
|
|
34553
|
+
}, {
|
|
34554
|
+
children: transform ? mapChildrenField : childrenField
|
|
34555
|
+
});
|
|
34556
|
+
childRowList.forEach(vals => {
|
|
34557
|
+
const node = vals[0];
|
|
34558
|
+
const nodeid = vals[1];
|
|
34559
|
+
const childList = vals[2];
|
|
34560
|
+
let sLen = 0; // 已选
|
|
34561
|
+
let hLen = 0; // 半选
|
|
34562
|
+
let vLen = 0; // 有效行
|
|
34563
|
+
childList.forEach(checkMethod ? item => {
|
|
34564
|
+
const childNodeid = getNodeId(item);
|
|
34565
|
+
const isSelect = selectCheckboxMaps[childNodeid];
|
|
34566
|
+
if (checkMethod({
|
|
34567
|
+
node: item
|
|
34568
|
+
})) {
|
|
34569
|
+
if (isSelect) {
|
|
34570
|
+
sLen++;
|
|
34571
|
+
} else if (indeterminateRowMaps[childNodeid]) {
|
|
34572
|
+
hLen++;
|
|
34573
|
+
}
|
|
34574
|
+
vLen++;
|
|
34575
|
+
} else {
|
|
34576
|
+
if (isSelect) {
|
|
34577
|
+
sLen++;
|
|
34578
|
+
} else if (indeterminateRowMaps[childNodeid]) {
|
|
34579
|
+
hLen++;
|
|
34580
|
+
}
|
|
34581
|
+
}
|
|
34582
|
+
} : item => {
|
|
34583
|
+
const childNodeid = getNodeId(item);
|
|
34584
|
+
const isSelect = selectCheckboxMaps[childNodeid];
|
|
34585
|
+
if (isSelect) {
|
|
34586
|
+
sLen++;
|
|
34587
|
+
} else if (indeterminateRowMaps[childNodeid]) {
|
|
34588
|
+
hLen++;
|
|
34589
|
+
}
|
|
34590
|
+
vLen++;
|
|
34591
|
+
});
|
|
34592
|
+
const isSelected = sLen >= vLen;
|
|
34593
|
+
const halfSelect = !isSelected && (sLen >= 1 || hLen >= 1);
|
|
34594
|
+
if (isSelected) {
|
|
34595
|
+
selectCheckboxMaps[nodeid] = node;
|
|
34596
|
+
if (indeterminateRowMaps[nodeid]) {
|
|
34597
|
+
delete indeterminateRowMaps[nodeid];
|
|
34598
|
+
}
|
|
34599
|
+
} else {
|
|
34600
|
+
if (selectCheckboxMaps[nodeid]) {
|
|
34601
|
+
delete selectCheckboxMaps[nodeid];
|
|
34602
|
+
}
|
|
34603
|
+
if (halfSelect) {
|
|
34604
|
+
indeterminateRowMaps[nodeid] = node;
|
|
34605
|
+
} else {
|
|
34606
|
+
if (indeterminateRowMaps[nodeid]) {
|
|
34607
|
+
delete indeterminateRowMaps[nodeid];
|
|
34608
|
+
}
|
|
34454
34609
|
}
|
|
34455
34610
|
}
|
|
34456
34611
|
});
|
|
34457
|
-
reactData.
|
|
34458
|
-
reactData.indeterminateCheckboxMaps = indeterminateMaps;
|
|
34612
|
+
reactData.updateCheckboxFlag++;
|
|
34459
34613
|
}
|
|
34460
34614
|
};
|
|
34461
34615
|
const changeCheckboxEvent = (evnt, node) => {
|
|
34462
34616
|
evnt.preventDefault();
|
|
34463
34617
|
evnt.stopPropagation();
|
|
34618
|
+
const {
|
|
34619
|
+
transform
|
|
34620
|
+
} = props;
|
|
34621
|
+
const {
|
|
34622
|
+
selectCheckboxMaps
|
|
34623
|
+
} = internalData;
|
|
34624
|
+
const childrenField = computeChildrenField.value;
|
|
34625
|
+
const mapChildrenField = computeMapChildrenField.value;
|
|
34464
34626
|
const checkboxOpts = computeCheckboxOpts.value;
|
|
34465
34627
|
const {
|
|
34466
34628
|
checkStrictly,
|
|
@@ -34475,35 +34637,33 @@ function getNodeUniqueId() {
|
|
|
34475
34637
|
if (isDisabled) {
|
|
34476
34638
|
return;
|
|
34477
34639
|
}
|
|
34478
|
-
const selectKeyMaps = Object.assign({}, reactData.selectCheckboxMaps);
|
|
34479
|
-
const childrenField = computeChildrenField.value;
|
|
34480
34640
|
const nodeid = getNodeId(node);
|
|
34481
34641
|
let isChecked = false;
|
|
34482
|
-
if (
|
|
34483
|
-
delete
|
|
34642
|
+
if (selectCheckboxMaps[nodeid]) {
|
|
34643
|
+
delete selectCheckboxMaps[nodeid];
|
|
34484
34644
|
} else {
|
|
34485
34645
|
isChecked = true;
|
|
34486
|
-
|
|
34646
|
+
selectCheckboxMaps[nodeid] = node;
|
|
34487
34647
|
}
|
|
34488
34648
|
if (!checkStrictly) {
|
|
34489
34649
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(node, childrenField), childNode => {
|
|
34490
34650
|
const childNodeid = getNodeId(childNode);
|
|
34491
34651
|
if (isChecked) {
|
|
34492
|
-
if (!
|
|
34493
|
-
|
|
34652
|
+
if (!selectCheckboxMaps[childNodeid]) {
|
|
34653
|
+
selectCheckboxMaps[childNodeid] = true;
|
|
34494
34654
|
}
|
|
34495
34655
|
} else {
|
|
34496
|
-
if (
|
|
34497
|
-
delete
|
|
34656
|
+
if (selectCheckboxMaps[childNodeid]) {
|
|
34657
|
+
delete selectCheckboxMaps[childNodeid];
|
|
34498
34658
|
}
|
|
34499
34659
|
}
|
|
34500
34660
|
}, {
|
|
34501
|
-
children: childrenField
|
|
34661
|
+
children: transform ? mapChildrenField : childrenField
|
|
34502
34662
|
});
|
|
34503
34663
|
}
|
|
34504
|
-
reactData.
|
|
34664
|
+
reactData.updateCheckboxFlag++;
|
|
34505
34665
|
updateCheckboxStatus();
|
|
34506
|
-
const value =
|
|
34666
|
+
const value = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().keys(selectCheckboxMaps);
|
|
34507
34667
|
emitCheckboxMode(value);
|
|
34508
34668
|
dispatchEvent('checkbox-change', {
|
|
34509
34669
|
node,
|
|
@@ -34608,7 +34768,7 @@ function getNodeUniqueId() {
|
|
|
34608
34768
|
class: ['vxe-radio--icon', isChecked ? getIcon().RADIO_CHECKED : getIcon().RADIO_UNCHECKED]
|
|
34609
34769
|
})]);
|
|
34610
34770
|
}
|
|
34611
|
-
return (
|
|
34771
|
+
return renderEmptyElement($xeTree);
|
|
34612
34772
|
};
|
|
34613
34773
|
const renderCheckbox = (node, nodeid, isChecked) => {
|
|
34614
34774
|
const {
|
|
@@ -34646,7 +34806,7 @@ function getNodeUniqueId() {
|
|
|
34646
34806
|
class: ['vxe-checkbox--icon', isIndeterminate ? getIcon().CHECKBOX_INDETERMINATE : isChecked ? getIcon().CHECKBOX_CHECKED : getIcon().CHECKBOX_UNCHECKED]
|
|
34647
34807
|
})]);
|
|
34648
34808
|
}
|
|
34649
|
-
return (
|
|
34809
|
+
return renderEmptyElement($xeTree);
|
|
34650
34810
|
};
|
|
34651
34811
|
const renderNode = node => {
|
|
34652
34812
|
const {
|
|
@@ -34661,12 +34821,15 @@ function getNodeUniqueId() {
|
|
|
34661
34821
|
showIcon
|
|
34662
34822
|
} = props;
|
|
34663
34823
|
const {
|
|
34664
|
-
nodeMaps,
|
|
34665
|
-
treeExpandedMaps,
|
|
34666
34824
|
currentNode,
|
|
34667
34825
|
selectRadioKey,
|
|
34668
|
-
|
|
34826
|
+
updateExpandedFlag
|
|
34669
34827
|
} = reactData;
|
|
34828
|
+
const {
|
|
34829
|
+
nodeMaps,
|
|
34830
|
+
treeExpandedMaps,
|
|
34831
|
+
treeExpandLazyLoadedMaps
|
|
34832
|
+
} = internalData;
|
|
34670
34833
|
const childrenField = computeChildrenField.value;
|
|
34671
34834
|
const titleField = computeTitleField.value;
|
|
34672
34835
|
const hasChildField = computeHasChildField.value;
|
|
@@ -34676,7 +34839,7 @@ function getNodeUniqueId() {
|
|
|
34676
34839
|
const titleSlot = slots.title;
|
|
34677
34840
|
const extraSlot = slots.extra;
|
|
34678
34841
|
const nodeid = getNodeId(node);
|
|
34679
|
-
const isExpand = treeExpandedMaps[nodeid];
|
|
34842
|
+
const isExpand = updateExpandedFlag && treeExpandedMaps[nodeid];
|
|
34680
34843
|
const nodeItem = nodeMaps[nodeid];
|
|
34681
34844
|
const nodeValue = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(node, titleField);
|
|
34682
34845
|
const childVns = [];
|
|
@@ -34742,7 +34905,7 @@ function getNodeUniqueId() {
|
|
|
34742
34905
|
isExpand
|
|
34743
34906
|
}) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
34744
34907
|
class: isLazyLoading ? iconLoaded || getIcon().TREE_NODE_LOADED : isExpand ? iconOpen || getIcon().TREE_NODE_OPEN : iconClose || getIcon().TREE_NODE_CLOSE
|
|
34745
|
-
})])] : []) : (
|
|
34908
|
+
})])] : []) : renderEmptyElement($xeTree), renderRadio(node, nodeid, isRadioChecked), renderCheckbox(node, nodeid, isCheckboxChecked), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
34746
34909
|
class: 'vxe-tree--node-item-inner'
|
|
34747
34910
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
34748
34911
|
class: 'vxe-tree--node-item-title'
|
|
@@ -34754,9 +34917,9 @@ function getNodeUniqueId() {
|
|
|
34754
34917
|
}, getSlotVNs(extraSlot({
|
|
34755
34918
|
node,
|
|
34756
34919
|
isExpand
|
|
34757
|
-
}))) : (
|
|
34920
|
+
}))) : renderEmptyElement($xeTree)])]), hasChild && treeExpandedMaps[nodeid] ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
34758
34921
|
class: 'vxe-tree--node-child-wrapper'
|
|
34759
|
-
}, childVns) : (
|
|
34922
|
+
}, childVns) : renderEmptyElement($xeTree)]);
|
|
34760
34923
|
};
|
|
34761
34924
|
const renderNodeList = () => {
|
|
34762
34925
|
const {
|
|
@@ -34814,7 +34977,7 @@ function getNodeUniqueId() {
|
|
|
34814
34977
|
dataFlag.value++;
|
|
34815
34978
|
});
|
|
34816
34979
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(dataFlag, () => {
|
|
34817
|
-
|
|
34980
|
+
loadTreeData(props.data || []);
|
|
34818
34981
|
});
|
|
34819
34982
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.checkNodeKey, val => {
|
|
34820
34983
|
reactData.selectRadioKey = val;
|
|
@@ -34831,11 +34994,11 @@ function getNodeUniqueId() {
|
|
|
34831
34994
|
});
|
|
34832
34995
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
|
|
34833
34996
|
reactData.treeList = [];
|
|
34834
|
-
|
|
34835
|
-
|
|
34997
|
+
internalData.treeExpandedMaps = {};
|
|
34998
|
+
internalData.indeterminateRowMaps = {};
|
|
34999
|
+
internalData.nodeMaps = {};
|
|
34836
35000
|
});
|
|
34837
|
-
|
|
34838
|
-
updateCheckboxChecked(props.checkNodeKeys || []);
|
|
35001
|
+
loadTreeData(props.data || []);
|
|
34839
35002
|
$xeTree.renderVN = renderVN;
|
|
34840
35003
|
return $xeTree;
|
|
34841
35004
|
},
|
|
@@ -37388,11 +37551,11 @@ const saveLocalFile = options => {
|
|
|
37388
37551
|
class: 'vxe-upload--file-item-loading-icon'
|
|
37389
37552
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
37390
37553
|
class: getIcon().UPLOAD_LOADING
|
|
37391
|
-
})]) : (
|
|
37554
|
+
})]) : renderEmptyElement($xeUpload), showProgress && isLoading && cacheItem ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37392
37555
|
class: 'vxe-upload--file-item-loading-text'
|
|
37393
37556
|
}, progressText ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toFormatString(`${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(progressText) ? progressText({}) : progressText}`, {
|
|
37394
37557
|
percent: cacheItem.percent
|
|
37395
|
-
}) : i18n_getI18n('vxe.upload.uploadProgress', [cacheItem.percent])) : (
|
|
37558
|
+
}) : i18n_getI18n('vxe.upload.uploadProgress', [cacheItem.percent])) : renderEmptyElement($xeUpload), showErrorStatus && isError ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37396
37559
|
class: 'vxe-upload--image-item-error'
|
|
37397
37560
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(src_button, {
|
|
37398
37561
|
icon: getIcon().UPLOAD_IMAGE_RE_UPLOAD,
|
|
@@ -37402,7 +37565,7 @@ const saveLocalFile = options => {
|
|
|
37402
37565
|
onClick() {
|
|
37403
37566
|
handleReUpload(item);
|
|
37404
37567
|
}
|
|
37405
|
-
})]) : (
|
|
37568
|
+
})]) : renderEmptyElement($xeUpload), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37406
37569
|
class: 'vxe-upload--file-item-btn-wrapper'
|
|
37407
37570
|
}, [cornerSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37408
37571
|
class: 'vxe-upload--file-item-corner'
|
|
@@ -37410,21 +37573,21 @@ const saveLocalFile = options => {
|
|
|
37410
37573
|
option: item,
|
|
37411
37574
|
isMoreView,
|
|
37412
37575
|
readonly: formReadonly
|
|
37413
|
-
}))) : (
|
|
37576
|
+
}))) : renderEmptyElement($xeUpload), showDownloadButton && !isLoading ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37414
37577
|
class: 'vxe-upload--file-item-download-btn',
|
|
37415
37578
|
onClick(evnt) {
|
|
37416
37579
|
downloadFileEvent(evnt, item);
|
|
37417
37580
|
}
|
|
37418
37581
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
37419
37582
|
class: getIcon().UPLOAD_FILE_DOWNLOAD
|
|
37420
|
-
})]) : (
|
|
37583
|
+
})]) : renderEmptyElement($xeUpload), showRemoveButton && !formReadonly && !isDisabled && !isLoading ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37421
37584
|
class: 'vxe-upload--file-item-remove-btn',
|
|
37422
37585
|
onClick(evnt) {
|
|
37423
37586
|
removeFileEvent(evnt, item, index);
|
|
37424
37587
|
}
|
|
37425
37588
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
37426
37589
|
class: getIcon().UPLOAD_FILE_REMOVE
|
|
37427
|
-
})]) : (
|
|
37590
|
+
})]) : renderEmptyElement($xeUpload)])]);
|
|
37428
37591
|
});
|
|
37429
37592
|
};
|
|
37430
37593
|
const renderFileAction = isMoreView => {
|
|
@@ -37444,11 +37607,11 @@ const saveLocalFile = options => {
|
|
|
37444
37607
|
const defaultSlot = slots.default;
|
|
37445
37608
|
const tipSlot = slots.tip || slots.hint;
|
|
37446
37609
|
if (formReadonly || !showUploadButton) {
|
|
37447
|
-
return (
|
|
37610
|
+
return renderEmptyElement($xeUpload);
|
|
37448
37611
|
}
|
|
37449
37612
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37450
37613
|
class: 'vxe-upload--file-action'
|
|
37451
|
-
}, [autoHiddenButton && overCount ? (
|
|
37614
|
+
}, [autoHiddenButton && overCount ? renderEmptyElement($xeUpload) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37452
37615
|
class: 'vxe-upload--file-action-btn',
|
|
37453
37616
|
onClick: clickEvent
|
|
37454
37617
|
}, defaultSlot ? getSlotVNs(defaultSlot({
|
|
@@ -37462,7 +37625,7 @@ const saveLocalFile = options => {
|
|
|
37462
37625
|
class: 'vxe-upload--file-action-tip'
|
|
37463
37626
|
}, tipSlot ? getSlotVNs(tipSlot({
|
|
37464
37627
|
$upload: $xeUpload
|
|
37465
|
-
})) : `${defTipText}`) : (
|
|
37628
|
+
})) : `${defTipText}`) : renderEmptyElement($xeUpload)]);
|
|
37466
37629
|
};
|
|
37467
37630
|
const renderAllMode = () => {
|
|
37468
37631
|
const {
|
|
@@ -37490,7 +37653,7 @@ const saveLocalFile = options => {
|
|
|
37490
37653
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37491
37654
|
key: 'all',
|
|
37492
37655
|
class: 'vxe-upload--file-wrapper'
|
|
37493
|
-
}, showList ? [showMoreButton && moreConfig && isHorizontal ? (
|
|
37656
|
+
}, showList ? [showMoreButton && moreConfig && isHorizontal ? renderEmptyElement($xeUpload) : renderFileAction(true), currList.length || showMoreButton && isHorizontal ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37494
37657
|
class: ['vxe-upload--file-list-wrapper', {
|
|
37495
37658
|
'is--horizontal': isHorizontal
|
|
37496
37659
|
}]
|
|
@@ -37502,14 +37665,14 @@ const saveLocalFile = options => {
|
|
|
37502
37665
|
default: () => renderFileItemList(currList, false)
|
|
37503
37666
|
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37504
37667
|
class: 'vxe-upload--file-list'
|
|
37505
|
-
}, renderFileItemList(currList, false)) : (
|
|
37668
|
+
}, renderFileItemList(currList, false)) : renderEmptyElement($xeUpload), showMoreButton && overMaxNum ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37506
37669
|
class: 'vxe-upload--file-over-more'
|
|
37507
37670
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(src_button, {
|
|
37508
37671
|
mode: 'text',
|
|
37509
37672
|
content: i18n_getI18n('vxe.upload.moreBtnText', [fileList.length]),
|
|
37510
37673
|
status: 'primary',
|
|
37511
37674
|
onClick: handleMoreEvent
|
|
37512
|
-
})]) : (
|
|
37675
|
+
})]) : renderEmptyElement($xeUpload), showMoreButton && moreConfig && isHorizontal ? renderFileAction(false) : renderEmptyElement($xeUpload)]) : renderEmptyElement($xeUpload)] : [renderFileAction(false)]);
|
|
37513
37676
|
};
|
|
37514
37677
|
const renderImageItemList = (currList, isMoreView) => {
|
|
37515
37678
|
const {
|
|
@@ -37571,7 +37734,7 @@ const saveLocalFile = options => {
|
|
|
37571
37734
|
class: 'vxe-upload--image-item-loading-text'
|
|
37572
37735
|
}, progressText ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toFormatString(`${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(progressText) ? progressText({}) : progressText}`, {
|
|
37573
37736
|
percent: cacheItem.percent
|
|
37574
|
-
}) : i18n_getI18n('vxe.upload.uploadProgress', [cacheItem.percent])) : (
|
|
37737
|
+
}) : i18n_getI18n('vxe.upload.uploadProgress', [cacheItem.percent])) : renderEmptyElement($xeUpload)]) : renderEmptyElement($xeUpload), !isLoading ? isError && showErrorStatus ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37575
37738
|
class: 'vxe-upload--image-item-error'
|
|
37576
37739
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(src_button, {
|
|
37577
37740
|
icon: getIcon().UPLOAD_IMAGE_RE_UPLOAD,
|
|
@@ -37586,7 +37749,7 @@ const saveLocalFile = options => {
|
|
|
37586
37749
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('img', {
|
|
37587
37750
|
class: 'vxe-upload--image-item-img',
|
|
37588
37751
|
src: getThumbnailFileUrl(item)
|
|
37589
|
-
})]) : (
|
|
37752
|
+
})]) : renderEmptyElement($xeUpload), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37590
37753
|
class: 'vxe-upload--image-item-btn-wrapper',
|
|
37591
37754
|
onClick(evnt) {
|
|
37592
37755
|
evnt.stopPropagation();
|
|
@@ -37597,7 +37760,7 @@ const saveLocalFile = options => {
|
|
|
37597
37760
|
option: item,
|
|
37598
37761
|
isMoreView,
|
|
37599
37762
|
readonly: formReadonly
|
|
37600
|
-
}))) : (
|
|
37763
|
+
}))) : renderEmptyElement($xeUpload), showRemoveButton && !formReadonly && !isDisabled && !isLoading ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37601
37764
|
class: 'vxe-upload--image-item-remove-btn',
|
|
37602
37765
|
onClick(evnt) {
|
|
37603
37766
|
evnt.stopPropagation();
|
|
@@ -37605,7 +37768,7 @@ const saveLocalFile = options => {
|
|
|
37605
37768
|
}
|
|
37606
37769
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
37607
37770
|
class: getIcon().UPLOAD_IMAGE_REMOVE
|
|
37608
|
-
})]) : (
|
|
37771
|
+
})]) : renderEmptyElement($xeUpload)])])]);
|
|
37609
37772
|
});
|
|
37610
37773
|
};
|
|
37611
37774
|
const renderImageAction = isMoreView => {
|
|
@@ -37625,7 +37788,7 @@ const saveLocalFile = options => {
|
|
|
37625
37788
|
const defaultSlot = slots.default;
|
|
37626
37789
|
const tipSlot = slots.tip || slots.hint;
|
|
37627
37790
|
if (formReadonly || !showUploadButton || autoHiddenButton && overCount) {
|
|
37628
|
-
return (
|
|
37791
|
+
return renderEmptyElement($xeUpload);
|
|
37629
37792
|
}
|
|
37630
37793
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37631
37794
|
key: 'action',
|
|
@@ -37642,13 +37805,13 @@ const saveLocalFile = options => {
|
|
|
37642
37805
|
class: 'vxe-upload--image-action-icon'
|
|
37643
37806
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
37644
37807
|
class: buttonIcon || getIcon().UPLOAD_IMAGE_ADD
|
|
37645
|
-
})]) : (
|
|
37808
|
+
})]) : renderEmptyElement($xeUpload), isMoreView || showButtonText ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37646
37809
|
class: 'vxe-upload--image-action-content'
|
|
37647
|
-
}, buttonText ? `${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(buttonText) ? buttonText({}) : buttonText}` : i18n_getI18n('vxe.upload.imgBtnText')) : (
|
|
37810
|
+
}, buttonText ? `${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(buttonText) ? buttonText({}) : buttonText}` : i18n_getI18n('vxe.upload.imgBtnText')) : renderEmptyElement($xeUpload), showTipText && (defTipText || tipSlot) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37648
37811
|
class: 'vxe-upload--image-action-hint'
|
|
37649
37812
|
}, tipSlot ? getSlotVNs(tipSlot({
|
|
37650
37813
|
$upload: $xeUpload
|
|
37651
|
-
})) : `${defTipText}`) : (
|
|
37814
|
+
})) : `${defTipText}`) : renderEmptyElement($xeUpload)])])]);
|
|
37652
37815
|
};
|
|
37653
37816
|
const renderImageMode = () => {
|
|
37654
37817
|
const {
|
|
@@ -37686,7 +37849,7 @@ const saveLocalFile = options => {
|
|
|
37686
37849
|
content: i18n_getI18n('vxe.upload.moreBtnText', [fileList.length]),
|
|
37687
37850
|
status: 'primary',
|
|
37688
37851
|
onClick: handleMoreEvent
|
|
37689
|
-
})]) : (
|
|
37852
|
+
})]) : renderEmptyElement($xeUpload), renderImageAction(false)])
|
|
37690
37853
|
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37691
37854
|
class: 'vxe-upload--image-list'
|
|
37692
37855
|
}, renderImageItemList(currList, false).concat([showMoreButton && overMaxNum ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
@@ -37696,7 +37859,7 @@ const saveLocalFile = options => {
|
|
|
37696
37859
|
content: i18n_getI18n('vxe.upload.moreBtnText', [fileList.length]),
|
|
37697
37860
|
status: 'primary',
|
|
37698
37861
|
onClick: handleMoreEvent
|
|
37699
|
-
})]) : (
|
|
37862
|
+
})]) : renderEmptyElement($xeUpload), renderImageAction(false)]))] : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
37700
37863
|
class: 'vxe-upload--image-list'
|
|
37701
37864
|
}, [renderImageAction(false)])]);
|
|
37702
37865
|
};
|
|
@@ -37755,13 +37918,11 @@ const saveLocalFile = options => {
|
|
|
37755
37918
|
updateFileList();
|
|
37756
37919
|
});
|
|
37757
37920
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
37758
|
-
if (
|
|
37759
|
-
|
|
37760
|
-
|
|
37761
|
-
|
|
37762
|
-
|
|
37763
|
-
warnLog('vxe.error.delProp', ['image-style', 'image-config']);
|
|
37764
|
-
}
|
|
37921
|
+
if (props.multiple && props.singleMode) {
|
|
37922
|
+
errLog('vxe.error.errConflicts', ['multiple', 'single-mode']);
|
|
37923
|
+
}
|
|
37924
|
+
if (props.imageStyle) {
|
|
37925
|
+
warnLog('vxe.error.delProp', ['image-style', 'image-config']);
|
|
37765
37926
|
}
|
|
37766
37927
|
if (props.dragSort) {
|
|
37767
37928
|
initTpImg();
|
|
@@ -39678,7 +39839,7 @@ const Icon = VxeIcon;
|
|
|
39678
39839
|
class: item.icon || ''
|
|
39679
39840
|
})]), showIconTitle ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
39680
39841
|
class: 'vxe-ico-picker--item-title'
|
|
39681
|
-
}, `${item.title || ''}`) : (
|
|
39842
|
+
}, `${item.title || ''}`) : renderEmptyElement($xeIconPicker)]);
|
|
39682
39843
|
}));
|
|
39683
39844
|
}));
|
|
39684
39845
|
};
|
|
@@ -39761,7 +39922,7 @@ const Icon = VxeIcon;
|
|
|
39761
39922
|
style: reactData.panelStyle
|
|
39762
39923
|
}, [initialized && (visiblePanel || isAniVisible) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
39763
39924
|
class: 'vxe-ico-picker--panel-wrapper'
|
|
39764
|
-
}, [renderIconWrapper()]) : (
|
|
39925
|
+
}, [renderIconWrapper()]) : renderEmptyElement($xeIconPicker)])])]);
|
|
39765
39926
|
};
|
|
39766
39927
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.modelValue, val => {
|
|
39767
39928
|
reactData.selectIcon = `${val || ''}`;
|
|
@@ -39830,6 +39991,7 @@ const IconPicker = VxeIconPicker;
|
|
|
39830
39991
|
type: Boolean,
|
|
39831
39992
|
default: () => getConfig().imagePreview.showDownloadButton
|
|
39832
39993
|
},
|
|
39994
|
+
toolbarConfig: Object,
|
|
39833
39995
|
beforeDownloadMethod: Function,
|
|
39834
39996
|
downloadMethod: Function
|
|
39835
39997
|
},
|
|
@@ -39857,6 +40019,9 @@ const IconPicker = VxeIconPicker;
|
|
|
39857
40019
|
const computeMarginSize = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
39858
40020
|
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(props.marginSize || 0) || 16;
|
|
39859
40021
|
});
|
|
40022
|
+
const computeToolbarOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
40023
|
+
return Object.assign({}, getConfig().imagePreview.toolbarConfig, props.toolbarConfig);
|
|
40024
|
+
});
|
|
39860
40025
|
const computeRotateText = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
39861
40026
|
const {
|
|
39862
40027
|
offsetRotate
|
|
@@ -40102,10 +40267,13 @@ const IconPicker = VxeIconPicker;
|
|
|
40102
40267
|
const {
|
|
40103
40268
|
activeIndex
|
|
40104
40269
|
} = reactData;
|
|
40270
|
+
const toolbarOpts = computeToolbarOpts.value;
|
|
40271
|
+
const btnConf = toolbarOpts.download;
|
|
40272
|
+
const btnOpts = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(btnConf) ? {} : btnConf ? Object.assign({}, btnConf) : {};
|
|
40105
40273
|
const imgList = computeImgList.value;
|
|
40106
40274
|
const imgUrl = imgList[activeIndex || 0];
|
|
40107
|
-
const beforeDownloadFn = props.beforeDownloadMethod || getConfig().imagePreview.beforeDownloadMethod;
|
|
40108
|
-
const downloadFn = props.downloadMethod || getConfig().imagePreview.downloadMethod;
|
|
40275
|
+
const beforeDownloadFn = props.beforeDownloadMethod || btnOpts.beforeDownloadMethod || getConfig().imagePreview.beforeDownloadMethod;
|
|
40276
|
+
const downloadFn = props.downloadMethod || btnOpts.downloadMethod || getConfig().imagePreview.downloadMethod;
|
|
40109
40277
|
Promise.resolve(beforeDownloadFn ? beforeDownloadFn({
|
|
40110
40278
|
$imagePreview: $xeImagePreview,
|
|
40111
40279
|
url: imgUrl,
|
|
@@ -40287,15 +40455,19 @@ const IconPicker = VxeIconPicker;
|
|
|
40287
40455
|
}));
|
|
40288
40456
|
};
|
|
40289
40457
|
const renderOperationBtn = (code, icon) => {
|
|
40290
|
-
|
|
40458
|
+
const toolbarOpts = computeToolbarOpts.value;
|
|
40459
|
+
const btnConf = toolbarOpts[code];
|
|
40460
|
+
const btnOpts = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(btnConf) ? {} : btnConf ? Object.assign({}, btnConf) : {};
|
|
40461
|
+
const showBtn = btnConf !== false;
|
|
40462
|
+
return showBtn ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
40291
40463
|
class: 'vxe-image-preview--operation-btn',
|
|
40292
40464
|
title: i18n_getI18n(`vxe.imagePreview.operBtn.${code}`),
|
|
40293
40465
|
onClick(evnt) {
|
|
40294
40466
|
handleOperationBtn(evnt, code);
|
|
40295
40467
|
}
|
|
40296
40468
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
40297
|
-
class: getIcon()[icon]
|
|
40298
|
-
})]);
|
|
40469
|
+
class: btnOpts.icon || getIcon()[icon]
|
|
40470
|
+
})]) : renderEmptyElement($xeImagePreview);
|
|
40299
40471
|
};
|
|
40300
40472
|
const renderBtnWrapper = () => {
|
|
40301
40473
|
const {
|
|
@@ -40308,6 +40480,7 @@ const IconPicker = VxeIconPicker;
|
|
|
40308
40480
|
const imgList = computeImgList.value;
|
|
40309
40481
|
const rotateText = computeRotateText.value;
|
|
40310
40482
|
const scaleText = computeScaleText.value;
|
|
40483
|
+
const toolbarOpts = computeToolbarOpts.value;
|
|
40311
40484
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
40312
40485
|
class: 'vxe-image-preview--btn-wrapper'
|
|
40313
40486
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
@@ -40326,14 +40499,14 @@ const IconPicker = VxeIconPicker;
|
|
|
40326
40499
|
}
|
|
40327
40500
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
40328
40501
|
class: getIcon().IMAGE_PREVIEW_PREVIOUS
|
|
40329
|
-
})]) : (
|
|
40502
|
+
})]) : renderEmptyElement($xeImagePreview), imgList.length > 1 ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
40330
40503
|
class: 'vxe-image-preview--next-btn',
|
|
40331
40504
|
onClick() {
|
|
40332
40505
|
handleChange(true);
|
|
40333
40506
|
}
|
|
40334
40507
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
40335
40508
|
class: getIcon().IMAGE_PREVIEW_NEXT
|
|
40336
|
-
})]) : (
|
|
40509
|
+
})]) : renderEmptyElement($xeImagePreview), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
40337
40510
|
class: 'vxe-image-preview--operation-info'
|
|
40338
40511
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
40339
40512
|
class: 'vxe-image-preview--operation-deg'
|
|
@@ -40347,7 +40520,7 @@ const IconPicker = VxeIconPicker;
|
|
|
40347
40520
|
class: 'vxe-image-preview--operation-active-current'
|
|
40348
40521
|
}, `${(activeIndex || 0) + 1}`), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
40349
40522
|
class: 'vxe-image-preview--operation-active-total'
|
|
40350
|
-
}, `/${imgList.length}`)]), renderOperationBtn('zoomOut', 'IMAGE_PREVIEW_ZOOM_OUT'), renderOperationBtn('zoomIn', 'IMAGE_PREVIEW_ZOOM_IN'), renderOperationBtn('pctFull', 'IMAGE_PREVIEW_PCT_FULL'), renderOperationBtn('pct11', 'IMAGE_PREVIEW_PCT_1_1'), renderOperationBtn('rotateLeft', 'IMAGE_PREVIEW_ROTATE_LEFT'), renderOperationBtn('rotateRight', 'IMAGE_PREVIEW_ROTATE_RIGHT'), showPrintButton ? renderOperationBtn('print', 'IMAGE_PREVIEW_PRINT') : (
|
|
40523
|
+
}, `/${imgList.length}`)]), renderOperationBtn('zoomOut', 'IMAGE_PREVIEW_ZOOM_OUT'), renderOperationBtn('zoomIn', 'IMAGE_PREVIEW_ZOOM_IN'), renderOperationBtn('pctFull', 'IMAGE_PREVIEW_PCT_FULL'), renderOperationBtn('pct11', 'IMAGE_PREVIEW_PCT_1_1'), renderOperationBtn('rotateLeft', 'IMAGE_PREVIEW_ROTATE_LEFT'), renderOperationBtn('rotateRight', 'IMAGE_PREVIEW_ROTATE_RIGHT'), showPrintButton || toolbarOpts.print ? renderOperationBtn('print', 'IMAGE_PREVIEW_PRINT') : renderEmptyElement($xeImagePreview), showDownloadButton || toolbarOpts.download ? renderOperationBtn('download', 'IMAGE_PREVIEW_DOWNLOAD') : renderEmptyElement($xeImagePreview)])]);
|
|
40351
40524
|
};
|
|
40352
40525
|
const renderVN = () => {
|
|
40353
40526
|
const {
|
|
@@ -40415,6 +40588,7 @@ const openPreviewImage = options => {
|
|
|
40415
40588
|
urlField: opts.urlField,
|
|
40416
40589
|
marginSize: opts.marginSize,
|
|
40417
40590
|
maskClosable: opts.maskClosable,
|
|
40591
|
+
toolbarConfig: opts.toolbarConfig,
|
|
40418
40592
|
showPrintButton: opts.showPrintButton,
|
|
40419
40593
|
showDownloadButton: opts.showDownloadButton,
|
|
40420
40594
|
beforeDownloadMethod: opts.beforeDownloadMethod,
|
|
@@ -40449,6 +40623,7 @@ const openPreviewImage = options => {
|
|
|
40449
40623
|
type: Boolean,
|
|
40450
40624
|
default: () => getConfig().image.maskClosable
|
|
40451
40625
|
},
|
|
40626
|
+
toolbarConfig: Object,
|
|
40452
40627
|
showPreview: {
|
|
40453
40628
|
type: Boolean,
|
|
40454
40629
|
default: () => getConfig().image.showPreview
|
|
@@ -40549,6 +40724,7 @@ const openPreviewImage = options => {
|
|
|
40549
40724
|
const clickEvent = evnt => {
|
|
40550
40725
|
const {
|
|
40551
40726
|
showPreview,
|
|
40727
|
+
toolbarConfig,
|
|
40552
40728
|
showPrintButton,
|
|
40553
40729
|
showDownloadButton,
|
|
40554
40730
|
maskClosable
|
|
@@ -40563,6 +40739,7 @@ const openPreviewImage = options => {
|
|
|
40563
40739
|
if (showPreview && imgUrl) {
|
|
40564
40740
|
openPreviewImage({
|
|
40565
40741
|
urlList: imgList,
|
|
40742
|
+
toolbarConfig,
|
|
40566
40743
|
showPrintButton,
|
|
40567
40744
|
showDownloadButton,
|
|
40568
40745
|
maskClosable
|
|
@@ -40636,6 +40813,7 @@ const image_Image = VxeImage;
|
|
|
40636
40813
|
type: String,
|
|
40637
40814
|
default: () => getConfig().imageGroup.size || getConfig().size
|
|
40638
40815
|
},
|
|
40816
|
+
toolbarConfig: Object,
|
|
40639
40817
|
showPrintButton: {
|
|
40640
40818
|
type: Boolean,
|
|
40641
40819
|
default: () => getConfig().imageGroup.showPrintButton
|
|
@@ -40697,6 +40875,7 @@ const image_Image = VxeImage;
|
|
|
40697
40875
|
handleClickImgEvent(evnt, params) {
|
|
40698
40876
|
const {
|
|
40699
40877
|
showPreview,
|
|
40878
|
+
toolbarConfig,
|
|
40700
40879
|
showPrintButton,
|
|
40701
40880
|
showDownloadButton
|
|
40702
40881
|
} = props;
|
|
@@ -40708,6 +40887,7 @@ const image_Image = VxeImage;
|
|
|
40708
40887
|
openPreviewImage({
|
|
40709
40888
|
activeIndex: Math.max(0, external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().findIndexOf(imgList, item => item.url === url)),
|
|
40710
40889
|
urlList: imgList,
|
|
40890
|
+
toolbarConfig,
|
|
40711
40891
|
showPrintButton,
|
|
40712
40892
|
showDownloadButton
|
|
40713
40893
|
});
|
|
@@ -41555,13 +41735,11 @@ const default_setting_data_getDefaultSettingFormData = () => {
|
|
|
41555
41735
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
41556
41736
|
updateTableData();
|
|
41557
41737
|
});
|
|
41558
|
-
|
|
41559
|
-
(
|
|
41560
|
-
|
|
41561
|
-
|
|
41562
|
-
|
|
41563
|
-
});
|
|
41564
|
-
}
|
|
41738
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
41739
|
+
if (!VxeTableGridComponent) {
|
|
41740
|
+
errLog('vxe.error.reqComp', ['vxe-grid']);
|
|
41741
|
+
}
|
|
41742
|
+
});
|
|
41565
41743
|
return () => {
|
|
41566
41744
|
const {
|
|
41567
41745
|
searchFormData,
|
|
@@ -43260,7 +43438,7 @@ const ListDesign = VxeListDesign;
|
|
|
43260
43438
|
ref: refGrid
|
|
43261
43439
|
}), Object.assign({}, slots, {
|
|
43262
43440
|
default: undefined
|
|
43263
|
-
})) : (
|
|
43441
|
+
})) : renderEmptyElement($xeListView)]),
|
|
43264
43442
|
/**
|
|
43265
43443
|
* 加载中
|
|
43266
43444
|
*/
|
|
@@ -43276,13 +43454,11 @@ const ListDesign = VxeListDesign;
|
|
|
43276
43454
|
loadConfig(props.config);
|
|
43277
43455
|
}
|
|
43278
43456
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeListView', $xeListView);
|
|
43279
|
-
|
|
43280
|
-
(
|
|
43281
|
-
|
|
43282
|
-
|
|
43283
|
-
|
|
43284
|
-
});
|
|
43285
|
-
}
|
|
43457
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
43458
|
+
if (!VxeTableGridComponent) {
|
|
43459
|
+
errLog('vxe.error.reqComp', ['vxe-grid']);
|
|
43460
|
+
}
|
|
43461
|
+
});
|
|
43286
43462
|
$xeListView.renderVN = renderVN;
|
|
43287
43463
|
return $xeListView;
|
|
43288
43464
|
},
|
|
@@ -44056,7 +44232,7 @@ const List = VxeList;
|
|
|
44056
44232
|
}
|
|
44057
44233
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
44058
44234
|
class: isExpand ? getIcon().MENU_ITEM_EXPAND_OPEN : getIcon().MENU_ITEM_EXPAND_CLOSE
|
|
44059
|
-
})]) : (
|
|
44235
|
+
})]) : renderEmptyElement($xeMenu)];
|
|
44060
44236
|
};
|
|
44061
44237
|
const renderDefaultChildren = item => {
|
|
44062
44238
|
const {
|
|
@@ -44075,7 +44251,7 @@ const List = VxeList;
|
|
|
44075
44251
|
const isCollapsed = computeIsCollapsed.value;
|
|
44076
44252
|
if (item.permissionCode) {
|
|
44077
44253
|
if (!permission.checkVisible(item.permissionCode)) {
|
|
44078
|
-
return (
|
|
44254
|
+
return renderEmptyElement($xeMenu);
|
|
44079
44255
|
}
|
|
44080
44256
|
}
|
|
44081
44257
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
@@ -44100,7 +44276,7 @@ const List = VxeList;
|
|
|
44100
44276
|
}
|
|
44101
44277
|
}, renderMenuTitle(item)), hasChild ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
44102
44278
|
class: 'vxe-menu--item-group'
|
|
44103
|
-
}, childList.map(child => renderDefaultChildren(child))) : (
|
|
44279
|
+
}, childList.map(child => renderDefaultChildren(child))) : renderEmptyElement($xeMenu)]);
|
|
44104
44280
|
};
|
|
44105
44281
|
const renderCollapseChildren = item => {
|
|
44106
44282
|
const {
|
|
@@ -44114,7 +44290,7 @@ const List = VxeList;
|
|
|
44114
44290
|
} = item;
|
|
44115
44291
|
if (item.permissionCode) {
|
|
44116
44292
|
if (!permission.checkVisible(item.permissionCode)) {
|
|
44117
|
-
return (
|
|
44293
|
+
return renderEmptyElement($xeMenu);
|
|
44118
44294
|
}
|
|
44119
44295
|
}
|
|
44120
44296
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
@@ -44138,7 +44314,7 @@ const List = VxeList;
|
|
|
44138
44314
|
}
|
|
44139
44315
|
}, renderMenuTitle(item)), hasChild ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
44140
44316
|
class: 'vxe-menu--item-group'
|
|
44141
|
-
}, childList.map(child => renderDefaultChildren(child))) : (
|
|
44317
|
+
}, childList.map(child => renderDefaultChildren(child))) : renderEmptyElement($xeMenu)]);
|
|
44142
44318
|
};
|
|
44143
44319
|
const renderVN = () => {
|
|
44144
44320
|
const {
|
|
@@ -44174,7 +44350,7 @@ const List = VxeList;
|
|
|
44174
44350
|
onMouseleave: handleMenuMouseleave
|
|
44175
44351
|
}, [isCollapsed ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
44176
44352
|
class: 'vxe-menu--item-list'
|
|
44177
|
-
}, menuList.map(child => renderDefaultChildren(child))) : (
|
|
44353
|
+
}, menuList.map(child => renderDefaultChildren(child))) : renderEmptyElement($xeMenu)]) : renderEmptyElement($xeMenu),
|
|
44178
44354
|
/**
|
|
44179
44355
|
* 加载中
|
|
44180
44356
|
*/
|
|
@@ -45452,9 +45628,7 @@ const Option = VxeOption;
|
|
|
45452
45628
|
if (renderFn) {
|
|
45453
45629
|
childNodes.push(renderFn());
|
|
45454
45630
|
} else {
|
|
45455
|
-
|
|
45456
|
-
errLog('vxe.error.notProp', [`layouts -> ${name}`]);
|
|
45457
|
-
}
|
|
45631
|
+
errLog('vxe.error.notProp', [`layouts -> ${name}`]);
|
|
45458
45632
|
}
|
|
45459
45633
|
});
|
|
45460
45634
|
if (slots.right) {
|
|
@@ -45773,12 +45947,12 @@ const Pager = VxePager;
|
|
|
45773
45947
|
onClick: clearValueEvent
|
|
45774
45948
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
45775
45949
|
class: getIcon().INPUT_CLEAR
|
|
45776
|
-
})]) : (
|
|
45950
|
+
})]) : renderEmptyElement($xePasswordInput), controls ? renderPasswordIcon() : renderEmptyElement($xePasswordInput), suffixSlot || suffixIcon ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
45777
45951
|
class: 'vxe-password-input--suffix-icon',
|
|
45778
45952
|
onClick: clickSuffixEvent
|
|
45779
45953
|
}, suffixSlot ? getSlotVNs(suffixSlot({})) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
45780
45954
|
class: suffixIcon
|
|
45781
|
-
})]) : (
|
|
45955
|
+
})]) : renderEmptyElement($xePasswordInput)]) : null;
|
|
45782
45956
|
};
|
|
45783
45957
|
passwordInputMethods = {
|
|
45784
45958
|
dispatchEvent(type, params, evnt) {
|
|
@@ -45842,7 +46016,7 @@ const Pager = VxePager;
|
|
|
45842
46016
|
'show--clear': isClearable && !disabled && !(inputValue === '' || external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(inputValue))
|
|
45843
46017
|
}],
|
|
45844
46018
|
spellcheck: false
|
|
45845
|
-
}, [prefix || (
|
|
46019
|
+
}, [prefix || renderEmptyElement($xePasswordInput), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
45846
46020
|
class: 'vxe-password-input--wrapper'
|
|
45847
46021
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('input', {
|
|
45848
46022
|
ref: refInputTarget,
|
|
@@ -45860,7 +46034,7 @@ const Pager = VxePager;
|
|
|
45860
46034
|
onChange: changeEvent,
|
|
45861
46035
|
onFocus: focusEvent,
|
|
45862
46036
|
onBlur: blurEvent
|
|
45863
|
-
})]), suffix || (
|
|
46037
|
+
})]), suffix || renderEmptyElement($xePasswordInput)]);
|
|
45864
46038
|
};
|
|
45865
46039
|
$xePasswordInput.renderVN = renderVN;
|
|
45866
46040
|
return $xePasswordInput;
|
|
@@ -46292,7 +46466,7 @@ const PrintPageBreak = VxePrintPageBreak;
|
|
|
46292
46466
|
class: ['vxe-print-page-break--header', headerAlign ? `align--${headerAlign}` : '']
|
|
46293
46467
|
}, headerHtml ? `${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(headerHtml) ? headerHtml(params) : headerHtml || ''}` : [title && (showAllPageTitle || !index) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46294
46468
|
class: 'vxe-print-page-break--header-title'
|
|
46295
|
-
}, `${title || ''}`) : (
|
|
46469
|
+
}, `${title || ''}`) : renderEmptyElement($xePrint)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46296
46470
|
class: 'vxe-print-page-break--body'
|
|
46297
46471
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46298
46472
|
class: 'vxe-print-page-break--left'
|
|
@@ -46304,7 +46478,7 @@ const PrintPageBreak = VxePrintPageBreak;
|
|
|
46304
46478
|
class: ['vxe-print-page-break--footer', footerAlign ? `align--${footerAlign}` : '']
|
|
46305
46479
|
}, footerHtml ? `${external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(footerHtml) ? footerHtml(params) : footerHtml || ''}` : [showPageNumber ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46306
46480
|
class: 'vxe-print-page-break--footer-page-number'
|
|
46307
|
-
}, `${currentPage}/${pageCount}`) : (
|
|
46481
|
+
}, `${currentPage}/${pageCount}`) : renderEmptyElement($xePrint)])]);
|
|
46308
46482
|
});
|
|
46309
46483
|
};
|
|
46310
46484
|
const renderPageStaticLayouts = () => {
|
|
@@ -46338,7 +46512,7 @@ const PrintPageBreak = VxePrintPageBreak;
|
|
|
46338
46512
|
class: ['vxe-print-page-break--header', headerAlign ? `align--${headerAlign}` : '']
|
|
46339
46513
|
}, headerSlot ? getSlotVNs(headerSlot(params)) : [title && (showAllPageTitle || !index) ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46340
46514
|
class: 'vxe-print-page-break--header-title'
|
|
46341
|
-
}, `${title || ''}`) : (
|
|
46515
|
+
}, `${title || ''}`) : renderEmptyElement($xePrint)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46342
46516
|
class: 'vxe-print-page-break--body'
|
|
46343
46517
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46344
46518
|
class: 'vxe-print-page-break--left'
|
|
@@ -46350,7 +46524,7 @@ const PrintPageBreak = VxePrintPageBreak;
|
|
|
46350
46524
|
class: ['vxe-print-page-break--footer', footerAlign ? `align--${footerAlign}` : '']
|
|
46351
46525
|
}, footerSlot ? getSlotVNs(footerSlot(params)) : [showPageNumber ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46352
46526
|
class: 'vxe-print-page-break--footer-page-number'
|
|
46353
|
-
}, `${currentPage}/${pageCount}`) : (
|
|
46527
|
+
}, `${currentPage}/${pageCount}`) : renderEmptyElement($xePrint)])]);
|
|
46354
46528
|
});
|
|
46355
46529
|
};
|
|
46356
46530
|
const renderVN = () => {
|
|
@@ -46767,7 +46941,7 @@ const Print = VxePrint;
|
|
|
46767
46941
|
class: 'vxe-pulldown--panel-header'
|
|
46768
46942
|
}, headerSlot({
|
|
46769
46943
|
$pulldown: $xePulldown
|
|
46770
|
-
})) : (
|
|
46944
|
+
})) : renderEmptyElement($xePulldown), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
46771
46945
|
class: 'vxe-pulldown--panel-body'
|
|
46772
46946
|
}, dropdownSlot ? dropdownSlot({
|
|
46773
46947
|
$pulldown: $xePulldown
|
|
@@ -46775,7 +46949,7 @@ const Print = VxePrint;
|
|
|
46775
46949
|
class: 'vxe-pulldown--panel-footer'
|
|
46776
46950
|
}, footerSlot({
|
|
46777
46951
|
$pulldown: $xePulldown
|
|
46778
|
-
})) : (
|
|
46952
|
+
})) : renderEmptyElement($xePulldown)] : [])])])]);
|
|
46779
46953
|
};
|
|
46780
46954
|
$xePulldown.renderVN = renderVN;
|
|
46781
46955
|
return $xePulldown;
|
|
@@ -48568,13 +48742,11 @@ function getRowUniqueId() {
|
|
|
48568
48742
|
globalEvents.off($xeTableSelect, 'mousedown');
|
|
48569
48743
|
globalEvents.off($xeTableSelect, 'blur');
|
|
48570
48744
|
});
|
|
48571
|
-
|
|
48572
|
-
(
|
|
48573
|
-
|
|
48574
|
-
|
|
48575
|
-
|
|
48576
|
-
});
|
|
48577
|
-
}
|
|
48745
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
48746
|
+
if (!VxeTableGridComponent) {
|
|
48747
|
+
errLog('vxe.error.reqComp', ['vxe-grid']);
|
|
48748
|
+
}
|
|
48749
|
+
});
|
|
48578
48750
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeTableSelect', $xeTableSelect);
|
|
48579
48751
|
$xeTableSelect.renderVN = renderVN;
|
|
48580
48752
|
return $xeTableSelect;
|
|
@@ -48674,7 +48846,7 @@ const Tabs = VxeTabs;
|
|
|
48674
48846
|
class: 'vxe-tag--icon'
|
|
48675
48847
|
}, iconSlot ? getSlotVNs(iconSlot({})) : [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
48676
48848
|
class: icon
|
|
48677
|
-
})]) : (
|
|
48849
|
+
})]) : renderEmptyElement($xeTag), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
48678
48850
|
class: 'vxe-tag--content'
|
|
48679
48851
|
}, defaultSlot ? defaultSlot({}) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(content))];
|
|
48680
48852
|
};
|