Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

update onboarding upgrade screen

Steven Tey8cb272a3410e
diff --git a/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/page.tsx b/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/page.tsx
index 1426cdb2c5..0110f94364 100644
--- a/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/page.tsx
+++ b/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/page.tsx
@@ -7,7 +7,7 @@ export default function Plan() {
<StepPage
title="Choose your plan"
description="Find a plan that fits your needs"
- className="max-w-2xl"
+ className="max-w-screen-lg"
>
<PlanSelector />
<div className="mt-8 flex flex-col gap-3">
diff --git a/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/plan-selector.tsx b/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/plan-selector.tsx
index 42bb949b79..ca526fa4fd 100644
--- a/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/plan-selector.tsx
+++ b/apps/web/app/app.dub.co/(onboarding)/onboarding/(steps)/plan/plan-selector.tsx
@@ -4,7 +4,12 @@ import useWorkspace from "@/lib/swr/use-workspace";
import { PlanFeatures } from "@/ui/workspaces/plan-features";
import { UpgradePlanButton } from "@/ui/workspaces/upgrade-plan-button";
import { Badge, ToggleGroup } from "@dub/ui";
-import { PRO_PLAN, SELF_SERVE_PAID_PLANS } from "@dub/utils";
+import {
+ ADVANCED_PLAN,
+ BUSINESS_PLAN,
+ PRO_PLAN,
+ SELF_SERVE_PAID_PLANS,
+} from "@dub/utils";
import NumberFlow from "@number-flow/react";
import { useEffect, useState } from "react";
@@ -29,15 +34,10 @@ export function PlanSelector() {
}
/>
</div>
- <div className="mt-8 grid gap-4 sm:grid-cols-2">
+ <div className="mt-8 grid gap-4 sm:grid-cols-3">
<PlanCard name="Pro" plans={[PRO_PLAN]} period={periodTab} />
- <PlanCard
- name="Business"
- plans={SELF_SERVE_PAID_PLANS.filter(({ name }) =>
- name.startsWith("Business"),
- )}
- period={periodTab}
- />
+ <PlanCard name="Business" plans={[BUSINESS_PLAN]} period={periodTab} />
+ <PlanCard name="Advanced" plans={[ADVANCED_PLAN]} period={periodTab} />
</div>
</div>
);
diff --git a/apps/web/ui/workspaces/plan-features.tsx b/apps/web/ui/workspaces/plan-features.tsx
index ac03c96ffe..9e4af789c2 100644
--- a/apps/web/ui/workspaces/plan-features.tsx
+++ b/apps/web/ui/workspaces/plan-features.tsx
@@ -28,13 +28,13 @@ export function PlanFeatures({
animate="show"
className={cn("flex flex-col gap-2", className)}
>
- {selectedPlan.name.startsWith("Business") && (
+ {selectedPlan.featureTitle && (
<motion.div
key="business-plan-feature"
variants={STAGGER_CHILD_VARIANTS}
className="text-sm text-neutral-500"
>
- Everything in Pro, plus:
+ {selectedPlan.featureTitle}
</motion.div>
)}
{selectedPlan.features.map(({ text, footnote }, i) => (
diff --git a/packages/utils/src/constants/pricing.tsx b/packages/utils/src/constants/pricing.tsx
index 246dfe442f..a2281e25b4 100644
--- a/packages/utils/src/constants/pricing.tsx
+++ b/packages/utils/src/constants/pricing.tsx
@@ -604,6 +604,7 @@ export const PLAN_COMPARE_FEATURES: {
export const FREE_PLAN = PLANS.find((plan) => plan.name === "Free")!;
export const PRO_PLAN = PLANS.find((plan) => plan.name === "Pro")!;
export const BUSINESS_PLAN = PLANS.find((plan) => plan.name === "Business")!;
+export const ADVANCED_PLAN = PLANS.find((plan) => plan.name === "Advanced")!;
export const ENTERPRISE_PLAN = PLANS.find(
(plan) => plan.name === "Enterprise",
)!;
@@ -612,6 +613,7 @@ export const PUBLIC_PLANS = [
FREE_PLAN,
PRO_PLAN,
BUSINESS_PLAN,
+ ADVANCED_PLAN,
ENTERPRISE_PLAN,
];