mjml-social
Advanced tools
Comparing version 4.4.1 to 4.5.0
@@ -207,2 +207,4 @@ 'use strict'; | ||
var hasLink = !!this.getAttribute('href'); | ||
return '\n <tr\n ' + this.htmlAttributes({ | ||
@@ -216,7 +218,7 @@ class: this.getAttribute('css-class') | ||
style: 'table' | ||
}) + '\n >\n <tr>\n <td ' + this.htmlAttributes({ style: 'icon' }) + '>\n <a ' + this.htmlAttributes({ | ||
}) + '\n >\n <tr>\n <td ' + this.htmlAttributes({ style: 'icon' }) + '>\n ' + (hasLink ? '<a ' + this.htmlAttributes({ | ||
href: href, | ||
rel: this.getAttribute('rel'), | ||
target: this.getAttribute('target') | ||
}) + '>\n <img\n ' + this.htmlAttributes({ | ||
}) + '>' : '') + '\n <img\n ' + this.htmlAttributes({ | ||
alt: this.getAttribute('alt'), | ||
@@ -228,3 +230,3 @@ title: this.getAttribute('title'), | ||
width: parseInt(iconSize, 10) | ||
}) + '\n />\n </a>\n </td>\n </tr>\n </table>\n </td>\n ' + (this.getContent() ? '\n <td ' + this.htmlAttributes({ style: 'tdText' }) + '>\n <a\n ' + this.htmlAttributes({ | ||
}) + '\n />\n ' + (hasLink ? '</a>' : '') + '\n </td>\n </tr>\n </table>\n </td>\n ' + (this.getContent() ? '\n <td ' + this.htmlAttributes({ style: 'tdText' }) + '>\n ' + (hasLink ? '<a\n ' + this.htmlAttributes({ | ||
href: href, | ||
@@ -234,3 +236,5 @@ style: 'text', | ||
target: this.getAttribute('target') | ||
}) + '>\n ' + this.getContent() + '\n </a>\n </td>\n ' : '') + '\n </tr>\n '; | ||
}) + '>' : '<span\n ' + this.htmlAttributes({ | ||
style: 'text' | ||
}) + '>') + '\n ' + this.getContent() + '\n ' + (hasLink ? '</a>' : '</span>') + '\n </td>\n ' : '') + '\n </tr>\n '; | ||
} | ||
@@ -275,6 +279,5 @@ }]); | ||
target: '_blank', | ||
'text-decoration': 'none', | ||
href: '[[SHORT_PERMALINK]]' | ||
'text-decoration': 'none' | ||
}, _temp); | ||
exports.default = MjSocialElement; | ||
module.exports = exports['default']; |
{ | ||
"name": "mjml-social", | ||
"description": "mjml-social", | ||
"version": "4.4.1", | ||
"version": "4.5.0", | ||
"main": "lib/index.js", | ||
@@ -21,4 +21,4 @@ "repository": { | ||
"babel-runtime": "^6.26.0", | ||
"lodash": "^4.17.2", | ||
"mjml-core": "4.4.1" | ||
"lodash": "^4.17.15", | ||
"mjml-core": "4.5.0" | ||
}, | ||
@@ -25,0 +25,0 @@ "devDependencies": { |
@@ -81,3 +81,3 @@ ## mjml-social | ||
font-weight | string | font weight | normal | ||
href | url | button redirection url | [[SHORT_PERMALINK]] | ||
href | url | button redirection url | none | ||
icon-height | percent/px | icon height, overrides icon-size | icon-size | ||
@@ -88,3 +88,3 @@ icon-size | percent/px | icon size (width and height) | 20px | ||
name | string | social network name, see supported list below | N/A | ||
padding | px | supports up to 4 parameters | 10px 25px | ||
padding | px | supports up to 4 parameters | 4px | ||
padding-bottom | px | bottom offset | n/a | ||
@@ -136,1 +136,3 @@ padding-left | px | left offset | n/a | ||
``` | ||
You can also use mj-social this way with no `href` attribute to make a simple list of inlined images-texts. |
22845
389
136
+ Addedmjml-core@4.5.0(transitive)
+ Addedmjml-migrate@4.5.0(transitive)
+ Addedmjml-parser-xml@4.5.0(transitive)
+ Addedmjml-validator@4.5.0(transitive)
- Removedmjml-core@4.4.1(transitive)
- Removedmjml-migrate@4.4.1(transitive)
- Removedmjml-parser-xml@4.4.1(transitive)
- Removedmjml-validator@4.4.0(transitive)
Updatedlodash@^4.17.15
Updatedmjml-core@4.5.0