fix(edgy): only add symbolsoutline to the sidebar if it is installed.

This commit is contained in:
Folke Lemaitre
2023-06-22 20:53:14 +02:00
parent 09c1bf54ea
commit ed89d01113

View File

@ -14,7 +14,8 @@ return {
-- stylua: ignore
{ "<leader>uE", function() require("edgy").select() end, desc = "Edgy Select Window" },
},
opts = {
opts = function()
local opts = {
bottom = {
{
ft = "toggleterm",
@ -83,11 +84,6 @@ return {
pinned = true,
open = "Neotree position=top buffers",
},
{
ft = "Outline",
pinned = true,
open = "SymbolsOutline",
},
"neo-tree",
},
keys = {
@ -108,7 +104,18 @@ return {
win:resize("height", -2)
end,
},
},
}
local Util = require("lazyvim.util")
if Util.has("symbols-outline.nvim") then
table.insert(opts.left, {
title = "Outline",
ft = "outline",
pinned = true,
open = "SymbolsOutline",
})
end
return opts
end,
},
-- prevent neo-tree from opening files in edgy windows