gitlab-org--gitlab-foss/app/assets/stylesheets/framework/highlight.scss
2019-06-10 05:00:43 +00:00

77 lines
1.5 KiB
SCSS

.file-content.code {
border: 0;
box-shadow: none;
margin: 0;
padding: 0;
table-layout: fixed;
pre {
padding: 10px 0;
border: 0;
border-radius: 0 0 $border-radius-default $border-radius-default;
font-family: $monospace-font;
font-size: $code-font-size;
line-height: 1.5;
margin: 0;
overflow: auto;
overflow-y: hidden;
white-space: pre;
word-wrap: normal;
border-left: 1px solid;
code {
display: inline-block;
min-width: 100%;
font-family: $monospace-font;
white-space: normal;
word-wrap: normal;
padding: 0;
.line {
display: block;
width: 100%;
min-height: 1.5em;
padding-left: 10px;
padding-right: 10px;
white-space: pre;
}
}
}
.line-numbers {
padding: 10px;
text-align: right;
float: left;
border-bottom-left-radius: $border-radius-default;
a {
font-family: $monospace-font;
display: block;
font-size: $code-font-size !important;
min-height: 1.5em;
white-space: nowrap;
i {
float: left;
margin-top: 3px;
margin-right: 5px;
visibility: hidden;
}
&:hover,
&:focus {
outline: none;
i {
visibility: visible;
}
}
}
}
}
// Vertically aligns <table> line numbers (eg. blame view)
// see https://gitlab.com/gitlab-org/gitlab-ce/issues/54048
td.line-numbers {
line-height: 1;
}