diff --git a/frontend/src/documents/data/useDocumentMutations.ts b/frontend/src/documents/data/useDocumentMutations.ts index 89bf71b..034e64d 100644 --- a/frontend/src/documents/data/useDocumentMutations.ts +++ b/frontend/src/documents/data/useDocumentMutations.ts @@ -127,7 +127,7 @@ interface UseDocumentMutationsResult { documentId: DocumentId, nextIssuedDate: number | null, ) => Promise; - handleTagRemove: ( + handleDocumentTagDetach: ( documentId?: DocumentId, tagId?: DocumentId, ) => Promise; @@ -588,7 +588,7 @@ const useDocumentMutations = ({ [updateDocumentCaches], ); - const handleTagRemove = useCallback( + const handleDocumentTagDetach = useCallback( async ( documentId?: DocumentId, tagId?: DocumentId, @@ -695,7 +695,7 @@ const useDocumentMutations = ({ handleDocumentTagAttach, handleDocumentTitleUpdate, handleDocumentIssuedUpdate, - handleTagRemove, + handleDocumentTagDetach, handleFolderDelete, }; }; diff --git a/frontend/src/documents/data/useDocumentsWorkspace.ts b/frontend/src/documents/data/useDocumentsWorkspace.ts index 7cd6554..ca5bdab 100644 --- a/frontend/src/documents/data/useDocumentsWorkspace.ts +++ b/frontend/src/documents/data/useDocumentsWorkspace.ts @@ -694,7 +694,7 @@ const useDocumentsWorkspace = ({ handleDocumentTagAttach, handleDocumentTitleUpdate, handleDocumentIssuedUpdate, - handleTagRemove, + handleDocumentTagDetach, } = useDocumentMutations({ documentLookup, folderLabelMap, @@ -1003,7 +1003,7 @@ const useDocumentsWorkspace = ({ window.removeEventListener('dragend', handleTagDragEnd, true); setTagRemovalCursor(false); }; - }, [handleTagRemove, setTagRemovalCursor]); + }, [handleDocumentTagDetach, setTagRemovalCursor]); const { @@ -1026,7 +1026,7 @@ const useDocumentsWorkspace = ({ handleDocumentTitleUpdate, handleDocumentIssuedUpdate, handleDocumentTagAdd, - handleTagRemove, + handleDocumentTagDetach, ensureAssetUrl, getAsset: getDocumentAsset, correspondents, @@ -1098,7 +1098,8 @@ const useDocumentsWorkspace = ({ activeTagFilters, handleTagUpdate, handleTagDelete, - handleDocumentTagDrop: handleDocumentTagAttach, + handleDocumentTagAttach, + handleDocumentTagDetach, handleBulkTagAddFromDetail, handleBulkTagRemoveFromDetail, openTagsModal, diff --git a/frontend/src/viewer/logic/useDetailWorkspace.ts b/frontend/src/viewer/logic/useDetailWorkspace.ts index f552c19..de6bea5 100644 --- a/frontend/src/viewer/logic/useDetailWorkspace.ts +++ b/frontend/src/viewer/logic/useDetailWorkspace.ts @@ -27,7 +27,7 @@ interface UseDetailWorkspaceArgs { handleDocumentTitleUpdate?: (docId: Identifier, title: string) => Promise | boolean; handleDocumentIssuedUpdate?: (docId: Identifier, issued: number | null) => Promise | boolean; handleDocumentTagAdd?: (doc: Document, value: string, context?: { option?: unknown }) => void; - handleTagRemove?: (...args: unknown[]) => void; + handleDocumentTagDetach?: (...args: unknown[]) => void; ensureAssetUrl?: EnsureAssetUrl; getAsset?: GetAsset; correspondents?: unknown[]; @@ -64,7 +64,7 @@ const useDetailWorkspace = ({ handleDocumentTitleUpdate, handleDocumentIssuedUpdate, handleDocumentTagAdd, - handleTagRemove, + handleDocumentTagDetach, ensureAssetUrl, getAsset, correspondents, @@ -184,7 +184,7 @@ const useDetailWorkspace = ({ tags, tagLookupById, onTagAdd: handleDocumentTagAdd, - onTagRemove: handleTagRemove, + onTagRemove: handleDocumentTagDetach, onOpenPreview: openDocumentPreview, activePreviewId, onUpdateTitle: handleDocumentTitleUpdate, @@ -212,7 +212,7 @@ const useDetailWorkspace = ({ handleDocumentTagAdd, handleDocumentIssuedUpdate, handleDocumentTitleUpdate, - handleTagRemove, + handleDocumentTagDetach, folderNodes, ensureFolderData, openDocumentPreview,