mirror of
https://github.com/coder/coder.git
synced 2025-07-12 00:14:10 +00:00
fix: show notifications on mobile (#17008)
Show the notifications close to the menu button. **After fix:** <img width="515" alt="Screenshot 2025-03-19 at 15 09 36" src="https://github.com/user-attachments/assets/38f86c5b-d324-4a8b-9c68-ea818b226ae4" />
This commit is contained in:
@ -67,9 +67,8 @@ export const MobileMenu: FC<MobileMenuProps> = ({
|
|||||||
<DropdownMenuTrigger asChild>
|
<DropdownMenuTrigger asChild>
|
||||||
<Button
|
<Button
|
||||||
aria-label={open ? "Close menu" : "Open menu"}
|
aria-label={open ? "Close menu" : "Open menu"}
|
||||||
size="lg"
|
size="icon-lg"
|
||||||
variant="subtle"
|
variant="subtle"
|
||||||
className="ml-auto md:hidden"
|
|
||||||
>
|
>
|
||||||
{open ? <XIcon /> : <MenuIcon />}
|
{open ? <XIcon /> : <MenuIcon />}
|
||||||
</Button>
|
</Button>
|
||||||
|
@ -67,6 +67,17 @@ export const NavbarView: FC<NavbarViewProps> = ({
|
|||||||
canViewHealth={canViewHealth}
|
canViewHealth={canViewHealth}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
{user && (
|
||||||
|
<UserDropdown
|
||||||
|
user={user}
|
||||||
|
buildInfo={buildInfo}
|
||||||
|
supportLinks={supportLinks}
|
||||||
|
onSignOut={onSignOut}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="ml-auto flex items-center gap-3 md:hidden">
|
||||||
<NotificationsInbox
|
<NotificationsInbox
|
||||||
fetchNotifications={API.getInboxNotifications}
|
fetchNotifications={API.getInboxNotifications}
|
||||||
markAllAsRead={() => {
|
markAllAsRead={() => {
|
||||||
@ -79,16 +90,6 @@ export const NavbarView: FC<NavbarViewProps> = ({
|
|||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
{user && (
|
|
||||||
<UserDropdown
|
|
||||||
user={user}
|
|
||||||
buildInfo={buildInfo}
|
|
||||||
supportLinks={supportLinks}
|
|
||||||
onSignOut={onSignOut}
|
|
||||||
/>
|
|
||||||
)}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<MobileMenu
|
<MobileMenu
|
||||||
proxyContextValue={proxyContextValue}
|
proxyContextValue={proxyContextValue}
|
||||||
user={user}
|
user={user}
|
||||||
@ -100,6 +101,7 @@ export const NavbarView: FC<NavbarViewProps> = ({
|
|||||||
canViewHealth={canViewHealth}
|
canViewHealth={canViewHealth}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user