Repository navigation
Expand file tree
/
Copy pathcategories.html
More file actions
55 lines (51 loc) · 1.65 KB
/
Copy pathcategories.html
File metadata and controls
55 lines (51 loc) · 1.65 KB
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
---
title: Monty Python Categories
layout: page
---
{% assign rawcategories = "" %}
{% for sketch in site.sketches %}
{% assign tcategories = sketch.categories | join:'|' | append:'|' %}
{% assign rawcategories = rawcategories | append:tcategories %}
{% endfor %}
{% assign rawcategories = rawcategories | split:'|' | sort %}
{% assign categories = "" %}
{% for category in rawcategories %}
{% if category != "" %}
{% if categories == "" %}
{% assign categories = category | split:'|' %}
{% endif %}
{% unless categories contains category %}
{% assign categories = categories | join:'|' | append:'|' | append:category | split:'|' %}
{% endunless %}
{% endif %}
{% endfor %}
<ul class="taxonomy-index">
{% for category in categories %}
<li>
<a href="#{{ category | slugify }}"><i class="far fa-list-alt"></i>{{ category }}</a>
</li>
{% endfor %}
<li>
<a href="#holy-grail"><i class="far fa-list-alt"></i>holy grail</a>
</li>
</ul>
<hr />
<h2>Sketches by Category</h2>
{% for category in categories %}
<section id="{{ category | slugify | downcase }}" class="taxonomy-section">
<h3 class="taxonomy-title">{{ category }}</h3>
{% for sketch in site.sketches %}
{% if sketch.categories contains category %}
<div class="entries-{{ page.entries_layout | default: 'list' }}">
<a href="{{ site.url}}{{ sketch.url }}">{{ sketch.title }}</a>
</div>
{% endif %}
{% endfor %}
</section>
{% endfor %}
<section id="holy-grail" class="taxonomy-section">
<h3 class="taxonomy-title">holy grail</h3>
<div class="entries-{{ page.entries_layout | default: 'list' }}">
<a href="/holygrail/#the-screenplay-index">See the Screenplay Index</a>
</div>
</section>