From be321d07d16173dac7a0cbc43dd128e8ef5a859b Mon Sep 17 00:00:00 2001 From: Shankar Date: Tue, 17 May 2016 19:24:30 +0530 Subject: [PATCH 1/3] Added SASS version [base] --- grid.scss | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 grid.scss diff --git a/grid.scss b/grid.scss new file mode 100644 index 0000000..be11a79 --- /dev/null +++ b/grid.scss @@ -0,0 +1,96 @@ +@import url(https://fonts.googleapis.com/css?family=Lato:400,300,300italic,400italic,700,700italic); + +// fonts +$font-family: 'Lato', Helvetica, sans-serif; +$font-weight-light: 200; +$font-weight-regular: 400; +$font-weight-heavy: 700; + +// colors +$primary: #FBCED1; +$border-color: #FE7880; + +// grid +$grid-spacing: 4%; +$width: 96%; + + +* { + font-family: $font-family ; + color: #333447; + line-height: 1.5; +} +.row { + position: relative; + width: 100%; +} + +.container { + width: 90%; + margin: 0 auto; +} + +//----- Columns (Automatic) +.col-1 { width:($width / 12) - ($grid-spacing * 11 / 12); } +.col-2 { width:($width / 6) - ($grid-spacing * 10 / 12); } +.col-3 { width:($width / 4) - ($grid-spacing * 9 / 12); } +.col-4 { width:($width / 3) - ($grid-spacing * 8 / 12); } +.col-5 { width:($width / 2.4) - ($grid-spacing * 7 / 12); } +.col-6 { width:($width / 2) - ($grid-spacing * 6 / 12); } +.col-7 { width:($width / 1.714285714285714) - ($grid-spacing * 5 / 12); } +.col-8 { width:($width / 1.5) - ($grid-spacing * 4 / 12); } +.col-9 { width:($width / 1.333333333333333) - ($grid-spacing * 3 / 12); } +.col-10 { width:($width / 1.2) - ($grid-spacing * 2 / 12); } +.col-11 { width:($width / 1.090909090909091) - ($grid-spacing * 1 / 12); } +.col-12 { width:$width; } + + +[class^="col-"] { + float:left; + margin:8px 2%; + box-sizing:border-box; + background: $primary; + border: 1px solid $border-color; + border-radius: 4px; + text-align: center; + &:last-child { + margin-right:0%; + } +} + +//----- font +.font-light { + font-weight: $font-weight-light; +} + +.font-regular { + font-weight: $font-weight-regular; +} + +.font-heavy { + font-weight: $font-weight-heavy; +} + +.ell { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.break-word { word-wrap: break-word; } +.no-wrap { white-space: nowrap; } + + +// utilities +.f-left { + float: left; +} +.f-right { + float: right; +} +.clearfix { + display: block; +} +.hidden { + visibility: hidden; +} From 958b2d97965079605f0fd6a8fe04a414003394ca Mon Sep 17 00:00:00 2001 From: Shankar Date: Mon, 23 May 2016 11:22:50 +0530 Subject: [PATCH 2/3] fixed sass to enable/disable text styles [issue 8] --- grid.scss | 96 ------------------------------------------------------- 1 file changed, 96 deletions(-) delete mode 100644 grid.scss diff --git a/grid.scss b/grid.scss deleted file mode 100644 index be11a79..0000000 --- a/grid.scss +++ /dev/null @@ -1,96 +0,0 @@ -@import url(https://fonts.googleapis.com/css?family=Lato:400,300,300italic,400italic,700,700italic); - -// fonts -$font-family: 'Lato', Helvetica, sans-serif; -$font-weight-light: 200; -$font-weight-regular: 400; -$font-weight-heavy: 700; - -// colors -$primary: #FBCED1; -$border-color: #FE7880; - -// grid -$grid-spacing: 4%; -$width: 96%; - - -* { - font-family: $font-family ; - color: #333447; - line-height: 1.5; -} -.row { - position: relative; - width: 100%; -} - -.container { - width: 90%; - margin: 0 auto; -} - -//----- Columns (Automatic) -.col-1 { width:($width / 12) - ($grid-spacing * 11 / 12); } -.col-2 { width:($width / 6) - ($grid-spacing * 10 / 12); } -.col-3 { width:($width / 4) - ($grid-spacing * 9 / 12); } -.col-4 { width:($width / 3) - ($grid-spacing * 8 / 12); } -.col-5 { width:($width / 2.4) - ($grid-spacing * 7 / 12); } -.col-6 { width:($width / 2) - ($grid-spacing * 6 / 12); } -.col-7 { width:($width / 1.714285714285714) - ($grid-spacing * 5 / 12); } -.col-8 { width:($width / 1.5) - ($grid-spacing * 4 / 12); } -.col-9 { width:($width / 1.333333333333333) - ($grid-spacing * 3 / 12); } -.col-10 { width:($width / 1.2) - ($grid-spacing * 2 / 12); } -.col-11 { width:($width / 1.090909090909091) - ($grid-spacing * 1 / 12); } -.col-12 { width:$width; } - - -[class^="col-"] { - float:left; - margin:8px 2%; - box-sizing:border-box; - background: $primary; - border: 1px solid $border-color; - border-radius: 4px; - text-align: center; - &:last-child { - margin-right:0%; - } -} - -//----- font -.font-light { - font-weight: $font-weight-light; -} - -.font-regular { - font-weight: $font-weight-regular; -} - -.font-heavy { - font-weight: $font-weight-heavy; -} - -.ell { - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} - -.break-word { word-wrap: break-word; } -.no-wrap { white-space: nowrap; } - - -// utilities -.f-left { - float: left; -} -.f-right { - float: right; -} -.clearfix { - display: block; -} -.hidden { - visibility: hidden; -} From ddd98d400bcb1643e9f812e47f1493855116326d Mon Sep 17 00:00:00 2001 From: Shankar Date: Mon, 23 May 2016 11:38:27 +0530 Subject: [PATCH 3/3] fixed merge issues --- sass/_grid.scss | 46 +++++++++++++++++++++++++++++++++++++++ sass/_typography.scss | 50 +++++++++++++++++++++++++++++++++++++++++++ sass/_utilities.scss | 14 ++++++++++++ style.scss | 4 ++++ 4 files changed, 114 insertions(+) create mode 100644 sass/_grid.scss create mode 100644 sass/_typography.scss create mode 100644 sass/_utilities.scss create mode 100644 style.scss diff --git a/sass/_grid.scss b/sass/_grid.scss new file mode 100644 index 0000000..8a9efed --- /dev/null +++ b/sass/_grid.scss @@ -0,0 +1,46 @@ + +// colors +$primary: #FBCED1; +$border-color: #FE7880; + +// grid +$grid-spacing: 4%; +$width: 96%; + +.row { + position: relative; + width: 100%; +} + +.container { + width: 90%; + margin: 0 auto; +} + +//----- Columns (Automatic) +.col-1 { width:($width / 12) - ($grid-spacing * 11 / 12); } +.col-2 { width:($width / 6) - ($grid-spacing * 10 / 12); } +.col-3 { width:($width / 4) - ($grid-spacing * 9 / 12); } +.col-4 { width:($width / 3) - ($grid-spacing * 8 / 12); } +.col-5 { width:($width / 2.4) - ($grid-spacing * 7 / 12); } +.col-6 { width:($width / 2) - ($grid-spacing * 6 / 12); } +.col-7 { width:($width / 1.714285714285714) - ($grid-spacing * 5 / 12); } +.col-8 { width:($width / 1.5) - ($grid-spacing * 4 / 12); } +.col-9 { width:($width / 1.333333333333333) - ($grid-spacing * 3 / 12); } +.col-10 { width:($width / 1.2) - ($grid-spacing * 2 / 12); } +.col-11 { width:($width / 1.090909090909091) - ($grid-spacing * 1 / 12); } +.col-12 { width:$width; } + + +[class^="col-"] { + float:left; + margin:8px 2%; + box-sizing:border-box; + background: $primary; + border: 1px solid $border-color; + border-radius: 4px; + text-align: center; + &:last-child { + margin-right:0%; + } +} diff --git a/sass/_typography.scss b/sass/_typography.scss new file mode 100644 index 0000000..0a4bed8 --- /dev/null +++ b/sass/_typography.scss @@ -0,0 +1,50 @@ +@import url(https://fonts.googleapis.com/css?family=Lato:400,300,300italic,400italic,700,700italic); +// fonts +$font-family: 'Lato', Helvetica, sans-serif; +$font-weight-light: 200; +$font-weight-regular: 400; +$font-weight-heavy: 700; +$line-height: 1.5; + +* { + font-family: $font-family ; + color: #333447; + line-height: $line-height; +} + +/* TYPOGRAPHY */ +$start: 2.5rem; +@each $h in h1, h2, h3, h4, h5, h6{ + #{$h} { + font-size: $start; + } + + $start: $start - 0.125; + } + +p { + font-size: 1.125rem; + font-weight: 200; + line-height: 1.8; +} + +.font-light { + font-weight: $font-weight-light; +} + +.font-regular { + font-weight: $font-weight-regular; +} + +.font-heavy { + font-weight: $font-weight-heavy; +} + +.ell { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.break-word { word-wrap: break-word; } +.no-wrap { white-space: nowrap; } diff --git a/sass/_utilities.scss b/sass/_utilities.scss new file mode 100644 index 0000000..532d4b6 --- /dev/null +++ b/sass/_utilities.scss @@ -0,0 +1,14 @@ + +// utilities +.f-left { + float: left; +} +.f-right { + float: right; +} +.clearfix { + display: block; +} +.hidden { + visibility: hidden; +} diff --git a/style.scss b/style.scss new file mode 100644 index 0000000..8780b69 --- /dev/null +++ b/style.scss @@ -0,0 +1,4 @@ +@import "sass/_grid.scss"; +@import "sass/_utilities.scss"; +// Remove this line for a text-style-free version +@import "sass/_typography.scss";