From a3f5f2e116858865b9ee49beca33843682c22f74 Mon Sep 17 00:00:00 2001 From: Kentai Radiquum Date: Tue, 16 Jul 2024 05:43:46 +0500 Subject: [PATCH] refactor: navbar - make user profile consistent with links. --- app/components/Navbar/Navbar.jsx | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/app/components/Navbar/Navbar.jsx b/app/components/Navbar/Navbar.jsx index 8cb1e83..418f6f9 100644 --- a/app/components/Navbar/Navbar.jsx +++ b/app/components/Navbar/Navbar.jsx @@ -34,7 +34,7 @@ export const Navbar = () => { title: "Закладки", href: "/bookmarks", withAuthOnly: true, - mobileMenu: true, + mobileMenu: false, }, { id: 4, @@ -66,7 +66,11 @@ export const Navbar = () => { key={link.id} href={link.href} className={`flex-col items-center sm:flex-row ${ - link.mobileMenu ? "hidden sm:flex" : "flex" + link.withAuthOnly && !userStore.isAuth + ? "hidden" + : link.mobileMenu + ? "hidden sm:flex" + : "flex" }`} > { })} {userStore.isAuth ? ( -
- -

{userStore.user.login}

+
+ +

{userStore.user.login}

) : (