Skip to content

Commit

Permalink
Fix - delete selected inline void in chrome (#4526)
Browse files Browse the repository at this point in the history
* Fix - delete selected inline void in chrome

* Add changeset

* Fix prettier on changeset

Co-authored-by: Dylan Schiemann <dylan@dojotoolkit.org>
  • Loading branch information
VictorBaron and dylans committed Sep 24, 2021
1 parent 38717ad commit bc85497
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/loud-planets-count.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'slate-react': patch
---

Fix - delete selected inline void in chrome
2 changes: 1 addition & 1 deletion packages/slate-react/src/components/editable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1215,7 +1215,7 @@ export const Editable = (props: EditableProps) => {
Editor.isInline(editor, currentNode)
) {
event.preventDefault()
Transforms.delete(editor, { unit: 'block' })
Editor.deleteBackward(editor, { unit: 'block' })

return
}
Expand Down

0 comments on commit bc85497

Please sign in to comment.