add (really badly) state logic for the active iframe

This commit is contained in:
Gigiaj 2025-05-03 00:07:00 -05:00
parent c64dbb0563
commit 7808adbbe1

View file

@ -33,6 +33,7 @@ export function PersistentCallContainer({ isVisible, viewedRoomId }: PersistentC
activeCallRoomId, activeCallRoomId,
isChatOpen, isChatOpen,
isCallActive, isCallActive,
isPrimaryIframe,
setActiveCallRoomId, setActiveCallRoomId,
registerActiveClientWidgetApi, registerActiveClientWidgetApi,
} = useCallState(); } = useCallState();
@ -222,7 +223,7 @@ export function PersistentCallContainer({ isVisible, viewedRoomId }: PersistentC
position: 'absolute', position: 'absolute',
top: 0, top: 0,
left: 0, left: 0,
display: isViewingActiveCall ? 'flex' : 'none', display: isPrimaryIframe || isViewingActiveCall ? 'flex' : 'none',
width: '100%', width: '100%',
height: '100%', height: '100%',
border: 'none', border: 'none',
@ -242,7 +243,7 @@ export function PersistentCallContainer({ isVisible, viewedRoomId }: PersistentC
height: '100%', height: '100%',
border: 'none', border: 'none',
display: isViewingActiveCall ? 'none' : 'flex', display: !isPrimaryIframe || isViewingActiveCall ? 'none' : 'flex',
}} }}
title={`Persistent Element Call`} title={`Persistent Element Call`}
sandbox="allow-forms allow-scripts allow-same-origin allow-popups allow-modals allow-downloads" sandbox="allow-forms allow-scripts allow-same-origin allow-popups allow-modals allow-downloads"