OfficeDev / microsoft-teams-library-js

JavaScript library for use by Microsoft Teams apps
https://docs.microsoft.com/microsoftteams/platform/
Other
426 stars 193 forks source link

Load another app with a Task Module in tab #1301

Closed msmichaelwoo closed 2 years ago

msmichaelwoo commented 2 years ago

Hello,

I am trying to load another app inside of a different app's tab using a Task Module. I have a button that calls the startTask function with a TaskInfo object that has the url pointing to our other apps url.

I was wondering in this case, would the manifest used be based on the tab app or the url app? Also when I do this call the Task Module renders but with no App Icon or App's Short Name. Is there a way to specify this?

ghost commented 2 years ago

Hi msmichaelwoo! Thank you for bringing this issue to our attention. We will investigate and if we require further information we will reach out in one business day. Please use this link to escalate if you don't get replies.

Best regards, Teams Platform

AE-MS commented 2 years ago

Hi @msmichaelwoo! Unfortunately, you cannot load a different TeamsJS app inside of a task module/dialog. When loading an app within a dialog, the loading information and context will be based on the manifest of the app that triggered the dialog.

Can you tell us more about the scenario you are trying to enable to see if we could help provide an alternative or consideration for future support?

msmichaelwoo commented 2 years ago

Hi, we have a messaging extension app that we were hoping to integrate into other apps. We were thinking that other apps could integrate easily by using Task Modules and pointing the iframe url to our apps url. Experimenting with this we've found that it seems to work but does not display the app icon and app name in the task module, only the title and iframe.

embailie commented 2 years ago

Hey @msmichaelwoo - jumping in for my colleague AE here, with a few more questions.

What is the desired view for the task module? You mentioned having a messaging extension app - are you hoping that the task module will show the search/selection menu from message extensions?

This scenario is not supported in Task Modules, so I'm not surprised you're not seeing the app name / logo. Once we know more about the desired Task Module contents, we can provide more guidance on how you might achieve that.

msmichaelwoo commented 2 years ago

Hello,

My desired view is for a third party app to launch our app in a Task Module the same way it gets launched when you select the app from the message extensions menu.

embailie commented 2 years ago

@msmichaelwoo thanks for clarifying. Unfortunately, that scenario is not supported. It would be a poor UX for a user to click one app's icon, and then see content from another app - not to mention considerations of data storage or privacy between the two apps. If you are in content with the developer of the third-party app, you could ask them to make an enhancement to support your app in the Message Extension context.

embailie commented 2 years ago

The OP and I have discussed, and deeplinking will be used to support their scenario. Closing out this ticket.

msmichaelwoo commented 2 years ago

Was able to use Deeplinks instead of tasks.startTask method

https://docs.microsoft.com/en-us/javascript/api/@microsoft/teams-js/?view=msteams-client-js-latest#@microsoft-teams-js-executedeeplink

ghost commented 2 years ago

Tell us about your experience!

Hi msmichaelwoo! This issue is closed in our system. We would like your feedback on your experience with our support team and Platform.

Best regards, Teams Platform