Update OOjs UI to v0.1.0-pre (0fbf6bd14e)
New changes: ab5ebc6 Localisation updates from https://translatewiki.net. 39a1496 Make flags on buttons in confirmation dialog configurable Change-Id: I6c67b919003a33b1617ad36734bde489d79d916c
This commit is contained in:
parent
8a70e9825f
commit
08f105e2d9
5 changed files with 24 additions and 16 deletions
|
|
@ -2,8 +2,12 @@
|
|||
"@metadata": {
|
||||
"authors": [
|
||||
"Calak",
|
||||
"Muhammed taha"
|
||||
"Muhammed taha",
|
||||
"Serwan"
|
||||
]
|
||||
},
|
||||
"ooui-dialog-action-close": "دایخە"
|
||||
"ooui-dialog-action-close": "دایخە",
|
||||
"ooui-dialog-confirm-default-prompt": "ئایا تۆ دڵنیات ؟",
|
||||
"ooui-dialog-confirm-default-ok": "باشە",
|
||||
"ooui-dialog-confirm-default-cancel": "پاشگەزبوونەوە"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,5 +8,8 @@
|
|||
"ooui-outline-control-move-down": "Bweeschs nunna",
|
||||
"ooui-outline-control-move-up": "Bweeschs nuff",
|
||||
"ooui-outline-control-remove": "Leschs",
|
||||
"ooui-toolbar-more": "Mea"
|
||||
"ooui-toolbar-more": "Mea",
|
||||
"ooui-dialog-confirm-default-prompt": "Bischda sischa?",
|
||||
"ooui-dialog-confirm-default-ok": "OK",
|
||||
"ooui-dialog-confirm-default-cancel": "Abbresche"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,5 +15,6 @@
|
|||
"ooui-toolbar-more": "Mai mult",
|
||||
"ooui-dialog-confirm-title": "Confirmă",
|
||||
"ooui-dialog-confirm-default-prompt": "Ești sigur?",
|
||||
"ooui-dialog-confirm-default-ok": "OK",
|
||||
"ooui-dialog-confirm-default-cancel": "Renunță"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
/*!
|
||||
* OOjs UI v0.1.0-pre (521a9e242b)
|
||||
* OOjs UI v0.1.0-pre (0fbf6bd14e)
|
||||
* https://www.mediawiki.org/wiki/OOjs_UI
|
||||
*
|
||||
* Copyright 2011–2014 OOjs Team and other contributors.
|
||||
* Released under the MIT license
|
||||
* http://oojs.mit-license.org
|
||||
*
|
||||
* Date: Mon May 19 2014 10:42:43 GMT-0700 (PDT)
|
||||
* Date: Mon May 19 2014 14:09:28 GMT-0700 (PDT)
|
||||
*/
|
||||
( function ( OO ) {
|
||||
|
||||
|
|
@ -1957,14 +1957,10 @@ OO.ui.ConfirmationDialog.prototype.initialize = function () {
|
|||
|
||||
this.$promptContainer = this.$( '<div>' ).addClass( 'oo-ui-dialog-confirm-promptContainer' );
|
||||
|
||||
this.cancelButton = new OO.ui.ButtonWidget( {
|
||||
'flags': [ 'destructive' ]
|
||||
} );
|
||||
this.cancelButton = new OO.ui.ButtonWidget();
|
||||
this.cancelButton.connect( this, { 'click': [ 'emit', 'cancel' ] } );
|
||||
|
||||
this.okButton = new OO.ui.ButtonWidget( {
|
||||
'flags': [ 'constructive' ]
|
||||
} );
|
||||
this.okButton = new OO.ui.ButtonWidget();
|
||||
this.okButton.connect( this, { 'click': [ 'emit', 'ok' ] } );
|
||||
|
||||
// Make the buttons
|
||||
|
|
@ -1990,6 +1986,8 @@ OO.ui.ConfirmationDialog.prototype.initialize = function () {
|
|||
* @param {jQuery|string} [data.prompt] The text of the dialog.
|
||||
* @param {jQuery|string|Function|null} [data.okLabel] The text used on the OK button
|
||||
* @param {jQuery|string|Function|null} [data.cancelLabel] The text used on the cancel button
|
||||
* @param {string[]} [data.okFlags] Flags for the OK button
|
||||
* @param {string[]} [data.cancelFlags] Flags for the cancel button
|
||||
*/
|
||||
OO.ui.ConfirmationDialog.prototype.setup = function ( data ) {
|
||||
// Parent method
|
||||
|
|
@ -1997,7 +1995,9 @@ OO.ui.ConfirmationDialog.prototype.setup = function ( data ) {
|
|||
|
||||
var prompt = data.prompt || OO.ui.deferMsg( 'ooui-dialog-confirm-default-prompt' ),
|
||||
okLabel = data.okLabel || OO.ui.deferMsg( 'ooui-dialog-confirm-default-ok' ),
|
||||
cancelLabel = data.cancelLabel || OO.ui.deferMsg( 'ooui-dialog-confirm-default-cancel' );
|
||||
cancelLabel = data.cancelLabel || OO.ui.deferMsg( 'ooui-dialog-confirm-default-cancel' ),
|
||||
okFlags = data.okFlags || [ 'constructive'],
|
||||
cancelFlags = data.cancelFlags || [ 'destructive' ];
|
||||
|
||||
if ( typeof prompt === 'string' ) {
|
||||
this.$promptContainer.text( prompt );
|
||||
|
|
@ -2005,8 +2005,8 @@ OO.ui.ConfirmationDialog.prototype.setup = function ( data ) {
|
|||
this.$promptContainer.empty().append( prompt );
|
||||
}
|
||||
|
||||
this.okButton.setLabel( okLabel );
|
||||
this.cancelButton.setLabel( cancelLabel );
|
||||
this.okButton.setLabel( okLabel ).clearFlags().setFlags( okFlags );
|
||||
this.cancelButton.setLabel( cancelLabel ).clearFlags().setFlags( cancelFlags );
|
||||
};
|
||||
/**
|
||||
* Element with a button.
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
/*!
|
||||
* OOjs UI v0.1.0-pre (521a9e242b)
|
||||
* OOjs UI v0.1.0-pre (0fbf6bd14e)
|
||||
* https://www.mediawiki.org/wiki/OOjs_UI
|
||||
*
|
||||
* Copyright 2011–2014 OOjs Team and other contributors.
|
||||
* Released under the MIT license
|
||||
* http://oojs.mit-license.org
|
||||
*
|
||||
* Date: Mon May 19 2014 10:42:43 GMT-0700 (PDT)
|
||||
* Date: Mon May 19 2014 14:09:28 GMT-0700 (PDT)
|
||||
*/
|
||||
|
||||
/* Textures */
|
||||
|
|
|
|||
Loading…
Reference in a new issue