mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-12-03 02:16:51 +00:00
216d0ea7a7
New changes: 281b543 Slugs: Remove vertical alignment hack d6ddbe4 Localisation updates from https://translatewiki.net. 94bb263 Follow-up d6ddbe4: Fix build for added language 'sd' bc8579d [BREAKING CHANGE] CommandHelp: Cleanup registry API Change-Id: I65e2bfc299fbd60d6bdc7a57a030980b6cb8ab18
52 lines
1.9 KiB
JavaScript
52 lines
1.9 KiB
JavaScript
/*!
|
|
* VisualEditor MediaWiki SequenceRegistry registrations.
|
|
*
|
|
* @copyright 2011-2015 VisualEditor Team and others; see AUTHORS.txt
|
|
* @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(
|
|
new ve.ui.Sequence( 'wikitextSig', 'mwWikitextWarning', '~~~' )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'wikitextHeading', 'heading2', [ { type: 'paragraph' }, '=', '=' ], 2 )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'numberHash', 'numberWrapOnce', [ { type: 'paragraph' }, '#', ' ' ], 2 )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'wikitextDefinition', 'mwWikitextWarning', [ { type: 'paragraph' }, ';' ] )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'wikitextDescription', 'blockquote', [ { type: 'paragraph' }, ':' ], 1 )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'wikitextTable', 'insertTable', '{|', 2 )
|
|
);
|
|
ve.ui.sequenceRegistry.register(
|
|
new ve.ui.Sequence( 'wikitextComment', 'comment', '<!--', 4 )
|
|
);
|
|
|
|
/* Help registrations */
|
|
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'heading2', {
|
|
sequences: [ 'wikitextHeading' ],
|
|
label: OO.ui.deferMsg( 'visualeditor-formatdropdown-format-heading2' )
|
|
} );
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'listNumber', { sequences: [ 'numberHash' ] } );
|
|
ve.ui.commandHelpRegistry.register( 'formatting', 'blockquote', { sequences: [ 'wikitextDescription' ] } );
|
|
ve.ui.commandHelpRegistry.register( 'insert', 'table', {
|
|
sequences: [ 'wikitextTable' ],
|
|
label: OO.ui.deferMsg( 'visualeditor-table-insert-table' )
|
|
} );
|
|
ve.ui.commandHelpRegistry.register( 'insert', 'comment', {
|
|
sequences: [ 'wikitextComment' ],
|
|
label: OO.ui.deferMsg( 'visualeditor-commentinspector-title' )
|
|
} );
|