Add an option to control Bootstrap reset output.

I'm pretty unfamiliar with the Bootstrap framework, so I'm following along with
the existing comments.

The goal here is to remove and CSS when a project is not using Bootstrap
already.
This commit is contained in:
Brian McAllister 2013-02-17 17:42:04 -05:00
parent c5998d9844
commit a6d69fb85b

View File

@ -36,9 +36,13 @@
Configuration. Configuration.
---------------------------------- */ ---------------------------------- */
/* Font Awesome. */
$font-awesome-path: '../font' !default; $font-awesome-path: '../font' !default;
$font-awesome-version: '3.0.2'; $font-awesome-version: '3.0.2';
/* Bootstrap. */
$font-awesome-using-bootstrap: true !default;
/* Colors. */ /* Colors. */
$font-awesome-border-color: #eee !default; $font-awesome-border-color: #eee !default;
$font-awesome-icon-muted: $font-awesome-border-color !default; $font-awesome-icon-muted: $font-awesome-border-color !default;
@ -71,8 +75,12 @@ $font-awesome-icon-muted: $font-awesome-border-color !default;
font-style: normal; font-style: normal;
} }
/* Font Awesome styles
------------------------------------------------------- */ /** ----------------------------------
Main Font Awesome styles.
---------------------------------- */
[class^="icon-"], [class^="icon-"],
[class*=" icon-"] { [class*=" icon-"] {
font-family: FontAwesome; font-family: FontAwesome;
@ -81,35 +89,44 @@ $font-awesome-icon-muted: $font-awesome-border-color !default;
text-decoration: inherit; text-decoration: inherit;
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
/* sprites.less reset */ /*
display: inline; Reset sprites.less.
width: auto; */
height: auto; @if $font-awesome-using-bootstrap {
line-height: normal; display: inline;
vertical-align: baseline; width: auto;
background-image: none; height: auto;
background-position: 0% 0%; line-height: normal;
background-repeat: repeat; vertical-align: baseline;
margin-top: 0; background-image: none;
background-position: 0% 0%;
background-repeat: repeat;
margin-top: 0;
}
} }
/* more sprites.less reset */ /*
.icon-white, Other Bootstrap sprites.less reset styles.
.nav-pills > .active > a > [class^="icon-"], */
.nav-pills > .active > a > [class*=" icon-"], @if $font-awesome-using-bootstrap {
.nav-list > .active > a > [class^="icon-"], .icon-white,
.nav-list > .active > a > [class*=" icon-"], .nav-pills > .active > a > [class^="icon-"],
.navbar-inverse .nav > .active > a > [class^="icon-"], .nav-pills > .active > a > [class*=" icon-"],
.navbar-inverse .nav > .active > a > [class*=" icon-"], .nav-list > .active > a > [class^="icon-"],
.dropdown-menu > li > a:hover > [class^="icon-"], .nav-list > .active > a > [class*=" icon-"],
.dropdown-menu > li > a:hover > [class*=" icon-"], .navbar-inverse .nav > .active > a > [class^="icon-"],
.dropdown-menu > .active > a > [class^="icon-"], .navbar-inverse .nav > .active > a > [class*=" icon-"],
.dropdown-menu > .active > a > [class*=" icon-"], .dropdown-menu > li > a:hover > [class^="icon-"],
.dropdown-submenu:hover > a > [class^="icon-"], .dropdown-menu > li > a:hover > [class*=" icon-"],
.dropdown-submenu:hover > a > [class*=" icon-"] { .dropdown-menu > .active > a > [class^="icon-"],
background-image: none; .dropdown-menu > .active > a > [class*=" icon-"],
.dropdown-submenu:hover > a > [class^="icon-"],
.dropdown-submenu:hover > a > [class*=" icon-"] {
background-image: none;
}
} }
[class^="icon-"]:before, [class^="icon-"]:before,
[class*=" icon-"]:before { [class*=" icon-"]:before {
text-decoration: inherit; text-decoration: inherit;