-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscript.js
37 lines (31 loc) · 908 Bytes
/
script.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// //////////////////////////////////////
// Carousel slider
$(".slick-slider").slick({
slidesToShow: 5,
slidesToScroll: 1,
autoplay: true,
autoplaySpeed: 500,
dots: false,
prevArrow: false,
nextArrow: false,
});
///////////////////////////////////////////////////////////
// Smooth scrolling animation
// const allLinks = document.querySelectorAll("a:link");
// allLinks.forEach(function (link) {
// link.addEventListener("click", function (e) {
// e.preventDefault();
// const href = link.getAttribute("href");
// Scroll back to top
// if (href === "#")
// window.scrollTo({
// top: 0,
// behavior: "smooth",
// });
// // Scroll to other links
// if (href !== "#" && href.startsWith("#")) {
// const sectionEl = document.querySelector(href);
// sectionEl.scrollIntoView({ behavior: "smooth" });
// }
// });
// });