Skip to content
Snippets Groups Projects
Unverified Commit 7506d9e7 authored by Sébastien Gaya's avatar Sébastien Gaya
Browse files

published opacity

parent c524845d
No related branches found
No related tags found
No related merge requests found
......@@ -8,7 +8,11 @@
<tbody>
<% pages.each do |page| %>
<tr>
<td><%= link_to page, admin_communication_website_page_path(website_id: page.website.id, id: page.id) %></td>
<td>
<%= link_to page,
admin_communication_website_page_path(website_id: page.website.id, id: page.id),
class: "#{'opacity-50' unless page.published?}" %>
</td>
<td class="text-end">
<div class="btn-group" role="group">
<%= link_to t('edit'),
......
......@@ -13,7 +13,9 @@
<i class="close_btn--without_children far fa-folder-open"></i>
</span>
<% end %>
<%= link_to page, admin_communication_website_page_path(website_id: page.website.id, id: page.id) %>
<%= link_to page,
admin_communication_website_page_path(website_id: page.website.id, id: page.id),
class: "#{'opacity-50' unless page.published?}" %>
<span class="move_btn py-2 ps-2"><i class="fas fa-sort"></i></span>
<div class="ms-auto">
<%= edit_link page %>
......
......@@ -44,7 +44,8 @@
admin_communication_website_page_path(
website_id: @website.id,
id: @page.parent.id
) %></td>
),
class: "#{'opacity-50' unless @page.parent.published?}" %></td>
</tr>
<% end %>
<% if @page.children.any? %>
......@@ -53,12 +54,12 @@
<td>
<ul class="list-unstyled mb-0">
<% @page.children.each do |child| %>
<li><%= link_to_if can?(:read, child),
<li>
<%= link_to_if can?(:read, child),
child,
admin_communication_website_page_path(
website_id: @website.id,
id: child.id
) %></li>
admin_communication_website_page_path( website_id: @website.id, id: child.id),
class: "#{'opacity-50' unless child.published?}" %>
</li>
<% end %>
</ul>
</td>
......
......@@ -20,7 +20,9 @@
<tbody>
<% posts.each do |post| %>
<tr>
<td><%= link_to post, admin_communication_website_post_path(website_id: post.website.id, id: post.id) %></td>
<td><%= link_to post,
admin_communication_website_post_path(website_id: post.website.id, id: post.id),
class: "#{'opacity-50' unless post.published?}" %></td>
<td><%= image_tag post.featured_image.representation(resize: 'x100'),
height: 50 if post.featured_image.attached? && post.featured_image.representable? %></td>
<% unless hide_author %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment