Add compatibility fix for CSS skins with <style> element

This commit is contained in:
Tobi Schäfer 2025-05-27 20:26:38 +02:00
parent c6d86368c5
commit 0b326e71e6
Signed by: tobi
GPG key ID: 91FAE6FE2EBAC4C8

View file

@ -489,7 +489,8 @@ Site.prototype.main_css_action = function() {
res.push();
this.renderSkin('$Site#stylesheet');
this.renderSkin('Site#stylesheet');
var css = res.pop();
var css = res.pop()
.replace(/<(\/?style|!).*/g, ''); // TODO: Actually, a compatibility fix (earlier CSS skins contained the <style> element)
try {
lessParser.parse(css, function(error, less) {