Summary: When loading the exercise in local mode, the <script> block would immediately run before `KhanUtil` was defined, resulting in the screen-grabber-thing complaining about `ReferenceError: Can't find variable: KhanUtil`. Instead since the p1Position function is only called once, I just unfactored the logic into that one place. I also noticed a separate bug when testing where the graph dimensions weren't always computed properly, so I kinda made that a little better. (check out the last hint at http://sandcastle.kasandbox.org/media/castles/Khan:master/exercises/solving_for_the_y-intercept.html?debug&problem=given-point&seed=129) Test Plan: Load http://exercises.ka.local/exercises/solving_for_the_y-intercept.html?debug&problem=given-point and don't see a JS error in the console. Take hints and see things work. Load http://exercises.ka.local/exercises/solving_for_the_y-intercept.html?debug&problem=given-point&seed=129 and take all hints. Notice the graph in the last hint is less insane. Reviewers: emily Reviewed By: emily Differential Revision: https://phabricator.khanacademy.org/D14870
Summary: Also did some misc cleanup in khan-exercise.js, mostly related to module-y things ("151 ++----"). I combined local jquery-ui into one file to make it easier to load. Test Plan: Opened addition_1, deriviative_intuition, graphing_points_2 locally, and all looked fine. In webapp/khan-exercises/, ran: ``` npm install -g requirejs r.js -o requirejs.config.js ``` then saw that /exercises/addition_1 looked right. Reviewers: eater, jack Reviewed By: jack CC: alex Differential Revision: http://phabricator.khanacademy.org/D7095
…tly-expanding whitespace problem in the cleaner.
Test Plan: local mode in chrome Reviewers: cbhl Reviewed By: cbhl CC: alpert Differential Revision: http://phabricator.khanacademy.org/D2079
…t fraction doesn't reduce by default