Skip to content

Commit

Permalink
[default-layout] Improve layout of SideMenu
Browse files Browse the repository at this point in the history
  • Loading branch information
mariuslundgard authored and rexxars committed Oct 6, 2020
1 parent 12312a0 commit cb5c4d9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
:root {
--side-menu-color: var(--component-bg);
--side-menu-color-inverted: var(--component-text-color);
--side-menu-margin-right: 49px;
}

.root {
Expand All @@ -28,6 +29,7 @@
transform: translate(-100%);
pointer-events: all;
padding-left: env(safe-area-inset-left);
margin-right: var(--side-menu-margin-right);
}

.root.isOpen {
Expand All @@ -45,15 +47,17 @@
}

.closeButtonContainer {
padding: 4px;
padding: calc(var(--medium-padding) - var(--extra-small-padding));
}

.userProfile {
flex: 1;
min-width: 0;
display: flex;
align-items: center;
padding: 0.5em;
padding: calc(var(--medium-padding) - var(--extra-small-padding)) 0
calc(var(--medium-padding) - var(--extra-small-padding))
calc(var(--medium-padding) - var(--extra-small-padding));
}

.userAvatarContainer {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ function SideMenu(props: Props) {
icon={CloseIcon}
kind="simple"
onClick={onClose}
padding="small"
tabIndex={tabIndex}
title="Close menu"
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ function ToolMenu(props: Props) {
key={tool.name}
kind="simple"
onClick={onSwitchTool}
padding="small"
padding={direction === 'horizontal' ? 'small' : 'medium'}
selected={activeToolName === tool.name}
state={{...router.state, tool: tool.name, [tool.name]: undefined}}
title={title}
Expand Down

0 comments on commit cb5c4d9

Please sign in to comment.