feat: Individual Toast Duration
- PR includes addition of duration prop on individual toast trigger.
Example:
toast({
variant: "default",
title: "Notified",
duration: 2000,
});
@rkwap is attempting to deploy a commit to the shadcn-pro Team on Vercel.
A member of the Team first needs to authorize it.
Individual toast times can already be configured at the toast level.
toast({
duration: 5000,
title: "Hello World",
});
This comes from Radix UI's toast here, which has per-toast duration.
@kevinmitch14 @rkwap The issue here is that TOAST_REMOVE_DELAY is automatically set to such a large number (it's at 1000000 in both default and new york styles), that even after that duration runs out, the toast will not dismiss for a super long time.
I think we should consider changing TOAST_REMOVE_DELAY to something more sensible, though I've set it to 0 in my local copy.