mirror of
https://github.com/Xevion/old.xevion.github.io.git
synced 2025-12-06 15:15:39 -06:00
hire me
This commit is contained in:
@@ -2,7 +2,7 @@ $(function() {
|
|||||||
|
|
||||||
const d = new Date();
|
const d = new Date();
|
||||||
const hours = d.getHours();
|
const hours = d.getHours();
|
||||||
const nighttime = (hours >= 19) || (hours <= 7); // 7pm <= hours <= 7am
|
const nighttime = (hours >= 19) || (hours <= 7); // between 7pm and 7am
|
||||||
const body = document.querySelector('body');
|
const body = document.querySelector('body');
|
||||||
const toggle = document.getElementById('toggle');
|
const toggle = document.getElementById('toggle');
|
||||||
const input = document.getElementById('switch');
|
const input = document.getElementById('switch');
|
||||||
|
|||||||
@@ -8,16 +8,16 @@
|
|||||||
// background-color: $yellow;
|
// background-color: $yellow;
|
||||||
|
|
||||||
&__light {
|
&__light {
|
||||||
width: 20px;
|
width: 30px;
|
||||||
height: 20px;
|
height: 30px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
&__ring {
|
&__ring {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 18px;
|
width: 25px;
|
||||||
height: 18px;
|
height: 25px;
|
||||||
animation: pulsate 2s ease-out;
|
animation: pulsate 2s ease-out;
|
||||||
animation-iteration-count: infinite;
|
animation-iteration-count: infinite;
|
||||||
opacity: .0;
|
opacity: .0;
|
||||||
@@ -41,8 +41,8 @@
|
|||||||
|
|
||||||
&__led {
|
&__led {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 10px;
|
width: 13px;
|
||||||
height: 10px;
|
height: 13px;
|
||||||
background: $green;
|
background: $green;
|
||||||
border-radius: 100%;
|
border-radius: 100%;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ module.exports = gulp => {
|
|||||||
useEslintrc: true
|
useEslintrc: true
|
||||||
}))
|
}))
|
||||||
.pipe(eslint.format())
|
.pipe(eslint.format())
|
||||||
.pipe(uglify())
|
// .pipe(uglify())
|
||||||
.pipe(gulp.dest(destPath))
|
.pipe(gulp.dest(destPath))
|
||||||
.pipe(gulp.dest('js'));
|
.pipe(gulp.dest('js'));
|
||||||
});
|
});
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
78
js/main.js
78
js/main.js
@@ -1 +1,77 @@
|
|||||||
$(function(){function e(){l.classList.add("wave"),setTimeout(function(){l.classList.remove("wave")},2e3)}const t=new Date,o=t.getHours(),n=o>=19||o<=7,c=document.querySelector("body"),s=document.getElementById("toggle"),i=document.getElementById("switch");n&&(i.checked=!0,c.classList.add("night")),s.addEventListener("click",function(){const e=i.checked;e?c.classList.remove("night"):c.classList.add("night")});const r=document.querySelector(".intro").offsetHeight,a=document.getElementById("top-button"),d=$("#top-button");window.addEventListener("scroll",function(){window.scrollY>r?d.fadeIn():d.fadeOut()},!1),a.addEventListener("click",function(){$("html, body").animate({scrollTop:0},500)});const l=document.querySelector(".emoji.wave-hand");setTimeout(function(){e()},1e3),l.addEventListener("mouseover",function(){l.classList.add("wave")}),l.addEventListener("mouseout",function(){l.classList.remove("wave")}),window.sr=ScrollReveal({reset:!1,duration:600,easing:"cubic-bezier(.694,0,.335,1)",scale:1,viewFactor:.3}),sr.reveal(".background"),sr.reveal(".skills"),sr.reveal(".experience",{viewFactor:.2}),sr.reveal(".featured-projects",{viewFactor:.1}),sr.reveal(".other-projects",{viewFactor:.05})});
|
$(function() {
|
||||||
|
|
||||||
|
const d = new Date();
|
||||||
|
const hours = d.getHours();
|
||||||
|
const nighttime = (hours >= 19) || (hours <= 7); // 7pm <= hours <= 7am
|
||||||
|
const body = document.querySelector('body');
|
||||||
|
const toggle = document.getElementById('toggle');
|
||||||
|
const input = document.getElementById('switch');
|
||||||
|
|
||||||
|
if (nighttime) {
|
||||||
|
input.checked = true;
|
||||||
|
body.classList.add('night');
|
||||||
|
}
|
||||||
|
|
||||||
|
toggle.addEventListener('click', function() {
|
||||||
|
const isChecked = input.checked;
|
||||||
|
if (isChecked) {
|
||||||
|
body.classList.remove('night');
|
||||||
|
} else {
|
||||||
|
body.classList.add('night');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
const introHeight = document.querySelector('.intro').offsetHeight;
|
||||||
|
const topButton = document.getElementById('top-button');
|
||||||
|
const $topButton = $('#top-button');
|
||||||
|
|
||||||
|
window.addEventListener('scroll', function() {
|
||||||
|
if (window.scrollY > introHeight) {
|
||||||
|
$topButton.fadeIn();
|
||||||
|
} else {
|
||||||
|
$topButton.fadeOut();
|
||||||
|
}
|
||||||
|
}, false);
|
||||||
|
|
||||||
|
topButton.addEventListener('click', function() {
|
||||||
|
$('html, body').animate({scrollTop: 0}, 500);
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const hand = document.querySelector('.emoji.wave-hand');
|
||||||
|
|
||||||
|
function waveOnLoad() {
|
||||||
|
hand.classList.add('wave');
|
||||||
|
setTimeout(function() {
|
||||||
|
hand.classList.remove('wave');
|
||||||
|
}, 2000);
|
||||||
|
}
|
||||||
|
|
||||||
|
setTimeout(function() { waveOnLoad(); }, 1000);
|
||||||
|
|
||||||
|
hand.addEventListener('mouseover', function() {
|
||||||
|
hand.classList.add('wave');
|
||||||
|
});
|
||||||
|
|
||||||
|
hand.addEventListener('mouseout', function() {
|
||||||
|
hand.classList.remove('wave');
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
window.sr = ScrollReveal({
|
||||||
|
reset: false,
|
||||||
|
duration: 600,
|
||||||
|
easing: 'cubic-bezier(.694,0,.335,1)',
|
||||||
|
scale: 1,
|
||||||
|
viewFactor: 0.3
|
||||||
|
});
|
||||||
|
|
||||||
|
sr.reveal('.background');
|
||||||
|
sr.reveal('.skills');
|
||||||
|
sr.reveal('.experience', {viewFactor: 0.2});
|
||||||
|
sr.reveal('.featured-projects', {viewFactor: 0.1});
|
||||||
|
sr.reveal('.other-projects', {viewFactor: 0.05});
|
||||||
|
|
||||||
|
});
|
||||||
|
|||||||
20
package-lock.json
generated
20
package-lock.json
generated
@@ -501,9 +501,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"browser-sync": {
|
"browser-sync": {
|
||||||
"version": "2.20.0",
|
"version": "2.21.0",
|
||||||
"resolved": "https://registry.npmjs.org/browser-sync/-/browser-sync-2.20.0.tgz",
|
"resolved": "https://registry.npmjs.org/browser-sync/-/browser-sync-2.21.0.tgz",
|
||||||
"integrity": "sha512-PjF3EHLzgax11AuKfTzgx4wUe7ksT2VSWxdq5FssvytxGSdIqJWvV3unM0+lnI0BxGt/8sGLZEIlgx7Dn2S0LQ==",
|
"integrity": "sha1-kc3jqEUvIvNV6+cXyhs8Hb+coJY=",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"browser-sync-ui": "1.0.1",
|
"browser-sync-ui": "1.0.1",
|
||||||
@@ -514,6 +514,8 @@
|
|||||||
"easy-extender": "2.3.2",
|
"easy-extender": "2.3.2",
|
||||||
"eazy-logger": "3.0.2",
|
"eazy-logger": "3.0.2",
|
||||||
"emitter-steward": "1.0.0",
|
"emitter-steward": "1.0.0",
|
||||||
|
"etag": "1.8.1",
|
||||||
|
"fresh": "0.5.2",
|
||||||
"fs-extra": "3.0.1",
|
"fs-extra": "3.0.1",
|
||||||
"http-proxy": "1.15.2",
|
"http-proxy": "1.15.2",
|
||||||
"immutable": "3.8.1",
|
"immutable": "3.8.1",
|
||||||
@@ -2865,9 +2867,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"fresh": {
|
"fresh": {
|
||||||
"version": "0.5.0",
|
"version": "0.5.2",
|
||||||
"resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz",
|
||||||
"integrity": "sha1-9HTKXmqSRtb9jglTz6m5yAWvp44=",
|
"integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"fs-exists-sync": {
|
"fs-exists-sync": {
|
||||||
@@ -7993,6 +7995,12 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"fresh": {
|
||||||
|
"version": "0.5.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.0.tgz",
|
||||||
|
"integrity": "sha1-9HTKXmqSRtb9jglTz6m5yAWvp44=",
|
||||||
|
"dev": true
|
||||||
|
},
|
||||||
"http-errors": {
|
"http-errors": {
|
||||||
"version": "1.6.2",
|
"version": "1.6.2",
|
||||||
"resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.2.tgz",
|
"resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.2.tgz",
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
"author": "Brittany Chiang",
|
"author": "Brittany Chiang",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"browser-sync": "^2.20.0",
|
"browser-sync": "^2.21.0",
|
||||||
"eslint-config-starry": "7.0.0",
|
"eslint-config-starry": "7.0.0",
|
||||||
"eslint-plugin-starry": "5.0.0",
|
"eslint-plugin-starry": "5.0.0",
|
||||||
"gulp": "3.9.1",
|
"gulp": "3.9.1",
|
||||||
|
|||||||
BIN
resume.pdf
BIN
resume.pdf
Binary file not shown.
Reference in New Issue
Block a user