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

@flourish/legend

Package Overview
Dependencies
Maintainers
31
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@flourish/legend - npm Package Compare versions

Comparing version 6.2.0 to 6.2.2

2

package.json
{
"name": "@flourish/legend",
"version": "6.2.0",
"version": "6.2.2",
"description": "Flourish module for making legend",

@@ -5,0 +5,0 @@ "main": "legend.js",

# 6.2.0
* Add extra check to ensure toFixed() in the roundDown function
is getting values it can process (i.e. between 0 and 100)
# 6.2.0
* Add settings to continuous legend that allow user to add custom labels

@@ -3,0 +8,0 @@

@@ -10,2 +10,3 @@ function remToPx(rem) {

function roundDown(val) {
if (val === 0) return 0;
// Round x down to nice value (preserve the first significant digit, the remaining digits -> 0)

@@ -19,3 +20,7 @@ // e.g. 123.456 => 100, 0.123456 -> 0.1

// Remove floating point garbage from decimal values
if (exp < 0) rounded = parseFloat(rounded.toFixed(-exp));
if (exp < 0) {
var abs_exp = -exp;
// toFixed() limited to range 0 to 100
rounded = abs_exp <= 100 ? parseFloat(rounded.toFixed(abs_exp)): 0;
}

@@ -22,0 +27,0 @@ return rounded;

Sorry, the diff of this file is too big to display

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