<% attachments = Array(field.many? ? field.attachments : field.data) removable = local_assigns.fetch(:removable, false) %> <% attachments.each do |attachment| %>
<%= render partial: 'fields/active_storage/item', locals: { field: field, attachment: attachment, removable: removable, image_size: field.show_preview_size } %>
<% end %>