docs: fix banner accessibility and hover color contrast#2245
Conversation
Apply WCAG AA compliant colors for the announcement banner: - Light mode: #1d4ed8 (6.70:1 contrast with white text) - Dark mode: #2563eb (5.17:1 contrast with white text, 3.31:1 vs header) - Fix link hover color inheriting accent color instead of staying white Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Review Summary by QodoFix banner accessibility and hover color contrast for WCAG AA compliance
WalkthroughsDescription• Apply WCAG AA compliant banner colors for light and dark modes • Fix dark mode banner background from #1e3a5f to #2563eb for better contrast • Fix banner link hover/focus colors to stay white instead of inheriting accent color • Ensure banner is visually distinct from header with proper color contrast ratios Diagramflowchart LR
A["Banner Styling"] --> B["Light Mode: #1d4ed8"]
A --> C["Dark Mode: #2563eb"]
A --> D["Link Colors"]
D --> E["Hover/Focus: White"]
B --> F["6.70:1 Contrast"]
C --> G["5.17:1 Contrast"]
File Changes1. docs/docs/css/custom.css
|
Code Review by Qodo
1. Banner fg not explicit
|
There was a problem hiding this comment.
Pull request overview
Updates the MkDocs Material announcement banner styling to improve accessibility by ensuring the banner background is visually distinct in both light/dark modes and that banner links remain readable on hover/focus.
Changes:
- Set explicit announcement banner background colors for default and
slate(dark) schemes. - Force banner link color (including hover/focus) to inherit the banner text color for consistent contrast, and underline links for clarity.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@CodiumAI-Agent /improve |
|
@CodiumAI-Agent /review |
|
@qodo-ai /review |
Summary
#1e3a5f(1.49:1 distinction vs header) to#2563eb(3.31:1 distinction)Accessibility
#1d4ed8#2563ebTest plan
🤖 Generated with Claude Code