issuable.scss 14.2 KB
Newer Older
1 2 3 4 5 6 7
// 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;
}

Luke "Jared" Bennett's avatar
Luke "Jared" Bennett committed
8
.issuable-warning-icon {
9
  color: $orange-600;
10
  background-color: $orange-100;
Regis's avatar
Regis committed
11
  border-radius: $border-radius-default;
12
  padding: 5px;
Luke "Jared" Bennett's avatar
Luke "Jared" Bennett committed
13 14 15 16
  margin: 0 $btn-side-margin 0 0;
  width: $issuable-warning-size;
  height: $issuable-warning-size;
  text-align: center;
Luke "Jared" Bennett's avatar
Luke "Jared" Bennett committed
17 18 19 20

  &:first-of-type {
    margin-right: $issuable-warning-icon-margin;
  }
21 22
}

23 24 25 26
.sidebar-item-icon {
  border-radius: $border-radius-default;
  padding: 5px;
  margin: 0 3px 0 -4px;
27

28
  &.is-active {
Luke "Jared" Bennett's avatar
Luke "Jared" Bennett committed
29 30
    color: $orange-600;
    background-color: $orange-50;
31 32 33
  }
}

34
.limit-container-width {
35 36 37 38 39
  .detail-page-header,
  .page-content-header,
  .commit-box,
  .info-well,
  .commit-ci-menu,
40
  .files-changed-inner,
41 42
  .limited-header-width,
  .limited-width-notes {
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
    @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 {
62
    .mr-version-controls {
63 64 65 66 67
      @extend .fixed-width-container;
    }
  }
}

68
.issuable-details {
69
  section {
70
    .issuable-discussion {
71 72 73
      margin-right: 1px;
    }
  }
74

75 76
  .title {
    padding: 0;
77
    margin-bottom: 16px;
78 79 80
    border-bottom: none;
  }

81
  // Border around images in issue and MR descriptions.
82
  .description img:not(.emoji) {
83
    border: 1px solid $white-normal;
84
    padding: 5px;
85
    max-height: calc(100vh - 100px);
86
    max-width: 100%;
87
  }
88 89

  .emoji-block {
90
    padding: 10px 0;
91
  }
92
}
93 94 95 96 97 98 99 100

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

Douwe Maan's avatar
Douwe Maan committed
102 103 104 105 106
.issuable-show-labels {
  a {
    margin-right: 5px;
    margin-bottom: 5px;
    display: inline-block;
107

Douwe Maan's avatar
Douwe Maan committed
108 109
    .color-label {
      padding: 6px 10px;
110
      border-radius: $label-border-radius;
Douwe Maan's avatar
Douwe Maan committed
111 112
    }
  }
Phil Hughes's avatar
Phil Hughes committed
113 114 115 116

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

Phil Hughes's avatar
Phil Hughes committed
119
.right-sidebar {
120
  a:not(.btn-retry),
121
  .btn-link {
122 123 124
    color: inherit;
  }

125 126 127 128
  .btn-link {
    outline: none;
  }

129 130 131 132
  .issuable-header-text {
    margin-top: 7px;
  }

133 134
  .block {
    @include clearfix;
135
    padding: $gl-padding 0;
136
    border-bottom: 1px solid $border-gray-normal;
137
    // This prevents the mess when resizing the sidebar
138
    // of elements repositioning themselves..
Jacob Schatz's avatar
Jacob Schatz committed
139
    width: $gutter_inner_width;
140
    // --
141

Phil Hughes's avatar
Phil Hughes committed
142 143 144
    &.issuable-sidebar-header {
      padding-top: 0;
      padding-bottom: 10px;
145 146
    }

147 148 149
    &:last-child {
      border: none;
    }
150

Jacob Schatz's avatar
Jacob Schatz committed
151
    span {
152 153 154
      display: inline-block;
    }

Jacob Schatz's avatar
Jacob Schatz committed
155 156 157 158
    .select2-container span {
      margin-top: 0;
    }

159
    .gutter-toggle {
Jacob Schatz's avatar
Jacob Schatz committed
160
      margin-left: 20px;
161
      padding-left: 10px;
162 163 164 165

      &:hover {
        color: $gray-darkest;
      }
166
    }
167
  }
168

Phil Hughes's avatar
Phil Hughes committed
169 170 171 172
  .block-first {
    padding-top: 0;
  }

173 174
  .title {
    color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
175 176
    margin-bottom: 10px;
    line-height: 1;
Valery Sizov's avatar
Valery Sizov committed
177

178 179
    .avatar {
      margin-left: 0;
Valery Sizov's avatar
Valery Sizov committed
180 181
    }

182
    .edit-link {
183
      color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
184

185 186
      &:not([href]):hover {
        color: rgba($avatar-border, .2);
Phil Hughes's avatar
Phil Hughes committed
187
      }
188
    }
Valery Sizov's avatar
Valery Sizov committed
189 190
  }

191
  .cross-project-reference {
192
    color: inherit;
193

194 195
    span {
      white-space: nowrap;
Jacob Schatz's avatar
Jacob Schatz committed
196
      width: 85%;
197 198 199 200 201
      overflow: hidden;
      position: relative;
      display: inline-block;
      text-overflow: ellipsis;
    }
Valery Sizov's avatar
Valery Sizov committed
202

203 204 205 206
    cite {
      font-style: normal;
    }

207 208
    button {
      float: right;
209 210
      padding: 1px 5px;
      background-color: $gray-light;
Valery Sizov's avatar
Valery Sizov committed
211
    }
212
  }
213

214
  .selectbox {
215
    display: none;
216
  }
217

218
  .btn-clipboard:hover {
219
    color: $gl-text-color;
Valery Sizov's avatar
Valery Sizov committed
220
  }
221
}
222 223

.right-sidebar {
224
  position: absolute;
225
  top: $header-height;
226
  bottom: 0;
227
  right: 0;
228
  transition: width $right-sidebar-transition-duration;
229
  background: $gray-light;
230
  z-index: 200;
231 232 233 234
  overflow: hidden;

  .issuable-sidebar {
    width: calc(100% + 100px);
235
    height: 100%;
236 237 238 239
    overflow-y: scroll;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
  }
240

winh's avatar
winh committed
241 242 243 244
  &.affix-top .issuable-sidebar {
    height: 100%;
  }

245 246
  &.right-sidebar-expanded {
    width: $gutter_width;
247

Phil Hughes's avatar
Phil Hughes committed
248 249
    .value {
      line-height: 1;
250 251 252 253 254

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

257 258 259 260
    .issuable-sidebar {
      padding: 0 20px;
    }

261 262 263 264
    .issuable-sidebar-header {
      padding-top: 10px;
    }

265
    &:not(.issue-boards-sidebar):not([data-signed-in]):not([data-always-show-toggle]) {
Clement Ho's avatar
Clement Ho committed
266 267 268 269 270
      .issuable-sidebar-header {
        display: none;
      }
    }

271 272 273 274
    .assign-yourself .btn-link {
      padding-left: 0;
    }

Phil Hughes's avatar
Phil Hughes committed
275
    .light {
276
      font-weight: $gl-font-weight-normal;
Phil Hughes's avatar
Phil Hughes committed
277 278
    }

279
    .no-value {
280
      color: $gl-text-color-secondary;
281 282
    }

283 284 285 286 287
    .sidebar-collapsed-icon {
      display: none;
    }

    .gutter-toggle {
Phil Hughes's avatar
Phil Hughes committed
288
      margin-top: 7px;
289
      border-left: 1px solid $border-gray-normal;
290
    }
Phil Hughes's avatar
Phil Hughes committed
291

Clement Ho's avatar
Clement Ho committed
292 293 294 295
    .title .gutter-toggle {
      margin-top: 0;
    }

296
    .assignee .avatar {
Phil Hughes's avatar
Phil Hughes committed
297 298 299 300 301 302
      float: left;
      margin-right: 10px;
      margin-bottom: 0;
      margin-left: 0;
    }

303 304 305 306
    .assignee .user-list .avatar {
      margin: 0;
    }

Phil Hughes's avatar
Phil Hughes committed
307 308 309 310
    .username {
      display: block;
      margin-top: 4px;
      font-size: 13px;
311
      font-weight: $gl-font-weight-normal;
Phil Hughes's avatar
Phil Hughes committed
312
    }
Phil Hughes's avatar
Phil Hughes committed
313 314 315 316

    .hide-expanded {
      display: none;
    }
317 318 319
  }

  &.right-sidebar-collapsed {
320 321 322
    /* Extra small devices (phones, less than 768px) */
    display: none;
    /* Small devices (tablets, 768px and up) */
323
    @media (min-width: $screen-sm-min) {
324
      display: block;
325 326
    }

327
    width: $gutter_collapsed_width;
328
    padding: 0;
329 330

    .block {
331
      width: $gutter_collapsed_width - 2px;
332
      padding: 15px 0 0;
333 334
      border-bottom: none;
      overflow: hidden;
335
    }
336

Phil Hughes's avatar
Phil Hughes committed
337
    .participants {
338
      border-bottom: 1px solid $border-gray-normal;
Phil Hughes's avatar
Phil Hughes committed
339 340
    }

341
    .hide-collapsed {
Jacob Schatz's avatar
Jacob Schatz committed
342 343 344
      display: none;
    }

345
    .gutter-toggle {
Phil Hughes's avatar
Phil Hughes committed
346 347 348
      width: 100%;
      margin-left: 0;
      padding-left: 25px;
349 350 351 352
    }

    .sidebar-collapsed-icon {
      display: block;
353
      width: 100%;
354
      text-align: center;
Phil Hughes's avatar
Phil Hughes committed
355
      margin-bottom: 10px;
356
      color: $issuable-sidebar-color;
357

358 359 360 361
      svg {
        fill: $issuable-sidebar-color;
      }

dimitrieh's avatar
dimitrieh committed
362 363
      &:hover,
      &:hover .todo-undone {
364
        color: $gl-text-color;
365 366 367 368

        svg {
          fill: $gl-text-color;
        }
369 370
      }

371 372 373 374
      span {
        display: block;
        margin-top: 0;
      }
375

376 377 378 379
      .sidebar-avatar-counter {
        padding-top: 2px;
      }

380 381 382 383
      .todo-undone {
        color: $gl-link-color;
      }

384 385 386 387
      .author {
        display: none;
      }

388 389
      .avatar-counter:hover {
        color: $issuable-sidebar-color;
390
        border-color: $issuable-sidebar-color;
391 392
      }

393 394
      .btn-clipboard {
        border: none;
395
        color: $issuable-sidebar-color;
396 397 398

        &:hover {
          background: transparent;
399
          color: $gl-text-color;
400 401
        }
      }
402 403 404 405 406 407 408 409 410 411 412

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

    .sidebar-avatar-counter {
      width: 24px;
      height: 24px;
      border-radius: 12px;
413
    }
Phil Hughes's avatar
Phil Hughes committed
414 415 416 417 418

    .sidebar-collapsed-user {
      padding-bottom: 0;
      margin-bottom: 10px;
    }
419 420 421 422

    .issuable-header-btn {
      display: none;
    }
423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453

    .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;
        }
      }
    }
454 455 456 457 458 459

    .milestone-title span {
      @include str-truncated(100%);
      display: block;
      margin: 0 4px;
    }
Jacob Schatz's avatar
Jacob Schatz committed
460 461
  }

462
  a:not(.btn-retry) {
Phil Hughes's avatar
Phil Hughes committed
463 464 465
    &:hover {
      color: $md-link-color;
      text-decoration: none;
466 467

      .avatar {
468
        border-color: rgba($avatar-border, .2);
469
      }
Phil Hughes's avatar
Phil Hughes committed
470 471
    }
  }
472

473 474 475 476 477 478
  .dropdown-content {
    a:hover {
      color: inherit;
    }
  }

479 480
  .dropdown-menu-toggle {
    width: 100%;
481
    padding-top: 6px;
482 483
  }

484
  .dropdown-menu {
485 486
    width: 100%;
  }
487
}
488

489
.with-performance-bar .right-sidebar {
490
  top: $header-height + $performance-bar-height;
491 492

  .issuable-sidebar {
493
    height: calc(100% - #{$header-height} - #{$performance-bar-height});
494 495 496
  }
}

497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514
.sidebar-move-issue-dropdown {
  @include new-style-dropdown;
}

.sidebar-move-issue-confirmation-button {
  width: 100%;

  &.is-loading {
    .sidebar-move-issue-confirmation-loading-icon {
      display: inline-block;
    }
  }
}

.sidebar-move-issue-confirmation-loading-icon {
  display: none;
}

515
.detail-page-description {
516
  padding: 16px 0;
517

518 519 520
  small {
    color: $gray-darkest;
  }
521
}
522 523 524

.edited-text {
  color: $gray-darkest;
525
  display: block;
526
  margin: 16px 0 0;
527
  font-size: 85%;
528 529 530 531 532

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

.participants-list {
535
  margin: -5px;
Phil Hughes's avatar
Phil Hughes committed
536 537
}

538

539 540 541 542 543
.user-list {
  display: flex;
  flex-wrap: wrap;
}

Phil Hughes's avatar
Phil Hughes committed
544
.participants-author {
545
  display: inline-block;
546
  padding: 5px;
Phil Hughes's avatar
Phil Hughes committed
547

548 549 550 551
  &:nth-of-type(7n) {
    padding-right: 0;
  }

Phil Hughes's avatar
Phil Hughes committed
552 553 554 555 556 557 558 559 560
  .author_link {
    display: block;
  }

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

561 562 563 564 565 566 567 568 569 570 571 572
.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
573 574 575
  margin-top: 5px;
  margin-left: 5px;

576 577
  a,
  .btn-link {
578
    color: $gl-text-color-secondary;
Phil Hughes's avatar
Phil Hughes committed
579
  }
580 581 582 583 584 585 586 587 588 589 590 591 592 593

  .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
594
}
595 596 597 598 599 600

.issuable-form-padding-top {
  @media (min-width: $screen-sm-min) {
    padding-top: 7px;
  }
}
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

.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 {
628 629
  @include new-style-dropdown;

630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648
  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;
649
  font-size: 14px;
650
}
651 652 653 654 655

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

657 658 659 660
  @media (max-width: $screen-sm-max) {
    margin-bottom: $gl-padding;
  }
}
661 662 663

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

665 666 667 668 669 670 671 672
    .issue-box {
      display: -webkit-flex;
      display: flex;
    }

    .issue-info-container {
      -webkit-flex: 1;
      flex: 1;
Taurie Davis's avatar
Taurie Davis committed
673
      display: flex;
674
      padding-right: $gl-padding;
Taurie Davis's avatar
Taurie Davis committed
675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704

      .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
705 706
    }

707
    .issue-check {
708
      padding-right: $gl-padding;
709 710 711 712 713 714 715
      margin-bottom: 10px;
      min-width: 15px;

      .selected_issue {
        vertical-align: text-top;
      }
    }
Taurie Davis's avatar
Taurie Davis committed
716 717 718 719 720

    .issuable-milestone,
    .issuable-info,
    .task-status,
    .issuable-updated-at {
721
      font-weight: $gl-font-weight-normal;
Taurie Davis's avatar
Taurie Davis committed
722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739
      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;
      }
    }
740 741
  }
}
742

743 744 745 746 747 748 749 750 751 752 753 754 755
.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;
  }
}

756 757 758 759 760 761 762 763 764 765 766 767 768 769
.time_tracker {
  padding-bottom: 0;
  border-bottom: 0;


  .sidebar-collapsed-icon {

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

    svg {
      width: 16px;
      height: 16px;
770
      fill: $issuable-sidebar-color;
771 772 773
    }

    &:hover svg {
Bryce Johnson's avatar
Bryce Johnson committed
774
      fill: $gl-text-color;
775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791
    }
  }

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

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

    &.over_estimate {
      .meter-fill {
792
        background: $red-500;
793 794 795 796
      }

      .time-remaining,
      .compare-value.spent {
797
        color: $red-500;
798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820
      }
    }
  }

  .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
821
      color: $compare-display-color;
822 823

      .compare-value {
Bryce Johnson's avatar
Bryce Johnson committed
824
        color: $gl-text-color;
825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853
      }
    }
  }

  .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
854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871

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

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

    &.sidebar-collapsed-icon {
      .issuable-todo-inner {
        display: none;
      }
    }
  }
}
872 873 874 875 876 877

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

878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893
.issuable-close-dropdown {
  .dropdown-menu {
    min-width: 270px;
    left: auto;
    right: 0;
  }

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

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