From 4cbee4da97dcc2832cd354142aa9909a80070952 Mon Sep 17 00:00:00 2001 From: Fuwn Date: Mon, 19 Jan 2026 23:05:26 -0800 Subject: feat: Add OpenCode-compatible theme loader Add support for loading and applying OpenCode-compatible themes via URL. Fetches theme JSON, resolves color references, generates CSS variables and Tailwind class overrides to apply the theme seamlessly. Features: - Add theme_url config field under site section - Fetch and parse OpenCode theme.json format - Generate CSS custom properties (--theme-*) for all theme colors - Generate Tailwind class overrides to apply theme colors - Support both light and dark modes - Template.CSS type for safe CSS injection Example usage: site: theme_url: "https://raw.githubusercontent.com/anomalyco/opencode/.../opencode.json" Theme schema: https://opencode.ai/theme.json --- internal/server/templates/index.html | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'internal/server/templates') diff --git a/internal/server/templates/index.html b/internal/server/templates/index.html index db4c61a..6bdfeff 100644 --- a/internal/server/templates/index.html +++ b/internal/server/templates/index.html @@ -11,6 +11,12 @@ {{end}} + {{if .ThemeCSS}} + + {{end}}