AngularJS Directive for iviewer