AalianKhan / mushroom-strategy

A strategy to automatically generate a dashboard using mushroom cards
MIT License
364 stars 36 forks source link

After editing the home screen using the visual editor, clicking on the room doesn't go to that room #116

Closed clowgg closed 6 months ago

clowgg commented 6 months ago

Describe the bug After editing the home screen using the visual editor, clicking on the room doesn't go to that room

Versions

To Reproduce Steps to reproduce the behavior:

  1. Go to Home screen
  2. Edit the Dashboard, take ownership, edit the home screen Area card stack.
  3. Change the order of cards, save.
  4. Click on a area/room - the view does not change. The URL does change, but the browser stays on the dashboard home page.

Expected behavior The area/rooms click would change the browser view to that room as when the home screen area card stack is in its default order.

Screenshots Changed order of card stack: image

Additional context I have noticed that the areas/rooms become "UNNAMED VIEW" tabs across the top bar. When you click on these, the associated area/room opens up fine.

image

DigiLive commented 6 months ago

What exactly do you mean with "visual editor". Only a "YAML editor" should be available.

clowgg commented 6 months ago

This one...

image

image

clowgg commented 6 months ago

Have I done something that wasn't supposed to be possible?

DigiLive commented 6 months ago

Have I done something that wasn't supposed to be possible?

I'm not sure, but it seems to me your yaml configuration file isn't compatible anymore. It should be something like https://github.com/AalianKhan/mushroom-strategy/wiki/Full-Example and at least:

strategy:
  type: custom:mushroom-strategy
views: []

I suspect both mushroom-strategy as well as the default hass-strategy are trying to setup the dashboards, based on the contents of the yaml file. This will lead to such errors.

clowgg commented 6 months ago

So what is the right way to edit the dashboard then? When I have it displayed in the browser, and I click 3 dots - Edit dashboard, I get this:

image

If I press Save, it goes back to the dashboard. If I click the 3 dots, I get:

image

If I click Raw config editor, I get the basic starter yaml:

image

If I click Take control, I get:

image

which is what I did to get the visual editor view I showed in my previous comment.

If this breaks the dashboard, how do you get to see the full yaml so you can change the order the rooms appear it, their icons, and the colours of the icons?

DigiLive commented 6 months ago

You don't take control.

If you do, both mushroom-strategy as well as Home Assistant are trying to setup the dashboards, which doesn't work.

mushroom-strategy generates the dashboard configuration on the fly, while Home Assistant will try to use the static configuration in the yaml file.

clowgg commented 6 months ago

Thank you for the update. I now understand the approach that I must take.

I have edited the yaml file correctly, and have success!! :)

image

DigiLive commented 6 months ago

I'm glad it works out for you. :)