私はhttp://isotope.metafizzy.co/docs/options.html#onlayoutを使用していますが、次のように表示されます。
「コールバックと同様に、onLayoutは、Isotopeインスタンスがそのレイアウトロジックを実行するたびにトリガーされる関数です。」
$('#container').isotope({
onLayout: function( $elems ) {
// `this` refers to jQuery object of the container element
console.log( this.height() );
// callback provides jQuery object of laid-out item elements
$elems.css({ background: 'blue' });
}
});
つまり、「レイアウト」が終了したら、これを実行できます。
$elems.css({ background: 'blue' });
私は「$elems」を持っていませんが、「onLayout」が終了すると、必要なものを実行できることを理解できます。これを実行したいと思います。
$("#container").width();
$("#head").animate({ width: newWidth}, "fast");
しかし、「()」内の「$ elems」はどのように、そして何ですか?
ありがとう