-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
187 lines (183 loc) · 9.07 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
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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
// NAVBAR SCROLLDOWN EFFECT START
$(window).scroll(function () {
if ($(window).scrollTop() >= 50) {
$('.main_nav').css('box-shadow', '0 4px 12px 0 rgb(110 87 224 / 30%), 0 2px 4px rgb(110 87 224 / 40%)');
$('.main_nav').css('background', 'var(--body-color)', 'important');
$('.main_nav').css('border-bottom', '2px solid var(--primaryColor)');
} else {
$('.main_nav').css('background', 'transparent');
$('.main_nav').css('border-bottom', 'none');
$('.main_nav').css('box-shadow', 'none');
}
});
// NAVBAR SCROLLDOWN EFFECT END
// LINK SWITCHER START
document.getElementById("HME").addEventListener("click", function () {
document.getElementById("HME").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("ABT").addEventListener("click", function () {
document.getElementById("ABT").classList.add("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("EDU").addEventListener("click", function () {
document.getElementById("EDU").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("SKL").addEventListener("click", function () {
document.getElementById("SKL").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("SRV").addEventListener("click", function () {
document.getElementById("SRV").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("PRT").addEventListener("click", function () {
document.getElementById("PRT").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("CNT").classList.remove("active");
});
document.getElementById("CNT").addEventListener("click", function () {
document.getElementById("CNT").classList.add("active");
document.getElementById("ABT").classList.remove("active");
document.getElementById("EDU").classList.remove("active");
document.getElementById("HME").classList.remove("active");
document.getElementById("SRV").classList.remove("active");
document.getElementById("SKL").classList.remove("active");
document.getElementById("PRT").classList.remove("active");
});
// LINK SWITCHER END
// BLOCK SWITCHING START
var element__btn___1 = document.getElementById("basic-success-trigger");
var element__btn___2 = document.getElementById("basic-primary-trigger");
if (element__btn___1) {
document.getElementById("basic-success-trigger").addEventListener("click", function () {
document.getElementById("basic-success-trigger").classList.add("active__btn");
document.getElementById("grad__cap").style.setProperty("color", "#fff", "important");
document.getElementById("briefcase").style.setProperty("color", "var(--primaryHoverColor)", "important");
document.getElementById("basic-primary-trigger").classList.remove("active__btn");
document.getElementById("ed__block__1").style.setProperty("display", "block", "important");
document.getElementById("ed__block__2").style.setProperty("display", "block", "important");
document.getElementById("ed__block__3").style.setProperty("display", "block", "important");
document.getElementById("ed__block__4").style.setProperty("display", "block", "important");
document.getElementById("work__block__1").style.setProperty("display", "none", "important");
document.getElementById("work__block__2").style.setProperty("display", "none", "important");
document.getElementById("work__block__3").style.setProperty("display", "none", "important");
document.getElementById("work__block__4").style.setProperty("display", "none", "important");
});
}
if (element__btn___2) {
document.getElementById("basic-primary-trigger").addEventListener("click", function () {
document.getElementById("basic-primary-trigger").classList.add("active__btn");
document.getElementById("briefcase").style.setProperty("color", "#fff", "important");
document.getElementById("grad__cap").style.setProperty("color", "var(--primaryHoverColor)", "important");
document.getElementById("basic-success-trigger").classList.remove("active__btn");
document.getElementById("work__block__1").style.setProperty("display", "block", "important");
document.getElementById("work__block__2").style.setProperty("display", "block", "important");
document.getElementById("work__block__3").style.setProperty("display", "block", "important");
document.getElementById("work__block__4").style.setProperty("display", "block", "important");
document.getElementById("ed__block__1").style.setProperty("display", "none", "important");
document.getElementById("ed__block__2").style.setProperty("display", "none", "important");
document.getElementById("ed__block__3").style.setProperty("display", "none", "important");
document.getElementById("ed__block__4").style.setProperty("display", "none", "important");
});
}
// BLOCK SWITCHING END
// SCROLLDOWN
// (function ($) {
// $(document).ready(
// function () {
// $("body").niceScroll({
// cursorwidth: "10px",
// scrollspeed: 60,
// autohidemode: true,
// background: 'transparent',
// hidecursordelay: 400,
// enablekeyboard: true,
// horizrailenabled: true,
// bouncescroll: false,
// smoothscroll: true,
// iframeautoresize: true,
// touchbehavior: false,
// zindex: 999,
// overflowx:false
// });
// }
// );
// })(jQuery);
// fakeloader initialization
$(document).ready(function () {
$.fakeLoader({
timeToHide: 5000,
bgColor: "hsl(250, 69%, 61%)",
spinner: "spinner7"
});
});
// Newsletter POP UP
$(document).ready(function () {
setTimeout(function () {
$('#myModal').modal('show');
}, 20000);
});
$("#closebutton").click(function () {
$('.modal-backdrop').remove();
});
// Cookie Pop-up
$(document).ready(function () {
setTimeout(function () {
$('#cookie_modal').modal('show');
}, 9500);
});
$("#ok__btn").click(function () {
$('.modal-backdrop').remove();
});
// Example starter JavaScript for disabling form submissions if there are invalid fields
(function () {
// Fetch all the forms we want to apply custom Bootstrap validation styles to
var forms = document.querySelectorAll('.needs-validation')
// Loop over them and prevent submission
Array.prototype.slice.call(forms)
.forEach(function (form) {
form.addEventListener('submit', function (event) {
if (!form.checkValidity()) {
event.preventDefault()
event.stopPropagation()
}
form.classList.add('was-validated')
}, false)
})
});
// TOOLTIPS INITIALIZERbasic-primary-trigger
var tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'))
var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {
return new bootstrap.Tooltip(tooltipTriggerEl)
})