1
1
mirror of https://github.com/primer/css.git synced 2024-12-26 07:35:04 +03:00
css/scss/_utility.scss

85 lines
1.3 KiB
SCSS
Raw Normal View History

// Clear floats
.clearfix {
@include clearfix;
}
// Floats
.right { float: right; }
.left { float: left; }
// Layout
// Centers content horizontally. Can be used inside or outside the grid.
.centered {
display: block;
float: none;
margin-left: auto;
margin-right: auto;
}
// Text alignment
.text-right { text-align: right; }
.text-left { text-align: left; }
// Text states
.danger { color: #c00; }
.mute { color: #000; }
.text-diff-added { color: darken($brand-green, 10%); }
.text-diff-deleted { color: $brand-red; }
.text-open,
.text-success { color: $status-open; }
.text-closed { color: $status-closed; }
.text-reverted { color: $status-reverted; }
.text-merged { color: $status-merged; }
.text-renamed { color: $status-renamed; }
.text-pending { color: $status-pending; }
.text-error,
.text-failure { color: $brand-red; }
// Muted link
//
// Have a link you need to be gray to start, and blue on hover? Use this.
.muted-link {
2015-05-29 13:59:52 +03:00
color: $brand-gray;
&:hover {
color: $brand-blue;
text-decoration: none;
}
}
// Misc
.hidden {
display: none;
}
.warning {
padding: 0.5em;
margin-bottom: 0.8em;
font-weight: bold;
background-color: #fffccc;
}
.error_box {
padding: 1em;
font-weight: bold;
background-color: #ffebe8;
border: 1px solid #dd3c10;
}