I disabled a lot of lovelace templates, and now it is solved. I have to check it out. Iām also thinking that custom mod cards, also use the browser_mod, like custom mod-card, etcā¦
How does browser_mod work with Home Assistant Cast? I am able to cast to a Google Home Hub and I can see the browser on google home hub, but I do not get a new device created for the home hub. Can browser_mod work with google home hubs?
Thanks, I did the same, and that solved the problem for me.
I cannot figure out why my popup is not working with the new fire-dom-event syntax. Iāve verified that the js console shows the necessary versions of browser_mod and custom:button-card, and Iāve cleared the cache. Help please!
type: 'custom:button-card'
icon: 'mdi:music'
name: Media Players
layout: icon_name
tap_action:
action: fire-dom-event
browser_mod:
command: popup
title: Sonos
card:
cards:
- artwork: cover
entity: media_player.dining_room
hide:
power: true
source: false
info: short
speaker_group:
entities:
- entity_id: media_player.tv_room
name: Living Room
- entity_id: media_player.bedroom_2
name: Office
- entity_id: media_player.bedroom
name: Master Bedroom
expanded: false
platform: sonos
show_group_count: true
type: 'custom:mini-media-player'
- artwork: cover
entity: media_player.tv_room
hide:
power: true
source: false
info: short
speaker_group:
entities:
- entity_id: media_player.dining_room
name: Dining Room
- entity_id: media_player.bedroom_2
name: Office
- entity_id: media_player.bedroom
name: Master Bedroom
expanded: false
platform: sonos
show_group_count: true
type: 'custom:mini-media-player'
- artwork: cover
entity: media_player.bedroom_2
hide:
power: true
source: false
info: short
type: 'custom:mini-media-player'
- type: 'custom:button-card'
name: Pause after Next Track
icon: 'mdi:music-off'
color: var(--accent-color)
color_type: card
tap_action:
action: call-service
service: automation.turn_on
service_data:
entity_id: automation.stop_music_after_current_track
layout: icon_name
type: vertical-stack
You may need to add an entity to your button for this to work.
Thank you for the recommendations. Alas! It didnāt work for me. Iām trying to sort out the problem by trying to get a more simple popup to work. This doesnāt work either:
type: button
icon: 'mdi:star'
entity: light.bedside_his
tap_action:
action: fire-dom-event
browser_mod:
command: popup
card:
type: entities
entities:
- light.bedside_hers
- light.bedside_his
Sorry, I was wrong. The issue is not with the entity but some parameters, especially deviceID, was missing from your code.
This should work (even without an entity):
type: button
icon: 'mdi:star'
tap_action:
action: fire-dom-event
browser_mod:
command: popup
title: Bedside lights
hide_header: false
large: false
deviceID:
- this
- dashboard
card:
type: entities
entities:
- light.bedside_hers
- light.bedside_his
The same problem did you fix it?
Just upgraded, would someone please double check why the popup is not working as a script but fine as tap_action? The script popup setup used to work in version 1.2.3.
This tap_action works:
Lovelace.yaml
- type: 'custom:paper-buttons-row'
buttons:
- icon: "mdi:shield-check-outline"
tap_action:
action: fire-dom-event
browser_mod:
command: popup
title: Popup example
card:
type: entities
entities:
- light.family
- light.kitchen_light
deviceID:
- this
# action: call-service
# service: script.security_control_menu
When the above uses call_service script.security_control_menu, nothing happened:
Script.yaml
security_control_menu:
alias: security_control_menu
sequence:
- service: browser_mod.popup
data:
title: Popup example
card:
type: entities
entities:
- light.family
- light.kitchen_light
deviceID:
- this
[Edit]: Found the reason, itās not possible to resolve āthisā in such (explained here).
Thank you so much! Based on the release notes I thought that we didnāt need deviceID but clearly I was wrong!
That code is working for a standard button card, but not the custom button card. Iāll play around with it a bit more and if I donāt succeed Iāll seek help in the custom button card thread.
For the custom button card, you may need to add an entity.
You need to report this to the maintainer of the custom card.
Hmm. Alas! That does not work. Iāll seek additional help in the custom button card thread given that this now works with a standard button card, thanks to you! Thank you!
What am I doing wrong?! The code below does not allow execute a popup when the image is clicked UNLESS I remove the deviceID parameter. However, when I do that the popup is executed across all three of my tablets in the house. I just want it to popup when clicked on the device that is in use. Help!!! TIA
tap_action:
action: call-service
service: browser_mod.popup
service_data:
auto_close: true
card:
image: 'http://xxxxx.duckdns.org:8084/'
type: picture
deviceID:
- this
- dashboard
First of all you should use the new way of calling:
tap_action:
action: fire-dom-event
browser_mod:
command: popup
Thanks for the replyā¦I changed it to the following, but it still isnāt working?!
tap_action:
action: fire-dom-event
browser_mod:
command: popup
deviceID:
- this
- dashboard
service_data:
auto_close: true
card:
image: 'http://xxxxxxxx.duckdns.org:8082/'
type: picture
title: Driveway
type: picture-glance
Try:
deviceID: this
But I removed it from all my actions and it works (window opens only on the device Iām controling).
I really appreciate the help, but it still isnāt working?! Am I doing something wrong? I click on the image and nothing happens. No popup. Code below:
tap_action:
action: fire-dom-event
browser_mod:
command: popup
deviceID: this
service_data:
auto_close: true
card:
image: 'http://xxxxxxx.duckdns.org:8082/'
type: picture
title: Driveway
type: picture-glance
Did you configure browser_mod in configuration.yaml?
can you try this?
as service data and deviceID are not required for tap_action
deviceID: this
service_data: