From e7042e601ca86b8693f1f42b3b7f6f020cdd982b Mon Sep 17 00:00:00 2001 From: Bruno Quaresma Date: Tue, 3 Oct 2023 14:10:51 -0300 Subject: [PATCH] fix(site): fix navbar hover (#10021) --- .../Dashboard/Navbar/NavbarView.tsx | 73 +++++++++---------- 1 file changed, 33 insertions(+), 40 deletions(-) diff --git a/site/src/components/Dashboard/Navbar/NavbarView.tsx b/site/src/components/Dashboard/Navbar/NavbarView.tsx index e600c5d2ff..ae46a3f403 100644 --- a/site/src/components/Dashboard/Navbar/NavbarView.tsx +++ b/site/src/components/Dashboard/Navbar/NavbarView.tsx @@ -1,7 +1,5 @@ import Drawer from "@mui/material/Drawer"; import IconButton from "@mui/material/IconButton"; -import List from "@mui/material/List"; -import ListItem from "@mui/material/ListItem"; import MenuIcon from "@mui/icons-material/Menu"; import { CoderIcon } from "components/Icons/CoderIcon"; import { type FC, type ReactNode, useRef, useState } from "react"; @@ -108,12 +106,17 @@ const styles = { text-decoration: none; transition: background-color 0.15s ease-in-out; + &.active { + color: ${theme.palette.text.primary}; + font-weight: 500; + } + &:hover { - background-color: theme.palette.action.hover; + background-color: ${theme.palette.action.hover}; } ${theme.breakpoints.up("md")} { - height: ${navHeight}; + height: ${navHeight}px; padding: 0 ${theme.spacing(3)}; } `, @@ -134,48 +137,38 @@ const NavItems: React.FC = (props) => { const theme = useTheme(); return ( - - - - {Language.workspaces} - - - - - {Language.templates} - - + ); }; export const NavbarView: FC = ({