From 76a048e31c879d9102d89c36b1bd1529fade48f4 Mon Sep 17 00:00:00 2001 From: automated-signal <37887102+automated-signal@users.noreply.github.com> Date: Tue, 2 Jul 2024 12:17:45 -0500 Subject: [PATCH] Fix PiP and call settings in reconnecting calls --- stylesheets/_modules.scss | 5 ++++- ts/components/CallScreen.tsx | 1 + ts/util/callingIsReconnecting.ts | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/stylesheets/_modules.scss b/stylesheets/_modules.scss index 88a075265d..a809a383df 100644 --- a/stylesheets/_modules.scss +++ b/stylesheets/_modules.scss @@ -4258,6 +4258,10 @@ button.module-image__border-overlay:focus { } } + &__controls { + z-index: $z-index-above-above-base; + } + &__controls--fadeIn { @include module-ongoing-call__controls--fade-in; } @@ -4271,7 +4275,6 @@ button.module-image__border-overlay:focus { position: absolute; top: calc(32px + var(--title-bar-drag-area-height)); inset-inline-end: 0; - z-index: $z-index-above-above-base; display: flex; &__button { diff --git a/ts/components/CallScreen.tsx b/ts/components/CallScreen.tsx index 850a141376..b02321c378 100644 --- a/ts/components/CallScreen.tsx +++ b/ts/components/CallScreen.tsx @@ -491,6 +491,7 @@ export function CallScreen({ const controlsFadedOut = !showControls && !isAudioOnly && isConnected; const controlsFadeClass = classNames({ + 'module-ongoing-call__controls': true, 'module-ongoing-call__controls--fadeIn': (showControls || isAudioOnly) && !isConnected, 'module-ongoing-call__controls--fadeOut': controlsFadedOut, diff --git a/ts/util/callingIsReconnecting.ts b/ts/util/callingIsReconnecting.ts index 9c44b4b643..3ee7fe8a01 100644 --- a/ts/util/callingIsReconnecting.ts +++ b/ts/util/callingIsReconnecting.ts @@ -7,10 +7,11 @@ import { GroupCallConnectionState, } from '../types/Calling'; import type { ActiveCallType } from '../types/Calling'; +import { isGroupOrAdhocActiveCall } from './isGroupOrAdhocCall'; export function isReconnecting(activeCall: ActiveCallType): boolean { return ( - (activeCall.callMode === CallMode.Group && + (isGroupOrAdhocActiveCall(activeCall) && activeCall.connectionState === GroupCallConnectionState.Reconnecting) || (activeCall.callMode === CallMode.Direct && activeCall.callState === CallState.Reconnecting)