Upgrade H5P core library with split-out font and theme stylesheets
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Overview
Upgrade the vendored H5P core to upstream h5p/h5p-php-library@cb64a1f, adding the stylesheets upstream split out. The automated bump in #15455 drops them.
Complexity: Low Target branch: develop
Context
- Upstream moved
@font-facerules intostyles/h5p-fonts.css. - Upstream moved the
--h5p-theme-*variables intostyles/h5p-theme-variables.cssandstyles/h5p-theme.css. kolibri/plugins/h5p_viewer/h5p_build/h5pBundle.jsimports none of these files.- With #15455 as-is:
- icon glyphs render blank or as tofu
- the confirmation dialog has no dim backdrop or shadow (reproduced in QA: Lesson 9, Check → Finish)
- with
theme: truethe dialog renders unstyled, and axe reports a criticalbutton-nameviolation
The Change
h5pBundle.jsshould importh5p-fonts.css,h5p-theme-variables.cssandh5p-theme.css, in upstream's order.downloadH5PVendor.jsshould exempth5p-fonts.cssfrom the per-file purge. ItsfontFace: truepurge would empty a fonts-only file.- Rebuild with
pnpm run build-h5pinkolibri/plugins/h5p_viewerand commit the output.
Acceptance Criteria
- [ ]
.h5p-commit-shaiscb64a1f3884408487c3178e31fc140f5d45ca165or newer - [ ] Built CSS in
static/h5p/contains@font-face{font-family:h5p - [ ] Built CSS contains
--h5p-theme-main-cta-base: - [ ]
.woff2font files are present instatic/h5p/ - [ ] H5P icon glyphs render correctly
- [ ] The confirmation dialog in Lesson 9 (Check → Finish) has its backdrop and shadow
- [ ] axe reports no
button-nameviolation on that dialog
References
- #15455
- https://github.com/h5p/h5p-php-library/compare/4237a6c75a35a10ea78e303a4380938e2d958543...cb64a1f3884408487c3178e31fc140f5d45ca165
AI usage
Drafted by Claude Code from its review of #15455, at a maintainer's request. The bot checked the file paths against develop.
Plan: Bump vendored H5P core to h5p/h5p-php-library@cb64a1f with its fonts and theme stylesheets bundled.
- [ ] Bundle the split-out stylesheets and rebuild
- [ ] Verify rendering in a live H5P activity
- [ ] Self-review the produced code
Assumptions — the issue did not settle these; say so if one is wrong.
h5p-fonts.cssis exempted whole, per the issue: ships Inter + Open Sans (~1 MB woff2); if too heavy, keep only theh5p/h5p-themefaces.- Existing imports reorder to upstream's (confirmation-dialog before core-button); if wrong, the cascade between those two differs from upstream's.
- No OFL/LICENSE text is copied beside the Inter and Open Sans woff2; if redistribution needs it, copy
fonts/*/OFL.txtandLICENSE.txtintostatic/h5p/. - Any H5P activity with a Check → Finish confirmation dialog stands in for "Lesson 9"; if that lesson exercises something else, QA misses it.
@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
- Implemented code following the pre-approved plan using test-driven development (red-green-refactor)
- Ran the project's full test suite and linter before committing
- For UI changes: captured live screenshots to verify rendering
- For backend changes: verified with example API/CLI output
@rtibbles Blocked — these cannot be assumed either way:
- Confirmation-dialog shadow: upstream cb64a1f removed it on purpose (8703485d "VA-1168 Remove popup shadow"). Restore it with a Kolibri override stylesheet after the vendor CSS (
box-shadow: 0 0 6px 6px rgba(10,10,10,.3)), or drop "shadow" from the AC and match upstream?
@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
- Implemented code following the pre-approved plan using test-driven development (red-green-refactor)
- Ran the project's full test suite and linter before committing
- For UI changes: captured live screenshots to verify rendering
- For backend changes: verified with example API/CLI output
Restore with the override.