updated JS with heatmap and pinning