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

"showEmptyItems: false" not applied to pagination bullets #5

Open
andrejpavlovic opened this issue Dec 3, 2012 · 0 comments
Open

Comments

@andrejpavlovic
Copy link

When showEmptyItems is set to false, the last pagination bullet still shows empty items.

Changing the addPage function in the following code:

            env.$elts.paginationBtns.click(function (e) {
                goToStep(env, $(this).data("firstStep"));

to:

            env.$elts.paginationBtns.click(function (e) {
                var firstStep = $(this).data("firstStep");

                goToStep(env, (!env.params.showEmptyItems)
                    ? Math.min(firstStep, env.steps.count - env.params.dispItems)
                    : firstStep
                );

... fixes the problem.

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

No branches or pull requests

1 participant