diff --git a/lua/vulkanite/groups/semantic_tokens.lua b/lua/vulkanite/groups/semantic_tokens.lua index b3a9f8b..c8b4c2a 100644 --- a/lua/vulkanite/groups/semantic_tokens.lua +++ b/lua/vulkanite/groups/semantic_tokens.lua @@ -61,6 +61,7 @@ function M.setup(colors, opts) ["@lsp.typemod.class.defaultLibrary"] = { link = "Type" }, ["@lsp.typemod.type.defaultLibrary"] = { link = "Type" }, ["@lsp.typemod.namespace.defaultLibrary"] = { link = "@module.builtin" }, + ["@lsp.typemod.namespace.attribute"] = { link = "@module" }, ["@lsp.typemod.enumMember.readonly"] = { link = "Constant" }, } end diff --git a/test/vulkanite_spec.lua b/test/vulkanite_spec.lua index 35b3cc5..0336336 100644 --- a/test/vulkanite_spec.lua +++ b/test/vulkanite_spec.lua @@ -427,6 +427,11 @@ local function run() "readonly variables preserve the variable style" ) assert_link_or_fg("@lsp.type.decorator", "Special", "decorators use the special syntax role") + assert_eq( + vim.api.nvim_get_hl(0, { name = "@lsp.typemod.namespace.attribute", link = true }).link, + "@module", + "Rust attributes preserve the namespace color" + ) assert_eq( vim.api.nvim_get_hl(0, { name = "LspKindSnippet" }).fg, 0x9083b9,