Skip to content

docs: links take Docusaurus' colours, not Primer's blue - #101

Merged
echarles merged 1 commit into
mainfrom
fix/docs-link-colour
Nov 21, 2026
Merged

echarles merged 1 commit into
mainfrom
fix/docs-link-colour

Conversation

@echarles

Copy link
Copy Markdown
Member

PrimerRoot wrapped the site in Primer's BaseStyles, whose global rule :where(a:not([class*=prc-])…) { color: var(--fgColor-accent) } painted every link of the docs Primer's blue, over Docusaurus' own colours.

A plain div now carries the attributes BaseStyles set (data-portal-root, data-color-mode, data-light-theme, data-dark-theme), so Primer's components and CSS variables still follow the colour mode, and links keep Docusaurus' colours. The footer flex fix is kept.

PrimerRoot wrapped the site in BaseStyles, whose global link rule painted
every link with --fgColor-accent over Docusaurus' own colours. A plain div
now carries the colour-mode attributes Primer's components read.
Copilot AI balanced review requested due to automatic review settings November 21, 2026 04:41
@github-actions

Copy link
Copy Markdown

Binder 👈 Launch a Binder on branch datalayer/jupyter-server-nbmodel/fix%2Fdocs-link-colour

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

There are no active review issues for the Primer wrapper change.

No open issues 🎉

What changed in this PR

This PR prevents Primer’s global link styles from overriding Docusaurus’ colours while preserving Primer theme support and the footer layout.

Changes:

  • Replaces BaseStyles with a plain div carrying portal and colour-mode attributes.
  • Retains inherited typography and flex styling.
  • Updates comments to explain the wrapper’s purpose.
File Description
docs/​src/​theme/​PrimerRoot.tsx Removes the BaseStyles wrapper while retaining theme attributes and layout styles.

Review effort: Balanced

@echarles
echarles merged commit 58454ce into main Nov 21, 2026
9 checks passed
@echarles
echarles deleted the fix/docs-link-colour branch November 21, 2026 04:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants