summaryrefslogtreecommitdiff
path: root/views/base.twig
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2023-09-24 13:40:25 +0200
committerDaniel Weipert <code@drogueronin.de>2023-09-24 13:40:25 +0200
commitfa00b957378a393f8edbfc98ef111d35d18ecb09 (patch)
tree654e7dc5414f7f2795dbe996d3e1570793a5b1b8 /views/base.twig
initial commit
Diffstat (limited to 'views/base.twig')
-rw-r--r--views/base.twig26
1 files changed, 26 insertions, 0 deletions
diff --git a/views/base.twig b/views/base.twig
new file mode 100644
index 0000000..94e5037
--- /dev/null
+++ b/views/base.twig
@@ -0,0 +1,26 @@
+{% extends 'root.twig' %}
+
+{% block body %}
+<div class="wrap">
+ <header></header>
+
+ <main>
+ {% block main %}{% endblock %}
+ </main>
+
+ <footer></footer>
+
+ <div class="global-timer"></div>
+ <script>
+ const timer = document.querySelectorAll('.global-timer');
+ function setTime () {
+ const now = new Date();
+ for (const t of timer) {
+ t.innerHTML = now;
+ }
+ }
+ setTime();
+ setInterval(setTime, 1000);
+ </script>
+</div>
+{% endblock %}