debian-mirror-gitlab/app/assets/stylesheets/framework/common.scss

598 lines
11 KiB
SCSS
Raw Normal View History

2014-09-02 18:07:02 +05:30
/** COLORS **/
2018-11-20 20:47:30 +05:30
.cgray { color: $gl-text-color; }
2017-08-17 22:00:37 +05:30
.clgray { color: $common-gray-light; }
2018-11-20 20:47:30 +05:30
.cred { color: $red-500; }
.cgreen { color: $green-600; }
2017-08-17 22:00:37 +05:30
.cdark { color: $common-gray-dark; }
2014-09-02 18:07:02 +05:30
2019-09-04 21:01:54 +05:30
.fwhite { fill: $white-light; }
.fgray { fill: $gray-700; }
2018-03-17 18:26:18 +05:30
.text-plain,
.text-plain:hover {
color: $gl-text-color;
}
.text-secondary {
color: $gl-text-color-secondary;
}
2018-03-27 19:54:05 +05:30
.text-tertiary {
color: $gl-text-color-tertiary;
}
2018-03-17 18:26:18 +05:30
.text-primary,
.text-primary:hover {
color: $brand-primary;
}
.text-success,
.text-success:hover {
color: $brand-success;
}
.text-danger,
.text-danger:hover {
color: $brand-danger;
}
2018-12-13 13:39:08 +05:30
.text-danger-muted,
.text-danger-muted:hover {
color: $red-300;
}
2018-03-17 18:26:18 +05:30
.text-warning,
.text-warning:hover {
color: $brand-warning;
}
.text-info,
.text-info:hover {
color: $brand-info;
}
2014-09-02 18:07:02 +05:30
2019-07-31 22:56:46 +05:30
.bg-gray-light {
background-color: $gray-light;
}
2020-03-09 13:42:32 +05:30
.bg-white {
background-color: $white;
}
2019-12-21 20:55:43 +05:30
.bg-line-target-blue {
background: $line-target-blue;
}
2019-07-07 11:18:12 +05:30
.text-break-word {
word-break: break-all;
}
.text-underline,
.text-underline:hover {
text-decoration: underline;
}
.hint {
font-style: italic;
color: $gl-gray-400;
}
2018-11-20 20:47:30 +05:30
.light { color: $gl-text-color; }
2014-09-02 18:07:02 +05:30
.slead {
2018-11-20 20:47:30 +05:30
color: $gl-text-color;
2017-08-17 22:00:37 +05:30
font-size: 14px;
2014-09-02 18:07:02 +05:30
margin-bottom: 12px;
2018-03-17 18:26:18 +05:30
font-weight: $gl-font-weight-normal;
2014-09-02 18:07:02 +05:30
line-height: 24px;
}
2017-08-17 22:00:37 +05:30
.bold {
2018-03-17 18:26:18 +05:30
font-weight: $gl-font-weight-bold;
2017-08-17 22:00:37 +05:30
}
2014-09-02 18:07:02 +05:30
.tab-content {
overflow: visible;
}
pre {
&.clean {
background: none;
2018-03-17 18:26:18 +05:30
border: 0;
2014-09-02 18:07:02 +05:30
margin: 0;
padding: 0;
}
2017-08-17 22:00:37 +05:30
&.wrap {
word-break: break-word;
white-space: pre-wrap;
2014-09-02 18:07:02 +05:30
}
}
2015-12-23 02:04:40 +05:30
hr {
2017-08-17 22:00:37 +05:30
margin: 24px 0;
border-top: 1px solid darken($gray-normal, 8%);
2015-12-23 02:04:40 +05:30
}
2014-09-02 18:07:02 +05:30
.str-truncated {
@include str-truncated;
2018-03-17 18:26:18 +05:30
2019-03-02 22:35:43 +05:30
&-30 {
@include str-truncated(30%);
}
2018-03-17 18:26:18 +05:30
&-60 {
@include str-truncated(60%);
}
&-100 {
@include str-truncated(100%);
}
2014-09-02 18:07:02 +05:30
}
2017-08-17 22:00:37 +05:30
.block-truncated {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
2019-07-07 11:18:12 +05:30
> div:not(.block),
2017-08-17 22:00:37 +05:30
.str-truncated {
display: inline;
}
}
2018-03-17 18:26:18 +05:30
.item-title { font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.author-link {
2018-11-20 20:47:30 +05:30
color: $blue-600;
}
.author-link:hover {
text-decoration: none;
2014-09-02 18:07:02 +05:30
}
2018-03-17 18:26:18 +05:30
table {
a code {
position: relative;
top: -2px;
margin-right: 3px;
}
2014-09-02 18:07:02 +05:30
}
.loading {
margin: 20px auto;
height: 40px;
2018-12-05 23:21:45 +05:30
color: $gl-gray-700;
2014-09-02 18:07:02 +05:30
font-size: 32px;
text-align: center;
}
p.time {
2018-12-05 23:21:45 +05:30
color: $gl-gray-400;
2014-09-02 18:07:02 +05:30
font-size: 90%;
margin: 30px 3px 3px 2px;
}
.highlight {
text-shadow: none;
}
2019-07-07 11:18:12 +05:30
.thin-area {
2014-09-02 18:07:02 +05:30
height: 150px;
}
// Fix issue with notes & lists creating a bunch of bottom borders.
li.note {
2016-11-03 12:29:30 +05:30
img { max-width: 100%; }
2019-07-07 11:18:12 +05:30
2014-09-02 18:07:02 +05:30
.note-title {
li {
2018-03-17 18:26:18 +05:30
border-bottom: 0 !important;
2014-09-02 18:07:02 +05:30
}
}
}
.markdown {
img {
max-width: 100%;
}
}
2017-08-17 22:00:37 +05:30
.wiki_content code,
.readme code {
2014-09-02 18:07:02 +05:30
background-color: inherit;
}
.error-message {
padding: 10px;
2018-11-20 20:47:30 +05:30
background: $red-400;
2014-09-02 18:07:02 +05:30
margin: 0;
2017-08-17 22:00:37 +05:30
color: $white-light;
2014-09-02 18:07:02 +05:30
a {
2017-08-17 22:00:37 +05:30
color: $white-light;
2014-09-02 18:07:02 +05:30
text-decoration: underline;
}
}
2019-07-07 11:18:12 +05:30
@mixin message($background-color, $border-color, $text-color) {
border-left: 4px solid $border-color;
color: $text-color;
2019-12-21 20:55:43 +05:30
padding: $gl-padding $gl-padding-24;
margin-bottom: $gl-padding-12;
background-color: $background-color;
2014-09-02 18:07:02 +05:30
&.centered {
text-align: center;
}
2019-12-21 20:55:43 +05:30
.close {
svg {
width: $gl-font-size-large;
height: $gl-font-size-large;
}
color: inherit;
}
2014-09-02 18:07:02 +05:30
}
2019-07-07 11:18:12 +05:30
.warning_message {
2019-12-21 20:55:43 +05:30
@include message($orange-100, $orange-200, $orange-800);
2019-07-07 11:18:12 +05:30
}
.danger_message {
@include message($red-100, $red-200, $red-900);
}
2014-09-02 18:07:02 +05:30
.gitlab-promo {
a {
2018-12-05 23:21:45 +05:30
color: $gl-gray-350;
2014-09-02 18:07:02 +05:30
margin-right: 30px;
}
}
.milestone {
.progress {
margin-top: 4px;
2017-08-17 22:00:37 +05:30
box-shadow: none;
background-color: $border-gray-light;
2014-09-02 18:07:02 +05:30
}
}
img.emoji {
height: 20px;
2016-09-29 09:46:39 +05:30
vertical-align: top;
2014-09-02 18:07:02 +05:30
width: 20px;
2017-08-17 22:00:37 +05:30
margin-top: 1px;
2014-09-02 18:07:02 +05:30
}
.chart {
overflow: hidden;
height: 220px;
}
.description-block {
@extend .light-well;
@extend .light;
margin-bottom: 10px;
}
2015-04-26 12:48:37 +05:30
.footer-links {
margin-bottom: 20px;
2016-11-03 12:29:30 +05:30
2015-04-26 12:48:37 +05:30
a {
margin-right: 15px;
}
2014-09-02 18:07:02 +05:30
}
2018-11-08 19:23:39 +05:30
.card.card-body {
2015-12-23 02:04:40 +05:30
margin-bottom: $gl-padding;
2017-08-17 22:00:37 +05:30
hr {
border-color: $gray-darker;
}
2015-11-26 14:37:03 +05:30
}
2014-09-02 18:07:02 +05:30
.search_box {
2018-11-08 19:23:39 +05:30
@extend .card.card-body;
2014-09-02 18:07:02 +05:30
text-align: center;
}
2015-09-25 12:07:36 +05:30
.dropzone .dz-preview .dz-progress {
border-color: $border-color !important;
2018-03-17 18:26:18 +05:30
.dz-upload {
2018-11-20 20:47:30 +05:30
background: $green-500 !important;
2018-03-17 18:26:18 +05:30
}
2015-09-25 12:07:36 +05:30
}
2015-10-24 18:46:33 +05:30
2017-09-10 17:25:29 +05:30
.dz-message {
margin: 0;
}
2015-10-24 18:46:33 +05:30
.space-right {
margin-right: 10px;
}
2015-12-23 02:04:40 +05:30
2018-11-18 11:00:15 +05:30
.alert {
2015-12-23 02:04:40 +05:30
margin-bottom: $gl-padding;
}
2018-11-18 11:00:15 +05:30
.progress {
height: 4px;
}
2016-04-02 18:10:28 +05:30
.project-item-select-holder {
2015-12-23 02:04:40 +05:30
display: inline-block;
position: relative;
2016-04-02 18:10:28 +05:30
.project-item-select {
2015-12-23 02:04:40 +05:30
position: absolute;
top: 0;
right: 0;
2016-06-02 11:05:42 +05:30
min-width: 250px;
2015-12-23 02:04:40 +05:30
visibility: hidden;
}
}
2017-08-17 22:00:37 +05:30
.gl-accessibility {
&:focus {
2018-03-17 18:26:18 +05:30
display: flex;
align-items: center;
2017-08-17 22:00:37 +05:30
top: 1px;
left: 1px;
width: auto;
height: 100%;
padding: 0 10px;
clip: auto;
text-decoration: none;
color: $gl-text-color;
background: $gray-light;
z-index: 1;
}
}
.bordered-box {
border: 1px solid $border-color;
border-radius: $border-radius-default;
}
.tooltip {
.tooltip-inner {
word-wrap: break-word;
}
}
2017-09-10 17:25:29 +05:30
.disabled-content {
pointer-events: none;
2019-07-07 11:18:12 +05:30
opacity: 0.5;
2017-09-10 17:25:29 +05:30
}
2018-03-17 18:26:18 +05:30
2018-05-09 12:01:36 +05:30
.break-word {
word-wrap: break-word;
}
2018-12-05 23:21:45 +05:30
.checkbox-icon-inline-wrapper {
.checkbox {
display: inline;
label {
display: inline;
}
}
}
2018-12-13 13:39:08 +05:30
.outline-0 {
outline: 0;
&:focus {
outline: 0;
}
}
2018-03-17 18:26:18 +05:30
/** COMMON CLASSES **/
.prepend-top-0 { margin-top: 0; }
2018-10-15 14:42:47 +05:30
.prepend-top-2 { margin-top: 2px; }
2018-12-13 13:39:08 +05:30
.prepend-top-4 { margin-top: $gl-padding-4; }
2018-03-17 18:26:18 +05:30
.prepend-top-5 { margin-top: 5px; }
.prepend-top-8 { margin-top: $grid-size; }
.prepend-top-10 { margin-top: 10px; }
.prepend-top-15 { margin-top: 15px; }
.prepend-top-default { margin-top: $gl-padding !important; }
.prepend-top-16 { margin-top: 16px; }
.prepend-top-20 { margin-top: 20px; }
2019-07-07 11:18:12 +05:30
.prepend-top-32 { margin-top: 32px; }
2019-12-21 20:55:43 +05:30
.prepend-left-2 { margin-left: 2px; }
2018-03-17 18:26:18 +05:30
.prepend-left-4 { margin-left: 4px; }
.prepend-left-5 { margin-left: 5px; }
.prepend-left-8 { margin-left: 8px; }
.prepend-left-10 { margin-left: 10px; }
2019-07-07 11:18:12 +05:30
.prepend-left-15 { margin-left: 15px; }
2018-03-17 18:26:18 +05:30
.prepend-left-default { margin-left: $gl-padding; }
.prepend-left-20 { margin-left: 20px; }
2019-07-07 11:18:12 +05:30
.prepend-left-32 { margin-left: 32px; }
2019-12-04 20:38:33 +05:30
.prepend-left-64 { margin-left: 64px; }
2018-11-18 11:00:15 +05:30
.append-right-4 { margin-right: 4px; }
2018-03-17 18:26:18 +05:30
.append-right-5 { margin-right: 5px; }
.append-right-8 { margin-right: 8px; }
.append-right-10 { margin-right: 10px; }
2019-07-07 11:18:12 +05:30
.append-right-15 { margin-right: 15px; }
2018-03-17 18:26:18 +05:30
.append-right-default { margin-right: $gl-padding; }
.append-right-20 { margin-right: 20px; }
2019-12-04 20:38:33 +05:30
.append-right-32 { margin-right: 32px; }
.append-right-48 { margin-right: 48px; }
2019-07-07 11:18:12 +05:30
.prepend-right-32 { margin-right: 32px; }
2018-03-17 18:26:18 +05:30
.append-bottom-0 { margin-bottom: 0; }
2018-12-13 13:39:08 +05:30
.append-bottom-4 { margin-bottom: $gl-padding-4; }
2018-03-17 18:26:18 +05:30
.append-bottom-5 { margin-bottom: 5px; }
2018-10-15 14:42:47 +05:30
.append-bottom-8 { margin-bottom: $grid-size; }
2018-03-17 18:26:18 +05:30
.append-bottom-10 { margin-bottom: 10px; }
.append-bottom-15 { margin-bottom: 15px; }
.append-bottom-20 { margin-bottom: 20px; }
.append-bottom-default { margin-bottom: $gl-padding; }
2019-07-07 11:18:12 +05:30
.prepend-bottom-32 { margin-bottom: 32px; }
2018-03-17 18:26:18 +05:30
.inline { display: inline-block; }
.center { text-align: center; }
2019-07-07 11:18:12 +05:30
.block { display: block; }
.flex { display: flex; }
2019-09-04 21:01:54 +05:30
.vertical-align-top { vertical-align: top; }
2020-01-01 13:55:28 +05:30
.vertical-align-text-top { vertical-align: text-top; }
2018-03-17 18:26:18 +05:30
.vertical-align-middle { vertical-align: middle; }
2019-03-02 22:35:43 +05:30
.vertical-align-sub { vertical-align: sub; }
2018-11-18 11:00:15 +05:30
.flex-align-self-center { align-self: center; }
.flex-grow { flex-grow: 1; }
.flex-no-shrink { flex-shrink: 0; }
2018-12-13 13:39:08 +05:30
.ws-initial { white-space: initial; }
2019-07-07 11:18:12 +05:30
.ws-normal { white-space: normal; }
2019-12-21 20:55:43 +05:30
.ws-pre-wrap { white-space: pre-wrap; }
2019-02-15 15:39:39 +05:30
.overflow-auto { overflow: auto; }
2020-01-01 13:55:28 +05:30
.overflow-visible { overflow: visible; }
2019-07-07 11:18:12 +05:30
2019-03-02 22:35:43 +05:30
.d-flex-center {
display: flex;
align-items: center;
justify-content: center;
}
2019-02-15 15:39:39 +05:30
/** COMMON SIZING CLASSES **/
.w-0 { width: 0; }
2019-10-12 21:52:04 +05:30
.w-8em { width: 8em; }
.w-3rem { width: 3rem; }
2019-12-21 20:55:43 +05:30
.w-15p { width: 15%; }
2020-03-09 13:42:32 +05:30
.w-30p { width: 30%; }
.w-60p { width: 60%; }
2019-12-21 20:55:43 +05:30
.w-70p { width: 70%; }
2019-03-02 22:35:43 +05:30
.h-12em { height: 12em; }
2019-12-04 20:38:33 +05:30
.h-32-px { height: 32px;}
2019-03-02 22:35:43 +05:30
2019-02-15 15:39:39 +05:30
.mw-460 { max-width: 460px; }
.mw-6em { max-width: 6em; }
2019-07-07 11:18:12 +05:30
.mw-70p { max-width: 70%; }
2019-10-12 21:52:04 +05:30
.mw-90p { max-width: 90%; }
2019-03-02 22:35:43 +05:30
2019-02-15 15:39:39 +05:30
.min-height-0 { min-height: 0; }
2019-07-31 22:56:46 +05:30
.svg-w-100 {
svg {
width: 100%;
}
}
2019-02-15 15:39:39 +05:30
/** COMMON SPACING CLASSES **/
2019-07-31 22:56:46 +05:30
@each $index, $padding in $spacing-scale {
#{'.gl-p-#{$index}'} { padding: $padding; }
#{'.gl-pl-#{$index}'} { padding-left: $padding; }
#{'.gl-pr-#{$index}'} { padding-right: $padding; }
#{'.gl-pt-#{$index}'} { padding-top: $padding; }
#{'.gl-pb-#{$index}'} { padding-bottom: $padding; }
}
2019-03-02 22:35:43 +05:30
/**
* Removes browser specific clear icon from input fields in
* Internet Explorer 10, Internet Explorer 11, and Microsoft Edge.
* This is intended for elements which add a customized clear icon.
*
* see also https://developer.mozilla.org/en-US/docs/Web/CSS/::-ms-clear
*/
.ms-no-clear ::-ms-clear {
display: none;
}
/** COMMON POSITIONING CLASSES */
2019-07-07 11:18:12 +05:30
.position-bottom-0 { bottom: 0 !important; }
.position-left-0 { left: 0 !important; }
.position-right-0 { right: 0 !important; }
.position-top-0 { top: 0 !important; }
.drag-handle {
width: 4px;
&:hover {
background-color: $white-normal;
}
&.is-dragging {
background-color: $gray-600;
}
}
.cursor-pointer {
cursor: pointer;
}
2019-09-04 21:01:54 +05:30
2020-01-01 13:55:28 +05:30
// this needs to use "!important" due to some very specific styles
// around buttons
.cursor-default {
cursor: default !important;
}
2019-09-04 21:01:54 +05:30
// Make buttons/dropdowns full-width on mobile
.full-width-mobile {
@include media-breakpoint-down(xs) {
width: 100%;
> .dropdown-menu,
> .btn {
width: 100%;
}
}
}
.onboarding-helper-container {
bottom: 40px;
right: 40px;
font-size: $gl-font-size-small;
background: $gray-100;
width: 200px;
border-radius: 24px;
box-shadow: 0 2px 4px $issue-boards-card-shadow;
z-index: 10000;
.collapsible {
max-height: 0;
transition: max-height 0.5s cubic-bezier(0, 1, 0, 1);
}
&.expanded {
border-bottom-right-radius: $border-radius-default;
border-bottom-left-radius: $border-radius-default;
.collapsible {
max-height: 1000px;
transition: max-height 1s ease-in-out;
}
}
.avatar {
border-color: darken($gray-normal, 10%);
img {
width: 32px;
height: 32px;
}
}
}
2019-12-21 20:55:43 +05:30
.gl-font-size-small { font-size: $gl-font-size-small; }
2019-12-26 22:10:19 +05:30
.gl-font-size-large { font-size: $gl-font-size-large; }
2019-12-21 20:55:43 +05:30
.gl-line-height-24 { line-height: $gl-line-height-24; }
2020-03-09 13:42:32 +05:30
.gl-line-height-14 { line-height: $gl-line-height-14; }
2019-12-26 22:10:19 +05:30
2020-03-09 13:42:32 +05:30
.gl-font-size-0 { font-size: 0; }
2019-12-26 22:10:19 +05:30
.gl-font-size-12 { font-size: $gl-font-size-12; }
.gl-font-size-14 { font-size: $gl-font-size-14; }
.gl-font-size-16 { font-size: $gl-font-size-16; }
.gl-font-size-20 { font-size: $gl-font-size-20; }
.gl-font-size-28 { font-size: $gl-font-size-28; }
.gl-font-size-42 { font-size: $gl-font-size-42; }
.border-section {
@include gl-py-6;
@include gl-m-0;
border-top: 1px solid $border-color;
}