feat(user notifications): added the ability for users to sub to notifications and add multi email

This commit is contained in:
2026-04-06 09:29:46 -05:00
parent 3ecf5fb916
commit 637de857f9
7 changed files with 207 additions and 16 deletions

View File

@@ -13,6 +13,7 @@ import { useAppForm } from "@/lib/formSutff";
import { Spinner } from "../../components/ui/spinner";
import ChangePassword from "./-components/ChangePassword";
import NotificationsSubCard from "./-components/NotificationsSubCard";
import NotificationsTable from "./-components/NotificationsTable";
export const Route = createFileRoute("/(auth)/user/profile")({
beforeLoad: async () => {
@@ -119,11 +120,24 @@ function RouteComponent() {
</div>
</div>
<div className="w-fill">
<Card>
<CardHeader className="text-center">
You are not subscribed to any notifications.
</CardHeader>
</Card>
<Suspense
fallback={
<Card className="p-3">
<CardHeader>
<CardTitle className="text-center">Subscriptions</CardTitle>
</CardHeader>
<CardContent>
<div className="flex justify-center m-auto">
<div>
<Spinner className="size-32" />
</div>
</div>
</CardContent>
</Card>
}
>
{session && <NotificationsTable userId={`${session.user.id}`} />}
</Suspense>
</div>
</div>
);