From b4653c15b851c107cffde307a03b72c9619e8dc8 Mon Sep 17 00:00:00 2001 From: xdBronch <51252236+xdBronch@users.noreply.github.com> Date: Mon, 5 May 2025 18:25:09 -0400 Subject: [PATCH] language: Add fallback for enum member completion highlight (#27929) i tried to use `variant` but it wasnt giving any color despite my theme definitely having a color for it, am i doing something wrong? i think `property` is an alright fallback before: ![image](https://github.com/user-attachments/assets/e020ec4d-3a85-45fb-9ddb-823c55e0afca) after: ![image](https://github.com/user-attachments/assets/3c335ed6-746e-4136-858a-8b80e5229f29) Release Notes: - N/A --- crates/language/src/language.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/language/src/language.rs b/crates/language/src/language.rs index 864d7a3fd3..7de1b9ba4f 100644 --- a/crates/language/src/language.rs +++ b/crates/language/src/language.rs @@ -1948,6 +1948,9 @@ impl CodeLabel { Kind::ENUM => grammar .highlight_id_for_name("enum") .or_else(|| grammar.highlight_id_for_name("type")), + Kind::ENUM_MEMBER => grammar + .highlight_id_for_name("variant") + .or_else(|| grammar.highlight_id_for_name("property")), Kind::FIELD => grammar.highlight_id_for_name("property"), Kind::FUNCTION => grammar.highlight_id_for_name("function"), Kind::INTERFACE => grammar.highlight_id_for_name("type"),