moved all javascript to map.js