Directive

wrClickOutside

Emits when a mousedown lands outside the host. Useful for dismissing inline popovers / inline edit fields.

Import

import { WrClickOutside } from 'ngwr/directives';

Usage

<div class="popup" (wrClickOutside)="close()"> … </div>
Click outside this box (count: 0)

API

NameDescriptionTypeDefault
(wrClickOutside)Emits when a mousedown event lands outside the host element.MouseEvent