You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
1.3 KiB

3 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. $(document).ready(function() {
  2. $().owlCarousel && ($(".owl-carousel.basic").length > 0 && $(".owl-carousel.basic").owlCarousel({
  3. margin: 30,
  4. stagePadding: 15,
  5. dotsContainer: $(".owl-carousel.basic").parents(".owl-container").find(".slider-dot-container"),
  6. responsive: {
  7. 0: {
  8. items: 1
  9. },
  10. 600: {
  11. items: 2
  12. },
  13. 1000: {
  14. items: 3
  15. }
  16. }
  17. }).data("owl.carousel").onResize(), $(".owl-carousel.single").length > 0 && $(".owl-carousel.single").owlCarousel({
  18. margin: 30,
  19. items: 1,
  20. loop: !0,
  21. stagePadding: 15,
  22. dotsContainer: $(".owl-carousel.single").parents(".owl-container").find(".slider-dot-container")
  23. }).data("owl.carousel").onResize(), $(".owl-dot").click(function() {
  24. $($(this).parents(".owl-container").find(".owl-carousel")).owlCarousel().trigger("to.owl.carousel", [$(this).index(), 300])
  25. }), $(".owl-prev").click(function(e) {
  26. e.preventDefault(), $($(this).parents(".owl-container").find(".owl-carousel")).owlCarousel().trigger("prev.owl.carousel", [300])
  27. }), $(".owl-next").click(function(e) {
  28. e.preventDefault(), $($(this).parents(".owl-container").find(".owl-carousel")).owlCarousel().trigger("next.owl.carousel", [300])
  29. }));
  30. });