-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Inline Toolbar overrides selected content outside editor when pressing "/" #2863
Comments
Taking a look at this one |
@idebenone I noticed this has been open for over a month so I decided to quickly fix this. I hope you don't mind @neSpecc Here is the fix for the bug Can you help have a look when you have the chance? |
Hey @obafemitayor, Thank you for your contribution, we will definitely look into it. |
@obafemitayor I've checked it. The fix works fine, but the test is not fully reproduce the original problem. Would you have time to refine test? |
@neSpecc Yes, I will work on this now |
@neSpecc I have modified the test to fully reproduce the original problem |
Bug Description
When the Inline Toolbar is enabled in Editor.js, pressing the "/" key after selecting any text or element outside the editor area results in replacing the selected content with a "/". This issue occurs both in custom implementations and on the official Editor.js documentation site.
Steps to Reproduce
Expected behavior
Pressing "/" should not affect selected content or elements outside the editor area.
Actual Behavior
The "/" keypress unexpectedly replaces selected text and elements outside the editor with "/".
Screenshots
Additional Context
This behavior appears to be triggered by Inline Toolbar, which activates the editor's command palette when "/" is pressed, regardless of the selected area. It disrupts the content and layout outside the editor area.
Environment
Editor.js version: 2.29.x
Browser: e.g., Chrome 130.0, Firefox 132.0
OS: e.g., Ubuntu 24.04, macOS 15
Plugins you use with their versions: Header 2.8.1, ImageTool 2.9.0, NestedList 1.4.2, Embed 2.8.1, Table 2.3.0, Underline 1.1.0
The text was updated successfully, but these errors were encountered: