fix noopener on event binding

This commit is contained in:
Nicolas Constant 2020-08-28 21:39:55 -04:00
parent 58c1f04609
commit 1f93817a6f
No known key found for this signature in database
GPG Key ID: 1E9F677FB01A5688
1 changed files with 9 additions and 9 deletions

View File

@ -221,18 +221,18 @@ export class DatabindedTextComponent implements OnInit {
this.renderer.listen(el, 'click', (event) => {
event.preventDefault();
event.stopImmediatePropagation();
window.open(sanitizedLink, '_blank');
window.open(sanitizedLink, '_blank', 'noopener');
return false;
});
this.renderer.listen(el, 'mouseup', (event) => {
if (event.which === 2) {
event.preventDefault();
event.stopImmediatePropagation();
window.open(sanitizedLink, '_blank');
return false;
}
});
// this.renderer.listen(el, 'mouseup', (event) => {
// if (event.which === 2) {
// event.preventDefault();
// event.stopImmediatePropagation();
// window.open(sanitizedLink, '_blank', 'noopener');
// return false;
// }
// });
}
}
}