Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion apps/web/src/app/dashboard/[guildId]/forms/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,16 @@ export default async function GuildFormsPage({
// Whether the viewer may fully manage a given form (guild manager or a per-form
// manage grant). Drives the per-form edit/preview/delete/export-definition buttons.
const manages = (formId: string) => manageScope.all || manageScope.formIds.includes(formId);
const base = appBaseUrl();
// Public form links (share link, QR, embed) point at the guild's verified
// custom domain when it has one, falling back to the primary domain otherwise.
const guildDomain = await prisma.guild.findUnique({
where: { id: guildId },
select: { customDomain: true, customDomainVerifiedAt: true },
});
const base =
guildDomain?.customDomain && guildDomain.customDomainVerifiedAt
? `https://${guildDomain.customDomain}`
: appBaseUrl();
const dict = await getDict();
const t = dict.dashboard;
const atFormLimit = !plan.isPro && forms.length >= FREE_FORM_LIMIT;
Expand Down