changes design to accept polygons and collections