mirror of
https://github.com/vector-im/element-call.git
synced 2026-08-29 21:15:19 +00:00
display missing lk participant + fix tile multiplier
This commit is contained in:
@@ -406,10 +406,7 @@ export class CallViewModel extends ViewModel {
|
|||||||
const indexedMediaId = `${mediaId}:${i}`;
|
const indexedMediaId = `${mediaId}:${i}`;
|
||||||
const prevMedia = prevItems.get(indexedMediaId);
|
const prevMedia = prevItems.get(indexedMediaId);
|
||||||
if (prevMedia && prevMedia instanceof UserMedia) {
|
if (prevMedia && prevMedia instanceof UserMedia) {
|
||||||
if (
|
if (prevMedia.participant.value !== participant) {
|
||||||
prevMedia.participant.value === undefined &&
|
|
||||||
participant !== undefined
|
|
||||||
) {
|
|
||||||
// Update the BahviourSubject in the UserMedia.
|
// Update the BahviourSubject in the UserMedia.
|
||||||
prevMedia.participant.next(participant);
|
prevMedia.participant.next(participant);
|
||||||
}
|
}
|
||||||
@@ -421,7 +418,7 @@ export class CallViewModel extends ViewModel {
|
|||||||
// Once a participant appears we will update the BehaviourSubject. (see above)
|
// Once a participant appears we will update the BehaviourSubject. (see above)
|
||||||
prevMedia ??
|
prevMedia ??
|
||||||
new UserMedia(
|
new UserMedia(
|
||||||
mediaId,
|
indexedMediaId,
|
||||||
member,
|
member,
|
||||||
participant,
|
participant,
|
||||||
this.encryptionSystem,
|
this.encryptionSystem,
|
||||||
|
|||||||
@@ -84,6 +84,9 @@ const UserMediaTile = forwardRef<HTMLDivElement, UserMediaTileProps>(
|
|||||||
const videoEnabled = useObservableEagerState(vm.videoEnabled);
|
const videoEnabled = useObservableEagerState(vm.videoEnabled);
|
||||||
const speaking = useObservableEagerState(vm.speaking);
|
const speaking = useObservableEagerState(vm.speaking);
|
||||||
const cropVideo = useObservableEagerState(vm.cropVideo);
|
const cropVideo = useObservableEagerState(vm.cropVideo);
|
||||||
|
const isRTCParticipantAvailable = useObservableEagerState(
|
||||||
|
vm.isRTCParticipantAvailable,
|
||||||
|
);
|
||||||
const onSelectFitContain = useCallback(
|
const onSelectFitContain = useCallback(
|
||||||
(e: Event) => {
|
(e: Event) => {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
@@ -134,7 +137,10 @@ const UserMediaTile = forwardRef<HTMLDivElement, UserMediaTileProps>(
|
|||||||
className={styles.muteIcon}
|
className={styles.muteIcon}
|
||||||
/>
|
/>
|
||||||
}
|
}
|
||||||
displayName={displayName}
|
displayName={
|
||||||
|
displayName +
|
||||||
|
(isRTCParticipantAvailable ? "" : " missing Livekit Participant...")
|
||||||
|
}
|
||||||
primaryButton={
|
primaryButton={
|
||||||
<Menu
|
<Menu
|
||||||
open={menuOpen}
|
open={menuOpen}
|
||||||
@@ -226,6 +232,7 @@ const RemoteUserMediaTile = forwardRef<
|
|||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
const locallyMuted = useObservableEagerState(vm.locallyMuted);
|
const locallyMuted = useObservableEagerState(vm.locallyMuted);
|
||||||
const localVolume = useObservableEagerState(vm.localVolume);
|
const localVolume = useObservableEagerState(vm.localVolume);
|
||||||
|
|
||||||
const onSelectMute = useCallback(
|
const onSelectMute = useCallback(
|
||||||
(e: Event) => {
|
(e: Event) => {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
@@ -248,6 +255,9 @@ const RemoteUserMediaTile = forwardRef<
|
|||||||
mirror={false}
|
mirror={false}
|
||||||
menuStart={
|
menuStart={
|
||||||
<>
|
<>
|
||||||
|
{/* {isRTCParticipantAvailable
|
||||||
|
? "is available"
|
||||||
|
: "Loading RTC participant"} */}
|
||||||
<ToggleMenuItem
|
<ToggleMenuItem
|
||||||
Icon={MicOffIcon}
|
Icon={MicOffIcon}
|
||||||
label={t("video_tile.mute_for_me")}
|
label={t("video_tile.mute_for_me")}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ interface Props extends ComponentProps<typeof animated.div> {
|
|||||||
style?: ComponentProps<typeof animated.div>["style"];
|
style?: ComponentProps<typeof animated.div>["style"];
|
||||||
targetWidth: number;
|
targetWidth: number;
|
||||||
targetHeight: number;
|
targetHeight: number;
|
||||||
video: TrackReferenceOrPlaceholder;
|
video: TrackReferenceOrPlaceholder | undefined;
|
||||||
videoFit: "cover" | "contain";
|
videoFit: "cover" | "contain";
|
||||||
mirror: boolean;
|
mirror: boolean;
|
||||||
member: RoomMember | undefined;
|
member: RoomMember | undefined;
|
||||||
@@ -83,7 +83,7 @@ export const MediaView = forwardRef<HTMLDivElement, Props>(
|
|||||||
src={member?.getMxcAvatarUrl()}
|
src={member?.getMxcAvatarUrl()}
|
||||||
className={styles.avatar}
|
className={styles.avatar}
|
||||||
/>
|
/>
|
||||||
{video.publication !== undefined && (
|
{video?.publication !== undefined && (
|
||||||
<VideoTrack
|
<VideoTrack
|
||||||
trackRef={video}
|
trackRef={video}
|
||||||
// There's no reason for this to be focusable
|
// There's no reason for this to be focusable
|
||||||
|
|||||||
Reference in New Issue
Block a user