<commit_before># *************************************
#
#   Toggle
#   -> Toggle state on given elements
#
# *************************************
#
# @param $element    { jQuery object }
# @param proximity   { string }
# @param event       { string }
# @param toggleClass { string }
# @param activeClass { string }
#
# *************************************

@Spellbook.toggle = ( options ) ->
  settings = $.extend
    $element    : $( '.js-toggle' )
    proximity   : 'next' # prev, parent, nextParent, prevParent, $( '.element' )
    event       : 'click' # hover
    toggleClass : 'is-hidden'
    activeClass : 'is-active'
    onClick     : null
    onMouseover : null
    onMouseout  : null
  , options

  switch settings.event

    # -------------------------------------
    #   Click
    # -------------------------------------<commit_msg>Update comment docs in Spellbook.toggle<commit_after># *************************************
#
#   Toggle
#   -> Toggle state on given elements
#
# *************************************
#
# @param $element    { jQuery object }
# @param proximity   { string }
# @param event       { string }
# @param toggleClass { string }
# @param activeClass { string }
# @param onClick     { function }
# @param onMouseover { function }
# @param onMouseout  { function }
#
# *************************************

@Spellbook.toggle = ( options ) ->
  settings = $.extend
    $element    : $( '.js-toggle' )
    proximity   : 'next' # prev, parent, nextParent, prevParent, $( '.element' )
    event       : 'click' # hover
    toggleClass : 'is-hidden'
    activeClass : 'is-active'
    onClick     : null
    onMouseover : null
    onMouseout  : null
  , options

  switch settings.event

    # -------------------------------------
    #   Click
    # -------------------------------------
{'fraction_non_alphanumeric': 0.30646929824561403, 'fraction_numerical': 0.0, 'mean_word_length': 2.1629116117850953, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '2325366', 'n_tokens_mistral': 502, 'n_tokens_neox': 486, 'n_words': 119}