I'm using Bootstrap 4, the latest Datatables (from CDN) and Editor.
I'm having a problem overriding the classes for the form buttons that appear in the dialog. For example, I have:
{ extend: 'edit',
editor: _this.main_editor,
formTitle: "Update Opportunity",
className: "btn btn-primary",
formButtons: [
{
label: 'Update Opportunity',
className: 'btn btn-primary',
action: function () { this.submit(); }
},
{
label: 'Cancel',
className: 'btn btn-secondary ',
action: function () { this.close(); }
}
]
}
Yet the form buttons render as
<button class="btn btn-outline-secondary btn btn-primary" tabindex="0">Update Opportunity</button>
<button class="btn btn-outline-secondary btn btn-secondary" tabindex="0">Cancel</button>
For the buttons related to the table itself: (create, edit, remove ), I can do this:
buttons: {
dom: {
button: {
tag: "button",
className: ""
}
},
This removes the default classes and the buttons render with only the classes specified in className.
I cannot figure out how to achieve this for the form buttons.