Skip to content

Commit 432c8fb

Browse files
committed
fix: remove kModal class when closing the popup without timeout
1 parent 4b1e2ec commit 432c8fb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

kaltura-ui/src/popup-widget/popup-widget.component.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -184,11 +184,11 @@ export class PopupWidgetComponent implements AfterViewInit, OnDestroy{
184184
this.popup.nativeElement.style.bottom = this.popupHeight!== 'auto' ? this.popupHeight * -1 +"px" : "-1000px";
185185
timeout = 300;
186186
}
187+
document.body.classList.remove("kModal");
187188
setTimeout(()=>{
188189
// remove modal
189190
if (this.modal && this._modalOverlay) {
190191
document.body.removeChild(this._modalOverlay);
191-
document.body.classList.remove("kModal");
192192
this._modalOverlay = null;
193193
}
194194
this._statechange.next({state: PopupWidgetStates.Close, context: context, reason: reason}); // use timeout to prevent valueChangeAfterChecked error

0 commit comments

Comments
 (0)