I've implemented font awesome 5 pseudo elements to attach an :after
tag to my element as shown below:
&:after {
content: "\f068";
font-weight:400;
color:$brandRed;
float:right;
font-family: "Font Awesome 5 Pro";
}
The content is being added correctly, but the styling I applied like float:right
does not reflect on the generated SVG from font awesome.
https://i.sstatic.net/NCafe.png
As seen in the image above, while the SVG element loads correctly, the :after
tag with float:right
styling remains unapplied to the SVG. Why doesn't it carry over?
Even though the documentation suggests adding stylings along with the content, it seems those stylings don't transfer over as expected.
.login::before {
font-family: "Font Awesome 5 Free";
font-weight: 900;
content: "\f007";
}
Why are the stylings failing to be applied properly?