ng-scrollable
ng-scrollable copied to clipboard
"scrollable-ignore" on focused elements
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.