Changing the class .filter-box for shopfront to .filter-shopfront

This prevents the issue with inheritance / styling crossover
This commit is contained in:
summerscope
2015-03-13 16:06:46 +11:00
parent e3bc7cf894
commit dc1dd2e243
5 changed files with 8 additions and 19 deletions

View File

@@ -35,7 +35,7 @@ Darkswarm.directive 'singleLineSelectors', ($timeout, $filter) ->
fit = ->
used = $(element).find("li.more").outerWidth(true)
available = $(element).parent(".filter-box").innerWidth()
available = $(element).parent(".filter-shopfront").innerWidth()
$(element).find("li").not(".more").each (i) ->
used += $(this).outerWidth(true)
scope.allSelectors[i].fits = used <= available

View File

@@ -6,14 +6,6 @@
%em from
%span.avenir {{ enterprise.name }}
.filter-box.taxon-selectors
%div{ objects: "[product] | taxonsOf"}
%hr
.filter-box.property-selectors
%single-line-selectors{ objects: "[product] | propertiesOf"}
/ %render-svg{path: "{{product.primary_taxon.icon}}"}

View File

@@ -11,6 +11,8 @@
margin: 0 0 0.25rem 0.25rem
&:hover, &:focus
background: transparent
&.active
box-shadow: none
a
@include border-radius(0.5em)
@@ -69,7 +71,7 @@
span.filter-label
opacity: 0.75
.filter-box.taxon-selectors, .filter-box.property-selectors
.filter-shopfront.taxon-selectors, .filter-shopfront.property-selectors
background: transparent
single-line-selectors
@@ -86,7 +88,7 @@
list-style: none
.filter-box
.filter-shopfront
// Shopfront taxons
&.taxon-selectors
@include filter-selector($clr-blue, $clr-blue-light, $clr-blue-bright)

View File

@@ -8,7 +8,7 @@
margin-left: 0
margin-right: 0
.row.filter-box:first-child, .row.filter-box.filter-box-shopfront
.row.filter-box:first-child
border: 1px solid $clr-blue-light
@include border-radius(0.25em)
margin-top: 2px
@@ -19,11 +19,6 @@
background: transparent
margin-top: 1em
.row.filter-box.filter-box-shopfront
margin-top: 0
background: transparent
border: 0 none
products .filter-box
background: #f7f7f7

View File

@@ -1,5 +1,5 @@
.filter-box.taxon-selectors.animate-hide.text-right
.filter-shopfront.taxon-selectors.animate-hide.text-right
%single-line-selectors{ objects: "Products.products | products:query | taxonsOf", "active-selectors" => "activeTaxons"}
.filter-box.property-selectors.animate-hide.text-right
.filter-shopfront.property-selectors.animate-hide.text-right
%single-line-selectors{ objects: "Products.products | products:query | propertiesOf", "active-selectors" => "activeProperties"}