@newlogic-digital/core 0.7.2 → 0.8.0
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/index.js +18 -1
- package/modules/Serve.js +3 -0
- package/modules/Styles.js +1 -1
- package/modules/Templates.js +1 -1
- package/package.json +12 -12
package/index.js
CHANGED
@@ -17,8 +17,25 @@ import {
|
|
17
17
|
|
18
18
|
const defineConfig = (config) => new Core().init(config);
|
19
19
|
|
20
|
+
const tailwindColors = (colors = []) => {
|
21
|
+
colors.forEach(name => {
|
22
|
+
colors[name] = ({opacityVariable, opacityValue}) => {
|
23
|
+
if (opacityValue !== undefined) {
|
24
|
+
return `rgba(var(--color-${name}), ${opacityValue})`
|
25
|
+
}
|
26
|
+
if (opacityVariable !== undefined) {
|
27
|
+
return `rgba(var(--color-${name}), var(${opacityVariable}, 1))`
|
28
|
+
}
|
29
|
+
return `rgb(var(--color-${name}))`
|
30
|
+
}
|
31
|
+
})
|
32
|
+
|
33
|
+
return colors
|
34
|
+
}
|
35
|
+
|
20
36
|
export {
|
21
37
|
defineConfig,
|
38
|
+
tailwindColors,
|
22
39
|
Core,
|
23
40
|
Utils,
|
24
41
|
Styles,
|
@@ -33,4 +50,4 @@ export {
|
|
33
50
|
Package,
|
34
51
|
Config,
|
35
52
|
root
|
36
|
-
}
|
53
|
+
}
|
package/modules/Serve.js
CHANGED
package/modules/Styles.js
CHANGED
@@ -184,7 +184,7 @@ export class Styles {
|
|
184
184
|
|
185
185
|
const clean = lazypipe().pipe(cleanCSS, lodash.merge({
|
186
186
|
inline: Config.styles.import,
|
187
|
-
level: {1: {specialComments: 0}, 2: {removeEmpty:
|
187
|
+
level: {1: {specialComments: 0}, 2: {removeEmpty: true}}
|
188
188
|
}, Config.styles.clean), (details) => {
|
189
189
|
if (details.warnings.length > 0) {
|
190
190
|
details.warnings.map(warning => console.log("\x1b[32m", warning, "\x1b[0m"))
|
package/modules/Templates.js
CHANGED
@@ -419,7 +419,7 @@ export class Templates {
|
|
419
419
|
.pipe(buildLayoutClear())
|
420
420
|
.pipe(buildLayoutTwig())
|
421
421
|
.pipe(buildLayoutHbs())
|
422
|
-
.pipe(
|
422
|
+
.pipe(renameHtml())
|
423
423
|
.pipe(gulp.dest(root + Config.paths.output.root))
|
424
424
|
.on("end", resolve))
|
425
425
|
])
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@newlogic-digital/core",
|
3
3
|
"type": "module",
|
4
|
-
"version": "0.
|
4
|
+
"version": "0.8.0",
|
5
5
|
"main": "index.js",
|
6
6
|
"author": "New Logic Studio s.r.o.",
|
7
7
|
"description": "Set of tools that can be used to create modern web applications",
|
@@ -12,12 +12,12 @@
|
|
12
12
|
"docs:serve": "vitepress serve docs"
|
13
13
|
},
|
14
14
|
"dependencies": {
|
15
|
-
"@babel/core": "^7.
|
16
|
-
"@babel/preset-env": "^7.
|
15
|
+
"@babel/core": "^7.16.7",
|
16
|
+
"@babel/preset-env": "^7.16.7",
|
17
17
|
"@rollup/plugin-babel": "^5.3.0",
|
18
18
|
"@rollup/plugin-commonjs": "^21.0.1",
|
19
|
-
"@rollup/plugin-node-resolve": "^13.
|
20
|
-
"@rollup/plugin-replace": "^3.0.
|
19
|
+
"@rollup/plugin-node-resolve": "^13.1.3",
|
20
|
+
"@rollup/plugin-replace": "^3.0.1",
|
21
21
|
"adm-zip": "^0.5.9",
|
22
22
|
"clean-css": "^5.2.2",
|
23
23
|
"fs-extra": "^10.0.0",
|
@@ -31,7 +31,7 @@
|
|
31
31
|
"gulp-inline-css": "^4.0.0",
|
32
32
|
"gulp-plumber": "^1.2.1",
|
33
33
|
"gulp-postcss": "^9.0.1",
|
34
|
-
"gulp-purgecss": "^4.
|
34
|
+
"gulp-purgecss": "^4.1.3",
|
35
35
|
"gulp-rename": "^2.0.0",
|
36
36
|
"gulp-replace": "^1.1.3",
|
37
37
|
"gulp-rev": "^9.0.0",
|
@@ -39,18 +39,18 @@
|
|
39
39
|
"lazypipe": "^1.0.2",
|
40
40
|
"lodash": "^4.17.21",
|
41
41
|
"postcss-custom-media": "^8.0.0",
|
42
|
-
"postcss-custom-properties": "^12.0.
|
42
|
+
"postcss-custom-properties": "^12.0.4",
|
43
43
|
"postcss-custom-selectors": "^6.0.0",
|
44
44
|
"postcss-import": "^14.0.2",
|
45
|
-
"postcss-nesting": "^
|
46
|
-
"rollup": "^2.
|
45
|
+
"postcss-nesting": "^8.0.1",
|
46
|
+
"rollup": "^2.63.0",
|
47
47
|
"rollup-plugin-import-map": "^2.2.2",
|
48
48
|
"rollup-plugin-terser": "^7.0.2",
|
49
|
-
"vite": "~2.
|
49
|
+
"vite": "~2.7.10"
|
50
50
|
},
|
51
51
|
"peerDependencies": {
|
52
|
-
"autoprefixer": "^10.4.
|
53
|
-
"postcss": "^8.
|
52
|
+
"autoprefixer": "^10.4.2",
|
53
|
+
"postcss": "^8.4.5",
|
54
54
|
"tailwindcss": "^2.2.19"
|
55
55
|
},
|
56
56
|
"devDependencies": {
|