Socket
Socket
Sign inDemoInstall

postcss-calc

Package Overview
Dependencies
8
Maintainers
7
Versions
33
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 8.2.0 to 8.2.1

9

dist/lib/reducer.js

@@ -144,2 +144,4 @@ "use strict";

}
} else if (node.type === 'ParenthesizedExpression') {
collectAddSubItems(preOperator, node.content, collected, precision);
} else {

@@ -351,2 +353,3 @@ collected.push({

* @param {number} precision
* @return {import('../parser').CalcNode}
*/

@@ -376,2 +379,8 @@

if (node.type === 'ParenthesizedExpression') {
if (node.content.type !== 'Function') {
return reduce(node.content, precision);
}
}
return node;

@@ -378,0 +387,0 @@ }

@@ -29,2 +29,4 @@ "use strict";

* @param {import('../parser').CalcNode} node
*
* @return {string}
*/

@@ -67,2 +69,5 @@

case 'ParenthesizedExpression':
return `(${stringify(node.content, prec)})`;
default:

@@ -69,0 +74,0 @@ return round(node.value, prec) + node.unit;

4

package.json
{
"name": "postcss-calc",
"version": "8.2.0",
"version": "8.2.1",
"description": "PostCSS plugin to reduce calc()",

@@ -43,3 +43,3 @@ "keywords": [

"typescript": "^4.5.4",
"uvu": "^0.5.2"
"uvu": "^0.5.3"
},

@@ -46,0 +46,0 @@ "dependencies": {

@@ -9,3 +9,4 @@ export default reduce;

* @param {number} precision
* @return {import('../parser').CalcNode}
*/
declare function reduce(node: import('../parser').CalcNode, precision: number): import("../parser").MathExpression | import("../parser").DimensionExpression | import("../parser").NumberExpression | import("../parser").FunctionExpression;
declare function reduce(node: import('../parser').CalcNode, precision: number): import('../parser').CalcNode;

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with โšก๏ธ by Socket Inc