What am I doing wrong ?

It definitely should not. We should be operating on the same widget rather than create a brand new one on click. Count those the same way:

image

Does it also go 1 up every time we click? Should it?

1 Like

yes this is the widget button i have the logic in for the other widget to open . Every time the button is clicked the number goes up by 1. I don’t think it should as it should on the second click remove the widget ui

Definitely do investigate why those buttons multiply - if you add them to the viewport, they probably stack on top of each other. Then, when clicked, each button instance creates a brand new instance of the site map.

If in doubt, do clarify how those buttons are added to the UI - I reckon that’s the root of the issue.

1 Like

Thanks yes going to do some investigations as it make no sense right now

1 Like