Villhellm / custom-sidebar

Custom Sidebar for Home Assistant
115 stars 23 forks source link

Feature Request: Custom Entries in Sidebar #6

Closed david-kalbermatten closed 4 years ago

david-kalbermatten commented 4 years ago

After the latest update of HA (Docker) the logs have been moved to the configuration page which sparked the idea that it'd be pretty nifty to be able to make custom entries with this integration:

order:
  - item: custom
    name: "Logs"
    icon: mdi:note-text
    href: /config/logs
Villhellm commented 4 years ago

Yes this has actually been in my mental todo list for a while. Once I update to 0.112 I’ll start working on it 👍

Villhellm commented 4 years ago

0.1.3-beta release adds this ability. Please read the updated README for the correct syntax, it is slightly different than what you have suggested.

david-kalbermatten commented 4 years ago

First up, thank you for implementing this feature 👍 When I tried it, it didn't work...

order:
  - item: overview
  - item: hacs
  - item: developer tools
    href: /developer-tools/state
  - item: map
    href: /config/logs
  - item: history
    bottom: true
  - item: logbook
    bottom: true
  - item: configuration
    bottom: true
  - new_item: true
    item: Server Controls
    href: /config/server_control
    icon: "mdi:server"

I reinstalled the latest beta version via HACS and restarted the Home Assistant after updating the config. However, it doesn't show up in the sidebar...

image

Villhellm commented 4 years ago

Double check that the beta is actually being loaded and check the browser console for any errors. It's working on both of my HA instances that I've tested

david-kalbermatten commented 4 years ago

Alright, figured it out! It was my NGINX Reverse Proxy that had an invalid cache and for some reason didn't cache the new file anymore :D

Villhellm commented 4 years ago

It also appears to not work on ios, so it appears I still have work to do 😓

david-kalbermatten commented 4 years ago

Found another bug, (just visual though) When clicking a new_item after having clicked some other non-new_item, it highlights the wrong item.

Steps to reproduce

  1. Click Overview
  2. Click custom item i.e. new_item
  3. Observe the wrong item being high-lighted

In the picture below, I clicked the note-icon (/config/logs) image

Villhellm commented 4 years ago

Yeah that's expected, as per the release notes Redirection to existing panels still has some selection highlighting weirdness, but it doesn't affect the actual function