Currently font icons are applied to elements and positioned absolutely against them. This approach gives incorrect result in a case if icon is applied to inline element that spans on multiple lines. Hence it is good idea to add support for applying font icons to such elements. It can be done by introducing inline parameter to font-icon() as applying font icons to inline elements will require different approach. Icon position will need to be positioned like this:
top: (line-height - 1em) / 2;
transform: none;
where line-height is line height value of the element itself. Since this value can't be obtained automatically - it should be required to pass it (as unitless or em value) as separate parameter.
Currently font icons are applied to elements and positioned absolutely against them. This approach gives incorrect result in a case if icon is applied to inline element that spans on multiple lines. Hence it is good idea to add support for applying font icons to such elements. It can be done by introducing
inline
parameter tofont-icon()
as applying font icons to inline elements will require different approach. Icon position will need to be positioned like this:where
line-height
is line height value of the element itself. Since this value can't be obtained automatically - it should be required to pass it (as unitless or em value) as separate parameter.