Merge pull request #13664 from overleaf/mj-bibtex-match-brackets

Add bibtex match brackets highlighting

GitOrigin-RevId: d0ed07d9874f097dd8b59eff582eb23a59f46332
This commit is contained in:
Alf Eaton 2023-07-04 09:10:57 +01:00 committed by Copybot
parent c16d2d5840
commit e41bda3e61

View file

@ -1,5 +1,3 @@
@top Bibliography {
(Declaration | StringDeclaration)*
}
@ -15,7 +13,9 @@
EntryTypeName { $[a-zA-Z]+ }
Number { @digit+ }
StringKeyword {"@"$[Ss]$[Tt]$[Rr]$[Ii]$[Nn]$[Gg]}
"@" "{" "}" "\"" "," "#" "@string"
"{"[closedBy="}"]
"}"[openedBy="{"]
"@" "\"" "," "#" "@string"
Comment { "%" ![\n]* }
}
@ -51,8 +51,8 @@ Expression {
}
@local tokens {
openBracedContents {"{"}
closeBracedContents {"}"}
OpenBracedContents[closedBy="}", @name="{"] {"{"}
CloseBracedContents[openedBy="{", @name="}"] {"}"}
@else nonClosingBracedContents
}
@ -61,19 +61,17 @@ Expression {
(
nonClosingBracedContents |
nestedBracedString {
openBracedContents
OpenBracedContents
bracedStringContents
closeBracedContents
CloseBracedContents
}
)*
}
BracedString {
"{"
bracedStringContents closeBracedContents
"{" bracedStringContents CloseBracedContents
}
}
// TODO: Implement this
@precedence { concatenation @left }
StringConcatenation {