diff --git a/src/room/InCallView.tsx b/src/room/InCallView.tsx index d50be3c9..ec981c45 100644 --- a/src/room/InCallView.tsx +++ b/src/room/InCallView.tsx @@ -260,10 +260,17 @@ export const InCallView: FC = ({ [setSettingsModalOpen], ); - const openProfile = useCallback(() => { - setSettingsTab("profile"); - setSettingsModalOpen(true); - }, [setSettingsTab, setSettingsModalOpen]); + const openProfile = useMemo( + () => + // Profile settings are unavailable in widget mode + widget === null + ? (): void => { + setSettingsTab("profile"); + setSettingsModalOpen(true); + } + : null, + [setSettingsTab, setSettingsModalOpen], + ); const [headerRef, headerBounds] = useMeasure(); const [footerRef, footerBounds] = useMeasure(); diff --git a/src/tile/GridTile.tsx b/src/tile/GridTile.tsx index a85abe23..1eb0b933 100644 --- a/src/tile/GridTile.tsx +++ b/src/tile/GridTile.tsx @@ -160,7 +160,7 @@ UserMediaTile.displayName = "UserMediaTile"; interface LocalUserMediaTileProps extends TileProps { vm: LocalUserMediaViewModel; - onOpenProfile: () => void; + onOpenProfile: (() => void) | null; } const LocalUserMediaTile = forwardRef( @@ -191,11 +191,13 @@ const LocalUserMediaTile = forwardRef( /> } menuEnd={ - + onOpenProfile && ( + + ) } {...props} /> @@ -268,7 +270,7 @@ RemoteUserMediaTile.displayName = "RemoteUserMediaTile"; interface GridTileProps { vm: UserMediaViewModel; - onOpenProfile: () => void; + onOpenProfile: (() => void) | null; targetWidth: number; targetHeight: number; className?: string;