change node name
This commit is contained in:
1 parent
cad9a2c4d6
commit
a4810121d1
4 files changed
+21
-7
No files matched your search
@@ -306,7 +306,15 @@ export default class Editor extends React.Component<EditorProps, EditorState> {
|
||||
<NodePanel
|
||||
model={curNode}
|
||||
settings={settings}
|
||||
updateNode={id => {
|
||||
updateNode={(id, forceUpdate) => {
|
||||
if (forceUpdate) {
|
||||
const data: any = this.graph.findDataById(id);
|
||||
data.conf = settings.getNodeConf(data.name);
|
||||
data.size = Utils.calcTreeNodeSize(data);
|
||||
this.graph.changeData();
|
||||
this.graph.layout();
|
||||
}
|
||||
|
||||
const item = this.graph.findById(id);
|
||||
item.draw();
|
||||
}}
|
||||
|
||||
Reference in new issue
Block a user