codex-team / editor.js

A block-style editor with clean JSON output
https://editorjs.io
Apache License 2.0
28.93k stars 2.09k forks source link

Is there a way to prevent delete block on backspace? #1450

Closed CavalcanteLeo closed 2 years ago

CavalcanteLeo commented 4 years ago

Hi, i'm creating a platform for radiologists that makes structures reports. So, users can not remove any block.

But when i press backspace, it deletes the whole block. Is there a way to prevent it? Also i can not allow to delete multiple blocks by selecting them

Users are still allow to delete letters/words from the block, but not the block itself

gaona233 commented 3 years ago

How did you solve it,i have same problem

crying2812 commented 3 years ago

Hi @CavalcanteLeo, can you show me the full of sourcecode? I'm a newbie, i cant find where i can put your code

MakarovCode commented 3 years ago

Any way to solve this issue?

conanliuhuan commented 2 years ago

Any way to solve this issue? If i rendered a custom-web-component with shadow-root, backspace in that input will remove all the block