thecodeholic/lobibox

onClick for notifications?

Closed this issue · 3 comments

Is there a way to use onClick events on notifications?
Like opening a url when clicking that notification

Well, there is no direct event in plugin, but plugin initialization returns plugin instance which has $el property which refers to jquery object of notification.

var notify = Lobibox.notify("error", {
    msg: "message"
});

notify.$el.on('click', function(){
    console.log("works");
});

Thanks!

Added onClick event