2014-11-23 18:04:00 +00:00
|
|
|
/*!
|
|
|
|
* VisualEditor MediaWiki SequenceRegistry registrations.
|
|
|
|
*
|
2015-01-08 23:54:03 +00:00
|
|
|
* @copyright 2011-2015 VisualEditor Team and others; see AUTHORS.txt
|
2014-11-23 18:04:00 +00:00
|
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
|
|
*/
|
|
|
|
|
|
|
|
ve.ui.sequenceRegistry.register(
|
|
|
|
new ve.ui.Sequence( 'wikitextItalic', 'mwWikitextWarning', '\'\'' )
|
|
|
|
);
|
|
|
|
ve.ui.sequenceRegistry.register(
|
|
|
|
new ve.ui.Sequence( 'wikitextNowiki', 'mwWikitextWarning', '<nowiki' )
|
|
|
|
);
|
|
|
|
ve.ui.sequenceRegistry.register(
|
2014-11-26 01:42:37 +00:00
|
|
|
new ve.ui.Sequence( 'wikitextHeading', 'heading2', [ { type: 'paragraph' }, '=', '=' ], 2 )
|
2014-11-23 18:04:00 +00:00
|
|
|
);
|
|
|
|
ve.ui.sequenceRegistry.register(
|
2014-11-23 18:07:15 +00:00
|
|
|
new ve.ui.Sequence( 'numberHash', 'numberWrapOnce', [ { type: 'paragraph' }, '#', ' ' ], 2 )
|
2014-11-23 18:04:00 +00:00
|
|
|
);
|
2014-11-26 00:47:29 +00:00
|
|
|
ve.ui.sequenceRegistry.register(
|
|
|
|
new ve.ui.Sequence( 'wikitextDefinition', 'mwWikitextWarning', [ { type: 'paragraph' }, ';' ] )
|
|
|
|
);
|
|
|
|
ve.ui.sequenceRegistry.register(
|
2014-11-26 01:13:11 +00:00
|
|
|
new ve.ui.Sequence( 'wikitextDescription', 'blockquote', [ { type: 'paragraph' }, ':' ], 1 )
|
2014-11-26 00:47:29 +00:00
|
|
|
);
|
2015-10-22 14:18:45 +00:00
|
|
|
ve.ui.sequenceRegistry.register(
|
|
|
|
new ve.ui.Sequence( 'wikitextTable', 'insertTable', '{|', 2 )
|
|
|
|
);
|
|
|
|
ve.ui.sequenceRegistry.register(
|
|
|
|
new ve.ui.Sequence( 'wikitextComment', 'comment', '<!--', 4 )
|
|
|
|
);
|
2015-11-03 11:22:42 +00:00
|
|
|
|
|
|
|
/* Help registrations */
|
|
|
|
|
|
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'heading2', {
|
2015-11-05 10:11:35 +00:00
|
|
|
sequences: [ 'wikitextHeading' ],
|
|
|
|
label: OO.ui.deferMsg( 'visualeditor-formatdropdown-format-heading2' )
|
2015-11-03 11:22:42 +00:00
|
|
|
} );
|
2015-11-05 10:11:35 +00:00
|
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'listNumber', { sequences: [ 'numberHash' ] } );
|
|
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'blockquote', { sequences: [ 'wikitextDescription' ] } );
|
2015-11-03 11:22:42 +00:00
|
|
|
ve.ui.commandHelpRegistry.register( 'insert', 'table', {
|
2015-11-05 10:11:35 +00:00
|
|
|
sequences: [ 'wikitextTable' ],
|
|
|
|
label: OO.ui.deferMsg( 'visualeditor-table-insert-table' )
|
2015-11-03 11:22:42 +00:00
|
|
|
} );
|
|
|
|
ve.ui.commandHelpRegistry.register( 'insert', 'comment', {
|
2015-11-05 10:11:35 +00:00
|
|
|
sequences: [ 'wikitextComment' ],
|
|
|
|
label: OO.ui.deferMsg( 'visualeditor-commentinspector-title' )
|
2015-11-03 11:22:42 +00:00
|
|
|
} );
|