@@ -6,7 +6,10 @@ import {
66} from "@features/inbox/components/InboxEmptyStates" ;
77import { InboxLiveRail } from "@features/inbox/components/InboxLiveRail" ;
88import { InboxSourcesDialog } from "@features/inbox/components/InboxSourcesDialog" ;
9- import { useInboxReportsInfinite } from "@features/inbox/hooks/useInboxReports" ;
9+ import {
10+ useInboxAvailableSuggestedReviewers ,
11+ useInboxReportsInfinite ,
12+ } from "@features/inbox/hooks/useInboxReports" ;
1013import { useSignalSourceConfigs } from "@features/inbox/hooks/useSignalSourceConfigs" ;
1114import { useInboxReportSelectionStore } from "@features/inbox/stores/inboxReportSelectionStore" ;
1215import { useInboxSignalsFilterStore } from "@features/inbox/stores/inboxSignalsFilterStore" ;
@@ -15,6 +18,7 @@ import { useInboxSourcesDialogStore } from "@features/inbox/stores/inboxSourcesD
1518import {
1619 buildSignalReportListOrdering ,
1720 buildStatusFilterParam ,
21+ buildSuggestedReviewerFilterParam ,
1822 filterReportsBySearch ,
1923} from "@features/inbox/utils/filterReports" ;
2024import { INBOX_REFETCH_INTERVAL_MS } from "@features/inbox/utils/inboxConstants" ;
@@ -38,6 +42,9 @@ export function InboxSignalsTab() {
3842 const sourceProductFilter = useInboxSignalsFilterStore (
3943 ( s ) => s . sourceProductFilter ,
4044 ) ;
45+ const suggestedReviewerFilter = useInboxSignalsFilterStore (
46+ ( s ) => s . suggestedReviewerFilter ,
47+ ) ;
4148
4249 // ── Signal source configs ───────────────────────────────────────────────
4350 const { data : signalSourceConfigs } = useSignalSourceConfigs ( ) ;
@@ -64,6 +71,10 @@ export function InboxSignalsTab() {
6471 const inboxPollingActive = windowFocused && isInboxView ;
6572
6673 // ── Data fetching ───────────────────────────────────────────────────────
74+ useInboxAvailableSuggestedReviewers ( {
75+ enabled : isInboxView ,
76+ } ) ;
77+
6778 const inboxQueryParams = useMemo (
6879 ( ) : SignalReportsQueryParams => ( {
6980 status : buildStatusFilterParam ( statusFilter ) ,
@@ -72,8 +83,18 @@ export function InboxSignalsTab() {
7283 sourceProductFilter . length > 0
7384 ? sourceProductFilter . join ( "," )
7485 : undefined ,
86+ suggested_reviewers :
87+ suggestedReviewerFilter . length > 0
88+ ? buildSuggestedReviewerFilterParam ( suggestedReviewerFilter )
89+ : undefined ,
7590 } ) ,
76- [ statusFilter , sortField , sortDirection , sourceProductFilter ] ,
91+ [
92+ statusFilter ,
93+ sortField ,
94+ sortDirection ,
95+ sourceProductFilter ,
96+ suggestedReviewerFilter ,
97+ ] ,
7798 ) ;
7899
79100 const {
@@ -194,7 +215,9 @@ export function InboxSignalsTab() {
194215 // ── Layout mode (computed early — needed by focus effect below) ────────
195216 const hasReports = allReports . length > 0 ;
196217 const hasActiveFilters =
197- sourceProductFilter . length > 0 || statusFilter . length < 5 ;
218+ sourceProductFilter . length > 0 ||
219+ suggestedReviewerFilter . length > 0 ||
220+ statusFilter . length < 5 ;
198221 const shouldShowTwoPane =
199222 hasReports || ! ! searchQuery . trim ( ) || hasActiveFilters ;
200223
@@ -324,21 +347,15 @@ export function InboxSignalsTab() {
324347 className = "outline-none"
325348 onMouseDownCapture = { ( e ) => {
326349 const target = e . target as HTMLElement ;
327- if (
328- target . closest (
329- "[data-report-id], button, input, select, textarea, [role='checkbox']" ,
330- )
331- ) {
350+ if ( target . closest ( "[data-report-id]" ) ) {
332351 focusListPane ( ) ;
333352 }
334353 } }
335354 onFocusCapture = { ( e ) => {
336355 const target = e . target as HTMLElement ;
337356 if (
338357 target !== leftPaneRef . current &&
339- target . closest (
340- "[data-report-id], button, input, select, textarea, [role='checkbox']" ,
341- )
358+ target . closest ( "[data-report-id]" )
342359 ) {
343360 focusListPane ( ) ;
344361 }
0 commit comments