$content .= $this->prepareFile($mixin);
}
+ // getFont helper
+ $content .= <<<'EOT'
+@function getFont($filename, $family: "/", $version: "") {
+ @if (1 == 1) {
+ @if ($family != "") {
+ $family: "families/" + $family + "/";
+ }
+ @if ($version != "") {
+ $version: "?v=" + $version;
+ }
+
+ @return "../font/" + $family + $filename + $version;
+ }
+ @else {
+ @return "../font/getFont.php?family=" + $family + "&filename=" + $filename + "&v=" + $version;
+ }
+}
+EOT;
+
// add google fonts
if (!empty($variables['wcfFontFamilyGoogle']) && PACKAGE_ID) {
$cssFile = FontManager::getInstance()->getCssFilename(substr($variables['wcfFontFamilyGoogle'], 1, -1));