2017-07-19 16:56:02 +02:00

73 lines
2.1 KiB
Plaintext

component Layout(app *aero.Application, ctx *aero.Context, user *arn.User, openGraph *arn.OpenGraph, content string)
html(lang="en")
head
if openGraph != nil
title= openGraph.Tags["og:title"]
else
title= app.Config.Title
meta(name="viewport", content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes")
meta(name="theme-color", content=app.Config.Manifest.ThemeColor)
if openGraph != nil
for name, value := range openGraph.Meta
meta(name=name, content=value)
for property, content := range openGraph.Tags
meta(property=property, content=content)
link(rel="chrome-webstore-item", href="https://chrome.google.com/webstore/detail/hajchfikckiofgilinkpifobdbiajfch")
link(rel="manifest", href="/manifest.json")
body
#container(class=utils.GetContainerClass(ctx))
#header
Navigation(user)
#content-container
main#content.fade!= content
LoadingAnimation
StatusMessage
aside#sidebar
Sidebar(user)
if user != nil
#user(data-id=user.ID)
script(src="/scripts")
component Sidebar(user *arn.User)
.user-image-container
if user != nil
Avatar(user)
else
img.user-image.lazy(data-src="/images/brand/64", alt="Anime Notifier")
SidebarButton("Home", "/", "home")
SidebarButton("Forum", "/forum", "comment")
SidebarButton("Explore", "/explore", "th")
SidebarButton("Soundtracks", "/soundtracks", "headphones")
SidebarButton("Users", "/users", "globe")
if user != nil
if user.Role != ""
SidebarButton("Statistics", "/statistics", "pie-chart")
SidebarButton("Settings", "/settings", "cog")
SidebarButtonNoAJAX("Logout", "/logout", "sign-out")
else
SidebarButton("Login", "/login", "sign-in")
component StatusMessage
#status-message.fade.fade-out
#status-message-text
a.status-message-action.action(href="#", data-trigger="click", data-action="closeStatusMessage", aria-label="Close status message")
RawIcon("close")
component LoadingAnimation
#loading.sk-cube-grid.fade
.sk-cube.hide
.sk-cube
.sk-cube.hide
.sk-cube
.sk-cube.sk-cube-center
.sk-cube
.sk-cube.hide
.sk-cube
.sk-cube.hide