kop / yii2-scroll-pager

Infinite AJAX scrolling for Yii2 ListView widget
https://kop.github.io/yii2-scroll-pager/
MIT License
180 stars 63 forks source link

bad work positioning block on first load #86

Open FanGremlin opened 6 years ago

FanGremlin commented 6 years ago

I have problems on first load page with scroll-pager blog

I suspect that this situation is due to the fact that the script runs before the download of pictures script registration is in progress          $ this-> view-> registerJs ($ initString, View :: POS_READY, "{$ this-> id} _ias_main"); an attempt to replace POS_READY with POS_LOAD gives the correct effect when you press "Load more items", but not the first time the page loads The delay (Minimal number of milliseconds to stay in a loading state) parameter can not be passed at all for execution $ this-> render ($ model-> view?: 'category.twig', [              'dataProvider' => $ dataProvider,              'model' => $ model,              'pager' => ['class' => ScrollPager :: className (), 'delay' => 6000]          ]);

omer-sds commented 6 years ago

i am using in the listing gallery too but didnt come across this problem see here a demo http://potentialpads.idowstech.com/properties/grid, can you add a link to your current page you are working on