add basic map
part fix
add conditional checking to javascript