ericam/susy — pull request #189 by Hannes-III (2013-05-23 13:28:36+00:00)
Title: New approach for clean IE only css

I am using SASS/compass/SUSY to create to two completely different .css files which I include using IE conditional comments like

The two different .css are created by two wrapper SASS files that set the according $breakpoint-xxx variables and import the Stylesheet.

All methods that I have found in the at-breakpoint functionality had some drawbacks in creating a clean CSS.

$breakpoint-raw-output: too big CSS a lot of unnecessary information uncontrollable which breakpoint will be displayed at the end.

$breakpoint-ie-output: quite good, but I would have to add a class to my Body object just to activate the rules prefixed by that class.
Yes, I could place that Class permanently. The CSS For that class would not get generated in my all.css file because I would set $breakpoint-ie-output:false in the Wrapper.
This is the nearest to perfect solution, but not verry clean.

My approach intorduces a new $breakpoint-xxx variable
$breakpoint-include-ie-classes [list | boolean ] : false !default;

If set it acts like $breakpoint-raw-output but includes only at-breakpoint content that has fallback support for IE activated by setting it to true or giving it a className.

-) if set to false or an empty list nothing will happen (Default)
-) if set to true, it will rawly include content of every at-breakpoint where $ie is set.
-) if set to list with entries, it will rawly include content of every at-breakpoint where
$ie is set but only if the value of $ie matches an element of the list.
If $ie is set to true, the default name 'lt-ie9' (See value of $default-IE-fallback-class) is assumed.

By this approach it is possible to create a clean IE css. Yes, it will have all the Mobile First settings in it and will override them later, but this is much less overhead, than having all unnecessary @media statements in it.

Please have a look at the changes.
I hope you will include it into the master branch, tell me if you will, I can add some comments to the Documentation so that everything is Documentet too. Or need some test cases I could write them too.

But also tell me if this will never make its way into the branch.

This is the first time that I commit somthing usin GIT if I do soemthing wrong please let me know.

regards, Hannes