import { useState } from "react"; import { Check, Download, Info } from "lucide-react"; import { LuFileSpreadsheet } from "react-icons/lu"; // Alternatif icon task dari react-icons const initialNotifications = [ { id: 1, type: "new-task", title: "New Task Assigned", time: "Just now", isNew: true, group: "TODAY", description: "Mentor Sarah Johnson has pushed a new task: User Persona Analysis" }, { id: 2, type: "achievement", title: "Certificate Ready", time: "2 hours ago", isNew: false, group: "TODAY", description: "Your certificate for UI Engineering Phase 1 is now available for download!" }, { id: 3, type: "system", title: "System Maintenance", time: "2 days ago", isNew: false, group: "YESTERDAY", description: "Internify will undergo scheduled maintenance this Sunday from 02:00 AM to 04:00 AM GMT+7." } ]; export default function NotificationList() { const [notifications, setNotifications] = useState(initialNotifications); const handleMarkAllRead = () => { setNotifications(prev => prev.map(n => ({ ...n, isNew: false }))); alert("All notifications marked as read!"); }; return (
Keep track of your interns' progress and system updates.
{item.type === 'new-task' ? ( <>Mentor Sarah Johnson has pushed a new task: User Persona Analysis> ) : item.type === 'achievement' ? ( <>Your certificate for UI Engineering Phase 1 is now available for download!> ) : item.description}
{/* Conditional Actions */} {item.type === 'new-task' && ({item.description}