3 * Adds default classes to buttons for styling purposes.
10 $.widget('ui.dialog', $.ui.dialog, {
12 buttonClass: 'button',
13 buttonPrimaryClass: 'button--primary'
15 _createButtons: function () {
16 var opts = this.options;
20 var il = opts.buttons.length;
21 for (index = 0; index < il; index++) {
22 if (opts.buttons[index].primary && opts.buttons[index].primary === true) {
24 delete opts.buttons[index].primary;
29 $buttons = this.uiButtonSet.children().addClass(opts.buttonClass);
30 if (typeof primaryIndex !== 'undefined') {
31 $buttons.eq(index).addClass(opts.buttonPrimaryClass);