CustomUI - discussion thread

It disappeared after cleaning caches two-three times…

Will lovelace will be supported?

I’m not sure what is going on. I disabled Custom-UI as since going to Lovelace I didn’t have a need for it. Now I do and I can’t seem to get it going again. I uncommented the lines in my configuration.yaml file to enable it again, but it’s not enabling. I’ve updated to the latest with update.sh, There are no errors, I just can’t work it out.

I remember in dev-info it would say what version you had loaded. I don’t see that. I’ve enabled custom-ui with:

customizer:
  custom_ui: local

I’ve also had this under frontend: but can’t remember if I need them enabled or not. Looking at the docs, it says to use one or the other.

frontend:
  extra_html_url:
#   - /local/custom_ui/state-card-custom-ui.html
  extra_html_url_es5:
#    - /local/custom_ui/state-card-custom-ui-es5.html

You need to uncomment both of those lines.

Thanks @finity. That’s got it working again.

After I enable custom_ui, some issues happened on HA system service. For instance:
Check 'configuration validation '
Endless loading. After I comment custom_ui related code, it works fine.
Restart Homeassistant from UI:
Failed with this error:
Error executing service <ServiceCall homeassistant.restart (c:16013f5ea06840f38138d7779f237bc0)> Traceback (most recent call last): File "/usr/src/app/homeassistant/core.py", line 1130, in _safe_execute await self._execute_service(handler, service_call) File "/usr/src/app/homeassistant/core.py", line 1143, in _execute_service await handler.func(service_call) File "/usr/src/app/homeassistant/components/__init__.py", line 129, in async_handle_core_service errors = await conf_util.async_check_ha_config_file(hass) File "/usr/src/app/homeassistant/config.py", line 800, in async_check_ha_config_file check_ha_config_file, hass) File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run result = self.fn(*self.args, **self.kwargs) File "/usr/src/app/homeassistant/scripts/check_config.py", line 335, in check_ha_config_file component = loader.get_component(hass, domain) File "/usr/src/app/homeassistant/loader.py", line 92, in get_component module = importlib.import_module(path) File "/usr/local/lib/python3.6/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 994, in _gcd_import File "<frozen importlib._bootstrap>", line 971, in _find_and_load File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 665, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 674, in exec_module File "<frozen importlib._bootstrap_external>", line 781, in get_code File "<frozen importlib._bootstrap_external>", line 741, in source_to_code

HA and custom_ui are the latest version.

customizer:
  custom_ui: hosted

frontend:
  javascript_version: latest
  extra_html_url:
    - https://raw.githubusercontent.com/andrey-git/home-assistant-custom-ui/master/state-card-custom-ui.html
  extra_html_url_es5:
    - https://raw.githubusercontent.com/andrey-git/home-assistant-custom-ui/master/state-card-custom-ui-dbg.html

Any clue?

issue with extra_badge not showing unit and showing ‘none’ instead, does anyone have a solution for this. Or is it just not available any longer above HA 0.84.3…

see issue filed:

latest 2 version custom-ui and HA 0.84.6:
02

ha 0.84.3:
26

Hi, I’m new on HA and CustomUI :slight_smile:
I’m trying to customize the entity_picture on a smoke sensor. This sensor can have several values (0, 2, 3 and 255). By default the value is displaying in the circle but I would like to display an icon depending on this value.

So I’ve added in configuration.yaml:

customizer:
  custom_ui: local

and in customize.yaml:

sensor.smoke_kitchen:
  templates:
    entity_picture: if (state === '2') return '/local/fire.png'; return '/local/shield.png';

but nothing happens.

if I only do this:

sensor.smoke_kitchen:
  entity_picture: /local/shield.png

I can see the icon in the circle instead of the number but of course it does not change when the value changes.

Any idea to help?
Thanks!

did you try: if (state === 2) ?
can be confusing at times when to use quotes and when not…

I can’t seem to get the customUI to work.

I have the warning in the log file that the custom component for customizer has not been tested by Home Assistant so I know it is getting that from the Custom Components folder however when I try to do the following in my customize.yaml file nothing seems to happen:

sensor.kitchen_motion_sensor_burglar:
  friendly_name: Kitchen Motion Sensor
  templates:
    _stateDisplay: "if (state === 8) return 'Detected'; else return 'None';"
    icon: "if (state === 8) return 'mdi:run-fast'; else return 'mdi:walk';"

What might I be doing wrong?

I have this in my configuration.yaml file:

customizer:
  custom_ui: local

Hi, I’m pretty new to Home Assistant an I can’t get most Custom-UI features running even that I followed the documentation. Maybe someone can point me to the right direction?

I try to get something like this here from the Custom-UI docs:

But the sliders (and the ‘show_last_changed’ I also try to display) are not showing up (the light is of type ‘MQTT Light’):

Any ideas what could go wrong or what else I can try?


About my system:
I have HA 0.87.1 running with the newest Custom-UI from Github.

Home Assistant is installed without hass.io image through virtualenv on a ubuntu host in case this is important.

Custom-UI has been installed the local / automatic way described here:
https://github.com/andrey-git/home-assistant-custom-ui/blob/master/docs/installing.md

The files in .homeassistant/www/custom_ui/ are in the right place and the folders and files are owned an readable by the homeassistant user.
I also doule-checked that by testing if I can reach the files through http://<myip>:8123/local/custom_ui/state-card-custom-ui.html

This is my entry in the configuration.yaml:

homeassistant:
  # Name of the location where Home Assistant is running
  name: Home
  # metric for Metric, imperial for Imperial
  unit_system: metric
  # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
  time_zone: Europe/Berlin
  # Customization file
  customize: !include customize.yaml

frontend:
  extra_html_url:
    - /local/custom_ui/state-card-custom-ui.html
  extra_html_url_es5:
    - /local/custom_ui/state-card-custom-ui-es5.html
  themes: !include themes.yaml

And here my customize.yaml:

light.bogenlampe:
  custom_ui_state_card: state-card-custom-ui
  state_card_mode: single-line
  show_last_changed: true
  templates:
    entity_picture: if (state === 'on') return '/local/img/stand_on.png'; else return '/local/img/stand_off.png';

As you can see in the screenshot, the entity_picture feature works, the icon changes when I switch the light on and off.
So the customize entry itself seems to work and is loaded.

I also see the Custom-UI menu entry in the settings of Home Assistant and a log entry in java console in Chrome with the text ‘Loaded CustomUI 20190113’.
So I guess Custom-UI should also be loaded.

I’m new to Custom-UI too and I have similar configuration like @Thyraz and I also can’t make it work.
I can see the Custom-UI loaded in the HA Info, I don’t see any error in the log, but I can’t see any changes in the Lovelace UI.
When I go to Configuration > Customization I see this message:

The following attributes are customized from outside of customize.yaml
Possibly via a domain, a glob or a different include. 

And I see the show_last_changed checkbox enabled, so I believe that it should work.

My environment:

Hass.io version 0.87.1 installed from image to Raspberry Pi 1
Home Assistant version: 0.87.1
Lovelace mode: storage
Frontend JavaScript version: latest
Custom UIs: 20190113

configuration.yaml

homeassistant:
  customize_glob: !include customize_glob.yaml
  customize: !include customize.yaml

customizer:
  custom_ui: hosted

frontend:
  javascript_version: latest
  extra_html_url:
    - https://raw.githubusercontent.com/andrey-git/home-assistant-custom-ui/master/state-card-custom-ui.html
  extra_html_url_es5:
    - https://raw.githubusercontent.com/andrey-git/home-assistant-custom-ui/master/state-card-custom-ui-dbg.html

customize_glob.yaml

"*.*":
  custom_ui_state_card: state-card-custom-ui
  show_last_changed: true

customize.yaml

light.workroom_led_light:
  state_card_mode: break-slider
  stretch_slider: true

@andrey is this project still active, please? I see your last reply here 6 months ago (August 2018).

Thanks!

I just found that the Lovelace can be switched from storage mode to yaml mode, so I did that and made a restart and nothing happened. Custom-UI changes are still not visible :frowning:

its not that custom-ui doesn’t work per se, it’s HA, and Lovelace all the more, taking out customization support more and more unfortunately. You’ve found a few, there are more. You could check the regular HA interface it custom-ui is working properly.

Have a look:

HA 84.3 regular:

34

Ha 84.3 Lovelace:

13

HA 84.6 regular:

54

further upgrading takes out more options which aren’t yet in Lovelace… reason on this side not to upgrade yet…

the much used _stateDisplay customization has been taken out too, so no more

41

but this:

15

in regular HA that is, theming per entity isnt supported on Lovelace either:

03

Thanks for the info, so I’ll stick with the non-customized Lovelace for now and see what future will bring…

I wouldn’t say that Lovelace isn’t customizable, in fact I think it’s a lot more flexible and customizable. CustomUI doesn’t work with Lovelace, but there are probably hundreds of custom Lovelace cards that provide much of the same options and many more.

@andrey, it looks like a change in 0.90 affected your custom_ui config panel addition and it makes the entire config panel nearly unusable if custom_ui is enabled. I also just get a white screen when going into the Custom UI menu item, so it’s not usable either. Can you check it out when you have a chance?

https://github.com/andrey-git/home-assistant-custom-ui/issues/170#issuecomment-475479131

Just FYI - I forked your repo, commented out the line that adds the new entry in the config panel, rebuilt it, and nav is working for me now.

Hi,

Can I use custom_updater to update this component?

I can not install CustomUI. I followed the next steps but I did not succeed. I need help

You arent adding enough useful information for anyone to help you.

What do you mean that you didnt succeed? Logs?