#101305
yavordashew
Member

Hi davout,
You can use ‘event.target’ to check from where the event is coming from, also you use event.preventDefault() and event.target can be the window or another component that is inside the window that fires the same event.
For example:
onClose(event): void {
const smartWindow = this.smartWindow;
if (event.target === smartWindow.nativeElement) {
event.preventDefault()
}
}
Please, do not hesitate to contact us if you have any additional questions.
Best regards,
Yavor Dashev
Smart UI Team
https://www.htmlelements.com/