JS coloring and JS logic for editing