fix(core): payment ui issues (#4672)

This commit is contained in:
liuyi 2023-10-20 16:51:17 +08:00 committed by forehalo
parent 95d37fc63f
commit 113b20f669
No known key found for this signature in database
2 changed files with 28 additions and 16 deletions

View File

@ -44,7 +44,7 @@ export const BillingSettings = () => {
/>
{/* TODO: loading fallback */}
<Suspense>
<SettingWrapper title="information">
<SettingWrapper title="Information">
<SubscriptionSettings />
</SettingWrapper>
</Suspense>

View File

@ -144,12 +144,18 @@ const Settings = () => {
<SettingHeader
title="Plans"
subtitle={
// TODO: different subtitle for un-logged user
<p>
You are current on the {currentPlan} plan. If you have any
questions, please contact our{' '}
<span>{/*TODO: add action*/}customer support</span>.
</p>
loggedIn ? (
<p>
You are current on the {currentPlan} plan. If you have any
questions, please contact our{' '}
<span>{/*TODO: add action*/}customer support</span>.
</p>
) : (
<p>
This is the Pricing plans of AFFiNE Cloud. You can sign up or sign
in to your account first.
</p>
)
}
/>
<div className={styles.wrapper}>
@ -193,15 +199,21 @@ const Settings = () => {
)}
</p>
<p>
<span className={styles.planPrice}>
$
{detail.type === 'dynamic'
? '?'
: recurring === SubscriptionRecurring.Monthly
? detail.price
: detail.yearlyPrice}
</span>
<span className={styles.planPriceDesc}>per month</span>
{detail.type === 'dynamic' ? (
<span className={styles.planPriceDesc}>
Coming soon...
</span>
) : (
<>
<span className={styles.planPrice}>
$
{recurring === SubscriptionRecurring.Monthly
? detail.price
: detail.yearlyPrice}
</span>
<span className={styles.planPriceDesc}>per month</span>
</>
)}
</p>
{
// branches: