@mui/material 5.8.5 → 5.9.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/Alert/Alert.js +19 -11
- package/Autocomplete/Autocomplete.d.ts +2 -0
- package/Autocomplete/Autocomplete.js +14 -10
- package/CHANGELOG.md +190 -0
- package/FilledInput/FilledInput.js +1 -1
- package/Input/Input.js +1 -1
- package/Modal/Modal.js +6 -6
- package/OutlinedInput/OutlinedInput.js +15 -0
- package/Popper/Popper.d.ts +1 -6
- package/README.md +60 -23
- package/ScopedCssBaseline/ScopedCssBaseline.d.ts +6 -0
- package/ScopedCssBaseline/ScopedCssBaseline.js +6 -1
- package/Select/Select.d.ts +1 -1
- package/Select/Select.js +1 -1
- package/Slider/Slider.js +9 -9
- package/SnackbarContent/SnackbarContent.js +1 -1
- package/Tabs/Tabs.js +10 -2
- package/Tooltip/Tooltip.js +6 -5
- package/Unstable_Grid2/Grid2.d.ts +4 -0
- package/Unstable_Grid2/Grid2.js +34 -0
- package/Unstable_Grid2/Grid2Props.d.ts +15 -0
- package/Unstable_Grid2/Grid2Props.js +1 -0
- package/Unstable_Grid2/grid2Classes.d.ts +5 -0
- package/Unstable_Grid2/grid2Classes.js +14 -0
- package/Unstable_Grid2/index.d.ts +4 -0
- package/Unstable_Grid2/index.js +4 -0
- package/Unstable_Grid2/package.json +6 -0
- package/index.d.ts +3 -0
- package/index.js +3 -1
- package/legacy/Alert/Alert.js +19 -11
- package/legacy/Autocomplete/Autocomplete.js +14 -10
- package/legacy/FilledInput/FilledInput.js +1 -1
- package/legacy/Input/Input.js +1 -1
- package/legacy/Modal/Modal.js +13 -9
- package/legacy/OutlinedInput/OutlinedInput.js +15 -0
- package/legacy/ScopedCssBaseline/ScopedCssBaseline.js +6 -1
- package/legacy/Select/Select.js +1 -1
- package/legacy/Slider/Slider.js +9 -9
- package/legacy/SnackbarContent/SnackbarContent.js +1 -1
- package/legacy/Tabs/Tabs.js +10 -2
- package/legacy/Tooltip/Tooltip.js +6 -5
- package/legacy/Unstable_Grid2/Grid2.js +38 -0
- package/legacy/Unstable_Grid2/Grid2Props.js +1 -0
- package/legacy/Unstable_Grid2/grid2Classes.js +27 -0
- package/legacy/Unstable_Grid2/index.js +4 -0
- package/legacy/index.js +3 -1
- package/legacy/styles/CssVarsProvider.js +10 -8
- package/legacy/styles/experimental_extendTheme.js +85 -29
- package/modern/Alert/Alert.js +19 -11
- package/modern/Autocomplete/Autocomplete.js +13 -9
- package/modern/FilledInput/FilledInput.js +1 -1
- package/modern/Input/Input.js +1 -1
- package/modern/Modal/Modal.js +6 -6
- package/modern/OutlinedInput/OutlinedInput.js +15 -0
- package/modern/ScopedCssBaseline/ScopedCssBaseline.js +6 -1
- package/modern/Select/Select.js +1 -1
- package/modern/Slider/Slider.js +9 -9
- package/modern/SnackbarContent/SnackbarContent.js +1 -1
- package/modern/Tabs/Tabs.js +10 -2
- package/modern/Tooltip/Tooltip.js +6 -5
- package/modern/Unstable_Grid2/Grid2.js +34 -0
- package/modern/Unstable_Grid2/Grid2Props.js +1 -0
- package/modern/Unstable_Grid2/grid2Classes.js +14 -0
- package/modern/Unstable_Grid2/index.js +4 -0
- package/modern/index.js +3 -1
- package/modern/styles/CssVarsProvider.js +6 -6
- package/modern/styles/experimental_extendTheme.js +80 -30
- package/node/Alert/Alert.js +19 -11
- package/node/Autocomplete/Autocomplete.js +14 -10
- package/node/FilledInput/FilledInput.js +1 -1
- package/node/Input/Input.js +1 -1
- package/node/Modal/Modal.js +9 -9
- package/node/OutlinedInput/OutlinedInput.js +13 -0
- package/node/ScopedCssBaseline/ScopedCssBaseline.js +6 -1
- package/node/Select/Select.js +1 -1
- package/node/Slider/Slider.js +9 -9
- package/node/SnackbarContent/SnackbarContent.js +1 -1
- package/node/Tabs/Tabs.js +10 -2
- package/node/Tooltip/Tooltip.js +6 -5
- package/node/Unstable_Grid2/Grid2.js +47 -0
- package/node/Unstable_Grid2/Grid2Props.js +5 -0
- package/node/Unstable_Grid2/grid2Classes.js +25 -0
- package/node/Unstable_Grid2/index.js +56 -0
- package/node/index.js +22 -1
- package/node/styles/CssVarsProvider.js +11 -6
- package/node/styles/experimental_extendTheme.js +84 -31
- package/package.json +7 -7
- package/styles/CssVarsProvider.d.ts +14 -28
- package/styles/CssVarsProvider.js +10 -6
- package/styles/components.d.ts +5 -0
- package/styles/createPalette.d.ts +0 -89
- package/styles/createTheme.d.ts +1 -1
- package/styles/experimental_extendTheme.d.ts +315 -35
- package/styles/experimental_extendTheme.js +80 -30
- package/styles/index.d.ts +35 -1
- package/styles/overrides.d.ts +3 -1
- package/styles/props.d.ts +2 -0
- package/themeCssVarsAugmentation/index.d.ts +26 -0
- package/umd/material-ui.development.js +1211 -559
- package/umd/material-ui.production.min.js +20 -25
package/Alert/Alert.js
CHANGED
|
@@ -60,22 +60,30 @@ const AlertRoot = styled(Paper, {
|
|
|
60
60
|
display: 'flex',
|
|
61
61
|
padding: '6px 16px'
|
|
62
62
|
}, color && ownerState.variant === 'standard' && {
|
|
63
|
-
color: getColor(theme.palette[color].light, 0.6),
|
|
64
|
-
backgroundColor: getBackgroundColor(theme.palette[color].light, 0.9),
|
|
65
|
-
[`& .${alertClasses.icon}`]: {
|
|
63
|
+
color: theme.vars ? theme.vars.palette.Alert[`${color}Color`] : getColor(theme.palette[color].light, 0.6),
|
|
64
|
+
backgroundColor: theme.vars ? theme.vars.palette.Alert[`${color}StandardBg`] : getBackgroundColor(theme.palette[color].light, 0.9),
|
|
65
|
+
[`& .${alertClasses.icon}`]: theme.vars ? {
|
|
66
|
+
color: theme.vars.palette.Alert[`${color}IconColor`]
|
|
67
|
+
} : {
|
|
66
68
|
color: theme.palette.mode === 'dark' ? theme.palette[color].main : theme.palette[color].light
|
|
67
69
|
}
|
|
68
70
|
}, color && ownerState.variant === 'outlined' && {
|
|
69
|
-
color: getColor(theme.palette[color].light, 0.6),
|
|
70
|
-
border: `1px solid ${theme.palette[color].light}`,
|
|
71
|
-
[`& .${alertClasses.icon}`]: {
|
|
71
|
+
color: theme.vars ? theme.vars.palette.Alert[`${color}Color`] : getColor(theme.palette[color].light, 0.6),
|
|
72
|
+
border: `1px solid ${(theme.vars || theme).palette[color].light}`,
|
|
73
|
+
[`& .${alertClasses.icon}`]: theme.vars ? {
|
|
74
|
+
color: theme.vars.palette.Alert[`${color}IconColor`]
|
|
75
|
+
} : {
|
|
72
76
|
color: theme.palette.mode === 'dark' ? theme.palette[color].main : theme.palette[color].light
|
|
73
77
|
}
|
|
74
|
-
}, color && ownerState.variant === 'filled' && {
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
78
|
+
}, color && ownerState.variant === 'filled' && _extends({
|
|
79
|
+
fontWeight: theme.typography.fontWeightMedium
|
|
80
|
+
}, theme.vars ? {
|
|
81
|
+
color: theme.vars.palette.Alert[`${color}FilledColor`],
|
|
82
|
+
backgroundColor: theme.vars.palette.Alert[`${color}FilledBg`]
|
|
83
|
+
} : {
|
|
84
|
+
backgroundColor: theme.palette.mode === 'dark' ? theme.palette[color].dark : theme.palette[color].main,
|
|
85
|
+
color: theme.palette.getContrastText(theme.palette.mode === 'dark' ? theme.palette[color].dark : theme.palette[color].main)
|
|
86
|
+
}));
|
|
79
87
|
});
|
|
80
88
|
const AlertIcon = styled('div', {
|
|
81
89
|
name: 'MuiAlert',
|
|
@@ -120,6 +120,8 @@ export interface AutocompleteProps<
|
|
|
120
120
|
componentsProps?: {
|
|
121
121
|
clearIndicator?: Partial<IconButtonProps>;
|
|
122
122
|
paper?: PaperProps;
|
|
123
|
+
popper?: Partial<PopperProps>;
|
|
124
|
+
popupIndicator?: Partial<IconButtonProps>;
|
|
123
125
|
};
|
|
124
126
|
/**
|
|
125
127
|
* If `true`, the component is disabled.
|
|
@@ -349,7 +349,7 @@ const AutocompleteGroupUl = styled('ul', {
|
|
|
349
349
|
});
|
|
350
350
|
export { createFilterOptions };
|
|
351
351
|
const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps, ref) {
|
|
352
|
-
var _componentsProps$clea, _componentsProps$pape;
|
|
352
|
+
var _componentsProps$clea, _componentsProps$popu, _componentsProps$popp, _componentsProps$pape;
|
|
353
353
|
|
|
354
354
|
const props = useThemeProps({
|
|
355
355
|
props: inProps,
|
|
@@ -457,7 +457,7 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
457
457
|
|
|
458
458
|
if (multiple && value.length > 0) {
|
|
459
459
|
const getCustomizedTagProps = params => _extends({
|
|
460
|
-
className:
|
|
460
|
+
className: classes.tag,
|
|
461
461
|
disabled
|
|
462
462
|
}, getTagProps(params));
|
|
463
463
|
|
|
@@ -550,21 +550,21 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
550
550
|
disabled: disabled,
|
|
551
551
|
"aria-label": popupOpen ? closeText : openText,
|
|
552
552
|
title: popupOpen ? closeText : openText,
|
|
553
|
-
|
|
554
|
-
|
|
553
|
+
ownerState: ownerState
|
|
554
|
+
}, componentsProps.popupIndicator, {
|
|
555
|
+
className: clsx(classes.popupIndicator, (_componentsProps$popu = componentsProps.popupIndicator) == null ? void 0 : _componentsProps$popu.className),
|
|
555
556
|
children: popupIcon
|
|
556
557
|
})) : null]
|
|
557
558
|
})
|
|
558
559
|
}),
|
|
559
560
|
inputProps: _extends({
|
|
560
|
-
className:
|
|
561
|
+
className: classes.input,
|
|
561
562
|
disabled,
|
|
562
563
|
readOnly
|
|
563
564
|
}, getInputProps())
|
|
564
565
|
})
|
|
565
|
-
})), popupOpen && anchorEl ? /*#__PURE__*/_jsx(AutocompletePopper, {
|
|
566
|
+
})), popupOpen && anchorEl ? /*#__PURE__*/_jsx(AutocompletePopper, _extends({
|
|
566
567
|
as: PopperComponent,
|
|
567
|
-
className: clsx(classes.popper),
|
|
568
568
|
disablePortal: disablePortal,
|
|
569
569
|
style: {
|
|
570
570
|
width: anchorEl ? anchorEl.clientWidth : null
|
|
@@ -572,7 +572,9 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
572
572
|
ownerState: ownerState,
|
|
573
573
|
role: "presentation",
|
|
574
574
|
anchorEl: anchorEl,
|
|
575
|
-
open: true
|
|
575
|
+
open: true
|
|
576
|
+
}, componentsProps.popper, {
|
|
577
|
+
className: clsx(classes.popper, (_componentsProps$popp = componentsProps.popper) == null ? void 0 : _componentsProps$popp.className),
|
|
576
578
|
children: /*#__PURE__*/_jsxs(AutocompletePaper, _extends({
|
|
577
579
|
ownerState: ownerState,
|
|
578
580
|
as: PaperComponent
|
|
@@ -609,7 +611,7 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
609
611
|
})
|
|
610
612
|
})) : null]
|
|
611
613
|
}))
|
|
612
|
-
}) : null]
|
|
614
|
+
})) : null]
|
|
613
615
|
});
|
|
614
616
|
});
|
|
615
617
|
process.env.NODE_ENV !== "production" ? Autocomplete.propTypes
|
|
@@ -711,7 +713,9 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes
|
|
|
711
713
|
*/
|
|
712
714
|
componentsProps: PropTypes.shape({
|
|
713
715
|
clearIndicator: PropTypes.object,
|
|
714
|
-
paper: PropTypes.object
|
|
716
|
+
paper: PropTypes.object,
|
|
717
|
+
popper: PropTypes.object,
|
|
718
|
+
popupIndicator: PropTypes.object
|
|
715
719
|
}),
|
|
716
720
|
|
|
717
721
|
/**
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,195 @@
|
|
|
1
1
|
# [Versions](https://mui.com/versions/)
|
|
2
2
|
|
|
3
|
+
## 5.9.0
|
|
4
|
+
|
|
5
|
+
<!-- generated comparing v5.8.7..master -->
|
|
6
|
+
|
|
7
|
+
_Jul 12, 2022_
|
|
8
|
+
|
|
9
|
+
A big thanks to the 19 contributors who made this release possible. Here are some highlights ✨:
|
|
10
|
+
|
|
11
|
+
- 🧪 Exported Grid v2 as `Unstable_Grid2` (#33479) @siriwatknp
|
|
12
|
+
- 📖 Added a guide for using Joy UI and Material UI together (#33396) @siriwatknp
|
|
13
|
+
- 🐛 Fixed a few bugs in Material UI components. Thanks to @ZeeshanTamboli, @ivan-ngchakming, and @joebingham-wk.
|
|
14
|
+
- many other 🐛 bug fixes and 📚 documentation improvements
|
|
15
|
+
- our documentation site is now running with React 18! (#33196) @mnajdova
|
|
16
|
+
|
|
17
|
+
### `@mui/material@5.9.0`
|
|
18
|
+
|
|
19
|
+
- [CssBaseline] Fixes in overriding style (#33338) @ZeeshanTamboli
|
|
20
|
+
- [Autocomplete] Remove unnecessary `clsx` wrapper for single className (#33398) @ZeeshanTamboli
|
|
21
|
+
- [Grid] Export new grid as unstable (#33479) @siriwatknp
|
|
22
|
+
- [Tooltip] Fix children mouse over detection (#32321) @ivan-ngchakming
|
|
23
|
+
- [TypeScript] getCssVar autocomplete for Material UI (#33464) @siriwatknp
|
|
24
|
+
- [TypeScript] Fix theme options components types to use `Theme` (#33434) @siriwatknp
|
|
25
|
+
- [TypeScript] Reexports necessary types for module augmentation (#33397) @siriwatknp
|
|
26
|
+
- [ScopedCssBaseline] Add sx typings (#33474) @joebingham-wk
|
|
27
|
+
|
|
28
|
+
### `@mui/system@5.9.0`
|
|
29
|
+
|
|
30
|
+
- [System] Add offset feature to Grid (#33415) @siriwatknp
|
|
31
|
+
- [system] Add new `Grid` implementation (#32746) @siriwatknp
|
|
32
|
+
|
|
33
|
+
### `@mui/lab@5.0.0-alpha.90`
|
|
34
|
+
|
|
35
|
+
- [lab] Remove the pickers (#33386) @flaviendelangle
|
|
36
|
+
- [Masonry] Support `rem`/`em` values for `spacing` prop (#33384) @hbjORbj
|
|
37
|
+
|
|
38
|
+
### `@mui/base@5.0.0-alpha.89`
|
|
39
|
+
|
|
40
|
+
- Base] Change the order of class names merged in useSlotProps (#33383) @michaldudak
|
|
41
|
+
- [ModalUnstyled] Accept callbacks in componentsProps (#33181) @michaldudak
|
|
42
|
+
- [SelectUnstyled] Accept callbacks in componentsProps (#33197) @michaldudak
|
|
43
|
+
- [TabsUnstyled] Accept callbacks in componentsProps (#33284) @michaldudak
|
|
44
|
+
|
|
45
|
+
### `@mui/joy@5.0.0-alpha.36`
|
|
46
|
+
|
|
47
|
+
- [Joy] Add guide about using Joy and Material UI together (#33396) @siriwatknp
|
|
48
|
+
- [Joy] Fix variants color palette regressions (#33394) @danilo-leal
|
|
49
|
+
|
|
50
|
+
### Docs
|
|
51
|
+
|
|
52
|
+
- [docs] Correcting small grammatical error (#33393) @robyyo
|
|
53
|
+
- [docs] Link to the correct package on Joy component pages (#33439) @cherniavskii
|
|
54
|
+
- [docs] Fix e2e tests (#33477) @siriwatknp
|
|
55
|
+
- [docs] Fix dead links (#33462) @oliviertassinari
|
|
56
|
+
- [docs] Cleanup the migration (#33463) @siriwatknp
|
|
57
|
+
- [docs] Fix broken Sponsoring services links @samuelsycamore
|
|
58
|
+
- [docs] Improve repo README with light/dark logos, relative links and more (#33356) @samuelsycamore
|
|
59
|
+
- [docs] Update links to MUI X Overview and Introduction pages (#33201) @samuelsycamore
|
|
60
|
+
- [docs] Update to React 18 (#33196) @mnajdova
|
|
61
|
+
- [docs] Simplify "Upload button" demo (#33326) @baharalidurrani
|
|
62
|
+
- [docs] Add "refine" demo to showcase (#33240) @omeraplak
|
|
63
|
+
- [docs] Add webpack alias for legacy utils package (#33376) @jgbae
|
|
64
|
+
- [docs] Improve external link icons synonyms (#33257) @davidgarciab
|
|
65
|
+
- [examples] Update MUI Base with Tailwind CSS to use the latest versions of the dependencies (#33401) @mnajdova
|
|
66
|
+
- [examples] Add MUI base example (#33154) @siriwatknp
|
|
67
|
+
|
|
68
|
+
### Core
|
|
69
|
+
|
|
70
|
+
- [core] Fix @mui/monorepo regression for the import of the docs infra (#33390) @Janpot
|
|
71
|
+
- [core] Remove old babel resolve rule (#33432) @oliviertassinari
|
|
72
|
+
- [website] Shorten the plan descriptions on the pricing page (#32984) @joserodolfofreitas
|
|
73
|
+
- [website] Link EULA in the license quantity section (#33292) @oliviertassinari
|
|
74
|
+
|
|
75
|
+
All contributors of this release in alphabetical order: @baharalidurrani, @cherniavskii, @danilo-leal, @davidgarciab, @flaviendelangle, @hbjORbj, @ivan-ngchakming, @Janpot, @jgbae, @joebingham-wk, @joserodolfofreitas, @michaldudak, @mnajdova, @oliviertassinari, @omeraplak, @robyyo, @samuelsycamore, @siriwatknp, @ZeeshanTamboli
|
|
76
|
+
|
|
77
|
+
## 5.8.7
|
|
78
|
+
|
|
79
|
+
<!-- generated comparing v5.8.6..master -->
|
|
80
|
+
|
|
81
|
+
_Jul 4, 2022_
|
|
82
|
+
|
|
83
|
+
A big thanks to the 13 contributors who made this release possible. Here are some highlights ✨:
|
|
84
|
+
|
|
85
|
+
- 🐛 Fixed an issue causing Typescript errors when building a project with Material UI v5.8.6 (@michaldudak)
|
|
86
|
+
- 🐛 Fixed a few bugs in Material UI components. Thanks @henriqueholtz, @jake-collibra, @MattiasMartens and @TimoWilhelm!
|
|
87
|
+
- many other 🐛 bug fixes and 📚 documentation improvements
|
|
88
|
+
|
|
89
|
+
### `@mui/material@5.8.7`
|
|
90
|
+
|
|
91
|
+
- [Autocomplete] Add some missing props in `useAutocomplete` (#33269) @henriqueholtz
|
|
92
|
+
- [Autocomplete] Extend `componentsProps` to include `popper` and `popupIndicator` slots (#33283) @jake-collibra
|
|
93
|
+
- [Select] Annotate empty string as valid value prop (#33088) @MattiasMartens
|
|
94
|
+
- [SnackbarContent] Fix message text color with css var provider (#33285) @TimoWilhelm
|
|
95
|
+
|
|
96
|
+
### `@mui/styled-engine@5.8.7`
|
|
97
|
+
|
|
98
|
+
- [styled-engine] Add missing type dependency on csstype (#33310) @Methuselah96
|
|
99
|
+
|
|
100
|
+
### `@mui/system@5.8.7`
|
|
101
|
+
|
|
102
|
+
- [system] Simplify theme input types for `CssVarsProvider` (#33381) @siriwatknp
|
|
103
|
+
- [system] Export required types (#33324) @michaldudak
|
|
104
|
+
|
|
105
|
+
### `@mui/joy@5.0.0-alpha.35`
|
|
106
|
+
|
|
107
|
+
- [Joy] Add radio button documentation (#33254) @siriwatknp
|
|
108
|
+
- [Joy] Add switch documentation (#33302) @siriwatknp
|
|
109
|
+
- [Joy] Batch a couple of documentation refinements (#33158)
|
|
110
|
+
- [Joy] Enable Joy and Material UI compatibility (#33379) @siriwatknp
|
|
111
|
+
|
|
112
|
+
### `@mui/base@5.0.0-alpha.88`
|
|
113
|
+
|
|
114
|
+
- [base] Remove a type incompatible with Typescript 3.5 (#33361) @michaldudak
|
|
115
|
+
- [BadgeUnstyled] Export BadgeUnstyledOwnProps interface to fix typescript compiler error (#33314) @aaronlademann-wf
|
|
116
|
+
- [TablePaginationUnstyled] Accept callbacks in componentsProps (#33309) @michaldudak
|
|
117
|
+
|
|
118
|
+
### Docs
|
|
119
|
+
|
|
120
|
+
- [docs] Fix Link typings in the react-router example (#32308) @aaarichter
|
|
121
|
+
- [docs] Add caveat about class components with Tooltip (#33325) @joshkel
|
|
122
|
+
- [docs] Fix SEO issues (#33288) @oliviertassinari
|
|
123
|
+
- [docs] Fix Slider's "player" demo (#33267) @xlianghang
|
|
124
|
+
- [website] Link MUI Toolpad in mui.com (#33287) @oliviertassinari
|
|
125
|
+
|
|
126
|
+
All contributors of this release in alphabetical order: @aaarichter, @aaronlademann-wf, @danilo-leal, @henriqueholtz, @jake-collibra, @joshkel, @MattiasMartens, @Methuselah96, @michaldudak, @oliviertassinari, @siriwatknp, @TimoWilhelm, @xlianghang
|
|
127
|
+
|
|
128
|
+
## 5.8.6
|
|
129
|
+
|
|
130
|
+
<!-- generated comparing v5.8.5..master -->
|
|
131
|
+
|
|
132
|
+
_Jun 27, 2022_
|
|
133
|
+
|
|
134
|
+
A big thanks to the 13 contributors who made this release possible. Here are some highlights ✨:
|
|
135
|
+
|
|
136
|
+
- ⚒️ Fixed React 18 issues in few components
|
|
137
|
+
- 🚀 Improved the TypeScript augmentation when using CSS variables with `@mui/material`
|
|
138
|
+
- many other 🐛 bug fixes and 📚 documentation improvements
|
|
139
|
+
|
|
140
|
+
### `@mui/material@5.8.6`
|
|
141
|
+
|
|
142
|
+
- ​<!-- 27 -->[Alert] Add support for CSS vars (#32624) @haneenmahd
|
|
143
|
+
- ​<!-- 26 -->[Alert] Use `getContrastText` for filled variant font color (#29813) @SamoraMabuya
|
|
144
|
+
|
|
145
|
+
Note: The color of the text in the warning contained `Alert` in dark mode was changed to black in order to improve the color contrast ratio
|
|
146
|
+
|
|
147
|
+
- ​<!-- 11 -->[OutlinedInput] Fix `ownerState` undefined in theme style overrides (#33241) @siriwatknp
|
|
148
|
+
- ​<!-- 08 -->[Tabs] Fix crash when used with React 18 & Suspense (#33277) @mnajdova
|
|
149
|
+
- ​<!-- 05 -->[TypeScript] Add CSS vars type augmentation for Material UI (#33211) @siriwatknp
|
|
150
|
+
|
|
151
|
+
### `@mui/system@5.8.6`
|
|
152
|
+
|
|
153
|
+
- ​<!-- 09 -->[system] Add enableColorScheme option to getInitColorSchemeScript (#33261) @siriwatknp
|
|
154
|
+
|
|
155
|
+
### `@mui/utils@5.8.6`
|
|
156
|
+
|
|
157
|
+
- ​<!-- 04 -->[utils] Allow state prefix to be configurable (#32972) @siriwatknp
|
|
158
|
+
|
|
159
|
+
### `@mui/base@5.0.0-alpha.87`
|
|
160
|
+
|
|
161
|
+
- ​<!-- 25 -->[base] Improve the return type of useSlotProps (#33279) @michaldudak
|
|
162
|
+
- ​<!-- 24 -->[base] Improve some types (#33270) @mnajdova
|
|
163
|
+
- ​<!-- 13 -->[MenuUnstyled] Fix keyboard accessibility of menu items (#33145) @michaldudak
|
|
164
|
+
- ​<!-- 12 -->[ModalManager] Lock body scroll when container is inside shadow DOM (#33168) @jacobweberbowery
|
|
165
|
+
- ​<!-- 10 -->[SliderUnstyled] Use useSlotProps (#33132) @michaldudak
|
|
166
|
+
- ​<!-- 07 -->[TextareaAutosize] Fix crash when used with React 18 & Suspense (#33238) @howlettt
|
|
167
|
+
- ​<!-- 06 -->[TextareaAutosize] Fix warnings for too many renders in React 18 (#33253) @mnajdova
|
|
168
|
+
|
|
169
|
+
### `@mui/joy@5.0.0-alpha.34`
|
|
170
|
+
|
|
171
|
+
- ​<!-- 14 -->[Joy] Add `Sheet` doc (#32820) @hbjORbj
|
|
172
|
+
|
|
173
|
+
### Docs
|
|
174
|
+
|
|
175
|
+
- ​<!-- 23 -->[blog] Polish Why you should migrate to Material UI v5 today (#33244) @oliviertassinari
|
|
176
|
+
- ​<!-- 21 -->[docs] Add note in docs about `componentsProps.root` taking precedence (#33097) @ZeeshanTamboli
|
|
177
|
+
- ​<!-- 20 -->[docs] Remove a note about Base components being reexported from Material UI (#33265) @michaldudak
|
|
178
|
+
- ​<!-- 19 -->[docs] Update code snippet in docs for custom color palette (#32946) @ZeeshanTamboli
|
|
179
|
+
- ​<!-- 18 -->[docs] Fix the docs for production class generation (#31933) @Fafruch
|
|
180
|
+
- ​<!-- 17 -->[docs] Fix internal link in Box page (#33149) @davidgarciab
|
|
181
|
+
- ​<!-- 16 -->[docs] Badge component link in Base docs should be under Data Display section (#33249) @ZeeshanTamboli
|
|
182
|
+
- ​<!-- 15 -->[examples] Fix comment typo (#33256) @WinmezzZ
|
|
183
|
+
|
|
184
|
+
### Core
|
|
185
|
+
|
|
186
|
+
- ​<!-- 22 -->[core] Remove dead code (#33243) @oliviertassinari
|
|
187
|
+
- ​<!-- 03 -->[website] Fix the scroll-top for all the website (#33215) @oliviertassinari
|
|
188
|
+
- ​<!-- 02 -->[website] List new core role @oliviertassinari
|
|
189
|
+
- ​<!-- 01 -->[website] Fix navigation menu close behavior (#33203) @oliviertassinari
|
|
190
|
+
|
|
191
|
+
All contributors of this release in alphabetical order: @davidgarciab, @Fafruch, @haneenmahd, @hbjORbj, @howlettt, @jacobweberbowery, @michaldudak, @mnajdova, @oliviertassinari, @SamoraMabuya, @siriwatknp, @WinmezzZ, @ZeeshanTamboli
|
|
192
|
+
|
|
3
193
|
## 5.8.5
|
|
4
194
|
|
|
5
195
|
<!-- generated comparing v5.8.4..master -->
|
|
@@ -96,7 +96,7 @@ const FilledInputRoot = styled(InputBaseRoot, {
|
|
|
96
96
|
|
|
97
97
|
},
|
|
98
98
|
'&:before': {
|
|
99
|
-
borderBottom: `1px solid ${theme.vars ? `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.
|
|
99
|
+
borderBottom: `1px solid ${theme.vars ? `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.inputUnderline})` : bottomLineColor}`,
|
|
100
100
|
left: 0,
|
|
101
101
|
bottom: 0,
|
|
102
102
|
// Doing the other way around crash on IE11 "''" https://github.com/cssinjs/jss/issues/242
|
package/Input/Input.js
CHANGED
|
@@ -43,7 +43,7 @@ const InputRoot = styled(InputBaseRoot, {
|
|
|
43
43
|
let bottomLineColor = light ? 'rgba(0, 0, 0, 0.42)' : 'rgba(255, 255, 255, 0.7)';
|
|
44
44
|
|
|
45
45
|
if (theme.vars) {
|
|
46
|
-
bottomLineColor = `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.
|
|
46
|
+
bottomLineColor = `rgba(${theme.vars.palette.common.onBackgroundChannel} / ${theme.vars.opacity.inputUnderline})`;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
return _extends({
|
package/Modal/Modal.js
CHANGED
|
@@ -3,9 +3,9 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
3
3
|
const _excluded = ["BackdropComponent", "BackdropProps", "closeAfterTransition", "children", "component", "components", "componentsProps", "disableAutoFocus", "disableEnforceFocus", "disableEscapeKeyDown", "disablePortal", "disableRestoreFocus", "disableScrollLock", "hideBackdrop", "keepMounted", "theme"];
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import PropTypes from 'prop-types';
|
|
6
|
-
import { isHostComponent } from '@mui/base';
|
|
7
|
-
import { elementAcceptingRef, HTMLElementType } from '@mui/utils';
|
|
8
6
|
import ModalUnstyled, { modalUnstyledClasses } from '@mui/base/ModalUnstyled';
|
|
7
|
+
import { isHostComponent, resolveComponentProps } from '@mui/base/utils';
|
|
8
|
+
import { elementAcceptingRef, HTMLElementType } from '@mui/utils';
|
|
9
9
|
import styled from '../styles/styled';
|
|
10
10
|
import useThemeProps from '../styles/useThemeProps';
|
|
11
11
|
import Backdrop from '../Backdrop';
|
|
@@ -115,11 +115,11 @@ const Modal = /*#__PURE__*/React.forwardRef(function Modal(inProps, ref) {
|
|
|
115
115
|
Backdrop: BackdropComponent
|
|
116
116
|
}, components),
|
|
117
117
|
componentsProps: {
|
|
118
|
-
root: _extends({}, componentsProps.root, !isHostComponent(Root) && {
|
|
118
|
+
root: () => _extends({}, resolveComponentProps(componentsProps.root, ownerState), !isHostComponent(Root) && {
|
|
119
119
|
as: component,
|
|
120
120
|
theme
|
|
121
121
|
}),
|
|
122
|
-
backdrop: _extends({}, BackdropProps, componentsProps.backdrop)
|
|
122
|
+
backdrop: () => _extends({}, BackdropProps, resolveComponentProps(componentsProps.backdrop, ownerState))
|
|
123
123
|
},
|
|
124
124
|
onTransitionEnter: () => setExited(false),
|
|
125
125
|
onTransitionExited: () => setExited(true),
|
|
@@ -196,8 +196,8 @@ process.env.NODE_ENV !== "production" ? Modal.propTypes
|
|
|
196
196
|
* @default {}
|
|
197
197
|
*/
|
|
198
198
|
componentsProps: PropTypes.shape({
|
|
199
|
-
backdrop: PropTypes.object,
|
|
200
|
-
root: PropTypes.object
|
|
199
|
+
backdrop: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
|
|
200
|
+
root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])
|
|
201
201
|
}),
|
|
202
202
|
|
|
203
203
|
/**
|
|
@@ -144,12 +144,27 @@ const OutlinedInput = /*#__PURE__*/React.forwardRef(function OutlinedInput(inPro
|
|
|
144
144
|
muiFormControl,
|
|
145
145
|
states: ['required']
|
|
146
146
|
});
|
|
147
|
+
|
|
148
|
+
const ownerState = _extends({}, props, {
|
|
149
|
+
color: fcs.color || 'primary',
|
|
150
|
+
disabled: fcs.disabled,
|
|
151
|
+
error: fcs.error,
|
|
152
|
+
focused: fcs.focused,
|
|
153
|
+
formControl: muiFormControl,
|
|
154
|
+
fullWidth,
|
|
155
|
+
hiddenLabel: fcs.hiddenLabel,
|
|
156
|
+
multiline,
|
|
157
|
+
size: fcs.size,
|
|
158
|
+
type
|
|
159
|
+
});
|
|
160
|
+
|
|
147
161
|
return /*#__PURE__*/_jsx(InputBase, _extends({
|
|
148
162
|
components: _extends({
|
|
149
163
|
Root: OutlinedInputRoot,
|
|
150
164
|
Input: OutlinedInputInput
|
|
151
165
|
}, components),
|
|
152
166
|
renderSuffix: state => /*#__PURE__*/_jsx(NotchedOutlineRoot, {
|
|
167
|
+
ownerState: ownerState,
|
|
153
168
|
className: classes.notchedOutline,
|
|
154
169
|
label: label != null && label !== '' && fcs.required ? _React$Fragment || (_React$Fragment = /*#__PURE__*/_jsxs(React.Fragment, {
|
|
155
170
|
children: [label, "\xA0", '*']
|
package/Popper/Popper.d.ts
CHANGED
|
@@ -20,10 +20,5 @@ export declare type PopperProps = Omit<PopperUnstyledProps, 'direction'> & {
|
|
|
20
20
|
*
|
|
21
21
|
* - [Popper API](https://mui.com/material-ui/api/popper/)
|
|
22
22
|
*/
|
|
23
|
-
declare const Popper: React.ForwardRefExoticComponent<Pick<
|
|
24
|
-
/**
|
|
25
|
-
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
26
|
-
*/
|
|
27
|
-
sx?: SxProps<Theme> | undefined;
|
|
28
|
-
}, "hidden" | "color" | "style" | "open" | "translate" | "transition" | "slot" | "title" | "children" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "sx" | "placement" | "anchorEl" | "container" | "disablePortal" | "keepMounted" | "modifiers" | "popperOptions" | "popperRef"> & React.RefAttributes<HTMLDivElement>>;
|
|
23
|
+
declare const Popper: React.ForwardRefExoticComponent<Pick<PopperProps, "hidden" | "color" | "style" | "open" | "translate" | "transition" | "slot" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "sx" | "container" | "placement" | "anchorEl" | "disablePortal" | "keepMounted" | "modifiers" | "popperOptions" | "popperRef"> & React.RefAttributes<HTMLDivElement>>;
|
|
29
24
|
export default Popper;
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<!-- markdownlint-disable-next-line -->
|
|
2
2
|
<p align="center">
|
|
3
|
-
<a href="https://mui.com/" rel="noopener" target="_blank"><img width="150" src="
|
|
3
|
+
<a href="https://mui.com/" rel="noopener" target="_blank"><img width="150" src="/docs/public/static/logo.svg" alt="MUI logo"></a>
|
|
4
4
|
</p>
|
|
5
5
|
|
|
6
6
|
<h1 align="center">MUI Core</h1>
|
|
@@ -39,11 +39,15 @@
|
|
|
39
39
|
|
|
40
40
|
Material UI is available as an [npm package](https://www.npmjs.com/package/@mui/material).
|
|
41
41
|
|
|
42
|
+
**npm:**
|
|
43
|
+
|
|
42
44
|
```sh
|
|
43
|
-
// with npm
|
|
44
45
|
npm install @mui/material @emotion/react @emotion/styled
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
**yarn:**
|
|
45
49
|
|
|
46
|
-
|
|
50
|
+
```sh
|
|
47
51
|
yarn add @mui/material @emotion/react @emotion/styled
|
|
48
52
|
```
|
|
49
53
|
|
|
@@ -63,11 +67,15 @@ Use `@latest` for the latest stable release.
|
|
|
63
67
|
|
|
64
68
|
MUI Base is available as an [npm package](https://www.npmjs.com/package/@mui/base).
|
|
65
69
|
|
|
70
|
+
**npm:**
|
|
71
|
+
|
|
66
72
|
```sh
|
|
67
|
-
// with npm
|
|
68
73
|
npm install @mui/base
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
**yarn:**
|
|
69
77
|
|
|
70
|
-
|
|
78
|
+
```sh
|
|
71
79
|
yarn add @mui/base
|
|
72
80
|
```
|
|
73
81
|
|
|
@@ -78,22 +86,30 @@ We are adding new components regularly and you're welcome to contribute!
|
|
|
78
86
|
|
|
79
87
|
MUI System is available as an [npm package](https://www.npmjs.com/package/@mui/system).
|
|
80
88
|
|
|
89
|
+
**npm:**
|
|
90
|
+
|
|
81
91
|
```sh
|
|
82
|
-
// with npm
|
|
83
92
|
npm install @mui/system @emotion/react @emotion/styled
|
|
93
|
+
```
|
|
84
94
|
|
|
85
|
-
|
|
95
|
+
**yarn:**
|
|
96
|
+
|
|
97
|
+
```sh
|
|
86
98
|
yarn add @mui/system @emotion/react @emotion/styled
|
|
87
99
|
```
|
|
88
100
|
|
|
89
101
|
Or if you want to use `styled-components` as a styling engine:
|
|
90
102
|
|
|
103
|
+
**npm:**
|
|
104
|
+
|
|
91
105
|
```sh
|
|
92
|
-
|
|
93
|
-
|
|
106
|
+
npm install @mui/material @mui/styled-engine-sc styled-components
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
**yarn:**
|
|
94
110
|
|
|
95
|
-
|
|
96
|
-
yarn add @mui/
|
|
111
|
+
```sh
|
|
112
|
+
yarn add @mui/material @mui/styled-engine-sc styled-components
|
|
97
113
|
```
|
|
98
114
|
|
|
99
115
|
Visit our [`styled-engine` guide](https://mui.com/material-ui/guides/styled-engine/) for more information about how to configure `styled-components` as the style engine.
|
|
@@ -160,8 +176,9 @@ Our documentation features [a collection of example projects using Material UI](
|
|
|
160
176
|
|
|
161
177
|
## Documentation
|
|
162
178
|
|
|
163
|
-
- [Material UI](https://mui.com/material-ui/getting-started/
|
|
164
|
-
- [
|
|
179
|
+
- [Material UI](https://mui.com/material-ui/getting-started/overview/)
|
|
180
|
+
- [Joy UI](https://mui.com/joy-ui/getting-started/overview/)
|
|
181
|
+
- [MUI Base](https://mui.com/base/getting-started/overview/)
|
|
165
182
|
- [MUI System](https://mui.com/system/basics/)
|
|
166
183
|
|
|
167
184
|
## Premium themes
|
|
@@ -196,22 +213,42 @@ For details of supported versions and contact details for reporting security iss
|
|
|
196
213
|
|
|
197
214
|
These great services sponsor MUI's core infrastructure:
|
|
198
215
|
|
|
199
|
-
|
|
216
|
+
<picture>
|
|
217
|
+
|
|
218
|
+
<source media="(prefers-color-scheme: dark)" srcset="/docs/public/static/readme/github-darkmode.svg">
|
|
219
|
+
<source media="(prefers-color-scheme: light)" srcset="/docs/public/static/readme/github-lightmode.svg">
|
|
220
|
+
<img alt="GitHub logo" src="/docs/public/static/readme/github-darkmode.svg">
|
|
221
|
+
</picture>
|
|
222
|
+
|
|
223
|
+
[GitHub](https://github.com/) lets us host the Git repository and coordinate contributions.
|
|
224
|
+
|
|
225
|
+
<picture>
|
|
226
|
+
|
|
227
|
+
<source media="(prefers-color-scheme: dark)" srcset="/docs/public/static/readme/netlify-darkmode.svg">
|
|
228
|
+
<source media="(prefers-color-scheme: light)" srcset="/docs/public/static/readme/netlify-lightmode.svg">
|
|
229
|
+
<img alt="Netlify logo" src="/docs/public/static/readme/netlify-darkmode.svg">
|
|
230
|
+
</picture>
|
|
200
231
|
|
|
201
|
-
|
|
232
|
+
[Netlify](https://www.netlify.com/) lets us distribute the documentation.
|
|
202
233
|
|
|
203
|
-
|
|
234
|
+
<picture>
|
|
204
235
|
|
|
205
|
-
|
|
236
|
+
<source media="(prefers-color-scheme: dark)" srcset="/docs/public/static/readme/crowdin-darkmode.svg">
|
|
237
|
+
<source media="(prefers-color-scheme: light)" srcset="/docs/public/static/readme/crowdin-lightmode.svg">
|
|
238
|
+
<img alt="Crowdin logo" src="/docs/public/static/readme/crowdin-darkmode.svg">
|
|
239
|
+
</picture>
|
|
206
240
|
|
|
207
|
-
[
|
|
241
|
+
[Crowdin](https://crowdin.com/) lets us translate the documentation.
|
|
208
242
|
|
|
209
|
-
|
|
243
|
+
<picture>
|
|
210
244
|
|
|
211
|
-
|
|
245
|
+
<source media="(prefers-color-scheme: dark)" srcset="/docs/public/static/readme/browserstack-darkmode.svg">
|
|
246
|
+
<source media="(prefers-color-scheme: light)" srcset="/docs/public/static/readme/browserstack-lightmode.svg">
|
|
247
|
+
<img alt="GitHub logo" src="/docs/public/static/readme/browserstack-darkmode.svg">
|
|
248
|
+
</picture>
|
|
212
249
|
|
|
213
|
-
BrowserStack lets us test in real browsers.
|
|
250
|
+
[BrowserStack](https://www.browserstack.com/) lets us test in real browsers.
|
|
214
251
|
|
|
215
|
-
|
|
252
|
+
<img loading="lazy" alt="CodeCov logo" src="https://github.com/codecov.png?size=70" width="35" height="35">
|
|
216
253
|
|
|
217
|
-
CodeCov lets us monitor test coverage.
|
|
254
|
+
[CodeCov](https://codecov.io/) lets us monitor test coverage.
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { SxProps } from '@mui/system';
|
|
1
2
|
import * as React from 'react';
|
|
3
|
+
import { Theme } from '../styles';
|
|
2
4
|
import { OverridableComponent, OverrideProps } from '../OverridableComponent';
|
|
3
5
|
import { ScopedCssBaselineClasses } from './scopedCssBaselineClasses';
|
|
4
6
|
|
|
@@ -18,6 +20,10 @@ export interface ScopedCssBaselineTypeMap<P = {}, D extends React.ElementType =
|
|
|
18
20
|
* For browser support, check out https://caniuse.com/?search=color-scheme
|
|
19
21
|
*/
|
|
20
22
|
enableColorScheme?: boolean;
|
|
23
|
+
/**
|
|
24
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
25
|
+
*/
|
|
26
|
+
sx?: SxProps<Theme>;
|
|
21
27
|
};
|
|
22
28
|
defaultComponent: D;
|
|
23
29
|
}
|
|
@@ -96,6 +96,11 @@ process.env.NODE_ENV !== "production" ? ScopedCssBaseline.propTypes
|
|
|
96
96
|
* For more details, check out https://developer.mozilla.org/en-US/docs/Web/CSS/color-scheme
|
|
97
97
|
* For browser support, check out https://caniuse.com/?search=color-scheme
|
|
98
98
|
*/
|
|
99
|
-
enableColorScheme: PropTypes.bool
|
|
99
|
+
enableColorScheme: PropTypes.bool,
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
103
|
+
*/
|
|
104
|
+
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])
|
|
100
105
|
} : void 0;
|
|
101
106
|
export default ScopedCssBaseline;
|
package/Select/Select.d.ts
CHANGED
|
@@ -144,7 +144,7 @@ export interface SelectProps<T = unknown>
|
|
|
144
144
|
* If the value is an object it must have reference equality with the option in order to be selected.
|
|
145
145
|
* If the value is not an object, the string representation must match with the string representation of the option in order to be selected.
|
|
146
146
|
*/
|
|
147
|
-
value?: T;
|
|
147
|
+
value?: T | '';
|
|
148
148
|
/**
|
|
149
149
|
* The variant to use.
|
|
150
150
|
* @default 'outlined'
|
package/Select/Select.js
CHANGED
|
@@ -294,7 +294,7 @@ process.env.NODE_ENV !== "production" ? Select.propTypes
|
|
|
294
294
|
* If the value is an object it must have reference equality with the option in order to be selected.
|
|
295
295
|
* If the value is not an object, the string representation must match with the string representation of the option in order to be selected.
|
|
296
296
|
*/
|
|
297
|
-
value: PropTypes.any,
|
|
297
|
+
value: PropTypes.oneOfType([PropTypes.oneOf(['']), PropTypes.any]),
|
|
298
298
|
|
|
299
299
|
/**
|
|
300
300
|
* The variant to use.
|