You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@leafer/helper

Package Overview
Dependencies
Maintainers
1
Versions
117
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@leafer/helper - npm Package Compare versions

Comparing version
2.0.2
to
2.0.3
+5
-5
package.json
{
"name": "@leafer/helper",
"version": "2.0.2",
"version": "2.0.3",
"description": "@leafer/helper",

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

"dependencies": {
"@leafer/data": "2.0.2",
"@leafer/math": "2.0.2",
"@leafer/platform": "2.0.2"
"@leafer/data": "2.0.3",
"@leafer/math": "2.0.3",
"@leafer/platform": "2.0.3"
},
"devDependencies": {
"@leafer/interface": "2.0.2"
"@leafer/interface": "2.0.3"
}
}
export { LeafHelper } from './LeafHelper'
export { LeafBoundsHelper } from './LeafBoundsHelper'
export { BranchHelper } from './BranchHelper'
export { WaitHelper } from './WaitHelper'
export { WaitHelper } from './WaitHelper'

@@ -19,3 +19,4 @@ import { ILeaf, IBoundsData, IRenderOptions } from '@leafer/interface'

localRenderBounds(target: ILeaf): IBoundsData {
return target.__.eraser || target.__.visible === 0 ? null : target.__layout.localRenderBounds
const { __, __layout } = target
return __.eraser || __.visible === 0 ? null : (__layout.localOuterBounds || __layout.localRenderBounds)
},

@@ -32,3 +33,4 @@

maskLocalRenderBounds(target: ILeaf, index: number): IBoundsData {
return checkMask(target, index) && target.__layout.localRenderBounds
const { __layout } = target
return checkMask(target, index) && (__layout.localOuterBounds || __layout.localRenderBounds)
},

@@ -35,0 +37,0 @@

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

import { IAlign, ILeaf, IMatrixData, IPointData, IAxis, ITransition, ILeaferCanvas, IBoundsData, IMatrixWithBoundsData } from '@leafer/interface'
import { IAlign, ILeaf, IMatrixData, IPointData, IAxis, ITransition, ILeaferCanvas, IRenderOptions, IBoundsData, IMatrixWithBoundsData } from '@leafer/interface'
import { MathHelper, MatrixHelper, PointHelper, AroundHelper, getMatrixData, BoundsHelper } from '@leafer/math'

@@ -63,2 +63,6 @@ import { Platform } from '@leafer/platform'

leaf.__updateChange()
if (layout.surfaceChanged) {
if (leaf.__hasComplex) L.updateComplex(leaf)
layout.surfaceChanged = false
}
},

@@ -94,2 +98,7 @@

// complex will rewrite
renderComplex(_leaf: ILeaf, _canvas: ILeaferCanvas, _options: IRenderOptions): void { },
updateComplex(_leaf: ILeaf): void { },
checkComplex(_leaf: ILeaf): void { },
// transform

@@ -215,2 +224,9 @@

// @leafer-in/scale-fixed will rewrite
updateScaleFixedWorld(_t: ILeaf): void { },
updateOuterBounds(_t: ILeaf): void { },
// @leafer-in/find will rewrite
cacheId(_t: ILeaf): void { },
drop(t: ILeaf, parent: ILeaf, index?: number, resize?: boolean): void {

@@ -217,0 +233,0 @@ t.setTransform(L.getRelativeWorld(t, parent, true), resize)

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

import { ILeaf, ILeaferCanvas, IBoundsData, IPointData, ITransition, IMatrixData, IAxis, IAlign, IRenderOptions, ILeafList, ILeafLevelList, IFunction } from '@leafer/interface';
import { ILeaf, ILeaferCanvas, IBoundsData, IRenderOptions, IPointData, ITransition, IMatrixData, IAxis, IAlign, ILeafList, ILeafLevelList, IFunction } from '@leafer/interface';

@@ -13,2 +13,5 @@ declare const LeafHelper: {

copyCanvasByWorld(leaf: ILeaf, currentCanvas: ILeaferCanvas, fromCanvas: ILeaferCanvas, fromWorld?: IBoundsData, blendMode?: string, onlyResetTransform?: boolean): void;
renderComplex(_leaf: ILeaf, _canvas: ILeaferCanvas, _options: IRenderOptions): void;
updateComplex(_leaf: ILeaf): void;
checkComplex(_leaf: ILeaf): void;
moveWorld(t: ILeaf, x: number | IPointData, y?: number, isInnerPoint?: boolean, transition?: ITransition): void;

@@ -29,2 +32,5 @@ moveLocal(t: ILeaf, x: number | IPointData, y?: number, transition?: ITransition): void;

getRelativeWorld(t: ILeaf, relative: ILeaf, temp?: boolean): IMatrixData;
updateScaleFixedWorld(_t: ILeaf): void;
updateOuterBounds(_t: ILeaf): void;
cacheId(_t: ILeaf): void;
drop(t: ILeaf, parent: ILeaf, index?: number, resize?: boolean): void;

@@ -31,0 +37,0 @@ hasHighPosition(t: ILeaf): boolean;