diff --git a/packages/extension-dropcursor/src/index.ts b/packages/extension-dropcursor/src/index.ts index fd951be2..91759fed 100644 --- a/packages/extension-dropcursor/src/index.ts +++ b/packages/extension-dropcursor/src/index.ts @@ -1,10 +1,22 @@ import { Extension } from '@tiptap/core' import { dropCursor } from 'prosemirror-dropcursor' +type DropcursorOptions = { + color: string | null, + width: number | null, + class: string | null, +} + const Dropcursor = Extension.create({ + defaultOptions: { + color: 'black', + width: 1, + class: null, + }, + addProseMirrorPlugins() { return [ - dropCursor(), + dropCursor(this.options), ] }, })