This commit is contained in:
Philipp Kühn 2020-10-23 11:41:24 +02:00
parent 54195d29eb
commit f7153cfe66

View File

@ -58,7 +58,7 @@ const Link = createMark({
addCommands() { addCommands() {
return { return {
link: (options: { href?: string, target?: string }): Command => ({ commands }) => { link: (options: { href?: string, target?: string } = {}): Command => ({ commands }) => {
if (!options.href) { if (!options.href) {
return commands.removeMark('link') return commands.removeMark('link')
} }
@ -68,12 +68,6 @@ const Link = createMark({
} }
}, },
addKeyboardShortcuts() {
return {
'Mod-i': () => this.editor.italic(),
}
},
addPasteRules() { addPasteRules() {
return [ return [
markPasteRule(pasteRegex, this.type, (url: string) => ({ href: url })), markPasteRule(pasteRegex, this.type, (url: string) => ({ href: url })),