Merge pull request #837 from kvch/smaller-navbar

[enh] make navbar smaller
This commit is contained in:
Adam Tauber 2017-01-27 00:09:36 +01:00 committed by GitHub
commit 42606f53dd
5 changed files with 48 additions and 120 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,89 +1,31 @@
.navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:hover, .navbar-default .navbar-nav > .active > a:focus{ .searx-navbar {
background: @black; background: @black;
height: 2.3rem;
font-size: 1.3rem;
line-height: 1.3rem;
padding: 0.5rem;
font-weight: bold;
margin-bottom: 0.8rem;
a, a:hover {
margin-right: 2.0rem;
color: white;
text-decoration: none;
}
.instance a {
color: @light-green; color: @light-green;
} margin-left: 2.0rem;
.navbar > li > a {
padding: 0;
margin: 0;
}
.navbar-nav > li > a {
background: @black;
padding: 0 8px;
margin: 0;
line-height: 30px;
}
.navbar, .navbar-default, .menu {
background-color: @black;
border: none;
border-top: 4px solid @light-green;
padding-top: 5px;
color: @dim-gray !important;
font-weight: 700;
font-size: 1.1em;
text-transform: lowercase;
margin-bottom: 24px;
height: 30px;
line-height: 30px;
.navbar-nav > li > a{
color: @dim-gray;
}
.navbar-brand{
font-weight: 700;
color: @light-green;
line-height: 30px;
padding: 0 30px;
margin: 0;
}
z-index: 10;
}
// Hover color
// http://stackoverflow.com/users/114029/leniel-macaferi
.navbar-default .navbar-nav > li > a:hover, .navbar-default .navbar-nav > li > a:focus {
color: @light-green;
background: @black;
}
.navbar-toggle {
margin-top: 0;
}
.menu {
margin: 0;
padding: 0;
position: absolute;
top: 4px;
border: 0;
z-index: 1000000000;
height: 40px;
line-height: 40px;
ul {
padding: 0;
margin: 0;
li {
padding: 0 0.6em;
margin: 0;
float: left;
list-style: none;
a {
color: @dim-gray;
}
}
li.active a {
color: @light-green;
}
} }
} }
.menu-right { #main-logo {
right: 2em; margin-top: 20vh;
margin-bottom: 25px;
& > img {
max-width: 350px;
width: 80%;
}
} }
.menu-left {
left: 2em;
}

View File

@ -1,28 +1,19 @@
.menu { .searx-navbar {
margin: 0; background: #eee;
padding: 0; color: #aaa;
position: absolute; height: 2.3rem;
top: 4px; font-size: 1.3rem;
border: 0; line-height: 1.3rem;
z-index: 1000000000; padding: 0.5rem;
height: 40px; font-weight: bold;
line-height: 40px;
ul { a, a:hover {
padding: 0; margin-right: 2.0rem;
margin: 0; text-decoration: none;
li {
padding: 0 0.6em;
margin: 0;
float: left;
list-style: none;
}
}
} }
.menu-right { .instance a {
right: 2em; color: #444;
margin-left: 2.0rem;
} }
.menu-left {
left: 2em;
} }

View File

@ -1,14 +1,9 @@
<!-- Static navbar --> <div class="searx-navbar">
<div class="navbar navbar-default" role="navigation"> <span class="instance {% if rtl %}pull-right{% else %}pull-left{% endif%}">
<div class="container-fluid"> <a href="{{ url_for('index') }}">{{ instance_name }}</a>
<div class="navbar-header{% if rtl %} navbar-right{% endif %}"> </span>
<a class="navbar-brand" href="{{ url_for('index') }}">{{ instance_name }}</a> <span class="{% if rtl %}pull-left{% else %}pull-right{% endif %}">
<a href="{{ url_for('about') }}">{{ _('about') }}</a>
<a href="{{ url_for('preferences') }}">{{ _('preferences') }}</a>
</span>
</div> </div>
</div><!--/.container-fluid -->
</div>
<div class="menu menu-{% if rtl %}left{% else %}right{% endif %}">
<ul> <!-- results.html -->
<li{% if template_name == 'about.html' %} class="active"{% endif %}><a href="{{ url_for('about') }}" class="hmarg">{{ _('about') }}</a></li>
<li{% if template_name == 'preferences.html' %} class="active"{% endif %}><a href="{{ url_for('preferences') }}" class="hmarg">{{ _('preferences') }}</a></li>
</ul>
</div><!--/.nav-collapse -->