From 14ccf70a24e85e4aa569ddf9a49f3bc28aeb101b Mon Sep 17 00:00:00 2001
From: "gpt-engineer-app[bot]"
<159125892+gpt-engineer-app[bot]@users.noreply.github.com>
Date: Sat, 11 Jul 2026 18:20:48 +0000
Subject: [PATCH] Changes
Co-authored-by: wolfoftyreso-debug <250630591+wolfoftyreso-debug@users.noreply.github.com>
---
src/pages/Account.tsx | 104 ++++++++++++++++++++++++++++++++++--------
1 file changed, 84 insertions(+), 20 deletions(-)
diff --git a/src/pages/Account.tsx b/src/pages/Account.tsx
index 0a40fdc..08dfcbf 100644
--- a/src/pages/Account.tsx
+++ b/src/pages/Account.tsx
@@ -363,26 +363,90 @@ const Account = () => {
Mitt abonnemang
-
-
- Du har för närvarande inget aktivt abonnemang.
-
-
-
+ {subscription ? (
+
+
+
+
+ Ditt abonnemang
+
+
+ {subscription.kg_per_week ?? "—"} kg / vecka
+
+ {subscription.monthly_amount && (
+
+ {Math.round(subscription.monthly_amount * 1.25).toLocaleString("sv-SE")} kr/mån ink moms
+ {" · "}
+ {subscription.collection_method === "send_invoice" ? "Faktura" : "Kort"}
+
+ )}
+
+
+ {subscription.cancel_at_period_end
+ ? "Avslutas vid periodens slut"
+ : subscription.status === "active"
+ ? "Aktiv"
+ : subscription.status === "trialing"
+ ? "Provperiod"
+ : subscription.status === "past_due"
+ ? "Obetald – Stripe försöker igen"
+ : subscription.status === "canceled"
+ ? "Avslutad"
+ : subscription.status}
+
+
+
+ {subscription.current_period_end && (
+
+ {subscription.cancel_at_period_end || subscription.status === "canceled"
+ ? "Sista leveransperiod till: "
+ : "Nästa förnyelse: "}
+ {new Date(subscription.current_period_end).toLocaleDateString("sv-SE")}
+
+ )}
+
+
+
+ Ändra kort, ladda ner fakturor eller säg upp — tillgång kvar till periodens slut.
+
+
+ ) : (
+
+
+ Du har för närvarande inget aktivt abonnemang.
+
+
+
+ )}