fix(panel): rebalance diff windows after auto-width resize#48
Merged
dlyongemallo merged 1 commit intomainfrom Mar 20, 2026
Merged
fix(panel): rebalance diff windows after auto-width resize#48dlyongemallo merged 1 commit intomainfrom
dlyongemallo merged 1 commit intomainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adjusts Diffview panel window resizing so that when an auto-width split panel changes width, the rest of the diff layout rebalances accordingly.
Changes:
- Rebalance window sizes after an auto-width panel resize (
Panel:resize()). - Avoid running
wincmd =onFilePanel:open()/FileHistoryPanel:open()when using split + auto width (to prevent redundant/undesired equalization).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| lua/diffview/ui/panel.lua | Rebalances windows after an auto-width resize by invoking window equalization before re-rendering. |
| lua/diffview/scene/views/file_history/file_history_panel.lua | Skips wincmd = during open when split width is auto. |
| lua/diffview/scene/views/diff/file_panel.lua | Skips wincmd = during open when split width is auto. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
8cd89a5 to
681c93f
Compare
Owner
Author
|
@copilot I think you may have been wrong about the |
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.
No description provided.