vxe-pc-ui 4.3.63 → 4.3.64
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/button/src/button-group.js +1 -0
- package/es/button/src/button.js +16 -5
- package/es/button/style.css +4 -3
- package/es/button/style.min.css +1 -1
- package/es/button-group/style.css +8 -2
- package/es/button-group/style.min.css +1 -1
- package/es/date-picker/src/date-picker.js +104 -32
- package/es/date-picker/style.css +37 -12
- package/es/date-picker/style.min.css +1 -1
- package/es/icon/style.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/ui/index.js +8 -2
- package/es/ui/src/log.js +1 -1
- package/es/vxe-button/style.css +4 -3
- package/es/vxe-button/style.min.css +1 -1
- package/es/vxe-button-group/style.css +8 -2
- package/es/vxe-button-group/style.min.css +1 -1
- package/es/vxe-date-picker/style.css +37 -12
- package/es/vxe-date-picker/style.min.css +1 -1
- package/lib/button/src/button-group.js +1 -0
- package/lib/button/src/button-group.min.js +1 -1
- package/lib/button/src/button.js +17 -5
- package/lib/button/src/button.min.js +1 -1
- package/lib/button/style/style.css +4 -3
- package/lib/button/style/style.min.css +1 -1
- package/lib/button-group/style/style.css +8 -2
- package/lib/button-group/style/style.min.css +1 -1
- package/lib/date-picker/src/date-picker.js +114 -31
- package/lib/date-picker/src/date-picker.min.js +1 -1
- package/lib/date-picker/style/style.css +37 -12
- package/lib/date-picker/style/style.min.css +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +141 -39
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/ui/index.js +8 -2
- 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/vxe-button/style/style.css +4 -3
- package/lib/vxe-button/style/style.min.css +1 -1
- package/lib/vxe-button-group/style/style.css +8 -2
- package/lib/vxe-button-group/style/style.min.css +1 -1
- package/lib/vxe-date-picker/style/style.css +37 -12
- package/lib/vxe-date-picker/style/style.min.css +1 -1
- package/package.json +1 -1
- package/packages/button/src/button-group.ts +1 -0
- package/packages/button/src/button.ts +17 -5
- package/packages/date-picker/src/date-picker.ts +106 -33
- package/packages/ui/index.ts +7 -1
- package/styles/components/button-group.scss +14 -2
- package/styles/components/button.scss +7 -5
- package/styles/components/date-picker.scss +33 -11
- package/types/components/button-group.d.ts +3 -1
- package/types/components/button.d.ts +2 -2
- package/types/components/date-picker.d.ts +32 -1
- /package/es/icon/{iconfont.1736058631411.ttf → iconfont.1736093254019.ttf} +0 -0
- /package/es/icon/{iconfont.1736058631411.woff → iconfont.1736093254019.woff} +0 -0
- /package/es/icon/{iconfont.1736058631411.woff2 → iconfont.1736093254019.woff2} +0 -0
- /package/es/{iconfont.1736058631411.ttf → iconfont.1736093254019.ttf} +0 -0
- /package/es/{iconfont.1736058631411.woff → iconfont.1736093254019.woff} +0 -0
- /package/es/{iconfont.1736058631411.woff2 → iconfont.1736093254019.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1736058631411.ttf → iconfont.1736093254019.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1736058631411.woff → iconfont.1736093254019.woff} +0 -0
- /package/lib/icon/style/{iconfont.1736058631411.woff2 → iconfont.1736093254019.woff2} +0 -0
- /package/lib/{iconfont.1736058631411.ttf → iconfont.1736093254019.ttf} +0 -0
- /package/lib/{iconfont.1736058631411.woff → iconfont.1736093254019.woff} +0 -0
- /package/lib/{iconfont.1736058631411.woff2 → iconfont.1736093254019.woff2} +0 -0
package/lib/index.umd.js
CHANGED
|
@@ -4141,14 +4141,14 @@ function checkDynamic() {
|
|
|
4141
4141
|
}
|
|
4142
4142
|
;// CONCATENATED MODULE: ./packages/ui/src/log.ts
|
|
4143
4143
|
|
|
4144
|
-
const log_version = `ui v${"4.3.
|
|
4144
|
+
const log_version = `ui v${"4.3.64"}`;
|
|
4145
4145
|
const warnLog = log.create('warn', log_version);
|
|
4146
4146
|
const errLog = log.create('error', log_version);
|
|
4147
4147
|
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
4148
4148
|
|
|
4149
4149
|
|
|
4150
4150
|
|
|
4151
|
-
const ui_version = "4.3.
|
|
4151
|
+
const ui_version = "4.3.64";
|
|
4152
4152
|
index_esm_VxeUI.uiVersion = ui_version;
|
|
4153
4153
|
index_esm_VxeUI.dynamicApp = dynamicApp;
|
|
4154
4154
|
function config(options) {
|
|
@@ -4229,7 +4229,13 @@ setConfig({
|
|
|
4229
4229
|
startDate: new Date(1900, 0, 1),
|
|
4230
4230
|
endDate: new Date(2100, 0, 1),
|
|
4231
4231
|
startDay: 1,
|
|
4232
|
-
selectDay: 1
|
|
4232
|
+
selectDay: 1,
|
|
4233
|
+
shortcutConfig: {
|
|
4234
|
+
// position: 'left',
|
|
4235
|
+
align: 'left',
|
|
4236
|
+
mode: 'text',
|
|
4237
|
+
autoClose: true
|
|
4238
|
+
}
|
|
4233
4239
|
},
|
|
4234
4240
|
drawer: {
|
|
4235
4241
|
// size: null,
|
|
@@ -6401,6 +6407,18 @@ function handleBooleanDefaultValue(value) {
|
|
|
6401
6407
|
}
|
|
6402
6408
|
return '';
|
|
6403
6409
|
});
|
|
6410
|
+
const computeBtnAlign = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
6411
|
+
const {
|
|
6412
|
+
align
|
|
6413
|
+
} = props;
|
|
6414
|
+
if (align) {
|
|
6415
|
+
return align;
|
|
6416
|
+
}
|
|
6417
|
+
if ($xeButtonGroup) {
|
|
6418
|
+
return $xeButtonGroup.props.align;
|
|
6419
|
+
}
|
|
6420
|
+
return false;
|
|
6421
|
+
});
|
|
6404
6422
|
const computeBtnRound = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
6405
6423
|
const {
|
|
6406
6424
|
round
|
|
@@ -6762,7 +6780,6 @@ function handleBooleanDefaultValue(value) {
|
|
|
6762
6780
|
const {
|
|
6763
6781
|
className,
|
|
6764
6782
|
popupClassName,
|
|
6765
|
-
align,
|
|
6766
6783
|
trigger,
|
|
6767
6784
|
title,
|
|
6768
6785
|
routerLink,
|
|
@@ -6780,6 +6797,7 @@ function handleBooleanDefaultValue(value) {
|
|
|
6780
6797
|
const btnMode = computeBtnMode.value;
|
|
6781
6798
|
const btnStatus = computeBtnStatus.value;
|
|
6782
6799
|
const btnRound = computeBtnRound.value;
|
|
6800
|
+
const btnAlign = computeBtnAlign.value;
|
|
6783
6801
|
const btnCircle = computeBtnCircle.value;
|
|
6784
6802
|
const btnTransfer = computeBtnTransfer.value;
|
|
6785
6803
|
const btnDisabled = computeBtnDisabled.value;
|
|
@@ -6809,7 +6827,7 @@ function handleBooleanDefaultValue(value) {
|
|
|
6809
6827
|
}]
|
|
6810
6828
|
}, [routerLink ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('router-link'), {
|
|
6811
6829
|
ref: refButton,
|
|
6812
|
-
class: ['vxe-button', 'vxe-button--link', `type--${btnMode}`,
|
|
6830
|
+
class: ['vxe-button', 'vxe-button--link', `type--${btnMode}`, btnAlign ? `align--${btnAlign}` : '', className ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(className) ? className({
|
|
6813
6831
|
$button: $xeButton
|
|
6814
6832
|
}) : className : '', {
|
|
6815
6833
|
[`size--${vSize}`]: vSize,
|
|
@@ -6834,7 +6852,7 @@ function handleBooleanDefaultValue(value) {
|
|
|
6834
6852
|
}
|
|
6835
6853
|
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('button', {
|
|
6836
6854
|
ref: refButton,
|
|
6837
|
-
class: ['vxe-button', `type--${btnMode}`,
|
|
6855
|
+
class: ['vxe-button', `type--${btnMode}`, btnAlign ? `align--${btnAlign}` : '', className ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(className) ? className({
|
|
6838
6856
|
$button: $xeButton
|
|
6839
6857
|
}) : className : '', {
|
|
6840
6858
|
[`size--${vSize}`]: vSize,
|
|
@@ -6876,7 +6894,7 @@ function handleBooleanDefaultValue(value) {
|
|
|
6876
6894
|
if (routerLink) {
|
|
6877
6895
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('router-link'), {
|
|
6878
6896
|
ref: refButton,
|
|
6879
|
-
class: ['vxe-button', 'vxe-button--link', `type--${btnMode}`,
|
|
6897
|
+
class: ['vxe-button', 'vxe-button--link', `type--${btnMode}`, btnAlign ? `align--${btnAlign}` : '', className ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(className) ? className({
|
|
6880
6898
|
$button: $xeButton
|
|
6881
6899
|
}) : className : '', {
|
|
6882
6900
|
[`size--${vSize}`]: vSize,
|
|
@@ -6902,7 +6920,7 @@ function handleBooleanDefaultValue(value) {
|
|
|
6902
6920
|
}
|
|
6903
6921
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('button', {
|
|
6904
6922
|
ref: refButton,
|
|
6905
|
-
class: ['vxe-button', `type--${btnMode}`,
|
|
6923
|
+
class: ['vxe-button', `type--${btnMode}`, btnAlign ? `align--${btnAlign}` : '', className ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(className) ? className({
|
|
6906
6924
|
$button: $xeButton
|
|
6907
6925
|
}) : className : '', {
|
|
6908
6926
|
[`size--${vSize}`]: vSize,
|
|
@@ -6968,6 +6986,7 @@ const Button = VxeButton;
|
|
|
6968
6986
|
round: Boolean,
|
|
6969
6987
|
vertical: Boolean,
|
|
6970
6988
|
circle: Boolean,
|
|
6989
|
+
align: String,
|
|
6971
6990
|
className: [String, Function],
|
|
6972
6991
|
disabled: Boolean,
|
|
6973
6992
|
permissionCode: [String, Number],
|
|
@@ -14182,6 +14201,7 @@ const Countdown = VxeCountdown;
|
|
|
14182
14201
|
|
|
14183
14202
|
|
|
14184
14203
|
|
|
14204
|
+
|
|
14185
14205
|
/* harmony default export */ var date_picker = ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
|
|
14186
14206
|
name: 'VxeDatePicker',
|
|
14187
14207
|
props: {
|
|
@@ -14262,6 +14282,7 @@ const Countdown = VxeCountdown;
|
|
|
14262
14282
|
type: Boolean,
|
|
14263
14283
|
default: null
|
|
14264
14284
|
},
|
|
14285
|
+
shortcutConfig: Object,
|
|
14265
14286
|
// 已废弃 startWeek,被 startDay 替换
|
|
14266
14287
|
startWeek: Number,
|
|
14267
14288
|
// 已废弃
|
|
@@ -14269,7 +14290,7 @@ const Countdown = VxeCountdown;
|
|
|
14269
14290
|
// 已废弃
|
|
14270
14291
|
autocomplete: String
|
|
14271
14292
|
},
|
|
14272
|
-
emits: ['update:modelValue', 'input', 'change', 'keydown', 'keyup', 'wheel', 'click', 'focus', 'blur', 'clear', 'prefix-click', 'suffix-click', 'date-prev', 'date-today', 'date-next'],
|
|
14293
|
+
emits: ['update:modelValue', 'input', 'change', 'keydown', 'keyup', 'wheel', 'click', 'focus', 'blur', 'clear', 'prefix-click', 'suffix-click', 'date-prev', 'date-today', 'date-next', 'shortcut-click'],
|
|
14273
14294
|
setup(props, context) {
|
|
14274
14295
|
const {
|
|
14275
14296
|
slots,
|
|
@@ -14787,6 +14808,9 @@ const Countdown = VxeCountdown;
|
|
|
14787
14808
|
} = props;
|
|
14788
14809
|
return immediate;
|
|
14789
14810
|
});
|
|
14811
|
+
const computeShortcutOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
14812
|
+
return Object.assign({}, getConfig().datePicker.shortcutConfig, props.shortcutConfig);
|
|
14813
|
+
});
|
|
14790
14814
|
const updateModelValue = modelValue => {
|
|
14791
14815
|
const {
|
|
14792
14816
|
isActivated,
|
|
@@ -14807,18 +14831,25 @@ const Countdown = VxeCountdown;
|
|
|
14807
14831
|
};
|
|
14808
14832
|
const parseDate = (value, format) => {
|
|
14809
14833
|
const {
|
|
14810
|
-
type
|
|
14834
|
+
type,
|
|
14835
|
+
multiple
|
|
14811
14836
|
} = props;
|
|
14812
14837
|
if (type === 'time') {
|
|
14813
14838
|
return toStringTimeDate(value);
|
|
14814
14839
|
}
|
|
14840
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(value)) {
|
|
14841
|
+
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toStringDate(value[0], format);
|
|
14842
|
+
}
|
|
14843
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(value)) {
|
|
14844
|
+
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toStringDate(multiple ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().last(value.split(',')) : value, format);
|
|
14845
|
+
}
|
|
14815
14846
|
return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toStringDate(value, format);
|
|
14816
14847
|
};
|
|
14817
14848
|
const triggerEvent = evnt => {
|
|
14818
14849
|
const {
|
|
14819
14850
|
inputValue
|
|
14820
14851
|
} = reactData;
|
|
14821
|
-
|
|
14852
|
+
dispatchEvent(evnt.type, {
|
|
14822
14853
|
value: inputValue
|
|
14823
14854
|
}, evnt);
|
|
14824
14855
|
};
|
|
@@ -14826,7 +14857,7 @@ const Countdown = VxeCountdown;
|
|
|
14826
14857
|
reactData.inputValue = value;
|
|
14827
14858
|
emit('update:modelValue', value);
|
|
14828
14859
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(props.modelValue) !== value) {
|
|
14829
|
-
|
|
14860
|
+
dispatchEvent('change', {
|
|
14830
14861
|
value
|
|
14831
14862
|
}, evnt);
|
|
14832
14863
|
// 自动更新校验状态
|
|
@@ -14845,7 +14876,7 @@ const Countdown = VxeCountdown;
|
|
|
14845
14876
|
if (inpImmediate) {
|
|
14846
14877
|
handleChange(value, evnt);
|
|
14847
14878
|
} else {
|
|
14848
|
-
|
|
14879
|
+
dispatchEvent('input', {
|
|
14849
14880
|
value
|
|
14850
14881
|
}, evnt);
|
|
14851
14882
|
}
|
|
@@ -14871,7 +14902,7 @@ const Countdown = VxeCountdown;
|
|
|
14871
14902
|
const {
|
|
14872
14903
|
inputValue
|
|
14873
14904
|
} = reactData;
|
|
14874
|
-
|
|
14905
|
+
dispatchEvent('prefix-click', {
|
|
14875
14906
|
value: inputValue
|
|
14876
14907
|
}, evnt);
|
|
14877
14908
|
}
|
|
@@ -14891,7 +14922,7 @@ const Countdown = VxeCountdown;
|
|
|
14891
14922
|
hidePanel();
|
|
14892
14923
|
}
|
|
14893
14924
|
handleChange('', evnt);
|
|
14894
|
-
|
|
14925
|
+
dispatchEvent('clear', {
|
|
14895
14926
|
value
|
|
14896
14927
|
}, evnt);
|
|
14897
14928
|
};
|
|
@@ -14901,7 +14932,7 @@ const Countdown = VxeCountdown;
|
|
|
14901
14932
|
const {
|
|
14902
14933
|
inputValue
|
|
14903
14934
|
} = reactData;
|
|
14904
|
-
|
|
14935
|
+
dispatchEvent('suffix-click', {
|
|
14905
14936
|
value: inputValue
|
|
14906
14937
|
}, evnt);
|
|
14907
14938
|
}
|
|
@@ -14980,7 +15011,7 @@ const Countdown = VxeCountdown;
|
|
|
14980
15011
|
reactData.selectMonth = month;
|
|
14981
15012
|
}
|
|
14982
15013
|
};
|
|
14983
|
-
const dateChange = date => {
|
|
15014
|
+
const dateChange = (date, isReload) => {
|
|
14984
15015
|
const {
|
|
14985
15016
|
modelValue,
|
|
14986
15017
|
multiple
|
|
@@ -15007,10 +15038,9 @@ const Countdown = VxeCountdown;
|
|
|
15007
15038
|
dateCheckMonth(date);
|
|
15008
15039
|
if (multiple) {
|
|
15009
15040
|
// 如果为多选
|
|
15010
|
-
const dateMultipleValue = computeDateMultipleValue.value;
|
|
15011
15041
|
if (isDateTimeType) {
|
|
15012
15042
|
// 如果是datetime特殊类型
|
|
15013
|
-
const dateListValue = [...computeDateListValue.value];
|
|
15043
|
+
const dateListValue = isReload ? [] : [...computeDateListValue.value];
|
|
15014
15044
|
const datetimeRest = [];
|
|
15015
15045
|
const eqIndex = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().findIndexOf(dateListValue, val => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isDateSame(date, val, 'yyyyMMdd'));
|
|
15016
15046
|
if (eqIndex === -1) {
|
|
@@ -15032,6 +15062,7 @@ const Countdown = VxeCountdown;
|
|
|
15032
15062
|
type: 'update'
|
|
15033
15063
|
});
|
|
15034
15064
|
} else {
|
|
15065
|
+
const dateMultipleValue = isReload ? [] : computeDateMultipleValue.value;
|
|
15035
15066
|
// 如果是日期类型
|
|
15036
15067
|
if (dateMultipleValue.some(val => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isEqual(val, inpVal))) {
|
|
15037
15068
|
handleChange(dateMultipleValue.filter(val => !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isEqual(val, inpVal)).join(','), {
|
|
@@ -15120,7 +15151,7 @@ const Countdown = VxeCountdown;
|
|
|
15120
15151
|
if (!reactData.visiblePanel) {
|
|
15121
15152
|
reactData.isActivated = false;
|
|
15122
15153
|
}
|
|
15123
|
-
|
|
15154
|
+
dispatchEvent('blur', {
|
|
15124
15155
|
value
|
|
15125
15156
|
}, evnt);
|
|
15126
15157
|
// 自动更新校验状态
|
|
@@ -15146,7 +15177,23 @@ const Countdown = VxeCountdown;
|
|
|
15146
15177
|
reactData.selectMonth = month;
|
|
15147
15178
|
};
|
|
15148
15179
|
const dateNowHandle = () => {
|
|
15149
|
-
const
|
|
15180
|
+
const {
|
|
15181
|
+
type
|
|
15182
|
+
} = props;
|
|
15183
|
+
const firstDayOfWeek = computeFirstDayOfWeek.value;
|
|
15184
|
+
let currentDate = new Date();
|
|
15185
|
+
switch (type) {
|
|
15186
|
+
case 'week':
|
|
15187
|
+
currentDate = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(currentDate, 0, firstDayOfWeek);
|
|
15188
|
+
break;
|
|
15189
|
+
case 'datetime':
|
|
15190
|
+
currentDate = new Date();
|
|
15191
|
+
reactData.datetimePanelValue = new Date();
|
|
15192
|
+
break;
|
|
15193
|
+
default:
|
|
15194
|
+
currentDate = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatDay(Date.now(), 0, 'first');
|
|
15195
|
+
break;
|
|
15196
|
+
}
|
|
15150
15197
|
reactData.currentDate = currentDate;
|
|
15151
15198
|
dateMonthHandle(currentDate, 0);
|
|
15152
15199
|
};
|
|
@@ -15195,7 +15242,7 @@ const Countdown = VxeCountdown;
|
|
|
15195
15242
|
}
|
|
15196
15243
|
}
|
|
15197
15244
|
reactData.selectMonth = viewDate;
|
|
15198
|
-
|
|
15245
|
+
dispatchEvent('date-prev', {
|
|
15199
15246
|
viewType: datePanelType,
|
|
15200
15247
|
viewDate,
|
|
15201
15248
|
value,
|
|
@@ -15205,11 +15252,11 @@ const Countdown = VxeCountdown;
|
|
|
15205
15252
|
};
|
|
15206
15253
|
const dateTodayMonthEvent = evnt => {
|
|
15207
15254
|
dateNowHandle();
|
|
15255
|
+
dateChange(reactData.currentDate, true);
|
|
15208
15256
|
if (!props.multiple) {
|
|
15209
|
-
dateChange(reactData.currentDate);
|
|
15210
15257
|
hidePanel();
|
|
15211
15258
|
}
|
|
15212
|
-
|
|
15259
|
+
dispatchEvent('date-today', {
|
|
15213
15260
|
type: props.type
|
|
15214
15261
|
}, evnt);
|
|
15215
15262
|
};
|
|
@@ -15247,7 +15294,7 @@ const Countdown = VxeCountdown;
|
|
|
15247
15294
|
}
|
|
15248
15295
|
}
|
|
15249
15296
|
reactData.selectMonth = viewDate;
|
|
15250
|
-
|
|
15297
|
+
dispatchEvent('date-next', {
|
|
15251
15298
|
viewType: datePanelType,
|
|
15252
15299
|
value,
|
|
15253
15300
|
type
|
|
@@ -15531,17 +15578,25 @@ const Countdown = VxeCountdown;
|
|
|
15531
15578
|
offsetMonth = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatMonth(offsetMonth, 4);
|
|
15532
15579
|
}
|
|
15533
15580
|
dateMoveMonth(offsetMonth);
|
|
15534
|
-
} else {
|
|
15581
|
+
} else if (datePanelType === 'week') {
|
|
15535
15582
|
let offsetDay = datePanelValue || external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatDay(Date.now(), 0, 'first');
|
|
15536
15583
|
const firstDayOfWeek = computeFirstDayOfWeek.value;
|
|
15584
|
+
if (isUpArrow) {
|
|
15585
|
+
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, -1, firstDayOfWeek);
|
|
15586
|
+
} else if (isDwArrow) {
|
|
15587
|
+
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, 1, firstDayOfWeek);
|
|
15588
|
+
}
|
|
15589
|
+
dateMoveDay(offsetDay);
|
|
15590
|
+
} else {
|
|
15591
|
+
let offsetDay = datePanelValue || external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatDay(Date.now(), 0, 'first');
|
|
15537
15592
|
if (isLeftArrow) {
|
|
15538
15593
|
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatDay(offsetDay, -1);
|
|
15539
15594
|
} else if (isUpArrow) {
|
|
15540
|
-
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, -1,
|
|
15595
|
+
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, -1, offsetDay.getDay());
|
|
15541
15596
|
} else if (isRightArrow) {
|
|
15542
15597
|
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatDay(offsetDay, 1);
|
|
15543
15598
|
} else if (isDwArrow) {
|
|
15544
|
-
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, 1,
|
|
15599
|
+
offsetDay = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(offsetDay, 1, offsetDay.getDay());
|
|
15545
15600
|
}
|
|
15546
15601
|
dateMoveDay(offsetDay);
|
|
15547
15602
|
}
|
|
@@ -15714,7 +15769,27 @@ const Countdown = VxeCountdown;
|
|
|
15714
15769
|
const clickEvent = evnt => {
|
|
15715
15770
|
triggerEvent(evnt);
|
|
15716
15771
|
};
|
|
15717
|
-
|
|
15772
|
+
const handleShortcutEvent = ({
|
|
15773
|
+
option,
|
|
15774
|
+
$event
|
|
15775
|
+
}) => {
|
|
15776
|
+
const shortcutOpts = computeShortcutOpts.value;
|
|
15777
|
+
const {
|
|
15778
|
+
autoClose
|
|
15779
|
+
} = shortcutOpts;
|
|
15780
|
+
const clickMethod = option.clickMethod || shortcutOpts.clickMethod;
|
|
15781
|
+
const shortcutParams = {
|
|
15782
|
+
$datePicker: $xeDatePicker,
|
|
15783
|
+
option: option
|
|
15784
|
+
};
|
|
15785
|
+
if (clickMethod) {
|
|
15786
|
+
clickMethod(shortcutParams);
|
|
15787
|
+
}
|
|
15788
|
+
if (autoClose) {
|
|
15789
|
+
hidePanel();
|
|
15790
|
+
}
|
|
15791
|
+
dispatchEvent('shortcut-click', shortcutParams, $event);
|
|
15792
|
+
};
|
|
15718
15793
|
// 全局事件
|
|
15719
15794
|
const handleGlobalMousedownEvent = evnt => {
|
|
15720
15795
|
const {
|
|
@@ -16217,6 +16292,27 @@ const Countdown = VxeCountdown;
|
|
|
16217
16292
|
}, item.label);
|
|
16218
16293
|
})) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)()])];
|
|
16219
16294
|
};
|
|
16295
|
+
const renderShortcutBtn = (pos, isVertical) => {
|
|
16296
|
+
const shortcutOpts = computeShortcutOpts.value;
|
|
16297
|
+
const {
|
|
16298
|
+
options,
|
|
16299
|
+
position,
|
|
16300
|
+
align,
|
|
16301
|
+
mode
|
|
16302
|
+
} = shortcutOpts;
|
|
16303
|
+
if (isEnableConf(shortcutOpts) && options && options.length && (position || 'left') === pos) {
|
|
16304
|
+
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16305
|
+
class: `vxe-date-picker--panel-${pos}-wrapper`
|
|
16306
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(button_group, {
|
|
16307
|
+
options,
|
|
16308
|
+
mode,
|
|
16309
|
+
align,
|
|
16310
|
+
vertical: isVertical,
|
|
16311
|
+
onClick: handleShortcutEvent
|
|
16312
|
+
})]);
|
|
16313
|
+
}
|
|
16314
|
+
return renderEmptyElement($xeDatePicker);
|
|
16315
|
+
};
|
|
16220
16316
|
const renderPanel = () => {
|
|
16221
16317
|
const {
|
|
16222
16318
|
type
|
|
@@ -16230,12 +16326,18 @@ const Countdown = VxeCountdown;
|
|
|
16230
16326
|
} = reactData;
|
|
16231
16327
|
const vSize = computeSize.value;
|
|
16232
16328
|
const btnTransfer = computeBtnTransfer.value;
|
|
16329
|
+
const shortcutOpts = computeShortcutOpts.value;
|
|
16330
|
+
const {
|
|
16331
|
+
options,
|
|
16332
|
+
position
|
|
16333
|
+
} = shortcutOpts;
|
|
16233
16334
|
const headerSlot = slots.header;
|
|
16234
16335
|
const footerSlot = slots.footer;
|
|
16235
16336
|
const topSlot = slots.top;
|
|
16236
16337
|
const bottomSlot = slots.bottom;
|
|
16237
16338
|
const leftSlot = slots.left;
|
|
16238
16339
|
const rightSlot = slots.right;
|
|
16340
|
+
const hasShortcutBtn = options && options.length;
|
|
16239
16341
|
const renders = [];
|
|
16240
16342
|
if (type === 'datetime') {
|
|
16241
16343
|
renders.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
@@ -16270,10 +16372,10 @@ const Countdown = VxeCountdown;
|
|
|
16270
16372
|
'is--transfer': btnTransfer,
|
|
16271
16373
|
'ani--leave': isAniVisible,
|
|
16272
16374
|
'ani--enter': visiblePanel,
|
|
16273
|
-
'show--top': !!(topSlot || headerSlot),
|
|
16274
|
-
'show--bottom': !!(bottomSlot || footerSlot),
|
|
16275
|
-
'show--left': !!leftSlot,
|
|
16276
|
-
'show--right': !!rightSlot
|
|
16375
|
+
'show--top': !!(topSlot || headerSlot || hasShortcutBtn && (position === 'top' || position === 'header')),
|
|
16376
|
+
'show--bottom': !!(bottomSlot || footerSlot || hasShortcutBtn && (position === 'bottom' || position === 'footer')),
|
|
16377
|
+
'show--left': !!(leftSlot || hasShortcutBtn && position === 'left'),
|
|
16378
|
+
'show--right': !!(rightSlot || hasShortcutBtn && position === 'right')
|
|
16277
16379
|
}],
|
|
16278
16380
|
placement: panelPlacement,
|
|
16279
16381
|
style: panelStyle
|
|
@@ -16281,23 +16383,23 @@ const Countdown = VxeCountdown;
|
|
|
16281
16383
|
class: 'vxe-date-picker--panel-layout-wrapper'
|
|
16282
16384
|
}, [topSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16283
16385
|
class: 'vxe-date-picker--panel-top-wrapper'
|
|
16284
|
-
}, topSlot({})) :
|
|
16386
|
+
}, topSlot({})) : renderShortcutBtn('top'), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16285
16387
|
class: 'vxe-date-picker--panel-body-layout-wrapper'
|
|
16286
16388
|
}, [leftSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16287
16389
|
class: 'vxe-date-picker--panel-left-wrapper'
|
|
16288
|
-
}, leftSlot({})) :
|
|
16390
|
+
}, leftSlot({})) : renderShortcutBtn('left', true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16289
16391
|
class: 'vxe-date-picker--panel-body-content-wrapper'
|
|
16290
16392
|
}, [headerSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16291
16393
|
class: 'vxe-date-picker--panel-header-wrapper'
|
|
16292
|
-
}, headerSlot({})) :
|
|
16394
|
+
}, headerSlot({})) : renderShortcutBtn('header'), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16293
16395
|
class: 'vxe-date-picker--panel-body-wrapper'
|
|
16294
16396
|
}, renders), footerSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16295
16397
|
class: 'vxe-date-picker--panel-footer-wrapper'
|
|
16296
|
-
}, footerSlot({})) :
|
|
16398
|
+
}, footerSlot({})) : renderShortcutBtn('footer')]), rightSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16297
16399
|
class: 'vxe-date-picker--panel-right-wrapper'
|
|
16298
|
-
}, rightSlot({})) :
|
|
16400
|
+
}, rightSlot({})) : renderShortcutBtn('right', true)]), bottomSlot ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
16299
16401
|
class: 'vxe-date-picker--panel-bottom-wrapper'
|
|
16300
|
-
}, bottomSlot({})) :
|
|
16402
|
+
}, bottomSlot({})) : renderShortcutBtn('bottom')])] : [])]);
|
|
16301
16403
|
};
|
|
16302
16404
|
const renderPrefixIcon = () => {
|
|
16303
16405
|
const {
|