forked from oswaldoacauan/ghostium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
post.hbs
111 lines (107 loc) · 4.52 KB
/
post.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
{{!< default}}
<section class="wrapper wrapper-post">
<div class="wrapper-container">
<article itemscope itemtype="http://schema.org/BlogPosting" role="article" class="post {{post_class}}">
{{#post}}
<section class="post-container">
<header class="post-header">
<ul class="post-meta-list">
<li class="post-meta-item">
<time datetime="{{date published_at format="YYYY-MM-DD"}}" itemprop="datePublished">
{{date published_at timeago="true"}}
</time>
</li>
{{#if tags}}
<li class="post-meta-item">
{{#foreach tags}}
<a itemprop="{{#if @first}}articleSection{{else}}keywords{{/if}}" href="{{url}}" data-pjax>{{name}}</a>
{{~#if @last}} {{else}}, {{/if}}
{{/foreach}}
</li>
{{/if}}
<li class="post-meta-item">
<a href="#disqus_thread" data-disqus-identifier="{{id}}">Comments</a>
</li>
</ul>
<h1 itemprop="name headline" class="post-title"><a href="{{url}}" itemprop="url" data-pjax title="{{{title}}}">{{{title}}}</a></h1>
{{! A subtitle not available in Ghosts yet }}
<!--h2 itemprop="about" class="post-subtitle"></h2-->
</header>
<aside class="post-side">
<div class="post-author">
{{#if author.image}}
<a href="{{author.website}}" class="post-author-avatar">
<img src="{{author.image}}" alt="{{author.name}}">
</a>
{{/if}}
<div class="post-author-info">
<a href="{{author.website}}" class="post-author-name">
{{author.name}}
</a>
<p class="post-author-bio">{{author.bio}}</p>
</div>
</div>
</aside>
<div itemprop="articleBody" class="post-body">
{{content}}
</div>
<footer class="post-footer">
<div itemprop="author" itemscope itemtype="http://schema.org/Person" class="post-author">
{{#if author.image}}
<a href="{{author.website}}" class="post-author-avatar">
<img itemprop="image" src="{{author.image}}" alt="{{author.name}}">
</a>
{{/if}}
<div class="post-author-info">
<h4 class="post-footer-heading">Written By</h4>
<a href="{{author.website}}" itemprop="url" class="post-author-name">
<span itemprop="name">{{author.name}}</span>
</a>
<p itemprop="description" class="post-author-bio">{{author.bio}}</p>
{{#if author.location}}
<p class="post-author-location">{{author.location}}</p>
{{/if}}
{{#if author.website}}
<p class="post-author-website">
<a href="{{author.website}}" rel="nofollow">{{author.website}}</a>
</p>
{{/if}}
<p class="post-info">
<b class="post-info-title">Published on</b>
<time class="post-date">{{date format='MMMM DD, YYYY'}}</time>
</p>
</div>
</div>
<div class="post-social">
<h4 class="post-footer-heading">Spread the word</h4>
<a href="#" data-action="share-twitter"><i class="fa fa-fw fa-lg fa-twitter"></i></a>
<a href="#" data-action="share-facebook"><i class="fa fa-fw fa-lg fa-facebook"></i></a>
<a href="#" data-action="share-gplus"><i class="fa fa-fw fa-lg fa-google-plus"></i></a>
</div>
</footer>
</section>
{{/post}}
<section itemprop="comment" class="post-comments">
<div id="disqus_thread"></div>
</section>
</article>
{{> footer this}}
</div>
</section>
<script type="text/javascript">
if(GHOSTIUM.haveDisqus) {
{{#post}}
var disqus_identifier = '{{id}}';
{{/post}}
if(typeof DISQUS !== 'object') {
(function () {
var s = document.createElement('script'); s.async = true;
s.type = 'text/javascript';
s.src = '//' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s);
}());
}
} else {
document.querySelector('.post-comments').remove();
}
</script>