@@ -53,6 +53,8 @@ import {
5353 OPTIONAL_THREAD_SLOT ,
5454} from './ChatLayout/constants.ts' ;
5555import { ChatSkipNavigation } from './AccessibilityNavigation/ChatSkipNavigation.tsx' ;
56+ import { SlotGeometryProvider } from 'stream-chat-react/slot-geometry' ;
57+ import { AlsoSentInChannelIndicator } from './ChatLayout/AlsoSentInChannelIndicator.tsx' ;
5658import { ChannelsPanels , ThreadsPanels } from './ChatLayout/Panels.tsx' ;
5759import { SidebarProvider } from './ChatLayout/SidebarContext.tsx' ;
5860import {
@@ -481,7 +483,6 @@ const App = () => {
481483 [ initialPanelLayout . leftPanel . width , initialPanelLayout . threadPanel . width ] ,
482484 ) ;
483485
484- // Memoized so the ChatView `views` map keeps a stable reference across renders.
485486 const chatViews = useMemo (
486487 ( ) => ( {
487488 channels : (
@@ -531,6 +532,10 @@ const App = () => {
531532 return (
532533 < WithComponents
533534 overrides = { {
535+ // Coverage-aware "Also sent in channel β View": records a reveal intent that a
536+ // channels-view effect resolves after navigation (works across the threads β channels
537+ // switch; closes the covering thread only when it actually covers).
538+ MessageAlsoSentInChannelIndicator : AlsoSentInChannelIndicator ,
534539 emojiSearchIndex : SearchIndex ,
535540 EmojiPicker : EmojiPickerWithCustomOptions ,
536541 NotificationList : ConfigurableNotificationList ,
@@ -566,16 +571,22 @@ const App = () => {
566571 iconOnly = { chatView . iconOnly }
567572 layoutRef = { appLayoutRef }
568573 />
569- < ChatView
570- dialogManagerId = { globalDialogManager }
571- layouts = { chatViewLayouts }
572- maxSlots = { 2 }
573- minSlots = { 2 }
574- views = { chatViews }
575- >
576- < ChatStateSync initialChatView = { initialChatView } />
577- < SidebarLayoutSync />
578- </ ChatView >
574+ { /* Geometry provider spans the whole ChatView so slot-coverage state and the reveal
575+ intent are shared across views (the "Also sent in channel β View" indicator sets
576+ the intent in the threads view; the channels panels resolve it after navigating).
577+ Instance-scoped β not a module singleton β so other chat surfaces don't collide. */ }
578+ < SlotGeometryProvider >
579+ < ChatView
580+ dialogManagerId = { globalDialogManager }
581+ layouts = { chatViewLayouts }
582+ maxSlots = { 2 }
583+ minSlots = { 2 }
584+ views = { chatViews }
585+ >
586+ < ChatStateSync initialChatView = { initialChatView } />
587+ < SidebarLayoutSync />
588+ </ ChatView >
589+ </ SlotGeometryProvider >
579590 </ div >
580591 </ div >
581592 { /* The single-channel scenario floats over the full app in a draggable modal (the full
0 commit comments