@mui/material 5.4.2 → 5.4.3

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.
Files changed (197) hide show
  1. package/Accordion/accordionClasses.d.ts +18 -18
  2. package/AccordionActions/accordionActionsClasses.d.ts +10 -10
  3. package/AccordionDetails/accordionDetailsClasses.d.ts +8 -8
  4. package/AccordionSummary/accordionSummaryClasses.d.ts +22 -22
  5. package/Alert/alertClasses.d.ts +44 -44
  6. package/AlertTitle/alertTitleClasses.d.ts +8 -8
  7. package/AppBar/appBarClasses.d.ts +28 -28
  8. package/Autocomplete/autocompleteClasses.d.ts +54 -54
  9. package/Avatar/avatarClasses.d.ts +20 -20
  10. package/AvatarGroup/avatarGroupClasses.d.ts +10 -10
  11. package/BottomNavigation/BottomNavigation.js +0 -0
  12. package/BottomNavigation/bottomNavigationClasses.d.ts +8 -8
  13. package/BottomNavigationAction/bottomNavigationActionClasses.d.ts +14 -14
  14. package/Breadcrumbs/breadcrumbsClasses.d.ts +14 -14
  15. package/Button/buttonClasses.d.ts +76 -76
  16. package/ButtonBase/ButtonBase.d.ts +1 -1
  17. package/ButtonBase/ButtonBase.js +1 -1
  18. package/ButtonBase/buttonBaseClasses.d.ts +12 -12
  19. package/ButtonBase/touchRippleClasses.d.ts +20 -20
  20. package/ButtonGroup/ButtonGroupContext.d.ts +18 -18
  21. package/ButtonGroup/buttonGroupClasses.d.ts +58 -58
  22. package/CHANGELOG.md +47 -0
  23. package/Card/cardClasses.d.ts +8 -8
  24. package/CardActionArea/cardActionAreaClasses.d.ts +12 -12
  25. package/CardActions/cardActionsClasses.d.ts +10 -10
  26. package/CardContent/cardContentClasses.d.ts +8 -8
  27. package/CardHeader/cardHeaderClasses.d.ts +18 -18
  28. package/CardMedia/cardMediaClasses.d.ts +12 -12
  29. package/Checkbox/checkboxClasses.d.ts +18 -18
  30. package/Chip/chipClasses.d.ts +80 -80
  31. package/CircularProgress/circularProgressClasses.d.ts +26 -26
  32. package/ClickAwayListener/index.d.ts +2 -2
  33. package/Collapse/collapseClasses.d.ts +18 -18
  34. package/Container/containerClasses.d.ts +22 -22
  35. package/Dialog/Dialog.d.ts +4 -1
  36. package/Dialog/Dialog.js +10 -6
  37. package/Dialog/DialogContext.d.ts +6 -6
  38. package/Dialog/dialogClasses.d.ts +36 -36
  39. package/DialogActions/dialogActionsClasses.d.ts +10 -10
  40. package/DialogContent/dialogContentClasses.d.ts +10 -10
  41. package/DialogContentText/dialogContentTextClasses.d.ts +8 -8
  42. package/DialogTitle/dialogTitleClasses.d.ts +8 -8
  43. package/Divider/dividerClasses.d.ts +34 -34
  44. package/Drawer/Drawer.d.ts +4 -1
  45. package/Drawer/Drawer.js +11 -9
  46. package/Drawer/drawerClasses.d.ts +30 -30
  47. package/Fab/fabClasses.d.ts +26 -26
  48. package/Fade/Fade.d.ts +2 -2
  49. package/Fade/Fade.js +8 -8
  50. package/FilledInput/filledInputClasses.d.ts +40 -40
  51. package/FormControl/formControlClasses.d.ts +14 -14
  52. package/FormControlLabel/formControlLabelClasses.d.ts +20 -20
  53. package/FormGroup/formGroupClasses.d.ts +12 -12
  54. package/FormHelperText/formHelperTextClasses.d.ts +22 -22
  55. package/FormLabel/formLabelClasses.d.ts +22 -22
  56. package/Grid/gridClasses.d.ts +48 -48
  57. package/Icon/iconClasses.d.ts +24 -24
  58. package/IconButton/iconButtonClasses.d.ts +26 -26
  59. package/ImageList/imageListClasses.d.ts +16 -16
  60. package/ImageListItem/imageListItemClasses.d.ts +18 -18
  61. package/ImageListItemBar/imageListItemBarClasses.d.ts +30 -30
  62. package/Input/inputClasses.d.ts +34 -34
  63. package/InputAdornment/inputAdornmentClasses.d.ts +24 -24
  64. package/InputBase/inputBaseClasses.d.ts +44 -44
  65. package/InputLabel/inputLabelClasses.d.ts +32 -32
  66. package/LinearProgress/linearProgressClasses.d.ts +42 -42
  67. package/Link/linkClasses.d.ts +18 -18
  68. package/List/listClasses.d.ts +14 -14
  69. package/ListItem/listItemClasses.d.ts +30 -30
  70. package/ListItemAvatar/listItemAvatarClasses.d.ts +10 -10
  71. package/ListItemButton/listItemButtonClasses.d.ts +22 -22
  72. package/ListItemIcon/listItemIconClasses.d.ts +10 -10
  73. package/ListItemSecondaryAction/listItemSecondaryActionClasses.d.ts +10 -10
  74. package/ListItemText/listItemTextClasses.d.ts +18 -18
  75. package/ListSubheader/listSubheaderClasses.d.ts +18 -18
  76. package/Menu/menuClasses.d.ts +12 -12
  77. package/MenuItem/menuItemClasses.d.ts +20 -20
  78. package/MobileStepper/mobileStepperClasses.d.ts +22 -22
  79. package/NativeSelect/nativeSelectClasses.d.ts +32 -32
  80. package/OutlinedInput/outlinedInputClasses.d.ts +36 -36
  81. package/Pagination/paginationClasses.d.ts +14 -14
  82. package/PaginationItem/paginationItemClasses.d.ts +42 -42
  83. package/Paper/paperClasses.d.ts +39 -39
  84. package/Popover/popoverClasses.d.ts +10 -10
  85. package/Popper/Popper.d.ts +17 -17
  86. package/Radio/radioClasses.d.ts +16 -16
  87. package/RadioGroup/RadioGroupContext.d.ts +11 -11
  88. package/RadioGroup/useRadioGroup.d.ts +4 -4
  89. package/Rating/ratingClasses.d.ts +40 -40
  90. package/ScopedCssBaseline/scopedCssBaselineClasses.d.ts +8 -8
  91. package/Select/selectClasses.d.ts +30 -30
  92. package/Skeleton/skeletonClasses.d.ts +24 -24
  93. package/Slide/Slide.d.ts +4 -4
  94. package/Slide/Slide.js +14 -14
  95. package/Snackbar/Snackbar.d.ts +2 -2
  96. package/Snackbar/Snackbar.js +8 -8
  97. package/Snackbar/snackbarClasses.d.ts +20 -20
  98. package/SnackbarContent/snackbarContentClasses.d.ts +12 -12
  99. package/SpeedDial/SpeedDial.d.ts +2 -2
  100. package/SpeedDial/SpeedDial.js +9 -7
  101. package/SpeedDial/speedDialClasses.d.ts +22 -22
  102. package/SpeedDialAction/speedDialActionClasses.d.ts +20 -20
  103. package/SpeedDialIcon/speedDialIconClasses.d.ts +18 -18
  104. package/Step/StepContext.d.ts +20 -0
  105. package/Step/StepContext.js +10 -2
  106. package/Step/index.d.ts +3 -0
  107. package/Step/index.js +3 -1
  108. package/Step/stepClasses.d.ts +16 -16
  109. package/StepButton/stepButtonClasses.d.ts +14 -14
  110. package/StepConnector/stepConnectorClasses.d.ts +26 -26
  111. package/StepContent/stepContentClasses.d.ts +12 -12
  112. package/StepIcon/stepIconClasses.d.ts +16 -16
  113. package/StepLabel/stepLabelClasses.d.ts +28 -28
  114. package/Stepper/stepperClasses.d.ts +14 -14
  115. package/SvgIcon/svgIconClasses.d.ts +24 -24
  116. package/SwipeableDrawer/SwipeableDrawer.js +8 -6
  117. package/Switch/switchClasses.d.ts +32 -32
  118. package/Tab/tabClasses.d.ts +26 -26
  119. package/TabScrollButton/tabScrollButtonClasses.d.ts +12 -12
  120. package/Table/tableClasses.d.ts +10 -10
  121. package/TableBody/tableBodyClasses.d.ts +8 -8
  122. package/TableCell/tableCellClasses.d.ts +32 -32
  123. package/TableContainer/tableContainerClasses.d.ts +8 -8
  124. package/TableFooter/tableFooterClasses.d.ts +8 -8
  125. package/TableHead/tableHeadClasses.d.ts +8 -8
  126. package/TablePagination/tablePaginationClasses.d.ts +28 -28
  127. package/TableRow/tableRowClasses.d.ts +16 -16
  128. package/TableSortLabel/tableSortLabelClasses.d.ts +16 -16
  129. package/Tabs/tabsClasses.d.ts +32 -32
  130. package/TextField/textFieldClasses.d.ts +8 -8
  131. package/ToggleButton/toggleButtonClasses.d.ts +24 -24
  132. package/ToggleButtonGroup/toggleButtonGroupClasses.d.ts +18 -18
  133. package/Toolbar/toolbarClasses.d.ts +14 -14
  134. package/Tooltip/tooltipClasses.d.ts +30 -30
  135. package/Typography/typographyClasses.d.ts +50 -50
  136. package/Zoom/Zoom.d.ts +2 -2
  137. package/Zoom/Zoom.js +8 -8
  138. package/darkScrollbar/index.d.ts +28 -28
  139. package/index.js +1 -1
  140. package/internal/switchBaseClasses.d.ts +12 -12
  141. package/legacy/BottomNavigation/BottomNavigation.js +0 -0
  142. package/legacy/ButtonBase/ButtonBase.js +1 -1
  143. package/legacy/Dialog/Dialog.js +10 -6
  144. package/legacy/Drawer/Drawer.js +11 -9
  145. package/legacy/Fade/Fade.js +8 -8
  146. package/legacy/Slide/Slide.js +14 -14
  147. package/legacy/Snackbar/Snackbar.js +8 -8
  148. package/legacy/SpeedDial/SpeedDial.js +9 -7
  149. package/legacy/Step/StepContext.js +10 -2
  150. package/legacy/Step/index.js +3 -1
  151. package/legacy/SwipeableDrawer/SwipeableDrawer.js +8 -6
  152. package/legacy/Zoom/Zoom.js +8 -8
  153. package/legacy/index.js +1 -1
  154. package/legacy/locale/index.js +86 -78
  155. package/locale/index.d.ts +68 -68
  156. package/locale/index.js +12 -6
  157. package/modern/BottomNavigation/BottomNavigation.js +0 -0
  158. package/modern/ButtonBase/ButtonBase.js +1 -1
  159. package/modern/Dialog/Dialog.js +10 -6
  160. package/modern/Drawer/Drawer.js +11 -9
  161. package/modern/Fade/Fade.js +8 -8
  162. package/modern/Slide/Slide.js +14 -14
  163. package/modern/Snackbar/Snackbar.js +8 -8
  164. package/modern/SpeedDial/SpeedDial.js +9 -7
  165. package/modern/Step/StepContext.js +10 -2
  166. package/modern/Step/index.js +3 -1
  167. package/modern/SwipeableDrawer/SwipeableDrawer.js +8 -6
  168. package/modern/Zoom/Zoom.js +8 -8
  169. package/modern/index.js +1 -1
  170. package/modern/locale/index.js +12 -6
  171. package/node/BottomNavigation/BottomNavigation.js +0 -0
  172. package/node/ButtonBase/ButtonBase.js +1 -1
  173. package/node/Dialog/Dialog.js +11 -7
  174. package/node/Drawer/Drawer.js +11 -10
  175. package/node/Fade/Fade.js +7 -9
  176. package/node/Slide/Slide.js +14 -16
  177. package/node/Snackbar/Snackbar.js +8 -9
  178. package/node/SpeedDial/SpeedDial.js +9 -7
  179. package/node/Step/StepContext.js +11 -1
  180. package/node/Step/index.js +22 -1
  181. package/node/SwipeableDrawer/SwipeableDrawer.js +8 -7
  182. package/node/Zoom/Zoom.js +7 -9
  183. package/node/index.js +1 -1
  184. package/node/locale/index.js +12 -6
  185. package/package.json +2 -2
  186. package/transitions/index.d.ts +1 -1
  187. package/transitions/transition.d.ts +13 -13
  188. package/transitions/utils.d.ts +23 -23
  189. package/umd/material-ui.development.js +90 -66
  190. package/umd/material-ui.production.min.js +16 -16
  191. package/useMediaQuery/useMediaQuery.d.ts +31 -31
  192. package/useTouchRipple/index.d.ts +1 -1
  193. package/useTouchRipple/useTouchRipple.d.ts +28 -28
  194. package/utils/getScrollbarSize.d.ts +2 -2
  195. package/utils/ownerDocument.d.ts +2 -2
  196. package/utils/ownerWindow.d.ts +2 -2
  197. package/utils/setRef.d.ts +2 -2
@@ -7,7 +7,6 @@ import { elementAcceptingRef, HTMLElementType, chainPropTypes } from '@mui/utils
7
7
  import debounce from '../utils/debounce';
8
8
  import useForkRef from '../utils/useForkRef';
9
9
  import useTheme from '../styles/useTheme';
10
- import { duration, easing } from '../styles/createTransitions';
11
10
  import { reflow, getTransitionProps } from '../transitions/utils';
12
11
  import { ownerWindow } from '../utils'; // Translate the node so it can't be seen on the screen.
13
12
  // Later, we're going to translate the node back to its original location with `none`.
@@ -81,20 +80,22 @@ export function setTranslateValue(direction, node, containerProp) {
81
80
  node.style.transform = transform;
82
81
  }
83
82
  }
84
- var defaultEasing = {
85
- enter: easing.easeOut,
86
- exit: easing.sharp
87
- };
88
- var defaultTimeout = {
89
- enter: duration.enteringScreen,
90
- exit: duration.leavingScreen
91
- };
92
83
  /**
93
84
  * The Slide transition is used by the [Drawer](/components/drawers/) component.
94
85
  * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.
95
86
  */
96
87
 
97
88
  var Slide = /*#__PURE__*/React.forwardRef(function Slide(props, ref) {
89
+ var theme = useTheme();
90
+ var defaultEasing = {
91
+ enter: theme.transitions.easing.easeOut,
92
+ exit: theme.transitions.easing.sharp
93
+ };
94
+ var defaultTimeout = {
95
+ enter: theme.transitions.duration.enteringScreen,
96
+ exit: theme.transitions.duration.leavingScreen
97
+ };
98
+
98
99
  var addEndListener = props.addEndListener,
99
100
  _props$appear = props.appear,
100
101
  appear = _props$appear === void 0 ? true : _props$appear,
@@ -118,7 +119,6 @@ var Slide = /*#__PURE__*/React.forwardRef(function Slide(props, ref) {
118
119
  TransitionComponent = _props$TransitionComp === void 0 ? Transition : _props$TransitionComp,
119
120
  other = _objectWithoutProperties(props, ["addEndListener", "appear", "children", "container", "direction", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]);
120
121
 
121
- var theme = useTheme();
122
122
  var childrenRef = React.useRef(null);
123
123
  var handleRefIntermediary = useForkRef(_children.ref, childrenRef);
124
124
  var handleRef = useForkRef(handleRefIntermediary, ref);
@@ -308,8 +308,8 @@ process.env.NODE_ENV !== "production" ? Slide.propTypes
308
308
  * The transition timing function.
309
309
  * You may specify a single easing or a object containing enter and exit values.
310
310
  * @default {
311
- * enter: easing.easeOut,
312
- * exit: easing.sharp,
311
+ * enter: theme.transitions.easing.easeOut,
312
+ * exit: theme.transitions.easing.sharp,
313
313
  * }
314
314
  */
315
315
  easing: PropTypes.oneOfType([PropTypes.shape({
@@ -361,8 +361,8 @@ process.env.NODE_ENV !== "production" ? Slide.propTypes
361
361
  * The duration for the transition, in milliseconds.
362
362
  * You may specify a single timeout for all transitions, or individually with an object.
363
363
  * @default {
364
- * enter: duration.enteringScreen,
365
- * exit: duration.leavingScreen,
364
+ * enter: theme.transitions.duration.enteringScreen,
365
+ * exit: theme.transitions.duration.leavingScreen,
366
366
  * }
367
367
  */
368
368
  timeout: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
@@ -9,7 +9,6 @@ import ClickAwayListener from '@mui/base/ClickAwayListener';
9
9
  import styled from '../styles/styled';
10
10
  import useTheme from '../styles/useTheme';
11
11
  import useThemeProps from '../styles/useThemeProps';
12
- import { duration } from '../styles/createTransitions';
13
12
  import useEventCallback from '../utils/useEventCallback';
14
13
  import capitalize from '../utils/capitalize';
15
14
  import Grow from '../Grow';
@@ -86,6 +85,11 @@ var Snackbar = /*#__PURE__*/React.forwardRef(function Snackbar(inProps, ref) {
86
85
  props: inProps,
87
86
  name: 'MuiSnackbar'
88
87
  });
88
+ var theme = useTheme();
89
+ var defaultTransitionDuration = {
90
+ enter: theme.transitions.duration.enteringScreen,
91
+ exit: theme.transitions.duration.leavingScreen
92
+ };
89
93
  var action = props.action,
90
94
  _props$anchorOrigin = props.anchorOrigin;
91
95
  _props$anchorOrigin = _props$anchorOrigin === void 0 ? {
@@ -113,10 +117,7 @@ var Snackbar = /*#__PURE__*/React.forwardRef(function Snackbar(inProps, ref) {
113
117
  _props$TransitionComp = props.TransitionComponent,
114
118
  TransitionComponent = _props$TransitionComp === void 0 ? Grow : _props$TransitionComp,
115
119
  _props$transitionDura = props.transitionDuration,
116
- transitionDuration = _props$transitionDura === void 0 ? {
117
- enter: duration.enteringScreen,
118
- exit: duration.leavingScreen
119
- } : _props$transitionDura,
120
+ transitionDuration = _props$transitionDura === void 0 ? defaultTransitionDuration : _props$transitionDura,
120
121
  _props$TransitionProp = props.TransitionProps;
121
122
  _props$TransitionProp = _props$TransitionProp === void 0 ? {} : _props$TransitionProp;
122
123
 
@@ -125,7 +126,6 @@ var Snackbar = /*#__PURE__*/React.forwardRef(function Snackbar(inProps, ref) {
125
126
  TransitionProps = _objectWithoutProperties(_props$TransitionProp, ["onEnter", "onExited"]),
126
127
  other = _objectWithoutProperties(props, ["action", "anchorOrigin", "autoHideDuration", "children", "className", "ClickAwayListenerProps", "ContentProps", "disableWindowBlurListener", "message", "onBlur", "onClose", "onFocus", "onMouseEnter", "onMouseLeave", "open", "resumeHideDuration", "TransitionComponent", "transitionDuration", "TransitionProps"]);
127
128
 
128
- var theme = useTheme();
129
129
  var isRtl = theme.direction === 'rtl';
130
130
 
131
131
  var ownerState = _extends({}, props, {
@@ -450,8 +450,8 @@ process.env.NODE_ENV !== "production" ? Snackbar.propTypes
450
450
  * The duration for the transition, in milliseconds.
451
451
  * You may specify a single timeout for all transitions, or individually with an object.
452
452
  * @default {
453
- * enter: duration.enteringScreen,
454
- * exit: duration.leavingScreen,
453
+ * enter: theme.transitions.duration.enteringScreen,
454
+ * exit: theme.transitions.duration.leavingScreen,
455
455
  * }
456
456
  */
457
457
  transitionDuration: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
@@ -9,7 +9,7 @@ import clsx from 'clsx';
9
9
  import { unstable_composeClasses as composeClasses } from '@mui/base';
10
10
  import styled from '../styles/styled';
11
11
  import useThemeProps from '../styles/useThemeProps';
12
- import { duration } from '../styles/createTransitions';
12
+ import useTheme from '../styles/useTheme';
13
13
  import Zoom from '../Zoom';
14
14
  import Fab from '../Fab';
15
15
  import capitalize from '../utils/capitalize';
@@ -132,6 +132,11 @@ var SpeedDial = /*#__PURE__*/React.forwardRef(function SpeedDial(inProps, ref) {
132
132
  props: inProps,
133
133
  name: 'MuiSpeedDial'
134
134
  });
135
+ var theme = useTheme();
136
+ var defaultTransitionDuration = {
137
+ enter: theme.transitions.duration.enteringScreen,
138
+ exit: theme.transitions.duration.leavingScreen
139
+ };
135
140
  var ariaLabel = props.ariaLabel,
136
141
  _props$FabProps = props.FabProps;
137
142
  _props$FabProps = _props$FabProps === void 0 ? {} : _props$FabProps;
@@ -157,10 +162,7 @@ var SpeedDial = /*#__PURE__*/React.forwardRef(function SpeedDial(inProps, ref) {
157
162
  _props$TransitionComp = props.TransitionComponent,
158
163
  TransitionComponent = _props$TransitionComp === void 0 ? Zoom : _props$TransitionComp,
159
164
  _props$transitionDura = props.transitionDuration,
160
- transitionDuration = _props$transitionDura === void 0 ? {
161
- enter: duration.enteringScreen,
162
- exit: duration.leavingScreen
163
- } : _props$transitionDura,
165
+ transitionDuration = _props$transitionDura === void 0 ? defaultTransitionDuration : _props$transitionDura,
164
166
  TransitionProps = props.TransitionProps,
165
167
  other = _objectWithoutProperties(props, ["ariaLabel", "FabProps", "children", "className", "direction", "hidden", "icon", "onBlur", "onClose", "onFocus", "onKeyDown", "onMouseEnter", "onMouseLeave", "onOpen", "open", "openIcon", "TransitionComponent", "transitionDuration", "TransitionProps"]);
166
168
 
@@ -541,8 +543,8 @@ process.env.NODE_ENV !== "production" ? SpeedDial.propTypes
541
543
  * The duration for the transition, in milliseconds.
542
544
  * You may specify a single timeout for all transitions, or individually with an object.
543
545
  * @default {
544
- * enter: duration.enteringScreen,
545
- * exit: duration.leavingScreen,
546
+ * enter: theme.transitions.duration.enteringScreen,
547
+ * exit: theme.transitions.duration.leavingScreen,
546
548
  * }
547
549
  */
548
550
  transitionDuration: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
@@ -1,12 +1,20 @@
1
1
  import * as React from 'react';
2
+
2
3
  /**
3
- * @ignore - internal component.
4
+ * Provides information about the current step in Stepper.
4
5
  */
5
-
6
6
  var StepContext = /*#__PURE__*/React.createContext({});
7
7
 
8
8
  if (process.env.NODE_ENV !== 'production') {
9
9
  StepContext.displayName = 'StepContext';
10
10
  }
11
+ /**
12
+ * Returns the current StepContext or an empty object if no StepContext
13
+ * has been defined in the component tree.
14
+ */
15
+
11
16
 
17
+ export function useStepContext() {
18
+ return React.useContext(StepContext);
19
+ }
12
20
  export default StepContext;
@@ -1,3 +1,5 @@
1
1
  export { default } from './Step';
2
2
  export { default as stepClasses } from './stepClasses';
3
- export * from './stepClasses';
3
+ export * from './stepClasses';
4
+ export { default as StepContext } from './StepContext';
5
+ export * from './StepContext';
@@ -10,7 +10,6 @@ import ownerDocument from '../utils/ownerDocument';
10
10
  import ownerWindow from '../utils/ownerWindow';
11
11
  import useEventCallback from '../utils/useEventCallback';
12
12
  import useEnhancedEffect from '../utils/useEnhancedEffect';
13
- import { duration } from '../styles/createTransitions';
14
13
  import useTheme from '../styles/useTheme';
15
14
  import { getTransitionProps } from '../transitions/utils';
16
15
  import SwipeArea from './SwipeArea'; // This value is closed to what browsers are using internally to
@@ -122,16 +121,16 @@ function computeHasNativeHandler(_ref) {
122
121
  }
123
122
 
124
123
  var iOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent);
125
- var transitionDurationDefault = {
126
- enter: duration.enteringScreen,
127
- exit: duration.leavingScreen
128
- };
129
124
  var SwipeableDrawer = /*#__PURE__*/React.forwardRef(function SwipeableDrawer(inProps, ref) {
130
125
  var props = useThemeProps({
131
126
  name: 'MuiSwipeableDrawer',
132
127
  props: inProps
133
128
  });
134
129
  var theme = useTheme();
130
+ var transitionDurationDefault = {
131
+ enter: theme.transitions.duration.enteringScreen,
132
+ exit: theme.transitions.duration.leavingScreen
133
+ };
135
134
  var _props$anchor = props.anchor,
136
135
  anchor = _props$anchor === void 0 ? 'left' : _props$anchor,
137
136
  _props$disableBackdro = props.disableBackdropTransition,
@@ -623,7 +622,10 @@ process.env.NODE_ENV !== "production" ? SwipeableDrawer.propTypes
623
622
  /**
624
623
  * The duration for the transition, in milliseconds.
625
624
  * You may specify a single timeout for all transitions, or individually with an object.
626
- * @default { enter: duration.enteringScreen, exit: duration.leavingScreen }
625
+ * @default {
626
+ * enter: theme.transitions.duration.enteringScreen,
627
+ * exit: theme.transitions.duration.leavingScreen,
628
+ * }
627
629
  */
628
630
  transitionDuration: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
629
631
  appear: PropTypes.number,
@@ -4,7 +4,6 @@ import * as React from 'react';
4
4
  import PropTypes from 'prop-types';
5
5
  import { Transition } from 'react-transition-group';
6
6
  import { elementAcceptingRef } from '@mui/utils';
7
- import { duration } from '../styles/createTransitions';
8
7
  import useTheme from '../styles/useTheme';
9
8
  import { reflow, getTransitionProps } from '../transitions/utils';
10
9
  import useForkRef from '../utils/useForkRef';
@@ -17,10 +16,6 @@ var styles = {
17
16
  transform: 'none'
18
17
  }
19
18
  };
20
- var defaultTimeout = {
21
- enter: duration.enteringScreen,
22
- exit: duration.leavingScreen
23
- };
24
19
  /**
25
20
  * The Zoom transition can be used for the floating variant of the
26
21
  * [Button](/components/buttons/#floating-action-buttons) component.
@@ -28,6 +23,12 @@ var defaultTimeout = {
28
23
  */
29
24
 
30
25
  var Zoom = /*#__PURE__*/React.forwardRef(function Zoom(props, ref) {
26
+ var theme = useTheme();
27
+ var defaultTimeout = {
28
+ enter: theme.transitions.duration.enteringScreen,
29
+ exit: theme.transitions.duration.leavingScreen
30
+ };
31
+
31
32
  var addEndListener = props.addEndListener,
32
33
  _props$appear = props.appear,
33
34
  appear = _props$appear === void 0 ? true : _props$appear,
@@ -47,7 +48,6 @@ var Zoom = /*#__PURE__*/React.forwardRef(function Zoom(props, ref) {
47
48
  TransitionComponent = _props$TransitionComp === void 0 ? Transition : _props$TransitionComp,
48
49
  other = _objectWithoutProperties(props, ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]);
49
50
 
50
- var theme = useTheme();
51
51
  var nodeRef = React.useRef(null);
52
52
  var foreignRef = useForkRef(_children.ref, ref);
53
53
  var handleRef = useForkRef(nodeRef, foreignRef);
@@ -214,8 +214,8 @@ process.env.NODE_ENV !== "production" ? Zoom.propTypes
214
214
  * The duration for the transition, in milliseconds.
215
215
  * You may specify a single timeout for all transitions, or individually with an object.
216
216
  * @default {
217
- * enter: duration.enteringScreen,
218
- * exit: duration.leavingScreen,
217
+ * enter: theme.transitions.duration.enteringScreen,
218
+ * exit: theme.transitions.duration.leavingScreen,
219
219
  * }
220
220
  */
221
221
  timeout: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
package/legacy/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license MUI v5.4.2
1
+ /** @license MUI v5.4.3
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
@@ -1866,9 +1866,13 @@ export var itIT = {
1866
1866
 
1867
1867
  return 'Vai alla pagina precedente';
1868
1868
  },
1869
- labelRowsPerPage: 'Righe per pagina:' // labelDisplayedRows: ({ from, to, count }) =>
1870
- // `${from}–${to} di ${count !== -1 ? count : `more than ${to}`}`,
1871
-
1869
+ labelRowsPerPage: 'Righe per pagina:',
1870
+ labelDisplayedRows: function labelDisplayedRows(_ref14) {
1871
+ var from = _ref14.from,
1872
+ to = _ref14.to,
1873
+ count = _ref14.count;
1874
+ return "".concat(from, "\u2013").concat(to, " di ").concat(count !== -1 ? count : "pi\xF9 di ".concat(to));
1875
+ }
1872
1876
  }
1873
1877
  },
1874
1878
  MuiRating: {
@@ -1946,10 +1950,10 @@ export var jaJP = {
1946
1950
  return '前のページへ';
1947
1951
  },
1948
1952
  labelRowsPerPage: 'ページあたりの行数:',
1949
- labelDisplayedRows: function labelDisplayedRows(_ref14) {
1950
- var from = _ref14.from,
1951
- to = _ref14.to,
1952
- count = _ref14.count;
1953
+ labelDisplayedRows: function labelDisplayedRows(_ref15) {
1954
+ var from = _ref15.from,
1955
+ to = _ref15.to,
1956
+ count = _ref15.count;
1953
1957
  return "".concat(from, "\uFF5E").concat(to, " / ").concat(count !== -1 ? count : "".concat(to, "\u4EE5\u4E0A"));
1954
1958
  }
1955
1959
  }
@@ -2029,10 +2033,10 @@ export var khKH = {
2029
2033
  return 'ទៅទំព័រមុន';
2030
2034
  },
2031
2035
  labelRowsPerPage: 'ចំនួនជួរដេកក្នុងមួយទំព័រ:',
2032
- labelDisplayedRows: function labelDisplayedRows(_ref15) {
2033
- var from = _ref15.from,
2034
- to = _ref15.to,
2035
- count = _ref15.count;
2036
+ labelDisplayedRows: function labelDisplayedRows(_ref16) {
2037
+ var from = _ref16.from,
2038
+ to = _ref16.to,
2039
+ count = _ref16.count;
2036
2040
  return "".concat(from, " - ").concat(to, " \u1793\u17C3 ").concat(count !== -1 ? count : "\u1785\u17D2\u179A\u17BE\u1793\u1787\u17B6\u1784 ".concat(to));
2037
2041
  }
2038
2042
  }
@@ -2112,10 +2116,10 @@ export var koKR = {
2112
2116
  return '이전 페이지로 이동';
2113
2117
  },
2114
2118
  labelRowsPerPage: '페이지 당 행:',
2115
- labelDisplayedRows: function labelDisplayedRows(_ref16) {
2116
- var from = _ref16.from,
2117
- to = _ref16.to,
2118
- count = _ref16.count;
2119
+ labelDisplayedRows: function labelDisplayedRows(_ref17) {
2120
+ var from = _ref17.from,
2121
+ to = _ref17.to,
2122
+ count = _ref17.count;
2119
2123
  return "".concat(from, "\u2013").concat(to, " / ").concat(count !== -1 ? count : "".concat(to, "\uAC1C \uC774\uC0C1"));
2120
2124
  }
2121
2125
  }
@@ -2195,10 +2199,10 @@ export var kzKZ = {
2195
2199
  return 'Алдыңғы бетке өту';
2196
2200
  },
2197
2201
  labelRowsPerPage: 'Беттегі қатарлар:',
2198
- labelDisplayedRows: function labelDisplayedRows(_ref17) {
2199
- var from = _ref17.from,
2200
- to = _ref17.to,
2201
- count = _ref17.count;
2202
+ labelDisplayedRows: function labelDisplayedRows(_ref18) {
2203
+ var from = _ref18.from,
2204
+ to = _ref18.to,
2205
+ count = _ref18.count;
2202
2206
  return "".concat(count !== -1 ? count : "+".concat(to), " \u049B\u0430\u0442\u0430\u0440\u0434\u044B\u04A3 \u0456\u0448\u0456\u043D\u0435\u043D ").concat(from, "\u2013").concat(to);
2203
2207
  }
2204
2208
  }
@@ -2282,10 +2286,10 @@ export var nbNO = {
2282
2286
  return 'Gå til forrige side';
2283
2287
  },
2284
2288
  labelRowsPerPage: 'Rader per side:',
2285
- labelDisplayedRows: function labelDisplayedRows(_ref18) {
2286
- var from = _ref18.from,
2287
- to = _ref18.to,
2288
- count = _ref18.count;
2289
+ labelDisplayedRows: function labelDisplayedRows(_ref19) {
2290
+ var from = _ref19.from,
2291
+ to = _ref19.to,
2292
+ count = _ref19.count;
2289
2293
  return "".concat(from, "\u2013").concat(to, " av ").concat(count !== -1 ? count : "mer enn ".concat(to));
2290
2294
  }
2291
2295
  }
@@ -2365,10 +2369,10 @@ export var nlNL = {
2365
2369
  return 'Ga naar vorige pagina';
2366
2370
  },
2367
2371
  labelRowsPerPage: 'Regels per pagina:',
2368
- labelDisplayedRows: function labelDisplayedRows(_ref19) {
2369
- var from = _ref19.from,
2370
- to = _ref19.to,
2371
- count = _ref19.count;
2372
+ labelDisplayedRows: function labelDisplayedRows(_ref20) {
2373
+ var from = _ref20.from,
2374
+ to = _ref20.to,
2375
+ count = _ref20.count;
2372
2376
  return "".concat(from, "\u2013").concat(to, " van ").concat(count !== -1 ? count : "meer dan ".concat(to));
2373
2377
  }
2374
2378
  }
@@ -2447,9 +2451,13 @@ export var plPL = {
2447
2451
 
2448
2452
  return 'Przejdź do poprzedniej strony';
2449
2453
  },
2450
- labelRowsPerPage: 'Wierszy na stronę:' // labelDisplayedRows: ({ from, to, count }) =>
2451
- // `${from}–${to} z ${count !== -1 ? count : `more than ${to}`}`,
2452
-
2454
+ labelRowsPerPage: 'Wierszy na stronę:',
2455
+ labelDisplayedRows: function labelDisplayedRows(_ref21) {
2456
+ var from = _ref21.from,
2457
+ to = _ref21.to,
2458
+ count = _ref21.count;
2459
+ return "".concat(from, "\u2013").concat(to, " z ").concat(count !== -1 ? count : "ponad ".concat(to));
2460
+ }
2453
2461
  }
2454
2462
  },
2455
2463
  MuiRating: {
@@ -2536,10 +2544,10 @@ export var ptBR = {
2536
2544
  return 'Ir para a página anterior';
2537
2545
  },
2538
2546
  labelRowsPerPage: 'Linhas por página:',
2539
- labelDisplayedRows: function labelDisplayedRows(_ref20) {
2540
- var from = _ref20.from,
2541
- to = _ref20.to,
2542
- count = _ref20.count;
2547
+ labelDisplayedRows: function labelDisplayedRows(_ref22) {
2548
+ var from = _ref22.from,
2549
+ to = _ref22.to,
2550
+ count = _ref22.count;
2543
2551
  return "".concat(from, "\u2013").concat(to, " de ").concat(count !== -1 ? count : "mais de ".concat(to));
2544
2552
  }
2545
2553
  }
@@ -2619,10 +2627,10 @@ export var ptPT = {
2619
2627
  return 'Página anterior';
2620
2628
  },
2621
2629
  labelRowsPerPage: 'Linhas por página:',
2622
- labelDisplayedRows: function labelDisplayedRows(_ref21) {
2623
- var from = _ref21.from,
2624
- to = _ref21.to,
2625
- count = _ref21.count;
2630
+ labelDisplayedRows: function labelDisplayedRows(_ref23) {
2631
+ var from = _ref23.from,
2632
+ to = _ref23.to,
2633
+ count = _ref23.count;
2626
2634
  return "".concat(from, "\u2013").concat(to, " de ").concat(count !== -1 ? count : "mais de ".concat(to));
2627
2635
  }
2628
2636
  }
@@ -2781,10 +2789,10 @@ export var ruRU = {
2781
2789
  return 'Перейти на предыдущую страницу';
2782
2790
  },
2783
2791
  labelRowsPerPage: 'Строк на странице:',
2784
- labelDisplayedRows: function labelDisplayedRows(_ref22) {
2785
- var from = _ref22.from,
2786
- to = _ref22.to,
2787
- count = _ref22.count;
2792
+ labelDisplayedRows: function labelDisplayedRows(_ref24) {
2793
+ var from = _ref24.from,
2794
+ to = _ref24.to,
2795
+ count = _ref24.count;
2788
2796
  return "".concat(from, "\u2013").concat(to, " \u0438\u0437 ").concat(count !== -1 ? count : "\u0431\u043E\u043B\u0435\u0435 \u0447\u0435\u043C ".concat(to));
2789
2797
  }
2790
2798
  }
@@ -2877,10 +2885,10 @@ export var siLK = {
2877
2885
  return 'පෙර පිටුවට යන්න';
2878
2886
  },
2879
2887
  labelRowsPerPage: 'පිටුවක පේළි:',
2880
- labelDisplayedRows: function labelDisplayedRows(_ref23) {
2881
- var from = _ref23.from,
2882
- to = _ref23.to,
2883
- count = _ref23.count;
2888
+ labelDisplayedRows: function labelDisplayedRows(_ref25) {
2889
+ var from = _ref25.from,
2890
+ to = _ref25.to,
2891
+ count = _ref25.count;
2884
2892
  return "".concat(from, "\u2013").concat(to, " \u0DAF\u0D9A\u0DCA\u0DC0\u0DCF ").concat(count !== -1 ? count : "".concat(to, " \u0DA7 \u0DC0\u0DD0\u0DA9\u0DD2 \u0DB4\u0DCA\u200D\u0DBB\u0DB8\u0DCF\u0DAB\u0DBA\u0D9A\u0DD2\u0DB1\u0DCA"));
2885
2893
  }
2886
2894
  }
@@ -2960,10 +2968,10 @@ export var skSK = {
2960
2968
  return 'Ísť na predchádzajúcu stránku';
2961
2969
  },
2962
2970
  labelRowsPerPage: 'Riadkov na stránke:',
2963
- labelDisplayedRows: function labelDisplayedRows(_ref24) {
2964
- var from = _ref24.from,
2965
- to = _ref24.to,
2966
- count = _ref24.count;
2971
+ labelDisplayedRows: function labelDisplayedRows(_ref26) {
2972
+ var from = _ref26.from,
2973
+ to = _ref26.to,
2974
+ count = _ref26.count;
2967
2975
  return "".concat(from, "\u2013").concat(to, " z ").concat(count !== -1 ? count : "viac ako ".concat(to));
2968
2976
  }
2969
2977
  }
@@ -3051,10 +3059,10 @@ export var svSE = {
3051
3059
  return 'Gå till föregående sida';
3052
3060
  },
3053
3061
  labelRowsPerPage: 'Rader per sida:',
3054
- labelDisplayedRows: function labelDisplayedRows(_ref25) {
3055
- var from = _ref25.from,
3056
- to = _ref25.to,
3057
- count = _ref25.count;
3062
+ labelDisplayedRows: function labelDisplayedRows(_ref27) {
3063
+ var from = _ref27.from,
3064
+ to = _ref27.to,
3065
+ count = _ref27.count;
3058
3066
  return "".concat(from, "\u2013").concat(to, " av ").concat(count !== -1 ? count : "fler \xE4n ".concat(to));
3059
3067
  }
3060
3068
  }
@@ -3134,10 +3142,10 @@ export var thTH = {
3134
3142
  return 'ไปที่หน้าก่อน';
3135
3143
  },
3136
3144
  labelRowsPerPage: 'จำนวนแถวต่อหน้า:',
3137
- labelDisplayedRows: function labelDisplayedRows(_ref26) {
3138
- var from = _ref26.from,
3139
- to = _ref26.to,
3140
- count = _ref26.count;
3145
+ labelDisplayedRows: function labelDisplayedRows(_ref28) {
3146
+ var from = _ref28.from,
3147
+ to = _ref28.to,
3148
+ count = _ref28.count;
3141
3149
  return "".concat(from, "\u2013").concat(to, " \u0E08\u0E32\u0E01 ").concat(count !== -1 ? count : "\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32 ".concat(to));
3142
3150
  }
3143
3151
  }
@@ -3296,10 +3304,10 @@ export var ukUA = {
3296
3304
  return 'Перейти на попередню сторінку';
3297
3305
  },
3298
3306
  labelRowsPerPage: 'Рядків на сторінці:',
3299
- labelDisplayedRows: function labelDisplayedRows(_ref27) {
3300
- var from = _ref27.from,
3301
- to = _ref27.to,
3302
- count = _ref27.count;
3307
+ labelDisplayedRows: function labelDisplayedRows(_ref29) {
3308
+ var from = _ref29.from,
3309
+ to = _ref29.to,
3310
+ count = _ref29.count;
3303
3311
  return "".concat(from, "\u2013").concat(to, " \u0437 ").concat(count !== -1 ? count : "\u043F\u043E\u043D\u0430\u0434 ".concat(to));
3304
3312
  }
3305
3313
  }
@@ -3388,10 +3396,10 @@ export var viVN = {
3388
3396
  return 'Về trang trước đó';
3389
3397
  },
3390
3398
  labelRowsPerPage: 'Số hàng mỗi trang:',
3391
- labelDisplayedRows: function labelDisplayedRows(_ref28) {
3392
- var from = _ref28.from,
3393
- to = _ref28.to,
3394
- count = _ref28.count;
3399
+ labelDisplayedRows: function labelDisplayedRows(_ref30) {
3400
+ var from = _ref30.from,
3401
+ to = _ref30.to,
3402
+ count = _ref30.count;
3395
3403
  return "".concat(from, "\u2013").concat(to, " trong ").concat(count !== -1 ? count : "nhi\u1EC1u h\u01A1n ".concat(to));
3396
3404
  }
3397
3405
  }
@@ -3470,10 +3478,10 @@ export var zhCN = {
3470
3478
  return '上一页';
3471
3479
  },
3472
3480
  labelRowsPerPage: '每页行数:',
3473
- labelDisplayedRows: function labelDisplayedRows(_ref29) {
3474
- var from = _ref29.from,
3475
- to = _ref29.to,
3476
- count = _ref29.count;
3481
+ labelDisplayedRows: function labelDisplayedRows(_ref31) {
3482
+ var from = _ref31.from,
3483
+ to = _ref31.to,
3484
+ count = _ref31.count;
3477
3485
  return "\u7B2C ".concat(from, " \u6761\u5230\u7B2C ").concat(to, " \u6761\uFF0C").concat(count !== -1 ? "\u5171 ".concat(count, " \u6761") : "\u81F3\u5C11 ".concat(to, " \u6761"));
3478
3486
  }
3479
3487
  }
@@ -3527,10 +3535,10 @@ export var zhHK = {
3527
3535
  return '上一頁';
3528
3536
  },
3529
3537
  labelRowsPerPage: '每頁行數:',
3530
- labelDisplayedRows: function labelDisplayedRows(_ref30) {
3531
- var from = _ref30.from,
3532
- to = _ref30.to,
3533
- count = _ref30.count;
3538
+ labelDisplayedRows: function labelDisplayedRows(_ref32) {
3539
+ var from = _ref32.from,
3540
+ to = _ref32.to,
3541
+ count = _ref32.count;
3534
3542
  return "\u7B2C ".concat(from, " \u9805\u81F3\u7B2C ").concat(to, " \u9805\uFF0C").concat(count !== -1 ? "\u5171 ".concat(count, " \u9805") : "\u8D85\u904E ".concat(to, " \u9805"));
3535
3543
  }
3536
3544
  }
@@ -3584,10 +3592,10 @@ export var zhTW = {
3584
3592
  return '上一頁';
3585
3593
  },
3586
3594
  labelRowsPerPage: '每行行數:',
3587
- labelDisplayedRows: function labelDisplayedRows(_ref31) {
3588
- var from = _ref31.from,
3589
- to = _ref31.to,
3590
- count = _ref31.count;
3595
+ labelDisplayedRows: function labelDisplayedRows(_ref33) {
3596
+ var from = _ref33.from,
3597
+ to = _ref33.to,
3598
+ count = _ref33.count;
3591
3599
  return "\u7B2C ".concat(from, " \u689D\u5230\u7B2C ").concat(to, " \u689D\uFF0C").concat(count !== -1 ? "\u5171 ".concat(count, " \u689D") : "\u81F3\u5C11 ".concat(to, " \u689D"));
3592
3600
  }
3593
3601
  }