mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-12-12 14:35:28 +00:00
Merge "Re-add adding undocumented paramters in some cases"
This commit is contained in:
commit
928b33ce69
|
@ -150,6 +150,15 @@ ve.ui.MWTemplateDialog.prototype.onReplacePart = function ( removed, added ) {
|
|||
} else if ( shouldAddPlaceholder && !this.isNewSidebar ) {
|
||||
page.addPlaceholderParameter();
|
||||
}
|
||||
|
||||
if ( this.isNewSidebar ) {
|
||||
var documentedParameters = added.getSpec().getDocumentedParameterOrder(),
|
||||
undocumentedParameters = added.getSpec().getUndocumentedParameterNames();
|
||||
|
||||
if ( !documentedParameters.length || undocumentedParameters.length ) {
|
||||
page.addPlaceholderParameter();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if ( reselect ) {
|
||||
|
|
Loading…
Reference in a new issue