forked from TryGhost/London
-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.hbs
124 lines (104 loc) · 4.87 KB
/
default.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
<!DOCTYPE html>
<html lang="{{@site.lang}}">
<head>
{{!-- Document Settings --}}
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
{{!-- Base Meta --}}
<title>{{meta_title}}</title>
<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
{{!-- Styles'n'Scripts --}}
<link rel="stylesheet" type="text/css" href="{{asset "built/screen.css"}}" />
{{!-- This tag outputs SEO meta+structured data and other important settings --}}
{{ghost_head}}
</head>
<body class="{{body_class}}">
<div class="site-wrapper">
<header class="site-head">
<div class="site-head-container">
<a class="nav-burger" href="#">
<div class="hamburger hamburger--collapse" aria-label="Menu" role="button" aria-controls="navigation">
<div class="hamburger-box">
<div class="hamburger-inner"></div>
</div>
</div>
</a>
<nav id="swup" class="site-head-left">
{{navigation}}
</nav>
<div class="site-head-center">
{{#if @site.logo}}
<a class="site-head-logo" href="{{@site.url}}"><img src="{{@site.logo}}" alt="{{@site.title}}" /></a>
{{else}}
<a class="site-head-logo" href="{{@site.url}}">{{@site.title}}</a>
{{/if}}
</div>
<div class="site-head-right">
<div class="social-links">
{{#if @site.facebook}}
<a href="{{facebook_url @site.facebook}}" title="Facebook" target="_blank" rel="noopener">Facebook</a>
{{/if}}
{{#if @site.twitter}}
<a href="{{twitter_url @site.twitter}}" title="Twitter" target="_blank" rel="noopener">Twitter</a>
{{/if}}
<a href="https://feedly.com/i/subscription/feed/{{@site.url}}/rss/" title="RSS" target="_blank" rel="noopener">RSS</a>
</div>
</div>
</div>
</header>
<main id="site-main" class="site-main">
<div id="swup" class="transition-fade">
{{!-- All the main content gets inserted here, index.hbs, post.hbs, etc --}}
{{{body}}}
</div>
</main>
{{!-- The footer at the very bottom of the screen --}}
<footer class="site-foot">
© {{date format="YYYY"}} <a href="{{@site.url}}">{{@site.title}}</a> — Published with <a href="https://ghost.org" target="_blank" rel="noopener">Ghost</a>
</footer>
</div>
{{!-- The big email subscribe modal content --}}
{{#if @labs.subscribers}}
<div id="subscribe" class="subscribe-overlay">
<a class="subscribe-overlay-close" href="#"></a>
<div class="subscribe-overlay-content">
{{#if @site.logo}}
<img class="subscribe-overlay-logo" src="{{@site.logo}}" alt="{{@site.title}}" />
{{/if}}
<h1 class="subscribe-overlay-title">Subscribe to {{@site.title}}</h1>
<p class="subscribe-overlay-description">Stay up to date! Get all the latest & greatest posts delivered straight to your inbox</p>
{{subscribe_form placeholder="[email protected]"}}
</div>
</div>
{{/if}}
<script src="{{asset "built/swup.js"}}"></script>
<script src="{{asset "built/infinitescroll.js"}}"></script>
<script
src="https://code.jquery.com/jquery-3.2.1.min.js"
integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4="
crossorigin="anonymous">
</script>
<script>
$(document).ready(function () {
// Mobile Menu Trigger
$('.nav-burger').click(function () {
$('body').toggleClass('site-head-open');
});
$('.site-head-open a').click(function () {
$('body').removeClass('site-head-open');
});
});
// Initiate Swup transitions
var swup = new Swup();
swup.usePlugin(swupMergeHeadPlugin, { option: true });
document.addEventListener('swup:contentReplaced', event => {
initInfiniteScroll(window, document);
});
</script>
{{!-- The #block helper will pull in data from the #contentFor other template files. In this case, there's some JavaScript which we only want to use in post.hbs, but it needs to be included down here, after jQuery has already loaded. --}}
{{{block "scripts"}}}
{{!-- Ghost outputs important scripts and data with this tag - it should always be the very last thing before the closing body tag --}}
{{ghost_foot}}
</body>
</html>