From af1f4677c685e8a2c4967ffa0350d314a6543db7 Mon Sep 17 00:00:00 2001 From: Horus3 Date: Thu, 5 Feb 2015 02:55:30 +0100 Subject: Init --- app/views/App/Index.html | 23 +++++++++++++++++ app/views/debug.html | 64 +++++++++++++++++++++++++++++++++++++++++++++++ app/views/errors/404.html | 20 +++++++++++++++ app/views/errors/500.html | 16 ++++++++++++ app/views/flash.html | 18 +++++++++++++ app/views/footer.html | 5 ++++ app/views/header.html | 17 +++++++++++++ 7 files changed, 163 insertions(+) create mode 100644 app/views/App/Index.html create mode 100644 app/views/debug.html create mode 100644 app/views/errors/404.html create mode 100644 app/views/errors/500.html create mode 100644 app/views/flash.html create mode 100644 app/views/footer.html create mode 100644 app/views/header.html (limited to 'app/views') diff --git a/app/views/App/Index.html b/app/views/App/Index.html new file mode 100644 index 0000000..deb2304 --- /dev/null +++ b/app/views/App/Index.html @@ -0,0 +1,23 @@ +{{set . "title" "Home"}} +{{template "header.html" .}} + +
+
+
+
+

It works!

+

+
+
+
+
+ +
+
+
+ {{template "flash.html" .}} +
+
+
+ +{{template "footer.html" .}} diff --git a/app/views/debug.html b/app/views/debug.html new file mode 100644 index 0000000..f3975b7 --- /dev/null +++ b/app/views/debug.html @@ -0,0 +1,64 @@ + + + + + diff --git a/app/views/errors/404.html b/app/views/errors/404.html new file mode 100644 index 0000000..ebdfe10 --- /dev/null +++ b/app/views/errors/404.html @@ -0,0 +1,20 @@ + + + + Not found + + +{{if eq .RunMode "dev"}} +{{template "errors/404-dev.html" .}} +{{else}} + {{with .Error}} +

+ {{.Title}} +

+

+ {{.Description}} +

+ {{end}} +{{end}} + + diff --git a/app/views/errors/500.html b/app/views/errors/500.html new file mode 100644 index 0000000..0cef4de --- /dev/null +++ b/app/views/errors/500.html @@ -0,0 +1,16 @@ + + + + Application error + + + {{if eq .RunMode "dev"}} + {{template "errors/500-dev.html" .}} + {{else}} +

Oops, an error occured

+

+ This exception has been logged. +

+ {{end}} + + diff --git a/app/views/flash.html b/app/views/flash.html new file mode 100644 index 0000000..9c9ade9 --- /dev/null +++ b/app/views/flash.html @@ -0,0 +1,18 @@ +{{if .flash.success}} +
+ {{.flash.success}} +
+{{end}} + +{{if or .errors .flash.error}} +
+ {{if .flash.error}} + {{.flash.error}} + {{end}} + +
+{{end}} diff --git a/app/views/footer.html b/app/views/footer.html new file mode 100644 index 0000000..8db95e5 --- /dev/null +++ b/app/views/footer.html @@ -0,0 +1,5 @@ + {{if eq .RunMode "dev"}} + {{template "debug.html" .}} + {{end}} + + diff --git a/app/views/header.html b/app/views/header.html new file mode 100644 index 0000000..01637f4 --- /dev/null +++ b/app/views/header.html @@ -0,0 +1,17 @@ + + + + + {{.title}} + + + + + {{range .moreStyles}} + + {{end}} + {{range .moreScripts}} + + {{end}} + + -- cgit v1.2.3