aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorGravatar Gareth Coles <[email protected]>2018-06-02 13:47:58 +0100
committerGravatar Gareth Coles <[email protected]>2018-06-02 13:47:58 +0100
commit41f9f179a645e4fc551beec0cd71e6ac79ddfc2e (patch)
treef06c80f41929c23111d39352a0ab640e6ebff2df /templates
parentMerge branch 'master' of github.com:discord-python/site [ci skip] (diff)
[Wiki] UX improvements for sidebar
Diffstat (limited to 'templates')
-rw-r--r--templates/wiki/base.html9
1 files changed, 7 insertions, 2 deletions
diff --git a/templates/wiki/base.html b/templates/wiki/base.html
index 537a844b..cbf89356 100644
--- a/templates/wiki/base.html
+++ b/templates/wiki/base.html
@@ -33,7 +33,7 @@
<div class="uk-flex uk-flex-row uk-flex-1">
<div class="uk-card uk-card-body uk-flex-left uk-flex uk-card-primary">
<ul class="uk-nav-default uk-nav-parent-icon" uk-nav id="wiki-nav">
- {% if data is defined %}
+ {% if data is defined and page == "wiki.page" %}
{% if "headers" in data and data.headers %}
<li class="uk-nav-header">Contents</li>
{% for header in data.headers %}
@@ -57,6 +57,8 @@
<li class="uk-nav-divider"></li>
{% endif %}
{% endif %}
+ <li class="uk-nav-header">Pages</li>
+
<li><a href="{{ url_for("wiki.page", page="home") }}">
<i class="uk-icon fas fa-fw fa-home"></i> &nbsp;Home
</a></li>
@@ -75,11 +77,13 @@
"wiki.history.compare", "wiki.source", "wiki.delete",
"wiki.move"
] %}
- {% set actionable = current_page in ACTIONABLE_PAGES %}
+ {% set actionable = can_edit and current_page in ACTIONABLE_PAGES %}
{% if actionable %}
<li class="uk-nav-divider"></li>
+ <li class="uk-nav-header">Actions</li>
+
{% if current_page == "wiki.edit" %}
<li>
<a href="{{ url_for("wiki.page", page=page) }}">
@@ -158,6 +162,7 @@
{% endif %}
<li class="uk-nav-divider"></li>
+ <li class="uk-nav-header">Information</li>
<li><a href="{{ url_for("wiki.special") }}">
<i class="uk-icon fas fa-fw fa-ellipsis-h"></i> &nbsp;Special Pages