Notification Settings card

This commit is contained in:
headlesdev
2025-05-26 11:30:19 +02:00
parent d045aad2dd
commit 338c1922d0
14 changed files with 121 additions and 17 deletions

View File

@@ -8,7 +8,7 @@ import useNotifications from '@/hooks/useNotifications';
import { Plus, Trash2, Play, Bell } from 'lucide-react';
import Loading from '@/components/Loading';
export const NotificationSettings = ({ onError, onSuccess }: { onError: (message: string) => void, onSuccess: (message: string) => void }) => {
export const NotificationProviderSettings = ({ onError, onSuccess }: { onError: (message: string) => void, onSuccess: (message: string) => void }) => {
const { loadNotifications, notifications, loading, testNotification } = useNotifications();
const [deleteNotificationId, setDeleteNotificationId] = useState<number | null>(null);
const [notificationTestId, setNotificationTestId] = useState<number | null>(null);

View File

@@ -0,0 +1,25 @@
"use client";
import { useState } from "react";
interface NotificationSettingsProps {
onError: (message: string) => void;
onSuccess: (message: string) => void;
}
export const NotificationSettings = ({ onError, onSuccess }: NotificationSettingsProps) => {
const [enabled, setEnabled] = useState(false);
return (
<div>
<div className="w-full bg-base-200 p-4 rounded-2xl border border-stone-800">
<div className="flex items-center justify-between">
<div>
<h2 className="text-lg font-bold">Notification Settings</h2>
<p className="text-sm opacity-70">Manage your notification settings</p>
</div>
</div>
</div>
</div>
)
}