sendgrid / email-templates

A repository of common email templates to use and modify to your heart's content.
https://sendgrid.com
MIT License
818 stars 987 forks source link

Receipt Rendering on Outlook for iOS #81

Open justinobney opened 5 years ago

justinobney commented 5 years ago

Actual Behaviour

Outlook for iOS is causing my receipt table to stagger.

image

Expected Behaviour

image

Steps to reproduce it

Open the example template in Outlook for iOS

Notes

This only happens when the line item content is wrapped in a div. Moving the center style to the td and removing the div fixes this issue and appears to still render correctly according to Litmus.

https://github.com/sendgrid/email-templates/blob/master/dynamic-templates/receipt/receipt.html#L183

It appears that Outlook for iOS runs javascript (outlook-ios.js) that tries to find "out of bound elements" and scale them with explicit widths.