feat: Add dynamic side panel width#5177
Closed
chmouel wants to merge 1 commit intojesseduffield:masterfrom
Closed
Conversation
Introduced a new configuration option `dynamicSidePanelWidth` that allows the GUI to automatically adjust the width of side panels based on which panel has focus. When a side panel is focused, the left section expands, and when the main panel is focused, the right section expands. This feature is only applicable in normal screen mode. The feature includes two new configuration options: - `sidePanelFocusedRatio`: Defines the ratio of the side panel's width when a side panel has focus. - `mainPanelFocusedRatio`: Defines the ratio of the main panel's width when the main panel has focus. Added corresponding validation and tests for these new configuration options. Also, included an integration test to verify the functionality of the dynamic side panel width. Signed-off-by: Chmouel Boudjnah <chmouel@chmouel.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Description
Introduced a new configuration option
dynamicSidePanelWidththat allows the GUI to automatically adjust the width of side panels based on which panel has focus. When a side panel is focused, the left section expands, and when the main panel is focused, the right section expands. This feature is only applicable in normal screen mode.The feature includes two new configuration options:
sidePanelFocusedRatio: Defines the ratio of the side panel's width when a side panel has focus.mainPanelFocusedRatio: Defines the ratio of the main panel's width when the main panel has focus.The idea comes from emacs's golden-ratio.el
https://github.com/roman/golden-ratio.el
Demo
recording-20260105-14h29.mp4
Please check if the PR fulfills these requirements
go generate ./...)