Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to have outline open in fully collapsed mode #1487

Open
cwinsnes opened this issue Aug 29, 2024 · 1 comment
Open

Add option to have outline open in fully collapsed mode #1487

cwinsnes opened this issue Aug 29, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@cwinsnes
Copy link

Is your feature request related to a problem? Please describe.
When I use the LspSaga outline feature, I commonly want all collapsible objects to be collapsed to get a high level overview of the current file.

I have tried setting detail=false in my lspsaga setup which does not seem to do this action and I don't see any other available option in the documentation (https://nvimdev.github.io/lspsaga/outline/) that looks applicable.

Describe the solution you'd like
I would like to see an option to open the outline with every collapsable object in the collapsed state by default. It could for example look like

require('lspsaga').setup({
	-- The default value of collapsed could be false to align with current behaviour
	outline = { collapsed = true }
})

Describe alternatives you've considered
An alternative solution could be the already requested feature (#1435) where one has to press the "collapse all" button when using the outline.

Another possible solution would be to add a keybind which lets you jump to the next collapsible object in the list so that one can jump between high level objects in an easy way. This keybind would be useful for getting a slightly better high level overview of the file, but I belive it to be less useful for the problem at hand.

Additional context
To me, it sounds similar in scope to the already mentioned feature request of being able to collapse all items in the outline (#1435) so the two features could probably be implemented in tandem.

@cwinsnes cwinsnes added the enhancement New feature or request label Aug 29, 2024
@TheNoeTrevino
Copy link

this would be a great addition! i would love to have this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants