diff options
| author | Ben Sima <ben@bsima.me> | 2025-11-12 15:53:20 -0500 |
|---|---|---|
| committer | Ben Sima <ben@bsima.me> | 2025-11-12 15:53:20 -0500 |
| commit | b3f4eb6e5f8807700942d01fe592678e8c76be87 (patch) | |
| tree | b550ebaa78adb4abfcc3f59981d16f4ce0ed7287 /Biz | |
| parent | c846966535ef2531eab581a8c4e77f6bebdd1b5b (diff) | |
Make Upgrade Now an actual button in free tier banner
- Replace '[Upgrade Now]' text link with proper btn-warning button -
Add arrow-up-circle icon to Upgrade Now button - Hide Billing button
for free tier users (they now have Upgrade Now) - Keep Billing button
visible for paid tier users
Diffstat (limited to 'Biz')
| -rw-r--r-- | Biz/PodcastItLater/Web.py | 28 |
1 files changed, 22 insertions, 6 deletions
diff --git a/Biz/PodcastItLater/Web.py b/Biz/PodcastItLater/Web.py index c1abf02..8881c3a 100644 --- a/Biz/PodcastItLater/Web.py +++ b/Biz/PodcastItLater/Web.py @@ -939,14 +939,28 @@ class HomePage(Component[AnyChildren, HomePageAttrs]): articles_left = max(0, articles_limit - articles_used) return html.div( - html.strong("Free: "), - f"{articles_left} articles left ", + html.div( + html.strong("Free: "), + f"{articles_left} articles left", + classes=["mb-2"], + ), html.a( - "[Upgrade Now]", + html.i( + classes=[ + "bi", + "bi-arrow-up-circle", + "me-1", + ], + ), + "Upgrade Now", href="/billing", - classes=["text-decoration-none"], + classes=[ + "btn", + "btn-warning", + "btn-sm", + ], ), - classes=["mb-3", "text-warning"], + classes=["mb-3"], ) # Paid plan - just show plan name return html.div( @@ -1053,7 +1067,9 @@ class HomePage(Component[AnyChildren, HomePageAttrs]): "me-2", "mb-2", ], - ), + ) + if user.get("plan_tier", "free") != "free" + else html.span(), html.a( html.i( classes=[ |
