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:
@@ -19,9 +19,9 @@
|
||||
officing_poll_ballot_sheets_path(poll),
|
||||
class: "button" %>
|
||||
|
||||
<%= link_to t("officing.polls.final.add_results"),
|
||||
new_officing_poll_ballot_sheet_path(poll),
|
||||
class: "button hollow" %>
|
||||
<%= link_to t("officing.polls.final.add_results"),
|
||||
new_officing_poll_ballot_sheet_path(poll),
|
||||
class: "button hollow" %>
|
||||
<% else %>
|
||||
<%= link_to t("officing.polls.final.add_results"),
|
||||
new_officing_poll_result_path(poll),
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
<%= results_by_booth[booth_assignment].first.booth_assignment.booth.name %>
|
||||
</td>
|
||||
<td>
|
||||
<%= link_to t("officing.results.new.see_results"), officing_poll_results_path(@poll, date: l(date), booth_assignment_id: booth_assignment) %>
|
||||
<%= link_to t("officing.results.new.see_results"), officing_poll_results_path(@poll, date: l(date), booth_assignment_id: booth_assignment) %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
|
||||
@@ -9,10 +9,10 @@
|
||||
method: :post,
|
||||
remote: true,
|
||||
html: { id: "new_officing_voter" } do |f| %>
|
||||
<%= f.hidden_field :poll_id, value: poll.id %>
|
||||
<%= f.hidden_field :user_id, value: @user.id %>
|
||||
<%= f.submit t("officing.voters.show.submit"),
|
||||
class: "button success",
|
||||
data: { disable_with: t("officing.voters.can_vote.submit_disable_with") } %>
|
||||
<%= f.hidden_field :poll_id, value: poll.id %>
|
||||
<%= f.hidden_field :user_id, value: @user.id %>
|
||||
<%= f.submit t("officing.voters.show.submit"),
|
||||
class: "button success",
|
||||
data: { disable_with: t("officing.voters.can_vote.submit_disable_with") } %>
|
||||
<% end %>
|
||||
</td>
|
||||
|
||||
@@ -13,18 +13,18 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @polls.each do |poll| %>
|
||||
<tr id="<%= dom_id(poll) %>">
|
||||
<td>
|
||||
<%= poll.name %>
|
||||
</td>
|
||||
<% if poll.votable_by?(@user) %>
|
||||
<%= render "can_vote", poll: poll %>
|
||||
<% elsif poll.voted_by?(@user) || poll.user_has_an_online_ballot?(@user) %>
|
||||
<%= render "already_voted" %>
|
||||
<% else %>
|
||||
<%= render "cannot_vote" %>
|
||||
<% end %>
|
||||
</tr>
|
||||
<tr id="<%= dom_id(poll) %>">
|
||||
<td>
|
||||
<%= poll.name %>
|
||||
</td>
|
||||
<% if poll.votable_by?(@user) %>
|
||||
<%= render "can_vote", poll: poll %>
|
||||
<% elsif poll.voted_by?(@user) || poll.user_has_an_online_ballot?(@user) %>
|
||||
<%= render "already_voted" %>
|
||||
<% else %>
|
||||
<%= render "cannot_vote" %>
|
||||
<% end %>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user