mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-06-21 00:25:50 +02:00
fix(blink): make sure to use LazyVim.config.icons.kinds
(#5668)
## Description This blink [commit](010d939e7f
) made a change, so that third party sources can provide their own `item.kind_icon` and `item.kind_name`. The problem is that these icons will take precedence over `config.kind_icons[kind]`, which LazyVim sets [here](541b83276e/lua/lazyvim/plugins/extras/coding/blink.lua (L164-L164)
). I noticed that `blink-cmp-copilot` also started providing its own in the items that it returns. I noticed this because I have the following in my configuration `columns = { { "label", "label_description", gap = 1 }, { "kind_icon", "kind" } }`. The icon that it uses is a smaller icon one character long, which by default it will scale up and show normally like the LazyVim icon. But when you put another component next to it (like `kind`) in the `columns` field, then it shows the normal size of the icon next to the `kind` and it looks kinda weird compared to the default LazyVim icon. <!-- Describe the big picture of your changes to communicate to the maintainers why we should accept this pull request. --> ## Related Issue(s) None <!-- If this PR fixes any issues, please link to the issue here. - Fixes #<issue_number> --> ## Screenshots Before (the default icon provided by `blink-cmp-copilot`)  After (the LazyVim icon)  <!-- Add screenshots of the changes if applicable. --> ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines.
This commit is contained in:
parent
541b83276e
commit
771089f692
1 changed files with 1 additions and 0 deletions
|
@ -143,6 +143,7 @@ return {
|
|||
items = transform_items and transform_items(ctx, items) or items
|
||||
for _, item in ipairs(items) do
|
||||
item.kind = kind_idx or item.kind
|
||||
item.kind_icon = LazyVim.config.icons.kinds[item.kind_name] or item.kind_icon or nil
|
||||
end
|
||||
return items
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue