From 7ca22e9de8a5eabb07c521548758994068f480d7 Mon Sep 17 00:00:00 2001 From: alma Date: Fri, 25 Apr 2025 19:18:26 +0200 Subject: [PATCH] panel 2 courier api restore --- app/courrier/page.tsx | 90 +++++++++++++++++++------------------------ 1 file changed, 39 insertions(+), 51 deletions(-) diff --git a/app/courrier/page.tsx b/app/courrier/page.tsx index 17aa6fc4..4b0d243a 100644 --- a/app/courrier/page.tsx +++ b/app/courrier/page.tsx @@ -271,15 +271,8 @@ const getFolderIcon = (folder: string) => { } }; -// Initial sidebar items - only INBOX -const initialSidebarItems = [ - { - view: 'INBOX' as MailFolder, - label: 'Inbox', - icon: Inbox, - folder: 'INBOX' - } -]; +// Update the initialSidebarItems to be empty since we're using folders under Accounts now +const initialSidebarItems: any[] = []; // Remove the default Inbox item function formatDate(date: Date | null): string { if (!date) return ''; @@ -1241,37 +1234,44 @@ export default function CourrierPage() { } }; - // Fix the sidebar navigation without the folders section and divider + // Update the renderSidebarNav function to handle empty items or display other navigation options const renderSidebarNav = () => ( ); @@ -1634,9 +1634,9 @@ export default function CourrierPage() { {account.folders && account.folders.length > 0 ? ( account.folders.map((folder) => (