<?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: off panel widget icon in Web AppBuilder Custom Widgets Questions</title>
    <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773679#M1860</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Robert,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Doh! Why didn't I think of using the onOpen() method?! The code you have looks perfect for what I want to do, thanks for your help. I assume you're setting the widget's closeable property true in the app config.js, so that the icon is displayed?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Miles.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 24 Apr 2018 22:22:30 GMT</pubDate>
    <dc:creator>mileshitchen1</dc:creator>
    <dc:date>2018-04-24T22:22:30Z</dc:date>
    <item>
      <title>off panel widget icon</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773677#M1858</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I'm trying to create an off panel widget that when clicked will zoom to a predefined level. I'd like to use an existing widget icon. My problem is that I'm using the following html in the Widget.html file and the border around the icon is being displayed slightly larger than a standard in-panel widget icon, ie 42x45 pixels, rather than 40x40 pixels, and I have no idea why. Any help would be much appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class="" style="color: #26282a; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-size: 9.5pt;"&gt;div&lt;/SPAN&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: red; font-size: 9.5pt;"&gt;title&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;="Zoom To"&lt;/SPAN&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: red; font-size: 9.5pt;"&gt;data-dojo-attach-event&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;="onclick:_onButtonClicked"&lt;/SPAN&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: red; font-size: 9.5pt;"&gt;class&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;="jimu-widget-onscreen-icon"&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="" style="color: #26282a; background-color: #ffffff;"&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-size: 9.5pt;"&gt;img&lt;/SPAN&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: red; font-size: 9.5pt;"&gt;src&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;="widgets/About/images/icon.png"&lt;/SPAN&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="" style="color: #26282a; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-size: 9.5pt;"&gt;div&lt;/SPAN&gt;&lt;SPAN style="color: blue; font-size: 9.5pt;"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Miles.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2018 21:31:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773677#M1858</guid>
      <dc:creator>mileshitchen1</dc:creator>
      <dc:date>2018-04-24T21:31:05Z</dc:date>
    </item>
    <item>
      <title>Re: off panel widget icon</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773678#M1859</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mile you should look at my Layer Toggle Button widget.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is a on screen widget that does not open a UI but executes code when clicked.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/docs/DOC-8592-layer-toggle-button-widget-version-22-01132017"&gt;https://community.esri.com/docs/DOC-8592-layer-toggle-button-widget-version-22-01132017&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2018 21:50:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773678#M1859</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-04-24T21:50:34Z</dc:date>
    </item>
    <item>
      <title>Re: off panel widget icon</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773679#M1860</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Robert,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Doh! Why didn't I think of using the onOpen() method?! The code you have looks perfect for what I want to do, thanks for your help. I assume you're setting the widget's closeable property true in the app config.js, so that the icon is displayed?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Miles.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2018 22:22:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773679#M1860</guid>
      <dc:creator>mileshitchen1</dc:creator>
      <dc:date>2018-04-24T22:22:30Z</dc:date>
    </item>
    <item>
      <title>Re: off panel widget icon</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773680#M1861</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Robert,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm having difficulty using your approach. Basically I have an off panel widget with no UI and closeable property true. My code is listening to the onOpen event of the widget and in there I set the maps zoom level and then close the widget. This all works, but on the first click of the widget icon, the onOpen event is fired 3 times, and then leaves the widget and icon in an open state. Any idea what's going on and how to fix this? It seems like it should be a simple task, but I've been banging my head against the desk for hours now!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks, Miles.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's my Widget code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;define([&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'dojo/_base/declare'&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'dojo/on'&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'dijit/_WidgetsInTemplateMixin'&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'jimu/BaseWidget'&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'jimu/WidgetManager'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp; ],&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt; (declare, on, _WidgetsInTemplateMixin, BaseWidget, WidgetManager) {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt; clazz = declare([BaseWidget, _WidgetsInTemplateMixin], {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; baseClass: &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: #a31515; background: white;"&gt;'jimu-widget-about'&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green; background: white;"&gt;// clasName: 'esri.widgets.About',&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; onOpen: &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt; () {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt; (&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;this&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;.map.getLevel() !== 13) {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;this&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;.map.setLevel(13);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WidgetManager.getInstance().closeWidget(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;this&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; });&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue; background: white;"&gt;return&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt; clazz;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: black; background: white;"&gt;&amp;nbsp; });&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2018 02:21:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773680#M1861</guid>
      <dc:creator>mileshitchen1</dc:creator>
      <dc:date>2018-04-25T02:21:56Z</dc:date>
    </item>
    <item>
      <title>Re: off panel widget icon</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773681#M1862</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P class=""&gt;Miles,&lt;/P&gt;&lt;P class=""&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp; I dealt with all those issues in my widget code.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2018 02:43:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/off-panel-widget-icon/m-p/773681#M1862</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2018-04-25T02:43:13Z</dc:date>
    </item>
  </channel>
</rss>

