import React from "react"; // components import { CustomMenu } from "components/ui"; import { ArchiveIcon, Tooltip } from "@plane/ui"; //icon import { ArrowLeft, CheckCheck, Clock, ListFilter, MoreVertical, RefreshCw, X } from "lucide-react"; // helpers import { getNumberCount } from "helpers/string.helper"; // type import type { NotificationType, NotificationCount } from "types"; type NotificationHeaderProps = { notificationCount?: NotificationCount | null; notificationMutate: () => void; closePopover: () => void; isRefreshing?: boolean; snoozed: boolean; archived: boolean; readNotification: boolean; selectedTab: NotificationType; setSnoozed: React.Dispatch>; setArchived: React.Dispatch>; setReadNotification: React.Dispatch>; setSelectedTab: React.Dispatch>; markAllNotificationsAsRead: () => Promise; }; export const NotificationHeader: React.FC = (props) => { const { notificationCount, notificationMutate, closePopover, isRefreshing, snoozed, archived, readNotification, selectedTab, setSnoozed, setArchived, setReadNotification, setSelectedTab, markAllNotificationsAsRead, } = props; const notificationTabs: Array<{ label: string; value: NotificationType; unreadCount?: number; }> = [ { label: "My Issues", value: "assigned", unreadCount: notificationCount?.my_issues, }, { label: "Created by me", value: "created", unreadCount: notificationCount?.created_issues, }, { label: "Subscribed", value: "watching", unreadCount: notificationCount?.watching_issues, }, ]; return ( <>

Notifications

} >
Mark all as read
{ setArchived(false); setReadNotification(false); setSnoozed((prev) => !prev); }} >
Show snoozed
{ setSnoozed(false); setReadNotification(false); setArchived((prev) => !prev); }} >
Show archived
{snoozed || archived || readNotification ? ( ) : ( )}
); };