improve command handling

This commit is contained in:
Philipp Kühn
2020-09-22 10:49:38 +02:00
parent 0aa5a4c474
commit 119fdd0dff
31 changed files with 41 additions and 38 deletions

View File

@@ -4,17 +4,11 @@ import { deleteSelection as originalDeleteSelection } from 'prosemirror-commands
type DeleteSelectionCommand = () => Command
declare module '../Editor' {
interface Editor {
interface Commands {
deleteSelection: DeleteSelectionCommand,
}
}
// declare module '../Editor' {
// interface Commands {
// deleteSelection: DeleteSelectionCommand,
// }
// }
export const deleteSelection: DeleteSelectionCommand = () => ({ state, dispatch }) => {
return originalDeleteSelection(state, dispatch)
}