Skip to content

Commit

Permalink
add / replace new font-awesome files
Browse files Browse the repository at this point in the history
  • Loading branch information
jenniferisasi authored Nov 21, 2024
1 parent de47279 commit 54f7d5b
Show file tree
Hide file tree
Showing 15 changed files with 828 additions and 1,838 deletions.
4 changes: 2 additions & 2 deletions _sass/font-awesome/_bordered-pulled.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@

.#{$fa-css-prefix}-pull-left {
float: left;
margin-right: var(--#{$fa-css-prefix}-pull-margin, #{$fa-pull-margin});
margin-right: var(--#{$fa-css-prefix}-pull-margin, #{$fa-pull-margin});
}

.#{$fa-css-prefix}-pull-right {
float: right;
margin-left: var(--#{$fa-css-prefix}-pull-margin, #{$fa-pull-margin});
margin-left: var(--#{$fa-css-prefix}-pull-margin, #{$fa-pull-margin});
}
33 changes: 20 additions & 13 deletions _sass/font-awesome/_core.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,17 @@
// -------------------------

.#{$fa-css-prefix} {
font-family: var(--#{$fa-css-prefix}-style-family, "#{$fa-style-family}");
font-family: var(--#{$fa-css-prefix}-style-family, '#{$fa-style-family}');
font-weight: var(--#{$fa-css-prefix}-style, #{$fa-style});
}

.#{$fa-css-prefix},
.#{$fa-css-prefix}-classic,
.#{$fa-css-prefix}-sharp,
.fas,
.#{$fa-css-prefix}-solid,
.far,
.#{$fa-css-prefix}-regular,
.fab,
.#{$fa-css-prefix}-brands {
.#{$fa-css-prefix}-solid,
.#{$fa-css-prefix}-regular,
.#{$fa-css-prefix}-brands,
.#{$fa-css-prefix} {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
display: var(--#{$fa-css-prefix}-display, #{$fa-display});
Expand All @@ -24,17 +22,26 @@
text-rendering: auto;
}

.fas,
.fas::before,
.far::before,
.fab::before,
.#{$fa-css-prefix}-solid::before,
.#{$fa-css-prefix}-regular::before,
.#{$fa-css-prefix}-brands::before,
.fa::before {
content: var(#{$fa-icon-property});
}

.#{$fa-css-prefix}-classic,
.fas,
.#{$fa-css-prefix}-solid,
.far,
.#{$fa-css-prefix}-regular {
font-family: "Font Awesome 6 Free";
font-family: 'Font Awesome 6 Free';
}

.fab,
.#{$fa-css-prefix}-brands {
font-family: "Font Awesome 6 Brands";
.#{$fa-css-prefix}-brands,
.fab {
font-family: 'Font Awesome 6 Brands';
}

%fa-icon {
Expand Down
4 changes: 2 additions & 2 deletions _sass/font-awesome/_functions.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// fa-content: convenience function used to set content property
@function fa-content($fa-var) {
@return unquote('"#{ $fa-var }"');
@return unquote("\"#{ $fa-var }\"");
}

// fa-divide: Originally obtained from the Bootstrap https://github.com/twbs/bootstrap
Expand Down Expand Up @@ -51,7 +51,7 @@
$remainder: $remainder - $divisor;
}
@if $remainder > 0 and $precision > 0 {
$remainder: fa-divide($remainder * 10, $divisor, $precision - 1) * 0.1;
$remainder: fa-divide($remainder * 10, $divisor, $precision - 1) * .1;
}
@return ($quotient + $remainder) * $sign;
}
6 changes: 4 additions & 2 deletions _sass/font-awesome/_icons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
readers do not read off random characters that represent icons */

@each $name, $icon in $fa-icons {
.#{$fa-css-prefix}-#{$name}::before {
content: unquote('"#{ $icon }"');
.#{$fa-css-prefix}-#{$name} {
#{$fa-icon-property}: unquote("\"#{ $icon }\"");
#{$fa-duotone-icon-property}: unquote("\"#{$icon}#{$icon}\"");
}
}

6 changes: 2 additions & 4 deletions _sass/font-awesome/_list.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,11 @@
margin-left: var(--#{$fa-css-prefix}-li-margin, #{$fa-li-margin});
padding-left: 0;

> li {
position: relative;
}
> li { position: relative; }
}

.#{$fa-css-prefix}-li {
left: calc(var(--#{$fa-css-prefix}-li-width, #{$fa-li-width}) * -1);
left: calc(-1 * var(--#{$fa-css-prefix}-li-width, #{$fa-li-width}));
position: absolute;
text-align: center;
width: var(--#{$fa-css-prefix}-li-width, #{$fa-li-width});
Expand Down
25 changes: 8 additions & 17 deletions _sass/font-awesome/_mixins.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
}

// sets relative font-sizing and alignment (in _sizing)
@mixin fa-size($font-size) {
@mixin fa-size ($font-size) {
font-size: fa-divide($font-size, $fa-size-scale-base) * 1em; // converts step in sizing scale into an em-based value that's relative to the scale's base
line-height: fa-divide(1, $font-size) * 1em; // sets the line-height of the icon back to that of it's parent
vertical-align: (fa-divide(6, $font-size) - fa-divide(3, 8)) * 1em; // vertically centers the icon taking into account the surrounding text's descender
Expand Down Expand Up @@ -42,33 +42,24 @@
}

// sets a specific icon family to use alongside style + icon mixins
@mixin fa-family-classic() {
@extend .fa-classic;
}

// convenience mixins for declaring pseudo-elements by CSS variable,
// including all style-specific font properties, and both the ::before
// and ::after elements in the duotone case.
// including all style-specific font properties
@mixin fa-icon-solid($fa-var) {
@extend %fa-icon;
@extend .fa-solid;

&::before {
content: unquote('"#{ $fa-var }"');
}
& { #{$fa-icon-property}: unquote("\"#{ $fa-var }\""); #{$fa-duotone-icon-property}: unquote("\"#{ $fa-var }#{ $fa-var }\""); }
}

@mixin fa-icon-regular($fa-var) {
@extend %fa-icon;
@extend .fa-regular;

&::before {
content: unquote('"#{ $fa-var }"');
}
& { #{$fa-icon-property}: unquote("\"#{ $fa-var }\""); #{$fa-duotone-icon-property}: unquote("\"#{ $fa-var }#{ $fa-var }\""); }
}

@mixin fa-icon-brands($fa-var) {
@extend %fa-icon;
@extend .fa-brands;

&::before {
content: unquote('"#{ $fa-var }"');
}
& { #{$fa-icon-property}: unquote("\"#{ $fa-var }\""); #{$fa-duotone-icon-property}: unquote("\"#{ $fa-var }#{ $fa-var }\""); }
}
2 changes: 1 addition & 1 deletion _sass/font-awesome/_rotated-flipped.scss
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@
}

.#{$fa-css-prefix}-rotate-by {
transform: rotate(var(--#{$fa-css-prefix}-rotate-angle, none));
transform: rotate(var(--#{$fa-css-prefix}-rotate-angle, 0));
}
Loading

0 comments on commit 54f7d5b

Please sign in to comment.