From 6de3ac3e17a42e92d4939a9107c673bf37991507 Mon Sep 17 00:00:00 2001 From: Ben Kunkle Date: Sun, 9 Mar 2025 11:11:37 -0500 Subject: [PATCH] Revert "Highlight `super` and `this` as keywords in JS/TS/TSX" (#26342) Reverts zed-industries/zed#25135 This approach was not the best as explained in the response to the original PR. Likely, the better approach is to create a newer specific scope for these kinds of variables under the `@variable` prefix so that themes can control these pseudo-keywords specifically --- crates/languages/src/javascript/highlights.scm | 4 ++-- crates/languages/src/tsx/highlights.scm | 4 ++-- crates/languages/src/typescript/highlights.scm | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/languages/src/javascript/highlights.scm b/crates/languages/src/javascript/highlights.scm index f46db408e7d73bb1aa714cf02176870f47d388de..1b2e047a1e6e9465b2d9387100b0f344e2a9dc82 100644 --- a/crates/languages/src/javascript/highlights.scm +++ b/crates/languages/src/javascript/highlights.scm @@ -62,8 +62,8 @@ ; Literals -(this) @keyword -(super) @keyword +(this) @variable.special +(super) @variable.special [ (null) diff --git a/crates/languages/src/tsx/highlights.scm b/crates/languages/src/tsx/highlights.scm index 5b83ec903c8d429eac872600247d75f58234598f..6e1ced93ccdcd82bf7d31b75bda31271f678f9be 100644 --- a/crates/languages/src/tsx/highlights.scm +++ b/crates/languages/src/tsx/highlights.scm @@ -62,8 +62,8 @@ ; Literals -(this) @keyword -(super) @keyword +(this) @variable.special +(super) @variable.special [ (null) diff --git a/crates/languages/src/typescript/highlights.scm b/crates/languages/src/typescript/highlights.scm index 502957c93bc565e3c7b06467996a374d513412a9..b83999786382da064f3ad5ffb73b924dcf81df32 100644 --- a/crates/languages/src/typescript/highlights.scm +++ b/crates/languages/src/typescript/highlights.scm @@ -80,8 +80,8 @@ ; Literals -(this) @keyword -(super) @keyword +(this) @variable.special +(super) @variable.special [ (null)