PHP Classes

PHP Hex Color Value Enum: Retrieve color values used in CSS stylesheets

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 66 All time: 10,366 This week: 488Up
Version License PHP version Categories
hex-colors 1.0MIT/X Consortium ...8.1HTML, Graphics
Description 

Author

This package can retrieve color values used in CSS stylesheets.

It provides several enumeration definitions with constant values that associate names with color values in hexadecimal format.

Currently, it provides enumeration definitions for:

- Constant color values used in all browsers

- Color values used by BootStrap and Tailwind CSS libraries

A package with CSS Enum colors and Tailwindcss Enum colors as Hex color.

Innovation Award
PHP Programming Innovation award nominee
September 2023
Number 4
In Web browsers, colors can be referred to using the numeric values of the component color values, like in hexadecimal or by the respective names.

The popularity of CSS frameworks like Bootstrap and Tailwind has increased the number of colors developers may want to use in their site pages.

Humans usually prefer to use names rather than numbers to refer to objects because names are easier to remember.

This package provides sets of enumeration definitions for colors used by default browsers, Tailwindow or Bootstrap.

This way, developers can refer to any of those colors by name rather than by color values.

Manuel Lemos
Picture of Angel Campos
Name: Angel Campos <contact>
Classes: 8 packages by
Country: Spain Spain
Age: ???
All time rank: 377599 in Spain Spain
Week rank: 200 Up7 in Spain Spain Up
Innovation award
Innovation award
Nominee: 4x

Documentation

hex-colors

A package with CSS Enum colors.

At the moment, those are the colors included.

  • Bootstrap colors.
  • Browser default HTML/CSS colors.
  • Tailwindcss colors.

  Files folder image Files (32)  
File Role Description
Files folder imagesrc (3 directories)
Accessible without login Plain text file CHANGELOG.md Data Auxiliary data
Accessible without login Plain text file CODE_OF_CONDUCT.md Data Auxiliary data
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (32)  /  src  
File Role Description
Files folder imageEnums (3 directories)
Files folder imageInterfaces (2 files)
Files folder imageTraits (1 file)

  Files folder image Files (32)  /  src  /  Enums  
File Role Description
Files folder imageBootstrap (1 file)
Files folder imageCss (1 file)
Files folder imageTailwindcss (22 files)

  Files folder image Files (32)  /  src  /  Enums  /  Bootstrap  
File Role Description
  Plain text file BootstrapColor.php Class Class

  Files folder image Files (32)  /  src  /  Enums  /  Css  
File Role Description
  Plain text file BrowserColors.php Class Class

  Files folder image Files (32)  /  src  /  Enums  /  Tailwindcss  
File Role Description
  Plain text file Amber.php Class Class
  Plain text file Blue.php Class Class
  Plain text file Cyan.php Class Class
  Plain text file Emerald.php Class Class
  Plain text file Fuchsia.php Class Class
  Plain text file Gray.php Class Class
  Plain text file Green.php Class Class
  Plain text file Indigo.php Class Class
  Plain text file Lime.php Class Class
  Plain text file Neutral.php Class Class
  Plain text file Orange.php Class Class
  Plain text file Pink.php Class Class
  Plain text file Purple.php Class Class
  Plain text file Red.php Class Class
  Plain text file Rose.php Class Class
  Plain text file Sky.php Class Class
  Plain text file Slate.php Class Class
  Plain text file Stone.php Class Class
  Plain text file Teal.php Class Class
  Plain text file Violet.php Class Class
  Plain text file Yellow.php Class Class
  Plain text file Zinc.php Class Class

  Files folder image Files (32)  /  src  /  Interfaces  
File Role Description
  Plain text file ColorInterface.php Class Class source
  Plain text file TailwindColor.php Class Class source

  Files folder image Files (32)  /  src  /  Traits  
File Role Description
  Plain text file ColorTrait.php Class Class source

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:66
This week:0
All time:10,366
This week:488Up