support custom icons
This commit is contained in:
1 parent
1c0ac119f4
commit
b81d9449c9
8 files changed
+16
-6
No files matched your search
@@ -174,7 +174,7 @@ G6.registerNode(
|
||||
});
|
||||
|
||||
// icon
|
||||
const img = `./icons/${classify}.svg`;
|
||||
const img = nodeDef.icon ? workspace.workdir + "/" + nodeDef.icon : `./icons/${classify}.svg`;
|
||||
addShape("image", {
|
||||
attrs: {
|
||||
x: 5,
|
||||
|
||||
Reference in new issue
Block a user