From 5eadce061c7e5d0bb443650691276e346b259ff4 Mon Sep 17 00:00:00 2001 From: Mateusz Kwasniewski Date: Fri, 31 May 2024 13:40:35 +0200 Subject: [PATCH] feat: align list items on mode switch (#7229) --- .../NavigationSidebar/ListItems.tsx | 37 +++++++++---------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/frontend/src/component/layout/MainLayout/NavigationSidebar/ListItems.tsx b/frontend/src/component/layout/MainLayout/NavigationSidebar/ListItems.tsx index 22f86d8db012..d31d0024f38e 100644 --- a/frontend/src/component/layout/MainLayout/NavigationSidebar/ListItems.tsx +++ b/frontend/src/component/layout/MainLayout/NavigationSidebar/ListItems.tsx @@ -28,6 +28,15 @@ const CappedText = styled(Typography)({ maxWidth: '160px', }); +const StyledListItemIcon = styled(ListItemIcon)(({ theme }) => ({ + minWidth: theme.spacing(4), + margin: theme.spacing(0.25, 0), +})); + +const StyledListItemText = styled(ListItemText)(({ theme }) => ({ + margin: 0, +})); + export const FullListItem: FC<{ href: string; text: string; @@ -44,12 +53,10 @@ export const FullListItem: FC<{ sx={listItemButtonStyle} selected={selected} > - ({ minWidth: theme.spacing(4) })}> - {children} - - + {children} + {text} - + {badge} @@ -70,10 +77,8 @@ export const ExternalFullListItem: FC<{ href: string; text: string }> = ({ rel='noopener noreferrer' target='_blank' > - ({ minWidth: theme.spacing(4) })}> - {children} - - + {children} + ); @@ -83,12 +88,10 @@ export const SignOutItem = () => {
- ({ minWidth: theme.spacing(4) })} - > + - - + +
@@ -111,11 +114,7 @@ export const MiniListItem: FC<{ selected={selected} > - ({ minWidth: theme.spacing(4) })} - > - {children} - + {children}