feat: Replace alert() with professional toast notification system
- Remove buggy Undo/Redo that saved character-by-character - Simplify state to plain useState like Google Keep - Create toast component with success/error/warning/info types - Toast notifications auto-dismiss after 3s with smooth animations - Add ToastProvider in layout - Remove all JavaScript alert() calls - Production-ready notification system
This commit is contained in:
@@ -2,6 +2,7 @@ import type { Metadata } from "next";
|
||||
import { Inter } from "next/font/google";
|
||||
import "./globals.css";
|
||||
import { Header } from "@/components/header";
|
||||
import { ToastProvider } from "@/components/ui/toast";
|
||||
|
||||
const inter = Inter({
|
||||
subsets: ["latin"],
|
||||
@@ -20,8 +21,10 @@ export default function RootLayout({
|
||||
return (
|
||||
<html lang="en" suppressHydrationWarning>
|
||||
<body className={inter.className}>
|
||||
<Header />
|
||||
{children}
|
||||
<ToastProvider>
|
||||
<Header />
|
||||
{children}
|
||||
</ToastProvider>
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user