manually merge HTMLAttributes

This commit is contained in:
Philipp Kühn
2020-11-25 09:50:54 +01:00
parent 7a058b9c2f
commit ddc71f792a
21 changed files with 88 additions and 41 deletions

View File

@@ -1,4 +1,4 @@
import { Command, Node } from '@tiptap/core'
import { Command, Node, mergeAttributes } from '@tiptap/core'
import { wrappingInputRule } from 'prosemirror-inputrules'
export interface BlockquoteOptions {
@@ -29,7 +29,7 @@ const Blockquote = Node.create({
},
renderHTML({ HTMLAttributes }) {
return ['blockquote', HTMLAttributes, 0]
return ['blockquote', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0]
},
addCommands() {