- {Object.keys(eventsByDate)
- .filter((yearMonth) => visibleYearMonths.includes(yearMonth))
- .map((yearMonth) => (
-
-
{formatYearMonth(yearMonth)}
- {Object.keys(eventsByDate[yearMonth]).map((week) => (
-
- {Object.keys(eventsByDate[yearMonth][week]).map((day) => (
-
- ))}
-
- ))}
-
- ))}
+ {Object.keys(eventsByDate).map((yearMonth) => (
+
toggleYearMonth(yearMonth)}
+ >
+
{formatYearMonth(yearMonth)}
+ {Object.keys(eventsByDate[yearMonth]).map((week) => (
+
+ {Object.keys(eventsByDate[yearMonth][week]).map((day) => (
+
+ ))}
+
+ ))}
+
+ ))}
- {!showAll && yearMonths.length > 2 && (
-