add custom content to a layer legend