From: Dessalines Date: Wed, 21 Jun 2023 18:46:29 +0000 (-0400) Subject: Commenting out markdown_it_emoji, because it breaks bolds. X-Git-Url: http://these/git/%22%7Burl%7D/%22https:/image.com/%7B%60%24%7BghostArchiveUrl%7D/%7BimageSrc%7D?a=commitdiff_plain;h=9480e6337ba6ce1f5c8d10fafc62534a4412931f;p=lemmy-ui.git Commenting out markdown_it_emoji, because it breaks bolds. - Fixes #1439 --- diff --git a/src/shared/utils.ts b/src/shared/utils.ts index 33658d1..f2face7 100644 --- a/src/shared/utils.ts +++ b/src/shared/utils.ts @@ -31,7 +31,7 @@ import { } from "lemmy-js-client"; import { default as MarkdownIt } from "markdown-it"; import markdown_it_container from "markdown-it-container"; -import markdown_it_emoji from "markdown-it-emoji/bare"; +// import markdown_it_emoji from "markdown-it-emoji/bare"; import markdown_it_footnote from "markdown-it-footnote"; import markdown_it_html5_embed from "markdown-it-html5-embed"; import markdown_it_sub from "markdown-it-sub"; @@ -576,19 +576,19 @@ function setupMarkdown() { typographer: true, }; - const emojiDefs = Array.from(customEmojisLookup.entries()).reduce( - (main, [key, value]) => ({ ...main, [key]: value }), - {} - ); + // const emojiDefs = Array.from(customEmojisLookup.entries()).reduce( + // (main, [key, value]) => ({ ...main, [key]: value }), + // {} + // ); md = new MarkdownIt(markdownItConfig) .use(markdown_it_sub) .use(markdown_it_sup) .use(markdown_it_footnote) .use(markdown_it_html5_embed, html5EmbedConfig) - .use(markdown_it_container, "spoiler", spoilerConfig) - .use(markdown_it_emoji, { - defs: emojiDefs, - }); + .use(markdown_it_container, "spoiler", spoilerConfig); + // .use(markdown_it_emoji, { + // defs: emojiDefs, + // }); mdNoImages = new MarkdownIt(markdownItConfig) .use(markdown_it_sub) @@ -596,9 +596,9 @@ function setupMarkdown() { .use(markdown_it_footnote) .use(markdown_it_html5_embed, html5EmbedConfig) .use(markdown_it_container, "spoiler", spoilerConfig) - .use(markdown_it_emoji, { - defs: emojiDefs, - }) + // .use(markdown_it_emoji, { + // defs: emojiDefs, + // }) .disable("image"); const defaultRenderer = md.renderer.rules.image; md.renderer.rules.image = function (