Skip to content

Commit

Permalink
Change LogIn and SignUp button to turn red on hover
Browse files Browse the repository at this point in the history
  • Loading branch information
neetidesai committed Sep 24, 2024
1 parent 3e3a950 commit d20b4b2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions apps/frontend/src/pages/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ function Navbar() {
const [selected, setSelected] = useState(false);
const [showSignupPopup, setShowSignupPopup] = useState(false);
const [showSidePanel, setShowSidePanel] = useState(false);

const [logInHovered, setLogInHovered] = useState(false);
const [signUpHovered, setSignUpHovered] = useState(false);

const openSignupPopup = () => {
setShowSignupPopup(true);
Expand Down Expand Up @@ -62,9 +63,11 @@ function Navbar() {
<img src={c4cLogo} />
<div style={{ marginRight: 0, marginLeft: 'auto' }}>
<button
onMouseEnter={() => setSignUpHovered(true)}
onMouseLeave={() => setSignUpHovered(false)}
style={{
font: 'Montserrat',
color: selected ? 'red' : 'black',
color: signUpHovered ? 'red' : 'black',
background: 'none',
border: 'none',
padding: 0,
Expand All @@ -77,9 +80,11 @@ function Navbar() {
</button>
<Link to="/login" style={{ textDecoration: 'none' }}></Link>
<button
onMouseEnter={() => setLogInHovered(true)}
onMouseLeave={() => setLogInHovered(false)}
style={{
font: 'Montserrat',
color: 'black',
color: logInHovered ? 'red' : 'black',
background: 'none',
border: 'none',
padding: 0,
Expand Down

0 comments on commit d20b4b2

Please sign in to comment.