2014-02-13 13:29:29 +00:00
|
|
|
/*!
|
|
|
|
* VisualEditor UserInterface MWCommandHelpDialog class.
|
|
|
|
*
|
2019-01-01 13:24:23 +00:00
|
|
|
* @copyright 2011-2019 VisualEditor Team and others; see AUTHORS.txt
|
2014-02-13 13:29:29 +00:00
|
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Dialog listing all command keyboard shortcuts.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.CommandHelpDialog
|
|
|
|
*
|
|
|
|
* @constructor
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
2014-08-21 00:50:54 +00:00
|
|
|
ve.ui.MWCommandHelpDialog = function VeUiMWCommandHelpDialog( config ) {
|
2014-02-13 13:29:29 +00:00
|
|
|
// Parent constructor
|
2014-08-21 00:50:54 +00:00
|
|
|
ve.ui.MWCommandHelpDialog.super.call( this, config );
|
2014-02-13 13:29:29 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
/* Inheritance */
|
|
|
|
|
|
|
|
OO.inheritClass( ve.ui.MWCommandHelpDialog, ve.ui.CommandHelpDialog );
|
|
|
|
|
2015-11-03 11:20:36 +00:00
|
|
|
/* Static properties */
|
|
|
|
|
2016-03-11 13:12:25 +00:00
|
|
|
ve.ui.MWCommandHelpDialog.static.commandGroups = ve.extendObject( {}, ve.ui.MWCommandHelpDialog.static.commandGroups, {
|
2015-11-03 11:20:36 +00:00
|
|
|
insert: {
|
2015-11-05 10:11:35 +00:00
|
|
|
title: OO.ui.deferMsg( 'visualeditor-shortcuts-insert' ),
|
2018-08-22 12:28:58 +00:00
|
|
|
promote: [ 'ref', 'template', 'table' ],
|
|
|
|
demote: [ 'horizontalRule' ]
|
2015-11-03 11:20:36 +00:00
|
|
|
}
|
|
|
|
} );
|
|
|
|
|
2018-08-22 12:28:58 +00:00
|
|
|
ve.ui.MWCommandHelpDialog.static.commandGroupsOrder = [
|
|
|
|
'textStyle', 'clipboard', 'history', 'dialog',
|
|
|
|
'formatting', 'insert',
|
|
|
|
'other'
|
|
|
|
];
|
|
|
|
|
2015-10-23 17:21:11 +00:00
|
|
|
/* Registration */
|
2014-02-13 13:29:29 +00:00
|
|
|
|
2015-10-23 17:21:11 +00:00
|
|
|
ve.ui.windowFactory.register( ve.ui.MWCommandHelpDialog );
|