diff --git a/src/components/Header/Header.jsx b/src/components/Header/Header.jsx index 1a44fdb..4ee13ff 100644 --- a/src/components/Header/Header.jsx +++ b/src/components/Header/Header.jsx @@ -7,7 +7,7 @@ function Header() { const [notificationMenu, setnotificationMenu] = useState(false); const [unreadNotification, setunreadNotification] = useState(true); const [mobileMenu, setMobileMenu] = useState(false); - const [notifications, setNotifications] = useState([]); + const [notifications, setNotifications] = useState([{"content" : "ok"}, {"content" : "pourquoi pas antoine"}]); const notificationRef = useRef(null); @@ -15,7 +15,10 @@ function Header() { useEffect(() => { async function loadNotifications() { const notifData = await getUserNotifications(); + /* setNotifications(notifData || []); + */ + } //loadNotifications(); @@ -105,7 +108,7 @@ function Header() { className={`${styles.notificationDiv} glassCard ${notificationMenu ? styles.activeNotificationDiv : ""}`} > {notifications.length === 0 ? ( -

Vous n'avez aucune notification !

+

Vous n'avez aucune notification !

) : ( notifications.map((notification, index) => (
@@ -114,9 +117,7 @@ function Header() { className={styles.closeBtn} onClick={() => setNotifications(prev => prev.filter((_, i) => i !== index))} > - - - + supprimer la notification
)) diff --git a/src/components/Header/Header.module.css b/src/components/Header/Header.module.css index 1aaa72b..c9ffc2b 100644 --- a/src/components/Header/Header.module.css +++ b/src/components/Header/Header.module.css @@ -175,10 +175,11 @@ } .notification{ - margin-bottom: 7%; + padding: 0.5em 1em; display: flex; justify-content: space-between; align-items: center; + border-radius: 15px; } .notificationBadge { diff --git a/src/components/SearchBar/SearchBar.module.css b/src/components/SearchBar/SearchBar.module.css index a58f1de..d35c808 100644 --- a/src/components/SearchBar/SearchBar.module.css +++ b/src/components/SearchBar/SearchBar.module.css @@ -31,7 +31,6 @@ .searchedEvent{ display: flex; padding: 0.5rem; - border-radius: 15px; align-items: center; }