From 8af2fc7bcc963e5384435e5949695ad9f83901b8 Mon Sep 17 00:00:00 2001 From: danielvincent Date: Fri, 21 Jan 2011 01:16:34 -0800 Subject: [PATCH] fix in calculating selected states on aspect filters --- public/javascripts/aspect-filters.js | 4 ++-- public/stylesheets/sass/application.sass | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/public/javascripts/aspect-filters.js b/public/javascripts/aspect-filters.js index cb7c8ad8a..50af0b769 100644 --- a/public/javascripts/aspect-filters.js +++ b/public/javascripts/aspect-filters.js @@ -11,7 +11,7 @@ $(document).ready(function(){ var button = $(this), guid = button.attr('data-guid'); - if(guid && location.href.search("a_ids..="+guid) != -1){ + if(guid && location.href.search("a_ids..="+guid+"(&|$)") != -1){ button.addClass('selected'); selectedGUIDS.push(guid); } @@ -115,7 +115,7 @@ $(document).ready(function(){ }); // set url - history.pushState(null, document.title, generateURL()); + history.pushState(null, document.title, newURL); $.ajax({ url : newURL, diff --git a/public/stylesheets/sass/application.sass b/public/stylesheets/sass/application.sass index 08e733bff..03b95e8a0 100644 --- a/public/stylesheets/sass/application.sass +++ b/public/stylesheets/sass/application.sass @@ -2033,6 +2033,9 @@ h3,h4 :color #fff :font :weight normal + &:hover + :text + :decoration none .aspects :position relative