Skip to content

feat(gui): complete the reduced-motion story - #256

Merged
CameronBrooks11 merged 1 commit into
mainfrom
feat/250-reduced-motion
Jun 27, 2026
Merged

CameronBrooks11 merged 1 commit into
mainfrom
feat/250-reduced-motion

Conversation

@CameronBrooks11

Copy link
Copy Markdown
Member

Closes #250. Part of epic #246 (post-redesign audit follow-ups).

Problem

Reduced-motion only zeroed the CSS transition tokens. Svelte JS transitions (Toasts fly/fade/flip), scrollIntoView({behavior:"smooth"}) in StreamLog, and keyframe animations (the viewport spinner) kept moving — the "complete reduced-motion story" was overstated.

Fix

  • One global @media (prefers-reduced-motion: reduce) block in reset.css flattening all CSS animations, transitions, and smooth scroll to near-instant (universal selector + !important — the canonical a11y pattern; scoped stylelint-disable for the required !important). Covers keyframe loops like the spinner.
  • JS-driven motion the CSS can't touch is gated via svelte/motion's prefersReducedMotion: Toasts collapse to duration 0; StreamLog scroll uses "auto".
  • Removed the superseded token-zeroing block + its overstated comment.

Verification

  • lint:css, lint:css:vars, check:svelte (0 errors), tsc, 316/316 tests ✓
  • App reloads clean (no console errors from the svelte/motion integration).

The prior reduced-motion handling only zeroed the CSS transition tokens; Svelte
JS transitions, smooth-scroll, and keyframe animations (the viewport spinner)
kept moving — the "complete reduced-motion" claim was overstated.

- Replace the token-only zeroing with one global @media (prefers-reduced-motion)
  block in reset.css that flattens ALL CSS animations, transitions, and smooth
  scrolling to near-instant (universal selector with !important, the canonical
  a11y pattern; scoped stylelint-disable for the required !important). This also
  covers keyframe loops like the viewport spinner.
- Gate the JS-driven motion the CSS block cannot reach via svelte/motion's
  prefersReducedMotion: Toasts' fly/fade/flip collapse to duration 0, and
  StreamLog's scrollIntoView uses "auto" instead of "smooth".
- Drop the superseded tokens.css reduced-motion block and its overstated comment.

Part of #246. Closes #250.
@CameronBrooks11
CameronBrooks11 merged commit e425732 into main Jun 27, 2026
18 checks passed
@CameronBrooks11
CameronBrooks11 deleted the feat/250-reduced-motion branch June 27, 2026 15:38
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.

GUI: complete the reduced-motion story

1 participant