Closed Ian-Harrington closed 1 year ago
Hi, so https://github.com/material-table-core/core/blob/master/src/components/MTableToolbar/index.js#L184 this style just takes our styling, which is not the passed but generated by us. The classes are just used for the outer most wrapper. How would you propose to pass items to each child Menuitem?
Understood. I'm new to React and don't have sufficient experience to suggest an implementation that is robust/extensible enough to include in this package.
For my own purposes I ended up creating a custom show/hide menu component with the desired styling which I included in the toolbar. Some thoughts that might be helpful to others with similar issues:
Thanks for the reply.
How to style show/hide columns menu?
I am looking to style the items within the popover menu for the default action "columnsButton". From the source code here, I'd expect that passing styling for "formControlLabel" to an overridden Toolbar component would be propagated to elements within the popover menu. Doing so in the codesandbox, the searchField and showColumns action icon can be styled, but no change is seen in the menu styling. What am I missing to style the checkboxes and text in the menu?
codesandbox: https://codesandbox.io/s/material-table-starter-template-forked-iwtjhm?file=/src/index.js