Colored/moveable rectangles using non OOP js