AngularJS based directive for json editing