blob: f88bba6362f9b56b92afff2253fb4061dc7067c5 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
{{define "base"}}
<!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/admin.css">
<link rel="stylesheet" href="/lib/milkdown-crepe/style.css">
<script type="importmap">
{
"imports": {
"@milkdown/crepe": "/lib/node_modules/@milkdown/crepe"
}
}
</script>
</head>
<body>
<nav>
<span class="brand">Admin</span>
<a href="/admin/">Posts</a>
<a href="/admin/new">New Post</a>
</nav>
<main>
{{if eq .ContentTemplate "list-content"}}{{template "list-content" .}}{{end}}
{{if eq .ContentTemplate "form-content"}}{{template "form-content" .}}{{end}}
{{if eq .ContentTemplate "error-content"}}{{template "error-content" .}}{{end}}
</main>
</body>
</html>
{{end}}
|