tall-toasts
tall-toasts copied to clipboard
Per notification duration
As it stands at the moment, the duration for when the notifications are scheduled to be removed is set globally in the config for all notifications.
While this works for most notification, it would be nice to be able to override the duration per notification.
I am happy to write a PR for this is it is wanted.
Hey @ashleyhood,
I haven't thought of a scenario that requires this, but I have something on my to-do list, which is sticky notifications: notifications that don't fade out until canceled.
Do you think this is enough for your use case?
IF a more fine-grained approach is needed, before submitting the PR let me know how you plan on writing it, as well as some common scenarios for use cases that are not covered by sticky notifications.
@usernotnull I think sticky notifications would work for most other use cases I have.
I second this feature.
Most of my notifications are 3000ms, but for notifications that have more text than just a "Success, your item was created", I would like to set them to 7500ms.
I'm okay with either toast()->success('Your item was created', 'Success')->duration(7500)->push() or even something like toast()->success('Your item was created', 'Success', 7500)->push();.
And for notifications that don't have a title, toast()->success('blah blah blah', '', 7500)->push()
My line of work changed and my focus is currently on something else for the moment.
I'm open for PRs until I'm able to do it myself.