Update the delete button's feature flag in the tranclusion context menu

Bug: T274263
Change-Id: If805ce9dfc44be34e07ec79179837f12898e626e
This commit is contained in:
Andrew Kostka 2021-05-20 12:10:49 +02:00 committed by Andrew-WMDE
parent 4f0c564fbc
commit 2fe6094099
2 changed files with 2 additions and 2 deletions

View file

@ -68,7 +68,7 @@ ve.ui.MWTransclusionContextItem.static.isCompatibleWith =
*/
ve.ui.MWTransclusionContextItem.prototype.isDeletable = function () {
var veConfig = mw.config.get( 'wgVisualEditorConfig' );
return veConfig.transclusionDialogNewSidebar;
return veConfig.transclusionDialogBackButton;
};
/**

View file

@ -105,7 +105,7 @@ ve.ui.MWTemplatePage = function VeUiMWTemplatePage( template, name, config ) {
.addClass( 've-ui-mwTemplatePage' )
.append( this.infoFieldset.$element );
if ( !config.isReadOnly ) {
if ( !veConfig.transclusionDialogNewSidebar ) {
if ( !veConfig.transclusionDialogBackButton ) {
this.$element.append( this.removeButton.$element );
}
this.$element.append( this.$more );