Allow scroll when user selects a date (#22313)

This commit is contained in:
Hariom Balhara
2025-07-08 07:00:30 +00:00
committed by GitHub
parent 076afdc00e
commit 4843658dfb
+2 -2
View File
@@ -155,8 +155,8 @@ const BookerComponent = ({
const scrolledToTimeslotsOnce = useRef(false);
const scrollToTimeSlots = () => {
if (isMobile && !isEmbed && !scrolledToTimeslotsOnce.current) {
// eslint-disable-next-line @calcom/eslint/no-scroll-into-view-embed -- Conditional within !isEmbed condition
if (isMobile && !scrolledToTimeslotsOnce.current) {
// eslint-disable-next-line @calcom/eslint/no-scroll-into-view-embed -- We are allowing it here because scrollToTimeSlots is called on explicit user action where it makes sense to scroll, remember that the goal is to not do auto-scroll on embed load because that ends up scrolling the embedding webpage too
timeslotsRef.current?.scrollIntoView({ behavior: "smooth" });
scrolledToTimeslotsOnce.current = true;
}