the-graph icon indicating copy to clipboard operation
the-graph copied to clipboard

Component icons are lost when navigating between graphs

Open bergie opened this issue 11 years ago • 1 comments

noflo-ui allows you to navigate between main graph and subgraphs used in it. We do this by changing the graph property of the-graph-editor. Since the runtime connection remains the same, we don't change the library.

However, in this scenario the graph editor loses icons.

In the main graph, we have icons initially:

screenshot 2014-03-10 at 01 47 07

In a subgraph, icons are gone:

screenshot 2014-03-10 at 01 47 19

Coming back to the main graph, no icons there either:

screenshot 2014-03-10 at 01 47 25

bergie avatar Mar 10 '14 00:03 bergie

I think this is getting overwritten in the-graph-editor.buildInitialLibrary():

    nofloGraph.nodes.forEach(function (node) {
      var component = {
        name: node.component,
        icon: 'cog',
        description: '',
        inports: [],
        outports: []
      };
      ...

Should be smarter there, but not sure how...

forresto avatar Mar 14 '14 20:03 forresto