-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.js
More file actions
55 lines (49 loc) · 1.17 KB
/
Copy pathmain.js
File metadata and controls
55 lines (49 loc) · 1.17 KB
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
let header = document.querySelector('header');
window.addEventListener('scroll', () =>{
header.classList.toggle('shadow', window.scrollY > 0);
});
let menu = document.querySelector('#menu-icon');
let navbar = document.querySelector('.navbar');
menu.onclick = () =>{
menu.classList.toggle('bx-x');
navbar.classList.toggle('active');
}
window.onscroll = () =>{
menu.classList.remove('bx-x');
navbar.classList.remove('active');
}
var swiper = new Swiper(".home", {
spaceBetween: 30,
centeredSlides: true,
autoplay: {
delay: 4000,
disableOnInteraction: false,
},
pagination: {
el: ".swiper-pagination",
clickable: true,
},
});
var swiper = new Swiper(".coming-container", {
spaceBetween: 20,
loop: true,
centeredSlides: true,
autoplay: {
delay: 2000,
disableOnInteraction: false,
},
breakpoints: {
0: {
slidesPerView: 2,
},
568: {
slidesPerView: 3,
},
768: {
slidesPerView: 4,
},
968: {
slidesPerView: 5,
},
}
});