Show invited people the Rule, let them copy its cards for their community, and replace an expired invitation link.

This commit is contained in:
adilallo committed 2026-11-06 09:16:06 -07:00
1 parent 727a92a9ac
commit 3c984e00c5
37 files changed
+1962 -19

No files matched your search

+20
View File
@@ -0,0 +1,20 @@
export const INVITE_COPY_QUERY = "copy";
export const INVITE_COPY_VALUE = "1";
export const CREATE_FLOW_COPIED_QUERY = "copied";
export const CREATE_FLOW_COPIED_VALUE = "1";
export function invitedRulePath(
ruleId: string,
opts?: { copy?: boolean },
): string {
const base = `/invite/${encodeURIComponent(ruleId)}`;
if (opts?.copy) {
return `${base}?${INVITE_COPY_QUERY}=${INVITE_COPY_VALUE}`;
}
return base;
}
export function inviteExpiredPath(token?: string | null): string {
if (!token) return "/invite/expired";
return `/invite/expired?token=${encodeURIComponent(token)}`;
}