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

Sequence not working correctly on browser mod 2 #457

Closed
Daniel-dev22 opened this issue Sep 29, 2022 · 2 comments
Closed

Sequence not working correctly on browser mod 2 #457

Daniel-dev22 opened this issue Sep 29, 2022 · 2 comments
Labels

Comments

@Daniel-dev22
Copy link

Daniel-dev22 commented Sep 29, 2022

Running the latest version of home assistant.

On browser mod 1 this worked, it navigated and closed the pop-up seamlessly.

- type: custom:mushroom-template-card
  primary: Media
  icon: mdi:cog
  picture: local/icons/custom_icons/sonos.png
  tap_action:
    action: fire-dom-event
    browser_mod:
    command: commands
    commands:
       - command: navigate
          navigation_path: /lovelace/sonos
        - command: close_popup

On browser mod 2 this only navigates but doesn't close the pop-up

- type: custom:mushroom-template-card
   primary: Media
   icon: mdi:cog
   picture: local/icons/custom_icons/sonos.png
   tap_action:
     action: fire-dom-event
      browser_mod:
      service: browser_mod.sequence
      data:
        sequence:
          - service: browser_mod.navigate
            data:
               path: /lovelace/sonos
          -  service: browser_mod.close_popup

I also tried this per documentation

- type: custom:mushroom-template-card
  primary: Switches
  icon: mdi:cog
  picture: local/icons/custom_icons/scene-switch1.png
  tap_action:
  action: call-service
  service: browser_mod.sequence
  data:
    sequence:
       - service: browser_mod.navigate
         data:
            path: /lovelace/switches
       - service: browser_mod.close_popup

I was recommended to reverse the order and use a delay which worked for the user on desktop but not on mobile.

type: custom:mushroom-template-card
primary: Media
icon: mdi:cog
picture: local/icons/custom_icons/sonos.png
tap_action:
  action: fire-dom-event
  browser_mod:
    service: browser_mod.sequence
    data:
      sequence:
        - service: browser_mod.close_popup
          data:
            browser_id: THIS
        - service: browser_mod.delay
          data:
            time: 1
        - service: browser_mod.navigate
          data:
            path: /lovelace/sonos

On mobile the above didn't work both with and without browser_id: THIS

Link to forum post of it working on desktop

@Daniel-dev22
Copy link
Author

I had to click out of the pop-up for it to disappear. Again in browser mod 1 it would go away immediately when navigating for a seamless transition.

Screen_Recording_20221001_110821_Home.Assistant.mp4

@stale
Copy link

stale bot commented Dec 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 3, 2022
@stale stale bot closed this as completed Dec 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant