Skip to content

Calculate dots on setPosition #3003

Open
@fdiluzio

Description

@fdiluzio

short description of the bug / issue, provide more detail below.

_.buildDots() should be called in setPostion():
however, by doing that, the behavior of the dots does not work after using the slider.

http://jsfiddle.net/fmo50w7n/1311/

calling _.build after setPosition where the dots no longer work properly:

http://jsfiddle.net/fmo50w7n/1313/

====================================================================

Steps to reproduce the problem

Initial:
slider.slick({
infinite: false,
draggable: false,
slidesToShow: 3,
autoplay: false,
dots: true
});

Then:

slider.slick('slickSetOption', 'slidesToShow', 1);
slider.slick('setPosition');

====================================================================

What is the expected behaviour?

Number of dots under Slider should be re-calculated since going from 3 to 2 Slides per page changes how many dots should be shown.

====================================================================

What is observed behaviour?

Number of dots is based on initial slidesToShow. Aafter using method to change slidesToShow the number of dot is not recalculated.

====================================================================

More Details

jQuery 3.0, Slick 1.7.0

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions