fix
This commit is contained in:
@@ -2770,6 +2770,8 @@ export const createDesktopSurface = ({
|
|||||||
onBulkReanalyze,
|
onBulkReanalyze,
|
||||||
folderOptions,
|
folderOptions,
|
||||||
onMoveDocumentsToFolder,
|
onMoveDocumentsToFolder,
|
||||||
|
searchIncludeDescendants,
|
||||||
|
onToggleSearchIncludeDescendants,
|
||||||
} = workspaceProps;
|
} = workspaceProps;
|
||||||
|
|
||||||
const title = Array.isArray(searchResults) ? 'Search results' : currentFolderName;
|
const title = Array.isArray(searchResults) ? 'Search results' : currentFolderName;
|
||||||
@@ -2786,6 +2788,8 @@ export const createDesktopSurface = ({
|
|||||||
onViewModeChange,
|
onViewModeChange,
|
||||||
onRefresh,
|
onRefresh,
|
||||||
onShowDeskHelp: viewMode === 'desk' ? workspaceProps?.onOpenHelp : null,
|
onShowDeskHelp: viewMode === 'desk' ? workspaceProps?.onOpenHelp : null,
|
||||||
|
includeDescendants: searchIncludeDescendants,
|
||||||
|
onToggleIncludeDescendants: onToggleSearchIncludeDescendants,
|
||||||
});
|
});
|
||||||
|
|
||||||
const floatingActions = selectionCount > 0
|
const floatingActions = selectionCount > 0
|
||||||
|
|||||||
@@ -3024,6 +3024,13 @@ const AppLayout = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (uniqueIdSet.size) {
|
if (uniqueIdSet.size) {
|
||||||
|
setSearchResults((prev) => {
|
||||||
|
if (!Array.isArray(prev) || !prev.length) {
|
||||||
|
return prev;
|
||||||
|
}
|
||||||
|
const filtered = prev.filter((doc) => doc && !uniqueIdSet.has(doc.id));
|
||||||
|
return filtered.length === prev.length ? prev : filtered;
|
||||||
|
});
|
||||||
setDocuments((prev) => prev.filter((doc) => !uniqueIdSet.has(doc.id)));
|
setDocuments((prev) => prev.filter((doc) => !uniqueIdSet.has(doc.id)));
|
||||||
setFolderContents((prev) => {
|
setFolderContents((prev) => {
|
||||||
if (!prev.size) {
|
if (!prev.size) {
|
||||||
@@ -5063,6 +5070,8 @@ const AppLayout = () => {
|
|||||||
onBulkReanalyze: handleBulkSelectionReanalyze,
|
onBulkReanalyze: handleBulkSelectionReanalyze,
|
||||||
folderOptions,
|
folderOptions,
|
||||||
onMoveDocumentsToFolder: moveDocumentsToFolder,
|
onMoveDocumentsToFolder: moveDocumentsToFolder,
|
||||||
|
searchIncludeDescendants,
|
||||||
|
onToggleSearchIncludeDescendants: toggleSearchIncludeDescendants,
|
||||||
}),
|
}),
|
||||||
[
|
[
|
||||||
documents,
|
documents,
|
||||||
@@ -5105,6 +5114,8 @@ const AppLayout = () => {
|
|||||||
handleBulkSelectionReanalyze,
|
handleBulkSelectionReanalyze,
|
||||||
folderOptions,
|
folderOptions,
|
||||||
moveDocumentsToFolder,
|
moveDocumentsToFolder,
|
||||||
|
searchIncludeDescendants,
|
||||||
|
toggleSearchIncludeDescendants,
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user