-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.js
1 lines (1 loc) · 1.19 KB
/
app.js
1
$(".nojs").removeClass("nojs"),$("#nojs").addClass("js"),$("#home_button").click(function(o){$("html, body").animate({scrollTop:$("#title").offset().top},"slow"),o.stopPropagation()}),$("#about_button").click(function(o){$("html, body").animate({scrollTop:$("#about").offset().top},"slow"),o.stopPropagation()}),$("#projects_button").click(function(o){$("html, body").animate({scrollTop:$("#projects").offset().top},"slow"),o.stopPropagation()}),$("#contact_button").click(function(o){$("html, body").animate({scrollTop:$("#contact").offset().top},"slow"),o.stopPropagation()}),$("#button-hamburger").click(function(o){$("#buttons").hasClass("on")?($("#buttons").removeClass("on"),$("#buttons").addClass("off")):($("#buttons").removeClass("off"),$("#buttons").addClass("on"))});var app=angular.module("projectsApp",[]);app.controller("projectsController",["$scope","$http",function(t,o){o.get("res/projects.json").then(function(o){t.projects=o.data.projects})}]);var scroll=$(window).scrollTop();$(window).scroll(function(){scroll=$(window).scrollTop();var o=$(window).height()/2;3*o<scroll?$(".project").css("animation-play-state","running"):o<scroll&&$("#about-container").css("animation-play-state","running")});