Render FontAwesome correctly in Firefox

Based on Mozilla specification
(https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face#specifying_local_font_alternatives)
the reference to 'local' should contain either the full path to the
font location (which we don't want to hard code) or a reference to the font name.
The latter renders FontAwesome correctly in Firefox for packages
installed locally.
This commit is contained in:
Karolina Surma 2022-07-18 14:44:56 +02:00
parent cbe0a3155f
commit fef1a90465

View File

@ -110,7 +110,7 @@ do
done
sed -e "s|src:url(fonts/fontawesome-webfont\.[^)]*);||" \
-e "s|src:\(url(fonts/fontawesome-webfont\.[^)]*) format([^)]*),\?\)\+|src:local(\"fontawesome/FontAwesome\"),url('/.sysassets/fonts/fontawesome/fontawesome-webfont.ttf') format(\"truetype\")|" \
-e "s|src:\(url(fonts/fontawesome-webfont\.[^)]*) format([^)]*),\?\)\+|src:local(\"FontAwesome\"),url('/.sysassets/fonts/fontawesome/fontawesome-webfont.ttf') format(\"truetype\")|" \
-i badge_only.css theme.css
popd