Merged in fix/bw-fixes (pull request #3481)
Fix/bw fixes * fix(bookingwidget): fixed some mobile issues with the booking widget * fixed dual scroll and hidden button in mobile guests & rooms picker * fixed button colors * fixed mobile search button position * Remove scroll lock
This commit is contained in:
@@ -131,7 +131,7 @@ export default function DatePickerRangeMobile({
|
||||
<footer className={styles.footer}>
|
||||
<Button
|
||||
className={styles.button}
|
||||
variant="Primary"
|
||||
variant="Tertiary"
|
||||
color="Primary"
|
||||
size="md"
|
||||
onPress={close}
|
||||
|
||||
@@ -81,7 +81,6 @@ div.months {
|
||||
#ffffff 82.5%
|
||||
);
|
||||
display: flex;
|
||||
grid-area: content;
|
||||
padding: var(--Space-x1) var(--Space-x2) var(--Space-x7);
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
|
||||
@@ -8,7 +8,6 @@ import { useMediaQuery } from "usehooks-ts"
|
||||
|
||||
import { longDateFormat } from "@scandic-hotels/common/constants/dateFormats"
|
||||
import { dt } from "@scandic-hotels/common/dt"
|
||||
import { useScrollLock } from "@scandic-hotels/common/hooks/useScrollLock"
|
||||
import { Typography } from "@scandic-hotels/design-system/Typography"
|
||||
|
||||
import useLang from "../../../hooks/useLang"
|
||||
@@ -31,9 +30,6 @@ export default function DatePickerForm({
|
||||
|
||||
const checkIsDesktop = useMediaQuery("(min-width: 1367px)")
|
||||
const [isDesktop, setIsDesktop] = useState(true)
|
||||
const { lockScroll, unlockScroll } = useScrollLock({
|
||||
autoLock: false,
|
||||
})
|
||||
const [isOpen, setIsOpen] = useState(false)
|
||||
const selectedDate = useWatch({ name })
|
||||
const { setValue } = useFormContext()
|
||||
@@ -50,8 +46,7 @@ export default function DatePickerForm({
|
||||
)
|
||||
}
|
||||
setIsOpen(false)
|
||||
unlockScroll()
|
||||
}, [name, setValue, selectedDate, unlockScroll])
|
||||
}, [name, setValue, selectedDate])
|
||||
|
||||
const { overlayProps, underlayProps } = useOverlay(
|
||||
{
|
||||
@@ -168,11 +163,6 @@ export default function DatePickerForm({
|
||||
ariaLabelledBy={ariaLabelledBy}
|
||||
onPress={() => {
|
||||
setIsOpen((prev) => !prev)
|
||||
if (!isOpen) {
|
||||
lockScroll()
|
||||
} else {
|
||||
unlockScroll()
|
||||
}
|
||||
}}
|
||||
selectedFromDate={selectedFromDate}
|
||||
selectedToDate={selectedToDate}
|
||||
|
||||
Reference in New Issue
Block a user