BigW Consortium Gitlab

lists.scss 5.81 KB
Newer Older
1 2 3 4 5
/**
 * Well styled list
 *
 */
.well-list {
Phil Hughes committed
6
  position: relative;
7
  margin: 0;
Dmitriy Zaporozhets committed
8
  padding: 0;
9
  list-style: none;
Dmitriy Zaporozhets committed
10

11
  > li {
12
    padding: 10px 15px;
13
    min-height: 20px;
14
    border-bottom: 1px solid $list-border;
15

16
    &::after {
17 18 19 20 21
      content: " ";
      display: table;
      clear: both;
    }

22
    &.disabled {
23
      color: $list-text-disabled-color;
24 25
    }

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

32
    &.warning-row {
33 34 35
      background-color: $list-warning-row-bg;
      border-color: $list-warning-row-border;
      color: $list-warning-row-color;
36 37
    }

38
    &.smoke { background-color: $gray-light; }
39

40
    &:not(.ui-sort-disabled):hover {
41
      background: $row-hover;
42
    }
43 44

    &:last-child {
45
      border-bottom: none;
46 47

      &.bottom {
48
        background: $gray-light;
49
      }
50 51
    }

52 53 54 55 56 57
    .list-item-name {
      float: left;
      position: relative;
      top: 3px;
    }

58
    p {
59
      padding-top: 1px;
60
      margin: 0;
61
      color: $white-normal;
62

63
      img {
64 65
        position: relative;
        top: 3px;
66 67
      }
    }
68 69

    .well-title {
70
      font-size: $list-font-size;
71 72
      line-height: 18px;
    }
73 74
  }
}
randx committed
75

76 77

/** light list with border-bottom between li **/
78 79
ul.bordered-list,
ul.unstyled-list {
80
  @include basic-list;
81 82 83 84

  &.top-list {
    li:first-child {
      padding-top: 0;
85

86 87
      h4,
      h5 {
88 89 90 91
        margin-top: 0;
      }
    }
  }
92
}
93

94 95 96 97
ul.unstyled-list > li {
  border-bottom: none;
}

98
// Generic content list
99 100 101 102 103
ul.content-list {
  @include basic-list;
  margin: 0;
  padding: 0;

104
  li {
105
    border-color: $white-normal;
106
    font-size: $list-font-size;
107
    color: $list-text-color;
108

109 110 111 112 113 114
    &.no-description {
      .title {
        line-height: $list-text-height;
      }
    }

115 116 117
    .title {
      font-weight: 600;
    }
118

119
    a {
120
      color: $gl-text-color;
121 122
    }

Phil Hughes committed
123
    .member-group-link {
124
      color: $blue-600;
Phil Hughes committed
125 126
    }

127 128 129 130 131 132 133
    .description {
      p {
        @include str-truncated;
        margin-bottom: 0;
      }
    }

Dmitriy Zaporozhets committed
134 135
    .controls {
      float: right;
136

137 138
      > .control-text {
        margin-right: $gl-padding-top;
139
        line-height: $list-text-height;
140 141 142 143 144 145

        &:last-child {
          margin-right: 0;
        }
      }

146
      > .btn,
147 148
      > .btn-group,
      > .dropdown.inline {
149 150
        margin-right: $gl-padding-top;
        display: inline-block;
151
        margin-top: 3px;
152
        margin-bottom: 4px;
153

154
        &.has-tooltip,
155 156
        &:last-child {
          margin-right: 0;
157 158 159 160

          @media(max-width: $screen-xs-max) {
            margin: 0 auto;
          }
161
        }
162
      }
163 164

      .no-comments {
165
        opacity: .5;
166
      }
Dmitriy Zaporozhets committed
167
    }
168

169 170
    .member-controls {
      float: none;
Phil Hughes committed
171 172

      @media (min-width: $screen-sm-min) {
173 174 175 176
        float: right;
      }
    }

177 178 179 180 181 182 183
    // When dragging a list item
    &.ui-sortable-helper {
      border-bottom: none;
    }

    &.list-placeholder {
      background-color: $gray-light;
184
      border: dotted 1px $white-normal;
185
      margin: 1px 0;
186
      min-height: 52px;
187
    }
188 189 190
  }
}

191 192 193 194 195 196
// Content list using flexbox
.flex-list {
  .flex-row {
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
197
    align-items: center;
198 199 200 201 202 203 204 205 206
    white-space: nowrap;
  }

  .row-main-content {
    flex: 1 1 auto;
    overflow: hidden;
    padding-right: 8px;
  }

207 208 209 210 211
  .row-fixed-content {
    flex: 0 0 auto;
    margin-left: auto;
  }

212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227
  .row-title {
    font-weight: 600;
  }

  .row-second-line {
    display: block;
  }

  .dropdown {
    .btn-block {
      margin-bottom: 0;
      line-height: inherit;
    }
  }

  .label-default {
228
    color: $gl-text-color-secondary;
229 230 231
  }
}

232 233 234 235
.panel > .content-list > li {
  padding: $gl-padding-top $gl-padding;
}

236 237 238
ul.controls {
  float: right;
  list-style: none;
239 240
  display: flex;
  align-items: center;
241 242 243 244 245 246 247

  .btn {
    padding: 10px 14px;
  }

  > li {
    float: left;
248
    margin-right: 10px;
249

250 251 252
    &:last-child {
      margin-right: 0;
    }
253 254 255 256 257 258 259

    .author_link {
      display: inline-block;

      .avatar-inline {
        margin-left: 0;
        margin-right: 0;
260
        margin-bottom: 0;
261 262 263
      }
    }
  }
264 265 266 267 268 269

  .issuable-pipeline-broken a,
  .issuable-pipeline-status a,
  .author_link {
    display: flex;
  }
270
}
271 272 273 274

ul.indent-list {
  padding: 10px 0 0 30px;
}
275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301


// Specific styles for tree list
.group-list-tree {
  .folder-toggle-wrap {
    float: left;
    line-height: $list-text-height;
    font-size: 0;

    span {
      font-size: $gl-font-size;
    }
  }

  .folder-caret,
  .folder-icon {
    display: inline-block;
  }

  .folder-caret {
    width: 15px;
  }

  .folder-icon {
    width: 20px;
  }

302
  > .group-row:not(.has-subgroups) {
303 304 305 306 307 308 309 310 311 312 313
    .folder-caret .fa {
      opacity: 0;
    }
  }

  .content-list li:last-child {
    padding-bottom: 0;
  }

  .group-list-tree {
    margin-bottom: 0;
314
    margin-left: 30px;
315 316
    position: relative;

317
    &::before {
318 319 320 321
      content: '';
      display: block;
      width: 0;
      position: absolute;
322
      top: 5px;
323 324 325 326 327 328 329
      bottom: 0;
      left: -16px;
      border-left: 2px solid $border-white-normal;
    }

    .group-row {
      position: relative;
330 331

      &::before {
332 333 334 335 336 337 338 339 340 341
        content: "";
        display: block;
        width: 10px;
        height: 0;
        border-top: 2px solid $border-white-normal;
        position: absolute;
        top: 30px;
        left: -16px;
      }

342 343
      &:last-child::before {
        background: $white-light;
344 345 346 347 348 349
        height: auto;
        top: 30px;
        bottom: 0;
      }
    }
  }
Alfredo Sumaran committed
350

351 352 353
  .group-row {
    padding: 0;
    border: none;
354 355 356 357 358 359

    &:last-of-type {
      .group-row-contents:not(:hover) {
        border-bottom: 1px solid transparent;
      }
    }
360 361 362
  }

  .group-row-contents {
Alfredo Sumaran committed
363
    padding: 10px 10px 8px;
364 365 366
    border-top: solid 1px transparent;
    border-bottom: solid 1px $white-normal;

Alfredo Sumaran committed
367
    &:hover {
368 369
      border-color: $row-hover-border;
      background-color: $row-hover;
Alfredo Sumaran committed
370
      cursor: pointer;
371 372
    }
  }
373
}
374 375 376 377 378 379 380

.js-groups-list-holder {
  .groups-list-loading {
    font-size: 34px;
    text-align: center;
  }
}