<?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: Close widget panel on selection changed in Web AppBuilder Custom Widgets Questions</title>
    <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870777#M12826</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;What widget panel are you wanting to close? There is no selection-change on the map class.&amp;nbsp;A FeatureLayer does have&amp;nbsp;a selection-complete event though. So you have to attach to a specific layers selection-complete&amp;nbsp;or selection-clear event.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 08 Mar 2018 17:23:13 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2018-03-08T17:23:13Z</dc:date>
    <item>
      <title>Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870776#M12825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am working with WAB 2.6 and want to close a widget panel when the selection in the map is changed. I can see the map.on("selection-change") code in some other question samples but don't see anything about it in the API 3.23 reference under map events. Can someone tell me the syntax for this function, where it goes and what needs to be defined in order to use the event handler? Thanks, cob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 16:58:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870776#M12825</guid>
      <dc:creator>CharlesBailey3</dc:creator>
      <dc:date>2018-03-08T16:58:57Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870777#M12826</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;What widget panel are you wanting to close? There is no selection-change on the map class.&amp;nbsp;A FeatureLayer does have&amp;nbsp;a selection-complete event though. So you have to attach to a specific layers selection-complete&amp;nbsp;or selection-clear event.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 17:23:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870777#M12826</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-03-08T17:23:13Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870778#M12827</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="display: inline !important; float: none; background-color: transparent; color: #3d3d3d; font-family: Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px; word-wrap: break-word;"&gt;It's a custom in panel that displays the area and perimeter of the selected feature via a feature action. I want it to close whenever any other feature is selected in the map - and it also needs to work on layers added to the map from local sources - can I use &lt;/SPAN&gt;&lt;EM style="background-color: transparent; color: #3d3d3d; font-family: Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size: 15px; font-style: italic; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px; word-wrap: break-word; padding: 0px; margin: 0px;"&gt;lang.hitch(this&lt;/EM&gt;&lt;SPAN style="display: inline !important; float: none; background-color: transparent; color: #3d3d3d; font-family: Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px; word-wrap: break-word;"&gt; or something to make it apply to any layer in the map? Thanks Robert - cob&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 19:37:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870778#M12827</guid>
      <dc:creator>CharlesBailey3</dc:creator>
      <dc:date>2018-03-08T19:37:17Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870779#M12828</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P class=""&gt;Cob,&lt;/P&gt;&lt;P class=""&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp; Is it the selection widget that is used to select the feature or are you just talking about selected it using a pop Up?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 20:48:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870779#M12828</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-03-08T20:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870780#M12829</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just the popup by clicking the feature on the map - are you thinking about the selection change on the popup class? Could something like this work?&lt;/P&gt;&lt;PRE style="margin: 0.5em 0.5em 0.5em 0px; white-space: pre; line-height: normal; font-family: Consolas, 'Andale Mono', 'Lucida Console', Monaco, 'Courier New', Courier, monospace; font-size: 14px; word-wrap: break-word; tab-size: 4; max-width: 100%; border-radius: 3px; padding: 0.5em 0px 0.5em 0.5em; background: #fafafa; color: #4d4d4d; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial; border: 2px solid #dddddd;"&gt;&lt;SPAN style="margin: 0px; color: #595959;"&gt;map&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #595959;"&gt;infoWindow&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #595959;"&gt;on&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #dd1144;"&gt;"selection-change"&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #595959;"&gt; &lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #333333; font-weight: bold;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;()&lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #595959;"&gt; &lt;/SPAN&gt;&lt;SPAN style="margin: 0px; color: #666600;"&gt;{&lt;/SPAN&gt;Close the Panel}&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 20:55:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870780#M12829</guid>
      <dc:creator>CharlesBailey3</dc:creator>
      <dc:date>2018-03-08T20:55:56Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870781#M12830</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P class=""&gt;Cob,&lt;/P&gt;&lt;P class=""&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp; Absolutely that is where I am going.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2018 20:59:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870781#M12830</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-03-08T20:59:18Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870782#M12831</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK I tried it in a test setting but it doesn't seem to recognize the event. This code is in the widget.js file (which may not be the right place) for the test widget infographic :I defined 'esri/dijit/Popup' and function Popup, and here is the code in the PostCreate function:&amp;nbsp;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;SPAN style="color: #0000ff;"&gt;this&lt;/SPAN&gt;.inherited(arguments);&lt;/PRE&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;map.infoWindow.on(&lt;SPAN style="color: #800000;"&gt;"selection-change"&lt;/SPAN&gt;, &lt;SPAN style="color: #0000ff;"&gt;function&lt;/SPAN&gt;() { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;console.log(&lt;SPAN style="color: #800000;"&gt;'foo'&lt;/SPAN&gt;);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; PanelManager.getInstance().closePanel(&lt;SPAN style="color: #0000ff;"&gt;this&lt;/SPAN&gt;.id + &lt;SPAN style="color: #800000;"&gt;'_panel'&lt;/SPAN&gt;);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; });

It fails with no error, and is not firing the selection event at all (i.e. no 'foo' printed). I know the close panel routine works because I 
had a click event in there before with the same code. I also tried this.map.infoWindow.on(...with the same results. Thoughts? 

&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 17:01:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870782#M12831</guid>
      <dc:creator>CharlesBailey3</dc:creator>
      <dc:date>2021-12-12T17:01:36Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870783#M12832</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Your code should be:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;this&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;map&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;infoWindow&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;on&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"selection-change"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; lang&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;hitch&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;this&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;function&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
&amp;nbsp; PanelManager&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;getInstance&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;closePanel&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;this&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;id &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'_panel'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 10:51:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870783#M12832</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-12T10:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: Close widget panel on selection changed</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870784#M12833</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Outstanding as usual Robert, thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Mar 2018 15:29:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/close-widget-panel-on-selection-changed/m-p/870784#M12833</guid>
      <dc:creator>CharlesBailey3</dc:creator>
      <dc:date>2018-03-09T15:29:58Z</dc:date>
    </item>
  </channel>
</rss>

