header.scss 4.51 KB
Newer Older
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
1 2 3 4
/*
 *  Application Header
 *
 */
5
header {
6
  &.navbar-gitlab {
7
    margin-bottom: 0;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
8
    min-height: 40px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
9

10 11
    .navbar-inner {
      background: #F1F1F1;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
12
      border-bottom: 1px solid #DDD;
13
      filter: none;
14 15 16 17

      .nav > li > a {
        color: $style_color;
        text-shadow: 0 1px 0 #fff;
18
        font-size: 14px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
19 20 21 22 23 24
        line-height: 32px;
        padding: 6px 10px;

        &:hover {
          background: none;
        }
25 26 27 28 29 30 31
      }

      /** NAV block with links and profile **/
      .nav {
        float: right;
        margin-right: 0;
      }
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84

      .navbar-toggle {
        color: $style_color;
        margin: 0 -15px 0 0;
        padding: 10px;
        border-radius: 0;

        button i { font-size: 22px; }

        &.collapsed { background-color: transparent !important;}

        &:hover {
          background-color: #EEE;
        }
      }
    }

    @media (max-width: $screen-xs-max) {
      border-width: 0;
      font-size: 18px;

      .app_logo { margin-left: -15px; }
      .project_name {
        display: inline-block;
        overflow: hidden;
        text-overflow: ellipsis;
        vertical-align: top;
        white-space: nowrap;
        max-width: 70%;
      }

      .navbar-collapse {
        padding-right: 0;
        padding-left: 0;
      }

      .navbar-nav {
        margin: 5px 0;

        .visible-xs, .visable-sm {
          display: table-cell !important;
        }
      }

      li {
        display: table-cell;
        width: 1%;

        a {
          text-align: center;
          font-size: 18px !important;
        }
      }
85 86 87
    }
  }

88
  z-index: 10;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
89 90

  /**
91
   *
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
92 93 94 95
   * Logo holder
   *
   */
  .app_logo {
96
    float: left;
97
    margin-right: 9px;
98

99
    a {
100
      float: left;
101
      padding: 0px;
102
      margin: 0 6px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
103

104
      h1 {
105
        margin: 0;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
106 107
        background: url('logo-black.png') no-repeat center center;
        background-size: 32px;
108
        float: left;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
109
        height: 46px;
110
        width: 40px;
111
        @include header-font;
112
        text-indent: -9999px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
113 114
      }
    }
115 116 117
    &:hover {
      background-color: #EEE;
    }
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
118 119 120
  }

  /**
121
   *
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
122 123 124 125
   * Project / Area name
   *
   */
  .project_name {
126 127 128
    position: relative;
    float: left;
    margin: 0;
129
    margin-left: 5px;
130
    @include header-font;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
131 132
  }

Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
133 134
  .profile-pic {
    position: relative;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
135
    top: -1px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
136 137
    img {
      width: 26px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
138
      height: 26px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
139 140 141 142
      @include border-radius(4px);
    }
  }

Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
143
  /**
144
   *
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
145 146 147
   * Search box
   *
   */
148
  .search {
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
149
    margin-right: 10px;
150
    margin-left: 10px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
151
    margin-top: 8px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
152 153 154

    form {
      margin: 0;
155
      padding: 0;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
156
    }
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
157

Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
158
    .search-input {
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
159 160 161
      background-image: url("icon-search.png");
      background-repeat: no-repeat;
      background-position: 10px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
162 163
      height: inherit;
      padding: 4px 6px;
164
      padding-left: 25px;
165
      font-size: 13px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
166
      @include border-radius(3px);
167
      border: 1px solid #c6c6c6;
168
      box-shadow: none;
169
      @include transition(all 0.15s ease-in 0s);
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
170 171 172
    }
  }

173 174 175 176 177 178 179 180 181 182 183

  /*
   * Dark header
   *
   */
  &.header-dark {
    &.navbar-gitlab {
      .navbar-inner {
        background: #708090;
        border-bottom: 1px solid #AAA;

184 185
        .navbar-toggle { color: #fff; }

186
        .nav > li > a {
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
187
          color: #AAA;
188 189 190 191 192
          text-shadow: 0 1px 0 #444;

          &:hover {
            color: #FFF;
          }
193 194 195 196
        }
      }
    }

Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
197 198
    .turbolink-spinner {
      color: #FFF;
199 200
      font-size: 22px;
      margin-right: 10px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
201 202
    }

203 204 205 206
    .search {
      .search-input {
        background-color: #D2D5DA;
        background-color: rgba(255, 255, 255, 0.5);
207
        border: 1px solid #AAA;
208 209 210 211 212 213 214 215 216 217 218 219

        &:focus {
          background-color: white;
        }
      }
    }
    .search-input::-webkit-input-placeholder {
      color: #666;
    }
    .app_logo {
      a {
        h1 {
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
220 221
          background: url('logo-white.png') no-repeat center center;
          background-size: 32px;
222
          color: #fff;
223
          text-shadow: 0 1px 1px #444;
224 225 226 227
        }
      }
    }
    .project_name {
228
      a {
229
        color: #BBB;
230 231 232
        &:hover {
          color: #FFF;
        }
233
      }
234
      color: #fff;
235
      text-shadow: 0 1px 1px #444;
236 237
    }
  }
238 239 240 241 242 243 244 245 246 247

  .app_logo {
    .separator {
      margin-left: 0;
      margin-right: 0;
    }
  }

  .separator {
    float: left;
248
    height: 46px;
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
249
    width: 2px;
250 251 252 253 254
    background: white;
    border-left: 1px solid #DDD;
    margin-left: 10px;
    margin-right: 10px;
  }
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
255 256
}

257 258 259 260 261 262 263 264 265 266 267 268 269 270 271
.search .search-input {
  width: 300px;
  &:focus {
    width: 400px;
  }
}

@media (max-width: 1200px)  {
  .search .search-input {
    width: 200px;
    &:focus {
      width: 300px;
    }
  }
}