# HG changeset patch # User domruf # Date 1474391017 -7200 # Node ID 8bd7a637cea00de25ab9c4b305a713b2cb2feceb # Parent 71acaf87e5a25a1a88828a9d6159324a07a4b99f template: use Bootstrap compatible navbar markup Based on work from Andrew Shadura . Further modified by Mads Kiilerich. diff -r 71acaf87e5a2 -r 8bd7a637cea0 kallithea/public/css/contextbar.css --- a/kallithea/public/css/contextbar.css Wed Sep 21 19:58:44 2016 +0200 +++ b/kallithea/public/css/contextbar.css Tue Sep 20 19:03:37 2016 +0200 @@ -48,20 +48,20 @@ min-height: 36px; } -#content #context-bar h2 { +#content #context-bar .navbar-header { display: inline-block; color: #FFF; margin: 8px 20px 3px; padding-bottom: 2px; } -#header #header-inner #quick a, +nav.navbar #quick a, #content #context-bar, #content #context-bar a { color: #FFFFFF; } -#header #header-inner #quick a:hover, +nav.navbar #quick a:hover, #content #context-bar a:hover { text-decoration: none; } @@ -77,16 +77,19 @@ margin: 0; } +ul.navbar-nav, ul.horizontal-list { display: block; } +ul.navbar-nav > li, ul.horizontal-list > li { float: left; position: relative; } -#header #header-inner #quick ul, +nav.navbar #quick ul, +ul.navbar-nav > li ul, ul.horizontal-list > li ul { position: absolute; display: none; @@ -94,13 +97,15 @@ z-index: 999; } -#header #header-inner #quick li ul li, +nav.navbar #quick li ul li, +ul.navbar-nav ul li, ul.horizontal-list ul li { position: relative; border-bottom: 1px solid rgba(0,0,0,0.1); border-top: 1px solid rgba(255,255,255,0.1); } +ul.navbar-nav > li ul ul, ul.horizontal-list > li ul ul { position: absolute; right: 100%; @@ -111,7 +116,8 @@ overflow-y: auto; } -#header #header-inner #quick ul a, +nav.navbar #quick ul a, +ul.navbar-nav li a, ul.horizontal-list li a { white-space: nowrap; } @@ -129,7 +135,7 @@ font-size: 1.4em; } -#header #header-inner #quick ul, +nav.navbar #quick ul, #revision-changer, #context-pages, #context-pages ul { @@ -137,7 +143,7 @@ background: linear-gradient(to bottom, #577632 0%, #577632 100%); /* W3C */ } -#header #header-inner #quick a, +nav.navbar #quick a, #context-actions a, #context-pages a { background-repeat: no-repeat; @@ -180,14 +186,14 @@ } ul.dropdown-menu li a:focus, -#header #header-inner #quick li:hover, +nav.navbar #quick li:hover, #revision-changer:hover, #context-pages li:hover, #context-actions li:hover, #content #context-actions li:hover, -#header #header-inner #quick li.current, -#header #header-inner #quick li a.menu_link:focus, -#context-pages li.current { +nav.navbar #quick li.active, +nav.navbar #quick li a.menu_link:focus, +#context-pages li.active { background: #6388ad; /* Old browsers */ background: linear-gradient(to bottom, rgba(255,255,255,0.2) 0%, rgba(255,255,255,0.1) 100%); /* W3C */ } @@ -225,27 +231,27 @@ margin-right: 5px; } -#header #header-inner #quick li, +nav.navbar #quick li, #content #context-pages li { border-right: 1px solid rgba(0,0,0,0.1); border-left: 1px solid rgba(255,255,255,0.1); padding: 0; } -#header #header-inner #quick li:last-child, +nav.navbar #quick li:last-child, #content #context-pages li:last-child { border-right: none; } -#header #header-inner #quick > li:first-child { +nav.navbar #quick > li:first-child { border-left: none; } -#header #header-inner #quick > li:first-child > a { +nav.navbar #quick > li:first-child > a { border-radius: 4px 0 0 4px; } -#header #header-inner #quick a, +nav.navbar #quick a, #context-pages a, #context-pages .dropdown-menu a { display: block; @@ -253,17 +259,17 @@ line-height: 35px; } -#header #header-inner #quick a.thin, +nav.navbar #quick a.thin, #context-pages a.thin, #context-pages .dropdown-menu a.thin { line-height: 28px !important; } -#header #header-inner #quick a#quick_login_link { +nav.navbar #quick a#quick_login_link { padding-left: 0px; } -#header #header-inner #quick a { +nav.navbar #quick a { overflow: hidden; } #context-pages a.dropdown-toggle:after { diff -r 71acaf87e5a2 -r 8bd7a637cea0 kallithea/public/css/style.css --- a/kallithea/public/css/style.css Wed Sep 21 19:58:44 2016 +0200 +++ b/kallithea/public/css/style.css Tue Sep 20 19:03:37 2016 +0200 @@ -265,25 +265,33 @@ visibility: visible; } -#header #logo { +nav.navbar #logo { padding-left: 10px; } -div.header img { +#content nav.navbar #logo { + padding-left: inherit; +} + +nav.navbar #logo .navbar-brand img { padding-top: 5px; -} - -#header #logo div.header, -#header #logo div.branding { + margin-right: 5px; +} + +nav.navbar #logo .navbar-brand { font-size: 20px; color: white; float: left; height: 44px; line-height: 44px; - margin-right: 5px; -} - -#header ul#logged-user { +} + +#content nav.navbar #logo .navbar-brand { + height: inherit; + line-height: inherit; +} + +nav.navbar ul#logged-user { margin-bottom: 5px !important; border-radius: 0px 0px 8px 8px; height: 37px; @@ -293,7 +301,7 @@ box-shadow: 0 2px 2px rgba(0, 0, 0, 0.6); } -#header ul#logged-user li { +nav.navbar ul#logged-user li { list-style: none; float: left; margin: 8px 0 0; @@ -301,58 +309,42 @@ border-left: 1px solid #576622; } -#header ul#logged-user li.first { +nav.navbar ul#logged-user li.first { border-left: none; margin: 4px; } -#header ul#logged-user li.first div.gravatar { +nav.navbar ul#logged-user li.first div.gravatar { margin-top: -2px; } -#header ul#logged-user li.first div.account { +nav.navbar ul#logged-user li.first div.account { padding-top: 4px; float: left; } -#header ul#logged-user li.last { +nav.navbar ul#logged-user li.last { border-right: none; } -#header ul#logged-user li a { +nav.navbar ul#logged-user li a { color: #fff; font-weight: 700; text-decoration: none; } -#header ul#logged-user li a:hover { +nav.navbar ul#logged-user li a:hover { text-decoration: underline; } -#header ul#logged-user li.highlight a { +nav.navbar ul#logged-user li.highlight a { color: #fff; } -#header ul#logged-user li.highlight a:hover { +nav.navbar ul#logged-user li.highlight a:hover { color: #FFF; } -#header-dd { - clear: both; - position: fixed !important; - background-color: #577632; - opacity: 0.01; - cursor: pointer; - min-height: 10px; - width: 100% !important; - border-radius: 0px 0px 4px 4px; -} - -#header-dd:hover { - opacity: 0.2; - transition: opacity 0.5s ease-in-out; -} - -#header #header-inner { +nav.navbar { min-height: 44px; clear: both; position: relative; @@ -365,19 +357,14 @@ box-shadow: 0 2px 2px rgba(0, 0, 0, 0.6); border-radius: 0px 0px 4px 4px; } -#header #header-inner.hover { - width: 100% !important; - border-radius: 0px 0px 0px 0px; - position: fixed !important; - z-index: 10000; -} - -.header-pos-fix, .anchor { + +.header-pos-fix, +.anchor { margin-top: -46px; padding-top: 46px; } -#header #header-inner #home a { +nav.navbar #home a { height: 40px; width: 46px; display: block; @@ -386,32 +373,32 @@ padding: 0; } -#header #header-inner #home a:hover { +nav.navbar #home a:hover { background-position: 0 -40px; } -#header #header-inner #logo { +nav.navbar #logo { float: left; position: absolute; } -#header #header-inner #logo h1 { +nav.navbar #logo h1 { color: #FFF; font-size: 20px; margin: 12px 0 0 13px; padding: 0; } -#header #header-inner #logo a { +nav.navbar #logo a { color: #fff; text-decoration: none; } -#header #header-inner #logo a:hover { +nav.navbar #logo a:hover { color: #bfe3ff; } -#header #header-inner #quick { +nav.navbar #quick { position: relative; float: right; list-style-type: none; @@ -421,63 +408,59 @@ border-radius: 4px; } -#header #header-inner #quick li span.short { +nav.navbar #quick li span.short { padding: 9px 6px 8px 6px; } -#header #header-inner #quick li span { +nav.navbar #quick li span { display: inline; margin: 0; } -#header #header-inner #quick li span.normal { +nav.navbar #quick li span.normal { border: none; padding: 10px 12px 8px; } -#header #header-inner #quick li .icon { +nav.navbar #quick li .icon { border-left: none; padding-left: 10px; -} - -#header #header-inner #quick li .icon_short { - top: 0; - left: 0; - border-left: none; - border-right: 1px solid #2e5c89; - padding: 8px 6px 4px; -} - -#header #header-inner #quick li .icon img, -#header #header-inner #quick li .icon_short img { + display: inline; +} + +nav.navbar #quick li .icon img { vertical-align: middle; margin-bottom: 2px; } -#header #header-inner #quick ul.repo_switcher { +nav.navbar #quick ul.repo_switcher { max-height: 275px; overflow-x: hidden; overflow-y: auto; } -#header #header-inner #quick ul.repo_switcher li.qfilter_rs { +nav.navbar #quick ul.repo_switcher li.qfilter_rs { padding: 2px 3px; padding-right: 17px; } -#header #header-inner #quick ul.repo_switcher li.qfilter_rs input { +nav.navbar #quick ul.repo_switcher li.qfilter_rs input { width: 100%; border-radius: 10px; padding: 2px 7px; } -#header #header-inner #quick .repo_switcher_type { +nav.navbar #quick .repo_switcher_type { position: absolute; left: 0; top: 9px; margin: 0px 2px 0px 2px; } +.navbar-toggle { + display: none; +} + .groups_breadcrumbs a { color: #fff; } @@ -522,6 +505,7 @@ margin: 0 60px 10px 290px; } +#content nav.navbar, #content div.panel { clear: both; background: #fff; @@ -2906,7 +2890,7 @@ border-radius: 2px; } -#header, #content, #footer { +nav.navbar, #content, #footer { min-width: 978px; } @@ -3114,7 +3098,7 @@ } img, -#header #header-inner #quick li a:hover span.normal, +nav.navbar #quick li a:hover span.normal, #clone_url, #clone_url_id { @@ -3125,7 +3109,7 @@ vertical-align: bottom; } -#header ul#logged-user, +nav.navbar ul#logged-user, #content div.panel div.panel-heading ul.links, #content div.panel div.message div.dismiss, #content div.panel div.traffic div.legend ul { @@ -3134,8 +3118,8 @@ padding: 0; } -#header #header-inner #home, -#header #header-inner #logo, +nav.navbar #home, +nav.navbar #logo, #content div.panel ul.left, #content div.panel ol.left, div#commit_history, @@ -3143,7 +3127,7 @@ float: left; } -#header #header-inner #quick li #quick_login, +nav.navbar #quick li #quick_login, #content #left #menu ul.closed, #content #left #menu li ul.collapsed, .yui-tt-shadow { @@ -3161,12 +3145,16 @@ content: ' \23f7'; /* triangle-down */ } +.branch-switcher .select2-choice, .repo-switcher .select2-choice { padding: 0px 8px 1px !important; display: block; height: 100%; } +.branch-switcher .select2-container, +.branch-switcher .select2-choice, +.branch-switcher .select2-choice span, .repo-switcher .select2-container, .repo-switcher .select2-choice, .repo-switcher .select2-choice span { @@ -3176,16 +3164,19 @@ color: #FFFFFF !important; } +.branch-switcher .select2-arrow, .repo-switcher .select2-arrow { display: none !important; } +.branch-switcher-dropdown.select2-drop.select2-drop-active, .repo-switcher-dropdown.select2-drop.select2-drop-active { box-shadow: none; color: #fff; background-color: #576622; } +.branch-switcher-dropdown.select2-drop.select2-drop-active .select2-results .select2-highlighted, .repo-switcher-dropdown.select2-drop.select2-drop-active .select2-results .select2-highlighted { background-color: #6388ad; } diff -r 71acaf87e5a2 -r 8bd7a637cea0 kallithea/templates/base/base.html --- a/kallithea/templates/base/base.html Wed Sep 21 19:58:44 2016 +0200 +++ b/kallithea/templates/base/base.html Tue Sep 20 19:03:37 2016 +0200 @@ -93,8 +93,9 @@ <%def name="repo_context_bar(current=None, rev=None)"> <% rev = None if rev == 'tip' else rev %> -
-

+

-
+ + -
  • +
  • ${_('Pull Requests')} %if c.repository_pull_requests: ${c.repository_pull_requests} %endif
  • - - + +