From 61122401a9050797640d2355331cadcb5bb11eb4 Mon Sep 17 00:00:00 2001 From: alma Date: Fri, 25 Apr 2025 20:55:41 +0200 Subject: [PATCH] panel 2 courier api restore --- app/courrier/page.tsx | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/app/courrier/page.tsx b/app/courrier/page.tsx index a9bd1839..1d6aa97a 100644 --- a/app/courrier/page.tsx +++ b/app/courrier/page.tsx @@ -1049,7 +1049,8 @@ export default function CourrierPage() { className="flex-1 overflow-y-auto" onScroll={handleScroll} > - {loading || isLoadingInitial ? ( + {/* Only show loading if we don't have emails yet - this prevents stuck loading states */} + {(loading || isLoadingInitial) && filteredEmails.length === 0 ? (
@@ -1092,6 +1093,13 @@ export default function CourrierPage() {
)} + {/* Show loading indicator at the bottom if we're still loading but have emails */} + {(loading || isLoadingInitial) && filteredEmails.length > 0 && ( +
+
+ Refreshing email list... +
+ )}
)} @@ -1102,8 +1110,8 @@ export default function CourrierPage() { // Update the email count in the header to show filtered count const renderEmailListHeader = () => (
-
-
+
+