mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-04-21 22:02:05 +02:00
update k key handler in core plugin
This commit is contained in:
parent
1fd27578fa
commit
2b10e270c6
@ -519,12 +519,9 @@ function Plugin(options = {}) {
|
||||
|
||||
function onKeyDownK(e, data, state) {
|
||||
if (!IS_MAC || !data.isCtrl) return
|
||||
|
||||
const { startOffset, startBlock } = state
|
||||
|
||||
return state
|
||||
.transform()
|
||||
.deleteForward(startBlock.length - startOffset)
|
||||
.deleteLineForward()
|
||||
.apply()
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user