Skip to content

Use the site's brand blue for light-mode $primary - #2241

Draft
cwickham wants to merge 1 commit into
mainfrom
fix/white-on-primary-contrast
Draft

cwickham wants to merge 1 commit into
mainfrom
fix/white-on-primary-contrast

Conversation

@cwickham

@cwickham cwickham commented Sep 29, 2026 •

Copy link
Copy Markdown
Member

Light mode did not set $primary, so it used the cosmo default, #2780e3. White text on this color is 3.97:1, and text needs 4.5:1 (WCAG 1.4.3). This affects the badges on the triaging page and the header of Quarto's notebook preview. Light mode now uses #447099, which is the dark theme's $blue.

  • White on #447099 is 5.22:1. The notebook-preview title, which Quarto shows at opacity: .9, is 4.59:1.
  • $primary also sets the default Mermaid colors and the focus-ring color. The Mermaid labels change from bright blue to the brand blue. Links, callouts, and dark mode do not change.

Checked with an axe scan of docs/triaging/index.html and docs/authoring/penguins-preview.html before and after: color-contrast (8 instances) is gone. Nothing is new or worse. Full-site scan (all 374 pages, light and dark, before and after all five batch fixes): this finding is gone, and nothing is new or worse.

Check (light mode)

Light mode inherited cosmo's #2780e3, which puts white text at 3.97:1
(badges, .btn-primary, Quarto's notebook-preview header; axe
color-contrast). Use #447099, the dark theme's $blue: white is 5.22:1 and
the faded notebook h6 is 4.59:1.
@github-actions

Copy link
Copy Markdown
Contributor

📝 Preview Deployment

🔍 Full site preview: https://deploy-preview-2241.quarto.org

This branch has not been deployed

No deployments
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