Socket
Socket
Sign inDemoInstall

@nivo/scales

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nivo/scales - npm Package Compare versions

Comparing version 0.55.0 to 0.56.0

15

dist/nivo-scales.cjs.js

@@ -250,6 +250,15 @@ 'use strict';

var generateSeriesAxis = function generateSeriesAxis(series, axis, scaleSpec) {
var _ref = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {},
_ref$getValue = _ref.getValue,
getValue = _ref$getValue === void 0 ? function (d) {
return d.data[axis];
} : _ref$getValue,
_ref$setValue = _ref.setValue,
setValue = _ref$setValue === void 0 ? function (d, v) {
d.data[axis] = v;
} : _ref$setValue;
if (scaleSpec.type === 'linear') {
series.forEach(function (serie) {
serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseFloat(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseFloat(getValue(d)));
});

@@ -261,3 +270,3 @@ });

serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseTime(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseTime(getValue(d)));
});

@@ -269,3 +278,3 @@ });

serie.data.forEach(function (d) {
all.push(d.data[axis]);
all.push(getValue(d));
});

@@ -272,0 +281,0 @@ });

@@ -244,6 +244,15 @@ import PropTypes from 'prop-types';

var generateSeriesAxis = function generateSeriesAxis(series, axis, scaleSpec) {
var _ref = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {},
_ref$getValue = _ref.getValue,
getValue = _ref$getValue === void 0 ? function (d) {
return d.data[axis];
} : _ref$getValue,
_ref$setValue = _ref.setValue,
setValue = _ref$setValue === void 0 ? function (d, v) {
d.data[axis] = v;
} : _ref$setValue;
if (scaleSpec.type === 'linear') {
series.forEach(function (serie) {
serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseFloat(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseFloat(getValue(d)));
});

@@ -255,3 +264,3 @@ });

serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseTime(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseTime(getValue(d)));
});

@@ -263,3 +272,3 @@ });

serie.data.forEach(function (d) {
all.push(d.data[axis]);
all.push(getValue(d));
});

@@ -266,0 +275,0 @@ });

@@ -248,6 +248,15 @@ (function (global, factory) {

var generateSeriesAxis = function generateSeriesAxis(series, axis, scaleSpec) {
var _ref = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {},
_ref$getValue = _ref.getValue,
getValue = _ref$getValue === void 0 ? function (d) {
return d.data[axis];
} : _ref$getValue,
_ref$setValue = _ref.setValue,
setValue = _ref$setValue === void 0 ? function (d, v) {
d.data[axis] = v;
} : _ref$setValue;
if (scaleSpec.type === 'linear') {
series.forEach(function (serie) {
serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseFloat(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseFloat(getValue(d)));
});

@@ -259,3 +268,3 @@ });

serie.data.forEach(function (d) {
d.data[axis] = d.data[axis] === null ? null : parseTime(d.data[axis]);
setValue(d, getValue(d) === null ? null : parseTime(getValue(d)));
});

@@ -267,3 +276,3 @@ });

serie.data.forEach(function (d) {
all.push(d.data[axis]);
all.push(getValue(d));
});

@@ -270,0 +279,0 @@ });

8

package.json
{
"name": "@nivo/scales",
"version": "0.55.0",
"version": "0.56.0",
"license": "MIT",

@@ -18,5 +18,5 @@ "author": {

"dependencies": {
"d3-scale": "^2.1.2",
"d3-scale": "^3.0.0",
"d3-time-format": "^2.1.3",
"lodash": "^4.17.4"
"lodash": "^4.17.11"
},

@@ -29,3 +29,3 @@ "peerDependencies": {

},
"gitHead": "4c4cbde54f3a954016a0d6a417a9a25a6e18e8f1"
"gitHead": "99c7f6bd886d517f12fa04441b1102d082a1bf26"
}
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