Fondation

This commit is contained in:
alma 2026-01-17 00:35:19 +01:00
parent 79ed31e4f4
commit fb671bf06c

View File

@ -56,6 +56,14 @@ import { Checkbox } from "@/components/ui/checkbox";
// Register French locale
registerLocale('fr', fr);
// Helper function to clean description by removing Microsoft ID prefix
const cleanDescription = (description: string | null | undefined): string | null => {
if (!description) return null;
// Remove [MS_ID:xxx] prefix if present
const cleaned = description.replace(/^\[MS_ID:[^\]]+\]\n?/, '');
return cleaned.trim() || null;
};
// Predefined professional color palette
const colorPalette = [
"#4f46e5", // Indigo
@ -1239,14 +1247,6 @@ export function CalendarClient({ initialCalendars, userId, userProfile }: Calend
}
};
// Helper function to clean description by removing Microsoft ID prefix
const cleanDescription = (description: string | null | undefined): string | null => {
if (!description) return null;
// Remove [MS_ID:xxx] prefix if present
const cleaned = description.replace(/^\[MS_ID:[^\]]+\]\n?/, '');
return cleaned.trim() || null;
};
const getCalendarDisplayName = (calendar: CalendarWithMission) => {
// If calendar is synced to an external account, use the same display name as in courrier
if (calendar.syncConfig?.syncEnabled && calendar.syncConfig?.mailCredential) {