diff --git a/elements/timetable/Timetable.tsx b/elements/timetable/Timetable.tsx index b6a5b51..0181865 100644 --- a/elements/timetable/Timetable.tsx +++ b/elements/timetable/Timetable.tsx @@ -13,7 +13,7 @@ const AnimatedPager = Animated.createAnimatedComponent(PagerView); const Timetable = () => { const [events, setEvents] = useState([]); - const [eventDayIndex, setEventDayIndex] = useState(0); + const [eventDayIndex, setEventDayIndex] = useState(-1); const { favorites, toggle: toggleFavorite } = useFavorite(); const callback = useCallback((position: number) => { @@ -59,7 +59,7 @@ const Timetable = () => { return ( - {events.length === 0 ? ( + {events.length === 0 || eventDayIndex === -1 ? ( ) : (