From 15e7c50efe80f9d6b3028fb1aa04b568955ed9a8 Mon Sep 17 00:00:00 2001 From: necolas Date: Wed, 1 Jun 2011 19:24:02 +0100 Subject: [PATCH] Update normalize.css and demo.html from master --- demo.html | 2 +- normalize.css | 182 ++++++++++++++++++++++++++++---------------------- 2 files changed, 105 insertions(+), 79 deletions(-) diff --git a/demo.html b/demo.html index 142a04c..a536f7f 100644 --- a/demo.html +++ b/demo.html @@ -2,7 +2,7 @@ - + Normalize CSS diff --git a/normalize.css b/normalize.css index bfe564f..6c84bfa 100644 --- a/normalize.css +++ b/normalize.css @@ -1,8 +1,10 @@ -/* ============================================================================================================= HTML5 ELEMENT DISPLAY */ +/* ============================================================================= + HTML5 element display + ========================================================================== */ /* * Add display for block-level HTML5 elements - * Display not defined in IE6/7/8/9 & FF3 + * Addresses display not defined in IE6/7/8/9 & FF3 */ article, @@ -20,7 +22,7 @@ section { /* * Add display for embedded HTML5 elements - * Display not defined in IE6/7/8/9 & FF3 + * Addresses display not defined in IE6/7/8/9 & FF3 */ audio[controls], @@ -32,55 +34,58 @@ video { } -/* ============================================================================================================= BASE STYLES & FIXES */ +/* ============================================================================= + Base + ========================================================================== */ /* - * 1. Add vertical scrollbar to element - * Keeps page centred in all browsers regardless of content height - * 2. Remove Android and iOS tap highlight color to prevent entire container being highlighted - * www.yuiblog.com/blog/2010/10/01/quick-tip-customizing-the-mobile-safari-tap-highlight-color/ - * 3. Remove iOS text size adjust without disabling user zoom - * www.456bereastreet.com/archive/201012/controlling_text_size_in_safari_for_ios_without_disabling_user_zoom/ + * 1. Add font size + * Addresses text resizing oddly in IE6/7 when body font-size is set using em units + * http://clagnut.com/blog/348/#c790 + * 2. Add vertical scrollbar + * Keeps page centred in all browsers regardless of content height + * 3. Remove Android and iOS tap highlight color to prevent entire container being highlighted + * www.yuiblog.com/blog/2010/10/01/quick-tip-customizing-the-mobile-safari-tap-highlight-color/ + * 4. Remove iOS text size adjust without disabling user zoom + * www.456bereastreet.com/archive/201012/controlling_text_size_in_safari_for_ios_without_disabling_user_zoom/ */ html { - overflow-y: scroll; /* 1 */ - -webkit-tap-highlight-color: rgba(0,0,0,0); /* 2 */ - -webkit-text-size-adjust: 100%; /* 3 */ - -ms-text-size-adjust: 100%; + font-size: 100%; /* 1 */ + overflow-y: scroll; /* 2 */ + -webkit-tap-highlight-color: rgba(0,0,0,0); /* 3 */ + -webkit-text-size-adjust: 100%; /* 4 */ + -ms-text-size-adjust: 100%; /* 4 */ } /* - * 1. Define the base font-size of choice; set in % or em to retain text resizing in IE6/7 - * 2. Define the base line-height of choice. - * 3. Remove margin from element + * Remove margin + * Addresses margins handled incorrectly in IE6/7 */ body { - font-size: 100%; /* 1 */ - line-height: normal; /* 2 */ - margin: 0; /* 3 */ + margin: 0; } /* - * Define the base font-family and text color for and form elements - * Fixes font-family inconsistency between