disable draggable for 1 second in flickticky slideri dont want to set it as a var;i want to disable it by slider class selector
To disable the draggable feature of the flickticky slider using the class selector, you can use the following code:
$(".slider").flickity("option", "draggable", false);
setTimeout(function() {
$(".slider").flickity("option", "draggable", true);
}, 1000);
In this code, we use the flickity method to access the slider's options. We set the draggable option to false to disable dragging. Then, after a delay of 1 second (1000 milliseconds), we set the draggable option back to true to re-enable dragging.
Make sure to replace slider with the actual class name of your flickticky slider
原文地址: https://www.cveoy.top/t/topic/h7vI 著作权归作者所有。请勿转载和采集!