Skip to content

fix(explore): make the whole collapsed rail expand on tap#131

Merged
jrosskopf merged 1 commit into
mainfrom
fix/both-panes-expand
May 31, 2026
Merged

fix(explore): make the whole collapsed rail expand on tap#131
jrosskopf merged 1 commit into
mainfrom
fix/both-panes-expand

Conversation

@jrosskopf
Copy link
Copy Markdown
Contributor

Summary

A collapsed pane couldn't be re-opened by a real mouse — "I can collapse, but afterwards expand is not possible." The expand chevron was a centered 16px IconButton, so only that tiny icon was tappable. Collapsing lives in a full-width 28px header bar (easy); expanding was the small rail icon (usually missed). When both panes collapse it's worst: the right rail balloons to a wide blank region (leftW = rail, rightW = w - rail - divW) that ignores clicks everywhere but the icon.

Fix. Make the entire collapsed rail an InkWell(onTap: onToggle), chevron centered for affordance, so a tap anywhere in the rail re-expands it.

Why tests missed it. tester.tap(find.bySemanticsLabel(...)) hits the widget's centre — exactly where the icon is — so every collapse/expand test passed while real off-icon clicks failed.

Test plan

test/crm/both_panes_collapse_test.dart (no-mock, real fixture, pointer path):

  • collapse both panes, then both expand chevrons work;
  • a tap anywhere in the collapsed rail re-expands it (not just the icon) — uses tapAt at an offset away from the centered icon; verified red under the old icon-only target, green after.

flutter analyze clean; full suite green (97 tests). Adds docs/notes/discovered/2026-05-31-collapsed-rail-tiny-hit-target.md.

🤖 Generated with Claude Code

A collapsed pane could not be re-opened by a real mouse: the expand
chevron was a centered 16px IconButton, so only that tiny icon was
tappable. Collapsing (a full-width 28px header bar) was easy; expanding
(the small rail icon) usually missed — and when both panes collapsed,
the right rail ballooned to a wide blank region that ignored clicks
everywhere but the icon.

Widget tests missed it because `tester.tap` hits the widget centre —
exactly where the icon is. Make the entire collapsed rail an
`InkWell(onTap: onToggle)` so a tap anywhere re-expands it.

Tests (both no-mock, real fixture, pointer path):
- collapse both panes, then both expand chevrons work;
- a tap *off* the icon (top of the rail, via tapAt) still expands —
  verified red under the old icon-only target, green after.
Adds a discovered-note on small-hit-target bugs that `tester.tap` hides.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@jrosskopf jrosskopf merged commit be9038a into main May 31, 2026
1 check passed
@jrosskopf jrosskopf deleted the fix/both-panes-expand branch May 31, 2026 04:56
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