The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
final changes
Steven Teyd63bcb0cf88a
diff --git a/apps/web/ui/partners/format-discount-description.ts b/apps/web/ui/partners/format-discount-description.tsindex b1658fa4ba..0950942449 100644--- a/apps/web/ui/partners/format-discount-description.ts+++ b/apps/web/ui/partners/format-discount-description.ts@@ -20,9 +20,11 @@ export function formatDiscountDescription({parts.push(`New users get ${discountAmount} off `);if (discount.maxDuration === null) {- parts.push("for the their lifetime");+ parts.push("for their lifetime");} else if (discount.maxDuration === 0) {parts.push("for their first purchase");+ } else if (discount.maxDuration === 1) {+ parts.push("for their first month");} else if (discount.maxDuration && discount.maxDuration > 0) {parts.push(`for ${discount.maxDuration} ${pluralize("month", discount.maxDuration)}`,diff --git a/apps/web/ui/partners/program-reward-description.tsx b/apps/web/ui/partners/program-reward-description.tsxindex 811af72842..6a9ddc1c57 100644--- a/apps/web/ui/partners/program-reward-description.tsx+++ b/apps/web/ui/partners/program-reward-description.tsx@@ -84,20 +84,23 @@ export function ProgramRewardDescription({})}</strong>{" "}off{" "}- <strong className={cn("font-semibold", periodClassName)}>- {discount.maxDuration === null ? (- <strong className={cn("font-semibold", periodClassName)}>- {" "}- for their lifetime- </strong>- ) : discount.maxDuration && discount.maxDuration > 1 ? (- <strong className={cn("font-semibold", periodClassName)}>- for {discount.maxDuration} months- </strong>- ) : (- " for their first month"- )}- </strong>+ {discount.maxDuration === null ? (+ <strong className={cn("font-semibold", periodClassName)}>+ for their lifetime+ </strong>+ ) : discount.maxDuration === 0 ? (+ <strong className={cn("font-semibold", periodClassName)}>+ for their first purchase+ </strong>+ ) : discount.maxDuration === 1 ? (+ <strong className={cn("font-semibold", periodClassName)}>+ for their first month+ </strong>+ ) : discount.maxDuration && discount.maxDuration > 1 ? (+ <strong className={cn("font-semibold", periodClassName)}>+ for {discount.maxDuration} months+ </strong>+ ) : null}</>) : null}</>