Swipe for sidebar?

I can no longer swipe from the left to access the side bar on Android. Did something change?

3 Likes

+1. I have same issue. Any solution?

1 Like

Same here and mentioned here too:

+1

It happened when I updated to the latest:

Home Assistant 2023.4.0
Supervisor 2023.04.0
Operating System 9.5
Frontend 20230405.0 - latest

I opened this ticket for Android - Edge Swipe for navigation drawer (2023.4+) · Issue #3460 · home-assistant/android · GitHub. I don’t know the full history, but it seems like previously the web front-end might have been handling the edge swipe gesture, but now it has been removed and possibly left for the native apps to implement themselves (also looks like it has already been done for iOS - Add edge swipe to show sidebar by bramkragten · Pull Request #2328 · home-assistant/iOS · GitHub). Hopefully they re-integrate it; it seems like many people use this gesture frequently.

4 Likes

Yeah , especially when hiding the title bar, now I can’t go to the menu anymore, I need to make buttons for it now, quite stupid :frowning:

Having this problem on iOS too.

Ah looks like my app hadn’t updated yet, had to go find it in the app store and click the update button.

Same here after update 2023.4.0 2023.4.1 and 2023.4.2
Just updated the mobile app but also no difference

Can you describe how to create these buttons? Is there a url or something else to open up the sidebar instead?

I don’t know about a way to show the sidebar with a button but the ‘applications/sections’ from the sidebar all have a unique URL like: ‘your HA IP or name:8123/browser-mod’ for instance.

When hovering above these buttons you see the URL and clicking the right button on your mouse can copy that link.

Then you create a button which navigates to that URL:

              - type: button
                icon: mdi:server
                tap_action:
                  action: navigate
                  navigation_path: /browser-mod

Ok got it, thank you. 10 buttons for that workaround look really ugly :nauseated_face:

I hope the swipe function comes back soon.

3 Likes

I managed to get the sidebar to show via browser_mod.javascript service call.
Just add this to a button or an element on your frontend and when clicked it will show the sidebar.
There may be a more elegant way of doing this but it works.

    tap_action:
      action: fire-dom-event
      browser_mod:
        service: browser_mod.javascript
        data:
          browser_id: THIS
          code: "document.querySelector('body > home-assistant').shadowRoot.querySelector('home-assistant-main').dispatchEvent(new CustomEvent('hass-toggle-menu', {detail: {open: true}}));"
9 Likes

Thanks a lot for that tip!

That doesn’t work for my android. Event not in desktop browser. Everything is up to date. Browser mod is installed.

Doesnt work for me either

Does anything come up in console in DevTools??
Maybe one of my custom mods is causing my element selector to be different…
It basically just emulates the ‘hass-toggle-menu’ that i found under Event Listener in the browsers DevTools.
In your browser, while on your home assistant frontend. Go to DevTools and under the Elements tab.
It the ‘body’ section of the site, if you expand the first few sections there should be an element which contains the event to toggle the sidebar. If you right click that element then right click “copy” → “copy JS Path” then put it into the javascript below and then into the tap_action as listed above.

"<PASTE_HERE>.dispatchEvent(new CustomEvent('hass-toggle-menu', {detail: {open: true}}));"

1 Like

Thanks for your explanation but um stucked here:

Can’t figure out event name.

//EDIT:

Ok, I was able to follow your instructions using chrome. But without success. I got the same code you posted.

Ok, my workaround is very simple. I just navigate to energy dashboard. There the button for the side panel is shown and I have access to everything again.

tap_action:
  action: navigate
  navigation_path: /energy
1 Like

Perfect! I like your solution.
I prefer
navigation_path: /config/dashboard
because I use settings, automations or scripts more often.