preliminary js for creating pallette. need to complete grid