Refactored Colorplane.js