iziModal
iziModal copied to clipboard
Can i addClass to my iziModal on open?
$('#modal').iziModal('open', {
class: 'my-class' // add class to modal div
});
or can i setTheme
like setTitle ?
$('#modal').iziModal('open', {
theme: 'light',
});
not workin for me..
i use this
setTheme: function(drawclass){
var that = this,
theme = this.options.theme || drawclass;
if( drawclass !== undefined && drawclass !== this.options.theme){
this.$element.removeClass(this.options.theme);
theme = drawclass;
this.options.theme = theme;
this.$element.addClass(theme);
}
if(this.state == STATES.CLOSED){
this.open();
}
},
and init
$('#modal').iziModal('setTheme', 'my-class');