From 708c36183a925e06c13b9b04ed03af073c315978 Mon Sep 17 00:00:00 2001 From: Divyansh Singh <40380293+brc-dd@users.noreply.github.com> Date: Wed, 3 Aug 2022 13:11:17 +0530 Subject: [PATCH] fix(build): update language regex for line number class (#1108) --- src/node/markdown/plugins/lineNumbers.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node/markdown/plugins/lineNumbers.ts b/src/node/markdown/plugins/lineNumbers.ts index 739b0222..43156e98 100644 --- a/src/node/markdown/plugins/lineNumbers.ts +++ b/src/node/markdown/plugins/lineNumbers.ts @@ -21,7 +21,7 @@ export const lineNumberPlugin = (md: MarkdownIt) => { const finalCode = rawCode .replace(/<\/div>$/, `${lineNumbersWrapperCode}`) - .replace(/"(language-\w*)"/, '"$1 line-numbers-mode"') + .replace(/"(language-[-\w]*)"/, '"$1 line-numbers-mode"') return finalCode }