You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When setting panel constraints via group.api.setConstraints({ minimumHeight: 50 }), the minimum height works correctly during runtime but reverts to the default 100px after page refresh. This occurs because addPanel uses a default minimumHeight: 100px if not explicitly provided, overriding the dynamically set constraint.
When initial constraints are set via addPanel parameters (e.g., minimumHeight: 200), subsequent calls to panelGroup.api.setConstraints({ minimumHeight: 50 }) fail to override the initial values. This creates an irreversible constraint configuration where dynamic constraint updates are ignored.
The minimumHeight set via setConstraints should persist after refresh, or at least not be overridden by the default 100px value from addPanel
The setConstraints API should always take precedence over initial values set in addPanel, allowing runtime constraint adjustments regardless of initialization parameters.
Technical Analysis
The constraint system appears to have this priority order: addPanel parameters > setConstraints > group defaults
When it should be: Active setConstraints > addPanel parameters > group defaults
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Browser: Chrome 131
macOS : 14.2
Additional context
The issue arises because addPanel defaults minimumHeight to 100px. When the layout reinitializes after refresh, it uses this default value instead of the dynamically set constraint.
Expected resolution: Either:
Allow setConstraints to override the default values permanently, or
Make addPanel inherit constraints set via setConstraints during initialization.
The text was updated successfully, but these errors were encountered:
Describe the bug
group.api.setConstraints({ minimumHeight: 50 })
, the minimum height works correctly during runtime but reverts to the default 100px after page refresh. This occurs becauseaddPanel
uses a defaultminimumHeight: 100px
if not explicitly provided, overriding the dynamically set constraint.addPanel
parameters (e.g.,minimumHeight: 200
), subsequent calls topanelGroup.api.setConstraints({ minimumHeight: 50 })
fail to override the initial values. This creates an irreversible constraint configuration where dynamic constraint updates are ignored.To Reproduce
https://codesandbox.io/p/sandbox/dawn-glade-8xq494
Steps to reproduce the behavior:
For the first question:
minimumHeight
minimumWidth
:For the second question:
1.Add panel with initial constraints:
Expected behavior
Technical Analysis
The constraint system appears to have this priority order:
addPanel parameters > setConstraints > group defaults
When it should be:
Active setConstraints > addPanel parameters > group defaults
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Additional context
The issue arises because addPanel defaults minimumHeight to 100px. When the layout reinitializes after refresh, it uses this default value instead of the dynamically set constraint.
Expected resolution: Either:
Allow setConstraints to override the default values permanently, or
Make addPanel inherit constraints set via setConstraints during initialization.
The text was updated successfully, but these errors were encountered: