@seafile/seafile-calendar 0.0.31-Apph0.58 → 0.0.31-Apph0.60
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/rc-calendar.js +8 -5
- package/dist/rc-calendar.js.map +1 -1
- package/dist/rc-calendar.min.js +1 -1
- package/es/Calendar.js +6 -2
- package/es/date/DateInput.js +2 -3
- package/lib/Calendar.js +6 -2
- package/lib/date/DateInput.js +2 -3
- package/package.json +1 -1
package/dist/rc-calendar.js
CHANGED
@@ -3081,8 +3081,12 @@ var _initialiseProps = function _initialiseProps() {
|
|
3081
3081
|
}
|
3082
3082
|
};
|
3083
3083
|
|
3084
|
-
this.onClear = function () {
|
3085
|
-
|
3084
|
+
this.onClear = function (value, shouldDisplayCurrent) {
|
3085
|
+
if (shouldDisplayCurrent) {
|
3086
|
+
_this2.onSelect(value || __WEBPACK_IMPORTED_MODULE_9_dayjs___default()());
|
3087
|
+
} else {
|
3088
|
+
_this2.onSelect(null);
|
3089
|
+
}
|
3086
3090
|
_this2.props.onClear();
|
3087
3091
|
_this2.setState({ currentStatus: 1 });
|
3088
3092
|
};
|
@@ -7419,15 +7423,14 @@ var _initialiseProps = function _initialiseProps() {
|
|
7419
7423
|
format = _props.format,
|
7420
7424
|
onChange = _props.onChange,
|
7421
7425
|
selectedValue = _props.selectedValue,
|
7422
|
-
shouldDisplayCurrent = _props.shouldDisplayCurrent
|
7423
|
-
openValue = _props.openValue;
|
7426
|
+
shouldDisplayCurrent = _props.shouldDisplayCurrent;
|
7424
7427
|
|
7425
7428
|
console.log('openValue', openValue);
|
7426
7429
|
// 没有内容,合法并直接退出
|
7427
7430
|
if (!str || !calendarStr) {
|
7428
7431
|
if (shouldDisplayCurrent) {
|
7429
7432
|
_this2.setState({ str: '' });
|
7430
|
-
|
7433
|
+
_this2.props.onClear(openValue, shouldDisplayCurrent);
|
7431
7434
|
return;
|
7432
7435
|
}
|
7433
7436
|
_this2.onClear();
|