From a34a5d187b2d98553f68a6732a2003b754a20252 Mon Sep 17 00:00:00 2001 From: Gazook89 Date: Sat, 2 May 2026 15:36:56 -0500 Subject: [PATCH 1/2] Fix issue with closing brace not highlighting --- client/components/codeEditor/customHighlight.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/client/components/codeEditor/customHighlight.js b/client/components/codeEditor/customHighlight.js index 8797704cc..86bad59c8 100644 --- a/client/components/codeEditor/customHighlight.js +++ b/client/components/codeEditor/customHighlight.js @@ -182,13 +182,14 @@ export function tokenizeCustomMarkdown(text) { } if(lineText.includes('{') && lineText.includes('}')) { - const injectionRegex = /(?:^|[^{\n])({(?=((?:[:=](?:"[\w,\-()#%. ]*"|[\w\-()#%.]*)|[^"':={}\s]*)*))\2})/gm; + const injectionRegex = /(?:^|[^{\n])({(?=((?:[:=](?:"[\w,\-()#%. ]*"|[\w\-()#%.]*)|[^"':={}\s]*)*))\2})/gmd; let match; while ((match = injectionRegex.exec(lineText)) !== null) { + console.log(match[2]); tokens.push({ line : lineNumber, - from : match.index, - to : match.index + match[1].length, + from : match.indices[1][0], + to : match.indices[1][1], type : customTags.injection, }); } From 80093a1998aaae140990635c8e867890ee4721d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Losada=20Hern=C3=A1ndez?= <5ecleric.naturalcrit@gmail.com> Date: Mon, 4 May 2026 16:13:15 +0200 Subject: [PATCH 2/2] remove console.log --- client/components/codeEditor/customHighlight.js | 1 - 1 file changed, 1 deletion(-) diff --git a/client/components/codeEditor/customHighlight.js b/client/components/codeEditor/customHighlight.js index 86bad59c8..0d53e2f33 100644 --- a/client/components/codeEditor/customHighlight.js +++ b/client/components/codeEditor/customHighlight.js @@ -185,7 +185,6 @@ export function tokenizeCustomMarkdown(text) { const injectionRegex = /(?:^|[^{\n])({(?=((?:[:=](?:"[\w,\-()#%. ]*"|[\w\-()#%.]*)|[^"':={}\s]*)*))\2})/gmd; let match; while ((match = injectionRegex.exec(lineText)) !== null) { - console.log(match[2]); tokens.push({ line : lineNumber, from : match.indices[1][0],