Files
tiptap/packages/core/src/commands/undoInputRule.ts
2021-02-16 18:39:37 +01:00

18 lines
445 B
TypeScript

import { undoInputRule as originalUndoInputRule } from 'prosemirror-inputrules'
import { Command, RawCommands } from '../types'
declare module '@tiptap/core' {
interface Commands {
undoInputRule: {
/**
* Undo an input rule.
*/
undoInputRule: () => Command,
}
}
}
export const undoInputRule: RawCommands['undoInputRule'] = () => ({ state, dispatch }) => {
return originalUndoInputRule(state, dispatch)
}