Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

a11y-color

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

a11y-color

Color evaluation and manipulation tools

  • 0.0.6
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-77.78%
Maintainers
1
Weekly downloads
 
Created
Source

Accessibility Color Tools (a11y-color)

Utilities

Color Parsing

parseColor: Parses a color string in rgb or rgba format into a Color object.

Color suggestions for specific contrast ratios

suggestedColors: Suggests alternative color suggestions to meet a given contrast ratio.

Contrast ratio calculation

calculateContrastRatio: Calculate the contrast ratio between the two given colors. Returns the ratio to 1, for example for two two colors with a contrast ratio of 21:1, this function will return 21.

Flatten colors

flattenColors: Combine the two given colors according to alpha blending.

FAQs

Package last updated on 14 Nov 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc