From 9a5034a115d5e05eedd2ce8f3727660c08a943b6 Mon Sep 17 00:00:00 2001 From: Paul Duncan Date: Sat, 21 May 2016 15:59:03 -0400 Subject: add navbars to admin, login, and logout --- src/guff.cr | 2 +- src/views/admin-page.ecr | 41 ++++++++++++++++++++++++++++++++++------- src/views/login-page.ecr | 19 ++++++++++++++++++- src/views/logout-page.ecr | 19 ++++++++++++++++++- 4 files changed, 71 insertions(+), 10 deletions(-) diff --git a/src/guff.cr b/src/guff.cr index 783c98a..733a76f 100644 --- a/src/guff.cr +++ b/src/guff.cr @@ -429,6 +429,7 @@ module Guff end class AdminPageView < View + TITLE = "Guff Admin" ECR.def_to_s("src/views/admin-page.ecr") end @@ -494,7 +495,6 @@ module Guff end end - # TODO: check referrer, add x-frame-options class AssetsHandler < Handler def initialize(context : Context) super(context) diff --git a/src/views/admin-page.ecr b/src/views/admin-page.ecr index 1698cb5..287e35f 100644 --- a/src/views/admin-page.ecr +++ b/src/views/admin-page.ecr @@ -2,7 +2,7 @@ - Guff Admin + <%= h(TITLE) %> <%= styles %w{ @@ -14,13 +14,40 @@ - - - Logout - +
+ + + +
+ + +
+

+ TODO +

+
<%= diff --git a/src/views/login-page.ecr b/src/views/login-page.ecr index 79a92bb..16f63a4 100644 --- a/src/views/login-page.ecr +++ b/src/views/login-page.ecr @@ -14,13 +14,30 @@ + +
- Guff Login + Login
diff --git a/src/views/logout-page.ecr b/src/views/logout-page.ecr index 61fa505..0c6d70e 100644 --- a/src/views/logout-page.ecr +++ b/src/views/logout-page.ecr @@ -14,13 +14,30 @@ + +
- Guff Logout + Logout
-- cgit v1.2.3