How to automatically / dynamicly arrange icons?

I have created one widget, and within a widget, created 5 separate Stack Groups.
Within each Stack Group, I added one icon, and some condition (if there is an unread notification from an app, display the icon, otherwise hide it).

The solution works, but I would like to achieve a system, that the icons would be displayed not in a pre-defined place, but if there is at least one notification from one app, place it to the 1st place, then if anoother comes, put it into the 2nd place, etc.

It looks like this now, if all of the apps has notification:

... and looks like this, if only a few:

How could I achieve, that the icons always start to sidplay from the side of the screen, and if a new notification arrives, the next icon appear on the 2nd slot? (I'll definitely replyce current icons, it is created only for a working demo).

You can use a formula in every Stack group in the Layer>Visible that you are using to show or hide the icons, you need to use always,remove

the remove are going to remove entirely the stack group if this app don't have a notification.

Yes, that part is working - but the PLACE of the notifications are not moving.

For example, if I have only a Telegram notirication, still the Telegram icon appears in the middle of the screen, however I would see it next to the side. Then if a Messenged comes, should be the next on the row, etc, etc...

Try to anchor the Stack group to the left

I have all of them anchor to Top Left.
And also, using XOffset - because if not, then all the icons are stacked over each other. Maybe I'm doing it wrong?

I have like:
Root
- Telegram Stack Group (layer Vertical left, Position Top left, XOffset 0
-- Image
- Messenger Stack Group (layer Vertical left, Position Top left, XOffset 100
-- Image
- Facebook Stack Group (layer Vertical left, Position Top left, XOffset 200
-- Image
- Gmail Stack Group (layer Vertical left, Position Top left, XOffset 300
-- Image
- Reddit Stack Group (layer Vertical left, Position Top left, XOffset 400
-- Image

Then I'm switching each layer's visibility, if there are any notification on the shader...

Ahhh, no, you need to put the stacks into a stack group, arrange it vertical center, and maybe you can put this stack group inside an Overlap group and put a transparent rectangle behind it that cover all the icons and then anchor the stack group to the left inside the overlap group.

I'll try it later... It is really late here, need some sleep :D

Yep, I was able to follow this, and works! Thank you! :D

You are welcome!! and good designs!!😃👍