feat(web): add vanilla JS/CSS SPA with embed.FS

Stream view with date grouping, card view sorted by usage, capture
bar with client-side grammar parsing, tag rail filter, detail pane
with card affordances (template slot fill, checklist toggle, link
open), promote modal with auto-detect, keyboard shortcuts (j/k/n/p/
Enter/dd/1/2). Dark theme, responsive layout. Embedded in Go binary.
This commit is contained in:
2026-05-14 11:38:45 -04:00
parent 6de174e474
commit 5b0d0a8f33
7 changed files with 1170 additions and 2 deletions
+7 -1
View File
@@ -3,6 +3,7 @@ package cmd
import (
"context"
"fmt"
"io/fs"
"net/http"
"os"
"os/signal"
@@ -14,6 +15,8 @@ import (
"github.com/spf13/cobra"
)
var WebFS fs.FS
var (
servePort int
serveDev bool
@@ -51,7 +54,10 @@ func runServe(_ *cobra.Command, _ []string) error {
}
defer store.Close()
router := api.NewRouter(store, serveDev)
var router = api.NewRouter(store, serveDev)
if WebFS != nil {
router = api.NewRouter(store, serveDev, WebFS)
}
addr := fmt.Sprintf(":%d", port)
srv := &http.Server{