Skip to content

Commit

Permalink
fix(document_symbols): support blank line from "add_blank_line_at_top…
Browse files Browse the repository at this point in the history
…" option (#972)
  • Loading branch information
nhat-vo committed Jun 6, 2023
1 parent 4c36956 commit d883632
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lua/neo-tree/sources/document_symbols/components.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ local M = {}
M.icon = function(config, node, state)
return {
text = node:get_depth() == 1 and "" or node.extra.kind.icon,
highlight = node.extra.kind.hl,
highlight = node.extra and node.extra.kind.hl or highlights.FILE_NAME,
}
end

Expand All @@ -27,14 +27,14 @@ M.kind_icon = M.icon
M.kind_name = function(config, node, state)
return {
text = node:get_depth() == 1 and "" or node.extra.kind.name,
highlight = node.extra.kind.hl,
highlight = node.extra and node.extra.kind.hl or highlights.FILE_NAME,
}
end

M.name = function(config, node, state)
return {
text = node.name,
highlight = node.extra.kind.hl or highlights.FILE_NAME,
highlight = node.extra and node.extra.kind.hl or highlights.FILE_NAME,
}
end

Expand Down

0 comments on commit d883632

Please sign in to comment.