Update parser.js

This commit is contained in:
Andrea Bogazzi 2015-06-26 12:07:03 +02:00
parent f2662ae411
commit 2315fafde1

View file

@ -761,7 +761,7 @@
svgUid = element.getAttribute('svgUid');
}
// if there's a parent container (`g` or `a` or `symbol` node), parse its attributes recursively upwards
if (element.parentNode && /^symbol|[g|a]$/i.test(element.parentNode.nodeName)) {
if (element.parentNode && /^(symbol|g|a)$/i.test(element.parentNode.nodeName)) {
parentAttributes = fabric.parseAttributes(element.parentNode, attributes, svgUid);
}
fontSize = (parentAttributes && parentAttributes.fontSize ) ||