fix: disable page scrolling during tutorial flow#1482
Conversation
|
@yashr5120 is attempting to deploy a commit to the magic-peach1's projects Team on Vercel. A member of the Team first needs to authorize it. |
✅ PR Format Check Passed — @yashr5120Basic format checks passed. A maintainer will review your code changes. This does not mean the PR is approved — it just means the format is correct. |
👋 Thanks for your PR, @yashr5120!Welcome to Reframe — a browser-based video editor built for everyone 🎬
What happens next
Quick checklist
Useful links
Happy coding! 🎉 |
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Adds body scroll locking while the onboarding tour is visible to prevent background scrolling during the tour overlay.
Changes:
- Introduced a
useEffectthat setsdocument.body.style.overflow = "hidden"when the tour is visible. - Restores the previous inline
overflowstyle on cleanup.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| useEffect(() => { | ||
| if (!visible) return; | ||
| const originalOverflow = document.body.style.overflow; | ||
| document.body.style.overflow = "hidden"; | ||
| return () => { | ||
| document.body.style.overflow = originalOverflow; | ||
| }; | ||
| }, [visible]); |
|
@magic-peach kindly review and merge the pr |
This pull request introduces an improvement to the onboarding tour user experience by preventing background scrolling when the tour is active.
User experience enhancement:
useEffecthook to theOnboardingTourcomponent to lock the body scroll (by settingdocument.body.style.overflowto"hidden") while the tour is visible, and restore the original overflow style when the tour is dismissed.## DescriptionRelated Issue
Closes #1481
Type of Contribution
Participant Info