From 5975421889f2cdf31f353deb0b401ddfc78b86c4 Mon Sep 17 00:00:00 2001 From: thomaspblock Date: Fri, 19 Jun 2026 11:37:10 -0400 Subject: [PATCH] fix(desktop): align sidebar unread pills (#1138) --- .../src/features/sidebar/ui/AppSidebar.tsx | 125 +++++++++--------- .../features/sidebar/ui/MoreUnreadButton.tsx | 5 +- desktop/src/shared/ui/UnreadPill.tsx | 2 +- 3 files changed, 64 insertions(+), 68 deletions(-) diff --git a/desktop/src/features/sidebar/ui/AppSidebar.tsx b/desktop/src/features/sidebar/ui/AppSidebar.tsx index 8c2a8a8b9..24dd20f7b 100644 --- a/desktop/src/features/sidebar/ui/AppSidebar.tsx +++ b/desktop/src/features/sidebar/ui/AppSidebar.tsx @@ -229,15 +229,6 @@ export function AppSidebar({ React.useState(false); const showSidebarUpdateCard = canShowSidebarUpdateCard && !isSidebarUpdateCardDismissed; - const sidebarFooterCardCount = - (sidebarRelayConnectionCard.showSidebarRelayConnectionCard ? 1 : 0) + - (showSidebarUpdateCard ? 1 : 0); - const unreadBelowBottomClass = - sidebarFooterCardCount >= 2 - ? "bottom-56" - : sidebarFooterCardCount >= 1 - ? "bottom-44" - : "bottom-24"; const [isNewDmOpenInternal, setIsNewDmOpenInternal] = React.useState(false); const isNewDmOpen = isNewDmOpenProp ?? isNewDmOpenInternal; const setIsNewDmOpen = onNewDmOpenChange ?? setIsNewDmOpenInternal; @@ -776,64 +767,66 @@ export function AppSidebar({ ) : null} - {unreadBelowCount > 0 ? ( - - ) : null} - - - - {sidebarRelayConnectionCard.showSidebarRelayConnectionCard ? ( - - ) : null} - - {showSidebarUpdateCard ? ( -
- setIsSidebarUpdateCardDismissed(true)} - /> -
+
+ {unreadBelowCount > 0 ? ( + ) : null} - - - - - - + + + + {sidebarRelayConnectionCard.showSidebarRelayConnectionCard ? ( + + ) : null} + + {showSidebarUpdateCard ? ( +
+ setIsSidebarUpdateCardDismissed(true)} + /> +
+ ) : null} + + + + + +
+