Skip to content

Commit

Permalink
Clean up comments in Sass partials
Browse files Browse the repository at this point in the history
  • Loading branch information
mmistakes authored and Tamas K Lengyel committed Feb 8, 2015
1 parent f6c6028 commit dd7067b
Show file tree
Hide file tree
Showing 9 changed files with 480 additions and 211 deletions.
6 changes: 5 additions & 1 deletion _sass/coderay.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
/* ==========================================================================
Coderay syntax highlighting
========================================================================== */

.CodeRay {
background-color: #efefef;
font-family: $code-font;
Expand Down Expand Up @@ -130,4 +134,4 @@ ol.CodeRay li { white-space: pre }
.CodeRay .insert .insert { color: #080; font-weight:bold }
.CodeRay .delete .delete { color: #800; font-weight:bold }
.CodeRay .change .change { color: #66f; }
.CodeRay .head .head { color: #f4f; }
.CodeRay .head .head { color: #f4f; }
44 changes: 41 additions & 3 deletions _sass/elements.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
/*
Rules
========================================================================== */

hr {
display: block;
margin: 1em 0;
Expand All @@ -7,20 +11,29 @@ hr {
border-top: 1px solid #ccc;
border-bottom: 1px solid #fff;
}
/* Figures and images ==================================== */

/*
Figures and images
========================================================================== */

figure {
margin-bottom: $indent-var;
}

article img {
max-width: 100%;
height: auto;
border-width: 0;
vertical-align: middle;
-ms-interpolation-mode: bicubic;
}

svg:not(:root) {
overflow: hidden;
}

/* 2 images of equal dimensions in a row */

.half {
@include container;
@include clearfix;
Expand All @@ -33,6 +46,9 @@ svg:not(:root) {
}
}
}

/* 3 images of equal dimensions in a row */

.third {
@include container;
@include clearfix;
Expand All @@ -45,7 +61,13 @@ svg:not(:root) {
}
}
}
/* Buttons ============================================== */

/*
Buttons
========================================================================== */

/* Default button */

.btn {
display: inline-block;
margin-bottom: 20px;
Expand All @@ -68,6 +90,9 @@ svg:not(:root) {
color: $primary;
}
}

/* Success button */

.btn-success {
background-color: $success;
color: $white;
Expand All @@ -80,6 +105,9 @@ svg:not(:root) {
color: $success;
}
}

/* Warning button */

.btn-warning {
background-color: $warning;
color: $white;
Expand All @@ -92,6 +120,9 @@ svg:not(:root) {
color: $warning;
}
}

/* Danger button */

.btn-danger {
background-color: $danger;
color: $white;
Expand All @@ -104,6 +135,9 @@ svg:not(:root) {
color: $danger;
}
}

/* Information button */

.btn-info {
background-color: $info;
color: $white;
Expand All @@ -116,7 +150,11 @@ svg:not(:root) {
color: $info;
}
}
/* Well ================================================= */

/*
Wells
========================================================================== */

.well {
min-height: 20px;
padding: 19px;
Expand Down
36 changes: 30 additions & 6 deletions _sass/forms.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
/* ==========================================================================
Forms
========================================================================== */

btnform {
margin: 0 0 5px 0;
fieldset {
Expand Down Expand Up @@ -158,7 +162,11 @@ input[type="hidden"] {
.checkbox.inline + .checkbox.inline {
margin-left : 10px;
}
/* disabled ==================================== */

/*
Disabled state
========================================================================== */

input[disabled],
select[disabled],
textarea[disabled],
Expand All @@ -168,7 +176,11 @@ textarea[readonly] {
@include opacity(.5);
cursor : not-allowed;
}
/* focus and active ============================ */

/*
Focus & active state
========================================================================== */

input:focus,
textarea:focus {
border-color : $accentcolor;
Expand All @@ -181,7 +193,11 @@ input[type="checkbox"]:focus,
select:focus {
@include box-shadow(none);
}
/* help text ==================================== */

/*
Help text
========================================================================== */

.help-block,
.help-inline {
color : lighten($black, 50);
Expand All @@ -196,7 +212,11 @@ select:focus {
vertical-align : middle;
padding-left : 5px;
}
/* .form-inline ================================= */

/*
.form-inline
========================================================================== */

.form-inline input,
.form-inline textarea,
.form-inline select {
Expand All @@ -218,7 +238,11 @@ select:focus {
float : left;
margin-left : 0;
margin-right : 3px; }
/* .form-search ================================= */

/*
.form-search
========================================================================== */

.form-search input,
.form-search textarea,
.form-search select {
Expand Down Expand Up @@ -246,4 +270,4 @@ select:focus {
float : left;
margin-left : 0;
margin-right : 3px;
}
}
61 changes: 49 additions & 12 deletions _sass/grid.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
// Defining number of columns in the grid.
// Common Values would be 12, 16 or 24
/* ==========================================================================
Grid mixins
========================================================================== */

/*
Define number of columns in the grid
Common values would be 12, 16 or 24
========================================================================== */

$width: 100%;
$def_grid: 12;
$margin: 0;
Expand All @@ -8,40 +15,70 @@ $margin: 0;
margin:0 auto;
width:$width;
}

// Works out the width of elements based
// on total number of columns and width
// number of columns being displayed.
// Removes 20px for margins

/*
Works out the width of elements based on total number of columns and width
number of columns being displayed. Removes 20px for margins.
========================================================================== */

@mixin grid($grid:$def_grid,$cols:'',$float:left,$display:inline){
display:$display;
float:$float;
width:(100%/$grid * $cols) - ($margin * 2);
}

// Allows for padding before element
/*
Add x amount of column padding before an element
Example: @include prefix(1,12);
========================================================================== */

@mixin prefix($grid:$def_grid,$cols:''){
margin-left:(100%/$grid * $cols);
}
// Allows for padding after element

/*
Add x amount of column padding after an element
Example: @include suffix(2,12);
========================================================================== */

@mixin suffix($grid:$def_grid,$cols:''){
margin-right:(100%/$grid * $cols);
}
// Removes left margin

/*
Remove left margin
Example: @include first;
========================================================================== */

@mixin first(){
margin-left:0;
}
// Removes right margin

/*
Remove right margin
Example: @include last;
========================================================================== */

@mixin last(){
margin-right:0;
}

/*
Push an element x amount of column(s) to the right
Example: @include push(2,12);
========================================================================== */

@mixin push($grid:$def_grid,$move:'') {
position:relative;
left:(100%/$grid * $move);
}

/*
Pull an element x amount of column(s) to the left
Example: @include pull(1,12);
========================================================================== */

@mixin pull($grid:$def_grid,$move:''){
position:relative;
left:(100%/$grid * $move) * -1;
}
}
Loading

0 comments on commit dd7067b

Please sign in to comment.