Add asset support to extension API for server-side rendering
This adds the infrastructure for extensions to return binary assets
(like PNG images) that will be written alongside HTML output. This
enables server-side rendering of diagrams instead of client-side
JavaScript rendering.
API changes:
- New `asset` type: { asset_filename: string; asset_content: bytes }
- `extension_output` now includes `assets: asset list` field
- `Page.t` includes assets collected from extensions
- `Renderer.page` includes assets to write with the page
- `Renderer.traverse` callback now receives assets parameter
The HTML generator writes assets to the same directory as the HTML file.
Extensions can use `__ODOC_ASSET__filename__` placeholders in HTML content
to reference assets (placeholder substitution to be added in follow-up).
All existing extensions updated to return `assets = []`.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>