Change pool category class location

In order to make blacklisting by category easier.
This commit is contained in:
Toks
2013-07-27 11:46:35 -04:00
parent 942ba4ac09
commit e3ca0b26a7
3 changed files with 7 additions and 7 deletions

View File

@@ -1,6 +1,6 @@
@import "../common/000_vars.css.scss"; @import "../common/000_vars.css.scss";
a.pool-category-series, span.pool-category-series a { .pool-category-series a {
color: #A0A; color: #A0A;
&:hover { &:hover {
@@ -8,7 +8,7 @@ a.pool-category-series, span.pool-category-series a {
} }
} }
a.pool-category-collection, span.pool-category-collection a { .pool-category-collection a {
color: $link_color; color: $link_color;
&:hover { &:hover {

View File

@@ -202,17 +202,17 @@ class PostPresenter < Presenter
end end
def pool_link_html(template, pool, options = {}) def pool_link_html(template, pool, options = {})
pool_html = ["<li id='nav-link-for-pool-#{pool.id}'>"] pool_html = [%{<li id="nav-link-for-pool-#{pool.id}" class="pool-category-#{pool.category}">}]
match_found = false match_found = false
if options[:include_rel] if options[:include_rel]
prev_rel = "prev" prev_rel = "prev"
next_rel = "next" next_rel = "next"
klass = "active pool-category-#{pool.category}" klass = "active"
else else
prev_rel = nil prev_rel = nil
next_rel = nil next_rel = nil
klass = "pool-category-#{pool.category}" klass = ""
end end
if @post.id != pool.post_id_array.first if @post.id != pool.post_id_array.first

View File

@@ -11,12 +11,12 @@
</thead> </thead>
<tbody> <tbody>
<% @pools.each do |pool| %> <% @pools.each do |pool| %>
<%= content_tag(:tr, :id => "pool-#{pool.id}") do %> <%= content_tag(:tr, :id => "pool-#{pool.id}", :class => "pool-category-#{pool.category}") do %>
<td> <td>
</td> </td>
<td> <td>
<%= link_to pool.pretty_name, pool_path(pool), :class => "pool-category-#{pool.category}" %> <%= link_to pool.pretty_name, pool_path(pool) %>
<% if pool.post_count > CurrentUser.user.per_page %> <% if pool.post_count > CurrentUser.user.per_page %>
<%= link_to "page #{pool.last_page}", pool_path(pool, :page => pool.last_page), :class => "last-page" %> <%= link_to "page #{pool.last_page}", pool_path(pool, :page => pool.last_page), :class => "last-page" %>