Custom-sidebar: manage Home Assistant's sidebar items per user or device basis

Folks,
[email protected] has been released. It comes with many changes and improvements:

  1. base_order option in exceptions has been renamed to extend_from_base. If it is true it will merge order from base with the order from the exception, for the rest of properties it will take the propery from the base if it is not available in the exception.
  2. Now it is possible to set more options in exceptions apart from order:
    • title
    • sidebar_editable
    • styles

    If extend_from_base is true and any of these options are not set, it will try to get them from the base config.

  3. order in exceptions is not mandatory anymore.
  4. sidebar_editable apart from a boolean now accepts a string with a JavaScript or a Jinja template. The template should return true or false, otherwise it will be ignored.
  5. When sidebar_editable is false it will also avoid showing the glow circle around the mouse when one press and hold over the title
  6. Now you can use some client side variables inside Jinja templates (they were available in JavaScript templates but not in Jinja ones):
    • user_name: String with the logged user’s name
    • user_is_admin: Bolean value than indicates if the logged user is admin or not
    • user_is_owner: Bolean value than indicates if the logged user is the owner or not
    • user_agent: User agent of the browser in which Home Assistant is being executed