OfficeDev / office-js

A repo and NPM package for Office.js, corresponding to a copy of what gets published to the official "evergreen" Office.js CDN, at https://appsforoffice.microsoft.com/lib/1/hosted/office.js.
https://learn.microsoft.com/javascript/api/overview
Other
670 stars 96 forks source link

Office.context.ui.messageParent is undefined on Safari 16.2 #3773

Open st1992 opened 11 months ago

st1992 commented 11 months ago

Found that Office.context is an empty object on Safari 16.2, even though we are using it after Office.onReady(). Due to this behaviour, from Dialog, when we send an auth token to taskpane using Office.context.ui.messageParent, it is undefined Also, (might be related) In the dialog box opened by using Office.context.ui.displayDialogAsync, We are getting this warning Warning: Office.js is loaded outside of Office client you can see this in the screenshot below as well.

Environment

Steps to Reproduce (On Safari 16.2)

  1. Load your add in ,
  2. Open dialog using Office.context.ui.displayDialogAsync from taskpane
  3. try sending a message using Office.context.ui.messageParent to taskpane.
iliapir2 commented 11 months ago

I have the same issue

iliapir2 commented 11 months ago

Want to add a bit of context about this issue. I found that when I call Office.context.ui.displayDialogAsync in Safari and try to open completely empty pop-up window it works.

Once I added Githubissues.

  • Githubissues is a development platform for aggregating issues.