Skip to content

[BUGFIX] Rebuild theme assets from their current sources - #1354

Merged
linawolf merged 1 commit into
mainfrom
task/rebuild-stale-theme-assets
Jul 26, 2026
Merged

[BUGFIX] Rebuild theme assets from their current sources#1354
linawolf merged 1 commit into
mainfrom
task/rebuild-stale-theme-assets

Conversation

@CybotTM

@CybotTM CybotTM commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

The generated files in packages/typo3-docs-theme/resources/public/ are older than the sources they are built from. Rebuilding tag 0.40.1 with npm ci && npm run build on Node 24.16.0 (.nvmrc) produces a different theme.min.js, a different theme.css and four different font files; bootstrap.min.js comes out byte-identical.

The info modal of the :php: text roles is broken in 0.40.1

theme.min.js was last built in #1353. #1345 then changed both assets/js/code-inline.js and PhpTextRole.php: signature, flags and summary now travel as separate plain-text data-* attributes, and CodeInlineNode receives '' as help text, so data-details is empty.

The bundle that ships in 0.40.1 predates that change and reads only dataset.details:

// shipped in 0.40.1
t.dataset.details&&(r.innerHTML+=`<p>${l(t.dataset.details)}</p>`)

// rebuilt from the same commit
t.dataset.signature&&n.push(`<code>${l(t.dataset.signature)}</code>`),
t.dataset.flags&&n.push(l(t.dataset.flags)),
t.dataset.summary&&n.push(`<em>${l(t.dataset.summary)}</em>`),
t.dataset.details&&n.push(l(t.dataset.details)),

So the modal renders neither signature nor flags nor summary. Verified in the published image ghcr.io/typo3-documentation/render-guides:0.40.1 (sha256:afc0ec1775c6cac35bfb13b06e7436ee618cc9e54baba083327cad1c9fb2277a): zero occurrences of dataset.signature.

CSS and fonts are FontAwesome 7.2.0, the lock file says 7.3.1

package-lock.json pins FontAwesome 7.3.1 since #1333 (16 Jul). The committed theme.css and the four fa-*.woff2 files are 7.2.0 — the last CSS build (#1290, 26 Jul) ran against outdated node_modules. Icons added in 7.3.1 (fa-matrix, fa-nextcloud, fa-codeberg, fa-lotus and others) resolve to nothing, and the animation timings differ. The theme's own SCSS is in sync: no commit touches assets/sass after #1290.

Reach

deploy-azure-assets.yaml copies resources/public/ verbatim to the Azure CDN on every tag, so the stale files are also served from theme/typo3-docs-theme/0.40.1/.

What this PR does

Runs the documented build and commits its output. No source file is touched.

Nothing in CI catches this — no workflow runs npm run build, and main.yaml only runs npm test. A follow-up PR adds that guard.

The generated files in resources/public/ predate the sources they are
built from:

- theme.min.js was last built in #1353. #1345 then changed
  assets/js/code-inline.js and PhpTextRole so that signature, flags and
  summary travel as separate plain-text data-* attributes while
  data-details stays empty. The shipped bundle only reads
  dataset.details, so the info modal of the :php: text roles shows
  neither signature nor flags nor summary.
- theme.css and the four fa-*.woff2 files are FontAwesome 7.2.0, while
  package-lock.json pins 7.3.1 since #1333. Icons added in 7.3.1
  (fa-matrix, fa-nextcloud, fa-codeberg and others) resolve to nothing.

Both also reach the CDN: deploy-azure-assets.yaml uploads
resources/public/ verbatim on every tag.

Rebuilt with `npm ci && npm run build` on Node 24.16.0 (.nvmrc).
bootstrap.min.js stays byte-identical.

Signed-off-by: Sebastian Mendel <github@sebastianmendel.de>
@linawolf
linawolf added this pull request to the merge queue Jul 26, 2026
Merged via the queue into main with commit 30fbd17 Jul 26, 2026
10 checks passed
@linawolf
linawolf deleted the task/rebuild-stale-theme-assets branch July 26, 2026 09:34
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