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

Issue: toolbars causing unwanted vertical scrolls #2642

Open
VikhorKonstantin opened this issue Feb 29, 2024 · 2 comments
Open

Issue: toolbars causing unwanted vertical scrolls #2642

VikhorKonstantin opened this issue Feb 29, 2024 · 2 comments
Labels

Comments

@VikhorKonstantin
Copy link
Contributor

Describe a bug.

Steps to reproduce:

https://github.com/codex-team/editor.js/assets/52427793/c43dbb03-806b-4c58-b12c-84980b530c70
You can see that after I deleted inner toolbar element, scroll disappeared
This happens because toolbars are still taking some space, despite the position: absolute and visibility: hidden

image
Moreover, I'm expecting to see the displayed toolbox to be over the element with the red border, not to be hidden under it (maybe this is not always the expected behavior, so this is can be a configurable option), because in my experience usually different types of tooltips and floating menus are allowed to be drawn outside the related containers and they definitely shouldn't force them to grow/scroll
All this can be achieved by rendering toolbars under some special element under document's body, then we should just carefully position them. For sure it will also require some other changes like to make sure that click under these toolbars are not treated as clicks outside of the editor and etc.
image
This is pretty much the same thing TinyMCE do with their toolbars: they are rendering toolbars outside of the editor's container, under some special element under document's body
It allows them to render their toolbar fully visible even if the toolbar is bigger than the maximum height available for the editor.

Browser, OS:
Windows, Chrome

Editor.js version: 2.29.1

@SEEDART007
Copy link

can i work on this bug?

@neSpecc
Copy link
Member

neSpecc commented Mar 23, 2024

can i work on this bug?

Right now we're working on unifying all toolbars by the Popover component. It seems like this feature should be implemented inside the Popover. You can take a look and try to suggest your PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants