Allow alien extension node encapsulation wrappers to be of various types

Like transclusions, extensions can contain nodes of other types.  This
hasn't been an issue because the legacy parser doesn't generate content
with these annotations.  But, moving forward, as Parsoid becoming
responsible for more extensions.  This is the case for the new ImageMap
implementation.

Matches I95767e466803f0744b6626204a0a3a1514fff174

Change-Id: I6ff81a01207e2734090c626b177e5f4d10bb6d61
This commit is contained in:
Arlo Breault 2020-09-29 18:29:43 -04:00
parent af6bed0144
commit d02c0bbf45

View file

@ -27,6 +27,9 @@ ve.dm.MWAlienExtensionNode.static.getMatchRdfaTypes = function () {
]; ];
}; };
// Similar to transclusions, extension encapsulation nodes can be of various types
ve.dm.MWAlienExtensionNode.static.allowedRdfaTypes = null;
ve.dm.MWAlienExtensionNode.static.toDataElement = function ( domElements, converter ) { ve.dm.MWAlienExtensionNode.static.toDataElement = function ( domElements, converter ) {
// 'Parent' method // 'Parent' method
var element = ve.dm.MWExtensionNode.static.toDataElement.call( this, domElements, converter ), var element = ve.dm.MWExtensionNode.static.toDataElement.call( this, domElements, converter ),