issuable.scss 14.1 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;
}

L
Luke "Jared" Bennett 已提交
8
.issuable-warning-icon {
9 10
  color: $orange-600;
  background-color: $orange-50;
R
Regis 已提交
11
  border-radius: $border-radius-default;
12
  padding: 5px;
L
Luke "Jared" Bennett 已提交
13 14 15 16
  margin: 0 $btn-side-margin 0 0;
  width: $issuable-warning-size;
  height: $issuable-warning-size;
  text-align: center;
17 18
}

L
Luke "Jared" Bennett 已提交
19 20 21 22
.sidebar-item-icon {
  border-radius: $border-radius-default;
  padding: 5px;
  margin: 0 3px 0 -4px;
23

L
Luke "Jared" Bennett 已提交
24
  &.is-active {
L
Luke "Jared" Bennett 已提交
25 26
    color: $orange-600;
    background-color: $orange-50;
27 28 29
  }
}

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

64
.issuable-details {
65
  section {
66
    .issuable-discussion {
67 68 69
      margin-right: 1px;
    }
  }
70

71 72
  .title {
    padding: 0;
73
    margin-bottom: 16px;
74 75 76
    border-bottom: none;
  }

77
  // Border around images in issue and MR descriptions.
78
  .description img:not(.emoji) {
A
Annabel Dunstone Gray 已提交
79
    border: 1px solid $white-normal;
80
    padding: 5px;
81
    max-height: calc(100vh - 100px);
82
    max-width: 100%;
83
  }
84 85

  .emoji-block {
86
    padding: 10px 0;
87
  }
88
}
89 90 91 92 93 94 95 96

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

D
Douwe Maan 已提交
98 99 100 101 102
.issuable-show-labels {
  a {
    margin-right: 5px;
    margin-bottom: 5px;
    display: inline-block;
103

D
Douwe Maan 已提交
104 105
    .color-label {
      padding: 6px 10px;
106
      border-radius: $label-border-radius;
D
Douwe Maan 已提交
107 108
    }
  }
P
Phil Hughes 已提交
109 110 111 112

  &.has-labels {
    margin-bottom: -5px;
  }
D
Douwe Maan 已提交
113 114
}

P
Phil Hughes 已提交
115
.right-sidebar {
116 117
  a,
  .btn-link {
P
Phil Hughes 已提交
118 119 120
    color: inherit;
  }

121 122 123 124
  .btn-link {
    outline: none;
  }

P
Phil Hughes 已提交
125 126 127 128
  .issuable-header-text {
    margin-top: 7px;
  }

129 130
  .block {
    @include clearfix;
131
    padding: $gl-padding 0;
A
Annabel Dunstone Gray 已提交
132
    border-bottom: 1px solid $border-gray-normal;
133
    // This prevents the mess when resizing the sidebar
134
    // of elements repositioning themselves..
J
Jacob Schatz 已提交
135
    width: $gutter_inner_width;
136
    // --
137

P
Phil Hughes 已提交
138 139 140
    &.issuable-sidebar-header {
      padding-top: 0;
      padding-bottom: 10px;
141 142
    }

143 144 145
    &:last-child {
      border: none;
    }
146

J
Jacob Schatz 已提交
147
    span {
148 149 150
      display: inline-block;
    }

J
Jacob Schatz 已提交
151 152 153 154
    .select2-container span {
      margin-top: 0;
    }

155
    .gutter-toggle {
J
Jacob Schatz 已提交
156
      margin-left: 20px;
157
      padding-left: 10px;
158 159 160 161

      &:hover {
        color: $gray-darkest;
      }
162
    }
163
  }
D
Dmitriy Zaporozhets 已提交
164

P
Phil Hughes 已提交
165 166 167 168
  .block-first {
    padding-top: 0;
  }

169 170
  .title {
    color: $gl-text-color;
P
Phil Hughes 已提交
171 172
    margin-bottom: 10px;
    line-height: 1;
V
Valery Sizov 已提交
173

174 175
    .avatar {
      margin-left: 0;
V
Valery Sizov 已提交
176 177
    }

178
    .edit-link {
T
tauriedavis 已提交
179
      color: $gl-text-color;
P
Phil Hughes 已提交
180

181 182
      &:not([href]):hover {
        color: rgba($avatar-border, .2);
P
Phil Hughes 已提交
183
      }
D
Dmitriy Zaporozhets 已提交
184
    }
V
Valery Sizov 已提交
185 186
  }

187
  .cross-project-reference {
P
Phil Hughes 已提交
188
    color: inherit;
189

190 191
    span {
      white-space: nowrap;
J
Jacob Schatz 已提交
192
      width: 85%;
193 194 195 196 197
      overflow: hidden;
      position: relative;
      display: inline-block;
      text-overflow: ellipsis;
    }
V
Valery Sizov 已提交
198

199 200 201 202
    cite {
      font-style: normal;
    }

203 204
    button {
      float: right;
205 206
      padding: 1px 5px;
      background-color: $gray-light;
V
Valery Sizov 已提交
207
    }
208
  }
D
Dmitriy Zaporozhets 已提交
209

210
  .selectbox {
211
    display: none;
212
  }
D
Dmitriy Zaporozhets 已提交
213

214
  .btn-clipboard:hover {
T
tauriedavis 已提交
215
    color: $gl-text-color;
V
Valery Sizov 已提交
216
  }
217
}
J
Jacob Schatz 已提交
218 219

.right-sidebar {
220
  position: absolute;
A
Annabel Dunstone Gray 已提交
221
  top: $new-navbar-height;
222
  bottom: 0;
J
Jacob Schatz 已提交
223
  right: 0;
224
  transition: width .3s;
J
Jacob Schatz 已提交
225
  background: $gray-light;
L
Luke "Jared" Bennett 已提交
226
  z-index: 200;
227 228 229 230
  overflow: hidden;

  .issuable-sidebar {
    width: calc(100% + 100px);
A
Annabel Dunstone Gray 已提交
231
    height: calc(100% - #{$new-navbar-height});
232 233 234 235
    overflow-y: scroll;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
  }
236

W
winh 已提交
237 238 239 240
  &.affix-top .issuable-sidebar {
    height: 100%;
  }

241 242
  &.right-sidebar-expanded {
    width: $gutter_width;
J
Jacob Schatz 已提交
243

P
Phil Hughes 已提交
244 245
    .value {
      line-height: 1;
246 247 248 249 250

      .assign-yourself {
        margin-top: 10px;
        display: block;
      }
P
Phil Hughes 已提交
251 252
    }

253 254 255 256
    .issuable-sidebar {
      padding: 0 20px;
    }

257 258 259 260
    .issuable-sidebar-header {
      padding-top: 10px;
    }

261
    &:not(.issue-boards-sidebar):not([data-signed-in]):not([data-always-show-toggle]) {
C
Clement Ho 已提交
262 263 264 265 266
      .issuable-sidebar-header {
        display: none;
      }
    }

267 268 269 270
    .assign-yourself .btn-link {
      padding-left: 0;
    }

P
Phil Hughes 已提交
271
    .light {
272
      font-weight: $gl-font-weight-normal;
P
Phil Hughes 已提交
273 274
    }

275
    .no-value {
T
tauriedavis 已提交
276
      color: $gl-text-color-secondary;
277 278
    }

279 280 281 282 283
    .sidebar-collapsed-icon {
      display: none;
    }

    .gutter-toggle {
P
Phil Hughes 已提交
284
      margin-top: 7px;
A
Annabel Dunstone Gray 已提交
285
      border-left: 1px solid $border-gray-normal;
286
    }
P
Phil Hughes 已提交
287

C
Clement Ho 已提交
288 289 290 291
    .title .gutter-toggle {
      margin-top: 0;
    }

292
    .assignee .avatar {
P
Phil Hughes 已提交
293 294 295 296 297 298
      float: left;
      margin-right: 10px;
      margin-bottom: 0;
      margin-left: 0;
    }

299 300 301 302
    .assignee .user-list .avatar {
      margin: 0;
    }

P
Phil Hughes 已提交
303 304 305 306
    .username {
      display: block;
      margin-top: 4px;
      font-size: 13px;
307
      font-weight: $gl-font-weight-normal;
P
Phil Hughes 已提交
308
    }
P
Phil Hughes 已提交
309 310 311 312

    .hide-expanded {
      display: none;
    }
313 314 315
  }

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

323
    width: $gutter_collapsed_width;
324
    padding: 0;
J
Jacob Schatz 已提交
325 326

    .block {
327
      width: $gutter_collapsed_width - 2px;
328
      padding: 15px 0 0;
329 330
      border-bottom: none;
      overflow: hidden;
J
Jacob Schatz 已提交
331
    }
332

P
Phil Hughes 已提交
333
    .participants {
A
Annabel Dunstone Gray 已提交
334
      border-bottom: 1px solid $border-gray-normal;
P
Phil Hughes 已提交
335 336
    }

337
    .hide-collapsed {
J
Jacob Schatz 已提交
338 339 340
      display: none;
    }

341
    .gutter-toggle {
P
Phil Hughes 已提交
342 343 344
      width: 100%;
      margin-left: 0;
      padding-left: 25px;
345 346 347 348
    }

    .sidebar-collapsed-icon {
      display: block;
349
      width: 100%;
350
      text-align: center;
P
Phil Hughes 已提交
351
      margin-bottom: 10px;
S
Sam Rose 已提交
352
      color: $issuable-sidebar-color;
J
Jacob Schatz 已提交
353

354 355 356 357
      svg {
        fill: $issuable-sidebar-color;
      }

D
dimitrieh 已提交
358 359
      &:hover,
      &:hover .todo-undone {
T
tauriedavis 已提交
360
        color: $gl-text-color;
361 362 363 364

        svg {
          fill: $gl-text-color;
        }
365 366
      }

J
Jacob Schatz 已提交
367 368 369 370
      span {
        display: block;
        margin-top: 0;
      }
371

372 373 374 375
      .sidebar-avatar-counter {
        padding-top: 2px;
      }

376 377 378 379
      .todo-undone {
        color: $gl-link-color;
      }

380 381 382 383
      .author {
        display: none;
      }

384 385
      .avatar-counter:hover {
        color: $issuable-sidebar-color;
386
        border-color: $issuable-sidebar-color;
387 388
      }

389 390
      .btn-clipboard {
        border: none;
T
tauriedavis 已提交
391
        color: $issuable-sidebar-color;
392 393 394

        &:hover {
          background: transparent;
T
tauriedavis 已提交
395
          color: $gl-text-color;
396 397
        }
      }
398 399 400 401 402 403 404 405 406 407 408

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

    .sidebar-avatar-counter {
      width: 24px;
      height: 24px;
      border-radius: 12px;
409
    }
P
Phil Hughes 已提交
410 411 412 413 414

    .sidebar-collapsed-user {
      padding-bottom: 0;
      margin-bottom: 10px;
    }
415 416 417 418

    .issuable-header-btn {
      display: none;
    }
419 420 421 422 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

    .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;
        }
      }
    }
450 451 452 453 454 455

    .milestone-title span {
      @include str-truncated(100%);
      display: block;
      margin: 0 4px;
    }
J
Jacob Schatz 已提交
456 457
  }

458
  a {
P
Phil Hughes 已提交
459 460 461
    &:hover {
      color: $md-link-color;
      text-decoration: none;
462 463

      .avatar {
464
        border-color: rgba($avatar-border, .2);
465
      }
P
Phil Hughes 已提交
466 467
    }
  }
P
Phil Hughes 已提交
468

469 470 471 472 473 474
  .dropdown-content {
    a:hover {
      color: inherit;
    }
  }

475 476
  .dropdown-menu-toggle {
    width: 100%;
477
    padding-top: 6px;
478 479
  }

480
  .dropdown-menu {
481 482
    width: 100%;
  }
483
}
J
Jacob Schatz 已提交
484

485
.with-performance-bar .right-sidebar {
A
Annabel Dunstone Gray 已提交
486
  top: $new-navbar-height + $performance-bar-height;
487 488

  .issuable-sidebar {
A
Annabel Dunstone Gray 已提交
489
    height: calc(100% - #{$new-navbar-height} - #{$performance-bar-height});
490 491 492
  }
}

493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510
.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;
}

J
Jacob Schatz 已提交
511
.detail-page-description {
512
  padding: 16px 0;
513

J
Jacob Schatz 已提交
514 515 516
  small {
    color: $gray-darkest;
  }
517
}
P
Phil Hughes 已提交
518 519 520

.edited-text {
  color: $gray-darkest;
521
  display: block;
522
  margin: 16px 0 0;
523
  font-size: 85%;
P
Phil Hughes 已提交
524 525 526 527 528

  .author_link {
    color: $gray-darkest;
  }
}
P
Phil Hughes 已提交
529 530

.participants-list {
531
  margin: -5px;
P
Phil Hughes 已提交
532 533
}

C
Clement Ho 已提交
534

535 536 537 538 539
.user-list {
  display: flex;
  flex-wrap: wrap;
}

P
Phil Hughes 已提交
540
.participants-author {
C
Clement Ho 已提交
541
  display: inline-block;
542
  padding: 5px;
P
Phil Hughes 已提交
543

C
Clement Ho 已提交
544 545 546 547
  &:nth-of-type(7n) {
    padding-right: 0;
  }

P
Phil Hughes 已提交
548 549 550 551 552 553 554 555 556
  .author_link {
    display: block;
  }

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

557 558 559 560 561 562 563 564 565 566 567 568
.user-item {
  display: inline-block;
  padding: 5px;
  flex-basis: 20%;

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

.participants-more,
.user-list-more {
P
Phil Hughes 已提交
569 570 571
  margin-top: 5px;
  margin-left: 5px;

572 573
  a,
  .btn-link {
T
tauriedavis 已提交
574
    color: $gl-text-color-secondary;
P
Phil Hughes 已提交
575
  }
576 577 578 579 580 581 582 583 584 585 586 587 588 589

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

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

  .btn-link:focus {
    text-decoration: none;
  }
P
Phil Hughes 已提交
590
}
591 592 593 594 595 596

.issuable-form-padding-top {
  @media (min-width: $screen-sm-min) {
    padding-top: 7px;
  }
}
597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623

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

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

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

653 654 655 656
  @media (max-width: $screen-sm-max) {
    margin-bottom: $gl-padding;
  }
}
657 658 659

.issuable-list {
  li {
N
Nur Rony 已提交
660

N
Nur Rony 已提交
661 662 663 664 665 666 667 668
    .issue-box {
      display: -webkit-flex;
      display: flex;
    }

    .issue-info-container {
      -webkit-flex: 1;
      flex: 1;
T
Taurie Davis 已提交
669
      display: flex;
N
Nur Rony 已提交
670
      padding-right: $gl-padding;
T
Taurie Davis 已提交
671 672 673 674 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

      .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;
          }
        }
      }
N
Nur Rony 已提交
701 702
    }

703
    .issue-check {
704
      padding-right: $gl-padding;
705 706 707 708 709 710 711
      margin-bottom: 10px;
      min-width: 15px;

      .selected_issue {
        vertical-align: text-top;
      }
    }
T
Taurie Davis 已提交
712 713 714 715 716

    .issuable-milestone,
    .issuable-info,
    .task-status,
    .issuable-updated-at {
717
      font-weight: $gl-font-weight-normal;
T
Taurie Davis 已提交
718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735
      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;
      }
    }
736 737
  }
}
738

739 740 741 742 743 744 745 746 747 748 749 750 751
.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;
  }
}

752 753 754 755 756 757 758 759 760 761 762 763 764 765
.time_tracker {
  padding-bottom: 0;
  border-bottom: 0;


  .sidebar-collapsed-icon {

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

    svg {
      width: 16px;
      height: 16px;
766
      fill: $issuable-sidebar-color;
767 768 769
    }

    &:hover svg {
B
Bryce Johnson 已提交
770
      fill: $gl-text-color;
771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787
    }
  }

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

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

    &.over_estimate {
      .meter-fill {
788
        background: $red-500;
789 790 791 792
      }

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

  .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;
B
Bryce Johnson 已提交
817
      color: $compare-display-color;
818 819

      .compare-value {
B
Bryce Johnson 已提交
820
        color: $gl-text-color;
821 822 823 824 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
      }
    }
  }

  .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;
  }
}
P
Phil Hughes 已提交
850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867

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

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

    &.sidebar-collapsed-icon {
      .issuable-todo-inner {
        display: none;
      }
    }
  }
}
868 869 870 871 872 873

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

874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889
.issuable-close-dropdown {
  .dropdown-menu {
    min-width: 270px;
    left: auto;
    right: 0;
  }

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

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