refactoring
This commit is contained in:
@@ -13,8 +13,8 @@ declare module '@tiptap/core/src/Editor' {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export interface HistoryOptions {
|
export interface HistoryOptions {
|
||||||
depth: any,
|
depth: number,
|
||||||
newGroupDelay: any,
|
newGroupDelay: number,
|
||||||
}
|
}
|
||||||
|
|
||||||
export default new Extension<HistoryOptions>()
|
export default new Extension<HistoryOptions>()
|
||||||
@@ -37,9 +37,6 @@ export default new Extension<HistoryOptions>()
|
|||||||
'Shift-Mod-z': () => editor.redo(),
|
'Shift-Mod-z': () => editor.redo(),
|
||||||
}))
|
}))
|
||||||
.plugins(({ options }) => [
|
.plugins(({ options }) => [
|
||||||
history({
|
history(options),
|
||||||
...options.depth,
|
|
||||||
...options.newGroupDelay,
|
|
||||||
}),
|
|
||||||
])
|
])
|
||||||
.create()
|
.create()
|
||||||
|
|||||||
Reference in New Issue
Block a user