Skip to content

Upgrade Docsy theme from v0.12.0 to v0.14.2#170

Open
vinooganesh wants to merge 3 commits intoapache:productionfrom
vinooganesh:vinooganesh/upgradeDocsy
Open

Upgrade Docsy theme from v0.12.0 to v0.14.2#170
vinooganesh wants to merge 3 commits intoapache:productionfrom
vinooganesh:vinooganesh/upgradeDocsy

Conversation

@vinooganesh
Copy link
Collaborator

@vinooganesh vinooganesh commented Feb 14, 2026

Upgrades the Docsy theme to v0.14.2 and fixes the visual regressions that came with it:

  • Bump Docsy from v0.12.0 to v0.14.2 in go.mod

  • Bump Hugo minimum version to 0.155.3 in hugo.toml and deploy.yml

  • Fix navbar turning white by setting $td-navbar-bg-color to $primary

  • Make navbar transparent on cover pages so it blends with the hero image

  • Switch Releases button from btn-secondary to btn-outline-light

  • Add navbar_theme = "dark" for proper light text on the blue navbar

  • Delete outdated navbar.html override (incompatible with v0.14.2)

  • Delete empty hook partials (head-end.html, body-end.html)

  • Remove deprecated [blackfriday] config section

  • Update head.html and scripts.html overrides to match v0.14.2 (dark mode support, scrollspy patch, updated KaTeX handling) while keeping CSP-compliant local jQuery/Lunr loading

  • Related to Consider vendoring the entire docsy template #164

Apache's Content Security Policy on parquet.apache.org blocks scripts
from external CDNs. Docsy loads jQuery from code.jquery.com and Lunr
from unpkg.com, both of which get blocked, breaking all JS on the
production site.

This vendors both libraries in static/js/ and overrides Docsy's
head.html to load them from the site itself. Same versions, just
self-hosted.

jQuery is still needed — Docsy's base.js and offline-search.js both
depend on it (see google/docsy#1436 for their effort to drop it).

Part of apache#163
Upgrades the Docsy theme to v0.14.2 and fixes the visual regressions
that come with it:

- Bump Docsy from v0.12.0 to v0.14.2 in go.mod
- Bump Hugo minimum version to 0.155.3 in hugo.toml and deploy.yml
- Fix navbar turning white by setting $td-navbar-bg-color to $primary
- Make navbar transparent on cover pages so it blends with the hero image
- Switch Releases button from btn-secondary to btn-outline-light
- Add navbar_theme = "dark" for proper light text on the blue navbar
- Delete outdated navbar.html override (incompatible with v0.14.2)
- Delete empty hook partials (head-end.html, body-end.html)
- Remove deprecated [blackfriday] config section
- Update head.html and scripts.html overrides to match v0.14.2
  (dark mode support, scrollspy patch, updated KaTeX handling)
  while keeping CSP-compliant local jQuery/Lunr loading
@vinooganesh vinooganesh changed the title Upgrade Docsy theme from v0.12.0 to v0.14.2 [WIP] Upgrade Docsy theme from v0.12.0 to v0.14.2 Feb 14, 2026
@alamb
Copy link
Collaborator

alamb commented Feb 21, 2026

@vinooganesh this PR has a "WIP" in its title but is not marked as a draft. Is it ready for review?

@alamb
Copy link
Collaborator

alamb commented Feb 21, 2026

Also, what do you think about vendoring the theme? As we continue to add overrides to the partials it seems like it would be easier to understand what we have changed 🤔

@vinooganesh
Copy link
Collaborator Author

Hey @alamb - it wasn't at the time, but now I think it's ready to go. I'll update the title!

Docsy's docs actually recommend going with the hugo go module approach. I'm a little more concerned with vendoring docsy then I am about vendoring lunr and jquery mostly because docsy is a pretty active project. I can imagine upgrading eventually resulting in a huge number of diffs making the CR of actual content more difficult (also I've seen projects that vendor other large repos just decided to never update the dependency because over time it becomes a maintenance pain).

I think the biggest question is how flexible and customizable we want the website to be. I originally chose docsy as just a simple theme that we could pretty easily use/follow that "looked" like other projects (Iceberg was first and I mirrored their setup). If we want a lot more flexibility outside of what docsy provides then I think it's definitely something worth discussing.

@vinooganesh vinooganesh changed the title [WIP] Upgrade Docsy theme from v0.12.0 to v0.14.2 Upgrade Docsy theme from v0.12.0 to v0.14.2 Feb 22, 2026
@vinooganesh vinooganesh force-pushed the vinooganesh/upgradeDocsy branch from 1cc91be to 3c13c12 Compare February 23, 2026 03:52
@alamb
Copy link
Collaborator

alamb commented Feb 27, 2026

Docsy's docs actually recommend going with the hugo go module approach. I'm a little more concerned with vendoring docsy then I am about vendoring lunr and jquery mostly because docsy is a pretty active project.
I can imagine upgrading eventually resulting in a huge number of diffs making the CR of actual content more difficult (also I've seen projects that vendor other large repos just decided to never update the dependency because over time it becomes a maintenance pain).

My biggest concern is that it will actually be even harder to upgrade to new docsy versions due to our copy/paste/modify overrides of the partial templates. Right now to update docsy and not lose the changes in our overrides we'l have to know how to:

  1. Update the docsy version (like this PR)
  2. Manually apply any changes to the partials that have been made in the base docsy theme

I am not sure others would even know that we needed to do 2 and so it would be easy to forget

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.

3 participants