@mui/material 5.2.4 → 5.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. package/Autocomplete/Autocomplete.js +3 -1
  2. package/Avatar/Avatar.d.ts +3 -1
  3. package/Backdrop/Backdrop.js +3 -1
  4. package/Badge/Badge.d.ts +25 -0
  5. package/Badge/Badge.js +29 -9
  6. package/ButtonGroup/ButtonGroupContext.d.ts +1 -1
  7. package/CHANGELOG.md +230 -32
  8. package/FilledInput/FilledInput.js +4 -1
  9. package/FormControlLabel/FormControlLabel.js +3 -1
  10. package/Input/Input.js +4 -1
  11. package/InputBase/InputBase.js +4 -1
  12. package/InputLabel/InputLabel.js +4 -0
  13. package/ListItem/ListItem.js +3 -1
  14. package/Modal/Modal.js +3 -1
  15. package/README.md +17 -28
  16. package/Slider/Slider.d.ts +2 -0
  17. package/Slider/Slider.js +21 -3
  18. package/StepLabel/StepLabel.js +3 -1
  19. package/SvgIcon/SvgIcon.d.ts +8 -0
  20. package/SvgIcon/SvgIcon.js +19 -3
  21. package/Tabs/Tabs.d.ts +1 -1
  22. package/TextField/TextField.d.ts +1 -0
  23. package/TextField/TextField.js +1 -0
  24. package/Tooltip/Tooltip.js +6 -1
  25. package/index.js +1 -1
  26. package/legacy/Autocomplete/Autocomplete.js +3 -1
  27. package/legacy/Backdrop/Backdrop.js +3 -1
  28. package/legacy/Badge/Badge.js +34 -10
  29. package/legacy/FilledInput/FilledInput.js +4 -1
  30. package/legacy/FormControlLabel/FormControlLabel.js +3 -1
  31. package/legacy/Input/Input.js +4 -1
  32. package/legacy/InputBase/InputBase.js +4 -1
  33. package/legacy/InputLabel/InputLabel.js +4 -0
  34. package/legacy/ListItem/ListItem.js +3 -1
  35. package/legacy/Modal/Modal.js +3 -1
  36. package/legacy/Slider/Slider.js +21 -3
  37. package/legacy/StepLabel/StepLabel.js +3 -1
  38. package/legacy/SvgIcon/SvgIcon.js +20 -3
  39. package/legacy/TextField/TextField.js +1 -0
  40. package/legacy/Tooltip/Tooltip.js +6 -1
  41. package/legacy/index.js +1 -1
  42. package/legacy/locale/index.js +319 -142
  43. package/locale/index.d.ts +2 -0
  44. package/locale/index.js +220 -50
  45. package/modern/Autocomplete/Autocomplete.js +3 -1
  46. package/modern/Backdrop/Backdrop.js +3 -1
  47. package/modern/Badge/Badge.js +29 -9
  48. package/modern/FilledInput/FilledInput.js +4 -1
  49. package/modern/FormControlLabel/FormControlLabel.js +3 -1
  50. package/modern/Input/Input.js +4 -1
  51. package/modern/InputBase/InputBase.js +4 -1
  52. package/modern/InputLabel/InputLabel.js +4 -0
  53. package/modern/ListItem/ListItem.js +3 -1
  54. package/modern/Modal/Modal.js +3 -1
  55. package/modern/Slider/Slider.js +21 -3
  56. package/modern/StepLabel/StepLabel.js +3 -1
  57. package/modern/SvgIcon/SvgIcon.js +19 -3
  58. package/modern/TextField/TextField.js +1 -0
  59. package/modern/Tooltip/Tooltip.js +6 -1
  60. package/modern/index.js +1 -1
  61. package/modern/locale/index.js +220 -50
  62. package/node/Autocomplete/Autocomplete.js +3 -1
  63. package/node/Backdrop/Backdrop.js +3 -1
  64. package/node/Badge/Badge.js +29 -9
  65. package/node/FilledInput/FilledInput.js +4 -1
  66. package/node/FormControlLabel/FormControlLabel.js +3 -1
  67. package/node/Input/Input.js +4 -1
  68. package/node/InputBase/InputBase.js +4 -1
  69. package/node/InputLabel/InputLabel.js +4 -0
  70. package/node/ListItem/ListItem.js +3 -1
  71. package/node/Modal/Modal.js +3 -1
  72. package/node/Slider/Slider.js +21 -3
  73. package/node/StepLabel/StepLabel.js +3 -1
  74. package/node/SvgIcon/SvgIcon.js +19 -3
  75. package/node/TextField/TextField.js +1 -0
  76. package/node/Tooltip/Tooltip.js +6 -1
  77. package/node/index.js +1 -1
  78. package/node/locale/index.js +223 -51
  79. package/package.json +3 -3
  80. package/umd/material-ui.development.js +251 -89
  81. package/umd/material-ui.production.min.js +21 -21
package/README.md CHANGED
@@ -1,3 +1,4 @@
1
+ <!-- markdownlint-disable-next-line -->
1
2
  <p align="center">
2
3
  <a href="https://mui.com/" rel="noopener" target="_blank"><img width="150" src="https://mui.com/static/logo.svg" alt="MUI logo"></a></p>
3
4
  </p>
@@ -18,7 +19,7 @@ Quickly build beautiful [React](https://reactjs.org/) apps. MUI is a simple and
18
19
  [![Renovate status](https://img.shields.io/badge/renovate-enabled-brightgreen.svg)](https://github.com/mui-org/material-ui/issues/27062)
19
20
  [![Average time to resolve an issue](https://isitmaintained.com/badge/resolution/mui-org/material-ui.svg)](https://isitmaintained.com/project/mui-org/material-ui 'Average time to resolve an issue')
20
21
  [![Crowdin](https://badges.crowdin.net/material-ui-docs/localized.svg)](https://translate.mui.com/project/material-ui-docs)
21
- [![Open Collective backers and sponsors](https://img.shields.io/opencollective/all/material-ui)](https://opencollective.com/mui)
22
+ [![Open Collective backers and sponsors](https://img.shields.io/opencollective/all/mui)](https://opencollective.com/mui)
22
23
 
23
24
  </div>
24
25
 
@@ -51,43 +52,31 @@ Please note that `@next` will only point to pre-releases; to get the latest stab
51
52
 
52
53
  ### Diamond 💎
53
54
 
54
- <p style="display: flex; justify-content: center;">
55
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="octopus" href="https://octopus.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="128" width="128" src="https://avatars3.githubusercontent.com/u/1287123?s=256" alt="octopus" title="Repeatable, reliable deployments" loading="lazy" /></a>
56
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="doit-intl" href="https://www.doit-intl.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="128" width="128" src="https://avatars3.githubusercontent.com/u/8424863?s=256" alt="doit-intl" title="Management Platform for Google Cloud and AWS" loading="lazy" /></a>
57
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="aptugo" href="https://www.aptugo.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="128" width="128" src="https://www.aptugo.com/img/favicon.png" alt="aptugo" title="Augmented Software Development Platform" loading="lazy" /></a>
55
+ <p align="center">
56
+ <a href="https://octopus.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="128" width="128" src="https://avatars3.githubusercontent.com/u/1287123?s=256" alt="octopus" title="Repeatable, reliable deployments" loading="lazy" /></a>
57
+ <a href="https://www.doit-intl.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="128" width="128" src="https://avatars3.githubusercontent.com/u/8424863?s=256" alt="doit-intl" title="Management Platform for Google Cloud and AWS" loading="lazy" /></a>
58
+ <a href="https://www.aptugo.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="128" width="128" src="https://www.aptugo.com/img/favicon.png" alt="aptugo" title="Augmented Software Development Platform" loading="lazy" /></a>
58
59
  </p>
59
60
 
60
61
  Diamond Sponsors are those who have pledged \$1,500/month or more to MUI.
61
62
 
62
63
  ### Gold 🏆
63
64
 
64
- via [Patreon](https://www.patreon.com/oliviertassinari)
65
-
66
- <p style="display: flex; justify-content: center;">
67
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="tidelift" href="https://tidelift.com/subscription/pkg/npm-material-ui?utm_source=npm-material-ui&utm_medium=referral&utm_campaign=homepage" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://github.com/tidelift.png?size=192" alt="tidelift" title="Enterprise-ready open-source software" loading="lazy" /></a>
68
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="bitsrc" href="https://bit.dev/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://github.com/teambit.png?size=192" alt="bitsrc" title="The fastest way to share code" loading="lazy" /></a>
69
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="movavi" href="https://spicefactory.co/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://avatars.githubusercontent.com/u/13365608?s=192" alt="Next gen digital product studio." loading="lazy" /></a>
70
- </p>
71
-
72
- via [OpenCollective](https://opencollective.com/mui)
65
+ via [OpenCollective](https://opencollective.com/mui) or via [Patreon](https://www.patreon.com/oliviertassinari)
73
66
 
74
- <p style="display: flex; justify-content: center; flex-wrap: wrap;">
75
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="textemall" href="https://www.text-em-all.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/callemall/a6946da/logo/192.png" alt="call-em-all" title="Mass Text Messaging & Automated Calling" height="96" width="96" loading="lazy"></a>
76
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="hoodiebees" href="https://hoodiebees.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://images.opencollective.com/hoodiebees1/617b451/logo/192.png" alt="hoodiebees" loading="lazy" /></a>
77
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="movavi" href="https://www.movavi.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://images.opencollective.com/movavi-software/a1d0167/logo/192.png" alt="Screen recorder for Mac" loading="lazy" /></a>
78
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="sunmatosoft" href="https://sumatosoft.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://images.opencollective.com/sumatosoft_company/0b78570/avatar/192.png" alt="We help companies to digitalize their businesses" loading="lazy" /></a>
79
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="topaussiecasinos.com" href="https://topaussiecasinos.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img height="96" width="96" src="https://images.opencollective.com/aussiecasinohex/923df37/logo/192.png" alt="Aussie Gambling Guide" loading="lazy" /></a>
80
- </p>
81
-
82
- Direct
83
-
84
- <p style="display: flex; justify-content: center; flex-wrap: wrap;">
85
- <a data-ga-event-category="sponsor" data-ga-event-action="logo" data-ga-event-label="elevator" href="https://www.elevatormag.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-right: 16px;"><img src="https://mui.com/static/sponsors/elevator.png" alt="elevator" title="The dopest new hip hop, upcoming artists, music news, culture, and style" height="57" width="191" loading="lazy"></a>
67
+ <p align="center">
68
+ <a href="https://tidelift.com/subscription/pkg/npm-material-ui?utm_source=npm-material-ui&utm_medium=referral&utm_campaign=homepage" rel="noopener sponsored" target="_blank"><img height="96" width="96" src="https://github.com/tidelift.png?size=192" alt="tidelift.com" title="Enterprise-ready open-source software" loading="lazy" /></a>
69
+ <a href="https://bit.dev/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank" style="margin-rig ht: 16px;"><img height="96" width="96" src="https://github.com/teambit.png?size=192" alt="bit.dev" title="The fastest way to share code" loading="lazy" /></a>
70
+ <a href="https://www.text-em-all.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img src="https://images.opencollective.com/callemall/09710fe/logo/192.png" alt="text-em-all.com" title="Mass Text Messaging & Automated Calling" height="96" width="96" loading="lazy"></a>
71
+ <a href="https://www.laststance.io/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="96" width="96" src="https://images.opencollective.com/laststance/daffd6c/avatar/192.png" alt="laststance.io" title="Indipendent organization for OSS activity based on Tokyo" loading="lazy" /></a>
72
+ <a href="https://www.movavi.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="96" width="96" src="https://images.opencollective.com/movavi-software/a1d0167/logo/192.png" alt="movavi.com" title="Screen recorder for Mac" loading="lazy" /></a>
73
+ <a href="https://topaussiecasinos.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="96" width="96" src="https://images.opencollective.com/aussiecasinohex/923df37/logo/192.png" alt="topaussiecasinos.com" title="Aussie Gambling Guide" loading="lazy" /></a>
74
+ <a href="https://sumatosoft.com/?utm_source=MUI&utm_medium=referral&utm_content=readme" rel="noopener sponsored" target="_blank"><img height="96" width="96" src="https://images.opencollective.com/sumatosoft_company/0b78570/avatar/192.png" alt="sumatosoft.com" title="We help companies to digitalize their businesses" loading="lazy" /></a>
86
75
  </p>
87
76
 
88
77
  Gold Sponsors are those who have pledged \$500/month or more to MUI.
89
78
 
90
- ### There is more!
79
+ ### There is more
91
80
 
92
81
  See the full list of [our backers](https://mui.com/discover-more/backers/).
93
82
 
@@ -132,7 +121,7 @@ Check out our [documentation website](https://mui.com/).
132
121
 
133
122
  ## Premium Themes
134
123
 
135
- You can find complete templates & themes in the [MUI Store](https://material-ui.com/store/?utm_source=docs&utm_medium=referral&utm_campaign=readme-store).
124
+ You can find complete templates & themes in the [MUI Store](https://mui.com/store/?utm_source=docs&utm_medium=referral&utm_campaign=readme-store).
136
125
 
137
126
  ## Contributing
138
127
 
@@ -60,6 +60,7 @@ type SliderRailProps = NonNullable<SliderTypeMap['props']['componentsProps']>['r
60
60
  type SliderTrackProps = NonNullable<SliderTypeMap['props']['componentsProps']>['track'];
61
61
  type SliderThumbProps = NonNullable<SliderTypeMap['props']['componentsProps']>['thumb'];
62
62
  type SliderValueLabelProps = NonNullable<SliderTypeMap['props']['componentsProps']>['valueLabel'];
63
+ type SliderInputProps = NonNullable<SliderTypeMap['props']['componentsProps']>['input'];
63
64
 
64
65
  export const SliderRoot: React.FC<SliderRootProps>;
65
66
  export const SliderMark: React.FC<SliderMarkProps>;
@@ -68,6 +69,7 @@ export const SliderRail: React.FC<SliderRailProps>;
68
69
  export const SliderTrack: React.FC<SliderTrackProps>;
69
70
  export const SliderThumb: React.FC<SliderThumbProps>;
70
71
  export const SliderValueLabel: React.FC<SliderValueLabelProps>;
72
+ export const SliderInput: React.FC<SliderInputProps>;
71
73
 
72
74
  /**
73
75
  *
package/Slider/Slider.js CHANGED
@@ -370,11 +370,11 @@ const shouldSpreadOwnerState = Component => {
370
370
  return !Component || !isHostComponent(Component);
371
371
  };
372
372
 
373
- const Slider = /*#__PURE__*/React.forwardRef(function Slider(inputProps, ref) {
373
+ const Slider = /*#__PURE__*/React.forwardRef(function Slider(sliderProps, ref) {
374
374
  var _componentsProps$root, _componentsProps$thum, _componentsProps$trac, _componentsProps$valu;
375
375
 
376
376
  const props = useThemeProps({
377
- props: inputProps,
377
+ props: sliderProps,
378
378
  name: 'MuiSlider'
379
379
  });
380
380
  const theme = useTheme();
@@ -498,6 +498,7 @@ process.env.NODE_ENV !== "production" ? Slider.propTypes
498
498
  * @default {}
499
499
  */
500
500
  components: PropTypes.shape({
501
+ Input: PropTypes.elementType,
501
502
  Mark: PropTypes.elementType,
502
503
  MarkLabel: PropTypes.elementType,
503
504
  Rail: PropTypes.elementType,
@@ -511,7 +512,24 @@ process.env.NODE_ENV !== "production" ? Slider.propTypes
511
512
  * The props used for each slot inside the Slider.
512
513
  * @default {}
513
514
  */
514
- componentsProps: PropTypes.object,
515
+ componentsProps: PropTypes.shape({
516
+ input: PropTypes.object,
517
+ mark: PropTypes.object,
518
+ markLabel: PropTypes.object,
519
+ rail: PropTypes.object,
520
+ root: PropTypes.object,
521
+ thumb: PropTypes.object,
522
+ track: PropTypes.object,
523
+ valueLabel: PropTypes.shape({
524
+ className: PropTypes.string,
525
+ components: PropTypes.shape({
526
+ Root: PropTypes.elementType
527
+ }),
528
+ style: PropTypes.object,
529
+ value: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.number), PropTypes.number]),
530
+ valueLabelDisplay: PropTypes.oneOf(['auto', 'off', 'on'])
531
+ })
532
+ }),
515
533
 
516
534
  /**
517
535
  * The default value. Use when the component is not controlled.
@@ -205,7 +205,9 @@ process.env.NODE_ENV !== "production" ? StepLabel.propTypes
205
205
  * The props used for each slot inside.
206
206
  * @default {}
207
207
  */
208
- componentsProps: PropTypes.object,
208
+ componentsProps: PropTypes.shape({
209
+ label: PropTypes.object
210
+ }),
209
211
 
210
212
  /**
211
213
  * If `true`, the step is marked as failed.
@@ -48,6 +48,14 @@ export interface SvgIconTypeMap<P = {}, D extends React.ElementType = 'svg'> {
48
48
  * Applies a color attribute to the SVG element.
49
49
  */
50
50
  htmlColor?: string;
51
+ /**
52
+ * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`
53
+ * prop will be ignored.
54
+ * Useful when you want to reference a custom `component` and have `SvgIcon` pass that
55
+ * `component`'s viewBox to the root node.
56
+ * @default false
57
+ */
58
+ inheritViewBox?: boolean;
51
59
  /**
52
60
  * The shape-rendering attribute. The behavior of the different options is described on the
53
61
  * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).
@@ -1,6 +1,6 @@
1
1
  import _extends from "@babel/runtime/helpers/esm/extends";
2
2
  import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
- const _excluded = ["children", "className", "color", "component", "fontSize", "htmlColor", "titleAccess", "viewBox"];
3
+ const _excluded = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"];
4
4
  import * as React from 'react';
5
5
  import PropTypes from 'prop-types';
6
6
  import clsx from 'clsx';
@@ -76,6 +76,7 @@ const SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {
76
76
  component = 'svg',
77
77
  fontSize = 'medium',
78
78
  htmlColor,
79
+ inheritViewBox = false,
79
80
  titleAccess,
80
81
  viewBox = '0 0 24 24'
81
82
  } = props,
@@ -85,21 +86,27 @@ const SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {
85
86
  color,
86
87
  component,
87
88
  fontSize,
89
+ inheritViewBox,
88
90
  viewBox
89
91
  });
90
92
 
93
+ const more = {};
94
+
95
+ if (!inheritViewBox) {
96
+ more.viewBox = viewBox;
97
+ }
98
+
91
99
  const classes = useUtilityClasses(ownerState);
92
100
  return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({
93
101
  as: component,
94
102
  className: clsx(classes.root, className),
95
103
  ownerState: ownerState,
96
104
  focusable: "false",
97
- viewBox: viewBox,
98
105
  color: htmlColor,
99
106
  "aria-hidden": titleAccess ? undefined : true,
100
107
  role: titleAccess ? 'img' : undefined,
101
108
  ref: ref
102
- }, other, {
109
+ }, more, other, {
103
110
  children: [children, titleAccess ? /*#__PURE__*/_jsx("title", {
104
111
  children: titleAccess
105
112
  }) : null]
@@ -156,6 +163,15 @@ process.env.NODE_ENV !== "production" ? SvgIcon.propTypes
156
163
  */
157
164
  htmlColor: PropTypes.string,
158
165
 
166
+ /**
167
+ * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`
168
+ * prop will be ignored.
169
+ * Useful when you want to reference a custom `component` and have `SvgIcon` pass that
170
+ * `component`'s viewBox to the root node.
171
+ * @default false
172
+ */
173
+ inheritViewBox: PropTypes.bool,
174
+
159
175
  /**
160
176
  * The shape-rendering attribute. The behavior of the different options is described on the
161
177
  * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).
package/Tabs/Tabs.d.ts CHANGED
@@ -88,7 +88,7 @@ export interface TabsTypeMap<P = {}, D extends React.ElementType = typeof Button
88
88
  * Props applied to the tab indicator element.
89
89
  * @default {}
90
90
  */
91
- TabIndicatorProps?: Partial<React.HTMLAttributes<HTMLDivElement>>;
91
+ TabIndicatorProps?: React.HTMLAttributes<HTMLDivElement>;
92
92
  /**
93
93
  * Props applied to the [`TabScrollButton`](/api/tab-scroll-button/) element.
94
94
  * @default {}
@@ -83,6 +83,7 @@ export interface BaseTextFieldProps
83
83
  id?: string;
84
84
  /**
85
85
  * Props applied to the [`InputLabel`](/api/input-label/) element.
86
+ * Pointer events like `onClick` are enabled if and only if `shrink` is `true`.
86
87
  */
87
88
  InputLabelProps?: Partial<InputLabelProps>;
88
89
  /**
@@ -296,6 +296,7 @@ process.env.NODE_ENV !== "production" ? TextField.propTypes
296
296
 
297
297
  /**
298
298
  * Props applied to the [`InputLabel`](/api/input-label/) element.
299
+ * Pointer events like `onClick` are enabled if and only if `shrink` is `true`.
299
300
  */
300
301
  InputLabelProps: PropTypes.object,
301
302
 
@@ -681,7 +681,12 @@ process.env.NODE_ENV !== "production" ? Tooltip.propTypes
681
681
  * and `componentsProps.transition` prop values win over `TransitionProps` if both are applied.
682
682
  * @default {}
683
683
  */
684
- componentsProps: PropTypes.object,
684
+ componentsProps: PropTypes.shape({
685
+ arrow: PropTypes.object,
686
+ popper: PropTypes.object,
687
+ tooltip: PropTypes.object,
688
+ transition: PropTypes.object
689
+ }),
685
690
 
686
691
  /**
687
692
  * Set to `true` if the `title` acts as an accessible description.
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license MUI v5.2.4
1
+ /** @license MUI v5.2.8
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.
@@ -733,7 +733,9 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes
733
733
  * The props used for each slot inside.
734
734
  * @default {}
735
735
  */
736
- componentsProps: PropTypes.object,
736
+ componentsProps: PropTypes.shape({
737
+ clearIndicator: PropTypes.object
738
+ }),
737
739
 
738
740
  /**
739
741
  * The default value. Use when the component is not controlled.
@@ -123,7 +123,9 @@ process.env.NODE_ENV !== "production" ? Backdrop.propTypes
123
123
  * The props used for each slot inside the Backdrop.
124
124
  * @default {}
125
125
  */
126
- componentsProps: PropTypes.object,
126
+ componentsProps: PropTypes.shape({
127
+ root: PropTypes.object
128
+ }),
127
129
 
128
130
  /**
129
131
  * If `true`, the backdrop is invisible.
@@ -11,16 +11,19 @@ import styled from '../styles/styled';
11
11
  import useThemeProps from '../styles/useThemeProps';
12
12
  import capitalize from '../utils/capitalize';
13
13
  import { jsx as _jsx } from "react/jsx-runtime";
14
- export var badgeClasses = _extends({}, badgeUnstyledClasses, generateUtilityClasses('MuiBadge', ['colorError', 'colorInfo', 'colorPrimary', 'colorSecondary', 'colorSuccess', 'colorWarning']));
14
+ export var badgeClasses = _extends({}, badgeUnstyledClasses, generateUtilityClasses('MuiBadge', ['colorError', 'colorInfo', 'colorPrimary', 'colorSecondary', 'colorSuccess', 'colorWarning', 'overlapRectangular', 'overlapCircular', // TODO: v6 remove the overlap value from these class keys
15
+ 'anchorOriginTopLeftCircular', 'anchorOriginTopLeftRectangular', 'anchorOriginTopRightCircular', 'anchorOriginTopRightRectangular', 'anchorOriginBottomLeftCircular', 'anchorOriginBottomLeftRectangular', 'anchorOriginBottomRightCircular', 'anchorOriginBottomRightRectangular']));
15
16
  var RADIUS_STANDARD = 10;
16
17
  var RADIUS_DOT = 4;
17
18
 
18
19
  var extendUtilityClasses = function extendUtilityClasses(ownerState) {
19
20
  var color = ownerState.color,
21
+ anchorOrigin = ownerState.anchorOrigin,
22
+ overlap = ownerState.overlap,
20
23
  _ownerState$classes = ownerState.classes,
21
24
  classes = _ownerState$classes === void 0 ? {} : _ownerState$classes;
22
25
  return _extends({}, classes, {
23
- badge: clsx(classes.badge, color !== 'default' && [getBadgeUtilityClass("color".concat(capitalize(color))), classes["color".concat(capitalize(color))]])
26
+ badge: clsx(classes.badge, getBadgeUtilityClass("anchorOrigin".concat(capitalize(anchorOrigin.vertical)).concat(capitalize(anchorOrigin.horizontal)).concat(capitalize(overlap))), getBadgeUtilityClass("overlap".concat(capitalize(overlap))), color !== 'default' && [getBadgeUtilityClass("color".concat(capitalize(color))), classes["color".concat(capitalize(color))]])
24
27
  });
25
28
  };
26
29
 
@@ -154,12 +157,19 @@ var Badge = /*#__PURE__*/React.forwardRef(function Badge(inProps, ref) {
154
157
  name: 'MuiBadge'
155
158
  });
156
159
 
157
- var _props$component = props.component,
160
+ var _props$anchorOrigin = props.anchorOrigin,
161
+ anchorOriginProp = _props$anchorOrigin === void 0 ? {
162
+ vertical: 'top',
163
+ horizontal: 'right'
164
+ } : _props$anchorOrigin,
165
+ _props$component = props.component,
158
166
  component = _props$component === void 0 ? 'span' : _props$component,
159
167
  _props$components = props.components,
160
168
  components = _props$components === void 0 ? {} : _props$components,
161
169
  _props$componentsProp = props.componentsProps,
162
170
  componentsProps = _props$componentsProp === void 0 ? {} : _props$componentsProp,
171
+ _props$overlap = props.overlap,
172
+ overlapProp = _props$overlap === void 0 ? 'rectangular' : _props$overlap,
163
173
  _props$color = props.color,
164
174
  colorProp = _props$color === void 0 ? 'default' : _props$color,
165
175
  invisibleProp = props.invisible,
@@ -168,10 +178,12 @@ var Badge = /*#__PURE__*/React.forwardRef(function Badge(inProps, ref) {
168
178
  showZero = _props$showZero === void 0 ? false : _props$showZero,
169
179
  _props$variant = props.variant,
170
180
  variantProp = _props$variant === void 0 ? 'standard' : _props$variant,
171
- other = _objectWithoutProperties(props, ["component", "components", "componentsProps", "color", "invisible", "badgeContent", "showZero", "variant"]);
181
+ other = _objectWithoutProperties(props, ["anchorOrigin", "component", "components", "componentsProps", "overlap", "color", "invisible", "badgeContent", "showZero", "variant"]);
172
182
 
173
183
  var prevProps = usePreviousProps({
174
- color: colorProp
184
+ anchorOrigin: anchorOriginProp,
185
+ color: colorProp,
186
+ overlap: overlapProp
175
187
  });
176
188
  var invisible = invisibleProp;
177
189
 
@@ -181,15 +193,22 @@ var Badge = /*#__PURE__*/React.forwardRef(function Badge(inProps, ref) {
181
193
 
182
194
  var _ref10 = invisible ? prevProps : props,
183
195
  _ref10$color = _ref10.color,
184
- color = _ref10$color === void 0 ? colorProp : _ref10$color;
196
+ color = _ref10$color === void 0 ? colorProp : _ref10$color,
197
+ _ref10$overlap = _ref10.overlap,
198
+ overlap = _ref10$overlap === void 0 ? overlapProp : _ref10$overlap,
199
+ _ref10$anchorOrigin = _ref10.anchorOrigin,
200
+ anchorOrigin = _ref10$anchorOrigin === void 0 ? anchorOriginProp : _ref10$anchorOrigin;
185
201
 
186
202
  var ownerState = _extends({}, props, {
203
+ anchorOrigin: anchorOrigin,
187
204
  invisible: invisible,
188
- color: color
205
+ color: color,
206
+ overlap: overlap
189
207
  });
190
208
 
191
209
  var classes = extendUtilityClasses(ownerState);
192
210
  return /*#__PURE__*/_jsx(BadgeUnstyled, _extends({
211
+ anchorOrigin: anchorOrigin,
193
212
  invisible: invisibleProp,
194
213
  badgeContent: badgeContentProp,
195
214
  showZero: showZero,
@@ -203,12 +222,14 @@ var Badge = /*#__PURE__*/React.forwardRef(function Badge(inProps, ref) {
203
222
  root: _extends({}, componentsProps.root, shouldSpreadAdditionalProps(components.Root) && {
204
223
  as: component,
205
224
  ownerState: _extends({}, (_componentsProps$root = componentsProps.root) == null ? void 0 : _componentsProps$root.ownerState, {
206
- color: color
225
+ color: color,
226
+ overlap: overlap
207
227
  })
208
228
  }),
209
229
  badge: _extends({}, componentsProps.badge, shouldSpreadAdditionalProps(components.Badge) && {
210
230
  ownerState: _extends({}, (_componentsProps$badg = componentsProps.badge) == null ? void 0 : _componentsProps$badg.ownerState, {
211
- color: color
231
+ color: color,
232
+ overlap: overlap
212
233
  })
213
234
  })
214
235
  },
@@ -279,7 +300,10 @@ process.env.NODE_ENV !== "production" ? Badge.propTypes
279
300
  * The props used for each slot inside the Badge.
280
301
  * @default {}
281
302
  */
282
- componentsProps: PropTypes.object,
303
+ componentsProps: PropTypes.shape({
304
+ badge: PropTypes.object,
305
+ root: PropTypes.object
306
+ }),
283
307
 
284
308
  /**
285
309
  * If `true`, the badge is invisible.
@@ -255,7 +255,10 @@ process.env.NODE_ENV !== "production" ? FilledInput.propTypes
255
255
  * The props used for each slot inside the Input.
256
256
  * @default {}
257
257
  */
258
- componentsProps: PropTypes.object,
258
+ componentsProps: PropTypes.shape({
259
+ input: PropTypes.object,
260
+ root: PropTypes.object
261
+ }),
259
262
 
260
263
  /**
261
264
  * The default value. Use when the component is not controlled.
@@ -156,7 +156,9 @@ process.env.NODE_ENV !== "production" ? FormControlLabel.propTypes
156
156
  * The props used for each slot inside.
157
157
  * @default {}
158
158
  */
159
- componentsProps: PropTypes.object,
159
+ componentsProps: PropTypes.shape({
160
+ typography: PropTypes.object
161
+ }),
160
162
 
161
163
  /**
162
164
  * A control element. For instance, it can be a `Radio`, a `Switch` or a `Checkbox`.
@@ -190,7 +190,10 @@ process.env.NODE_ENV !== "production" ? Input.propTypes
190
190
  * The props used for each slot inside the Input.
191
191
  * @default {}
192
192
  */
193
- componentsProps: PropTypes.object,
193
+ componentsProps: PropTypes.shape({
194
+ input: PropTypes.object,
195
+ root: PropTypes.object
196
+ }),
194
197
 
195
198
  /**
196
199
  * The default value. Use when the component is not controlled.
@@ -561,7 +561,10 @@ process.env.NODE_ENV !== "production" ? InputBase.propTypes
561
561
  * The props used for each slot inside the Input.
562
562
  * @default {}
563
563
  */
564
- componentsProps: PropTypes.object,
564
+ componentsProps: PropTypes.shape({
565
+ input: PropTypes.object,
566
+ root: PropTypes.object
567
+ }),
565
568
 
566
569
  /**
567
570
  * The default value. Use when the component is not controlled.
@@ -78,6 +78,8 @@ var InputLabelRoot = styled(FormLabel, {
78
78
  }, ownerState.size === 'small' && {
79
79
  transform: 'translate(12px, 13px) scale(1)'
80
80
  }, ownerState.shrink && _extends({
81
+ userSelect: 'none',
82
+ pointerEvents: 'auto',
81
83
  transform: 'translate(12px, 7px) scale(0.75)',
82
84
  maxWidth: 'calc(133% - 24px)'
83
85
  }, ownerState.size === 'small' && {
@@ -91,6 +93,8 @@ var InputLabelRoot = styled(FormLabel, {
91
93
  }, ownerState.size === 'small' && {
92
94
  transform: 'translate(14px, 9px) scale(1)'
93
95
  }, ownerState.shrink && {
96
+ userSelect: 'none',
97
+ pointerEvents: 'auto',
94
98
  maxWidth: 'calc(133% - 24px)',
95
99
  transform: 'translate(14px, -9px) scale(0.75)'
96
100
  }));
@@ -348,7 +348,9 @@ process.env.NODE_ENV !== "production" ? ListItem.propTypes
348
348
  * The props used for each slot inside the Input.
349
349
  * @default {}
350
350
  */
351
- componentsProps: PropTypes.object,
351
+ componentsProps: PropTypes.shape({
352
+ root: PropTypes.object
353
+ }),
352
354
 
353
355
  /**
354
356
  * The container component used when a `ListItemSecondaryAction` is the last child.
@@ -194,7 +194,9 @@ process.env.NODE_ENV !== "production" ? Modal.propTypes
194
194
  * The props used for each slot inside the Modal.
195
195
  * @default {}
196
196
  */
197
- componentsProps: PropTypes.object,
197
+ componentsProps: PropTypes.shape({
198
+ root: PropTypes.object
199
+ }),
198
200
 
199
201
  /**
200
202
  * An HTML element or function that returns one.
@@ -384,11 +384,11 @@ var shouldSpreadOwnerState = function shouldSpreadOwnerState(Component) {
384
384
  return !Component || !isHostComponent(Component);
385
385
  };
386
386
 
387
- var Slider = /*#__PURE__*/React.forwardRef(function Slider(inputProps, ref) {
387
+ var Slider = /*#__PURE__*/React.forwardRef(function Slider(sliderProps, ref) {
388
388
  var _componentsProps$root, _componentsProps$thum, _componentsProps$trac, _componentsProps$valu;
389
389
 
390
390
  var props = useThemeProps({
391
- props: inputProps,
391
+ props: sliderProps,
392
392
  name: 'MuiSlider'
393
393
  });
394
394
  var theme = useTheme();
@@ -514,6 +514,7 @@ process.env.NODE_ENV !== "production" ? Slider.propTypes
514
514
  * @default {}
515
515
  */
516
516
  components: PropTypes.shape({
517
+ Input: PropTypes.elementType,
517
518
  Mark: PropTypes.elementType,
518
519
  MarkLabel: PropTypes.elementType,
519
520
  Rail: PropTypes.elementType,
@@ -527,7 +528,24 @@ process.env.NODE_ENV !== "production" ? Slider.propTypes
527
528
  * The props used for each slot inside the Slider.
528
529
  * @default {}
529
530
  */
530
- componentsProps: PropTypes.object,
531
+ componentsProps: PropTypes.shape({
532
+ input: PropTypes.object,
533
+ mark: PropTypes.object,
534
+ markLabel: PropTypes.object,
535
+ rail: PropTypes.object,
536
+ root: PropTypes.object,
537
+ thumb: PropTypes.object,
538
+ track: PropTypes.object,
539
+ valueLabel: PropTypes.shape({
540
+ className: PropTypes.string,
541
+ components: PropTypes.shape({
542
+ Root: PropTypes.elementType
543
+ }),
544
+ style: PropTypes.object,
545
+ value: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.number), PropTypes.number]),
546
+ valueLabelDisplay: PropTypes.oneOf(['auto', 'off', 'on'])
547
+ })
548
+ }),
531
549
 
532
550
  /**
533
551
  * The default value. Use when the component is not controlled.
@@ -209,7 +209,9 @@ process.env.NODE_ENV !== "production" ? StepLabel.propTypes
209
209
  * The props used for each slot inside.
210
210
  * @default {}
211
211
  */
212
- componentsProps: PropTypes.object,
212
+ componentsProps: PropTypes.shape({
213
+ label: PropTypes.object
214
+ }),
213
215
 
214
216
  /**
215
217
  * If `true`, the step is marked as failed.