mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-22 15:02:51 +02:00
This reverts commit 6f676d6771
.
This behavior should be in userland, because there isn't agreement
among text editors on how it should behave.
Resolves #1269.
This commit is contained in:
committed by
Ian Storm Taylor
parent
1777fc3959
commit
6298d5442d
@@ -474,15 +474,9 @@ function AfterPlugin(options = {}) {
|
||||
const { state } = change
|
||||
|
||||
if (HOTKEYS.SPLIT_BLOCK(event)) {
|
||||
if (state.isInVoid) {
|
||||
return change.collapseToStartOfNextText()
|
||||
} else {
|
||||
change = change.splitBlock()
|
||||
state.activeMarks.forEach((mark) => {
|
||||
change = change.addMark(mark)
|
||||
})
|
||||
return change
|
||||
}
|
||||
return state.isInVoid
|
||||
? change.collapseToStartOfNextText()
|
||||
: change.splitBlock()
|
||||
}
|
||||
|
||||
if (HOTKEYS.DELETE_CHAR_BACKWARD(event)) {
|
||||
|
Reference in New Issue
Block a user