uploads: allow changing thumbnail size on My Uploads / All Uploads pages.
* Add a "Size" menu to the My Uploads / All Uploads pages to allow changing the thumbnail size. * Make the My Uploads / All Uploads pages use the same thumbnail size as the post index page. * Change the "Gallery | Table" links on the My Uploads page to icons.
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<%= render PopupMenuComponent.new(classes: "preview-size-menu") do |menu| %>
|
||||
<% menu.button do %>
|
||||
<span class="text-sm">Size <%= caret_down_icon %></span>
|
||||
<% end %>
|
||||
|
||||
<% menu.item do %>
|
||||
<%= link_to "Small", current_page_path(size: 150), class: ("font-bold" if current_size == 150), rel: "nofollow" %>
|
||||
<% end %>
|
||||
|
||||
<% menu.item do %>
|
||||
<%= link_to "Medium", current_page_path(size: 180), class: ("font-bold" if current_size == 180), rel: "nofollow" %>
|
||||
<% end %>
|
||||
|
||||
<% menu.item do %>
|
||||
<%= link_to "Large", current_page_path(size: 225), class: ("font-bold" if current_size == 225), rel: "nofollow" %>
|
||||
<% end %>
|
||||
|
||||
<%# Mobile only %>
|
||||
<% menu.item do %>
|
||||
<%= link_to "Huge", current_page_path(size: 360), class: ["mobile-only", ("font-bold" if current_size == 360)], rel: "nofollow" %>
|
||||
<% end %>
|
||||
|
||||
<%# Desktop only %>
|
||||
<% menu.item do %>
|
||||
<%= link_to "Huge", current_page_path(size: 270), class: ["desktop-only", ("font-bold" if current_size == 270)], rel: "nofollow" %>
|
||||
<% end %>
|
||||
|
||||
<%# Desktop only %>
|
||||
<% menu.item do %>
|
||||
<%= link_to "Gigantic", current_page_path(size: 360), class: ["desktop-only", ("font-bold" if current_size == 360)], rel: "nofollow" %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
@@ -0,0 +1 @@
|
||||
../../javascript/src/javascripts/preview_size_menu_component.js
|
||||
Reference in New Issue
Block a user