feat: add hl_group for file icons (#1131)
This commit is contained in:
@@ -83,8 +83,13 @@ if icon_state.show_file_icon then
|
||||
end
|
||||
end
|
||||
else
|
||||
get_file_icon = function()
|
||||
return #icon_state.icons.default > 0 and icon_state.icons.default .. icon_padding or ""
|
||||
get_file_icon = function(_, _, line, depth)
|
||||
local hl_group = "NvimTreeFileIcon"
|
||||
local icon = icon_state.icons.default
|
||||
if #icon > 0 then
|
||||
table.insert(hl, { hl_group, line, depth, depth + #icon + 1 })
|
||||
end
|
||||
return #icon > 0 and icon .. icon_padding or ""
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user