I was able to plot a map with goe JSON file and color code with the values of the shape file. now i want to add a legend for colors of the shapes. there is an option in google overlay component to display and customize the legend.

Can any explain on how to achieve this or display the legend in newMapComponent.

Any help is greatly appreciated.