-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscript.js
102 lines (95 loc) · 3.63 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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
const body = document.querySelector('body');
const menuBars = document.getElementById('menu-bars');
const overlay = document.getElementById('overlay');
const nav1 = document.getElementById('nav-1');
const nav2 = document.getElementById('nav-2');
const nav3 = document.getElementById('nav-3');
const navItems = [nav1, nav2, nav3];
function toggleNav() {
menuBars.classList.toggle('change');
overlay.classList.toggle('overlay-active');
if (overlay.classList.contains('overlay-active')) {
overlay.classList.replace('overlay-slide-left', 'overlay-slide-right');
} else {
overlay.classList.replace('overlay-slide-right', 'overlay-slide-left');
}
body.classList.toggle('overflow');
}
menuBars.addEventListener('click', toggleNav);
navItems.forEach((nav) => {
nav.addEventListener('click', toggleNav);
});
const speakerCardsItems = [
{
speaker_image: 'images/img/zabi0.png',
speaker_name: 'Ing . Nelofar Zabi',
speaker_education:
'B.Sc degree in computer Science, at Kabul University AFG',
speaker_bio: `Software Engineer at apple company , with more than 7 years experience in
developing Software .`,
},
{
speaker_image: 'images/img/zuhra0.png',
speaker_name: 'Ing . Zuhra Hashimi',
speaker_education:
'B.Sc degree in computer Science, at Kabul University AFG',
speaker_bio: `Chairperson-Board of Directors at STEAD Society, National Outreach Coordinator at The
International .`,
},
{
speaker_image: 'images/img/king0.png',
speaker_name: 'Ing . Khalid Zabi',
speaker_education:
'B.Sc degree in computer Science, at Banglore University AFG',
speaker_bio: `Founder and Apple Company | Yagnkar Company | Women & Girls, Empowerment
| Woman right.`,
},
{
speaker_image: 'images/img/aisha.png',
speaker_name: 'Ing . Omar Walizada',
speaker_education:
'B.Sc Honoursstudent in computer Science, at Kateb University USA',
speaker_bio: `An experienced Software designer and developer. Managed native and hybrid
mobile applications .`,
},
{
speaker_image: 'images/img/zubair1.png',
speaker_name: 'Ing . Sahil Tammem ',
speaker_education: `Colorado Technical University Master of Science in Management,
Organizational Leadership and Change 2021 - 2023`,
speaker_bio: `Program Manager at USA Company . Washington,
District of Columbia, United States `,
},
{
speaker_image: 'images/img/tahmin.png',
speaker_name: 'Ing . Tahmin Alokozay',
speaker_education:
'B.Sc Honoursstudent in computer Science, at Kateb University USA',
speaker_bio: `Program Manager at USA Company . Washington,
District of Columbia, United States `,
},
];
speakerCardsItems.forEach((Element, index) => {
const speakerCard = document.querySelector('.featured_speakers_main_div');
const cardSection = document.createElement('div');
cardSection.classList = 'cardSection';
const speakerCardHTML = `
<div class='speaker_div'>
<div class='speaker_image_container'>
<img class='speaker_image' src='${speakerCardsItems[index].speaker_image}' alt=''>
</div>
<div class='speaker_text_container'>
<h3 class='speaker_name'> ${speakerCardsItems[index].speaker_name}</h3>
<p class="speaker_education_background">
${speakerCardsItems[index].speaker_education}
</p>
<div class='divider_line'></div>
<p class='speaker_education_bio'>
${speakerCardsItems[index].speaker_bio}
</p>
</div>
</div>
`;
cardSection.innerHTML += speakerCardHTML;
speakerCard.appendChild(cardSection);
});