hass-browser_mod: Popups broken in 0.113

Log

2020-07-17 08:40:29 ERROR (MainThread) [frontend.js.latest.202007160] http://192.168.77.67:8123/browser_mod.js:1:5017 TypeError: r is undefined

Console Auswahl_372

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 7
  • Comments: 29 (4 by maintainers)

Commits related to this issue

Most upvoted comments

I have a fix in the works. There’s been some really big changes to how the more-info dialog works, so I’ll need to redo everything pretty much from scratch. The end result will be better than what was before, though, but It’ll take a day or two more.

I’ll get ulcers from all that coffee.

Thank you everyone!

0.113 had some major changes to the frontend regarding more-info. You can check them out here.

What this means is the method used to find the more-info popup in card-tools is no longer working. You used to be able to find it using this: document.querySelector("home-assistant")._moreInfoEl

Now for 0.113, you need to do something like this: document.querySelector("home-assistant").shadowRoot.querySelector("ha-more-info-dialog").shadowRoot.querySelector("ha-dialog").getElementsByClassName("content")[0].querySelector("more-info-content")

I ran into this with some updates I made to custom-ui to bring back hiding attributes on the standard popup. Not sure exactly how to incorporate this into card-tools/browser-mod and have it be backwards compatible. Might not be possible, might just need to handle different versions differently. I am interested to see how this is resolved and hopefully I can use it in my custom-ui code.

Should be fixed in release 1.1.0. If you have the latest version of card-mod, you may get an error when you open a popup-card. This can be safely ignored, but I’ll try to make it not happen in the next card-mod release.

Lets all pool together some coffees for Thomas, for all that hard work he is/will be putting in! Here is my contribution! image

I have spent a lot of time trying to temporarely fix this until @thomasloven review the code, but I have to forgive. Too many code has been changed here. Open and close method does not exist anymore (there is a closeDialog and showDialog, but showDialog is failing). I think a lot of code has to be reviewed 😦 The best result I have is my popup opens but only after I opened a standard “more-info” dialog. It is usable but it cannot be closed using buttons, and it is not centered on my screen.

same here 0.113 release ERROR (MainThread) [frontend.js.latest.202007160] http://192.168.1.17:8123/browser_mod.js:1:5019 Uncaught TypeError: Cannot read property 'close' of undefined

Exact same thing here with 0.113 release. 2020-07-23 09:06:01 ERROR (MainThread) [frontend.js.latest.202007160] http://10.0.1.9:8123/browser_mod.js:1:5019 Uncaught TypeError: Cannot read property 'close' of undefined

Since styles don’t really work anyway, I decided to move over to card-mod-style styles instead in 1.1.1.

See #117 for more info.