Navigation Menu

Skip to content

Commit

Permalink
Merge branch 'trs/bootstrap-nits' into mo/bootstrap
Browse files Browse the repository at this point in the history
  • Loading branch information
tsibley committed Feb 2, 2014
2 parents 5b1d9b9 + c982102 commit 093750d
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 11 deletions.
6 changes: 3 additions & 3 deletions root/inc/breadcrumbs.html
@@ -1,5 +1,5 @@
<% BLOCK version_dropdown %>
<%- IF versions.size > 1; %>
<%- IF versions.size; %>
<%-
backpan = [];
MACRO breadcrumb_link(version) BLOCK;
Expand All @@ -25,15 +25,15 @@
<a rel="author" itemprop="author" itemscope itemtype="http://schema.org/Person" href="/author/<% module.author %>" title="<% author.asciiname %>"><% author.name %></a>
<span>&nbsp;/&nbsp;</span>
<div class="release">
<a itemprop="name" href="/release/<% IF release.status == 'latest'; release.distribution; ELSE; [module.author, module.release].join('/'); END %>"><% release.name %></a>
<span class="dropdown"><b class="caret"></b></span>
<select onchange="document.location.href=this.value"><% PROCESS version_dropdown %></select>
<a itemprop="name" href="/release/<% IF release.status == 'latest'; release.distribution; ELSE; [module.author, module.release].join('/'); END %>"><% release.name %></a>
</div>
<div class="inline"><%- INCLUDE inc/favorite.html module = module %></div>
<%- IF module %>
<span>&nbsp;/&nbsp;
<% module.documentation %></span>
<%- END %>
<div class="inline"><%- INCLUDE inc/favorite.html module = module %></div>
<%- IF release.status != 'latest' %>
<div class="pull-right">
<%- IF release.maturity == 'developer'; 'dev release, '; END %>
Expand Down
2 changes: 1 addition & 1 deletion root/inc/dependencies.html
@@ -1,4 +1,4 @@
<ul class="nav nav-list box-right hidden-phone">
<ul class="nav nav-list box-right hidden-phone dependencies">
<li class="nav-header">Dependencies</li>
<%-
deps = [];
Expand Down
6 changes: 3 additions & 3 deletions root/inc/favorite.html
Expand Up @@ -4,8 +4,8 @@
<input type="hidden" name="release" value="<% module.release || module.name %>">
<input type="hidden" name="author" value="<% module.author %>">
<input type="hidden" name="distribution" value="<% module.distribution %>">
<button type="submit" class="favorite<% IF module.favorites || release.favorites %> highlight<% END %><% IF module.myfavorite %> active<% END %>"><span><% module.favorites || release.favorites %></span> ++</button>
<button type="submit" class="favorite<% IF module.favorites || release.favorites %> highlight<% END %><% IF module.myfavorite %> active<% END %>"><% module.favorites || release.favorites %> ++</button>
</form>
<% ELSE -%>
<a href="" onclick="alert('Please sign in to add favorites'); return false" class="favorite<% IF module.favorites || release.favorites %> highlight<% END %>"><span>
<% module.favorites || release.favorites %></span> ++</a><% END -%>
<a href="" onclick="alert('Please sign in to add favorites'); return false" class="favorite<% IF module.favorites || release.favorites %> highlight<% END %>">
<% module.favorites || release.favorites %> ++</a><% END -%>
9 changes: 8 additions & 1 deletion root/static/css/style.css
Expand Up @@ -93,6 +93,12 @@ button.favorite, a.favorite {
top: -1px;
}

/* Counter-act .breadcrumbs a */
.breadcrumbs a.favorite {
font-size: 0.85em;
font-weight: normal;
}

button.favorite {
min-width: 35px;
cursor: pointer;
Expand All @@ -115,7 +121,8 @@ button.favorite:hover, button.favorite.active, a.favorite.active, a.favorite:hov
color: #fff;
text-shadow: 0px 1px 1px #333;
border-color: #36C;
opacity: 1
opacity: 1;
text-decoration: none;
}

.user-profiles > a {
Expand Down
12 changes: 9 additions & 3 deletions root/static/less/breadcrumbs.less
Expand Up @@ -21,9 +21,15 @@

select {
position: absolute;
right: -10px;
width: 30px;
left: -0.5em;
width: 1.5em;
height: 1.5em;
opacity: 0;
}

.dropdown .caret {
margin-left: auto;
margin-right: 2px;
}
}
}
}
7 changes: 7 additions & 0 deletions root/static/less/style.less
Expand Up @@ -117,6 +117,13 @@
text-decoration: underline;
}

.dependencies.nav-list.nav > li > a {
display: block;
padding: 0;
margin: 0;
width: 100%;
}

.dropdown-menu {
overflow-y: auto;
overflow-x: hidden;
Expand Down

0 comments on commit 093750d

Please sign in to comment.