diff --git a/example-app/js/app.js b/example-app/js/app.js index f1cbfa5..fea0629 100644 --- a/example-app/js/app.js +++ b/example-app/js/app.js @@ -1,6 +1,6 @@ var app = angular.module("app", ["ngAnnotate"]); -app.controller("AnnotationController", function($scope) +app.controller("AnnotationController", function($scope, $timeout) { $scope.annotationColours = [ { name: "Red", value: "red" }, @@ -20,6 +20,8 @@ app.controller("AnnotationController", function($scope) { $scope.$reject() }; + + $timeout(function() { $scope.$reposition(); }); }); app.controller("MainController", function($scope, $timeout, NGAnnotation)