fix
This commit is contained in:
@@ -474,10 +474,12 @@ const DocumentsTable = ({
|
|||||||
[activeCorrespondentIdSet, onCorrespondentClick],
|
[activeCorrespondentIdSet, onCorrespondentClick],
|
||||||
);
|
);
|
||||||
|
|
||||||
const noResults = rows.length === 0;
|
const noDocumentRows = rows.length === 0;
|
||||||
const showDefaultEmptyState = !showingSearchResults && !isFilterActive && !subfolders.length && noResults;
|
const hasFolderRows = !showingSearchResults && subfolders.length > 0;
|
||||||
const showListSearchEmptyState = showingSearchResults && noResults && !isGridView && !isSearchLoading;
|
const showTableRows = hasFolderRows || !noDocumentRows;
|
||||||
const showGridSearchEmptyState = isGridView && showingSearchResults && noResults && !isSearchLoading;
|
const showDefaultEmptyState = !showingSearchResults && !isFilterActive && !hasFolderRows && noDocumentRows;
|
||||||
|
const showListSearchEmptyState = showingSearchResults && noDocumentRows && !isGridView && !isSearchLoading;
|
||||||
|
const showGridSearchEmptyState = isGridView && showingSearchResults && noDocumentRows && !isSearchLoading;
|
||||||
const showSearchHint = showingSearchResults && rows.length > 0;
|
const showSearchHint = showingSearchResults && rows.length > 0;
|
||||||
const breadcrumbEntries = useMemo(() => (Array.isArray(breadcrumbs) ? breadcrumbs.filter(Boolean) : []), [breadcrumbs]);
|
const breadcrumbEntries = useMemo(() => (Array.isArray(breadcrumbs) ? breadcrumbs.filter(Boolean) : []), [breadcrumbs]);
|
||||||
const trailEntries = useMemo(() => {
|
const trailEntries = useMemo(() => {
|
||||||
@@ -773,7 +775,7 @@ const DocumentsTable = ({
|
|||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
</div>
|
</div>
|
||||||
) : noResults ? null : (
|
) : !showTableRows ? null : (
|
||||||
<table aria-multiselectable="true">
|
<table aria-multiselectable="true">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
Reference in New Issue
Block a user