Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Back To Top plugin seems not to be working for issues

Matthew Harrison
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 16, 2020

We're using a locally installed version of JIRA version 8.3.4.  The users wanted a way to return to the top of the page easily, so we installed the 'Back To Top' plugin.

This seems to work in quite a few pages, but seems not to on the issues page. 

Having a look at the HTML and javascript, it looks like for this page the window does not scroll, but a div within it does; and so I think the following script might need to be added:

AJS.$('.issue-view').scroll(function(){
var scrollValue = AJS.$('.issue-view').scrollTop().valueOf();
TOPPER.handleScroll('.issue-view',scrollValue);
});

in the init.

 

Does this seem like it might resolve the issue?  Or could it cause issues elsewhere?  And, is it easy to get this patched in - or maybe a new release with this?

 

Thanks,

Matt

1 answer

0 votes
Alex Trebek
Contributor
February 10, 2023

Pure JS solution:

    AJS.$("#main > div").animate({scrollTop : 0}, 300);

    AJS.$("#main > div > div > div > div > div > div > div.aui-item.detail-panel").animate({scrollTop : 0}, 300);

    AJS.$("#main > div > div.navigator-group > div > div > div > div > div > div.aui-item.detail-panel").animate({scrollTop : 0}, 300);

Not only it is a Div element that being scrolled, but also different Divs depending on page.

The first line - main issue view screen.

2: Issue list within project context

3: Issue navigator

Suggest an answer

Log in or Sign up to answer