mirror of
https://github.com/LazyVim/LazyVim.git
synced 2026-07-25 14:01:06 +00:00
feat(cmp): disable item.menu for Rust filetypes
This commit is contained in:
parent
72547b809f
commit
109a523d46
1 changed files with 4 additions and 1 deletions
|
|
@ -49,11 +49,14 @@ return {
|
||||||
{ name = "buffer" },
|
{ name = "buffer" },
|
||||||
}),
|
}),
|
||||||
formatting = {
|
formatting = {
|
||||||
format = function(_, item)
|
format = function(entry, item)
|
||||||
local icons = LazyVim.config.icons.kinds
|
local icons = LazyVim.config.icons.kinds
|
||||||
if icons[item.kind] then
|
if icons[item.kind] then
|
||||||
item.kind = icons[item.kind] .. item.kind
|
item.kind = icons[item.kind] .. item.kind
|
||||||
end
|
end
|
||||||
|
if entry.context.filetype == "rust" then
|
||||||
|
item.menu = nil
|
||||||
|
end
|
||||||
return item
|
return item
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue