add more core commands

This commit is contained in:
Philipp Kühn
2021-01-06 13:02:30 +01:00
parent d90510156b
commit 5e29cc1481
12 changed files with 134 additions and 36 deletions

View File

@@ -1,19 +1,27 @@
import { Extension } from '../Extension'
import * as blur from '../commands/blur'
import * as clearContent from '../commands/clearContent'
import * as command from '../commands/command'
import * as clearNodes from '../commands/clearNodes'
import * as command from '../commands/command'
import * as createParagraphNear from '../commands/createParagraphNear'
import * as deleteSelection from '../commands/deleteSelection'
import * as exitCode from '../commands/exitCode'
import * as extendMarkRange from '../commands/extendMarkRange'
import * as first from '../commands/first'
import * as focus from '../commands/focus'
import * as insertHTML from '../commands/insertHTML'
import * as insertText from '../commands/insertText'
import * as joinBackward from '../commands/joinBackward'
import * as joinForward from '../commands/joinForward'
import * as lift from '../commands/lift'
import * as liftEmptyBlock from '../commands/liftEmptyBlock'
import * as liftListItem from '../commands/liftListItem'
import * as newlineInCode from '../commands/newlineInCode'
import * as resetNodeAttributes from '../commands/resetNodeAttributes'
import * as scrollIntoView from '../commands/scrollIntoView'
import * as selectAll from '../commands/selectAll'
import * as selectNodeBackward from '../commands/selectNodeBackward'
import * as selectNodeForward from '../commands/selectNodeForward'
import * as selectParentNode from '../commands/selectParentNode'
import * as setContent from '../commands/setContent'
import * as setMark from '../commands/setMark'
@@ -25,6 +33,7 @@ import * as toggleList from '../commands/toggleList'
import * as toggleMark from '../commands/toggleMark'
import * as toggleNode from '../commands/toggleNode'
import * as toggleWrap from '../commands/toggleWrap'
import * as undoInputRule from '../commands/undoInputRule'
import * as unsetAllMarks from '../commands/unsetAllMarks'
import * as unsetMark from '../commands/unsetMark'
import * as updateNodeAttributes from '../commands/updateNodeAttributes'
@@ -40,17 +49,25 @@ export const Commands = Extension.create({
...clearContent,
...clearNodes,
...command,
...createParagraphNear,
...deleteSelection,
...exitCode,
...extendMarkRange,
...first,
...focus,
...insertHTML,
...insertText,
...joinBackward,
...joinForward,
...lift,
...liftEmptyBlock,
...liftListItem,
...newlineInCode,
...resetNodeAttributes,
...scrollIntoView,
...selectAll,
...selectNodeBackward,
...selectNodeForward,
...selectParentNode,
...setContent,
...setMark,
@@ -62,8 +79,9 @@ export const Commands = Extension.create({
...toggleMark,
...toggleNode,
...toggleWrap,
...unsetMark,
...undoInputRule,
...unsetAllMarks,
...unsetMark,
...updateNodeAttributes,
...wrapIn,
...wrapInList,