mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-12-01 09:29:02 +08:00
Add keyboard shortcuts to toggle superscript and subscript marks.
This commit is contained in:
parent
3f57a13d19
commit
f3a94e1db4
@ -66,4 +66,10 @@ export const Subscript = Mark.create<SubscriptExtensionOptions>({
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
addKeyboardShortcuts() {
|
||||
return {
|
||||
'Mod-,': () => this.editor.commands.toggleSubscript(),
|
||||
}
|
||||
},
|
||||
})
|
||||
|
@ -66,4 +66,10 @@ export const Superscript = Mark.create<SuperscriptExtensionOptions>({
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
addKeyboardShortcuts() {
|
||||
return {
|
||||
'Mod-.': () => this.editor.commands.toggleSuperscript(),
|
||||
}
|
||||
},
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user