header.scss 8.06 KB
Newer Older
1 2 3 4 5
.timeago {
  color: $text-grey;
  border-bottom: none;
}

6
body > header {
7
  @include header-gradient($header-background-color);
8
  box-shadow: 0 1px 3px rgba(0,0,0,0.9);
9 10 11
  z-index: 1001;
  padding: 6px 0;
  color: #CCC;
Augier's avatar
Augier committed
12
  height: 39px;
13 14
  position: fixed;
  width: 100%;
Fla's avatar
Fla committed
15
  min-width: 620px;
16 17
  top: 0;
  left: 0;
18
  border-bottom: 1px solid darken($header-background-color, 8%);
19

20 21 22 23
  > div > div.container {
    height: 26px;
  }

24 25 26 27 28 29
  .diaspora_header_logo {
    float: left;
    margin-top: -6px;
    height: 38px;
    width: 65px;
  }
30

31 32 33 34 35 36
  .ie-user-menu-active { height: 150px; }

  a.header_root_link {
    display: inline-block;
    margin-top: 5px;
  }
37

38 39 40 41
  a {
    color: #CCC;
    color: rgb(147,147,147);

42
    &:hover, &:focus {
43
      background: none;
44
      color: $highlight-white;
45
    }
SpF's avatar
SpF committed
46
    &:focus {
47 48
      outline: thin dotted $border-dark-grey;
      text-decoration: none;
SpF's avatar
SpF committed
49
    }
50 51 52 53 54 55
  }

  &.landing {
    height: 40px;
    .right { top: 10px; }
  }
56

57 58 59 60
  #nav_badges {
    display: inline-block;
    margin-top: 2px;
    float: left;
Fla's avatar
Fla committed
61
    width: 61px;
62 63 64 65 66 67 68 69

    a:hover { text-decoration: none; }

    .badge {
      width: 22px;
      position: relative;
      top: 2px;
      display: inline;
70
      margin: 0 2px;
71 72 73
      font-weight: bold;
      font-size: smaller;

Fla's avatar
Fla committed
74
      .badge_count {
75
        border-radius: 2px;
Fla's avatar
Fla committed
76 77 78 79 80
        z-index: 3;
        position: absolute;
        top: -4px;
        left: 15px;
        padding: 1px 2px;
81
        background-color: $red;
Fla's avatar
Fla committed
82 83 84 85
        line-height: 12px;
        color: #fff;
      }

86 87
      &:hover .badge_count { background-color: lighten($red, 5%); }

88
      .icons-notifications_grey { height: 16px; }
89 90 91 92 93

      &.active .icons-notifications_grey:hover {
        background-position: sprite-position($icons-sprites, notifications_grey);
      }

94 95 96 97 98 99 100 101 102
      .icons-mail_grey { height: 11px }

      a.badge_link {
        display: block;
        width: 100%;
        height: 16px;
        float: left;
      }
    }
103

104
    #notification_badge, #conversations_badge {
105 106 107
      float: left;
      padding: 0px 3px;
    }
108

109
    #conversations_badge {
110
      padding-top: 3px;
Fla's avatar
Fla committed
111 112 113
      margin-right: 0px;
      padding-right: 0px;
    }
114

Fla's avatar
Fla committed
115 116 117
    #notification_badge.active {
      z-index: 10;
      background-color: #fff;
Srihari Sriraman's avatar
Srihari Sriraman committed
118
      border: 1px solid $border-dark-grey;
Fla's avatar
Fla committed
119 120 121
      border-bottom: 0px;
      margin-left: 0px;
      padding-bottom: 12px;
122 123 124 125
    }

    #notification_dropdown {
      background: white;
Srihari Sriraman's avatar
Srihari Sriraman committed
126
      border: solid $border-dark-grey 1px;
127
      box-shadow: 0 0px 13px rgba(20,20,20,0.5);
128 129 130 131
      left: 300px;
      width: 380px;
      display: none;
      float: left;
132
      color: $grey;
133 134

      a { color: $blue; }
135 136 137 138
      a.disabled {
        color: $link-disabled-grey;
        cursor: default;
      }
139 140

      .header {
141 142
        border-bottom: 1px solid $border-grey;
        padding: 5px 10px 5px 5px;
143

144 145 146
        h4 {
          padding-bottom: 0;
          margin-bottom: 0;
147 148
          font-size: 16px;
          color: $black;
149 150
        }

151
        a {
152
          font-size: $font-size-small;
153 154 155
          font-weight: bold;
        }
      }
156 157

      .ajax_loader {
158
        border-bottom: 1px solid $border-grey;
159
        padding: 15px;
160
        img { height: 21px; }
161
      }
162 163 164 165
      .notifications{
        overflow: hidden;
        position: relative;
        max-height: 325px;
166

167 168 169 170 171 172
        .media.stream_element {
          border-bottom: 1px solid $border-grey;
          padding: 5px;
          min-height: 35px;
          line-height: 18px;
          margin: 0;
173

174 175 176 177 178
          img.avatar {
            width: 35px;
            height: 35px;
          }

179 180 181 182
          .media-body {
            word-break: break-all;
          }

183 184
          .pull-right > .aspect_membership_dropdown { display: none; }
          .unread-toggle { margin: 10px; }
185 186 187 188 189 190 191

          .entypo {
            cursor: pointer;
            color: lighten($black,75%);
            font-size: 17px;
            line-height: 17px;
          }
192 193 194
          .tooltip {
            position: fixed;
          }
195

196 197 198 199 200 201
          &.unread {
            background-color: $background-grey;
            color: $black;
            .unread-toggle {
              .entypo { color: $black; }
            }
202
          }
203

204 205 206 207 208 209 210 211 212 213 214 215
        }
      }

      .view_all {
        background-color: $blue;
        border-bottom: 1px solid $border-dark-grey;
        text-align: center;
        a {
          display: block;
          padding: 5px;
          color: white;
          font-size: 12px;
216 217 218 219 220
          font-weight: bold;
        }
      }
    }
  }
221

222 223 224 225 226 227 228 229
  #global_search {
    float: right;
    margin-right: 10px;
    position: relative;

    form {
      position: absolute;
      right: 0;
230

231
      input {
232 233
        box-shadow: 0 1px 1px #444;
        border-radius: 15px;
234 235 236 237 238 239
        @include transition(width);
        width: 100px;
        background-color: #444;
        border: 1px solid #222;
        font-size: 13px;
        padding: 4px;
240
        margin-top: 1px;
241 242 243 244

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

        &.active {
245
          background-color: $highlight-white;
246 247 248 249 250 251 252 253 254
          background-color: rgba(160,160,160,0.6);
        }

        &:focus {
          outline: none;
          background-color: white;
          width: 200px;
        }

255 256
        &::input-placeholder { text-shadow: none; }
        &::placeholder { text-shadow: none; }
257
        &.ac_loading::-webkit-search-cancel-button { -webkit-appearance: none; }
258 259 260 261 262 263 264 265 266 267 268 269 270 271
      }
    }
  }

  ul#user_menu {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    text-shadow: 0 1px 0 #000;
    color: rgb(147,147,147);
    min-width: 100px;
    cursor: pointer;
    z-index: 10;
    display: inline;
272
    visibility: hidden;
273
    top: -4px;
274
    float: right;
275
    margin: -2px -3px 0px 0px;
276
    padding: 0;
277

278 279 280 281 282 283 284 285 286 287 288 289 290
    > li {
      display: block;
      border-left: 1px solid #333;
      border-right: 1px solid #333;

      &:first-child {
        visibility: visible;
      }

      &:last-child {
        border-bottom: 1px solid #333;
      }
    }
291 292

    &.active {
293
      box-shadow: 0 0px 13px rgba(20,20,20,0.5);
294
      background-color: rgb(34,30,30);
295 296 297 298 299
      visibility: visible;

      > li {
        border-color: $border-dark-grey;
      }
300
    }
301
  }
302

303
  .user-menu-item a {
304
    padding: 4px 8px 4px 40px;
305
    height: 100%;
306
    color: $text-grey;
307 308 309

    &:hover {
      background-color: $blue;
310
      color: $highlight-white;
311 312 313 314 315
      text-decoration: none;
    }
  }

  .user-menu-trigger {
316
    padding: 10px 25px 10px 40px;
317 318

    &:hover {
319 320
      color: $highlight-white;
      .user-name { color: $highlight-white; }
321 322 323 324 325 326 327 328
    }
  }

  .user-name {

    &:hover {
      background-color: transparent;
      text-decoration: none;
329
    }
330

331
    &:focus { outline: none; }
332 333 334 335 336 337 338 339
  }

  .user-menu-more-indicator {
    position: absolute;
    right: 5px;
  }

  .user-menu-avatar {
340 341
    height: 25px;
    width: 25px;
342
    position: absolute;
343 344
    left: 8px;
    top: 8px;
345
    display: block;
346 347 348 349 350 351 352
  }

  .header-nav {
    font-weight: bold;
    float: left;
    height: 100%;
    margin-right: 5px;
353
    margin-top: 2px;
354 355 356 357 358 359 360 361 362 363 364

    a {
      padding: 0 10px;
      width: 100%;
      &:hover { text-decoration: none; }
    }

    > span {
      height: 100%;
      display: inline-block;
      margin-left: -4px;
Fla's avatar
Fla committed
365 366
      border-left: 1px solid #333;
      border-right: 1px solid #333;
367 368 369 370 371 372

      &:last-child {
        margin-left: -5px;
      }
    }
  }
373

374 375 376 377
  /* When the user is not connected */
  ul#landing_nav {
    position: absolute;
    top: 4px;
378
    right: 0;
379 380
    margin: 0;
    padding: 0;
381

382 383 384 385
    > li {
      text-shadow: 0 1px 0 #000;
      display: inline;
      margin-right: 0.5em;
386 387

      a {
388
        color: $blue;
389 390

        &.login {
391 392
          border-radius: 5px;
          box-shadow: 0 1px 1px #666;
393 394 395
          padding: 5px 8px;
          background-color: #000;
          border-top: 1px solid #000;
396

397 398 399
          &:hover { background-color: #222; }
        }
 	  }
400

401 402 403 404 405 406
      &:last-child { margin-right: 0; }
    }
  }
}


407
/*
408 409 410 411 412 413 414 415
 * Extract here from application.sass because
 * needed for the header in the bootstrap part
 */
ul.dropdown {
  padding: 0px;

  li {
    display: none;
416

417 418 419 420
    a { display: block; }

    &:first-child {
      display: block;
421

422 423 424 425 426 427 428 429 430 431 432 433
      a {
        height: auto;
        display: inline;
      }
    }
  }

  &.active {
    z-index: 30;
    li { display: block; }
  }
}