From e3ad77b78c8f429899d2e4ffa0e0a9116ee121c6 Mon Sep 17 00:00:00 2001 From: ijeoma Date: Fri, 16 Oct 2026 04:17:05 +0100 Subject: [PATCH] fix: theme caching, form ARIA, PolicyCard guard, dashboard empty states - Cache ThemeContext localStorage read in module-level variable (#732) - Add aria-describedby, aria-invalid, aria-live to form modals (#733) - Guard PolicyCard currency formatter against undefined/null amounts (#734) - Add EmptyState with CTA for claims section in Dashboard (#735) --- src/app/dashboard/page.tsx | 10 +++++++--- src/components/BuyPolicyModal.tsx | 2 +- src/components/DepositModal.tsx | 7 +++++-- src/components/PolicyCard.tsx | 4 ++-- src/components/WithdrawModal.tsx | 3 ++- src/context/ThemeContext.tsx | 15 ++++++++++++--- 6 files changed, 29 insertions(+), 12 deletions(-) diff --git a/src/app/dashboard/page.tsx b/src/app/dashboard/page.tsx index 8f55376..ee41ccc 100644 --- a/src/app/dashboard/page.tsx +++ b/src/app/dashboard/page.tsx @@ -195,9 +195,13 @@ export default function DashboardPage() { ) : recentClaims.length === 0 ? ( -
- No claims submitted yet. -
+ ) : (
diff --git a/src/components/BuyPolicyModal.tsx b/src/components/BuyPolicyModal.tsx index b6a146d..1bd47f6 100644 --- a/src/components/BuyPolicyModal.tsx +++ b/src/components/BuyPolicyModal.tsx @@ -436,7 +436,7 @@ export function BuyPolicyModal({ product, onClose }: Props) { )} - {error &&

{error}

} + {error &&

{error}

}
diff --git a/src/components/DepositModal.tsx b/src/components/DepositModal.tsx index 3c9ba52..a2e60c0 100644 --- a/src/components/DepositModal.tsx +++ b/src/components/DepositModal.tsx @@ -151,10 +151,11 @@ export function DepositModal({ pool, onClose }: Props) {
-
@@ -193,7 +196,7 @@ export function DepositModal({ pool, onClose }: Props) { {paused && (

This pool is paused. Deposits are temporarily disabled.

)} - {error &&

{error}

} + {error &&

{error}

}