Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Fix constant highlighting in JS, TypeScript
Max Brunsfeldaba2914a3161
diff --git a/crates/zed/src/languages/javascript/highlights.scm b/crates/zed/src/languages/javascript/highlights.scmindex 9dc3af4eaea..36ab21ca1ec 100644--- a/crates/zed/src/languages/javascript/highlights.scm+++ b/crates/zed/src/languages/javascript/highlights.scm@@ -43,8 +43,10 @@; Special identifiers-((identifier) @constructor- (#match? @constructor "^[A-Z]"))+((identifier) @type+ (#match? @type "^[A-Z]"))+(type_identifier) @type+(predefined_type) @type.builtin([(identifier)@@ -192,14 +194,6 @@"${" @punctuation.special"}" @punctuation.special) @embedded-; Types--(type_identifier) @type-(predefined_type) @type.builtin--((identifier) @type- (#match? @type "^[A-Z]"))-(type_arguments"<" @punctuation.bracket">" @punctuation.bracket)diff --git a/crates/zed/src/languages/typescript/highlights.scm b/crates/zed/src/languages/typescript/highlights.scmindex 4b744c3a806..bf086ea156f 100644--- a/crates/zed/src/languages/typescript/highlights.scm+++ b/crates/zed/src/languages/typescript/highlights.scm@@ -46,6 +46,11 @@((identifier) @constructor(#match? @constructor "^[A-Z]"))+((identifier) @type+ (#match? @type "^[A-Z]"))+(type_identifier) @type+(predefined_type) @type.builtin+([(identifier)(shorthand_property_identifier)@@ -193,14 +198,6 @@"${" @punctuation.special"}" @punctuation.special) @embedded-; Types--(type_identifier) @type-(predefined_type) @type.builtin--((identifier) @type- (#match? @type "^[A-Z]"))-(type_arguments"<" @punctuation.bracket">" @punctuation.bracket)