<commit_before><%
  dom_id ||= 'menu'
  css ||= 'menu'
  hide_children = RefinerySetting.find_or_set(:menu_hide_children, false) unless defined?(hide_children)
  cache_key = [Refinery.base_cache_key]
  cache_key << (action_suffix ||= RefinerySetting.find_or_set(:refinery_menu_cache_action_suffix, "site_menu"))
  cache_key << extra_suffix if defined?(extra_suffix) and extra_suffix.present?
  cache_key << request.path
  cache(cache_key.compact.join('_')) do
    # Select top menu items unless 'roots' is passed in.
    collection ||= @menu_pages
    roots ||= collection.select { |m| m.parent_id == nil }
    if roots.any?
      sibling_count = roots.size - 1
-%>
      <nav id='<%= dom_id %>' class='<%= %W(#{css} clearfix).join(' ') %>'>
        <ul>
          <%= render :partial => "/shared/menu_branch",
                     :collection => roots,
                     :locals => {
                       :hide_children => hide_children,
                       :sibling_count => sibling_count,
                       :collection => collection,
                       :apply_css => true #if you don't care about class='first' class='last' or class='selected' set apply_css to false for speed.
                     }
          -%>
        </ul>
      </nav>
  <%
    end
  end
-%><commit_msg>extra_suffix doesn't need to exist because dom_id does and is unique anyway. (ht: djones)<commit_after><%
  dom_id ||= 'menu'
  css ||= 'menu'
  hide_children = RefinerySetting.find_or_set(:menu_hide_children, false) unless defined?(hide_children)
  cache_key = [Refinery.base_cache_key]
  cache_key << dom_id
  cache_key << (action_suffix ||= RefinerySetting.find_or_set(:refinery_menu_cache_action_suffix, "site_menu"))
  cache_key << request.path
  cache(cache_key.compact.join('_')) do
    # Select top menu items unless 'roots' is passed in.
    collection ||= @menu_pages
    roots ||= collection.select { |m| m.parent_id == nil }
    if roots.any?
      sibling_count = roots.size - 1
-%>
      <nav id='<%= dom_id %>' class='<%= %W(#{css} clearfix).join(' ') %>'>
        <ul>
          <%= render :partial => "/shared/menu_branch",
                     :collection => roots,
                     :locals => {
                       :hide_children => hide_children,
                       :sibling_count => sibling_count,
                       :collection => collection,
                       :apply_css => true #if you don't care about class='first' class='last' or class='selected' set apply_css to false for speed.
                     }
          -%>
        </ul>
      </nav>
  <%
    end
  end
-%>
{'fraction_non_alphanumeric': 0.1371647509578544, 'fraction_numerical': 0.0007662835249042146, 'mean_word_length': 2.3050632911392404, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 35, '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': '2764957', 'n_tokens_mistral': 827, 'n_tokens_neox': 787, 'n_words': 183}