@plumeria/core 2.2.3 → 2.2.4
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/dist/index.js +18 -12
- package/dist/index.mjs +18 -12
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -49,20 +49,26 @@ function create(rule) {
|
|
|
49
49
|
if (atRule.startsWith("@media") || atRule.startsWith("@container")) nonFlatQuery[atRule] = nestedObj;
|
|
50
50
|
else nonFlatBase[atRule] = nestedObj;
|
|
51
51
|
});
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
const nonFlatObj = { [key]: targetNonFlat };
|
|
52
|
+
Object.entries(nonFlatBase).forEach(([selector, style]) => {
|
|
53
|
+
const nonFlatObj = { [key]: { [selector]: style } };
|
|
55
54
|
const nonFlatHash = (0, zss_engine.genBase36Hash)(nonFlatObj, 1, 7);
|
|
56
55
|
const { styleSheet } = (0, zss_engine.transpile)(nonFlatObj, nonFlatHash);
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
56
|
+
records.push({
|
|
57
|
+
key: selector,
|
|
58
|
+
hash: nonFlatHash,
|
|
59
|
+
sheet: styleSheet
|
|
60
|
+
});
|
|
61
|
+
});
|
|
62
|
+
Object.entries(nonFlatQuery).forEach(([atRule, nestedStyles]) => {
|
|
63
|
+
Object.entries(nestedStyles).forEach(([pseudoSelector, style]) => {
|
|
64
|
+
const nonFlatObj = { [key]: { [atRule]: { [pseudoSelector]: style } } };
|
|
65
|
+
const nonFlatHash = (0, zss_engine.genBase36Hash)(nonFlatObj, 1, 7);
|
|
66
|
+
const { styleSheet } = (0, zss_engine.transpile)(nonFlatObj, nonFlatHash);
|
|
67
|
+
const finalSheet = styleSheet.replace(`.${nonFlatHash}`, `.${nonFlatHash}:not(#\\#)`);
|
|
68
|
+
records.push({
|
|
69
|
+
key: atRule + pseudoSelector,
|
|
70
|
+
hash: nonFlatHash,
|
|
71
|
+
sheet: finalSheet
|
|
66
72
|
});
|
|
67
73
|
});
|
|
68
74
|
});
|
package/dist/index.mjs
CHANGED
|
@@ -49,20 +49,26 @@ function create(rule) {
|
|
|
49
49
|
if (atRule.startsWith("@media") || atRule.startsWith("@container")) nonFlatQuery[atRule] = nestedObj;
|
|
50
50
|
else nonFlatBase[atRule] = nestedObj;
|
|
51
51
|
});
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
const nonFlatObj = { [key]: targetNonFlat };
|
|
52
|
+
Object.entries(nonFlatBase).forEach(([selector, style]) => {
|
|
53
|
+
const nonFlatObj = { [key]: { [selector]: style } };
|
|
55
54
|
const nonFlatHash = genBase36Hash(nonFlatObj, 1, 7);
|
|
56
55
|
const { styleSheet } = transpile(nonFlatObj, nonFlatHash);
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
56
|
+
records.push({
|
|
57
|
+
key: selector,
|
|
58
|
+
hash: nonFlatHash,
|
|
59
|
+
sheet: styleSheet
|
|
60
|
+
});
|
|
61
|
+
});
|
|
62
|
+
Object.entries(nonFlatQuery).forEach(([atRule, nestedStyles]) => {
|
|
63
|
+
Object.entries(nestedStyles).forEach(([pseudoSelector, style]) => {
|
|
64
|
+
const nonFlatObj = { [key]: { [atRule]: { [pseudoSelector]: style } } };
|
|
65
|
+
const nonFlatHash = genBase36Hash(nonFlatObj, 1, 7);
|
|
66
|
+
const { styleSheet } = transpile(nonFlatObj, nonFlatHash);
|
|
67
|
+
const finalSheet = styleSheet.replace(`.${nonFlatHash}`, `.${nonFlatHash}:not(#\\#)`);
|
|
68
|
+
records.push({
|
|
69
|
+
key: atRule + pseudoSelector,
|
|
70
|
+
hash: nonFlatHash,
|
|
71
|
+
sheet: finalSheet
|
|
66
72
|
});
|
|
67
73
|
});
|
|
68
74
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plumeria/core",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.4",
|
|
4
4
|
"description": "An atomic CSS runtime designed to disappear.",
|
|
5
5
|
"author": "Refirst 11",
|
|
6
6
|
"license": "MIT",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"stylesheet.css"
|
|
46
46
|
],
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"zss-engine": "
|
|
48
|
+
"zss-engine": "2.0.0"
|
|
49
49
|
},
|
|
50
50
|
"publishConfig": {
|
|
51
51
|
"access": "public",
|