Skip to content

Commit 10b073a

Browse files
committed
[material-ui][Menu] Remove depreacted MenuListProps from demos
1 parent 394fa56 commit 10b073a

12 files changed

+48
-28
lines changed

docs/data/material/components/menus/BasicMenu.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ export default function BasicMenu() {
2929
anchorEl={anchorEl}
3030
open={open}
3131
onClose={handleClose}
32-
MenuListProps={{
33-
'aria-labelledby': 'basic-button',
32+
slotProps={{
33+
list: {
34+
'aria-labelledby': 'basic-button',
35+
},
3436
}}
3537
>
3638
<MenuItem onClick={handleClose}>Profile</MenuItem>

docs/data/material/components/menus/BasicMenu.tsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ export default function BasicMenu() {
2929
anchorEl={anchorEl}
3030
open={open}
3131
onClose={handleClose}
32-
MenuListProps={{
33-
'aria-labelledby': 'basic-button',
32+
slotProps={{
33+
list: {
34+
'aria-labelledby': 'basic-button',
35+
},
3436
}}
3537
>
3638
<MenuItem onClick={handleClose}>Profile</MenuItem>

docs/data/material/components/menus/CustomizedMenus.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,10 @@ export default function CustomizedMenus() {
7979
</Button>
8080
<StyledMenu
8181
id="demo-customized-menu"
82-
MenuListProps={{
83-
'aria-labelledby': 'demo-customized-button',
82+
slotProps={{
83+
list: {
84+
'aria-labelledby': 'demo-customized-button',
85+
},
8486
}}
8587
anchorEl={anchorEl}
8688
open={open}

docs/data/material/components/menus/CustomizedMenus.tsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,10 @@ export default function CustomizedMenus() {
7979
</Button>
8080
<StyledMenu
8181
id="demo-customized-menu"
82-
MenuListProps={{
83-
'aria-labelledby': 'demo-customized-button',
82+
slotProps={{
83+
list: {
84+
'aria-labelledby': 'demo-customized-button',
85+
},
8486
}}
8587
anchorEl={anchorEl}
8688
open={open}

docs/data/material/components/menus/FadeMenu.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@ export default function FadeMenu() {
2727
</Button>
2828
<Menu
2929
id="fade-menu"
30-
MenuListProps={{
31-
'aria-labelledby': 'fade-button',
30+
slotProps={{
31+
list: {
32+
'aria-labelledby': 'fade-button',
33+
},
3234
}}
3335
anchorEl={anchorEl}
3436
open={open}

docs/data/material/components/menus/FadeMenu.tsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@ export default function FadeMenu() {
2727
</Button>
2828
<Menu
2929
id="fade-menu"
30-
MenuListProps={{
31-
'aria-labelledby': 'fade-button',
30+
slotProps={{
31+
list: {
32+
'aria-labelledby': 'fade-button',
33+
},
3234
}}
3335
anchorEl={anchorEl}
3436
open={open}

docs/data/material/components/menus/GroupedMenu.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ export default function GroupedMenu() {
3030
anchorEl={anchorEl}
3131
open={open}
3232
onClose={handleClose}
33-
MenuListProps={{
34-
'aria-labelledby': 'basic-button',
33+
slotProps={{
34+
list: {
35+
'aria-labelledby': 'basic-button',
36+
},
3537
}}
3638
>
3739
<ListSubheader>Category 1</ListSubheader>

docs/data/material/components/menus/GroupedMenu.tsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ export default function GroupedMenu() {
3030
anchorEl={anchorEl}
3131
open={open}
3232
onClose={handleClose}
33-
MenuListProps={{
34-
'aria-labelledby': 'basic-button',
33+
slotProps={{
34+
list: {
35+
'aria-labelledby': 'basic-button',
36+
},
3537
}}
3638
>
3739
<ListSubheader>Category 1</ListSubheader>

docs/data/material/components/menus/LongMenu.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,6 @@ export default function LongMenu() {
4747
</IconButton>
4848
<Menu
4949
id="long-menu"
50-
MenuListProps={{
51-
'aria-labelledby': 'long-button',
52-
}}
5350
anchorEl={anchorEl}
5451
open={open}
5552
onClose={handleClose}
@@ -60,6 +57,9 @@ export default function LongMenu() {
6057
width: '20ch',
6158
},
6259
},
60+
list: {
61+
'aria-labelledby': 'long-button',
62+
},
6363
}}
6464
>
6565
{options.map((option) => (

docs/data/material/components/menus/LongMenu.tsx

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,6 @@ export default function LongMenu() {
4747
</IconButton>
4848
<Menu
4949
id="long-menu"
50-
MenuListProps={{
51-
'aria-labelledby': 'long-button',
52-
}}
5350
anchorEl={anchorEl}
5451
open={open}
5552
onClose={handleClose}
@@ -60,6 +57,9 @@ export default function LongMenu() {
6057
width: '20ch',
6158
},
6259
},
60+
list: {
61+
'aria-labelledby': 'long-button',
62+
},
6363
}}
6464
>
6565
{options.map((option) => (

docs/data/material/components/menus/SimpleListMenu.js

+5-3
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,11 @@ export default function SimpleListMenu() {
5555
anchorEl={anchorEl}
5656
open={open}
5757
onClose={handleClose}
58-
MenuListProps={{
59-
'aria-labelledby': 'lock-button',
60-
role: 'listbox',
58+
slotProps={{
59+
list: {
60+
'aria-labelledby': 'lock-button',
61+
role: 'listbox',
62+
},
6163
}}
6264
>
6365
{options.map((option, index) => (

docs/data/material/components/menus/SimpleListMenu.tsx

+5-3
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,11 @@ export default function SimpleListMenu() {
5858
anchorEl={anchorEl}
5959
open={open}
6060
onClose={handleClose}
61-
MenuListProps={{
62-
'aria-labelledby': 'lock-button',
63-
role: 'listbox',
61+
slotProps={{
62+
list: {
63+
'aria-labelledby': 'lock-button',
64+
role: 'listbox',
65+
},
6466
}}
6567
>
6668
{options.map((option, index) => (

0 commit comments

Comments
 (0)