requirements met and functioning in Chrome.

TODO: refactor js code; write tests; test across platforms/browsers