<%= render partial: 'toolbar/profile', locals: { :subject => profile_or_current_subject } %>
<%= render partial: 'layouts/loading' %>
<% profile_or_current_subject.class.contact_index_models.each do |type| %>
<%= text_field_tag "contact-filter-#{ type }", (current_contact_section?(type) ? params[:q] : ""), class: "pull-right contact-filter", placeholder: "filter", autocomplete: "off" %> <% if user_signed_in? && type == :group %> <%= link_to t('group.new.link'), new_group_path, class: 'new_group-modal-link', 'data-toggle' => 'modal' %> <%= render partial: 'groups/new_modal', locals: { resource_class: Group } %> <% end %>
<% if current_contact_section?(type) %> <% if @contacts.any? %> <%= render current_subject_contacts_to(@contacts) %> <% else %> <%= raw t("contact.empty", explore: explore_path) %> <% end %> <% else %> <%= render partial: 'layouts/loading' %> <% end %>
<% end %>
<%= javascript_tag do %> $(function() { SocialStream.Contact.index(); }); <% end %>