From 2cce2a95b7ea2ae7d582e717e0a8515cfd33d1af Mon Sep 17 00:00:00 2001 From: Tobias Johansson Date: Thu, 26 Jun 2025 06:49:59 +0000 Subject: [PATCH] Merged in fix/SW-2845-hotel-pins-map-screen (pull request #2437) fix(SW-2845): remove hover state when clicking hotel card address * fix(SW-2845): remove hover state when clicking hotel card address Approved-by: Michael Zetterberg --- .../components/HotelReservation/HotelCard/index.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/scandic-web/components/HotelReservation/HotelCard/index.tsx b/apps/scandic-web/components/HotelReservation/HotelCard/index.tsx index 3bc43fb66..421554b23 100644 --- a/apps/scandic-web/components/HotelReservation/HotelCard/index.tsx +++ b/apps/scandic-web/components/HotelReservation/HotelCard/index.tsx @@ -54,7 +54,8 @@ function HotelCard({ const lang = params.lang as Lang const intl = useIntl() - const { activate, engage, disengageAfterDelay } = useHotelsMapStore() + const { activate, engage, disengage, disengageAfterDelay } = + useHotelsMapStore() const amenities = hotel.detailedFacilities.slice(0, 5) const router = useRouter() @@ -65,6 +66,7 @@ function HotelCard({ const handleAddressClick = (event: React.MouseEvent) => { event.preventDefault() + disengage() // Disengage the current hotel to avoid the hover state from being active when clicking on the address activate(hotel.name) router.push(`${selectHotelMap(lang)}?${searchParams.toString()}`) }