Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request or doc to save others some time - easy infinite scroll instead of pager #379

Open
andrewblake1 opened this issue Sep 27, 2015 · 7 comments

Comments

@andrewblake1
Copy link

andrewblake1 commented Sep 27, 2015

Not sure if you are aware how easy infinite scroll can replace paging in your grid view widget:

        'pager' => [
            'class' => \kop\y2sp\ScrollPager::className(),
            'container' => '.grid-view',
            'item' => '.kv-grid-table tbody tr',
            'triggerOffset' => 1000,
        ],

works easy to add infinite scroll. After investigating various extensions and plugins, tried this one and worked first go (so far anyway - with only one minor display anomaly on spinner after filtering).

Potentially could add option to gridview perhaps - or just a note or demo in docs might help others.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@kartik-v
Copy link
Owner

Thanks for the suggestion. Will look at it when I get time.

@andrewblake1
Copy link
Author

Don’t rush, there are a couple of minor issues when used with pjax that I will look into in next few days - i think there are events in the plugin that will fix these but I will found out and put explanation and solution back in this issue.

On 30/09/2015, at 1:25 am, Kartik Visweswaran notifications@github.com wrote:

Thanks for the suggestion. Will look at it when I get time.


Reply to this email directly or view it on GitHub.

@kartik-v
Copy link
Owner

yes as mentioned will need to evaluate once I get time for this... its currently not on my priority list

@andrewblake1
Copy link
Author

Understood, and thanks for so many great extensions. They are a massive asset to the framework.

@andrewblake1
Copy link
Author

FYI when you get time:

My final personal configuration:

        'pager' => [
            'class' => ScrollPager::className(),
            'container' => '.grid-view',
            'item' => '.kv-grid-table tbody tr',
            'enabledExtensions' => [
                ScrollPager::EXTENSION_SPINNER,
            ],
        ],

There also appears to be a minor easily by-passable bug when used with pjax at this time though could be fixed by the time you get this - my simple solution for now, and suggested plugin fix is at webcreate/infinite-ajax-scroll#219

@strtob
Copy link

strtob commented May 15, 2021

Hi,

Unfortunately, I got this error in terms of bs4:

Setting unknown property: kop\y2sp\ScrollPager::linkContainerOptions

Is it possible to make it work ?

Thanks a lot!

@maxxer
Copy link
Contributor

maxxer commented Oct 21, 2022

For the record, I used different selectors (still on bs3)

    'pager' => [
        'class' => ScrollPager::class,
        'container' => '.kv-grid-table tbody',
        'item' => 'tr',
        'enabledExtensions' => [
            ScrollPager::EXTENSION_SPINNER,
        ],
    ],

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants