Skip to content

Commit f7471ab

Browse files
committed
Added credits wording
1 parent 53dc486 commit f7471ab

File tree

3 files changed

+91
-53
lines changed

3 files changed

+91
-53
lines changed

Diff for: components/pricing.tsx

+80-43
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ const PricingTier: React.FC<ExtendedPricingTierProps> = ({
116116
return (
117117
<div className="flex items-center">
118118
<span>
119-
Monthly refill of PearAI Credits for market-leading AI models
119+
Monthly refill of credits for market-leading AI models
120120
<PearCreditsTooltip type="standard" />
121121
</span>
122122
</div>
@@ -140,6 +140,24 @@ const PricingTier: React.FC<ExtendedPricingTierProps> = ({
140140
</span>
141141
</div>
142142
);
143+
} else if (feature?.startsWith("Pay-as-you-go")) {
144+
return (
145+
<div className="flex items-center">
146+
<span>
147+
Pay-as-you-go for additional credits
148+
<PayAsYouGoTooltip />
149+
</span>
150+
</div>
151+
);
152+
} else if (feature?.startsWith("Full access to PearAI Router")) {
153+
return (
154+
<div className="flex items-center">
155+
<span>
156+
Full access to PearAI Router & Hosted Servers
157+
<ServerAccessTooltip />
158+
</span>
159+
</div>
160+
);
143161
}
144162
return feature;
145163
};
@@ -161,8 +179,8 @@ const PricingTier: React.FC<ExtendedPricingTierProps> = ({
161179
<CardTitle className="text-2xl leading-6 text-primary-700">
162180
{title}
163181
&nbsp;
164-
{index === 1 && title === "Junior Engineer" && "(Monthly)"}
165-
{index === 2 && title === "10x Engineer" && "(Yearly)"}
182+
{index === 1 && title === "Maker" && "(Monthly)"}
183+
{index === 2 && title === "10x Maker" && "(Yearly)"}
166184
</CardTitle>
167185
<p className="text-base font-normal text-gray-600 sm:text-base md:text-sm">
168186
{index === 0 && isFree && (
@@ -401,9 +419,9 @@ const PricingPage: React.FC<PricingPageProps> = ({ user }) => {
401419
id="pricing-heading"
402420
className="mt-8 text-4xl font-medium leading-tight sm:text-4xl md:text-4xl lg:text-4xl"
403421
>
404-
Speed up your
422+
Make your next
405423
<br />
406-
development today.
424+
project today.
407425
</h1>
408426
</header>
409427

@@ -540,17 +558,6 @@ export default PricingPage;
540558
export const PearCreditsTooltip = ({ type }: { type: string }) => {
541559
const [isOpen, setIsOpen] = React.useState(false);
542560

543-
const pearCreditsCount = useMemo(() => {
544-
return (type: string) => {
545-
if (type === "free") {
546-
return "50";
547-
} else if (type === "enterprise") {
548-
return "1000";
549-
}
550-
return "700";
551-
};
552-
}, []);
553-
554561
return (
555562
<TooltipProvider>
556563
<Tooltip open={isOpen} onOpenChange={setIsOpen} delayDuration={50}>
@@ -562,43 +569,73 @@ export const PearCreditsTooltip = ({ type }: { type: string }) => {
562569
</TooltipTrigger>
563570
<TooltipContent sideOffset={5}>
564571
<p className="max-w-[250px]">
565-
Current built-in models for this plan include
572+
Current built-in models for this plan include (but not limited to)
566573
<ul className="list-disc pl-4">
567-
<li>Claude 3.5 Sonnet (new)</li>
574+
<li>PearAI Model</li>
575+
<li>Claude 3.5 Sonnet</li>
568576
<li>GPT4o</li>
569-
<li>GPT o1-preview</li>
570-
<li>GPT o1-mini</li>
577+
<li>Deepseek R1</li>
578+
<li>o1</li>
579+
<li>o3-mini</li>
571580
<li>Gemini 1.5 Pro</li>
572581
<li>Claude 3.5 Haiku (unlimited)</li>
573582
</ul>
574583
<br />
575-
Your PearAI Credits usage depend on your prompt input and output
576-
sizes. On average, this equates to around {pearCreditsCount(
577-
type,
578-
)}{" "}
579-
requests{type === "free" && " for our current free trial"}. For more
580-
info on usage. see{" "}
584+
Your PearAI Credits usage depends on the price of the underlying
585+
LLM, and your prompt&apos;s input and output sizes.
586+
</p>
587+
</TooltipContent>
588+
</Tooltip>
589+
</TooltipProvider>
590+
);
591+
};
592+
593+
export const PayAsYouGoTooltip = () => {
594+
const [isOpen, setIsOpen] = React.useState(false);
595+
596+
return (
597+
<TooltipProvider>
598+
<Tooltip open={isOpen} onOpenChange={setIsOpen} delayDuration={50}>
599+
<TooltipTrigger asChild>
600+
<Info
601+
className="mb-0.5 ml-1 inline-flex h-4 w-4 flex-shrink-0 cursor-pointer"
602+
onClick={() => setIsOpen((prev) => !prev)}
603+
/>
604+
</TooltipTrigger>
605+
<TooltipContent sideOffset={5}>
606+
<p className="max-w-[250px]">
607+
If you happen to run out of credits (which is unlikely), you can
608+
switch to a{" "}
581609
<Link
610+
href="/pay-as-you-go"
582611
className="text-primary-700 hover:text-primary-800"
583-
href="/docs/models-and-usage"
584612
>
585-
here
613+
pay-as-you-go extra credit plan
586614
</Link>
587-
.
588-
{type !== "free" && (
589-
<>
590-
<br /> <br />
591-
If you happen to run out of credits (which is unlikely), you can
592-
switch to a{" "}
593-
<Link
594-
href="/pay-as-you-go"
595-
className="text-primary-700 hover:text-primary-800"
596-
>
597-
pay-as-you-go extra credit plan
598-
</Link>
599-
, or use our free model for unlimited requests.
600-
</>
601-
)}
615+
, or use PearAI Mini free model for unlimited requests.
616+
</p>
617+
</TooltipContent>
618+
</Tooltip>
619+
</TooltipProvider>
620+
);
621+
};
622+
623+
export const ServerAccessTooltip = () => {
624+
const [isOpen, setIsOpen] = React.useState(false);
625+
626+
return (
627+
<TooltipProvider>
628+
<Tooltip open={isOpen} onOpenChange={setIsOpen} delayDuration={50}>
629+
<TooltipTrigger asChild>
630+
<Info
631+
className="mb-0.5 ml-1 inline-flex h-4 w-4 flex-shrink-0 cursor-pointer"
632+
onClick={() => setIsOpen((prev) => !prev)}
633+
/>
634+
</TooltipTrigger>
635+
<TooltipContent sideOffset={5}>
636+
<p className="max-w-[250px]">
637+
No need to configure and manage different API&apos;s and tools,
638+
PearAI will work out of the box.
602639
</p>
603640
</TooltipContent>
604641
</Tooltip>

Diff for: components/topup-modal.tsx

+3-2
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,9 @@ export default function TopUpModal() {
112112
<Tooltip>
113113
<TooltipContent className="-ml-9 max-w-[200px] border-gray-300 bg-white-50 text-center text-xs text-gray-700 dark:border-gray-200 dark:bg-secondary-main dark:text-gray-800">
114114
<p>
115-
Your PearAI Credits usage depend on your prompt
116-
input and output sizes.
115+
Your PearAI Credits usage depends on the price of
116+
the underlying LLM, and your prompt&apos;s input and
117+
output sizes.
117118
</p>
118119
</TooltipContent>
119120
</Tooltip>

Diff for: utils/constants.ts

+8-8
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ const NEXT_PUBLIC_STRIPE_WAITLIST_PRICE_ID_TEST =
2020
const NEXT_PUBLIC_STRIPE_MONTHLY_PRICE_ID = "price_1PoZiZ08N4O93LU5kCrdrXvI";
2121
const NEXT_PUBLIC_STRIPE_MONTHLY_PRICE_ID_TEST =
2222
"price_1Ppa9408N4O93LU5irNxLp5p";
23-
const NEXT_PUBLIC_STRIPE_ANNUAL_PRICE_ID = "price_1PpZUO08N4O93LU5FYFUyh43";
23+
const NEXT_PUBLIC_STRIPE_ANNUAL_PRICE_ID = "price_1Qvnlr08N4O93LU5W6LgZcge";
2424
const NEXT_PUBLIC_STRIPE_ANNUAL_PRICE_ID_TEST =
2525
"price_1PZUSi08N4O93LU5UVdlkfp2";
2626

@@ -81,29 +81,30 @@ export const PRICING_TIERS: {
8181
features: ["free", "Community Discord server"],
8282
},
8383
{
84-
title: "Junior Engineer",
84+
title: "Maker",
8585
price: "15",
8686
prevPrice: "18",
8787
description:
8888
"Get the monthly subscription, and we'll take care of you. 😎",
8989
features: [
90+
"Full access to PearAI Router & Hosted Servers",
9091
"custom-standard",
9192
"Full privacy: zero data retention policy with Anthropic",
9293
"Direct customer support by the founders and contributors",
93-
"Private Discord channel",
94+
"Pay-as-you-go for additional credits",
9495
],
9596
buttonText: "Get Started",
9697
priceId: STRIPE_PRICE_IDS.MONTHLY,
9798
index: 1,
9899
},
99100
{
100-
title: "10x Engineer",
101-
price: "10",
102-
prevPrice: "14",
101+
title: "10x Maker",
102+
price: "12",
103+
prevPrice: "15",
103104
description:
104105
"Pay one lump sum yearly, and you'll be treated like our VIP! 🤩",
105106
features: [
106-
"Everything from monthly",
107+
"Everything from monthly but lower price",
107108
"Priority for new feature requests",
108109
"Early access to new features",
109110
],
@@ -124,7 +125,6 @@ export const PRICING_TIERS: {
124125
"Full privacy: zero data retention policy with Anthropic",
125126
"Centralized Billing and Dashboard",
126127
"Direct customer support by the founders and contributors",
127-
"Private Discord Channel",
128128
],
129129
buttonText: "Get Started",
130130
priceId: STRIPE_PRICE_IDS.MONTHLY,

0 commit comments

Comments
 (0)