aboutsummaryrefslogtreecommitdiffstats
path: root/pydis_site/templates
diff options
context:
space:
mode:
authorGravatar kosayoda <[email protected]>2021-03-27 12:42:07 +0800
committerGravatar kosayoda <[email protected]>2021-03-27 12:42:07 +0800
commit624e87d15ccfbe4ba2410dcaab0b4fb494b664e5 (patch)
treeb2ac7802499d296af35df2ff0ebc457d7e9384e3 /pydis_site/templates
parentMerge pull request #393 from ks129/guides-app (diff)
Improve content page and listing metadata keys.
Make category `title` consistent with page `title`. Simplify `icon` key, since there is no benefit to defining the icon class and the icon separately. Allow overriding the `icon` for category entries just like page entries.
Diffstat (limited to 'pydis_site/templates')
-rw-r--r--pydis_site/templates/content/listing.html6
1 files changed, 3 insertions, 3 deletions
diff --git a/pydis_site/templates/content/listing.html b/pydis_site/templates/content/listing.html
index 6de306b0..ef0ef919 100644
--- a/pydis_site/templates/content/listing.html
+++ b/pydis_site/templates/content/listing.html
@@ -4,11 +4,11 @@
{% for category, data in categories.items %}
<div class="box" style="max-width: 800px;">
<span class="icon is-size-4 is-medium">
- <i class="fas fa-folder is-size-3 is-black has-icon-padding" aria-hidden="true"></i>
+ <i class="{{ data.icon|default:"fas fa-folder" }} is-size-3 is-black has-icon-padding" aria-hidden="true"></i>
</span>
<a href="{% url "content:page_category" location=path|add:category %}">
- <span class="is-size-4 has-text-weight-bold">{{ data.name }}</span>
+ <span class="is-size-4 has-text-weight-bold">{{ data.title }}</span>
</a>
<p class="is-italic">{{ data.description }}</p>
</div>
@@ -16,7 +16,7 @@
{% for page, data in pages.items %}
<div class="box" style="max-width: 800px;">
<span class="icon is-size-4 is-medium">
- <i class="{{ data.icon_class|default:"fab" }} {{ data.icon|default:"fa-python" }} is-size-3 is-black has-icon-padding" aria-hidden="true"></i>
+ <i class="{{ data.icon|default:"fab fa-python" }} is-size-3 is-black has-icon-padding" aria-hidden="true"></i>
</span>
<a href="{% url "content:page_category" location=path|add:page %}">
<span class="is-size-4 has-text-weight-bold">{{ data.title }}</span>