mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-25 23:05:35 +00:00
a2e59f7c86
*.php * Updated links to files ve.ui.MetaDialog * Added stack panel that now contains category and language editor panels * Attached outline widget to stack panel ve.ui.FlaggableWidget -> ve.ui.FlaggableElement * Moved to elements ve.ui.GroupWidget -> ve.ui.GroupElement * Moved to elements * Removed invalid event documentation ve.ui.LabledWidget -> ve.ui.LabledElement * Moved to elements ve.ui.StackPanelLayout.js * New class, mutually exclusive panel container ve.ui.TitledPanelLayout * Remvoed, using labeled element instead ve.ui.Element.css * Added for elements * Moved label style here, from widget styles *.css, ve.ui.ButtonWidget.js, ve.ui.InputLabelWidget, ve.ui.OptionWidget, ve.ui.SelectWidget * Adjusted class names to reflect widget -> element migration Change-Id: I32f504c844dba7aae1b286eef06ca046627bdc8d
39 lines
1,011 B
JavaScript
39 lines
1,011 B
JavaScript
/*!
|
|
* VisualEditor UserInterface EditorPanelLayout class.
|
|
*
|
|
* @copyright 2011-2013 VisualEditor Team and others; see AUTHORS.txt
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
*/
|
|
|
|
/**
|
|
* Editor panel layout.
|
|
*
|
|
* @class
|
|
* @extends ve.ui.PanelLayout
|
|
* @mixins ve.ui.LabeledElement
|
|
*
|
|
* @constructor
|
|
* @param {Object} [config] Config options
|
|
* @cfg {string} [icon=''] Symbolic icon name
|
|
*/
|
|
ve.ui.EditorPanelLayout = function VeUiEditorPanelLayout( config ) {
|
|
// Config initialization
|
|
config = ve.extendObject( config, { 'scroll': true } );
|
|
|
|
// Parent constructor
|
|
ve.ui.PanelLayout.call( this, config );
|
|
|
|
// Mixin constructors
|
|
ve.ui.LabeledElement.call( this, this.$$( '<div>' ), config );
|
|
|
|
// Initialization
|
|
this.$label.addClass( 've-ui-icon-' + config.icon + '-big' );
|
|
this.$.append( this.$label ).addClass( 've-ui-editorPanelLayout' );
|
|
};
|
|
|
|
/* Inheritance */
|
|
|
|
ve.inheritClass( ve.ui.EditorPanelLayout, ve.ui.PanelLayout );
|
|
|
|
ve.mixinClass( ve.ui.EditorPanelLayout, ve.ui.LabeledElement );
|