Outlook for Mac add-in with the newly released office.js API

泄露秘密 提交于 2021-02-07 11:05:59

问题


We have an add-in for Office Apps - using the compose form on Outlook appointments in the calendar.

Because finally the office.js add-ins support for Outlook for Mac is out as written here, I have some questions:

  • How can I debug the JS in the add-in side pane in Outlook for Mac? Since the behavior is sometimes different to Outlook Web
  • Office.context.mailbox.item.body.setAsync(newBody, { coercionType: Office.CoercionType.Html }, callback) seems to do nothing, only for Office.CoercionType.Text it seems to work
  • Is it possible to open a web page in the browser instead of a modal window? Because window.open(url, target, features) opens a modal window on top of the appointment, which is again different behavior to Outlook Web Client
  • It looks like JS is much slower in Outlook for Mac

回答1:


Question #1 MacOutlook uses webkit to render addin page. You can run the following command from CLI

defaults write NSGlobalDomain WebKitDeveloperExtras -bool true

Restart the outlook and invoke the Add-in. You will see new menu item inspect Element which will let you inspect the elements in the page.

Question #3: If the URL to be opened in a domain that is not listed in appmanifest, the URL will be opened in a separate browser window. The url to be opened is in the domain listed in appmainfest, you will see a popup window. MacOutlook uses modal window due to the limitations of webkit library currently being used.

Question #2 : Can you give specific steps to reproduce the problem and share the Outlook version that you are using - We do not see this problem

Senthil @ Microsoft



来源:https://stackoverflow.com/questions/41109115/outlook-for-mac-add-in-with-the-newly-released-office-js-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!