-
Notifications
You must be signed in to change notification settings - Fork 0
/
script.js
65 lines (56 loc) · 2.06 KB
/
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
const design_card_butttons = document.querySelectorAll('.design-card');
const introduction_text = document.querySelectorAll('.introduction-text');
const single_profile_card = document.querySelectorAll('.single-profile-card');
const testimonial_card = document.querySelectorAll('.testimonial-card');
design_card_butttons.forEach((button, index) => {
button.addEventListener('click', () => {
introduction_text.forEach((introduction, introductionIndex) => {
if (index === introductionIndex) {
introduction.style.display = 'block';
} else {
introduction.style.display = 'none';
}
});
design_card_butttons.forEach((btn, btnIndex) => {
if (index === btnIndex) {
btn.classList.add('active');
} else {
btn.classList.remove('active');
}
});
});
});
single_profile_card.forEach((btn, index) => {
btn.addEventListener('click', ()=> {
testimonial_card.forEach((testimonialCard, testimonialCardIndex) => {
if (index === testimonialCardIndex) {
testimonialCard.style.display = 'block';
} else {
testimonialCard.style.display = 'none';
}
});
single_profile_card.forEach((cardBtn, cardIndex) => {
if (index === cardIndex) {
cardBtn.classList.add('profile-card-active');
} else {
cardBtn.classList.remove('profile-card-active');
}
});
});
});
//PreLoder
var preloder = document.getElementById("loading");
function myfunction(){
preloder.style.display = "none";
}
//Responsive script
// let burger = document.querySelector('.burger');
// let mainMenu = document.querySelector('.navbar-menu');
// let close = document.querySelector('.close');
// burger.addEventListener('click' , ()=>{
// mainMenu.style.display = 'flex';
// mainMenu.style.top ='0';
// })
// close.addEventListener('click' , ()=>{
// mainMenu.style.top ='-100';
// })