From c055a499c470d71bad07e642b68cc3015e10ad39 Mon Sep 17 00:00:00 2001 From: raphaelgoettter Date: Wed, 4 Mar 2015 16:45:30 +0100 Subject: [PATCH] Refonte des nommages de positionnement MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit .left, .start, .fl WARNING : encore à méditer --- less/_01-base.less | 110 +++++++++++++++++++---------------------- less/_11-styling.less | 4 +- sass/_01-base.scss | 112 +++++++++++++++++++----------------------- 3 files changed, 102 insertions(+), 124 deletions(-) diff --git a/less/_01-base.less b/less/_01-base.less index 81777ec..3194abc 100644 --- a/less/_01-base.less +++ b/less/_01-base.less @@ -287,7 +287,56 @@ table { /* ==layout and modules */ /* ----------------------------- */ -/* float layout */ +/* simple blocks alignment */ +.left { + margin-right: auto; +} + +.right { + margin-left: auto; +} + +.center { + margin-left: auto; + margin-right: auto; +} + +/* text and contents alignment */ +.txtleft { + text-align: left; +} + +.txtright { + text-align: right; +} + +.txtcenter { + text-align: center; +} + +/* floating elements */ +.fl { + float: left; +} + +img.fl { + margin-right: @small-value; +} + +.fr { + float: right; +} + +img.fr { + margin-left: @small-value; +} + +img.fl, +img.fr { + margin-bottom: @tiny-value; +} + + /* module, gains superpower "BFC" Block Formating Context */ .mod { overflow: hidden; @@ -334,62 +383,3 @@ body > script { display: inline-block; vertical-align: top; } - -/* alignments (blocks and inline) */ -/* ------------------------------ */ - -/* blocks alignment */ -.left { - margin-right: auto; -} - -.right { - margin-left: auto; -} - -.center { - margin-left: auto; - margin-right: auto; -} - -/* text and contents alignment */ -.txtleft { - text-align: left; -} - -.txtright { - text-align: right; -} - -.txtcenter { - text-align: center; -} - -/* left (or starting) elements */ -.left, -.start { - float: left; -} - -img.left, -img.start { - margin-right: @small-value; -} - -/* right (or ending) elements */ -.right, -.end { - float: right; -} - -img.right, -img.end { - margin-left: @small-value; -} - -img.left, -img.right, -img.start, -img.end { - margin-bottom: @tiny-value; -} diff --git a/less/_11-styling.less b/less/_11-styling.less index 953e706..ec2980d 100644 --- a/less/_11-styling.less +++ b/less/_11-styling.less @@ -102,8 +102,8 @@ hr { border: 0; } -.table-alternate tbody { - border: 1px solid #ccc; +.table-alternate tbody { + border: 1px solid #ccc; } .table-alternate thead tr > * + * { diff --git a/sass/_01-base.scss b/sass/_01-base.scss index 20e3124..f95d393 100644 --- a/sass/_01-base.scss +++ b/sass/_01-base.scss @@ -276,12 +276,60 @@ table { margin-bottom: $medium-value; } - /* ----------------------------- */ /* ==layout and modules */ /* ----------------------------- */ -/* float layout */ +/* simple blocks alignment */ +.left { + margin-right: auto; +} + +.right { + margin-left: auto; +} + +.center { + margin-left: auto; + margin-right: auto; +} + +/* text and contents alignment */ +.txtleft { + text-align: left; +} + +.txtright { + text-align: right; +} + +.txtcenter { + text-align: center; +} + +/* floating elements */ +.fl { + float: left; +} + +img.fl { + margin-right: $small-value; +} + +.fr { + float: right; +} + +img.fr { + margin-left: $small-value; +} + +img.fl, +img.fr { + margin-bottom: $tiny-value; +} + + /* module, gains superpower "BFC" Block Formating Context */ .mod { overflow: hidden; @@ -328,63 +376,3 @@ body > script { display: inline-block; vertical-align: top; } - -/* alignments (blocks and inline) */ -/* ------------------------------ */ - -/* blocks alignment */ -.left { - margin-right: auto; -} - -.right { - margin-left: auto; -} - -.center { - margin-left: auto; - margin-right: auto; -} - -/* text and contents alignment */ -.txtleft { - text-align: left; -} - -.txtright { - text-align: right; -} - -.txtcenter { - text-align: center; -} - -/* left (or starting) elements */ -.left, -.start { - float: left; -} - -img.left, -img.start { - margin-right: $small-value; -} - -/* right (or ending) elements */ -.right, -.end { - float: right; -} - -img.right, -img.end { - margin-left: $small-value; -} - -img.left, -img.right, -img.start, -img.end { - margin-bottom: $tiny-value; -} -