Group management issues

I have noticed that there are some things I need to be able to do with groups, but can't. I've created a flow to demonstrate the issues I've noticed, which are partly to do with nested groups and partly to do with adding multiple nodes to a group.

I can add a new node (straight from the palette) to an inner or outer group. I can move an ungrouped existing node to an inner or outer group. I can't, however, move a node from one group to another without ungrouping it first; this (I suppose) makes sense when moving from one group to an entirely separate group, but I also can't move a node from a group to another group inside the existing one. (See the flow if this isn't clear!)

Also, I've noticed that I can't add multiple nodes or groups of nodes to an existing group, which means ungrouping one group and moving nodes individually to the other group, or else ungrouping both groups and creating a new group from all the nodes.

Here's my flow...

[{"id":"2587775f8b4eac4e","type":"tab","label":"Grouping issues","disabled":false,"info":"","env":[]},{"id":"ef5859c6d2b0ce43","type":"group","z":"2587775f8b4eac4e","g":"76a9538bd265a66a","name":"","style":{"stroke":"#92d04f","label":true,"fill":"#e3f3d3"},"nodes":["f994663fc5756533","aba2921ec09244fd","208d4d2ada0c384f"],"x":74,"y":119,"w":392,"h":142},{"id":"76a9538bd265a66a","type":"group","z":"2587775f8b4eac4e","name":"","style":{"stroke":"#ffC000","label":true,"fill":"#ffefbf"},"nodes":["eafa9c77c549aef3","ef5859c6d2b0ce43","db45412658a88959"],"x":34,"y":39,"w":492,"h":248},{"id":"90b7e23b7e791051","type":"group","z":"2587775f8b4eac4e","style":{"stroke":"#999999","stroke-opacity":"1","fill":"none","fill-opacity":"1","label":true,"label-position":"nw","color":"#a4a4a4"},"nodes":["95e473c3c33db5b8","87457cbd26e2ca99"],"x":74,"y":599,"w":452,"h":122},{"id":"f994663fc5756533","type":"debug","z":"2587775f8b4eac4e","g":"ef5859c6d2b0ce43","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":350,"y":220,"wires":[]},{"id":"aba2921ec09244fd","type":"inject","z":"2587775f8b4eac4e","g":"ef5859c6d2b0ce43","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":180,"y":220,"wires":[["f994663fc5756533"]]},{"id":"eafa9c77c549aef3","type":"comment","z":"2587775f8b4eac4e","g":"76a9538bd265a66a","name":"Outer group","info":"","x":130,"y":80,"wires":[]},{"id":"208d4d2ada0c384f","type":"comment","z":"2587775f8b4eac4e","g":"ef5859c6d2b0ce43","name":"Inner group","info":"","x":170,"y":160,"wires":[]},{"id":"ed1af2554db16997","type":"comment","z":"2587775f8b4eac4e","name":"(1)\\n A new node (straight from the palette) or an existing ungrouped node can be\\n dragged into either the inner or outer group.  However, a node in the outer\\n group cannot be added to the inner group directly.  It must be ungrouped first.","info":"","x":850,"y":160,"wires":[]},{"id":"42ee116801f7d389","type":"comment","z":"2587775f8b4eac4e","name":"(2)\\n Multiple nodes or a group of nodes cannot be added to an existing group, so\\n either all nodes have to be ungrouped, selected, and grouped (which is\\n difficult in an inner group) or nodes have to be added individually.","info":"","x":310,"y":400,"wires":[]},{"id":"95e473c3c33db5b8","type":"comment","z":"2587775f8b4eac4e","g":"90b7e23b7e791051","name":"(2b) Try to drag this group to the inner or outer group.","info":"","x":300,"y":640,"wires":[]},{"id":"162e9bbf02d5fad0","type":"comment","z":"2587775f8b4eac4e","name":"(2a) Select me...","info":"","x":120,"y":520,"wires":[]},{"id":"f44202853da25cc0","type":"comment","z":"2587775f8b4eac4e","name":"...and me, and try to drag us to the inner or outer group.","info":"","x":420,"y":520,"wires":[]},{"id":"87457cbd26e2ca99","type":"comment","z":"2587775f8b4eac4e","g":"90b7e23b7e791051","name":"(You wont be able to.)","info":"","x":200,"y":680,"wires":[]},{"id":"db45412658a88959","type":"comment","z":"2587775f8b4eac4e","g":"76a9538bd265a66a","name":"Try to drag me to the inner group","info":"","x":370,"y":80,"wires":[]}]

EDIT: I realised I didn't actually ask a question, but hopefully my meaning was clear... I suppose I'm asking (a) is what I want to do possible, perhaps by holding down a key whilst dragging?, or (b) if not, is this functionality slated to make it into a future release?

@jbudd Thanks for taking the time to reply and trying to help! I did see your post and the edited version; it's frustrating isn't it! I wondered about the "group selection" thing to add a node to an existing inner-group, but as I guess you noticed, it actually just creates another group containing the node and the first group.

Yes. I was so excited by my success that I didn't realise I was a complete failure. :upside_down_face:

Everything about groups is frustrating: There is too much space round the edge, you can't put text on both top and bottom edges, you try and delete a node inside but the whole group vanishes, ...

You must be a sucker for punishment to put groups inside groups!

By the way, your flow is an excellent illustration of the issue.

:rofl:

Well I appreciate the effort you clearly put in anyway.

I kind of need groups within groups as my flow is horribly complicated. (Not sure if that's unavoidable or if it's just my dodgy implementation.)

The other thing that really frustrates me with groups is that, when a node is grouped, I have to click it three times to move it! (The first two times are to select it and the third is the drag.) I think that's related to your "whole group vanishes" point. I'd prefer if I had to grab a group by its edge to select or move it; that way, clicking a node inside it would not select the whole group first!

Hi @rmwiseman

thanks for the feedback on groups. I think much of what you've identified are limitations of the group user experience right now.

There have been previous discussions around improving the group UX, although they haven't turned into concrete actions yet.

Hi @knolleary,

Thanks for the comments. Is there anything I can do to help move group user experience forwards? Should I submit a formal enhancement request, for example? (I don't know if one exists yet.)

I've raised an issue here: Feature: Group UX improvements · Issue #4067 · node-red/node-red · GitHub

I think I've capture the main points from your post - do add a comment if I've missed anything. This is very much focussed on the interaction with groups, rather than other aspects on appearance/labelling etc.

1 Like

Many thanks for raising the issue; I've added some thoughts too.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.