gilbertorm83@gmail.com

Add icon with the description of the layer in the legend widget web appbuilder 2.1

Discussion created by gilbertorm83@gmail.com on Sep 5, 2016

Hello!

I am using the web AppBuilder 2.1. I need to customize the widget legend, that beside each layer name, appears an icon any, that when clicked, will open an alert with the contents of the description of the layer (description, not the title). I would like some tips on how to do this, because when you try to change the widget.js file, found in the following line of code the possibility to add a css class to make the insertion of this image, however, it is only the first layer. How to do this for all the layers, and how to seek information?


this.legend = new Legend (legendParams, html.create ("div", {class "icon-description"}, this.domNode));

 

 

Thank you!
Gilberto.

Outcomes