|
|
@ -1,28 +1,36 @@
|
|
|
|
; inherits: javascript
|
|
|
|
; Namespaces
|
|
|
|
|
|
|
|
|
|
|
|
; Types
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(type_identifier) @type
|
|
|
|
(internal_module
|
|
|
|
(predefined_type) @type.builtin
|
|
|
|
[((identifier) @namespace) ((nested_identifier (identifier) @namespace))])
|
|
|
|
|
|
|
|
|
|
|
|
((identifier) @type
|
|
|
|
(ambient_declaration "global" @namespace)
|
|
|
|
(#match? @type "^[A-Z]"))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(type_arguments
|
|
|
|
|
|
|
|
"<" @punctuation.bracket
|
|
|
|
|
|
|
|
">" @punctuation.bracket)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; Variables
|
|
|
|
; Variables
|
|
|
|
|
|
|
|
|
|
|
|
(required_parameter (identifier) @variable.parameter)
|
|
|
|
(required_parameter (identifier) @variable.parameter)
|
|
|
|
(optional_parameter (identifier) @variable.parameter)
|
|
|
|
(optional_parameter (identifier) @variable.parameter)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; Punctuation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
|
|
|
":"
|
|
|
|
|
|
|
|
] @punctuation.delimiter
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(optional_parameter "?" @punctuation.special)
|
|
|
|
|
|
|
|
(property_signature "?" @punctuation.special)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(conditional_type ["?" ":"] @operator)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; Keywords
|
|
|
|
; Keywords
|
|
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
[
|
|
|
|
"abstract"
|
|
|
|
"abstract"
|
|
|
|
"declare"
|
|
|
|
"declare"
|
|
|
|
"export"
|
|
|
|
"export"
|
|
|
|
|
|
|
|
"infer"
|
|
|
|
"implements"
|
|
|
|
"implements"
|
|
|
|
"keyof"
|
|
|
|
"keyof"
|
|
|
|
"namespace"
|
|
|
|
"namespace"
|
|
|
@ -40,3 +48,17 @@
|
|
|
|
"protected"
|
|
|
|
"protected"
|
|
|
|
"readonly"
|
|
|
|
"readonly"
|
|
|
|
] @keyword.storage.modifier
|
|
|
|
] @keyword.storage.modifier
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; inherits: javascript
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; Types
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(type_identifier) @type
|
|
|
|
|
|
|
|
(predefined_type) @type.builtin
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(type_arguments
|
|
|
|
|
|
|
|
"<" @punctuation.bracket
|
|
|
|
|
|
|
|
">" @punctuation.bracket)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
((identifier) @type
|
|
|
|
|
|
|
|
(#match? @type "^[A-Z]"))
|
|
|
|