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

Inline Toolbar overrides selected content outside editor when pressing "/" #2863

Open
litvin0d opened this issue Nov 8, 2024 · 0 comments
Open

Comments

@litvin0d
Copy link

litvin0d commented Nov 8, 2024

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

  1. Go to any page with the editor loaded (e.g., editorjs.io and click "Play With Demo").
  2. Select text or any element outside the editor's area.
  3. Press the "/" key on your keyboard.

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

image
image

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

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

No branches or pull requests

3 participants