diff --git a/bower.json b/bower.json index 549efe9..03848db 100644 --- a/bower.json +++ b/bower.json @@ -1,7 +1,7 @@ { "name": "ngSmoothScroll", - "version": "2.0.0", - "homepage": "https://github.com/d-oliveros/ngSmoothScroll", + "version": "2.0.1", + "homepage": "https://github.com/CJSCommonPlatform/ngSmoothScroll", "authors": [ "David Oliveros " ], diff --git a/lib/angular-smooth-scroll.js b/lib/angular-smooth-scroll.js index df0c269..ca7ed19 100644 --- a/lib/angular-smooth-scroll.js +++ b/lib/angular-smooth-scroll.js @@ -235,6 +235,9 @@ targetElement = document.getElementById($attrs.scrollTo); if ( !targetElement ) return; + // for accessibility purposes the element that we are scrolling to must get the focus + targetElement.focus(); + var callbackBefore = function(element) { if ( $attrs.callbackBefore ) { var exprHandler = $scope.callbackBefore({element: element});