calendar 40
This commit is contained in:
parent
c8effe3fa7
commit
c207f494c7
@ -1107,11 +1107,11 @@ export function CalendarClient({ initialCalendars, userId, userProfile }: Calend
|
||||
.filter(cal => visibleCalendarIds.includes(cal.id))
|
||||
.flatMap(cal =>
|
||||
(cal.events || []).map(event => ({
|
||||
id: event.id,
|
||||
title: event.title,
|
||||
id: event.id,
|
||||
title: event.title,
|
||||
start: new Date(event.start),
|
||||
end: new Date(event.end),
|
||||
allDay: event.isAllDay,
|
||||
allDay: event.isAllDay,
|
||||
description: event.description,
|
||||
location: event.location,
|
||||
calendarId: event.calendarId,
|
||||
@ -1122,19 +1122,20 @@ export function CalendarClient({ initialCalendars, userId, userProfile }: Calend
|
||||
location: event.location,
|
||||
description: event.description,
|
||||
calendarId: event.calendarId,
|
||||
originalEvent: event
|
||||
originalEvent: event,
|
||||
color: cal.color
|
||||
}
|
||||
}))
|
||||
)}
|
||||
eventContent={(arg) => (
|
||||
<div
|
||||
className="px-2 py-1 overflow-hidden w-full transition-all rounded-sm"
|
||||
className="px-2 py-1 overflow-hidden w-full transition-all rounded-sm hover:brightness-110"
|
||||
style={{
|
||||
backgroundColor: `${arg.event.backgroundColor}dd`, // Add transparency
|
||||
backgroundColor: `${arg.event.backgroundColor}`,
|
||||
boxShadow: `inset 0 0 0 1px ${arg.event.backgroundColor}, 0 1px 2px ${arg.event.backgroundColor}40`
|
||||
}}
|
||||
>
|
||||
<div className="flex items-center gap-1.5 text-xs">
|
||||
<div className="flex items-center gap-1.5 text-xs text-white">
|
||||
{!arg.event.allDay && (
|
||||
<span className="font-medium whitespace-nowrap">
|
||||
{new Date(arg.event.start).toLocaleTimeString('fr-FR', {
|
||||
@ -1151,7 +1152,7 @@ export function CalendarClient({ initialCalendars, userId, userProfile }: Calend
|
||||
)}
|
||||
eventClassNames={(arg) => [
|
||||
'hover:ring-2 hover:ring-offset-1',
|
||||
'transition-all duration-200',
|
||||
'transition-all duration-150',
|
||||
arg.event.allDay ? 'py-1' : ''
|
||||
]}
|
||||
locale={frLocale}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user