Wraps addEventListener to capture UI breadcrumbs
@param evtName the event name (e.g. "click")
@returns {Function}
@private
function _breadcrumbEventHandler(evtName) {
	    var self = this;
	    return function (evt) {
	      // reset keypress timeout; e.g. triggering a 'click' after
	      // a 'keypress' will reset the keypress debounce so that a new
	      // set of keypresses can be recorded
	      self._keypressTimeout = null; // It's possible this handler might trigger multiple times for the same
	      // event (e.g. event propagation through node ancestors). Ignore if we've
	      // already captured the event.

	      if (self._lastCapturedEvent === evt) return;
	      self._lastCapturedEvent = evt; // try/catch both:
	      // - accessing evt.target (see getsentry/raven-js#838, #768)
	      // - `htmlTreeAsString` because it's complex, and just accessing the DOM incorrectly
	      //   can throw an exception in some circumstances.

	      var target;

	      try {
	        target = htmlTreeAsString$1(evt.target);
	      } catch (e) {
	        target = '<unknown>';
	      }

	      self.captureBreadcrumb({
	        category: 'ui.' + evtName,
	        // e.g. ui.click, ui.input
	        message: target
	      });
	    };
	  }