@progress/kendo-react-dateinputs 13.3.0 → 13.4.0-develop.2
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/PopupSettings.d.ts +22 -0
- package/calendar/components/Calendar.d.ts +202 -0
- package/calendar/components/Calendar.mjs +7 -7
- package/calendar/components/CalendarCell.d.ts +71 -0
- package/calendar/components/CalendarHeaderTitle.d.ts +38 -0
- package/calendar/components/CalendarNavigationItem.d.ts +39 -0
- package/calendar/components/CalendarWeekCell.d.ts +42 -0
- package/calendar/components/Header.d.ts +65 -0
- package/calendar/components/Header.mjs +3 -3
- package/calendar/components/HorizontalViewList.d.ts +80 -0
- package/calendar/components/HorizontalViewList.mjs +3 -3
- package/calendar/components/MultiViewCalendar.d.ts +226 -0
- package/calendar/components/MultiViewCalendar.js +1 -1
- package/calendar/components/MultiViewCalendar.mjs +17 -17
- package/calendar/components/Navigation.d.ts +85 -0
- package/calendar/components/TodayCommand.d.ts +46 -0
- package/calendar/components/TodayCommand.mjs +3 -3
- package/calendar/components/View.d.ts +101 -0
- package/calendar/components/ViewList.d.ts +128 -0
- package/calendar/models/ActiveView.d.ts +11 -0
- package/calendar/models/CalendarSettings.d.ts +256 -0
- package/calendar/models/CalendarViewEnum.d.ts +16 -0
- package/calendar/models/CellContext.d.ts +72 -0
- package/calendar/models/MultiViewCalendarMode.d.ts +16 -0
- package/calendar/models/MultiViewCalendarSettings.d.ts +129 -0
- package/calendar/models/NavigationAction.d.ts +22 -0
- package/calendar/models/SelectionRange.d.ts +24 -0
- package/calendar/models/SelectionRangeEnd.d.ts +11 -0
- package/calendar/models/ViewService.d.ts +32 -0
- package/calendar/models/WeekDaysFormat.d.ts +11 -0
- package/calendar/models/index.d.ts +18 -0
- package/calendar/services/BusViewService.d.ts +28 -0
- package/calendar/services/CenturyViewService.d.ts +32 -0
- package/calendar/services/CenturyViewService.mjs +4 -4
- package/calendar/services/DOMService.d.ts +36 -0
- package/calendar/services/DecadeViewService.d.ts +34 -0
- package/calendar/services/DecadeViewService.mjs +4 -4
- package/calendar/services/MonthViewService.d.ts +40 -0
- package/calendar/services/MonthViewService.mjs +2 -2
- package/calendar/services/NavigationService.d.ts +21 -0
- package/calendar/services/ScrollSyncService.d.ts +28 -0
- package/calendar/services/WeekNamesService.d.ts +17 -0
- package/calendar/services/YearViewService.d.ts +38 -0
- package/calendar/services/YearViewService.mjs +2 -2
- package/calendar/services/index.d.ts +17 -0
- package/calendar/utils/ScrollSync.d.ts +20 -0
- package/codemods/utils.js +1 -8
- package/codemods/v11/dateinput-handle.js +1 -8
- package/codemods/v11/datepicker-handle.js +1 -8
- package/common/AdaptiveMode.d.ts +22 -0
- package/common/ClearButton.d.ts +20 -0
- package/dateinput/DateInput.d.ts +248 -0
- package/dateinput/DateInput.js +1 -1
- package/dateinput/DateInput.mjs +63 -65
- package/dateinput/dateInputIntl.d.ts +30 -0
- package/dateinput/models/DateInputSettings.d.ts +107 -0
- package/dateinput/models/common-package-props.d.ts +34 -0
- package/dateinput/models/dateinput-options.d.ts +105 -0
- package/dateinput/models/format-placeholder.d.ts +46 -0
- package/dateinput/models/incremental-steps.d.ts +24 -0
- package/dateinput/models/index.d.ts +15 -0
- package/dateinput/models/kendo-date.d.ts +60 -0
- package/dateinput/models/mask.d.ts +14 -0
- package/dateinput/models/selection.d.ts +14 -0
- package/dateinput/utils.d.ts +31 -0
- package/datepicker/DatePicker.d.ts +279 -0
- package/datepicker/DatePicker.js +1 -1
- package/datepicker/DatePicker.mjs +68 -72
- package/datepicker/ToggleButton.d.ts +17 -0
- package/datepicker/models/DatePickerSettings.d.ts +248 -0
- package/datepicker/models/index.d.ts +9 -0
- package/daterangepicker/DateRangePicker.d.ts +357 -0
- package/daterangepicker/DateRangePicker.mjs +13 -13
- package/daterangepicker/models/DateRangePickerCalendarSettings.d.ts +13 -0
- package/daterangepicker/models/DateRangePickerDateInputSettings.d.ts +13 -0
- package/daterangepicker/models/DateRangePickerPopupSettings.d.ts +13 -0
- package/daterangepicker/models/DateRangePickerSettings.d.ts +129 -0
- package/daterangepicker/models/index.d.ts +12 -0
- package/datetimepicker/DateTimePicker.d.ts +420 -0
- package/datetimepicker/DateTimePicker.js +1 -1
- package/datetimepicker/DateTimePicker.mjs +16 -20
- package/datetimepicker/DateTimeSelector.d.ts +111 -0
- package/datetimepicker/DateTimeSelector.mjs +3 -3
- package/datetimepicker/models/DateTimePickerSettings.d.ts +154 -0
- package/datetimepicker/models/index.d.ts +9 -0
- package/dist/cdn/js/kendo-react-dateinputs.js +1 -1
- package/hooks/usePickerFloatingLabel.d.ts +27 -0
- package/index.d.mts +35 -4952
- package/index.d.ts +35 -4952
- package/messages/index.d.ts +132 -0
- package/package-metadata.d.ts +12 -0
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +10 -16
- package/package.json +8 -8
- package/timepicker/TimeList.d.ts +97 -0
- package/timepicker/TimeList.js +5 -5
- package/timepicker/TimeList.mjs +122 -112
- package/timepicker/TimePart.d.ts +146 -0
- package/timepicker/TimePart.mjs +3 -3
- package/timepicker/TimePicker.d.ts +417 -0
- package/timepicker/TimePicker.js +1 -1
- package/timepicker/TimePicker.mjs +64 -68
- package/timepicker/TimeSelector.d.ts +149 -0
- package/timepicker/TimeSelector.mjs +3 -3
- package/timepicker/models/IncrementalSteps.d.ts +18 -0
- package/timepicker/models/ListItem.d.ts +14 -0
- package/timepicker/models/ListService.d.ts +22 -0
- package/timepicker/models/ListServiceSettings.d.ts +19 -0
- package/timepicker/models/TimePart.d.ts +17 -0
- package/timepicker/models/TimePickerSettings.d.ts +137 -0
- package/timepicker/models/index.d.ts +14 -0
- package/timepicker/services/DOMService.d.ts +18 -0
- package/timepicker/services/DayPeriodService.d.ts +54 -0
- package/timepicker/services/HoursService.d.ts +40 -0
- package/timepicker/services/MinutesService.d.ts +39 -0
- package/timepicker/services/SecondsService.d.ts +39 -0
- package/timepicker/services/index.d.ts +13 -0
- package/timepicker/utils.d.ts +63 -0
- package/timepicker/utils.mjs +1 -1
- package/utils.d.ts +103 -0
- package/utils.js +1 -1
- package/utils.mjs +46 -46
- package/virtualization/Virtualization.d.ts +125 -0
- package/virtualization/services/ScrollerService.d.ts +56 -0
- package/virtualization/services/index.d.ts +10 -0
|
@@ -8,41 +8,41 @@
|
|
|
8
8
|
import * as n from "react";
|
|
9
9
|
import e from "prop-types";
|
|
10
10
|
import { Popup as ut } from "@progress/kendo-react-popup";
|
|
11
|
-
import { cloneDate as
|
|
12
|
-
import {
|
|
11
|
+
import { cloneDate as ie, getDate as st } from "@progress/kendo-date-math";
|
|
12
|
+
import { createPropsContext as ct, useId as dt, useAdaptiveModeContext as ft, usePropsContext as mt, canUseDOM as le, AsyncFocusBlur as pt, classNames as ue, kendoThemeMaps as se, Keys as O } from "@progress/kendo-react-common";
|
|
13
13
|
import { calendarIcon as gt } from "@progress/kendo-svg-icons";
|
|
14
14
|
import { DateInput as ht } from "../dateinput/DateInput.mjs";
|
|
15
15
|
import { Calendar as vt } from "../calendar/components/Calendar.mjs";
|
|
16
|
-
import {
|
|
16
|
+
import { MIN_DATE as bt, MAX_DATE as wt, isInDateRange as yt, setTime as Ct, nullable as r } from "../utils.mjs";
|
|
17
17
|
import { toggleCalendar as ce, messages as Dt } from "../messages/index.mjs";
|
|
18
18
|
import { useLocalization as Ot } from "@progress/kendo-react-intl";
|
|
19
|
-
import { ToggleButton as
|
|
20
|
-
import { PickerFloatingLabel as
|
|
19
|
+
import { ToggleButton as kt } from "./ToggleButton.mjs";
|
|
20
|
+
import { PickerFloatingLabel as Mt } from "../hooks/usePickerFloatingLabel.mjs";
|
|
21
21
|
import { ActionSheetContent as Pt } from "@progress/kendo-react-layout";
|
|
22
22
|
import { AdaptiveMode as Rt } from "../common/AdaptiveMode.mjs";
|
|
23
23
|
const de = n.forwardRef((a, fe) => {
|
|
24
|
-
const L =
|
|
25
|
-
defaultShow: pe =
|
|
26
|
-
defaultValue: ge =
|
|
27
|
-
dateInput: he =
|
|
28
|
-
calendar: ve =
|
|
29
|
-
toggleButton: be =
|
|
30
|
-
popup: we =
|
|
31
|
-
disabled: v =
|
|
32
|
-
format: ye =
|
|
33
|
-
max: R =
|
|
34
|
-
min: _ =
|
|
35
|
-
popupSettings: b =
|
|
36
|
-
tabIndex: Ce =
|
|
37
|
-
weekNumber: De =
|
|
38
|
-
validityStyles: K =
|
|
39
|
-
size: I =
|
|
40
|
-
rounded: S =
|
|
41
|
-
fillMode: E =
|
|
42
|
-
autoFocus: Oe =
|
|
24
|
+
const L = dt(a.id), me = Ot(), h = ft(), {
|
|
25
|
+
defaultShow: pe = i.defaultShow,
|
|
26
|
+
defaultValue: ge = i.defaultValue,
|
|
27
|
+
dateInput: he = i.dateInput,
|
|
28
|
+
calendar: ve = i.calendar,
|
|
29
|
+
toggleButton: be = i.toggleButton,
|
|
30
|
+
popup: we = i.popup,
|
|
31
|
+
disabled: v = i.disabled,
|
|
32
|
+
format: ye = i.format,
|
|
33
|
+
max: R = i.max,
|
|
34
|
+
min: _ = i.min,
|
|
35
|
+
popupSettings: b = i.popupSettings,
|
|
36
|
+
tabIndex: Ce = i.tabIndex,
|
|
37
|
+
weekNumber: De = i.weekNumber,
|
|
38
|
+
validityStyles: K = i.validityStyles,
|
|
39
|
+
size: I = i.size,
|
|
40
|
+
rounded: S = i.rounded,
|
|
41
|
+
fillMode: E = i.fillMode,
|
|
42
|
+
autoFocus: Oe = i.autoFocus,
|
|
43
43
|
show: q,
|
|
44
|
-
autoSwitchParts:
|
|
45
|
-
autoSwitchKeys:
|
|
44
|
+
autoSwitchParts: ke,
|
|
45
|
+
autoSwitchKeys: Me,
|
|
46
46
|
twoDigitYearMax: Pe,
|
|
47
47
|
ariaLabel: Re,
|
|
48
48
|
adaptive: It,
|
|
@@ -66,13 +66,13 @@ const de = n.forwardRef((a, fe) => {
|
|
|
66
66
|
onOpen: Y,
|
|
67
67
|
onClose: $,
|
|
68
68
|
...j
|
|
69
|
-
} =
|
|
70
|
-
if (
|
|
69
|
+
} = mt(_t, a), x = () => {
|
|
70
|
+
if (le)
|
|
71
71
|
return y.current && y.current.ownerDocument || window.document;
|
|
72
72
|
}, u = () => !!(g.windowWidth && h && g.windowWidth <= (h == null ? void 0 : h.medium) && a.adaptive), f = () => {
|
|
73
|
-
const t =
|
|
74
|
-
return t !== null ?
|
|
75
|
-
},
|
|
73
|
+
const t = k.current !== void 0 ? k.current : B !== void 0 ? B : g.value;
|
|
74
|
+
return t !== null ? ie(t) : null;
|
|
75
|
+
}, l = () => M.current !== void 0 ? M.current : q !== void 0 ? q : g.show, Fe = () => he || i.dateInput, Ne = () => be || i.toggleButton, ze = () => ve || i.calendar, Le = () => we || i.popup, X = () => a.required !== void 0 ? a.required : !1, T = () => {
|
|
76
76
|
const t = f() || B || null, o = _, s = R, P = yt(t, o, s), F = W !== void 0, N = (!X() || t != null) && P, z = H !== void 0 ? H : N;
|
|
77
77
|
return {
|
|
78
78
|
customError: F,
|
|
@@ -89,25 +89,25 @@ const de = n.forwardRef((a, fe) => {
|
|
|
89
89
|
}, Z = (t) => {
|
|
90
90
|
d.current = t;
|
|
91
91
|
}, m = (t) => {
|
|
92
|
-
|
|
92
|
+
l() !== t && (D({ show: t }), t && Y && Y({ target: w.current }), !t && $ && $({ target: w.current }));
|
|
93
93
|
}, We = (t) => {
|
|
94
94
|
const o = f();
|
|
95
95
|
return o && t ? Ct(t, o) : t;
|
|
96
96
|
}, He = (t) => {
|
|
97
97
|
b != null && b.onMouseDownOutside && b.onMouseDownOutside(t);
|
|
98
98
|
}, G = (t, o) => {
|
|
99
|
-
D({ value:
|
|
99
|
+
D({ value: ie(t || void 0) }), k.current = t, M.current = !1, u() || (p.current = !0), U && U({
|
|
100
100
|
syntheticEvent: o.syntheticEvent,
|
|
101
101
|
nativeEvent: o.nativeEvent,
|
|
102
102
|
value: f(),
|
|
103
|
-
show:
|
|
103
|
+
show: l(),
|
|
104
104
|
target: w.current
|
|
105
|
-
}),
|
|
105
|
+
}), k.current = void 0, M.current = void 0, m(!1);
|
|
106
106
|
}, Ue = (t) => {
|
|
107
107
|
const o = We(t.value);
|
|
108
108
|
G(o, t);
|
|
109
109
|
}, J = () => {
|
|
110
|
-
const { popupClass: t, ...o } = b, s =
|
|
110
|
+
const { popupClass: t, ...o } = b, s = l(), P = f(), F = P && st(P), N = ue(t), z = {
|
|
111
111
|
popupClass: "k-datepicker-popup",
|
|
112
112
|
show: s,
|
|
113
113
|
anchor: y.current,
|
|
@@ -133,13 +133,13 @@ const de = n.forwardRef((a, fe) => {
|
|
|
133
133
|
className: u() ? "k-calendar-lg" : "",
|
|
134
134
|
navigation: !u(),
|
|
135
135
|
onChange: Ue
|
|
136
|
-
}, ae = ze(),
|
|
137
|
-
return u() ? /* @__PURE__ */ n.createElement(ae, { _ref: Z, ...re }) : /* @__PURE__ */ n.createElement(
|
|
136
|
+
}, ae = ze(), lt = Le();
|
|
137
|
+
return u() ? /* @__PURE__ */ n.createElement(ae, { _ref: Z, ...re }) : /* @__PURE__ */ n.createElement(lt, { ...z }, /* @__PURE__ */ n.createElement(ae, { _ref: Z, ...re }));
|
|
138
138
|
}, Q = () => {
|
|
139
139
|
D({ focused: !1 }), m(!1);
|
|
140
140
|
}, Ye = () => {
|
|
141
141
|
const { windowWidth: t = 0 } = g, o = {
|
|
142
|
-
expand:
|
|
142
|
+
expand: l(),
|
|
143
143
|
onClose: Q,
|
|
144
144
|
title: _e,
|
|
145
145
|
subTitle: Ie,
|
|
@@ -151,14 +151,14 @@ const de = n.forwardRef((a, fe) => {
|
|
|
151
151
|
}, je = () => {
|
|
152
152
|
D({ focused: !0 });
|
|
153
153
|
}, Xe = () => {
|
|
154
|
-
m(!
|
|
154
|
+
m(!l());
|
|
155
155
|
}, A = () => {
|
|
156
|
-
v || (p.current = !0, m(!
|
|
156
|
+
v || (p.current = !0, m(!l()));
|
|
157
157
|
}, Ze = (t) => {
|
|
158
158
|
t.preventDefault();
|
|
159
159
|
}, Ge = (t) => {
|
|
160
160
|
const { altKey: o, keyCode: s } = t;
|
|
161
|
-
if (s === O.esc &&
|
|
161
|
+
if (s === O.esc && l()) {
|
|
162
162
|
p.current = !0, m(!1);
|
|
163
163
|
return;
|
|
164
164
|
}
|
|
@@ -181,7 +181,7 @@ const de = n.forwardRef((a, fe) => {
|
|
|
181
181
|
return a.name;
|
|
182
182
|
},
|
|
183
183
|
get show() {
|
|
184
|
-
return
|
|
184
|
+
return l();
|
|
185
185
|
},
|
|
186
186
|
get validity() {
|
|
187
187
|
return T();
|
|
@@ -197,7 +197,7 @@ const de = n.forwardRef((a, fe) => {
|
|
|
197
197
|
focus: qe
|
|
198
198
|
})
|
|
199
199
|
), n.useImperativeHandle(fe, () => w.current);
|
|
200
|
-
const
|
|
200
|
+
const k = n.useRef(void 0), M = n.useRef(void 0), Je = n.useRef(null), p = n.useRef(!1), V = n.useRef(!1), C = n.useRef(null), [g, Qe] = n.useState({
|
|
201
201
|
value: ge,
|
|
202
202
|
show: pe,
|
|
203
203
|
focused: !1
|
|
@@ -205,17 +205,17 @@ const de = n.forwardRef((a, fe) => {
|
|
|
205
205
|
Qe((o) => ({ ...o, ...t }));
|
|
206
206
|
};
|
|
207
207
|
n.useEffect(() => {
|
|
208
|
-
d.current && d.current.element &&
|
|
208
|
+
d.current && d.current.element && l() && !V.current && d.current.element.focus({ preventScroll: !0 }), u() && l() && !V.current && setTimeout(() => {
|
|
209
209
|
d.current && d.current.element && d.current.element.focus({ preventScroll: !0 });
|
|
210
|
-
}, 300), c.current && c.current.element && !
|
|
210
|
+
}, 300), c.current && c.current.element && !l() && p.current && c.current.element.focus({ preventScroll: !0 }), V.current = l(), p.current = !1;
|
|
211
211
|
}), n.useEffect(() => {
|
|
212
212
|
var t;
|
|
213
|
-
return C.current =
|
|
213
|
+
return C.current = le && window.ResizeObserver && new window.ResizeObserver((o) => Ke(o)), l() && et(), (t = x()) != null && t.body && C.current && C.current.observe(x().body), () => {
|
|
214
214
|
var o;
|
|
215
215
|
clearTimeout(Je.current), (o = x()) != null && o.body && C.current && C.current.disconnect();
|
|
216
216
|
};
|
|
217
217
|
}, []);
|
|
218
|
-
const ee = L + "-popup-id", tt = J(), nt = Fe(), ot = f(), rt = Ne(), at = Ye(), te = !K || T().valid, ne = me.toLanguageString(ce, Dt[ce]),
|
|
218
|
+
const ee = L + "-popup-id", tt = J(), nt = Fe(), ot = f(), rt = Ne(), at = Ye(), te = !K || T().valid, ne = me.toLanguageString(ce, Dt[ce]), it = {
|
|
219
219
|
disabled: v,
|
|
220
220
|
format: ye,
|
|
221
221
|
formatPlaceholder: Se,
|
|
@@ -229,7 +229,7 @@ const de = n.forwardRef((a, fe) => {
|
|
|
229
229
|
onChange: $e,
|
|
230
230
|
required: a.required,
|
|
231
231
|
_ref: c,
|
|
232
|
-
tabIndex:
|
|
232
|
+
tabIndex: l() ? -1 : Ce,
|
|
233
233
|
title: a.title,
|
|
234
234
|
valid: T().valid,
|
|
235
235
|
validationMessage: W,
|
|
@@ -237,20 +237,17 @@ const de = n.forwardRef((a, fe) => {
|
|
|
237
237
|
value: ot,
|
|
238
238
|
label: void 0,
|
|
239
239
|
placeholder: g.focused ? null : Ve,
|
|
240
|
-
ariaExpanded:
|
|
241
|
-
size: null,
|
|
242
|
-
fillMode: null,
|
|
243
|
-
rounded: null,
|
|
240
|
+
ariaExpanded: l(),
|
|
244
241
|
autoFill: a.autoFill,
|
|
245
242
|
twoDigitYearMax: Pe,
|
|
246
243
|
enableMouseWheel: a.enableMouseWheel,
|
|
247
244
|
autoCorrectParts: a.autoCorrectParts,
|
|
248
|
-
autoSwitchParts:
|
|
249
|
-
autoSwitchKeys:
|
|
245
|
+
autoSwitchParts: ke,
|
|
246
|
+
autoSwitchKeys: Me,
|
|
250
247
|
allowCaretMode: a.allowCaretMode,
|
|
251
248
|
inputAttributes: Ee
|
|
252
249
|
}, oe = /* @__PURE__ */ n.createElement(
|
|
253
|
-
|
|
250
|
+
pt,
|
|
254
251
|
{
|
|
255
252
|
onFocus: je,
|
|
256
253
|
onBlur: u() ? void 0 : Q,
|
|
@@ -286,10 +283,10 @@ const de = n.forwardRef((a, fe) => {
|
|
|
286
283
|
{
|
|
287
284
|
_ref: c,
|
|
288
285
|
ariaRole: "combobox",
|
|
289
|
-
ariaExpanded:
|
|
286
|
+
ariaExpanded: l(),
|
|
290
287
|
ariaControls: ee,
|
|
291
288
|
autoFocus: Oe,
|
|
292
|
-
...
|
|
289
|
+
...it
|
|
293
290
|
}
|
|
294
291
|
),
|
|
295
292
|
/* @__PURE__ */ n.createElement(
|
|
@@ -300,7 +297,6 @@ const de = n.forwardRef((a, fe) => {
|
|
|
300
297
|
svgIcon: gt,
|
|
301
298
|
title: ne,
|
|
302
299
|
className: "k-input-button",
|
|
303
|
-
rounded: null,
|
|
304
300
|
onClick: u() ? void 0 : A,
|
|
305
301
|
"aria-label": ne,
|
|
306
302
|
fillMode: E,
|
|
@@ -311,7 +307,7 @@ const de = n.forwardRef((a, fe) => {
|
|
|
311
307
|
), u() && at)
|
|
312
308
|
);
|
|
313
309
|
return a.label ? /* @__PURE__ */ n.createElement(
|
|
314
|
-
|
|
310
|
+
Mt,
|
|
315
311
|
{
|
|
316
312
|
dateInput: c,
|
|
317
313
|
label: a.label,
|
|
@@ -384,38 +380,38 @@ de.propTypes = {
|
|
|
384
380
|
validationMessage: e.string,
|
|
385
381
|
required: e.bool,
|
|
386
382
|
valid: e.bool,
|
|
387
|
-
size: e.oneOf([
|
|
388
|
-
rounded: e.oneOf([
|
|
389
|
-
fillMode: e.oneOf([
|
|
383
|
+
size: e.oneOf(["small", "medium", "large"]),
|
|
384
|
+
rounded: e.oneOf(["small", "medium", "large", "full"]),
|
|
385
|
+
fillMode: e.oneOf(["solid", "flat", "outline"]),
|
|
390
386
|
adaptive: e.bool,
|
|
391
387
|
adaptiveTitle: e.string,
|
|
392
388
|
adaptiveSubtitle: e.string,
|
|
393
389
|
autoFocus: e.bool,
|
|
394
390
|
inputAttributes: e.object
|
|
395
391
|
};
|
|
396
|
-
const
|
|
392
|
+
const i = {
|
|
397
393
|
defaultShow: !1,
|
|
398
394
|
defaultValue: null,
|
|
399
395
|
dateInput: ht,
|
|
400
396
|
calendar: vt,
|
|
401
|
-
toggleButton:
|
|
397
|
+
toggleButton: kt,
|
|
402
398
|
popup: ut,
|
|
403
399
|
disabled: !1,
|
|
404
400
|
format: "d",
|
|
405
|
-
max:
|
|
406
|
-
min:
|
|
401
|
+
max: wt,
|
|
402
|
+
min: bt,
|
|
407
403
|
popupSettings: {},
|
|
408
404
|
tabIndex: 0,
|
|
409
405
|
weekNumber: !1,
|
|
410
406
|
validityStyles: !0,
|
|
411
|
-
size:
|
|
412
|
-
rounded:
|
|
413
|
-
fillMode:
|
|
407
|
+
size: void 0,
|
|
408
|
+
rounded: void 0,
|
|
409
|
+
fillMode: void 0,
|
|
414
410
|
autoFocus: !1
|
|
415
|
-
}, _t =
|
|
411
|
+
}, _t = ct();
|
|
416
412
|
de.displayName = "KendoReactDatePicker";
|
|
417
413
|
export {
|
|
418
414
|
de as DatePicker,
|
|
419
415
|
_t as DatePickerPropsContext,
|
|
420
|
-
|
|
416
|
+
i as datePickerDefaultProps
|
|
421
417
|
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { ButtonProps } from '@progress/kendo-react-buttons';
|
|
9
|
+
/**
|
|
10
|
+
* Represents the props of the KendoReact [Toggle Button](https://www.telerik.com/kendo-react-ui/components/dateinputs/api/togglebutton) component.
|
|
11
|
+
*/
|
|
12
|
+
export interface ToggleButtonProps extends ButtonProps {
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Represents the default `toggleButton` component rendered by the [KendoReact Scheduler DatePicker](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker).
|
|
16
|
+
*/
|
|
17
|
+
export declare const ToggleButton: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<import('@progress/kendo-react-buttons').ButtonHandle | null>>;
|
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { default as React } from 'react';
|
|
9
|
+
import { DateInputFormatPlaceholder } from '../../dateinput/models/format-placeholder.js';
|
|
10
|
+
import { DateInputsPopupSettings } from '../../PopupSettings.js';
|
|
11
|
+
import { CalendarProps } from '../../calendar/components/Calendar.js';
|
|
12
|
+
import { PopupProps } from '@progress/kendo-react-popup';
|
|
13
|
+
import { DateInputProps, MultiViewCalendarProps } from '../../index.js';
|
|
14
|
+
import { DateFormatOptions } from '@progress/kendo-react-intl';
|
|
15
|
+
import { ToggleButtonProps } from '../ToggleButton.js';
|
|
16
|
+
/**
|
|
17
|
+
* @hidden
|
|
18
|
+
*/
|
|
19
|
+
export interface DatePickerSettings {
|
|
20
|
+
/**
|
|
21
|
+
* Allows you to customize or replace the default Toggle button rendered by DatePicker.
|
|
22
|
+
* ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/custom-rendering#toc-customizing-the-toggle-button)).
|
|
23
|
+
* Example usage of the `toggleButton` property:
|
|
24
|
+
* ```jsx
|
|
25
|
+
* <DatePicker toggleButton={CustomToggleButton} />
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
toggleButton?: React.ComponentType<ToggleButtonProps>;
|
|
29
|
+
/**
|
|
30
|
+
* Allows you to customize or replace the default Calendar rendered by DatePicker.
|
|
31
|
+
* ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/custom-rendering#toc-customizing-the-calendar)).
|
|
32
|
+
* Example usage of the `calendar` property:
|
|
33
|
+
* ```jsx
|
|
34
|
+
* <DatePicker calendar={CustomCalendar} />
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
calendar?: React.ComponentType<CalendarProps<any>> | React.ComponentType<MultiViewCalendarProps<any>>;
|
|
38
|
+
/**
|
|
39
|
+
* Allows you to customize or replace the default Popup rendered by DatePicker.
|
|
40
|
+
* ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/custom-rendering#toc-customizing-the-popup)).
|
|
41
|
+
* Example usage of the `popup` property:
|
|
42
|
+
* ```jsx
|
|
43
|
+
* <DatePicker popup={CustomPopup} />
|
|
44
|
+
* ```
|
|
45
|
+
*/
|
|
46
|
+
popup?: React.ComponentType<PopupProps>;
|
|
47
|
+
/**
|
|
48
|
+
* Allows you to customize or replace the default DateInput rendered by DatePicker.
|
|
49
|
+
* ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/custom-rendering#toc-customizing-the-dateinput)).
|
|
50
|
+
* Example usage of the `dateInput` property:
|
|
51
|
+
* ```jsx
|
|
52
|
+
* <DatePicker dateInput={CustomDateInput} />
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
dateInput?: React.ComponentType<DateInputProps<any>>;
|
|
56
|
+
/**
|
|
57
|
+
* Sets the `className` of the DatePicker.
|
|
58
|
+
* Example usage of the `className` property:
|
|
59
|
+
* ```jsx
|
|
60
|
+
* <DatePicker className="custom-class" />
|
|
61
|
+
* ```
|
|
62
|
+
*/
|
|
63
|
+
className?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Sets the default state of the DatePicker upon render ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/default-value)).
|
|
66
|
+
* Example usage of the `defaultShow` property:
|
|
67
|
+
* ```jsx
|
|
68
|
+
* <DatePicker defaultShow={true} />
|
|
69
|
+
* ```
|
|
70
|
+
*/
|
|
71
|
+
defaultShow?: boolean;
|
|
72
|
+
/**
|
|
73
|
+
* Determines whether the DatePicker is disabled ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/disabled-state)).
|
|
74
|
+
* Example usage of the `disabled` property:
|
|
75
|
+
* ```jsx
|
|
76
|
+
* <DatePicker disabled={true} />
|
|
77
|
+
* ```
|
|
78
|
+
*/
|
|
79
|
+
disabled?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Specifies the focused date of the DatePicker ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/date)).
|
|
82
|
+
* Example usage of the `focusedDate` property:
|
|
83
|
+
* ```jsx
|
|
84
|
+
* <DatePicker focusedDate={new Date()} />
|
|
85
|
+
* ```
|
|
86
|
+
*/
|
|
87
|
+
focusedDate?: Date;
|
|
88
|
+
/**
|
|
89
|
+
* Specifies the date format that is used to display the input value ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/formats)).
|
|
90
|
+
* Example usage of the `format` property:
|
|
91
|
+
* ```jsx
|
|
92
|
+
* <DatePicker format="MM/dd/yyyy" />
|
|
93
|
+
* ```
|
|
94
|
+
*/
|
|
95
|
+
format?: string | DateFormatOptions;
|
|
96
|
+
/**
|
|
97
|
+
* Defines the descriptions of the format sections in the input field ([more information and examples](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/placeholders)).
|
|
98
|
+
* Example usage of the `formatPlaceholder` property:
|
|
99
|
+
* ```jsx
|
|
100
|
+
* <DatePicker formatPlaceholder="Enter date" />
|
|
101
|
+
* ```
|
|
102
|
+
*/
|
|
103
|
+
formatPlaceholder?: DateInputFormatPlaceholder;
|
|
104
|
+
/**
|
|
105
|
+
* Specifies the `id` of the DatePicker.
|
|
106
|
+
* Example usage of the `id` property:
|
|
107
|
+
* ```jsx
|
|
108
|
+
* <DatePicker id="datepicker-id" />
|
|
109
|
+
* ```
|
|
110
|
+
*/
|
|
111
|
+
id?: string;
|
|
112
|
+
/**
|
|
113
|
+
* Identifies the element(s) which will describe the component, similar to [HTML aria-describedby attribute](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_aria-describedby_attribute).
|
|
114
|
+
* For example these elements could contain error or hint message.
|
|
115
|
+
* Example usage of the `ariaDescribedBy` property:
|
|
116
|
+
* ```jsx
|
|
117
|
+
* <DatePicker ariaDescribedBy="description-id" />
|
|
118
|
+
* ```
|
|
119
|
+
*/
|
|
120
|
+
ariaDescribedBy?: string;
|
|
121
|
+
/**
|
|
122
|
+
* Identifies the element(s) which will label the component.
|
|
123
|
+
* Example usage of the `ariaLabelledBy` property:
|
|
124
|
+
* ```jsx
|
|
125
|
+
* <DatePicker ariaLabelledBy="label-id" />
|
|
126
|
+
* ```
|
|
127
|
+
*/
|
|
128
|
+
ariaLabelledBy?: string;
|
|
129
|
+
/**
|
|
130
|
+
* The accessible label of the component.
|
|
131
|
+
* Example usage of the `ariaLabel` property:
|
|
132
|
+
* ```jsx
|
|
133
|
+
* <DatePicker ariaLabel="Date Picker" />
|
|
134
|
+
* ```
|
|
135
|
+
*/
|
|
136
|
+
ariaLabel?: string;
|
|
137
|
+
/**
|
|
138
|
+
* Specifies the greatest valid date ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/date-ranges)).
|
|
139
|
+
* Example usage of the `max` property:
|
|
140
|
+
* ```jsx
|
|
141
|
+
* <DatePicker max={new Date(2099, 11, 31)} />
|
|
142
|
+
* ```
|
|
143
|
+
*/
|
|
144
|
+
max?: Date;
|
|
145
|
+
/**
|
|
146
|
+
* Specifies the smallest valid date ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/date-ranges)).
|
|
147
|
+
* Example usage of the `min` property:
|
|
148
|
+
* ```jsx
|
|
149
|
+
* <DatePicker min={new Date(1900, 0, 1)} />
|
|
150
|
+
* ```
|
|
151
|
+
*/
|
|
152
|
+
min?: Date;
|
|
153
|
+
/**
|
|
154
|
+
* Specifies the `name` property of the `input` DOM element.
|
|
155
|
+
* Example usage of the `name` property:
|
|
156
|
+
* ```jsx
|
|
157
|
+
* <DatePicker name="datepicker-name" />
|
|
158
|
+
* ```
|
|
159
|
+
*/
|
|
160
|
+
name?: string;
|
|
161
|
+
/**
|
|
162
|
+
* Fires each time any of the DatePicker elements gets blurred.
|
|
163
|
+
* Example usage of the `onBlur` property:
|
|
164
|
+
* ```jsx
|
|
165
|
+
* <DatePicker onBlur={(event) => console.log('Blur event:', event)} />
|
|
166
|
+
* ```
|
|
167
|
+
*/
|
|
168
|
+
onBlur?: (event: React.FocusEvent<HTMLSpanElement | HTMLDivElement>) => void;
|
|
169
|
+
/**
|
|
170
|
+
* Fires each time the user focuses any of the DatePicker elements.
|
|
171
|
+
* Example usage of the `onFocus` property:
|
|
172
|
+
* ```jsx
|
|
173
|
+
* <DatePicker onFocus={(event) => console.log('Focus event:', event)} />
|
|
174
|
+
* ```
|
|
175
|
+
*/
|
|
176
|
+
onFocus?: (event: React.FocusEvent<HTMLSpanElement | HTMLDivElement>) => void;
|
|
177
|
+
/**
|
|
178
|
+
* Configures the popup options of the DatePicker.
|
|
179
|
+
*
|
|
180
|
+
* The available options are:
|
|
181
|
+
* - `animate: Boolean`—Controls the popup animation. By default, the open and close animations are enabled.
|
|
182
|
+
* - `appendTo`: — Defines the container to which the Popup will be appended. Defaults to [`body`](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/body).
|
|
183
|
+
* - `popupClass: String`—Specifies a list of CSS classes that are used to style the popup.
|
|
184
|
+
* Example usage of the `popupSettings` property:
|
|
185
|
+
* ```jsx
|
|
186
|
+
* <DatePicker popupSettings={{ animate: true, popupClass: 'custom-popup' }} />
|
|
187
|
+
* ```
|
|
188
|
+
*/
|
|
189
|
+
popupSettings?: DateInputsPopupSettings;
|
|
190
|
+
/**
|
|
191
|
+
* Specifies if the calendar will be displayed ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/controlled-state#toc-controlling-the-popup-state)).
|
|
192
|
+
* Example usage of the `show` property:
|
|
193
|
+
* ```jsx
|
|
194
|
+
* <DatePicker show={true} />
|
|
195
|
+
* ```
|
|
196
|
+
*/
|
|
197
|
+
show?: boolean;
|
|
198
|
+
/**
|
|
199
|
+
* Sets the `tabIndex` property of the DatePicker.
|
|
200
|
+
* Example usage of the `tabIndex` property:
|
|
201
|
+
* ```jsx
|
|
202
|
+
* <DatePicker tabIndex={0} />
|
|
203
|
+
* ```
|
|
204
|
+
*/
|
|
205
|
+
tabIndex?: number;
|
|
206
|
+
/**
|
|
207
|
+
* Sets the title of the `input` element of the DatePicker.
|
|
208
|
+
* Example usage of the `title` property:
|
|
209
|
+
* ```jsx
|
|
210
|
+
* <DatePicker title="Date Picker Title" />
|
|
211
|
+
* ```
|
|
212
|
+
*/
|
|
213
|
+
title?: string;
|
|
214
|
+
/**
|
|
215
|
+
* Determines whether to display a week number column in the `month` view of the Calendar ([see example](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/week-num-column)).
|
|
216
|
+
* Example usage of the `weekNumber` property:
|
|
217
|
+
* ```jsx
|
|
218
|
+
* <DatePicker weekNumber={true} />
|
|
219
|
+
* ```
|
|
220
|
+
*/
|
|
221
|
+
weekNumber?: boolean;
|
|
222
|
+
/**
|
|
223
|
+
* Specifies the width of the DatePicker.
|
|
224
|
+
* Example usage of the `width` property:
|
|
225
|
+
* ```jsx
|
|
226
|
+
* <DatePicker width="300px" />
|
|
227
|
+
* ```
|
|
228
|
+
*/
|
|
229
|
+
width?: number | string;
|
|
230
|
+
/**
|
|
231
|
+
* Renders a floating label for the DatePicker.
|
|
232
|
+
* Example usage of the `label` property:
|
|
233
|
+
* ```jsx
|
|
234
|
+
* <DatePicker label="Date Picker Label" />
|
|
235
|
+
* ```
|
|
236
|
+
*/
|
|
237
|
+
label?: React.ReactNode;
|
|
238
|
+
/**
|
|
239
|
+
* Specifies the hint the DateInput displays when its value is `null` or there is no partial selection.
|
|
240
|
+
* For more information, refer to the article on
|
|
241
|
+
* [placeholders](https://www.telerik.com/kendo-react-ui/components/dateinputs/datepicker/placeholders).
|
|
242
|
+
* Example usage of the `placeholder` property:
|
|
243
|
+
* ```jsx
|
|
244
|
+
* <DatePicker placeholder="Enter a date" />
|
|
245
|
+
* ```
|
|
246
|
+
*/
|
|
247
|
+
placeholder?: string | null;
|
|
248
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { DatePickerSettings } from './DatePickerSettings.js';
|
|
9
|
+
export { DatePickerSettings };
|