From 54ad8fe62c074ba3642fd515e32410b91a58e3bc Mon Sep 17 00:00:00 2001 From: Pontus Dreij Date: Tue, 17 Dec 2024 15:45:57 +0100 Subject: [PATCH] fix(SW-952) fix hydration error in map --- .../SelectHotelMap/SelectHotelMapContent/index.tsx | 2 +- .../SelectHotelMapContent/selectHotelMapContent.module.css | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/index.tsx b/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/index.tsx index 479dcd648..1f6a9c487 100644 --- a/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/index.tsx +++ b/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/index.tsx @@ -42,7 +42,7 @@ export default function SelectHotelContent({ const isAboveMobile = useMediaQuery("(min-width: 768px)") const [visibleHotels, setVisibleHotels] = useState([]) - const [showSkeleton, setShowSkeleton] = useState(isAboveMobile) + const [showSkeleton, setShowSkeleton] = useState(true) const listingContainerRef = useRef(null) const activeFilters = useHotelFilterStore((state) => state.activeFilters) diff --git a/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/selectHotelMapContent.module.css b/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/selectHotelMapContent.module.css index ae6b81191..f7b28cf18 100644 --- a/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/selectHotelMapContent.module.css +++ b/components/HotelReservation/SelectHotel/SelectHotelMap/SelectHotelMapContent/selectHotelMapContent.module.css @@ -23,6 +23,10 @@ border: none; } +.skeletonContainer { + display: none; +} + @media (min-width: 768px) { .container .closeButton { display: flex;