Gathering detailed insights and metrics for @csstools/postcss-stepped-value-functions
Gathering detailed insights and metrics for @csstools/postcss-stepped-value-functions
Gathering detailed insights and metrics for @csstools/postcss-stepped-value-functions
Gathering detailed insights and metrics for @csstools/postcss-stepped-value-functions
npm install @csstools/postcss-stepped-value-functions
Typescript
Module System
Min. Node Version
Node Version
NPM Version
97.6
Supply Chain
95.7
Quality
87.3
Maintenance
100
Vulnerability
100
License
CSS (43.25%)
JavaScript (30.24%)
TypeScript (22.9%)
HTML (3.03%)
Nunjucks (0.48%)
Shell (0.1%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT-0 License
984 Stars
4,380 Commits
77 Forks
9 Watchers
6 Branches
132 Contributors
Updated on Jul 12, 2025
Latest Version
4.0.9
Package Id
@csstools/postcss-stepped-value-functions@4.0.9
Unpacked Size
7.28 kB
Size
2.88 kB
File Count
7
NPM Version
10.9.0
Node Version
22.12.0
Published on
May 27, 2025
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
1
npm install @csstools/postcss-stepped-value-functions --save-dev
PostCSS Stepped Value Functions lets you use round
, rem
and mod
stepped value functions, following the CSS Values 4 specification.
1.test-functions { 2 padding: 8px mod(18px, 5px) 1px calc(rem(15px, 6px) + 50%); 3 transform: rotate(mod(-140deg, -90deg)); 4 top: round(15px, 4px); 5 right: round(nearest, 15px, 4px); 6 bottom: round(up, 15px, 7px); 7 left: round(down, 15px, 4px); 8 width: round(to-zero, 15px, 4px); 9} 10 11/* becomes */ 12 13.test-functions { 14 padding: 8px 3px 1px calc(3px + 50%); 15 transform: rotate(-50deg); 16 top: 16px; 17 right: 16px; 18 bottom: 21px; 19 left: 12px; 20 width: 12px; 21}
Add PostCSS Stepped Value Functions to your project:
1npm install postcss @csstools/postcss-stepped-value-functions --save-dev
Use it as a PostCSS plugin:
1const postcss = require('postcss'); 2const postcssSteppedValueFunctions = require('@csstools/postcss-stepped-value-functions'); 3 4postcss([ 5 postcssSteppedValueFunctions(/* pluginOptions */) 6]).process(YOUR_CSS /*, processOptions */);
Given the dynamic nature of custom properties it's impossible to know what the variable value is, which means the plugin can't compute a final value for the stylesheet.
Because of that, any usage that contains a var
is skipped.
The preserve
option determines whether the original notation
is preserved. By default, it is not preserved.
1postcssSteppedValueFunctions({ preserve: true })
1.test-functions { 2 padding: 8px mod(18px, 5px) 1px calc(rem(15px, 6px) + 50%); 3 transform: rotate(mod(-140deg, -90deg)); 4 top: round(15px, 4px); 5 right: round(nearest, 15px, 4px); 6 bottom: round(up, 15px, 7px); 7 left: round(down, 15px, 4px); 8 width: round(to-zero, 15px, 4px); 9} 10 11/* becomes */ 12 13.test-functions { 14 padding: 8px 3px 1px calc(3px + 50%); 15 padding: 8px mod(18px, 5px) 1px calc(rem(15px, 6px) + 50%); 16 transform: rotate(-50deg); 17 transform: rotate(mod(-140deg, -90deg)); 18 top: 16px; 19 top: round(15px, 4px); 20 right: 16px; 21 right: round(nearest, 15px, 4px); 22 bottom: 21px; 23 bottom: round(up, 15px, 7px); 24 left: 12px; 25 left: round(down, 15px, 4px); 26 width: 12px; 27 width: round(to-zero, 15px, 4px); 28}
No vulnerabilities found.
Reason
30 commit(s) and 7 issue activity found in the last 90 days -- score normalized to 10
Reason
no dangerous workflow patterns detected
Reason
security policy file detected
Details
Reason
license file detected
Details
Reason
no binaries found in the repo
Reason
1 existing vulnerabilities detected
Details
Reason
SAST tool detected but not run on all commits
Details
Reason
branch protection is not maximal on development and all release branches
Details
Reason
dependency not pinned by hash detected -- score normalized to 3
Details
Reason
Found 1/24 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
project is not fuzzed
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More