issuable.scss 12.7 KB
Newer Older
1 2 3 4 5 6 7 8
// Limit MR description for side-by-side diff view
.fixed-width-container {
  max-width: $limited-layout-width - ($gl-padding * 2);
  margin-left: auto;
  margin-right: auto;
}

.limit-container-width {
9 10 11 12 13
  .detail-page-header,
  .page-content-header,
  .commit-box,
  .info-well,
  .commit-ci-menu,
14 15 16
  .files-changed,
  .limited-header-width,
  .limited-width-notes {
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
    @extend .fixed-width-container;
  }

  .issuable-details {
    .detail-page-description,
    .mr-source-target,
    .mr-state-widget,
    .merge-manually {
      @extend .fixed-width-container;
    }
  }

  .merge-request-details {
    .emoji-list-container {
      @extend .fixed-width-container;
    }
  }

  .diffs {
36
    .mr-version-controls {
37 38 39 40 41
      @extend .fixed-width-container;
    }
  }
}

42
.issuable-details {
43
  section {
44
    .issuable-discussion {
45 46 47
      margin-right: 1px;
    }
  }
48

49 50
  .title {
    padding: 0;
51
    margin-bottom: 16px;
52 53 54
    border-bottom: none;
  }

55
  // Border around images in issue and MR descriptions.
56
  .description img:not(.emoji) {
57
    border: 1px solid $white-normal;
58
    padding: 5px;
59
    max-height: calc(100vh - 100px);
60
  }
61 62

  .emoji-block {
63
    padding: 10px 0;
64
  }
65
}
66 67 68 69 70 71 72 73

.issuable-filter-count {
  span {
    display: block;
    margin-bottom: -16px;
    padding: 13px 0;
  }
}
74

Douwe Maan's avatar
Douwe Maan committed
75 76 77 78 79
.issuable-show-labels {
  a {
    margin-right: 5px;
    margin-bottom: 5px;
    display: inline-block;
80

Douwe Maan's avatar
Douwe Maan committed
81 82
    .color-label {
      padding: 6px 10px;
83
      border-radius: $label-border-radius;
Douwe Maan's avatar
Douwe Maan committed
84 85
    }
  }
Phil Hughes's avatar
Phil Hughes committed
86 87 88 89

  &.has-labels {
    margin-bottom: -5px;
  }
Douwe Maan's avatar
Douwe Maan committed
90 91
}

Phil Hughes's avatar
Phil Hughes committed
92
.right-sidebar {
93 94
  a,
  .btn-link {
95 96 97
    color: inherit;
  }

98 99 100 101
  .btn-link {
    outline: none;
  }

102 103 104 105
  .issuable-header-text {
    margin-top: 7px;
  }

106 107
  .block {
    @include clearfix;
108
    padding: $gl-padding 0;
109
    border-bottom: 1px solid $border-gray-normal;
110
    // This prevents the mess when resizing the sidebar
111
    // of elements repositioning themselves..
Jacob Schatz's avatar
Jacob Schatz committed
112
    width: $gutter_inner_width;
113
    // --
114

Phil Hughes's avatar
Phil Hughes committed
115 116 117
    &.issuable-sidebar-header {
      padding-top: 0;
      padding-bottom: 10px;
118 119
    }

120 121 122
    &:last-child {
      border: none;
    }
123

Jacob Schatz's avatar
Jacob Schatz committed
124
    span {
125 126 127
      display: inline-block;
    }

Jacob Schatz's avatar
Jacob Schatz committed
128 129 130 131
    .select2-container span {
      margin-top: 0;
    }

132
    .gutter-toggle {
Jacob Schatz's avatar
Jacob Schatz committed
133
      margin-left: 20px;
134
      padding-left: 10px;
135 136 137 138

      &:hover {
        color: $gray-darkest;
      }
139
    }
140
  }
141

Phil Hughes's avatar
Phil Hughes committed
142 143 144 145
  .block-first {
    padding-top: 0;
  }

146 147
  .title {
    color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
148 149
    margin-bottom: 10px;
    line-height: 1;
Valery Sizov's avatar
Valery Sizov committed
150

151 152
    .avatar {
      margin-left: 0;
Valery Sizov's avatar
Valery Sizov committed
153 154
    }

155
    .edit-link {
156
      color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
157

158 159
      &:not([href]):hover {
        color: rgba($avatar-border, .2);
Phil Hughes's avatar
Phil Hughes committed
160
      }
161
    }
Valery Sizov's avatar
Valery Sizov committed
162 163
  }

164
  .cross-project-reference {
165
    color: inherit;
166

167 168
    span {
      white-space: nowrap;
Jacob Schatz's avatar
Jacob Schatz committed
169
      width: 85%;
170 171 172 173 174
      overflow: hidden;
      position: relative;
      display: inline-block;
      text-overflow: ellipsis;
    }
Valery Sizov's avatar
Valery Sizov committed
175

176 177 178 179
    cite {
      font-style: normal;
    }

180 181
    button {
      float: right;
182 183
      padding: 1px 5px;
      background-color: $gray-light;
Valery Sizov's avatar
Valery Sizov committed
184
    }
185
  }
186

187
  .selectbox {
188
    display: none;
189
  }
190

191
  .btn-clipboard:hover {
192
    color: $gl-text-color;
Valery Sizov's avatar
Valery Sizov committed
193
  }
194
}
195 196

.right-sidebar {
197
  position: absolute;
198
  top: $header-height;
199
  bottom: 0;
200
  right: 0;
201
  transition: width .3s;
202
  background: $gray-light;
203
  z-index: 200;
204 205 206 207
  overflow: hidden;

  .issuable-sidebar {
    width: calc(100% + 100px);
208
    height: calc(100% - #{$header-height});
209 210 211 212
    overflow-y: scroll;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
  }
213

214 215
  &.right-sidebar-expanded {
    width: $gutter_width;
216

Phil Hughes's avatar
Phil Hughes committed
217 218
    .value {
      line-height: 1;
219 220 221 222 223

      .assign-yourself {
        margin-top: 10px;
        display: block;
      }
Phil Hughes's avatar
Phil Hughes committed
224 225
    }

226 227 228 229
    .issuable-sidebar {
      padding: 0 20px;
    }

230 231 232 233
    .issuable-sidebar-header {
      padding-top: 10px;
    }

Clement Ho's avatar
Clement Ho committed
234 235 236 237 238 239
    &:not(.issue-boards-sidebar):not([data-signed-in]) {
      .issuable-sidebar-header {
        display: none;
      }
    }

240 241 242 243
    .assign-yourself .btn-link {
      padding-left: 0;
    }

Phil Hughes's avatar
Phil Hughes committed
244 245 246 247
    .light {
      font-weight: normal;
    }

248
    .no-value {
249
      color: $gl-text-color-secondary;
250 251
    }

252 253 254 255 256
    .sidebar-collapsed-icon {
      display: none;
    }

    .gutter-toggle {
Phil Hughes's avatar
Phil Hughes committed
257
      margin-top: 7px;
258
      border-left: 1px solid $border-gray-normal;
259
    }
Phil Hughes's avatar
Phil Hughes committed
260

Clement Ho's avatar
Clement Ho committed
261 262 263 264
    .title .gutter-toggle {
      margin-top: 0;
    }

265
    .assignee .avatar {
Phil Hughes's avatar
Phil Hughes committed
266 267 268 269 270 271
      float: left;
      margin-right: 10px;
      margin-bottom: 0;
      margin-left: 0;
    }

272 273 274 275
    .assignee .user-list .avatar {
      margin: 0;
    }

Phil Hughes's avatar
Phil Hughes committed
276 277 278 279 280 281
    .username {
      display: block;
      margin-top: 4px;
      font-size: 13px;
      font-weight: normal;
    }
Phil Hughes's avatar
Phil Hughes committed
282 283 284 285

    .hide-expanded {
      display: none;
    }
286 287 288
  }

  &.right-sidebar-collapsed {
289 290 291
    /* Extra small devices (phones, less than 768px) */
    display: none;
    /* Small devices (tablets, 768px and up) */
292
    @media (min-width: $screen-sm-min) {
293
      display: block;
294 295
    }

296
    width: $gutter_collapsed_width;
297
    padding: 0;
298 299

    .block {
300
      width: $gutter_collapsed_width - 2px;
301
      padding: 15px 0 0;
302 303
      border-bottom: none;
      overflow: hidden;
304
    }
305

Phil Hughes's avatar
Phil Hughes committed
306
    .participants {
307
      border-bottom: 1px solid $border-gray-normal;
Phil Hughes's avatar
Phil Hughes committed
308 309
    }

310
    .hide-collapsed {
Jacob Schatz's avatar
Jacob Schatz committed
311 312 313
      display: none;
    }

314
    .gutter-toggle {
Phil Hughes's avatar
Phil Hughes committed
315 316 317
      width: 100%;
      margin-left: 0;
      padding-left: 25px;
318 319 320 321
    }

    .sidebar-collapsed-icon {
      display: block;
322
      width: 100%;
323
      text-align: center;
Phil Hughes's avatar
Phil Hughes committed
324
      margin-bottom: 10px;
325
      color: $issuable-sidebar-color;
326

dimitrieh's avatar
dimitrieh committed
327 328
      &:hover,
      &:hover .todo-undone {
329
        color: $gl-text-color;
330 331
      }

332 333 334 335
      span {
        display: block;
        margin-top: 0;
      }
336

337 338 339 340
      .sidebar-avatar-counter {
        padding-top: 2px;
      }

341 342 343 344
      .todo-undone {
        color: $gl-link-color;
      }

345 346 347 348
      .author {
        display: none;
      }

349 350
      .avatar-counter:hover {
        color: $issuable-sidebar-color;
351
        border-color: $issuable-sidebar-color;
352 353
      }

354 355
      .btn-clipboard {
        border: none;
356
        color: $issuable-sidebar-color;
357 358 359

        &:hover {
          background: transparent;
360
          color: $gl-text-color;
361 362
        }
      }
363 364 365 366 367 368 369 370 371 372 373

      &.multiple-users {
        display: flex;
        justify-content: center;
      }
    }

    .sidebar-avatar-counter {
      width: 24px;
      height: 24px;
      border-radius: 12px;
374
    }
Phil Hughes's avatar
Phil Hughes committed
375 376 377 378 379

    .sidebar-collapsed-user {
      padding-bottom: 0;
      margin-bottom: 10px;
    }
380 381 382 383

    .issuable-header-btn {
      display: none;
    }
384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414

    .multiple-users {
      height: 24px;
      margin-bottom: 17px;
      margin-top: 4px;
      padding-bottom: 4px;

      .btn-link {
        padding: 0;
        border: 0;

        .avatar {
          margin: 0;
        }
      }

      .btn-link:first-child {
        position: absolute;
        left: 10px;
        z-index: 1;
      }

      .btn-link:last-child {
        position: absolute;
        right: 10px;

        &:hover {
          text-decoration: none;
        }
      }
    }
Jacob Schatz's avatar
Jacob Schatz committed
415 416
  }

417
  a {
Phil Hughes's avatar
Phil Hughes committed
418 419 420
    &:hover {
      color: $md-link-color;
      text-decoration: none;
421 422

      .avatar {
423
        border-color: rgba($avatar-border, .2);
424
      }
Phil Hughes's avatar
Phil Hughes committed
425 426
    }
  }
427

428 429 430 431 432 433
  .dropdown-content {
    a:hover {
      color: inherit;
    }
  }

434 435
  .dropdown-menu-toggle {
    width: 100%;
436
    padding-top: 6px;
437 438 439 440 441
  }

  .open .dropdown-menu {
    width: 100%;
  }
442
}
443 444

.detail-page-description {
445
  padding: 16px 0;
446

447 448 449
  small {
    color: $gray-darkest;
  }
450
}
451 452 453

.edited-text {
  color: $gray-darkest;
454
  display: block;
455
  margin: 16px 0 0;
456 457 458 459 460

  .author_link {
    color: $gray-darkest;
  }
}
Phil Hughes's avatar
Phil Hughes committed
461 462

.participants-list {
463
  margin: -5px;
Phil Hughes's avatar
Phil Hughes committed
464 465
}

466

467 468 469 470 471
.user-list {
  display: flex;
  flex-wrap: wrap;
}

Phil Hughes's avatar
Phil Hughes committed
472
.participants-author {
473
  display: inline-block;
474
  padding: 5px;
Phil Hughes's avatar
Phil Hughes committed
475

476 477 478 479
  &:nth-of-type(7n) {
    padding-right: 0;
  }

Phil Hughes's avatar
Phil Hughes committed
480 481 482 483 484 485 486 487 488
  .author_link {
    display: block;
  }

  .avatar.avatar-inline {
    margin: 0;
  }
}

489 490 491 492 493 494 495 496 497 498 499 500
.user-item {
  display: inline-block;
  padding: 5px;
  flex-basis: 20%;

  .user-link {
    display: inline-block;
  }
}

.participants-more,
.user-list-more {
Phil Hughes's avatar
Phil Hughes committed
501 502 503
  margin-top: 5px;
  margin-left: 5px;

504 505
  a,
  .btn-link {
506
    color: $gl-text-color-secondary;
Phil Hughes's avatar
Phil Hughes committed
507
  }
508 509 510 511 512 513 514 515 516 517 518 519 520 521

  .btn-link {
    outline: none;
    padding: 0;
  }

  .btn-link:hover {
    @extend a:hover;
    text-decoration: none;
  }

  .btn-link:focus {
    text-decoration: none;
  }
Phil Hughes's avatar
Phil Hughes committed
522
}
523 524 525 526 527 528

.issuable-form-padding-top {
  @media (min-width: $screen-sm-min) {
    padding-top: 7px;
  }
}
529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574

.issuable-status-box {
  float: none;
  display: inline-block;
  margin-top: 0;

  @media (max-width: $screen-xs-max) {
    position: absolute;
    top: 0;
    left: 0;
  }
}

.issuable-header {
  position: relative;
  padding-left: 45px;
  padding-right: 45px;
  line-height: 35px;

  @media (min-width: $screen-sm-min) {
    float: left;
    padding-left: 0;
    padding-right: 0;
  }
}

.issuable-actions {
  padding-top: 10px;

  @media (min-width: $screen-sm-min) {
    float: right;
    padding-top: 0;
  }
}

.issuable-gutter-toggle {
  @media (max-width: $screen-sm-max) {
    position: absolute;
    top: 0;
    right: 0;
  }
}

.issuable-meta {
  display: inline-block;
  line-height: 18px;
575
  font-size: 14px;
576
}
577 578 579 580 581

.js-issuable-selector-wrap {
  .js-issuable-selector {
    width: 100%;
  }
582

583 584 585 586
  @media (max-width: $screen-sm-max) {
    margin-bottom: $gl-padding;
  }
}
587 588 589

.issuable-list {
  li {
Nur Rony's avatar
Nur Rony committed
590

591 592 593 594 595 596 597 598
    .issue-box {
      display: -webkit-flex;
      display: flex;
    }

    .issue-info-container {
      -webkit-flex: 1;
      flex: 1;
Taurie Davis's avatar
Taurie Davis committed
599
      display: flex;
600
      padding-right: $gl-padding;
Taurie Davis's avatar
Taurie Davis committed
601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630

      .issue-main-info {
        flex: 1 auto;
        margin-right: 10px;
      }

      .issuable-meta {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        flex: 1 0 auto;

        .controls {
          margin-bottom: 2px;
          line-height: 20px;
          padding: 0;
        }

        .issue-updated-at {
          line-height: 20px;
        }
      }

      @media(max-width: $screen-xs-max) {
        .issuable-meta {
          .controls li {
            margin-right: 0;
          }
        }
      }
Nur Rony's avatar
Nur Rony committed
631 632
    }

633
    .issue-check {
634
      padding-right: $gl-padding;
635 636 637 638 639 640 641
      margin-bottom: 10px;
      min-width: 15px;

      .selected_issue {
        vertical-align: text-top;
      }
    }
Taurie Davis's avatar
Taurie Davis committed
642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665

    .issuable-milestone,
    .issuable-info,
    .task-status,
    .issuable-updated-at {
      font-weight: normal;
      color: $gl-text-color-secondary;

      a {
        color: $gl-text-color;

        .fa {
          color: $gl-text-color-secondary;
        }
      }
    }

    @media(max-width: $screen-md-max) {
      .task-status,
      .issuable-due-date,
      .project-ref-path {
        display: none;
      }
    }
666 667
  }
}
668

669 670 671 672 673 674 675 676 677 678 679 680 681
.issuable-list li,
.issue-info-container .controls {
  .avatar-counter {
    display: inline-block;
    vertical-align: middle;
    min-width: 16px;
    line-height: 14px;
    height: 16px;
    padding-left: 2px;
    padding-right: 2px;
  }
}

682 683 684 685 686 687 688 689 690 691 692 693 694 695
.time_tracker {
  padding-bottom: 0;
  border-bottom: 0;


  .sidebar-collapsed-icon {

    > .stopwatch-svg {
      display: inline-block;
    }

    svg {
      width: 16px;
      height: 16px;
696
      fill: $issuable-sidebar-color;
697 698 699
    }

    &:hover svg {
Bryce Johnson's avatar
Bryce Johnson committed
700
      fill: $gl-text-color;
701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717
    }
  }

  .help-button,
  .close-help-button {
    cursor: pointer;
  }

  .compare-meter {
    &.within_estimate {
      .meter-fill {
        background: $gl-primary;
      }
    }

    &.over_estimate {
      .meter-fill {
718
        background: $red-500;
719 720 721 722
      }

      .time-remaining,
      .compare-value.spent {
723
        color: $red-500;
724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746
      }
    }
  }

  .meter-container {
    background: $border-gray-light;
    border-radius: 3px;

    .meter-fill {
      max-width: 100%;
      height: 5px;
      border-radius: 3px;
      background: $gl-primary;
    }
  }

  .compare-display-container {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;

    .compare-display {
      font-size: 13px;
Bryce Johnson's avatar
Bryce Johnson committed
747
      color: $compare-display-color;
748 749

      .compare-value {
Bryce Johnson's avatar
Bryce Johnson committed
750
        color: $gl-text-color;
751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779
      }
    }
  }

  .time-tracking-help-state {
    background: $white-light;
    margin: 16px -20px 0;
    padding: 16px 20px;
    border-top: 1px solid $border-gray-light;
    border-bottom: 1px solid $border-gray-light;

    a:hover {
      color: $btn-white-active;
    }
  }

  .help-state-toggle-enter-active {
    transition: all .8s ease;
  }

  .help-state-toggle-leave-active {
    transition: all .5s ease;
  }

  .help-state-toggle-enter,
  .help-state-toggle-leave-active {
    opacity: 0;
  }
}
Phil Hughes's avatar
Phil Hughes committed
780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797

.issuable-todo-btn {
  .fa-spinner {
    display: none;
  }

  &.is-loading {
    .fa-spinner {
      display: inline-block;
    }

    &.sidebar-collapsed-icon {
      .issuable-todo-inner {
        display: none;
      }
    }
  }
}
798 799 800 801 802 803

.issuable-close-button,
.issuable-close-toggle {
  @include transition(border-color, color);
}

804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819
.issuable-close-dropdown {
  .dropdown-menu {
    min-width: 270px;
    left: auto;
    right: 0;
  }

  .description {
    .text {
      margin: 0;
    }
  }

  .dropdown-toggle > .icon {
    margin: 0 3px;
  }
820
}