From 113b20f6695ab6bd2b4d6a2ee398fc0989bf8f22 Mon Sep 17 00:00:00 2001
From: liuyi
Date: Fri, 20 Oct 2023 16:51:17 +0800
Subject: [PATCH] fix(core): payment ui issues (#4672)
---
.../general-setting/billing/index.tsx | 2 +-
.../general-setting/plans/index.tsx | 42 ++++++++++++-------
2 files changed, 28 insertions(+), 16 deletions(-)
diff --git a/packages/frontend/core/src/components/affine/setting-modal/general-setting/billing/index.tsx b/packages/frontend/core/src/components/affine/setting-modal/general-setting/billing/index.tsx
index ce82b5b83b..146f982470 100644
--- a/packages/frontend/core/src/components/affine/setting-modal/general-setting/billing/index.tsx
+++ b/packages/frontend/core/src/components/affine/setting-modal/general-setting/billing/index.tsx
@@ -44,7 +44,7 @@ export const BillingSettings = () => {
/>
{/* TODO: loading fallback */}
-
+
diff --git a/packages/frontend/core/src/components/affine/setting-modal/general-setting/plans/index.tsx b/packages/frontend/core/src/components/affine/setting-modal/general-setting/plans/index.tsx
index 9e488fd4a4..0c1e7af33b 100644
--- a/packages/frontend/core/src/components/affine/setting-modal/general-setting/plans/index.tsx
+++ b/packages/frontend/core/src/components/affine/setting-modal/general-setting/plans/index.tsx
@@ -144,12 +144,18 @@ const Settings = () => {
- You are current on the {currentPlan} plan. If you have any
- questions, please contact our{' '}
- {/*TODO: add action*/}customer support.
-
+ loggedIn ? (
+
+ You are current on the {currentPlan} plan. If you have any
+ questions, please contact our{' '}
+ {/*TODO: add action*/}customer support.
+
+ ) : (
+
+ This is the Pricing plans of AFFiNE Cloud. You can sign up or sign
+ in to your account first.
+
+ )
}
/>
@@ -193,15 +199,21 @@ const Settings = () => {
)}
-
- $
- {detail.type === 'dynamic'
- ? '?'
- : recurring === SubscriptionRecurring.Monthly
- ? detail.price
- : detail.yearlyPrice}
-
- per month
+ {detail.type === 'dynamic' ? (
+
+ Coming soon...
+
+ ) : (
+ <>
+
+ $
+ {recurring === SubscriptionRecurring.Monthly
+ ? detail.price
+ : detail.yearlyPrice}
+
+ per month
+ >
+ )}
{
// branches: