0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-04 19:02:38 +00:00

Fix Syntax Highlighting

Update changelog to match PR target shifts.
This commit is contained in:
David Bolack
2024-02-07 20:23:19 -06:00
parent ea320e0cc4
commit f3148ed53c
2 changed files with 26 additions and 11 deletions

View File

@@ -160,8 +160,8 @@ const Editor = createClass({
codeMirror.markText({ line: lineNumber, ch: match.indices[2][0] }, { line: lineNumber, ch: match.indices[2][1] }, { className: 'dd-highlight' });
const ddIndex = match.indices[2][0];
let colons = /::/g;
let colonMatches;
while((colonMatches = colons.exec(match[2])) !== null){
let colonMatches = colons.exec(match[2]);
if(colonMatches !== null){
codeMirror.markText({ line: lineNumber, ch: colonMatches.index + ddIndex }, { line: lineNumber, ch: colonMatches.index + colonMatches[0].length + ddIndex }, { className: 'dl-colon-highlight'} )
}
}