Don't show "All collections" when there's only the default collection
This commit is contained in:
@@ -1,13 +1,6 @@
|
||||
<% clear_url_path = user_filtering.self_filter_path(user_filtering.as_params.except(:collection_ids)) %>
|
||||
|
||||
<% if Current.user.collections.one? %>
|
||||
<%= link_to clear_url_path, class: "popup__group", id: "filter-collection-init", data: { filter_target: "item", navigable_list_target: "item" } do %>
|
||||
<%= tag.div class: "popup__item btn" do %>
|
||||
<span class="overflow-ellipsis"><%= Current.user.collections.first.name %></span>
|
||||
<span class="txt-ink translucent flex-item-no-shrink flex-item-justify-end"><span class="txt-x-small txt-uppercase">GO TO</span> ›</span>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% elsif Current.user.collections.many? %>
|
||||
<% if Current.user.collections.many? %>
|
||||
<li class="popup__group" data-filter-target="item" data-navigable-list-target="item" id="filter-collection-all">
|
||||
<%= link_to clear_url_path, class: "btn txt-xx-small flex-item-no-shrink" do %>
|
||||
<%= check_box_tag "filter_collections", nil, user_filtering.collections.blank?, class: "form-checkbox" %>
|
||||
|
||||
Reference in New Issue
Block a user