@mui/material 5.9.3 → 5.10.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/Accordion/accordionClasses.d.ts +18 -18
- package/AccordionActions/accordionActionsClasses.d.ts +10 -10
- package/AccordionDetails/accordionDetailsClasses.d.ts +8 -8
- package/AccordionSummary/accordionSummaryClasses.d.ts +22 -22
- package/Alert/alertClasses.d.ts +44 -44
- package/AlertTitle/alertTitleClasses.d.ts +8 -8
- package/AppBar/appBarClasses.d.ts +28 -28
- package/Autocomplete/autocompleteClasses.d.ts +54 -54
- package/Avatar/avatarClasses.d.ts +20 -20
- package/AvatarGroup/avatarGroupClasses.d.ts +10 -10
- package/Backdrop/backdropClasses.d.ts +10 -10
- package/Badge/badgeClasses.d.ts +56 -56
- package/BottomNavigation/BottomNavigation.js +0 -0
- package/BottomNavigation/bottomNavigationClasses.d.ts +8 -8
- package/BottomNavigationAction/bottomNavigationActionClasses.d.ts +14 -14
- package/Breadcrumbs/breadcrumbsClasses.d.ts +14 -14
- package/Button/buttonClasses.d.ts +100 -100
- package/ButtonBase/buttonBaseClasses.d.ts +12 -12
- package/ButtonBase/touchRippleClasses.d.ts +20 -20
- package/ButtonGroup/ButtonGroupContext.d.ts +18 -18
- package/ButtonGroup/buttonGroupClasses.d.ts +58 -58
- package/CHANGELOG.md +65 -4
- package/Card/cardClasses.d.ts +8 -8
- package/CardActionArea/cardActionAreaClasses.d.ts +12 -12
- package/CardActions/cardActionsClasses.d.ts +10 -10
- package/CardContent/cardContentClasses.d.ts +8 -8
- package/CardHeader/cardHeaderClasses.d.ts +18 -18
- package/CardMedia/cardMediaClasses.d.ts +12 -12
- package/Checkbox/checkboxClasses.d.ts +18 -18
- package/Chip/chipClasses.d.ts +88 -88
- package/CircularProgress/circularProgressClasses.d.ts +26 -26
- package/ClickAwayListener/index.d.ts +2 -2
- package/Collapse/collapseClasses.d.ts +18 -18
- package/Container/containerClasses.d.ts +6 -6
- package/Dialog/DialogContext.d.ts +6 -6
- package/Dialog/dialogClasses.d.ts +36 -36
- package/DialogActions/dialogActionsClasses.d.ts +10 -10
- package/DialogContent/dialogContentClasses.d.ts +10 -10
- package/DialogContentText/dialogContentTextClasses.d.ts +8 -8
- package/DialogTitle/dialogTitleClasses.d.ts +8 -8
- package/Divider/dividerClasses.d.ts +34 -34
- package/Drawer/drawerClasses.d.ts +30 -30
- package/Fab/fabClasses.d.ts +26 -26
- package/FilledInput/filledInputClasses.d.ts +40 -40
- package/FormControl/formControlClasses.d.ts +14 -14
- package/FormControlLabel/formControlLabelClasses.d.ts +20 -20
- package/FormGroup/formGroupClasses.d.ts +12 -12
- package/FormHelperText/formHelperTextClasses.d.ts +22 -22
- package/FormLabel/formLabelClasses.d.ts +22 -22
- package/Grid/Grid.d.ts +1 -1
- package/Grid/Grid.js +6 -2
- package/Grid/gridClasses.d.ts +48 -48
- package/Icon/iconClasses.d.ts +24 -24
- package/IconButton/iconButtonClasses.d.ts +26 -26
- package/ImageList/imageListClasses.d.ts +16 -16
- package/ImageListItem/imageListItemClasses.d.ts +18 -18
- package/ImageListItemBar/imageListItemBarClasses.d.ts +30 -30
- package/Input/inputClasses.d.ts +34 -34
- package/InputAdornment/inputAdornmentClasses.d.ts +24 -24
- package/InputBase/inputBaseClasses.d.ts +46 -46
- package/InputLabel/inputLabelClasses.d.ts +32 -32
- package/LinearProgress/linearProgressClasses.d.ts +42 -42
- package/Link/getTextDecoration.d.ts +15 -15
- package/Link/linkClasses.d.ts +18 -18
- package/List/listClasses.d.ts +14 -14
- package/ListItem/listItemClasses.d.ts +30 -30
- package/ListItemAvatar/listItemAvatarClasses.d.ts +10 -10
- package/ListItemButton/listItemButtonClasses.d.ts +22 -22
- package/ListItemIcon/listItemIconClasses.d.ts +10 -10
- package/ListItemSecondaryAction/listItemSecondaryActionClasses.d.ts +10 -10
- package/ListItemText/listItemTextClasses.d.ts +18 -18
- package/ListSubheader/listSubheaderClasses.d.ts +18 -18
- package/Menu/menuClasses.d.ts +12 -12
- package/MenuItem/menuItemClasses.d.ts +20 -20
- package/MobileStepper/mobileStepperClasses.d.ts +22 -22
- package/NativeSelect/nativeSelectClasses.d.ts +32 -32
- package/OutlinedInput/outlinedInputClasses.d.ts +36 -36
- package/Pagination/paginationClasses.d.ts +14 -14
- package/PaginationItem/paginationItemClasses.d.ts +42 -42
- package/Paper/paperClasses.d.ts +39 -39
- package/Popover/popoverClasses.d.ts +10 -10
- package/Popper/Popper.d.ts +24 -24
- package/README.md +2 -2
- package/Radio/radioClasses.d.ts +16 -16
- package/RadioGroup/RadioGroupContext.d.ts +11 -11
- package/RadioGroup/useRadioGroup.d.ts +4 -4
- package/Rating/ratingClasses.d.ts +40 -40
- package/ScopedCssBaseline/scopedCssBaselineClasses.d.ts +8 -8
- package/Select/selectClasses.d.ts +30 -30
- package/Skeleton/Skeleton.d.ts +1 -1
- package/Skeleton/Skeleton.js +3 -1
- package/Skeleton/skeletonClasses.d.ts +26 -24
- package/Skeleton/skeletonClasses.js +1 -1
- package/Snackbar/snackbarClasses.d.ts +20 -20
- package/SnackbarContent/snackbarContentClasses.d.ts +12 -12
- package/SpeedDial/speedDialClasses.d.ts +22 -22
- package/SpeedDialAction/speedDialActionClasses.d.ts +20 -20
- package/SpeedDialIcon/speedDialIconClasses.d.ts +18 -18
- package/Step/StepContext.d.ts +20 -20
- package/Step/stepClasses.d.ts +16 -16
- package/StepButton/stepButtonClasses.d.ts +14 -14
- package/StepConnector/stepConnectorClasses.d.ts +26 -26
- package/StepContent/stepContentClasses.d.ts +12 -12
- package/StepIcon/stepIconClasses.d.ts +16 -16
- package/StepLabel/StepLabel.js +1 -1
- package/StepLabel/stepLabelClasses.d.ts +28 -28
- package/Stepper/StepperContext.d.ts +18 -18
- package/Stepper/stepperClasses.d.ts +14 -14
- package/SvgIcon/svgIconClasses.d.ts +24 -24
- package/Switch/switchClasses.d.ts +32 -32
- package/Tab/tabClasses.d.ts +26 -26
- package/TabScrollButton/tabScrollButtonClasses.d.ts +12 -12
- package/Table/tableClasses.d.ts +10 -10
- package/TableBody/tableBodyClasses.d.ts +8 -8
- package/TableCell/TableCell.d.ts +4 -1
- package/TableCell/TableCell.js +3 -1
- package/TableCell/tableCellClasses.d.ts +32 -32
- package/TableContainer/tableContainerClasses.d.ts +8 -8
- package/TableFooter/tableFooterClasses.d.ts +8 -8
- package/TableHead/tableHeadClasses.d.ts +8 -8
- package/TablePagination/tablePaginationClasses.d.ts +28 -28
- package/TableRow/tableRowClasses.d.ts +16 -16
- package/TableSortLabel/tableSortLabelClasses.d.ts +16 -16
- package/Tabs/tabsClasses.d.ts +32 -32
- package/TextField/textFieldClasses.d.ts +8 -8
- package/ToggleButton/toggleButtonClasses.d.ts +24 -24
- package/ToggleButtonGroup/toggleButtonGroupClasses.d.ts +18 -18
- package/Toolbar/toolbarClasses.d.ts +14 -14
- package/Tooltip/Tooltip.js +1 -1
- package/Tooltip/tooltipClasses.d.ts +30 -30
- package/Typography/typographyClasses.d.ts +50 -50
- package/Unstable_Grid2/Grid2.d.ts +4 -4
- package/Unstable_Grid2/Grid2Props.d.ts +15 -15
- package/Unstable_Grid2/grid2Classes.d.ts +5 -5
- package/Unstable_Grid2/index.d.ts +4 -4
- package/className/index.d.ts +1 -1
- package/darkScrollbar/index.d.ts +28 -28
- package/index.js +1 -1
- package/internal/switchBaseClasses.d.ts +12 -12
- package/legacy/BottomNavigation/BottomNavigation.js +0 -0
- package/legacy/Grid/Grid.js +6 -2
- package/legacy/Skeleton/Skeleton.js +3 -1
- package/legacy/Skeleton/skeletonClasses.js +1 -1
- package/legacy/StepLabel/StepLabel.js +1 -1
- package/legacy/TableCell/TableCell.js +3 -1
- package/legacy/Tooltip/Tooltip.js +1 -1
- package/legacy/index.js +1 -1
- package/legacy/useScrollTrigger/useScrollTrigger.js +6 -2
- package/locale/index.d.ts +71 -71
- package/modern/BottomNavigation/BottomNavigation.js +0 -0
- package/modern/Grid/Grid.js +2 -2
- package/modern/Skeleton/Skeleton.js +3 -1
- package/modern/Skeleton/skeletonClasses.js +1 -1
- package/modern/StepLabel/StepLabel.js +1 -1
- package/modern/TableCell/TableCell.js +3 -1
- package/modern/Tooltip/Tooltip.js +1 -1
- package/modern/index.js +1 -1
- package/modern/useScrollTrigger/useScrollTrigger.js +6 -2
- package/node/BottomNavigation/BottomNavigation.js +0 -0
- package/node/Grid/Grid.js +6 -2
- package/node/Skeleton/Skeleton.js +3 -1
- package/node/Skeleton/skeletonClasses.js +1 -1
- package/node/StepLabel/StepLabel.js +1 -1
- package/node/TableCell/TableCell.js +3 -1
- package/node/Tooltip/Tooltip.js +1 -1
- package/node/index.js +1 -1
- package/node/useScrollTrigger/useScrollTrigger.js +6 -2
- package/package.json +2 -2
- package/styles/CssVarsProvider.d.ts +14 -14
- package/transitions/index.d.ts +1 -1
- package/transitions/transition.d.ts +13 -13
- package/transitions/utils.d.ts +23 -23
- package/umd/material-ui.development.js +58 -20
- package/umd/material-ui.production.min.js +7 -7
- package/useMediaQuery/useMediaQuery.d.ts +31 -31
- package/useScrollTrigger/useScrollTrigger.js +6 -2
- package/useTouchRipple/index.d.ts +1 -1
- package/useTouchRipple/useTouchRipple.d.ts +28 -28
- package/utils/getScrollbarSize.d.ts +2 -2
- package/utils/ownerDocument.d.ts +2 -2
- package/utils/ownerWindow.d.ts +2 -2
- package/utils/setRef.d.ts +2 -2
package/modern/Grid/Grid.js
CHANGED
|
@@ -195,7 +195,7 @@ export function generateRowGap({
|
|
|
195
195
|
};
|
|
196
196
|
}
|
|
197
197
|
|
|
198
|
-
if (zeroValueBreakpointKeys
|
|
198
|
+
if (zeroValueBreakpointKeys?.includes(breakpoint)) {
|
|
199
199
|
return {};
|
|
200
200
|
}
|
|
201
201
|
|
|
@@ -249,7 +249,7 @@ export function generateColumnGap({
|
|
|
249
249
|
};
|
|
250
250
|
}
|
|
251
251
|
|
|
252
|
-
if (zeroValueBreakpointKeys
|
|
252
|
+
if (zeroValueBreakpointKeys?.includes(breakpoint)) {
|
|
253
253
|
return {};
|
|
254
254
|
}
|
|
255
255
|
|
|
@@ -86,6 +86,8 @@ const SkeletonRoot = styled('span', {
|
|
|
86
86
|
}
|
|
87
87
|
}, ownerState.variant === 'circular' && {
|
|
88
88
|
borderRadius: '50%'
|
|
89
|
+
}, ownerState.variant === 'rounded' && {
|
|
90
|
+
borderRadius: (theme.vars || theme).shape.borderRadius
|
|
89
91
|
}, ownerState.hasChildren && {
|
|
90
92
|
'& > *': {
|
|
91
93
|
visibility: 'hidden'
|
|
@@ -221,7 +223,7 @@ process.env.NODE_ENV !== "production" ? Skeleton.propTypes
|
|
|
221
223
|
*/
|
|
222
224
|
variant: PropTypes
|
|
223
225
|
/* @typescript-to-proptypes-ignore */
|
|
224
|
-
.oneOfType([PropTypes.oneOf(['circular', 'rectangular', 'text']), PropTypes.string]),
|
|
226
|
+
.oneOfType([PropTypes.oneOf(['circular', 'rectangular', 'rounded', 'text']), PropTypes.string]),
|
|
225
227
|
|
|
226
228
|
/**
|
|
227
229
|
* Width of the skeleton.
|
|
@@ -2,5 +2,5 @@ import { generateUtilityClass, generateUtilityClasses } from '@mui/base';
|
|
|
2
2
|
export function getSkeletonUtilityClass(slot) {
|
|
3
3
|
return generateUtilityClass('MuiSkeleton', slot);
|
|
4
4
|
}
|
|
5
|
-
const skeletonClasses = generateUtilityClasses('MuiSkeleton', ['root', 'text', 'rectangular', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
5
|
+
const skeletonClasses = generateUtilityClasses('MuiSkeleton', ['root', 'text', 'rectangular', 'rounded', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
6
6
|
export default skeletonClasses;
|
|
@@ -27,7 +27,7 @@ const useUtilityClasses = ownerState => {
|
|
|
27
27
|
const slots = {
|
|
28
28
|
root: ['root', orientation, error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
29
29
|
label: ['label', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
30
|
-
iconContainer: ['iconContainer', alternativeLabel && 'alternativeLabel'],
|
|
30
|
+
iconContainer: ['iconContainer', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
31
31
|
labelContainer: ['labelContainer']
|
|
32
32
|
};
|
|
33
33
|
return composeClasses(slots, getStepLabelUtilityClass, classes);
|
|
@@ -212,7 +212,9 @@ process.env.NODE_ENV !== "production" ? TableCell.propTypes
|
|
|
212
212
|
* Specify the size of the cell.
|
|
213
213
|
* The prop defaults to the value (`'medium'`) inherited from the parent Table component.
|
|
214
214
|
*/
|
|
215
|
-
size: PropTypes
|
|
215
|
+
size: PropTypes
|
|
216
|
+
/* @typescript-to-proptypes-ignore */
|
|
217
|
+
.oneOfType([PropTypes.oneOf(['medium', 'small']), PropTypes.string]),
|
|
216
218
|
|
|
217
219
|
/**
|
|
218
220
|
* Set aria-sort direction.
|
|
@@ -185,7 +185,7 @@ const TooltipArrow = styled('span', {
|
|
|
185
185
|
/* = width / sqrt(2) = (length of the hypotenuse) */
|
|
186
186
|
,
|
|
187
187
|
boxSizing: 'border-box',
|
|
188
|
-
color: theme.vars ?
|
|
188
|
+
color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),
|
|
189
189
|
'&::before': {
|
|
190
190
|
content: '""',
|
|
191
191
|
margin: 'auto',
|
package/modern/index.js
CHANGED
|
@@ -44,9 +44,13 @@ export default function useScrollTrigger(options = {}) {
|
|
|
44
44
|
|
|
45
45
|
handleScroll(); // Re-evaluate trigger when dependencies change
|
|
46
46
|
|
|
47
|
-
target.addEventListener('scroll', handleScroll
|
|
47
|
+
target.addEventListener('scroll', handleScroll, {
|
|
48
|
+
passive: true
|
|
49
|
+
});
|
|
48
50
|
return () => {
|
|
49
|
-
target.removeEventListener('scroll', handleScroll
|
|
51
|
+
target.removeEventListener('scroll', handleScroll, {
|
|
52
|
+
passive: true
|
|
53
|
+
});
|
|
50
54
|
}; // See Option 3. https://github.com/facebook/react/issues/14476#issuecomment-471199055
|
|
51
55
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52
56
|
}, [target, getTrigger, JSON.stringify(other)]);
|
|
File without changes
|
package/node/Grid/Grid.js
CHANGED
|
@@ -209,6 +209,8 @@ function generateRowGap({
|
|
|
209
209
|
styles = (0, _system.handleBreakpoints)({
|
|
210
210
|
theme
|
|
211
211
|
}, rowSpacingValues, (propValue, breakpoint) => {
|
|
212
|
+
var _zeroValueBreakpointK;
|
|
213
|
+
|
|
212
214
|
const themeSpacing = theme.spacing(propValue);
|
|
213
215
|
|
|
214
216
|
if (themeSpacing !== '0px') {
|
|
@@ -220,7 +222,7 @@ function generateRowGap({
|
|
|
220
222
|
};
|
|
221
223
|
}
|
|
222
224
|
|
|
223
|
-
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
225
|
+
if ((_zeroValueBreakpointK = zeroValueBreakpointKeys) != null && _zeroValueBreakpointK.includes(breakpoint)) {
|
|
224
226
|
return {};
|
|
225
227
|
}
|
|
226
228
|
|
|
@@ -263,6 +265,8 @@ function generateColumnGap({
|
|
|
263
265
|
styles = (0, _system.handleBreakpoints)({
|
|
264
266
|
theme
|
|
265
267
|
}, columnSpacingValues, (propValue, breakpoint) => {
|
|
268
|
+
var _zeroValueBreakpointK2;
|
|
269
|
+
|
|
266
270
|
const themeSpacing = theme.spacing(propValue);
|
|
267
271
|
|
|
268
272
|
if (themeSpacing !== '0px') {
|
|
@@ -275,7 +279,7 @@ function generateColumnGap({
|
|
|
275
279
|
};
|
|
276
280
|
}
|
|
277
281
|
|
|
278
|
-
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
282
|
+
if ((_zeroValueBreakpointK2 = zeroValueBreakpointKeys) != null && _zeroValueBreakpointK2.includes(breakpoint)) {
|
|
279
283
|
return {};
|
|
280
284
|
}
|
|
281
285
|
|
|
@@ -111,6 +111,8 @@ const SkeletonRoot = (0, _styled.default)('span', {
|
|
|
111
111
|
}
|
|
112
112
|
}, ownerState.variant === 'circular' && {
|
|
113
113
|
borderRadius: '50%'
|
|
114
|
+
}, ownerState.variant === 'rounded' && {
|
|
115
|
+
borderRadius: (theme.vars || theme).shape.borderRadius
|
|
114
116
|
}, ownerState.hasChildren && {
|
|
115
117
|
'& > *': {
|
|
116
118
|
visibility: 'hidden'
|
|
@@ -243,7 +245,7 @@ process.env.NODE_ENV !== "production" ? Skeleton.propTypes
|
|
|
243
245
|
*/
|
|
244
246
|
variant: _propTypes.default
|
|
245
247
|
/* @typescript-to-proptypes-ignore */
|
|
246
|
-
.oneOfType([_propTypes.default.oneOf(['circular', 'rectangular', 'text']), _propTypes.default.string]),
|
|
248
|
+
.oneOfType([_propTypes.default.oneOf(['circular', 'rectangular', 'rounded', 'text']), _propTypes.default.string]),
|
|
247
249
|
|
|
248
250
|
/**
|
|
249
251
|
* Width of the skeleton.
|
|
@@ -12,6 +12,6 @@ function getSkeletonUtilityClass(slot) {
|
|
|
12
12
|
return (0, _base.generateUtilityClass)('MuiSkeleton', slot);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
const skeletonClasses = (0, _base.generateUtilityClasses)('MuiSkeleton', ['root', 'text', 'rectangular', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
15
|
+
const skeletonClasses = (0, _base.generateUtilityClasses)('MuiSkeleton', ['root', 'text', 'rectangular', 'rounded', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
16
16
|
var _default = skeletonClasses;
|
|
17
17
|
exports.default = _default;
|
|
@@ -52,7 +52,7 @@ const useUtilityClasses = ownerState => {
|
|
|
52
52
|
const slots = {
|
|
53
53
|
root: ['root', orientation, error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
54
54
|
label: ['label', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
55
|
-
iconContainer: ['iconContainer', alternativeLabel && 'alternativeLabel'],
|
|
55
|
+
iconContainer: ['iconContainer', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
56
56
|
labelContainer: ['labelContainer']
|
|
57
57
|
};
|
|
58
58
|
return (0, _base.unstable_composeClasses)(slots, _stepLabelClasses.getStepLabelUtilityClass, classes);
|
|
@@ -235,7 +235,9 @@ process.env.NODE_ENV !== "production" ? TableCell.propTypes
|
|
|
235
235
|
* Specify the size of the cell.
|
|
236
236
|
* The prop defaults to the value (`'medium'`) inherited from the parent Table component.
|
|
237
237
|
*/
|
|
238
|
-
size: _propTypes.default
|
|
238
|
+
size: _propTypes.default
|
|
239
|
+
/* @typescript-to-proptypes-ignore */
|
|
240
|
+
.oneOfType([_propTypes.default.oneOf(['medium', 'small']), _propTypes.default.string]),
|
|
239
241
|
|
|
240
242
|
/**
|
|
241
243
|
* Set aria-sort direction.
|
package/node/Tooltip/Tooltip.js
CHANGED
|
@@ -219,7 +219,7 @@ const TooltipArrow = (0, _styled.default)('span', {
|
|
|
219
219
|
/* = width / sqrt(2) = (length of the hypotenuse) */
|
|
220
220
|
,
|
|
221
221
|
boxSizing: 'border-box',
|
|
222
|
-
color: theme.vars ?
|
|
222
|
+
color: theme.vars ? theme.vars.palette.Tooltip.bg : (0, _system.alpha)(theme.palette.grey[700], 0.9),
|
|
223
223
|
'&::before': {
|
|
224
224
|
content: '""',
|
|
225
225
|
margin: 'auto',
|
package/node/index.js
CHANGED
|
@@ -60,9 +60,13 @@ function useScrollTrigger(options = {}) {
|
|
|
60
60
|
|
|
61
61
|
handleScroll(); // Re-evaluate trigger when dependencies change
|
|
62
62
|
|
|
63
|
-
target.addEventListener('scroll', handleScroll
|
|
63
|
+
target.addEventListener('scroll', handleScroll, {
|
|
64
|
+
passive: true
|
|
65
|
+
});
|
|
64
66
|
return () => {
|
|
65
|
-
target.removeEventListener('scroll', handleScroll
|
|
67
|
+
target.removeEventListener('scroll', handleScroll, {
|
|
68
|
+
passive: true
|
|
69
|
+
});
|
|
66
70
|
}; // See Option 3. https://github.com/facebook/react/issues/14476#issuecomment-471199055
|
|
67
71
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
68
72
|
}, [target, getTrigger, JSON.stringify(other)]);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/material",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.10.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"description": "React components that implement Google's Material Design.",
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"dependencies": {
|
|
48
48
|
"@babel/runtime": "^7.17.2",
|
|
49
49
|
"@mui/base": "5.0.0-alpha.92",
|
|
50
|
-
"@mui/system": "^5.
|
|
50
|
+
"@mui/system": "^5.10.0",
|
|
51
51
|
"@mui/types": "^7.1.5",
|
|
52
52
|
"@mui/utils": "^5.9.3",
|
|
53
53
|
"@types/react-transition-group": "^4.4.5",
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { SupportedColorScheme } from './experimental_extendTheme';
|
|
3
|
-
declare const shouldSkipGeneratingVar: (keys: string[]) => boolean;
|
|
4
|
-
declare const CssVarsProvider: (props: import("react").PropsWithChildren<Partial<import("@mui/system").CssVarsProviderConfig<SupportedColorScheme>> & {
|
|
5
|
-
theme?: {
|
|
6
|
-
cssVarPrefix?: string | undefined;
|
|
7
|
-
colorSchemes: Record<SupportedColorScheme, Record<string, any>>;
|
|
8
|
-
} | undefined;
|
|
9
|
-
documentNode?: Document | null | undefined;
|
|
10
|
-
colorSchemeNode?: Document | HTMLElement | null | undefined;
|
|
11
|
-
colorSchemeSelector?: string | undefined;
|
|
12
|
-
storageWindow?: Window | null | undefined;
|
|
13
|
-
}>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>, useColorScheme: () => import("@mui/system").ColorSchemeContextValue<SupportedColorScheme>, getInitColorSchemeScript: typeof import("@mui/system").getInitColorSchemeScript;
|
|
14
|
-
export { useColorScheme, getInitColorSchemeScript, shouldSkipGeneratingVar, CssVarsProvider as Experimental_CssVarsProvider, };
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { SupportedColorScheme } from './experimental_extendTheme';
|
|
3
|
+
declare const shouldSkipGeneratingVar: (keys: string[]) => boolean;
|
|
4
|
+
declare const CssVarsProvider: (props: import("react").PropsWithChildren<Partial<import("@mui/system").CssVarsProviderConfig<SupportedColorScheme>> & {
|
|
5
|
+
theme?: {
|
|
6
|
+
cssVarPrefix?: string | undefined;
|
|
7
|
+
colorSchemes: Record<SupportedColorScheme, Record<string, any>>;
|
|
8
|
+
} | undefined;
|
|
9
|
+
documentNode?: Document | null | undefined;
|
|
10
|
+
colorSchemeNode?: Document | HTMLElement | null | undefined;
|
|
11
|
+
colorSchemeSelector?: string | undefined;
|
|
12
|
+
storageWindow?: Window | null | undefined;
|
|
13
|
+
}>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>, useColorScheme: () => import("@mui/system").ColorSchemeContextValue<SupportedColorScheme>, getInitColorSchemeScript: typeof import("@mui/system").getInitColorSchemeScript;
|
|
14
|
+
export { useColorScheme, getInitColorSchemeScript, shouldSkipGeneratingVar, CssVarsProvider as Experimental_CssVarsProvider, };
|
package/transitions/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './transition';
|
|
1
|
+
export * from './transition';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { TransitionProps as _TransitionProps, TransitionActions } from 'react-transition-group/Transition';
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
export declare type TransitionHandlerKeys = 'onEnter' | 'onEntering' | 'onEntered' | 'onExit' | 'onExiting' | 'onExited';
|
|
4
|
-
export declare type TransitionHandlerProps = Pick<_TransitionProps, TransitionHandlerKeys>;
|
|
5
|
-
export interface EasingProps {
|
|
6
|
-
easing: string | {
|
|
7
|
-
enter?: string;
|
|
8
|
-
exit?: string;
|
|
9
|
-
};
|
|
10
|
-
}
|
|
11
|
-
export declare type TransitionKeys = 'in' | 'mountOnEnter' | 'unmountOnExit' | 'timeout' | 'easing' | 'addEndListener' | TransitionHandlerKeys;
|
|
12
|
-
export interface TransitionProps extends TransitionActions, Partial<Pick<_TransitionProps & EasingProps, TransitionKeys>>, React.HTMLAttributes<HTMLElement> {
|
|
13
|
-
}
|
|
1
|
+
import { TransitionProps as _TransitionProps, TransitionActions } from 'react-transition-group/Transition';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare type TransitionHandlerKeys = 'onEnter' | 'onEntering' | 'onEntered' | 'onExit' | 'onExiting' | 'onExited';
|
|
4
|
+
export declare type TransitionHandlerProps = Pick<_TransitionProps, TransitionHandlerKeys>;
|
|
5
|
+
export interface EasingProps {
|
|
6
|
+
easing: string | {
|
|
7
|
+
enter?: string;
|
|
8
|
+
exit?: string;
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
export declare type TransitionKeys = 'in' | 'mountOnEnter' | 'unmountOnExit' | 'timeout' | 'easing' | 'addEndListener' | TransitionHandlerKeys;
|
|
12
|
+
export interface TransitionProps extends TransitionActions, Partial<Pick<_TransitionProps & EasingProps, TransitionKeys>>, React.HTMLAttributes<HTMLElement> {
|
|
13
|
+
}
|
package/transitions/utils.d.ts
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
export declare const reflow: (node: Element) => number;
|
|
3
|
-
interface ComponentProps {
|
|
4
|
-
easing: string | {
|
|
5
|
-
enter?: string;
|
|
6
|
-
exit?: string;
|
|
7
|
-
} | undefined;
|
|
8
|
-
style: React.CSSProperties | undefined;
|
|
9
|
-
timeout: number | {
|
|
10
|
-
enter?: number;
|
|
11
|
-
exit?: number;
|
|
12
|
-
};
|
|
13
|
-
}
|
|
14
|
-
interface Options {
|
|
15
|
-
mode: 'enter' | 'exit';
|
|
16
|
-
}
|
|
17
|
-
interface TransitionProps {
|
|
18
|
-
duration: string | number;
|
|
19
|
-
easing: string | undefined;
|
|
20
|
-
delay: string | undefined;
|
|
21
|
-
}
|
|
22
|
-
export declare function getTransitionProps(props: ComponentProps, options: Options): TransitionProps;
|
|
23
|
-
export {};
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export declare const reflow: (node: Element) => number;
|
|
3
|
+
interface ComponentProps {
|
|
4
|
+
easing: string | {
|
|
5
|
+
enter?: string;
|
|
6
|
+
exit?: string;
|
|
7
|
+
} | undefined;
|
|
8
|
+
style: React.CSSProperties | undefined;
|
|
9
|
+
timeout: number | {
|
|
10
|
+
enter?: number;
|
|
11
|
+
exit?: number;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
interface Options {
|
|
15
|
+
mode: 'enter' | 'exit';
|
|
16
|
+
}
|
|
17
|
+
interface TransitionProps {
|
|
18
|
+
duration: string | number;
|
|
19
|
+
easing: string | undefined;
|
|
20
|
+
delay: string | undefined;
|
|
21
|
+
}
|
|
22
|
+
export declare function getTransitionProps(props: ComponentProps, options: Options): TransitionProps;
|
|
23
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** @license MUI v5.
|
|
1
|
+
/** @license MUI v5.10.0
|
|
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.
|
|
@@ -4738,7 +4738,15 @@
|
|
|
4738
4738
|
return stylesFactory(...styles);
|
|
4739
4739
|
};
|
|
4740
4740
|
}
|
|
4741
|
-
}
|
|
4741
|
+
} // eslint-disable-next-line @typescript-eslint/naming-convention
|
|
4742
|
+
|
|
4743
|
+
const internal_processStyles = (tag, processor) => {
|
|
4744
|
+
// Emotion attaches all the styles as `__emotion_styles`.
|
|
4745
|
+
// Ref: https://github.com/emotion-js/emotion/blob/16d971d0da229596d6bcc39d282ba9753c9ee7cf/packages/styled/src/base.js#L186
|
|
4746
|
+
if (Array.isArray(tag.__emotion_styles)) {
|
|
4747
|
+
tag.__emotion_styles = processor(tag.__emotion_styles);
|
|
4748
|
+
}
|
|
4749
|
+
};
|
|
4742
4750
|
|
|
4743
4751
|
const responsivePropType = PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) ;
|
|
4744
4752
|
var responsivePropType$1 = responsivePropType;
|
|
@@ -6872,7 +6880,9 @@
|
|
|
6872
6880
|
generateClassName,
|
|
6873
6881
|
styleFunctionSx = defaultStyleFunctionSx
|
|
6874
6882
|
} = options;
|
|
6875
|
-
const BoxRoot = styled$3('div'
|
|
6883
|
+
const BoxRoot = styled$3('div', {
|
|
6884
|
+
shouldForwardProp: prop => prop !== 'theme' && prop !== 'sx' && prop !== 'as'
|
|
6885
|
+
})(styleFunctionSx);
|
|
6876
6886
|
const Box = /*#__PURE__*/React__namespace.forwardRef(function Box(inProps, ref) {
|
|
6877
6887
|
const theme = useTheme$1(defaultTheme);
|
|
6878
6888
|
|
|
@@ -6928,6 +6938,14 @@
|
|
|
6928
6938
|
|
|
6929
6939
|
function isEmpty$2(obj) {
|
|
6930
6940
|
return Object.keys(obj).length === 0;
|
|
6941
|
+
} // https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40
|
|
6942
|
+
|
|
6943
|
+
|
|
6944
|
+
function isStringTag(tag) {
|
|
6945
|
+
return typeof tag === 'string' && // 96 is one less than the char code
|
|
6946
|
+
// for "a" so this is checking that
|
|
6947
|
+
// it's a lowercase character
|
|
6948
|
+
tag.charCodeAt(0) > 96;
|
|
6931
6949
|
}
|
|
6932
6950
|
|
|
6933
6951
|
const getStyleOverrides = (name, theme) => {
|
|
@@ -6997,7 +7015,19 @@
|
|
|
6997
7015
|
slotShouldForwardProp = shouldForwardProp,
|
|
6998
7016
|
styleFunctionSx = defaultStyleFunctionSx
|
|
6999
7017
|
} = input;
|
|
7018
|
+
|
|
7019
|
+
const systemSx = props => {
|
|
7020
|
+
const theme = isEmpty$2(props.theme) ? defaultTheme : props.theme;
|
|
7021
|
+
return styleFunctionSx(_extends({}, props, {
|
|
7022
|
+
theme
|
|
7023
|
+
}));
|
|
7024
|
+
};
|
|
7025
|
+
|
|
7026
|
+
systemSx.__mui_systemSx = true;
|
|
7000
7027
|
return (tag, inputOptions = {}) => {
|
|
7028
|
+
// Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.
|
|
7029
|
+
internal_processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));
|
|
7030
|
+
|
|
7001
7031
|
const {
|
|
7002
7032
|
name: componentName,
|
|
7003
7033
|
slot: componentSlot,
|
|
@@ -7025,6 +7055,9 @@
|
|
|
7025
7055
|
} else if (componentSlot) {
|
|
7026
7056
|
// any other slot specified
|
|
7027
7057
|
shouldForwardPropOption = slotShouldForwardProp;
|
|
7058
|
+
} else if (isStringTag(tag)) {
|
|
7059
|
+
// for string (html) tag, preserve the behavior in emotion & styled-components.
|
|
7060
|
+
shouldForwardPropOption = undefined;
|
|
7028
7061
|
}
|
|
7029
7062
|
|
|
7030
7063
|
const defaultStyledResolver = styled$3(tag, _extends({
|
|
@@ -7037,7 +7070,6 @@
|
|
|
7037
7070
|
// On the server Emotion doesn't use React.forwardRef for creating components, so the created
|
|
7038
7071
|
// component stays as a function. This condition makes sure that we do not interpolate functions
|
|
7039
7072
|
// which are basically components used as a selectors.
|
|
7040
|
-
// eslint-disable-next-line no-underscore-dangle
|
|
7041
7073
|
return typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg ? _ref => {
|
|
7042
7074
|
let {
|
|
7043
7075
|
theme: themeInput
|
|
@@ -7078,12 +7110,7 @@
|
|
|
7078
7110
|
}
|
|
7079
7111
|
|
|
7080
7112
|
if (!skipSx) {
|
|
7081
|
-
expressionsWithDefaultTheme.push(
|
|
7082
|
-
const theme = isEmpty$2(props.theme) ? defaultTheme : props.theme;
|
|
7083
|
-
return styleFunctionSx(_extends({}, props, {
|
|
7084
|
-
theme
|
|
7085
|
-
}));
|
|
7086
|
-
});
|
|
7113
|
+
expressionsWithDefaultTheme.push(systemSx);
|
|
7087
7114
|
}
|
|
7088
7115
|
|
|
7089
7116
|
const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;
|
|
@@ -7096,7 +7123,6 @@
|
|
|
7096
7123
|
} else if (typeof styleArg === 'function' && // On the server Emotion doesn't use React.forwardRef for creating components, so the created
|
|
7097
7124
|
// component stays as a function. This condition makes sure that we do not interpolate functions
|
|
7098
7125
|
// which are basically components used as a selectors.
|
|
7099
|
-
// eslint-disable-next-line no-underscore-dangle
|
|
7100
7126
|
styleArg.__emotion_real !== styleArg) {
|
|
7101
7127
|
// If the type is function, we need to define the default theme.
|
|
7102
7128
|
transformedStyleArg = _ref2 => {
|
|
@@ -32061,6 +32087,8 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
32061
32087
|
styles = handleBreakpoints({
|
|
32062
32088
|
theme
|
|
32063
32089
|
}, rowSpacingValues, (propValue, breakpoint) => {
|
|
32090
|
+
var _zeroValueBreakpointK;
|
|
32091
|
+
|
|
32064
32092
|
const themeSpacing = theme.spacing(propValue);
|
|
32065
32093
|
|
|
32066
32094
|
if (themeSpacing !== '0px') {
|
|
@@ -32072,7 +32100,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
32072
32100
|
};
|
|
32073
32101
|
}
|
|
32074
32102
|
|
|
32075
|
-
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
32103
|
+
if ((_zeroValueBreakpointK = zeroValueBreakpointKeys) != null && _zeroValueBreakpointK.includes(breakpoint)) {
|
|
32076
32104
|
return {};
|
|
32077
32105
|
}
|
|
32078
32106
|
|
|
@@ -32114,6 +32142,8 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
32114
32142
|
styles = handleBreakpoints({
|
|
32115
32143
|
theme
|
|
32116
32144
|
}, columnSpacingValues, (propValue, breakpoint) => {
|
|
32145
|
+
var _zeroValueBreakpointK2;
|
|
32146
|
+
|
|
32117
32147
|
const themeSpacing = theme.spacing(propValue);
|
|
32118
32148
|
|
|
32119
32149
|
if (themeSpacing !== '0px') {
|
|
@@ -32126,7 +32156,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
32126
32156
|
};
|
|
32127
32157
|
}
|
|
32128
32158
|
|
|
32129
|
-
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
32159
|
+
if ((_zeroValueBreakpointK2 = zeroValueBreakpointKeys) != null && _zeroValueBreakpointK2.includes(breakpoint)) {
|
|
32130
32160
|
return {};
|
|
32131
32161
|
}
|
|
32132
32162
|
|
|
@@ -42370,7 +42400,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
42370
42400
|
function getSkeletonUtilityClass(slot) {
|
|
42371
42401
|
return generateUtilityClass('MuiSkeleton', slot);
|
|
42372
42402
|
}
|
|
42373
|
-
const skeletonClasses = generateUtilityClasses('MuiSkeleton', ['root', 'text', 'rectangular', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
42403
|
+
const skeletonClasses = generateUtilityClasses('MuiSkeleton', ['root', 'text', 'rectangular', 'rounded', 'circular', 'pulse', 'wave', 'withChildren', 'fitContent', 'heightAuto']);
|
|
42374
42404
|
var skeletonClasses$1 = skeletonClasses;
|
|
42375
42405
|
|
|
42376
42406
|
const _excluded$C = ["animation", "className", "component", "height", "style", "variant", "width"];
|
|
@@ -42455,6 +42485,8 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
42455
42485
|
}
|
|
42456
42486
|
}, ownerState.variant === 'circular' && {
|
|
42457
42487
|
borderRadius: '50%'
|
|
42488
|
+
}, ownerState.variant === 'rounded' && {
|
|
42489
|
+
borderRadius: (theme.vars || theme).shape.borderRadius
|
|
42458
42490
|
}, ownerState.hasChildren && {
|
|
42459
42491
|
'& > *': {
|
|
42460
42492
|
visibility: 'hidden'
|
|
@@ -42590,7 +42622,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
42590
42622
|
*/
|
|
42591
42623
|
variant: PropTypes
|
|
42592
42624
|
/* @typescript-to-proptypes-ignore */
|
|
42593
|
-
.oneOfType([PropTypes.oneOf(['circular', 'rectangular', 'text']), PropTypes.string]),
|
|
42625
|
+
.oneOfType([PropTypes.oneOf(['circular', 'rectangular', 'rounded', 'text']), PropTypes.string]),
|
|
42594
42626
|
|
|
42595
42627
|
/**
|
|
42596
42628
|
* Width of the skeleton.
|
|
@@ -44873,7 +44905,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
44873
44905
|
/* = width / sqrt(2) = (length of the hypotenuse) */
|
|
44874
44906
|
,
|
|
44875
44907
|
boxSizing: 'border-box',
|
|
44876
|
-
color: theme.vars ?
|
|
44908
|
+
color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),
|
|
44877
44909
|
'&::before': {
|
|
44878
44910
|
content: '""',
|
|
44879
44911
|
margin: 'auto',
|
|
@@ -46502,7 +46534,7 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
46502
46534
|
const slots = {
|
|
46503
46535
|
root: ['root', orientation, error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
46504
46536
|
label: ['label', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
46505
|
-
iconContainer: ['iconContainer', alternativeLabel && 'alternativeLabel'],
|
|
46537
|
+
iconContainer: ['iconContainer', active && 'active', completed && 'completed', error && 'error', disabled && 'disabled', alternativeLabel && 'alternativeLabel'],
|
|
46506
46538
|
labelContainer: ['labelContainer']
|
|
46507
46539
|
};
|
|
46508
46540
|
return composeClasses(slots, getStepLabelUtilityClass, classes);
|
|
@@ -49072,7 +49104,9 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
49072
49104
|
* Specify the size of the cell.
|
|
49073
49105
|
* The prop defaults to the value (`'medium'`) inherited from the parent Table component.
|
|
49074
49106
|
*/
|
|
49075
|
-
size: PropTypes
|
|
49107
|
+
size: PropTypes
|
|
49108
|
+
/* @typescript-to-proptypes-ignore */
|
|
49109
|
+
.oneOfType([PropTypes.oneOf(['medium', 'small']), PropTypes.string]),
|
|
49076
49110
|
|
|
49077
49111
|
/**
|
|
49078
49112
|
* Set aria-sort direction.
|
|
@@ -52410,9 +52444,13 @@ See https://mui.com/r/migration-v4/#mui-material-styles for more details.` );
|
|
|
52410
52444
|
|
|
52411
52445
|
handleScroll(); // Re-evaluate trigger when dependencies change
|
|
52412
52446
|
|
|
52413
|
-
target.addEventListener('scroll', handleScroll
|
|
52447
|
+
target.addEventListener('scroll', handleScroll, {
|
|
52448
|
+
passive: true
|
|
52449
|
+
});
|
|
52414
52450
|
return () => {
|
|
52415
|
-
target.removeEventListener('scroll', handleScroll
|
|
52451
|
+
target.removeEventListener('scroll', handleScroll, {
|
|
52452
|
+
passive: true
|
|
52453
|
+
});
|
|
52416
52454
|
}; // See Option 3. https://github.com/facebook/react/issues/14476#issuecomment-471199055
|
|
52417
52455
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52418
52456
|
}, [target, getTrigger, JSON.stringify(other)]);
|