on master help sign in
Update typescript grammar and queries (#4703)
7367abdGabriel Dinner-David
languages.toml+2−2
@@ -399,7 +399,7 @@ indent = { tab-width = 2, unit = " " }
399
399
400[[grammar]]
400[[grammar]]
401name = "typescript"
401name = "typescript"
402−source = { git = "https://github.com/tree-sitter/tree-sitter-typescript", rev = "3e897ea5925f037cfae2e551f8e6b12eec2a201a", subpath = "typescript" }
402+source = { git = "https://github.com/tree-sitter/tree-sitter-typescript", rev = "6aac031ad88dd6317f02ac0bb27d099a553a7d8c", subpath = "typescript" }
403
403
404[[language]]
404[[language]]
405name = "tsx"
405name = "tsx"
@@ -413,7 +413,7 @@ indent = { tab-width = 2, unit = " " }
413
413
414[[grammar]]
414[[grammar]]
415name = "tsx"
415name = "tsx"
416−source = { git = "https://github.com/tree-sitter/tree-sitter-typescript", rev = "3e897ea5925f037cfae2e551f8e6b12eec2a201a", subpath = "tsx" }
416+source = { git = "https://github.com/tree-sitter/tree-sitter-typescript", rev = "6aac031ad88dd6317f02ac0bb27d099a553a7d8c", subpath = "tsx" }
417
417
418[[language]]
418[[language]]
419name = "css"
419name = "css"
runtime/queries/typescript/highlights.scm+13
@@ -34,6 +34,7 @@
34 "implements"
34 "implements"
35 "keyof"
35 "keyof"
36 "namespace"
36 "namespace"
37+ "override"
37] @keyword
38] @keyword
38
39
39[
40[
@@ -62,3 +63,15 @@
62
63
63((identifier) @type
64((identifier) @type
64 (#match? @type "^[A-Z]"))
65 (#match? @type "^[A-Z]"))
66+
67+; Literals
68+
69+[
70+ (template_literal_type)
71+] @string
72+
73+; Tokens
74+
75+(template_type
76+ "${" @punctuation.special
77+ "}" @punctuation.special) @embedded