Closed RoyBikram closed 1 year ago
// CustomDialog
const CustomDialog = (props) => {
return <Dialog {...props} {/* config... */}>/* … */</Dialog>
}
@supnate sorry for the late reply, but Material UI components receive theme from context not props. Here is a sandbox to replicate the issue: https://codesandbox.io/s/mui-theme-not-working-with-nice-modal-j272g1?file=/demo.tsx:808-1029
Running into this issue - is there a solution?
Edit: Looks like the fix is to use the declarative way of creating your Modals https://opensource.ebay.com/nice-modal-react/#declarative
When we use Nice Modal with the Material UI library the theming of MUI is not passed down to the Dialog.