Allow @import-ing of Google Fonts.

This commit is contained in:
Ian Prest 2015-07-30 22:04:58 -04:00
parent 45b0e0b03b
commit 798607a78b

View file

@ -222,7 +222,8 @@ var $renderKey = (typeof(exports) !== 'undefined') ? exports : {};
}
css += "}\n";
} else {
var ok = (rule.name === "@font-face");
var ok = (rule.name === "@font-face")
|| (rule.name === "@import" && !rule.content && rule.selector.match(/^url\(http:\/\/fonts.googleapis.com\/css\?family=[^\)]+\)$/));
if(ok) {
css += rule.name;
if(rule.selector) css += ' ' + rule.selector;
@ -231,7 +232,6 @@ var $renderKey = (typeof(exports) !== 'undefined') ? exports : {};
}
}
});
console.log(css);
return css;
}
}