<% if show_sort_and_per_page? and active_sort_fields.many? %>
<div id="sort-dropdown" class="btn-group">
  <button type="button" class="btn btn-info dropdown-toggle" data-toggle="dropdown">
      <%= t('blacklight.search.sort.label', :field =>current_sort_field.label) %> <span class="caret"></span>
  </button>

  <ul class="dropdown-menu" role="menu">
      <%- active_sort_fields.each do |sort_key, field_config| %>
        <li><%= link_to(field_config.label, url_for(search_state.params_for_search(sort: sort_key))) %></li>
      <%- end -%>
  </ul>
</div>
<% end %>
