From 35845258dde2d064e6ba59cf529f972a30aa9819 Mon Sep 17 00:00:00 2001 From: Glenn Carremans Date: Mon, 25 Feb 2019 18:47:32 +0100 Subject: [PATCH] Fix linting issues in app/views/blocks (#1851) [ci skip] --- app/views/blocks/_actions.html.erb | 2 +- app/views/blocks/_form.html.erb | 102 +++++++++++++++-------------- app/views/blocks/edit.html.erb | 4 +- app/views/blocks/index.html.erb | 8 +-- app/views/blocks/new.html.erb | 4 +- app/views/blocks/show.html.erb | 6 +- 6 files changed, 64 insertions(+), 62 deletions(-) diff --git a/app/views/blocks/_actions.html.erb b/app/views/blocks/_actions.html.erb index 96df0e6d0..6d22442d2 100644 --- a/app/views/blocks/_actions.html.erb +++ b/app/views/blocks/_actions.html.erb @@ -2,7 +2,7 @@ Featured: <%= block.featured %> | Position: <%= block.index_position %> <% if block.processed_html != block.published_html || block.processed_css != block.published_css %> <%= form_for(block) do |f| %> - <%= f.hidden_field :publish_now %>
+ <%= f.hidden_field :publish_now %>
<% end %> <% end %> diff --git a/app/views/blocks/_form.html.erb b/app/views/blocks/_form.html.erb index d9be1a756..bc10cff28 100644 --- a/app/views/blocks/_form.html.erb +++ b/app/views/blocks/_form.html.erb @@ -4,44 +4,46 @@ -
@@ -51,31 +53,31 @@ setTimeout(function(){

<%= pluralize(@block.errors.count, "error") %> prohibited this block from being saved:

<% end %> - <%= f.label :input_css %>
- <%= f.text_area :input_css %>
- <%= f.label :input_javascript %>
- <%= f.text_area :input_javascript %>
- <%= f.label :input_html %>
- <%= f.text_area :input_html %>
- <%= f.label :featured %>
- <%= f.check_box :featured %>
- <%= f.label :index_position %>
- <%= f.text_field :index_position %>
-
- <%= f.submit %> -
+ <%= f.label :input_css %>
+ <%= f.text_area :input_css %>
+ <%= f.label :input_javascript %>
+ <%= f.text_area :input_javascript %>
+ <%= f.label :input_html %>
+ <%= f.text_area :input_html %>
+ <%= f.label :featured %>
+ <%= f.check_box :featured %>
+ <%= f.label :index_position %>
+ <%= f.text_field :index_position %>
+
+ <%= f.submit %> +
<% end %> diff --git a/app/views/blocks/edit.html.erb b/app/views/blocks/edit.html.erb index a2740b23d..16d31e3e3 100644 --- a/app/views/blocks/edit.html.erb +++ b/app/views/blocks/edit.html.erb @@ -1,2 +1,2 @@ -



-<%= render 'form' %> +



+<%= render "form" %> diff --git a/app/views/blocks/index.html.erb b/app/views/blocks/index.html.erb index 4e92259f4..c7e838375 100644 --- a/app/views/blocks/index.html.erb +++ b/app/views/blocks/index.html.erb @@ -1,14 +1,14 @@
- <% @blocks.each_with_index do |block,i| %> - <%= render "articles/block", block: block, show_published: false, i:i %> + <% @blocks.each_with_index do |block, i| %> + <%= render "articles/block", block: block, show_published: false, i: i %>
<%= render "blocks/actions", block: block %> - <%= link_to 'Edit', edit_block_path(block), style: "color:white;display:block;font-size:35px;background:rgb(0, 93, 190);padding:10px 0px;" %> + <%= link_to "Edit", edit_block_path(block), style: "color:white;display:block;font-size:35px;background:rgb(0, 93, 190);padding:10px 0px;" %>
<% end %>
-<%= link_to 'New Block', new_block_path %> +<%= link_to "New Block", new_block_path %> diff --git a/app/views/blocks/new.html.erb b/app/views/blocks/new.html.erb index 7b2671f2b..32787ed47 100644 --- a/app/views/blocks/new.html.erb +++ b/app/views/blocks/new.html.erb @@ -1,5 +1,5 @@

New Block

-<%= render 'form' %> +<%= render "form" %> -<%= link_to 'Back', blocks_path %> +<%= link_to "Back", blocks_path %> diff --git a/app/views/blocks/show.html.erb b/app/views/blocks/show.html.erb index 734a086dd..8dc19ab42 100644 --- a/app/views/blocks/show.html.erb +++ b/app/views/blocks/show.html.erb @@ -1,9 +1,9 @@
- <%= render "articles/block", block: @block, show_published: false, i:0 %> + <%= render "articles/block", block: @block, show_published: false, i: 0 %>
- <%= render "blocks/actions", block: @block %> - <%= link_to 'Edit', edit_block_path(@block), style: "color:white;display:block;font-size:35px;background:rgb(0, 93, 190);padding:10px 0px;" %> + <%= render "blocks/actions", block: @block %> + <%= link_to "Edit", edit_block_path(@block), style: "color:white;display:block;font-size:35px;background:rgb(0, 93, 190);padding:10px 0px;" %>

Go to Index