-- Silent keymap option local opts = { silent = true } return { { "folke/edgy.nvim", optional = true, opts = function(_, opts) opts.right = opts.right or {} table.insert(opts.right, "aerial") table.insert(opts.right, { title = "hurl.nvim", ft = "hurl-nvim", size = { width = 0.5 }, }) end, }, { "stevearc/aerial.nvim", keys = { { "ta", "AerialToggle", desc = "AerialToggle" }, }, config = function() local status_ok, aerial = pcall(require, "aerial") if not status_ok then return end aerial.setup({ -- optionally use on_attach to set keymaps when aerial has attached to a buffer on_attach = function(bufnr) -- Jump forwards/backwards with '{' and '}' vim.keymap.set("n", "{", "AerialPrev", { buffer = bufnr }) vim.keymap.set("n", "}", "AerialNext", { buffer = bufnr }) vim.keymap.set("n", "fi", "Telescope aerial", opts) end, }) local tele_status_ok, telescope = pcall(require, "telescope") if not tele_status_ok then return end -- Define a custom command to open aerial with telescope vim.keymap.set("n", "fi", "Telescope aerial", { desc = "Telescope Aerial", }) telescope.load_extension("aerial") end, }, }