fix back to video button

This commit is contained in:
Timo
2025-06-25 16:23:19 +02:00
parent b01a1292c1
commit a98ced3e5b
2 changed files with 10 additions and 4 deletions

View File

@@ -14,10 +14,10 @@ import styles from "./EarpieceOverlay.module.css";
interface Props {
show: boolean;
onBackButtonPressed?: (() => void) | null;
onBackToVideoPressed?: (() => void) | null;
}
export const EarpieceOverlay: FC<Props> = ({ show }) => {
export const EarpieceOverlay: FC<Props> = ({ show, onBackToVideoPressed }) => {
const { t } = useTranslation();
return (
<div className={styles.overlay} data-show={show}>
@@ -28,7 +28,13 @@ export const EarpieceOverlay: FC<Props> = ({ show }) => {
{t("earpiece.overlay_title")}
</Heading>
<Text>{t("earpiece.overlay_description")}</Text>
<Button kind="primary" size="sm">
<Button
kind="primary"
size="sm"
onClick={() => {
onBackToVideoPressed?.();
}}
>
{t("earpiece.overlay_back_button")}
</Button>
</div>

View File

@@ -789,7 +789,7 @@ export const InCallView: FC<InCallViewProps> = ({
<ReactionsAudioRenderer vm={vm} muted={muteAllAudio} />
<EarpieceOverlay
show={earpieceMode}
onBackButtonPressed={toggleEarpieceMode}
onBackToVideoPressed={toggleEarpieceMode}
/>
<ReactionsOverlay vm={vm} />
{footer}