From 3d127d5852bb5f77c3dd30337be59853d934b301 Mon Sep 17 00:00:00 2001
From: Lukas <lukas.budginas@gmail.com>
Date: Tue, 18 Mar 2025 12:52:45 +0200
Subject: [PATCH] Show nothing if data is undefined and search wasn't executed

---
 .../account/tabs/interactions/InteractionsTabContent.tsx    | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/components/account/tabs/interactions/InteractionsTabContent.tsx b/components/account/tabs/interactions/InteractionsTabContent.tsx
index 78c421fd..f7e6256b 100644
--- a/components/account/tabs/interactions/InteractionsTabContent.tsx
+++ b/components/account/tabs/interactions/InteractionsTabContent.tsx
@@ -46,13 +46,14 @@ const InteractionsTabContent: React.FC<InteractionsTabContentProps> = ({
   } = useCommentSearch(props);
 
   const buildCommentSearchView = () => {
-    if (!isCommentSearchDataLoading && !commentSearchData?.total_operations) {
+    if (!commentSearchData) return;
+    if (!isCommentSearchDataFetching && !commentSearchData?.total_operations) {
       return (
         <div>
           <NoResult />
         </div>
       );
-    } else if (isCommentSearchDataFetching && isCommentSearchDataLoading) {
+    } else if (isCommentSearchDataLoading || isCommentSearchDataFetching) {
       return (
         <div className="flex justify-center text-center items-center">
           <Loader2 className="animate-spin mt-1 text-text h-12 w-12 ml-3 ..." />
@@ -92,6 +93,7 @@ const InteractionsTabContent: React.FC<InteractionsTabContentProps> = ({
         </CardHeader>
         <CardContent>
           <AccountPageInteractionSearch
+            setIsFiltersActive={setIsFiltersActive}
             isCommentSearchDataLoading={isCommentSearchDataFetching}
           />
         </CardContent>
-- 
GitLab