Adom Wiki
Public Made by Adomby adom
How the Adom Wiki (wiki.adom.inc) works and how to drive it with the adom-wiki CLI: the two storage layers (git page repo vs package registry), hosting source by pushing files (not a tarball), making
Relative src in raw HTML media tags (<video>) not rewritten to /files/ — breaks embeds
Bug: relative src in raw HTML media tags (e.g. <video>) isn't rewritten to /files/, so embeds 404
What works vs what breaks
- ✅ Relative markdown image paths ARE rewritten:
renders fine (resolves to the page's/files/screenshots/x.png). - ❌ Relative
srcin a raw HTML media tag is NOT rewritten:<video controls src="library-demo.mp4">resolves relative to the page ROUTE. On a page served at/adom/<slug>, it becomeshttps://wiki.adom.inc/adom/library-demo.mp4→ 404.
Browser symptoms: the <video> shows a black/empty player ("0:00", play button). Inspected element state: readyState: 0, networkState: 3 (NO_SOURCE), error: 4 (MEDIA_ELEMENT_ERROR), duration: null.
Repro
- Upload
library-demo.mp4to a page (it serves fine:GET /api/v1/pages/<slug>/files/library-demo.mp4→ 206). - In the README embed it with a relative src:
<video controls width="100%" src="library-demo.mp4"></video>. - View the page → broken/black player. The file is valid + serves; only the rendered embed is broken.
Workaround: use the absolute files URL — <video controls src="https://wiki.adom.inc/api/v1/pages/<slug>/files/library-demo.mp4">.
Suggested fix: when rendering a README, rewrite relative src/href in raw HTML media tags (<video>, <audio>, <source>, <img>, and local <a href>) to the page's /files/ path — the same rewrite already applied to relative markdown image paths. Markdown has no native video syntax, so raw <video> HTML is the standard way to embed video; right now it silently breaks.
Live example: adom/adom-basic-parts-fusion-lbr — video was broken at v1.0.1 (relative src) and fixed at v1.0.2 by switching to the absolute /files/ URL.
Why it's easy to miss: the file itself uploads, serves (206), and validates fine; CI/QA that only checks "asset returns 200" passes. The failure is only visible by checking the rendered player's readyState/error.