From 04074f434ef1e83490dab490cf0152c217523b30 Mon Sep 17 00:00:00 2001 From: Kalle <38327916+Sendouc@users.noreply.github.com> Date: Fri, 29 Jul 2022 20:59:09 +0300 Subject: [PATCH] Change flatMap -> map with fragments in event list --- TODO.md | 2 + app/routes/calendar/index.tsx | 145 +++++++++++++++++----------------- 2 files changed, 73 insertions(+), 74 deletions(-) diff --git a/TODO.md b/TODO.md index 161e5db88..daeb92346 100644 --- a/TODO.md +++ b/TODO.md @@ -20,6 +20,8 @@ Calendar ## Other +- [ ] Avatar (?) can have class attribute in DOM without value +- [x] flatMap -> React.fragment - [ ] Event page layout shift with time not taking space before mount (only if one day) - [x] WeekLinks make opaque blocks not take space on mobile - [x] Type problem with Avatar diff --git a/app/routes/calendar/index.tsx b/app/routes/calendar/index.tsx index 3ba2e7025..904ee9f18 100644 --- a/app/routes/calendar/index.tsx +++ b/app/routes/calendar/index.tsx @@ -269,84 +269,81 @@ function EventsList() {
- {events.flatMap((calendarEvent, i) => { - return [ -
-
-
-
, - i < events.length - 1 ? ( -
- ) : null, - ]; + + ); })}