Move text style tools out of experimental

These were meant to have been de-experimental-ised with the toolbar
commit; oh well. This moves the following text styles from being in
"experimental" mode to being regular annotations:

* Code
* Strikethrough
* Subscript
* Superscript
* Underline

Change-Id: I21be2dc844b47b825d7a1e48a592067166ecd122
This commit is contained in:
James D. Forrester 2013-09-11 19:41:14 -07:00
parent 129cf0a42c
commit 1a1ef97336
3 changed files with 114 additions and 114 deletions

View file

@ -559,6 +559,10 @@ $wgResourceModules += array(
'visualeditor-annotationbutton-code-tooltip',
'visualeditor-annotationbutton-italic-tooltip',
'visualeditor-annotationbutton-link-tooltip',
'visualeditor-annotationbutton-strikethrough-tooltip',
'visualeditor-annotationbutton-subscript-tooltip',
'visualeditor-annotationbutton-superscript-tooltip',
'visualeditor-annotationbutton-underline-tooltip',
'visualeditor-beta-label',
'visualeditor-beta-warning',
'visualeditor-browserwarning',
@ -725,10 +729,6 @@ $wgResourceModules += array(
'visualeditor-languageinspector-block-tooltip',
'visualeditor-languageinspector-block-tooltip-rtldirection',
'visualeditor-annotationbutton-language-tooltip',
'visualeditor-annotationbutton-strikethrough-tooltip',
'visualeditor-annotationbutton-subscript-tooltip',
'visualeditor-annotationbutton-superscript-tooltip',
'visualeditor-annotationbutton-underline-tooltip',
'visualeditor-mwalienextensioninspector-title',
'visualeditor-mwhieroinspector-title',
'visualeditor-mwmathinspector-title',

View file

@ -153,3 +153,113 @@ ve.ui.ItalicAnnotationTool.static.icon = {
ve.ui.ItalicAnnotationTool.static.titleMessage = 'visualeditor-annotationbutton-italic-tooltip';
ve.ui.ItalicAnnotationTool.static.annotation = { 'name': 'textStyle/italic' };
ve.ui.toolFactory.register( ve.ui.ItalicAnnotationTool );
/**
* UserInterface code tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.CodeAnnotationTool = function VeUiCodeAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.CodeAnnotationTool, ve.ui.AnnotationTool );
ve.ui.CodeAnnotationTool.static.name = 'code';
ve.ui.CodeAnnotationTool.static.group = 'textStyle';
ve.ui.CodeAnnotationTool.static.icon = 'code';
ve.ui.CodeAnnotationTool.static.titleMessage = 'visualeditor-annotationbutton-code-tooltip';
ve.ui.CodeAnnotationTool.static.annotation = { 'name': 'textStyle/code' };
ve.ui.toolFactory.register( ve.ui.CodeAnnotationTool );
/**
* UserInterface strikethrough tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.StrikethroughAnnotationTool = function VeUiStrikethroughAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.StrikethroughAnnotationTool, ve.ui.AnnotationTool );
ve.ui.StrikethroughAnnotationTool.static.name = 'strikethrough';
ve.ui.StrikethroughAnnotationTool.static.group = 'textStyle';
ve.ui.StrikethroughAnnotationTool.static.icon = {
'default': 'strikethrough-a',
'en': 'strikethrough-s'
};
ve.ui.StrikethroughAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-strikethrough-tooltip';
ve.ui.StrikethroughAnnotationTool.static.annotation = { 'name': 'textStyle/strike' };
ve.ui.toolFactory.register( ve.ui.StrikethroughAnnotationTool );
/**
* UserInterface underline tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.UnderlineAnnotationTool = function VeUiUnderlineAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.UnderlineAnnotationTool, ve.ui.AnnotationTool );
ve.ui.UnderlineAnnotationTool.static.name = 'underline';
ve.ui.UnderlineAnnotationTool.static.group = 'textStyle';
ve.ui.UnderlineAnnotationTool.static.icon = {
'default': 'underline-a',
'en': 'underline-u'
};
ve.ui.UnderlineAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-underline-tooltip';
ve.ui.UnderlineAnnotationTool.static.annotation = { 'name': 'textStyle/underline' };
ve.ui.toolFactory.register( ve.ui.UnderlineAnnotationTool );
/**
* UserInterface subscript tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.SubscriptAnnotationTool = function VeUiSubscriptAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.SubscriptAnnotationTool, ve.ui.AnnotationTool );
ve.ui.SubscriptAnnotationTool.static.name = 'subscript';
ve.ui.SubscriptAnnotationTool.static.group = 'textStyle';
ve.ui.SubscriptAnnotationTool.static.icon = 'subscript';
ve.ui.SubscriptAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-subscript-tooltip';
ve.ui.SubscriptAnnotationTool.static.annotation = { 'name': 'textStyle/subscript' };
ve.ui.toolFactory.register( ve.ui.SubscriptAnnotationTool );
/**
* UserInterface superscript tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.SuperscriptAnnotationTool = function VeUiSuperscriptAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.SuperscriptAnnotationTool, ve.ui.AnnotationTool );
ve.ui.SuperscriptAnnotationTool.static.name = 'superscript';
ve.ui.SuperscriptAnnotationTool.static.group = 'textStyle';
ve.ui.SuperscriptAnnotationTool.static.icon = 'superscript';
ve.ui.SuperscriptAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-superscript-tooltip';
ve.ui.SuperscriptAnnotationTool.static.annotation = { 'name': 'textStyle/superscript' };
ve.ui.toolFactory.register( ve.ui.SuperscriptAnnotationTool );

View file

@ -5,116 +5,6 @@
* @license The MIT License (MIT); see LICENSE.txt
*/
/**
* UserInterface code tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.CodeAnnotationTool = function VeUiCodeAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.CodeAnnotationTool, ve.ui.AnnotationTool );
ve.ui.CodeAnnotationTool.static.name = 'code';
ve.ui.CodeAnnotationTool.static.group = 'textStyle';
ve.ui.CodeAnnotationTool.static.icon = 'code';
ve.ui.CodeAnnotationTool.static.titleMessage = 'visualeditor-annotationbutton-code-tooltip';
ve.ui.CodeAnnotationTool.static.annotation = { 'name': 'textStyle/code' };
ve.ui.toolFactory.register( ve.ui.CodeAnnotationTool );
/**
* UserInterface code tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.StrikethroughAnnotationTool = function VeUiStrikethroughAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.StrikethroughAnnotationTool, ve.ui.AnnotationTool );
ve.ui.StrikethroughAnnotationTool.static.name = 'strikethrough';
ve.ui.StrikethroughAnnotationTool.static.group = 'textStyle';
ve.ui.StrikethroughAnnotationTool.static.icon = {
'default': 'strikethrough-a',
'en': 'strikethrough-s'
};
ve.ui.StrikethroughAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-strikethrough-tooltip';
ve.ui.StrikethroughAnnotationTool.static.annotation = { 'name': 'textStyle/strike' };
ve.ui.toolFactory.register( ve.ui.StrikethroughAnnotationTool );
/**
* UserInterface underline tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.UnderlineAnnotationTool = function VeUiUnderlineAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.UnderlineAnnotationTool, ve.ui.AnnotationTool );
ve.ui.UnderlineAnnotationTool.static.name = 'underline';
ve.ui.UnderlineAnnotationTool.static.group = 'textStyle';
ve.ui.UnderlineAnnotationTool.static.icon = {
'default': 'underline-a',
'en': 'underline-u'
};
ve.ui.UnderlineAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-underline-tooltip';
ve.ui.UnderlineAnnotationTool.static.annotation = { 'name': 'textStyle/underline' };
ve.ui.toolFactory.register( ve.ui.UnderlineAnnotationTool );
/**
* UserInterface subscript tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.SubscriptAnnotationTool = function VeUiSubscriptAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.SubscriptAnnotationTool, ve.ui.AnnotationTool );
ve.ui.SubscriptAnnotationTool.static.name = 'subscript';
ve.ui.SubscriptAnnotationTool.static.group = 'textStyle';
ve.ui.SubscriptAnnotationTool.static.icon = 'subscript';
ve.ui.SubscriptAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-subscript-tooltip';
ve.ui.SubscriptAnnotationTool.static.annotation = { 'name': 'textStyle/subscript' };
ve.ui.toolFactory.register( ve.ui.SubscriptAnnotationTool );
/**
* UserInterface superscript tool.
*
* @class
* @extends ve.ui.AnnotationTool
* @constructor
* @param {ve.ui.SurfaceToolbar} toolbar
* @param {Object} [config] Config options
*/
ve.ui.SuperscriptAnnotationTool = function VeUiSuperscriptAnnotationTool( toolbar, config ) {
ve.ui.AnnotationTool.call( this, toolbar, config );
};
ve.inheritClass( ve.ui.SuperscriptAnnotationTool, ve.ui.AnnotationTool );
ve.ui.SuperscriptAnnotationTool.static.name = 'superscript';
ve.ui.SuperscriptAnnotationTool.static.group = 'textStyle';
ve.ui.SuperscriptAnnotationTool.static.icon = 'superscript';
ve.ui.SuperscriptAnnotationTool.static.titleMessage =
'visualeditor-annotationbutton-superscript-tooltip';
ve.ui.SuperscriptAnnotationTool.static.annotation = { 'name': 'textStyle/superscript' };
ve.ui.toolFactory.register( ve.ui.SuperscriptAnnotationTool );
/**
* UserInterface language tool.
*