Preload the woff2 version of FontAwesome
authorTim Düsterhus <duesterhus@woltlab.com>
Thu, 25 Feb 2021 15:50:15 +0000 (16:50 +0100)
committerTim Düsterhus <duesterhus@woltlab.com>
Thu, 25 Feb 2021 16:01:24 +0000 (17:01 +0100)
wcfsetup/install/files/style/icon/icon.scss

index 84b23015a42cca2546edfaa318a2e9cbe3fc6a6d..070283ddacb8288e88fe1ad12f2c4d8a477cea68 100644 (file)
@@ -1,6 +1,12 @@
 /* do NOT reference fonts directly, always make use of 'getFont.php' */
 @font-face {
        font-family: "FontAwesome";
+       --woltlab-suite-preload: #{preload(
+                       getFont("fontawesome-webfont.woff2", "", "4.7.0"),
+                       $as: "font",
+                       $crossorigin: true,
+                       $type: "font/woff2"
+               )};
        src: url(getFont("fontawesome-webfont.eot", "", "4.7.0"));
        src: url(getFont("fontawesome-webfont.eot", "", "4.7.0") + "#iefix") format("embedded-opentype"),
                url(getFont("fontawesome-webfont.woff2", "", "4.7.0")) format("woff2"),