Skip to content

Commit

Permalink
fix: move presence menu to leftmost position in navbar
Browse files Browse the repository at this point in the history
This is done because the number of people present changes over time, causing
occasional "jumping" when people enter/exit. With the changelog/warning button
to the left of the presence menu, you can end up in situations where you click
on the wrong thing by accident, since the layout shifts. It also causes less
of a layout shift on update.
  • Loading branch information
rexxars committed Sep 14, 2022
1 parent 673e81a commit d172946
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/sanity/src/studio/components/navbar/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,10 @@ export function Navbar(props: NavbarProps) {
{shouldRender.brandingCenter && <Box marginX={1}>{brandingComponent}</Box>}

<Flex align="center">
<Box marginRight={1}>
<PresenceMenu collapse={shouldRender.collapsedPresenceMenu} />
</Box>

{shouldRender.changelog && (
<Box marginRight={1}>
<ChangelogButton />
Expand All @@ -291,10 +295,6 @@ export function Navbar(props: NavbarProps) {
</Box>
)}

<Box marginRight={1}>
<PresenceMenu collapse={shouldRender.collapsedPresenceMenu} />
</Box>

{shouldRender.tools && (
<Box>
<UserMenu />
Expand Down

0 comments on commit d172946

Please sign in to comment.