Skip to content

Instantly share code, notes, and snippets.

@sta1r
Last active October 7, 2015 01:17
Show Gist options
  • Select an option

  • Save sta1r/3082457 to your computer and use it in GitHub Desktop.

Select an option

Save sta1r/3082457 to your computer and use it in GitHub Desktop.
A more useful utilities sass file for inclusion in projects.
// UTILITY CLASSES
// ---------------
// Positioning
.relative {
position: relative;
}
.affix {
position: fixed;
}
// Quick floats
.pull-right {
float: right;
}
.pull-left {
float: left;
}
.full-width {
float: left;
width: 100%;
}
// Centering text and center-aligning elements
.centered {
text-align: center;
}
.alignright {
text-align: right;
}
.alignleft {
text-align: left;
}
.aligncenter {
margin: 0 auto;
}
// Quick margins
.add-top {
margin-top: 20px;
}
.add-bottom {
margin-bottom: 20px;
}
// Toggling content
.hide {
display: none;
}
.show {
display: block;
}
// Visibility
.invisible {
visibility: hidden;
}
// Formatting
.no-bullet {
list-style: none;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment