thomasloven / lovelace-card-mod

🔹 Add CSS styles to (almost) any lovelace card
MIT License
1.05k stars 169 forks source link

Card_mod broken on HA 2023.10.0b3 because of document.createElement("developer-tools-event") #300

Closed Mariusthvdb closed 9 months ago

Mariusthvdb commented 9 months ago

My Home Assistant version: 2023.10.0b3

My lovelace configuration method (GUI or yaml):

yaml What I am doing:

frontend:

  extra_module_url:
#     - /hacsfiles/lovelace-card-mod/card-mod.js
    - /local/resources/card-mod/card-mod.js

What I expected to happen:

What happened instead:

No card_mod is functional at all maybe related to https://github.com/home-assistant/frontend/pull/17869 ?

Minimal steps to reproduce:

# The least amount of code possible to reproduce my error

# End of code

Error messages from the browser console:

Unhandled Promise Rejection: TypeError: document.createElement("developer-tools-event")._computeParsedEventData is not a function. (In 'document.createElement("developer-tools-event")._computeParsedEventData(t)', 'document.create...

Note:

I am using an updated version of 3.1.4, because after that card_mod_icons didn't function anymore, and the issue about that has never been resolved. Not sure if that worsens the issue at hand, need some testing to excluded that.

Update

with the latest version loaded:

Scherm­afbeelding 2023-09-30 om 16 56 45

card_mod still is completely non functional, and the same error shows in the inspector:

Scherm­afbeelding 2023-09-30 om 16 57 27

By putting an X in the boxes ([]) below, I indicate that I:

jazzyisj commented 9 months ago
image

Chrome on Windows

hmmbob commented 9 months ago

image

Chrome on windows as well, and wondering if this is the reason why my custom_css to put the navigation bar at the bottom of the window is failing too.

This code used to move the bar perfectly fine to the bottom of the screen in my custom theme:

  card-mod-root-yaml: |
    .: |
      .header {
        top: calc(100vh - 48px) !important;
        bottom: 0 !important;
        transform: unset !important;
      }
      #view {
        padding-top: 0px !important;
        padding-bottom: 48px !important;
      }
Mariusthvdb commented 9 months ago

yes it is, card_mod completely stopped functioning, as stated in the opening issue post

downgrading HA to 0b2 doesnt really hurt, and brings back all card_mod goodness, hope this can be a small fix in the resource so we can safely update again