@mui/material 5.9.2 → 5.9.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.
- 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/Badge.js +1 -1
- 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/Button.js +8 -3
- package/Button/buttonClasses.d.ts +100 -100
- package/ButtonBase/TouchRipple.js +1 -1
- 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 +69 -1
- 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/Chip.js +5 -7
- package/Chip/chipClasses.d.ts +88 -80
- package/Chip/chipClasses.js +1 -1
- 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.js +67 -4
- 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/InputBase.js +3 -2
- package/InputBase/inputBaseClasses.d.ts +46 -44
- package/InputBase/inputBaseClasses.js +1 -1
- 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/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/SelectInput.js +1 -1
- package/Select/selectClasses.d.ts +30 -30
- package/Skeleton/skeletonClasses.d.ts +24 -24
- 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/Stack/Stack.js +2 -1
- 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/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/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/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/Badge/Badge.js +1 -1
- package/legacy/BottomNavigation/BottomNavigation.js +0 -0
- package/legacy/Button/Button.js +4 -2
- package/legacy/ButtonBase/TouchRipple.js +1 -1
- package/legacy/Chip/Chip.js +4 -6
- package/legacy/Chip/chipClasses.js +1 -1
- package/legacy/Grid/Grid.js +72 -12
- package/legacy/InputBase/InputBase.js +3 -2
- package/legacy/InputBase/inputBaseClasses.js +1 -1
- package/legacy/Select/SelectInput.js +1 -1
- package/legacy/Stack/Stack.js +2 -1
- package/legacy/index.js +1 -1
- package/legacy/styles/createTheme.js +5 -0
- package/locale/index.d.ts +71 -71
- package/modern/Badge/Badge.js +1 -1
- package/modern/BottomNavigation/BottomNavigation.js +0 -0
- package/modern/Button/Button.js +8 -3
- package/modern/ButtonBase/TouchRipple.js +1 -1
- package/modern/Chip/Chip.js +5 -7
- package/modern/Chip/chipClasses.js +1 -1
- package/modern/Grid/Grid.js +67 -4
- package/modern/InputBase/InputBase.js +3 -2
- package/modern/InputBase/inputBaseClasses.js +1 -1
- package/modern/Select/SelectInput.js +1 -1
- package/modern/Stack/Stack.js +2 -1
- package/modern/index.js +1 -1
- package/modern/styles/createTheme.js +6 -0
- package/node/Badge/Badge.js +1 -1
- package/node/BottomNavigation/BottomNavigation.js +0 -0
- package/node/Button/Button.js +10 -3
- package/node/ButtonBase/TouchRipple.js +1 -1
- package/node/Chip/Chip.js +5 -7
- package/node/Chip/chipClasses.js +1 -1
- package/node/Grid/Grid.js +67 -4
- package/node/InputBase/InputBase.js +3 -2
- package/node/InputBase/inputBaseClasses.js +1 -1
- package/node/Select/SelectInput.js +1 -1
- package/node/Stack/Stack.js +1 -0
- package/node/index.js +1 -1
- package/node/styles/createTheme.js +6 -0
- package/package.json +5 -5
- package/styles/CssVarsProvider.d.ts +14 -14
- package/styles/createTheme.js +6 -0
- 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 +123 -33
- package/umd/material-ui.production.min.js +20 -20
- package/useMediaQuery/useMediaQuery.d.ts +31 -31
- 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
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
+
import { formatMuiErrorMessage as _formatMuiErrorMessage } from "@mui/utils";
|
|
3
4
|
const _excluded = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"];
|
|
4
5
|
import { deepmerge } from '@mui/utils';
|
|
5
6
|
import { generateUtilityClass } from '@mui/base';
|
|
@@ -20,6 +21,11 @@ function createTheme(options = {}, ...args) {
|
|
|
20
21
|
} = options,
|
|
21
22
|
other = _objectWithoutPropertiesLoose(options, _excluded);
|
|
22
23
|
|
|
24
|
+
if (options.vars) {
|
|
25
|
+
throw new Error(process.env.NODE_ENV !== "production" ? `MUI: \`vars\` is a private field used for CSS variables support.
|
|
26
|
+
Please use another name.` : _formatMuiErrorMessage(18));
|
|
27
|
+
}
|
|
28
|
+
|
|
23
29
|
const palette = createPalette(paletteInput);
|
|
24
30
|
const systemTheme = systemCreateTheme(options);
|
|
25
31
|
let muiTheme = deepmerge(systemTheme, {
|
package/node/Badge/Badge.js
CHANGED
|
@@ -251,7 +251,7 @@ const Badge = /*#__PURE__*/React.forwardRef(function Badge(inProps, ref) {
|
|
|
251
251
|
Root: BadgeRoot,
|
|
252
252
|
Badge: BadgeBadge
|
|
253
253
|
}, components),
|
|
254
|
-
className: (0, _clsx.default)(
|
|
254
|
+
className: (0, _clsx.default)((_componentsProps$root = componentsProps.root) == null ? void 0 : _componentsProps$root.className, classes.root, className),
|
|
255
255
|
componentsProps: {
|
|
256
256
|
root: (0, _extends2.default)({}, componentsProps.root, (0, _shouldSpreadAdditionalProps.default)(components.Root) && {
|
|
257
257
|
as: component,
|
|
File without changes
|
package/node/Button/Button.js
CHANGED
|
@@ -37,7 +37,8 @@ var _ButtonGroupContext = _interopRequireDefault(require("../ButtonGroup/ButtonG
|
|
|
37
37
|
|
|
38
38
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
39
39
|
|
|
40
|
-
const _excluded = ["children", "color", "component", "className", "disabled", "disableElevation", "disableFocusRipple", "endIcon", "focusVisibleClassName", "fullWidth", "size", "startIcon", "type", "variant"]
|
|
40
|
+
const _excluded = ["children", "color", "component", "className", "disabled", "disableElevation", "disableFocusRipple", "endIcon", "focusVisibleClassName", "fullWidth", "size", "startIcon", "type", "variant"],
|
|
41
|
+
_excluded2 = ["root"];
|
|
41
42
|
|
|
42
43
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
43
44
|
|
|
@@ -282,7 +283,13 @@ const Button = /*#__PURE__*/React.forwardRef(function Button(inProps, ref) {
|
|
|
282
283
|
type,
|
|
283
284
|
variant
|
|
284
285
|
});
|
|
285
|
-
|
|
286
|
+
|
|
287
|
+
const _useUtilityClasses = useUtilityClasses(ownerState),
|
|
288
|
+
{
|
|
289
|
+
root: classesRoot
|
|
290
|
+
} = _useUtilityClasses,
|
|
291
|
+
classes = (0, _objectWithoutPropertiesLoose2.default)(_useUtilityClasses, _excluded2);
|
|
292
|
+
|
|
286
293
|
const startIcon = startIconProp && /*#__PURE__*/(0, _jsxRuntime.jsx)(ButtonStartIcon, {
|
|
287
294
|
className: classes.startIcon,
|
|
288
295
|
ownerState: ownerState,
|
|
@@ -295,7 +302,7 @@ const Button = /*#__PURE__*/React.forwardRef(function Button(inProps, ref) {
|
|
|
295
302
|
});
|
|
296
303
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(ButtonRoot, (0, _extends2.default)({
|
|
297
304
|
ownerState: ownerState,
|
|
298
|
-
className: (0, _clsx.default)(className,
|
|
305
|
+
className: (0, _clsx.default)(contextProps.className, classesRoot, className),
|
|
299
306
|
component: component,
|
|
300
307
|
disabled: disabled,
|
|
301
308
|
focusRipple: !disableFocusRipple,
|
|
@@ -333,7 +333,7 @@ const TouchRipple = /*#__PURE__*/React.forwardRef(function TouchRipple(inProps,
|
|
|
333
333
|
stop
|
|
334
334
|
}), [pulsate, start, stop]);
|
|
335
335
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(TouchRippleRoot, (0, _extends2.default)({
|
|
336
|
-
className: (0, _clsx.default)(
|
|
336
|
+
className: (0, _clsx.default)(_touchRippleClasses.default.root, classes.root, className),
|
|
337
337
|
ref: container
|
|
338
338
|
}, other, {
|
|
339
339
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactTransitionGroup.TransitionGroup, {
|
package/node/Chip/Chip.js
CHANGED
|
@@ -60,7 +60,7 @@ const useUtilityClasses = ownerState => {
|
|
|
60
60
|
label: ['label', `label${(0, _capitalize.default)(size)}`],
|
|
61
61
|
avatar: ['avatar', `avatar${(0, _capitalize.default)(size)}`, `avatarColor${(0, _capitalize.default)(color)}`],
|
|
62
62
|
icon: ['icon', `icon${(0, _capitalize.default)(size)}`, `iconColor${(0, _capitalize.default)(color)}`],
|
|
63
|
-
deleteIcon: ['deleteIcon', `deleteIcon${(0, _capitalize.default)(size)}`, `deleteIconColor${(0, _capitalize.default)(color)}`, `
|
|
63
|
+
deleteIcon: ['deleteIcon', `deleteIcon${(0, _capitalize.default)(size)}`, `deleteIconColor${(0, _capitalize.default)(color)}`, `deleteIcon${(0, _capitalize.default)(variant)}Color${(0, _capitalize.default)(color)}`]
|
|
64
64
|
};
|
|
65
65
|
return (0, _base.unstable_composeClasses)(slots, _chipClasses.getChipUtilityClass, classes);
|
|
66
66
|
};
|
|
@@ -98,8 +98,8 @@ const ChipRoot = (0, _styled.default)('div', {
|
|
|
98
98
|
}, {
|
|
99
99
|
[`& .${_chipClasses.default.deleteIcon}`]: styles[`deleteIconColor${(0, _capitalize.default)(color)}`]
|
|
100
100
|
}, {
|
|
101
|
-
[`& .${_chipClasses.default.deleteIcon}`]: styles[`
|
|
102
|
-
}, styles.root, styles[`size${(0, _capitalize.default)(size)}`], styles[`color${(0, _capitalize.default)(color)}`], clickable && styles.clickable, clickable && color !== 'default' && styles[`clickableColor${(0, _capitalize.default)(color)})`], onDelete && styles.deletable, onDelete && color !== 'default' && styles[`deletableColor${(0, _capitalize.default)(color)}`], styles[variant],
|
|
101
|
+
[`& .${_chipClasses.default.deleteIcon}`]: styles[`deleteIcon${(0, _capitalize.default)(variant)}Color${(0, _capitalize.default)(color)}`]
|
|
102
|
+
}, styles.root, styles[`size${(0, _capitalize.default)(size)}`], styles[`color${(0, _capitalize.default)(color)}`], clickable && styles.clickable, clickable && color !== 'default' && styles[`clickableColor${(0, _capitalize.default)(color)})`], onDelete && styles.deletable, onDelete && color !== 'default' && styles[`deletableColor${(0, _capitalize.default)(color)}`], styles[variant], styles[`${variant}${(0, _capitalize.default)(color)}`]];
|
|
103
103
|
}
|
|
104
104
|
})(({
|
|
105
105
|
theme,
|
|
@@ -365,7 +365,6 @@ const Chip = /*#__PURE__*/React.forwardRef(function Chip(inProps, ref) {
|
|
|
365
365
|
};
|
|
366
366
|
|
|
367
367
|
const clickable = clickableProp !== false && onClick ? true : clickableProp;
|
|
368
|
-
const small = size === 'small';
|
|
369
368
|
const component = clickable || onDelete ? _ButtonBase.default : ComponentProp || 'div';
|
|
370
369
|
const ownerState = (0, _extends2.default)({}, props, {
|
|
371
370
|
component,
|
|
@@ -386,12 +385,11 @@ const Chip = /*#__PURE__*/React.forwardRef(function Chip(inProps, ref) {
|
|
|
386
385
|
let deleteIcon = null;
|
|
387
386
|
|
|
388
387
|
if (onDelete) {
|
|
389
|
-
const customClasses = (0, _clsx.default)(color !== 'default' && (variant === 'outlined' ? classes[`deleteIconOutlinedColor${(0, _capitalize.default)(color)}`] : classes[`deleteIconColor${(0, _capitalize.default)(color)}`]), small && classes.deleteIconSmall);
|
|
390
388
|
deleteIcon = deleteIconProp && /*#__PURE__*/React.isValidElement(deleteIconProp) ? /*#__PURE__*/React.cloneElement(deleteIconProp, {
|
|
391
|
-
className: (0, _clsx.default)(deleteIconProp.props.className, classes.deleteIcon
|
|
389
|
+
className: (0, _clsx.default)(deleteIconProp.props.className, classes.deleteIcon),
|
|
392
390
|
onClick: handleDeleteIconClick
|
|
393
391
|
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_Cancel.default, {
|
|
394
|
-
className: (0, _clsx.default)(classes.deleteIcon
|
|
392
|
+
className: (0, _clsx.default)(classes.deleteIcon),
|
|
395
393
|
onClick: handleDeleteIconClick
|
|
396
394
|
});
|
|
397
395
|
}
|
package/node/Chip/chipClasses.js
CHANGED
|
@@ -12,6 +12,6 @@ function getChipUtilityClass(slot) {
|
|
|
12
12
|
return (0, _base.generateUtilityClass)('MuiChip', slot);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
const chipClasses = (0, _base.generateUtilityClasses)('MuiChip', ['root', 'sizeSmall', 'sizeMedium', 'colorPrimary', 'colorSecondary', 'disabled', 'clickable', 'clickableColorPrimary', 'clickableColorSecondary', 'deletable', 'deletableColorPrimary', 'deletableColorSecondary', 'outlined', 'filled', 'outlinedPrimary', 'outlinedSecondary', 'avatar', 'avatarSmall', 'avatarMedium', 'avatarColorPrimary', 'avatarColorSecondary', 'icon', 'iconSmall', 'iconMedium', 'iconColorPrimary', 'iconColorSecondary', 'label', 'labelSmall', 'labelMedium', 'deleteIcon', 'deleteIconSmall', 'deleteIconMedium', 'deleteIconColorPrimary', 'deleteIconColorSecondary', 'deleteIconOutlinedColorPrimary', 'deleteIconOutlinedColorSecondary', 'focusVisible']);
|
|
15
|
+
const chipClasses = (0, _base.generateUtilityClasses)('MuiChip', ['root', 'sizeSmall', 'sizeMedium', 'colorPrimary', 'colorSecondary', 'disabled', 'clickable', 'clickableColorPrimary', 'clickableColorSecondary', 'deletable', 'deletableColorPrimary', 'deletableColorSecondary', 'outlined', 'filled', 'outlinedPrimary', 'outlinedSecondary', 'filledPrimary', 'filledSecondary', 'avatar', 'avatarSmall', 'avatarMedium', 'avatarColorPrimary', 'avatarColorSecondary', 'icon', 'iconSmall', 'iconMedium', 'iconColorPrimary', 'iconColorSecondary', 'label', 'labelSmall', 'labelMedium', 'deleteIcon', 'deleteIconSmall', 'deleteIconMedium', 'deleteIconColorPrimary', 'deleteIconColorSecondary', 'deleteIconOutlinedColorPrimary', 'deleteIconOutlinedColorSecondary', 'deleteIconFilledColorPrimary', 'deleteIconFilledColorSecondary', 'focusVisible']);
|
|
16
16
|
var _default = chipClasses;
|
|
17
17
|
exports.default = _default;
|
package/node/Grid/Grid.js
CHANGED
|
@@ -155,6 +155,32 @@ function generateDirection({
|
|
|
155
155
|
return output;
|
|
156
156
|
});
|
|
157
157
|
}
|
|
158
|
+
/**
|
|
159
|
+
* Extracts zero value breakpoint keys before a non-zero value breakpoint key.
|
|
160
|
+
* @example { xs: 0, sm: 0, md: 2, lg: 0, xl: 0 } or [0, 0, 2, 0, 0]
|
|
161
|
+
* @returns [xs, sm]
|
|
162
|
+
*/
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
function extractZeroValueBreakpointKeys({
|
|
166
|
+
breakpoints,
|
|
167
|
+
values
|
|
168
|
+
}) {
|
|
169
|
+
let nonZeroKey = '';
|
|
170
|
+
Object.keys(values).forEach(key => {
|
|
171
|
+
if (nonZeroKey !== '') {
|
|
172
|
+
return;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
if (values[key] !== 0) {
|
|
176
|
+
nonZeroKey = key;
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
const sortedBreakpointKeysByValue = Object.keys(breakpoints).sort((a, b) => {
|
|
180
|
+
return breakpoints[a] - breakpoints[b];
|
|
181
|
+
});
|
|
182
|
+
return sortedBreakpointKeysByValue.slice(0, sortedBreakpointKeysByValue.indexOf(nonZeroKey));
|
|
183
|
+
}
|
|
158
184
|
|
|
159
185
|
function generateRowGap({
|
|
160
186
|
theme,
|
|
@@ -171,9 +197,18 @@ function generateRowGap({
|
|
|
171
197
|
values: rowSpacing,
|
|
172
198
|
breakpoints: theme.breakpoints.values
|
|
173
199
|
});
|
|
200
|
+
let zeroValueBreakpointKeys;
|
|
201
|
+
|
|
202
|
+
if (typeof rowSpacingValues === 'object') {
|
|
203
|
+
zeroValueBreakpointKeys = extractZeroValueBreakpointKeys({
|
|
204
|
+
breakpoints: theme.breakpoints.values,
|
|
205
|
+
values: rowSpacingValues
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
|
|
174
209
|
styles = (0, _system.handleBreakpoints)({
|
|
175
210
|
theme
|
|
176
|
-
}, rowSpacingValues, propValue => {
|
|
211
|
+
}, rowSpacingValues, (propValue, breakpoint) => {
|
|
177
212
|
const themeSpacing = theme.spacing(propValue);
|
|
178
213
|
|
|
179
214
|
if (themeSpacing !== '0px') {
|
|
@@ -185,7 +220,16 @@ function generateRowGap({
|
|
|
185
220
|
};
|
|
186
221
|
}
|
|
187
222
|
|
|
188
|
-
|
|
223
|
+
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
224
|
+
return {};
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
return {
|
|
228
|
+
marginTop: 0,
|
|
229
|
+
[`& > .${_gridClasses.default.item}`]: {
|
|
230
|
+
paddingTop: 0
|
|
231
|
+
}
|
|
232
|
+
};
|
|
189
233
|
});
|
|
190
234
|
}
|
|
191
235
|
|
|
@@ -207,9 +251,18 @@ function generateColumnGap({
|
|
|
207
251
|
values: columnSpacing,
|
|
208
252
|
breakpoints: theme.breakpoints.values
|
|
209
253
|
});
|
|
254
|
+
let zeroValueBreakpointKeys;
|
|
255
|
+
|
|
256
|
+
if (typeof columnSpacingValues === 'object') {
|
|
257
|
+
zeroValueBreakpointKeys = extractZeroValueBreakpointKeys({
|
|
258
|
+
breakpoints: theme.breakpoints.values,
|
|
259
|
+
values: columnSpacingValues
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
|
|
210
263
|
styles = (0, _system.handleBreakpoints)({
|
|
211
264
|
theme
|
|
212
|
-
}, columnSpacingValues, propValue => {
|
|
265
|
+
}, columnSpacingValues, (propValue, breakpoint) => {
|
|
213
266
|
const themeSpacing = theme.spacing(propValue);
|
|
214
267
|
|
|
215
268
|
if (themeSpacing !== '0px') {
|
|
@@ -222,7 +275,17 @@ function generateColumnGap({
|
|
|
222
275
|
};
|
|
223
276
|
}
|
|
224
277
|
|
|
225
|
-
|
|
278
|
+
if (zeroValueBreakpointKeys.includes(breakpoint)) {
|
|
279
|
+
return {};
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
return {
|
|
283
|
+
width: '100%',
|
|
284
|
+
marginLeft: 0,
|
|
285
|
+
[`& > .${_gridClasses.default.item}`]: {
|
|
286
|
+
paddingLeft: 0
|
|
287
|
+
}
|
|
288
|
+
};
|
|
226
289
|
});
|
|
227
290
|
}
|
|
228
291
|
|
|
@@ -81,13 +81,14 @@ const useUtilityClasses = ownerState => {
|
|
|
81
81
|
fullWidth,
|
|
82
82
|
hiddenLabel,
|
|
83
83
|
multiline,
|
|
84
|
+
readOnly,
|
|
84
85
|
size,
|
|
85
86
|
startAdornment,
|
|
86
87
|
type
|
|
87
88
|
} = ownerState;
|
|
88
89
|
const slots = {
|
|
89
|
-
root: ['root', `color${(0, _capitalize.default)(color)}`, disabled && 'disabled', error && 'error', fullWidth && 'fullWidth', focused && 'focused', formControl && 'formControl', size === 'small' && 'sizeSmall', multiline && 'multiline', startAdornment && 'adornedStart', endAdornment && 'adornedEnd', hiddenLabel && 'hiddenLabel'],
|
|
90
|
-
input: ['input', disabled && 'disabled', type === 'search' && 'inputTypeSearch', multiline && 'inputMultiline', size === 'small' && 'inputSizeSmall', hiddenLabel && 'inputHiddenLabel', startAdornment && 'inputAdornedStart', endAdornment && 'inputAdornedEnd']
|
|
90
|
+
root: ['root', `color${(0, _capitalize.default)(color)}`, disabled && 'disabled', error && 'error', fullWidth && 'fullWidth', focused && 'focused', formControl && 'formControl', size === 'small' && 'sizeSmall', multiline && 'multiline', startAdornment && 'adornedStart', endAdornment && 'adornedEnd', hiddenLabel && 'hiddenLabel', readOnly && 'readOnly'],
|
|
91
|
+
input: ['input', disabled && 'disabled', type === 'search' && 'inputTypeSearch', multiline && 'inputMultiline', size === 'small' && 'inputSizeSmall', hiddenLabel && 'inputHiddenLabel', startAdornment && 'inputAdornedStart', endAdornment && 'inputAdornedEnd', readOnly && 'readOnly']
|
|
91
92
|
};
|
|
92
93
|
return (0, _base.unstable_composeClasses)(slots, _inputBaseClasses.getInputBaseUtilityClass, classes);
|
|
93
94
|
};
|
|
@@ -12,6 +12,6 @@ function getInputBaseUtilityClass(slot) {
|
|
|
12
12
|
return (0, _base.generateUtilityClass)('MuiInputBase', slot);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
const inputBaseClasses = (0, _base.generateUtilityClasses)('MuiInputBase', ['root', 'formControl', 'focused', 'disabled', 'adornedStart', 'adornedEnd', 'error', 'sizeSmall', 'multiline', 'colorSecondary', 'fullWidth', 'hiddenLabel', 'input', 'inputSizeSmall', 'inputMultiline', 'inputTypeSearch', 'inputAdornedStart', 'inputAdornedEnd', 'inputHiddenLabel']);
|
|
15
|
+
const inputBaseClasses = (0, _base.generateUtilityClasses)('MuiInputBase', ['root', 'formControl', 'focused', 'disabled', 'adornedStart', 'adornedEnd', 'error', 'sizeSmall', 'multiline', 'colorSecondary', 'fullWidth', 'hiddenLabel', 'readOnly', 'input', 'inputSizeSmall', 'inputMultiline', 'inputTypeSearch', 'inputAdornedStart', 'inputAdornedEnd', 'inputHiddenLabel']);
|
|
16
16
|
var _default = inputBaseClasses;
|
|
17
17
|
exports.default = _default;
|
|
@@ -533,7 +533,7 @@ const SelectInput = /*#__PURE__*/React.forwardRef(function SelectInput(props, re
|
|
|
533
533
|
onFocus: onFocus
|
|
534
534
|
}, SelectDisplayProps, {
|
|
535
535
|
ownerState: ownerState,
|
|
536
|
-
className: (0, _clsx.default)(classes.select, className
|
|
536
|
+
className: (0, _clsx.default)(SelectDisplayProps.className, classes.select, className) // The id is required for proper a11y
|
|
537
537
|
,
|
|
538
538
|
id: buttonId,
|
|
539
539
|
children: isEmpty(display) ? // notranslate needed while Google Translate will not fix zero-width space issue
|
package/node/Stack/Stack.js
CHANGED
package/node/index.js
CHANGED
|
@@ -40,6 +40,12 @@ function createTheme(options = {}, ...args) {
|
|
|
40
40
|
typography: typographyInput = {}
|
|
41
41
|
} = options,
|
|
42
42
|
other = (0, _objectWithoutPropertiesLoose2.default)(options, _excluded);
|
|
43
|
+
|
|
44
|
+
if (options.vars) {
|
|
45
|
+
throw new Error(process.env.NODE_ENV !== "production" ? `MUI: \`vars\` is a private field used for CSS variables support.
|
|
46
|
+
Please use another name.` : (0, _utils.formatMuiErrorMessage)(18));
|
|
47
|
+
}
|
|
48
|
+
|
|
43
49
|
const palette = (0, _createPalette.default)(paletteInput);
|
|
44
50
|
const systemTheme = (0, _system.createTheme)(options);
|
|
45
51
|
let muiTheme = (0, _utils.deepmerge)(systemTheme, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/material",
|
|
3
|
-
"version": "5.9.
|
|
3
|
+
"version": "5.9.3",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"description": "React components that implement Google's Material Design.",
|
|
@@ -46,16 +46,16 @@
|
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
48
|
"@babel/runtime": "^7.17.2",
|
|
49
|
-
"@mui/base": "5.0.0-alpha.
|
|
50
|
-
"@mui/system": "^5.9.
|
|
49
|
+
"@mui/base": "5.0.0-alpha.92",
|
|
50
|
+
"@mui/system": "^5.9.3",
|
|
51
51
|
"@mui/types": "^7.1.5",
|
|
52
|
-
"@mui/utils": "^5.9.
|
|
52
|
+
"@mui/utils": "^5.9.3",
|
|
53
53
|
"@types/react-transition-group": "^4.4.5",
|
|
54
54
|
"clsx": "^1.2.1",
|
|
55
55
|
"csstype": "^3.1.0",
|
|
56
56
|
"prop-types": "^15.8.1",
|
|
57
57
|
"react-is": "^18.2.0",
|
|
58
|
-
"react-transition-group": "^4.4.
|
|
58
|
+
"react-transition-group": "^4.4.5"
|
|
59
59
|
},
|
|
60
60
|
"sideEffects": false,
|
|
61
61
|
"publishConfig": {
|
|
@@ -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/styles/createTheme.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
+
import { formatMuiErrorMessage as _formatMuiErrorMessage } from "@mui/utils";
|
|
3
4
|
const _excluded = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"];
|
|
4
5
|
import { deepmerge } from '@mui/utils';
|
|
5
6
|
import { generateUtilityClass } from '@mui/base';
|
|
@@ -20,6 +21,11 @@ function createTheme(options = {}, ...args) {
|
|
|
20
21
|
} = options,
|
|
21
22
|
other = _objectWithoutPropertiesLoose(options, _excluded);
|
|
22
23
|
|
|
24
|
+
if (options.vars) {
|
|
25
|
+
throw new Error(process.env.NODE_ENV !== "production" ? `MUI: \`vars\` is a private field used for CSS variables support.
|
|
26
|
+
Please use another name.` : _formatMuiErrorMessage(18));
|
|
27
|
+
}
|
|
28
|
+
|
|
23
29
|
const palette = createPalette(paletteInput);
|
|
24
30
|
const systemTheme = systemCreateTheme(options);
|
|
25
31
|
let muiTheme = deepmerge(systemTheme, {
|
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 {};
|