-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat/improve css compatibility #61
Conversation
Should improve compatibility on many email clients.
Codecov Report
@@ Coverage Diff @@
## master #61 +/- ##
==========================================
- Coverage 98.45% 97.59% -0.86%
==========================================
Files 3 3
Lines 907 957 +50
==========================================
+ Hits 893 934 +41
- Misses 8 16 +8
- Partials 6 7 +1
Continue to review full report at Codecov.
|
Great news! Thank you very much 🚀 |
Thank you very much. I just tested on Windows Server 2016 with Outlook 2016, and email is displaying correctly, except the button, as you said, "does not adapt to content, but it does the work." |
@dmuriel I will try this evening to adapt the button width from the length of the text (unless it reaches a maximum width). It should be technically doable, but we will see if it's not such a good idea. |
@matcornic you can also check this workaround I made for Outlook only, maybe you can use something for the button. It may not be pretty but it worked for me while waiting for a solution. |
Asking someone else at @lbryio to look at this. Thank you! |
LGTM, thank you again for looking into and fixing this! |
@dmuriel The button width in default theme is now adapting to text content since 027481f I checked with multiple text sizes and it seems to react nicely. I implemented the same behaviour with both classic/Outlook sections for compatibility purpose. Let me know what you think about it :) (last commit before merge 🚀) |
@matcornic I agree with leaving only with the width attribute. Regarding the button width it seems that now is cropping the text. |
@dmuriel weird, I used the trial of Litmus, and the button looks good on Outlook 2016. I will merge as is. |
theme flat and default has the same problem ,can not show button |
I find a workaround. success show button
h := hermes.Hermes{
// Optional Theme
// Theme: new(Default)
Theme: new(hermes.Flat),
DisableCSSInlining: true, |
Great news, a friend of mine has lent me a Windows with a licensed Outlook. So I can fix the Outlook compatibility issue.
So this PR contains code for:
=> Replaces PR #48
Hey @kauffj @loeffel-io @vjeantet @dmuriel @elliots 🙌
Can you test this PR on your side ?
It worked for me on a Windows 10 with latest version of Outlook. I think it's still perfectible, but it does the work.
Edit: the size of the button now adapts to content in default theme.