Factorise code in tooltip for julia monkeypatching

Should allow IJulia to just set `Tooltip.last_token_re` to another regexp, in their profile
or even `Tooltip.prototype.extract_oir_token` if they want their full custom
logic to extract the token they want the info of in js.

Otherwise, right now they send their own version of `tooltip.js`