Something along the lines of display none for shapes? (Or, why is my visible property still taking up space?)

In a horizontal panel layout that goes after a spot node, I have a circle, followed by a transparent rectangle with a width (for spacing), followed by another shape. When I hover over the spot, it forms some button adornments.

I am trying so that when I hover over the circle, a bigger circle appears over it. I added the bigger circle shape before the smaller circle shape, but when I add visibility: false to it, it still seems to be taking up space, even though that the property says it shouldn’t? I was thinking of making the smaller circle disappear (in CSS we would use display: none, but goJS doesn’t have this property).

Could you please show the before-and-after screenshots, along with the code?

Yes, setting GraphObject.visible to false will make it take up zero space. Setting GraphObject.opacity to zero will make it continue to take up its natural space but without drawing anything.

Hi @walter, thanks for the quick reply. After playing around with it, visible false indeed does take up zero space! I am not sure what happened on my development instance. Please feel free to remove this thread.