Use HTML beautifier to indent ERB files
We had inconsistent indentation in many places. Now we're fixing them and adding a linter to our CI so we don't accidentally introduce inconsistent indentations again.
This commit is contained in:
@@ -29,31 +29,31 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @process.draft_versions.each do |draft_version| %>
|
||||
<tr id="<%= dom_id(draft_version) %>">
|
||||
<td>
|
||||
<%= link_to draft_version.title, edit_admin_legislation_process_draft_version_path(@process, draft_version) %>
|
||||
</td>
|
||||
<td><%= draft_version.created_at.to_date %></td>
|
||||
<td>
|
||||
<% if draft_version.status == "draft" %>
|
||||
<%= Legislation::DraftVersion.human_attribute_name(:status_draft) %>
|
||||
<%= link_to "(#{t("admin.legislation.draft_versions.index.preview")})",
|
||||
legislation_process_draft_version_path(@process, draft_version) %>
|
||||
<% else %>
|
||||
<%= Legislation::DraftVersion.human_attribute_name(:status_published) %>
|
||||
<% end %>
|
||||
</td>
|
||||
<td class="text-center"><%= draft_version.total_comments %></td>
|
||||
<td class="text-center">
|
||||
<% if draft_version.final_version %>
|
||||
<span class="icon-check" title="<%= draft_version.final_version %>"></span>
|
||||
<% else %>
|
||||
<span class="icon-x delete" title="<%= draft_version.final_version %>"></span>
|
||||
<% end %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
<% @process.draft_versions.each do |draft_version| %>
|
||||
<tr id="<%= dom_id(draft_version) %>">
|
||||
<td>
|
||||
<%= link_to draft_version.title, edit_admin_legislation_process_draft_version_path(@process, draft_version) %>
|
||||
</td>
|
||||
<td><%= draft_version.created_at.to_date %></td>
|
||||
<td>
|
||||
<% if draft_version.status == "draft" %>
|
||||
<%= Legislation::DraftVersion.human_attribute_name(:status_draft) %>
|
||||
<%= link_to "(#{t("admin.legislation.draft_versions.index.preview")})",
|
||||
legislation_process_draft_version_path(@process, draft_version) %>
|
||||
<% else %>
|
||||
<%= Legislation::DraftVersion.human_attribute_name(:status_published) %>
|
||||
<% end %>
|
||||
</td>
|
||||
<td class="text-center"><%= draft_version.total_comments %></td>
|
||||
<td class="text-center">
|
||||
<% if draft_version.final_version %>
|
||||
<span class="icon-check" title="<%= draft_version.final_version %>"></span>
|
||||
<% else %>
|
||||
<span class="icon-x delete" title="<%= draft_version.final_version %>"></span>
|
||||
<% end %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end %>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
<% if @process.questions.any? %>
|
||||
<table class="stack">
|
||||
<thead>
|
||||
<thead>
|
||||
<tr>
|
||||
<th><%= t("admin.legislation.questions.table.title") %></th>
|
||||
<th><%= t("admin.legislation.questions.table.question_options") %></th>
|
||||
@@ -27,22 +27,22 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @process.questions.each do |question| %>
|
||||
<tr id="<%= dom_id(question) %>">
|
||||
<td>
|
||||
<%= link_to question.title, edit_admin_legislation_process_question_path(@process, question) %>
|
||||
</td>
|
||||
<td>
|
||||
<ul>
|
||||
<% question.question_options.each do |question_option| %>
|
||||
<li><%= "#{question_option.value} (#{question_option.answers_count})" %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</td>
|
||||
<td class="text-center"><%= question.answers_count %></td>
|
||||
<td class="text-center"><%= link_to question.comments.count, legislation_process_question_path(@process, question, anchor: "comments") %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
<% @process.questions.each do |question| %>
|
||||
<tr id="<%= dom_id(question) %>">
|
||||
<td>
|
||||
<%= link_to question.title, edit_admin_legislation_process_question_path(@process, question) %>
|
||||
</td>
|
||||
<td>
|
||||
<ul>
|
||||
<% question.question_options.each do |question_option| %>
|
||||
<li><%= "#{question_option.value} (#{question_option.answers_count})" %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</td>
|
||||
<td class="text-center"><%= question.answers_count %></td>
|
||||
<td class="text-center"><%= link_to question.comments.count, legislation_process_question_path(@process, question, anchor: "comments") %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user