Permastore UI look options?

There’s some UI options in the main panel (reachable via “About & Help”) such as navbar style and simple/extended navbar switchbutton.
I couldn’t get OH to permanently store them (so if I was to restore a config backup, the system would come up with these properly set).

Would anyone know how to accomplish that ?

I don’t believe that you can globally store those options. They are stored at the local level on each individual browser/web viewer.

@ysc Yannick sorry for pinging you but I’d guess you’re the only one to know if anyone.
Can I make these settings become part of a config backup and restore them ?
thanks

The settings made in the „Help & About“ section are local to that client only and stored in browser storage, which means, that they both „survive“ a reload of the application and even cache cleaning.

I cannot imagine how to store them on the openHAB server (how should the server identify which settings belong to which client?) and IMO settings like the theming of MainUI on an individual device also don‘t belong to the server.

Without being on the server, there is no way of backup or restore with the openHAB backup tool.

1 Like

thanks Florian and sorry for not thinking of you on this question.

Do you know if it is possible to change the initial value ? Some .cfg line maybe ?

Looking at the code, this is not possible, as the defaults are hard-coded into the UI.

We could use the /rest/ui/components endpoint to store defaults on the server, which are then retrieved by the client. That wouldn’t require backend work, but someone has to do the frontend work.
I can review a PR, but my own to do list is way to long to add more stuff.

1 Like

Trouble is noone dares to start work on webui when it’s just for a that ‘simple’ feature.
Ramp up cost/learning curve is too big here for anyone else.

Would you consider changing the defaults?
I’d think that the orange navbar is not most user’s favorite anyway.
Yeah I know it’s sorta part of the OH identity but the color is often perceived as pushy/obtrusive so using it as the default isn’t a damn good idea.
Likewise, enabling the ‘show simple navbar on dashboard’ button choice would be the better default choice.

Sorry for not answering for so long, I’ve missed your answer.

I’d think that the orange navbar is not most user’s favorite anyway.

Agreed, I have created a PR: Change the default navbar style from orange to light/dark by florian-h05 · Pull Request #2288 · openhab/openhab-webui · GitHub

Likewise, enabling the ‘show simple navbar on dashboard’ button choice would be the better default choice.

Not sure about this, I personally prefer the standard navbar. @ysc WDYT?

1 Like

That one just puts another title on top reading ‘overview’ (or localized ‘Übersicht’ in German) for the main page and AFAIK cannot be changed by users.
That’s redundant at best and eventually even wrong in specific setups. This is why it should not be the default.

Thanks for picking up. And your PR.

PS: just because we all are now on it: is there a means to en-/disable the bottom bar ?

No. Out of interest: Why?

Another thought: Instead of allowing to configure any aspect of the “main” page I would rather prefer to allow the admin to just declare any page as the “default” page.

You might not want to have that shown by default, it can be overwhelming to layman users
(read: anybody but the admin)

That would require knowing how to build a page that shows everything and in the very format the current main page does. Tough, I wouldn’t know how to reproduce all of it, in particular the bottom bar.

I’d think some more tweaking parameters for the original page will do better.

I don’t understand why you want to hide the bottom bar if you need it at the same time.

I just had a lok at the homepage, and the bottom navbar should automatically be hidden if the model tabs are disabled - you don’t need the bottom navbar if there is only one tab.

While I do, someone else might not.

That’s fine then, too.

I think I now understood what you want to achieve.

You don’t need the bottom bar because you only use the overview page, so you’d like to hide it.
This should be done automatically if all model tabs are disabled, I have a PR for that: Home page: Hide tab bar if all model tabs are hidden by florian-h05 · Pull Request #2291 · openhab/openhab-webui · GitHub

FYI: Hiding the bottom bar is already possible when not needing the model tabs: Just configure the home page to “Display model cards to: Administrators”.

1 Like