mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 10:35:48 +00:00
Merge "Use a fullscreen help dialog for templates on mobile"
This commit is contained in:
commit
d4a25fdbe7
|
@ -62,5 +62,8 @@ ve.ui.MWFloatingHelpDialog.prototype.getSetupProcess = function ( data ) {
|
|||
|
||||
ve.ui.MWFloatingHelpDialog.prototype.getSizeProperties = function () {
|
||||
var sizeProps = ve.ui.MWFloatingHelpDialog.super.prototype.getSizeProperties.call( this );
|
||||
return ve.extendObject( {}, sizeProps, { width: '350px' } );
|
||||
if ( !OO.ui.isMobile() ) {
|
||||
return ve.extendObject( {}, sizeProps, { width: '350px' } );
|
||||
}
|
||||
return sizeProps;
|
||||
};
|
||||
|
|
|
@ -32,13 +32,17 @@ ve.ui.MWFloatingHelpElement = function VeUiMWFloatingHelpElement( config ) {
|
|||
|
||||
this.windowManager = new OO.ui.WindowManager();
|
||||
this.windowManager.addWindows( [ this.helpDialog ] );
|
||||
this.windowManager.$element.addClass( 've-ui-mwFloatingHelpElement-windowManager' );
|
||||
|
||||
if ( OO.ui.isMobile() ) {
|
||||
$( document.body ).append( this.windowManager.$element );
|
||||
} else {
|
||||
this.$element.append( this.windowManager.$element );
|
||||
}
|
||||
|
||||
this.$element
|
||||
.addClass( 've-ui-mwFloatingHelpElement' )
|
||||
.append(
|
||||
this.windowManager.$element,
|
||||
this.helpButton.$element
|
||||
);
|
||||
.append( this.helpButton.$element );
|
||||
};
|
||||
|
||||
/* Inheritance */
|
||||
|
|
|
@ -275,3 +275,7 @@
|
|||
.ve-ui-mwTransclusionDialog-floatingHelpElement-fieldsetLayout label {
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.ve-ui-mwTransclusionDialog-floatingHelpElement-fieldsetLayout .oo-ui-buttonWidget {
|
||||
width: 100%;
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
right: 0;
|
||||
}
|
||||
|
||||
.ve-ui-mwFloatingHelpElement .oo-ui-dialog .oo-ui-panelLayout {
|
||||
.ve-ui-mwFloatingHelpElement-windowManager .oo-ui-dialog .oo-ui-panelLayout {
|
||||
padding: 16px;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue