()
| 62 | } |
| 63 | |
| 64 | enable() { |
| 65 | this.plugin.registerMarkdownPostProcessor((element, context) => { |
| 66 | void this.previewRenderer.processPreview(element, context); |
| 67 | }); |
| 68 | |
| 69 | this.registerRefreshEvents(); |
| 70 | |
| 71 | const highlightPlugin = createEditorHighlightDecorations({ |
| 72 | plugin: this.plugin, |
| 73 | highlightService: this.highlightService, |
| 74 | highlightRepository: this.highlightRepository |
| 75 | }); |
| 76 | |
| 77 | this.highlightPlugin = highlightPlugin; |
| 78 | this.plugin.registerEditorExtension([highlightPlugin]); |
| 79 | } |
| 80 | |
| 81 | private registerRefreshEvents(): void { |
| 82 | const refreshEvents: (keyof HighlightEvents)[] = [ |
no test coverage detected