Merge "Stop removal of only template placeholder from transclusion"

This commit is contained in:
jenkins-bot 2015-07-31 21:58:58 +00:00 committed by Gerrit Code Review
commit c8ab0003f3

View file

@ -155,8 +155,13 @@ ve.ui.MWTransclusionDialog.prototype.onBookletLayoutSet = function ( page ) {
!( page instanceof ve.ui.MWTemplatePage || page instanceof ve.ui.MWParameterPage )
);
this.bookletLayout.getOutlineControls().removeButton.toggle( !(
page instanceof ve.ui.MWParameterPage &&
page.parameter.isRequired()
(
page instanceof ve.ui.MWParameterPage &&
page.parameter.isRequired()
) || (
this.transclusionModel.getParts().length === 1 &&
page instanceof ve.ui.MWTemplatePlaceholderPage
)
) );
};