-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdefault.hbs
147 lines (136 loc) · 5.93 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
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
<!DOCTYPE html>
<html>
<head>
{{! Document Settings}}
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
{{! Page Meta}}
<title>{{meta_title}}</title>
<meta name="description" content="{{meta_description}}" />
<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
{{!-- <link rel="shortcut icon" href="{{asset "favicon.ico"}}"> --}}
{{! Scripts and Styles}}
<link rel="stylesheet" type="text/css" href="{{asset "lib/bootstrap/css/bootstrap.css"}}" />
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.4.0/css/font-awesome.min.css">
<link rel="stylesheet" type="text/css" href="{{asset "css/yeti.css"}}" />
<link rel="stylesheet" type="text/css" href="{{asset "css/screen.css"}}" />
{{! Ghost outputs important style and meta data with this tag }}
{{ghost_head}}
</head>
<body class="{{body_class}} {{#is 'index, tag, author'}}user{{/is}} {{#is 'post'}}{{#unless post.image}}noimage{{/unless}}{{/is}}">
<div role="navigation" class="navbar navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" data-toggle="collapse" data-target=".navbar-ex1-collapse" class="navbar-toggle"><span class="sr-only">Toggle navigation</span><span class="icon-bar"></span><span class="icon-bar"></span><span class="icon-bar"></span></button><a href="http://localhost:5000" class="navbar-brand"><img src="/img/movinggauteng.png"></a><a href="http://localhost:5000" class="navbar-brand"><span>Moving Gauteng</span></a>
</div>
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav">
<li><a href="/about/">About</a></li>
<li class="active"><a href="/blog/">Blog</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li class="hidden"><a>Filter Services</a></li>
<li><a href="/stops">Stations & Stops</a></li>
<li><a href="/routes">Routes</a></li>
<li><a href="/boards">Boards</a></li>
<li class="hidden-sm"><a href="/favourites">My Favourites</a></li>
<li class="hidden-sm"><a href="/fares">Fare Guide</a></li>
<li class="hidden-sm"><a href="https://rwt.to" target="blank" class="pill-rwtto">Trip Planner</a></li>
<li class="dropdown visible-sm"><a data-toggle="dropdown" role="button" aria-expanded="false" class="dropdown-toggle">More<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="/favourites">My Favourites</a></li>
<li><a href="/fares">Fare Guide</a></li>
<li class="hidden-sm"><a href="https://rwt.to" target="blank" class="pill-rwtto">Trip Planner</a></li>
</ul>
</li>
</ul>
</div>
</div>
</div>
<div id="application">
<div class="container">
{{{body}}}
<script>
{{#is 'post'}}
function get_text(el) {
ret = "";
var length = el.childNodes.length;
for(var i = 0; i < length; i++) {
var node = el.childNodes[i];
if(node.nodeType != 8) {
ret += node.nodeType != 1 ? node.nodeValue : get_text(node);
}
}
return ret;
}
function reading_time () {
var post_content = document.getElementById('js-post-content');
if (post_content) {
var words = get_text(post_content),
count = words.split(/\s+/).length,
read_time = Math.ceil((count / 150)),
read_time_node = document.createTextNode(read_time + ' min read');
document.getElementById('js-reading-time').appendChild(read_time_node);
}
}
{{/is}}
function no_schema_links () {
var links = document.querySelectorAll('.js-remove-domain-schema');
if (links) {
for (i = 0; i < links.length; ++i) {
var link = links[i],
text = link.innerHTML,
no_schema = text.replace(/.*?:\/\//g, "");
link.innerHTML = no_schema;
}
}
}
window.onload = function () {
no_schema_links();
{{#is 'post'}}
reading_time();
{{/is}}
}
</script>
{{! Ghost outputs important scripts and data with this tag }}
{{ghost_foot}}
{{#is 'post'}}
<script>
$(function(){
var share_modal = $("#share_modal"),
update_social_links = true;
$("#btn_share").click(function(){
var that = $(this);
share_modal.fadeIn(200);
return false;
});
share_modal.click(function(e){
if (e.target.className == "wrap" || e.target.id == "share_modal") {
share_modal.fadeOut(200);
}
return false;
});
share_modal.find("div.inner > header > a.close").click(function(){
share_modal.fadeOut(200);
return false;
});
});
</script>
{{/is}}
</div>
</div>
{{> "footer"}}
<script type="text/javascript">
/* * * CONFIGURATION VARIABLES * * */
var disqus_shortname = 'movinggauteng';
/* * * DON'T EDIT BELOW THIS LINE * * */
(function () {
var s = document.createElement('script'); s.async = true;
s.type = 'text/javascript';
s.src = '//' + disqus_shortname + '.disqus.com/count.js';
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s);
}());
</script>
</body>
</html>