Archived
1
0
Fork 0
This repository has been archived on 2024-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
SOD/views/layout.pug

61 lines
2.4 KiB
Text
Raw Normal View History

2020-08-20 22:46:46 +02:00
include mixin
2020-06-26 16:59:54 +02:00
doctype html
html
head
title= title
2020-09-27 17:52:35 +02:00
link(rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons")
link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css")
2020-09-29 16:12:43 +02:00
link(rel="stylesheet" href="/stylesheets/style.css")
2020-09-27 17:52:35 +02:00
meta(name="viewport" content="width=device-width, initial-scale=1.0")
2020-09-30 08:28:38 +02:00
link(rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon.png")
link(rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32.png")
link(rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16.png")
link(rel="manifest" href="/site.webmanifest")
link(rel="mask-icon" href="/images/safari-pinned-tab.svg" color="#5bbad5")
meta(name="msapplication-TileColor" content="#da532c")
meta(name="theme-color" content="#ffffff")
2020-06-26 16:59:54 +02:00
body
2020-09-27 17:52:35 +02:00
mixin nav
2020-08-17 19:08:35 +02:00
if user
if user.permissions >= 1
2020-09-27 17:52:35 +02:00
li: a(href="/sandwiches")=__("sandwiches")
2020-08-17 19:08:35 +02:00
if user.permissions >= 2
2020-09-27 17:52:35 +02:00
li: a(href="/orders")=__("orders")
2020-08-17 19:08:35 +02:00
if user.permissions >= 3
2020-09-27 17:52:35 +02:00
li: a(href="/admin")=__("admin.title")
li: a(href="/profile")=user.username
li: a(href="/logout")=__("layout.logout")
else
2020-09-27 17:52:35 +02:00
li: a(href="/login")=__("layout.login")
li: a(href="/register")=__("layout.register")
nav.orange(role="navigation")
div.nav-wrapper.container
a.brand-logo(href="/") SOD
a.sidenav-trigger(href="#" data-target="mobile-nav"): i.material-icons menu
ul.right.hide-on-med-and-down
+nav
ul#mobile-nav.sidenav
+nav
2020-09-29 16:12:43 +02:00
main
block content
2020-09-27 17:52:35 +02:00
2020-09-29 16:12:43 +02:00
if !test
p !{captcha}
2020-09-29 16:12:43 +02:00
footer.page-footer
div.container
div.row
div.col.l6.s12
h5.white-text=__("layout.links")
ul
li: a.grey-text.text-lighten-3(href="/about")=__("layout.about")
li: a.grey-text.text-lighten-3(href="/contact")=__("contact")
div.footer-copyright
div.container
a.grey-text.text-lighten-4(href="https://sapinet.fr" target="_blank")=__("layout.powered") + " Sapinet"
a.grey-text.text-lighten-4.right(href="https://www.linkedin.com/in/florian-charlaix" target="_blank")=__("layout.made") + " Florian Charlaix"
2020-09-27 17:52:35 +02:00
script(src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/js/materialize.min.js")
2020-08-17 19:19:13 +02:00
script(src="/javascripts/layout.js")