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

@palett/convert

Package Overview
Dependencies
Maintainers
1
Versions
127
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@palett/convert - npm Package Compare versions

Comparing version 0.2.11 to 0.2.12

6

dist/index.cjs.js

@@ -5,3 +5,3 @@ 'use strict';

var aryth = require('aryth');
var math = require('@aryth/math');

@@ -72,3 +72,3 @@ const rgbToInt = ([r, g, b]) => ((r & 0xFF) << 16) + ((g & 0xFF) << 8) + (b & 0xFF);

l = sum / 2;
return [aryth.round(h), aryth.round(s * THOUSAND) / 10, aryth.round(l * THOUSAND) / 10];
return [math.round(h), math.round(s * THOUSAND) / 10, math.round(l * THOUSAND) / 10];
}

@@ -146,3 +146,3 @@

b = hf(4, h, a, l);
return [aryth.round(r * 0xFF), aryth.round(g * 0xFF), aryth.round(b * 0xFF)]; // return [r * 0xFF & 0xFF, g * 0xFF & 0xFF, b * 0xFF & 0xFF]
return [math.round(r * 0xFF), math.round(g * 0xFF), math.round(b * 0xFF)]; // return [r * 0xFF & 0xFF, g * 0xFF & 0xFF, b * 0xFF & 0xFF]
}

@@ -149,0 +149,0 @@

@@ -1,2 +0,2 @@

import { round } from 'aryth';
import { round } from '@aryth/math';

@@ -3,0 +3,0 @@ const rgbToInt = ([r, g, b]) => ((r & 0xFF) << 16) + ((g & 0xFF) << 8) + (b & 0xFF);

{
"name": "@palett/convert",
"version": "0.2.11",
"version": "0.2.12",
"description": "A color converter among RGB, HEX and HSL.",

@@ -18,3 +18,3 @@ "main": "dist/index.cjs.js",

"dependencies": {
"aryth": "^0.0.5"
"@aryth/math": "^0.2.5"
},

@@ -44,3 +44,3 @@ "repository": {

"homepage": "https://github.com/hoyeungw/palett/rgb#readme",
"gitHead": "bc5829f824fe916225e028f985a3a7ed9d364ff2"
"gitHead": "40671704dd995d641148d4ce9e9ae2de0f93e013"
}
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