easy-email-pro-theme 1.44.1 → 1.44.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +9 -1
- package/package.json +1 -1
package/lib/index.js
CHANGED
|
@@ -15343,7 +15343,7 @@ const mjmlToJson = (content) => {
|
|
|
15343
15343
|
};
|
|
15344
15344
|
function mjmlTransform(data) {
|
|
15345
15345
|
const transform = (item2) => {
|
|
15346
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
15346
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
15347
15347
|
const attributes = item2.attributes;
|
|
15348
15348
|
switch (item2.tagName) {
|
|
15349
15349
|
case "mjml":
|
|
@@ -15403,6 +15403,14 @@ function mjmlTransform(data) {
|
|
|
15403
15403
|
if (!block) {
|
|
15404
15404
|
throw new Error(`${tag} block no found `);
|
|
15405
15405
|
}
|
|
15406
|
+
if (tag === "social") {
|
|
15407
|
+
const childrenNoPadding = (_j = item2.children) == null ? void 0 : _j.every(
|
|
15408
|
+
(item22) => item22.tagName === "mj-social-element" && !get(item22, "attributes.padding") && !get(item22, "attributes.padding-left") && !get(item22, "attributes.padding-right") && !get(item22, "attributes.padding-top") && !get(item22, "attributes.padding-bottom")
|
|
15409
|
+
);
|
|
15410
|
+
if (childrenNoPadding) {
|
|
15411
|
+
attributes.spacing = "8px";
|
|
15412
|
+
}
|
|
15413
|
+
}
|
|
15406
15414
|
const payload = {
|
|
15407
15415
|
type: block.type,
|
|
15408
15416
|
attributes,
|