From ec2396d9044b5b5dfbd3f5a2b006f03d0e8b60f0 Mon Sep 17 00:00:00 2001 From: Carlos Santos <4a.santos@gmail.com> Date: Fri, 29 Sep 2023 13:36:32 +0200 Subject: [PATCH] openvidu-components: Fixed show additional panel when others are opened --- .../src/lib/components/panel/panel.component.ts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/openvidu-components-angular/projects/openvidu-angular/src/lib/components/panel/panel.component.ts b/openvidu-components-angular/projects/openvidu-angular/src/lib/components/panel/panel.component.ts index af6ce41c34..5e185c2f9a 100644 --- a/openvidu-components-angular/projects/openvidu-angular/src/lib/components/panel/panel.component.ts +++ b/openvidu-components-angular/projects/openvidu-angular/src/lib/components/panel/panel.component.ts @@ -1,7 +1,10 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ContentChild, OnInit, TemplateRef } from '@angular/core'; import { skip, Subscription } from 'rxjs'; import { - ActivitiesPanelDirective, AdditionalPanelsDirective, ChatPanelDirective, ParticipantsPanelDirective + ActivitiesPanelDirective, + AdditionalPanelsDirective, + ChatPanelDirective, + ParticipantsPanelDirective } from '../../directives/template/openvidu-angular.directive'; import { PanelEvent, PanelType } from '../../models/panel.model'; import { PanelService } from '../../services/panel/panel.service'; @@ -169,7 +172,13 @@ export class PanelComponent implements OnInit { this.isBackgroundEffectsPanelOpened = ev.opened && ev.type === PanelType.BACKGROUND_EFFECTS; this.isSettingsPanelOpened = ev.opened && ev.type === PanelType.SETTINGS; this.isActivitiesPanelOpened = ev.opened && ev.type === PanelType.ACTIVITIES; - this.isExternalPanelOpened = ev.opened && ev.type !== PanelType.PARTICIPANTS && ev.type !== PanelType.CHAT; + this.isExternalPanelOpened = + ev.opened && + !this.isChatPanelOpened && + !this.isParticipantsPanelOpened && + !this.isBackgroundEffectsPanelOpened && + !this.isSettingsPanelOpened && + !this.isActivitiesPanelOpened; this.cd.markForCheck(); }); }