I think that this isn’t possible out-of-the-box atm (at least not as a dynamic created list from group items) as there is only a ‘group-popup’ vue-component available currently.
So, what IS possible and works with your first example is a cell inside the cell which triggers the popup in which the item-list gets generated (based on the group items). So you open a poup from inside a popup, which is obviously not beautful.
With a bit tinkering, you can create a list inside the cell which looks fine for the most part - BUT accordion lists won´t work (I think, this is because a dynamic calculation of the height inside the cell-component - but just a guess)
Here a small example of what i was able to archive as a widget-component:
I think cells could have a “secondary” action, i.e. when long tapping on a touch screen or using the 3-dot button on desktops, which normally expands the cell, but if you specify an action it would do that instead. I’ll consider it.
The “problem” with cells is that they’re actually Framework7 “expandable cards” so due to CSS propagation of the card class, if you try to insert a “regular” card inside the cell/expandable card, it will look funny at best, or not work at all. So that’s not supported right now…
@hmerk I tried to come around the native oh-cell and created a version with f7-components. It opens the keypad-widget with a click on the cell-element and the gSecurity-group as a popup with a click on the dots. But it might need some polishing on the font-sizes etc.
Maybe it fits your needs a bit more - and also creates the group-popup dynamically (so no more extra work creating a list-element inside the expanded-cell)
I had problems using the same theme color for “red” and “green” as the native ‘oh-cell’ - but you could change them to the correct values so they match the ones from the original component, if you like:
green = #4cd964
red = #ff3b30
Also the vertical dots looks slightly different as in the original, due to the fact that I used data-attributes instead of the native f7-icon.
So maybe you want to give it a try and tell me if it works for you.
Thanks again Rainer, your second version is working as expected, but I will stick to the first one, which gave me the ability to experiment with the badges a bit more.
Here is the result of my “group popup”
It is not finished yet. Smoke and battery alarms are to be moved to a separate section. Just there to see something
What I did not find do far is the ability to show the number of open windows or doors, like we had in openHAB 2
I see, that’s a special exception for sitemaps to convert the group’s state to a number when the pattern is %d. Ugly, but it could be done as well for the “display state” of the /rest/events/states SSE endpoint.
Right now you can only do it with an expression like: "=(items.Item1.state === 'ON' ? 1 : 0) + (items.Item2.state === 'ON' ? 1 : 0) + ..."