@worksafevictoria/wcl7.5 1.1.0-beta.57 → 1.1.0-beta.58
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@worksafevictoria/wcl7.5",
|
|
3
|
-
"version": "1.1.0-beta.
|
|
3
|
+
"version": "1.1.0-beta.58",
|
|
4
4
|
"main": "src/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -88,7 +88,6 @@
|
|
|
88
88
|
"react": "^18.2.0",
|
|
89
89
|
"react-dom": "^18.2.0",
|
|
90
90
|
"sass": "1.77.6",
|
|
91
|
-
"sass-loader": "^13.3.2",
|
|
92
91
|
"semantic-release": "^19.0.3",
|
|
93
92
|
"storybook": "^7.5.1",
|
|
94
93
|
"stylelint": "^15.11.0",
|
|
@@ -53,10 +53,11 @@ $current-rootsize: 16px;
|
|
|
53
53
|
|
|
54
54
|
|
|
55
55
|
// Converts a px value to rems. Should only work in absolute em document context (root level), unless $context is specified
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
56
|
+
/**/
|
|
57
|
+
/* @function px-to-rem($value, $context: $current-rootsize) {
|
|
58
|
+
//@if unit($context) == "rem" {
|
|
59
|
+
// $context: rem-to-px($context);
|
|
60
|
+
//}
|
|
60
61
|
$result: ();
|
|
61
62
|
|
|
62
63
|
@each $val in $value {
|
|
@@ -67,6 +68,25 @@ $current-rootsize: 16px;
|
|
|
67
68
|
}
|
|
68
69
|
}
|
|
69
70
|
@return $result;
|
|
71
|
+
} */
|
|
72
|
+
|
|
73
|
+
@function px-to-rem($px, $context: $current-rootsize) {
|
|
74
|
+
@if unit($context) == "rem" {
|
|
75
|
+
$context: rem-to-px($context);
|
|
76
|
+
}
|
|
77
|
+
$result: ();
|
|
78
|
+
|
|
79
|
+
// Iterate over each value in the $px list
|
|
80
|
+
@each $val in $px {
|
|
81
|
+
@if unit($val) == "px" {
|
|
82
|
+
// Convert px to rem
|
|
83
|
+
$val: #{$val / $context}rem;
|
|
84
|
+
}
|
|
85
|
+
// Append converted value to the result list
|
|
86
|
+
$result: append($result, $val);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
@return $result;
|
|
70
90
|
}
|
|
71
91
|
|
|
72
92
|
// Converts a em value to rems. Should only work in absolute em document context (root level), unless $context is specified
|