* Fixes backspace remove empty block * rename data to event
This commit is contained in:
parent
28924eeea5
commit
2e7e66dc29
@ -54,8 +54,8 @@ const BreakToDefaultBlockOpts = {
|
||||
export const BreakToDefaultBlockConfigured = BreakToDefaultBlock(BreakToDefaultBlockOpts);
|
||||
|
||||
const BackspaceCloseBlock = (options = {}) => ({
|
||||
onKeyDown(e, data, change) {
|
||||
if (data.key != 'backspace') return;
|
||||
onKeyDown(event, change) {
|
||||
if (event.key !== 'Backspace') return;
|
||||
|
||||
const { defaultBlock = 'paragraph', ignoreIn, onlyIn } = options;
|
||||
const { startBlock } = change.value;
|
||||
|
Loading…
x
Reference in New Issue
Block a user