chore: fix code formatting

This commit is contained in:
daniel
2024-12-23 11:05:34 +01:00
parent cc078fae6a
commit b10656c2c3

View File

@@ -72,9 +72,12 @@ export class DataviewSuggester extends EditorSuggest<String> {
renderMarkdownSuggestion(value: string, el: HTMLElement): void { renderMarkdownSuggestion(value: string, el: HTMLElement): void {
// render markdown preview of inline dataview metadata field // render markdown preview of inline dataview metadata field
let suggestionText = this.context!.editor.getLine(this.context!.start.line).slice(this.context!.start.ch-1, this.context!.start.ch)! let suggestionText = this.context!.editor.getLine(this.context!.start.line).slice(
this.context!.start.ch - 1,
this.context!.start.ch,
)!;
suggestionText += value.replace(/<mark>(.*?)<\/mark>/g, "$1"); suggestionText += value.replace(/<mark>(.*?)<\/mark>/g, "$1");
suggestionText += suggestionText.startsWith("(") ? ")" : "]" suggestionText += suggestionText.startsWith("(") ? ")" : "]";
MarkdownRenderer.render( MarkdownRenderer.render(
this.app, this.app,