Invitation page shows its gift package; person invites: e-mail and link only
- The admin invitation's page lists the package that comes with it (the public invitation view returns it; the promo code stays in the e-mail). - Inviting a person: no Facebook, WhatsApp or share-sheet buttons, only the e-mail and copying the link. - contents() moved to lib/packageContents so server pages can use it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
@@ -6,6 +6,7 @@ import { Logo } from "@/components/SiteHeader";
|
||||
import { ZodiacWheel } from "@/components/ZodiacWheel";
|
||||
import { BACKEND_URL, getMe } from "@/lib/server";
|
||||
import { formatDate } from "@/lib/astro";
|
||||
import { contents } from "@/lib/packageContents";
|
||||
import type { InvitationLanding, PublicConfig } from "@/lib/types";
|
||||
|
||||
import { AppleLogin } from "./AppleLogin";
|
||||
@@ -79,6 +80,19 @@ function InvitationCard({
|
||||
{invitation.inviter_name ? <strong>{invitation.inviter_name}</strong> : "Valaki"} meghívott a Sorsfonalakra.
|
||||
</p>
|
||||
{invitation.message && <blockquote className="invite-quote">{invitation.message}</blockquote>}
|
||||
{invitation.gift && (
|
||||
<div className="invite-gift">
|
||||
<p style={{ margin: 0 }}>
|
||||
Ajándékba kapod a <strong>„{invitation.gift.name}”</strong> csomagot, a regisztrációval magától
|
||||
jóváíródik:
|
||||
</p>
|
||||
<ul>
|
||||
{contents(invitation.gift).map((line) => (
|
||||
<li key={line}>{line}</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
)}
|
||||
<p className="hint" style={{ margin: 0 }}>
|
||||
Bármelyik {apple ? "Google- vagy Apple-fiókoddal" : "Google-fiókoddal"}
|
||||
{password ? ", vagy e-mail-címmel regisztrálva" : ""} elfogadhatod. Érvényes:{" "}
|
||||
|
||||
@@ -658,6 +658,11 @@ a.pair-row:hover strong { color: var(--gold); }
|
||||
|
||||
/* Invitations */
|
||||
.invite-card { display: flex; flex-direction: column; gap: 8px; }
|
||||
.invite-gift {
|
||||
border: 1px solid rgba(217, 180, 106, 0.45); background: rgba(217, 180, 106, 0.07); border-radius: 10px;
|
||||
padding: 10px 14px; font-size: 14px;
|
||||
}
|
||||
.invite-gift ul { margin: 6px 0 0; padding-left: 18px; color: var(--ink-2); }
|
||||
.invite-quote {
|
||||
margin: 0; padding: 2px 0 2px 14px; border-left: 3px solid var(--gold);
|
||||
font-style: italic; white-space: pre-line; color: var(--ink);
|
||||
|
||||
Reference in New Issue
Block a user