split out location search and map markup into directives