Emoji: do not try to replace emoji chars inside dynamic SVGs.
Fixes #32305 for trunk. git-svn-id: https://develop.svn.wordpress.org/trunk@32478 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
cfa32bc1d7
commit
cdd007cc62
@ -70,11 +70,13 @@
|
||||
node = node.parentNode;
|
||||
}
|
||||
|
||||
if ( ! node || ( node.className && node.className.indexOf( 'wp-exclude-emoji' ) !== -1 ) ) {
|
||||
if ( ! node || node.nodeType !== 1 || ( 'ownerSVGElement' in node ) ||
|
||||
( node.className && typeof node.className === 'string' && node.className.indexOf( 'wp-exclude-emoji' ) !== -1 ) ) {
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( node.nodeType === 1 && test( node.textContent ) ) {
|
||||
if ( test( node.textContent ) ) {
|
||||
parse( node );
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user