forked from zutrinken/attila
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdefault.hbs
109 lines (90 loc) · 3.33 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
<!DOCTYPE html>
<html lang="{{@site.lang}}">
<head>
{{!-- Document Settings --}}
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
{{!-- 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 "css/style.css"}}" />
<script>
var siteUrl = '{{@site.url}}';
</script>
<script>
var localTheme = localStorage.getItem('attila_theme');
switch (localTheme) {
case 'dark':
document.documentElement.classList.add('theme-dark');
break;
case 'light':
document.documentElement.classList.add('theme-light');
break;
default:
break;
}
</script>
{{ghost_head}}
</head>
<body class="{{body_class}}">
<div class="nav-header">
<nav class="nav-wrapper" aria-label="{{t "Main"}}">
{{#if @site.logo}}
<span class="logo">
<a href="{{@site.url}}" title="{{t "Home"}}"><img src="{{@site.logo}}" alt="{{t "Logo"}}" /></a>
</span>
{{/if}}
{{navigation}}
{{> "navigation-meta"}}
</nav>
<div class="nav-wrapper-control">
<div class="inner">
<a class="nav-menu" role="button"><i class="icon icon-menu" aria-hidden="true"></i>{{t "Menu"}}</a>
<a class="nav-search" style="display: none;" title="{{t "Search"}}" role="button"><i class="icon icon-search" aria-hidden="true"></i></a>
</div>
</div>
</div>
<div class="nav-close" role="button" aria-label="{{t "Close"}}"></div>
<section class="page-wrapper">
{{{body}}}
<div class="search-wrapper">
<div class="search">
<form class="search-form">
<input class="search-field" type="text" placeholder="{{t "Search"}} …">
<button class="search-button" type="submit">
<i class="icon icon-search" aria-hidden="true"></i>
</button>
</form>
<div class="popular-wrapper">
<h4 class="popular-title">{{t "Topics"}}</h4>
<span class="popular-tags post-tags">
{{#get 'tags' limit='all' include='count.posts' order='count.posts desc'}}
{{#foreach tags}}
<a href='{{ url }}'>{{ name }}: {{ count.posts }}</a>
{{/foreach}}
{{/get}}
</span>
</div>
<div class="search-result"></div>
</div>
<button class="search-wrapper-close" aria-label="{{t "Close"}}"></button>
</div>
<div class="nav-footer">
<nav class="nav-wrapper" aria-label="{{t "Footer"}}">
<span class="nav-copy">{{@site.title}} © {{date format='YYYY'}} <a class="nav-rss" title="RSS" href="{{@site.url}}/rss/" target="_blank"><i class="icon icon-rss" aria-hidden="true"></i></a></span>
{{#if @site.secondary_navigation}}
{{navigation type="secondary"}}
{{/if}}
</nav>
</div>
</section>
{{!-- Load basic scripts --}}
<script type="text/javascript" src="{{asset "js/script.js"}}"></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>