Set minimum height of svg element based on legend height required