This repository has been archived on 2026-04-03. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
core/server/pages/templates/surfaces/docs.html
Jeffrey Smith a887b4c78b
All checks were successful
CI/CD / detect-changes (push) Successful in 4s
CI/CD / test-frontend (push) Successful in 6s
CI/CD / test-go-pg (push) Successful in 2m46s
CI/CD / test-sqlite (push) Successful in 2m49s
CI/CD / build-and-deploy (push) Successful in 28s
V0.6.2 docs openapi (#37)
Co-authored-by: Jeffrey Smith <jasafpro@gmail.com>
Co-committed-by: Jeffrey Smith <jasafpro@gmail.com>
2026-03-31 12:01:51 +00:00

36 lines
1.1 KiB
HTML

{{/*
Docs surface — v0.6.1
Renders markdown documentation with sidebar navigation.
*/}}
{{define "surface-docs"}}
<div id="docs-mount" class="surface-docs">
<div style="padding:40px;text-align:center;color:var(--text-3);">Loading docs&hellip;</div>
</div>
{{end}}
{{define "css-docs"}}{{end}}
{{define "scripts-docs"}}
<script nonce="{{.CSPNonce}}">
window.__SECTION__ = '{{.Section}}';
</script>
<script type="module" nonce="{{.CSPNonce}}">
const { h, render } = await import('{{.BasePath}}/js/sw/vendor/preact.module.js');
const hooksModule = await import('{{.BasePath}}/js/sw/vendor/hooks.module.js');
const { default: htm } = await import('{{.BasePath}}/js/sw/vendor/htm.module.js');
const html = htm.bind(h);
window.preact = window.preact || { h, render };
window.hooks = window.hooks || hooksModule;
window.html = window.html || html;
// Boot SDK (idempotent)
const { boot } = await import('{{.BasePath}}/js/sw/sdk/index.js?v={{.Version}}');
await boot();
// Mount docs surface
await import('{{.BasePath}}/js/sw/surfaces/docs/index.js?v={{.Version}}');
</script>
{{end}}