XF 2.1 Font Awesome 5, Editor button management, Markdown support and more!

Rudy

Well-known member
Vote for a suggestion. :) I have just done so here:

 

Sunka

Well-known member
For XF 2.1 I'd probably recommend that you replace the contents of the font_awesome_setup template (which is new in 2.1 I think) with your CDN code.
What to change there with my cdn code?

PHP:
<xf:if is="fa_weight() == 'l'">
    <link rel="preload" href="{{ base_url('styles/fonts/fa/fa-light-300.woff2') }}" as="font" type="font/woff2" crossorigin="anonymous" />
<xf:elseif is="fa_weight() == 'r'" />
    <link rel="preload" href="{{ base_url('styles/fonts/fa/fa-regular-400.woff2') }}" as="font" type="font/woff2" crossorigin="anonymous" />
<xf:elseif is="fa_weight() == 's'" />
    <link rel="preload" href="{{ base_url('styles/fonts/fa/fa-solid-900.woff2') }}" as="font" type="font/woff2" crossorigin="anonymous" />
</xf:if>
<xf:if is="fa_weight() != 's'">
    <link rel="preload" href="{{ base_url('styles/fonts/fa/fa-solid-900.woff2') }}" as="font" type="font/woff2" crossorigin="anonymous" />
</xf:if>

<link rel="preload" href="{{ base_url('styles/fonts/fa/fa-brands-400.woff2') }}" as="font" type="font/woff2" crossorigin="anonymous" />
 

Chris D

XenForo developer
Staff member
Changes such as that are really beyond the scope of support, but beyond that, HYS threads aren't the correct place to ask for support so please create a new thread on the forum if you need help with it.
 

NicolasZN

Member
Font Awesome 5
Hey Chris:
I've been enjoying discovering FA5 and have encountered a few icons released in 5.7 that I can't yet display on my board. I'm wondering if we can expect regular updates to the point versions of FA5 as future releases of 2.1 roll out, or if things like that are likely to only happen in major point upgrades of XF?
 

Chris D

XenForo developer
Staff member
FA 5.7 is included in XF 2.1.1.

We couldn't include it in XF 2.1.0 because it was released so close to our stable release and we didn't have time to test it.

We will generally aim to keep it up to date within the 5.x line as long as there aren't any significant breaking changes.
 

Chris D

XenForo developer
Staff member
We're definitely using FA 5.7.

Not sure if the icons you refer to were added in 5.7.1 or 5.7.2 which have since been released but other than that, any 5.7 icon should work.
 
Top