3.31.0 • Published 3 months ago

csshue v3.31.0

Weekly downloads
3
License
ISC
Repository
github
Last release
3 months ago

csshue

CLI utility to uniformly rotate hue of colors in a css file.

Shown below is stock bootstrap modified with the npx csshue command to give it a green tint by rotating colors by 200 degrees.

npm.io

Constraints

Colors change everywhere, this may cause text readability issues, to address this issue all text is darkened to an almost black color. Text should be dark, in general. You can change that value or disable it altogether via the -t flag.

npm.io

Examples

npx csshue --input old.css --rotate 180 --output new.css
npx csshue --input https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css --rotate 140 --output pukestrap.min.css

Generate 0-345 variations.

#!/bin/bash
STEP=15;
for (( c=0; c<=$((360-$STEP)); c=$((c+$STEP)) ))
do
  npx csshue --input https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css --rotate $c --output pukestrap.`printf "%03.0f" $c`.min.css
done

Example only; use a local/cached copy of bootstrap.min.css please.

Features

  • input flag can be a file or url
  • rotation can be more than 360, it will wrap around
  • output can be STDOUT or filename
  • Supports hue rotation only, serves as a template for other transformation utils.

TLDR

npx csshue --input original.css --rotate 180 --output redesigned.css

Or grab a file from some CDN (Using a remote url)

npx csshue --input https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css --rotate 140 --output pukestrap.min.css
3.31.0

3 months ago

3.30.0

7 months ago

3.29.0

8 months ago

3.28.0

1 year ago

3.27.0

1 year ago

3.26.0

1 year ago

3.25.0

2 years ago

3.24.0

2 years ago

3.23.0

2 years ago

3.22.0

2 years ago

3.20.0

2 years ago

3.21.0

2 years ago

3.19.0

2 years ago

3.18.0

3 years ago

3.17.0

4 years ago

3.16.0

4 years ago

3.15.0

4 years ago

3.14.0

4 years ago

3.13.0

4 years ago

3.12.0

5 years ago

3.11.0

5 years ago

3.10.0

5 years ago

3.9.0

5 years ago

3.8.0

5 years ago

3.7.0

5 years ago

3.6.0

5 years ago

3.5.0

5 years ago

3.4.0

5 years ago

3.3.0

6 years ago

3.2.0

6 years ago

3.1.0

6 years ago

3.0.0

6 years ago

2.0.0

6 years ago

1.3.0

6 years ago

1.2.0

6 years ago

1.1.0

6 years ago