@arolariu/components
Version:
🎨 70+ beautiful, accessible React components built on Radix UI. TypeScript-first, tree-shakeable, SSR-ready. Perfect for modern web apps, design systems & rapid prototyping. Zero config, maximum flexibility! ⚡
24 lines (23 loc) • 1.23 kB
JavaScript
"use client";
import { jsx } from "react/jsx-runtime";
import { useTheme } from "next-themes";
import "react";
import { Toaster, toast } from "sonner";
const sonner_Toaster = ({ ...props })=>{
const { theme = "system" } = useTheme();
return /*#__PURE__*/ jsx(Toaster, {
theme: theme,
className: "toaster group",
toastOptions: {
classNames: {
toast: "group toast group-[.toaster]:bg-white group-[.toaster]:text-neutral-950 group-[.toaster]:border-neutral-200 group-[.toaster]:shadow-lg dark:group-[.toaster]:bg-neutral-950 dark:group-[.toaster]:text-neutral-50 dark:group-[.toaster]:border-neutral-800",
description: "group-[.toast]:text-neutral-500 dark:group-[.toast]:text-neutral-400",
actionButton: "group-[.toast]:bg-neutral-900 group-[.toast]:text-neutral-50 dark:group-[.toast]:bg-neutral-50 dark:group-[.toast]:text-neutral-900",
cancelButton: "group-[.toast]:bg-neutral-100 group-[.toast]:text-neutral-500 dark:group-[.toast]:bg-neutral-800 dark:group-[.toast]:text-neutral-400"
}
},
...props
});
};
export { sonner_Toaster as Toaster, toast };
//# sourceMappingURL=sonner.js.map