Skip to content

chore: CSS audit — dark mode badge overrides and surface-hover variable#68

Merged
eclectic-coding merged 1 commit into
mainfrom
chore/css-audit
May 26, 2026
Merged

chore: CSS audit — dark mode badge overrides and surface-hover variable#68
eclectic-coding merged 1 commit into
mainfrom
chore/css-audit

Conversation

@eclectic-coding
Copy link
Copy Markdown
Owner

Closes #36

Summary

Audit findings:

  • No dead CSS — all 110 defined classes are actively used in views, helpers, or JS (many are set via dynamic Ruby string interpolation which the naive grep misses)
  • Badges not dark-mode aware — all 10 badge colour variants (ready, scheduled, claimed, blocked, failed, paused, queue, worker, supervisor, dispatcher) used hardcoded light-mode hex values with no dark overrides; in dark mode they were rendering as bright light-coloured chips on a dark background
  • Table row hover hardcoded#f9fafb showed as a near-white flash on hover in dark mode

Fixes applied:

  • Added --surface-hover: #f9fafb to :root; overridden to #1c2128 in [data-theme="dark"]
  • sqw-table tbody tr:hover now uses var(--surface-hover)
  • Added 10 [data-theme="dark"] .sqw-badge--* overrides using rgba() tints of the semantic colour variables so badges read correctly in both themes

Test plan

  • Toggle dark mode — confirm all badge variants (processes page, jobs page) render correctly with tinted dark backgrounds
  • Hover table rows in dark mode — confirm subtle dark hover, not a white flash
  • Confirm all badges still look correct in light mode
  • bundle exec rake passes clean

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@eclectic-coding eclectic-coding merged commit a0198b8 into main May 26, 2026
4 checks passed
@eclectic-coding eclectic-coding deleted the chore/css-audit branch May 26, 2026 20:55
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.

[v0.7.0] CSS audit

1 participant