@navita/engine 0.0.9 → 0.0.10
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 +4 -0
- package/index.mjs +4 -0
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -647,6 +647,10 @@ function processStyles({ cache , type }) {
|
|
|
647
647
|
if (typeof value === "string") {
|
|
648
648
|
newValue = value.trim().replace(/;[\n\s]*$/, "");
|
|
649
649
|
}
|
|
650
|
+
// Check if value starts with --, if so, wrap in var()
|
|
651
|
+
if (typeof newValue === "string" && newValue.startsWith("--")) {
|
|
652
|
+
newValue = `var(${value})`;
|
|
653
|
+
}
|
|
650
654
|
if (typeof value === "number") {
|
|
651
655
|
newValue = pixelifyProperties(newProperty, value);
|
|
652
656
|
}
|
package/index.mjs
CHANGED
|
@@ -645,6 +645,10 @@ function processStyles({ cache , type }) {
|
|
|
645
645
|
if (typeof value === "string") {
|
|
646
646
|
newValue = value.trim().replace(/;[\n\s]*$/, "");
|
|
647
647
|
}
|
|
648
|
+
// Check if value starts with --, if so, wrap in var()
|
|
649
|
+
if (typeof newValue === "string" && newValue.startsWith("--")) {
|
|
650
|
+
newValue = `var(${value})`;
|
|
651
|
+
}
|
|
648
652
|
if (typeof value === "number") {
|
|
649
653
|
newValue = pixelifyProperties(newProperty, value);
|
|
650
654
|
}
|