Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Close/Closed not triggering on button/invoked closing #3

Open
test-clau-fw opened this issue Jul 23, 2012 · 1 comment
Open

Close/Closed not triggering on button/invoked closing #3

test-clau-fw opened this issue Jul 23, 2012 · 1 comment

Comments

@test-clau-fw
Copy link

The onClose and onClosed callbacks currently only trigger if the alert is allowed to time out and fade out naturally.
If you close the alert by clicking on the close button, or otherwise force it closed via alert methods, they won't fire.

I hotfixed this in my case by adding the following, after line 66 in bootstrap-notify.js (at the end of Notification.prototype.show):

this.$note.on('close', function(){
self.options.onClosed()
})

this.$note.on('closed', function(){
self.options.onClosed()
})

@nijikokun
Copy link
Contributor

Possibly fixed with current merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants