diff --git a/components/NavBar/index.js b/components/NavBar/index.js index 7761e1b..51b8619 100644 --- a/components/NavBar/index.js +++ b/components/NavBar/index.js @@ -7,6 +7,8 @@ import GenericClosePopUp from '../Close-popup/GenericClosePopUp'; const NavBar = ({ personData: { photo } }) => { const RDSLogo = '/assets/Real-Dev-Squad1x.png'; const [toggle, setToggle] = useState(false); + const [count, setCount] = useState(15); + const navbarRef = useRef(); GenericClosePopUp(navbarRef, () => { setToggle(false); @@ -51,11 +53,11 @@ const NavBar = ({ personData: { photo } }) => { toggle ? styles.dropdownContent : styles.dropdownContentHide } > - Link 1 - Link 2 - Link 3 - Link 4 - Link 5 + Profile + Notifications {count} + Setting + Orders + Log Out diff --git a/components/NavBar/navbar.module.css b/components/NavBar/navbar.module.css index e4f1198..4132e06 100644 --- a/components/NavBar/navbar.module.css +++ b/components/NavBar/navbar.module.css @@ -54,17 +54,25 @@ } .dropdownContent a { color: black; - padding: 5px 0; + padding: 5px 4px; text-decoration: none; text-align: center; - font-size: 18px; + font-size: 14px; border-bottom: 1px solid rgba(0, 0, 0, 0.26); display: block; } .dropdownContent a:hover { background-color: #e4e2e2 } - +.notificationNumbers{ + background-color: #041484; + color: white; + border: none; + border-radius: 50%; + padding: .3em; + font-size: .8em; + text-align: center; +} @media (max-width: 540px) { .navBar li { diff --git a/mock/notifications.json b/mock/notifications.json new file mode 100644 index 0000000..56c1752 --- /dev/null +++ b/mock/notifications.json @@ -0,0 +1,20 @@ +[ + { + "notification": "Rohit has requested RDS 200 from you" + }, + { + "notification": "Rohit has requested RDS 200 from you" + }, + { + "notification": "Rohit has requested RDS 200 from you" + }, + { + "notification": "Rohit has requested RDS 200 from you" + }, + { + "notification": "Rohit has requested RDS 200 from you" + }, + { + "notification": "Rohit has requested RDS 200 from you" + } +] diff --git a/pages/notification.js b/pages/notification.js new file mode 100644 index 0000000..2085832 --- /dev/null +++ b/pages/notification.js @@ -0,0 +1,86 @@ +import React from 'react'; +import personData from '../mock/person.json'; +import NavBar from '@components/NavBar'; +import data from '../mock/notifications.json'; + +export default function notification() { + return ( +