Skip to content
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

"scrollable-ignore" on focused elements #64

Open
nemes1s opened this issue Aug 25, 2017 · 0 comments
Open

"scrollable-ignore" on focused elements #64

nemes1s opened this issue Aug 25, 2017 · 0 comments

Comments

@nemes1s
Copy link

nemes1s commented Aug 25, 2017

Hello!

Was wondering, could there be a solution of my problem:

I have a very long list inside a ng-scrollable element, which is shown in uib-popover with it's own scroll (max-height; overflow-hidden).

When focusing on the most bottom element of that list, ng-scrollable launches it's own "handleFocus" function, which leads to content of ng-scrollable scroll to bottom as it sums up all focused element's parent's offsets here:

while (t && !t.classList.contains('scrollable')) {
            top += t.offsetTop;
            left += t.offsetLeft;
            t = t.offsetParent;
          } 

Current workaround i use, is just adding "scrollable" class to a focusable element.

Cheers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant