JanStevens / angular-growl-2

growl-like notifications for angularJS projects
MIT License
285 stars 97 forks source link

Set globalTimeToLive by severity #1

Closed nunomazer closed 10 years ago

nunomazer commented 10 years ago

It would be nice to set globalTimeToLive by severity.

Something like growlProvider.globalTimeToLive(2000, 'success'); growlProvider.globalTimeToLive(0, 'error'); // 0 meaning the need to close using close button

JanStevens commented 10 years ago

Ha wonderful idea, I'll look into it

JanStevens commented 10 years ago

I think a better syntax would be,

growlProvider.globalTimeToLive(2000) for a global setting (like now, backward compatible) growlProvider.globalTimeToLive({error: 0, success: 2000, warning: 2000, info: 5000}) where possible values can be left out, the default (null) would be applied.

nunomazer commented 10 years ago

Great, thanks