0

我的网址是 leftsideart (dot) co (dot) nz

我正在使用以下同位素设置:

jQuery('#post-area').isotope({
    animationOptions: {
        duration: 750,
        easing: 'linear',
        queue: false
    },
    getSortData : {
        number : function( $elem ) {
        return parseInt( $elem.find('.order').text(), 10 );
        }
    },
    sortBy : 'number',
    sortAscending : true,
    animationEngine : 'jquery'
});

var jQuerycontainer = jQuery('#post-area');
jQuerycontainer.imagesLoaded( function() {
    jQuerycontainer.isotope();
});

但我的 div 没有正确排序。同位素肯定会影响顺序,因为我尝试在我的 wordpress 循环中回显随机数,而不是增加数字和相应的 div 洗牌。

另外,可以肯定的是,当我将更改“sortAscending”更改为 false 时,div 的一般顺序是相反的。

Isotope 是否仅提供一般排序而不是精确排序?

4

1 回答 1

0

对于类似的问题,这对我有用

layoutMode: 'cellsByColumn',
cellsByColumn: {
  columnWidth: 240,
  rowHeight: 360
}

文档在这里http://isotope.metafizzy.co/v1/demos/layout-modes.html

于 2014-09-14T08:43:13.263 回答