AUI-1548 Fix several issues with scrollspy