feat: add support for hosted PNG social icons to improve compatibility with Outlook#81
Merged
Merged
Conversation
Deploying templatical-playground with
|
| Latest commit: |
b7ebacd
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://3c98cb11.templatical-playground.pages.dev |
| Branch Preview URL: | https://use-png-for-social-icons.templatical-playground.pages.dev |
Deploying templatical-docs with
|
| Latest commit: |
b7ebacd
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://090dfb1a.templatical-docs.pages.dev |
| Branch Preview URL: | https://use-png-for-social-icons.templatical-docs.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In this PR:
<img src=".../{style}/{platform}.png">instead of inline SVG data URIs. Outlook desktop (Word engine) doesn't support SVG and rejects base64 in<img src>— emails were broken there.RenderOptions.socialIconsBaseUrl(defaults to version-pinned unpkg URL of this package). 80 PNGs (16 platforms × 5 styles, 192×192) ship with the npm tarball; rasterized at build via@resvg/resvg-jswithrenderAsyncparallelism (~7s for all 80, assets gitignored).SOCIAL_ICONS,generateSocialIconDataUri. AddsDEFAULT_SOCIAL_ICONS_BASE_URL.Related to #80.