gitlabhq/app/assets/stylesheets/sections/header.scss
2013-03-10 00:12:25 +02:00

279 lines
5.7 KiB
SCSS

/*
* Application Header
*
*/
header {
&.navbar-gitlab {
.navbar-inner {
height: 40px;
padding: 3px;
background: #F1F1F1;
filter: none;
.nav > li > a {
color: $style_color;
text-shadow: 0 1px 0 #fff;
font-size: 16px;
padding: 10px;
}
/** NAV block with links and profile **/
.nav {
float: right;
margin-right: 0;
}
}
}
z-index: 10;
/**
*
* Logo holder
*
*/
.app_logo {
float: left;
margin-right: 9px;
position: relative;
top: -5px;
padding-top: 5px;
a {
float: left;
padding: 0px;
margin: 0 6px;
h1 {
background: url('logo-black.png') no-repeat center 1px;
background-size: 38px;
float: left;
height: 40px;
width: 40px;
@include header-font;
text-indent: -9999px;
}
}
&:hover {
background-color: #EEE;
}
}
/**
*
* Project / Area name
*
*/
.project_name {
position: relative;
float: left;
margin: 0;
margin-left: 10px;
@include header-font;
}
/**
*
* Search box
*
*/
.search {
margin-right: 45px;
margin-left: 10px;
.search-input {
@extend .span2;
background-image: url("icon-search.png");
background-repeat: no-repeat;
background-position: 10px;
padding-left: 25px;
font-size: 13px;
@include border-radius(3px);
border: 1px solid #c6c6c6;
box-shadow: none;
@include transition(all 0.15s ease-in 0s);
&:focus {
@extend .span3;
}
}
}
/**
*
* Account box
*
*/
.account-box {
position: absolute;
right: 0;
top: 4px;
z-index: 10000;
width: 128px;
font-size: 11px;
float: right;
display: block;
cursor: pointer;
img {
@include border-radius(3px);
right: 5px;
position: absolute;
width: 28px;
height: 28px;
display: block;
top: 1px;
&:after {
content: " ";
display: block;
position: absolute;
top: 0;
right: 0;
left: 0;
bottom: 0;
float: right;
@include border-radius(5px);
border: 1px solid rgba(255, 255, 255, 0.1);
border-bottom: 0;
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(rgba(255, 255, 255, 0.15)), to(rgba(0, 0, 0, 0.25))),
-webkit-gradient(linear, left top, right bottom, color-stop(0, rgba(255, 255, 255, 0)), color-stop(0.5, rgba(255, 255, 255, 0.1)), color-stop(0.501, rgba(255, 255, 255, 0)), color-stop(1, rgba(255, 255, 255, 0)));
background: -moz-linear-gradient(top, rgba(255, 255, 255, 0.15), rgba(0, 0, 0, 0.25)),
-moz-linear-gradient(left top, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.1) 50%, rgba(255, 255, 255, 0) 50%, rgba(255, 255, 255, 0));
background: linear-gradient(top, rgba(255, 255, 255, 0.15), rgba(0, 0, 0, 0.25)),
linear-gradient(left top, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.1) 50%, rgba(255, 255, 255, 0) 50%, rgba(255, 255, 255, 0));
-webkit-background-origin: border-box;
-moz-background-origin: border;
background-origin: border-box; } } }
.account-box {
&.hover {
height: 138px; }
&:hover > .account-links {
display: block; } }
.account-links {
@include border-radius(5px);
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
position: relative;
&:before {
content: ".";
width: 0;
height: 0;
position: absolute;
border: 5px solid transparent;
border-color: rgba(255, 255, 255, 0);
border-bottom-color: #555;
text-indent: -9999px;
top: -10px;
line-height: 0;
right: 10px;
z-index: 10; }
background: #555;
display: none;
z-index: 100000;
@include border-radius(4px);
width: 130px;
position: absolute;
right: 5px;
top: 38px;
margin-top: 0;
float: right;
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
a {
color: #fff;
padding: 12px 15px;
display: block;
text-shadow: none;
border-bottom: 1px solid #666;
font-size: 12px;
&:hover {
color: #fff;
background: #333;
}
}
}
.account-box.hover .arrow-up {
top: 41px;
right: 6px;
position: absolute; }
.account-links a {
&:first-child {
@include border-radius(5px 5px 0 0);
}
&:last-child {
@include border-radius(0 0 5px 5px);
border-bottom: 0;
}
}
/*
* Dark header
*
*/
&.header-dark {
&.navbar-gitlab {
.navbar-inner {
background: #708090;
border-bottom: 1px solid #AAA;
.nav > li > a {
color: #fff;
text-shadow: 0 1px 0 #111;
}
}
}
.search {
.search-input {
background-color: #D2D5DA;
background-color: rgba(255, 255, 255, 0.5);
border: 1px solid #AAA;
&:focus {
background-color: white;
}
}
}
.search-input::-webkit-input-placeholder {
color: #666;
}
.app_logo {
a {
h1 {
background: url('logo-white.png') no-repeat center 1px;
background-size: 38px;
color: #fff;
text-shadow: 0 1px 1px #111;
}
}
}
.project_name {
a {
color: #FFF;
}
color: #fff;
text-shadow: 0 1px 1px #111;
}
}
.app_logo {
.separator {
margin-left: 0;
margin-right: 0;
}
}
.separator {
float: left;
height: 46px;
width: 1px;
background: white;
border-left: 1px solid #DDD;
margin-top: -3px;
margin-left: 10px;
margin-right: 10px;
}
}