0

Is there anyway to override the global side content panel inside a conversation, so that we have one icon that will work globally and inside each thread at the same time?
Add global side bar content panel globally:

sdk.Global.addSidebarContentPanel({
title: 'Test sidebar',
iconUrl: 'logo.png',
el: el
});


Add side bar content panel inside each thread:

threadView.addSidebarContentPanel({
title: 'Test sidebar',
iconUrl: 'logo.png',
el: el
});

Any suggestions?

Mahmoud Abd AL Kareem
  • 615
  • 2
  • 10
  • 23

2 Answers2

0

A global sidebar is already accessible within each thread as well as globally. In case you want them to be two seperate sidebars, your posted code should work. Since you are using the same el in both sidebars, I assume you just want one global sidebar.

0

So I'm trying to do this as well, and while I don't think it fully answers your question I thought it might be helpful to point out that this blog post indicates that Gmail add ons and extensions with inboxSDK play nice together (scroll to question titled " I want an add-on and an extension, but I don’t want both to show up on desktop, can you do that?".)

The add on can be open globally and in the thread view, so I'm thinking that might be helpful to you:

... The Load Options object in the inboxSDK.load command now has a third parameter which is: suppressAddonTitle. When creating your Gmail Add-On you will give it a name. This name shows up as a tooltip and as the header of your add-on’s sidebar. If you want your extension to suppress the add-on when both are installed on a user’s account/browser then set the value of this property to the name of the add-on.

InboxSDK.load(2, 'YOUR_APP_ID_HERE', {suppressAddonTitle: 'YOUR_ADD_ON_TITLE_HERE'}).then(function(sdk){
      //more code
});

What this doesn't really answer is how you target the same icon in the sidebar. I would love to hear if you've found a better way of doing this!