From 1bb63d761444442822deffe8825cf4d25bd6e45e Mon Sep 17 00:00:00 2001 From: Samuel Newman Date: Fri, 15 May 2026 16:58:56 +0300 Subject: [PATCH] don't offset leftnav when ageassured --- src/view/shell/desktop/LeftNav.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/view/shell/desktop/LeftNav.tsx b/src/view/shell/desktop/LeftNav.tsx index 5ce5f9e696..37c32f231a 100644 --- a/src/view/shell/desktop/LeftNav.tsx +++ b/src/view/shell/desktop/LeftNav.tsx @@ -625,7 +625,12 @@ export function DesktopLeftNav({routeName}: {routeName: string}) { const {_} = useLingui() const t = useTheme() const {gtMobile} = useBreakpoints() - const isMessagesRelatedScreen = routeName.startsWith('Messages') + + const aa = useAgeAssurance() + // splitview uses the minimal variant of the leftnav. unfortunately there's no easy + // way to thread this data through because of the view hierarchy, so just check the route name + const isMessagesRelatedScreen = + routeName.startsWith('Messages') && aa.state.access === aa.Access.Full const {leftNavMinimal: leftNavMinimalBreakpoint, centerColumnOffset} = useLayoutBreakpoints() const numUnreadNotifications = useUnreadNotifications()