Skip to content

Unify expand and collapse timing - #364

Merged
MaggieAppleton merged 1 commit into
mainfrom
design/expand-collapse-timing
Oct 8, 2026
Merged

MaggieAppleton merged 1 commit into
mainfrom
design/expand-collapse-timing

Conversation

@MaggieAppleton

@MaggieAppleton MaggieAppleton commented Oct 7, 2026 •

Copy link
Copy Markdown
Collaborator

Why

Revealing more content moved at four speeds on two curves: the sidebar 250ms, the research fold 420ms rows + 300ms opacity after a 120ms delay (about 540ms in all, the slowest motion in the app), the decision fold 200ms on --ease-out, and Chat tool-call details not at all (display: none).

What changed

  • One preset: --acc-expand 250ms open, --acc-collapse 200ms close, --motion-move. --acc-collapse goes from 250ms to 200ms, and the collapse contract's closeDuration follows (200).
  • Research fold and decision fold use those tokens (open = expand, close = collapse); the 120ms delay and the bespoke 420/300ms values are gone, with their preserved-values.json exception.
  • Chat tool-call details now use MotionDisclosure with the collapse contract, so they animate like the sidebar (previously instant).
  • Reduced motion is unchanged: .motion-collapse and the folds still settle with transition: none.
  • Not done: decision "Add an option" row swap (an input/focus swap in packages/question, not a fold) and the broader token cleanup (finding 9). Left closeDuration untouched in other contracts to avoid Keep workspace chrome still when switching documents #346.

Screenshots

Research, decision, Chat, and sidebar folds at 50, 150, and 300 milliseconds after opening

Timing, not layout, changed. Height/opacity frame sequences every 50ms (before: main at :8795, after: this branch at :8864). The research, decision and tool-details folds were sampled by mounting the shipped classes in the live page, because the fake server has no Planner/research; the sidebar disclosure is the real component.

  • Before: frames-before.txt (not committed), after: frames-after.txt.
  • Settle time before to after: research open 533 to 260ms, research close 416 to 202ms, decision fold 199 to 259ms open / 210ms close, tool details instant to 258ms open / 208ms close, sidebar 253/324 to 243/246ms.

Testing

  • bun run ci passes; bun run types passes.
  • bun test apps/web packages/editor packages/question: all pass; tokens.test.ts timed out under machine load, passes alone with --timeout 60000.
  • Local e2e suspended per the brief; relying on PR CI.

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@MaggieAppleton
MaggieAppleton force-pushed the design/expand-collapse-timing branch from 232ca12 to ca4c981 Compare October 8, 2026 15:21
@MaggieAppleton
MaggieAppleton enabled auto-merge (rebase) October 8, 2026 15:21
@MaggieAppleton
MaggieAppleton merged commit 27f40ff into main Oct 8, 2026
4 checks passed
@MaggieAppleton
MaggieAppleton deleted the design/expand-collapse-timing branch October 8, 2026 15:31
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