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

@antv/scale

Package Overview
Dependencies
Maintainers
34
Versions
71
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@antv/scale - npm Package Compare versions

Comparing version

to
0.3.8

5

esm/util/extended.js

@@ -67,3 +67,3 @@ import { head, indexOf, last, map, size } from '@antv/util';

// 异常数据情况下,直接返回,防止 oom
if (typeof dmin !== 'number' || typeof dmax !== 'number') {
if (typeof dmin !== 'number' || typeof dmax !== 'number' || !m) {
return {

@@ -75,3 +75,4 @@ min: 0,

}
if (dmin === dmax || m === 1) {
// js 极大值极小值问题,差值小于 1e-15 会导致计算出错
if (dmax - dmin < 1e-15 || m === 1) {
return {

@@ -78,0 +79,0 @@ min: dmin,

@@ -70,3 +70,3 @@ "use strict";

// 异常数据情况下,直接返回,防止 oom
if (typeof dmin !== 'number' || typeof dmax !== 'number') {
if (typeof dmin !== 'number' || typeof dmax !== 'number' || !m) {
return {

@@ -78,3 +78,4 @@ min: 0,

}
if (dmin === dmax || m === 1) {
// js 极大值极小值问题,差值小于 1e-15 会导致计算出错
if (dmax - dmin < 1e-15 || m === 1) {
return {

@@ -81,0 +82,0 @@ min: dmin,

2

package.json
{
"name": "@antv/scale",
"version": "0.3.7",
"version": "0.3.8",
"description": "The scale module for G2",

@@ -5,0 +5,0 @@ "author": "https://github.com/orgs/antvis/people",

@@ -82,3 +82,3 @@ import { head, indexOf, last, map, size } from '@antv/util';

// 异常数据情况下,直接返回,防止 oom
if (typeof dmin !== 'number' || typeof dmax !== 'number') {
if (typeof dmin !== 'number' || typeof dmax !== 'number' || !m) {
return {

@@ -90,4 +90,5 @@ min: 0,

}
if (dmin === dmax || m === 1) {
// js 极大值极小值问题,差值小于 1e-15 会导致计算出错
if (dmax - dmin < 1e-15 || m === 1) {
return {

@@ -94,0 +95,0 @@ min: dmin,

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet