Skip to content

Commit

Permalink
[ADD] x to Social Element list
Browse files Browse the repository at this point in the history
  • Loading branch information
npracht authored Jan 29, 2024
1 parent af19dde commit 0236503
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/mjml-social/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,12 @@ Displays calls-to-action for various social networks with their associated logo.
<mj-social-element name="google" href="https://mjml.io/">
Google
</mj-social-element>
<mj-social-element name="twitter" href="https://mjml.io/">
<mj-social-element name="twitter" href="https://mjml.io/">
Twitter
</mj-social-element>
<mj-social-element name="x" href="https://mjml.io/">
X
</mj-social-element>
</mj-social>
</mj-column>
</mj-section>
Expand Down Expand Up @@ -106,6 +109,7 @@ vertical-align | string | top/middle/bottom | midd
Supported networks with a share url:
- facebook
- twitter
- x
- google
- pinterest
- linkedin
Expand Down
5 changes: 5 additions & 0 deletions packages/mjml-social/src/SocialElement.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ const defaultSocialNetworks = {
'background-color': '#55acee',
src: `${IMG_BASE_URL}twitter.png`,
},
x: {
'share-url': 'https://twitter.com/intent/tweet?url=[[URL]]',
'background-color': '#000000',
src: `${IMG_BASE_URL}twitter-x.png`,
},
google: {
'share-url': 'https://plus.google.com/share?url=[[URL]]',
'background-color': '#dc4e41',
Expand Down

0 comments on commit 0236503

Please sign in to comment.