ShadowAya / anchor-card

An anchor (scroll to) card for Home Assistant!

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Problem when changing view

cesarrew opened this issue · comments

Hi.

I've been using this custom card for a few days now, but I'm having the following problem:

I have an icon at the top of my dashboard to scroll to a specifc card. It's working as expected. The problem is that when I change de view, the query string used to navigate to the card before goes with this new URL. So when I go back to the previous view, it scrolls automaticaly to the card I navigated before. I expected that when I exited the view, the query string would not be joined.

Do you have any idea how to solve this problem?

Thanks in advance.

The navigation with the query gets pushed to the history, so yes, it scrolls again. I kind of had the same issue, but in a bit of a different scenario. I might implement an option that nukes the argument as soon as the card scrolls, sounds easy enough.

Thanks for the feedback!

It would be very helpful! Thank you!

Added an option to fix this in v2.2