Hide Legend

Updated directive and added option to show or hide legend.