Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoInstallSign in
Socket

@leafer/path

Package Overview
Dependencies
Maintainers
1
Versions
116
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@leafer/path - npm Package Compare versions

Comparing version
1.4.0
to
1.4.1
+4
-4
package.json
{
"name": "@leafer/path",
"version": "1.4.0",
"version": "1.4.1",
"description": "@leafer/path",

@@ -25,8 +25,8 @@ "author": "Chao (Leafer) Wan",

"dependencies": {
"@leafer/math": "1.4.0",
"@leafer/debug": "1.4.0"
"@leafer/math": "1.4.1",
"@leafer/debug": "1.4.1"
},
"devDependencies": {
"@leafer/interface": "1.4.0"
"@leafer/interface": "1.4.1"
}
}

@@ -81,7 +81,6 @@ import { IPathCommandData, IPointData } from '@leafer/interface'

if (lastX !== undefined) {
const maxRadius = tan(getRadianFrom(lastX, lastY, x1, y1, x2, y2) / 2) * (getMinDistanceFrom(lastX, lastY, x1, y1, x2, y2) / 2)
data.push(U, x1, y1, x2, y2, min(radius, abs(maxRadius)))
} else {
data.push(U, x1, y1, x2, y2, radius)
const d = getMinDistanceFrom(lastX, lastY, x1, y1, x2, y2)
radius = min(radius, min(d / 2, d / 2 * abs(tan(getRadianFrom(lastX, lastY, x1, y1, x2, y2) / 2))))
}
data.push(U, x1, y1, x2, y2, radius)
},

@@ -88,0 +87,0 @@