@progress/kendo-react-dateinputs 5.4.0-dev.202205250548 → 5.4.0-dev.202206081230
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/cdn/js/kendo-react-dateinputs.js +1 -1
- package/dist/es/PopupSettings.js +1 -0
- package/dist/es/calendar/components/Calendar.d.ts +10 -10
- package/dist/es/calendar/components/Calendar.js +26 -12
- package/dist/es/calendar/components/CalendarCell.js +7 -3
- package/dist/es/calendar/components/CalendarHeaderTitle.js +7 -3
- package/dist/es/calendar/components/CalendarNavigationItem.js +7 -3
- package/dist/es/calendar/components/CalendarWeekCell.js +7 -3
- package/dist/es/calendar/components/Header.d.ts +5 -4
- package/dist/es/calendar/components/Header.js +8 -6
- package/dist/es/calendar/components/HorizontalViewList.d.ts +4 -4
- package/dist/es/calendar/components/HorizontalViewList.js +8 -5
- package/dist/es/calendar/components/MultiViewCalendar.d.ts +13 -13
- package/dist/es/calendar/components/MultiViewCalendar.js +24 -15
- package/dist/es/calendar/components/Navigation.d.ts +2 -2
- package/dist/es/calendar/components/Navigation.js +13 -6
- package/dist/es/calendar/components/TodayCommand.d.ts +3 -3
- package/dist/es/calendar/components/TodayCommand.js +10 -6
- package/dist/es/calendar/components/View.d.ts +11 -11
- package/dist/es/calendar/components/View.js +17 -13
- package/dist/es/calendar/components/ViewList.d.ts +9 -9
- package/dist/es/calendar/components/ViewList.js +19 -9
- package/dist/es/calendar/models/ActiveView.js +1 -0
- package/dist/es/calendar/models/CalendarSettings.js +1 -0
- package/dist/es/calendar/models/CellContext.js +1 -0
- package/dist/es/calendar/models/MultiViewCalendarMode.js +1 -0
- package/dist/es/calendar/models/MultiViewCalendarSettings.js +1 -0
- package/dist/es/calendar/models/SelectionRangeEnd.js +1 -0
- package/dist/es/calendar/models/ViewService.js +1 -0
- package/dist/es/calendar/services/BusViewService.js +1 -1
- package/dist/es/calendar/services/CenturyViewService.js +2 -2
- package/dist/es/calendar/services/DOMService.js +24 -6
- package/dist/es/calendar/services/DecadeViewService.js +2 -2
- package/dist/es/calendar/services/MonthViewService.js +2 -2
- package/dist/es/calendar/services/NavigationService.js +1 -1
- package/dist/es/calendar/services/ScrollSyncService.js +5 -1
- package/dist/es/calendar/services/YearViewService.js +2 -2
- package/dist/es/calendar/utils/ScrollSync.d.ts +3 -3
- package/dist/es/calendar/utils/ScrollSync.js +2 -0
- package/dist/es/dateinput/DateInput.d.ts +24 -20
- package/dist/es/dateinput/DateInput.js +32 -19
- package/dist/es/dateinput/models/DateInputSettings.js +1 -0
- package/dist/es/dateinput/models/format-placeholder.js +1 -0
- package/dist/es/dateinput/models/incremental-steps.js +1 -0
- package/dist/es/dateinput/models/kendo-date.d.ts +2 -2
- package/dist/es/dateinput/models/kendo-date.js +3 -3
- package/dist/es/dateinput/models/mask.js +1 -0
- package/dist/es/dateinput/models/selection.js +1 -0
- package/dist/es/dateinput/utils.d.ts +2 -2
- package/dist/es/datepicker/DatePicker.d.ts +25 -25
- package/dist/es/datepicker/DatePicker.js +28 -23
- package/dist/es/datepicker/models/DatePickerSettings.js +1 -0
- package/dist/es/datepicker/models/index.js +1 -0
- package/dist/es/daterangepicker/DateRangePicker.d.ts +16 -14
- package/dist/es/daterangepicker/DateRangePicker.js +16 -14
- package/dist/es/daterangepicker/models/DateRangePickerCalendarSettings.js +1 -0
- package/dist/es/daterangepicker/models/DateRangePickerDateInputSettings.js +1 -0
- package/dist/es/daterangepicker/models/DateRangePickerPopupSettings.js +1 -0
- package/dist/es/daterangepicker/models/DateRangePickerSettings.js +1 -0
- package/dist/es/daterangepicker/models/index.js +1 -0
- package/dist/es/datetimepicker/DateTimePicker.d.ts +19 -19
- package/dist/es/datetimepicker/DateTimePicker.js +33 -18
- package/dist/es/datetimepicker/DateTimeSelector.d.ts +7 -7
- package/dist/es/datetimepicker/DateTimeSelector.js +17 -7
- package/dist/es/datetimepicker/models/DateTimePickerSettings.js +1 -0
- package/dist/es/datetimepicker/models/index.js +1 -0
- package/dist/es/hooks/usePickerFloatingLabel.d.ts +1 -1
- package/dist/es/messages/index.d.ts +21 -21
- package/dist/es/package-metadata.js +1 -1
- package/dist/es/timepicker/TimeList.d.ts +8 -8
- package/dist/es/timepicker/TimeList.js +33 -13
- package/dist/es/timepicker/TimePart.d.ts +11 -11
- package/dist/es/timepicker/TimePart.js +14 -9
- package/dist/es/timepicker/TimePicker.d.ts +23 -23
- package/dist/es/timepicker/TimePicker.js +27 -22
- package/dist/es/timepicker/TimeSelector.d.ts +6 -6
- package/dist/es/timepicker/TimeSelector.js +11 -5
- package/dist/es/timepicker/models/IncrementalSteps.js +1 -0
- package/dist/es/timepicker/models/ListItem.js +1 -0
- package/dist/es/timepicker/models/ListService.js +1 -0
- package/dist/es/timepicker/models/ListServiceSettings.js +1 -0
- package/dist/es/timepicker/models/TimePickerSettings.js +1 -0
- package/dist/es/timepicker/services/DOMService.js +2 -0
- package/dist/es/timepicker/services/DayPeriodService.js +9 -3
- package/dist/es/timepicker/services/HoursService.js +14 -5
- package/dist/es/timepicker/services/MinutesService.js +12 -6
- package/dist/es/timepicker/services/SecondsService.js +12 -6
- package/dist/es/timepicker/utils.d.ts +4 -4
- package/dist/es/utils.d.ts +1 -1
- package/dist/es/utils.js +10 -1
- package/dist/es/virtualization/Virtualization.d.ts +9 -8
- package/dist/es/virtualization/Virtualization.js +23 -13
- package/dist/es/virtualization/services/RowHeightService.js +10 -1
- package/dist/es/virtualization/services/ScrollerService.js +9 -3
- package/dist/npm/calendar/components/Calendar.d.ts +10 -10
- package/dist/npm/calendar/components/Calendar.js +53 -38
- package/dist/npm/calendar/components/CalendarCell.js +9 -4
- package/dist/npm/calendar/components/CalendarHeaderTitle.js +8 -3
- package/dist/npm/calendar/components/CalendarNavigationItem.js +9 -4
- package/dist/npm/calendar/components/CalendarWeekCell.js +9 -4
- package/dist/npm/calendar/components/Header.d.ts +5 -4
- package/dist/npm/calendar/components/Header.js +11 -8
- package/dist/npm/calendar/components/HorizontalViewList.d.ts +4 -4
- package/dist/npm/calendar/components/HorizontalViewList.js +11 -7
- package/dist/npm/calendar/components/MultiViewCalendar.d.ts +13 -13
- package/dist/npm/calendar/components/MultiViewCalendar.js +62 -52
- package/dist/npm/calendar/components/Navigation.d.ts +2 -2
- package/dist/npm/calendar/components/Navigation.js +18 -10
- package/dist/npm/calendar/components/TodayCommand.d.ts +3 -3
- package/dist/npm/calendar/components/TodayCommand.js +16 -11
- package/dist/npm/calendar/components/View.d.ts +11 -11
- package/dist/npm/calendar/components/View.js +27 -22
- package/dist/npm/calendar/components/ViewList.d.ts +9 -9
- package/dist/npm/calendar/components/ViewList.js +29 -18
- package/dist/npm/calendar/models/CalendarViewEnum.js +1 -0
- package/dist/npm/calendar/models/NavigationAction.js +1 -0
- package/dist/npm/calendar/models/SelectionRange.js +1 -0
- package/dist/npm/calendar/models/index.js +4 -3
- package/dist/npm/calendar/services/BusViewService.js +3 -2
- package/dist/npm/calendar/services/CenturyViewService.js +40 -39
- package/dist/npm/calendar/services/DOMService.js +34 -15
- package/dist/npm/calendar/services/DecadeViewService.js +34 -33
- package/dist/npm/calendar/services/MonthViewService.js +38 -37
- package/dist/npm/calendar/services/NavigationService.js +2 -1
- package/dist/npm/calendar/services/ScrollSyncService.js +6 -1
- package/dist/npm/calendar/services/WeekNamesService.js +2 -1
- package/dist/npm/calendar/services/YearViewService.js +35 -34
- package/dist/npm/calendar/services/index.js +10 -9
- package/dist/npm/calendar/utils/ScrollSync.d.ts +3 -3
- package/dist/npm/calendar/utils/ScrollSync.js +2 -0
- package/dist/npm/common/PickerWrap.js +2 -1
- package/dist/npm/dateinput/DateInput.d.ts +24 -20
- package/dist/npm/dateinput/DateInput.js +51 -37
- package/dist/npm/dateinput/models/index.js +3 -2
- package/dist/npm/dateinput/models/kendo-date.d.ts +2 -2
- package/dist/npm/dateinput/models/kendo-date.js +15 -14
- package/dist/npm/dateinput/models/mask.js +2 -0
- package/dist/npm/dateinput/utils.d.ts +2 -2
- package/dist/npm/dateinput/utils.js +9 -4
- package/dist/npm/datepicker/DatePicker.d.ts +25 -25
- package/dist/npm/datepicker/DatePicker.js +42 -36
- package/dist/npm/datepicker/ToggleButton.js +1 -0
- package/dist/npm/daterangepicker/DateRangePicker.d.ts +16 -14
- package/dist/npm/daterangepicker/DateRangePicker.js +34 -31
- package/dist/npm/datetimepicker/DateTimePicker.d.ts +19 -19
- package/dist/npm/datetimepicker/DateTimePicker.js +46 -30
- package/dist/npm/datetimepicker/DateTimeSelector.d.ts +7 -7
- package/dist/npm/datetimepicker/DateTimeSelector.js +26 -15
- package/dist/npm/defaults.js +1 -0
- package/dist/npm/hooks/usePickerFloatingLabel.d.ts +1 -1
- package/dist/npm/hooks/usePickerFloatingLabel.js +6 -3
- package/dist/npm/main.js +22 -21
- package/dist/npm/messages/index.d.ts +21 -21
- package/dist/npm/messages/index.js +2 -1
- package/dist/npm/package-metadata.js +2 -1
- package/dist/npm/timepicker/TimeList.d.ts +8 -8
- package/dist/npm/timepicker/TimeList.js +39 -18
- package/dist/npm/timepicker/TimePart.d.ts +11 -11
- package/dist/npm/timepicker/TimePart.js +25 -19
- package/dist/npm/timepicker/TimePicker.d.ts +23 -23
- package/dist/npm/timepicker/TimePicker.js +43 -37
- package/dist/npm/timepicker/TimeSelector.d.ts +6 -6
- package/dist/npm/timepicker/TimeSelector.js +22 -15
- package/dist/npm/timepicker/models/TimePart.js +1 -0
- package/dist/npm/timepicker/models/index.js +2 -1
- package/dist/npm/timepicker/services/DOMService.js +7 -4
- package/dist/npm/timepicker/services/DayPeriodService.js +11 -4
- package/dist/npm/timepicker/services/HoursService.js +21 -11
- package/dist/npm/timepicker/services/MinutesService.js +17 -10
- package/dist/npm/timepicker/services/SecondsService.js +17 -10
- package/dist/npm/timepicker/services/index.js +6 -5
- package/dist/npm/timepicker/utils.d.ts +4 -4
- package/dist/npm/timepicker/utils.js +30 -20
- package/dist/npm/utils.d.ts +1 -1
- package/dist/npm/utils.js +43 -20
- package/dist/npm/virtualization/Virtualization.d.ts +9 -8
- package/dist/npm/virtualization/Virtualization.js +27 -16
- package/dist/npm/virtualization/services/RowHeightService.js +11 -1
- package/dist/npm/virtualization/services/ScrollerService.js +10 -3
- package/dist/npm/virtualization/services/index.js +5 -4
- package/dist/systemjs/kendo-react-dateinputs.js +1 -1
- package/package.json +13 -13
|
@@ -3,10 +3,12 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
3
3
|
var extendStatics = function (d, b) {
|
|
4
4
|
extendStatics = Object.setPrototypeOf ||
|
|
5
5
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
-
function (d, b) { for (var p in b) if (
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
7
|
return extendStatics(d, b);
|
|
8
8
|
};
|
|
9
9
|
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
10
12
|
extendStatics(d, b);
|
|
11
13
|
function __() { this.constructor = d; }
|
|
12
14
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
@@ -24,6 +26,7 @@ var __assign = (this && this.__assign) || function () {
|
|
|
24
26
|
return __assign.apply(this, arguments);
|
|
25
27
|
};
|
|
26
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.TimeSelector = exports.Direction = void 0;
|
|
27
30
|
var React = require("react");
|
|
28
31
|
var PropTypes = require("prop-types");
|
|
29
32
|
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
@@ -49,6 +52,10 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
49
52
|
__extends(TimeSelector, _super);
|
|
50
53
|
function TimeSelector(props) {
|
|
51
54
|
var _this = _super.call(this, props) || this;
|
|
55
|
+
_this._element = null;
|
|
56
|
+
_this._cancelButton = null;
|
|
57
|
+
_this._acceptButton = null;
|
|
58
|
+
_this.timePart = null;
|
|
52
59
|
_this.focusActiveList = function () {
|
|
53
60
|
if (!_this.timePart) {
|
|
54
61
|
return;
|
|
@@ -68,7 +75,7 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
68
75
|
}
|
|
69
76
|
};
|
|
70
77
|
_this.handleAccept = function (event) {
|
|
71
|
-
var value = _this.mergeValue(kendo_date_math_1.cloneDate(_this.value || utils_2.getNow()), _this.timePart ? _this.timePart.value : _this.current);
|
|
78
|
+
var value = _this.mergeValue((0, kendo_date_math_1.cloneDate)(_this.value || (0, utils_2.getNow)()), _this.timePart ? _this.timePart.value : _this.current);
|
|
72
79
|
_this.setState({ value: value });
|
|
73
80
|
_this.valueDuringOnChange = value;
|
|
74
81
|
var onChange = _this.props.onChange;
|
|
@@ -90,7 +97,7 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
90
97
|
}
|
|
91
98
|
};
|
|
92
99
|
_this.handleNowClick = function (event) {
|
|
93
|
-
var now = _this.mergeValue(kendo_date_math_1.cloneDate(_this.value || utils_2.getNow()), utils_2.getNow());
|
|
100
|
+
var now = _this.mergeValue((0, kendo_date_math_1.cloneDate)(_this.value || (0, utils_2.getNow)()), (0, utils_2.getNow)());
|
|
94
101
|
_this.setState({
|
|
95
102
|
current: now,
|
|
96
103
|
value: now
|
|
@@ -111,7 +118,7 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
111
118
|
_this.setState({ current: candidate });
|
|
112
119
|
};
|
|
113
120
|
_this.dateFormatParts = _this.intl.splitDateFormat(_this.props.format || TimeSelector.defaultProps.format);
|
|
114
|
-
_this.mergeValue = utils_2.valueMerger(utils_2.generateGetters(_this.dateFormatParts));
|
|
121
|
+
_this.mergeValue = (0, utils_2.valueMerger)((0, utils_2.generateGetters)(_this.dateFormatParts));
|
|
115
122
|
_this.hasActiveButton = _this.hasActiveButton.bind(_this);
|
|
116
123
|
_this.state = {
|
|
117
124
|
current: _this.props.value || utils_1.MIDNIGHT_DATE,
|
|
@@ -126,7 +133,7 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
126
133
|
get: function () {
|
|
127
134
|
return this._element;
|
|
128
135
|
},
|
|
129
|
-
enumerable:
|
|
136
|
+
enumerable: false,
|
|
130
137
|
configurable: true
|
|
131
138
|
});
|
|
132
139
|
Object.defineProperty(TimeSelector.prototype, "value", {
|
|
@@ -137,26 +144,26 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
137
144
|
? this.props.value
|
|
138
145
|
: this.state.value;
|
|
139
146
|
return (value !== null)
|
|
140
|
-
? kendo_date_math_1.cloneDate(value)
|
|
147
|
+
? (0, kendo_date_math_1.cloneDate)(value)
|
|
141
148
|
: null;
|
|
142
149
|
},
|
|
143
|
-
enumerable:
|
|
150
|
+
enumerable: false,
|
|
144
151
|
configurable: true
|
|
145
152
|
});
|
|
146
153
|
Object.defineProperty(TimeSelector.prototype, "intl", {
|
|
147
154
|
get: function () {
|
|
148
|
-
return kendo_react_intl_1.provideIntlService(this);
|
|
155
|
+
return (0, kendo_react_intl_1.provideIntlService)(this);
|
|
149
156
|
},
|
|
150
|
-
enumerable:
|
|
157
|
+
enumerable: false,
|
|
151
158
|
configurable: true
|
|
152
159
|
});
|
|
153
160
|
Object.defineProperty(TimeSelector.prototype, "current", {
|
|
154
161
|
get: function () {
|
|
155
162
|
return this.state.current !== null
|
|
156
|
-
? kendo_date_math_1.cloneDate(this.state.current)
|
|
163
|
+
? (0, kendo_date_math_1.cloneDate)(this.state.current)
|
|
157
164
|
: null;
|
|
158
165
|
},
|
|
159
|
-
enumerable:
|
|
166
|
+
enumerable: false,
|
|
160
167
|
configurable: true
|
|
161
168
|
});
|
|
162
169
|
/**
|
|
@@ -171,10 +178,10 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
171
178
|
TimeSelector.prototype.render = function () {
|
|
172
179
|
var _this = this;
|
|
173
180
|
var _a = this.props, format = _a.format, cancelButton = _a.cancelButton, disabled = _a.disabled, tabIndex = _a.tabIndex, className = _a.className, smoothScroll = _a.smoothScroll, min = _a.min, max = _a.max, boundRange = _a.boundRange, nowButton = _a.nowButton, steps = _a.steps;
|
|
174
|
-
var localizationService = kendo_react_intl_1.provideLocalizationService(this);
|
|
181
|
+
var localizationService = (0, kendo_react_intl_1.provideLocalizationService)(this);
|
|
175
182
|
var cancelMessage = localizationService.toLanguageString(messages_1.timePickerCancel, messages_1.messages[messages_1.timePickerCancel]);
|
|
176
183
|
var setMessage = localizationService.toLanguageString(messages_1.timePickerSet, messages_1.messages[messages_1.timePickerSet]);
|
|
177
|
-
return (React.createElement("div", { ref: function (el) { _this._element = el; }, tabIndex: !disabled ? tabIndex || 0 : undefined, className: kendo_react_common_1.classNames('k-timeselector k-reset', className, {
|
|
184
|
+
return (React.createElement("div", { ref: function (el) { _this._element = el; }, tabIndex: !disabled ? tabIndex || 0 : undefined, className: (0, kendo_react_common_1.classNames)('k-timeselector k-reset', className, {
|
|
178
185
|
'k-disabled': disabled
|
|
179
186
|
}), onKeyDown: this.handleKeyDown },
|
|
180
187
|
React.createElement(TimePart_1.TimePart, { ref: function (el) { _this.timePart = el; }, value: this.current, onChange: this.handleChange, onNowClick: this.handleNowClick, format: format, smoothScroll: smoothScroll, min: min, max: max, boundRange: boundRange, disabled: disabled, nowButton: nowButton, steps: steps, show: this.props.show }),
|
|
@@ -245,5 +252,5 @@ var TimeSelector = /** @class */ (function (_super) {
|
|
|
245
252
|
return TimeSelector;
|
|
246
253
|
}(React.Component));
|
|
247
254
|
exports.TimeSelector = TimeSelector;
|
|
248
|
-
kendo_react_intl_1.registerForIntl(TimeSelector);
|
|
249
|
-
kendo_react_intl_1.registerForLocalization(TimeSelector);
|
|
255
|
+
(0, kendo_react_intl_1.registerForIntl)(TimeSelector);
|
|
256
|
+
(0, kendo_react_intl_1.registerForLocalization)(TimeSelector);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TIME_PART = void 0;
|
|
3
4
|
var TimePart_1 = require("./TimePart");
|
|
4
|
-
exports
|
|
5
|
+
Object.defineProperty(exports, "TIME_PART", { enumerable: true, get: function () { return TimePart_1.TIME_PART; } });
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DOMService = void 0;
|
|
3
4
|
var utils_1 = require("../../utils");
|
|
4
5
|
var kendo_react_common_1 = require("@progress/kendo-react-common");
|
|
5
6
|
/**
|
|
@@ -7,6 +8,8 @@ var kendo_react_common_1 = require("@progress/kendo-react-common");
|
|
|
7
8
|
*/
|
|
8
9
|
var DOMService = /** @class */ (function () {
|
|
9
10
|
function DOMService() {
|
|
11
|
+
this.itemHeight = 0;
|
|
12
|
+
this.timeListHeight = 0;
|
|
10
13
|
this.didCalculate = false;
|
|
11
14
|
}
|
|
12
15
|
DOMService.prototype.ensureHeights = function () {
|
|
@@ -19,10 +22,10 @@ var DOMService = /** @class */ (function () {
|
|
|
19
22
|
if (!kendo_react_common_1.canUseDOM) {
|
|
20
23
|
return;
|
|
21
24
|
}
|
|
22
|
-
var div = utils_1.domContainerFactory('div');
|
|
23
|
-
var span = utils_1.domContainerFactory('span');
|
|
24
|
-
var ul = utils_1.domContainerFactory('ul');
|
|
25
|
-
var li = utils_1.domContainerFactory('li');
|
|
25
|
+
var div = (0, utils_1.domContainerFactory)('div');
|
|
26
|
+
var span = (0, utils_1.domContainerFactory)('span');
|
|
27
|
+
var ul = (0, utils_1.domContainerFactory)('ul');
|
|
28
|
+
var li = (0, utils_1.domContainerFactory)('li');
|
|
26
29
|
var listItem = function () { return li('<span>02</span>', 'k-item'); };
|
|
27
30
|
var list = function () { return ul([listItem()], 'k-reset'); };
|
|
28
31
|
var scrollable = function () { return (div([list()], 'k-content k-calendar-content k-scrollable k-time-container')); };
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DayPeriodService = void 0;
|
|
3
4
|
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
4
5
|
var setHours = function (date, hours) {
|
|
5
|
-
var clone = kendo_date_math_1.cloneDate(date);
|
|
6
|
+
var clone = (0, kendo_date_math_1.cloneDate)(date);
|
|
6
7
|
clone.setHours(hours);
|
|
7
8
|
return clone;
|
|
8
9
|
};
|
|
@@ -16,6 +17,9 @@ var inReverseRange = function (value, min, max) { return ((!min && !max) || valu
|
|
|
16
17
|
var DayPeriodService = /** @class */ (function () {
|
|
17
18
|
function DayPeriodService(intl) {
|
|
18
19
|
this.intl = intl;
|
|
20
|
+
this.min = null;
|
|
21
|
+
this.max = null;
|
|
22
|
+
this.part = null;
|
|
19
23
|
}
|
|
20
24
|
/**
|
|
21
25
|
* @hidden
|
|
@@ -44,8 +48,8 @@ var DayPeriodService = /** @class */ (function () {
|
|
|
44
48
|
* @hidden
|
|
45
49
|
*/
|
|
46
50
|
DayPeriodService.prototype.data = function (_) {
|
|
47
|
-
var names = this.part.names;
|
|
48
|
-
if (!names) {
|
|
51
|
+
var names = this.part && this.part.names;
|
|
52
|
+
if (!names || !this.min) {
|
|
49
53
|
return [];
|
|
50
54
|
}
|
|
51
55
|
var data = [];
|
|
@@ -88,7 +92,7 @@ var DayPeriodService = /** @class */ (function () {
|
|
|
88
92
|
* @hidden
|
|
89
93
|
*/
|
|
90
94
|
DayPeriodService.prototype.selectedIndex = function (value) {
|
|
91
|
-
if (!this.valueInList(value)) {
|
|
95
|
+
if (!this.valueInList(value) || !this.min) {
|
|
92
96
|
return -1;
|
|
93
97
|
}
|
|
94
98
|
var index = Math.floor(value.getHours() / 12);
|
|
@@ -98,6 +102,9 @@ var DayPeriodService = /** @class */ (function () {
|
|
|
98
102
|
* @hidden
|
|
99
103
|
*/
|
|
100
104
|
DayPeriodService.prototype.valueInList = function (value) {
|
|
105
|
+
if (!this.min || !this.max) {
|
|
106
|
+
return false;
|
|
107
|
+
}
|
|
101
108
|
var reverse = this.min.getHours() !== this.normalizedRange()[0];
|
|
102
109
|
var isInRange = reverse ? inReverseRange : inRange;
|
|
103
110
|
return isInRange(value.getHours(), this.min.getHours(), this.max.getHours());
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HoursService = void 0;
|
|
3
4
|
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
4
5
|
var utils_1 = require("../../utils");
|
|
5
6
|
var utils_2 = require("../utils");
|
|
@@ -9,8 +10,8 @@ var clamp = clampToRange(HOURS_IN_DAY);
|
|
|
9
10
|
var stepper = function (start, step) { return function (idx) { return clamp(start + (idx * step)); }; };
|
|
10
11
|
var distanceFromMin = function (value, min) { return clamp(HOURS_IN_DAY + value - min); };
|
|
11
12
|
var limit = function (borderValue) { return function (barrier, value) {
|
|
12
|
-
var useBarrier = !value || kendo_date_math_1.getDate(barrier).getTime() === kendo_date_math_1.getDate(value).getTime();
|
|
13
|
-
return useBarrier ? barrier : utils_2.setHours(barrier, borderValue);
|
|
13
|
+
var useBarrier = !value || (0, kendo_date_math_1.getDate)(barrier).getTime() === (0, kendo_date_math_1.getDate)(value).getTime();
|
|
14
|
+
return useBarrier ? barrier : (0, utils_2.setHours)(barrier, borderValue);
|
|
14
15
|
}; };
|
|
15
16
|
var limitDown = limit(0);
|
|
16
17
|
var limitUp = limit(HOURS_IN_DAY - 1);
|
|
@@ -22,9 +23,13 @@ var HoursService = /** @class */ (function () {
|
|
|
22
23
|
this.intl = intl;
|
|
23
24
|
this.boundRange = false;
|
|
24
25
|
this.insertUndividedMax = false;
|
|
26
|
+
this.min = null;
|
|
27
|
+
this.max = null;
|
|
28
|
+
this.step = 0;
|
|
29
|
+
this.toListItem = null;
|
|
25
30
|
}
|
|
26
31
|
HoursService.prototype.apply = function (value, candidate) {
|
|
27
|
-
return utils_2.setHours(value, candidate.getHours());
|
|
32
|
+
return (0, utils_2.setHours)(value, candidate.getHours());
|
|
28
33
|
};
|
|
29
34
|
HoursService.prototype.configure = function (settings) {
|
|
30
35
|
var _this = this;
|
|
@@ -32,7 +37,7 @@ var HoursService = /** @class */ (function () {
|
|
|
32
37
|
this.boundRange = boundRange;
|
|
33
38
|
this.insertUndividedMax = insertUndividedMax;
|
|
34
39
|
this.toListItem = function (hour) {
|
|
35
|
-
var date = utils_2.setHours(utils_1.MIDNIGHT_DATE, hour);
|
|
40
|
+
var date = (0, utils_2.setHours)(utils_1.MIDNIGHT_DATE, hour);
|
|
36
41
|
return {
|
|
37
42
|
text: _this.intl.formatDate(date, part.pattern),
|
|
38
43
|
value: date
|
|
@@ -46,8 +51,8 @@ var HoursService = /** @class */ (function () {
|
|
|
46
51
|
var _this = this;
|
|
47
52
|
var min = this.range(selectedValue)[0];
|
|
48
53
|
var getHour = stepper(min, this.step);
|
|
49
|
-
var convertToItem = function (idx) { return (_this.toListItem(getHour(idx))); };
|
|
50
|
-
var data = utils_2.range(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
54
|
+
var convertToItem = function (idx) { return (_this.toListItem && _this.toListItem(getHour(idx))); };
|
|
55
|
+
var data = (0, utils_2.range)(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
51
56
|
this.addLast(data);
|
|
52
57
|
if (selectedValue) {
|
|
53
58
|
this.addMissing(data, selectedValue);
|
|
@@ -55,7 +60,10 @@ var HoursService = /** @class */ (function () {
|
|
|
55
60
|
return data;
|
|
56
61
|
};
|
|
57
62
|
HoursService.prototype.isRangeChanged = function (min, max) {
|
|
58
|
-
|
|
63
|
+
if (!this.min || !this.max) {
|
|
64
|
+
return false;
|
|
65
|
+
}
|
|
66
|
+
return !(0, kendo_date_math_1.isEqual)(this.min, min) || !(0, kendo_date_math_1.isEqual)(this.max, max);
|
|
59
67
|
};
|
|
60
68
|
HoursService.prototype.limitRange = function (min, max, value) {
|
|
61
69
|
return this.boundRange ? [limitDown(min, value), limitUp(max, value)] : [min, max];
|
|
@@ -76,7 +84,7 @@ var HoursService = /** @class */ (function () {
|
|
|
76
84
|
return matchMax || !this.isMissing(value);
|
|
77
85
|
};
|
|
78
86
|
HoursService.prototype.addLast = function (data, value) {
|
|
79
|
-
if (this.insertUndividedMax && this.isLastMissing(value)) {
|
|
87
|
+
if (this.insertUndividedMax && this.isLastMissing(value) && this.toListItem) {
|
|
80
88
|
data.push(this.toListItem(this.lastHour(value)));
|
|
81
89
|
}
|
|
82
90
|
return data;
|
|
@@ -85,8 +93,10 @@ var HoursService = /** @class */ (function () {
|
|
|
85
93
|
if (this.valueInList(value)) {
|
|
86
94
|
return data;
|
|
87
95
|
}
|
|
88
|
-
|
|
89
|
-
|
|
96
|
+
if (this.toListItem) {
|
|
97
|
+
var missingItem = this.toListItem(value.getHours());
|
|
98
|
+
data.splice(this.selectedIndex(value), 0, missingItem);
|
|
99
|
+
}
|
|
90
100
|
return data;
|
|
91
101
|
};
|
|
92
102
|
HoursService.prototype.countFromMin = function (value) {
|
|
@@ -100,7 +110,7 @@ var HoursService = /** @class */ (function () {
|
|
|
100
110
|
return this.selectedIndex(value) !== this.divideByStep(value);
|
|
101
111
|
};
|
|
102
112
|
HoursService.prototype.isLastMissing = function (value) {
|
|
103
|
-
return this.isMissing(utils_2.setHours(this.max, this.lastHour(value)));
|
|
113
|
+
return this.max !== null && this.isMissing((0, utils_2.setHours)(this.max, this.lastHour(value)));
|
|
104
114
|
};
|
|
105
115
|
HoursService.prototype.divideByStep = function (value) {
|
|
106
116
|
return distanceFromMin(value.getHours(), this.min.getHours()) / this.step;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MinutesService = void 0;
|
|
3
4
|
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
4
5
|
var utils_1 = require("../../utils");
|
|
5
6
|
var utils_2 = require("../utils");
|
|
@@ -10,7 +11,7 @@ var stepper = function (start, step) { return function (idx) { return clamp(star
|
|
|
10
11
|
var distanceFromMin = function (value, min) { return clamp(MINUTES_IN_HOUR + value - min); };
|
|
11
12
|
var limit = function (borderValue) { return function (barrier, value) {
|
|
12
13
|
var useBarrier = !value || barrier.getHours() === value.getHours();
|
|
13
|
-
return useBarrier ? barrier : utils_2.setMinutes(barrier, borderValue);
|
|
14
|
+
return useBarrier ? barrier : (0, utils_2.setMinutes)(barrier, borderValue);
|
|
14
15
|
}; };
|
|
15
16
|
var limitDown = limit(0);
|
|
16
17
|
var limitUp = limit(MINUTES_IN_HOUR - 1);
|
|
@@ -20,17 +21,21 @@ var limitUp = limit(MINUTES_IN_HOUR - 1);
|
|
|
20
21
|
var MinutesService = /** @class */ (function () {
|
|
21
22
|
function MinutesService(intl) {
|
|
22
23
|
this.intl = intl;
|
|
24
|
+
this.toListItem = null;
|
|
25
|
+
this.min = null;
|
|
26
|
+
this.max = null;
|
|
27
|
+
this.step = 0;
|
|
23
28
|
this.insertUndividedMax = false;
|
|
24
29
|
}
|
|
25
30
|
MinutesService.prototype.apply = function (value, candidate) {
|
|
26
|
-
return utils_2.setMinutes(value, candidate.getMinutes());
|
|
31
|
+
return (0, utils_2.setMinutes)(value, candidate.getMinutes());
|
|
27
32
|
};
|
|
28
33
|
MinutesService.prototype.configure = function (settings) {
|
|
29
34
|
var _this = this;
|
|
30
35
|
var _a = settings.insertUndividedMax, insertUndividedMax = _a === void 0 ? this.insertUndividedMax : _a, _b = settings.min, min = _b === void 0 ? this.min : _b, _c = settings.max, max = _c === void 0 ? this.max : _c, part = settings.part, _d = settings.step, step = _d === void 0 ? this.step : _d;
|
|
31
36
|
this.insertUndividedMax = insertUndividedMax;
|
|
32
37
|
this.toListItem = function (minute) {
|
|
33
|
-
var date = utils_2.setMinutes(utils_1.MIDNIGHT_DATE, minute);
|
|
38
|
+
var date = (0, utils_2.setMinutes)(utils_1.MIDNIGHT_DATE, minute);
|
|
34
39
|
return {
|
|
35
40
|
text: _this.intl.formatDate(date, part.pattern),
|
|
36
41
|
value: date
|
|
@@ -44,8 +49,8 @@ var MinutesService = /** @class */ (function () {
|
|
|
44
49
|
var _this = this;
|
|
45
50
|
var min = this.range(selectedValue)[0];
|
|
46
51
|
var getMinute = stepper(min, this.step);
|
|
47
|
-
var convertToItem = function (idx) { return (_this.toListItem(getMinute(idx))); };
|
|
48
|
-
var data = utils_2.range(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
52
|
+
var convertToItem = function (idx) { return (_this.toListItem && _this.toListItem(getMinute(idx))); };
|
|
53
|
+
var data = (0, utils_2.range)(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
49
54
|
this.addLast(data);
|
|
50
55
|
if (selectedValue) {
|
|
51
56
|
this.addMissing(data, selectedValue);
|
|
@@ -53,7 +58,7 @@ var MinutesService = /** @class */ (function () {
|
|
|
53
58
|
return data;
|
|
54
59
|
};
|
|
55
60
|
MinutesService.prototype.isRangeChanged = function (min, max) {
|
|
56
|
-
return !kendo_date_math_1.isEqual(this.min, min) || !kendo_date_math_1.isEqual(this.max, max);
|
|
61
|
+
return (this.min !== null && this.max !== null) && (!(0, kendo_date_math_1.isEqual)(this.min, min) || !(0, kendo_date_math_1.isEqual)(this.max, max));
|
|
57
62
|
};
|
|
58
63
|
MinutesService.prototype.limitRange = function (min, max, value) {
|
|
59
64
|
return [limitDown(min, value), limitUp(max, value)];
|
|
@@ -74,7 +79,7 @@ var MinutesService = /** @class */ (function () {
|
|
|
74
79
|
return matchMax || !this.isMissing(value);
|
|
75
80
|
};
|
|
76
81
|
MinutesService.prototype.addLast = function (data, value) {
|
|
77
|
-
if (this.insertUndividedMax && this.isLastMissing(value)) {
|
|
82
|
+
if (this.insertUndividedMax && this.isLastMissing(value) && this.toListItem) {
|
|
78
83
|
data.push(this.toListItem(this.lastMinute(value)));
|
|
79
84
|
}
|
|
80
85
|
return data;
|
|
@@ -83,8 +88,10 @@ var MinutesService = /** @class */ (function () {
|
|
|
83
88
|
if (this.valueInList(value)) {
|
|
84
89
|
return data;
|
|
85
90
|
}
|
|
86
|
-
|
|
87
|
-
|
|
91
|
+
if (this.toListItem) {
|
|
92
|
+
var missingItem = this.toListItem(value.getMinutes());
|
|
93
|
+
data.splice(this.selectedIndex(value), 0, missingItem);
|
|
94
|
+
}
|
|
88
95
|
return data;
|
|
89
96
|
};
|
|
90
97
|
MinutesService.prototype.countFromMin = function (value) {
|
|
@@ -98,7 +105,7 @@ var MinutesService = /** @class */ (function () {
|
|
|
98
105
|
return this.selectedIndex(value) !== this.divideByStep(value);
|
|
99
106
|
};
|
|
100
107
|
MinutesService.prototype.isLastMissing = function (value) {
|
|
101
|
-
return this.isMissing(utils_2.setMinutes(this.max, this.lastMinute(value)));
|
|
108
|
+
return this.max !== null && this.isMissing((0, utils_2.setMinutes)(this.max, this.lastMinute(value)));
|
|
102
109
|
};
|
|
103
110
|
MinutesService.prototype.divideByStep = function (value) {
|
|
104
111
|
return distanceFromMin(value.getMinutes(), this.min.getMinutes()) / this.step;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SecondsService = void 0;
|
|
3
4
|
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
4
5
|
var utils_1 = require("../../utils");
|
|
5
6
|
var utils_2 = require("../utils");
|
|
@@ -11,7 +12,7 @@ var distanceFromMin = function (value, min) { return clamp(SECONDS_IN_HOUR + val
|
|
|
11
12
|
var limit = function (borderValue) { return function (barrier, value) {
|
|
12
13
|
var useBarrier = !value ||
|
|
13
14
|
(barrier.getMinutes() === value.getMinutes() && barrier.getHours() === value.getHours());
|
|
14
|
-
return useBarrier ? barrier : utils_2.setSeconds(barrier, borderValue);
|
|
15
|
+
return useBarrier ? barrier : (0, utils_2.setSeconds)(barrier, borderValue);
|
|
15
16
|
}; };
|
|
16
17
|
var limitDown = limit(0);
|
|
17
18
|
var limitUp = limit(SECONDS_IN_HOUR - 1);
|
|
@@ -21,17 +22,21 @@ var limitUp = limit(SECONDS_IN_HOUR - 1);
|
|
|
21
22
|
var SecondsService = /** @class */ (function () {
|
|
22
23
|
function SecondsService(intl) {
|
|
23
24
|
this.intl = intl;
|
|
25
|
+
this.toListItem = null;
|
|
26
|
+
this.min = null;
|
|
27
|
+
this.max = null;
|
|
28
|
+
this.step = 0;
|
|
24
29
|
this.insertUndividedMax = false;
|
|
25
30
|
}
|
|
26
31
|
SecondsService.prototype.apply = function (value, candidate) {
|
|
27
|
-
return utils_2.setSeconds(value, candidate.getSeconds());
|
|
32
|
+
return (0, utils_2.setSeconds)(value, candidate.getSeconds());
|
|
28
33
|
};
|
|
29
34
|
SecondsService.prototype.configure = function (settings) {
|
|
30
35
|
var _this = this;
|
|
31
36
|
var _a = settings.insertUndividedMax, insertUndividedMax = _a === void 0 ? this.insertUndividedMax : _a, _b = settings.min, min = _b === void 0 ? this.min : _b, _c = settings.max, max = _c === void 0 ? this.max : _c, part = settings.part, _d = settings.step, step = _d === void 0 ? this.step : _d;
|
|
32
37
|
this.insertUndividedMax = insertUndividedMax;
|
|
33
38
|
this.toListItem = function (minute) {
|
|
34
|
-
var date = utils_2.setSeconds(utils_1.MIDNIGHT_DATE, minute);
|
|
39
|
+
var date = (0, utils_2.setSeconds)(utils_1.MIDNIGHT_DATE, minute);
|
|
35
40
|
return {
|
|
36
41
|
text: _this.intl.formatDate(date, part.pattern),
|
|
37
42
|
value: date
|
|
@@ -45,8 +50,8 @@ var SecondsService = /** @class */ (function () {
|
|
|
45
50
|
var _this = this;
|
|
46
51
|
var min = this.range(selectedValue)[0];
|
|
47
52
|
var getSecond = stepper(min, this.step);
|
|
48
|
-
var convertToItem = function (idx) { return (_this.toListItem(getSecond(idx))); };
|
|
49
|
-
var data = utils_2.range(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
53
|
+
var convertToItem = function (idx) { return (_this.toListItem && _this.toListItem(getSecond(idx))); };
|
|
54
|
+
var data = (0, utils_2.range)(0, this.countFromMin(selectedValue)).map(convertToItem);
|
|
50
55
|
this.addLast(data);
|
|
51
56
|
if (selectedValue) {
|
|
52
57
|
this.addMissing(data, selectedValue);
|
|
@@ -54,7 +59,7 @@ var SecondsService = /** @class */ (function () {
|
|
|
54
59
|
return data;
|
|
55
60
|
};
|
|
56
61
|
SecondsService.prototype.isRangeChanged = function (min, max) {
|
|
57
|
-
return !kendo_date_math_1.isEqual(this.min, min) || !kendo_date_math_1.isEqual(this.max, max);
|
|
62
|
+
return this.min !== null && this.max !== null && (!(0, kendo_date_math_1.isEqual)(this.min, min) || !(0, kendo_date_math_1.isEqual)(this.max, max));
|
|
58
63
|
};
|
|
59
64
|
SecondsService.prototype.limitRange = function (min, max, value) {
|
|
60
65
|
return [limitDown(min, value), limitUp(max, value)];
|
|
@@ -78,7 +83,7 @@ var SecondsService = /** @class */ (function () {
|
|
|
78
83
|
return distanceFromMin(value.getSeconds(), this.min.getSeconds()) / this.step;
|
|
79
84
|
};
|
|
80
85
|
SecondsService.prototype.addLast = function (data, value) {
|
|
81
|
-
if (this.insertUndividedMax && this.isLastMissing(value)) {
|
|
86
|
+
if (this.insertUndividedMax && this.isLastMissing(value) && this.toListItem) {
|
|
82
87
|
data.push(this.toListItem(this.lastSecond(value)));
|
|
83
88
|
}
|
|
84
89
|
return data;
|
|
@@ -87,8 +92,10 @@ var SecondsService = /** @class */ (function () {
|
|
|
87
92
|
if (this.valueInList(value)) {
|
|
88
93
|
return data;
|
|
89
94
|
}
|
|
90
|
-
|
|
91
|
-
|
|
95
|
+
if (this.toListItem) {
|
|
96
|
+
var missingItem = this.toListItem(value.getSeconds());
|
|
97
|
+
data.splice(this.selectedIndex(value), 0, missingItem);
|
|
98
|
+
}
|
|
92
99
|
return data;
|
|
93
100
|
};
|
|
94
101
|
SecondsService.prototype.countFromMin = function (value) {
|
|
@@ -102,7 +109,7 @@ var SecondsService = /** @class */ (function () {
|
|
|
102
109
|
return this.selectedIndex(value) !== this.divideByStep(value);
|
|
103
110
|
};
|
|
104
111
|
SecondsService.prototype.isLastMissing = function (value) {
|
|
105
|
-
return this.isMissing(utils_2.setSeconds(this.max, this.lastSecond(value)));
|
|
112
|
+
return this.max !== null && this.isMissing((0, utils_2.setSeconds)(this.max, this.lastSecond(value)));
|
|
106
113
|
};
|
|
107
114
|
SecondsService.prototype.lastSecond = function (value) {
|
|
108
115
|
return this.range(value)[1];
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SecondsService = exports.MinutesService = exports.HoursService = exports.DOMService = exports.DayPeriodService = void 0;
|
|
3
4
|
var DayPeriodService_1 = require("./DayPeriodService");
|
|
4
|
-
exports
|
|
5
|
+
Object.defineProperty(exports, "DayPeriodService", { enumerable: true, get: function () { return DayPeriodService_1.DayPeriodService; } });
|
|
5
6
|
var DOMService_1 = require("./DOMService");
|
|
6
|
-
exports
|
|
7
|
+
Object.defineProperty(exports, "DOMService", { enumerable: true, get: function () { return DOMService_1.DOMService; } });
|
|
7
8
|
var HoursService_1 = require("./HoursService");
|
|
8
|
-
exports
|
|
9
|
+
Object.defineProperty(exports, "HoursService", { enumerable: true, get: function () { return HoursService_1.HoursService; } });
|
|
9
10
|
var MinutesService_1 = require("./MinutesService");
|
|
10
|
-
exports
|
|
11
|
+
Object.defineProperty(exports, "MinutesService", { enumerable: true, get: function () { return MinutesService_1.MinutesService; } });
|
|
11
12
|
var SecondsService_1 = require("./SecondsService");
|
|
12
|
-
exports
|
|
13
|
+
Object.defineProperty(exports, "SecondsService", { enumerable: true, get: function () { return SecondsService_1.SecondsService; } });
|
|
@@ -41,16 +41,16 @@ export declare const timeInRange: (candidate: Date, min: Date, max: Date) => Dat
|
|
|
41
41
|
/**
|
|
42
42
|
* @hidden
|
|
43
43
|
*/
|
|
44
|
-
export declare const isInTimeRange: (candidate: Date, min?: Date, max?: Date) => boolean;
|
|
44
|
+
export declare const isInTimeRange: (candidate: Date | null, min?: Date, max?: Date) => boolean;
|
|
45
45
|
/**
|
|
46
46
|
* @hidden
|
|
47
47
|
*/
|
|
48
|
-
export declare const isInRange: (candidate: Date, min: Date, max: Date) => boolean;
|
|
48
|
+
export declare const isInRange: (candidate: Date | null, min: Date, max: Date) => boolean;
|
|
49
49
|
/**
|
|
50
50
|
* @hidden
|
|
51
51
|
*/
|
|
52
|
-
export declare const isSmallerThanMin: (val: Date, min: Date) => boolean;
|
|
52
|
+
export declare const isSmallerThanMin: (val: Date | null, min: Date | null) => boolean;
|
|
53
53
|
/**
|
|
54
54
|
* @hidden
|
|
55
55
|
*/
|
|
56
|
-
export declare const isBiggerThanMax: (val: Date, max: Date) => boolean;
|
|
56
|
+
export declare const isBiggerThanMax: (val: Date | null, max: Date | null) => boolean;
|