Skip to content

Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.

Add delayed email delivery notice on verification page

Cursor Agent5a96f4b3945c
diff --git a/app/(auth)/auth/email/[[...params]]/page-client.tsx b/app/(auth)/auth/email/[[...params]]/page-client.tsx
index 5991d2af..e41b4f1f 100644
--- a/app/(auth)/auth/email/[[...params]]/page-client.tsx
+++ b/app/(auth)/auth/email/[[...params]]/page-client.tsx
@@ -19,6 +19,7 @@ export default function EmailVerificationClient() {
const [isLoading, setIsLoading] = useState(false);
const [error, setError] = useState<string | null>(null);
const [isExpired, setIsExpired] = useState(false);
+ const [showEmailDeliveryNotice, setShowEmailDeliveryNotice] = useState(false);
// Check sessionStorage for pending verification email on mount
useEffect(() => {
@@ -39,6 +40,17 @@ export default function EmailVerificationClient() {
}
}, []);
+ // Show email delivery notice after 5 seconds when waiting for verification
+ useEffect(() => {
+ if (!emailLocked) return;
+
+ const timer = setTimeout(() => {
+ setShowEmailDeliveryNotice(true);
+ }, 5000);
+
+ return () => clearTimeout(timer);
+ }, [emailLocked]);
+
// Code verification
const handleSubmit = async (e: React.FormEvent) => {
e.preventDefault();
@@ -158,6 +170,26 @@ export default function EmailVerificationClient() {
</h3>
</div>
+ {/* Delayed email delivery notice */}
+ {showEmailDeliveryNotice && emailLocked && (
+ <div className="mx-4 mt-4 rounded-lg border border-red-300 bg-red-50 p-4 sm:mx-12">
+ <p className="text-sm text-red-800">
+ We are experiencing delivery issues with some email providers
+ and are working to resolve this.
+ </p>
+ <p className="mt-2 text-sm text-red-800">
+ Check your junk/spam and quarantine folders and ensure that{" "}
+ <a
+ href="mailto:[email protected]"
+ className="font-medium underline"
+ >
+ </a>{" "}
+ is on your allowed senders list.
+ </p>
+ </div>
+ )}
+
<form
className="flex flex-col gap-4 px-4 pt-8 sm:px-12"
onSubmit={handleSubmit}