Last active
August 29, 2015 13:56
-
-
Save chrisdpeters/9277386 to your computer and use it in GitHub Desktop.
Sass & CSS Style Guide
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
body { | |
padding: 0; | |
margin: 0; | |
background: #f5f5f5; | |
line-height: 1.2; | |
} | |
// Preferred | |
body { | |
background: #f5f5f5; | |
line-height: 1.2; | |
margin: 0; | |
padding: 0; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Fonts | |
// | |
@import "vendor/font-awesome"; | |
// | |
// Settings | |
// | |
@import "settings"; | |
// | |
// Vendor dependencies | |
// | |
@import "bower_components/bootstrap-sass/assets/stylesheets/bootstrap"; // Or whatever | |
// | |
// Bases | |
// | |
@import "bases/elements"; | |
// | |
// Layouts | |
// | |
@import "layouts"; | |
// | |
// Modules | |
// | |
@import "modules/headers", | |
"modules/global-navs", | |
"modules/footers"; | |
// | |
// Non-modular | |
// | |
@import "non-modular/home"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.breadcrumbs{ | |
font-size: rem-calc(13); | |
} | |
// Preferred | |
.breadcrumbs { | |
font-size: rem-calc(13); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.global-navigation { | |
background: rgb(56, 128, 45); | |
color: #55bb00; | |
} | |
// Preferred | |
.global-navigation { | |
background: #123456; | |
color: #5b0; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.local_navigation {} | |
.localnavigation {} | |
.localNavigation {} | |
// Preferred | |
.local-navigation {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.profile { | |
background: #dedede; | |
color: #3a3a3a; | |
@include border-radius(rem-calc(5)); | |
@extend .halo; | |
} | |
// Preferred | |
.profile { | |
@include border-radius(rem-calc(5)); | |
@extend .halo; | |
background: #dedede; | |
color: #3a3a3a; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
color: #E5E5E5; | |
// Preferred | |
color: #e5e5e5; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.profile { | |
background: #dedede; | |
color: #3a3a3a; | |
.heading { | |
font-size: rem-calc(18); | |
a { | |
color: #00f; | |
&:hover { | |
color: lighten(#00f, 10%); | |
i { | |
line-height: 1; | |
} | |
} | |
} | |
} | |
} | |
// Preferred | |
.profile { | |
background: #dedede; | |
color: #3a3a3a; | |
} | |
.profile-heading { | |
font-size: rem-calc(18); | |
} | |
.profile-link { | |
color: #00f; | |
&:hover { | |
color: lighten(#00f, 10%); | |
i { | |
line-height: 1; | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.footer { | |
background:firebrick; | |
} | |
// Preferred | |
.footer { | |
background: firebrick; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.sidebar { | |
border: 1px solid #ccc; | |
margin: 5px 0 10px; | |
} | |
// Preferred | |
.sidebar { | |
border: rem-calc(1) solid #ccc; | |
margin: rem-calc(5 0 10); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.sosume { | |
color: #ccc; | |
font-size: rem-calc(11); | |
} | |
// Preferred | |
.sosume { | |
color: #ccc; | |
font-size: rem-calc(11); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Not recommended | |
.header { | |
background: #eee;_____ | |
} | |
// Preferred | |
.header { | |
background: #eee; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.l-two-columns { | |
@include grid-row; | |
} | |
.l-two-columns-content, | |
.l-two-columns-sidebar { | |
@include grid-column(12); | |
} | |
@media #{$large-up} { | |
.l-two-columns-content { | |
@include grid-column(9); | |
} | |
.l-two-columns-sidebar { | |
@include grid-column(3); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment