Skip to content

[backport] refactor: move the site theme and chrome into a local extension - #2290

Merged
cderv merged 1 commit into
prereleasefrom
sync-2222-to-prerelease
Oct 16, 2026
Merged

cderv merged 1 commit into
prereleasefrom
sync-2222-to-prerelease

Conversation

@cderv

@cderv cderv commented Oct 15, 2026

Copy link
Copy Markdown
Member

Important

Backport from #2222

The automatic backport failed on a _freeze conflict in docs/authoring/cross-references.qmd, so this is a manual cherry-pick.
Prerelease already has the Typst lof/lot paragraph from #2272 on that page, so the freeze was regenerated for the prerelease source instead of taking main's.

Apart from that freeze, the diff is identical to the #2222 squash.
The prerelease banner keeps working: _quarto-prerelease-docs.yml still loads prerelease-banner.scss through the prerelease-docs profile, in light and dark.

Test Plan

  • Compare the non-freeze patch with the refactor: move the site theme and chrome into a local extension #2222 squash: identical
  • Render docs/authoring/placeholder.qmd with the prerelease-docs profile: both the light and dark Bootstrap CSS end with #quarto-announcement at #e60033
  • Deploy preview shows the site with the red prerelease banner in light and dark

Move the site theme, scripts, Lua filters and page chrome into a local
extension at _extensions/quartoorg/, used through a quartoorg project
type. Pages inherit quartoorg-html from the project instead of naming
it, so the theme is set in one place and a page cannot drop it
silently. This centralises the themes and makes the site easier to
maintain, and it lets #2140 pick up the same chrome.

- Move the page chooser shortcode and the accessibility fixes from
  main into the extension, with their CSS in the theme SCSS.
- Move brand images to assets/images/ and redirect the old root URLs
  that other sites and docs still load: /quarto.png, /favicon.png, the
  og:image files, and the hero and Posit logo images. Files the home
  page still serves from images/ stay where they are.
- Add _tools/check-site-format.ts to CI and the pre-commit hook. It
  fails when a format: html page drops the site theme.
- Dark mode borders use $gray-400, which is 3.70:1 against the page
  instead of 1.08:1. The main banner is brand blue in dark mode too,
  and the prerelease banner moves to #e60033 (white text 4.76:1).

Notebook preview pages still render with the built-in html format, so
they lose the Posit badge, code copy buttons and site grid widths.

See quarto-dev/quarto-cli#14954

(cherry picked from commit ac878df)
@cderv
cderv force-pushed the sync-2222-to-prerelease branch from ab0f8cd to c6317de Compare October 15, 2026 16:55
@github-actions

Copy link
Copy Markdown
Contributor

📝 Preview Deployment

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

🔄 Modified Documents

@cderv
cderv merged commit eebb1a3 into prerelease Oct 16, 2026
5 checks passed
@cderv
cderv deleted the sync-2222-to-prerelease branch October 16, 2026 10:13
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.

2 participants