updated AngularJS Directive