Displaying <%= (params[:page] || 1).to_i.ordinalize %> page with <%= @articles.size %> articles of total <%= @articles.total %>
No documents have been found. <% if @articles.response.suggestions['suggest_title'].present? || @articles.response.suggestions['suggest_body'].present? %> Maybe you mean <%= @articles.response.suggestions.map { |k,v| v.first['options'] }.flatten.map {|v| v['text']}.uniq.map do |term| link_to term, search_path(params.permit(:q, :a, :c, :s, :w, :comments).merge q: term) end.to_sentence(last_word_connector: ' or ').html_safe %>? <% end %>
<%= link_to 'All Sections →'.html_safe, search_path(params.permit(:q, :a, :c, :s, :w, :comments).merge(c: nil))%>
<% if article.try(:highlight).try(:abstract) %> <%= article.highlight.abstract.join.html_safe %> <% else %> <%= article.try(:highlight).try(:content) ? article.highlight.content.join('…').html_safe : article.abstract %> <% end %>
<% if comments = article.try(:highlight) && article.highlight['comments.body'] %>Comments: <%= comments.join('…').html_safe %>
<% end %>Authors: <%= article.authors.map(&:full_name).to_sentence %> | Published: <%= article.published_on %> | Score: <%= article._score %>