Download estimator uses metadata

Ready for review.

I think (hope) the commits should each be quite clear. So if you go through them in order it shouldn't be too difficult to see what is going on. And feel free to ask if there's something that you don't understand.
Yeah, it's cool. It was more like a "note to self" for us. I know there's not much that can be done natively in JS.