3 * Adds default classes to buttons for styling purposes.
7 $.widget('ui.dialog', $.ui.dialog, {
10 buttonPrimaryClass: 'button--primary',
13 const opts = this.options;
16 const il = opts.buttons.length;
17 for (index = 0; index < il; index++) {
18 if (opts.buttons[index].primary && opts.buttons[index].primary === true) {
20 delete opts.buttons[index].primary;
25 const $buttons = this.uiButtonSet.children().addClass(opts.buttonClass);
26 if (typeof primaryIndex !== 'undefined') {
27 $buttons.eq(index).addClass(opts.buttonPrimaryClass);