thomasloven / hass-browser_mod

🔹 A Home Assistant integration to turn your browser into a controllable entity and media player
MIT License
1.33k stars 186 forks source link

Button cards not being rendered in popup #637

Open JDiaz11 opened 1 year ago

JDiaz11 commented 1 year ago

My Home Assistant version: 2023.8.4

What I am doing: Adding button cards to popup don't display in the actual popup

What I expected to happen: Button cards to be displayed

What happened instead: All other card types seem to display correctly, buttons are not rendered at all

Minimal steps to reproduce:

# The least amount of code or steps possible to reproduce my error

# Put your code/steps here

service: browser_mod.popup data: dismissable: true content: show_name: true show_icon: true type: button tap_action: action: toggle entity: light.kitchen_light_hall target: device_id:

Error messages from the browser console:

// Select everything from the browser console and copy it

// Paste it here

By replacing the space in the checkboxes ([ ]) with an X below, I indicate that I:

obaldius commented 1 year ago

Hi there, did you find a solution for this? I'm suffering the same issue thanks in advanced

stefankoehne commented 1 year ago

Same issue here. Home Assistant OS 23.11.0

Card configuration:

type: vertical-stack
cards:
  - type: picture-glance
    camera_view: live
    title: Haustür
    entities: []
    camera_image: camera.g5_bullet_high
  - show_name: true
    show_icon: true
    type: button
    tap_action:
      action: toggle
    name: Licht
    icon_height: 32px
    icon: mdi:door-open
    show_state: false
    entity: light.dig2go

Browser Errors:

hui-button-card.ts:95 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'light.dig2go')
    at o.transformer (hui-button-card.ts:95:37)
    at o.set [as _stateObj] (transform.ts:43:52)
    at transform.ts:79:20
    at Set.forEach (<anonymous>)
    at i.willUpdate (transform.ts:77:18)
    at o.performUpdate (reactive-element.ts:1327:14)
    at o.scheduleUpdate (reactive-element.ts:1261:17)
    at o._$Ej (reactive-element.ts:1233:25)

Same issue with other entities as a button. Same YAML-Code works perfectly outside of the popup-card.

mani94321 commented 1 year ago

I am having the same issue. Trying to add horizontal stack card with button cards inside, same syntax is working fine outside broswer mod pop.

type: horizontal-stack cards:

Colorado4Wheeler commented 6 months ago

This has been an issue for quite a long time, I'm not sure why the original issue #490 was closed that reported this but no matter what I try I cannot get buttons to work in a popup: Buttons, Buttons in a Grid, Buttons in a Stack (Vertical or Horizontal). It doesn't matter if it is tied to an entity or is not (as per the other issue possible 'workarounds')

I can get tiles to work but not buttons.

joaogsleite commented 5 months ago

I'm also having the same problem. When I add a button to a popup card, it is displayed on the edit view. Then, after exiting the edit view, when I open the popup, the card is not displayed. Did anyone found a solution or workaround for this?

Spegeli commented 4 months ago

Im here with the same Issue. Buttons inside a popup are not rendered. Cant be possible that this is not a offical issue because it exists such a long time?!

//Edit: Found a workound: use the custom button-card from here: https://github.com/custom-cards/button-card is working inside a popup ^^