Off-Panel Widget is displaying an icon in Web AppBuilder

2742
4
Jump to solution
02-26-2016 03:28 PM
MarkNorbury2
New Contributor III

I've developed a 'hover' widget that does not need to appear in the panel.  That is, it's an off-panel widget that should be active at all times and should not have an icon in the panel.  I'm using the foldable theme in WAB.  However, an icon is appearing in the panel.  How do I remove this?Icon.PNG

Here's my widget's manifest.json.

{

  "name": "Hover",

  "2D": true,

  "3D": false,

  "platform": "HTML",

  "version": "1.4",

  "wabVersion": "1.4",

  "author": "Esri Canada Ltd",

  "description": "This is the hover widget",

  "copyright": "",

  "license": "http://www.apache.org/licenses/LICENSE-2.0",

  "properties": {

  "inPanel":false,

  "hasLocale": false,

  "hasStyle":true,

  "hasConfig":true,

  "hasUIFile":false,

  "hasSettingPage":true,

  "hasSettingUIFile":true,

  "hasSettingLocale":true,

  "hasSettingStyle":true,

  "IsController":false,

  "closeable": false,

  "openAtStart": true

  }

}

1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

Mark,

  No I am talking about WAB Dev. Your workflow is different than most developers though.

https://community.esri.com/message/576497#comment-576497

With your workflow you would have to add your non-inPanel widget to the apps main config.json in the widgetsOnScreen section:

"widgetOnScreen": {
    "widgets": [
      {
        "uri": "widgets/MyCustomWidget/Widget",
        "id": "widgets_MyCustomWidget_Widget_1",
        "name": "MyCustomWidget",
        "label": "My Custom Widget",
        "position": {
          "relativeTo": "map"
        },
        "config": "configs/MyCustomWidget/config_My Custom Widget.json"
      },

View solution in original post

4 Replies
RobertScheitlin__GISP
MVP Emeritus

Mark,

   All the inPanel false widgets I have created, I have had to add to the C:\web-appbuilder-1.3\client\stemapp\predefined-apps\default\config.json manually for them to appear in the middle widget section of the widget tab

sample.jpg

MarkNorbury2
New Contributor III

Hi Robert

Thanks for your response.  Are you talking about the edition of WAB that runs in ArcGIS Online?

I'm actually using the developer edition after having downloaded the WAB application to my web server and building a custom widget for it there.  I should probably have explained that in my post.

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

Mark,

  No I am talking about WAB Dev. Your workflow is different than most developers though.

https://community.esri.com/message/576497#comment-576497

With your workflow you would have to add your non-inPanel widget to the apps main config.json in the widgetsOnScreen section:

"widgetOnScreen": {
    "widgets": [
      {
        "uri": "widgets/MyCustomWidget/Widget",
        "id": "widgets_MyCustomWidget_Widget_1",
        "name": "MyCustomWidget",
        "label": "My Custom Widget",
        "position": {
          "relativeTo": "map"
        },
        "config": "configs/MyCustomWidget/config_My Custom Widget.json"
      },
MarkNorbury2
New Contributor III

Thanks for your help.

I've edited the application's config.json and simply moved the definition of my widget there from the widgetPool section to the widgetOnScreen section and it no longer appears in the panel.

0 Kudos