Skip to content

Fix dark button hover contrast - #621

Merged
zacjones93 merged 43 commits into
codex/ui-page-coverage-start-crewfrom
codex/ui-button-hover-contrast
Jul 15, 2026
Merged

Fix dark button hover contrast#621
zacjones93 merged 43 commits into
codex/ui-page-coverage-start-crewfrom
codex/ui-button-hover-contrast

Conversation

@zacjones93

@zacjones93 zacjones93 commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

What changed

  • raise the shared default Button's dark hover background from bg-primary/80 to bg-primary/90
  • explicitly hover the confirmation-dialog trigger during the dark Storybook contrast audit
  • document pointer-hover coverage in the UI library contract

Why

The dark default Button combined text-primary-foreground with dark:hover:bg-primary/80, producing only 3.85:1 contrast for normal text. The 90% hover background preserves the interaction treatment while raising the pair above WCAG AA.

Light hover behavior and all other Button variants are unchanged.

Validation

  • red-before Storybook audit: confirmation trigger hover (dark) failed at 3.85:1
  • green-after full Storybook semantic contrast suite: 2/2 tests pass across all stories and themes
  • Storybook static build
  • @repo/ui: 25 tests, typecheck, build, focused Biome
  • Start and Crew typechecks
  • UI inventory and page-coverage freshness checks
  • lat check
  • GitNexus detect-changes: low risk, zero affected flows

Stack

Base: codex/ui-page-coverage-start-crew


Summary by cubic

Fix dark theme default Button hover contrast to meet WCAG AA. Raises hover background to bg-primary/90 and adds an explicit hover audit in Storybook.

  • Bug Fixes
    • Default Button (dark) hover changed from dark:hover:bg-primary/80 to dark:hover:bg-primary/90; light and other variants unchanged.
    • Storybook contrast test now hovers the confirmation dialog trigger in dark and asserts zero violations.
    • UI library contract updated to document pointer-hover coverage.

Written for commit 1edf638. Summary will update on new commits.

Review in cubic

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@zacjones93, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 52 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 554d33d5-17ef-43cb-9442-13481abd8347

📥 Commits

Reviewing files that changed from the base of the PR and between 373f85b and 1edf638.

📒 Files selected for processing (3)
  • apps/wodsmith-start/storybook-tests/semantic-contrast.spec.ts
  • lat.md/ui-library.md
  • packages/ui/src/components/button.tsx
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/ui-button-hover-contrast

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@zacjones93

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@zacjones93

Copy link
Copy Markdown
Contributor Author

Independent review: LGTM — no blocking findings. I verified the exact base-to-head diff is limited to the shared default Button dark-hover opacity, its Storybook hover assertion, and matching LAT documentation. The change raises the dark hover foreground contrast from ~3.87:1 to ~4.65:1 while preserving the light hover and every other variant. The exact Storybook contrast suite passed once plus five repeated runs (10/10 tests), git diff --check passed, and lat check passed.

@zacjones93 zacjones93 closed this Jul 15, 2026
@zacjones93
zacjones93 merged commit d6316c1 into codex/ui-page-coverage-start-crew Jul 15, 2026
53 of 224 checks passed
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