feat: add Resend integration for email verification and update package dependencies

- Integrated Resend for sending email verification upon user sign-up.
- Updated package.json to include Resend as a dependency.
- Enhanced authentication flow with error handling for email sending.
- Removed outdated Canvas Implementation Guide documentation.
This commit is contained in:
Matthias
2026-03-25 14:56:20 +01:00
parent 4d17936570
commit 056e60743d
9 changed files with 369 additions and 801 deletions

View File

@@ -1,9 +1,10 @@
import { redirect } from "next/navigation";
import { notFound, redirect } from "next/navigation";
import Canvas from "@/components/canvas/canvas";
import CanvasToolbar from "@/components/canvas/canvas-toolbar";
import { api } from "@/convex/_generated/api";
import type { Id } from "@/convex/_generated/dataModel";
import { isAuthenticated } from "@/lib/auth-server";
import { fetchAuthQuery, isAuthenticated } from "@/lib/auth-server";
export default async function CanvasPage({
params,
@@ -18,6 +19,17 @@ export default async function CanvasPage({
const { canvasId } = await params;
const typedCanvasId = canvasId as Id<"canvases">;
try {
const canvas = await fetchAuthQuery(api.canvases.get, {
canvasId: typedCanvasId,
});
if (!canvas) {
notFound();
}
} catch {
notFound();
}
return (
<div className="relative h-screen w-screen overflow-hidden">
<CanvasToolbar canvasId={typedCanvasId} />