From 9a5cc484b7ea8ac3e191f7c347f2c93e523a2743 Mon Sep 17 00:00:00 2001 From: Madhura68 Date: Sun, 26 Apr 2026 18:02:38 +0200 Subject: [PATCH] feat: center product name in navbar Three-section layout (flex-1 left, center, flex-1 right) keeps the product name truly centered regardless of sidebar content. Co-Authored-By: Claude Sonnet 4.6 --- components/shared/nav-bar.tsx | 113 ++++++++++++++++++---------------- 1 file changed, 59 insertions(+), 54 deletions(-) diff --git a/components/shared/nav-bar.tsx b/components/shared/nav-bar.tsx index 5ca2abc..dcee6ab 100644 --- a/components/shared/nav-bar.tsx +++ b/components/shared/nav-bar.tsx @@ -44,47 +44,69 @@ export function NavBar({ isDemo, roles }: NavBarProps) { ] return ( -
- {/* Logo */} - - - Scrum4Me - {isDemo && ( - - Demo - - )} - +
+ {/* Links: logo + nav */} +
+ + + Scrum4Me + {isDemo && ( + + Demo + + )} + - {/* Nav links */} -
+ + {/* Midden: productnaam */} +
+ {currentProduct && ( + + + + }> + {currentProduct.name.length > 20 + ? currentProduct.name.slice(0, 20) + '…' + : currentProduct.name} + + {currentProduct.name} + + )} - +
{/* Rechts: rollen + instellingen + uitloggen */} -
+
{roles.length > 0 && ( @@ -97,23 +119,6 @@ export function NavBar({ isDemo, roles }: NavBarProps) { )} - {currentProduct && ( - - - - }> - {currentProduct.name.length > 20 - ? currentProduct.name.slice(0, 20) + '…' - : currentProduct.name} - - {currentProduct.name} - - - )}