import { Toast as ToastPrimitive } from '@base-ui/react/toast'
import { CircleCheck, Info, Loader2, OctagonX, TriangleAlert, X } from 'lucide-react'
import { toast } from '@/lib/notifications'
import './toast.css'
export { toast, settingsSaved } from '@/lib/notifications'
const icons = { success: CircleCheck, info: Info, warning: TriangleAlert, error: OctagonX, loading: Loader2 }
function ToastList() {
const { toasts } = ToastPrimitive.useToastManager()
return toasts.map(item => {
const Icon = icons[item.type as keyof typeof icons]
return (
{Icon && }
{item.description && }
{item.actionProps && }
)
})
}
// shadcn Base UI Toast composition; scoped styles support the dashboard's Tailwind 3 build.
export function Toaster() {
return (
)
}