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

380 lines
6.2 KiB
SCSS
Raw Normal View History

2014-09-02 18:07:02 +05:30
/**
* File content holder
*
*/
.file-holder {
border: 1px solid $border-color;
2017-09-10 17:25:29 +05:30
border-radius: $border-radius-default;
2014-09-02 18:07:02 +05:30
&.file-holder-no-border {
border: 0;
}
2015-11-26 14:37:03 +05:30
&.readme-holder {
2017-09-10 17:25:29 +05:30
margin: $gl-padding 0;
&.limited-width-container .file-content {
max-width: $limited-layout-width-sm;
margin-left: auto;
margin-right: auto;
padding-top: 64px;
padding-bottom: 64px;
}
2015-11-26 14:37:03 +05:30
}
2014-09-02 18:07:02 +05:30
table {
@extend .table;
}
.file-title {
2015-04-26 12:48:37 +05:30
position: relative;
2017-08-17 22:00:37 +05:30
background-color: $gray-light;
2015-04-26 12:48:37 +05:30
border-bottom: 1px solid $border-color;
2014-09-02 18:07:02 +05:30
margin: 0;
text-align: left;
2015-12-23 02:04:40 +05:30
padding: 10px $gl-padding;
2016-06-02 11:05:42 +05:30
word-wrap: break-word;
2017-09-10 17:25:29 +05:30
border-radius: $border-radius-default $border-radius-default 0 0;
2014-09-02 18:07:02 +05:30
&.file-title-clear {
padding-left: 0;
padding-right: 0;
background-color: transparent;
.file-actions {
right: 0;
}
}
2015-04-26 12:48:37 +05:30
.file-actions {
position: absolute;
top: 5px;
right: 15px;
.btn {
2016-06-02 11:05:42 +05:30
padding: 0 10px;
2015-04-26 12:48:37 +05:30
font-size: 13px;
line-height: 28px;
}
2014-09-02 18:07:02 +05:30
}
2016-06-02 11:05:42 +05:30
a:not(.btn) {
2016-08-24 12:49:21 +05:30
color: $gl-text-color;
2016-04-02 18:10:28 +05:30
}
2014-09-02 18:07:02 +05:30
.left-options {
margin-top: -3px;
}
}
2016-11-03 12:29:30 +05:30
2017-09-10 17:25:29 +05:30
.file-blame-legend {
background-color: $gray-light;
text-align: right;
padding: 8px $gl-padding;
border-bottom: 1px solid $border-color;
@media (max-width: $screen-xs-max) {
text-align: left;
}
.left-label {
padding-right: 5px;
}
.right-label {
padding-left: 5px;
}
.legend-box {
display: inline-block;
width: 10px;
height: 10px;
padding: 0 2px;
}
@for $i from 0 through 5 {
.legend-box-#{$i} {
background-color: mix($blame-cyan, $blame-blue, $i / 5.0 * 100%);
}
}
@for $i from 1 through 4 {
.legend-box-#{$i + 5} {
background-color: mix($blame-gray, $blame-cyan, $i / 4.0 * 100%);
}
}
}
2014-09-02 18:07:02 +05:30
.file-content {
2017-08-17 22:00:37 +05:30
background: $white-light;
2014-09-02 18:07:02 +05:30
2017-08-17 22:00:37 +05:30
&.image_file,
&.video {
background: $file-image-bg;
2014-09-02 18:07:02 +05:30
text-align: center;
2017-09-10 17:25:29 +05:30
padding: 30px;
2016-09-29 09:46:39 +05:30
2017-08-17 22:00:37 +05:30
img,
video {
2016-09-29 09:46:39 +05:30
max-width: 80%;
2014-09-02 18:07:02 +05:30
}
}
&.wiki {
2016-09-13 17:45:13 +05:30
padding: 30px $gl-padding;
2014-09-02 18:07:02 +05:30
}
&.blob-no-preview {
2017-08-17 22:00:37 +05:30
background: $blob-bg;
text-shadow: 0 1px 2px $white-light;
2014-09-02 18:07:02 +05:30
padding: 100px 0;
}
/**
* Blame file
*/
&.blame {
table {
border: none;
margin: 0;
}
2016-11-03 12:29:30 +05:30
2014-09-02 18:07:02 +05:30
tr {
2017-08-17 22:00:37 +05:30
border-bottom: 1px solid $blame-border;
2017-09-10 17:25:29 +05:30
&:last-child {
border-bottom: none;
}
2014-09-02 18:07:02 +05:30
}
2016-11-03 12:29:30 +05:30
2014-09-02 18:07:02 +05:30
td {
2017-09-10 17:25:29 +05:30
border-top: none;
border-bottom: none;
2014-09-02 18:07:02 +05:30
&:first-child {
border-left: none;
}
2016-11-03 12:29:30 +05:30
2014-09-02 18:07:02 +05:30
&:last-child {
border-right: none;
}
}
2016-11-03 12:29:30 +05:30
2015-09-25 12:07:36 +05:30
td.blame-commit {
2017-09-10 17:25:29 +05:30
padding: 5px 10px;
2016-09-29 09:46:39 +05:30
min-width: 400px;
2017-09-10 17:25:29 +05:30
max-width: 400px;
2016-09-29 09:46:39 +05:30
background: $gray-light;
2017-09-10 17:25:29 +05:30
border-left: 3px solid;
.commit-row-title {
display: flex;
}
.item-title {
flex: 1;
margin-right: 0.5em;
}
}
@for $i from 0 through 5 {
td.blame-commit-age-#{$i} {
border-left-color: mix($blame-cyan, $blame-blue, $i / 5.0 * 100%);
}
}
@for $i from 1 through 4 {
td.blame-commit-age-#{$i + 5} {
border-left-color: mix($blame-gray, $blame-cyan, $i / 4.0 * 100%);
}
2015-09-25 12:07:36 +05:30
}
2016-11-03 12:29:30 +05:30
2016-02-05 20:25:01 +05:30
td.line-numbers {
float: none;
2017-08-17 22:00:37 +05:30
border-left: 1px solid $blame-line-numbers-border;
2016-06-02 11:05:42 +05:30
i {
float: none;
margin-right: 0;
}
2015-09-25 12:07:36 +05:30
}
2016-11-03 12:29:30 +05:30
2015-09-25 12:07:36 +05:30
td.lines {
2016-02-05 20:25:01 +05:30
padding: 0;
2015-09-25 12:07:36 +05:30
}
2014-09-02 18:07:02 +05:30
}
&.logs {
2017-08-17 22:00:37 +05:30
background: $logs-bg;
2014-09-02 18:07:02 +05:30
max-height: 700px;
overflow-y: auto;
ol {
margin-left: 40px;
padding: 10px 0;
2015-04-26 12:48:37 +05:30
border-left: 1px solid $border-color;
2014-09-02 18:07:02 +05:30
margin-bottom: 0;
2017-08-17 22:00:37 +05:30
background: $white-light;
2016-11-03 12:29:30 +05:30
2014-09-02 18:07:02 +05:30
li {
2017-08-17 22:00:37 +05:30
color: $logs-li-color;
2016-11-03 12:29:30 +05:30
2014-09-02 18:07:02 +05:30
p {
margin: 0;
2017-08-17 22:00:37 +05:30
color: $logs-p-color;
2014-09-02 18:07:02 +05:30
line-height: 24px;
padding-left: 10px;
}
&:hover {
2016-04-02 18:10:28 +05:30
background: $row-hover;
2014-09-02 18:07:02 +05:30
}
}
}
}
/**
* Code file
*/
&.code {
padding: 0;
}
2017-08-17 22:00:37 +05:30
.list-inline.previews {
display: flex;
flex-wrap: wrap;
justify-content: center;
align-content: flex-start;
align-items: baseline;
.preview {
padding: $gl-padding;
}
}
2014-09-02 18:07:02 +05:30
}
}
2016-04-02 18:10:28 +05:30
span.idiff {
&.left {
border-top-left-radius: 2px;
border-bottom-left-radius: 2px;
}
&.right {
border-top-right-radius: 2px;
border-bottom-right-radius: 2px;
}
}
2017-08-17 22:00:37 +05:30
.file-stats {
ul {
list-style: none;
margin: 0;
padding: 10px 0;
li {
padding: 3px 0;
line-height: 20px;
}
}
.new-file {
a {
color: $gl-text-green;
}
}
.renamed-file {
a {
color: $gl-text-orange;
}
}
.deleted-file {
a {
color: $gl-text-red;
}
}
.edit-file {
a {
color: $gl-text-color;
}
}
a {
text-decoration: none;
.new-file {
color: $notify-new-file;
}
.deleted-file {
color: $notify-deleted-file;
}
}
}
.file-title-flex-parent {
display: flex;
align-items: center;
justify-content: space-between;
background-color: $gray-light;
border-bottom: 1px solid $border-color;
padding: 5px $gl-padding;
margin: 0;
2017-09-10 17:25:29 +05:30
border-radius: $border-radius-default $border-radius-default 0 0;
2017-08-17 22:00:37 +05:30
.file-header-content {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
padding-right: 30px;
position: relative;
}
.btn-clipboard {
position: absolute;
right: 0;
}
a {
color: $gl-text-color;
}
small {
margin: 0 10px 0 0;
}
.file-actions {
white-space: nowrap;
.btn {
padding: 0 10px;
font-size: 13px;
line-height: 28px;
display: inline-block;
float: none;
}
}
}
.is-stl-loading {
.stl-controls {
display: none;
}
}
.file-fork-suggestion {
display: flex;
align-items: center;
justify-content: flex-end;
background-color: $gray-light;
border-bottom: 1px solid $border-color;
padding: 5px $gl-padding;
}
.file-fork-suggestion-note {
margin-right: 1.5em;
}