mjml icon indicating copy to clipboard operation
mjml copied to clipboard

<!--[if !mso]><!-->...<!--<![endif]--> tag issue after exported

Open nguyentuansi opened this issue 6 years ago • 7 comments

Describe the bug Hi team, I'm facing an issue when export HTML. This function was worked perfectly but it just happened these days.

To Reproduce More details below:

I'm using below code for styling a superscript:

<!--[if !mso]><!-->
          <sup style="font-family: Arial, sans-serif;font-size: 9px;">#</sup>
<!--<![endif]-->
<!--[if mso | IE]>
          <sup style="font-family: Arial, sans-serif;font-size: 9px; line-height: 16px">#</sup>
<![endif]-->

When I exported to HTML it became:

<!--[if !mso]><!-->
          <sup style="font-family: Arial, sans-serif;font-size: 9px;">#</sup>
<!--<sup style="font-family: Arial, sans-serif;font-size: 9px; line-height: 16px">#</sup>
<![endif]-->

MJML environment (please complete the following information):

  • OS: Windows
  • MJML Version 4.2.0
  • MJML tool used : VS Code

Email sending environment(for rendering issues):

  • Platform used to send the email Putsmail

Affected email clients (for rendering issues):

  • OS: Windows Outlook from 2007

Screenshots From: 2019-10-04_15h23_19 To: 2019-10-04_15h21_44

nguyentuansi avatar Oct 04 '19 08:10 nguyentuansi

I think the conditionnal comment are merged, together because of permissive regexp,

https://github.com/mjmlio/mjml/blob/master/packages/mjml-core/src/helpers/mergeOutlookConditionnals.js

Try to add a random html comment in between those for now

iRyusa avatar Oct 23 '19 14:10 iRyusa