Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A PR to improve syntax highlighting and add missing scopes.
Changes are listed below with examples.
Release Notes:
Bash
>&
,>&-
,:
,//
,/
,%
,%%
,#
,##
,=
,==
:operator
-lt
,-le
,-gt
,-ge
,-eq
,-ne
,-z
,-n
:keyword.operator
, as defined in other languagesregex
:string.regex
, as defined in other languagesnumber
:number
string
:string
variable
:property
->variable
;
:punctuation.delimiter
(
,)
,{
,}
,[
,]
:punctuation.bracket
$
,${ }
,$( )
:punctuation.special
, as defined in other languagesC, C++
true
,false
,NULL
,nullptr
:constant
->constant.builtin
, as defined in other languagesIDENTIFIER
:constant
->constant.variable
, different from constant literalsCSS
|
:operator
and
,or
,not
,only
:operator
->keyword.operator
, as defined in other languageskeyword_query
:constant
, like in Atom and VS Codenamespace_name
:property
->namespace
, not a property nameproperty_name
:constant
->property
, likefeature_name
already definedplain_value
:constant
keyframes_name
:constant
, to stay coherent as it is tokenized asplain_value
when referencedunit
:type
->constant.unit
, Atom and VS Code also have aunit
scope for thisid_name
,class_name
:property
->selector
, not property names, these tokens deserve their own scope. Atom, VS Code, Neovim resort to recycling other scopesGo
constant
:constant
->constant.variable
, different from constant literalspackage_identifier
:namespace
method_elem
:function.method
;
,.
,,
,:
:punctuation.delimiter
JavaScript, JSDoc, TSX, TypeScript
IDENTIFIER
:constant
->constant.variable
, different from constant literalstrue
,false
:boolean
->constant.builtin
, this is the only language that has theboolean
scope, so conforming to the majorityjsx_text
:text.jsx
=
:punctuation.jsx.delimiter
@
:punctuation.special
, as in Pythonjsdoc
: addedcomment.doc
scope for themes that highlight itJSON
true
,false
,null
:constant
->constant.builtin
, as defined in other languages,
,:
:punctuation.delimiter
Markdown
Changes to include the
markup
scope, conforming to Neovim, VS Code, Atom, and Zed itself.# Heading
:title
->markup.heading
, as in the gitcommit grammar```
:punctuation.markup.embedded
-
,1.
,>
,|
:punctuation.markup
*italic*
:emphasis
->markup.emphasis
**bold**
:emphasis.strong
->markup.emphasis.strong
~~strikethrough~~
:markup.strikethrough
`raw`
:text.literal
->markup.raw
[link](url.com)
:markup.link
url.com
:link_uri
->markup.link.url
, as in the gitcommit grammarparagraph
,indented_code_block
,pipe_table
:text
Python
@
:operator
, for matrix multiplicationIDENTIFIER
:constant
->constant.variable
, different from constant literalsidentifier
:variable
.
,,
,:
:punctuation.delimiter
Regex
^
,$
,\b
,\B
,\k
:string.escape
->operator
group_name
:property
->label
(?P=
,<
:punctuation.bracket
regex
scope to target regex tokens specificallyRust
true
,false
:constant
->constant.builtin
, as defined in other languagesIDENTIFIER
:constant
->constant.variable
, different from constant literalsidentifier
:variable