mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-28 00:00:49 +00:00
Merge "Show signatures in NWE visual diff"
This commit is contained in:
commit
e6d89cd1ec
|
@ -1208,15 +1208,16 @@ ve.init.mw.ArticleTarget.prototype.getVisualDiffGeneratorPromise = function () {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( target.getSurface().getMode() === 'source' ) {
|
if ( target.getSurface().getMode() === 'source' ) {
|
||||||
newRevPromise = mw.libs.ve.targetLoader.requestParsoidData(
|
newRevPromise = target.getContentApi().post( {
|
||||||
mw.config.get( 'wgRelevantPageName' ),
|
action: 'visualeditor',
|
||||||
{
|
paction: 'parsedoc',
|
||||||
oldId: target.revid,
|
page: target.getPageName(),
|
||||||
targetName: 'diff',
|
wikitext: ve.init.target.getSurface().getDom(),
|
||||||
modified: true,
|
pst: true
|
||||||
wikitext: ve.init.target.getSurface().getDom()
|
} ).then( function ( response ) {
|
||||||
}
|
// Use anonymous function to avoid passing through API promise argument
|
||||||
).then( mw.libs.ve.diffLoader.getModelFromResponse );
|
return mw.libs.ve.diffLoader.getModelFromResponse( response );
|
||||||
|
} );
|
||||||
|
|
||||||
return mw.libs.ve.diffLoader.getVisualDiffGeneratorPromise( target.originalDmDocPromise, newRevPromise );
|
return mw.libs.ve.diffLoader.getVisualDiffGeneratorPromise( target.originalDmDocPromise, newRevPromise );
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue