-
No devices yet
-
Device registration arrives in Phase 2. Until then the
- dashboard, session login and /health are the working pieces.
+ {{if .Devices}}
+ {{template "device-cards.html" .}}
+ {{else}}
+
+
No devices yet
+
Add Harry's phone or Finn's computer to give it a name,
+ a child, and a platform. Nothing is enforced until a later phase.
+
+ {{end}}
+
+
+
+
+
Activity
+ append-only audit
+ {{template "audit-list.html" .}}
diff --git a/internal/web/templates/device-form.html b/internal/web/templates/device-form.html
new file mode 100644
index 0000000..be5399b
--- /dev/null
+++ b/internal/web/templates/device-form.html
@@ -0,0 +1,80 @@
+{{define "device-form.html"}}
+
+
+
+
+
+
{{.Title}} — Internet Use Control
+
+
+
+
+
+
+
+
+ ← Dashboard
+ {{.Heading}}
+ {{.Sub}}
+
+
+ {{if .Error}}{{.Error}}
{{end}}
+
+
+
+
+
+
+{{end}}
diff --git a/internal/web/templates/partials/audit-list.html b/internal/web/templates/partials/audit-list.html
new file mode 100644
index 0000000..dcf9b2c
--- /dev/null
+++ b/internal/web/templates/partials/audit-list.html
@@ -0,0 +1,14 @@
+{{define "audit-list.html"}}
+ {{range .Audit}}
+ -
+ {{.ActionLabel}}
+
+ {{if .DeviceName}}{{.DeviceName}}{{end}}
+ {{if .Detail}}{{.Detail}}{{end}}
+
+ {{.Actor}} · {{.CreatedAtLocal}}
+
+ {{else}}
+ - No activity yet.
+ {{end}}
+
{{end}}
diff --git a/internal/web/templates/partials/device-cards.html b/internal/web/templates/partials/device-cards.html
new file mode 100644
index 0000000..3ad0cf1
--- /dev/null
+++ b/internal/web/templates/partials/device-cards.html
@@ -0,0 +1,49 @@
+{{define "device-cards.html"}}
+ {{range .Devices}}
+
+
+
+
+ {{if .Locked}}Blocked{{if .TimeLeft}} · {{.TimeLeft}}{{end}}{{else}}No block active{{end}}
+
+ {{if .Until}}Lifts {{.UntilLocal}}
{{end}}
+
+
+
+ {{if .Locked}}
+
+ {{end}}
+
Edit
+
+
+
+ {{.Topic}}
+
+ {{end}}
+
{{end}}