Skip to content

fix(panels): proportional absorber pins, stale-pin cleanup, double-click to reset#2

Open
nishasdk wants to merge 1 commit into
mainfrom
panel-layout-improvements
Open

fix(panels): proportional absorber pins, stale-pin cleanup, double-click to reset#2
nishasdk wants to merge 1 commit into
mainfrom
panel-layout-improvements

Conversation

@nishasdk
Copy link
Copy Markdown
Owner

@nishasdk nishasdk commented May 17, 2026

What

ResizablePanel reliability fixes

  • Switch wrapperRefs from an index-keyed array to an ID-keyed Map — drag measurement now survives dynamic children changes (e.g. the plan tab appearing mid-drag)
  • Add flexGrow prop to PanelChild so absorbers can be weighted (notes-files gets a smaller weight, leaving the AI terminal ~2/3 of the remaining space)
  • Store absorber pins as flex-grow ratios instead of pixel values so they scale proportionally when the window is resized
  • Detect and clear asymmetric absorber pins (one absorber pinned while siblings are not) — these are stale pixel values from before the child was promoted to absorber status, and would otherwise starve the other absorbers

Double-click on tiling resize handles to unpin

  • Double-clicking a resize handle between two task columns resets both panels to the default equal split without any dragging

Layout cleanup

  • Remove the 40vh max-height from TaskNotesBody — it was a workaround for content-size bubbling up the flex chain; notes-files is now a proper weighted absorber so height is layout-driven, not content-driven

Why

Pinned panels previously stored pixel values, which go stale when the window is resized or when an absorber configuration changes. Storing ratios instead keeps the layout self-healing. The double-click reset gives users a quick escape hatch without needing to drag.

Testing

  1. Pin two panels at different widths, then resize the window → proportions should hold
  2. Double-click a tiling resize handle → both panels should snap back to an equal split
  3. Open the plan tab (which adds a new absorber) → drag should measure correctly with no visual jump
  4. No layout breakage in focus mode or with long plan markdown open

PS. just cosmetic fixes! just wanted to test what submitting a PR on parallel code would look like :)

…ick to reset

ResizablePanel:
- Switch wrapperRefs from an index-keyed array to an ID-keyed Map so drag
  measurement survives dynamic children changes (e.g. plan tab appearing).
- Add flexGrow prop to PanelChild for weighted absorbers (notes-files gets
  a smaller weight so the AI terminal absorbs ~2/3 of remaining space).
- Store absorber pins as flex-grow ratios instead of pixel values so pinned
  panels scale proportionally when the window is resized.
- Detect and clear asymmetric absorber pins (one absorber pinned while
  siblings are not) — these are stale pixel values that would starve siblings.

TilingLayout:
- Double-click on a tiling resize handle calls deletePanelUserSize to unpin
  both neighbours, snapping them back to the default equal split.

TaskNotesBody:
- Remove 40vh max-height cap; notes-files is now a weighted absorber so
  its height is layout-driven, not content-driven.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@nishasdk nishasdk force-pushed the panel-layout-improvements branch from 3f48704 to 01029dd Compare May 17, 2026 11:09
@nishasdk nishasdk changed the title feat(panels): collapsible changed-files panel + proportional absorber layout fix(panels): proportional absorber pins, stale-pin cleanup, double-click to reset May 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant