diff options
author | 2022-10-29 10:38:47 +0800 | |
---|---|---|
committer | 2023-05-06 11:04:37 +0200 | |
commit | 7bf2766bd2468766497b5ec35657856815f8bb34 (patch) | |
tree | 3a1d24f426647af435cdf19aab5f39b854bcdded /pydis_site/templates/content/base.html | |
parent | Use content articles source url in django.conf.settings (diff) |
Put 'Edit on GitHub' on breadcrum row with Sub-Articles dropdown
Diffstat (limited to 'pydis_site/templates/content/base.html')
-rw-r--r-- | pydis_site/templates/content/base.html | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/pydis_site/templates/content/base.html b/pydis_site/templates/content/base.html index 2fd721a3..caa08819 100644 --- a/pydis_site/templates/content/base.html +++ b/pydis_site/templates/content/base.html @@ -1,5 +1,6 @@ {% extends 'base/base.html' %} {% load static %} +{% load page_src %} {% block title %}{{ page_title }}{% endblock %} {% block head %} @@ -29,10 +30,21 @@ <li class="is-active"><a href="#">{{ page_title }}</a></li> </ul> </nav> + <div class="is-flex is-justify-content-flex-end"> {# Sub-Article dropdown for category pages #} {% if subarticles %} {% include "content/dropdown.html" %} {% endif %} + {# Edit on GitHub for content articles #} + {% if page %} + <div id="edit-on-github"> + <a href="{{ request.path | page_src_url }}"> + <i class="fa-solid fa-pencil"></i> + Edit on GitHub + </a> + </div> + {% endif %} + </div> </div> </section> |