How do you program a piano roll editor in JavaScript.