Visibility on webview and/or on section?

I’m able to conditionaly hide/show regular elements like Texts, Setpoint etc.
but when I try that on Webview it’s not working as well as on section (or how it’s called)

this works: (VisibilityHelper is by rules operated switch)

Text		label="Automatic Schedule"		visibility=[VisibilityHelper=="ON"]

but this is not

Text		label="Automatic Schedule"		visibility=[VisibilityHelper=="ON"] {
	Text label="test"
}

is this correct behaviour or bug?
in the documentation is mentioned that All sitemap elements shoul be configured hidden …

as well this is not working with Item type Webview

Not sure if these two are somehow special or smthing

This construction seems to work for me, in BasicUI and ClassicUI. What behaviour do you see?

If you are looking at the “sub-page” when the visibility controller changes, that doesn’t close. That might be expected, because the visibility control is about the “parent” widget, not the sub-page navigation. It is arguable either way.

Adding visibility= to the widget(s) on the sub-page is no help of course, you’re just left with a blank page :crazy_face:

I’ve no webview to play with, what happens with that? As I recall, they can be a bit flaky anyway in some UI/browser combos.

Text works for me as well as Frame and also works on a webview I have.

I’m running on a snapshot build though at the moment but was working on 2.5.0 M2

wbehaviour with webview and section is for me same, means they keeps hidden even when helper is ON

eg. when hiding single item it is hiding/showing as helper switching on/off, but when there is something under the item in brackets whole section just stay hidden, same with webview.

which build ur running? am on 2.5M2
logs are clear so not sure where to start debugging


This fix should be included in 2.5M3.

1 Like

Okay, the brackety-subpage part works fine for me in OH 2.4, BasicUI. I didn’t play with frames. The notable difference in my test was I was using some other button on the sitemap to control.

This might be more about getting the state update to the UI than the hide/show mechanism. This part is often tricky with the sitemap UIs.

Here’s an experiment, display the state of your “helper” / controlling Item somewhere with a Text in your sitemap. I suspect an update to a never displayed Item may be missed.

If that works, I suppose a bizarre workaround might be to “display” the control in a Text widget that has its own visibility set by some untrue condition as always off.

helper is being updated, can see it in log events as well as it is hiding/showing other items just fine… so i guess that is not a problem.

I’ll try to update to 2.5M3 and see if that helped

Don’t care, my point was whether the UI knows it has been updated, and if we could force-feed it.

UI knows it, as other elements are being shown/hidden as expected.

Happily confirmed that it was issue in 2.5M2 and in 2.5M3 it is working as expected even with webview

Thanks @Lolodomo

1 Like