@mui/x-date-pickers 8.16.0 → 8.18.0
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 +208 -1
- package/DateCalendar/DayCalendar.d.ts +1 -1
- package/DateCalendar/PickersFadeTransitionGroup.d.ts +1 -1
- package/DateCalendar/PickersSlideTransition.d.ts +1 -1
- package/DatePicker/DatePicker.js +8 -2
- package/DateTimePicker/DateTimePicker.js +8 -2
- package/DateTimePicker/DateTimePickerTabs.d.ts +1 -1
- package/DateTimePicker/DateTimePickerToolbar.d.ts +1 -1
- package/DateTimePicker/DateTimePickerToolbar.js +2 -1
- package/DayCalendarSkeleton/DayCalendarSkeleton.d.ts +1 -1
- package/DesktopDatePicker/DesktopDatePicker.js +8 -2
- package/DesktopDateTimePicker/DesktopDateTimePicker.js +8 -2
- package/DesktopTimePicker/DesktopTimePicker.js +8 -2
- package/MobileDatePicker/MobileDatePicker.js +8 -2
- package/MobileDateTimePicker/MobileDateTimePicker.js +8 -2
- package/MobileTimePicker/MobileTimePicker.js +8 -2
- package/PickersActionBar/PickersActionBar.d.ts +1 -1
- package/PickersShortcuts/PickersShortcuts.d.ts +1 -2
- package/PickersShortcuts/PickersShortcuts.js +2 -3
- package/PickersTextField/PickersOutlinedInput/Outline.d.ts +1 -1
- package/StaticDatePicker/StaticDatePicker.js +8 -2
- package/StaticDateTimePicker/StaticDateTimePicker.js +8 -2
- package/StaticTimePicker/StaticTimePicker.js +8 -2
- package/TimeClock/Clock.d.ts +1 -1
- package/TimeClock/ClockNumber.d.ts +1 -1
- package/TimeClock/ClockNumbers.d.ts +1 -1
- package/TimeClock/ClockPointer.d.ts +1 -1
- package/TimePicker/TimePicker.js +8 -2
- package/TimePicker/TimePickerToolbar.d.ts +1 -2
- package/TimePicker/TimePickerToolbar.js +2 -3
- package/dateViewRenderers/dateViewRenderers.d.ts +1 -2
- package/dateViewRenderers/dateViewRenderers.js +0 -2
- package/esm/DateCalendar/DayCalendar.d.ts +1 -1
- package/esm/DateCalendar/PickersFadeTransitionGroup.d.ts +1 -1
- package/esm/DateCalendar/PickersSlideTransition.d.ts +1 -1
- package/esm/DatePicker/DatePicker.js +8 -2
- package/esm/DateTimePicker/DateTimePicker.js +8 -2
- package/esm/DateTimePicker/DateTimePickerTabs.d.ts +1 -1
- package/esm/DateTimePicker/DateTimePickerToolbar.d.ts +1 -1
- package/esm/DateTimePicker/DateTimePickerToolbar.js +2 -1
- package/esm/DayCalendarSkeleton/DayCalendarSkeleton.d.ts +1 -1
- package/esm/DesktopDatePicker/DesktopDatePicker.js +8 -2
- package/esm/DesktopDateTimePicker/DesktopDateTimePicker.js +8 -2
- package/esm/DesktopTimePicker/DesktopTimePicker.js +8 -2
- package/esm/MobileDatePicker/MobileDatePicker.js +8 -2
- package/esm/MobileDateTimePicker/MobileDateTimePicker.js +8 -2
- package/esm/MobileTimePicker/MobileTimePicker.js +8 -2
- package/esm/PickersActionBar/PickersActionBar.d.ts +1 -1
- package/esm/PickersShortcuts/PickersShortcuts.d.ts +1 -2
- package/esm/PickersShortcuts/PickersShortcuts.js +2 -2
- package/esm/PickersTextField/PickersOutlinedInput/Outline.d.ts +1 -1
- package/esm/StaticDatePicker/StaticDatePicker.js +8 -2
- package/esm/StaticDateTimePicker/StaticDateTimePicker.js +8 -2
- package/esm/StaticTimePicker/StaticTimePicker.js +8 -2
- package/esm/TimeClock/Clock.d.ts +1 -1
- package/esm/TimeClock/ClockNumber.d.ts +1 -1
- package/esm/TimeClock/ClockNumbers.d.ts +1 -1
- package/esm/TimeClock/ClockPointer.d.ts +1 -1
- package/esm/TimePicker/TimePicker.js +8 -2
- package/esm/TimePicker/TimePickerToolbar.d.ts +1 -2
- package/esm/TimePicker/TimePickerToolbar.js +2 -2
- package/esm/dateViewRenderers/dateViewRenderers.d.ts +1 -2
- package/esm/dateViewRenderers/dateViewRenderers.js +0 -1
- package/esm/index.js +1 -1
- package/esm/internals/components/PickerFieldUI.d.ts +2 -2
- package/esm/internals/components/PickerPopper/PickerPopper.d.ts +1 -1
- package/esm/internals/components/PickerProvider.d.ts +9 -1
- package/esm/internals/components/PickersModalDialog.d.ts +1 -1
- package/esm/internals/demo/DemoContainer.d.ts +2 -2
- package/esm/internals/hooks/useDesktopPicker/useDesktopPicker.d.ts +1 -2
- package/esm/internals/hooks/useDesktopPicker/useDesktopPicker.js +0 -1
- package/esm/internals/hooks/useField/useFieldState.js +19 -10
- package/esm/internals/hooks/useField/useFieldV6TextField.js +1 -0
- package/esm/internals/hooks/useMobilePicker/useMobilePicker.d.ts +1 -2
- package/esm/internals/hooks/useMobilePicker/useMobilePicker.js +0 -1
- package/esm/internals/hooks/usePicker/hooks/useValueAndOpenStates.js +14 -2
- package/esm/internals/hooks/usePicker/usePicker.js +13 -5
- package/esm/internals/hooks/usePicker/usePicker.types.d.ts +8 -2
- package/esm/internals/hooks/useStaticPicker/useStaticPicker.d.ts +1 -2
- package/esm/internals/hooks/useStaticPicker/useStaticPicker.js +0 -1
- package/esm/models/pickers.d.ts +8 -0
- package/esm/timeViewRenderers/timeViewRenderers.d.ts +3 -4
- package/esm/timeViewRenderers/timeViewRenderers.js +0 -1
- package/index.js +1 -1
- package/internals/components/PickerFieldUI.d.ts +2 -2
- package/internals/components/PickerPopper/PickerPopper.d.ts +1 -1
- package/internals/components/PickerProvider.d.ts +9 -1
- package/internals/components/PickersModalDialog.d.ts +1 -1
- package/internals/demo/DemoContainer.d.ts +2 -2
- package/internals/hooks/useDesktopPicker/useDesktopPicker.d.ts +1 -2
- package/internals/hooks/useDesktopPicker/useDesktopPicker.js +0 -2
- package/internals/hooks/useField/useFieldState.js +19 -10
- package/internals/hooks/useField/useFieldV6TextField.js +1 -0
- package/internals/hooks/useMobilePicker/useMobilePicker.d.ts +1 -2
- package/internals/hooks/useMobilePicker/useMobilePicker.js +0 -2
- package/internals/hooks/usePicker/hooks/useValueAndOpenStates.js +14 -2
- package/internals/hooks/usePicker/usePicker.js +13 -5
- package/internals/hooks/usePicker/usePicker.types.d.ts +8 -2
- package/internals/hooks/useStaticPicker/useStaticPicker.d.ts +1 -2
- package/internals/hooks/useStaticPicker/useStaticPicker.js +0 -2
- package/models/pickers.d.ts +8 -0
- package/package.json +3 -3
- package/timeViewRenderers/timeViewRenderers.d.ts +3 -4
- package/timeViewRenderers/timeViewRenderers.js +0 -2
|
@@ -28,4 +28,4 @@ export interface ClockPointerOwnerState extends PickerOwnerState {
|
|
|
28
28
|
/**
|
|
29
29
|
* @ignore - internal component.
|
|
30
30
|
*/
|
|
31
|
-
export declare function ClockPointer(inProps: ClockPointerProps):
|
|
31
|
+
export declare function ClockPointer(inProps: ClockPointerProps): import("react/jsx-runtime").JSX.Element;
|
package/TimePicker/TimePicker.js
CHANGED
|
@@ -171,7 +171,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
|
|
|
171
171
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
172
172
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
173
173
|
* @param {TValue} value The value that was just accepted.
|
|
174
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
174
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
175
|
+
* - `validationError`: validation result of the current value
|
|
176
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
177
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
175
178
|
*/
|
|
176
179
|
onAccept: _propTypes.default.func,
|
|
177
180
|
/**
|
|
@@ -179,7 +182,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
|
|
|
179
182
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
180
183
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
181
184
|
* @param {TValue} value The new value.
|
|
182
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
185
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
186
|
+
* - `validationError`: validation result of the current value
|
|
187
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
188
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
183
189
|
*/
|
|
184
190
|
onChange: _propTypes.default.func,
|
|
185
191
|
/**
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { BaseToolbarProps, ExportedBaseToolbarProps } from "../internals/models/props/toolbar.js";
|
|
3
2
|
import { TimePickerToolbarClasses } from "./timePickerToolbarClasses.js";
|
|
4
3
|
export interface TimePickerToolbarProps extends BaseToolbarProps, ExportedTimePickerToolbarProps {
|
|
@@ -21,7 +20,7 @@ export interface ExportedTimePickerToolbarProps extends ExportedBaseToolbarProps
|
|
|
21
20
|
*
|
|
22
21
|
* - [TimePickerToolbar API](https://mui.com/x/api/date-pickers/time-picker-toolbar/)
|
|
23
22
|
*/
|
|
24
|
-
declare function TimePickerToolbar(inProps: TimePickerToolbarProps):
|
|
23
|
+
declare function TimePickerToolbar(inProps: TimePickerToolbarProps): import("react/jsx-runtime").JSX.Element;
|
|
25
24
|
declare namespace TimePickerToolbar {
|
|
26
25
|
var propTypes: any;
|
|
27
26
|
}
|
|
@@ -2,14 +2,12 @@
|
|
|
2
2
|
'use client';
|
|
3
3
|
|
|
4
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
5
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
6
5
|
Object.defineProperty(exports, "__esModule", {
|
|
7
6
|
value: true
|
|
8
7
|
});
|
|
9
8
|
exports.TimePickerToolbar = TimePickerToolbar;
|
|
10
9
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
10
|
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
12
|
-
var React = _interopRequireWildcard(require("react"));
|
|
13
11
|
var _clsx = _interopRequireDefault(require("clsx"));
|
|
14
12
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
15
13
|
var _styles = require("@mui/material/styles");
|
|
@@ -147,7 +145,8 @@ function TimePickerToolbar(inProps) {
|
|
|
147
145
|
meridiemMode,
|
|
148
146
|
handleMeridiemChange
|
|
149
147
|
} = (0, _dateHelpersHooks.useMeridiemMode)(value, ampm, newValue => setValue(newValue, {
|
|
150
|
-
changeImportance: 'set'
|
|
148
|
+
changeImportance: 'set',
|
|
149
|
+
source: 'view'
|
|
151
150
|
}));
|
|
152
151
|
const formatSection = format => {
|
|
153
152
|
if (!adapter.isValid(value)) {
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { DateCalendarProps } from "../DateCalendar/index.js";
|
|
3
2
|
import { DateView } from "../models/index.js";
|
|
4
3
|
import { DateOrTimeViewWithMeridiem } from "../internals/models/index.js";
|
|
@@ -47,4 +46,4 @@ export declare const renderDateViewCalendar: ({
|
|
|
47
46
|
fixedWeekNumber,
|
|
48
47
|
displayWeekNumber,
|
|
49
48
|
timezone
|
|
50
|
-
}: DateViewRendererProps<DateView>) =>
|
|
49
|
+
}: DateViewRendererProps<DateView>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.renderDateViewCalendar = void 0;
|
|
8
|
-
var React = _interopRequireWildcard(require("react"));
|
|
9
7
|
var _DateCalendar = require("../DateCalendar");
|
|
10
8
|
var _dateUtils = require("../internals/utils/date-utils");
|
|
11
9
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
@@ -82,4 +82,4 @@ export interface DayCalendarProps extends ExportedDayCalendarProps, DayValidatio
|
|
|
82
82
|
/**
|
|
83
83
|
* @ignore - do not document.
|
|
84
84
|
*/
|
|
85
|
-
export declare function DayCalendar(inProps: DayCalendarProps):
|
|
85
|
+
export declare function DayCalendar(inProps: DayCalendarProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -15,4 +15,4 @@ export interface PickersFadeTransitionGroupProps extends ExportedPickersFadeTran
|
|
|
15
15
|
/**
|
|
16
16
|
* @ignore - do not document.
|
|
17
17
|
*/
|
|
18
|
-
export declare function PickersFadeTransitionGroup(inProps: PickersFadeTransitionGroupProps):
|
|
18
|
+
export declare function PickersFadeTransitionGroup(inProps: PickersFadeTransitionGroupProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -22,4 +22,4 @@ export interface SlideTransitionProps extends Omit<CSSTransitionProps, 'timeout'
|
|
|
22
22
|
/**
|
|
23
23
|
* @ignore - do not document.
|
|
24
24
|
*/
|
|
25
|
-
export declare function PickersSlideTransition(inProps: SlideTransitionProps):
|
|
25
|
+
export declare function PickersSlideTransition(inProps: SlideTransitionProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -176,7 +176,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
|
|
|
176
176
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
177
177
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
178
178
|
* @param {TValue} value The value that was just accepted.
|
|
179
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
179
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
180
|
+
* - `validationError`: validation result of the current value
|
|
181
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
182
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
180
183
|
*/
|
|
181
184
|
onAccept: PropTypes.func,
|
|
182
185
|
/**
|
|
@@ -184,7 +187,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
|
|
|
184
187
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
185
188
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
186
189
|
* @param {TValue} value The new value.
|
|
187
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
190
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
191
|
+
* - `validationError`: validation result of the current value
|
|
192
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
193
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
188
194
|
*/
|
|
189
195
|
onChange: PropTypes.func,
|
|
190
196
|
/**
|
|
@@ -214,7 +214,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
|
|
|
214
214
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
215
215
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
216
216
|
* @param {TValue} value The value that was just accepted.
|
|
217
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
217
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
218
|
+
* - `validationError`: validation result of the current value
|
|
219
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
220
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
218
221
|
*/
|
|
219
222
|
onAccept: PropTypes.func,
|
|
220
223
|
/**
|
|
@@ -222,7 +225,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
|
|
|
222
225
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
223
226
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
224
227
|
* @param {TValue} value The new value.
|
|
225
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
228
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
229
|
+
* - `validationError`: validation result of the current value
|
|
230
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
231
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
226
232
|
*/
|
|
227
233
|
onChange: PropTypes.func,
|
|
228
234
|
/**
|
|
@@ -33,7 +33,7 @@ export interface DateTimePickerTabsProps extends ExportedBaseTabsProps {
|
|
|
33
33
|
* - [DateTimePickerTabs API](https://mui.com/x/api/date-pickers/date-time-picker-tabs/)
|
|
34
34
|
*/
|
|
35
35
|
declare const DateTimePickerTabs: {
|
|
36
|
-
(inProps: DateTimePickerTabsProps):
|
|
36
|
+
(inProps: DateTimePickerTabsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
37
37
|
propTypes: any;
|
|
38
38
|
};
|
|
39
39
|
export { DateTimePickerTabs };
|
|
@@ -40,7 +40,7 @@ export declare const DateTimePickerToolbarOverrideContext: React.Context<{
|
|
|
40
40
|
*
|
|
41
41
|
* - [DateTimePickerToolbar API](https://mui.com/x/api/date-pickers/date-time-picker-toolbar/)
|
|
42
42
|
*/
|
|
43
|
-
declare function DateTimePickerToolbar(inProps: DateTimePickerToolbarProps):
|
|
43
|
+
declare function DateTimePickerToolbar(inProps: DateTimePickerToolbarProps): import("react/jsx-runtime").JSX.Element;
|
|
44
44
|
declare namespace DateTimePickerToolbar {
|
|
45
45
|
var propTypes: any;
|
|
46
46
|
}
|
|
@@ -256,7 +256,8 @@ function DateTimePickerToolbar(inProps) {
|
|
|
256
256
|
meridiemMode,
|
|
257
257
|
handleMeridiemChange
|
|
258
258
|
} = useMeridiemMode(value, ampm, newValue => setValue(newValue, {
|
|
259
|
-
changeImportance: 'set'
|
|
259
|
+
changeImportance: 'set',
|
|
260
|
+
source: 'view'
|
|
260
261
|
}));
|
|
261
262
|
const toolbarVariant = overrides?.forceDesktopVariant ? 'desktop' : variant;
|
|
262
263
|
const isDesktop = toolbarVariant === 'desktop';
|
|
@@ -23,7 +23,7 @@ export interface DayCalendarSkeletonProps extends HTMLDivProps {
|
|
|
23
23
|
*
|
|
24
24
|
* - [CalendarPickerSkeleton API](https://mui.com/x/api/date-pickers/calendar-picker-skeleton/)
|
|
25
25
|
*/
|
|
26
|
-
declare function DayCalendarSkeleton(inProps: DayCalendarSkeletonProps):
|
|
26
|
+
declare function DayCalendarSkeleton(inProps: DayCalendarSkeletonProps): import("react/jsx-runtime").JSX.Element;
|
|
27
27
|
declare namespace DayCalendarSkeleton {
|
|
28
28
|
var propTypes: any;
|
|
29
29
|
}
|
|
@@ -187,7 +187,10 @@ DesktopDatePicker.propTypes = {
|
|
|
187
187
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
188
188
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
189
189
|
* @param {TValue} value The value that was just accepted.
|
|
190
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
190
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
191
|
+
* - `validationError`: validation result of the current value
|
|
192
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
193
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
191
194
|
*/
|
|
192
195
|
onAccept: PropTypes.func,
|
|
193
196
|
/**
|
|
@@ -195,7 +198,10 @@ DesktopDatePicker.propTypes = {
|
|
|
195
198
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
196
199
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
197
200
|
* @param {TValue} value The new value.
|
|
198
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
201
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
202
|
+
* - `validationError`: validation result of the current value
|
|
203
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
204
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
199
205
|
*/
|
|
200
206
|
onChange: PropTypes.func,
|
|
201
207
|
/**
|
|
@@ -309,7 +309,10 @@ DesktopDateTimePicker.propTypes = {
|
|
|
309
309
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
310
310
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
311
311
|
* @param {TValue} value The value that was just accepted.
|
|
312
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
312
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
313
|
+
* - `validationError`: validation result of the current value
|
|
314
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
315
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
313
316
|
*/
|
|
314
317
|
onAccept: PropTypes.func,
|
|
315
318
|
/**
|
|
@@ -317,7 +320,10 @@ DesktopDateTimePicker.propTypes = {
|
|
|
317
320
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
318
321
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
319
322
|
* @param {TValue} value The new value.
|
|
320
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
323
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
324
|
+
* - `validationError`: validation result of the current value
|
|
325
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
326
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
321
327
|
*/
|
|
322
328
|
onChange: PropTypes.func,
|
|
323
329
|
/**
|
|
@@ -191,7 +191,10 @@ DesktopTimePicker.propTypes = {
|
|
|
191
191
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
192
192
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
193
193
|
* @param {TValue} value The value that was just accepted.
|
|
194
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
194
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
195
|
+
* - `validationError`: validation result of the current value
|
|
196
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
197
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
195
198
|
*/
|
|
196
199
|
onAccept: PropTypes.func,
|
|
197
200
|
/**
|
|
@@ -199,7 +202,10 @@ DesktopTimePicker.propTypes = {
|
|
|
199
202
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
200
203
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
201
204
|
* @param {TValue} value The new value.
|
|
202
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
205
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
206
|
+
* - `validationError`: validation result of the current value
|
|
207
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
208
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
203
209
|
*/
|
|
204
210
|
onChange: PropTypes.func,
|
|
205
211
|
/**
|
|
@@ -185,7 +185,10 @@ MobileDatePicker.propTypes = {
|
|
|
185
185
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
186
186
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
187
187
|
* @param {TValue} value The value that was just accepted.
|
|
188
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
188
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
189
|
+
* - `validationError`: validation result of the current value
|
|
190
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
191
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
189
192
|
*/
|
|
190
193
|
onAccept: PropTypes.func,
|
|
191
194
|
/**
|
|
@@ -193,7 +196,10 @@ MobileDatePicker.propTypes = {
|
|
|
193
196
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
194
197
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
195
198
|
* @param {TValue} value The new value.
|
|
196
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
199
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
200
|
+
* - `validationError`: validation result of the current value
|
|
201
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
202
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
197
203
|
*/
|
|
198
204
|
onChange: PropTypes.func,
|
|
199
205
|
/**
|
|
@@ -275,7 +275,10 @@ MobileDateTimePicker.propTypes = {
|
|
|
275
275
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
276
276
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
277
277
|
* @param {TValue} value The value that was just accepted.
|
|
278
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
278
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
279
|
+
* - `validationError`: validation result of the current value
|
|
280
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
281
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
279
282
|
*/
|
|
280
283
|
onAccept: PropTypes.func,
|
|
281
284
|
/**
|
|
@@ -283,7 +286,10 @@ MobileDateTimePicker.propTypes = {
|
|
|
283
286
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
284
287
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
285
288
|
* @param {TValue} value The new value.
|
|
286
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
289
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
290
|
+
* - `validationError`: validation result of the current value
|
|
291
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
292
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
287
293
|
*/
|
|
288
294
|
onChange: PropTypes.func,
|
|
289
295
|
/**
|
|
@@ -176,7 +176,10 @@ MobileTimePicker.propTypes = {
|
|
|
176
176
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
177
177
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
178
178
|
* @param {TValue} value The value that was just accepted.
|
|
179
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
179
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
180
|
+
* - `validationError`: validation result of the current value
|
|
181
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
182
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
180
183
|
*/
|
|
181
184
|
onAccept: PropTypes.func,
|
|
182
185
|
/**
|
|
@@ -184,7 +187,10 @@ MobileTimePicker.propTypes = {
|
|
|
184
187
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
185
188
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
186
189
|
* @param {TValue} value The new value.
|
|
187
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
190
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
191
|
+
* - `validationError`: validation result of the current value
|
|
192
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
193
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
188
194
|
*/
|
|
189
195
|
onChange: PropTypes.func,
|
|
190
196
|
/**
|
|
@@ -21,7 +21,7 @@ export interface PickersActionBarProps extends DialogActionsProps {
|
|
|
21
21
|
*
|
|
22
22
|
* - [PickersActionBar API](https://mui.com/x/api/date-pickers/pickers-action-bar/)
|
|
23
23
|
*/
|
|
24
|
-
declare function PickersActionBarComponent(props: PickersActionBarProps):
|
|
24
|
+
declare function PickersActionBarComponent(props: PickersActionBarProps): import("react/jsx-runtime").JSX.Element | null;
|
|
25
25
|
declare namespace PickersActionBarComponent {
|
|
26
26
|
var propTypes: any;
|
|
27
27
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { ListProps } from '@mui/material/List';
|
|
3
2
|
import { PickerValidValue } from "../internals/models/index.js";
|
|
4
3
|
import { PickerChangeImportance } from "../models/pickers.js";
|
|
@@ -40,7 +39,7 @@ export interface PickersShortcutsProps<TValue extends PickerValidValue> extends
|
|
|
40
39
|
*
|
|
41
40
|
* - [PickersShortcuts API](https://mui.com/x/api/date-pickers/pickers-shortcuts/)
|
|
42
41
|
*/
|
|
43
|
-
declare function PickersShortcuts<TValue extends PickerValidValue>(props: PickersShortcutsProps<TValue>):
|
|
42
|
+
declare function PickersShortcuts<TValue extends PickerValidValue>(props: PickersShortcutsProps<TValue>): import("react/jsx-runtime").JSX.Element | null;
|
|
44
43
|
declare namespace PickersShortcuts {
|
|
45
44
|
var propTypes: any;
|
|
46
45
|
}
|
|
@@ -4,7 +4,6 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
4
4
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
5
|
const _excluded = ["items", "changeImportance"],
|
|
6
6
|
_excluded2 = ["getValue"];
|
|
7
|
-
import * as React from 'react';
|
|
8
7
|
import { styled } from '@mui/material/styles';
|
|
9
8
|
import PropTypes from 'prop-types';
|
|
10
9
|
import List from '@mui/material/List';
|
|
@@ -53,7 +52,8 @@ function PickersShortcuts(props) {
|
|
|
53
52
|
onClick: () => {
|
|
54
53
|
setValue(newValue, {
|
|
55
54
|
changeImportance,
|
|
56
|
-
shortcut: item
|
|
55
|
+
shortcut: item,
|
|
56
|
+
source: 'view'
|
|
57
57
|
});
|
|
58
58
|
},
|
|
59
59
|
disabled: !isValidValue(newValue)
|
|
@@ -7,5 +7,5 @@ interface OutlineProps extends React.HTMLAttributes<HTMLFieldSetElement> {
|
|
|
7
7
|
/**
|
|
8
8
|
* @ignore - internal component.
|
|
9
9
|
*/
|
|
10
|
-
export default function Outline(props: OutlineProps):
|
|
10
|
+
export default function Outline(props: OutlineProps): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export {};
|
|
@@ -142,7 +142,10 @@ StaticDatePicker.propTypes = {
|
|
|
142
142
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
143
143
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
144
144
|
* @param {TValue} value The value that was just accepted.
|
|
145
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
145
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
146
|
+
* - `validationError`: validation result of the current value
|
|
147
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
148
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
146
149
|
*/
|
|
147
150
|
onAccept: PropTypes.func,
|
|
148
151
|
/**
|
|
@@ -150,7 +153,10 @@ StaticDatePicker.propTypes = {
|
|
|
150
153
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
151
154
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
152
155
|
* @param {TValue} value The new value.
|
|
153
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
156
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
157
|
+
* - `validationError`: validation result of the current value
|
|
158
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
159
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
154
160
|
*/
|
|
155
161
|
onChange: PropTypes.func,
|
|
156
162
|
/**
|
|
@@ -229,7 +229,10 @@ StaticDateTimePicker.propTypes = {
|
|
|
229
229
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
230
230
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
231
231
|
* @param {TValue} value The value that was just accepted.
|
|
232
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
232
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
233
|
+
* - `validationError`: validation result of the current value
|
|
234
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
235
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
233
236
|
*/
|
|
234
237
|
onAccept: PropTypes.func,
|
|
235
238
|
/**
|
|
@@ -237,7 +240,10 @@ StaticDateTimePicker.propTypes = {
|
|
|
237
240
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
238
241
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
239
242
|
* @param {TValue} value The new value.
|
|
240
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
243
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
244
|
+
* - `validationError`: validation result of the current value
|
|
245
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
246
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
241
247
|
*/
|
|
242
248
|
onChange: PropTypes.func,
|
|
243
249
|
/**
|
|
@@ -132,7 +132,10 @@ StaticTimePicker.propTypes = {
|
|
|
132
132
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
133
133
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
134
134
|
* @param {TValue} value The value that was just accepted.
|
|
135
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
135
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
136
|
+
* - `validationError`: validation result of the current value
|
|
137
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
138
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
136
139
|
*/
|
|
137
140
|
onAccept: PropTypes.func,
|
|
138
141
|
/**
|
|
@@ -140,7 +143,10 @@ StaticTimePicker.propTypes = {
|
|
|
140
143
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
141
144
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
142
145
|
* @param {TValue} value The new value.
|
|
143
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
146
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
147
|
+
* - `validationError`: validation result of the current value
|
|
148
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
149
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
144
150
|
*/
|
|
145
151
|
onChange: PropTypes.func,
|
|
146
152
|
/**
|
package/esm/TimeClock/Clock.d.ts
CHANGED
|
@@ -47,4 +47,4 @@ export interface ClockOwnerState extends PickerOwnerState {
|
|
|
47
47
|
/**
|
|
48
48
|
* @ignore - internal component.
|
|
49
49
|
*/
|
|
50
|
-
export declare function Clock(inProps: ClockProps):
|
|
50
|
+
export declare function Clock(inProps: ClockProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -34,4 +34,4 @@ export interface ClockNumberOwnerState extends PickerOwnerState {
|
|
|
34
34
|
/**
|
|
35
35
|
* @ignore - internal component.
|
|
36
36
|
*/
|
|
37
|
-
export declare function ClockNumber(inProps: ClockNumberProps):
|
|
37
|
+
export declare function ClockNumber(inProps: ClockNumberProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -28,4 +28,4 @@ export interface ClockPointerOwnerState extends PickerOwnerState {
|
|
|
28
28
|
/**
|
|
29
29
|
* @ignore - internal component.
|
|
30
30
|
*/
|
|
31
|
-
export declare function ClockPointer(inProps: ClockPointerProps):
|
|
31
|
+
export declare function ClockPointer(inProps: ClockPointerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -164,7 +164,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
|
|
|
164
164
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
165
165
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
166
166
|
* @param {TValue} value The value that was just accepted.
|
|
167
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
167
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this acceptance:
|
|
168
|
+
* - `validationError`: validation result of the current value
|
|
169
|
+
* - `source`: source of the acceptance. One of 'field' | 'picker' | 'unknown'
|
|
170
|
+
* - `shortcut` (optional): the shortcut metadata if the value was accepted via a shortcut selection
|
|
168
171
|
*/
|
|
169
172
|
onAccept: PropTypes.func,
|
|
170
173
|
/**
|
|
@@ -172,7 +175,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
|
|
|
172
175
|
* @template TValue The value type. It will be the same type as `value` or `null`. It can be in `[start, end]` format in case of range value.
|
|
173
176
|
* @template TError The validation error type. It will be either `string` or a `null`. It can be in `[start, end]` format in case of range value.
|
|
174
177
|
* @param {TValue} value The new value.
|
|
175
|
-
* @param {FieldChangeHandlerContext<TError>} context
|
|
178
|
+
* @param {FieldChangeHandlerContext<TError>} context Context about this change:
|
|
179
|
+
* - `validationError`: validation result of the current value
|
|
180
|
+
* - `source`: source of the change. One of 'field' | 'view' | 'unknown'
|
|
181
|
+
* - `shortcut` (optional): the shortcut metadata if the change was triggered by a shortcut selection
|
|
176
182
|
*/
|
|
177
183
|
onChange: PropTypes.func,
|
|
178
184
|
/**
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { BaseToolbarProps, ExportedBaseToolbarProps } from "../internals/models/props/toolbar.js";
|
|
3
2
|
import { TimePickerToolbarClasses } from "./timePickerToolbarClasses.js";
|
|
4
3
|
export interface TimePickerToolbarProps extends BaseToolbarProps, ExportedTimePickerToolbarProps {
|
|
@@ -21,7 +20,7 @@ export interface ExportedTimePickerToolbarProps extends ExportedBaseToolbarProps
|
|
|
21
20
|
*
|
|
22
21
|
* - [TimePickerToolbar API](https://mui.com/x/api/date-pickers/time-picker-toolbar/)
|
|
23
22
|
*/
|
|
24
|
-
declare function TimePickerToolbar(inProps: TimePickerToolbarProps):
|
|
23
|
+
declare function TimePickerToolbar(inProps: TimePickerToolbarProps): import("react/jsx-runtime").JSX.Element;
|
|
25
24
|
declare namespace TimePickerToolbar {
|
|
26
25
|
var propTypes: any;
|
|
27
26
|
}
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
5
5
|
const _excluded = ["ampm", "ampmInClock", "className", "classes"];
|
|
6
|
-
import * as React from 'react';
|
|
7
6
|
import clsx from 'clsx';
|
|
8
7
|
import PropTypes from 'prop-types';
|
|
9
8
|
import { styled, useThemeProps } from '@mui/material/styles';
|
|
@@ -140,7 +139,8 @@ function TimePickerToolbar(inProps) {
|
|
|
140
139
|
meridiemMode,
|
|
141
140
|
handleMeridiemChange
|
|
142
141
|
} = useMeridiemMode(value, ampm, newValue => setValue(newValue, {
|
|
143
|
-
changeImportance: 'set'
|
|
142
|
+
changeImportance: 'set',
|
|
143
|
+
source: 'view'
|
|
144
144
|
}));
|
|
145
145
|
const formatSection = format => {
|
|
146
146
|
if (!adapter.isValid(value)) {
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { DateCalendarProps } from "../DateCalendar/index.js";
|
|
3
2
|
import { DateView } from "../models/index.js";
|
|
4
3
|
import { DateOrTimeViewWithMeridiem } from "../internals/models/index.js";
|
|
@@ -47,4 +46,4 @@ export declare const renderDateViewCalendar: ({
|
|
|
47
46
|
fixedWeekNumber,
|
|
48
47
|
displayWeekNumber,
|
|
49
48
|
timezone
|
|
50
|
-
}: DateViewRendererProps<DateView>) =>
|
|
49
|
+
}: DateViewRendererProps<DateView>) => import("react/jsx-runtime").JSX.Element;
|
package/esm/index.js
CHANGED