Archived
29 lines
686 B
TypeScript
29 lines
686 B
TypeScript
"use client";
|
|
|
|
import { Toaster as Sonner, type ToasterProps } from "sonner";
|
|
|
|
const Toaster = ({ ...props }: ToasterProps) => {
|
|
return (
|
|
<Sonner
|
|
theme="system"
|
|
className="toaster group"
|
|
position="bottom-right"
|
|
closeButton
|
|
richColors
|
|
toastOptions={{
|
|
classNames: {
|
|
toast: "group toast",
|
|
description: "group-[.toast]:text-muted-foreground",
|
|
actionButton:
|
|
"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",
|
|
cancelButton:
|
|
"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground",
|
|
},
|
|
}}
|
|
{...props}
|
|
/>
|
|
);
|
|
};
|
|
|
|
export { Toaster };
|