material-ui icon indicating copy to clipboard operation
material-ui copied to clipboard

Menu autowidth ends up overflowing

Open totopia opened this issue 11 years ago • 3 comments

https://github.com/callemall/material-ui/blob/master/src/js/menu/menu.jsx <Menu menuItems={filterMenuItems} /> With autowidth on iPhone6, it's somehow possible to get width: 384px; And that made it going to outbound. Is there an option to have width at 100%?

totopia avatar Mar 25 '15 17:03 totopia

I ended up doing the following as a work around

.mui-menu {width: 100% !important;}

anuragsimgeker avatar Apr 12 '15 18:04 anuragsimgeker

I also found an undocumented prop autoWidth which also worked

<Menu autoWidth={false} menuItems={filterMenuItems} />

anuragsimgeker avatar Apr 13 '15 22:04 anuragsimgeker

Hi @totopia and @anuragsimgeker, I'm sorry about the late reply. The autoWidth has been documented and will be included when the v0.8.0 is released. It is the proper way to prevent menus from using the hard-coded width of 264px.

mmrtnz avatar May 14 '15 00:05 mmrtnz