alexkatz / react-tiny-popover

A simple and highly customizable popover react higher order component with no other dependencies! Typescript friendly.
MIT License
445 stars 119 forks source link

use capturing for click event handling #154

Closed davidjgoss closed 2 years ago

davidjgoss commented 2 years ago

Fixes #138 by using capturing for click events, so that in cases where the clicked element will be unmounted by a local event handler, our handleOnClickOutside is fired first, so we can successfully detect where the element is.