+
{fmtHour(h)}
+
-
-
- ))}
- {/* Event blocks — absolutely positioned */}
- {day.map(e=>{
- const s=new Date(e.start_at), en=new Date(e.end_at);
- const top=eventTopOffset(s), height=eventHeightPx(s,en);
- return(
-
onSelect(e)} style={{
- position:'absolute', left:64, right:8,
- top, height,
- background:e.event_type?.colour||'#6366f1', color:'white',
- borderRadius:5, padding:'3px 8px', cursor:'pointer',
- fontSize:12, fontWeight:600, overflow:'hidden',
- boxShadow:'0 1px 3px rgba(0,0,0,0.2)',
- }}>
-
{e.title}
- {height>32&&
{fmtRange(e.start_at,e.end_at)}
}
-
- );
- })}
+ ))}
+ {day.map(e=>{
+ const s=new Date(e.start_at), en=new Date(e.end_at);
+ const top=eventTopOffset(s), height=eventHeightPx(s,en);
+ return(
+
onSelect(e)} style={{
+ position:'absolute', left:64, right:8,
+ top, height,
+ background:e.event_type?.colour||'#6366f1', color:'white',
+ borderRadius:5, padding:'3px 8px', cursor:'pointer',
+ fontSize:12, fontWeight:600, overflow:'hidden',
+ boxShadow:'0 1px 3px rgba(0,0,0,0.2)',
+ }}>
+
{e.title}
+ {height>32&&
{fmtRange(e.start_at,e.end_at)}
}
+
+ );
+ })}
+