Skip to content

fix: UI element position on scroll #769

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 5, 2024
Merged

Conversation

matthewlipski
Copy link
Collaborator

This PR fixes UI elements like the formatting toolbar and side menu only scrolling with the editor when the whole page is being scrolled. Now, the elements scroll with the editor regardless of which containing element is being scrolled. Additionally, the side menu is now hidden on click after being frozen, to more closely replicate Notion's UX.

Closes #748

Copy link

vercel bot commented May 27, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
blocknote ✅ Ready (Inspect) Visit Preview Jun 4, 2024 5:00pm
blocknote-website ✅ Ready (Inspect) Visit Preview Jun 4, 2024 5:00pm

@bensku
Copy link

bensku commented May 29, 2024

Not sure if I'm doing something wrong, but I can't get the side menu to open again in preview of this PR after I've closed it. Clicking or hovering over where it should be doesn't seem to work.

#748 seems to be fixed, though.

Copy link
Collaborator

@YousefED YousefED left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for testing @bensku !

Confirmed there's some bug here:
bug side

@matthewlipski
Copy link
Collaborator Author

matthewlipski commented Jun 4, 2024

Thanks for testing @bensku !

Confirmed there's some bug here: bug side

Fixed! Also I checked Notion and looks like their UX in general hides the side menu whenever the slash menu is open. We had this before only when using the add block button, but not when opening the slash menu using the "/" key, which made our own UX was kind of inconsistent. I made it so that opening the slash menu initially hides the side menu but moving the mouse shows it again (now the same for both pressing "/" key and add block button)

I think we can into making BlockNote's behaviour the same as Notions for this case (i.e. the side menu stays hidden while the slash menu is open), but that's a separate issue.

@matthewlipski matthewlipski merged commit 432110a into main Jun 5, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Blocknote hallucinating UI outside of container
3 participants