added js to make cubes wiggle
seperated code to js. cleaned up canvas elem