<commit_before>export default {
  mounted () {
    if (typeof document !== 'undefined') {
      document.documentElement.addEventListener('click', this._clickOutListener)
    }
  },
  beforeDestroy () {
    if (typeof document !== 'undefined') {
      document.removeEventListener('click', this._clickOutListener)
    }
  },
  methods: {
    _clickOutListener (e) {
      if (!this.$el.contains(e.target)) {
        if (this.clickOutListener) {
          this.clickOutListener()
        }
      }
    }
  }
}
<commit_msg>fix: call `removeEventListener` on the right element (#1557)<commit_after>export default {
  mounted () {
    if (typeof document !== 'undefined') {
      document.documentElement.addEventListener('click', this._clickOutListener)
    }
  },
  beforeDestroy () {
    if (typeof document !== 'undefined') {
      document.documentElement.removeEventListener('click', this._clickOutListener)
    }
  },
  methods: {
    _clickOutListener (e) {
      if (!this.$el.contains(e.target)) {
        if (this.clickOutListener) {
          this.clickOutListener()
        }
      }
    }
  }
}

{'fraction_non_alphanumeric': 0.14027149321266968, 'fraction_numerical': 0.0036199095022624436, 'mean_word_length': 2.7747440273037545, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7184167', 'n_tokens_mistral': 325, 'n_tokens_neox': 320, 'n_words': 55}