Age is now Client Side and Contact form has been added
This commit is contained in:
10
js/age.js
Normal file
10
js/age.js
Normal file
@ -0,0 +1,10 @@
|
||||
function getAge(dateString) {
|
||||
var today = new Date();
|
||||
var birthDate = dateString;
|
||||
var age = today.getFullYear() - birthDate.getFullYear();
|
||||
var m = today.getMonth() - birthDate.getMonth();
|
||||
if (m < 0 || (m === 0 && today.getDate() < birthDate.getDate())) {
|
||||
age--;
|
||||
}
|
||||
return age;
|
||||
}
|
@ -1,8 +1,3 @@
|
||||
/*!
|
||||
* Start Bootstrap - Resume v6.0.3 (https://startbootstrap.com/theme/resume)
|
||||
* Copyright 2013-2021 Start Bootstrap
|
||||
* Licensed under MIT (https://github.com/StartBootstrap/startbootstrap-resume/blob/master/LICENSE)
|
||||
*/
|
||||
(function ($) {
|
||||
"use strict"; // Start of use strict
|
||||
|
||||
|
11
js/type.js
11
js/type.js
@ -6,7 +6,6 @@ class typer{
|
||||
this.item = document.getElementById("type");
|
||||
this.text = text;
|
||||
this.retypeText = retypeText;
|
||||
this.type();
|
||||
}
|
||||
|
||||
type(){
|
||||
@ -22,7 +21,7 @@ class typer{
|
||||
this.i = 0;
|
||||
setTimeout(() => {
|
||||
this.retype();
|
||||
}, 3000);
|
||||
}, 2000);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -36,7 +35,7 @@ class typer{
|
||||
}, 100);
|
||||
}else{
|
||||
this.x++;
|
||||
//this.x > this.text.length -1 == loop
|
||||
//this.x > this.text.length -1 || loop
|
||||
if(this.x >= this.text.length - 1){
|
||||
//this.x = 0;
|
||||
this.retypeText = false;
|
||||
@ -46,4 +45,8 @@ class typer{
|
||||
}
|
||||
}
|
||||
|
||||
var work = new typer(["//Junior Software Developer", "//Aspiring Backend Engineer"], true);
|
||||
var pagetyper = new typer(["//Junior Software Developer", "//Aspiring Backend Engineer"], true);
|
||||
|
||||
setTimeout(() =>{
|
||||
pagetyper.type();
|
||||
}, 750)
|
Reference in New Issue
Block a user