diff --git a/src/services/import/markdown.spec.ts b/src/services/import/markdown.spec.ts index 91389350c..9ca6b6496 100644 --- a/src/services/import/markdown.spec.ts +++ b/src/services/import/markdown.spec.ts @@ -164,8 +164,8 @@ second line 2
  1. Hello
  2. { - const input = `
    `; - const expected = /*html*/`
    `; + const input = `
    `; + const expected = /*html*/`
    `; expect(markdownService.renderToHtml(input, "Title")).toStrictEqual(expected); }); diff --git a/src/services/import/markdown.ts b/src/services/import/markdown.ts index 22dd9cab9..a4b541979 100644 --- a/src/services/import/markdown.ts +++ b/src/services/import/markdown.ts @@ -100,7 +100,7 @@ function renderToHtml(content: string, title: string) { html = htmlSanitizer.sanitize(html); // Add a trailing semicolon to CSS styles. - html = html.replaceAll(/(]*)\s+\/>/g, "<$1$2>");