@digigov/css 0.8.1 → 0.8.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/CHANGELOG.json +12 -0
- package/CHANGELOG.md +8 -1
- package/color-vars.plugin.js +20 -0
- package/dist/base/index.css +2 -2
- package/dist/base.css +2 -2
- package/dist/digigov.css +2 -2
- package/package.json +2 -1
package/CHANGELOG.json
CHANGED
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@digigov/css",
|
|
3
3
|
"entries": [
|
|
4
|
+
{
|
|
5
|
+
"version": "0.8.2",
|
|
6
|
+
"tag": "@digigov/css_v0.8.2",
|
|
7
|
+
"date": "Mon, 14 Feb 2022 11:53:09 GMT",
|
|
8
|
+
"comments": {
|
|
9
|
+
"patch": [
|
|
10
|
+
{
|
|
11
|
+
"comment": "Include missing file color-vars.plugin.js"
|
|
12
|
+
}
|
|
13
|
+
]
|
|
14
|
+
}
|
|
15
|
+
},
|
|
4
16
|
{
|
|
5
17
|
"version": "0.8.1",
|
|
6
18
|
"tag": "@digigov/css_v0.8.1",
|
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
# Change Log - @digigov/css
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Mon, 14 Feb 2022 11:53:09 GMT and should not be manually modified.
|
|
4
|
+
|
|
5
|
+
## 0.8.2
|
|
6
|
+
Mon, 14 Feb 2022 11:53:09 GMT
|
|
7
|
+
|
|
8
|
+
### Patches
|
|
9
|
+
|
|
10
|
+
- Include missing file color-vars.plugin.js
|
|
4
11
|
|
|
5
12
|
## 0.8.1
|
|
6
13
|
Thu, 10 Feb 2022 13:45:56 GMT
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
|
|
2
|
+
function addColorVars ({ addBase, theme }) {
|
|
3
|
+
function extractColorVars(colorObj, colorGroup = '') {
|
|
4
|
+
return Object.keys(colorObj).reduce((vars, colorKey) => {
|
|
5
|
+
const value = colorObj[colorKey];
|
|
6
|
+
|
|
7
|
+
const newVars =
|
|
8
|
+
typeof value === 'string'
|
|
9
|
+
? { [`--color${colorGroup}-${colorKey}`]: value }
|
|
10
|
+
: extractColorVars(value, `-${colorKey}`);
|
|
11
|
+
|
|
12
|
+
return { ...vars, ...newVars };
|
|
13
|
+
}, {});
|
|
14
|
+
}
|
|
15
|
+
addBase({
|
|
16
|
+
':root': extractColorVars(theme('colors')),
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
module.exports = addColorVars;
|
package/dist/base/index.css
CHANGED
package/dist/base.css
CHANGED
package/dist/digigov.css
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@digigov/css",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.2",
|
|
4
4
|
"description": "Digigov CSS - Tailwind CSS Components",
|
|
5
5
|
"author": "GRNET Devs",
|
|
6
6
|
"license": "MIT",
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
"index.js",
|
|
27
27
|
"src",
|
|
28
28
|
"colors",
|
|
29
|
+
"color-vars.plugin.js",
|
|
29
30
|
"postcss.config.js",
|
|
30
31
|
"tailwind.config.js"
|
|
31
32
|
],
|