replaced symbols-outline for outline.nvim
This commit is contained in:
		
							parent
							
								
									0a4f9cec56
								
							
						
					
					
						commit
						cfd0733f64
					
				
					 3 changed files with 52 additions and 32 deletions
				
			
		| 
						 | 
				
			
			@ -180,24 +180,43 @@ require('lazy').setup({
 | 
			
		|||
        }
 | 
			
		||||
    },
 | 
			
		||||
    {
 | 
			
		||||
        'simrat39/symbols-outline.nvim',
 | 
			
		||||
 | 
			
		||||
        "hedyhli/outline.nvim",
 | 
			
		||||
        lazy = true,
 | 
			
		||||
        cmd = { "Outline", "OutlineOpen" },
 | 
			
		||||
        keys = { -- Example mapping to toggle outline
 | 
			
		||||
            { "<leader>o", "<cmd>Outline<CR>", desc = "Toggle outline" },
 | 
			
		||||
        },
 | 
			
		||||
        opts = {
 | 
			
		||||
            highlight_hovered_item = true,
 | 
			
		||||
            show_guides = true,
 | 
			
		||||
            auto_preview = false,
 | 
			
		||||
            position = 'right',
 | 
			
		||||
            relative_width = true,
 | 
			
		||||
            width = 30,
 | 
			
		||||
            auto_close = false,
 | 
			
		||||
            show_numbers = false,
 | 
			
		||||
            show_relative_numbers = false,
 | 
			
		||||
            show_symbol_details = true,
 | 
			
		||||
            preview_bg_highlight = 'Pmenu',
 | 
			
		||||
            autofold_depth = nil,
 | 
			
		||||
            auto_unfold_hover = true,
 | 
			
		||||
            fold_markers = { '', '' },
 | 
			
		||||
            wrap = false,
 | 
			
		||||
        }
 | 
			
		||||
            outline_items = {
 | 
			
		||||
                -- Show extra details with the symbols (lsp dependent) as virtual next
 | 
			
		||||
                show_symbol_details = true,
 | 
			
		||||
                -- Show corresponding line numbers of each symbol on the left column as
 | 
			
		||||
                -- virtual text, for quick navigation when not focused on outline.
 | 
			
		||||
                -- Why? See this comment:
 | 
			
		||||
                -- https://github.com/simrat39/symbols-outline.nvim/issues/212#issuecomment-1793503563
 | 
			
		||||
                show_symbol_lineno = true,
 | 
			
		||||
                -- Whether to highlight the currently hovered symbol and all direct parents
 | 
			
		||||
                highlight_hovered_item = true,
 | 
			
		||||
                -- Whether to automatically set cursor location in outline to match
 | 
			
		||||
                -- location in code when focus is in code. If disabled you can use
 | 
			
		||||
                -- `:OutlineFollow[!]` from any window or `<C-g>` from outline window to
 | 
			
		||||
                -- trigger this manually.
 | 
			
		||||
                auto_set_cursor = true,
 | 
			
		||||
                -- Autocmd events to automatically trigger these operations.
 | 
			
		||||
                auto_update_events = {
 | 
			
		||||
                    -- Includes both setting of cursor and highlighting of hovered item.
 | 
			
		||||
                    -- The above two options are respected.
 | 
			
		||||
                    -- This can be triggered manually through `follow_cursor` lua API,
 | 
			
		||||
                    -- :OutlineFollow command, or <C-g>.
 | 
			
		||||
                    follow = { 'CursorMoved' },
 | 
			
		||||
                    -- Re-request symbols from the provider.
 | 
			
		||||
                    -- This can be triggered manually through `refresh_outline` lua API, or
 | 
			
		||||
                    -- :OutlineRefresh command.
 | 
			
		||||
                    items = { 'InsertLeave', 'WinEnter', 'BufEnter', 'BufWinEnter', 'TabEnter', 'BufWritePost' },
 | 
			
		||||
                },
 | 
			
		||||
            },
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    {
 | 
			
		||||
        'stevearc/dressing.nvim',
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue