📕 yarn is a Self-Hosted, Twitter™-like Decentralised micro-Blogging platform. No ads, no tracking, your content, your data! https://yarn.social/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

138 lines
5.2 KiB

{{ define "base" }}
<!DOCTYPE html>
<html lang="en" {{ with .Theme }}data-theme="{{ . }}"{{ end }}>
<head>
{{ if $.Debug }}
<link href="/css/01-pico.css" rel="stylesheet" />
<link href="/css/02-tabler-icons.css" rel="stylesheet" />
<link href="/css/98-custom-icons.css" rel="stylesheet" />
<link href="/css/99-yarn.css" rel="stylesheet" />
<link rel="icon" type="image/png" href="/img/favicon.png" />
{{ else }}
<link href="/css/{{ .Commit }}/yarn.min.css" rel="stylesheet" />
<link rel="icon" type="image/png" href="/img/{{ .Commit}}/favicon.png" />
{{ end }}
{{ range .Alternatives }}
<link rel="alternate" type="{{ .Type }}" title="{{ .Title }}" href="{{ .URL }}" />
{{ end }}
{{ range .Links }}
<link href="{{ .Href }}" rel="{{ .Rel }}" />
{{ end }}
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>{{ .InstanceName }} {{ .Title }}</title>
{{ with .Meta.Title }}<meta name="title" content="{{ . }}">{{ end }}
{{ with .Meta.Author }}<meta name="author" content="{{ . }}">{{ end }}
{{ with .Meta.Keywords }}<meta name="keywords" content="{{ . }}">{{ end }}
{{ with .Meta.Description }}<meta name="description" content="{{ . }}">{{ end }}
<!-- OpenGraph Meta Tags -->
{{ with .Meta.Title }}<meta property="og:title" content="{{ . }}">{{ end }}
{{ with .Meta.Description }}<meta property="og:description" content="{{ . }}">{{ end }}
{{ with .Meta.UpdatedAt }}<meta property="og:updated_time" content="{{ . }}" />{{ end }}
{{ with .Meta.Image }}<meta property="og:image" content="{{ . }}">{{ end }}
{{ with .Meta.URL }}<meta property="og:url" content="{{ . }}">{{ end }}
<meta property="og:site_name" content="{{ .InstanceName }}">
</head>
<body>
<nav id="mainNav">
<ul>
<li class="mobile-menu">
<a id="burgerMenu" href="javascript:void(0);">
<i class="ti ti-menu-2"></i>
</a>
</li>
<li><a class="podLogo" href="/">{{ $.Logo }}</a></li>
{{ if .Authenticated }}
<li>
<a class="timelineBtn" href="/" title="Last updated {{ .TimelineUpdatedAt | time }}">
<i class="ti ti-message-circle"></i>
{{ tr . "NavTimeline" }}
</a>
</li>
<li>
<a class="discoverBtn" href="/discover" title="Last updated {{ .DiscoverUpdatedAt | time }}">
<i class="ti ti-compass"></i>
{{ tr . "NavDiscover" }}
</a>
</li>
<li>
<a class="mentionsBtn" href="/mentions" title="Last mentioned {{ .LastMentionedAt | time }}">
<i class="ti ti-bell-ringing"></i>
{{ tr . "NavMentions" }}
</a>
</li>
<li>
<a class="feedsBtn" href="/feeds">
<i class="ti ti-rss-nav"></i>
{{ tr . "NavFeeds" }}
</a>
</li>
{{ end }}
</ul>
<ul>
{{ if .Authenticated }}
<li>
<a class="settingsBtn" class="secondary" href="/settings">
<i class="ti ti-settings-nav"></i>
{{ tr . "NavSettings" }}
</a>
</li>
<li>
<a class="logoutBtn" class="secondary" href="/logout" onclick="return confirm('Are you sure you want logout?')">
<i class="ti ti-door-exit"></i>
{{ tr . "NavLogout" }}
</a>
</li>
{{ else }}
<li>
<a class="loginBtn" href="/login">
<i class="ti ti-door-enter"></i>
{{ tr . "NavLogin" }}
</a>
</li>
{{ if not .RegisterDisabled }}
<li>
<a class="registerBtn" href="/register">
<i class="ti ti-user-plus"></i>
{{ tr . "NavRegister" }}
</a>
</li>
{{ end }}
{{ end }}
</ul>
</nav>
<main class="container">
{{ template "content" . }}
</main>
<footer class="container">
<div class="footer-copyright">
Running <a href="https://git.mills.io/yarnsocial/yarn" target="_blank">yarnd</a>
<a href="/version">{{ .SoftwareVersion.FullVersion }}</a> &mdash;
a <a href="https://yarn.social" target="_blank">Yarn.social</a> pod.
</div>
<div class="footer-menu">
<a href="/about" class="menu-item">{{tr . "MenuAbout"}}</a>
<a href="/privacy" class="menu-item">{{tr . "MenuPrivacy"}}</a>
<a href="/abuse" class="menu-item">{{tr . "MenuAbuse"}}</a>
<a href="/help" class="menu-item">{{tr . "MenuHelp"}}</a>
<a href="/support" class="menu-item">{{tr . "MenuSupport"}}</a>
<a href="/atom.xml" class="footer-rss"> <i class="ti ti-rss"></i></a>
</div>
</footer>
{{ if $.Debug }}
<script type="application/javascript" src="/js/01-umbrella.js"></script>
<script type="application/javascript" src="/js/02-polyfill.js"></script>
<script type="application/javascript" src="/js/03-twix.js"></script>
<script type="application/javascript" src="/js/99-yarn.js"></script>
<script type="application/javascript" src="/js/ie11CustomProperties.min.js"></script>
{{ else }}
<script type="application/javascript" src="/js/{{ .Commit }}/yarn.min.js"></script>
{{ end }}
</body>
</html>
{{ end }}