Skip to main content

Color shades generator

Project description

Kleur: HSLuv based color utils & theme generators

Poetry PyPI - Version PyPI - Python Versions

Installation

pip install kleur

Usage

Generate shades based one 1 or 2 colors (as CSS variables)

General help

usage: kleur css [-h] [-l LABEL] -c COLOR1 [-k COLOR2] [-n AMOUNT] [-b] [-i] [-d DYNAMIC_RANGE]

options:
  -h, --help            show this help message and exit
  -l, --label LABEL
  -c, --color1 COLOR1
  -k, --color2 COLOR2
  -n, --amount AMOUNT
  -b, --include-black-and-white
  -i, --include-input-shades
  -d, --dynamic-range DYNAMIC_RANGE

Shades as CSS variables, based on one input color

$ kleur css doodle -c d00d1e -n 9

alt text

Shades as CSS variables, based on one input color (with input markers)

$ kleur css doodle -c d00d1e -n 9 -i

alt text

Shades as CSS variables, based on two input colors

$ kleur css -l beatle-salads -c bea71e -k 5a1ad5 -n 9 -d 66

alt text

Shades as CSS variables, based on two input colors (with input markers)

$ kleur css -l beatle-salads -c bea71e -k 5a1ad5 -n 9 -d 0 -i

alt text

$ kleur css -l beatle-salads -c bea71e -k 5a1ad5 -n 9 -d 50 -i

alt text

$ kleur css -l beatle-salads -c bea71e -k 5a1ad5 -n 9 -d 100 -i

alt text

Preview a color theme

General help

$ kleur colors -h
usage: kleur colors [-h] [-c NAME=HUE (1-360) [NAME=HUE (1-360) ...]] [-m] [-a] [-n NUM_SHADES]

options:
  -h, --help            show this help message and exit
  -c, --color-hues NAME=HUE (1-360) [NAME=HUE (1-360) ...]
  -m, --merge-with-default-theme
  -a, --alt-default-theme
  -n, --num-shades NUM_SHADES

Preview default theme

$ uv run kleur colors -n 7

alt text

Preview custom theme

$ kleur colors -n 7 -c green=133 blue=257 tomato=20

alt text

Preview custom theme merged with default theme

$ kleur colors -n 7 -c green=133 blue=257 tomato=20 -m

alt text

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kleur-1.2.4.tar.gz (10.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kleur-1.2.4-py3-none-any.whl (12.2 kB view details)

Uploaded Python 3

File details

Details for the file kleur-1.2.4.tar.gz.

File metadata

  • Download URL: kleur-1.2.4.tar.gz
  • Upload date:
  • Size: 10.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for kleur-1.2.4.tar.gz
Algorithm Hash digest
SHA256 ee7999d161fa6069b3e3947e639f8398725f50f98ca6a70427e805ea55c39eb8
MD5 9bee6b0048a5e99cbddb3a3321a08770
BLAKE2b-256 d760ce4b682573de01197f5c916a1f604c18f4fee3c729ccff152e5dcf00b08f

See more details on using hashes here.

Provenance

The following attestation bundles were made for kleur-1.2.4.tar.gz:

Publisher: on-release-tag__publish-to-pypi.yml on githuib/kleur

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kleur-1.2.4-py3-none-any.whl.

File metadata

  • Download URL: kleur-1.2.4-py3-none-any.whl
  • Upload date:
  • Size: 12.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for kleur-1.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 5beebe8c2c21e8d0f064b7e99e1a6bd700ae62162779c0999beb13149551d38d
MD5 c0530f63462db2c49b3981eb7a87f109
BLAKE2b-256 9496492b6fa39eec0e1a6f17490642d722ab3e8c1d5ccd6e4da82e3a4a0afa4a

See more details on using hashes here.

Provenance

The following attestation bundles were made for kleur-1.2.4-py3-none-any.whl:

Publisher: on-release-tag__publish-to-pypi.yml on githuib/kleur

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page