From cf49c6a4378f586ceafd0ff2c426e2914a931c37 Mon Sep 17 00:00:00 2001 From: Thomas Sibley Date: Sat, 1 Feb 2014 17:38:20 -0800 Subject: [PATCH 1/4] Show the release versions dropdown even if there's only a single release Otherwise it's an empty dropdown, which is confusing and looks weird. While we could hide the dropdown toggle (caret) altogether when there is only a single release, always show it for consistency across all distributions. --- root/inc/breadcrumbs.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/root/inc/breadcrumbs.html b/root/inc/breadcrumbs.html index c689953960..5602a41388 100644 --- a/root/inc/breadcrumbs.html +++ b/root/inc/breadcrumbs.html @@ -1,5 +1,5 @@ <% BLOCK version_dropdown %> -<%- IF versions.size > 1; %> +<%- IF versions.size; %> <%- backpan = []; MACRO breadcrumb_link(version) BLOCK; From e7dd3d70e94ba77b3c74554f570ffef8ffd03122 Mon Sep 17 00:00:00 2001 From: Thomas Sibley Date: Sat, 1 Feb 2014 17:42:02 -0800 Subject: [PATCH 2/4] Move the favorite button back into the breadcrumbs next to the release Effectively re-applies 77e99e3 on the new bootstrap layout. Positioning of the version dropdown caret is adjusted slightly (and made relative to font-size) to accommodate proximity to the favorite button. --- root/inc/breadcrumbs.html | 2 +- root/inc/favorite.html | 6 +++--- root/static/css/style.css | 9 ++++++++- root/static/less/breadcrumbs.less | 7 ++++--- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/root/inc/breadcrumbs.html b/root/inc/breadcrumbs.html index 5602a41388..4a3c45e08d 100644 --- a/root/inc/breadcrumbs.html +++ b/root/inc/breadcrumbs.html @@ -29,11 +29,11 @@ +
<%- INCLUDE inc/favorite.html module = module %>
<%- IF module %>  /  <% module.documentation %> <%- END %> -
<%- INCLUDE inc/favorite.html module = module %>
<%- IF release.status != 'latest' %>
<%- IF release.maturity == 'developer'; 'dev release, '; END %> diff --git a/root/inc/favorite.html b/root/inc/favorite.html index 7eab530f0a..e051445054 100644 --- a/root/inc/favorite.html +++ b/root/inc/favorite.html @@ -4,8 +4,8 @@ - + <% ELSE -%> - -<% module.favorites || release.favorites %> ++<% END -%> + +<% module.favorites || release.favorites %> ++<% END -%> diff --git a/root/static/css/style.css b/root/static/css/style.css index 309d66b828..dc70f9ba14 100644 --- a/root/static/css/style.css +++ b/root/static/css/style.css @@ -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; @@ -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 { diff --git a/root/static/less/breadcrumbs.less b/root/static/less/breadcrumbs.less index 615715b35b..d0a8df4dc8 100644 --- a/root/static/less/breadcrumbs.less +++ b/root/static/less/breadcrumbs.less @@ -21,9 +21,10 @@ select { position: absolute; - right: -10px; - width: 30px; + right: -0.5em; + width: 1.5em; + height: 1.5em; opacity: 0; } } -} \ No newline at end of file +} From 9905e29237d7d16057df99c1e8f0a416520008de Mon Sep 17 00:00:00 2001 From: Thomas Sibley Date: Sat, 1 Feb 2014 17:43:35 -0800 Subject: [PATCH 3/4] Move the release versions dropdown to the left side of the breadcrumb Nicely de-clutters the right side of the release breadcrumb now that the favorite button is there. This also causes the options list itself to appear directly underneath the breadcrumb instead of awkwardly to the right. The net result is that it actually appears more like a cohesive dropdown. --- root/inc/breadcrumbs.html | 2 +- root/static/less/breadcrumbs.less | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/root/inc/breadcrumbs.html b/root/inc/breadcrumbs.html index 4a3c45e08d..ee08b27a2a 100644 --- a/root/inc/breadcrumbs.html +++ b/root/inc/breadcrumbs.html @@ -25,9 +25,9 @@  / 
- <% release.name %> + <% release.name %>
<%- INCLUDE inc/favorite.html module = module %>
<%- IF module %> diff --git a/root/static/less/breadcrumbs.less b/root/static/less/breadcrumbs.less index d0a8df4dc8..6f68252f08 100644 --- a/root/static/less/breadcrumbs.less +++ b/root/static/less/breadcrumbs.less @@ -21,10 +21,15 @@ select { position: absolute; - right: -0.5em; + left: -0.5em; width: 1.5em; height: 1.5em; opacity: 0; } + + .dropdown .caret { + margin-left: auto; + margin-right: 2px; + } } } From c982102955c8bc246e137d7d911a86dce5bd8071 Mon Sep 17 00:00:00 2001 From: Thomas Sibley Date: Sat, 1 Feb 2014 17:58:21 -0800 Subject: [PATCH 4/4] Make sure each dependency link has a width and isn't cut off unreasonably early Previously these were displayed inline (due to 851a6fc), and inline elements don't have a width. Set zero padding and margin and take up the whole width of the container instead. --- root/inc/dependencies.html | 2 +- root/static/less/style.less | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/root/inc/dependencies.html b/root/inc/dependencies.html index 2b3ddf1ee5..16c2202a75 100644 --- a/root/inc/dependencies.html +++ b/root/inc/dependencies.html @@ -1,4 +1,4 @@ -