mirror of https://github.com/vuejs/core.git
fix: improve namespace handling for SVG and MathML tags
This commit is contained in:
parent
1b28566d5e
commit
fb4207c999
|
@ -24,7 +24,7 @@ export const parserOptions: ParserOptions = {
|
|||
let ns = parent ? parent.ns : rootNamespace
|
||||
if (parent && ns === Namespaces.MATH_ML) {
|
||||
if (parent.tag === 'annotation-xml') {
|
||||
if (tag === 'svg') {
|
||||
if (isSVGTag(tag)) {
|
||||
return Namespaces.SVG
|
||||
}
|
||||
if (
|
||||
|
@ -57,10 +57,10 @@ export const parserOptions: ParserOptions = {
|
|||
}
|
||||
|
||||
if (ns === Namespaces.HTML) {
|
||||
if (tag === 'svg') {
|
||||
if (isSVGTag(tag)) {
|
||||
return Namespaces.SVG
|
||||
}
|
||||
if (tag === 'math') {
|
||||
if (isMathMLTag(tag)) {
|
||||
return Namespaces.MATH_ML
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue