Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

Merge origin/main into codex/fix-custom-domain-dns-records

Richie McIlroya302d5756de3
diff --cc apps/web/app/(org)/dashboard/settings/organization/components/CustomDomainDialog/VerifyStep.tsx
index f559bb4d1,5c8eb5d35..3b11cc847
--- a/apps/web/app/(org)/dashboard/settings/organization/components/CustomDomainDialog/VerifyStep.tsx
+++ b/apps/web/app/(org)/dashboard/settings/organization/components/CustomDomainDialog/VerifyStep.tsx
@@@ -447,73 -432,6 +447,72 @@@ const VerifyStep = (
</div>
</div>
)}
+
- {/* Fallback when Vercel returned no recommendations */}
+ {showFallbackRecords && (
+ <div className="overflow-hidden rounded-lg border border-gray-4">
+ <div className="px-4 py-3 border-b bg-gray-2 border-gray-4">
+ <p className="font-medium text-md text-gray-12">
+ {fallbackIsSubdomain
+ ? "CNAME Record Configuration"
+ : "A Record Configuration"}
+ </p>
+ <p className="mt-1 text-sm text-gray-10">
+ Add this record to your domain:
+ </p>
+ </div>
+ <div className="px-4 py-3">
+ <dl className="grid gap-4">
+ <div className="grid grid-cols-[100px,1fr] items-center">
+ <dt className="text-sm font-medium text-gray-12">Type</dt>
+ <dd className="text-sm text-gray-10">
+ {fallbackIsSubdomain ? "CNAME" : "A"}
+ </dd>
+ </div>
+ <div className="grid grid-cols-[100px,1fr] items-center">
+ <dt className="text-sm font-medium text-gray-12">Name</dt>
+ <dd className="text-sm text-gray-10">
+ <code className="px-2 py-1 text-xs rounded bg-gray-4">
+ {fallbackIsSubdomain ? domain.split(".")[0] : "@"}
+ </code>
+ </dd>
+ </div>
+ <div className="grid grid-cols-[100px,1fr] items-center">
+ <dt className="text-sm font-medium text-gray-12">
+ Value
+ </dt>
+ <dd className="text-sm text-gray-10">
+ <div className="flex items-center justify-between gap-1.5 bg-gray-3 px-2 py-1 rounded-lg flex-1 min-w-0 border border-gray-4">
+ <code className="text-xs text-gray-10">
+ {fallbackIsSubdomain
+ ? "cname.vercel-dns.com"
+ : "76.76.21.21"}
+ </code>
+ <button
+ type="button"
+ onClick={() =>
+ handleCopy(
+ fallbackIsSubdomain
+ ? "cname.vercel-dns.com"
+ : "76.76.21.21",
+ "fallback-record",
+ )
+ }
+ className="p-1 rounded-md transition-colors hover:bg-gray-1 shrink-0"
+ title="Copy to clipboard"
+ >
+ {copiedField === "fallback-record" ? (
+ <Check className="size-3.5 text-green-500" />
+ ) : (
+ <Copy className="size-3.5 text-gray-10" />
+ )}
+ </button>
+ </div>
+ </dd>
+ </div>
+ </dl>
+ </div>
+ </div>
+ )}
</div>
)
)}