Skip to content

Commit

Permalink
fix: update tm language with new markdown frontmatter specs
Browse files Browse the repository at this point in the history
Fixes #501
  • Loading branch information
mcanouil committed Aug 5, 2024
1 parent 06678d5 commit 66036c2
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions apps/vscode/syntaxes/quarto.tmLanguage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,20 @@ repository:
]{4}|\t)'}
separator: {match: '(^|\G)[ ]{0,3}([\*\-\_])([ ]{0,2}\2){2,}[ \t]*$\n?', name: meta.separator.quarto}
frontMatter:
begin: \A-{3}\s*$
contentName: meta.embedded.block.frontmatter
begin: \A(?=(-{3,}))
end: ^ {,3}\1-*[ \t]*$|^[ \t]*\.{3}$
applyEndPatternLast: 1
endCaptures:
0: {name: punctuation.definition.end.frontmatter}
patterns:
- {include: source.yaml}
end: (^|\G)-{3}|\.{3}\s*$
- begin: \A(-{3,})(.*)$
while: ^(?! {,3}\1-*[ \t]*$|[ \t]*\.{3}$)
beginCaptures:
"1": {name: punctuation.definition.begin.frontmatter}
"2": {name: comment.frontmatter}
contentName: meta.embedded.block.frontmatter
patterns:
- {include: source.yaml}
inline:
patterns:
- {include: '#ampersand'}
Expand Down

0 comments on commit 66036c2

Please sign in to comment.