UI: Implement web-assets v2 component nav-pills #93592
@ -375,34 +375,6 @@ form
|
||||
position: relative
|
||||
top: calc(var(--border-width) * -1)
|
||||
|
||||
// TODO: Move to web-assets. This is copied over from Extensions.
|
||||
.nav-pills
|
||||
@extend .dropdown-menu
|
||||
|
||||
box-shadow: none
|
||||
display: block
|
||||
position: relative
|
||||
|
||||
.nav-pills-item
|
||||
@extend .dropdown-item
|
||||
|
||||
+margin(1, bottom)
|
||||
white-space: normal
|
||||
|
||||
&.active
|
||||
background-color: var(--color-accent-bg)
|
||||
+fw-normal
|
||||
|
||||
&:last-child
|
||||
+margin(0, bottom)
|
||||
|
||||
.nav-pills-divider
|
||||
@extend .dropdown-divider
|
||||
|
||||
+margin(0, top)
|
||||
+margin(1, bottom)
|
||||
|
||||
|
||||
/* Larger icons */
|
||||
i.icon.icon-lg
|
||||
svg
|
||||
|
@ -1,4 +1,7 @@
|
||||
<a class="nav-pills-item {% if url_match == request.path %}active{% endif %}" href="{% url url %}">
|
||||
{% if icon %}<i class="{{ icon }}"></i>{% endif %}
|
||||
{% if icon %}
|
||||
<i class="{{ icon }}"></i>
|
||||
{% endif %}
|
||||
|
||||
{{ title }}
|
||||
</a>
|
||||
|
@ -42,31 +42,33 @@
|
||||
|
||||
<div class="row">
|
||||
{% block sidebar %}
|
||||
<div class="col-md-3">
|
||||
<nav class="box p-2 mb-3">
|
||||
<div class="nav-drawer-body">
|
||||
<div class="nav nav-pills flex-column" role="tablist" aria-orientation="vertical">
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:index" title="Home" url_match="/" icon="i-home" %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:profile" title="Profile" url_match="/settings/profile" icon="i-user" %}
|
||||
<div class="nav-pills-divider"></div>
|
||||
<div class="col-md-3">
|
||||
<nav aria-orientation="vertical" class="flex-column mb-3 nav nav-pills" role="tablist">
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:index" title="Home" url_match="/" icon="i-home" %}
|
||||
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:active_sessions" title="Sessions" url_match="/active-sessions" icon="i-activity" %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:auth_tokens" title="Authenticated Apps" url_match="/applications" icon="i-link" %}
|
||||
{% if user.bid_main_oauth2application.count %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:profile" title="Profile" url_match="/settings/profile" icon="i-user" %}
|
||||
|
||||
<div class="nav-pills-divider"></div>
|
||||
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:active_sessions" title="Sessions" url_match="/active-sessions" icon="i-activity" %}
|
||||
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:auth_tokens" title="Authenticated Apps" url_match="/applications" icon="i-link" %}
|
||||
|
||||
{% if user.bid_main_oauth2application.count %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:developer_applications" title="Developer Apps" url_match="/developer/applications" icon="i-code" %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
<div class="nav-pills-divider"></div>
|
||||
<div class="nav-pills-divider"></div>
|
||||
|
||||
{% if show_mfa %}
|
||||
{% if show_mfa %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:mfa" title="Multi-factor Authentication" url_match="/settings/profile" icon="i-shield" %}
|
||||
{% endif %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:password_change" title="Password" url_match="/change" icon="i-shield" %}
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:delete_user" title="Delete Account" url_match="/delete-my-account" icon="i-trash" %}
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:password_change" title="Password" url_match="/change" icon="i-asterisk" %}
|
||||
|
||||
{% include "bid_main/components/sidebar_nav_item.html" with url="bid_main:delete_user" title="Delete Account" url_match="/delete-my-account" icon="i-trash" %}
|
||||
</nav>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
<div class="{% block column_class %}col-md-9{% endblock %} mx-auto">
|
||||
|
Loading…
Reference in New Issue
Block a user