diff --git a/app/courrier/page.tsx b/app/courrier/page.tsx index f3e98b4e..230a8a7c 100644 --- a/app/courrier/page.tsx +++ b/app/courrier/page.tsx @@ -58,7 +58,6 @@ import { formatForwardedEmail, formatReplyEmail, formatEmailForReplyOrForward, - formatEmailDate, // Add this import EmailMessage as FormatterEmailMessage, cleanHtmlContent } from '@/lib/utils/email-formatter'; @@ -340,6 +339,17 @@ const getFolderIcon = (folder: string) => { // 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 ''; + return new Intl.DateTimeFormat('fr-FR', { + day: '2-digit', + month: '2-digit', + year: 'numeric', + hour: '2-digit', + minute: '2-digit' + }).format(date); +} + /** * @deprecated This function is deprecated and will be removed in future versions. * Use the ReplyContent component directly instead. @@ -1392,7 +1402,7 @@ export default function CourrierPage() { )}
- {formatEmailDate(selectedEmail.date)} + {formatDate(new Date(selectedEmail.date))}
@@ -1441,7 +1451,7 @@ export default function CourrierPage() { )} - {formatEmailDate(email.date)} + {formatDate(new Date(email.date))}