mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-24 11:26:31 +00:00
Handle SVG correctly in page normalization
Related to mathjax/MathJax-node#65
This commit is contained in:
+8
-1
@@ -78,7 +78,14 @@ function pregQuote( str ) {
|
||||
|
||||
// Adapt an html snippet to be relative to a base folder
|
||||
function normalizeHtml(src, options) {
|
||||
var $ = cheerio.load(src, { xmlMode: false});
|
||||
var $ = cheerio.load(src, {
|
||||
// We should parse html without trying to normalize too much
|
||||
xmlMode: false,
|
||||
|
||||
// SVG need some attributes to use uppercases
|
||||
lowerCaseAttributeNames: false,
|
||||
lowerCaseTags: false
|
||||
});
|
||||
var toConvert = [];
|
||||
var svgContent = {};
|
||||
var outputRoot = options.book.options.output;
|
||||
|
||||
Reference in New Issue
Block a user