Fix user dropdown and mobile nav

This commit is contained in:
Sam Lu
2018-07-18 16:22:36 -05:00
parent 1342ed2601
commit 97c74f3267
6 changed files with 44 additions and 29 deletions

View File

@@ -9,7 +9,7 @@
| {% endif %}
| {% block menu_avatar %}
a.navbar-item.dropdown-toggle(href="#", data-toggle="dropdown", title="{{ current_user.email }}")
a.nav-link.dropdown-toggle(href="#", data-toggle="dropdown", title="{{ current_user.email }}", aria-haspopup="true", aria-expanded="false")
img.gravatar(
src="{{ current_user.gravatar }}",
class="{{ subscription }}",
@@ -26,26 +26,26 @@ a.navbar-item.dropdown-toggle(href="#", data-toggle="dropdown", title="{{ curren
| {% block menu_list %}
li.subscription-status(class="{{ subscription }}")
.dropdown-menu.subscription-status(class="{{ subscription }}", aria-labelledby="dropdownMenuLink")
| {% if subscription == 'subscriber' %}
a.navbar-item(
a.dropdown-item(
href="{{url_for('settings.billing')}}"
title="View subscription info")
i.pi-grin
span Your subscription is active!
| {% elif subscription == 'demo' %}
a.navbar-item(
a.dropdown-item(
href="{{url_for('settings.billing')}}"
title="View subscription info")
i.pi-heart-filled
span You have a free account.
| {% elif current_user.has_cap('can-renew-subscription') %}
a.navbar-item(target='_blank', href="/renew", title="Renew subscription")
a.dropdown-item(target='_blank', href="/renew", title="Renew subscription")
i.pi-heart
span.info Your subscription is not active.
span.renew Click here to renew.
| {% else %}
a.navbar-item(
a.dropdown-item(
href="https://store.blender.org/product/membership/"
title="Renew subscription")
i.pi-unhappy
@@ -56,7 +56,7 @@ li.subscription-status(class="{{ subscription }}")
| {{ super() }}
li
a.navbar-item(
a.dropdown-item(
href="{{ url_for('settings.billing') }}"
title="Billing")
i.pi-credit-card