From 0454c0d7e37f94acd25d6d427c67519181d07203 Mon Sep 17 00:00:00 2001 From: Anton Kulyk <kuliks.anton@gmail.com> Date: Mon, 4 Apr 2022 21:58:30 +0100 Subject: [PATCH] Fix collection menu padding (#21451) --- .../metabase/nav/containers/MainNavbar/MainNavbar.styled.tsx | 4 ++++ .../metabase/nav/containers/MainNavbar/MainNavbarView.tsx | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/frontend/src/metabase/nav/containers/MainNavbar/MainNavbar.styled.tsx b/frontend/src/metabase/nav/containers/MainNavbar/MainNavbar.styled.tsx index e6e43543b0d..d1730d181fe 100644 --- a/frontend/src/metabase/nav/containers/MainNavbar/MainNavbar.styled.tsx +++ b/frontend/src/metabase/nav/containers/MainNavbar/MainNavbar.styled.tsx @@ -77,6 +77,10 @@ export const CollectionsMoreIcon = styled(Icon)` color: ${color("text-medium")}; `; +export const CollectionMenuList = styled.ul` + padding: 0.5rem; +`; + export const LoadingContainer = styled.div` color: ${color("brand")}; text-align: center; diff --git a/frontend/src/metabase/nav/containers/MainNavbar/MainNavbarView.tsx b/frontend/src/metabase/nav/containers/MainNavbar/MainNavbarView.tsx index fce7a1777cf..c5334b7ec8d 100644 --- a/frontend/src/metabase/nav/containers/MainNavbar/MainNavbarView.tsx +++ b/frontend/src/metabase/nav/containers/MainNavbar/MainNavbarView.tsx @@ -25,6 +25,7 @@ import { BrowseLink, CollectionsMoreIconContainer, CollectionsMoreIcon, + CollectionMenuList, ProfileLinkContainer, SidebarContentRoot, SidebarHeading, @@ -141,7 +142,7 @@ function CollectionSectionHeading({ }: CollectionSectionHeadingProps) { const renderMenu = useCallback( ({ onClose }) => ( - <ul> + <CollectionMenuList> {currentUser.is_superuser && ( <SidebarLink icon={getCollectionIcon(PERSONAL_COLLECTIONS)} @@ -154,7 +155,7 @@ function CollectionSectionHeading({ <SidebarLink icon="view_archive" url={ARCHIVE_URL} onClick={onClose}> {t`View archive`} </SidebarLink> - </ul> + </CollectionMenuList> ), [currentUser], ); -- GitLab