import { ActionsObservable, StateObservable } from 'redux-observable'; import { Observable } from 'rxjs'; import { RootState } from '../../../../rootStateTypes'; import { bulkUploadReceiptsSuccess, clearBulkUpload, fetchBulkUploadBatchDetailsSuccess, fetchCompletedTransactions, fetchMissingReceipts, restoreBulkUploadMatchingState, storeBatchDetails } from '../../reducers/missingReceiptsViewReducer'; export type ActionType = ReturnType | ReturnType | ReturnType | ReturnType | ReturnType | ReturnType | ReturnType; /** * After automatch completes for the active bulk-upload batch, refresh the two * caches that are not invalidated by the existing batch-details refresh path: * - Missing Receipts list (`transactionIdsBySelectedPeriod`) * - Completed transactions cache (`bulkUpload.completedTransactionsByPeriod`) * * The Unmatched tab is already kept fresh via `pusherBatchStatusCompletionEpic` * dispatching `fetchBulkUploadBatches({invalidateBatchDetailsCache: true})`, * which feeds `fetchMultipleBatchDetailsEpic` and re-stores batch details. * * Lifecycle mirrors `bulkUploadMatchResultToastEpic`: trigger on * `bulkUploadReceiptsSuccess` (fresh upload) or `restoreBulkUploadMatchingState` * (restored session), then wait for the first batch-details action for that * batchId — landing as either `fetchBulkUploadBatchDetailsSuccess` or * `storeBatchDetails`. `clearBulkUpload` cancels the in-flight wait. * * Refetches use `cacheOverride: true` to bypass per-tab cache guards, and * `fetchMissingReceipts` uses `refreshViewInBackground: true` to keep the * existing rows visible while fresh data is in flight (the authoritative * server filter `is_attachment_missing_only=true` removes matched rows once * the response lands). */ export declare const syncTabsAfterAutomatchEpic: (actions$: ActionsObservable, state$: StateObservable) => Observable;