-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
84 lines (71 loc) · 2.08 KB
/
script.js
File metadata and controls
84 lines (71 loc) · 2.08 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
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
AOS.init({ disable: 'mobile' });
var navbarOpen = false;
var exp = {
html: 2019,
css: 2019,
js: 2020,
php: 2021
};
var typed = new Typed('#typed', {
strings: ['Naadir Al Ari', 'Naadir Al Atilla'],
backSpeed: 55,
typeSpeed: 55,
backDelay: 25
});
var date = new Date();
var currentYear = date.getFullYear();
$('#html-exp').html(`${currentYear - exp.html} > years`);
$('#css-exp').html(`${currentYear - exp.css} > years`);
$('#js-exp').html(`${currentYear - exp.js} years`);
$('#php-exp').html(`${currentYear - exp.php} > years`);
$('.copyright').html(`© ${currentYear} NavdPlay. All Rights Reserved`);
$('.projects').click(function() {
var rep = $(this).attr('data-value');
window.open('https://navdplay.github.io/' + rep + '/');
});
var headHeight = $('.header-container').height();
var dropLinkHeight = $('.dropdown-links').height();
var dropHeight = ((dropLinkHeight + 35) * 3);
$('.dropdown-container').css({
'height': dropHeight + 'px',
'top': '-' + dropHeight + 'px'
});
function mobileNavbar(x) {
if (navbarOpen) {
x.classList.remove('fa-times');
x.classList.add('fa-bars');
$('.dropdown-container').css({
'top': '-' + dropHeight + 'px'
});
navbarOpen = false;
} else {
x.classList.remove('fa-bars');
x.classList.add('fa-times');
$('.dropdown-container').css({
'top': '40px'
});
navbarOpen = true;
}
}
function linkClick() {
document.getElementById('menu-icon').classList.remove('fa-times');
document.getElementById('menu-icon').classList.add('fa-bars');
$('.dropdown-container').css({
'top': '-' + dropHeight + 'px'
});
}
function refreshPage() {
location.replace('index.html');
}
function githubRedir() {
window.open('https://github.com/NavdPlay/');
}
function instagramRedir() {
window.open('https://instagram.com/nerosann_/');
}
function tiktokRedir() {
window.open('https://tiktok.com/@nerosann_/');
}
function discordRedir() {
window.open('https://discordapp.com/users/685465239440982016/');
}