Преглед на файлове

disable temporarly variable substitution (issues with fonts)

Gildas преди 7 години
родител
ревизия
e0fcaf1277
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. 4 0
      lib/single-file/single-file-core.js

+ 4 - 0
lib/single-file/single-file-core.js

@@ -885,14 +885,18 @@ this.SingleFileCore = this.SingleFileCore || (() => {
 				if (resourceURL && resourceURL != baseURI && DomUtil.testValidPath(resourceURL) && stylesheetContent.includes(urlFunction)) {
 					const dataURI = await batchRequest.addURL(resourceURL);
 					const functions = stylesheetContent.match(DomUtil.getRegExp(urlFunction));
+					/*
 					if (!inline && options.compressCSS && functions.length > 1) {
 						const variableName = "--single-file-" + indexStyle + "-" + indexVariable;
 						stylesheetContent = variableName + ":url(\"" + dataURI + "\")" + (indexVariable ? ";" : "}") + stylesheetContent;
 						stylesheetContent = stylesheetContent.replace(DomUtil.getRegExp(urlFunction), "var(" + variableName + ")");
 						indexVariable++;
 					} else {
+						*/
 						stylesheetContent = stylesheetContent.replace(DomUtil.getRegExp(urlFunction), urlFunction.replace(originalResourceURL, dataURI));
+						/*
 					}
+					*/
 				}
 			}));
 			if (indexVariable) {