diff --git a/frontend/src/components/navbar/index.js b/frontend/src/components/navbar/index.js index b827d0e5..865ff37e 100644 --- a/frontend/src/components/navbar/index.js +++ b/frontend/src/components/navbar/index.js @@ -65,7 +65,7 @@ class Navbar extends Component { return ( - {path} + {path} ); @@ -74,7 +74,7 @@ class Navbar extends Component { return ( - {path} + {path} ); @@ -83,7 +83,13 @@ class Navbar extends Component { let formattedPath = path.toLowerCase().replace(/ /g, "-"); return ( - {path === "" ? "Home" : path} + + {path === "" ? ( + {"Home"} + ) : ( + {path} + )} + ); }); diff --git a/frontend/src/styles/partials/_navbar.scss b/frontend/src/styles/partials/_navbar.scss index 32b3b265..79aab265 100644 --- a/frontend/src/styles/partials/_navbar.scss +++ b/frontend/src/styles/partials/_navbar.scss @@ -73,6 +73,8 @@ color: $secondary-color; } + + a { display: block; padding: 0.5 * $gutter-width 0 0.5 * $gutter-width 0; @@ -136,3 +138,27 @@ } } + .hover-underline-animation { + display: inline-block; + position: relative; + + margin-top: -80px; + } + + .hover-underline-animation::after { + content: ''; + position: absolute; + width: 100%; + transform: scaleX(0); + height: 2px; + bottom: 0; + left: 0; + background-color: $secondary-color; + transform-origin: bottom right; + transition: transform 0.25s ease-out; + } + + .hover-underline-animation:hover::after { + transform: scaleX(1); + transform-origin: bottom left; + } \ No newline at end of file