@@ -16,13 +16,6 @@ interface SubscriptionDisplayProps {
16
16
onManageSubscription : ( ) => void ;
17
17
}
18
18
19
- function getPlanDescription ( plan : Plan ) : string {
20
- if ( plan === Plan . Free ) {
21
- return "Basic features for small teams" ;
22
- }
23
- return "Advanced features for growing organizations" ;
24
- }
25
-
26
19
function ActionButton ( {
27
20
plan,
28
21
onManageSubscription,
@@ -32,12 +25,12 @@ function ActionButton({
32
25
} ) {
33
26
if ( plan === Plan . Free ) {
34
27
return (
35
- < Link href = "/pricing ">
36
- < Button className = "gap-2 ">
28
+ < Button asChild className = "gap-2 ">
29
+ < Link href = "/pricing ">
37
30
< BsStars className = "h-4 w-4" />
38
31
Upgrade
39
- </ Button >
40
- </ Link >
32
+ </ Link >
33
+ </ Button >
41
34
) ;
42
35
}
43
36
@@ -49,21 +42,6 @@ function ActionButton({
49
42
) ;
50
43
}
51
44
52
- function SupportLink ( { plan } : { plan : Plan } ) {
53
- if ( plan === Plan . Free ) {
54
- return null ;
55
- }
56
-
57
- return (
58
- < p className = "text-sm text-muted-foreground mt-2" >
59
- Need help with your subscription?{ " " }
60
- < Link href = "/support" className = "text-primary hover:underline" >
61
- Contact support
62
- </ Link >
63
- </ p >
64
- ) ;
65
- }
66
-
67
45
function SubscriptionContent ( {
68
46
subscription,
69
47
onManageSubscription,
@@ -81,15 +59,16 @@ function SubscriptionContent({
81
59
" Plan" }
82
60
</ p >
83
61
< p className = "text-sm text-muted-foreground" >
84
- { getPlanDescription ( subscription . plan ) }
62
+ { subscription . plan === Plan . Free
63
+ ? "Basic features for small teams"
64
+ : "Advanced features for growing organizations" }
85
65
</ p >
86
66
</ div >
87
67
< ActionButton
88
68
plan = { subscription . plan }
89
69
onManageSubscription = { onManageSubscription }
90
70
/>
91
71
</ div >
92
- < SupportLink plan = { subscription . plan } />
93
72
</ div >
94
73
) ;
95
74
}
0 commit comments