Skip to content
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

Added scrolling to the bottom of the page when adding blocks from the files sidebar #148

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

joezein-oss
Copy link
Contributor

When adding a python or sql file from the sidbar in the notebook, it will scroll down to the bottom of the page where it's added.

@joezein-oss
Copy link
Contributor Author

Closes #14

Copy link
Member

@lucasfcosta lucasfcosta 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 the work here @joezein-oss!

I had a quick test at this and unfortunately it's not always working as expected.

The issue here is that sometimes it seems that the calculated scroll is different from what it should be. So sometimes the view scrolls past the block, and at other times it doesn't show the entire block in the viewport.

You can reproduce this if you add a bunch of blocks simultaneously or if you have a very long document and try adding more blocks.

I have previously tried an approach that was almost identical to your PR here but it didn't work for the same reason so I didn't go forward because it wasn't trivial - maybe the same issue happened here.

Do you think you could have another look at this?

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.

2 participants