{"id":13445715,"url":"https://github.com/guozhaolong/wfd","last_synced_at":"2026-01-30T15:16:12.103Z","repository":{"id":44449839,"uuid":"180095016","full_name":"guozhaolong/wfd","owner":"guozhaolong","description":"flowable workflow designer base on @antv/g6","archived":false,"fork":false,"pushed_at":"2020-10-09T06:16:34.000Z","size":7263,"stargazers_count":933,"open_issues_count":22,"forks_count":254,"subscribers_count":32,"default_branch":"master","last_synced_at":"2025-11-27T12:16:41.000Z","etag":null,"topics":["activiti","designer","editor","flowable","flowable-modeler","g6","g6-editor","workflow"],"latest_commit_sha":null,"homepage":"https://guozhaolong.github.io/wfd/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/guozhaolong.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-04-08T07:35:35.000Z","updated_at":"2025-09-24T11:32:16.000Z","dependencies_parsed_at":"2022-09-03T05:51:53.313Z","dependency_job_id":null,"html_url":"https://github.com/guozhaolong/wfd","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/guozhaolong/wfd","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guozhaolong%2Fwfd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guozhaolong%2Fwfd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guozhaolong%2Fwfd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guozhaolong%2Fwfd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/guozhaolong","download_url":"https://codeload.github.com/guozhaolong/wfd/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guozhaolong%2Fwfd/sbom","scorecard":{"id":449713,"data":{"date":"2025-08-11","repo":{"name":"github.com/guozhaolong/wfd","commit":"6ece64b2f7b00fe44629e425ae2dc5e4b0d5f822"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/11 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 25 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-19T07:53:08.569Z","repository_id":44449839,"created_at":"2025-08-19T07:53:08.569Z","updated_at":"2025-08-19T07:53:08.569Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28914901,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T12:13:43.263Z","status":"ssl_error","status_checked_at":"2026-01-30T12:13:22.389Z","response_time":66,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["activiti","designer","editor","flowable","flowable-modeler","g6","g6-editor","workflow"],"created_at":"2024-07-31T05:00:38.258Z","updated_at":"2026-01-30T15:16:12.084Z","avatar_url":"https://github.com/guozhaolong.png","language":"TypeScript","funding_links":[],"categories":["Libraries"],"sub_categories":["Graph Editing"],"readme":"## Workflow Designer\n\n[![NPM Version](http://img.shields.io/npm/v/wfd.svg?style=flat)](https://www.npmjs.org/package/wfd)\n[![NPM Downloads](https://img.shields.io/npm/dm/wfd.svg?style=flat)](https://www.npmjs.org/package/wfd)\n![](https://img.shields.io/badge/license-MIT-000000.svg)\n\n## Online Demo 1\n![image](https://github.com/guozhaolong/wfd/raw/master/example/snapshots/1.jpg)\n\nhttps://guozhaolong.github.io/wfd/\n\n## Online Demo 2\n![image](https://github.com/guozhaolong/wfd/raw/master/example/snapshots/2.jpg)\n\nhttps://guozhaolong.github.io/wfd2-example/\n\n## Vue version\nhttps://github.com/guozhaolong/wfd-vue/\n\n## Form Designer\nhttps://guozhaolong.github.io/apd-example/\n\n## Usage\n```\nimport React, { Component } from 'react';\nimport Designer from 'wfd';\n\nconst data = {\n    nodes: [{ id: 'startNode', x: 50, y: 200, label: 'Start', clazz: 'start' },\n      { id: 'taskNode1', x: 200, y: 200, label: 'Supervisor', assigneType: 'person', assigneValue: 'admin', isSequential:false, clazz: 'userTask' },\n      { id: 'taskNode2', x: 400, y: 200, label: 'Manager', assigneType: 'person', assigneValue: 'admin', isSequential:false, clazz: 'userTask' },\n      { id: 'decisionNode', x: 400, y: 320, label: 'Cost \u003e 1000', clazz: 'gateway' },\n      { id: 'taskNode3', x: 400, y: 450, label: 'CEO', clazz: 'userTask' },\n      { id: 'endNode', x: 600, y: 320, label: 'End', clazz: 'end' }],\n    edges: [{ source: 'startNode', target: 'taskNode1', sourceAnchor:1, targetAnchor:3, clazz: 'flow' },\n      { source: 'taskNode1', target: 'endNode', sourceAnchor:0, targetAnchor:0, clazz: 'flow' },\n      { source: 'taskNode1', target: 'taskNode2', sourceAnchor:1, targetAnchor:3, clazz: 'flow' },\n      { source: 'taskNode2', target: 'decisionNode', sourceAnchor:1, targetAnchor:0, clazz: 'flow' },\n      { source: 'taskNode2', target: 'taskNode1', sourceAnchor:2, targetAnchor:2, clazz: 'flow' },\n      { source: 'decisionNode', target: 'taskNode3', sourceAnchor:2, targetAnchor:0, clazz: 'flow' },\n      { source: 'decisionNode', target: 'endNode', sourceAnchor:1, targetAnchor:2, clazz: 'flow'},\n      { source: 'taskNode3', target: 'endNode', sourceAnchor:1, targetAnchor:1, clazz: 'flow' },\n      { source: 'taskNode3', target: 'taskNode1', sourceAnchor:3, targetAnchor:2, clazz: 'flow'},\n\nclass WFDemo extends Component {\n    constructor(props) {\n        super(props);\n        this.wfDef = React.createRef();\n    }\n    \n    handleSave = () =\u003e {\n        const bpm = this.wfDef.current.graph.save();\n    }\n      \n    render(){\n        const candidateUsers = [{id:'1',name:'Tom'},{id:'2',name:'Steven'},{id:'3',name:'Andy'}];\n        const candidateGroups = [{id:'1',name:'Manager'},{id:'2',name:'Security'},{id:'3',name:'OA'}];\n        return (\n            \u003c\u003e\n                \u003ca onClick={this.handleSave}\u003eSave\u003c/a\u003e\n                \u003cDesigner data={data} ref={this.wfDef} height={600} mode={\"edit\"} lang=\"zh\" users={candidateUsers} groups={candidateGroups}/\u003e\n            \u003c/\u003e\n        )\n    }\n}\n```\n## API\n##### Designer\n###### 属性\n* data: 初始化数据\n* height: 画布高度\n* mode: view为只读，edit为可编辑\n* lang: zh为中文，en为英文\n* isView: 是否为预览模式（隐藏工具栏和属性栏）\n* users: 选择审批人时对应的数据，数组内对象以id为键，name为值\n* groups: 选择审批组时对应的数据，数组内对象以id为键，name为值\n\n###### 方法\n* save(): 调用graph.save()生成json\n* saveXML(): 调用graph.saveXML(createFile)生成Flowable XML，createFile参数是否同时生成xml文件，默认为true\n\n##### Node\n###### 属性\n* id: 唯一标识\n* x: x点\n* y: y点\n* label: 节点标题\n* hideIcon: 是否隐藏图标  \n* active: 是否显示节点状态（节点边将显示运动动画）\n* clazz: 类，对应flowable节点，支持类型如下:\n    * start 开始节点\n    * timerStart 定时启动节点\n    * messageStart 消息启动节点\n    * signalStart 信号启动节点\n    * gateway 排他网关\n    * exclusiveGateway 排他网关\n    * parallelGateway 并行网关\n    * inclusiveGateway 包容网关\n    * [userTask](#UserTask) 用户审批节点\n    * [scriptTask](#ScriptTask) 脚本节点\n    * [mailTask](#MailTask) 邮件节点\n    * [javaTask](#JavaTask) 自定义类节点\n    * [receiveTask](#ReceiveTask) 接收状态节点\n    * timerCatch 定时捕获节点\n    * messageCatch 消息捕获节点\n    * signalCatch 信号捕获节点\n    * end 结束节点\n    \n##### Edge\n###### 属性\n* source: 源节点ID\n* target: 目标节点ID\n* sourceAnchor: 源节点锚点，0上、1右、2下、3左\n* targetAnchor: 目标节点锚点\n* clazz: 类，目前只有flow一种\n\n##### UserTask\n###### 属性\n* assignType 审批类型，包含人员、人员组、自定义类\n* assignValue 关联审批人或组\n* javaClass 自定义类名\n* dueDate 持续时间\n* isSequential 是否会签\n\n##### ScriptTask\n###### 属性\n* script 脚本内容\n\n##### JavaTask\n###### 属性\n* javaClass 自定义类名\n\n##### ReceiveTask\n###### 属性\n* waitState 等待状态字段名\n* stateValue 等待状态值\n\n##### MailTask\n###### 属性\n* to 收件人\n* subject 邮件主题\n* content 邮件内容\n\n## Run Example\n```\nnpm run dev\n```\n\n## React Version\n```\n\u003e= 16.x\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguozhaolong%2Fwfd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fguozhaolong%2Fwfd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguozhaolong%2Fwfd/lists"}