dynamick / multiple-filter-masonry

This script extend the great Desandro Masonry plugin adding the ability to filter elements using multiple filter (checkbox)
http://dynamick.github.io/multiple-filter-masonry/
40 stars 13 forks source link

Filtering (filter change functions) does not always rebuild masonry #8

Open stefanKuijers opened 8 years ago

stefanKuijers commented 8 years ago

Symptons

Items do not take up full width of the column

Cause

Reload functions misses the masonry options;

var reload = function($container,items){      
      $container.empty();
      $(items).each(function(){
        $($container).append($(this));
      });
      $container.masonry('reloadItems');
      $container.masonry();
    };

Fix

Last line should be:

$container.masonry();