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
689 stars 95 forks source link

SetSignature gets styles overwritten when a normalemail.dotm file is present in Outlook Desktop (classic) #4929

Open bogdanst24 opened 1 month ago

bogdanst24 commented 1 month ago

Your Environment

Expected behavior

The result is consistent regardless of the Platform when using the setSignature API with any HTML.

Current behavior

When having a template set for new documents (emails) in Outlook in the form of a custom normalemail.dotm file, then the signature inserted will inherit the document's styles. It is not the same when:

As this makes web add-ins inconsistent across different platforms and does not provide the expected results in the classic Outlook for Windows, this should be fixed. This is preventing customers from migrating from VSTO-based add-ins to Web add-ins.

Steps to reproduce

  1. Set up a custom template applied to new documents (update normalemail.dotm file). Can be easily tested with line spacing set to e.g. 40pt.
  2. Use Script Lab for Outlook
  3. Insert a signature using the "Work with client signatures (compose)" sample. The signature will inherit the styles. If custom styles are provided using HTML, then those will be overwritten when inserted.
bogdanst24 commented 1 month ago

Hi @pinverso, any reason why the tags were removed?

pinverso commented 1 month ago

Hello @bogdanst24 , I added back the Needs: attention. It was inadvertently removed.

ztcdsb commented 1 month ago

@bogdanst24 Thanks for reporting this issue regarding signature. It has been put on our backlog. We unfortunately have no timelines to share at this point

Internal tracking id: Office: 9445392