presenters: merge PostSetPresenter into PostSet.

Reduce indirection. PostSet is basically a collection of helper methods
for rendering the post index page. PostSetPresenter was a set of helper
methods for rendering the tag list on the post index page. These don't
need to be separated.
This commit is contained in:
evazion
2020-05-10 19:18:18 -05:00
parent 26d6e23377
commit a2814364ee
5 changed files with 74 additions and 97 deletions

View File

@@ -7,7 +7,7 @@
<section id="tag-box">
<h1>Tags</h1>
<%= @post_set.presenter.tag_list_html(current_query: params[:tags], show_extra_links: policy(Post).show_extra_links?) %>
<%= @post_set.tag_list_html(current_query: params[:tags], show_extra_links: policy(Post).show_extra_links?) %>
</section>
<%= render "posts/partials/index/options" %>

View File

@@ -1,6 +1,6 @@
<div id="posts" class="user-disable-cropped-<%= Danbooru.config.enable_image_cropping && CurrentUser.user.disable_cropped_thumbnails? %>">
<div id="posts-container">
<%= post_set.presenter.post_previews_html(self) %>
<%= post_set.post_previews_html(self) %>
</div>
<% if post_set.hidden_posts.present? %>