From b553cb9f217e9540077fd98521c35593c1c84be3 Mon Sep 17 00:00:00 2001 From: Catrope Date: Fri, 15 Feb 2013 18:00:53 -0800 Subject: [PATCH] Fix ModelRegistry stupidities * Register mw: as an extension-specific type * Include 'property' as an RDFa type attribute Change-Id: Ia70708b76294815eb8eb8132048c33b0636380e9 --- modules/ve/dm/ve.dm.ModelRegistry.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/ve/dm/ve.dm.ModelRegistry.js b/modules/ve/dm/ve.dm.ModelRegistry.js index a063bbecd9..26aa572a38 100644 --- a/modules/ve/dm/ve.dm.ModelRegistry.js +++ b/modules/ve/dm/ve.dm.ModelRegistry.js @@ -169,7 +169,8 @@ ve.dm.ModelRegistry.prototype.isExtensionSpecificType = function ( type ) { ve.dm.ModelRegistry.prototype.matchElement = function ( element ) { var i, name, model, matches, winner, types, elementExtSpecificTypes, matchTypes, tag = element.nodeName.toLowerCase(), - typeAttr = element.getAttribute( 'typeof' ) || element.getAttribute( 'rel' ), + typeAttr = element.getAttribute( 'typeof' ) || element.getAttribute( 'rel' ) || + element.getAttribute( 'property' ), reg = this; function byRegistrationOrderDesc( a, b ) { @@ -311,5 +312,6 @@ ve.dm.ModelRegistry.prototype.matchElement = function ( element ) { /* Initialization */ ve.dm.modelRegistry = new ve.dm.ModelRegistry(); +ve.dm.modelRegistry.registerExtensionSpecificType( /^mw:/ ); } )( ve );