<commit_before># Wraps native jQuery event objects.
class Event < `$.Event`
  def [](name)
    `#{self}[name]`
  end

  def current_target
    `$(#{self}.currentTarget)`
  end

  alias_native :default_prevented?, :isDefaultPrevented

  alias_native :prevent_default, :preventDefault

  def page_x
    `#{self}.pageX`
  end

  def page_y
    `#{self}.pageY`
  end

  alias_native :propagation_stopped?, :propagationStopped

  alias_native :stop_propagation, :stopPropagation

  alias_native :stop_immediate_propagation, :stopImmediatePropagation

  def target
    `$(#{self}.target)`
  end

  def type
    `#{self}.type`
  end

  def which
    `#{self}.which`
  end
end
<commit_msg>Add Event#kill, which stops propagation, and prevents default<commit_after># Wraps native jQuery event objects.
class Event < `$.Event`
  def [](name)
    `#{self}[name]`
  end

  def current_target
    `$(#{self}.currentTarget)`
  end

  alias_native :default_prevented?, :isDefaultPrevented

  def kill
    stop_propagation
    prevent_default
  end

  alias_native :prevent_default, :preventDefault

  def page_x
    `#{self}.pageX`
  end

  def page_y
    `#{self}.pageY`
  end

  alias_native :propagation_stopped?, :propagationStopped

  alias_native :stop_propagation, :stopPropagation

  alias_native :stop_immediate_propagation, :stopImmediatePropagation

  def target
    `$(#{self}.target)`
  end

  def touch_x
    `#{self}.originalEvent.touches[0].pageX`
  end

  def touch_y
    `#{self}.originalEvent.touches[0].pageY`
  end

  def type
    `#{self}.type`
  end

  def which
    `#{self}.which`
  end
end

{'fraction_non_alphanumeric': 0.11430356027482823, 'fraction_numerical': 0.0012492192379762648, 'mean_word_length': 3.767857142857143, 'pattern_counts': {'":': 0, '<': 5, '<?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': '402618', 'n_tokens_mistral': 572, 'n_tokens_neox': 567, 'n_words': 126}