-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtag-posts.html
46 lines (41 loc) · 1.72 KB
/
tag-posts.html
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
---
layout: layouts/default
title: Mark's Blog
subtitle: Topical thoughts.
pagination:
data: collections.tagPages
size: 1
alias: tag
permalink: /blog/tags/{{ tag.tagName }}/{% if tag.pageNumber!=0 %}{{ tag.pageNumber }}/{% endif %}
---
<h1 class="mdc-typography mdc-typography--headline2">Posts tagged "{{ tag.tagName }}"</h1>
{% comment %}
In order for the pagination list to work, we need to set up two things:
- currentCollection: the collection we want to iterate over (e.g. blog pages or tag pages)
- linkHead: the head of the pagination link (e.g. `/blog/` or `/blog/tags/tech/`)
{% endcomment %}
{% assign currentCollection = collections.tagPages %}
{% capture linkHead %}/blog/tags/{{ tag.tagName }}/{% endcapture %}
{% include 'snippets/post-pagination.html' %}
<div class="mdc-layout-grid__inner">
{% for post in tag.pageData %}
{% include 'snippets/post-card.html' %}
{% endfor %}
</div>
<footer>
<div class="fabs">
<button class="mdc-fab mdc-fab--extended fab" aria-label="Favorite" onclick="window.location.href='/blog/'">
<div class="mdc-fab__ripple"></div>
<span class="mdc-fab__icon material-icons">library_books</span>
<span class="mdc-fab__label">Main Blog</span>
</button>
<button class="mdc-fab mdc-fab--extended fab" aria-label="Favorite" onclick="window.location.href='/blog/tags/'">
<div class="mdc-fab__ripple"></div>
<span class="mdc-fab__icon material-icons">label</span>
<span class="mdc-fab__label">All Tags</span>
</button>
</div>
</footer>
{% capture title %}{{tag.tagName}}, page {{ tag.pageNumber }} - Mark's Blog{% endcapture %}
{% capture description %}Everything I've written about {{tag.tagName}}{% endcapture %}
{% pageMetadata, title, description %}