summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorClaude <noreply@anthropic.com>2026-03-31 12:11:18 +0200
committerClaude <noreply@anthropic.com>2026-03-31 12:11:18 +0200
commit3cb7c82cf7c4e050148f69be23590a7fbe587a27 (patch)
treed2b6506db2de72b3a6982cfbe69925b88936de90 /templates
parent33f214f6cd9729473bb55fd7b3b923d5d960bb98 (diff)
downloadnebbet.no-3cb7c82cf7c4e050148f69be23590a7fbe587a27.tar.xz
nebbet.no-3cb7c82cf7c4e050148f69be23590a7fbe587a27.zip
Add static site builder: SQLite-backed MD→HTML pipeline
- cmd/nebbet: CLI with build [--watch] and user add/passwd/delete/list - internal/builder: markdown→HTML, component injection via HTML comments, auto importmap from lib/, fsnotify watch with 150ms debounce - internal/db: meta.db (page index, tag queries) + search.db (FTS5) - internal/sqlitedrv: minimal CGO database/sql driver for system libsqlite3 - internal/auth: htpasswd-compatible bcrypt password file management - templates/base.html + admin.html, styles/main.css + admin.css - nginx.conf with auth_basic for /admin, clean URLs, gzip - nebbet.service systemd unit for watch daemon - Example content/index.md and components/site-greeting.js https://claude.ai/code/session_01HTc1BCBCiMTEB54XQP1Wz9
Diffstat (limited to 'templates')
-rw-r--r--templates/admin.html22
-rw-r--r--templates/base.html18
2 files changed, 40 insertions, 0 deletions
diff --git a/templates/admin.html b/templates/admin.html
new file mode 100644
index 0000000..c0ebeaa
--- /dev/null
+++ b/templates/admin.html
@@ -0,0 +1,22 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+ <meta charset="UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+ <title>Admin — {{.Title}}</title>
+ <link rel="stylesheet" href="/styles/main.css">
+ <link rel="stylesheet" href="/styles/admin.css">
+ {{.ImportMapTag}}
+ {{- range .ComponentScripts}}
+ <script type="module" src="{{.}}"></script>
+ {{- end}}
+</head>
+<body class="admin">
+ <nav class="admin-nav">
+ <a href="/admin/">Dashboard</a>
+ </nav>
+ <main>
+ {{.Content}}
+ </main>
+</body>
+</html>
diff --git a/templates/base.html b/templates/base.html
new file mode 100644
index 0000000..9128b2e
--- /dev/null
+++ b/templates/base.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+ <meta charset="UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+ <title>{{.Title}}</title>
+ <link rel="stylesheet" href="/styles/main.css">
+ {{.ImportMapTag}}
+ {{- range .ComponentScripts}}
+ <script type="module" src="{{.}}"></script>
+ {{- end}}
+</head>
+<body>
+ <main>
+ {{.Content}}
+ </main>
+</body>
+</html>