<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Styling of JS API Legend in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/1478678#M84718</link>
    <description>&lt;PRE&gt;&lt;SPAN class=""&gt;Hi Kelly. I would like to adjust the size of the legend. Can you help me?. This is my css:&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GerardoDuarte_Hodgson_0-1716587873452.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/105372iAE9C7AAADE115AA5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GerardoDuarte_Hodgson_0-1716587873452.png" alt="GerardoDuarte_Hodgson_0-1716587873452.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 24 May 2024 21:58:32 GMT</pubDate>
    <dc:creator>GerardoDuarte_Hodgson</dc:creator>
    <dc:date>2024-05-24T21:58:32Z</dc:date>
    <item>
      <title>Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59819#M5233</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hey all,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm working with the AGS JS API legend dijit (its awesome!).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Has anyone successfully styled this so as to change the size of the symbol swatches (e.g. squares representing polygon features), font-family, and font-size?&amp;nbsp; I'm simply trying to 'harmonize' the style of the legend dijit presentation with my site.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Dec 2010 14:05:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59819#M5233</guid>
      <dc:creator>ClintCabanero</dc:creator>
      <dc:date>2010-12-06T14:05:59Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59820#M5234</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;There are several css classes for the legend dijit that allow you to alter the default appearance, here's an example where the font color and family are modified for the text in the legend:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .esriLegendLayerLabel{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; font-family:'Monotype Corsiva';
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; color:red;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .esriLegendServiceLabel{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; font-family: 'Times New Roman';
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; color:green;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .esriLegendService{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; color:orange;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; font-weight:bold;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/EN/webapi/javascript/arcgis/help/jsapi_start.htm#jsapi/legend.htm" rel="nofollow noopener noreferrer" target="_blank"&gt;API Reference&lt;/A&gt;&lt;SPAN&gt; for the JavaScript API has a listing of the CSS classes.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 22:15:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59820#M5234</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2021-12-10T22:15:45Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59821#M5235</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You can increase the size of the symbol swatches using something like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .esriLegendService img{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; width:55px;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 22:15:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59821#M5235</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2021-12-10T22:15:48Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59822#M5236</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Anyone know how to use this with the&amp;nbsp; Javascript AGS api? Specifically. We create a legend at startup with:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; legend = new esri.dijit.Legend({map:map},"legendDiv");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; legend.startup();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; and in the body of the document we have&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;div id="legendDiv" dojoType="dijit.layout.ContentPane" name="my map" style="overflow:auto;width:178px;height:250px;vertical-align:top;"&amp;gt;&amp;lt;/div&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The discussion implies I can use CSS Styles to change the default name displayed by the dijit.Legend by modifying esriLegendServiceLabel. Where is this done and how does the digit know about it?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Jan 2011 21:03:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59822#M5236</guid>
      <dc:creator>RichardDaniels</dc:creator>
      <dc:date>2011-01-26T21:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59823#M5237</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Has anyone found the answer to this question?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Feb 2012 05:19:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59823#M5237</guid>
      <dc:creator>KristerVikström</dc:creator>
      <dc:date>2012-02-28T05:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59824#M5238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;AFAIK, you can only change the style of the legend elements like service label, layer label, image size, etc as set out in the API. The "name" of the legend? I presume you mean the service label. This is determined by the name of the map service(s) in the legend dijit definition. You can set the name of the service using layerInfos.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Feb 2012 06:12:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59824#M5238</guid>
      <dc:creator>EdSaunders</dc:creator>
      <dc:date>2012-02-28T06:12:49Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59825#M5239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you know if any of this has changed since the last post -- over 3 years ago?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, is the Legend title, etc, controlled by the type of renderer that is used to represent the feature layer?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example, &lt;A href="http://esri.github.io/visualization-js/enhance_legend/"&gt;in this instance&lt;/A&gt;, a unique value renderer is used and there is no sub-header in the Legend.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, when I use a classbreaksrenderer, the field used to calculate the breaks is shown below the Legend header (see below).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Legend.JPG" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/122393_Legend.JPG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;Finally, is it possible to reverse/dictate the order of the Legend items?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks...Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Aug 2015 16:10:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59825#M5239</guid>
      <dc:creator>ChristopherJohnson1</dc:creator>
      <dc:date>2015-08-14T16:10:45Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59826#M5240</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;FYI...I was able to hide the "Data_Value" using CSS and reverse the Legend items.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks...Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Aug 2015 11:20:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/59826#M5240</guid>
      <dc:creator>ChristopherJohnson1</dc:creator>
      <dc:date>2015-08-26T11:20:42Z</dc:date>
    </item>
    <item>
      <title>Re: Styling of JS API Legend</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/1478678#M84718</link>
      <description>&lt;PRE&gt;&lt;SPAN class=""&gt;Hi Kelly. I would like to adjust the size of the legend. Can you help me?. This is my css:&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GerardoDuarte_Hodgson_0-1716587873452.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/105372iAE9C7AAADE115AA5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GerardoDuarte_Hodgson_0-1716587873452.png" alt="GerardoDuarte_Hodgson_0-1716587873452.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 24 May 2024 21:58:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/styling-of-js-api-legend/m-p/1478678#M84718</guid>
      <dc:creator>GerardoDuarte_Hodgson</dc:creator>
      <dc:date>2024-05-24T21:58:32Z</dc:date>
    </item>
  </channel>
</rss>

