Reformat user menu and add external links to source and chat.

This commit is contained in:
Christopher Charbonneau Wells 2017-11-30 11:34:07 -05:00
parent 0646640ba3
commit c0f17dd273
3 changed files with 21 additions and 6 deletions

View File

@ -20,6 +20,10 @@
@extend .fa-camera; @extend .fa-camera;
} }
.icon-chat {
@extend .fa-users;
}
.icon-chevron-left { .icon-chevron-left {
@extend .fa-chevron-left; @extend .fa-chevron-left;
} }
@ -84,6 +88,10 @@
@extend .fa-bed; @extend .fa-bed;
} }
.icon-source {
@extend .fa-code-fork;
}
.icon-stop { .icon-stop {
@extend .fa-stop; @extend .fa-stop;
} }

View File

@ -173,19 +173,27 @@
aria-expanded="false"><i class="icon icon-user" aria-hidden="true"></i> {{ request.user }} aria-expanded="false"><i class="icon icon-user" aria-hidden="true"></i> {{ request.user }}
</a> </a>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="nav-user-menu-link"> <div class="dropdown-menu dropdown-menu-right" aria-labelledby="nav-user-menu-link">
<h6 class="dropdown-header">User</h6>
<a href="{% url 'user-settings' %}" class="dropdown-item">Settings</a> <a href="{% url 'user-settings' %}" class="dropdown-item">Settings</a>
<div class="dropdown-divider"></div> <a href="{% url 'logout' %}" class="dropdown-item">Logout</a>
<h6 class="dropdown-header">Site</h6>
<a href="{% url 'api:api-root' %}" <a href="{% url 'api:api-root' %}"
class="dropdown-item" class="dropdown-item"
target="_blank">API Browser</a> target="_blank">API Browser</a>
{% if request.user.is_staff %} {% if request.user.is_staff %}
<a href="{% url 'admin:index' %}" <a href="{% url 'admin:index' %}"
class="dropdown-item" class="dropdown-item"
target="_blank">Site Admin</a> target="_blank">Backend Admin</a>
{% endif %} {% endif %}
<div class="dropdown-divider"></div> <h6 class="dropdown-header">Support</h6>
<a href="{% url 'logout' %}" <a href="https://github.com/cdubz/babybuddy"
class="dropdown-item">Logout</a> class="dropdown-item"
target="_blank">
<i class="icon icon-source" aria-hidden="true"></i> Source Code</a>
<a href="https://gitter.im/babybuddy/Lobby"
class="dropdown-item"
target="_blank">
<i class="icon icon-chat" aria-hidden="true"></i> Chat / Support</a>
</div> </div>
</li> </li>
</ul> </ul>

View File

@ -20,7 +20,6 @@
</a> </a>
{% endif %} {% endif %}
{% if timers %} {% if timers %}
<div class="dropdown-divider"></div>
<h6 class="dropdown-header">Active Timers</h6> <h6 class="dropdown-header">Active Timers</h6>
{% for timer in timers %} {% for timer in timers %}
<a class="dropdown-item" href="{% url 'timer-detail' timer.id %}">{{ timer }} ({{ timer.user }})</a> <a class="dropdown-item" href="{% url 'timer-detail' timer.id %}">{{ timer }} ({{ timer.user }})</a>