Skip to content

Commit

Permalink
Add navbar height variable and plug it to everything I've adjusted fo…
Browse files Browse the repository at this point in the history
…r bottom height lately
  • Loading branch information
SteveMicroNova committed Jan 7, 2025
1 parent ea63b91 commit bc40327
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion web/src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ const App = ({ selectedPage }) => {
return (
<div className="app">
<DisconnectedIcon />
<div style={{ paddingBottom: "56px" }}>
<div className="app-body">
<Page selectedPage={selectedPage} />
</div>
<MenuBar pageNumber={selectedPage} />
Expand Down
4 changes: 4 additions & 0 deletions web/src/App.scss
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,7 @@
height: 100vh;
background-color: green;
}

.app-body {
padding-bottom: general.$navbar-height
}
1 change: 1 addition & 0 deletions web/src/components/MenuBar/MenuBar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@
z-index: 1; // The Marquees on player cards appeared above the MenuBar otherwise, the MenuBar needs to be on top of everything always
bottom: 0;
width: 100vw;
height: general.$navbar-height;
@include general.low-shadow-up;
}
2 changes: 1 addition & 1 deletion web/src/components/StatusBars/StatusBar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default function StatusBar(props) {

return(
<Snackbar
style={{bottom: "60px"}}
className="snackbar"
autoHideDuration={3000}
anchorOrigin={{vertical: "bottom", horizontal: "left"}}
open={open}
Expand Down
4 changes: 4 additions & 0 deletions web/src/components/StatusBars/StatusBars.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,7 @@
--right: translate(5px, 0px);
animation: errorShake 0.5s 1; // Only animate once, reapplying the class will reapply the animation
}

.snackbar {
bottom: calc(general.$navbar-height + 4px)
}
1 change: 1 addition & 0 deletions web/src/general.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ $select-color-gray: #bdbdbd; // for preset used_last
$mute-color: #dc3545;

$page-header-height: 3rem;
$navbar-height: 56px;

// fonts
@font-face {
Expand Down

0 comments on commit bc40327

Please sign in to comment.