
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@logicflow/layout
Advanced tools
layout 扩展包
npm install @logicflow/layout
or
yarn add @logicflow/layout
or
pnpm add @logicflow/layout
import LogicFlow from '@logicflow/core';
import { Dagre } from '@logicflow/layout';
const lf = new LogicFlow({
container: '#app',
plugins: [Dagre]
})
// 基本使用方式 - 无参数
lf.extension.dagre.layout()
// 使用布局参数
lf.extension.dagre.layout({
rankdir: 'LR', // 从坐到右布局
ranksep: 100 // 层级间距
nodesep: 50, // 节点间距
})
参数名 | 类型 | 默认值 | 说明 |
---|---|---|---|
rankdir | string | 'LR' | 布局方向,'LR'(左到右), 'TB'(上到下), 'BT'(下到上), 'RL'(右到左) |
align | string | 'UL' | 节点对齐方式,'UL'(上左), 'UR'(上右), 'DL'(下左), 'DR'(下右) |
nodesep | number | 100 | 节点间的水平间距(像素) |
ranksep | number | 150 | 层级间的垂直间距(像素) |
marginx | number | 120 | 图的水平边距(像素) |
marginy | number | 120 | 图的垂直边距(像素) |
ranker | string | 'tight-tree' | 排名算法,'network-simplex', 'tight-tree', 'longest-path' |
edgesep | number | 10 | 边之间的水平间距(像素) |
acyclicer | string | undefined | 如果设置为'greedy',使用贪心算法查找反馈弧集,用于使图变为无环图 |
isDefaultAnchor | boolean | false | 是否是系统默认锚点(默认上下左右4个锚点),当为true时会自动调整连线的路径 |
lf.extension.dagre.layout({
rankdir: 'LR' // 默认值
})
lf.extension.dagre.layout({
rankdir: 'TB'
})
lf.extension.dagre.layout({
rankdir: 'TB',
isDefaultAnchor: true // 调整连线锚点
})
FAQs
LogicFlow layout
We found that @logicflow/layout demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 7 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.