diff --git a/components/GuestsRoomsPicker/index.tsx b/components/GuestsRoomsPicker/index.tsx index 6f3704f1c..875e53629 100644 --- a/components/GuestsRoomsPicker/index.tsx +++ b/components/GuestsRoomsPicker/index.tsx @@ -63,19 +63,19 @@ export default function GuestsRoomsPickerForm() { (document.querySelector("#booking-widget")?.getBoundingClientRect() .bottom ?? 0) - 50 - const innerContainerHt = document - .querySelector(".react-aria-Popover") + const innerContainerHeight = document + .querySelector(".guests_picker_popover") ?.getBoundingClientRect().height if ( maxHeight != containerHeight && - innerContainerHt && - maxHeight <= innerContainerHt + innerContainerHeight && + maxHeight <= innerContainerHeight ) { setContainerHeight(maxHeight) } else if ( containerHeight && - innerContainerHt && - maxHeight > innerContainerHt + innerContainerHeight && + maxHeight > innerContainerHeight ) { setContainerHeight(0) } @@ -98,6 +98,7 @@ export default function GuestsRoomsPickerForm() { }} />