@mui/material 5.10.5 → 5.10.7
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/Button/Button.js +3 -10
- package/CHANGELOG.md +153 -0
- package/CardHeader/CardHeader.js +1 -3
- package/Checkbox/Checkbox.js +12 -3
- package/Chip/chipClasses.d.ts +8 -0
- package/Chip/chipClasses.js +1 -1
- package/DialogContentText/DialogContentText.js +14 -3
- package/InputLabel/InputLabel.js +12 -3
- package/ListItemButton/ListItemButton.js +10 -3
- package/MenuItem/MenuItem.js +10 -3
- package/OutlinedInput/NotchedOutline.js +2 -2
- package/README.md +1 -0
- package/Radio/Radio.js +12 -3
- package/StepLabel/StepLabel.js +5 -3
- package/SvgIcon/SvgIcon.js +2 -2
- package/SvgIcon/svgIconClasses.d.ts +2 -0
- package/Tooltip/Tooltip.d.ts +2 -2
- package/Tooltip/Tooltip.js +3 -5
- package/Unstable_TrapFocus/index.d.ts +2 -2
- package/Unstable_TrapFocus/index.js +2 -2
- package/esm/Button/Button.js +3 -8
- package/esm/CardHeader/CardHeader.js +1 -3
- package/esm/Checkbox/Checkbox.js +11 -3
- package/esm/Chip/chipClasses.js +1 -1
- package/esm/DialogContentText/DialogContentText.js +13 -3
- package/esm/InputLabel/InputLabel.js +11 -3
- package/esm/ListItemButton/ListItemButton.js +10 -3
- package/esm/MenuItem/MenuItem.js +10 -3
- package/esm/OutlinedInput/NotchedOutline.js +2 -2
- package/esm/Radio/Radio.js +11 -3
- package/esm/StepLabel/StepLabel.js +5 -3
- package/esm/SvgIcon/SvgIcon.js +2 -2
- package/esm/Tooltip/Tooltip.js +3 -5
- package/esm/Unstable_TrapFocus/index.js +1 -1
- package/esm/index.js +2 -1
- package/esm/styles/CssVarsProvider.js +3 -1
- package/esm/styles/excludeVariablesFromRoot.js +6 -0
- package/index.d.ts +3 -0
- package/index.js +11 -2
- package/legacy/Button/Button.js +2 -4
- package/legacy/CardHeader/CardHeader.js +1 -3
- package/legacy/Checkbox/Checkbox.js +10 -2
- package/legacy/Chip/chipClasses.js +1 -1
- package/legacy/DialogContentText/DialogContentText.js +10 -2
- package/legacy/InputLabel/InputLabel.js +10 -2
- package/legacy/ListItemButton/ListItemButton.js +9 -2
- package/legacy/MenuItem/MenuItem.js +9 -2
- package/legacy/OutlinedInput/NotchedOutline.js +2 -2
- package/legacy/Radio/Radio.js +10 -2
- package/legacy/StepLabel/StepLabel.js +5 -4
- package/legacy/SvgIcon/SvgIcon.js +2 -2
- package/legacy/Tooltip/Tooltip.js +3 -5
- package/legacy/Unstable_TrapFocus/index.js +1 -1
- package/legacy/index.js +3 -2
- package/legacy/styles/CssVarsProvider.js +3 -1
- package/legacy/styles/excludeVariablesFromRoot.js +12 -0
- package/modern/Button/Button.js +3 -8
- package/modern/CardHeader/CardHeader.js +1 -3
- package/modern/Checkbox/Checkbox.js +11 -3
- package/modern/Chip/chipClasses.js +1 -1
- package/modern/DialogContentText/DialogContentText.js +13 -3
- package/modern/InputLabel/InputLabel.js +11 -3
- package/modern/ListItemButton/ListItemButton.js +10 -3
- package/modern/MenuItem/MenuItem.js +10 -3
- package/modern/OutlinedInput/NotchedOutline.js +2 -2
- package/modern/Radio/Radio.js +11 -3
- package/modern/StepLabel/StepLabel.js +5 -3
- package/modern/SvgIcon/SvgIcon.js +2 -2
- package/modern/Tooltip/Tooltip.js +3 -5
- package/modern/Unstable_TrapFocus/index.js +1 -1
- package/modern/index.js +3 -2
- package/modern/styles/CssVarsProvider.js +3 -1
- package/modern/styles/excludeVariablesFromRoot.js +6 -0
- package/package.json +7 -7
- package/styles/CssVarsProvider.js +4 -1
- package/styles/excludeVariablesFromRoot.d.ts +5 -0
- package/styles/excludeVariablesFromRoot.js +14 -0
- package/umd/material-ui.development.js +512 -479
- package/umd/material-ui.production.min.js +20 -20
|
@@ -50,7 +50,7 @@ const SvgIconRoot = styled('svg', {
|
|
|
50
50
|
inherit: 'inherit',
|
|
51
51
|
small: theme.typography?.pxToRem?.(20) || '1.25rem',
|
|
52
52
|
medium: theme.typography?.pxToRem?.(24) || '1.5rem',
|
|
53
|
-
large: theme.typography?.pxToRem?.(35) || '2.
|
|
53
|
+
large: theme.typography?.pxToRem?.(35) || '2.1875rem'
|
|
54
54
|
}[ownerState.fontSize],
|
|
55
55
|
// TODO v5 deprecate, v6 remove for sx
|
|
56
56
|
color: (theme.vars || theme).palette?.[ownerState.color]?.main ?? {
|
|
@@ -97,13 +97,13 @@ const SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {
|
|
|
97
97
|
return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({
|
|
98
98
|
as: component,
|
|
99
99
|
className: clsx(classes.root, className),
|
|
100
|
-
ownerState: ownerState,
|
|
101
100
|
focusable: "false",
|
|
102
101
|
color: htmlColor,
|
|
103
102
|
"aria-hidden": titleAccess ? undefined : true,
|
|
104
103
|
role: titleAccess ? 'img' : undefined,
|
|
105
104
|
ref: ref
|
|
106
105
|
}, more, other, {
|
|
106
|
+
ownerState: ownerState,
|
|
107
107
|
children: [children, titleAccess ? /*#__PURE__*/_jsx("title", {
|
|
108
108
|
children: titleAccess
|
|
109
109
|
}) : null]
|
|
@@ -463,7 +463,7 @@ const Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {
|
|
|
463
463
|
const handleFocusRef = useForkRef(focusVisibleRef, handleUseRef);
|
|
464
464
|
const handleRef = useForkRef(children.ref, handleFocusRef); // There is no point in displaying an empty tooltip.
|
|
465
465
|
|
|
466
|
-
if (title
|
|
466
|
+
if (typeof title !== 'number' && !title) {
|
|
467
467
|
open = false;
|
|
468
468
|
}
|
|
469
469
|
|
|
@@ -799,11 +799,9 @@ process.env.NODE_ENV !== "production" ? Tooltip.propTypes
|
|
|
799
799
|
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
800
800
|
|
|
801
801
|
/**
|
|
802
|
-
* Tooltip title. Zero-length titles string are never displayed.
|
|
802
|
+
* Tooltip title. Zero-length titles string, undefined, null and false are never displayed.
|
|
803
803
|
*/
|
|
804
|
-
title: PropTypes
|
|
805
|
-
/* @typescript-to-proptypes-ignore */
|
|
806
|
-
.node.isRequired,
|
|
804
|
+
title: PropTypes.node,
|
|
807
805
|
|
|
808
806
|
/**
|
|
809
807
|
* The component used for the transition.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from '@mui/base/
|
|
1
|
+
export { default } from '@mui/base/FocusTrap';
|
package/modern/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** @license MUI v5.10.
|
|
1
|
+
/** @license MUI v5.10.7
|
|
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.
|
|
@@ -280,4 +280,5 @@ export { StyledEngineProvider } from './styles';
|
|
|
280
280
|
export { default as unstable_composeClasses } from '@mui/base/composeClasses';
|
|
281
281
|
export { default as generateUtilityClass } from '@mui/base/generateUtilityClass';
|
|
282
282
|
export * from '@mui/base/generateUtilityClass';
|
|
283
|
-
export { default as generateUtilityClasses } from '@mui/base/generateUtilityClasses';
|
|
283
|
+
export { default as generateUtilityClasses } from '@mui/base/generateUtilityClasses';
|
|
284
|
+
export { default as Unstable_TrapFocus } from './Unstable_TrapFocus';
|
|
@@ -2,6 +2,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import { unstable_createCssVarsProvider as createCssVarsProvider } from '@mui/system';
|
|
3
3
|
import experimental_extendTheme from './experimental_extendTheme';
|
|
4
4
|
import createTypography from './createTypography';
|
|
5
|
+
import excludeVariablesFromRoot from './excludeVariablesFromRoot';
|
|
5
6
|
|
|
6
7
|
const shouldSkipGeneratingVar = keys => !!keys[0].match(/(typography|mixins|breakpoints|direction|transitions)/) || keys[0] === 'palette' && !!keys[1]?.match(/(mode|contrastThreshold|tonalOffset)/);
|
|
7
8
|
|
|
@@ -26,6 +27,7 @@ const {
|
|
|
26
27
|
|
|
27
28
|
return newTheme;
|
|
28
29
|
},
|
|
29
|
-
shouldSkipGeneratingVar
|
|
30
|
+
shouldSkipGeneratingVar,
|
|
31
|
+
excludeVariablesFromRoot
|
|
30
32
|
});
|
|
31
33
|
export { useColorScheme, getInitColorSchemeScript, shouldSkipGeneratingVar, CssVarsProvider as Experimental_CssVarsProvider };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @internal These variables should not appear in the :root stylesheet when the `defaultMode="dark"`
|
|
3
|
+
*/
|
|
4
|
+
const excludeVariablesFromRoot = cssVarPrefix => [...[...Array(24)].map((_, index) => `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}overlays-${index + 1}`), `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}palette-AppBar-darkBg`, `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}palette-AppBar-darkColor`];
|
|
5
|
+
|
|
6
|
+
export default excludeVariablesFromRoot;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/material",
|
|
3
|
-
"version": "5.10.
|
|
3
|
+
"version": "5.10.7",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"description": "React components that implement Google's Material Design.",
|
|
@@ -45,15 +45,15 @@
|
|
|
45
45
|
}
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@babel/runtime": "^7.
|
|
49
|
-
"@mui/base": "5.0.0-alpha.
|
|
50
|
-
"@mui/core-downloads-tracker": "^5.10.
|
|
51
|
-
"@mui/system": "^5.10.
|
|
48
|
+
"@babel/runtime": "^7.19.0",
|
|
49
|
+
"@mui/base": "5.0.0-alpha.99",
|
|
50
|
+
"@mui/core-downloads-tracker": "^5.10.7",
|
|
51
|
+
"@mui/system": "^5.10.7",
|
|
52
52
|
"@mui/types": "^7.2.0",
|
|
53
|
-
"@mui/utils": "^5.10.
|
|
53
|
+
"@mui/utils": "^5.10.6",
|
|
54
54
|
"@types/react-transition-group": "^4.4.5",
|
|
55
55
|
"clsx": "^1.2.1",
|
|
56
|
-
"csstype": "^3.1.
|
|
56
|
+
"csstype": "^3.1.1",
|
|
57
57
|
"prop-types": "^15.8.1",
|
|
58
58
|
"react-is": "^18.2.0",
|
|
59
59
|
"react-transition-group": "^4.4.5"
|
|
@@ -15,6 +15,8 @@ var _experimental_extendTheme = _interopRequireDefault(require("./experimental_e
|
|
|
15
15
|
|
|
16
16
|
var _createTypography = _interopRequireDefault(require("./createTypography"));
|
|
17
17
|
|
|
18
|
+
var _excludeVariablesFromRoot = _interopRequireDefault(require("./excludeVariablesFromRoot"));
|
|
19
|
+
|
|
18
20
|
const shouldSkipGeneratingVar = keys => {
|
|
19
21
|
var _keys$;
|
|
20
22
|
|
|
@@ -42,7 +44,8 @@ const {
|
|
|
42
44
|
});
|
|
43
45
|
return newTheme;
|
|
44
46
|
},
|
|
45
|
-
shouldSkipGeneratingVar
|
|
47
|
+
shouldSkipGeneratingVar,
|
|
48
|
+
excludeVariablesFromRoot: _excludeVariablesFromRoot.default
|
|
46
49
|
});
|
|
47
50
|
exports.getInitColorSchemeScript = getInitColorSchemeScript;
|
|
48
51
|
exports.useColorScheme = useColorScheme;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @internal These variables should not appear in the :root stylesheet when the `defaultMode="dark"`
|
|
10
|
+
*/
|
|
11
|
+
const excludeVariablesFromRoot = cssVarPrefix => [...[...Array(24)].map((_, index) => `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}overlays-${index + 1}`), `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}palette-AppBar-darkBg`, `--${cssVarPrefix ? `${cssVarPrefix}-` : ''}palette-AppBar-darkColor`];
|
|
12
|
+
|
|
13
|
+
var _default = excludeVariablesFromRoot;
|
|
14
|
+
exports.default = _default;
|