commits.scss 5.42 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
.commit-description {
  background: none;
  border: none;
  padding: 0;
  margin-top: 10px;
  word-break: normal;
  white-space: pre-wrap;
}

.js-details-expand {
  &:hover {
    text-decoration: none;
  }
}

.commit-box {
  border-top: 1px solid $border-color;
  padding: $gl-padding 0;

  .commit-title {
    margin: 0;
22
    color: $gl-text-color;
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
  }

  .commit-description {
    margin-top: 15px;
  }
}

.commit-hash-full {
  @media (max-width: $screen-sm-max) {
    width: 80px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    vertical-align: bottom;
  }
}

41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56
.pipeline-info {
  .status-icon-container {
    display: inline-block;
    vertical-align: middle;
    margin-right: 3px;

    svg {
      display: block;
      width: 22px;
      height: 22px;
    }
  }

  .mr-widget-pipeline-graph {
    display: inline-block;
    vertical-align: middle;
57 58 59 60 61
    margin-right: 4px;

    .stage-cell .stage-container {
      margin: 3px 3px 3px 0;
    }
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76

    .dropdown-menu {
      margin-top: 11px;
    }
  }
}

.branch-info .commit-icon {
  margin-right: 3px;

  svg {
    top: 3px;
  }
}

77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
/*
 * Commit message textarea for web editor and
 * custom merge request message
 */
.commit-message-container {
  background-color: $body-bg;
  position: relative;
  font-family: $monospace_font;
  $left: 12px;
  overflow: hidden; // See https://gitlab.com/gitlab-org/gitlab-ce/issues/13987
  .max-width-marker {
    width: 72ch;
    color: $commit-max-width-marker-color;
    font-family: inherit;
    left: $left;
    height: 100%;
    border-right: 1px solid mix($input-border, $white-light);
    position: absolute;
    z-index: 1;
  }

98
  textarea {
99 100 101 102 103 104 105 106 107
    background-color: $commit-message-text-area-bg;
    font-family: inherit;
    padding-left: $left;
    position: relative;
    z-index: 2;
  }
}


108
.commits-compare-switch {
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
109 110 111
  float: left;
  margin-right: 9px;
}
112

Phil Hughes's avatar
Phil Hughes committed
113 114
.commit-header {
  padding: 5px 10px;
115
  background-color: $gray-light;
116
  border-bottom: 1px solid $gray-darker;
117
  border-top: 1px solid $gray-darker;
Phil Hughes's avatar
Phil Hughes committed
118 119 120 121 122
  font-size: 14px;

  &:first-child {
    border-top-width: 0;
  }
123 124
}

Phil Hughes's avatar
Phil Hughes committed
125 126 127 128
.commit-row-title {
  .notes_count {
    float: right;
    margin-right: 10px;
129
  }
130

Phil Hughes's avatar
Phil Hughes committed
131 132
  .str-truncated {
    max-width: 70%;
133
  }
134

Phil Hughes's avatar
Phil Hughes committed
135
  .commit-row-message {
136
    color: $gl-text-color;
137
  }
138 139 140 141
}

.text-expander {
  display: inline-block;
142
  background: $white-light;
143
  color: $gl-text-color-secondary;
144 145 146 147 148
  padding: 0 5px;
  cursor: pointer;
  border: 1px solid $border-gray-dark;
  border-radius: $border-radius-default;
  margin-left: 5px;
149 150 151
  font-size: $gl-font-size;
  line-height: $gl-font-size;
  outline: none;
152

153 154 155 156 157
  &.open {
    background: $gray-light;
    box-shadow: inset 0 0 2px rgba($black, 0.2);
  }

158 159 160
  &:hover {
    background-color: darken($gray-light, 10%);
    text-decoration: none;
161
  }
162
}
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
163

164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190
.commit.flex-list {
  display: flex;
}

.avatar-cell {
  width: 46px;

  img {
    margin-right: 0;
  }
}

.commit-detail {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-grow: 1;

  .merge-request-branches & {
    flex-direction: column;
  }
}

.commit-content {
  padding-right: 10px;
}

Phil Hughes's avatar
Phil Hughes committed
191
.commit-actions {
Phil Hughes's avatar
Phil Hughes committed
192
  @media (min-width: $screen-sm-min) {
193 194
    font-size: 0;
  }
195

196 197
  .ci-status-link {
    display: inline-block;
198 199
    position: relative;
    top: 1px;
200 201
  }

202 203
  .btn-clipboard,
  .btn-transparent {
204 205 206
    padding-left: 0;
    padding-right: 0;
  }
207

208 209 210
  .btn {
    &:not(:first-child) {
      margin-left: $gl-padding;
211
    }
Phil Hughes's avatar
Phil Hughes committed
212
  }
213

214 215 216 217
  .commit-sha {
    font-size: 14px;
    font-weight: 600;
  }
Phil Hughes's avatar
Phil Hughes committed
218
}
219

220 221
.commit,
.generic_commit_status {
222

223 224
  a,
  button {
225
    color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
226
    vertical-align: baseline;
Phil Hughes's avatar
Phil Hughes committed
227
  }
228 229 230 231

  .commit-row-description {
    font-size: 14px;
    padding: 10px 15px;
232
    margin: 10px 0;
233
    background: $gray-light;
234
    display: none;
235
    white-space: pre-wrap;
236
    word-break: normal;
237 238 239 240 241 242

    pre {
      border: none;
      background: inherit;
      padding: 0;
      margin: 0;
243
      white-space: pre-wrap;
244
    }
Phil Hughes's avatar
Phil Hughes committed
245 246

    a {
247
      color: $gl-text-color;
Phil Hughes's avatar
Phil Hughes committed
248
    }
249 250 251 252 253 254 255 256 257
  }

  &.inline-commit {
    .commit-row-title {
      font-size: 13px;
    }

    .committed_ago {
      @extend .cgray;
258
      float: right;
259 260 261
    }
  }
}
262

263
.branch-commit {
264
  color: $gl-text-color;
265

266 267 268 269 270 271 272 273
  .commit-icon {
    text-align: center;
    display: inline-block;

    svg {
      height: 14px;
      width: 14px;
      vertical-align: middle;
274
      fill: $gl-text-color-secondary;
275 276 277
    }
  }

278
  .commit-sha {
279 280 281
    color: $gl-link-color;
  }

282
  .commit-row-message {
283
    color: $gl-text-color;
284 285
  }
}
286

287

288
.gpg-status-box {
289 290 291
  padding: 2px 10px;
  margin-right: $gl-padding;

292 293 294 295
  &:empty {
    display: none;
  }

296
  &.valid {
297
    @include green-status-color;
298 299 300
  }

  &.invalid {
301 302
    @include status-color($gray-dark, $gray, $common-gray-dark);
    border-color: $common-gray-light;
303 304 305
  }
}

306 307 308
.gpg-popover-status {
  display: flex;
  align-items: center;
309
  font-weight: normal;
310
  line-height: 1.5;
311 312
}

313
.gpg-popover-icon {
314
  // same margin as .s32.avatar
315 316 317
  margin-right: $btn-side-margin;

  &.valid {
318 319 320 321
    svg {
      border: 1px solid $brand-success;
      fill: $brand-success;
    }
322 323 324
  }

  &.invalid {
325
    svg {
326 327
      border: 1px solid $common-gray-light;
      fill: $common-gray-light;
328 329 330 331 332 333 334 335
    }
  }

  svg {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    vertical-align: middle;
336 337 338
  }
}

339
.gpg-popover-user-link {
340 341 342
  display: flex;
  align-items: center;
  margin-bottom: $gl-padding / 2;
343 344 345 346
  text-decoration: none;
  color: $gl-text-color;
}

347
.commit .gpg-popover-help-link {
348 349 350
  display: block;
  color: $link-color;
}