vxe-pc-ui 4.18.16 → 4.18.18
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/dist/all.esm.js +72 -78
- package/dist/style.css +1 -1
- package/dist/style.min.css +1 -1
- package/es/calendar/src/calendar.js +11 -13
- package/es/date-panel/src/date-panel.js +17 -14
- package/es/date-picker/src/date-picker.js +14 -17
- package/es/date-range-picker/src/date-range-picker.js +10 -12
- package/es/drawer/src/drawer.js +6 -6
- package/es/icon/style.css +1 -1
- package/es/input/src/input.js +12 -14
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/calendar/src/calendar.js +11 -17
- package/lib/calendar/src/calendar.min.js +1 -1
- package/lib/date-panel/src/date-panel.js +16 -18
- package/lib/date-panel/src/date-panel.min.js +1 -1
- package/lib/date-picker/src/date-picker.js +14 -18
- package/lib/date-picker/src/date-picker.min.js +1 -1
- package/lib/date-range-picker/src/date-range-picker.js +10 -12
- package/lib/date-range-picker/src/date-range-picker.min.js +1 -1
- package/lib/drawer/src/drawer.js +6 -8
- package/lib/drawer/src/drawer.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +71 -93
- package/lib/index.umd.min.js +1 -1
- package/lib/input/src/input.js +12 -18
- package/lib/input/src/input.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/package.json +3 -4
- package/packages/calendar/src/calendar.ts +12 -13
- package/packages/date-panel/src/date-panel.ts +19 -14
- package/packages/date-picker/src/date-picker.ts +15 -17
- package/packages/date-range-picker/src/date-range-picker.ts +11 -13
- package/packages/drawer/src/drawer.ts +7 -6
- package/packages/input/src/input.ts +13 -14
- package/types/components/grid.d.ts +9 -0
- /package/es/icon/{iconfont.1789913111678.ttf → iconfont.1789965685931.ttf} +0 -0
- /package/es/icon/{iconfont.1789913111678.woff → iconfont.1789965685931.woff} +0 -0
- /package/es/icon/{iconfont.1789913111678.woff2 → iconfont.1789965685931.woff2} +0 -0
- /package/es/{iconfont.1789913111678.ttf → iconfont.1789965685931.ttf} +0 -0
- /package/es/{iconfont.1789913111678.woff → iconfont.1789965685931.woff} +0 -0
- /package/es/{iconfont.1789913111678.woff2 → iconfont.1789965685931.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1789913111678.ttf → iconfont.1789965685931.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1789913111678.woff → iconfont.1789965685931.woff} +0 -0
- /package/lib/icon/style/{iconfont.1789913111678.woff2 → iconfont.1789965685931.woff2} +0 -0
- /package/lib/{iconfont.1789913111678.ttf → iconfont.1789965685931.ttf} +0 -0
- /package/lib/{iconfont.1789913111678.woff → iconfont.1789965685931.woff} +0 -0
- /package/lib/{iconfont.1789913111678.woff2 → iconfont.1789965685931.woff2} +0 -0
package/dist/all.esm.js
CHANGED
|
@@ -101,7 +101,7 @@ function checkDynamic() {
|
|
|
101
101
|
}
|
|
102
102
|
|
|
103
103
|
const { log } = VxeUI;
|
|
104
|
-
const uiVersion = `ui v${"4.18.
|
|
104
|
+
const uiVersion = `ui v${"4.18.18"}`;
|
|
105
105
|
function createComponentLog(name) {
|
|
106
106
|
const tableVersion = VxeUI.tableVersion ? `table v${VxeUI.tableVersion}` : '';
|
|
107
107
|
const ganttVersion = VxeUI.ganttVersion ? `gantt v${VxeUI.ganttVersion}` : '';
|
|
@@ -115,7 +115,7 @@ function createComponentLog(name) {
|
|
|
115
115
|
const warnLog$i = log.create('warn', uiVersion);
|
|
116
116
|
log.create('error', uiVersion);
|
|
117
117
|
|
|
118
|
-
const version = "4.18.
|
|
118
|
+
const version = "4.18.18";
|
|
119
119
|
VxeUI.uiVersion = version;
|
|
120
120
|
VxeUI.dynamicApp = dynamicApp;
|
|
121
121
|
function config(options) {
|
|
@@ -4983,14 +4983,8 @@ var VxeCalendarComponent = defineVxeComponent({
|
|
|
4983
4983
|
},
|
|
4984
4984
|
labelFormat: String,
|
|
4985
4985
|
valueFormat: String,
|
|
4986
|
-
festivalMethod:
|
|
4987
|
-
|
|
4988
|
-
default: () => getConfig$2().calendar.festivalMethod
|
|
4989
|
-
},
|
|
4990
|
-
disabledMethod: {
|
|
4991
|
-
type: Function,
|
|
4992
|
-
default: () => getConfig$2().calendar.disabledMethod
|
|
4993
|
-
},
|
|
4986
|
+
festivalMethod: Function,
|
|
4987
|
+
disabledMethod: Function,
|
|
4994
4988
|
cellStyle: [Object, Function],
|
|
4995
4989
|
menuConfig: Object,
|
|
4996
4990
|
// week
|
|
@@ -5028,6 +5022,10 @@ var VxeCalendarComponent = defineVxeComponent({
|
|
|
5028
5022
|
monthSize: 20,
|
|
5029
5023
|
quarterSize: 8
|
|
5030
5024
|
};
|
|
5025
|
+
const defaultFuncProps = {
|
|
5026
|
+
festivalMethod: getConfig$2().calendar.festivalMethod,
|
|
5027
|
+
disabledMethod: getConfig$2().calendar.disabledMethod
|
|
5028
|
+
};
|
|
5031
5029
|
const refElem = ref();
|
|
5032
5030
|
const refMaps = {
|
|
5033
5031
|
refElem
|
|
@@ -5547,9 +5545,9 @@ var VxeCalendarComponent = defineVxeComponent({
|
|
|
5547
5545
|
}
|
|
5548
5546
|
};
|
|
5549
5547
|
const isDateDisabled = (item) => {
|
|
5550
|
-
const
|
|
5548
|
+
const disbMethod = props.disabledMethod || defaultFuncProps.disabledMethod;
|
|
5551
5549
|
const { datePanelType } = reactData;
|
|
5552
|
-
return
|
|
5550
|
+
return disbMethod && disbMethod({ type: datePanelType, viewType: datePanelType, date: item.date, $calendar: $xeCalendar });
|
|
5553
5551
|
};
|
|
5554
5552
|
const changeViewEvent = (evnt) => {
|
|
5555
5553
|
const { datePanelType } = reactData;
|
|
@@ -5742,10 +5740,10 @@ var VxeCalendarComponent = defineVxeComponent({
|
|
|
5742
5740
|
}
|
|
5743
5741
|
};
|
|
5744
5742
|
const renderDateLabel = (item, label) => {
|
|
5745
|
-
const
|
|
5746
|
-
if (
|
|
5743
|
+
const flMethod = props.festivalMethod || defaultFuncProps.festivalMethod;
|
|
5744
|
+
if (flMethod) {
|
|
5747
5745
|
const { datePanelType } = reactData;
|
|
5748
|
-
const festivalRest =
|
|
5746
|
+
const festivalRest = flMethod({ type: datePanelType, viewType: datePanelType, date: item.date, $calendar: $xeCalendar });
|
|
5749
5747
|
const festivalItem = festivalRest ? (XEUtils.isString(festivalRest) ? { label: festivalRest } : festivalRest) : {};
|
|
5750
5748
|
const extraItem = festivalItem.extra ? (XEUtils.isString(festivalItem.extra) ? { label: festivalItem.extra } : festivalItem.extra) : null;
|
|
5751
5749
|
const labels = [
|
|
@@ -9292,14 +9290,8 @@ var VxeInputComponent = defineVxeComponent({
|
|
|
9292
9290
|
type: Boolean,
|
|
9293
9291
|
default: true
|
|
9294
9292
|
},
|
|
9295
|
-
festivalMethod:
|
|
9296
|
-
|
|
9297
|
-
default: () => getConfig$3().input.festivalMethod
|
|
9298
|
-
},
|
|
9299
|
-
disabledMethod: {
|
|
9300
|
-
type: Function,
|
|
9301
|
-
default: () => getConfig$3().input.disabledMethod
|
|
9302
|
-
},
|
|
9293
|
+
festivalMethod: Function,
|
|
9294
|
+
disabledMethod: Function,
|
|
9303
9295
|
// week
|
|
9304
9296
|
selectDay: {
|
|
9305
9297
|
type: [String, Number],
|
|
@@ -9376,6 +9368,10 @@ var VxeInputComponent = defineVxeComponent({
|
|
|
9376
9368
|
hpTimeout: undefined,
|
|
9377
9369
|
dnTimeout: undefined
|
|
9378
9370
|
};
|
|
9371
|
+
const defaultFuncProps = {
|
|
9372
|
+
festivalMethod: getConfig$3().input.festivalMethod,
|
|
9373
|
+
disabledMethod: getConfig$3().input.disabledMethod
|
|
9374
|
+
};
|
|
9379
9375
|
const refElem = ref();
|
|
9380
9376
|
const refInputTarget = ref();
|
|
9381
9377
|
const refInputPanel = ref();
|
|
@@ -10557,7 +10553,7 @@ var VxeInputComponent = defineVxeComponent({
|
|
|
10557
10553
|
}
|
|
10558
10554
|
};
|
|
10559
10555
|
const isDateDisabled = (item) => {
|
|
10560
|
-
const
|
|
10556
|
+
const disbMethod = props.disabledMethod || defaultFuncProps.disabledMethod;
|
|
10561
10557
|
const { datePanelType } = reactData;
|
|
10562
10558
|
const dateStartTime = computeDateStartTime.value;
|
|
10563
10559
|
const dateEndTime = computeDateEndTime.value;
|
|
@@ -10568,8 +10564,8 @@ var VxeInputComponent = defineVxeComponent({
|
|
|
10568
10564
|
if (dateEndTime && dateEndTime.getTime() < date.getTime()) {
|
|
10569
10565
|
return true;
|
|
10570
10566
|
}
|
|
10571
|
-
if (
|
|
10572
|
-
return
|
|
10567
|
+
if (disbMethod) {
|
|
10568
|
+
return disbMethod({ type: datePanelType, viewType: datePanelType, date, $input: $xeInput });
|
|
10573
10569
|
}
|
|
10574
10570
|
return false;
|
|
10575
10571
|
};
|
|
@@ -11130,10 +11126,10 @@ var VxeInputComponent = defineVxeComponent({
|
|
|
11130
11126
|
};
|
|
11131
11127
|
Object.assign($xeInput, inputMethods);
|
|
11132
11128
|
const renderDateLabel = (item, label) => {
|
|
11133
|
-
const
|
|
11134
|
-
if (
|
|
11129
|
+
const flMethod = props.festivalMethod || defaultFuncProps.festivalMethod;
|
|
11130
|
+
if (flMethod) {
|
|
11135
11131
|
const { datePanelType } = reactData;
|
|
11136
|
-
const festivalRest =
|
|
11132
|
+
const festivalRest = flMethod({ type: datePanelType, viewType: datePanelType, date: item.date, $input: $xeInput });
|
|
11137
11133
|
const festivalItem = festivalRest ? (XEUtils.isString(festivalRest) ? { label: festivalRest } : festivalRest) : {};
|
|
11138
11134
|
const extraItem = festivalItem.extra ? (XEUtils.isString(festivalItem.extra) ? { label: festivalItem.extra } : festivalItem.extra) : null;
|
|
11139
11135
|
const labels = [
|
|
@@ -18711,14 +18707,8 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18711
18707
|
valueFormat: String,
|
|
18712
18708
|
timeFormat: String,
|
|
18713
18709
|
valueSort: Boolean,
|
|
18714
|
-
festivalMethod:
|
|
18715
|
-
|
|
18716
|
-
default: () => getConfig$3().datePanel.festivalMethod
|
|
18717
|
-
},
|
|
18718
|
-
disabledMethod: {
|
|
18719
|
-
type: Function,
|
|
18720
|
-
default: () => getConfig$3().datePanel.disabledMethod
|
|
18721
|
-
},
|
|
18710
|
+
festivalMethod: Function,
|
|
18711
|
+
disabledMethod: Function,
|
|
18722
18712
|
timeConfig: Object,
|
|
18723
18713
|
// week
|
|
18724
18714
|
selectDay: {
|
|
@@ -18760,6 +18750,10 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18760
18750
|
quarterSize: 4,
|
|
18761
18751
|
hpTimeout: undefined
|
|
18762
18752
|
};
|
|
18753
|
+
const defaultFuncProps = {
|
|
18754
|
+
festivalMethod: getConfig$3().datePanel.festivalMethod,
|
|
18755
|
+
disabledMethod: getConfig$3().datePanel.disabledMethod
|
|
18756
|
+
};
|
|
18763
18757
|
const refElem = ref();
|
|
18764
18758
|
const refPanelWrapper = ref();
|
|
18765
18759
|
const refInputTimeBody = ref();
|
|
@@ -19612,11 +19606,11 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
19612
19606
|
return false;
|
|
19613
19607
|
};
|
|
19614
19608
|
const isDateDisabled = (item) => {
|
|
19615
|
-
const
|
|
19609
|
+
const disbMethod = props.disabledMethod || defaultFuncProps.disabledMethod;
|
|
19616
19610
|
const { datePanelType } = reactData;
|
|
19617
19611
|
const { date } = item;
|
|
19618
|
-
if (
|
|
19619
|
-
return
|
|
19612
|
+
if (disbMethod) {
|
|
19613
|
+
return disbMethod({ type: datePanelType, viewType: datePanelType, date, $datePanel: $xeDatePanel });
|
|
19620
19614
|
}
|
|
19621
19615
|
return false;
|
|
19622
19616
|
};
|
|
@@ -19898,11 +19892,11 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
19898
19892
|
};
|
|
19899
19893
|
Object.assign($xeDatePanel, datePanelMethods);
|
|
19900
19894
|
const renderDateLabel = (item, label) => {
|
|
19901
|
-
const
|
|
19895
|
+
const flMethod = props.festivalMethod || defaultFuncProps.festivalMethod;
|
|
19902
19896
|
const labelVNs = [];
|
|
19903
|
-
if (
|
|
19897
|
+
if (flMethod) {
|
|
19904
19898
|
const { datePanelType } = reactData;
|
|
19905
|
-
const festivalRest =
|
|
19899
|
+
const festivalRest = flMethod({ type: datePanelType, viewType: datePanelType, date: item.date, $datePanel: $xeDatePanel });
|
|
19906
19900
|
const festivalItem = festivalRest ? (XEUtils.isString(festivalRest) ? { label: festivalRest } : festivalRest) : {};
|
|
19907
19901
|
const extraItem = festivalItem.extra ? (XEUtils.isString(festivalItem.extra) ? { label: festivalItem.extra } : festivalItem.extra) : null;
|
|
19908
19902
|
labelVNs.push(h('div', {
|
|
@@ -19938,6 +19932,11 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
19938
19932
|
]));
|
|
19939
19933
|
}
|
|
19940
19934
|
}
|
|
19935
|
+
else {
|
|
19936
|
+
labelVNs.push(h('div', {
|
|
19937
|
+
class: 'vxe-date-panel--label'
|
|
19938
|
+
}, `${label}`));
|
|
19939
|
+
}
|
|
19941
19940
|
return labelVNs;
|
|
19942
19941
|
};
|
|
19943
19942
|
const renderDateDayTable = () => {
|
|
@@ -20572,22 +20571,13 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
20572
20571
|
labelFormat: String,
|
|
20573
20572
|
valueFormat: String,
|
|
20574
20573
|
timeFormat: String,
|
|
20575
|
-
parseInputMethod:
|
|
20576
|
-
type: Function,
|
|
20577
|
-
default: () => getConfig$3().datePicker.parseInputMethod
|
|
20578
|
-
},
|
|
20574
|
+
parseInputMethod: Function,
|
|
20579
20575
|
editable: {
|
|
20580
20576
|
type: Boolean,
|
|
20581
20577
|
default: true
|
|
20582
20578
|
},
|
|
20583
|
-
festivalMethod:
|
|
20584
|
-
|
|
20585
|
-
default: () => getConfig$3().datePicker.festivalMethod
|
|
20586
|
-
},
|
|
20587
|
-
disabledMethod: {
|
|
20588
|
-
type: Function,
|
|
20589
|
-
default: () => getConfig$3().datePicker.disabledMethod
|
|
20590
|
-
},
|
|
20579
|
+
festivalMethod: Function,
|
|
20580
|
+
disabledMethod: Function,
|
|
20591
20581
|
// week
|
|
20592
20582
|
selectDay: {
|
|
20593
20583
|
type: [String, Number],
|
|
@@ -20660,6 +20650,11 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
20660
20650
|
const { computeSize } = useSize(props);
|
|
20661
20651
|
const reactData = reactive(createReactData$h());
|
|
20662
20652
|
const internalData = createInternalData$g();
|
|
20653
|
+
const defaultFuncProps = {
|
|
20654
|
+
parseInputMethod: getConfig$3().datePicker.parseInputMethod,
|
|
20655
|
+
festivalMethod: getConfig$3().datePicker.festivalMethod,
|
|
20656
|
+
disabledMethod: getConfig$3().datePicker.disabledMethod
|
|
20657
|
+
};
|
|
20663
20658
|
const refElem = ref();
|
|
20664
20659
|
const refInputTarget = ref();
|
|
20665
20660
|
const refInputPanel = ref();
|
|
@@ -21014,12 +21009,13 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
21014
21009
|
handleInputLabel(panelLabel, true);
|
|
21015
21010
|
};
|
|
21016
21011
|
const afterCheckValue = (inpVal) => {
|
|
21017
|
-
const { type, editable, multiple, maskedConfig
|
|
21012
|
+
const { type, editable, multiple, maskedConfig } = props;
|
|
21018
21013
|
const { inputLabel } = internalData;
|
|
21019
21014
|
const dateLabelFormat = computeDateLabelFormat.value;
|
|
21020
21015
|
const maskedOpts = computeMaskedOpts.value;
|
|
21021
21016
|
const dateStartDate = computeDateStartDate.value;
|
|
21022
21017
|
const dateEndDate = computeDateEndDate.value;
|
|
21018
|
+
const parseInpMethod = props.parseInputMethod || defaultFuncProps.parseInputMethod;
|
|
21023
21019
|
if (!inpVal) {
|
|
21024
21020
|
handleChange('', { type: 'check' });
|
|
21025
21021
|
return;
|
|
@@ -21046,8 +21042,8 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
21046
21042
|
}
|
|
21047
21043
|
}
|
|
21048
21044
|
let inpDateVal;
|
|
21049
|
-
if (
|
|
21050
|
-
inpDateVal =
|
|
21045
|
+
if (parseInpMethod) {
|
|
21046
|
+
inpDateVal = parseInpMethod({
|
|
21051
21047
|
$datePicker: $xeDatePicker,
|
|
21052
21048
|
type,
|
|
21053
21049
|
inputValue: inpVal,
|
|
@@ -21894,8 +21890,8 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
21894
21890
|
valueFormat: props.valueFormat,
|
|
21895
21891
|
timeFormat: props.timeFormat,
|
|
21896
21892
|
timeConfig: timeOpts,
|
|
21897
|
-
festivalMethod: props.festivalMethod,
|
|
21898
|
-
disabledMethod: props.disabledMethod,
|
|
21893
|
+
festivalMethod: props.festivalMethod || defaultFuncProps.festivalMethod,
|
|
21894
|
+
disabledMethod: props.disabledMethod || defaultFuncProps.disabledMethod,
|
|
21899
21895
|
selectDay: props.selectDay,
|
|
21900
21896
|
onChange: panelChangeEvent,
|
|
21901
21897
|
onConfirm: panelConfirmEvent,
|
|
@@ -22222,14 +22218,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
22222
22218
|
type: Boolean,
|
|
22223
22219
|
default: true
|
|
22224
22220
|
},
|
|
22225
|
-
festivalMethod:
|
|
22226
|
-
|
|
22227
|
-
default: () => getConfig$3().dateRangePicker.festivalMethod
|
|
22228
|
-
},
|
|
22229
|
-
disabledMethod: {
|
|
22230
|
-
type: Function,
|
|
22231
|
-
default: () => getConfig$3().dateRangePicker.disabledMethod
|
|
22232
|
-
},
|
|
22221
|
+
festivalMethod: Function,
|
|
22222
|
+
disabledMethod: Function,
|
|
22233
22223
|
separator: {
|
|
22234
22224
|
type: [String, Number],
|
|
22235
22225
|
default: () => getConfig$3().dateRangePicker.separator
|
|
@@ -22302,6 +22292,10 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
22302
22292
|
const { computeSize } = useSize(props);
|
|
22303
22293
|
const reactData = reactive(createReactData$g());
|
|
22304
22294
|
const internalData = createInternalData$f();
|
|
22295
|
+
const defaultFuncProps = {
|
|
22296
|
+
festivalMethod: getConfig$3().dateRangePicker.festivalMethod,
|
|
22297
|
+
disabledMethod: getConfig$3().dateRangePicker.disabledMethod
|
|
22298
|
+
};
|
|
22305
22299
|
const refElem = ref();
|
|
22306
22300
|
const refInputTarget = ref();
|
|
22307
22301
|
const refInputPanel = ref();
|
|
@@ -23387,8 +23381,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
23387
23381
|
defaultDate: sdDate,
|
|
23388
23382
|
defaultTime: sdTime,
|
|
23389
23383
|
timeConfig: timeOpts,
|
|
23390
|
-
festivalMethod: props.festivalMethod,
|
|
23391
|
-
disabledMethod: props.disabledMethod,
|
|
23384
|
+
festivalMethod: props.festivalMethod || defaultFuncProps.festivalMethod,
|
|
23385
|
+
disabledMethod: props.disabledMethod || defaultFuncProps.disabledMethod,
|
|
23392
23386
|
selectDay: props.selectDay,
|
|
23393
23387
|
cellClassName: panelCellClassName,
|
|
23394
23388
|
onChange: startPanelChangeEvent,
|
|
@@ -23414,8 +23408,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
23414
23408
|
defaultDate: edDate,
|
|
23415
23409
|
defaultTime: edTime,
|
|
23416
23410
|
timeConfig: timeOpts,
|
|
23417
|
-
festivalMethod: props.festivalMethod,
|
|
23418
|
-
disabledMethod: props.disabledMethod,
|
|
23411
|
+
festivalMethod: props.festivalMethod || defaultFuncProps.festivalMethod,
|
|
23412
|
+
disabledMethod: props.disabledMethod || defaultFuncProps.disabledMethod,
|
|
23419
23413
|
selectDay: props.selectDay,
|
|
23420
23414
|
cellClassName: panelCellClassName,
|
|
23421
23415
|
onChange: endPanelChangeEvent,
|
|
@@ -23887,10 +23881,7 @@ var VxeDrawerComponent = defineVxeComponent({
|
|
|
23887
23881
|
type: String,
|
|
23888
23882
|
default: () => getConfig$3().drawer.size || getConfig$3().size
|
|
23889
23883
|
},
|
|
23890
|
-
beforeHideMethod:
|
|
23891
|
-
type: Function,
|
|
23892
|
-
default: () => getConfig$3().drawer.beforeHideMethod
|
|
23893
|
-
},
|
|
23884
|
+
beforeHideMethod: Function,
|
|
23894
23885
|
slots: Object
|
|
23895
23886
|
},
|
|
23896
23887
|
emits: [
|
|
@@ -23922,6 +23913,9 @@ var VxeDrawerComponent = defineVxeComponent({
|
|
|
23922
23913
|
drawerZIndex: 0,
|
|
23923
23914
|
resizeFlag: 1
|
|
23924
23915
|
});
|
|
23916
|
+
const defaultFuncProps = {
|
|
23917
|
+
beforeHideMethod: getConfig$3().drawer.beforeHideMethod
|
|
23918
|
+
};
|
|
23925
23919
|
const refMaps = {
|
|
23926
23920
|
refElem
|
|
23927
23921
|
};
|
|
@@ -23988,11 +23982,11 @@ var VxeDrawerComponent = defineVxeComponent({
|
|
|
23988
23982
|
}
|
|
23989
23983
|
};
|
|
23990
23984
|
const closeDrawer = (type) => {
|
|
23991
|
-
const { beforeHideMethod } = props;
|
|
23992
23985
|
const { visible } = reactData;
|
|
23986
|
+
const beHideMethod = props.beforeHideMethod || defaultFuncProps.beforeHideMethod;
|
|
23993
23987
|
const params = { type };
|
|
23994
23988
|
if (visible) {
|
|
23995
|
-
Promise.resolve(
|
|
23989
|
+
Promise.resolve(beHideMethod ? beHideMethod(params) : null).then((rest) => {
|
|
23996
23990
|
if (!XEUtils.isError(rest)) {
|
|
23997
23991
|
const el = refElem.value;
|
|
23998
23992
|
if (el) {
|