posts: remove data-* attributes from #image element.

These attributes can be found on the `.image-container` element instead.
This commit is contained in:
evazion
2020-07-31 15:16:01 -05:00
parent 3fe18c57d0
commit a8577b2b94
5 changed files with 11 additions and 21 deletions

View File

@@ -1,6 +1,6 @@
<% if policy(post).visible? %>
<%= content_tag(:picture) do -%>
<%= tag.source media: "(max-width: 660px)", srcset: post.tagged_large_file_url -%>
<%= tag.img width: post.image_width_for(CurrentUser.user), height: post.image_height_for(CurrentUser.user), id: "image", class: "fit-width", "data-original-width": post.image_width, "data-original-height": post.image_height, "data-large-width": post.large_image_width, "data-large-height": post.large_image_height, "data-tags": post.tag_string, alt: post.presenter.humanized_essential_tag_string, "data-uploader": post.uploader.name, "data-rating": post.rating, "data-flags": post.status_flags, "data-parent-id": post.parent_id, "data-has-children": post.has_children?, "data-has-active-children": post.has_active_children?, "data-score": post.score, "data-fav-count": post.fav_count, src: post.file_url_for(CurrentUser.user) %>
<%= tag.img width: post.image_width_for(CurrentUser.user), height: post.image_height_for(CurrentUser.user), id: "image", class: "fit-width", alt: post.presenter.humanized_essential_tag_string, src: post.file_url_for(CurrentUser.user) %>
<% end -%>
<% end %>