auth-ui: picocss
diff --git a/core/auth/ui/templates/base.html b/core/auth/ui/templates/base.html
new file mode 100644
index 0000000..508b210
--- /dev/null
+++ b/core/auth/ui/templates/base.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html lang="en" data-theme="light">
+ <head>
+ <link rel="stylesheet" href="/static/pico.min.css">
+ <meta charset="utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <title>{{ block "title" . }}Title{{ end }}</title>
+ </head>
+<body>
+ <main class="container">
+ {{ block "main" . }}{{ end }}
+ </main>
+</body>
+</html>
+
diff --git a/core/auth/ui/templates/consent.html b/core/auth/ui/templates/consent.html
index 1eb4a1e..3a504a5 100644
--- a/core/auth/ui/templates/consent.html
+++ b/core/auth/ui/templates/consent.html
@@ -1,21 +1,19 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="utf-8" />
- <link rel="stylesheet" type="text/css" href="/static/main.css?v=0.0.1">
- <title>Consent</title>
-</head>
-<body>
- <div class="main">
- <form action="" method="POST">
- {{range .}}
- <label><input type="checkbox" name="scope" value="{{.}}" checked />{{.}}</label>
- {{end}}
- <input type="submit" name="allow" value="Allow" />
- <input type="submit" name="reject" value="Reject" />
- <a href="/logout">logout</a>
- </form>
- </div>
-</body>
-</html>
-
+{{ define "title" }}Consent{{ end }}
+{{ define "main" }}
+<form action="" method="POST">
+ {{ range . }}
+ <label for="{{ . }}">
+ <input type="checkbox" role="switch" id="{{ . }}" name="scope" value="{{ . }}" checked />{{ . }}
+ </label>
+ {{ end }}
+ <button type="submit" name="allow">Allow</button>
+ <button type="submit" name="reject" class="secondary outline">Reject</button>
+</form>
+<nav>
+ <ul>
+ <li>
+ <a href="/logout">Log Out</a>
+ </li>
+ </ul>
+</nav>
+{{ end }}
diff --git a/core/auth/ui/templates/login.html b/core/auth/ui/templates/login.html
index 285d936..f01f157 100644
--- a/core/auth/ui/templates/login.html
+++ b/core/auth/ui/templates/login.html
@@ -1,20 +1,16 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="utf-8" />
- <link rel="stylesheet" type="text/css" href="/static/main.css?v=0.0.1">
- <title>Login</title>
-</head>
-<body>
- <div class="main">
- <form action="" method="POST">
- <input class="field" type="text" name="username" placeholder="Username" autofocus />
- <input class="field" type="password" name="password" placeholder="Password" />
- <input type="submit" value="Sign In" />
- <input type="hidden" name="csrf_token" value="{{.}}" />
- <a href="/registration">Create Account</a>
- </form>
- </div>
-</body>
-</html>
-
+{{ define "title" }}Sign in{{ end }}
+{{ define "main" }}
+<form action="" method="POST">
+ <input type="text" name="username" placeholder="Username" autofocus required />
+ <input type="password" name="password" placeholder="Password" required />
+ <input type="hidden" name="csrf_token" value="{{ . }}" />
+ <button type="submit">Sign In</button>
+</form>
+<nav>
+ <ul>
+ <li>
+ <a href="/register">Create Account</a>
+ </li>
+ </ul>
+</nav>
+{{ end }}
diff --git a/core/auth/ui/templates/register.html b/core/auth/ui/templates/register.html
new file mode 100644
index 0000000..22d69a5
--- /dev/null
+++ b/core/auth/ui/templates/register.html
@@ -0,0 +1,16 @@
+{{ define "title" }}Create Account{{ end }}
+{{ define "main" }}
+<form action="" method="POST">
+ <input type="text" name="username" placeholder="Username" autofocus required />
+ <input type="password" name="password" placeholder="Password" required />
+ <input type="hidden" name="csrf_token" value="{{ . }}" />
+ <button type="submit">Create Account</button>
+</form>
+<nav>
+ <ul>
+ <li>
+ <a href="/login">Sign In</a>
+ </li>
+ </ul>
+</nav>
+{{ end }}
diff --git a/core/auth/ui/templates/registration.html b/core/auth/ui/templates/registration.html
deleted file mode 100644
index bb2a357..0000000
--- a/core/auth/ui/templates/registration.html
+++ /dev/null
@@ -1,20 +0,0 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="utf-8" />
- <link rel="stylesheet" type="text/css" href="/static/main.css?v=0.0.1">
- <title>Create Account</title>
-</head>
-<body>
- <div class="main">
- <form action="" method="POST">
- <input class="field" type="text" name="username" placeholder="Username" autofocus />
- <input class="field" type="password" name="password" placeholder="Password" />
- <input type="submit" value="Create Account" />
- <input type="hidden" name="csrf_token" value="{{.}}" />
- <a href="/login">Sign In</a>
- </form>
- </div>
-</body>
-</html>
-
diff --git a/core/auth/ui/templates/whoami.html b/core/auth/ui/templates/whoami.html
index 70e36ab..2001c9f 100644
--- a/core/auth/ui/templates/whoami.html
+++ b/core/auth/ui/templates/whoami.html
@@ -1,13 +1,5 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="utf-8" />
- <link rel="stylesheet" type="text/css" href="/static/main.css?v=0.0.1">
- <title>Hello {{.}}!</title>
-</head>
-<body>
- <a href="/logout">logout</a>
- Hello {{.}}!
-</body>
-</html>
-
+{{ define "title" }}Who Am I{{ end }}
+{{ define "main" }}
+Hello {{.}}!
+<a href="/logout" role="button">logout</a>
+{{ end }}