Expand my Community achievements bar.

Maintaining Scroll Position on Browser Back Button Click.

Avatar

Level 3

Hi,

We have a requirement where if a user clicks on an asset and then presses the browser back button, the scroll bar should not go to the top but should remain at the asset that was clicked earlier.
This functionality is crucial for maintaining a seamless user experience, as it prevents users from losing their place on the page.

Example
:
Step 1: Suppose a user clicks on the asset.

Screenshot (1149).png

Step 2: The asset is opened, and now if the browser's back button is clicked.

Screenshot (1150).png

 

Step 3: The scroll bar goes to the top.

Screenshot (1151).png


Step 4: However, we want the functionality where the scroll bar remains at the asset that was clicked earlier.

Screenshot (1149) - Copy.png


We would appreciate your assistance in implementing this feature.

Thanks & Regards,
Vishal Jain

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Reply

Avatar

Community Advisor

@Vishal_Jain03  My suggestion would be raising it as RFE with Adobe. I see the issue when you have lots of assets in a folder and the UI brings back to top of the folder, then the user has to scroll back to that position. As far as i know the clients normally wont work on fixing the console or enhance it since its the core product UI unless otherwise Adobe suggests how to customize it.  

 

Adobe provides the documentation at high level

https://experienceleague.adobe.com/en/docs/experience-manager-65/content/implementing/developing/ext...

 

Its upto you to whether add the script to identify the scroll position and saving it in cookie or local storage and retrieving it and take the user to the scroll position like this example

https://stackoverflow.com/questions/42604384/html-js-go-back-to-previous-page-in-the-same-scroll-pos...

 

other options to suggest to authors are if the number of assets are more , the content authors should use the filtering on left rail or try to list view which reduces the view for more assets. 

 

Hope that helps!