-
-
Notifications
You must be signed in to change notification settings - Fork 16
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
Reverse restrictToViewport #28
Comments
That would be a simple check of the
What was your main reasoning behind trying to do this? If think it would be a worthwhile feature, I will look into developing it! |
So idea being that a user could navigate to a page from google search or their history. Then by clicking the back button there’s a nice interaction to take them to the item in the list. Does that make sense? |
I apologize, but I'm not quite sure I follow what you're saying. If they arrive at
This gif you provided displays the behavior I intended. What is it that "doesn't work" exactly? Do you mean to have it not animate back to the list because the list item is outside of the viewport? |
Oh, so you're suggesting that the page is scrolled so that the active shared-element on the incoming route is positioned inside the viewport? |
Yep, spot on! Sorry I was a bit over the shop trying to explain. I think as an option might be best because I can see why some would prefer as is. |
That's a cool idea. I'll look into implementing it! |
If the route is changing between, this is generally best solved by using |
@719media I believe the difference they are talking about is for when navigating to pages that have not yet been visited. Where vue-router wouldn't work. |
Wondering how it could be possible to work restrictToViewport going the opposite direction.
restrictToViewport works great for:
/contacts to /contacts/12
But not so much going from
/contacts/12 to /contacts
To replicate, using your dynamic list example (obviously with restrictToViewport enabled)
/dynamic-lists to /dynamic-lists/8 works as intended:
But the opposite /dynamic-lists/8 to /dynamic-lists doesn't
The text was updated successfully, but these errors were encountered: