<commit_before><!-- the meta tag is for use with metamagic gem which generates 
     title and meta tags in conjunction with the metamagic
     method in app/views/layouts/application.html.erb 
     TODO: Create a view helper that works for all pages -->
<% meta title: "EBWiki tracking the case of #{@article.title}",
     description: "#{@article.overview.truncate(155)}",
     keywords: %w("@article.subjects.first.name police violence people color")
%>
<%= render 'layouts/header' %>
<!-- Page Content -->
<div class="container">

<!-- Portfolio Item Heading -->
	<div class="row">
	</div>
	<!-- /.row -->

	<!-- Portfolio Item Row -->
	<div class="row">
    <div class="col-md-3">
      <% if @article.avatar? %>
	      <%= image_tag(@article.avatar.large_avatar, :class => "img-responsive articleImage") %>
	    <% else %>
		    <%= image_tag('default-user-icon.png', :size => "250x250", :class => "img-responsive articleImage") %>
		  <% end %>

			<div class="">
	      <%= social_share_button_tag("Take a look at what I just found on EBWiki:") %>
	    </div>
	    <div class="row">
				<div class = "btn-group btn-group-justified">
					<% if user_signed_in? %>
						<% if (follow = current_user.follows.find_by_followable_id(@article.id)) %>
						    <%= link_to 'Unfollow', article_follow_path(@article, follow), :confirm => "Are you sure you want to unfollow this article?", :method => :delete, class: "btn btn-primary.outline" %>
				    <% else %>
				      <%= link_to 'Follow', article_follows_path(@article), :method => :post, class: "btn btn-primary", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Stay on top of this!",:content => "Click here to receive an email whenever this case is updated."} %>
				    <% end %>
						<%= link_to "Edit", edit_article_path(@article), class: "btn btn-success", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Something not right?",:content => "Click here to make changes to this case.  We're relying on folks like you to help us stay accurate!"} %>
					<% else %>
				    <%= link_to 'Follow', article_follows_path(@article), :method => :post, class: "btn btn-primary", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Login to Follow this case!",:content => "Click here to receive an email whenever this case is updated."} %>
					<% end %>
					<%= link_to "History", articles_history_path(@article), class: "btn btn-info", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Track Changes",:content => "Click here to see all the past edits to this article."} %>
				</div>
			</div>
			<%= render "comments/form" %>
			<div class="commentList" >
				<%= render "comments/comments" %>
			</div>
    </div>

	  <div class="col-md-9">
      <h1 class="page-header articleTitle"><%= @subjects.first.name %>, <%= @subjects.first.age ? "#{@subjects.first.age}" : "" %>
      <br>
          <small><%= @article.city %>, <%= @article.state.name %>. <%= @article.date.strftime("%B %d, %Y") %></small>
      </h1>
			<p class="timeAgo">Last updated: <%= time_ago_in_words(@article.updated_at) %> ago</p>
		    <% if @article.followers.present? %>
          <p>
            People tracking this case: <span class="timeAgo"><%= @article.followers.count %></span>. 
	            <% unless @article.followers.include?(current_user) %>
		            Click here to <%= link_to 'Track this case', article_follows_path(@article) %>.
		          <% end %>
          </p>
        <% end %>
				<% if @article.overview.present? %>
				    <h4 class="article_subheader">Summary  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "The basics", :content => "This section attempts to encapsulate the basic facts of the case."})%></h4>
					<p><%= raw @article.overview %></p>
				<% end %>
				<% if @article.litigation.present? %>
				    <h4 class="article_subheader">Legal Action  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "Case Proceedings", :content => "This section outlines the legal steps that have occurred in the case, answering questions about administrative actions and more formal charges."})%></h4>
					<p><%= raw @article.litigation %></p>
				<% end %>
				<% if @article.community_action.present? %>
				    <h4 class="article_subheader">Community and Family Efforts  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "Community Action", :content => "This section outlines the response of the local community and the victim's family."})%></h4>
					<p><%= raw @article.community_action %></p>
			<% end %>
			<div class="row">
				<div class="col-md-12">
					<% if @article.video_url.to_s != "" %>
						<div class="embed-container">
								<%= embed(@article.video_url) %>
						</div>
					<% end %>
				</div>
			</div>
			<div class="row">
				<div class="col-md-12">
					<% if @article.links.count > 0 %>
						<h4 class="article_subheader">Additional Resources:</h4>
						<div class = "background-links">
							<% @article.links.each do |link| %>
								<%= link_to link.url, "#{link.url}" %>
								</br>
							<% end %>
						</div>
					<% end %>
				</div>
			</div>
	    <% if @article.nearby_cases.present? %>
			<!-- Related Projects Row -->
				<div class="row">
			    <div class="col-lg-12">
		        <h3 class="page-header">EBWiki is tracking <%= @article.nearby_cases.size %> other case<%= "s" if @article.nearby_cases.size > 1 %> near <%= @article.city %>, <%= @article.state.name %>:</h3>
		      </div>
		    </div>
				<div class="row">
          <div class="col-lg-12">
				    <% @article.nearby_cases.each do |nearby| %>
					    <div class="col-lg-2 col-md-4 col-xs-12">
				        <div class="thumbnail" >
				          <div class="imageWrapper galleryImage">
							      <% if nearby.avatar? %>
							        <%= link_to image_tag(nearby.avatar.medium_avatar, :class => "img-responsive portfolio-item", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "#{nearby.date.strftime("%m/%d/%Y")} - #{nearby.title} ", :content => "#{raw truncate(nearby.overview, length:200)}"}), nearby %>
							      <% else %>
							        <%= link_to image_tag('default-user-icon.png', :class => "img-responsive portfolio-item", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "#{nearby.date.strftime("%m/%d/%Y")} - #{nearby.title} ", :content => "#{raw truncate(nearby.overview, length:200)}"}), nearby %>
							      <% end %>
					        </div>
					      </div>
					    </div>
				    <% end %>
				  </div>
			  </div>

		    <!-- Map -->
		    <div class="row">
			    <div class="col-lg-12 articleMap">
				  <div id='map'></div>
			  </div>
			<% end %>
		</div>
	</div>
</div>


<!-- /.row -->

<script type="text/javascript">
	$(document).ready(function(){
	    $('[data-toggle="popover"]').popover();
	});
</script>

<script type="">
	handler = Gmaps.build('Google');
	handler.buildMap({ provider: {}, internal: {id: 'map'}}, function(){
	  markers = handler.addMarkers(<%=raw @hash.to_json %>);
	  handler.bounds.extendWith(markers);
	  handler.fitMapToBounds();
	});
</script>

<commit_msg>minor grammar fixes on issue #215<commit_after><!-- the meta tag is for use with metamagic gem which generates 
     title and meta tags in conjunction with the metamagic
     method in app/views/layouts/application.html.erb 
     TODO: Create a view helper that works for all pages -->
<% meta title: "EBWiki tracking the case of #{@article.title}",
     description: "#{@article.overview.truncate(155)}",
     keywords: %w("@article.subjects.first.name police violence people color")
%>
<%= render 'layouts/header' %>
<!-- Page Content -->
<div class="container">

<!-- Portfolio Item Heading -->
	<div class="row">
	</div>
	<!-- /.row -->

	<!-- Portfolio Item Row -->
	<div class="row">
    <div class="col-md-3">
      <% if @article.avatar? %>
	      <%= image_tag(@article.avatar.large_avatar, :class => "img-responsive articleImage") %>
	    <% else %>
		    <%= image_tag('default-user-icon.png', :size => "250x250", :class => "img-responsive articleImage") %>
		  <% end %>

			<div class="">
	      <%= social_share_button_tag("Take a look at what I just found on EBWiki:") %>
	    </div>
	    <div class="row">
				<div class = "btn-group btn-group-justified">
					<% if user_signed_in? %>
						<% if (follow = current_user.follows.find_by_followable_id(@article.id)) %>
						    <%= link_to 'Unfollow', article_follow_path(@article, follow), :confirm => "Are you sure you want to unfollow this article?", :method => :delete, class: "btn btn-primary.outline" %>
				    <% else %>
				      <%= link_to 'Follow', article_follows_path(@article), :method => :post, class: "btn btn-primary", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Stay on top of this!",:content => "Click here to receive an email whenever this case is updated."} %>
				    <% end %>
						<%= link_to "Edit", edit_article_path(@article), class: "btn btn-success", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Something not right?",:content => "Click here to make changes to this case.  We're relying on folks like you to help us stay accurate!"} %>
					<% else %>
				    <%= link_to 'Follow', article_follows_path(@article), :method => :post, class: "btn btn-primary", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Login to Follow this case!",:content => "Click here to receive an email whenever this case is updated."} %>
					<% end %>
					<%= link_to "History", articles_history_path(@article), class: "btn btn-info", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom",:title => "Track Changes",:content => "Click here to see all the past edits to this article."} %>
				</div>
			</div>
			<%= render "comments/form" %>
			<div class="commentList" >
				<%= render "comments/comments" %>
			</div>
    </div>

	  <div class="col-md-9">
      <h1 class="page-header articleTitle"><%= @subjects.first.name %>, <%= @subjects.first.age ? "#{@subjects.first.age}" : "" %>
      <br>
          <small><%= @article.city %>, <%= @article.state.name %>. <%= @article.date.strftime("%B %d, %Y") %></small>
      </h1>
			<p class="timeAgo">Last updated: <%= time_ago_in_words(@article.updated_at) %> ago</p>
		    <% if @article.followers.present? %>
          <p>
            People tracking this case: <span class="timeAgo"><%= @article.followers.count %></span> 
	            <% unless @article.followers.include?(current_user) %>
		            -- Click here to <%= link_to 'Track this', article_follows_path(@article) %>.
		          <% end %>
          </p>
        <% end %>
				<% if @article.overview.present? %>
				    <h4 class="article_subheader">Summary  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "The basics", :content => "This section attempts to encapsulate the basic facts of the case."})%></h4>
					<p><%= raw @article.overview %></p>
				<% end %>
				<% if @article.litigation.present? %>
				    <h4 class="article_subheader">Legal Action  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "Case Proceedings", :content => "This section outlines the legal steps that have occurred in the case, answering questions about administrative actions and more formal charges."})%></h4>
					<p><%= raw @article.litigation %></p>
				<% end %>
				<% if @article.community_action.present? %>
				    <h4 class="article_subheader">Community and Family Efforts  <%= image_tag('help_icon.png', data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "Community Action", :content => "This section outlines the response of the local community and the victim's family."})%></h4>
					<p><%= raw @article.community_action %></p>
			<% end %>
			<div class="row">
				<div class="col-md-12">
					<% if @article.video_url.to_s != "" %>
						<div class="embed-container">
								<%= embed(@article.video_url) %>
						</div>
					<% end %>
				</div>
			</div>
			<div class="row">
				<div class="col-md-12">
					<% if @article.links.count > 0 %>
						<h4 class="article_subheader">Additional Resources:</h4>
						<div class = "background-links">
							<% @article.links.each do |link| %>
								<%= link_to link.url, "#{link.url}" %>
								</br>
							<% end %>
						</div>
					<% end %>
				</div>
			</div>
	    <% if @article.nearby_cases.present? %>
			<!-- Related Projects Row -->
				<div class="row">
			    <div class="col-lg-12">
		        <h3 class="page-header">EBWiki is tracking <%= @article.nearby_cases.size %> other case<%= "s" if @article.nearby_cases.size > 1 %> near <%= @article.city %>, <%= @article.state.name %>:</h3>
		      </div>
		    </div>
				<div class="row">
          <div class="col-lg-12">
				    <% @article.nearby_cases.each do |nearby| %>
					    <div class="col-lg-2 col-md-4 col-xs-12">
				        <div class="thumbnail" >
				          <div class="imageWrapper galleryImage">
							      <% if nearby.avatar? %>
							        <%= link_to image_tag(nearby.avatar.medium_avatar, :class => "img-responsive portfolio-item", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "#{nearby.date.strftime("%m/%d/%Y")} - #{nearby.title} ", :content => "#{raw truncate(nearby.overview, length:200)}"}), nearby %>
							      <% else %>
							        <%= link_to image_tag('default-user-icon.png', :class => "img-responsive portfolio-item", data: {:toggle => 'popover', :container => 'body', :trigger => 'hover',:placement => "bottom", :title => "#{nearby.date.strftime("%m/%d/%Y")} - #{nearby.title} ", :content => "#{raw truncate(nearby.overview, length:200)}"}), nearby %>
							      <% end %>
					        </div>
					      </div>
					    </div>
				    <% end %>
				  </div>
			  </div>

		    <!-- Map -->
		    <div class="row">
			    <div class="col-lg-12 articleMap">
				  <div id='map'></div>
			  </div>
			<% end %>
		</div>
	</div>
</div>


<!-- /.row -->

<script type="text/javascript">
	$(document).ready(function(){
	    $('[data-toggle="popover"]').popover();
	});
</script>

<script type="">
	handler = Gmaps.build('Google');
	handler.buildMap({ provider: {}, internal: {id: 'map'}}, function(){
	  markers = handler.addMarkers(<%=raw @hash.to_json %>);
	  handler.bounds.extendWith(markers);
	  handler.fitMapToBounds();
	});
</script>


{'fraction_non_alphanumeric': 0.2036732275689553, 'fraction_numerical': 0.006122045948258837, 'mean_word_length': 3.172480087887943, 'pattern_counts': {'":': 0, '<': 315, '<?xml version=': 0, '>': 445, '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': '7535246', 'n_tokens_mistral': 5814, 'n_tokens_neox': 4697, 'n_words': 1196}