diff --git a/iconomation.css b/iconomation.css new file mode 100644 index 0000000..13726d6 --- /dev/null +++ b/iconomation.css @@ -0,0 +1,26 @@ +body { +background-image: url("paper.jpg"); +} +box { + position: relative;} +#green { + background: #d6ef39; + height: 165px; + width: 165px; + margin: 10px; + position: relative; +} +#blue { + background: #00a5c6; + height: 165px; + width: 165px; + margin: 10px; + position: relative; +} +#red { + background: #ce007b; + height: 165px; + width: 165px; + margin: 10px; + position: relative; +} \ No newline at end of file diff --git a/iconomation.js b/iconomation.js new file mode 100644 index 0000000..81643b4 --- /dev/null +++ b/iconomation.js @@ -0,0 +1,63 @@ +$(document).ready(function() { + $(".button").click(function() { + $("#green").animate({ + height: "300px" + }); + $("#blue").animate({ + height: "400px" + }); + $("#red").animate({ + height: "500px" + }); + }); + $(".button2").click(function() { + $(".box").animate({ + height: '50px', + width: '300px' + }); + }); + + $(".button3").click(function() { + $("#green").animate({ + width: "500px" + }); + $("#blue").animate({ + width: "600px" + }); + $("#red").animate({ + width: "700px" + }); + }); + $(".button4").click(function() { + $(".box").animate({ + height: '300px', + width: '50px' + }); + }); + $(".button6").click(function() { + $('.box').removeAttr('style'); + }); + $(".button5").click(function() { + $(".box").css({ opacity: 0.8 }); + var h = $(window).height(); + var w = $(window).width(); + $('.box').each(function() { + var originalOffset = $(this).position(), + $this = $(this), + tLeft = w - Math.floor(Math.random() * 900), + tTop = h - Math.floor(Math.random() * 900); + + $(this).animate({ + "left": tLeft, + "top": tTop + }, 3000, function() { + $this.animate({ + "left": originalOffset.left, + "top": originalOffset.top+50 + }, 5000); + }); + }); + }); + }); + + diff --git a/index.html b/index.html index f1b9af2..cf0e840 100644 --- a/index.html +++ b/index.html @@ -1,31 +1,28 @@ -
-refresh to see it again
- - + + +