Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken in HomeAssistant beta (2023.4b0) #63

Closed
2 tasks done
kulmegil opened this issue Mar 30, 2023 · 10 comments
Closed
2 tasks done

Broken in HomeAssistant beta (2023.4b0) #63

kulmegil opened this issue Mar 30, 2023 · 10 comments
Labels
bug Something isn't working released

Comments

@kulmegil
Copy link

Checklist:

  • I updated to the latest version available
  • I cleared the cache of my browser

Release with the issue:

Home Assistant2023.4b0

Last working release (if known):

Home Assistant 2023.3.6

Browser and Operating System:

any

Description of problem:

Card is no longer able to load templates located in lovelace config.

This is caused by changes in dom structure in HA frontend and getLovelace() (from "custom-card-helpers" dependency)
no longer returning lovelace config to Decluittering Card

Javascript errors shown in the web inspector (if applicable):

card custom:decluttering-card TypeError: can't access property "config", t is null

Additional information:

@kulmegil kulmegil added the bug Something isn't working label Mar 30, 2023
@t-n
Copy link

t-n commented Mar 30, 2023

I found a workaround until we get a new release

  • remove www/community/decluttering-card/decluttering-card.js.gz
  • in www/community/decluttering-card/decluttering-card.js on line 850, replace the entire line with
    var e = document.querySelector("home-assistant");if (e = (e = (e = (e = (e = (e = (e = (e = e && e.shadowRoot) && e.querySelector("home-assistant-main")) && e.shadowRoot) && e.querySelector("mwc-drawer partial-panel-resolver")) || e) && e.querySelector("ha-panel-lovelace")) && e.shadowRoot) && e.querySelector("hui-root")) {
    (or change app-drawer-layout to mwc-drawer and remove the following && e.shadowRoot)

@kulmegil
Copy link
Author

You just needed to replace "app-drawer-layout partial-panel-resolver" into "app-drawer-layout, mwc-drawer partial-panel-resolver" and it should work with both beta and previous versions as well.

@johntdyer
Copy link

Yea, neither @kulmegil or @t-n 's method seem to be working for me...

github-actions bot pushed a commit that referenced this issue Apr 2, 2023
## 1.0.0 (2023-04-02)

### Bug Fixes

* card broken with HA 2023.4 beta and up ([0ccd5b0](0ccd5b0)), closes [#63](#63)
@github-actions
Copy link

github-actions bot commented Apr 2, 2023

🎉 This issue has been resolved in version 1.0.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@Mariusthvdb
Copy link

Thank you!

@kulmegil
Copy link
Author

kulmegil commented Apr 2, 2023

@RomRider thank you for fixing this one for us. Works well!

@johntdyer it did work until beta 4 broke things again ;)

@eiiot
Copy link

eiiot commented Apr 9, 2023

Still broken in 2023.4.1 for me...

@firstof9
Copy link

firstof9 commented Apr 9, 2023

Empty your browser cache and reload.

@SoulRaven
Copy link

same problem also on Home Assistant 2023.4.2 no change

@Mariusthvdb
Copy link

No it's not broken anymore. Just do what we have to do. Every time.
When a custom resource is updated..

Update via Hacs. Or edit the number manually with the 'cache-breaker' if using yaml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

No branches or pull requests

7 participants