Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BaiscUI] Icon update ignoring the OH iconset #1790

Closed
1 of 4 tasks
lolodomo opened this issue Mar 13, 2023 · 2 comments · Fixed by #1792
Closed
1 of 4 tasks

[BaiscUI] Icon update ignoring the OH iconset #1790

lolodomo opened this issue Mar 13, 2023 · 2 comments · Fixed by #1792
Labels
basic ui Basic UI bug Something isn't working

Comments

@lolodomo
Copy link
Contributor

Which UI are you reporting an issue for?

  • Basic UI
  • HABPanel
  • HABot
  • CometVisu

The problem

When an update event is received by Basic UI, the icon update ignores the iconset, meaning classic iconset is always considered. If your icon is not in the classic iconset, it can lead to either the icon disappearing or a wrong icon displayed because there is an icon with the same name in the classic iconset.

Expected behavior

Consider the iconset when updating the icon in the current page.

Additional information

The icon is properly retrieved when you open a new page. The problem is only when an update is triggered in the current page.

@lolodomo lolodomo added bug Something isn't working basic ui Basic UI labels Mar 13, 2023
@lolodomo
Copy link
Contributor Author

What I have done in PR #1706 did not enhance the live update of the OH icon (when iconset is not classic).

@lolodomo
Copy link
Contributor Author

lolodomo commented Mar 13, 2023

Using these additional icons in a separate iconset:

$ ls conf/icons/mdi
lightbulb_cfl_spiral.svg  lightbulb.svg

Using the following sitemap:


sitemap test4 label="Tests"
{
        Frame label="Using different iconsets" {
                Text item=TestColor label="Icon lightbuld (classic)" icon="lightbulb"
                Text item=TestColor label="Icon lightbuld (mdi)" icon="mdi:lightbulb"
                Text item=TestColor label="Icon lightbulb_cfl_spiral (mdi)" icon="mdi:lightbulb_cfl_spiral"
        }
}

Here is the result when opening the sitemap:
image

And after selecting a color, the second icon is wrong and the third icon disappear:
image

lolodomo added a commit to lolodomo/openhab-webui that referenced this issue Mar 13, 2023
Also trigger the update of the icon for a Colorpicker widget.

Fix openhab#1790

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
lolodomo added a commit to lolodomo/openhab-webui that referenced this issue Mar 14, 2023
Fix openhab#1790

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
kaikreuzer pushed a commit that referenced this issue Mar 17, 2023
Fix #1790

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
basic ui Basic UI bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant