New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@daeinc/color

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@daeinc/color - npm Package Compare versions

Comparing version 0.2.1 to 0.2.2

11

dist/index.js

@@ -25,11 +25,12 @@ "use strict";

if (Array.isArray(hOrValOrArr)) {
hOrValOrArr[0] *= 360;
if (hOrValOrArr.length === 3) {
const arr = [...hOrValOrArr];
arr[0] *= 360;
if (arr.length === 3) {
// ([h, s, v])
return [...hsvrgb(...hOrValOrArr)];
return [...hsvrgb(...arr)];
}
else if (hOrValOrArr.length === 4) {
else if (arr.length === 4) {
// ([h, s, v, a])
// hsvrgb's 4th argument is NOT alpha but out array
return [...hsvrgb(...hOrValOrArr.slice(0, 3)), hOrValOrArr[3]];
return [...hsvrgb(...arr.slice(0, 3)), arr[3]];
}

@@ -36,0 +37,0 @@ }

{
"name": "@daeinc/color",
"version": "0.2.1",
"version": "0.2.2",
"description": "Color utilities",

@@ -5,0 +5,0 @@ "types": "./dist/index.d.ts",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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