From dc6f7f1a836744d964ffc2484324094d47b942d3 Mon Sep 17 00:00:00 2001 From: Sabir Hassan Date: Thu, 29 Feb 2024 12:05:05 +0500 Subject: [PATCH] chore: fix appBar --- .gitignore | 2 + src/components/AppBar/AppBar.tsx | 133 +++++++++++------------- src/components/AppBar/style.module.scss | 54 +++------- 3 files changed, 79 insertions(+), 110 deletions(-) diff --git a/.gitignore b/.gitignore index a547bf3..d7de12f 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,8 @@ dist dist-ssr *.local +.env + # Editor directories and files .vscode/* !.vscode/extensions.json diff --git a/src/components/AppBar/AppBar.tsx b/src/components/AppBar/AppBar.tsx index 5e95007..8b1227a 100644 --- a/src/components/AppBar/AppBar.tsx +++ b/src/components/AppBar/AppBar.tsx @@ -64,91 +64,80 @@ export const AppBar = () => { return ( - - -
- Logo navigate('/')} /> -
- - {!isAuthenticated && ( - - - - )} + + + Logo navigate('/')} /> - {authState?.loggedIn && ( -
- - + {!isAuthenticated && ( +
- )} + + + )} +
) diff --git a/src/components/AppBar/style.module.scss b/src/components/AppBar/style.module.scss index 7423310..09f35bd 100644 --- a/src/components/AppBar/style.module.scss +++ b/src/components/AppBar/style.module.scss @@ -3,54 +3,32 @@ .AppBar { background-color: $background-color !important; z-index: 1400 !important; + height: 60px; + flex-direction: row !important; + align-items: center; - .AppBarIcon { - background-color: $btn-background-color !important; - margin-right: 10px; + .toolbar { + flex-grow: 1; + display: flex; + align-items: center; } .logoWrapper { - display: flex; - align-items: center; - height: 100%; - padding: 13px 0 13px 0; - box-sizing: border-box; - } - - .AppBarLogoWrapper { - height: 60px; + height: 50px; width: 100px; - cursor: pointer; - justify-content: center; + display: flex; align-items: center; + cursor: pointer; - .logoWrapper { - margin-left: 20px; - - img { - max-height: 100%; - max-width: 150px; - } + img { + max-height: 100%; + max-width: 150px; } } - .AppBarUnAuth { - height: 60px; - cursor: pointer; - justify-content: space-between; - align-items: center; + .rightSideBox { + flex-grow: 1; display: flex; - width: 100%; - - .logoWrapper { - img { - max-height: 100%; - max-width: 120px; - } - } - - .loginBtn { - margin-right: 16px; - } + justify-content: flex-end; } }