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

Hi folks, I have rescued custom-sidebar-v2 plugin and brought again to live because since a while I want to use it in one of my kiosk devices but it is not longer maintained and the repository is archived.

I am plannig to keep it alive and up to date with any Home Assistant front-end update.

If you have been looking for something like this too, try it out and report any error or unwanted behaviour opening an issue in the repository.

Regards

7 Likes

Well done, I was looking for this exact thing since the v2 around HACS stopped working a while back :+1:

1 Like

Any issue with this? Just stopped working for me all of a sudden

Go to the repo and open an issue there describing what is happening.
We can continue there.

Just in case that it stopped after you updated from version 1.x.x to version 2.x.x, read this:

1 Like

Thanks, yes I had the old file name sidebar-rdoer.json, fine after correcting it as per the link

1 Like

Very nice!!!
Exactly what I was looking for after seeing other 2 repos that were not updated for a whileā€¦
Thank for this sidebar custom shizzle plugin v3!! :+1::muscle::fist_right:

1 Like

What does this do that a long press that activates the sidebar editor in baseline not do?

@jmyler12,

Check all the options in the documentation, all the possibilities are documented there. But just some things (among others) that you can achieve with this custom plugin and it is not possible natively:

  1. The changes are stored in a config file so if you logout and login again, they donā€™t get lost. The same applies to different devices, every time that you log-in in a device the configuration that match with your username is taken from the stored config.
  2. You can change the icon or rename the sidebar items
  3. You can move items to the bottom group of the sidebar
  4. You can dynamically add notifications to the items in the sidebar (for example, display the number of HACS updates as a notification in the HACS sidebar item)
  5. You can use JavaScript/Jinja templates in some of the elements

But as it is stated in the last section of the documentation, if you donā€™t need anything of this, it is probably that the built-in sidebar configuration options are enough for you.

1 Like

For those searching for another optionā€¦

just use the built in functionalityā€¦

Click and hold ā€˜Home Assistantā€™ text for a few seconds, release and edit!

Took me a while to find this!

4 Likes

Hi @Malc3667,

Read the message that I left before or consult the documentation. Custom-sidebar is not only to hide and reorder the sidebar items for the current user and the current session (as the built-in functionality) so the built-in functionality is not another option to achieve what this plugin achieves.

But as it is stated in the same plugin documentation, maybe for some users the built-in functionality, together with the built-in panel_custom and the panel_iframe features, is enough for their use cases. :slight_smile:

Regards

Hi @elchininet

is there a way to add a margin-top/bottom to a specific item? I tried to use that styles string in the main json area, but it did nothing.

I also want to ask if there is a way to add a collapsible menu with sub items inside. My sidebar list is starting to get longā€¦

@mxp83,

The styles option should do the job if you want to add those margins/paddings, just post your code and I can guide you how to do it.

About the collapsible menu, at the moment it is not possible with this plugin. There was a proposal to implement it into Home Assistant but it was not merged. There is also this feature request that has not received much attention.

Hereā€™s a snippet, Iā€™m sure Iā€™m writing it wrong but I didnā€™t see a reference in the repo:

  "title": "Home Assistant",
  "sidebar_editable": false,
  "styles": ".ha-scrollbar a:nth-child:(24) { margin-top:90px }",
  "order": [

the 24th item is where the bottom: true starts.

@mxp83,

The styles are added automatically to the shadowRoot of the sidebar, you only need to specify the items, and it is better that you set the styles in the paper-icon-item element not in the a one. Try with this instead:

"styles": "a[data-panel=\"logbook\"] > paper-icon-item { margin-top: 90px }"

Instead of trying to get the item by its index, try to get it by its data-panel, the previous example tries to get the Logbook item, change it to the item that you want.

this was perfect. Thank you for helping

1 Like

Hi @derekmarch,
Did you solve your issue?

I think so, thank you

1 Like

Good to hear that.
Regards :+1:

Hi there,

I just came here because i asked Google for an option to edit the sidebar. Is it really still not possible to edit the sidebar by default?