Permalink
Browse files

Protect root against system color schemes

System color schemes (in particular, custom themes in Windows and Linux
distros) affect Firefox, IE, and Opera. Normalizing the web site/app's
root background and text color prevents these unwanted settings from
being used. Chrome doesn't apply system-level schemes to websites.

Fix gh-170
  • Loading branch information...
necolas committed Apr 1, 2013
1 parent 8a925e0 commit 907890983eb2d6667e4b9cbd8bd03ead4b077e34
Showing with 14 additions and 5 deletions.
  1. +3 −0 CHANGELOG.md
  2. +11 −5 normalize.css
@@ -1,5 +1,8 @@
== HEAD

* Normalize root `color` and `background` to counter the affects of system

This comment has been minimized.

@XhmikosR

XhmikosR Apr 1, 2013

Shouldn't this be "effects"?

This comment has been minimized.

@leeoniya

This comment has been minimized.

@ProgerXP
color schemes.

== 2.1.0 (January 21, 2013)

* Normalize `text-transform` for `button` and `select`.
@@ -56,15 +56,21 @@ audio:not([controls]) {
========================================================================== */

/**
* 1. Set default font family to sans-serif.
* 2. Prevent iOS text size adjust after orientation change, without disabling
* 1. Prevent system color scheme's background color being used in Firefox, IE,
* and Opera.
* 2. Prevent system color scheme's text color being used in Firefox, IE, and
* Opera.
* 3. Set default font family to sans-serif.
* 4. Prevent iOS text size adjust after orientation change, without disabling
* user zoom.
*/

html {
font-family: sans-serif; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
-ms-text-size-adjust: 100%; /* 2 */
background: #fff; /* 1 */

This comment has been minimized.

@mathiasbynens

mathiasbynens Apr 10, 2013

Contributor

This also avoids this horrible Windows Phone bug: http://nerd.vasilis.nl/alpha-channel-opacity-on-body-background/

color: #000; /* 2 */
font-family: sans-serif; /* 3 */
-ms-text-size-adjust: 100%; /* 4 */
-webkit-text-size-adjust: 100%; /* 4 */
}

/**

0 comments on commit 9078909

Please sign in to comment.