<commit_before><%= render 'shared/navigation' %>

<section class="question">
  <article>
    <header>
      <h4>
        <span class="emph">To:</span> <strong><%= link_to @question.person.name, person_path(@jurisdiction.abbreviation, @question.person.id) %></strong>
        <span>(<%= person_attributes(@question.person) %>)</span>
        <% if @question.bill_id? %>
          <span class="emph">on:</span> <strong><%= link_to short_bill_title(@question.bill), bill_path(@jurisdiction.abbreviation, @question.bill.id) %></strong>
        <% end %>
      </h4>
      <h1><%= @question.title %></h1>
    </header>
    <%= simple_format(@question.body) %>
    <span class="author_wrap">
      <%# HACK: issued_at set to created_at until issued_at is sorted out -%>
      <%# TODO: take out issued_at set to created_at -%>
      <% @question.issued_at = @question.created_at unless @question.issued_at.present? -%>
      <span class="posted">Posted <%= time_tag @question.issued_at, l(@question.issued_at.to_date, format: :long), 'data-time-ago' => @question.issued_at.iso8601 %> by</span>
      <span class="author">
        <%= link_to user_path(@question.user) do %>
          <% if @question.user.image? %>
            <%= image_tag(@question.user.image.url, size: '40x40', alt: '') %>
          <% end %>
          <%= @question.user.alternate_name %>
        <% end %>, of <%= @question.user.locality -%>, <%= @question.user.region.upcase -%>
      </span>
    </span>

    <div class="recipient_answer recipient"> <%# @todo JM %>
      <div class="avatar">
        <img src="http://lorempixel.com/130/130/" alt="" />
      </div>
      <div class="person-info">
        <h2><NAME></h2>
        <span class="jurisdiction">Republican, 6th House District</span>
        <span class="stats">
          <span>3 Questions</span>
          <span>1 Answers</span>
        </span>
      </div>
      <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

      <span class="pubdate"><time datetime="2009-11-13" pubdate>November 11th 2013 <sup>6:45pm</sup></time></span>
    </div>
    <a href="#sign_on_q" class="mobile_cta cta-pill">Sign On</a> <%# @todo JM - mobile sign on button, if logged in this button should sign the question, otherwise it should send the user to the anchored form %>

    <div class="comments">
      <div id="disqus_thread"></div>
    </div>

    <div class='recipient-answer-form'>
      <h2>Sign Up &amp; Answer this Question as <strong><NAME></strong></h2>
      <h2> (R- 6th House District)</h2>
      <%= simple_form_for(@user, as: :user, url: registration_path(:user)) do |f| %>
        <%= hidden_field_tag :question_id, @question.id %>
        <%= f.input :password, placeholder: "What is your answer?", as: :text, label: false %>
        <div class='recipient-answer-form-left'>
          <%= f.input :given_name, placeholder: "First Name", label: false %>
          <%= f.input :family_name, placeholder: "<NAME>", label: false %>
          <%= f.input :email, placeholder: "Official Gov. E-mail", label: false %>
          <%= f.input :password, placeholder: "Password", label: false %>
          <%= f.button :submit, 'Submit Answer', class: 'cta-pill' %>
        </div>
      <% end %>
      <p class='watermark-tip'>This watermark will appear on all answers you post to the OpenGovernment Website, indicating that you are an official representative.</p>
    </div>
  </article>
  <a name="sign_on_q"></a>
  <div class="actions">
    <h4>Support this question</h4>

    <div class="row">
      <div class="question_progress">
        <div class="progress_filler" style="width: <%= question_progress_percent(@question) %>%;"></div>
      </div>
      <span class="question_progress_count">
        <strong><span class="question-signatures" data-signature-question-id="<%= @question.id %>"><%= @question.signature_count -%></span></strong>
        out of
        <strong><span class="question-signature-threshold"><%= @question.person.signature_threshold -%></span></strong>
        Signatures
      </span>
    </div>

    <% if user_signed_in? %>
      <ul>
        <li>
          <% if current_user.question_signed? @question.id %>
            <a class='sign_on'>Signed On</a>
          <% else %>
          <%= link_to 'Sign On', "#", class: 'cta-pill sign-on-user', :'data-question-id' => @question.id %>
          <% end %>
        </li>
      </ul>
    <% else %>
      <div class="row last signup">
      <%= simple_form_for(@user, as: :user, url: registration_path(:user)) do |f| %>
        <%= hidden_field_tag :question_id, @question.id %>
        <%= f.input :given_name, placeholder: "<NAME>", label: false %>
        <%= f.input :family_name, placeholder: "<NAME>", label: false %>
        <%= f.input :email, placeholder: "E-mail", label: false %>
        <%= f.input :street_address, placeholder: "Street Address", label: false %>
        <%= f.input :locality, placeholder: "City", label: false %>
        <%= f.input :region, collection: OpenGovernment::STATES, prompt: "Select your state", label: false, wrapper_html: {class: 'icon-angle-down sculpt'} %>
        <%= f.input :postal_code, placeholder: "Zip or Postal Code", label: false %>
        <%= f.input :password, placeholder: "Password", label: false %>
        <%= f.button :submit, 'Sign On', class: 'cta-pill' %>
      <% end %>
      </div>
    <% end %>
    <% if @question.subject? %>
    <h5>Issue Area</h5>
    <ul class="tags">
      <li>
        <%= link_to @question.subject, questions_path(@jurisdiction.id, subject: @question.subject) %>
      </li>
    </ul>
    <% end %>
    <%= link_to 'Flag this question', '#', class: 'flag' %><%# @todo JM %>
  </div>
</section>
<% if params[:created] == 'true' %>
  <div id='overlay'></div>
  <div id='modal'>
    <div class='modal-content'><commit_msg>Moved comments block and commented out user sign up form on question#show page<commit_after><%= render 'shared/navigation' %>

<section class="question">
  <article>
    <header>
      <h4>
        <span class="emph">To:</span> <strong><%= link_to @question.person.name, person_path(@jurisdiction.abbreviation, @question.person.id) %></strong>
        <span>(<%= person_attributes(@question.person) %>)</span>
        <% if @question.bill_id? %>
          <span class="emph">on:</span> <strong><%= link_to short_bill_title(@question.bill), bill_path(@jurisdiction.abbreviation, @question.bill.id) %></strong>
        <% end %>
      </h4>
      <h1><%= @question.title %></h1>
    </header>
    <%= simple_format(@question.body) %>
    <span class="author_wrap">
      <%# HACK: issued_at set to created_at until issued_at is sorted out -%>
      <%# TODO: take out issued_at set to created_at -%>
      <% @question.issued_at = @question.created_at unless @question.issued_at.present? -%>
      <span class="posted">Posted <%= time_tag @question.issued_at, l(@question.issued_at.to_date, format: :long), 'data-time-ago' => @question.issued_at.iso8601 %> by</span>
      <span class="author">
        <%= link_to user_path(@question.user) do %>
          <% if @question.user.image? %>
            <%= image_tag(@question.user.image.url, size: '40x40', alt: '') %>
          <% end %>
          <%= @question.user.alternate_name %>
        <% end %>, of <%= @question.user.locality -%>, <%= @question.user.region.upcase -%>
      </span>
    </span>

    <div class="recipient_answer recipient"> <%# @todo JM %>
      <div class="avatar">
        <img src="http://lorempixel.com/130/130/" alt="" />
      </div>
      <div class="person-info">
        <h2><NAME></h2>
        <span class="jurisdiction">Republican, 6th House District</span>
        <span class="stats">
          <span>3 Questions</span>
          <span>1 Answers</span>
        </span>
      </div>
      <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

      <span class="pubdate"><time datetime="2009-11-13" pubdate>November 11th 2013 <sup>6:45pm</sup></time></span>
    </div>
    <a href="#sign_on_q" class="mobile_cta cta-pill">Sign On</a> <%# @todo JM - mobile sign on button, if logged in this button should sign the question, otherwise it should send the user to the anchored form %>

    <div class='recipient-answer-form'>
      <h2>Sign Up &amp; Answer this Question as <strong><NAME></strong></h2>
      <h2> (R- 6th House District)</h2>
      <%= simple_form_for(@user, as: :user, url: registration_path(:user)) do |f| %>
        <%= hidden_field_tag :question_id, @question.id %>
        <%= f.input :password, placeholder: "What is your answer?", as: :text, label: false %>
        <div class='recipient-answer-form-left'>
          <%= f.input :given_name, placeholder: "First Name", label: false %>
          <%= f.input :family_name, placeholder: "Last Name", label: false %>
          <%= f.input :email, placeholder: "Official Gov. E-mail", label: false %>
          <%= f.input :password, placeholder: "Password", label: false %>
          <%= f.button :submit, 'Submit Answer', class: 'cta-pill' %>
        </div>
      <% end %>
      <p class='watermark-tip'>This watermark will appear on all answers you post to the OpenGovernment Website, indicating that you are an official representative.</p>
    </div>
    <div class="comments">
      <div id="disqus_thread"></div>
    </div>

  </article>
  <a name="sign_on_q"></a>
  <div class="actions">
    <h4>Support this question</h4>

    <div class="row">
      <div class="question_progress">
        <div class="progress_filler" style="width: <%= question_progress_percent(@question) %>%;"></div>
      </div>
      <span class="question_progress_count">
        <strong><span class="question-signatures" data-signature-question-id="<%= @question.id %>"><%= @question.signature_count -%></span></strong>
        out of
        <strong><span class="question-signature-threshold"><%= @question.person.signature_threshold -%></span></strong>
        Signatures
      </span>
    </div>

    <% if user_signed_in? %>
      <ul>
        <li>
          <% if current_user.question_signed? @question.id %>
            <a class='sign_on'>Signed On</a>
          <% else %>
          <%= link_to 'Sign On', "#", class: 'cta-pill sign-on-user', :'data-question-id' => @question.id %>
          <% end %>
        </li>
      </ul>
    <%# else %>
    <!-- <div class="row last signup"> -->
      <%#= simple_form_for(@user, as: :user, url: registration_path(:user)) do |f| %>
        <%#= hidden_field_tag :question_id, @question.id %>
        <%#= f.input :given_name, placeholder: "First Name", label: false %>
        <%#= f.input :family_name, placeholder: "Last Name", label: false %>
        <%#= f.input :email, placeholder: "E-mail", label: false %>
        <%#= f.input :street_address, placeholder: "Street Address", label: false %>
        <%#= f.input :locality, placeholder: "City", label: false %>
        <%#= f.input :region, collection: OpenGovernment::STATES, prompt: "Select your state", label: false, wrapper_html: {class: 'icon-angle-down sculpt'} %>
        <%#= f.input :postal_code, placeholder: "Zip or Postal Code", label: false %>
        <%#= f.input :password, placeholder: "Password", label: false %>
        <%#= f.button :submit, 'Sign On', class: 'cta-pill' %>
      <%# end %>
      <!-- </div> -->
    <% end %>
    <% if @question.subject? %>
    <h5>Issue Area</h5>
    <ul class="tags">
      <li>
        <%= link_to @question.subject, questions_path(@jurisdiction.id, subject: @question.subject) %>
      </li>
    </ul>
    <% end %>
    <%= link_to 'Flag this question', '#', class: 'flag' %><%# @todo JM %>
  </div>
</section>
<% if params[:created] == 'true' %>
  <div id='overlay'></div>
  <div id='modal'>
    <div class='modal-content'>
{'fraction_non_alphanumeric': 0.17687400318979266, 'fraction_numerical': 0.00781499202551834, 'mean_word_length': 3.0507105943152455, 'pattern_counts': {'":': 0, '<': 350, '<?xml version=': 0, '>': 354, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 14, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2993630', 'n_tokens_mistral': 4368, 'n_tokens_neox': 3989, 'n_words': 1008}