From 8e038c2210d8e85d51db7d9d0a787bb4fa4bfa8d Mon Sep 17 00:00:00 2001 From: raphaelgoettter Date: Wed, 4 Mar 2015 14:58:29 +0100 Subject: [PATCH] =?UTF-8?q?meilleure=20int=C3=A9gration=20de=20box-sizing?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit /* switching to border-box model for all elements */ html { box-sizing: border-box; } * { box-sizing: inherit; } --- less/_01-base.less | 14 +++++++++++--- sass/_01-base.scss | 14 +++++++++++--- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/less/_01-base.less b/less/_01-base.less index 0411b3f..21f51b3 100644 --- a/less/_01-base.less +++ b/less/_01-base.less @@ -7,11 +7,15 @@ /* == soft reset */ /* ----------------------------- */ -/* switching box model for all elements */ -* { +/* switching to border-box model for all elements */ +html { box-sizing: border-box; } +* { + box-sizing: inherit; +} + /* soft reset */ html, body { @@ -29,11 +33,15 @@ ul.unstyled { } img { - height: auto; vertical-align: middle; border: 0; } +/* height auto only for non SVG images */ +img:not([src$=".svg"]) { + height: auto; +} + blockquote, figure { margin-left: 0; diff --git a/sass/_01-base.scss b/sass/_01-base.scss index c734187..9f397fd 100644 --- a/sass/_01-base.scss +++ b/sass/_01-base.scss @@ -7,11 +7,15 @@ /* == soft reset */ /* ----------------------------- */ -/* switching box model for all elements */ -* { +/* switching to border-box model for all elements */ +html { box-sizing: border-box; } +* { + box-sizing: inherit; +} + /* soft reset */ html, body { @@ -29,11 +33,15 @@ ul.unstyled { } img { - height: auto; vertical-align: middle; border: 0; } +/* height auto only for non SVG images */ +img:not([src$=".svg"]) { + height: auto; +} + blockquote, figure { margin-left: 0;