Skip to content

Commit

Permalink
Improved Prev/Next post elements in posts
Browse files Browse the repository at this point in the history
  • Loading branch information
steilerDev authored and steilerDev committed Jun 2, 2017
1 parent c0216d4 commit 0f4e6d9
Showing 1 changed file with 29 additions and 12 deletions.
41 changes: 29 additions & 12 deletions _layouts/posts.html
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,35 @@ <h2>{{ picture.title }}</h2>
</div>
{% endif %}
</div>
<div class="page-navigation">
{% if page.previous.url %}
<a class="prev" href="{{page.previous.url}}">&laquo; {{page.previous.title}}</a>
{% else %}
<a class="prev"></>
{% endif %}
{% if page.next.url %}
<a class="next" href="{{page.next.url}}">{{page.next.title}} &raquo;</a>
{% else %}
<a class="next"></>
{% endif %}
</div>
<p></p>
<div class="row">
{% if page.previous.url %}
<a href="{{page.previous.url}}">
<div class="col-xs-1 text-right page-navigation">
&laquo;
</div>
<div class="col-xs-5 text-left page-navigation">
{{page.previous.title}}
</div>
</a>
{% else %}
<div class="col-xs-6">
</div>
{% endif %}
{% if page.next.url %}
<a href="{{page.next.url}}">
<div class="col-xs-5 text-right page-navigation">
{{page.next.title}}
</div>
<div class="col-xs-1 text-left page-navigation">
&raquo;
</div>
</a>
{% else %}
<div class="col-xs-6">
</div>
{% endif %}
</div>
<hr>

<div class="row center-block text-center">
Expand Down

0 comments on commit 0f4e6d9

Please sign in to comment.