Plugin Directory

Changeset 659734


Ignore:
Timestamp:
01/27/2013 03:26:27 PM (13 years ago)
Author:
ethanhackett
Message:

Fixed a JS error

File:
1 edited

Legend:

Unmodified
Added
Removed
  • post-tiles/trunk/post-tiles-frontend.js

    r623444 r659734  
    1010    // This used the category key to accent selected category
    1111    $('#category-key a').not('#category-all').click(function() {
     12        // Get category's id which is the cateogyr name
    1213        var categoryClass = '.'+$(this).attr('id');
     14        // Target all those posts except with matching category id and fade
    1315        $('ul#post-tiles li').not(categoryClass).fadeTo('slow', 0.3);
    14         $('.post-tile-selected').removeClass('post-tile-selected')
     16        // Remove the previous selected category id
     17        $('.post-tile-selected').removeClass('post-tile-selected');
     18        // Fade in the current selected category
    1519        $(categoryClass).fadeTo('fast', 1.0);
     20        // Add the active class to the category key
    1621        $(categoryClass).addClass('post-tile-selected');
     22        // Disbale the anchor
    1723        return false;
    1824    });       
     
    8288        });
    8389    // Animate Down
    84         $('li.featured-image.fade a').fadeToggle();
     90        $('li.fade a').fadeToggle();
    8591        // Action when mouse enter of featured image
    86         $('li.featured-image.fade').mouseenter(function() {
     92        $('li.fade').mouseenter(function() {
    8793            $(this).children('a').animate({
    8894                left: '0%'
     
    9298       
    9399        // Action when mouse leave of featured image
    94         $('li.featured-image.fade').mouseleave(function() {
     100        $('li.fade').mouseleave(function() {
    95101            $(this).children('a').fadeToggle();
    96102            $(this).children('a').animate({
Note: See TracChangeset for help on using the changeset viewer.