@mui/docs 6.0.0-alpha.6 → 6.0.0-alpha.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.
package/CHANGELOG.md CHANGED
@@ -1,12 +1,94 @@
1
1
  # [Versions](https://mui.com/versions/)
2
2
 
3
+ ## v6.0.0-alpha.8
4
+
5
+ <!-- generated comparing v6.0.0-alpha.7..next -->
6
+
7
+ _May 21, 2024_
8
+
9
+ A big thanks to the 7 contributors who made this release possible.
10
+ This release was mostly about 🐛 bug fixes and 📚 documentation improvements.
11
+
12
+ ### `@mui/material@6.0.0-alpha.7`
13
+
14
+ - &#8203;<!-- 04 -->[material-ui] Filter only valid theme palette for generating styles (#42147) @siriwatknp
15
+ - &#8203;<!-- 03 -->[material-ui] Remove UMD bundle (#42172) @ZeeshanTamboli
16
+ - &#8203;<!-- 02 -->[material-ui][TextField] Deprecate `*Props` props (#42062) @DiegoAndai
17
+
18
+ ### Docs
19
+
20
+ - &#8203;<!-- 08 -->[docs] Remove Base UI from the README (#42307) @danilo-leal
21
+ - &#8203;<!-- 07 -->[docs][material-ui] Fix typo in style interoperability with Tailwind CSS docs (#42279) @ZeeshanTamboli
22
+ - &#8203;<!-- 06 -->[docs][material-ui] Add supported browsers section to migration guide (#42194) @DiegoAndai
23
+ - &#8203;<!-- 05 -->[docs][material-ui][Pagination] Clarify pagination `page` prop API (#42220) @Mandar-Pandya
24
+
25
+ ### Core
26
+
27
+ - &#8203;<!-- 12 -->[blog] Update blog post OG image (#42270) @danilo-leal
28
+ - &#8203;<!-- 11 -->[blog] Update Pigment CSS post (#42266) @danilo-leal
29
+ - &#8203;<!-- 10 -->[docs] Remove LocalMonero (#42224) @oliviertassinari
30
+ - &#8203;<!-- 08 -->[docs-infra] Fix keyboard navigation on page tabs (#42152) @danilo-leal
31
+ - &#8203;<!-- 10 -->[code-infra] Remove raw-loader (#42275) @Janpot
32
+ - &#8203;<!-- 09 -->[core] Remove outdated Babel plugins (#42140) @ZeeshanTamboli
33
+ - &#8203;<!-- 12 -->[core] Fix a few more key spread issues (#42168) @oliviertassinari
34
+ - &#8203;<!-- 01 -->[website] Avoid duplicate simple vs. rich (#42100) @oliviertassinari
35
+
36
+ All contributors of this release in alphabetical order: @danilo-leal, @DiegoAndai, @Janpot, @Mandar-Pandya, @oliviertassinari, @siriwatknp, @ZeeshanTamboli
37
+
38
+ ## v6.0.0-alpha.7
39
+
40
+ <!-- generated comparing v6.0.0-alpha.6..next -->
41
+
42
+ _May 16, 2024_
43
+
44
+ A big thanks to the 14 contributors who made this release possible.
45
+
46
+ ### `@mui/material@6.0.0-alpha.7`
47
+
48
+ - &#8203;<!-- 23 -->[Autocomplete] Deprecate `componentsProps` props (#42179) @lhilgert9
49
+ - &#8203;<!-- 22 -->[Autocomplete] Improve design when there's a start adornment for small autocomplete (#41781) @TahaRhidouani
50
+ - &#8203;<!-- 21 -->[Autocomplete] deprecate `*Component` and `*Props` for v6 (#41875) @lhilgert9
51
+ - &#8203;<!-- 19 -->[CircularProgress] Deprecate composed classes (#42076) @sai6855
52
+ - &#8203;<!-- 05 -->[ToggleButtonGroup] Add missing `selected` class in ToggleButtonGroupClasses type (#42243) @tarunrajput
53
+
54
+ ### `@mui/codemod@6.0.0-alpha.6`
55
+
56
+ - &#8203;<!-- 18 -->[Divider] Only apply codemod if light prop is present (#42098) @DiegoAndai
57
+
58
+ ### Docs
59
+
60
+ - &#8203;<!-- 13 -->Fix 301 to Figma @oliviertassinari
61
+ - &#8203;<!-- 12 -->Fix use of deprecated React API (#42118) @oliviertassinari
62
+ - &#8203;<!-- 11 -->Remove the Base notification (#42191) @danilo-leal
63
+ - &#8203;<!-- 07 -->[material-ui] Improve descriptions for deprecated props (#42221) @aarongarciah
64
+ - &#8203;<!-- 06 -->[material-ui] Fix typo in composition docs (#42195) @aarongarciah
65
+
66
+ ### Core
67
+
68
+ - &#8203;<!-- 20 -->[blog] Introducing Pigment CSS blog post (#42198) @samuelsycamore
69
+ - &#8203;<!-- 17 -->[core] Remove confusing comment @oliviertassinari
70
+ - &#8203;<!-- 16 -->[core] Match other repositories and convention @oliviertassinari
71
+ - &#8203;<!-- 15 -->[core] Fix React 18.3 warnings about spreading keys in the Material UI `Autocomplete` component (#42099) @heath-freenome
72
+ - &#8203;<!-- 14 -->[core] Remove unecessary quotes @oliviertassinari
73
+ - &#8203;<!-- 10 -->[docs-infra] Share code for section title (#42236) @alexfauquette
74
+ - &#8203;<!-- 09 -->[docs-infra] Limit the copy button to the visible code block (#42115) @danilo-leal
75
+ - &#8203;<!-- 08 -->[docs-infra] Make select components with two capital letters (#42004) @alexfauquette
76
+ - &#8203;<!-- 08 -->[docs-infra][toolpad] Fix Page title and SERP title mismatch (#41919) @bharatkashyap
77
+ - &#8203;<!-- 05 -->[website] Add redirection for talk @oliviertassinari
78
+ - &#8203;<!-- 04 -->[website] Adds Arthur Balduini team info (#42193) @arthurbalduini
79
+ - &#8203;<!-- 03 -->[website] Update the role template file (#42192) @danilo-leal
80
+ - &#8203;<!-- 02 -->[website] Update MUI X deps and migrate TreeView demos to v7 API (#42149) @noraleonte
81
+ - &#8203;<!-- 01 -->[website] Fix pricing casing (#42178) @aarongarciah
82
+
83
+ All contributors of this release in alphabetical order: @aarongarciah, @alexfauquette, @arthurbalduini, @bharatkashyap, @danilo-leal, @DiegoAndai, @heath-freenome, @lhilgert9, @noraleonte, @oliviertassinari, @sai6855, @samuelsycamore, @TahaRhidouani, @tarunrajput
84
+
3
85
  ## v6.0.0-alpha.6
4
86
 
5
87
  <!-- generated comparing v6.0.0-alpha.5..next -->
6
88
 
7
89
  _May 8, 2024_
8
90
 
9
- A big thanks to the 10 contributors who made this release possible. Here are some highlights ✨:
91
+ A big thanks to the 10 contributors who made this release possible.
10
92
 
11
93
  ### `@mui/material@6.0.0-alpha.6`
12
94
 
@@ -54,7 +136,7 @@ All contributors of this release in alphabetical order: @aarongarciah, @danilo-l
54
136
 
55
137
  _May 1, 2024_
56
138
 
57
- A big thanks to the 9 contributors who made this release possible. Here are some highlights ✨:
139
+ A big thanks to the 9 contributors who made this release possible.
58
140
 
59
141
  ### `@mui/material@6.0.0-alpha.5`
60
142
 
@@ -1,17 +1,12 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
2
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
1
  var _span, _span2;
4
- const _excluded = ["code"];
5
2
  import * as React from 'react';
6
- import ContentCopyRoundedIcon from '@mui/icons-material/ContentCopyRounded';
7
- import LibraryAddCheckRoundedIcon from '@mui/icons-material/LibraryAddCheckRounded';
8
3
  import useClipboardCopy from './useClipboardCopy';
9
4
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
10
5
  export function CodeCopyButton(props) {
11
6
  const {
12
- code
13
- } = props,
14
- other = _objectWithoutPropertiesLoose(props, _excluded);
7
+ code,
8
+ ...other
9
+ } = props;
15
10
  const {
16
11
  copy,
17
12
  isCopied
@@ -21,7 +16,8 @@ export function CodeCopyButton(props) {
21
16
  const key = macOS ? '⌘' : 'Ctrl + ';
22
17
  return /*#__PURE__*/_jsx("div", {
23
18
  className: "MuiCode-copy-container",
24
- children: /*#__PURE__*/_jsxs("button", _extends({}, other, {
19
+ children: /*#__PURE__*/_jsxs("button", {
20
+ ...other,
25
21
  "aria-label": "Copy the code",
26
22
  type: "button",
27
23
  className: "MuiCode-copy",
@@ -29,22 +25,17 @@ export function CodeCopyButton(props) {
29
25
  // event.stopPropagation();
30
26
  await copy(code);
31
27
  },
32
- children: [isCopied ? /*#__PURE__*/_jsx(LibraryAddCheckRoundedIcon, {
33
- sx: {
34
- fontSize: 18
35
- }
36
- }) : /*#__PURE__*/_jsx(ContentCopyRoundedIcon, {
37
- sx: {
38
- fontSize: 18
39
- }
40
- }), /*#__PURE__*/_jsxs("span", {
28
+ children: [isCopied ? 'Copied' : 'Copy', /*#__PURE__*/_jsxs("span", {
41
29
  className: "MuiCode-copyKeypress",
30
+ style: {
31
+ opacity: isCopied ? 0 : 1
32
+ },
42
33
  children: [_span || (_span = /*#__PURE__*/_jsx("span", {
43
34
  children: "(or"
44
35
  })), " ", key, "C", _span2 || (_span2 = /*#__PURE__*/_jsx("span", {
45
36
  children: ")"
46
37
  }))]
47
38
  })]
48
- }))
39
+ })
49
40
  });
50
41
  }
@@ -1,6 +1,3 @@
1
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
- import _extends from "@babel/runtime/helpers/esm/extends";
3
- const _excluded = ["copyButtonHidden", "copyButtonProps", "code", "language", "plainStyle", "parentComponent", "preComponent"];
4
1
  import * as React from 'react';
5
2
  import prism from '@mui/internal-markdown/prism';
6
3
  import { NoSsr } from '@mui/base/NoSsr';
@@ -20,39 +17,42 @@ const Pre = styled('pre')(({
20
17
  [theme.breakpoints.up('md')]: {
21
18
  maxWidth: 'calc(100vw - 32px - 16px)'
22
19
  },
23
- '& code': _extends({}, theme.typography.caption, {
20
+ '& code': {
21
+ // Avoid layout jump after hydration (style injected by Prism)
22
+ ...theme.typography.caption,
24
23
  fontFamily: theme.typography.fontFamilyCode,
25
24
  fontWeight: 400,
26
25
  WebkitFontSmoothing: 'subpixel-antialiased'
27
26
  // Reset for Safari
28
27
  // https://github.com/necolas/normalize.css/blob/master/normalize.css#L102
29
- })
28
+ }
30
29
  }));
31
30
  export const HighlightedCode = /*#__PURE__*/React.forwardRef(function HighlightedCode(props, ref) {
32
31
  const {
33
- copyButtonHidden = false,
34
- copyButtonProps,
35
- code,
36
- language,
37
- plainStyle,
38
- parentComponent: Component = plainStyle ? 'div' : MarkdownElement,
39
- preComponent: PreComponent = plainStyle ? Pre : 'pre'
40
- } = props,
41
- other = _objectWithoutPropertiesLoose(props, _excluded);
32
+ copyButtonHidden = false,
33
+ copyButtonProps,
34
+ code,
35
+ language,
36
+ plainStyle,
37
+ parentComponent: Component = plainStyle ? 'div' : MarkdownElement,
38
+ preComponent: PreComponent = plainStyle ? Pre : 'pre',
39
+ ...other
40
+ } = props;
42
41
  const renderedCode = React.useMemo(() => {
43
42
  return prism(code.trim(), language);
44
43
  }, [code, language]);
45
44
  const handlers = useCodeCopy();
46
- return /*#__PURE__*/_jsx(Component, _extends({
47
- ref: ref
48
- }, other, {
49
- children: /*#__PURE__*/_jsxs("div", _extends({
50
- className: "MuiCode-root"
51
- }, handlers, {
45
+ return /*#__PURE__*/_jsx(Component, {
46
+ ref: ref,
47
+ ...other,
48
+ children: /*#__PURE__*/_jsxs("div", {
49
+ className: "MuiCode-root",
50
+ ...handlers,
52
51
  children: [copyButtonHidden ? null : /*#__PURE__*/_jsx(NoSsr, {
53
- children: /*#__PURE__*/_jsx(CodeCopyButton, _extends({
54
- code: code
55
- }, copyButtonProps))
52
+ children: /*#__PURE__*/_jsx(CodeCopyButton, {
53
+ code: code,
54
+ ...copyButtonProps
55
+ })
56
56
  }), /*#__PURE__*/_jsx(PreComponent, {
57
57
  children: /*#__PURE__*/_jsx("code", {
58
58
  className: `language-${language}`
@@ -63,6 +63,6 @@ export const HighlightedCode = /*#__PURE__*/React.forwardRef(function Highlighte
63
63
  }
64
64
  })
65
65
  })]
66
- }))
67
- }));
66
+ })
67
+ });
68
68
  });
@@ -1,6 +1,3 @@
1
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
- import _extends from "@babel/runtime/helpers/esm/extends";
3
- const _excluded = ["classNameDescription", "classNameTitle", "description", "icon", "link", "svg", "title", "titleProps"];
4
1
  import * as React from 'react';
5
2
  import { alpha } from '@mui/material/styles';
6
3
  import Box from '@mui/material/Box';
@@ -12,7 +9,7 @@ export function GlowingIconContainer({
12
9
  icon
13
10
  }) {
14
11
  return /*#__PURE__*/_jsx(Box, {
15
- sx: theme => _extends({
12
+ sx: theme => ({
16
13
  width: 36,
17
14
  height: 36,
18
15
  display: 'flex',
@@ -26,63 +23,65 @@ export function GlowingIconContainer({
26
23
  boxShadow: `0px 0 0 2px ${alpha(theme.palette.primary[500], 0.1)}, 0px 2px 12px 0px rgba(234, 237, 241, 0.3) inset`,
27
24
  '& .MuiSvgIcon-root': {
28
25
  fontSize: theme.typography.pxToRem(18)
29
- }
30
- }, theme.applyDarkStyles({
31
- borderColor: alpha(theme.palette.primary[400], 0.25),
32
- bgcolor: alpha(theme.palette.primary[900], 0.2),
33
- boxShadow: `0 0 0 2px ${alpha(theme.palette.primary[600], 0.1)}, 0px 2px 12px 0px rgba(0, 0, 0, 0.25) inset`
34
- })),
26
+ },
27
+ ...theme.applyDarkStyles({
28
+ borderColor: alpha(theme.palette.primary[400], 0.25),
29
+ bgcolor: alpha(theme.palette.primary[900], 0.2),
30
+ boxShadow: `0 0 0 2px ${alpha(theme.palette.primary[600], 0.1)}, 0px 2px 12px 0px rgba(0, 0, 0, 0.25) inset`
31
+ })
32
+ }),
35
33
  children: icon
36
34
  });
37
35
  }
38
36
  export function InfoCard(props) {
39
37
  const {
40
- classNameDescription,
41
- classNameTitle,
42
- description,
43
- icon,
44
- link,
45
- svg,
46
- title,
47
- titleProps
48
- } = props,
49
- other = _objectWithoutPropertiesLoose(props, _excluded);
50
- return /*#__PURE__*/_jsxs(Paper, _extends({
38
+ classNameDescription,
39
+ classNameTitle,
40
+ description,
41
+ icon,
42
+ link,
43
+ svg,
44
+ title,
45
+ titleProps,
46
+ ...other
47
+ } = props;
48
+ return /*#__PURE__*/_jsxs(Paper, {
51
49
  variant: "outlined",
52
50
  component: link ? Link : 'div',
53
- href: link
54
- }, link ? {
55
- noLinkStyle: true,
56
- // Fix overloading with prefetch={false}, only prefetch on hover.
57
- prefetch: false
58
- } : {}, {
59
- sx: theme => _extends({
51
+ href: link,
52
+ ...(link ? {
53
+ noLinkStyle: true,
54
+ // Fix overloading with prefetch={false}, only prefetch on hover.
55
+ prefetch: false
56
+ } : {}),
57
+ sx: theme => ({
60
58
  p: 2.5,
61
59
  height: '100%',
62
- background: `${(theme.vars || theme).palette.gradients.linearSubtle}`
63
- }, theme.applyDarkStyles({
64
- bgcolor: alpha(theme.palette.primaryDark[800], 0.25),
65
60
  background: `${(theme.vars || theme).palette.gradients.linearSubtle}`,
66
- borderColor: 'primaryDark.700'
67
- }))
68
- }, other, {
61
+ ...theme.applyDarkStyles({
62
+ bgcolor: alpha(theme.palette.primaryDark[800], 0.25),
63
+ background: `${(theme.vars || theme).palette.gradients.linearSubtle}`,
64
+ borderColor: 'primaryDark.700'
65
+ })
66
+ }),
67
+ ...other,
69
68
  children: [svg && svg, icon && /*#__PURE__*/_jsx(GlowingIconContainer, {
70
69
  icon: icon
71
- }), /*#__PURE__*/_jsx(Typography, _extends({
70
+ }), /*#__PURE__*/_jsx(Typography, {
72
71
  fontWeight: "semiBold",
73
72
  component: "h3",
74
73
  color: "text.primary",
75
74
  variant: "body2",
76
75
  mt: icon ? 2 : 0,
77
76
  mb: description ? 0.5 : 0,
78
- className: classNameTitle
79
- }, titleProps, {
77
+ className: classNameTitle,
78
+ ...titleProps,
80
79
  children: title
81
- })), /*#__PURE__*/_jsx(Typography, {
80
+ }), /*#__PURE__*/_jsx(Typography, {
82
81
  variant: "body2",
83
82
  color: "text.secondary",
84
83
  className: classNameDescription,
85
84
  children: description
86
85
  })]
87
- }));
86
+ });
88
87
  }
package/Link/Link.js CHANGED
@@ -1,7 +1,3 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
2
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
- const _excluded = ["to", "linkAs", "replace", "scroll", "shallow", "prefetch", "legacyBehavior", "locale"],
4
- _excluded2 = ["activeClassName", "as", "className", "href", "legacyBehavior", "linkAs", "locale", "noLinkStyle", "prefetch", "replace", "role", "scroll", "shallow"];
5
1
  import * as React from 'react';
6
2
  import clsx from 'clsx';
7
3
  import { useRouter } from 'next/router';
@@ -24,16 +20,16 @@ import { jsx as _jsx } from "react/jsx-runtime";
24
20
  const Anchor = styled('a')({});
25
21
  const NextLinkComposed = /*#__PURE__*/React.forwardRef(function NextLinkComposed(props, ref) {
26
22
  const {
27
- to,
28
- linkAs,
29
- replace,
30
- scroll,
31
- shallow,
32
- prefetch,
33
- legacyBehavior = true,
34
- locale
35
- } = props,
36
- other = _objectWithoutPropertiesLoose(props, _excluded);
23
+ to,
24
+ linkAs,
25
+ replace,
26
+ scroll,
27
+ shallow,
28
+ prefetch,
29
+ legacyBehavior = true,
30
+ locale,
31
+ ...other
32
+ } = props;
37
33
  return /*#__PURE__*/_jsx(NextLink, {
38
34
  href: to,
39
35
  prefetch: prefetch,
@@ -44,31 +40,33 @@ const NextLinkComposed = /*#__PURE__*/React.forwardRef(function NextLinkComposed
44
40
  passHref: true,
45
41
  locale: locale,
46
42
  legacyBehavior: legacyBehavior,
47
- children: /*#__PURE__*/_jsx(Anchor, _extends({
43
+ children: /*#__PURE__*/_jsx(Anchor, {
48
44
  "data-no-markdown-link": "true",
49
- ref: ref
50
- }, other))
45
+ ref: ref,
46
+ ...other
47
+ })
51
48
  });
52
49
  });
53
50
  // A styled version of the Next.js Pages Router Link component:
54
51
  // https://nextjs.org/docs/pages/api-reference/components/link
55
52
  export const Link = /*#__PURE__*/React.forwardRef(function Link(props, ref) {
56
53
  const {
57
- activeClassName = 'active',
58
- as,
59
- className: classNameProps,
60
- href,
61
- legacyBehavior,
62
- linkAs: linkAsProp,
63
- locale,
64
- noLinkStyle,
65
- prefetch,
66
- replace,
67
- // Link don't have roles.
68
- scroll,
69
- shallow
70
- } = props,
71
- other = _objectWithoutPropertiesLoose(props, _excluded2);
54
+ activeClassName = 'active',
55
+ as,
56
+ className: classNameProps,
57
+ href,
58
+ legacyBehavior,
59
+ linkAs: linkAsProp,
60
+ locale,
61
+ noLinkStyle,
62
+ prefetch,
63
+ replace,
64
+ role,
65
+ // Link don't have roles.
66
+ scroll,
67
+ shallow,
68
+ ...other
69
+ } = props;
72
70
  const router = useRouter();
73
71
  const pathname = typeof href === 'string' ? href : href?.pathname;
74
72
  const routerPathname = router.pathname.replace('/[docsTab]', '');
@@ -93,14 +91,18 @@ export const Link = /*#__PURE__*/React.forwardRef(function Link(props, ref) {
93
91
  locale
94
92
  };
95
93
  if (noLinkStyle) {
96
- return /*#__PURE__*/_jsx(NextLinkComposed, _extends({
94
+ return /*#__PURE__*/_jsx(NextLinkComposed, {
97
95
  className: className,
98
- ref: ref
99
- }, nextjsProps, other));
96
+ ref: ref,
97
+ ...nextjsProps,
98
+ ...other
99
+ });
100
100
  }
101
- return /*#__PURE__*/_jsx(MuiLink, _extends({
101
+ return /*#__PURE__*/_jsx(MuiLink, {
102
102
  component: NextLinkComposed,
103
103
  className: className,
104
- ref: ref
105
- }, nextjsProps, other));
104
+ ref: ref,
105
+ ...nextjsProps,
106
+ ...other
107
+ });
106
108
  });