diff --git a/src/components/Navbar.js b/src/components/Navbar.js index cd53712..fb0a2a5 100644 --- a/src/components/Navbar.js +++ b/src/components/Navbar.js @@ -1,4 +1,4 @@ -import React from 'react' +import React, { useState } from 'react'; import { Link, useLocation } from 'react-router-dom'; import "../includes/css/navbar.css" import logo from "../includes/images/aks.png" @@ -6,6 +6,8 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; import { faLaptop,faCircleInfo, faContactBook, faHome, faLaptopCode, faTimeline } from '@fortawesome/free-solid-svg-icons'; const Navbar = () => { + const [isShown, setIsShown] = useState(false); + const location = useLocation(); @@ -34,8 +36,11 @@ const Navbar = () => { return ( -
-
+
+
setIsShown(true)} + onMouseLeave={() => setIsShown(false)} + className="sticky navbar bg-slate-800 flex items-center md:justify-content-start md:items-start justify-between px-2 md:px-0 md:justify-center h-[80px] md:h-[100vh] shadow-sm md:shadow-lg shadow-gray-800"> diff --git a/src/pages/Home.js b/src/pages/Home.js index 0ee6817..ac3d73f 100644 --- a/src/pages/Home.js +++ b/src/pages/Home.js @@ -11,7 +11,7 @@ const Home = () => { return ( -
+