fix(splitter): preserve pane sizes after collapse - 22.1.x - #17554
Merged
Conversation
kdinev
approved these changes
Sep 8, 2026
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The behavioral change is narrowly scoped to collapse/expand sizing, aligns with the reported issue/acceptance criteria, and is covered by targeted unit tests for the key scenarios.
Pull request overview
This PR fixes IgxSplitterPane collapse/expand behavior so panes retain their configured sizes (and min/max constraints) after being collapsed and then expanded, addressing #17545 and preventing sibling panes from being reset to size="auto".
Changes:
- Removed the “reset all pane sizes when any pane is collapsed” initialization behavior in
IgxSplitterComponent. - Updated
IgxSplitterPaneComponentcollapse handling to preserve configured sizes, clear only temporarydragSize, and allow adjacent fixed-size panes to flex-grow while a sibling is collapsed. - Added/updated unit tests to cover horizontal/vertical splitters, fixed-size behavior during collapse, initially-collapsed panes, and drag-size cleanup.
File summaries
| File | Description |
|---|---|
| projects/igniteui-angular/splitter/src/splitter/splitter.component.ts | Stops resetting pane sizes during pane initialization when panes are collapsed, enabling size preservation across collapse/expand. |
| projects/igniteui-angular/splitter/src/splitter/splitter.component.spec.ts | Adds coverage validating size preservation, fixed-size fill behavior during collapse, initial-collapse constraints, and dragSize cleanup. |
| projects/igniteui-angular/splitter/src/splitter/splitter-pane/splitter-pane.component.ts | Preserves size on collapse, clears only sibling dragSize, and adjusts flex-grow logic to let adjacent panes fill released space while collapsed. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
kdinev
requested changes
Sep 8, 2026
kdinev
approved these changes
Sep 8, 2026
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.
Closes #17545
Description
This PR prevents
IgxSplitterPanefrom losing its configured size after being collapsed and expanded.Previously, collapsing a pane reset its siblings to
size="auto", which caused horizontal panes to lose their previous width. The updated behavior:Testing
Added coverage for horizontal and vertical splitters, fixed-size panes, initial collapse, and temporary drag-size cleanup.
Motivation / Context
Type of Change (check all that apply):
Component(s) / Area(s) Affected:
How Has This Been Tested?
Test Configuration:
Screenshots / Recordings
Checklist:
feature/README.MDupdates for the feature docsREADME.MDCHANGELOG.MDupdates for newly added functionalityng updatemigrations for the breaking changes (migrations guidelines)