@mui/x-date-pickers-pro 7.0.0-alpha.1 → 7.0.0-alpha.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/CHANGELOG.md +366 -188
- package/DateRangeCalendar/DateRangeCalendar.js +2 -8
- package/DateRangeCalendar/DateRangeCalendar.types.d.ts +0 -4
- package/DateRangeCalendar/useDragRange.js +1 -1
- package/DateRangePicker/DateRangePicker.js +1 -5
- package/DesktopDateRangePicker/DesktopDateRangePicker.js +1 -5
- package/MobileDateRangePicker/MobileDateRangePicker.js +1 -5
- package/MultiInputDateRangeField/MultiInputDateRangeField.js +1 -1
- package/MultiInputDateTimeRangeField/MultiInputDateTimeRangeField.js +1 -9
- package/MultiInputTimeRangeField/MultiInputTimeRangeField.js +1 -9
- package/SingleInputDateRangeField/SingleInputDateRangeField.js +1 -1
- package/SingleInputDateTimeRangeField/SingleInputDateTimeRangeField.js +1 -9
- package/SingleInputTimeRangeField/SingleInputTimeRangeField.js +1 -9
- package/StaticDateRangePicker/StaticDateRangePicker.js +1 -5
- package/dateRangeViewRenderers/dateRangeViewRenderers.d.ts +1 -1
- package/dateRangeViewRenderers/dateRangeViewRenderers.js +0 -2
- package/index.js +1 -1
- package/internals/utils/releaseInfo.js +1 -1
- package/legacy/DateRangeCalendar/DateRangeCalendar.js +7 -14
- package/legacy/DateRangeCalendar/useDragRange.js +1 -1
- package/legacy/DateRangePicker/DateRangePicker.js +1 -5
- package/legacy/DateRangePickerDay/DateRangePickerDay.js +3 -4
- package/legacy/DesktopDateRangePicker/DesktopDateRangePicker.js +1 -5
- package/legacy/MobileDateRangePicker/MobileDateRangePicker.js +1 -5
- package/legacy/MultiInputDateRangeField/MultiInputDateRangeField.js +1 -1
- package/legacy/MultiInputDateTimeRangeField/MultiInputDateTimeRangeField.js +1 -9
- package/legacy/MultiInputTimeRangeField/MultiInputTimeRangeField.js +1 -9
- package/legacy/SingleInputDateRangeField/SingleInputDateRangeField.js +1 -1
- package/legacy/SingleInputDateTimeRangeField/SingleInputDateTimeRangeField.js +1 -9
- package/legacy/SingleInputTimeRangeField/SingleInputTimeRangeField.js +1 -9
- package/legacy/StaticDateRangePicker/StaticDateRangePicker.js +1 -5
- package/legacy/dateRangeViewRenderers/dateRangeViewRenderers.js +0 -2
- package/legacy/index.js +1 -1
- package/legacy/internals/utils/releaseInfo.js +1 -1
- package/modern/DateRangeCalendar/DateRangeCalendar.js +2 -8
- package/modern/DateRangeCalendar/useDragRange.js +1 -1
- package/modern/DateRangePicker/DateRangePicker.js +1 -5
- package/modern/DesktopDateRangePicker/DesktopDateRangePicker.js +1 -5
- package/modern/MobileDateRangePicker/MobileDateRangePicker.js +1 -5
- package/modern/MultiInputDateRangeField/MultiInputDateRangeField.js +1 -1
- package/modern/MultiInputDateTimeRangeField/MultiInputDateTimeRangeField.js +1 -9
- package/modern/MultiInputTimeRangeField/MultiInputTimeRangeField.js +1 -9
- package/modern/SingleInputDateRangeField/SingleInputDateRangeField.js +1 -1
- package/modern/SingleInputDateTimeRangeField/SingleInputDateTimeRangeField.js +1 -9
- package/modern/SingleInputTimeRangeField/SingleInputTimeRangeField.js +1 -9
- package/modern/StaticDateRangePicker/StaticDateRangePicker.js +1 -5
- package/modern/dateRangeViewRenderers/dateRangeViewRenderers.js +0 -2
- package/modern/index.js +1 -1
- package/modern/internals/utils/releaseInfo.js +1 -1
- package/node/DateRangeCalendar/DateRangeCalendar.js +2 -8
- package/node/DateRangeCalendar/useDragRange.js +1 -1
- package/node/DateRangePicker/DateRangePicker.js +1 -5
- package/node/DesktopDateRangePicker/DesktopDateRangePicker.js +1 -5
- package/node/MobileDateRangePicker/MobileDateRangePicker.js +1 -5
- package/node/MultiInputDateRangeField/MultiInputDateRangeField.js +1 -1
- package/node/MultiInputDateTimeRangeField/MultiInputDateTimeRangeField.js +1 -9
- package/node/MultiInputTimeRangeField/MultiInputTimeRangeField.js +1 -9
- package/node/SingleInputDateRangeField/SingleInputDateRangeField.js +1 -1
- package/node/SingleInputDateTimeRangeField/SingleInputDateTimeRangeField.js +1 -9
- package/node/SingleInputTimeRangeField/SingleInputTimeRangeField.js +1 -9
- package/node/StaticDateRangePicker/StaticDateRangePicker.js +1 -5
- package/node/dateRangeViewRenderers/dateRangeViewRenderers.js +0 -2
- package/node/index.js +1 -1
- package/node/internals/utils/releaseInfo.js +1 -1
- package/package.json +6 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
2
2
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
|
-
const _excluded = ["value", "defaultValue", "referenceDate", "onChange", "className", "disableFuture", "disablePast", "minDate", "maxDate", "shouldDisableDate", "reduceAnimations", "onMonthChange", "
|
|
3
|
+
const _excluded = ["value", "defaultValue", "referenceDate", "onChange", "className", "disableFuture", "disablePast", "minDate", "maxDate", "shouldDisableDate", "reduceAnimations", "onMonthChange", "rangePosition", "defaultRangePosition", "onRangePositionChange", "calendars", "currentMonthCalendarPosition", "slots", "slotProps", "loading", "renderLoading", "disableHighlightToday", "readOnly", "disabled", "showDaysOutsideCurrentMonth", "dayOfWeekFormatter", "disableAutoMonthSwitching", "autoFocus", "fixedWeekNumber", "disableDragEditing", "displayWeekNumber", "timezone"],
|
|
4
4
|
_excluded2 = ["isDragging", "rangeDragDay", "draggingDatePosition"];
|
|
5
5
|
import * as React from 'react';
|
|
6
6
|
import PropTypes from 'prop-types';
|
|
@@ -138,7 +138,6 @@ const DateRangeCalendar = /*#__PURE__*/React.forwardRef(function DateRangeCalend
|
|
|
138
138
|
shouldDisableDate,
|
|
139
139
|
reduceAnimations,
|
|
140
140
|
onMonthChange,
|
|
141
|
-
defaultCalendarMonth,
|
|
142
141
|
rangePosition: rangePositionProp,
|
|
143
142
|
defaultRangePosition: inDefaultRangePosition,
|
|
144
143
|
onRangePositionChange: inOnRangePositionChange,
|
|
@@ -258,7 +257,6 @@ const DateRangeCalendar = /*#__PURE__*/React.forwardRef(function DateRangeCalend
|
|
|
258
257
|
} = useCalendarState({
|
|
259
258
|
value: value[0] || value[1],
|
|
260
259
|
referenceDate,
|
|
261
|
-
defaultCalendarMonth,
|
|
262
260
|
disableFuture,
|
|
263
261
|
disablePast,
|
|
264
262
|
disableSwitchToMonthOnDayFocus: true,
|
|
@@ -519,10 +517,6 @@ process.env.NODE_ENV !== "production" ? DateRangeCalendar.propTypes = {
|
|
|
519
517
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
520
518
|
*/
|
|
521
519
|
dayOfWeekFormatter: PropTypes.func,
|
|
522
|
-
/**
|
|
523
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
524
|
-
*/
|
|
525
|
-
defaultCalendarMonth: PropTypes.any,
|
|
526
520
|
/**
|
|
527
521
|
* The initial position in the edited date range.
|
|
528
522
|
* Used when the component is not controlled.
|
|
@@ -672,7 +666,7 @@ process.env.NODE_ENV !== "production" ? DateRangeCalendar.propTypes = {
|
|
|
672
666
|
* Choose which timezone to use for the value.
|
|
673
667
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
674
668
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
675
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
669
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
676
670
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
677
671
|
*/
|
|
678
672
|
timezone: PropTypes.string,
|
|
@@ -37,10 +37,6 @@ export interface ExportedDateRangeCalendarProps<TDate> extends ExportedDayCalend
|
|
|
37
37
|
* @default false
|
|
38
38
|
*/
|
|
39
39
|
disableAutoMonthSwitching?: boolean;
|
|
40
|
-
/**
|
|
41
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
42
|
-
*/
|
|
43
|
-
defaultCalendarMonth?: TDate;
|
|
44
40
|
/**
|
|
45
41
|
* If `true`, the picker and text field are disabled.
|
|
46
42
|
* @default false
|
|
@@ -8,7 +8,7 @@ const resolveDateFromTarget = (target, utils, timezone) => {
|
|
|
8
8
|
return null;
|
|
9
9
|
}
|
|
10
10
|
const timestamp = +timestampString;
|
|
11
|
-
return utils.
|
|
11
|
+
return utils.date(new Date(timestamp).toISOString(), timezone);
|
|
12
12
|
};
|
|
13
13
|
const isSameAsDraggingDate = event => {
|
|
14
14
|
const timestampString = event.target.dataset.timestamp;
|
|
@@ -80,10 +80,6 @@ process.env.NODE_ENV !== "production" ? DateRangePicker.propTypes = {
|
|
|
80
80
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
81
81
|
*/
|
|
82
82
|
dayOfWeekFormatter: PropTypes.func,
|
|
83
|
-
/**
|
|
84
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
85
|
-
*/
|
|
86
|
-
defaultCalendarMonth: PropTypes.any,
|
|
87
83
|
/**
|
|
88
84
|
* The initial position in the edited date range.
|
|
89
85
|
* Used when the component is not controlled.
|
|
@@ -316,7 +312,7 @@ process.env.NODE_ENV !== "production" ? DateRangePicker.propTypes = {
|
|
|
316
312
|
* Choose which timezone to use for the value.
|
|
317
313
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
318
314
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
319
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
315
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
320
316
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
321
317
|
*/
|
|
322
318
|
timezone: PropTypes.string,
|
|
@@ -95,10 +95,6 @@ DesktopDateRangePicker.propTypes = {
|
|
|
95
95
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
96
96
|
*/
|
|
97
97
|
dayOfWeekFormatter: PropTypes.func,
|
|
98
|
-
/**
|
|
99
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
100
|
-
*/
|
|
101
|
-
defaultCalendarMonth: PropTypes.any,
|
|
102
98
|
/**
|
|
103
99
|
* The initial position in the edited date range.
|
|
104
100
|
* Used when the component is not controlled.
|
|
@@ -325,7 +321,7 @@ DesktopDateRangePicker.propTypes = {
|
|
|
325
321
|
* Choose which timezone to use for the value.
|
|
326
322
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
327
323
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
328
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
324
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
329
325
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
330
326
|
*/
|
|
331
327
|
timezone: PropTypes.string,
|
|
@@ -95,10 +95,6 @@ MobileDateRangePicker.propTypes = {
|
|
|
95
95
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
96
96
|
*/
|
|
97
97
|
dayOfWeekFormatter: PropTypes.func,
|
|
98
|
-
/**
|
|
99
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
100
|
-
*/
|
|
101
|
-
defaultCalendarMonth: PropTypes.any,
|
|
102
98
|
/**
|
|
103
99
|
* The initial position in the edited date range.
|
|
104
100
|
* Used when the component is not controlled.
|
|
@@ -325,7 +321,7 @@ MobileDateRangePicker.propTypes = {
|
|
|
325
321
|
* Choose which timezone to use for the value.
|
|
326
322
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
327
323
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
328
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
324
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
329
325
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
330
326
|
*/
|
|
331
327
|
timezone: PropTypes.string,
|
|
@@ -325,7 +325,7 @@ process.env.NODE_ENV !== "production" ? MultiInputDateRangeField.propTypes = {
|
|
|
325
325
|
* Choose which timezone to use for the value.
|
|
326
326
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
327
327
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
328
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
328
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
329
329
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
330
330
|
*/
|
|
331
331
|
timezone: PropTypes.string,
|
|
@@ -308,14 +308,6 @@ process.env.NODE_ENV !== "production" ? MultiInputDateTimeRangeField.propTypes =
|
|
|
308
308
|
endIndex: PropTypes.number.isRequired,
|
|
309
309
|
startIndex: PropTypes.number.isRequired
|
|
310
310
|
})]),
|
|
311
|
-
/**
|
|
312
|
-
* Disable specific clock time.
|
|
313
|
-
* @param {number} clockValue The value to check.
|
|
314
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
315
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
316
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
317
|
-
*/
|
|
318
|
-
shouldDisableClock: PropTypes.func,
|
|
319
311
|
/**
|
|
320
312
|
* Disable specific date.
|
|
321
313
|
*
|
|
@@ -374,7 +366,7 @@ process.env.NODE_ENV !== "production" ? MultiInputDateTimeRangeField.propTypes =
|
|
|
374
366
|
* Choose which timezone to use for the value.
|
|
375
367
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
376
368
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
377
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
369
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
378
370
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
379
371
|
*/
|
|
380
372
|
timezone: PropTypes.string,
|
|
@@ -292,14 +292,6 @@ process.env.NODE_ENV !== "production" ? MultiInputTimeRangeField.propTypes = {
|
|
|
292
292
|
endIndex: PropTypes.number.isRequired,
|
|
293
293
|
startIndex: PropTypes.number.isRequired
|
|
294
294
|
})]),
|
|
295
|
-
/**
|
|
296
|
-
* Disable specific clock time.
|
|
297
|
-
* @param {number} clockValue The value to check.
|
|
298
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
299
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
300
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
301
|
-
*/
|
|
302
|
-
shouldDisableClock: PropTypes.func,
|
|
303
295
|
/**
|
|
304
296
|
* Disable specific time.
|
|
305
297
|
* @template TDate
|
|
@@ -347,7 +339,7 @@ process.env.NODE_ENV !== "production" ? MultiInputTimeRangeField.propTypes = {
|
|
|
347
339
|
* Choose which timezone to use for the value.
|
|
348
340
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
349
341
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
350
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
342
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
351
343
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
352
344
|
*/
|
|
353
345
|
timezone: PropTypes.string,
|
|
@@ -320,7 +320,7 @@ process.env.NODE_ENV !== "production" ? SingleInputDateRangeField.propTypes = {
|
|
|
320
320
|
* Choose which timezone to use for the value.
|
|
321
321
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
322
322
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
323
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
323
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
324
324
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
325
325
|
*/
|
|
326
326
|
timezone: PropTypes.string,
|
|
@@ -304,14 +304,6 @@ process.env.NODE_ENV !== "production" ? SingleInputDateTimeRangeField.propTypes
|
|
|
304
304
|
endIndex: PropTypes.number.isRequired,
|
|
305
305
|
startIndex: PropTypes.number.isRequired
|
|
306
306
|
})]),
|
|
307
|
-
/**
|
|
308
|
-
* Disable specific clock time.
|
|
309
|
-
* @param {number} clockValue The value to check.
|
|
310
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
311
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
312
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
313
|
-
*/
|
|
314
|
-
shouldDisableClock: PropTypes.func,
|
|
315
307
|
/**
|
|
316
308
|
* Disable specific date.
|
|
317
309
|
*
|
|
@@ -369,7 +361,7 @@ process.env.NODE_ENV !== "production" ? SingleInputDateTimeRangeField.propTypes
|
|
|
369
361
|
* Choose which timezone to use for the value.
|
|
370
362
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
371
363
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
372
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
364
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
373
365
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
374
366
|
*/
|
|
375
367
|
timezone: PropTypes.string,
|
|
@@ -288,14 +288,6 @@ process.env.NODE_ENV !== "production" ? SingleInputTimeRangeField.propTypes = {
|
|
|
288
288
|
endIndex: PropTypes.number.isRequired,
|
|
289
289
|
startIndex: PropTypes.number.isRequired
|
|
290
290
|
})]),
|
|
291
|
-
/**
|
|
292
|
-
* Disable specific clock time.
|
|
293
|
-
* @param {number} clockValue The value to check.
|
|
294
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
295
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
296
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
297
|
-
*/
|
|
298
|
-
shouldDisableClock: PropTypes.func,
|
|
299
291
|
/**
|
|
300
292
|
* Disable specific time.
|
|
301
293
|
* @template TDate
|
|
@@ -342,7 +334,7 @@ process.env.NODE_ENV !== "production" ? SingleInputTimeRangeField.propTypes = {
|
|
|
342
334
|
* Choose which timezone to use for the value.
|
|
343
335
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
344
336
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
345
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
337
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
346
338
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
347
339
|
*/
|
|
348
340
|
timezone: PropTypes.string,
|
|
@@ -81,10 +81,6 @@ StaticDateRangePicker.propTypes = {
|
|
|
81
81
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
82
82
|
*/
|
|
83
83
|
dayOfWeekFormatter: PropTypes.func,
|
|
84
|
-
/**
|
|
85
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
86
|
-
*/
|
|
87
|
-
defaultCalendarMonth: PropTypes.any,
|
|
88
84
|
/**
|
|
89
85
|
* The initial position in the edited date range.
|
|
90
86
|
* Used when the component is not controlled.
|
|
@@ -263,7 +259,7 @@ StaticDateRangePicker.propTypes = {
|
|
|
263
259
|
* Choose which timezone to use for the value.
|
|
264
260
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
265
261
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
266
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
262
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
267
263
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
268
264
|
*/
|
|
269
265
|
timezone: PropTypes.string,
|
|
@@ -10,4 +10,4 @@ export interface DateRangeViewRendererProps<TDate, TView extends DateOrTimeViewW
|
|
|
10
10
|
* We don't pass all the props down to `DateRangeCalendar`,
|
|
11
11
|
* because otherwise some unwanted props would be passed to the HTML element.
|
|
12
12
|
*/
|
|
13
|
-
export declare const renderDateRangeViewCalendar: <TDate extends unknown>({ value, defaultValue, referenceDate, onChange, className, classes, disableFuture, disablePast, minDate, maxDate, shouldDisableDate, reduceAnimations, onMonthChange,
|
|
13
|
+
export declare const renderDateRangeViewCalendar: <TDate extends unknown>({ value, defaultValue, referenceDate, onChange, className, classes, disableFuture, disablePast, minDate, maxDate, shouldDisableDate, reduceAnimations, onMonthChange, rangePosition, defaultRangePosition, onRangePositionChange, calendars, currentMonthCalendarPosition, slots, slotProps, loading, renderLoading, disableHighlightToday, readOnly, disabled, showDaysOutsideCurrentMonth, dayOfWeekFormatter, disableAutoMonthSwitching, sx, autoFocus, fixedWeekNumber, disableDragEditing, displayWeekNumber, timezone, }: DateRangeViewRendererProps<TDate, any>) => React.JSX.Element;
|
|
@@ -19,7 +19,6 @@ export const renderDateRangeViewCalendar = ({
|
|
|
19
19
|
shouldDisableDate,
|
|
20
20
|
reduceAnimations,
|
|
21
21
|
onMonthChange,
|
|
22
|
-
defaultCalendarMonth,
|
|
23
22
|
rangePosition,
|
|
24
23
|
defaultRangePosition,
|
|
25
24
|
onRangePositionChange,
|
|
@@ -55,7 +54,6 @@ export const renderDateRangeViewCalendar = ({
|
|
|
55
54
|
shouldDisableDate: shouldDisableDate,
|
|
56
55
|
reduceAnimations: reduceAnimations,
|
|
57
56
|
onMonthChange: onMonthChange,
|
|
58
|
-
defaultCalendarMonth: defaultCalendarMonth,
|
|
59
57
|
rangePosition: rangePosition,
|
|
60
58
|
defaultRangePosition: defaultRangePosition,
|
|
61
59
|
onRangePositionChange: onRangePositionChange,
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export const getReleaseInfo = () => {
|
|
3
|
-
const releaseInfo = "
|
|
3
|
+
const releaseInfo = "MTcwMDY5MDQwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -2,7 +2,7 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
5
|
-
var _excluded = ["value", "defaultValue", "referenceDate", "onChange", "className", "disableFuture", "disablePast", "minDate", "maxDate", "shouldDisableDate", "reduceAnimations", "onMonthChange", "
|
|
5
|
+
var _excluded = ["value", "defaultValue", "referenceDate", "onChange", "className", "disableFuture", "disablePast", "minDate", "maxDate", "shouldDisableDate", "reduceAnimations", "onMonthChange", "rangePosition", "defaultRangePosition", "onRangePositionChange", "calendars", "currentMonthCalendarPosition", "slots", "slotProps", "loading", "renderLoading", "disableHighlightToday", "readOnly", "disabled", "showDaysOutsideCurrentMonth", "dayOfWeekFormatter", "disableAutoMonthSwitching", "autoFocus", "fixedWeekNumber", "disableDragEditing", "displayWeekNumber", "timezone"],
|
|
6
6
|
_excluded2 = ["isDragging", "rangeDragDay", "draggingDatePosition"];
|
|
7
7
|
import * as React from 'react';
|
|
8
8
|
import PropTypes from 'prop-types';
|
|
@@ -60,23 +60,22 @@ var DAY_RANGE_SIZE = 40;
|
|
|
60
60
|
var weeksContainerHeight = (DAY_RANGE_SIZE + DAY_MARGIN * 2) * 6;
|
|
61
61
|
var warnInvalidCurrentMonthCalendarPosition = buildWarning(['The `currentMonthCalendarPosition` prop must be an integer between `1` and the amount of calendars rendered.', 'For example if you have 2 calendars rendered, it should be equal to either 1 or 2.']);
|
|
62
62
|
var DayCalendarForRange = styled(DayCalendar)(function (_ref2) {
|
|
63
|
-
var _$concat, _ref3;
|
|
64
63
|
var theme = _ref2.theme;
|
|
65
|
-
return
|
|
64
|
+
return _defineProperty(_defineProperty({
|
|
66
65
|
minWidth: 312,
|
|
67
66
|
minHeight: weeksContainerHeight
|
|
68
|
-
},
|
|
67
|
+
}, "&.".concat(dateRangeCalendarClasses.dayDragging), _defineProperty(_defineProperty({}, "& .".concat(dayClasses.day), {
|
|
69
68
|
cursor: 'grabbing'
|
|
70
|
-
}),
|
|
69
|
+
}), "& .".concat(dayClasses.root, ":not(.").concat(dayClasses.rangeIntervalDayHighlightStart, "):not(.").concat(dayClasses.rangeIntervalDayHighlightEnd, ") .").concat(dayClasses.day, ":not(.").concat(dayClasses.notSelectedDate, ")"), {
|
|
71
70
|
// we can't override `PickersDay` background color here, because it's styles take precedence
|
|
72
71
|
opacity: 0.6
|
|
73
|
-
})
|
|
72
|
+
})), "&:not(.".concat(dateRangeCalendarClasses.dayDragging, ") .").concat(dayClasses.dayOutsideRangeInterval), {
|
|
74
73
|
'@media (pointer: fine)': {
|
|
75
74
|
'&:hover': {
|
|
76
75
|
border: "1px solid ".concat((theme.vars || theme).palette.grey[500])
|
|
77
76
|
}
|
|
78
77
|
}
|
|
79
|
-
})
|
|
78
|
+
});
|
|
80
79
|
});
|
|
81
80
|
function useDateRangeCalendarDefaultizedProps(props, name) {
|
|
82
81
|
var _themeProps$renderLoa, _themeProps$reduceAni, _props$loading, _props$disablePast, _props$disableFuture, _themeProps$calendars, _themeProps$disableDr;
|
|
@@ -141,7 +140,6 @@ var DateRangeCalendar = /*#__PURE__*/React.forwardRef(function DateRangeCalendar
|
|
|
141
140
|
shouldDisableDate = props.shouldDisableDate,
|
|
142
141
|
reduceAnimations = props.reduceAnimations,
|
|
143
142
|
onMonthChange = props.onMonthChange,
|
|
144
|
-
defaultCalendarMonth = props.defaultCalendarMonth,
|
|
145
143
|
rangePositionProp = props.rangePosition,
|
|
146
144
|
inDefaultRangePosition = props.defaultRangePosition,
|
|
147
145
|
inOnRangePositionChange = props.onRangePositionChange,
|
|
@@ -255,7 +253,6 @@ var DateRangeCalendar = /*#__PURE__*/React.forwardRef(function DateRangeCalendar
|
|
|
255
253
|
var _useCalendarState = useCalendarState({
|
|
256
254
|
value: value[0] || value[1],
|
|
257
255
|
referenceDate: referenceDate,
|
|
258
|
-
defaultCalendarMonth: defaultCalendarMonth,
|
|
259
256
|
disableFuture: disableFuture,
|
|
260
257
|
disablePast: disablePast,
|
|
261
258
|
disableSwitchToMonthOnDayFocus: true,
|
|
@@ -540,10 +537,6 @@ process.env.NODE_ENV !== "production" ? DateRangeCalendar.propTypes = {
|
|
|
540
537
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
541
538
|
*/
|
|
542
539
|
dayOfWeekFormatter: PropTypes.func,
|
|
543
|
-
/**
|
|
544
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
545
|
-
*/
|
|
546
|
-
defaultCalendarMonth: PropTypes.any,
|
|
547
540
|
/**
|
|
548
541
|
* The initial position in the edited date range.
|
|
549
542
|
* Used when the component is not controlled.
|
|
@@ -693,7 +686,7 @@ process.env.NODE_ENV !== "production" ? DateRangeCalendar.propTypes = {
|
|
|
693
686
|
* Choose which timezone to use for the value.
|
|
694
687
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
695
688
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
696
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
689
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
697
690
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
698
691
|
*/
|
|
699
692
|
timezone: PropTypes.string,
|
|
@@ -9,7 +9,7 @@ var resolveDateFromTarget = function resolveDateFromTarget(target, utils, timezo
|
|
|
9
9
|
return null;
|
|
10
10
|
}
|
|
11
11
|
var timestamp = +timestampString;
|
|
12
|
-
return utils.
|
|
12
|
+
return utils.date(new Date(timestamp).toISOString(), timezone);
|
|
13
13
|
};
|
|
14
14
|
var isSameAsDraggingDate = function isSameAsDraggingDate(event) {
|
|
15
15
|
var timestampString = event.target.dataset.timestamp;
|
|
@@ -79,10 +79,6 @@ process.env.NODE_ENV !== "production" ? DateRangePicker.propTypes = {
|
|
|
79
79
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
80
80
|
*/
|
|
81
81
|
dayOfWeekFormatter: PropTypes.func,
|
|
82
|
-
/**
|
|
83
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
84
|
-
*/
|
|
85
|
-
defaultCalendarMonth: PropTypes.any,
|
|
86
82
|
/**
|
|
87
83
|
* The initial position in the edited date range.
|
|
88
84
|
* Used when the component is not controlled.
|
|
@@ -315,7 +311,7 @@ process.env.NODE_ENV !== "production" ? DateRangePicker.propTypes = {
|
|
|
315
311
|
* Choose which timezone to use for the value.
|
|
316
312
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
317
313
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
318
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
314
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
319
315
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
320
316
|
*/
|
|
321
317
|
timezone: PropTypes.string,
|
|
@@ -51,14 +51,13 @@ var DateRangePickerDayRoot = styled('div', {
|
|
|
51
51
|
return [_defineProperty({}, "&.".concat(dateRangePickerDayClasses.rangeIntervalDayHighlight), styles.rangeIntervalDayHighlight), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.rangeIntervalDayHighlightStart), styles.rangeIntervalDayHighlightStart), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.rangeIntervalDayHighlightEnd), styles.rangeIntervalDayHighlightEnd), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.firstVisibleCell), styles.firstVisibleCell), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.lastVisibleCell), styles.lastVisibleCell), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.startOfMonth), styles.startOfMonth), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.endOfMonth), styles.endOfMonth), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.outsideCurrentMonth), styles.outsideCurrentMonth), _defineProperty({}, "&.".concat(dateRangePickerDayClasses.hiddenDayFiller), styles.hiddenDayFiller), styles.root];
|
|
52
52
|
}
|
|
53
53
|
})(function (_ref10) {
|
|
54
|
-
var _extends2;
|
|
55
54
|
var theme = _ref10.theme,
|
|
56
55
|
ownerState = _ref10.ownerState;
|
|
57
|
-
return ownerState.isHiddenDayFiller ? {} : _extends((
|
|
56
|
+
return ownerState.isHiddenDayFiller ? {} : _extends(_defineProperty(_defineProperty({}, "&:first-of-type .".concat(dateRangePickerDayClasses.rangeIntervalDayPreview), _extends({}, startBorderStyle, {
|
|
58
57
|
borderLeftColor: (theme.vars || theme).palette.divider
|
|
59
|
-
})),
|
|
58
|
+
})), "&:last-of-type .".concat(dateRangePickerDayClasses.rangeIntervalDayPreview), _extends({}, endBorderStyle, {
|
|
60
59
|
borderRightColor: (theme.vars || theme).palette.divider
|
|
61
|
-
})),
|
|
60
|
+
})), ownerState.isHighlighting && {
|
|
62
61
|
borderRadius: 0,
|
|
63
62
|
color: (theme.vars || theme).palette.primary.contrastText,
|
|
64
63
|
backgroundColor: theme.vars ? "rgba(".concat(theme.vars.palette.primary.mainChannel, " / ").concat(theme.vars.palette.action.focusOpacity, ")") : alpha(theme.palette.primary.main, theme.palette.action.focusOpacity),
|
|
@@ -94,10 +94,6 @@ DesktopDateRangePicker.propTypes = {
|
|
|
94
94
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
95
95
|
*/
|
|
96
96
|
dayOfWeekFormatter: PropTypes.func,
|
|
97
|
-
/**
|
|
98
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
99
|
-
*/
|
|
100
|
-
defaultCalendarMonth: PropTypes.any,
|
|
101
97
|
/**
|
|
102
98
|
* The initial position in the edited date range.
|
|
103
99
|
* Used when the component is not controlled.
|
|
@@ -324,7 +320,7 @@ DesktopDateRangePicker.propTypes = {
|
|
|
324
320
|
* Choose which timezone to use for the value.
|
|
325
321
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
326
322
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
327
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
323
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
328
324
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
329
325
|
*/
|
|
330
326
|
timezone: PropTypes.string,
|
|
@@ -94,10 +94,6 @@ MobileDateRangePicker.propTypes = {
|
|
|
94
94
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
95
95
|
*/
|
|
96
96
|
dayOfWeekFormatter: PropTypes.func,
|
|
97
|
-
/**
|
|
98
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
99
|
-
*/
|
|
100
|
-
defaultCalendarMonth: PropTypes.any,
|
|
101
97
|
/**
|
|
102
98
|
* The initial position in the edited date range.
|
|
103
99
|
* Used when the component is not controlled.
|
|
@@ -324,7 +320,7 @@ MobileDateRangePicker.propTypes = {
|
|
|
324
320
|
* Choose which timezone to use for the value.
|
|
325
321
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
326
322
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
327
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
323
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
328
324
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
329
325
|
*/
|
|
330
326
|
timezone: PropTypes.string,
|
|
@@ -324,7 +324,7 @@ process.env.NODE_ENV !== "production" ? MultiInputDateRangeField.propTypes = {
|
|
|
324
324
|
* Choose which timezone to use for the value.
|
|
325
325
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
326
326
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
327
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
327
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
328
328
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
329
329
|
*/
|
|
330
330
|
timezone: PropTypes.string,
|
|
@@ -307,14 +307,6 @@ process.env.NODE_ENV !== "production" ? MultiInputDateTimeRangeField.propTypes =
|
|
|
307
307
|
endIndex: PropTypes.number.isRequired,
|
|
308
308
|
startIndex: PropTypes.number.isRequired
|
|
309
309
|
})]),
|
|
310
|
-
/**
|
|
311
|
-
* Disable specific clock time.
|
|
312
|
-
* @param {number} clockValue The value to check.
|
|
313
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
314
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
315
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
316
|
-
*/
|
|
317
|
-
shouldDisableClock: PropTypes.func,
|
|
318
310
|
/**
|
|
319
311
|
* Disable specific date.
|
|
320
312
|
*
|
|
@@ -373,7 +365,7 @@ process.env.NODE_ENV !== "production" ? MultiInputDateTimeRangeField.propTypes =
|
|
|
373
365
|
* Choose which timezone to use for the value.
|
|
374
366
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
375
367
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
376
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
368
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
377
369
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
378
370
|
*/
|
|
379
371
|
timezone: PropTypes.string,
|
|
@@ -291,14 +291,6 @@ process.env.NODE_ENV !== "production" ? MultiInputTimeRangeField.propTypes = {
|
|
|
291
291
|
endIndex: PropTypes.number.isRequired,
|
|
292
292
|
startIndex: PropTypes.number.isRequired
|
|
293
293
|
})]),
|
|
294
|
-
/**
|
|
295
|
-
* Disable specific clock time.
|
|
296
|
-
* @param {number} clockValue The value to check.
|
|
297
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
298
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
299
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
300
|
-
*/
|
|
301
|
-
shouldDisableClock: PropTypes.func,
|
|
302
294
|
/**
|
|
303
295
|
* Disable specific time.
|
|
304
296
|
* @template TDate
|
|
@@ -346,7 +338,7 @@ process.env.NODE_ENV !== "production" ? MultiInputTimeRangeField.propTypes = {
|
|
|
346
338
|
* Choose which timezone to use for the value.
|
|
347
339
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
348
340
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
349
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
341
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
350
342
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
351
343
|
*/
|
|
352
344
|
timezone: PropTypes.string,
|
|
@@ -313,7 +313,7 @@ process.env.NODE_ENV !== "production" ? SingleInputDateRangeField.propTypes = {
|
|
|
313
313
|
* Choose which timezone to use for the value.
|
|
314
314
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
315
315
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
316
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
316
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
317
317
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
318
318
|
*/
|
|
319
319
|
timezone: PropTypes.string,
|
|
@@ -297,14 +297,6 @@ process.env.NODE_ENV !== "production" ? SingleInputDateTimeRangeField.propTypes
|
|
|
297
297
|
endIndex: PropTypes.number.isRequired,
|
|
298
298
|
startIndex: PropTypes.number.isRequired
|
|
299
299
|
})]),
|
|
300
|
-
/**
|
|
301
|
-
* Disable specific clock time.
|
|
302
|
-
* @param {number} clockValue The value to check.
|
|
303
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
304
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
305
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
306
|
-
*/
|
|
307
|
-
shouldDisableClock: PropTypes.func,
|
|
308
300
|
/**
|
|
309
301
|
* Disable specific date.
|
|
310
302
|
*
|
|
@@ -362,7 +354,7 @@ process.env.NODE_ENV !== "production" ? SingleInputDateTimeRangeField.propTypes
|
|
|
362
354
|
* Choose which timezone to use for the value.
|
|
363
355
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
364
356
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
365
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
357
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
366
358
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
367
359
|
*/
|
|
368
360
|
timezone: PropTypes.string,
|
|
@@ -281,14 +281,6 @@ process.env.NODE_ENV !== "production" ? SingleInputTimeRangeField.propTypes = {
|
|
|
281
281
|
endIndex: PropTypes.number.isRequired,
|
|
282
282
|
startIndex: PropTypes.number.isRequired
|
|
283
283
|
})]),
|
|
284
|
-
/**
|
|
285
|
-
* Disable specific clock time.
|
|
286
|
-
* @param {number} clockValue The value to check.
|
|
287
|
-
* @param {TimeView} view The clock type of the timeValue.
|
|
288
|
-
* @returns {boolean} If `true` the time will be disabled.
|
|
289
|
-
* @deprecated Consider using `shouldDisableTime`.
|
|
290
|
-
*/
|
|
291
|
-
shouldDisableClock: PropTypes.func,
|
|
292
284
|
/**
|
|
293
285
|
* Disable specific time.
|
|
294
286
|
* @template TDate
|
|
@@ -335,7 +327,7 @@ process.env.NODE_ENV !== "production" ? SingleInputTimeRangeField.propTypes = {
|
|
|
335
327
|
* Choose which timezone to use for the value.
|
|
336
328
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
337
329
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
338
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
330
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
339
331
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
340
332
|
*/
|
|
341
333
|
timezone: PropTypes.string,
|
|
@@ -80,10 +80,6 @@ StaticDateRangePicker.propTypes = {
|
|
|
80
80
|
* @default (_day: string, date: TDate) => adapter.format(date, 'weekdayShort').charAt(0).toUpperCase()
|
|
81
81
|
*/
|
|
82
82
|
dayOfWeekFormatter: PropTypes.func,
|
|
83
|
-
/**
|
|
84
|
-
* Default calendar month displayed when `value={[null, null]}`.
|
|
85
|
-
*/
|
|
86
|
-
defaultCalendarMonth: PropTypes.any,
|
|
87
83
|
/**
|
|
88
84
|
* The initial position in the edited date range.
|
|
89
85
|
* Used when the component is not controlled.
|
|
@@ -262,7 +258,7 @@ StaticDateRangePicker.propTypes = {
|
|
|
262
258
|
* Choose which timezone to use for the value.
|
|
263
259
|
* Example: "default", "system", "UTC", "America/New_York".
|
|
264
260
|
* If you pass values from other timezones to some props, they will be converted to this timezone before being used.
|
|
265
|
-
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones
|
|
261
|
+
* @see See the {@link https://mui.com/x/react-date-pickers/timezone/ timezones documentation} for more details.
|
|
266
262
|
* @default The timezone of the `value` or `defaultValue` prop is defined, 'default' otherwise.
|
|
267
263
|
*/
|
|
268
264
|
timezone: PropTypes.string,
|