JavaScript helpers for rendering high-resolution image variants