Skip to content

Commit

Permalink
More Ghost 0.5 updates
Browse files Browse the repository at this point in the history
  • Loading branch information
max-holland committed Aug 9, 2014
1 parent d74a952 commit 85297b2
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 107 deletions.
27 changes: 2 additions & 25 deletions author.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -29,31 +29,8 @@
</header>
</article>
{{/author}}
{{#foreach posts}}
<article class="post" id="{{id}}" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
<div class="wrapper">
<header>
<h2 class="post-title" itemprop="name headline"><a href="{{url}}" class="post-link">{{{title}}}</a></h2>
</header>
<section class="post-text" itemprop="articleBody text">
<p>{{excerpt}}&hellip;</p>
</section>
<footer>
<ul>
<li itemprop="author" itemscope itemtype="http://schema.org/Person">
{{#if author.image}}
<img class="author-image" src="{{author.image}}" alt="{{author.name}}">
{{/if}}
<span class="author-info">
<span rel="author" itemprop="url name">{{author.name}}</span>
<span class="hide-on-mobile">{{tags separator=", " prefix="in "}}</span>
</span>
</li>
</ul>
</footer>
</div>
</article>
{{/foreach}}
{{! The tag below includes the post loop - partials/post-loop.hbs }}
{{> "post-loop"}}
</div>
</section>

Expand Down
28 changes: 2 additions & 26 deletions index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -29,35 +29,11 @@
{{#if @blog.cover}}<img id="bg-img" src="{{@blog.cover}}">{{/if}}

{{! Each post will be output using this markup }}
{{#foreach posts}}
<article class="post" id="{{id}}" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
<div class="wrapper">
<header>
<h2 class="post-title" itemprop="name headline"><a href="{{url}}" class="post-link">{{{title}}}</a></h2>
</header>
<section class="post-text" itemprop="articleBody text">
<p>{{excerpt}}&hellip;</p>
</section>
<footer>
<ul>
<li itemprop="author" itemscope itemtype="http://schema.org/Person">
{{#if author.image}}
<img class="author-image" src="{{author.image}}" alt="{{author.name}}">
{{/if}}
<span class="author-info">
<span rel="author" itemprop="url name">{{author.name}}</span>
<span class="hide-on-mobile">{{tags separator=", " prefix="in "}}</span>
</span>
</li>
</ul>
</footer>
</div>
</article>

{{/foreach}}

{{!! After all the posts, we have the previous/next pagination links }}

{{! The tag below includes the post loop - partials/post-loop.hbs }}
{{> "post-loop"}}
</div>


Expand Down
28 changes: 28 additions & 0 deletions partials/post-loop.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{#foreach posts}}
<article class="post" id="{{id}}" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
<div class="wrapper">
<header>
<h2 class="post-title" itemprop="name headline"><a href="{{url}}" class="post-link">{{{title}}}</a></h2>
</header>
<section class="post-text" itemprop="articleBody text">
<p>{{excerpt}}&hellip;</p>
</section>
<footer>
<ul>
{{#author}}
<li itemprop="author" itemscope itemtype="http://schema.org/Person">
{{#if image}}
<img class="author-image" src="{{image}}" alt="{{name}}">
{{/if}}
<span class="author-info">
<span rel="author" itemprop="url name">{{name}}</span>
{{/author}}
<span class="hide-on-mobile">{{tags separator=", " prefix="in "}}</span>
</span>
</li>
</ul>
</footer>
</div>
</article>

{{/foreach}}
19 changes: 16 additions & 3 deletions post.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,30 @@
<span>
<h1 itemprop="name">{{{title}}}</h1>
<ul>

<li class="hide-on-mobile">
{{#if author.image}}<img class="author-image" src="{{author.image}}" alt="{{author.name}}">{{/if}}<span class="author-info">{{author.name}} {{tags separator=" , " prefix="in "}}</span>
{{#author}}
{{#if image}}
<img class="author-image" src="{{image}}" alt="{{name}}">
{{/if}}
<span class="author-info">{{name}}
{{/author}}
{{tags separator=" , " prefix="in "}}</span>
<span class="author-info hide-on-mobile" style="float:right;">&nbsp;read</span>
<span class="author-info post-reading-time " style="float:right;"></span>
</li>
<li class="hide-on-desktop hide-on-tablet">
{{#if author.image}}<img class="author-image" src="{{author.image}}" alt="{{author.name}}">{{/if}}<span class="author-info">{{author.name}} </span>
{{#author}}
{{#if author.image}}
<img class="author-image" src="{{image}}" alt="{{name}}">
{{/if}}
<span class="author-info">{{name}}
{{/author}}
</span>
<span class="author-info post-reading-time" style="float:right;"></span>
</li>

</ul>
</ul>

</span>
</span>
Expand Down
53 changes: 0 additions & 53 deletions tag.hbs

This file was deleted.

0 comments on commit 85297b2

Please sign in to comment.