-
-
Notifications
You must be signed in to change notification settings - Fork 320
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
NEXT: Toasts #2398
Comments
Toasts could be more useful with custom event options. |
Toast should have custom element for Dismiss button. Allow me to put my own button in the inside Toast, and attach an identifier to designate it as the dismiss button. All my other close button in my UI system is using a specific svg icon, it bothers me that the close button in Toast looks different. |
Hey Typograph, I'm expecting us to converge on an API that's the best parts of modals/drawers/toasts, including the potential for serving fully custom components as the toasts if you so choose. One way or another, we'll definitely cover this use case. |
I am trying to handle an array of toast, and have them show/dismiss in a staggered fashion... import { getToastStore, type ToastSettings } from '@skeletonlabs/skeleton';
const toastStore = getToastStore();
let toasts: {message:string, type: 'success'|'error'} = [
{ message: "Toast1", type: "success" },
{ message: "Toast2", type: "error" },
{ message: "Toast3", type: "success" }
];
toasts.forEach((each) => {
setTimeout(() =>
toastStore.trigger({
message: each.message,
hideDismiss: true,
background: each.type !== 'error' ? 'variant-filled-success' : 'variant-filled-error'
} as ToastSettings), 1000);
});
</script> but they seem to show/hide nearly all at the same time. Stackblitz minimal repro https://stackblitz.com/edit/skeletonlabs-repl-mshrcf?file=src%2Froutes%2F%2Bpage.svelte |
In v3, we're going to combine modals/drawers/toasts into a unified "overlay system": |
Warning
This issue is a work in progress.
This will act as a hub to centralize this information.
Framework Status
Maintainer Requests
The following requests are coming straight from the Skeleton team. These are highly likely be implemented:
Community Requests
The following requests have come from the community and are under consideration:
Bugs and Issues
Feedback
If you have additional updates or requests for this feature, please do so in the comments section below.
The text was updated successfully, but these errors were encountered: