-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
42 lines (40 loc) · 1.33 KB
/
index.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
// Showcase proficiency in jQuery event handling and DOM manipulation
$(document).ready(function () {
// Demonstrate ability to create interactive tab functionality
$("#mountain-1, #mountain-2").click(function () {
$("#mountain-1, #mountain-2").toggleClass("active inactive");
$("#tab-1-image, #tab-2-image").toggleClass(
"active-tab-image inactive-tab-image"
);
$("#event-schedule-section").toggleClass("active-section inactive-section");
});
// Highlight skills in implementing accordion functionality
$("#accordion-button-1").click(function () {
$("#accordion-button-1").toggleClass('"" collapsed');
$("#mountain1-details").toggleClass('"" show');
});
$("#accordion-button-2").click(function () {
$("#accordion-button-2").toggleClass('"" collapsed');
$("#mountain2-details").toggleClass('"" show');
});
});
// Exhibit expertise in responsive design and smooth scrolling
$(".footer-logo-link, .navbar-brand").click(function () {
if ($(window).width() >= 900) {
// Implement smooth scrolling for desktop view
$("html, body").animate(
{
scrollTop: $("#desktop-hero").offset().top,
},
800
);
} else {
// Optimize smooth scrolling for mobile view
$("html, body").animate(
{
scrollTop: $("#hero").offset().top,
},
300
);
}
});