@newlogic-digital/core 0.9.6 → 0.9.7
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/modules/Emails.js +2 -2
- package/modules/Utils.js +15 -0
- package/package.json +1 -1
package/modules/Emails.js
CHANGED
@@ -20,7 +20,7 @@ export class Emails {
|
|
20
20
|
removeStyleTags: Config.emails.inlineOnly
|
21
21
|
}
|
22
22
|
|
23
|
-
const buildCss = lazypipe().pipe(() => gulpif("*.css", postcss(new Utils().
|
23
|
+
const buildCss = lazypipe().pipe(() => gulpif("*.css", postcss(new Utils().postcssPluginsEmails(Config.emails.postcss, [postcssCustomProperties({
|
24
24
|
preserve: false
|
25
25
|
}), autoprefixer])))
|
26
26
|
).pipe(() => gulpif("*.less", Modules.less.module()))
|
@@ -107,4 +107,4 @@ export class Emails {
|
|
107
107
|
resolve();
|
108
108
|
})
|
109
109
|
}
|
110
|
-
}
|
110
|
+
}
|
package/modules/Utils.js
CHANGED
@@ -279,6 +279,21 @@ export class Utils {
|
|
279
279
|
return config;
|
280
280
|
}
|
281
281
|
|
282
|
+
return plugins.concat(after);
|
283
|
+
}
|
284
|
+
postcssPluginsEmails(config, after) {
|
285
|
+
let plugins = [postcssImport, postcssNesting({
|
286
|
+
noIsPseudoSelector: true
|
287
|
+
}), postcssCustomMedia, postcssCustomSelectors];
|
288
|
+
|
289
|
+
if (Exists.postcssConfig) {
|
290
|
+
return {config: root}
|
291
|
+
} else if (typeof config.extend !== "undefined") {
|
292
|
+
plugins = plugins.concat(config.extend)
|
293
|
+
} else if (Array.isArray(config) && config.length !== 0) {
|
294
|
+
return config;
|
295
|
+
}
|
296
|
+
|
282
297
|
return plugins.concat(after);
|
283
298
|
}
|
284
299
|
}
|
package/package.json
CHANGED