From 2156e3452e72ee97dd746374afa55f75843b97a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ver=C3=B3nica=20Mil=C3=A1n?= Date: Fri, 26 Jul 2024 13:26:17 +0200 Subject: [PATCH] Mui v5 fix styles to upgrade to the latest stable version (#892) --- CHANGELOG.md | 1 + packages/react-ui/src/theme/sections/components/forms.js | 3 ++- packages/react-ui/src/theme/sections/components/navigation.js | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1a1cbbb0d..b6beadc06 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Not released +- Mui v5 fix styles to upgrade to the latest stable version [#892](https://github.com/CartoDB/carto-react/pull/892) - fix legend widget return bug [#893](https://github.com/CartoDB/carto-react/pull/893) ## 3.0.0 diff --git a/packages/react-ui/src/theme/sections/components/forms.js b/packages/react-ui/src/theme/sections/components/forms.js index c415db3f8..f820a26bb 100644 --- a/packages/react-ui/src/theme/sections/components/forms.js +++ b/packages/react-ui/src/theme/sections/components/forms.js @@ -511,7 +511,7 @@ export const formsOverrides = { right: theme.spacing(2), color: theme.palette.text.secondary }, - '&.Mui-disabled .MuiSelect-icon': { + '&.Mui-disabled .MuiSelect-icon, &.Mui-readOnly .MuiSelect-icon': { color: theme.palette.text.disabled }, '& .MuiSelect-iconStandard': { @@ -661,6 +661,7 @@ export const formsOverrides = { }), endAdornment: ({ theme }) => ({ + transform: 'none', top: theme.spacing(2), display: 'flex', alignItems: 'center', diff --git a/packages/react-ui/src/theme/sections/components/navigation.js b/packages/react-ui/src/theme/sections/components/navigation.js index 8770c258d..d509ae8f0 100644 --- a/packages/react-ui/src/theme/sections/components/navigation.js +++ b/packages/react-ui/src/theme/sections/components/navigation.js @@ -129,7 +129,7 @@ export const navigationOverrides = { root: ({ theme }) => ({ paddingTop: 0, - '.MuiPopover-root &, .MuiPopper-root &': { + '.MuiPopover-root &, .MuiPopper-root &, .MuiPaper-root &': { minWidth: theme.spacing(8), // 64px, defined by design maxHeight: theme.spacing(39), // 312px, defined by design overflowY: 'auto',