Skip to content

Commit

Permalink
fix(modal): don't hide on out click if backdrop === 'static' (#629)
Browse files Browse the repository at this point in the history
Fixes: #574
  • Loading branch information
adrienverge authored and valorkin committed Jun 23, 2016
1 parent f3199df commit df85712
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion components/modal/modal.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ export class ModalDirective implements AfterViewInit, OnDestroy {

@HostListener('click', ['$event'])
protected onClick(event:any):void {
if (event.target === this.element.nativeElement) {
if (this.config.backdrop !== 'static' &&
event.target === this.element.nativeElement) {
this.hide(event);
}
}
Expand Down

0 comments on commit df85712

Please sign in to comment.