MWSaveDialog: Give checkboxes a class based on their origin's name

Bug: T138631
Change-Id: I2c31becd57c7988c4dd26c09ee01b4f7820c7aaa
This commit is contained in:
David Lynch 2016-07-19 11:21:36 -05:00
parent 3da7110f0c
commit e9b99d8181

View file

@ -395,7 +395,8 @@ ve.init.mw.DesktopArticleTarget.prototype.loadSuccess = function ( response ) {
}
checkbox = new OO.ui.CheckboxInputWidget( {
value: $this.attr( 'value' ),
selected: defaults[ name ] !== undefined ? defaults[ name ] : $this.prop( 'checked' )
selected: defaults[ name ] !== undefined ? defaults[ name ] : $this.prop( 'checked' ),
classes: [ 've-ui-mwSaveDialog-checkbox-' + name ]
} );
// HACK: CheckboxInputWidget doesn't support access keys
checkbox.$input.attr( 'accesskey', $( this ).attr( 'accesskey' ) );