gitlab-org--gitlab-foss/app/assets/stylesheets/framework/typography.scss

283 lines
4.1 KiB
SCSS
Raw Normal View History

@mixin md-typography {
color: $md-text-color;
word-wrap: break-word;
a {
color: $md-link-color;
}
img {
max-width: 100%;
}
*:first-child {
margin-top: 0;
}
// Single code lines should wrap
code {
font-family: $monospace_font;
white-space: pre-wrap;
word-wrap: normal;
}
// Multi-line code blocks should scroll horizontally
pre {
code {
white-space: pre;
}
}
kbd {
display: inline-block;
padding: 3px 5px;
font-size: 11px;
line-height: 10px;
color: #555;
vertical-align: middle;
background-color: #fcfcfc;
border-width: 1px;
border-style: solid;
border-color: #ccc #ccc #bbb;
border-image: none;
border-radius: 3px;
box-shadow: 0 -1px 0 #bbb inset;
}
h1 {
font-size: 2em;
font-weight: 600;
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
padding: 0 0 0.3em;
border-bottom: 1px solid $btn-default-border;
2016-04-25 20:02:15 +00:00
color: $gl-gray-dark;
}
h2 {
font-size: 1.6em;
font-weight: 600;
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
padding-bottom: 0.3em;
border-bottom: 1px solid $btn-default-border;
2016-04-25 20:02:15 +00:00
color: $gl-gray-dark;
}
h3 {
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
font-size: 1.4em;
}
h4 {
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
font-size: 1.25em;
}
h5 {
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
font-size: 1em;
}
h6 {
2016-06-28 16:36:41 +00:00
margin: 1em 0 10px;
font-size: 0.95em;
}
blockquote {
color: #7f8fa4;
font-size: inherit;
padding: 8px 21px;
margin: 12px 0;
border-left: 3px solid #e7e9ed;
}
blockquote p {
color: #7f8fa4 !important;
font-size: inherit;
line-height: 1.5;
}
p {
2016-01-25 10:42:47 +00:00
color: #5c5d5e;
margin: 6px 0 0;
}
table {
@extend .table;
@extend .table-bordered;
margin: 12px 0;
color: #5c5d5e;
th {
background: #f8fafc;
}
}
pre {
margin: 12px 0;
2016-01-25 10:42:47 +00:00
font-size: 13px;
line-height: 1.6em;
overflow-x: auto;
2016-09-09 16:59:36 +00:00
border-radius: 2px;
}
p > code {
font-weight: inherit;
}
ul, ol {
padding: 0;
2016-06-28 16:36:41 +00:00
margin: 3px 0 3px 28px !important;
}
li {
line-height: 1.6em;
}
a[href*="/uploads/"], a[href*="storage.googleapis.com/google-code-attachments/"] {
&:before {
margin-right: 4px;
font: normal normal normal 14px/1 FontAwesome;
font-size: inherit;
text-rendering: auto;
-webkit-font-smoothing: antialiased;
content: "\f0c6";
}
&:hover:before {
text-decoration: none;
}
}
a.no-attachment-icon {
&:before {
display: none;
}
}
/* Link to current header. */
h1, h2, h3, h4, h5, h6 {
position: relative;
a.anchor {
2016-07-30 19:23:46 +00:00
left: -16px;
position: absolute;
text-decoration: none;
&:after {
content: image-url('icon_anchor.svg');
2016-07-30 19:23:46 +00:00
visibility: hidden;
}
}
2016-07-30 19:23:46 +00:00
&:hover > a.anchor:after {
visibility: visible;
}
}
}
/**
* Headers
*
*/
body {
-webkit-text-shadow: rgba(255,255,255,0.01) 0 0 1px;
}
2015-03-07 04:02:34 +00:00
.page-title {
margin-top: $gl-padding;
line-height: 1.3;
font-size: 1.25em;
font-weight: 600;
2015-12-02 13:43:23 +00:00
&:last-child {
margin-bottom: 0;
}
2015-09-28 15:58:30 +00:00
}
.page-title-empty {
margin-top: 0;
2015-09-28 15:58:30 +00:00
line-height: 1.3;
font-size: 1.25em;
font-weight: 600;
margin: 12px 7px;
}
h1, h2, h3, h4, h5, h6 {
2016-09-08 21:38:14 +00:00
color: $gl-title-color;
2016-03-02 10:28:17 +00:00
font-weight: 600;
}
.light-header {
font-weight: 600;
}
/** CODE **/
pre {
font-family: $monospace_font;
&.plain-readme {
background: none;
border: none;
padding: 0;
margin: 0;
font-size: 14px;
}
}
2012-11-23 04:24:09 +00:00
.monospace {
font-family: $monospace_font;
font-size: 90%;
2012-11-23 04:24:09 +00:00
}
2013-01-10 16:09:12 +00:00
code {
&.key-fingerprint {
background: $body-bg;
color: $text-color;
}
}
a > code {
color: $link-color;
}
2013-01-10 16:09:12 +00:00
/**
* Apply Markdown typography
2013-01-10 16:09:12 +00:00
*
*/
.wiki {
2013-03-04 19:34:26 +00:00
@include md-typography;
2013-01-10 16:09:12 +00:00
}
2013-03-04 20:00:51 +00:00
.md {
@include md-typography;
}
/**
* Textareas intended for GFM
*
*/
2014-11-05 20:45:18 +00:00
.strikethrough {
text-decoration: line-through;
}
h1, h2, h3, h4 {
small {
color: $gl-gray;
}
}
.text-right-lg {
@media (min-width: $screen-lg-min) {
text-align: right;
}
}
.idiff.deletion {
background: $line-removed-dark;
}
.idiff.addition {
background: $line-added-dark;
}