diff --git a/lua/navigator/symbols.lua b/lua/navigator/symbols.lua index caee706..baef5cb 100644 --- a/lua/navigator/symbols.lua +++ b/lua/navigator/symbols.lua @@ -146,6 +146,7 @@ function M.side_panel() local Panel = require('guihua.panel') local buf = vim.api.nvim_get_current_buf() local p = Panel:new({ + scope = 'range', render = function(bufnr) local ft = vim.api.nvim_buf_get_option(bufnr, 'buftype') if ft == 'nofile' or ft == 'guihua' or ft == 'prompt' then diff --git a/lua/navigator/treesitter.lua b/lua/navigator/treesitter.lua index 0f17421..3f26f9b 100644 --- a/lua/navigator/treesitter.lua +++ b/lua/navigator/treesitter.lua @@ -26,6 +26,7 @@ local trace = function(...) end if vim.fn.has('nvim-0.7') == 1 then local trace = require('navigator.util').trace end +trace = log local get_icon = function(kind) if kind == nil or _NgConfigValues.icons.match_kinds[kind] == nil then @@ -641,6 +642,7 @@ function M.side_panel() end return require('navigator.treesitter').all_ts_nodes(b) end, + scope = 'node_scope' }) panel:open(true) end