feat: Implement Phase 4 Streamlined Enhancements

This commit is contained in:
gpt-engineer-app[bot]
2025-10-13 22:46:42 +00:00
parent 787e16753e
commit 68a2572c23
3 changed files with 52 additions and 12 deletions

View File

@@ -184,6 +184,18 @@ export function useModerationQueueManager(config: ModerationQueueManagerConfig):
}
}, [queueQuery.isLoading, queueQuery.isRefreshing]);
// Show error toast when query fails
useEffect(() => {
if (queueQuery.error) {
console.error('❌ Queue query error:', queueQuery.error);
toast({
variant: 'destructive',
title: 'Failed to Load Queue',
description: queueQuery.error.message || 'An error occurred while fetching the moderation queue.',
});
}
}, [queueQuery.error, toast]);
// Update total count for pagination
useEffect(() => {
paginationRef.current.setTotalCount(queueQuery.totalCount);