Feat v0.10.0 panel manifest lifecycle

Panels are a new kernel rendering tier between surfaces and block
renderers, enabling composable companion views (e.g. notes panel
inside chat). This version ships the plumbing layer:

- Manifest validation for panels field (provider map + consumer array)
- Soft-dep warning at install time for unresolved panel consumers
- PanelMeta struct + resolvePanels() resolves consumers at surface load
- window.__PANELS__ injected into base template
- sw.panels SDK module (open/close/toggle/isOpen/isAvailable/list/active)
- Lazy JS loading pipeline with module caching
- 10 new tests (6 validation + 4 resolve)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-03 21:03:22 +00:00
parent 414b2290ce
commit b937580ed8
9 changed files with 561 additions and 2 deletions

View File

@@ -124,6 +124,7 @@
{{if .Manifest}}window.__MANIFEST__ = {{.Manifest | toJSON}};{{end}}
{{if .SurfacePath}}window.__SURFACE_PATH__ = '{{.SurfacePath}}';{{end}}
{{if .SurfaceParams}}window.__SURFACE_PARAMS__ = {{.SurfaceParams | toJSON}};{{end}}
{{if .Panels}}window.__PANELS__ = {{.Panels | toJSON}};{{end}}
</script>
{{/* All surfaces use Preact SDK boot(). Legacy script includes removed.