我正在使用jQuery Quicksand plugin - http://jsfiddle.net/se9pY/
但我在FireBug中获得rawDestElement is undefined
...
$(function() {
$("#filter a").click(function() {
var $this = $(this),
$oriColl = $("#boxes"),
$clonedColl = $oriColl.clone(),
filtered = ($this.text() == "all") ? $("#boxes li") : $("#boxes li[data-type=" + $this.text() + "]");
$("#boxes").quicksand(filtered, { duration: 800, easing: 'easeInOutQuad' });
});
});
怎么了?
答案 0 :(得分:9)
我曾经有过这个问题,原来是一个简单的疏忽。您现在可能已经想到了这一点,但您可能只需要在所有列表项上使用唯一的data-id属性。
<li data-type="test" data-id="id-1">...</li>