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

colormangle

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

colormangle - npm Package Compare versions

Comparing version 0.1.86 to 0.1.87

2

package.json
{
"name": "colormangle",
"version": "0.1.86",
"version": "0.1.87",
"description": "converts html color strings to various format",

@@ -5,0 +5,0 @@ "main": "colormangle.min.js",

@@ -12,3 +12,3 @@ <img alt="APM" src="https://img.shields.io/apm/l/vim-mode">

```
<script src="https://broadwayinc.dev/jslib/colormangle/dev/colormangle.js"></script>
<script src="https://broadwayinc.dev/jslib/colormangle/0.1.87/colormangle.js"></script>
```

@@ -62,5 +62,5 @@ And in your javascript:

### .rgba()
### .rgba(<number: opacity. 0~1 range>)
**.rgba()** converts any css color format string to **rgba** format. The input argument 'opacity' is to set the opacity value of the rgba output. Without any argument, the default value is 1 (0 as fully transparent and 1 as fully opaque).
**.rgba()** converts any color format string to **rgba** format. The input argument 'opacity' is to set the opacity value of the rgba output. Without any argument, the default value is 1 (0 as fully transparent and 1 as fully opaque).
<br />**.rgba()** returns object properties (r, g, b, a, string and their values) as in the following structure.

@@ -90,3 +90,3 @@

### .hsla()
### .hsla(<number: opacity 0~1 range>)

@@ -127,3 +127,3 @@ **.hsla()** converts any css color format string to hsla format. The input argument 'opacity' is to set the opacity value of the rgba output. Without any argument, the default value is 1 (0 as fully transparent and 1 as fully opaque). **.hsla()** returns object properties (r, g, b, h, s, l, a, string and their values) as in the following structure.

### .contrastRatio()
### .contrastRatio(<string: html color>)
**.contrastRatio()** calculates the contrast ratio between the given colors.

@@ -138,3 +138,3 @@

### .textColor()
### .textColor(<number: opacity. 0~1 range>)

@@ -141,0 +141,0 @@ **.textColor()** automatically returns the text color string (either 'white' or 'black') that shows the greatest contrast with the background color. **Opacity** of the output text color (either 'black' or 'white') can be set by **input argument**. Without any argument, the default value is 1 (0 as fully transparent and 1 as fully opaque).

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