@serenity-ui/styles
Advanced tools
Comparing version 0.1.9 to 0.1.10
@@ -25,6 +25,6 @@ import { Tuple } from "@serenity-ui/utils"; | ||
* | ||
* @param size Size | number | ||
* @return string | ||
* @param size Size | number | undefined | ||
* @return string | undefined | ||
*/ | ||
export declare function resolveSize(varName: string, size: Size | number, unit: UnitType): string; | ||
export declare function resolveSize(varName: string, size: Size | number | undefined, unit: UnitType): string | undefined; | ||
/** | ||
@@ -31,0 +31,0 @@ * Returns a modifier variable with a name and value |
@@ -196,3 +196,3 @@ const v = [ | ||
let r = e; | ||
r.startsWith("#") && (r = r.slice(1)), r.length === 3 && (r = r.split("").map((b) => b + b).join("")); | ||
r.startsWith("#") && (r = r.slice(1)), r.length === 3 && (r = r.split("").map((d) => d + d).join("")); | ||
const n = parseInt(r, 16); | ||
@@ -215,3 +215,3 @@ let s = n >> 16 & 255, f = n >> 8 & 255, c = n & 255; | ||
let r = e; | ||
r[0] === "#" && (r = r.slice(1)), r.length === 3 && (r = r.split("").map((b) => b + b).join("")); | ||
r[0] === "#" && (r = r.slice(1)), r.length === 3 && (r = r.split("").map((d) => d + d).join("")); | ||
const n = parseInt(r, 16), s = n >> 16 & 255, f = n >> 8 & 255, c = n & 255; | ||
@@ -231,3 +231,3 @@ return `rgba(${s}, ${f}, ${c}, ${t})`; | ||
return `hsla(${s}, ${f}%, ${c}%, ${t})`; | ||
}, d = (e, t, r) => { | ||
}, b = (e, t, r) => { | ||
if (!e) | ||
@@ -276,3 +276,4 @@ return e; | ||
function $(e, t, r) { | ||
return typeof t == "number" ? t + r : u(e, t); | ||
if (t != null) | ||
return typeof t == "number" ? t + r : u(e, t); | ||
} | ||
@@ -394,4 +395,4 @@ function u(e, t) { | ||
"text-color": r, | ||
"background-color": d(r, 0.1, a), | ||
"hover-color": d(r, 0.12, a) | ||
"background-color": b(r, 0.1, a), | ||
"hover-color": b(r, 0.12, a) | ||
}; | ||
@@ -403,3 +404,3 @@ }, Y = (e, t) => { | ||
"border-color": r, | ||
"hover-color": d(r, 0.12, a) | ||
"hover-color": b(r, 0.12, a) | ||
}; | ||
@@ -414,7 +415,7 @@ }, Z = (e, t) => { | ||
}; | ||
}, z = (e, t) => { | ||
}, D = (e, t) => { | ||
const r = l(e, t); | ||
return { | ||
"text-color": r, | ||
"hover-color": d(r, 0.12, a) | ||
"hover-color": b(r, 0.12, a) | ||
}; | ||
@@ -449,6 +450,6 @@ }; | ||
$ as resolveSize, | ||
z as resolveSubtleVariant, | ||
D as resolveSubtleVariant, | ||
F as resolveTransparentVariant, | ||
U as resolveWhiteVariant, | ||
d as setColorOpacity, | ||
b as setColorOpacity, | ||
A as setHSLOpacity, | ||
@@ -455,0 +456,0 @@ h as setHexOpacity, |
{ | ||
"name": "@serenity-ui/styles", | ||
"version": "0.1.9", | ||
"version": "0.1.10", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "main": "./dist/serenity-styles.umd.cjs", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
48771
30
847