Add a user_email option to the nav "Account" dropdown.

This commit is contained in:
Shane Kilkelly 2016-11-29 16:04:20 +00:00
parent a03ac8fe72
commit cf94429e05
3 changed files with 13 additions and 3 deletions

View file

@ -35,6 +35,9 @@ nav.navbar.navbar-default
each child in item.dropdown each child in item.dropdown
if child.divider if child.divider
li.divider li.divider
else if child.user_email
li
div.subdued #{getUserEmail()}
else else
li li
if child.url if child.url

View file

@ -347,6 +347,10 @@ module.exports = settings =
text: "Account" text: "Account"
only_when_logged_in: true only_when_logged_in: true
dropdown: [{ dropdown: [{
user_email: true
},{
divider: true
}, {
text: "Account Settings" text: "Account Settings"
url: "/user/settings" url: "/user/settings"
}, { }, {

View file

@ -58,8 +58,8 @@
.nav-divider(@dropdown-divider-bg); .nav-divider(@dropdown-divider-bg);
} }
// Links within the dropdown menu // Links and other items within the dropdown menu
> li > a { > li > a,div {
display: block; display: block;
padding: 3px 20px; padding: 3px 20px;
clear: both; clear: both;
@ -67,8 +67,11 @@
line-height: @line-height-base; line-height: @line-height-base;
color: @dropdown-link-color; color: @dropdown-link-color;
white-space: nowrap; // prevent links from randomly breaking onto new lines white-space: nowrap; // prevent links from randomly breaking onto new lines
&.subdued {
color: #7a7a7a
}
.subdued { .subdued {
color: #7a7a7a color: #7a7a7a
} }
} }
} }