"function"!=typeof angular.element.prototype.outerHeight&&(angular.element.prototype.outerHeight=function(){function a(a){return"px"===a.slice(-2)?parseFloat(a.slice(0,-2)):0}var b,c=!1,d=this.eq(0),e=d[0];return arguments[0]===!0||arguments[0]===!1||void 0===arguments[0]?d.length?(c=arguments[0]&&!0||!1,b=e.outerHeight?e.outerHeight:e.offsetHeight,c&&(b+=a(d.css("marginTop"))+a(d.css("marginBottom"))),b):0:d.length?(b=parseFloat(arguments[0]),c=arguments[1]&&!0||!1,c&&(b-=a(d.css("marginTop"))+a(d.css("marginBottom"))),b-=a(d.css("borderTopWidth"))+a(d.css("borderBottomWidth"))+a(d.css("paddingTop"))+a(d.css("paddingBottom")),d.css("height",b+"px"),this):this}),angular.module("ngWig",["ngwig-app-templates"]),angular.module("ngWig").directive("ngWig",function(){return{scope:{content:"=ngWig"},restrict:"A",replace:!0,templateUrl:"ng-wig/views/ng-wig.html",link:function(a,b,c){a.originalHeight=b.outerHeight(),a.editMode=!1,a.autoexpand=!("autoexpand"in c)||"off"!==c.autoexpand,a.cssPath=a.cssPath?a.cssPath:"css/ng-wig.css",a.toggleEditMode=function(){a.editMode=!a.editMode},a.execCommand=function(b,c){"createlink"===b&&(c=prompt("Please enter the URL","http://")),a.$emit("execCommand",{command:b,options:c})},a.resizeEditor=function(a){var c=b.children();for(var d in c){var e=c.eq(d);if(e.hasClass("nw-editor")){e.outerHeight(a);break}}}}}}),angular.module("ngWig").directive("ngWigEditable",function(){function a(a,b,c,d){function e(){f(),d.$setViewValue(b.html())}function f(){if(a.autoexpand)c=b.outerHeight();else var c=a.originalHeight;a.resizeEditor(c)}var g=b[0].ownerDocument;b.attr("contenteditable",!0),d.$render=function(){b.html(d.$viewValue||"")},b.bind("blur keyup change paste",e),a.$on("execCommand",function(a,c){b[0].focus();var d=g.selection,f=c.command,h=c.options;if(d)var i=d.createRange();g.execCommand(f,!1,h),d&&(i.collapse(!1),i.select()),e()}),a.$watch("autoexpand",f),a.$watch("editMode",function(a,b){b&&f()})}return{restrict:"A",require:"ngModel",replace:!0,link:a}}),angular.module("ngwig-app-templates",["ng-wig/views/ng-wig.html"]),angular.module("ng-wig/views/ng-wig.html",[]).run(["$templateCache",function(a){a.put("ng-wig/views/ng-wig.html",'