(columns);
@@ -35,11 +36,18 @@ const OpeningsSearchTab: React.FC = () => {
setFiltersApplied(!filtersApplied);
};
+ const hasFilters = countActiveFilters(filters) > 0 || searchTerm.length > 0;
+
+
const handleSearch = () => {
- toggleFiltersApplied();
- setFiltersApplied(true); // Set filters as applied to show results
- setFinalParams({...searchParams, ...filters, page: currentPage, perPage: itemsPerPage }); // Only update finalParams on search
- setIsSearchTriggered(true); // Trigger the search
+ setIsNoFilterSearch(!hasFilters);
+
+ if(hasFilters){
+ toggleFiltersApplied();
+ setFiltersApplied(true); // Set filters as applied to show results
+ setFinalParams({...searchParams, ...filters, page: currentPage, perPage: itemsPerPage }); // Only update finalParams on search
+ setIsSearchTriggered(true); // Trigger the search
+ }
};
const handleFiltersChanged = () => {
@@ -116,6 +124,7 @@ const OpeningsSearchTab: React.FC = () => {
<>
{showSpatial ? (
diff --git a/frontend/src/components/TruncatedText/index.tsx b/frontend/src/components/TruncatedText/index.tsx
index 9d69c273..aedfc31a 100644
--- a/frontend/src/components/TruncatedText/index.tsx
+++ b/frontend/src/components/TruncatedText/index.tsx
@@ -14,7 +14,7 @@ const TruncatedText: React.FC<{text: string, maxLength?: number, parentWidth?: n
align="bottom-left"
autoAlign
>
- {truncated}
+ {truncated}
;
}