summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
Diffstat (limited to 'templates')
-rw-r--r--templates/404.html7
-rw-r--r--templates/base.html34
-rw-r--r--templates/base_empty.html3
-rw-r--r--templates/chat.html11
-rw-r--r--templates/home.html8
-rw-r--r--templates/messages.html12
6 files changed, 75 insertions, 0 deletions
diff --git a/templates/404.html b/templates/404.html
new file mode 100644
index 0000000..5210bfb
--- /dev/null
+++ b/templates/404.html
@@ -0,0 +1,7 @@
+{{ define "content" }}
+<h1>page not found</h1>
+<p><em>but hey, at least you found our witty 404 page. that's something, right?</em></p>
+
+<p><a href="/">go back home</a></p>
+
+{{ end }}
diff --git a/templates/base.html b/templates/base.html
new file mode 100644
index 0000000..e97e8d2
--- /dev/null
+++ b/templates/base.html
@@ -0,0 +1,34 @@
+{{ define "base" }}
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>phoneof simponic.</title>
+ <meta charset="utf-8">
+ <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
+ <link href="/static/img/favicon.ico" rel="icon" type="image/x-icon">
+ <link rel="stylesheet" type="text/css" href="/static/css/styles.css">
+
+ <meta property="og:type" content="website">
+ <meta property="og:url" content="https://phoneof.simponic.xyz">
+ <meta property="og:title" content="phoneof simponic.">
+ <meta property="og:description" content="phoneof simponic.">
+ <meta property="og:image:secure_url" content="https://phoneof.simponic.xyz/static/img/favicon.ico">
+ <meta property="og:image:secure" content="https://phoneof.simponic.xyz/static/img/favicon.ico">
+
+ <script src="/static/js/util/setThemeBeforeRender.js"></script>
+ </head>
+ <body>
+ <div id="content" class="container">
+ <div>
+ <h1>phoneof</h1>
+ <a href="/">home.</a>
+ <span> | </span>
+ <a href="javascript:void(0);" id="theme-switcher">light mode.</a>
+ </div>
+ <hr>
+ {{ template "content" . }}
+ </div>
+ <script data-main="/static/js/script.js" src="/static/js/require.js"></script>
+ </body>
+</html>
+{{ end }}
diff --git a/templates/base_empty.html b/templates/base_empty.html
new file mode 100644
index 0000000..6191ab9
--- /dev/null
+++ b/templates/base_empty.html
@@ -0,0 +1,3 @@
+{{ define "base" }}
+ {{ template "content" . }}
+{{ end }} \ No newline at end of file
diff --git a/templates/chat.html b/templates/chat.html
new file mode 100644
index 0000000..05957bf
--- /dev/null
+++ b/templates/chat.html
@@ -0,0 +1,11 @@
+{{ define "content" }}
+<div id="messages">
+</div>
+<div>
+<form action="/chat" method="POST" autocomplete="off">
+ <input id="fren_id" name="fren_id" value="{{ .User.Id }}" type="hidden">
+ <input name="message" value="" type="text">
+ <input type="submit" value="send.">
+</form>
+</div>
+{{ end }}
diff --git a/templates/home.html b/templates/home.html
new file mode 100644
index 0000000..7e8ecb7
--- /dev/null
+++ b/templates/home.html
@@ -0,0 +1,8 @@
+{{ define "content" }}
+<p>please use this if you know who i am and know how to use this but need to get ahold of me while im away from computers.</p>
+<form action="/chat" method="GET" autocomplete="off">
+ <label for="fren_id">fren id.</label>
+ <input type="text" id="fren_id" name="fren_id">
+ <input type="submit" value="login.">
+</form>
+{{ end }}
diff --git a/templates/messages.html b/templates/messages.html
new file mode 100644
index 0000000..e09ac46
--- /dev/null
+++ b/templates/messages.html
@@ -0,0 +1,12 @@
+{{ define "content" }}
+<div id="chat-container" class="chat-container">
+ {{ range $message := .Messages }}
+ <div class="message {{if $message.FrenSent}}fren{{end}}">
+ <div class="message-text {{if $message.FrenSent}}fren{{end}}">
+ <p>{{$message.Message}}</p>
+ <div class="time timestamp">{{$message.Time.Format "2006-01-02T15:04:05Z07:00"}}</div>
+ </div>
+ </div>
+ {{ end }}
+</div>
+{{ end }}