fix: deselect day when closing DayDetailPanel
Closing the panel via the X button now calls handleSelectDay(null), clearing selectedDayId from the Zustand store and resetting the route. Fixes #356.
This commit is contained in:
@@ -717,7 +717,7 @@ export default function TripPlannerPage(): React.ReactElement | null {
|
|||||||
reservations={reservations}
|
reservations={reservations}
|
||||||
lat={geoPlace?.lat}
|
lat={geoPlace?.lat}
|
||||||
lng={geoPlace?.lng}
|
lng={geoPlace?.lng}
|
||||||
onClose={() => setShowDayDetail(null)}
|
onClose={() => { setShowDayDetail(null); handleSelectDay(null) }}
|
||||||
onAccommodationChange={loadAccommodations}
|
onAccommodationChange={loadAccommodations}
|
||||||
leftWidth={isMobile ? 0 : (leftCollapsed ? 0 : leftWidth)}
|
leftWidth={isMobile ? 0 : (leftCollapsed ? 0 : leftWidth)}
|
||||||
rightWidth={isMobile ? 0 : (rightCollapsed ? 0 : rightWidth)}
|
rightWidth={isMobile ? 0 : (rightCollapsed ? 0 : rightWidth)}
|
||||||
|
|||||||
Reference in New Issue
Block a user