Updated site layout for preliminary pagination handling.
This commit is contained in:
parent
b28e8770d4
commit
1d7d85e20f
2 changed files with 32 additions and 7 deletions
|
|
@ -2,12 +2,14 @@
|
||||||
layout: base
|
layout: base
|
||||||
pagination:
|
pagination:
|
||||||
data: collections.notes
|
data: collections.notes
|
||||||
size: 3
|
size: 6
|
||||||
alias: notes
|
alias: notes
|
||||||
|
permalink: notes/{{ notes | slugify }}/index.html
|
||||||
---
|
---
|
||||||
|
|
||||||
<main id="main" class="main box-flex" tabindex="-1">
|
<main id="main" class="main box-flex" tabindex="-1">
|
||||||
|
|
||||||
|
{#
|
||||||
<article id="container-centre" class="column centre">
|
<article id="container-centre" class="column centre">
|
||||||
|
|
||||||
<header class="page-header inner pt-700 pb-600">
|
<header class="page-header inner pt-700 pb-600">
|
||||||
|
|
@ -22,7 +24,7 @@ pagination:
|
||||||
|
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
</article>
|
</article>#}
|
||||||
|
|
||||||
<div class="bg-white pt-1100 pb-1100">
|
<div class="bg-white pt-1100 pb-1100">
|
||||||
|
|
||||||
|
|
@ -43,7 +45,7 @@ pagination:
|
||||||
|
|
||||||
{% for item in post.data.tags %}
|
{% for item in post.data.tags %}
|
||||||
|
|
||||||
{%- if item !== 'blog' -%}
|
{%- if item !== 'notes' -%}
|
||||||
|
|
||||||
<span class="category box-block bg-secondary color-primary text-300">{{ item | capitalize }}</span>
|
<span class="category box-block bg-secondary color-primary text-300">{{ item | capitalize }}</span>
|
||||||
|
|
||||||
|
|
@ -63,9 +65,12 @@ pagination:
|
||||||
|
|
||||||
<div class="card-content pt-700 pb-900 pl-300 pr-300">
|
<div class="card-content pt-700 pb-900 pl-300 pr-300">
|
||||||
|
|
||||||
<h2><a class="card-title-link color-primary weight-regular hover-color-secondary" href="{{ post.url | url }}">{{ post.data.title }}</a></h2>
|
<h3><a class="card-title-link color-primary weight-regular hover-color-secondary" href="{{ post.url | url }}">{{ post.data.title }}</a></h3>
|
||||||
|
{%- if post.data.sub_heading -%}
|
||||||
|
<h4>{{ post.data.sub_heading }}</h4>
|
||||||
|
{%- endif -%}
|
||||||
|
|
||||||
<time class="datetime color-grey text-400" datetime="{{ post.date | timestamp }}">
|
<time class="datetime color-grey text-600" datetime="{{ post.date | timestamp }}">
|
||||||
{{ post.date | dateDisplay }}
|
{{ post.date | dateDisplay }}
|
||||||
</time>
|
</time>
|
||||||
|
|
||||||
|
|
@ -79,4 +84,24 @@ pagination:
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{% if pagination.pages.length > 1 %}
|
||||||
|
<div class="pagination inner box-grid">
|
||||||
|
<ul>
|
||||||
|
{%- if pagination.href.previous %}
|
||||||
|
<li><a href="{{ pagination.href.previous }}">« Prev</a></li>
|
||||||
|
{% endif -%}
|
||||||
|
{% for entry in pagination.pages %}
|
||||||
|
{% if page.url == pagination.hrefs[loop.index0] %}
|
||||||
|
<li>{{ loop.index }}</li>
|
||||||
|
{% else %}
|
||||||
|
<li><a href="/sundays{{ pagination.hrefs[ loop.index0 ] }}"{% if page.url == pagination.hrefs[ loop.index0 ] %} class="current"{% endif %}>{{ loop.index }}</a></li>
|
||||||
|
{% endif %}
|
||||||
|
{% endfor %}
|
||||||
|
{%- if pagination.href.next %}
|
||||||
|
<li><a href="{{ pagination.href.next }}">Next »</a></li>
|
||||||
|
{% endif -%}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
</main>
|
</main>
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@ layout: base
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
{# featured post image #}
|
{# featured post image #}
|
||||||
{% if post_image %}
|
{# if post_image %}
|
||||||
|
|
||||||
<figure class="post-image bg-white pt-600 pr-600 pl-600 mb-1000">
|
<figure class="post-image bg-white pt-600 pr-600 pl-600 mb-1000">
|
||||||
|
|
||||||
|
|
@ -62,7 +62,7 @@ layout: base
|
||||||
|
|
||||||
</figure>
|
</figure>
|
||||||
|
|
||||||
{% endif %}
|
{% endif #}
|
||||||
|
|
||||||
<div class="content flow length-optimal">
|
<div class="content flow length-optimal">
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue