Changed sizes.* to return em values instead of px.

This commit is contained in:
Macdonald, Zak 2015-07-02 20:46:11 -07:00
parent 80ddc308b1
commit 7e0b75e2b7
7 changed files with 27 additions and 45 deletions

28
css/font-awesome.css vendored
View File

@ -19,41 +19,41 @@
transform: translate(0, 0); transform: translate(0, 0);
} }
.fa-default { .fa-default {
font-size: 14px; font-size: 1em;
line-height: 10px; line-height: 0.75em;
vertical-align: -15%; vertical-align: -15%;
} }
.fa-lg { .fa-lg {
font-size: 18px; font-size: 1.333em;
line-height: 13px; line-height: 0.99975em;
vertical-align: -15%; vertical-align: -15%;
} }
.fa-sm { .fa-sm {
font-size: 9px; font-size: 0.666em;
line-height: 6px; line-height: 0.4995em;
vertical-align: -15%; vertical-align: -15%;
} }
.fa-xl { .fa-xl {
font-size: 23px; font-size: 1.666em;
line-height: 17px; line-height: 1.2495em;
vertical-align: -15%; vertical-align: -15%;
} }
.fa-xs { .fa-xs {
font-size: 4px; font-size: 0.333em;
line-height: 3px; line-height: 0.24975em;
vertical-align: -15%; vertical-align: -15%;
} }
.fa-2x { .fa-2x {
font-size: 28px; font-size: 2em;
} }
.fa-3x { .fa-3x {
font-size: 42px; font-size: 3em;
} }
.fa-4x { .fa-4x {
font-size: 56px; font-size: 4em;
} }
.fa-5x { .fa-5x {
font-size: 70px; font-size: 5em;
} }
.fa-fw { .fa-fw {
width: 1.28571429em; width: 1.28571429em;

File diff suppressed because one or more lines are too long

View File

@ -8,8 +8,8 @@
@fa-icon-scale: extract(extract(@fa-var-scales, @iterator), 2); @fa-icon-scale: extract(extract(@fa-var-scales, @iterator), 2);
.@{fa-css-prefix}-@{fa-icon-scale-name-unquoted} { .@{fa-css-prefix}-@{fa-icon-scale-name-unquoted} {
font-size: floor(@fa-font-size-base * @fa-icon-scale); font-size: unit(@fa-icon-scale, em);
line-height: floor(@fa-font-size-base * @fa-icon-scale * 0.75); line-height: unit(@fa-icon-scale * 0.75, em);
vertical-align: -15%; vertical-align: -15%;
} }
.createIconScales((@iterator + 1)); .createIconScales((@iterator + 1));
@ -23,7 +23,7 @@
@fa-icon-multiplier: extract(extract(@fa-var-multipliers, @iterator), 2); @fa-icon-multiplier: extract(extract(@fa-var-multipliers, @iterator), 2);
.@{fa-css-prefix}-@{fa-icon-multiplier-name-unquoted} { .@{fa-css-prefix}-@{fa-icon-multiplier-name-unquoted} {
font-size: floor(@fa-font-size-base * @fa-icon-multiplier); font-size: unit(@fa-icon-multiplier, em);
} }
.createIconMultipliers((@iterator + 1)); .createIconMultipliers((@iterator + 1));
} }

View File

@ -1,18 +0,0 @@
// icon sizes
// -------------------------
// scale icon size by n
@each $fa-icon-scale-name, $fa-icon-scale in $fa-var-scales {
.#{$fa-css-prefix}-#{$fa-icon-scale-name} {
font-size: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale)}px;
line-height: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale * 0.75)}px;
vertical-align: -15%;
}
}
// multiply icon size by n
@each $fa-icon-multiplier-name, $fa-icon-multiplier in $fa-var-multipliers {
.#{$fa-css-prefix}-#{$fa-icon-multiplier-name} {
font-size: #{fudge($fa-font-size-base * $fa-icon-multiplier)}px;
}
}

View File

@ -4,8 +4,8 @@
// scale icon size by n // scale icon size by n
@each $fa-icon-scale-name, $fa-icon-scale in $fa-var-scales { @each $fa-icon-scale-name, $fa-icon-scale in $fa-var-scales {
.#{$fa-css-prefix}-#{$fa-icon-scale-name} { .#{$fa-css-prefix}-#{$fa-icon-scale-name} {
font-size: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale)}px; font-size: #{$fa-icon-scale}em;
line-height: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale * 0.75)}px; line-height: #{$fa-icon-scale * 0.75}em;
vertical-align: -15%; vertical-align: -15%;
} }
} }
@ -13,6 +13,6 @@
// multiply icon size by n // multiply icon size by n
@each $fa-icon-multiplier-name, $fa-icon-multiplier in $fa-var-multipliers { @each $fa-icon-multiplier-name, $fa-icon-multiplier in $fa-var-multipliers {
.#{$fa-css-prefix}-#{$fa-icon-multiplier-name} { .#{$fa-css-prefix}-#{$fa-icon-multiplier-name} {
font-size: #{fudge($fa-font-size-base * $fa-icon-multiplier)}px; font-size: #{$fa-icon-multiplier}em;
} }
} }

View File

@ -11,8 +11,8 @@
@fa-icon-scale: extract(extract(@fa-var-scales, @iterator), 2); @fa-icon-scale: extract(extract(@fa-var-scales, @iterator), 2);
.@{fa-css-prefix}-@{fa-icon-scale-name-unquoted} { .@{fa-css-prefix}-@{fa-icon-scale-name-unquoted} {
font-size: floor(@fa-font-size-base * @fa-icon-scale); font-size: unit(@fa-icon-scale, em);
line-height: floor(@fa-font-size-base * @fa-icon-scale * 0.75); line-height: unit(@fa-icon-scale * 0.75, em);
vertical-align: -15%; vertical-align: -15%;
} }
.createIconScales((@iterator + 1)); .createIconScales((@iterator + 1));
@ -26,7 +26,7 @@
@fa-icon-multiplier: extract(extract(@fa-var-multipliers, @iterator), 2); @fa-icon-multiplier: extract(extract(@fa-var-multipliers, @iterator), 2);
.@{fa-css-prefix}-@{fa-icon-multiplier-name-unquoted} { .@{fa-css-prefix}-@{fa-icon-multiplier-name-unquoted} {
font-size: floor(@fa-font-size-base * @fa-icon-multiplier); font-size: unit(@fa-icon-multiplier, em);
} }
.createIconMultipliers((@iterator + 1)); .createIconMultipliers((@iterator + 1));
} }

View File

@ -7,8 +7,8 @@
// scale icon size by n // scale icon size by n
@each $fa-icon-scale-name, $fa-icon-scale in $fa-var-scales { @each $fa-icon-scale-name, $fa-icon-scale in $fa-var-scales {
.#{$fa-css-prefix}-#{$fa-icon-scale-name} { .#{$fa-css-prefix}-#{$fa-icon-scale-name} {
font-size: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale)}px; font-size: #{$fa-icon-scale}em;
line-height: #{fudge(unitless($fa-font-size-base) * $fa-icon-scale * 0.75)}px; line-height: #{$fa-icon-scale * 0.75}em;
vertical-align: -15%; vertical-align: -15%;
} }
} }
@ -16,6 +16,6 @@
// multiply icon size by n // multiply icon size by n
@each $fa-icon-multiplier-name, $fa-icon-multiplier in $fa-var-multipliers { @each $fa-icon-multiplier-name, $fa-icon-multiplier in $fa-var-multipliers {
.#{$fa-css-prefix}-#{$fa-icon-multiplier-name} { .#{$fa-css-prefix}-#{$fa-icon-multiplier-name} {
font-size: #{fudge($fa-font-size-base * $fa-icon-multiplier)}px; font-size: #{$fa-icon-multiplier}em;
} }
} }