tripleo-quickstart-extras/roles/validate-tempest/files/stackviz/js/main.js

22 lines
624 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!function e(t,n,r){function i(o,s){if(!n[o]){if(!t[o]){var l="function"==typeof require&&require;if(!s&&l)return l(o,!0);if(a)return a(o,!0);var u=new Error("Cannot find module '"+o+"'");throw u.code="MODULE_NOT_FOUND",u}var c=n[o]={exports:{}};t[o][0].call(c.exports,function(e){var n=t[o][1][e];return i(n?n:e)},c,c.exports,e,t,n,r)}return n[o].exports}for(var a="function"==typeof require&&require,o=0;o<r.length;o++)i(r[o]);return i}({"/home/stack/stackviz/app/js/constants.js":[function(e,t,n){"use strict";var r={appTitle:"StackViz",healthRoot:"http://status.openstack.org/openstack-health"};t.exports=r},{}],"/home/stack/stackviz/app/js/controllers/_index.js":[function(e,t,n){"use strict";var r=e("angular");t.exports=r.module("app.controllers",[]),{console:e("./console.js"),home:e("./home.js"),main:e("./main.js"),"test-details":e("./test-details.js"),timeline:e("./timeline.js")}},{"./console.js":"/home/stack/stackviz/app/js/controllers/console.js","./home.js":"/home/stack/stackviz/app/js/controllers/home.js","./main.js":"/home/stack/stackviz/app/js/controllers/main.js","./test-details.js":"/home/stack/stackviz/app/js/controllers/test-details.js","./timeline.js":"/home/stack/stackviz/app/js/controllers/timeline.js",angular:"/home/stack/stackviz/node_modules/angular/index.js"}],"/home/stack/stackviz/app/js/controllers/console.js":[function(e,t,n){"use strict";function r(e,t,n,r){var i=this;i.artifactName=n.artifactName,i.show=t.search().show,r.artifact(i.artifactName,"console").then(function(e){i.data=e.data})}r.$inject=["$scope","$location","$stateParams","datasetService"];var i=e("./_index");e("codemirror");i.controller("ConsoleController",r)},{"./_index":"/home/stack/stackviz/app/js/controllers/_index.js",codemirror:"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js"}],"/home/stack/stackviz/app/js/controllers/home.js":[function(e,t,n){"use strict";function r(e,t,n){var r=this;r.focus=t.params.artifactName,n.groups().then(function(e){r.groups=e,r.focus||(r.focus=e[0])}),e.$watch(function(){return r.focus},function(e,n){e!==n&&t.go("home",{artifactName:e},{notify:!1})})}r.$inject=["$scope","$state","datasetService"];var i=e("./_index");i.controller("HomeController",r)},{"./_index":"/home/stack/stackviz/app/js/controllers/_index.js"}],"/home/stack/stackviz/app/js/controllers/main.js":[function(e,t,n){"use strict";function r(e,t){e.addEventListener("resize",function(){t.$broadcast("windowResize"),t.$apply()})}r.$inject=["$window","$scope"];var i=e("./_index");i.controller("MainController",r)},{"./_index":"/home/stack/stackviz/app/js/controllers/_index.js"}],"/home/stack/stackviz/app/js/controllers/test-details.js":[function(e,t,n){"use strict";function r(e,t,n,r,i,a,o,s){var l=this;l.artifactName=n.artifactName,l.testName=n.test,l.healthRoot=s.healthRoot,o.start({parent:'div[role="main"] .panel-body'});var u=a.artifact(l.artifactName,"subunit-stats"),c=a.artifact(l.artifactName,"subunit"),f=a.artifact(l.artifactName,"subunit-details"),d=u.then(function(e){l.stats=e.data}),p=c.then(function(e){var t=null;for(var n in e.data)e.data[n].name===l.testName&&(t=e.data[n]);l.item=t,o.inc()}),h=f.then(function(e){l.details=e,l.originalDetails=angular.copy(e.data[l.testName]),l.itemDetails=e.data[l.testName]})["catch"](function(e){});i.all([d,p,h])["catch"](function(e){r.error(e)})["finally"](function(){o.done()}),l.parsePythonLogging=function(e,t,n,r){if(l.originalDetails&&l.originalDetails.pythonlogging){var i=l.originalDetails.pythonlogging,a=[],o=i.split("\n");for(var s in o){var u=o[s];e&&u.includes("INFO")&&a.push(u),t&&u.includes("DEBUG")&&a.push(u),n&&u.includes("WARNING")&&a.push(u),r&&u.includes("ERROR")&&a.push(u)}l.itemDetails.pythonlogging=a.join("\n")}}}r.$inject=["$scope","$location","$stateParams","$log","$q","datasetService","progressService","AppSettings"];var i=e("./_index");i.controller("TestDetailsController",r)},{"./_index":"/home/stack/stackviz/app/js/controllers/_index.js"}],"/home/stack/stackviz/app/js/controllers/timeline.js":[function(e,t,n){"use strict";function r(e,t,n,r){var i=this;i.artifactName=n.artifactName,i.hoveredItem=null,i.selectedItem=null,i.preselect=t.search().test,e.$watch(function(){return i.selectedItem},function(e){e?(t.search({test:e.name}),i.preselect=null):null===i.preselect&&t.search({test:null})})}r.$inject=["$scope","$location","$stateParams","datasetService"];var i=e("./_index");i.controller("TimelineController",r)},{"./_index":"/home/stack/stackviz/app/js/controllers/_index.js"}],"/home/stack/stackviz/app/js/directives/_index.js":[function(e,t,n){"use strict";var r=e("angular");t.exports=r.module("app.directives",[]),{"artifact-summary":e("./artifact-summary.js"),"codemirror-console":e("./codemirror-console.js"),"console-summary":e("./console-summary.js"),"subunit-failures":e("./subunit-failures.js"),"subunit-summary":e("./subunit-summary.js"),"test-details-search":e("./test-details-search.js"),"timeline-details":e("./timeline-details.js"),"timeline-dstat":e("./timeline-dstat.js"),"timeline-overview":e("./timeline-overview.js"),"timeline-search":e("./timeline-search.js"),"timeline-viewport":e("./timeline-viewport.js"),timeline:e("./timeline.js")}},{"./artifact-summary.js":"/home/stack/stackviz/app/js/directives/artifact-summary.js","./codemirror-console.js":"/home/stack/stackviz/app/js/directives/codemirror-console.js","./console-summary.js":"/home/stack/stackviz/app/js/directives/console-summary.js","./subunit-failures.js":"/home/stack/stackviz/app/js/directives/subunit-failures.js","./subunit-summary.js":"/home/stack/stackviz/app/js/directives/subunit-summary.js","./test-details-search.js":"/home/stack/stackviz/app/js/directives/test-details-search.js","./timeline-details.js":"/home/stack/stackviz/app/js/directives/timeline-details.js","./timeline-dstat.js":"/home/stack/stackviz/app/js/directives/timeline-dstat.js","./timeline-overview.js":"/home/stack/stackviz/app/js/directives/timeline-overview.js","./timeline-search.js":"/home/stack/stackviz/app/js/directives/timeline-search.js","./timeline-viewport.js":"/home/stack/stackviz/app/js/directives/timeline-viewport.js","./timeline.js":"/home/stack/stackviz/app/js/directives/timeline.js",angular:"/home/stack/stackviz/node_modules/angular/index.js"}],"/home/stack/stackviz/app/js/directives/artifact-summary.js":[function(e,t,n){"use strict";function r(e,t,n){var r=function(r,i,a,o){r.$watch("artifactName",function(a){i.empty(),t.artifacts(a).then(function(t){t.forEach(function(t){n.directivesForType(t.artifact_type).forEach(function(t){var n=t.directiveName,o="<"+n+" artifact-name=\"'"+a+"'\"></"+n+">",s=e(o)(r);i.append(s)})})})})};return{restrict:"EA",scope:{artifactName:"="},link:r}}r.$inject=["$compile","datasetService","summaryService"];var i=e("./_index.js");i.directive("artifactSummary",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/codemirror-console.js":[function(e,t,n){"use strict";function r(e,t,n,r){var a=null,o=null,s=new Map,l=function(e,t){if(!s.has(t.line))return null;var n=!1,r=null;return s.forEach(function(e,i){return n||i!==t.line?void(n&&null===r&&(r=i-1)):void(n=!0)}),null===r&&(r=e.lastLine()),{from:i.Pos(t.line,e.getLine(t.line).length),to:i.Pos(r,e.getLine(r).length)}},u=function(e,n,r,s){a=i(n[0],{lineNumbers:!0,readOnly:!0,value:"test test test",mode:"console",theme:"neat",foldGutter:{rangeFinder:l},gutters:["CodeMirror-linenumbers","CodeMirror-foldgutter"]}),o=n.find("div");var u=function(){var e=o[0].getBoundingClientRect();o[0].style.height=t.innerHeight-e.top+"px"};e.$on("windowResize",u),u()},c=function(e){e.$watch("data",function(e){if(e){var t=[],n=0;s.clear(),e.scripts.forEach(function(e){s.set(n,e.name),e.lines.forEach(function(e){t.push(e.date+" | "+e.line),n++})}),a.setValue(t.join("\n"));var r=a.getDoc();s.forEach(function(e,t){var n=angular.element("<div><span>"+e+"</span></div>");n.addClass("console-script-header"),r.addLineWidget(t,n[0],{above:!0,noHScroll:!0})})}})};return c.$inject=["$scope"],{restrict:"EA",scope:{data:"=",show:"="},link:u,controller:c}}r.$inject=["$compile","$window","datasetService","summaryService"];var i=e("codemirror");e("codemirror/addon/mode/simple"),e("codemirror/addon/fold/foldcode"),e("codemirror/addon/fold/foldgutter");var a=e("./_index.js");i.defineSimpleMode("console",{start:[{token:"comment",regex:/[\d\-]+ [\d\:\.]+ \|/,sol:!0},{token:"keyword",regex:/\[[a-z\-]+\] \$ .*/}]}),a.directive("codemirrorConsole",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js",codemirror:"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js","codemirror/addon/fold/foldcode":"/home/stack/stackviz/node_modules/codemirror/addon/fold/foldcode.js","codemirror/addon/fold/foldgutter":"/home/stack/stackviz/node_modules/codemirror/addon/fold/foldgutter.js","codemirror/addon/mode/simple":"/home/stack/stackviz/node_modules/codemirror/addon/mode/simple.js"}],"/home/stack/stackviz/app/js/directives/console-summary.js":[function(e,t,n){"use strict";function r(){var e=function(e,t,n){e.$watch("artifactName",function(t){n.artifact(t,"console").then(function(t){e.console=t.data})})};return e.$inject=["$scope","$attrs","datasetService"],{restrict:"EA",scope:{artifactName:"="},controller:e,templateUrl:"directives/console-summary.html"}}var i=e("./_index.js");i.directive("consoleSummary",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/subunit-failures.js":[function(e,t,n){"use strict";function r(){var e=function(e,t,n){e.$watch("artifactName",function(t){n.artifact(t,"subunit-stats").then(function(t){e.stats=t.data})})};return e.$inject=["$scope","$attrs","datasetService"],{restrict:"EA",scope:{artifactName:"="},controller:e,templateUrl:"directives/subunit-failures.html"}}var i=e("./_index.js");i.directive("subunitFailures",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/subunit-summary.js":[function(e,t,n){"use strict";function r(){var e=function(e,t,n){e.$watch("artifactName",function(t){n.artifact(t,"subunit-stats").then(function(t){var n=t.data;e.stats=n,e.timeDiff=(new Date(n.end)-new Date(n.start))/1e3})})};return e.$inject=["$scope","$attrs","datasetService"],{restrict:"EA",scope:{artifactName:"="},controller:e,templateUrl:"directives/subunit-summary.html"}}var i=e("./_index.js");i.directive("subunitSummary",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/test-details-search.js":[function(e,t,n){"use strict";function r(){var e=function(e,t){var n=this;this.open=!1,this.showINFO=!0,this.showDEBUG=!0,this.showWARNING=!0,this.showERROR=!0;var r=function(){e.filter(n.showINFO,n.showDEBUG,n.showWARNING,n.showERROR)};e.$watch(function(){return n.query},r),e.$watch(function(){return n.showINFO},r),e.$watch(function(){return n.showDEBUG},r),e.$watch(function(){return n.showWARNING},r),e.$watch(function(){return n.showERROR},r)};return e.$inject=["$scope","$element"],{restrict:"EA",require:["^testDetailsSearch","^testDetails"],scope:{filter:"="},controller:e,controllerAs:"search",templateUrl:"directives/test-details-search.html",transclude:!0}}var i=e("./_index.js");i.directive("testDetailsSearch",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/timeline-details.js":[function(e,t,n){"use strict";function r(e){var t=function(t){t.healthRoot=e.healthRoot};return t.$inject=["$scope"],{restrict:"EA",scope:{artifactName:"=",item:"="},controller:t,templateUrl:"directives/timeline-details.html"}}r.$inject=["AppSettings"];var i=e("./_index.js");i.directive("timelineDetails",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/timeline-dstat.js":[function(e,t,n){"use strict";function r(e,t){var n=function(e,t,n,r){function i(){M=[];var e=b(r.timeExtents[1]),t=500,n=Math.ceil(e/t),i=0;if(n>30){var a=b(r.viewExtents[0]),o=b(r.viewExtents[1]),s=a+(o-a)/2;n=50,i=Math.max(0,s-15*t)}for(var l=0;n>l;l++){var u=Math.min(e-i,t),c=b.invert(i),f=b.invert(i+u),d=r.dstatInBounds(c,f);M.push({x:i,width:u,min:c,max:f,data:d,c:null,dirty:!0,index:M.length}),i+=u}}function u(e,t){return M.filter(function(n){return n.x+n.width>e&&n.x<t})}function c(){S.resize(r.width+p.left+p.right),S.ctx.clearRect(0,0,S.canvas.width,S.canvas.height),S.ctx.strokeStyle="lightgray",S.ctx.textAlign="end",S.ctx.textBaseline="middle",S.ctx.font="10px sans-serif";for(var e=.8*y(1),t=0;t<m.length;t++)for(var n=m[t],i=y(t+.5),a=0,o=0;o<n.length;o++){var s=n[o];s.scale.range([e,0]),"text"in s&&(S.ctx.fillStyle=s.color,S.ctx.fillText(s.text,p.left-p.right,i+a,p.left-10),a+=10)}}function f(e){if(e.dirty){e.c||(e.c=r.createCanvas(e.width,h));var t=e.c.ctx;t.clearRect(0,0,e.width,h),t.strokeStyle="rgb(175, 175, 175)",t.lineWidth=1;for(var n=0;n<m.length;n++)for(var i=m[n],a=y(n)+g,o=0;o<i.length;o++)if(e.data.length){var s=i[o],l="line"===s.type;t.strokeStyle=s.color,t.fillStyle=s.color;var u=e.data[0];t.beginPath(),t.moveTo(b(+u.system_time)-e.x,y(n)+s.scale(s.value(u)));for(var c=1;c<e.data.length;c++){var f=e.data[c];t.lineTo(b(+f.system_time)-e.x,y(n)+s.scale(s.value(f)))}if(l)t.stroke();else{var d=e.data[e.data.length-1];t.lineTo(b(+d.system_time)-e.x,a),t.lineTo(b(+u.system_time)-e.x,a),t.fill()}}e.dirty=!1}}function d(){$||($=r.viewExtents);var e=r.width+p.left+p.right;angular.element(T.canvas);T.resize(e);var t=function(e){return e*T.ratio};T.ctx.clearRect(0,0,T.canvas.width,T.canvas.height),T.ctx.drawImage(S.canvas,0,0);var n=b($[0]),a=b($[1]),o=u(n,a),s=0;o.forEach(function(e){s+=e.width}),s<r.width&&(i(),o=u(n,a)),o.forEach(function(e){f(e);var r=Math.max(0,n-e.x),i=Math.min(e.width,a-e.x),o=i-r;Math.max(0,n-e.x);0!==Math.floor(o)&&T.ctx.drawImage(e.c.canvas,t(r),0,Math.floor(t(o)),t(h),t(p.left+e.x-n+r),0,t(o),t(h))})}var p=r.margin,h=140,m=[],g=30,v=!1,b=r.axes.absolute,y=(r.axes.selection,s.scaleLinear()),$=null,w=null,x=a.easeCubicOut,k=null,C=500,M=[],S=r.createCanvas(null,h),T=r.createCanvas(null,h,!1);t.append(T.canvas),r.animateCallbacks.push(function(e){if(!v)return!1;if(w){var t=$[1]-$[0],n=r.viewExtents[1]-r.viewExtents[0],a=t-n,o=e-k,s=o/C;return $=w(x(s)),Math.abs(a)>1&&i(),d(),s>=1?(k=null,w=null,!1):!0}return d(),!1}),e.$on("dstatLoaded",function(e,t){m=l(t.entries,t.minimums,t.maximums),g=h/(m.length+1),y.domain([0,m.length]).range([0,h]),c(),i(),v=!0}),e.$on("update",function(){v&&(c(),i(),r.animate())}),e.$on("updateViewSize",function(){v&&($?(w=o.interpolateArray($,r.viewExtents),k=performance.now()):i(),r.animate())}),e.$on("updateViewPosition",function(){v&&($&&(w=o.interpolateArray($,r.viewExtents),k=performance.now()),r.animate())})};return{restrict:"E",require:"^timeline",scope:!0,link:n}}r.$inject=["$document","$window"];var i=e("./_index.js"),a=e("d3-ease"),o=e("d3-interpolate"),s=e("d3-scale"),l=(e("../util/array-util"),e("../util/dstat-parse"),function(e,t,n){if(!e||!e.length)return[];var r=e[0],i=[];return"total_cpu_usage_usr"in r&&"total_cpu_usage_sys"in r&&i.push([{scale:s.scaleLinear().domain([0,100]),value:function(e){return e.total_cpu_usage_wai},color:"rgba(224, 188, 188, 1)",text:"CPU wait"},{scale:s.scaleLinear().domain([0,100]),value:function(e){return e.total_cpu_usage_usr+e.total_cpu_usage_sys},color:"rgba(102, 140, 178, 0.75)",text:"CPU (user+sys)"}]),"memory_usage_used"in r&&i.push([{scale:s.scaleLinear().domain([0,n.memory_usage_used]),value:function(e){return e.memory_usage_used},color:"rgba(102, 140, 178, 0.75)",text:"Memory"}]),"net_total_recv"in r&&"net_total_send"in r&&i.push([{scale:s.scaleLinear().domain([0,n.net_total_recv]),value:function(e){return e.net_total_recv},color:"rgba(224, 188, 188, 1)",text:"Net Down"},{scale:s.scaleLinear().domain([0,n.net_total_send]),value:function(e){return e.net_total_send},color:"rgba(102, 140, 178, 0.75)",text:"Net Up",type:"line"}]),"dsk_total_read"in r&&"dsk_total_writ"in r&&i.push([{scale:s.scaleLinear().domain([0,n.dsk_total_read]),value:function(e){return e.dsk_total_read},color:"rgba(224, 188, 188, 1)",text:"Disk Read",type:"line"},{scale:s.scaleLinear().domain([0,n.dsk_total_writ]),value:function(e){return e.dsk_total_writ},color:"rgba(102, 140, 178, 0.75)",text:"Disk Write",type:"line"}]),i});i.directive("timelineDstat",r)},{"../util/array-util":"/home/stack/stackviz/app/js/util/array-util.js","../util/dstat-parse":"/home/stack/stackviz/app/js/util/dstat-parse.js","./_index.js":"/home/stack/stackviz/app/js/directives/_index.js","d3-ease":"/home/stack/stackviz/node_modules/d3-ease/build/d3-ease.js","d3-interpolate":"/home/stack/stackviz/node_modules/d3-interpolate/build/d3-interpolate.js","d3-scale":"/home/stack/stackviz/node_modules/d3-scale/build/d3-scale.js"}],"/home/stack/stackviz/app/js/directives/timeline-overview.js":[function(e,t,n){"use strict";function r(e,t){var n=function(e,n,r,i){function o(e){var t=i.timeExtents,n=t[0],r=t[1],a=i.viewExtents,o=a[0],s=a[1];if(e.startDate>=o&&e.endDate<=s)return!1;var l,u,c=s-o,f=+o+c/2,d=e.startDate.getTime()+(e.endDate-e.startDate)/2;if(d>f)u=e.endDate.getTime(),l=Math.max(n.getTime(),u-c);else{if(!(f>d))return!1;l=e.startDate.getTime(),u=Math.min(r.getTime(),l+c)}return M=[l,u],i.setViewExtents(M),i.animate(),!0}function s(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];t.push({x:k(r.startDate),y:C(r.worker+.5)-5,width:k(r.endDate)-k(r.startDate),height:w,entry:r})}return t}function l(e,t){var n=E.ctx;n.fillStyle=i.statusColorMap[e.entry.status],n.strokeStyle="rgb(200, 200, 200)",t&&n.clearRect(e.x,e.y,e.width,e.height),n.fillRect(e.x,e.y,e.width,e.height),n.strokeRect(e.x,e.y,e.width,e.height)}function u(){E.resize(i.width),E.ctx.clearRect(0,0,E.canvas.width,E.canvas.height);for(var e=0;e<D.length;e++)l(D[e])}function c(){var e=O.ratio,t=O.ctx;t.fillStyle="dodgerblue",t.globalAlpha=.365;var n=e*y.left+e*k(M[0]),r=e*(k(M[1])-k(M[0]));t.fillRect(n,0,r,O.canvas.height),t.globalAlpha=1}function f(){var e=O.ratio,t=i.width+y.left+y.right;O.resize(t),O.ctx.clearRect(0,0,O.canvas.width,O.canvas.height),O.ctx.drawImage(E.canvas,e*y.left,0),c()}function d(e){var t=O.canvas.getBoundingClientRect(),n={xRaw:e.clientX-t.left,x:e.clientX-t.left-y.left,y:e.clientY-t.top,radius:e.radiusX||3*O.ratio};return n.inBounds=n.x>0&&n.x<i.width&&n.y>0&&n.y<$,n}function p(e,t){return e.inBounds&&Math.abs(t-e.x)<=e.radius}function h(e){return"left"===e?"right":"right"===e?"left":e}function m(e,t,n){e=k.invert(e),t=k.invert(t),e>t&&(n=h(n));var r=Math.min(e,t),a=Math.max(e,t);if("position"===n){var o=a-r;r<i.timeExtents[0]?(r=+i.timeExtents[0],a=Math.min(+i.timeExtents[1],r+o)):a>i.timeExtents[1]&&(a=+i.timeExtents[1],r=Math.max(+i.timeExtents[0],a-o))}else r<i.timeExtents[0]&&(r=i.timeExtents[0]),a>i.timeExtents[1]&&(a=i.timeExtents[1]);return{extent:[r,a],type:n}}function g(e){var t=k(M[0]),n=k(M[1]);p(e,t)?T="left":p(e,n)?T="right":e.x>t&&e.x<n?(T="position",S=e.x-t):(M=[k.invert(e.x),k.invert(e.x)],T="left",i.animate())}function v(e){var t,n=k(M[0]),r=k(M[1]);if(null!==T){if("left"===T)t=m(e.x,r,T),T=t.type,M=t.extent;else if("right"===T)t=m(n,e.x,T),T=t.type,M=t.extent;else{var a=r-n,o=e.x-S;M=m(o,o+a,T).extent}return i.setViewExtents(M),i.animate(),!1}return p(e,n)?O.canvas.style.cursor="ew-resize":p(e,r)?O.canvas.style.cursor="ew-resize":e.inBounds&&e.x>n&&e.x<r?O.canvas.style.cursor="move":O.canvas.style.cursor="default",!0}function b(){T=null,S=null,O.canvas.style.cursor="default"}var y=i.margin,$=80,w=10,x=!1,k=i.axes.x,C=a.scaleLinear(),M=[0,0],S=null,T=null,D=[],E=i.createCanvas(i.width,$),O=i.createCanvas(null,$,!1);O.canvas.unselectable="on",O.canvas.onselectstart=function(){return!1},O.canvas.style.userSelect="none",n.append(O.canvas),i.animateCallbacks.push(function(){f()}),O.canvas.addEventListener("mousedown",function(e){e.preventDefault(),g(d(e))}),O.canvas.addEventListener("touchstart",function(e){e.preventDefault();for(var t=0;t<e.changedTouches.length;t++){var n=e.changedTouches[t];g(d(n))}}),t.addEventListener("mousemove",function(e){v(d(e))||e.preventDefault()}),t.addEventListener("touchmove",function(e){for(var t=0;t<e.changedTouches.length;t++){var n=e.changedTouches[t];if(!v(d(n)))return void e.preventDefault()}}),t.addEventListener("mouseup",b),t.addEventListener("touchend",b),t.addEventListener("touchcancel",b),e.$on("dataLoaded",function(e,t){w=$/(t.length+1),C.domain([0,t.length]).range([0,$]),D=s(i.dataRaw);var n=i.timeExtents,r=n[0],a=n[1],o=new Date(r.getTime()+(a-r)/8);M=[r,o],i.setViewExtents(M),x=!0,u()}),e.$on("update",function(){D=s(i.dataRaw),u(),i.animate()}),e.$on("updateView",function(){M=i.viewExtents,i.animate()}),e.$on("select",function(e,t){t&&o(t.item)}),e.$on("filter",function(){x&&u()})};return{restrict:"E",require:"^timeline",scope:!0,link:n}}r.$inject=["$document","$window"];var i=e("./_index.js"),a=e("d3-scale");i.directive("timelineOverview",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js","d3-scale":"/home/stack/stackviz/node_modules/d3-scale/build/d3-scale.js"}],"/home/stack/stackviz/app/js/directives/timeline-search.js":[function(e,t,n){"use strict";function r(){var e=function(e,t){var n=this;this.open=!1,this.query="",this.showSuccess=!0,this.showSkip=!0,this.showFail=!0,this.results=[];var r=function(e){return"success"===e.status&&!n.showSuccess||"skip"===e.status&&!n.showSkip||"fail"===e.status&&!n.showFail?!1:!(e.name.toLowerCase().indexOf(n.query.toLowerCase())<0)};this.updateResults=function(){var e=t.controller("timeline");e.setFilterFunction(function(e){return r(e)});for(var n=[],i=0;i<e.dataRaw.length;i++){var a=e.dataRaw[i];if(r(a)&&(n.push(e.dataRaw[i]),n.length>25))break}this.results=n},this.select=function(e){var r=t.controller("timeline");r.selectItem(e),r.setFilterFunction(null),n.query="",n.open=!1};var i=function(e,t){e!==t&&n.updateResults()};e.$watch(function(){return n.query},i),e.$watch(function(){return n.showSuccess},i),e.$watch(function(){return n.showSkip},i),e.$watch(function(){return n.showFail},i),e.$on("dataLoaded",function(){n.updateResults()})};return e.$inject=["$scope","$element"],{restrict:"EA",require:["^timelineSearch","^timeline"],scope:!0,controller:e,controllerAs:"search",templateUrl:"directives/timeline-search.html"}}var i=e("./_index.js");i.directive("timelineSearch",r)},{"./_index.js":"/home/stack/stackviz/app/js/directives/_index.js"}],"/home/stack/stackviz/app/js/directives/timeline-viewport.js":[function(e,t,n){"use strict";function r(e,t){var n=function(e,t,n,r){function i(e){for(var t=[],n=.8*T(1),r=0;r<e.length;r++){var i=e[r],a=D(+i.startDate);t.push({x:a,y:T(i.worker),width:D(+i.endDate)-a,height:n,entry:i})}return t}function u(){H=[];var e=D(r.timeExtents[1]),t=500,n=Math.ceil(e/t),a=0;if(n>30){var o=D(r.viewExtents[0]),s=D(r.viewExtents[1]),l=o+(s-o)/2;n=50,a=Math.max(0,l-15*t)}for(var u=0;n>u;u++){var c=Math.min(e-a,t),f=D.invert(a),d=D.invert(a+c),p=r.dataInBounds(f,d),h=i(p);H.push({x:a,width:c,min:f,max:d,data:p,rects:h,c:null,dirty:!0,index:H.length}),a+=c}}function c(){H.forEach(function(e){e.dirty=!0})}function f(e,t){return H.filter(function(n){return n.x+n.width>e&&n.x<t})}function d(e){var t=D(e.startDate),n=D(e.endDate);return f(t,n)}function p(e,t){return e.rects.find(function(e){return e.entry===t})}function h(e){if(e<k.left||e>U.canvas.width-k.right)return null;var t=D(N[0])+(e-k.left);return H.find(function(e){return t>=e.x&&t<=e.x+e.width})}function m(e,t){if(t<k.top||t>U.canvas.height-k.bottom)return null;var n=h(e);if(!n)return null;for(var r=D(N[0])+(e-k.left),i=t-k.top,a=0;a<n.rects.length;a++){var o=n.rects[a];if(r>=o.x&&r<=o.x+o.width&&i>=o.y&&i<=o.y+o.height)return o}return null}function g(){R.resize(r.width+k.left+k.right),R.ctx.clearRect(0,0,R.canvas.width,R.canvas.height),R.ctx.strokeStyle="lightgray",R.ctx.textBaseline="middle",R.ctx.font="14px Arial";for(var e=T(1),t=0;t<r.data.length;t++){var n=k.top+T(t-.1);R.ctx.beginPath(),R.ctx.moveTo(k.left,n),R.ctx.lineTo(k.left+r.width,n),R.ctx.stroke(),R.ctx.fillText("Worker #"+t,5,n+e/2,k.left-10)}}function v(e,t,n){var i=e.c.ctx;t.entry===z?i.fillStyle=C.selected:t.entry===_?i.fillStyle=C.hover:i.fillStyle=C[t.entry.status],n&&i.clearRect(t.x-e.x,t.y,t.width,t.height);var a=r.filterFunction;!a||a(t.entry)?i.globalAlpha=1:i.globalAlpha=.15,i.fillRect(t.x-e.x,t.y,t.width,t.height),i.strokeRect(t.x-e.x,t.y,t.width,t.height)}function b(e){d(e).forEach(function(t){if(t.c){var n=p(t,e);n&&v(t,n,!0)}})}function y(e){if(e.dirty){e.c||(e.c=r.createCanvas(e.width,M+k.bottom));var t=e.c.ctx;t.clearRect(0,0,e.width,M),t.strokeStyle="rgb(175, 175, 175)",t.lineWidth=1;for(var n=0;n<e.rects.length;n++){var i=e.rects[n];v(e,i)}t.strokeStyle="lightgray",t.fillStyle="#888",t.font="9px sans-serif",t.textAlign="center",t.textBaseline="top",t.beginPath(),t.moveTo(0,M+.5),t.lineTo(e.width,M+.5),t.stroke();for(var a=s.scaleTime().domain([D.invert(e.x+10),D.invert(e.x+e.width-10)]),o=a.ticks(Math.floor(e.width/125)),l=0;l<o.length;l++){var u=o[l],c=Math.floor(D(u)-e.x)+.5;t.beginPath(),t.moveTo(c,M),t.lineTo(c,M+6),t.stroke(),t.fillText(A(u),c,M+7)}t.strokeStyle="rgb(175, 175, 175)",e.dirty=!1}}function $(){if(F&&F.inBounds){var e=(U.ratio,U.ctx);e.scale(U.ratio,U.ratio),e.textAlign="center",e.textBaseline="top",e.fillStyle="dimgrey",e.strokeStyle="blue",e.beginPath(),e.moveTo(F.x,k.top),e.lineTo(F.x,k.top+M),e.stroke(),e.font="9px sans-serif";var t=new Date(E.invert(F.x-k.left));if(e.fillText(O(t),F.x,16),_){var n=k.left,i=n+r.width;e.font="bold 12px sans-serif";var a=_.name.split(".").pop(),o=e.measureText(a).width,s=F.x;F.x+o/2>i?s-=F.x-(i-o/2):F.x-o/2<n&&(s+=n+o/2-F.x),e.fillText(a,s,1)}e.setTransform(1,0,0,1,0,0)}}function w(){var e=r.width+k.left+k.right;angular.element(U.canvas);U.resize(e);var t=function(e){return e*U.ratio};U.ctx.clearRect(0,0,U.canvas.width,U.canvas.height),U.ctx.drawImage(R.canvas,0,0);var n=D(N[0]),i=D(N[1]),a=f(n,i),o=0;a.forEach(function(e){o+=e.width}),o<r.width&&(u(),a=f(n,i)),a.forEach(function(e){y(e);var r=Math.max(0,n-e.x),a=Math.min(e.width,i-e.x),o=a-r;Math.max(0,n-e.x);0!==Math.floor(o)&&U.ctx.drawImage(e.c.canvas,t(r),0,Math.floor(t(o)),t(M+k.bottom),t(k.left+e.x-n+r),t(k.top),t(o),t(M+k.bottom))}),$()}function x(e){var t=U.canvas.getBoundingClientRect(),n={xRaw:e.clientX-t.left,x:e.clientX-t.left,y:e.clientY-t.top};return n.inBounds=n.x>k.left&&n.x<k.left+r.width&&n.y>k.top&&n.y<k.top+M,n}var k=r.margin,C=r.statusColorMap,M=200,S=!1,T=s.scaleLinear(),D=r.axes.absolute,E=r.axes.selection,O=l.timeFormat("%X"),A=r.axes.x.tickFormat(),N=null,j=null,L=a.easeCubicOut,P=null,I=500,F=null,z=null,_=null,R=r.createCanvas(),H=[],U=(r.createCanvas(),r.createCanvas(null,null,!1));t.append(U.canvas),r.animateCallbacks.push(function(e){if(!S)return!1;if(j){var t=N[1]-N[0],n=r.viewExtents[1]-r.viewExtents[0],i=t-n,a=e-P,o=a/I;return N=j(L(o)),Math.abs(i)>1&&u(),w(),o>=1?(P=null,j=null,!1):!0}return w(),!1}),U.canvas.addEventListener("mousedown",function(t){t.preventDefault(),F=x(t);var n=m(F.x,F.y);n&&(r.selectItem(n.entry),e.$apply())}),U.canvas.addEventListener("mousemove",function(e){F=x(e);var t=m(F.x,F.y),n=_;t&&t.entry!==_?(U.canvas.style.cursor="pointer",_=t.entry,b(t.entry),n&&b(n)):!t&&_&&(U.canvas.style.cursor="default",_=null,b(n)),r.animate()}),U.canvas.addEventListener("mouseout",function(e){F=null,U.canvas.style.cursor="default",r.animate()}),e.$on("dataLoaded",function(e,t){T.domain([0,t.length]).range([0,M]),u(),g(),S=!0}),e.$on("update",function(){S&&(u(),g(),r.animate())}),e.$on("updateViewSize",function(){S&&(N?(j=o.interpolateArray(N,r.viewExtents),P=performance.now()):(N=r.viewExtents,u()),r.animate())}),e.$on("updateViewPosition",function(){S&&(N?(j=o.interpolateArray(N,r.viewExtents),P=performance.now()):N=r.viewExtents,r.animate())}),e.$on("postSelect",function(e,t){var n=z;z=t?t.item:null,n&&b(n),z&&b(z),r.animate()}),e.$on("filter",function(){S&&(c(),r.animate())})};return{restrict:"E",require:"^timeline",scope:!0,link:n}}r.$inject=["$document","$window"];var i=e("./_index.js"),a=(e("../util/array-util"),e("d3-ease")),o=e("d3-interpolate"),s=e("d3-scale"),l=e("d3-time-format");i.directive("timelineViewport",r)},{"../util/array-util":"/home/stack/stackviz/app/js/util/array-util.js","./_index.js":"/home/stack/stackviz/app/js/directives/_index.js","d3-ease":"/home/stack/stackviz/node_modules/d3-ease/build/d3-ease.js","d3-interpolate":"/home/stack/stackviz/node_modules/d3-interpolate/build/d3-interpolate.js","d3-scale":"/home/stack/stackviz/node_modules/d3-scale/build/d3-scale.js","d3-time-format":"/home/stack/stackviz/node_modules/d3-time-format/build/d3-time-format.js"}],"/home/stack/stackviz/app/js/directives/timeline.js":[function(e,t,n){"use strict";function r(e,t,n,r){var i=function(i){var f=this;f.statusColorMap=u,f.data=[],f.dataRaw=[],f.dstat=[],f.margin={top:40,right:10,bottom:20,left:80},f.width=0,f.height=550-this.margin.top-this.margin.bottom,f.timeExtents=[0,0],f.viewExtents=[0,0],f.axes={x:l.scaleTime(),selection:l.scaleLinear(),absolute:l.scaleLinear()},f.selectionName=null,f.selection=null,f.hover=null,f.filterFunction=null,f.animateId=null,f.animateCallbacks=[],f.setViewExtents=function(e){e[0]instanceof Date&&(e[0]=+e[0]),e[1]instanceof Date&&(e[1]=+e[1]);var t=f.viewExtents[1]-f.viewExtents[0],n=e[1]-e[0];f.viewExtents=e,f.axes.selection.domain(e),f.axes.absolute.domain([+f.timeExtents[0],+f.timeExtents[0]+n]),Math.abs(t-n)>1?i.$broadcast("updateViewSize"):i.$broadcast("updateViewPosition"),i.$broadcast("updateView")},f.setHover=function(e){f.hover=e,i.hoveredItem=e},f.clearHover=function(){f.hover=null,i.hoveredItem=null},f.setSelection=function(e,t){f.selection&&f.selection.item.name===t.name?(f.selectionName=null,f.selection=null,i.selectedItem=null):(f.selectionName=t.name,f.selection={item:t,index:e},i.selectedItem=t),i.$broadcast("select",f.selection),i.$broadcast("postSelect",f.selection)},f.setFilterFunction=function(e){f.filterFunction=e,i.$broadcast("filter",e)},f.selectItem=function(e){var t=f.data[e.worker].values,n=-1;return t.forEach(function(t,r){t.name===e.name&&(n=r)}),-1===n?!1:(f.setSelection(n,e),!0)},f.selectIndex=function(e,t){var n=f.data[e].values[t];return f.setSelection(t,n),!0},f.clearSelection=function(){f.selection=null,i.$broadcast("select",null)},f.selectNextItem=function(){if(f.selection){var e=f.selection.item.worker;if(f.selection.index<f.data[e].values.length-1)return f.selectIndex(e,f.selection.index+1),!0}return!1},f.selectPreviousItem=function(){if(f.selection){var e=f.selection.item.worker;if(f.selection.index>0)return f.selectIndex(e,f.selection.index-1),!0}return!1},f.hidden=function(e){var t=f.axes.selection(e.endDate)-f.axes.selection(e.startDate),n=2>t;return e.hidden=n,n},f.dataInBounds=function(e,t){return f.dataRaw.filter(function(n){return+n.endDate>+e&&+n.startDate<+t})},f.dstatInBounds=function(e,t){var n=f.dstat.entries,r=function(e){return e.system_time};return n.slice(a.binaryMinIndex(e,n,r),a.binaryMaxIndex(t,n,r)+1)},f.createCanvas=function(t,n,r){t=t||f.width+f.margin.left+f.margin.right,n=n||200+f.margin.top+f.margin.bottom,"undefined"==typeof r&&(r=!0);var i=angular.element("<canvas>")[0];i.style.width=t+"px",i.style.height=n+"px";var a=i.getContext("2d"),o=e.devicePixelRatio||1,s=a.webkitBackingStorePixelRatio||a.mozBackingStorePixelRatio||a.msBackingStorePixelRatio||a.oBackingStorePixelRatio||a.backingStorePixelRatio||1,l=o/s;i.width=t*l,i.height=n*l,r&&a.scale(l,l);var u=function(e){i.width=e*l,i.style.width=e+"px",a.setTransform(1,0,0,1,0,0),r&&a.scale(l,l)};return{canvas:i,ctx:a,scale:r,ratio:l,resize:u}},f.animate=function(){if(!f.animateId){var e=function(t){for(var n=!1,r=0;r<f.animateCallbacks.length;r++)f.animateCallbacks[r](t)&&(n=!0);n?f.animateId=requestAnimationFrame(e):f.animateId=null};f.animateId=requestAnimationFrame(e)}};var d=function(e){f.dataRaw=e;var t=null,n=null,r=null;
e.forEach(function(e){e.worker=c(e.tags),e.startDate=new Date(e.timestamps[0]),(null===t||e.startDate<t)&&(t=e.startDate),e.endDate=new Date(e.timestamps[1]),(null===n||e.endDate>n)&&(n=e.endDate),i.preselect&&e.name===i.preselect&&(r=e)}),f.timeExtents=[t,n],f.data=s.nest().key(function(e){return e.worker}).sortKeys(function(e,t){return parseInt(e,10)-parseInt(t,10)}).entries(e.filter(function(e){return e.duration>0})),f.axes.x.domain(f.timeExtents),i.$broadcast("dataLoaded",f.data),r&&f.selectItem(r)},p=function(e){var t=f.timeExtents[0],n=f.timeExtents[1],r=function(e){return e.system_time},o=a.binaryMinIndex(t,e.entries,r),s=a.binaryMaxIndex(n,e.entries,r);0>o&&(o=0),f.dstat={entries:e.entries.slice(o,s),minimums:e.minimums,maximums:e.maximums},i.$broadcast("dstatLoaded",f.dstat)};i.$watch("artifactName",function(e){e&&(r.start({parent:"timeline .panel-body"}),n.artifact(e,"subunit").then(function(e){return r.set(.33),d(e.data),n.artifact("dstat")}).then(function(e){r.set(.66);var t=new Date(f.dataRaw[0].timestamps[0]),n=o(e.data,t.getYear());p(n)})["catch"](function(e){t.warn(e)})["finally"](function(){i.$broadcast("update"),r.done()}))}),i.$watch(function(){return f.width},function(e){f.axes.x.range([0,e]),f.axes.selection.range([0,e]),f.axes.absolute.range([0,e]),i.$broadcast("update")})};i.$inject=["$scope"];var f=function(t,n,r,i){var a=function(){var e=n[0].querySelector("div.panel div.panel-body"),t=getComputedStyle(e);i.width=e.clientWidth-i.margin.left-i.margin.right-parseFloat(t.paddingLeft)-parseFloat(t.paddingRight)};t.$on("windowResize",a),a(),e.addEventListener("keydown",function(e){37===e.keyCode&&i.selectPreviousItem(),39===e.keyCode&&i.selectNextItem(),t.$apply()})};return{controller:i,controllerAs:"timeline",restrict:"EA",transclude:!0,templateUrl:"directives/timeline.html",scope:{artifactName:"=",hoveredItem:"=",selectedItem:"=",preselect:"="},link:f}}r.$inject=["$window","$log","datasetService","progressService"];var i=e("./_index.js"),a=e("../util/array-util"),o=e("../util/dstat-parse"),s=(e("d3-array"),e("d3-collection")),l=e("d3-scale"),u={success:"LightGreen",fail:"Crimson",skip:"DodgerBlue",selected:"GoldenRod",hover:"DarkTurquoise"},c=function(e){for(var t=0;t<e.length;t++)if(e[t].startsWith("worker"))return parseInt(e[t].split("-")[1],10);return null};i.directive("timeline",r)},{"../util/array-util":"/home/stack/stackviz/app/js/util/array-util.js","../util/dstat-parse":"/home/stack/stackviz/app/js/util/dstat-parse.js","./_index.js":"/home/stack/stackviz/app/js/directives/_index.js","d3-array":"/home/stack/stackviz/node_modules/d3-array/build/d3-array.js","d3-collection":"/home/stack/stackviz/node_modules/d3-collection/build/d3-collection.js","d3-scale":"/home/stack/stackviz/node_modules/d3-scale/build/d3-scale.js"}],"/home/stack/stackviz/app/js/filters/_index.js":[function(e,t,n){"use strict";var r=e("angular");t.exports=r.module("app.filters",[]),{"bootstrap-filters":e("./bootstrap-filters.js"),"list-filters":e("./list-filters.js"),"seconds-time":e("./seconds-time.js")}},{"./bootstrap-filters.js":"/home/stack/stackviz/app/js/filters/bootstrap-filters.js","./list-filters.js":"/home/stack/stackviz/app/js/filters/list-filters.js","./seconds-time.js":"/home/stack/stackviz/app/js/filters/seconds-time.js",angular:"/home/stack/stackviz/node_modules/angular/index.js"}],"/home/stack/stackviz/app/js/filters/bootstrap-filters.js":[function(e,t,n){"use strict";var r=e("./_index.js"),i=function(e,t){var n;return e?(e=e.toLowerCase(),n="success"===e?"success":"skip"===e?"info":"fail"===e||"failure"===e?"danger":"default"):n="default",t?t+"-"+n:n},a=function(e,t){return i(e.status,t)};r.filter("contextClass",function(){return a}),r.filter("statusClass",function(){return i})},{"./_index.js":"/home/stack/stackviz/app/js/filters/_index.js"}],"/home/stack/stackviz/app/js/filters/list-filters.js":[function(e,t,n){"use strict";var r=e("./_index.js"),i=function(e,t){return"undefined"==typeof e||null===e?[]:(t=t||",",e.split(t))},a=function(e,t){return"undefined"==typeof e||null===e?"":(t=t||", ",e.join(t))},o=function(e,t){return"undefined"==typeof e||null===e?"":e[t]},s=function(e,t){return"undefined"==typeof e||null===e?"":e[e.length-t]},l=function(e,t,n){return"undefined"==typeof e||null===e?[]:e.slice(t,n)},u=function(e,t){return"undefined"==typeof e||null===e?"":(t=t||1,e.slice(0,e.length-t))},c=function(e,t){return"undefined"==typeof e||null===e?"":(t=t||1,e.slice(e.length-t,e.length))};r.filter("split",function(){return i}),r.filter("join",function(){return a}),r.filter("pick",function(){return o}),r.filter("pickRight",function(){return s}),r.filter("slice",function(){return l}),r.filter("first",function(){return u}),r.filter("last",function(){return c})},{"./_index.js":"/home/stack/stackviz/app/js/filters/_index.js"}],"/home/stack/stackviz/app/js/filters/seconds-time.js":[function(e,t,n){"use strict";var r=e("./_index.js"),i=function(e){return 10>e?"0"+e:e.toString()},a=function(e){var t=Math.floor(e/60/60);e-=60*t*60;var n=Math.floor(e/60);e=Math.floor(e-60*n);var r=i(n)+":"+i(e);return t>0&&(r=t+":"+r),r};r.filter("secondsToTime",function(){return a})},{"./_index.js":"/home/stack/stackviz/app/js/filters/_index.js"}],"/home/stack/stackviz/app/js/main.js":[function(e,t,n){"use strict";var r=e("angular");e("angular-ui-router"),e("angular-ui-bootstrap"),e("angular-fontawesome"),e("./templates"),e("./controllers/_index"),e("./services/_index"),e("./directives/_index"),e("./filters/_index");var i=["ui.router","ui.bootstrap","templates","app.controllers","app.services","app.directives","app.filters","picardy.fontawesome"];r.module("app",i),r.module("app").constant("AppSettings",e("./constants"));var a=e("./on_config");r.module("app").config(a);var o=e("./on_run");r.module("app").run(o),r.bootstrap(document,["app"],{strictDi:!0})},{"./constants":"/home/stack/stackviz/app/js/constants.js","./controllers/_index":"/home/stack/stackviz/app/js/controllers/_index.js","./directives/_index":"/home/stack/stackviz/app/js/directives/_index.js","./filters/_index":"/home/stack/stackviz/app/js/filters/_index.js","./on_config":"/home/stack/stackviz/app/js/on_config.js","./on_run":"/home/stack/stackviz/app/js/on_run.js","./services/_index":"/home/stack/stackviz/app/js/services/_index.js","./templates":"/home/stack/stackviz/app/js/templates.js",angular:"/home/stack/stackviz/node_modules/angular/index.js","angular-fontawesome":"/home/stack/stackviz/node_modules/angular-fontawesome/dist/angular-fontawesome.js","angular-ui-bootstrap":"/home/stack/stackviz/node_modules/angular-ui-bootstrap/index.js","angular-ui-router":"/home/stack/stackviz/node_modules/angular-ui-router/release/angular-ui-router.js"}],"/home/stack/stackviz/app/js/on_config.js":[function(e,t,n){"use strict";function r(e,t,n){e.state("home",{url:"/{artifactName}",params:{artifactName:null},controller:"HomeController as home",templateUrl:"home.html",title:"Home"}),e.state("timeline",{url:"/{artifactName}/timeline?test",controller:"TimelineController as timeline",templateUrl:"timeline.html",reloadOnSearch:!1,title:"Timeline"}),e.state("testDetails",{url:"/{artifactName}/test-details/{test}",controller:"TestDetailsController",controllerAs:"testDetails",templateUrl:"test-details.html",title:"Test Details"}),e.state("console",{url:"/{artifactName}/console?show",controller:"ConsoleController",controllerAs:"console",templateUrl:"console.html",title:"Console"}),n.otherwise("/")}r.$inject=["$stateProvider","$locationProvider","$urlRouterProvider"],t.exports=r},{}],"/home/stack/stackviz/app/js/on_run.js":[function(e,t,n){"use strict";function r(e,t){var n=e.$on("$stateChangeSuccess",function(n,r){e.pageTitle="",r.title&&(e.pageTitle+=r.title,e.pageTitle+=" — "),e.pageTitle+=t.appTitle});e.$on("$destroy",n)}r.$inject=["$rootScope","AppSettings"],t.exports=r},{}],"/home/stack/stackviz/app/js/services/_index.js":[function(e,t,n){"use strict";var r=e("angular");t.exports=r.module("app.services",[]),{dataset:e("./dataset.js"),progress:e("./progress.js"),summary:e("./summary.js")}},{"./dataset.js":"/home/stack/stackviz/app/js/services/dataset.js","./progress.js":"/home/stack/stackviz/app/js/services/progress.js","./summary.js":"/home/stack/stackviz/app/js/services/summary.js",angular:"/home/stack/stackviz/node_modules/angular/index.js"}],"/home/stack/stackviz/app/js/services/dataset.js":[function(e,t,n){"use strict";function r(e,t,n){var r={},i=null,a=null,o=new Map,s=!1,l=function(){var e=n.location.pathname;return i.root&&e.startsWith(i.root)&&(e=e.replace(i.root,"")),e.startsWith("/")&&(e=e.substr(1,e.length-1)),e.includes("/")&&(e=e.substring(0,e.indexOf("/"))),t({cache:!0,url:i.apiRoot+"/task",method:"POST",data:{q:e}})},u=function(e){e.forEach(function(e){o.has(e.artifact_name)?o.get(e.artifact_name).push(e):o.set(e.artifact_name,[e])})};r.config=function(){return e(function(e,n){return i?void e({config:i,datasets:a,artifacts:o}):void t({cache:!0,url:"data/config.json",method:"GET"}).then(function(t){i=t.data,i.deployer===!0?(s=!0,l().then(function(t){a=[t.data],u(t.data.artifacts),e({config:i,datasets:a,artifacts:o})},function(e){n(e)})):(a=i.datasets,i.datasets.forEach(function(e){u(e.artifacts)}),e({config:i,datasets:a,artifacts:o}))},function(e){n(e)})})},r.list=function(){return e(function(e,t){r.config().then(function(t){e(t.datasets)},t)})},r.groups=function(t){return"undefined"==typeof t&&(t=!0),e(function(e,n){r.config().then(function(n){var r=[];n.artifacts.forEach(function(e,n){t&&(e=e.filter(function(e){return e.primary})),e.length>0&&r.push(n)}),e(r)},n)})},r.get=function(t){return e(function(e,n){r.config().then(function(r){var i=r.datasets[t];i?e(i):n("Dataset not found with ID: "+t)},function(e){n(e)})})},r.artifacts=function(t){return e(function(e,n){r.config().then(function(r){if("undefined"==typeof t){var i=[];r.datasets.forEach(function(e){i.push.apply(i,e.artifacts)}),e(i)}else{var a=r.artifacts.get(t);a&&a.length>0?e(a):n("No artifacts found with name: "+t)}},n)})};var c=function(e,n,r,a){if(e){var o=null;o=s?i.apiRoot+"/blob/"+e.id:"data/"+e.path,n(t({cache:!0,url:o,method:"GET"}))}else r("No artifact found matching "+a)};return r.artifact=function(t,n){return 1===arguments.length?(n=arguments[0],e(function(e,t){r.artifacts().then(function(r){c(r.find(function(e){return e.artifact_type===n}),e,t,"type="+n)})})):e(function(e,i){r.artifacts(t).then(function(r){c(r.find(function(e){return e.artifact_type===n}),e,i,"name="+t+", type="+n)},i)})},r}r.$inject=["$q","$http","$window"];var i=e("./_index.js");i.service("datasetService",r)},{"./_index.js":"/home/stack/stackviz/app/js/services/_index.js"}],"/home/stack/stackviz/app/js/services/progress.js":[function(e,t,n){"use strict";function r(){return{start:function(e){e&&i.configure(e),i.start()},done:function(){i.done()},remove:function(){i.remove()},set:function(e){i.set(e)},inc:function(){i.inc()}}}var i=e("nprogress"),a=e("./_index.js");a.service("progressService",r)},{"./_index.js":"/home/stack/stackviz/app/js/services/_index.js",nprogress:"/home/stack/stackviz/node_modules/nprogress/nprogress.js"}],"/home/stack/stackviz/app/js/services/summary.js":[function(e,t,n){"use strict";function r(){var e=[],t={directivesForType:function(t){return e.filter(function(e){return e.artifactType===t})},mapType:function(t,n,r){"undefined"==typeof r&&(r=0),e.push({artifactType:t,directiveName:n,priority:r}),e.sort(function(e,t){return t.priority-e.priority})}};return t.mapType("subunit-stats","subunit-summary",5),t.mapType("subunit-stats","subunit-failures",4),t.mapType("console","console-summary",5),t}var i=e("./_index.js");i.service("summaryService",r)},{"./_index.js":"/home/stack/stackviz/app/js/services/_index.js"}],"/home/stack/stackviz/app/js/templates.js":[function(e,t,n){angular.module("templates",[]).run(["$templateCache",function(e){e.put("console.html",'<header class="bs-header">\n <div class="container">\n <h1 class="page-header">\n Console: {{ console.artifactName }}\n </h1>\n <ol class="breadcrumb">\n <li><a ui-sref="home">Home</a></li>\n <li>\n <a ui-sref="home({artifactName: console.artifactName})">\n {{ console.artifactName }}\n </a>\n </li>\n <li class="active">Console</li>\n </ol>\n </div>\n</header>\n\n<div class="container">\n <div class="row">\n <div class="col-lg-12">\n <codemirror-console data="console.data"\n show="console.show"></codemirror-console>\n </div>\n </div>\n</div>\n'),e.put("home.html",'\n<header class="bs-header">\n <div class="container">\n <h1 class="page-header">Datasets</h1>\n <ol class="breadcrumb">\n <li><a ui-sref="home">Home</a></li>\n <li class="active">{{ home.focus }}</li>\n </ol>\n </div>\n</header>\n\n<div class="container">\n <div class="row" ng-if="!home.groups.length">\n <div class="col-lg-12">\n <div class="alert alert-danger">\n No artifacts could be loaded!\n </div>\n </div>\n </div>\n <div class="row" ng-if="!!home.groups.length">\n <div class="col-lg-8">\n <artifact-summary artifact-name="home.focus"></artifact-summary>\n </div>\n <div class="col-lg-4" ng-if="home.groups.length > 1">\n <div class="panel panel-default">\n <div class="panel-heading">\n <h3 class="panel-title">Other Artifacts</h3>\n </div>\n\n <ul class="list-group">\n <li class="list-group-item"\n ng-repeat="group in home.groups"\n ng-if="group != home.focus"\n ng-click="home.focus = group"\n style="cursor: pointer">\n {{ group }}\n </li>\n </ul>\n </div>\n </div>\n </div>\n</div>\n'),e.put("test-details.html",'<header class="bs-header">\n <div class="container">\n <h1 class="page-header">Test Details</h1>\n <ol class="breadcrumb">\n <li><a ui-sref="home">Home</a></li>\n <li>\n <a ui-sref="home({artifactName: testDetails.artifactName})">\n {{ testDetails.artifactName }}\n </a>\n </li>\n <li class="active">Test Details: {{ testDetails.item.name | split:\'.\' | pickRight:1 }}</li>\n </ol>\n </div>\n</header>\n\n<div class="container">\n <div class="row">\n <div class="col-lg-12">\n <div class="panel panel-default">\n <div class="panel-heading">\n <h3 class="panel-title">\n {{testDetails.testName | split:\'.\' | slice:-2 | join:\'.\'}}\n <test-details-search class="pull-right" filter="testDetails.parsePythonLogging"></test-details-search>\n </h3>\n </div>\n\n <div class="panel-body">\n <uib-tabset class="nav-tabs">\n <uib-tab heading="Summary">\n <table class="table table-bordered table-hover table-striped">\n <tr>\n <td>Name</td>\n <td>{{testDetails.item.name | split:\'.\' | pickRight:1}}</td>\n <tr>\n <td>Full Name</td>\n <td><a href="{{testDetails.healthRoot}}/#/test/{{testDetails.item.name}}"\n target="_blank"\n uib-tooltip="Show in OpenStack-health">\n {{testDetails.item.name}}\n <fa name="external-link"></fa></a></td>\n </tr>\n <tr>\n <td>Status</td>\n <td>{{testDetails.item.status}}</td>\n </tr>\n <tr>\n <td>Tags</td>\n <td>{{testDetails.item.tags | join:\', \'}}</td>\n </tr>\n <tr>\n <td>Duration</td>\n <td>{{testDetails.item.duration | number:1}} seconds</td>\n </tr>\n </table>\n </uib-tab>\n <uib-tab ng-repeat="(entry,log) in testDetails.itemDetails" heading="{{entry}}">\n <pre style="height: 400px; overflow-y: scroll;">{{log}}</pre>\n </uib-tab>\n </uib-tabset>\n </div>\n\n <div class="panel-footer clearfix">\n <a class="btn btn-default pull-right"\n ui-sref="timeline({artifactName: testDetails.artifactName, test: testDetails.item.name})">\n Timeline\n </a>\n </div>\n </div>\n </div>\n </div>\n</div>\n'),e.put("timeline.html",'<header class="bs-header">\n <div class="container">\n <h1 class="page-header">\n Timeline: {{ timeline.artifactName }}\n </h1>\n <ol class="breadcrumb">\n <li><a ui-sref="home">Home</a></li>\n <li>\n <a ui-sref="home({artifactName: timeline.artifactName})">\n {{ timeline.artifactName }}\n </a>\n </li>\n <li class="active">Timeline</li>\n </ol>\n </div>\n</header>\n\n<div class="container">\n <div class="row">\n <div class="col-lg-12">\n <div class="alert alert-danger" ng-if="!!timeline.error">\n {{ timeline.error }}\n </div>\n </div>\n </div>\n <div class="row" ng-if="!timeline.error">\n <div class="col-lg-12">\n <timeline artifact-name="timeline.artifactName"\n hovered-item="timeline.hoveredItem"\n selected-item="timeline.selectedItem"\n preselect="timeline.preselect"></timeline>\n </div>\n </div>\n <div class="row">\n <div class="col-lg-12">\n <a name="details"></a>\n <timeline-details artifact-name="timeline.artifactName"\n item="timeline.selectedItem"></timeline-details>\n </div>\n </div>\n</div>\n'),e.put("directives/console-summary.html",'<div class="panel" ng-if="!!console" ng-class="console.status | statusClass:\'panel\'">\n <div class="panel-heading">\n <h3 class="panel-title">{{artifactName}}</h3>\n </div>\n <div class="panel-body">\n <div class="row">\n <div class="col-md-6 text-center">\n <span class="huge" ng-class="console.status | statusClass:\'text\'">\n {{console.status}}\n </span>\n <br>\n <span class="text-muted">status</span>\n </div>\n <div class="col-md-6 text-center">\n <span class="huge text-info" ng-if="console.remaining.length == 0">\n {{console.scripts.length}} of\n {{console.scripts.length + console.remaining.length}}\n </span>\n <span class="huge text-danger" ng-if="console.remaining.length > 0">\n {{console.scripts.length}} of\n {{console.scripts.length + console.remaining.length}}\n </span>\n <br>\n <span class="text-muted">scripts completed</span>\n </div>\n </div>\n <div class="row" ng-if="console.remaining.length > 0">\n <hr>\n <div class="col-xs-12 text-center">\n <span class="huge text-danger">\n {{console.scripts[console.scripts.length - 2].name}}\n </span>\n <br>\n <span class="text-muted">last script run</span>\n </div>\n </div>\n </div>\n <div class="panel-footer clearfix">\n <div class="btn-group pull-right">\n <a type="button"\n class="btn btn-default"\n ui-sref="console({artifactName: artifactName})">Details</a>\n </div>\n </div>\n</div>\n'),e.put("directives/subunit-failures.html",'<div class="panel panel-danger" ng-if="stats.failures.length > 0">\n <div class="panel-heading">\n <h3 class="panel-title">Failures</h3>\n </div>\n <div class="list-group">\n <a class="list-group-item"\n ng-repeat="fail in stats.failures"\n ui-sref="testDetails({artifactName: artifactName, test: fail.name})">\n <h4 class="list-group-item-heading">\n {{fail.name | split:\'.\' | slice:-2 | join:\'.\'}}\n </h4>\n <p ng-repeat="line in fail.details" class="list-group-item-text">\n {{line}}\n </p>\n </a>\n </ul>\n</div>\n'),e.put("directives/subunit-summary.html",'<div class="panel panel-default">\n <div class="panel-heading">\n <h3 class="panel-title">\n {{artifactName}}\n <span class="text-muted" style="font-size: 65%">\n {{stats.start | date:\'d MMM, yyyy\'}}\n </span>\n </h3>\n </div>\n <div class="panel-body">\n <div class="col-xs-3 text-center">\n <span class="huge">{{timeDiff | secondsToTime}}</span>\n <br>\n runtime\n </div>\n <div class="col-xs-3 text-center">\n <span class="huge">{{stats.count}}</span>\n <br>\n tests run\n </div>\n <div class="col-xs-3 text-center">\n <span class="huge text-danger">{{stats.failures.length}}</span>\n <br>\n failed\n </div>\n <div class="col-xs-3 text-center">\n <span class="huge text-primary">{{stats.skips.length}}</span>\n <br>\n skipped\n </div>\n </div>\n <div class="panel-footer clearfix">\n <div class="btn-group pull-right">\n <a type="button"\n class="btn btn-default"\n ui-sref="timeline({artifactName: artifactName})">Details</a>\n </div>\n </div>\n</div>\n'),e.put("directives/test-details-search-popover.html",'<div class="test-details-search-popover">\n\n <label>Filter pythonlogging by log level:</label>\n <div class="status-group btn-group btn-group-justified">\n <label uib-btn-checkbox\n ng-model="search.showINFO"\n class="btn btn-default">INFO</label>\n <label uib-btn-checkbox\n ng-model="search.showDEBUG"\n class="btn btn-default">DEBUG</label>\n <label uib-btn-checkbox\n ng-model="search.showWARNING"\n class="btn btn-default">WARNING</label>\n <label uib-btn-checkbox\n ng-model="search.showERROR"\n class="btn btn-default">ERROR</label>\n </div>\n\n</div>\n'),e.put("directives/test-details-search.html",'<a uib-popover-template="\'directives/test-details-search-popover.html\'"\n popover-placement="bottom-right"\n popover-title="Filter Options"\n popover-is-open="search.open">\n <fa name="search"></fa>\n <fa name="caret-down"></fa>\n</a>\n'),e.put("directives/timeline-details.html",'<div ng-if="!item" class="panel panel-default">\n <div class="panel-heading">\n <h3 class="panel-title">Test Details</h3>\n </div>\n <div class="panel-body">\n <i>Select a test above for details.</i>\n </div>\n</div>\n\n<div ng-if="!!item"\n class="panel"\n ng-class="item | contextClass:\'panel\'">\n <div class="panel-heading">\n <h3 class="panel-title">\n Details: <a href="{{healthRoot}}/#/test/{{item.name}}"\n target="_blank" uib-tooltip="Show in OpenStack-health">\n {{item.name | split:\'.\' | pickRight:1}}\n <fa name="external-link"></fa></a>\n <span class="label label-{{item | contextClass}}">\n {{item.status}}\n </span>\n &nbsp;\n <span class="label label-default"\n ng-if="item.hidden">\n hidden\n </span>\n </h3>\n </div>\n <table class="table table-bordered table-hover table-striped">\n <tr>\n <td>Class</td>\n <td>{{item.name | split:\'.\' | pickRight:2}}</td>\n <tr>\n <td>Module</td>\n <td>{{item.name | split:\'.\' | slice:0:-2 | join:\'.\'}}</td>\n </tr>\n <tr>\n <td>Tags</td>\n <td>{{item.tags | join:\', \'}}</td>\n </tr>\n <tr>\n <td>Duration</td>\n <td>{{item.duration | number:1}} seconds</td>\n </tr>\n <tr>\n <td>Start</td>\n <td>{{item.startDate | date:\'medium\'}}</td>\n </tr>\n <tr>\n <td>End</td>\n <td>{{item.endDate | date:\'medium\'}}</td>\n </tr>\n <tr ng-if="item.hidden" class="warning text-center">\n <td colspan="2">\n <fa name="exclamation-triangle"></fa>\n This test executed too quickly to be visible above.\n </td>\n </tr>\n </table>\n <div class="panel-footer clearfix">\n <div class="btn-group pull-right">\n <a type="button"\n ui-sref="testDetails({artifactName: artifactName, test: item.name})"\n class="btn btn-default">Details</a>\n </div>\n </div>\n</div>\n'),e.put("directives/timeline-search-popover.html",'<div class="timeline-search-popover">\n <label>Filter by name:</label>\n <div class="input-group">\n <span class="input-group-addon"><fa name="search"></fa></span>\n <input type="text"\n placeholder="query..."\n class="form-control"\n ng-model="search.query"\n ng-model-options="{debounce: 250}">\n </div>\n <br>\n\n <label>Filter by status:</label>\n <div class="status-group btn-group btn-group-justified">\n <label uib-btn-checkbox\n ng-model="search.showSuccess"\n class="btn btn-default">success</label>\n <label uib-btn-checkbox\n ng-model="search.showSkip"\n class="btn btn-default">skip</label>\n <label uib-btn-checkbox\n ng-model="search.showFail"\n class="btn btn-default">fail</label>\n </div>\n <br>\n\n <div class="jump-group">\n <label>Jump to:</label>\n <ul class="list-group">\n <li ng-repeat="item in search.results"\n class="list-group-item"\n ng-class="item | contextClass:\'list-group-item\'"\n ng-click="search.select(item)">\n {{item.name | split:\'.\' | pickRight:1}}\n </li>\n </ul>\n </div>\n</div>\n'),e.put("directives/timeline-search.html",'<a uib-popover-template="\'directives/timeline-search-popover.html\'"\n popover-placement="bottom-right"\n popover-title="Filter Options"\n popover-is-open="search.open">\n <fa name="search"></fa>\n <fa name="caret-down"></fa>\n</a>\n'),e.put("directives/timeline.html",'<div class="panel panel-default">\n <div class="panel-heading">\n <h3 class="panel-title">\n Timeline\n <timeline-search class="pull-right"></timeline-search>\n </h3>\n </div>\n <div class="panel-body">\n <timeline-viewport></timeline-viewport>\n <timeline-dstat></timeline-dstat>\n <timeline-overview></timeline-overview>\n </div>\n</div>\n')}])},{}],"/home/stack/stackviz/app/js/util/array-util.js":[function(e,t,n){"use strict";var r=function(e,t,n){for(var r=0,i=t.length-1;i>r;){var a=Math.floor((r+i)/2);e<n(t[a])?i=a-1:e>n(t[a])?r=a+1:i=a}return r>=t.length?t.length-1:n(t[r])<=e?r:r-1},i=function(e,t,n){for(var r=0,i=t.length-1;i>r;){var a=Math.floor((r+i)/2);e<n(t[a])?i=a-1:e>n(t[a])?r=a+1:i=a}return 0>i?0:n(t[i])<=e?i+1:i};t.exports={binaryMinIndex:r,binaryMaxIndex:i}},{}],"/home/stack/stackviz/app/js/util/dstat-parse.js":[function(e,t,n){"use strict";var r=e("d3-time-format"),i=e("d3-dsv"),a=function(e){for(var t=0;t<e.length-1;t++)e[t+1]||(e[t+1]=e[t])},o=function(e,t){for(var n=[],r=0;r<e.length;r++)n.push((e[r]+"_"+t[r]).replace(/[ \/]/g,"_"));return n},s=function(e,t){var n=null,s=null,l=null,u={},c={},f=r.utcParse("%d-%m %H:%M:%S"),d=i.csvParseRows(e,function(e,r){if(0!==r){if(4>=r)return null;if(5===r)return n=e,a(n),null;if(6===r)return s=e,l=o(n,s),null;for(var i={},d=0;d<e.length;d++){var p=l[d],h=e[d];h&&p&&("system_time"===p?(h=f(h),h.setFullYear(1900+t)):h=parseFloat(h),p in u&&!(h<u[p])||(u[p]=h),p in c&&!(h>c[p])||(c[p]=h),i[p]=h)}return i}if(1!==e.length||!e[0].startsWith("Dstat")||!e[0].endsWith("CSV output"))throw new Error("Invalid Dstat CSV")});return{minimums:u,maximums:c,entries:d}};t.exports=s},{"d3-dsv":"/home/stack/stackviz/node_modules/d3-dsv/build/d3-dsv.js","d3-time-format":"/home/stack/stackviz/node_modules/d3-time-format/build/d3-time-format.js"}],"/home/stack/stackviz/node_modules/angular-fontawesome/dist/angular-fontawesome.js":[function(e,t,n){angular.module("picardy.fontawesome",[]).directive("fa",function(){return{restrict:"E",template:'<i class="fa"></i>',replace:!0,link:function(e,t,n){function r(e,r){n.$observe(e,function(){if(r=r||"fa-"+e,t.removeClass(a[e]),n[e]){var i=[r,n[e]].join("-");t.addClass(i),a[e]=i}})}function i(e,r){n.$observe(e,function(){r=r||"fa-"+e;var i=e in n&&"false"!==n[e]&&n[e]!==!1;t.toggleClass(r,i)})}var a={};r("name","fa"),r("rotate"),r("flip"),r("stack"),n.$observe("size",function(){var e;t.removeClass(a.size),"large"===n.size?e="fa-lg":isNaN(parseInt(n.size,10))||(e="fa-"+n.size+"x"),t.addClass(e),a.size=e}),n.$observe("stack",function(){var e;t.removeClass(a.stack),"large"===n.stack?e="fa-stack-lg":isNaN(parseInt(n.stack,10))||(e="fa-stack-"+n.stack+"x"),t.addClass(e),a.stack=e}),i("border"),i("fw"),i("inverse"),i("spin"),t.toggleClass("fa-li",t.parent()&&t.parent().parent()&&t.parent().parent().hasClass("fa-ul")&&t.parent().children()[0]===t[0]&&"false"!==n.list&&n.list!==!1)}}}).directive("faStack",function(){return{restrict:"E",transclude:!0,template:'<span ng-transclude class="fa-stack fa-lg"></span>',replace:!0,link:function(e,t,n){function r(e,r){n.$observe(e,function(){if(r=r||"fa-"+e,t.removeClass(i[e]),n[e]){var a=[r,n[e]].join("-");t.addClass(a),i[e]=a}})}var i={};r("size"),n.$observe("size",function(){var e;t.removeClass(i.size),"large"===n.size?e="fa-lg":isNaN(parseInt(n.size,10))||(e="fa-"+n.size+"x"),t.addClass(e),i.size=e})}}})},{}],"/home/stack/stackviz/node_modules/angular-ui-bootstrap/dist/ui-bootstrap-tpls.js":[function(e,t,n){angular.module("ui.bootstrap",["ui.bootstrap.tpls","ui.bootstrap.collapse","ui.bootstrap.accordion","ui.bootstrap.alert","ui.bootstrap.buttons","ui.bootstrap.carousel","ui.bootstrap.dateparser","ui.bootstrap.isClass","ui.bootstrap.position","ui.bootstrap.datepicker","ui.bootstrap.debounce","ui.bootstrap.dropdown","ui.bootstrap.stackedMap","ui.bootstrap.modal","ui.bootstrap.paging","ui.bootstrap.pager","ui.bootstrap.pagination","ui.bootstrap.tooltip","ui.bootstrap.popover","ui.bootstrap.progressbar","ui.bootstrap.rating","ui.bootstrap.tabs","ui.bootstrap.timepicker","ui.bootstrap.typeahead"]),angular.module("ui.bootstrap.tpls",["uib/template/accordion/accordion-group.html","uib/template/accordion/accordion.html","uib/template/alert/alert.html","uib/template/carousel/carousel.html","uib/template/carousel/slide.html","uib/template/datepicker/datepicker.html","uib/template/datepicker/day.html","uib/template/datepicker/month.html","uib/template/datepicker/popup.html","uib/template/datepicker/year.html","uib/template/modal/backdrop.html","uib/template/modal/window.html","uib/template/pager/pager.html","uib/template/pagination/pagination.html","uib/template/tooltip/tooltip-html-popup.html","uib/template/tooltip/tooltip-popup.html","uib/template/tooltip/tooltip-template-popup.html","uib/template/popover/popover-html.html","uib/template/popover/popover-template.html","uib/template/popover/popover.html","uib/template/progressbar/bar.html","uib/template/progressbar/progress.html","uib/template/progressbar/progressbar.html","uib/template/rating/rating.html","uib/template/tabs/tab.html","uib/template/tabs/tabset.html","uib/template/timepicker/timepicker.html","uib/template/typeahead/typeahead-match.html","uib/template/typeahead/typeahead-popup.html"]),
angular.module("ui.bootstrap.collapse",[]).directive("uibCollapse",["$animate","$q","$parse","$injector",function(e,t,n,r){var i=r.has("$animateCss")?r.get("$animateCss"):null;return{link:function(r,a,o){function s(){a.hasClass("collapse")&&a.hasClass("in")||t.resolve(f(r)).then(function(){a.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),i?i(a,{addClass:"in",easing:"ease",to:{height:a[0].scrollHeight+"px"}}).start()["finally"](l):e.addClass(a,"in",{to:{height:a[0].scrollHeight+"px"}}).then(l)})}function l(){a.removeClass("collapsing").addClass("collapse").css({height:"auto"}),d(r)}function u(){return a.hasClass("collapse")||a.hasClass("in")?void t.resolve(p(r)).then(function(){a.css({height:a[0].scrollHeight+"px"}).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),i?i(a,{removeClass:"in",to:{height:"0"}}).start()["finally"](c):e.removeClass(a,"in",{to:{height:"0"}}).then(c)}):c()}function c(){a.css({height:"0"}),a.removeClass("collapsing").addClass("collapse"),h(r)}var f=n(o.expanding),d=n(o.expanded),p=n(o.collapsing),h=n(o.collapsed);r.$eval(o.uibCollapse)||a.addClass("in").addClass("collapse").attr("aria-expanded",!0).attr("aria-hidden",!1).css({height:"auto"}),r.$watch(o.uibCollapse,function(e){e?u():s()})}}}]),angular.module("ui.bootstrap.accordion",["ui.bootstrap.collapse"]).constant("uibAccordionConfig",{closeOthers:!0}).controller("UibAccordionController",["$scope","$attrs","uibAccordionConfig",function(e,t,n){this.groups=[],this.closeOthers=function(r){var i=angular.isDefined(t.closeOthers)?e.$eval(t.closeOthers):n.closeOthers;i&&angular.forEach(this.groups,function(e){e!==r&&(e.isOpen=!1)})},this.addGroup=function(e){var t=this;this.groups.push(e),e.$on("$destroy",function(n){t.removeGroup(e)})},this.removeGroup=function(e){var t=this.groups.indexOf(e);-1!==t&&this.groups.splice(t,1)}}]).directive("uibAccordion",function(){return{controller:"UibAccordionController",controllerAs:"accordion",transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/accordion/accordion.html"}}}).directive("uibAccordionGroup",function(){return{require:"^uibAccordion",transclude:!0,replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/accordion/accordion-group.html"},scope:{heading:"@",panelClass:"@?",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(e){this.heading=e}},link:function(e,t,n,r){r.addGroup(e),e.openClass=n.openClass||"panel-open",e.panelClass=n.panelClass||"panel-default",e.$watch("isOpen",function(n){t.toggleClass(e.openClass,!!n),n&&r.closeOthers(e)}),e.toggleOpen=function(t){e.isDisabled||t&&32!==t.which||(e.isOpen=!e.isOpen)};var i="accordiongroup-"+e.$id+"-"+Math.floor(1e4*Math.random());e.headingId=i+"-tab",e.panelId=i+"-panel"}}}).directive("uibAccordionHeading",function(){return{transclude:!0,template:"",replace:!0,require:"^uibAccordionGroup",link:function(e,t,n,r,i){r.setHeading(i(e,angular.noop))}}}).directive("uibAccordionTransclude",function(){return{require:"^uibAccordionGroup",link:function(e,t,n,r){e.$watch(function(){return r[n.uibAccordionTransclude]},function(e){if(e){var n=angular.element(t[0].querySelector("[uib-accordion-header]"));n.html(""),n.append(e)}})}}}),angular.module("ui.bootstrap.alert",[]).controller("UibAlertController",["$scope","$attrs","$interpolate","$timeout",function(e,t,n,r){e.closeable=!!t.close;var i=angular.isDefined(t.dismissOnTimeout)?n(t.dismissOnTimeout)(e.$parent):null;i&&r(function(){e.close()},parseInt(i,10))}]).directive("uibAlert",function(){return{controller:"UibAlertController",controllerAs:"alert",templateUrl:function(e,t){return t.templateUrl||"uib/template/alert/alert.html"},transclude:!0,replace:!0,scope:{type:"@",close:"&"}}}),angular.module("ui.bootstrap.buttons",[]).constant("uibButtonConfig",{activeClass:"active",toggleEvent:"click"}).controller("UibButtonsController",["uibButtonConfig",function(e){this.activeClass=e.activeClass||"active",this.toggleEvent=e.toggleEvent||"click"}]).directive("uibBtnRadio",["$parse",function(e){return{require:["uibBtnRadio","ngModel"],controller:"UibButtonsController",controllerAs:"buttons",link:function(t,n,r,i){var a=i[0],o=i[1],s=e(r.uibUncheckable);n.find("input").css({display:"none"}),o.$render=function(){n.toggleClass(a.activeClass,angular.equals(o.$modelValue,t.$eval(r.uibBtnRadio)))},n.on(a.toggleEvent,function(){if(!r.disabled){var e=n.hasClass(a.activeClass);e&&!angular.isDefined(r.uncheckable)||t.$apply(function(){o.$setViewValue(e?null:t.$eval(r.uibBtnRadio)),o.$render()})}}),r.uibUncheckable&&t.$watch(s,function(e){r.$set("uncheckable",e?"":void 0)})}}}]).directive("uibBtnCheckbox",function(){return{require:["uibBtnCheckbox","ngModel"],controller:"UibButtonsController",controllerAs:"button",link:function(e,t,n,r){function i(){return o(n.btnCheckboxTrue,!0)}function a(){return o(n.btnCheckboxFalse,!1)}function o(t,n){return angular.isDefined(t)?e.$eval(t):n}var s=r[0],l=r[1];t.find("input").css({display:"none"}),l.$render=function(){t.toggleClass(s.activeClass,angular.equals(l.$modelValue,i()))},t.on(s.toggleEvent,function(){n.disabled||e.$apply(function(){l.$setViewValue(t.hasClass(s.activeClass)?a():i()),l.$render()})})}}}),angular.module("ui.bootstrap.carousel",[]).controller("UibCarouselController",["$scope","$element","$interval","$timeout","$animate",function(e,t,n,r,i){function a(){for(;y.length;)y.shift()}function o(e){for(var t=0;t<g.length;t++)g[t].slide.active=t===e}function s(n,r,l){if(!$){if(angular.extend(n,{direction:l}),angular.extend(g[b].slide||{},{direction:l}),i.enabled(t)&&!e.$currentTransition&&g[r].element&&m.slides.length>1){g[r].element.data(v,n.direction);var u=m.getCurrentIndex();angular.isNumber(u)&&g[u].element&&g[u].element.data(v,n.direction),e.$currentTransition=!0,i.on("addClass",g[r].element,function(t,n){if("close"===n&&(e.$currentTransition=null,i.off("addClass",t),y.length)){var r=y.pop().slide,o=r.index,l=o>m.getCurrentIndex()?"next":"prev";a(),s(r,o,l)}})}e.active=n.index,b=n.index,o(r),f()}}function l(e){for(var t=0;t<g.length;t++)if(g[t].slide===e)return t}function u(){p&&(n.cancel(p),p=null)}function c(t){t.length||(e.$currentTransition=null,a())}function f(){u();var t=+e.interval;!isNaN(t)&&t>0&&(p=n(d,t))}function d(){var t=+e.interval;h&&!isNaN(t)&&t>0&&g.length?e.next():e.pause()}var p,h,m=this,g=m.slides=e.slides=[],v="uib-slideDirection",b=e.active,y=[],$=!1;m.addSlide=function(t,n){g.push({slide:t,element:n}),g.sort(function(e,t){return+e.slide.index>+t.slide.index}),(t.index===e.active||1===g.length&&!angular.isNumber(e.active))&&(e.$currentTransition&&(e.$currentTransition=null),b=t.index,e.active=t.index,o(b),m.select(g[l(t)]),1===g.length&&e.play())},m.getCurrentIndex=function(){for(var e=0;e<g.length;e++)if(g[e].slide.index===b)return e},m.next=e.next=function(){var t=(m.getCurrentIndex()+1)%g.length;return 0===t&&e.noWrap()?void e.pause():m.select(g[t],"next")},m.prev=e.prev=function(){var t=m.getCurrentIndex()-1<0?g.length-1:m.getCurrentIndex()-1;return e.noWrap()&&t===g.length-1?void e.pause():m.select(g[t],"prev")},m.removeSlide=function(t){var n=l(t),r=y.indexOf(g[n]);-1!==r&&y.splice(r,1),g.splice(n,1),g.length>0&&b===n?n>=g.length?(b=g.length-1,e.active=b,o(b),m.select(g[g.length-1])):(b=n,e.active=b,o(b),m.select(g[n])):b>n&&(b--,e.active=b),0===g.length&&(b=null,e.active=null,a())},m.select=e.select=function(t,n){var r=l(t.slide);void 0===n&&(n=r>m.getCurrentIndex()?"next":"prev"),t.slide.index===b||e.$currentTransition?t&&t.slide.index!==b&&e.$currentTransition&&y.push(g[r]):s(t.slide,r,n)},e.indexOfSlide=function(e){return+e.slide.index},e.isActive=function(t){return e.active===t.slide.index},e.pause=function(){e.noPause||(h=!1,u())},e.play=function(){h||(h=!0,f())},e.$on("$destroy",function(){$=!0,u()}),e.$watch("noTransition",function(e){i.enabled(t,!e)}),e.$watch("interval",f),e.$watchCollection("slides",c),e.$watch("active",function(e){if(angular.isNumber(e)&&b!==e){for(var t=0;t<g.length;t++)if(g[t].slide.index===e){e=t;break}var n=g[e];n&&(b=e,o(e),m.select(g[e]))}})}]).directive("uibCarousel",function(){return{transclude:!0,replace:!0,controller:"UibCarouselController",controllerAs:"carousel",templateUrl:function(e,t){return t.templateUrl||"uib/template/carousel/carousel.html"},scope:{active:"=",interval:"=",noTransition:"=",noPause:"=",noWrap:"&"}}}).directive("uibSlide",function(){return{require:"^uibCarousel",transclude:!0,replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/carousel/slide.html"},scope:{actual:"=?",index:"=?"},link:function(e,t,n,r){r.addSlide(e,t),e.$on("$destroy",function(){r.removeSlide(e)})}}}).animation(".item",["$animateCss",function(e){function t(e,t,n){e.removeClass(t),n&&n()}var n="uib-slideDirection";return{beforeAddClass:function(r,i,a){if("active"===i){var o=!1,s=r.data(n),l="next"===s?"left":"right",u=t.bind(this,r,l+" "+s,a);return r.addClass(s),e(r,{addClass:l}).start().done(u),function(){o=!0}}a()},beforeRemoveClass:function(r,i,a){if("active"===i){var o=!1,s=r.data(n),l="next"===s?"left":"right",u=t.bind(this,r,l,a);return e(r,{addClass:l}).start().done(u),function(){o=!0}}a()}}}]),angular.module("ui.bootstrap.dateparser",[]).service("uibDateParser",["$log","$locale","dateFilter","orderByFilter",function(e,t,n,r){function i(e,t){var n=[],i=e.split(""),a=e.indexOf("'");if(a>-1){var o=!1;e=e.split("");for(var s=a;s<e.length;s++)o?("'"===e[s]&&(s+1<e.length&&"'"===e[s+1]?(e[s+1]="$",i[s+1]=""):(i[s]="",o=!1)),e[s]="$"):"'"===e[s]&&(e[s]="$",i[s]="",o=!0);e=e.join("")}return angular.forEach(p,function(r){var a=e.indexOf(r.key);if(a>-1){e=e.split(""),i[a]="("+r.regex+")",e[a]="$";for(var o=a+1,s=a+r.key.length;s>o;o++)i[o]="",e[o]="$";e=e.join(""),n.push({index:a,key:r.key,apply:r[t],matcher:r.regex})}}),{regex:new RegExp("^"+i.join("")+"$"),map:r(n,"index")}}function a(e,t,n){return 1>n?!1:1===t&&n>28?29===n&&(e%4===0&&e%100!==0||e%400===0):3===t||5===t||8===t||10===t?31>n:!0}function o(e){return parseInt(e,10)}function s(e,t){return e&&t?f(e,t):e}function l(e,t){return e&&t?f(e,t,!0):e}function u(e,t){var n=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(n)?t:n}function c(e,t){return e=new Date(e.getTime()),e.setMinutes(e.getMinutes()+t),e}function f(e,t,n){n=n?-1:1;var r=u(t,e.getTimezoneOffset());return c(e,n*(r-e.getTimezoneOffset()))}var d,p,h=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g;this.init=function(){d=t.id,this.parsers={},this.formatters={},p=[{key:"yyyy",regex:"\\d{4}",apply:function(e){this.year=+e},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),n(t,"yyyy")}},{key:"yy",regex:"\\d{2}",apply:function(e){this.year=+e+2e3},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),n(t,"yy")}},{key:"y",regex:"\\d{1,4}",apply:function(e){this.year=+e},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),n(t,"y")}},{key:"M!",regex:"0?[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){var t=e.getMonth();return/^[0-9]$/.test(t)?n(e,"MM"):n(e,"M")}},{key:"MMMM",regex:t.DATETIME_FORMATS.MONTH.join("|"),apply:function(e){this.month=t.DATETIME_FORMATS.MONTH.indexOf(e)},formatter:function(e){return n(e,"MMMM")}},{key:"MMM",regex:t.DATETIME_FORMATS.SHORTMONTH.join("|"),apply:function(e){this.month=t.DATETIME_FORMATS.SHORTMONTH.indexOf(e)},formatter:function(e){return n(e,"MMM")}},{key:"MM",regex:"0[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){return n(e,"MM")}},{key:"M",regex:"[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){return n(e,"M")}},{key:"d!",regex:"[0-2]?[0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){var t=e.getDate();return/^[1-9]$/.test(t)?n(e,"dd"):n(e,"d")}},{key:"dd",regex:"[0-2][0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){return n(e,"dd")}},{key:"d",regex:"[1-2]?[0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){return n(e,"d")}},{key:"EEEE",regex:t.DATETIME_FORMATS.DAY.join("|"),formatter:function(e){return n(e,"EEEE")}},{key:"EEE",regex:t.DATETIME_FORMATS.SHORTDAY.join("|"),formatter:function(e){return n(e,"EEE")}},{key:"HH",regex:"(?:0|1)[0-9]|2[0-3]",apply:function(e){this.hours=+e},formatter:function(e){return n(e,"HH")}},{key:"hh",regex:"0[0-9]|1[0-2]",apply:function(e){this.hours=+e},formatter:function(e){return n(e,"hh")}},{key:"H",regex:"1?[0-9]|2[0-3]",apply:function(e){this.hours=+e},formatter:function(e){return n(e,"H")}},{key:"h",regex:"[0-9]|1[0-2]",apply:function(e){this.hours=+e},formatter:function(e){return n(e,"h")}},{key:"mm",regex:"[0-5][0-9]",apply:function(e){this.minutes=+e},formatter:function(e){return n(e,"mm")}},{key:"m",regex:"[0-9]|[1-5][0-9]",apply:function(e){this.minutes=+e},formatter:function(e){return n(e,"m")}},{key:"sss",regex:"[0-9][0-9][0-9]",apply:function(e){this.milliseconds=+e},formatter:function(e){return n(e,"sss")}},{key:"ss",regex:"[0-5][0-9]",apply:function(e){this.seconds=+e},formatter:function(e){return n(e,"ss")}},{key:"s",regex:"[0-9]|[1-5][0-9]",apply:function(e){this.seconds=+e},formatter:function(e){return n(e,"s")}},{key:"a",regex:t.DATETIME_FORMATS.AMPMS.join("|"),apply:function(e){12===this.hours&&(this.hours=0),"PM"===e&&(this.hours+=12)},formatter:function(e){return n(e,"a")}},{key:"Z",regex:"[+-]\\d{4}",apply:function(e){var t=e.match(/([+-])(\d{2})(\d{2})/),n=t[1],r=t[2],i=t[3];this.hours+=o(n+r),this.minutes+=o(n+i)},formatter:function(e){return n(e,"Z")}},{key:"ww",regex:"[0-4][0-9]|5[0-3]",formatter:function(e){return n(e,"ww")}},{key:"w",regex:"[0-9]|[1-4][0-9]|5[0-3]",formatter:function(e){return n(e,"w")}},{key:"GGGG",regex:t.DATETIME_FORMATS.ERANAMES.join("|").replace(/\s/g,"\\s"),formatter:function(e){return n(e,"GGGG")}},{key:"GGG",regex:t.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return n(e,"GGG")}},{key:"GG",regex:t.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return n(e,"GG")}},{key:"G",regex:t.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return n(e,"G")}}]},this.init(),this.filter=function(e,n){if(!angular.isDate(e)||isNaN(e)||!n)return"";n=t.DATETIME_FORMATS[n]||n,t.id!==d&&this.init(),this.formatters[n]||(this.formatters[n]=i(n,"formatter"));var r=this.formatters[n],a=r.map,o=n;return a.reduce(function(t,n,r){var i=o.match(new RegExp("(.*)"+n.key));i&&angular.isString(i[1])&&(t+=i[1],o=o.replace(i[1]+n.key,""));var s=r===a.length-1?o:"";return n.apply?t+n.apply.call(null,e)+s:t+s},"")},this.parse=function(n,r,o){if(!angular.isString(n)||!r)return n;r=t.DATETIME_FORMATS[r]||r,r=r.replace(h,"\\$&"),t.id!==d&&this.init(),this.parsers[r]||(this.parsers[r]=i(r,"apply"));var s=this.parsers[r],l=s.regex,u=s.map,c=n.match(l),f=!1;if(c&&c.length){var p,m;angular.isDate(o)&&!isNaN(o.getTime())?p={year:o.getFullYear(),month:o.getMonth(),date:o.getDate(),hours:o.getHours(),minutes:o.getMinutes(),seconds:o.getSeconds(),milliseconds:o.getMilliseconds()}:(o&&e.warn("dateparser:","baseDate is not a valid date"),p={year:1900,month:0,date:1,hours:0,minutes:0,seconds:0,milliseconds:0});for(var g=1,v=c.length;v>g;g++){var b=u[g-1];"Z"===b.matcher&&(f=!0),b.apply&&b.apply.call(p,c[g])}var y=f?Date.prototype.setUTCFullYear:Date.prototype.setFullYear,$=f?Date.prototype.setUTCHours:Date.prototype.setHours;return a(p.year,p.month,p.date)&&(!angular.isDate(o)||isNaN(o.getTime())||f?(m=new Date(0),y.call(m,p.year,p.month,p.date),$.call(m,p.hours||0,p.minutes||0,p.seconds||0,p.milliseconds||0)):(m=new Date(o),y.call(m,p.year,p.month,p.date),$.call(m,p.hours,p.minutes,p.seconds,p.milliseconds))),m}},this.toTimezone=s,this.fromTimezone=l,this.timezoneToOffset=u,this.addDateMinutes=c,this.convertTimezoneToLocal=f}]),angular.module("ui.bootstrap.isClass",[]).directive("uibIsClass",["$animate",function(e){var t=/^\s*([\s\S]+?)\s+on\s+([\s\S]+?)\s*$/,n=/^\s*([\s\S]+?)\s+for\s+([\s\S]+?)\s*$/;return{restrict:"A",compile:function(r,i){function a(e,t,n){l.push(e),u.push({scope:e,element:t}),h.forEach(function(t,n){o(t,e)}),e.$on("$destroy",s)}function o(t,r){var i=t.match(n),a=r.$eval(i[1]),o=i[2],s=c[t];if(!s){var l=function(t){var n=null;u.some(function(e){var r=e.scope.$eval(d);return r===t?(n=e,!0):void 0}),s.lastActivated!==n&&(s.lastActivated&&e.removeClass(s.lastActivated.element,a),n&&e.addClass(n.element,a),s.lastActivated=n)};c[t]=s={lastActivated:null,scope:r,watchFn:l,compareWithExp:o,watcher:r.$watch(o,l)}}s.watchFn(r.$eval(o))}function s(e){var t=e.targetScope,n=l.indexOf(t);if(l.splice(n,1),u.splice(n,1),l.length){var r=l[0];angular.forEach(c,function(e){e.scope===t&&(e.watcher=r.$watch(e.compareWithExp,e.watchFn),e.scope=r)})}else c={}}var l=[],u=[],c={},f=i.uibIsClass.match(t),d=f[2],p=f[1],h=p.split(",");return a}}}]),angular.module("ui.bootstrap.position",[]).factory("$uibPosition",["$document","$window",function(e,t){var n,r={normal:/(auto|scroll)/,hidden:/(auto|scroll|hidden)/},i={auto:/\s?auto?\s?/i,primary:/^(top|bottom|left|right)$/,secondary:/^(top|bottom|left|right|center)$/,vertical:/^(top|bottom)$/};return{getRawNode:function(e){return e.nodeName?e:e[0]||e},parseStyle:function(e){return e=parseFloat(e),isFinite(e)?e:0},offsetParent:function(n){function r(e){return"static"===(t.getComputedStyle(e).position||"static")}n=this.getRawNode(n);for(var i=n.offsetParent||e[0].documentElement;i&&i!==e[0].documentElement&&r(i);)i=i.offsetParent;return i||e[0].documentElement},scrollbarWidth:function(){if(angular.isUndefined(n)){var t=angular.element('<div class="uib-position-scrollbar-measure"></div>');e.find("body").append(t),n=t[0].offsetWidth-t[0].clientWidth,n=isFinite(n)?n:0,t.remove()}return n},isScrollable:function(e,n){e=this.getRawNode(e);var i=n?r.hidden:r.normal,a=t.getComputedStyle(e);return i.test(a.overflow+a.overflowY+a.overflowX)},scrollParent:function(n,i){n=this.getRawNode(n);var a=i?r.hidden:r.normal,o=e[0].documentElement,s=t.getComputedStyle(n),l="absolute"===s.position,u=n.parentElement||o;if(u===o||"fixed"===s.position)return o;for(;u.parentElement&&u!==o;){var c=t.getComputedStyle(u);if(l&&"static"!==c.position&&(l=!1),!l&&a.test(c.overflow+c.overflowY+c.overflowX))break;u=u.parentElement}return u},position:function(n,r){n=this.getRawNode(n);var i=this.offset(n);if(r){var a=t.getComputedStyle(n);i.top-=this.parseStyle(a.marginTop),i.left-=this.parseStyle(a.marginLeft)}var o=this.offsetParent(n),s={top:0,left:0};return o!==e[0].documentElement&&(s=this.offset(o),s.top+=o.clientTop-o.scrollTop,s.left+=o.clientLeft-o.scrollLeft),{width:Math.round(angular.isNumber(i.width)?i.width:n.offsetWidth),height:Math.round(angular.isNumber(i.height)?i.height:n.offsetHeight),top:Math.round(i.top-s.top),left:Math.round(i.left-s.left)}},offset:function(n){n=this.getRawNode(n);var r=n.getBoundingClientRect();return{width:Math.round(angular.isNumber(r.width)?r.width:n.offsetWidth),height:Math.round(angular.isNumber(r.height)?r.height:n.offsetHeight),top:Math.round(r.top+(t.pageYOffset||e[0].documentElement.scrollTop)),left:Math.round(r.left+(t.pageXOffset||e[0].documentElement.scrollLeft))}},viewportOffset:function(n,r,i){n=this.getRawNode(n),i=i!==!1;var a=n.getBoundingClientRect(),o={top:0,left:0,bottom:0,right:0},s=r?e[0].documentElement:this.scrollParent(n),l=s.getBoundingClientRect();if(o.top=l.top+s.clientTop,o.left=l.left+s.clientLeft,s===e[0].documentElement&&(o.top+=t.pageYOffset,o.left+=t.pageXOffset),o.bottom=o.top+s.clientHeight,o.right=o.left+s.clientWidth,i){var u=t.getComputedStyle(s);o.top+=this.parseStyle(u.paddingTop),o.bottom-=this.parseStyle(u.paddingBottom),o.left+=this.parseStyle(u.paddingLeft),o.right-=this.parseStyle(u.paddingRight)}return{top:Math.round(a.top-o.top),bottom:Math.round(o.bottom-a.bottom),left:Math.round(a.left-o.left),right:Math.round(o.right-a.right)}},parsePlacement:function(e){var t=i.auto.test(e);return t&&(e=e.replace(i.auto,"")),e=e.split("-"),e[0]=e[0]||"top",i.primary.test(e[0])||(e[0]="top"),e[1]=e[1]||"center",i.secondary.test(e[1])||(e[1]="center"),t?e[2]=!0:e[2]=!1,e},positionElements:function(e,n,r,a){e=this.getRawNode(e),n=this.getRawNode(n);var o=angular.isDefined(n.offsetWidth)?n.offsetWidth:n.prop("offsetWidth"),s=angular.isDefined(n.offsetHeight)?n.offsetHeight:n.prop("offsetHeight");r=this.parsePlacement(r);var l=a?this.offset(e):this.position(e),u={top:0,left:0,placement:""};if(r[2]){var c=this.viewportOffset(e,a),f=t.getComputedStyle(n),d={width:o+Math.round(Math.abs(this.parseStyle(f.marginLeft)+this.parseStyle(f.marginRight))),height:s+Math.round(Math.abs(this.parseStyle(f.marginTop)+this.parseStyle(f.marginBottom)))};if(r[0]="top"===r[0]&&d.height>c.top&&d.height<=c.bottom?"bottom":"bottom"===r[0]&&d.height>c.bottom&&d.height<=c.top?"top":"left"===r[0]&&d.width>c.left&&d.width<=c.right?"right":"right"===r[0]&&d.width>c.right&&d.width<=c.left?"left":r[0],r[1]="top"===r[1]&&d.height-l.height>c.bottom&&d.height-l.height<=c.top?"bottom":"bottom"===r[1]&&d.height-l.height>c.top&&d.height-l.height<=c.bottom?"top":"left"===r[1]&&d.width-l.width>c.right&&d.width-l.width<=c.left?"right":"right"===r[1]&&d.width-l.width>c.left&&d.width-l.width<=c.right?"left":r[1],"center"===r[1])if(i.vertical.test(r[0])){var p=l.width/2-o/2;c.left+p<0&&d.width-l.width<=c.right?r[1]="left":c.right+p<0&&d.width-l.width<=c.left&&(r[1]="right")}else{var h=l.height/2-d.height/2;c.top+h<0&&d.height-l.height<=c.bottom?r[1]="top":c.bottom+h<0&&d.height-l.height<=c.top&&(r[1]="bottom")}}switch(r[0]){case"top":u.top=l.top-s;break;case"bottom":u.top=l.top+l.height;break;case"left":u.left=l.left-o;break;case"right":u.left=l.left+l.width}switch(r[1]){case"top":u.top=l.top;break;case"bottom":u.top=l.top+l.height-s;break;case"left":u.left=l.left;break;case"right":u.left=l.left+l.width-o;break;case"center":i.vertical.test(r[0])?u.left=l.left+l.width/2-o/2:u.top=l.top+l.height/2-s/2}return u.top=Math.round(u.top),u.left=Math.round(u.left),u.placement="center"===r[1]?r[0]:r[0]+"-"+r[1],u},positionArrow:function(e,n){e=this.getRawNode(e);var r=e.querySelector(".tooltip-inner, .popover-inner");if(r){var a=angular.element(r).hasClass("tooltip-inner"),o=a?e.querySelector(".tooltip-arrow"):e.querySelector(".arrow");if(o){var s={top:"",bottom:"",left:"",right:""};if(n=this.parsePlacement(n),"center"===n[1])return void angular.element(o).css(s);var l="border-"+n[0]+"-width",u=t.getComputedStyle(o)[l],c="border-";c+=i.vertical.test(n[0])?n[0]+"-"+n[1]:n[1]+"-"+n[0],c+="-radius";var f=t.getComputedStyle(a?r:e)[c];switch(n[0]){case"top":s.bottom=a?"0":"-"+u;break;case"bottom":s.top=a?"0":"-"+u;break;case"left":s.right=a?"0":"-"+u;break;case"right":s.left=a?"0":"-"+u}s[n[1]]=f,angular.element(o).css(s)}}}}}]),angular.module("ui.bootstrap.datepicker",["ui.bootstrap.dateparser","ui.bootstrap.isClass","ui.bootstrap.position"]).value("$datepickerSuppressError",!1).value("uibDatepickerAttributeWarning",!0).constant("uibDatepickerConfig",{datepickerMode:"day",formatDay:"dd",formatMonth:"MMMM",formatYear:"yyyy",formatDayHeader:"EEE",formatDayTitle:"MMMM yyyy",formatMonthTitle:"yyyy",maxDate:null,maxMode:"year",minDate:null,minMode:"day",ngModelOptions:{},shortcutPropagation:!1,showWeeks:!0,yearColumns:5,yearRows:4}).controller("UibDatepickerController",["$scope","$attrs","$parse","$interpolate","$locale","$log","dateFilter","uibDatepickerConfig","$datepickerSuppressError","uibDatepickerAttributeWarning","uibDateParser",function(e,t,n,r,i,a,o,s,l,u,c){function f(t){e.datepickerMode=t,g&&(e.datepickerOptions.datepickerMode=t)}var d=this,p={$setViewValue:angular.noop},h={},m=[],g=!!t.datepickerOptions;if(this.modes=["day","month","year"],g)["customClass","dateDisabled","datepickerMode","formatDay","formatDayHeader","formatDayTitle","formatMonth","formatMonthTitle","formatYear","initDate","maxDate","maxMode","minDate","minMode","showWeeks","shortcutPropagation","startingDay","yearColumns","yearRows"].forEach(function(t){switch(t){case"customClass":case"dateDisabled":e[t]=e.datepickerOptions[t]||angular.noop;break;case"datepickerMode":e.datepickerMode=angular.isDefined(e.datepickerOptions.datepickerMode)?e.datepickerOptions.datepickerMode:s.datepickerMode;break;case"formatDay":case"formatDayHeader":case"formatDayTitle":case"formatMonth":case"formatMonthTitle":case"formatYear":d[t]=angular.isDefined(e.datepickerOptions[t])?r(e.datepickerOptions[t])(e.$parent):s[t];break;case"showWeeks":case"shortcutPropagation":case"yearColumns":case"yearRows":d[t]=angular.isDefined(e.datepickerOptions[t])?e.datepickerOptions[t]:s[t];break;case"startingDay":angular.isDefined(e.datepickerOptions.startingDay)?d.startingDay=e.datepickerOptions.startingDay:angular.isNumber(s.startingDay)?d.startingDay=s.startingDay:d.startingDay=(i.DATETIME_FORMATS.FIRSTDAYOFWEEK+8)%7;break;case"maxDate":case"minDate":e.datepickerOptions[t]?e.$watch(function(){return e.datepickerOptions[t]},function(e){e?angular.isDate(e)?d[t]=c.fromTimezone(new Date(e),h.timezone):d[t]=new Date(o(e,"medium")):d[t]=null,d.refreshView()}):d[t]=s[t]?c.fromTimezone(new Date(s[t]),h.timezone):null;break;case"maxMode":case"minMode":e.datepickerOptions[t]?e.$watch(function(){return e.datepickerOptions[t]},function(n){d[t]=e[t]=angular.isDefined(n)?n:datepickerOptions[t],("minMode"===t&&d.modes.indexOf(e.datepickerOptions.datepickerMode)<d.modes.indexOf(d[t])||"maxMode"===t&&d.modes.indexOf(e.datepickerOptions.datepickerMode)>d.modes.indexOf(d[t]))&&(e.datepickerMode=d[t],e.datepickerOptions.datepickerMode=d[t])}):d[t]=e[t]=s[t]||null;break;case"initDate":e.datepickerOptions.initDate?(d.activeDate=c.fromTimezone(e.datepickerOptions.initDate,h.timezone)||new Date,e.$watch(function(){return e.datepickerOptions.initDate},function(e){e&&(p.$isEmpty(p.$modelValue)||p.$invalid)&&(d.activeDate=c.fromTimezone(e,h.timezone),d.refreshView())})):d.activeDate=new Date}});else{if(angular.forEach(["formatDay","formatMonth","formatYear","formatDayHeader","formatDayTitle","formatMonthTitle"],function(n){d[n]=angular.isDefined(t[n])?r(t[n])(e.$parent):s[n],angular.isDefined(t[n])&&u&&a.warn("uib-datepicker "+n+" attribute usage is deprecated, use datepicker-options attribute instead")}),angular.forEach(["showWeeks","yearRows","yearColumns","shortcutPropagation"],function(n){d[n]=angular.isDefined(t[n])?e.$parent.$eval(t[n]):s[n],angular.isDefined(t[n])&&u&&a.warn("uib-datepicker "+n+" attribute usage is deprecated, use datepicker-options attribute instead")}),angular.forEach(["dateDisabled","customClass"],function(e){angular.isDefined(t[e])&&u&&a.warn("uib-datepicker "+e+" attribute usage is deprecated, use datepicker-options attribute instead")}),angular.isDefined(t.startingDay)?(u&&a.warn("uib-datepicker startingDay attribute usage is deprecated, use datepicker-options attribute instead"),d.startingDay=e.$parent.$eval(t.startingDay)):angular.isNumber(s.startingDay)?d.startingDay=s.startingDay:d.startingDay=(i.DATETIME_FORMATS.FIRSTDAYOFWEEK+8)%7,angular.forEach(["minDate","maxDate"],function(n){t[n]?(u&&a.warn("uib-datepicker "+n+" attribute usage is deprecated, use datepicker-options attribute instead"),m.push(e.$parent.$watch(t[n],function(e){e?angular.isDate(e)?d[n]=c.fromTimezone(new Date(e),h.timezone):d[n]=new Date(o(e,"medium")):d[n]=null,d.refreshView()}))):d[n]=s[n]?c.fromTimezone(new Date(s[n]),h.timezone):null}),angular.forEach(["minMode","maxMode"],function(n){t[n]?(u&&a.warn("uib-datepicker "+n+" attribute usage is deprecated, use datepicker-options attribute instead"),m.push(e.$parent.$watch(t[n],function(r){d[n]=e[n]=angular.isDefined(r)?r:t[n],("minMode"===n&&d.modes.indexOf(e.datepickerMode)<d.modes.indexOf(d[n])||"maxMode"===n&&d.modes.indexOf(e.datepickerMode)>d.modes.indexOf(d[n]))&&(e.datepickerMode=d[n])}))):d[n]=e[n]=s[n]||null}),angular.isDefined(t.initDate)){u&&a.warn("uib-datepicker initDate attribute usage is deprecated, use datepicker-options attribute instead");var v=c.fromTimezone(e.$parent.$eval(t.initDate),h.timezone);this.activeDate=isNaN(v)?new Date:v,m.push(e.$parent.$watch(t.initDate,function(e){e&&(p.$isEmpty(p.$modelValue)||p.$invalid)&&(e=c.fromTimezone(e,h.timezone),d.activeDate=isNaN(e)?new Date:e,d.refreshView())}))}else this.activeDate=new Date;t.datepickerMode&&u&&a.warn("uib-datepicker datepickerMode attribute usage is deprecated, use datepicker-options attribute instead"),e.datepickerMode=e.datepickerMode||s.datepickerMode}e.uniqueId="datepicker-"+e.$id+"-"+Math.floor(1e4*Math.random()),e.disabled=angular.isDefined(t.disabled)||!1,angular.isDefined(t.ngDisabled)&&m.push(e.$parent.$watch(t.ngDisabled,function(t){e.disabled=t,d.refreshView()})),e.isActive=function(t){return 0===d.compare(t.date,d.activeDate)?(e.activeDateId=t.uid,!0):!1},this.init=function(e){p=e,h=e.$options||s.ngModelOptions,this.activeDate=p.$modelValue?c.fromTimezone(new Date(p.$modelValue),h.timezone):c.fromTimezone(new Date,h.timezone),p.$render=function(){d.render()}},this.render=function(){if(p.$viewValue){var e=new Date(p.$viewValue),t=!isNaN(e);t?this.activeDate=c.fromTimezone(e,h.timezone):l||a.error('Datepicker directive: "ng-model" value must be a Date object')}this.refreshView()},this.refreshView=function(){if(this.element){e.selectedDt=null,this._refreshView(),e.activeDt&&(e.activeDateId=e.activeDt.uid);var t=p.$viewValue?new Date(p.$viewValue):null;t=c.fromTimezone(t,h.timezone),p.$setValidity("dateDisabled",!t||this.element&&!this.isDisabled(t))}},this.createDateObject=function(t,n){var r=p.$viewValue?new Date(p.$viewValue):null;r=c.fromTimezone(r,h.timezone);var i=new Date;i=c.fromTimezone(i,h.timezone);var a=this.compare(t,i),o={date:t,label:c.filter(t,n),selected:r&&0===this.compare(t,r),disabled:this.isDisabled(t),past:0>a,current:0===a,future:a>0,customClass:this.customClass(t)||null};return r&&0===this.compare(t,r)&&(e.selectedDt=o),d.activeDate&&0===this.compare(o.date,d.activeDate)&&(e.activeDt=o),o},this.isDisabled=function(t){return e.disabled||this.minDate&&this.compare(t,this.minDate)<0||this.maxDate&&this.compare(t,this.maxDate)>0||e.dateDisabled&&e.dateDisabled({date:t,mode:e.datepickerMode})},this.customClass=function(t){return e.customClass({date:t,mode:e.datepickerMode})},this.split=function(e,t){for(var n=[];e.length>0;)n.push(e.splice(0,t));return n},e.select=function(t){if(e.datepickerMode===d.minMode){var n=p.$viewValue?c.fromTimezone(new Date(p.$viewValue),h.timezone):new Date(0,0,0,0,0,0,0);n.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),n=c.toTimezone(n,h.timezone),p.$setViewValue(n),p.$render()}else d.activeDate=t,f(d.modes[d.modes.indexOf(e.datepickerMode)-1]),e.$emit("uib:datepicker.mode")},e.move=function(e){var t=d.activeDate.getFullYear()+e*(d.step.years||0),n=d.activeDate.getMonth()+e*(d.step.months||0);d.activeDate.setFullYear(t,n,1),d.refreshView()},e.toggleMode=function(t){t=t||1,e.datepickerMode===d.maxMode&&1===t||e.datepickerMode===d.minMode&&-1===t||(f(d.modes[d.modes.indexOf(e.datepickerMode)+t]),e.$emit("uib:datepicker.mode"))},e.keys={13:"enter",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down"};var b=function(){d.element[0].focus()};e.$on("uib:datepicker.focus",b),e.keydown=function(t){var n=e.keys[t.which];if(n&&!t.shiftKey&&!t.altKey&&!e.disabled)if(t.preventDefault(),d.shortcutPropagation||t.stopPropagation(),"enter"===n||"space"===n){if(d.isDisabled(d.activeDate))return;e.select(d.activeDate)}else!t.ctrlKey||"up"!==n&&"down"!==n?(d.handleKeyDown(n,t),d.refreshView()):e.toggleMode("up"===n?1:-1)},e.$on("$destroy",function(){for(;m.length;)m.shift()()})}]).controller("UibDaypickerController",["$scope","$element","dateFilter",function(e,t,n){function r(e,t){return 1!==t||e%4!==0||e%100===0&&e%400!==0?a[t]:29}function i(e){var t=new Date(e);t.setDate(t.getDate()+4-(t.getDay()||7));var n=t.getTime();return t.setMonth(0),t.setDate(1),Math.floor(Math.round((n-t)/864e5)/7)+1}var a=[31,28,31,30,31,30,31,31,30,31,30,31];this.step={
months:1},this.element=t,this.init=function(t){angular.extend(t,this),e.showWeeks=t.showWeeks,t.refreshView()},this.getDates=function(e,t){for(var n,r=new Array(t),i=new Date(e),a=0;t>a;)n=new Date(i),r[a++]=n,i.setDate(i.getDate()+1);return r},this._refreshView=function(){var t=this.activeDate.getFullYear(),r=this.activeDate.getMonth(),a=new Date(this.activeDate);a.setFullYear(t,r,1);var o=this.startingDay-a.getDay(),s=o>0?7-o:-o,l=new Date(a);s>0&&l.setDate(-s+1);for(var u=this.getDates(l,42),c=0;42>c;c++)u[c]=angular.extend(this.createDateObject(u[c],this.formatDay),{secondary:u[c].getMonth()!==r,uid:e.uniqueId+"-"+c});e.labels=new Array(7);for(var f=0;7>f;f++)e.labels[f]={abbr:n(u[f].date,this.formatDayHeader),full:n(u[f].date,"EEEE")};if(e.title=n(this.activeDate,this.formatDayTitle),e.rows=this.split(u,7),e.showWeeks){e.weekNumbers=[];for(var d=(11-this.startingDay)%7,p=e.rows.length,h=0;p>h;h++)e.weekNumbers.push(i(e.rows[h][d].date))}},this.compare=function(e,t){var n=new Date(e.getFullYear(),e.getMonth(),e.getDate()),r=new Date(t.getFullYear(),t.getMonth(),t.getDate());return n.setFullYear(e.getFullYear()),r.setFullYear(t.getFullYear()),n-r},this.handleKeyDown=function(e,t){var n=this.activeDate.getDate();if("left"===e)n-=1;else if("up"===e)n-=7;else if("right"===e)n+=1;else if("down"===e)n+=7;else if("pageup"===e||"pagedown"===e){var i=this.activeDate.getMonth()+("pageup"===e?-1:1);this.activeDate.setMonth(i,1),n=Math.min(r(this.activeDate.getFullYear(),this.activeDate.getMonth()),n)}else"home"===e?n=1:"end"===e&&(n=r(this.activeDate.getFullYear(),this.activeDate.getMonth()));this.activeDate.setDate(n)}}]).controller("UibMonthpickerController",["$scope","$element","dateFilter",function(e,t,n){this.step={years:1},this.element=t,this.init=function(e){angular.extend(e,this),e.refreshView()},this._refreshView=function(){for(var t,r=new Array(12),i=this.activeDate.getFullYear(),a=0;12>a;a++)t=new Date(this.activeDate),t.setFullYear(i,a,1),r[a]=angular.extend(this.createDateObject(t,this.formatMonth),{uid:e.uniqueId+"-"+a});e.title=n(this.activeDate,this.formatMonthTitle),e.rows=this.split(r,3)},this.compare=function(e,t){var n=new Date(e.getFullYear(),e.getMonth()),r=new Date(t.getFullYear(),t.getMonth());return n.setFullYear(e.getFullYear()),r.setFullYear(t.getFullYear()),n-r},this.handleKeyDown=function(e,t){var n=this.activeDate.getMonth();if("left"===e)n-=1;else if("up"===e)n-=3;else if("right"===e)n+=1;else if("down"===e)n+=3;else if("pageup"===e||"pagedown"===e){var r=this.activeDate.getFullYear()+("pageup"===e?-1:1);this.activeDate.setFullYear(r)}else"home"===e?n=0:"end"===e&&(n=11);this.activeDate.setMonth(n)}}]).controller("UibYearpickerController",["$scope","$element","dateFilter",function(e,t,n){function r(e){return parseInt((e-1)/a,10)*a+1}var i,a;this.element=t,this.yearpickerInit=function(){i=this.yearColumns,a=this.yearRows*i,this.step={years:a}},this._refreshView=function(){for(var t,n=new Array(a),o=0,s=r(this.activeDate.getFullYear());a>o;o++)t=new Date(this.activeDate),t.setFullYear(s+o,0,1),n[o]=angular.extend(this.createDateObject(t,this.formatYear),{uid:e.uniqueId+"-"+o});e.title=[n[0].label,n[a-1].label].join(" - "),e.rows=this.split(n,i),e.columns=i},this.compare=function(e,t){return e.getFullYear()-t.getFullYear()},this.handleKeyDown=function(e,t){var n=this.activeDate.getFullYear();"left"===e?n-=1:"up"===e?n-=i:"right"===e?n+=1:"down"===e?n+=i:"pageup"===e||"pagedown"===e?n+=("pageup"===e?-1:1)*a:"home"===e?n=r(this.activeDate.getFullYear()):"end"===e&&(n=r(this.activeDate.getFullYear())+a-1),this.activeDate.setFullYear(n)}}]).directive("uibDatepicker",function(){return{replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/datepicker.html"},scope:{datepickerMode:"=?",datepickerOptions:"=?",dateDisabled:"&",customClass:"&",shortcutPropagation:"&?"},require:["uibDatepicker","^ngModel"],controller:"UibDatepickerController",controllerAs:"datepicker",link:function(e,t,n,r){var i=r[0],a=r[1];i.init(a)}}}).directive("uibDaypicker",function(){return{replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/day.html"},require:["^uibDatepicker","uibDaypicker"],controller:"UibDaypickerController",link:function(e,t,n,r){var i=r[0],a=r[1];a.init(i)}}}).directive("uibMonthpicker",function(){return{replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/month.html"},require:["^uibDatepicker","uibMonthpicker"],controller:"UibMonthpickerController",link:function(e,t,n,r){var i=r[0],a=r[1];a.init(i)}}}).directive("uibYearpicker",function(){return{replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/year.html"},require:["^uibDatepicker","uibYearpicker"],controller:"UibYearpickerController",link:function(e,t,n,r){var i=r[0];angular.extend(i,r[1]),i.yearpickerInit(),i.refreshView()}}}).value("uibDatepickerPopupAttributeWarning",!0).constant("uibDatepickerPopupConfig",{altInputFormats:[],appendToBody:!1,clearText:"Clear",closeOnDateSelection:!0,closeText:"Done",currentText:"Today",datepickerPopup:"yyyy-MM-dd",datepickerPopupTemplateUrl:"uib/template/datepicker/popup.html",datepickerTemplateUrl:"uib/template/datepicker/datepicker.html",html5Types:{date:"yyyy-MM-dd","datetime-local":"yyyy-MM-ddTHH:mm:ss.sss",month:"yyyy-MM"},onOpenFocus:!0,showButtonBar:!0,placement:"auto bottom-left"}).controller("UibDatepickerPopupController",["$scope","$element","$attrs","$compile","$log","$parse","$window","$document","$rootScope","$uibPosition","dateFilter","uibDateParser","uibDatepickerPopupConfig","$timeout","uibDatepickerConfig","uibDatepickerPopupAttributeWarning",function(e,t,n,r,i,a,o,s,l,u,c,f,d,p,h,m){function g(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()})}function v(t){var n=f.parse(t,k,e.date);if(isNaN(n))for(var r=0;r<P.length;r++)if(n=f.parse(t,P[r],e.date),!isNaN(n))return n;return n}function b(e){if(angular.isNumber(e)&&(e=new Date(e)),!e)return null;if(angular.isDate(e)&&!isNaN(e))return e;if(angular.isString(e)){var t=v(e);if(!isNaN(t))return f.toTimezone(t,j.timezone)}return N.$options&&N.$options.allowInvalid?e:void 0}function y(e,t){var r=e||t;return n.ngRequired||r?(angular.isNumber(r)&&(r=new Date(r)),r?angular.isDate(r)&&!isNaN(r)?!0:angular.isString(r)?!isNaN(v(t)):!1:!0):!0}function $(n){if(e.isOpen||!e.disabled){var r=L[0],i=t[0].contains(n.target),a=void 0!==r.contains&&r.contains(n.target);!e.isOpen||i||a||e.$apply(function(){e.isOpen=!1})}}function w(n){27===n.which&&e.isOpen?(n.preventDefault(),n.stopPropagation(),e.$apply(function(){e.isOpen=!1}),t[0].focus()):40!==n.which||e.isOpen||(n.preventDefault(),n.stopPropagation(),e.$apply(function(){e.isOpen=!0}))}function x(){if(e.isOpen){var r=angular.element(L[0].querySelector(".uib-datepicker-popup")),i=n.popupPlacement?n.popupPlacement:d.placement,a=u.positionElements(t,r,i,M);r.css({top:a.top+"px",left:a.left+"px"}),r.hasClass("uib-position-measure")&&r.removeClass("uib-position-measure")}}var k,C,M,S,T,D,E,O,A,N,j,L,P,I={},F=!1,z=[];e.watchData={},this.init=function(u){if(N=u,j=u.$options||h.ngModelOptions,C=angular.isDefined(n.closeOnDateSelection)?e.$parent.$eval(n.closeOnDateSelection):d.closeOnDateSelection,M=angular.isDefined(n.datepickerAppendToBody)?e.$parent.$eval(n.datepickerAppendToBody):d.appendToBody,S=angular.isDefined(n.onOpenFocus)?e.$parent.$eval(n.onOpenFocus):d.onOpenFocus,T=angular.isDefined(n.datepickerPopupTemplateUrl)?n.datepickerPopupTemplateUrl:d.datepickerPopupTemplateUrl,D=angular.isDefined(n.datepickerTemplateUrl)?n.datepickerTemplateUrl:d.datepickerTemplateUrl,P=angular.isDefined(n.altInputFormats)?e.$parent.$eval(n.altInputFormats):d.altInputFormats,e.showButtonBar=angular.isDefined(n.showButtonBar)?e.$parent.$eval(n.showButtonBar):d.showButtonBar,d.html5Types[n.type]?(k=d.html5Types[n.type],F=!0):(k=n.uibDatepickerPopup||d.datepickerPopup,n.$observe("uibDatepickerPopup",function(e,t){var n=e||d.datepickerPopup;if(n!==k&&(k=n,N.$modelValue=null,!k))throw new Error("uibDatepickerPopup must have a date format specified.")})),!k)throw new Error("uibDatepickerPopup must have a date format specified.");if(F&&n.uibDatepickerPopup)throw new Error("HTML5 date input types do not support custom formats.");E=angular.element("<div uib-datepicker-popup-wrap><div uib-datepicker></div></div>"),e.ngModelOptions=angular.copy(j),e.ngModelOptions.timezone=null,e.ngModelOptions.updateOnDefault===!0&&(e.ngModelOptions.updateOn=e.ngModelOptions.updateOn?e.ngModelOptions.updateOn+" default":"default"),E.attr({"ng-model":"date","ng-model-options":"ngModelOptions","ng-change":"dateSelection(date)","template-url":T}),O=angular.element(E.children()[0]),O.attr("template-url",D),F&&"month"===n.type&&(O.attr("datepicker-mode",'"month"'),O.attr("min-mode","month")),e.datepickerOptions&&O.attr("datepicker-options","datepickerOptions"),angular.forEach(["minMode","maxMode","datepickerMode","shortcutPropagation"],function(t){if(n[t]){m&&i.warn("uib-datepicker settings via uib-datepicker-popup attributes are deprecated and will be removed in UI Bootstrap 1.3, use datepicker-options attribute instead");var r=a(n[t]),o={get:function(){return r(e.$parent)}};if(O.attr(g(t),"watchData."+t),"datepickerMode"===t){var s=r.assign;o.set=function(t){s(e.$parent,t)}}Object.defineProperty(e.watchData,t,o)}}),angular.forEach(["minDate","maxDate","initDate"],function(t){if(n[t]){m&&i.warn("uib-datepicker settings via uib-datepicker-popup attributes are deprecated and will be removed in UI Bootstrap 1.3, use datepicker-options attribute instead");var r=a(n[t]);z.push(e.$parent.$watch(r,function(n){if("minDate"===t||"maxDate"===t)null===n?I[t]=null:angular.isDate(n)?I[t]=f.fromTimezone(new Date(n),j.timezone):I[t]=new Date(c(n,"medium")),e.watchData[t]=null===n?null:I[t];else{var r=n?new Date(n):new Date;e.watchData[t]=f.fromTimezone(r,j.timezone)}})),O.attr(g(t),"watchData."+t)}}),n.dateDisabled&&(m&&i.warn("uib-datepicker settings via uib-datepicker-popup attributes are deprecated and will be removed in UI Bootstrap 1.3, use datepicker-options attribute instead"),O.attr("date-disabled","dateDisabled({ date: date, mode: mode })")),angular.forEach(["formatDay","formatMonth","formatYear","formatDayHeader","formatDayTitle","formatMonthTitle","showWeeks","startingDay","yearRows","yearColumns"],function(e){angular.isDefined(n[e])&&(m&&i.warn("uib-datepicker settings via uib-datepicker-popup attributes are deprecated and will be removed in UI Bootstrap 1.3, use datepicker-options attribute instead"),O.attr(g(e),n[e]))}),n.customClass&&(m&&i.warn("uib-datepicker settings via uib-datepicker-popup attributes are deprecated and will be removed in UI Bootstrap 1.3, use datepicker-options attribute instead"),O.attr("custom-class","customClass({ date: date, mode: mode })")),F?N.$formatters.push(function(t){return e.date=f.fromTimezone(t,j.timezone),t}):(N.$$parserName="date",N.$validators.date=y,N.$parsers.unshift(b),N.$formatters.push(function(t){return N.$isEmpty(t)?(e.date=t,t):(e.date=f.fromTimezone(t,j.timezone),angular.isNumber(e.date)&&(e.date=new Date(e.date)),f.filter(e.date,k))})),N.$viewChangeListeners.push(function(){e.date=v(N.$viewValue)}),t.on("keydown",w),L=r(E)(e),E.remove(),M?s.find("body").append(L):t.after(L),e.$on("$destroy",function(){for(e.isOpen===!0&&(l.$$phase||e.$apply(function(){e.isOpen=!1})),L.remove(),t.off("keydown",w),s.off("click",$),A&&A.off("scroll",x),angular.element(o).off("resize",x);z.length;)z.shift()()})},e.getText=function(t){return e[t+"Text"]||d[t+"Text"]},e.isDisabled=function(t){return"today"===t&&(t=f.fromTimezone(new Date,j.timezone)),e.datepickerOptions?e.datepickerOptions&&e.datepickerOptions.minDate&&e.compare(t,e.datepickerOptions.minDate)<0||e.datepickerOptions.maxDate&&e.compare(t,e.datepickerOptions.maxDate)>0:e.watchData.minDate&&e.compare(t,I.minDate)<0||e.watchData.maxDate&&e.compare(t,I.maxDate)>0},e.compare=function(e,t){return new Date(e.getFullYear(),e.getMonth(),e.getDate())-new Date(t.getFullYear(),t.getMonth(),t.getDate())},e.dateSelection=function(n){angular.isDefined(n)&&(e.date=n);var r=e.date?f.filter(e.date,k):null;t.val(r),N.$setViewValue(r),C&&(e.isOpen=!1,t[0].focus())},e.keydown=function(n){27===n.which&&(n.stopPropagation(),e.isOpen=!1,t[0].focus())},e.select=function(t,n){if(n.stopPropagation(),"today"===t){var r=new Date;angular.isDate(e.date)?(t=new Date(e.date),t.setFullYear(r.getFullYear(),r.getMonth(),r.getDate())):t=new Date(r.setHours(0,0,0,0))}e.dateSelection(t)},e.close=function(n){n.stopPropagation(),e.isOpen=!1,t[0].focus()},e.disabled=angular.isDefined(n.disabled)||!1,n.ngDisabled&&z.push(e.$parent.$watch(a(n.ngDisabled),function(t){e.disabled=t})),e.$watch("isOpen",function(r){r?e.disabled?e.isOpen=!1:p(function(){x(),S&&e.$broadcast("uib:datepicker.focus"),s.on("click",$);var r=n.popupPlacement?n.popupPlacement:d.placement;M||u.parsePlacement(r)[2]?(A=A||angular.element(u.scrollParent(t)),A&&A.on("scroll",x)):A=null,angular.element(o).on("resize",x)},0,!1):(s.off("click",$),A&&A.off("scroll",x),angular.element(o).off("resize",x))}),e.$on("uib:datepicker.mode",function(){p(x,0,!1)})}]).directive("uibDatepickerPopup",function(){return{require:["ngModel","uibDatepickerPopup"],controller:"UibDatepickerPopupController",scope:{datepickerOptions:"=?",isOpen:"=?",currentText:"@",clearText:"@",closeText:"@",dateDisabled:"&",customClass:"&"},link:function(e,t,n,r){var i=r[0],a=r[1];a.init(i)}}}).directive("uibDatepickerPopupWrap",function(){return{replace:!0,transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/popup.html"}}}),angular.module("ui.bootstrap.debounce",[]).factory("$$debounce",["$timeout",function(e){return function(t,n){var r;return function(){var i=this,a=Array.prototype.slice.call(arguments);r&&e.cancel(r),r=e(function(){t.apply(i,a)},n)}}}]),angular.module("ui.bootstrap.dropdown",["ui.bootstrap.position"]).constant("uibDropdownConfig",{appendToOpenClass:"uib-dropdown-open",openClass:"open"}).service("uibDropdownService",["$document","$rootScope",function(e,t){var n=null;this.open=function(t){n||(e.on("click",r),e.on("keydown",i)),n&&n!==t&&(n.isOpen=!1),n=t},this.close=function(t){n===t&&(n=null,e.off("click",r),e.off("keydown",i))};var r=function(e){if(n&&!(e&&"disabled"===n.getAutoClose()||e&&3===e.which)){var r=n.getToggleElement();if(!(e&&r&&r[0].contains(e.target))){var i=n.getDropdownElement();e&&"outsideClick"===n.getAutoClose()&&i&&i[0].contains(e.target)||(n.isOpen=!1,t.$$phase||n.$apply())}}},i=function(e){27===e.which?(n.focusToggleElement(),r()):n.isKeynavEnabled()&&-1!==[38,40].indexOf(e.which)&&n.isOpen&&(e.preventDefault(),e.stopPropagation(),n.focusDropdownEntry(e.which))}}]).controller("UibDropdownController",["$scope","$element","$attrs","$parse","uibDropdownConfig","uibDropdownService","$animate","$uibPosition","$document","$compile","$templateRequest",function(e,t,n,r,i,a,o,s,l,u,c){var f,d,p=this,h=e.$new(),m=i.appendToOpenClass,g=i.openClass,v=angular.noop,b=n.onToggle?r(n.onToggle):angular.noop,y=!1,$=null,w=!1,x=l.find("body");t.addClass("dropdown"),this.init=function(){if(n.isOpen&&(d=r(n.isOpen),v=d.assign,e.$watch(d,function(e){h.isOpen=!!e})),angular.isDefined(n.dropdownAppendTo)){var i=r(n.dropdownAppendTo)(h);i&&($=angular.element(i))}y=angular.isDefined(n.dropdownAppendToBody),w=angular.isDefined(n.keyboardNav),y&&!$&&($=x),$&&p.dropdownMenu&&($.append(p.dropdownMenu),t.on("$destroy",function(){p.dropdownMenu.remove()}))},this.toggle=function(e){return h.isOpen=arguments.length?!!e:!h.isOpen,angular.isFunction(v)&&v(h,h.isOpen),h.isOpen},this.isOpen=function(){return h.isOpen},h.getToggleElement=function(){return p.toggleElement},h.getAutoClose=function(){return n.autoClose||"always"},h.getElement=function(){return t},h.isKeynavEnabled=function(){return w},h.focusDropdownEntry=function(e){var n=p.dropdownMenu?angular.element(p.dropdownMenu).find("a"):t.find("ul").eq(0).find("a");switch(e){case 40:angular.isNumber(p.selectedOption)?p.selectedOption=p.selectedOption===n.length-1?p.selectedOption:p.selectedOption+1:p.selectedOption=0;break;case 38:angular.isNumber(p.selectedOption)?p.selectedOption=0===p.selectedOption?0:p.selectedOption-1:p.selectedOption=n.length-1}n[p.selectedOption].focus()},h.getDropdownElement=function(){return p.dropdownMenu},h.focusToggleElement=function(){p.toggleElement&&p.toggleElement[0].focus()},h.$watch("isOpen",function(n,r){if($&&p.dropdownMenu){var i,l,d=s.positionElements(t,p.dropdownMenu,"bottom-left",!0);if(i={top:d.top+"px",display:n?"block":"none"},l=p.dropdownMenu.hasClass("dropdown-menu-right"),l?(i.left="auto",i.right=window.innerWidth-(d.left+t.prop("offsetWidth"))+"px"):(i.left=d.left+"px",i.right="auto"),!y){var w=s.offset($);i.top=d.top-w.top+"px",l?i.right=window.innerWidth-(d.left-w.left+t.prop("offsetWidth"))+"px":i.left=d.left-w.left+"px"}p.dropdownMenu.css(i)}var x=$?$:t,k=x.hasClass($?m:g);if(k===!n&&o[n?"addClass":"removeClass"](x,$?m:g).then(function(){angular.isDefined(n)&&n!==r&&b(e,{open:!!n})}),n)p.dropdownMenuTemplateUrl&&c(p.dropdownMenuTemplateUrl).then(function(e){f=h.$new(),u(e.trim())(f,function(e){var t=e;p.dropdownMenu.replaceWith(t),p.dropdownMenu=t})}),h.focusToggleElement(),a.open(h);else{if(p.dropdownMenuTemplateUrl){f&&f.$destroy();var C=angular.element('<ul class="dropdown-menu"></ul>');p.dropdownMenu.replaceWith(C),p.dropdownMenu=C}a.close(h),p.selectedOption=null}angular.isFunction(v)&&v(e,n)}),e.$on("$locationChangeSuccess",function(){"disabled"!==h.getAutoClose()&&(h.isOpen=!1)})}]).directive("uibDropdown",function(){return{controller:"UibDropdownController",link:function(e,t,n,r){r.init()}}}).directive("uibDropdownMenu",function(){return{restrict:"A",require:"?^uibDropdown",link:function(e,t,n,r){if(r&&!angular.isDefined(n.dropdownNested)){t.addClass("dropdown-menu");var i=n.templateUrl;i&&(r.dropdownMenuTemplateUrl=i),r.dropdownMenu||(r.dropdownMenu=t)}}}}).directive("uibDropdownToggle",function(){return{require:"?^uibDropdown",link:function(e,t,n,r){if(r){t.addClass("dropdown-toggle"),r.toggleElement=t;var i=function(i){i.preventDefault(),t.hasClass("disabled")||n.disabled||e.$apply(function(){r.toggle()})};t.bind("click",i),t.attr({"aria-haspopup":!0,"aria-expanded":!1}),e.$watch(r.isOpen,function(e){t.attr("aria-expanded",!!e)}),e.$on("$destroy",function(){t.unbind("click",i)})}}}}),angular.module("ui.bootstrap.stackedMap",[]).factory("$$stackedMap",function(){return{createNew:function(){var e=[];return{add:function(t,n){e.push({key:t,value:n})},get:function(t){for(var n=0;n<e.length;n++)if(t===e[n].key)return e[n]},keys:function(){for(var t=[],n=0;n<e.length;n++)t.push(e[n].key);return t},top:function(){return e[e.length-1]},remove:function(t){for(var n=-1,r=0;r<e.length;r++)if(t===e[r].key){n=r;break}return e.splice(n,1)[0]},removeTop:function(){return e.splice(e.length-1,1)[0]},length:function(){return e.length}}}}}),angular.module("ui.bootstrap.modal",["ui.bootstrap.stackedMap"]).factory("$$multiMap",function(){return{createNew:function(){var e={};return{entries:function(){return Object.keys(e).map(function(t){return{key:t,value:e[t]}})},get:function(t){return e[t]},hasKey:function(t){return!!e[t]},keys:function(){return Object.keys(e)},put:function(t,n){e[t]||(e[t]=[]),e[t].push(n)},remove:function(t,n){var r=e[t];if(r){var i=r.indexOf(n);-1!==i&&r.splice(i,1),r.length||delete e[t]}}}}}}).provider("$uibResolve",function(){var e=this;this.resolver=null,this.setResolver=function(e){this.resolver=e},this.$get=["$injector","$q",function(t,n){var r=e.resolver?t.get(e.resolver):null;return{resolve:function(e,i,a,o){if(r)return r.resolve(e,i,a,o);var s=[];return angular.forEach(e,function(e){angular.isFunction(e)||angular.isArray(e)?s.push(n.resolve(t.invoke(e))):angular.isString(e)?s.push(n.resolve(t.get(e))):s.push(n.resolve(e))}),n.all(s).then(function(t){var n={},r=0;return angular.forEach(e,function(e,i){n[i]=t[r++]}),n})}}}]}).directive("uibModalBackdrop",["$animate","$injector","$uibModalStack",function(e,t,n){function r(t,r,i){i.modalInClass&&(e.addClass(r,i.modalInClass),t.$on(n.NOW_CLOSING_EVENT,function(n,a){var o=a();t.modalOptions.animation?e.removeClass(r,i.modalInClass).then(o):o()}))}return{replace:!0,templateUrl:"uib/template/modal/backdrop.html",compile:function(e,t){return e.addClass(t.backdropClass),r}}}]).directive("uibModalWindow",["$uibModalStack","$q","$animateCss","$document",function(e,t,n,r){return{scope:{index:"@"},replace:!0,transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/modal/window.html"},link:function(i,a,o){a.addClass(o.windowClass||""),a.addClass(o.windowTopClass||""),i.size=o.size,i.close=function(t){var n=e.getTop();n&&n.value.backdrop&&"static"!==n.value.backdrop&&t.target===t.currentTarget&&(t.preventDefault(),t.stopPropagation(),e.dismiss(n.key,"backdrop click"))},a.on("click",i.close),i.$isRendered=!0;var s=t.defer();o.$observe("modalRender",function(e){"true"===e&&s.resolve()}),s.promise.then(function(){var s=null;o.modalInClass&&(s=n(a,{addClass:o.modalInClass}).start(),i.$on(e.NOW_CLOSING_EVENT,function(e,t){var r=t();n(a,{removeClass:o.modalInClass}).start().then(r)})),t.when(s).then(function(){var t=e.getTop();if(t&&e.modalRendered(t.key),!r[0].activeElement||!a[0].contains(r[0].activeElement)){var n=a[0].querySelector("[autofocus]");n?n.focus():a[0].focus()}})})}}}]).directive("uibModalAnimationClass",function(){return{compile:function(e,t){t.modalAnimation&&e.addClass(t.uibModalAnimationClass)}}}).directive("uibModalTransclude",function(){return{link:function(e,t,n,r,i){i(e.$parent,function(e){t.empty(),t.append(e)})}}}).factory("$uibModalStack",["$animate","$animateCss","$document","$compile","$rootScope","$q","$$multiMap","$$stackedMap",function(e,t,n,r,i,a,o,s){function l(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)}function u(){for(var e=-1,t=y.keys(),n=0;n<t.length;n++)y.get(t[n]).value.backdrop&&(e=n);return e}function c(e,t){var n=y.get(e).value,r=n.appendTo;y.remove(e),p(n.modalDomEl,n.modalScope,function(){var t=n.openedClass||b;$.remove(t,e),r.toggleClass(t,$.hasKey(t)),f(!0)},n.closedDeferred),d(),t&&t.focus?t.focus():r.focus&&r.focus()}function f(e){var t;y.length()>0&&(t=y.top().value,t.modalDomEl.toggleClass(t.windowTopClass||"",e))}function d(){if(g&&-1===u()){var e=v;p(g,v,function(){e=null}),g=void 0,v=void 0}}function p(t,n,r,i){function o(){o.done||(o.done=!0,e.leave(t).then(function(){t.remove(),i&&i.resolve()}),n.$destroy(),r&&r())}var s,l=null,u=function(){return s||(s=a.defer(),l=s.promise),function(){s.resolve()}};return n.$broadcast(w.NOW_CLOSING_EVENT,u),a.when(l).then(o)}function h(e){if(e.isDefaultPrevented())return e;var t=y.top();if(t)switch(e.which){case 27:t.value.keyboard&&(e.preventDefault(),i.$apply(function(){w.dismiss(t.key,"escape key press")}));break;case 9:var n=w.loadFocusElementList(t),r=!1;e.shiftKey?(w.isFocusInFirstItem(e,n)||w.isModalFocused(e,t))&&(r=w.focusLastFocusableElement(n)):w.isFocusInLastItem(e,n)&&(r=w.focusFirstFocusableElement(n)),r&&(e.preventDefault(),e.stopPropagation())}}function m(e,t,n){return!e.value.modalScope.$broadcast("modal.closing",t,n).defaultPrevented}var g,v,b="modal-open",y=s.createNew(),$=o.createNew(),w={NOW_CLOSING_EVENT:"modal.stack.now-closing"},x="a[href], area[href], input:not([disabled]), button:not([disabled]),select:not([disabled]), textarea:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable=true]";return i.$watch(u,function(e){v&&(v.index=e)}),n.on("keydown",h),i.$on("$destroy",function(){n.off("keydown",h)}),w.open=function(t,a){var o=n[0].activeElement,s=a.openedClass||b;f(!1),y.add(t,{deferred:a.deferred,renderDeferred:a.renderDeferred,closedDeferred:a.closedDeferred,modalScope:a.scope,backdrop:a.backdrop,keyboard:a.keyboard,openedClass:a.openedClass,windowTopClass:a.windowTopClass,animation:a.animation,appendTo:a.appendTo}),$.put(s,t);var l=a.appendTo,c=u();if(!l.length)throw new Error("appendTo element not found. Make sure that the element passed is in DOM.");c>=0&&!g&&(v=i.$new(!0),v.modalOptions=a,v.index=c,g=angular.element('<div uib-modal-backdrop="modal-backdrop"></div>'),g.attr("backdrop-class",a.backdropClass),a.animation&&g.attr("modal-animation","true"),r(g)(v),e.enter(g,l));var d=angular.element('<div uib-modal-window="modal-window"></div>');d.attr({"template-url":a.windowTemplateUrl,"window-class":a.windowClass,"window-top-class":a.windowTopClass,size:a.size,index:y.length()-1,animate:"animate"}).html(a.content),a.animation&&d.attr("modal-animation","true"),e.enter(r(d)(a.scope),l).then(function(){a.scope.$$uibDestructionScheduled||e.addClass(l,s)}),y.top().value.modalDomEl=d,y.top().value.modalOpener=o},w.close=function(e,t){var n=y.get(e);return n&&m(n,t,!0)?(n.value.modalScope.$$uibDestructionScheduled=!0,n.value.deferred.resolve(t),c(e,n.value.modalOpener),!0):!n},w.dismiss=function(e,t){var n=y.get(e);return n&&m(n,t,!1)?(n.value.modalScope.$$uibDestructionScheduled=!0,n.value.deferred.reject(t),c(e,n.value.modalOpener),!0):!n},w.dismissAll=function(e){for(var t=this.getTop();t&&this.dismiss(t.key,e);)t=this.getTop()},w.getTop=function(){return y.top()},w.modalRendered=function(e){var t=y.get(e);t&&t.value.renderDeferred.resolve()},w.focusFirstFocusableElement=function(e){return e.length>0?(e[0].focus(),!0):!1},w.focusLastFocusableElement=function(e){return e.length>0?(e[e.length-1].focus(),!0):!1},w.isModalFocused=function(e,t){if(e&&t){var n=t.value.modalDomEl;if(n&&n.length)return(e.target||e.srcElement)===n[0]}return!1},w.isFocusInFirstItem=function(e,t){return t.length>0?(e.target||e.srcElement)===t[0]:!1},w.isFocusInLastItem=function(e,t){return t.length>0?(e.target||e.srcElement)===t[t.length-1]:!1},w.loadFocusElementList=function(e){if(e){var t=e.value.modalDomEl;if(t&&t.length){var n=t[0].querySelectorAll(x);return n?Array.prototype.filter.call(n,function(e){return l(e)}):n}}},w}]).provider("$uibModal",function(){var e={options:{animation:!0,backdrop:!0,keyboard:!0},$get:["$rootScope","$q","$document","$templateRequest","$controller","$uibResolve","$uibModalStack",function(t,n,r,i,a,o,s){function l(e){return e.template?n.when(e.template):i(angular.isFunction(e.templateUrl)?e.templateUrl():e.templateUrl)}var u={},c=null;return u.getPromiseChain=function(){return c},u.open=function(i){function u(){return v}var f=n.defer(),d=n.defer(),p=n.defer(),h=n.defer(),m={result:f.promise,opened:d.promise,closed:p.promise,rendered:h.promise,close:function(e){return s.close(m,e)},dismiss:function(e){return s.dismiss(m,e)}};if(i=angular.extend({},e.options,i),i.resolve=i.resolve||{},i.appendTo=i.appendTo||r.find("body").eq(0),!i.template&&!i.templateUrl)throw new Error("One of template or templateUrl options is required.");var g,v=n.all([l(i),o.resolve(i.resolve,{},null,null)]);return g=c=n.all([c]).then(u,u).then(function(e){var n=i.scope||t,r=n.$new();r.$close=m.close,r.$dismiss=m.dismiss,r.$on("$destroy",function(){r.$$uibDestructionScheduled||r.$dismiss("$uibUnscheduledDestruction")});var o,l,u={};i.controller&&(u.$scope=r,u.$uibModalInstance=m,angular.forEach(e[1],function(e,t){u[t]=e}),l=a(i.controller,u,!0),i.controllerAs?(o=l.instance,i.bindToController&&(o.$close=r.$close,o.$dismiss=r.$dismiss,angular.extend(o,n)),o=l(),r[i.controllerAs]=o):o=l(),angular.isFunction(o.$onInit)&&o.$onInit()),s.open(m,{scope:r,deferred:f,renderDeferred:h,closedDeferred:p,content:e[0],animation:i.animation,backdrop:i.backdrop,keyboard:i.keyboard,backdropClass:i.backdropClass,windowTopClass:i.windowTopClass,windowClass:i.windowClass,windowTemplateUrl:i.windowTemplateUrl,size:i.size,openedClass:i.openedClass,appendTo:i.appendTo}),d.resolve(!0)},function(e){d.reject(e),f.reject(e)})["finally"](function(){c===g&&(c=null)}),m},u}]};return e}),angular.module("ui.bootstrap.paging",[]).factory("uibPaging",["$parse",function(e){return{create:function(t,n,r){t.setNumPages=r.numPages?e(r.numPages).assign:angular.noop,t.ngModelCtrl={$setViewValue:angular.noop},t._watchers=[],t.init=function(e,i){t.ngModelCtrl=e,t.config=i,e.$render=function(){t.render()},r.itemsPerPage?t._watchers.push(n.$parent.$watch(r.itemsPerPage,function(e){t.itemsPerPage=parseInt(e,10),n.totalPages=t.calculateTotalPages(),t.updatePage()})):t.itemsPerPage=i.itemsPerPage,n.$watch("totalItems",function(e,r){(angular.isDefined(e)||e!==r)&&(n.totalPages=t.calculateTotalPages(),t.updatePage())})},t.calculateTotalPages=function(){var e=t.itemsPerPage<1?1:Math.ceil(n.totalItems/t.itemsPerPage);return Math.max(e||0,1)},t.render=function(){n.page=parseInt(t.ngModelCtrl.$viewValue,10)||1},n.selectPage=function(e,r){r&&r.preventDefault();var i=!n.ngDisabled||!r;i&&n.page!==e&&e>0&&e<=n.totalPages&&(r&&r.target&&r.target.blur(),t.ngModelCtrl.$setViewValue(e),t.ngModelCtrl.$render())},n.getText=function(e){return n[e+"Text"]||t.config[e+"Text"]},n.noPrevious=function(){return 1===n.page},n.noNext=function(){return n.page===n.totalPages},t.updatePage=function(){t.setNumPages(n.$parent,n.totalPages),n.page>n.totalPages?n.selectPage(n.totalPages):t.ngModelCtrl.$render()},n.$on("$destroy",function(){for(;t._watchers.length;)t._watchers.shift()()})}}}]),angular.module("ui.bootstrap.pager",["ui.bootstrap.paging"]).controller("UibPagerController",["$scope","$attrs","uibPaging","uibPagerConfig",function(e,t,n,r){e.align=angular.isDefined(t.align)?e.$parent.$eval(t.align):r.align,n.create(this,e,t)}]).constant("uibPagerConfig",{itemsPerPage:10,previousText:"« Previous",nextText:"Next »",align:!0}).directive("uibPager",["uibPagerConfig",function(e){return{scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["uibPager","?ngModel"],controller:"UibPagerController",controllerAs:"pager",templateUrl:function(e,t){return t.templateUrl||"uib/template/pager/pager.html"},replace:!0,link:function(t,n,r,i){var a=i[0],o=i[1];o&&a.init(o,e)}}}]),angular.module("ui.bootstrap.pagination",["ui.bootstrap.paging"]).controller("UibPaginationController",["$scope","$attrs","$parse","uibPaging","uibPaginationConfig",function(e,t,n,r,i){function a(e,t,n){return{number:e,text:t,active:n}}function o(e,t){var n=[],r=1,i=t,o=angular.isDefined(l)&&t>l;o&&(u?(r=Math.max(e-Math.floor(l/2),1),i=r+l-1,i>t&&(i=t,r=i-l+1)):(r=(Math.ceil(e/l)-1)*l+1,i=Math.min(r+l-1,t)));for(var s=r;i>=s;s++){var p=a(s,d(s),s===e);n.push(p)}if(o&&l>0&&(!u||c||f)){if(r>1){if(!f||r>3){var h=a(r-1,"...",!1);n.unshift(h)}if(f){if(3===r){var m=a(2,"2",!1);n.unshift(m)}var g=a(1,"1",!1);n.unshift(g)}}if(t>i){if(!f||t-2>i){var v=a(i+1,"...",!1);n.push(v)}if(f){if(i===t-2){var b=a(t-1,t-1,!1);n.push(b)}var y=a(t,t,!1);n.push(y)}}}return n}var s=this,l=angular.isDefined(t.maxSize)?e.$parent.$eval(t.maxSize):i.maxSize,u=angular.isDefined(t.rotate)?e.$parent.$eval(t.rotate):i.rotate,c=angular.isDefined(t.forceEllipses)?e.$parent.$eval(t.forceEllipses):i.forceEllipses,f=angular.isDefined(t.boundaryLinkNumbers)?e.$parent.$eval(t.boundaryLinkNumbers):i.boundaryLinkNumbers,d=angular.isDefined(t.pageLabel)?function(n){return e.$parent.$eval(t.pageLabel,{$page:n})}:angular.identity;e.boundaryLinks=angular.isDefined(t.boundaryLinks)?e.$parent.$eval(t.boundaryLinks):i.boundaryLinks,e.directionLinks=angular.isDefined(t.directionLinks)?e.$parent.$eval(t.directionLinks):i.directionLinks,r.create(this,e,t),t.maxSize&&s._watchers.push(e.$parent.$watch(n(t.maxSize),function(e){l=parseInt(e,10),s.render()}));var p=this.render;this.render=function(){p(),e.page>0&&e.page<=e.totalPages&&(e.pages=o(e.page,e.totalPages))}}]).constant("uibPaginationConfig",{itemsPerPage:10,boundaryLinks:!1,boundaryLinkNumbers:!1,directionLinks:!0,firstText:"First",previousText:"Previous",nextText:"Next",lastText:"Last",rotate:!0,forceEllipses:!1}).directive("uibPagination",["$parse","uibPaginationConfig",function(e,t){return{scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",
ngDisabled:"="},require:["uibPagination","?ngModel"],controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(e,t){return t.templateUrl||"uib/template/pagination/pagination.html"},replace:!0,link:function(e,n,r,i){var a=i[0],o=i[1];o&&a.init(o,t)}}}]),angular.module("ui.bootstrap.tooltip",["ui.bootstrap.position","ui.bootstrap.stackedMap"]).provider("$uibTooltip",function(){function e(e){var t=/[A-Z]/g,n="-";return e.replace(t,function(e,t){return(t?n:"")+e.toLowerCase()})}var t={placement:"top",placementClassPrefix:"",animation:!0,popupDelay:0,popupCloseDelay:0,useContentExp:!1},n={mouseenter:"mouseleave",click:"click",outsideClick:"outsideClick",focus:"blur",none:""},r={};this.options=function(e){angular.extend(r,e)},this.setTriggers=function(e){angular.extend(n,e)},this.$get=["$window","$compile","$timeout","$document","$uibPosition","$interpolate","$rootScope","$parse","$$stackedMap",function(i,a,o,s,l,u,c,f,d){function p(e){if(27===e.which){var t=h.top();t&&(t.value.close(),h.removeTop(),t=null)}}var h=d.createNew();return s.on("keypress",p),c.$on("$destroy",function(){s.off("keypress",p)}),function(i,c,d,p){function m(e){var t=(e||p.trigger||d).split(" "),r=t.map(function(e){return n[e]||e});return{show:t,hide:r}}p=angular.extend({},t,r,p);var g=e(i),v=u.startSymbol(),b=u.endSymbol(),y="<div "+g+'-popup title="'+v+"title"+b+'" '+(p.useContentExp?'content-exp="contentExp()" ':'content="'+v+"content"+b+'" ')+'placement="'+v+"placement"+b+'" popup-class="'+v+"popupClass"+b+'" animation="animation" is-open="isOpen"origin-scope="origScope" class="uib-position-measure"></div>';return{compile:function(e,t){var n=a(y);return function(e,t,r,a){function u(){_.isOpen?g():d()}function d(){z&&!e.$eval(r[c+"Enable"])||($(),k(),_.popupDelay?N||(N=o(v,_.popupDelay,!1)):v())}function g(){b(),_.popupCloseDelay?j||(j=o(y,_.popupCloseDelay,!1)):y()}function v(){return b(),$(),_.content?(w(),void _.$evalAsync(function(){_.isOpen=!0,C(!0),W()})):angular.noop}function b(){N&&(o.cancel(N),N=null),L&&(o.cancel(L),L=null)}function y(){_&&_.$evalAsync(function(){_&&(_.isOpen=!1,C(!1),_.animation?A||(A=o(x,150,!1)):x())})}function $(){j&&(o.cancel(j),j=null),A&&(o.cancel(A),A=null)}function w(){E||(O=_.$new(),E=n(O,function(e){I?s.find("body").append(e):t.after(e)}),M())}function x(){b(),$(),S(),E&&(E.remove(),E=null),O&&(O.$destroy(),O=null)}function k(){_.title=r[c+"Title"],U?_.content=U(e):_.content=r[i],_.popupClass=r[c+"Class"],_.placement=angular.isDefined(r[c+"Placement"])?r[c+"Placement"]:p.placement;var t=l.parsePlacement(_.placement);P=t[1]?t[0]+"-"+t[1]:t[0];var n=parseInt(r[c+"PopupDelay"],10),a=parseInt(r[c+"PopupCloseDelay"],10);_.popupDelay=isNaN(n)?p.popupDelay:n,_.popupCloseDelay=isNaN(a)?p.popupCloseDelay:a}function C(t){H&&angular.isFunction(H.assign)&&H.assign(e,t)}function M(){V.length=0,U?(V.push(e.$watch(U,function(e){_.content=e,!e&&_.isOpen&&y()})),V.push(O.$watch(function(){R||(R=!0,O.$$postDigest(function(){R=!1,_&&_.isOpen&&W()}))}))):V.push(r.$observe(i,function(e){_.content=e,!e&&_.isOpen?y():W()})),V.push(r.$observe(c+"Title",function(e){_.title=e,_.isOpen&&W()})),V.push(r.$observe(c+"Placement",function(e){_.placement=e?e:p.placement;var t=l.parsePlacement(_.placement);P=t[1]?t[0]+"-"+t[1]:t[0],_.isOpen&&W()}))}function S(){V.length&&(angular.forEach(V,function(e){e()}),V.length=0)}function T(e){_&&_.isOpen&&E&&(t[0].contains(e.target)||E[0].contains(e.target)||g())}function D(){var e=r[c+"Trigger"];B(),F=m(e),"none"!==F.show&&F.show.forEach(function(e,n){"outsideClick"===e?(t.on("click",u),s.on("click",T)):e===F.hide[n]?t.on(e,u):e&&(t.on(e,d),t.on(F.hide[n],g)),t.on("keypress",function(e){27===e.which&&g()})})}var E,O,A,N,j,L,P,I=angular.isDefined(p.appendToBody)?p.appendToBody:!1,F=m(void 0),z=angular.isDefined(r[c+"Enable"]),_=e.$new(!0),R=!1,H=angular.isDefined(r[c+"IsOpen"])?f(r[c+"IsOpen"]):!1,U=p.useContentExp?f(r[i]):!1,V=[],W=function(){E&&E.html()&&(L||(L=o(function(){var e=l.positionElements(t,E,_.placement,I);E.css({top:e.top+"px",left:e.left+"px"}),E.hasClass(e.placement.split("-")[0])||(E.removeClass(P.split("-")[0]),E.addClass(e.placement.split("-")[0])),E.hasClass(p.placementClassPrefix+e.placement)||(E.removeClass(p.placementClassPrefix+P),E.addClass(p.placementClassPrefix+e.placement)),E.hasClass("uib-position-measure")?(l.positionArrow(E,e.placement),E.removeClass("uib-position-measure")):P!==e.placement&&l.positionArrow(E,e.placement),P=e.placement,L=null},0,!1)))};_.origScope=e,_.isOpen=!1,h.add(_,{close:y}),_.contentExp=function(){return _.content},r.$observe("disabled",function(e){e&&b(),e&&_.isOpen&&y()}),H&&e.$watch(H,function(e){_&&!e===_.isOpen&&u()});var B=function(){F.show.forEach(function(e){"outsideClick"===e?t.off("click",u):(t.off(e,d),t.off(e,u))}),F.hide.forEach(function(e){"outsideClick"===e?s.off("click",T):t.off(e,g)})};D();var q=e.$eval(r[c+"Animation"]);_.animation=angular.isDefined(q)?!!q:p.animation;var Y,G=c+"AppendToBody";Y=G in r&&void 0===r[G]?!0:e.$eval(r[G]),I=angular.isDefined(Y)?Y:I,e.$on("$destroy",function(){B(),x(),h.remove(_),_=null})}}}}}]}).directive("uibTooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest",function(e,t,n,r){return{link:function(i,a,o){var s,l,u,c=i.$eval(o.tooltipTemplateTranscludeScope),f=0,d=function(){l&&(l.remove(),l=null),s&&(s.$destroy(),s=null),u&&(e.leave(u).then(function(){l=null}),l=u,u=null)};i.$watch(t.parseAsResourceUrl(o.uibTooltipTemplateTransclude),function(t){var o=++f;t?(r(t,!0).then(function(r){if(o===f){var i=c.$new(),l=r,p=n(l)(i,function(t){d(),e.enter(t,a)});s=i,u=p,s.$emit("$includeContentLoaded",t)}},function(){o===f&&(d(),i.$emit("$includeContentError",t))}),i.$emit("$includeContentRequested",t)):d()}),i.$on("$destroy",d)}}}]).directive("uibTooltipClasses",["$uibPosition",function(e){return{restrict:"A",link:function(t,n,r){if(t.placement){var i=e.parsePlacement(t.placement);n.addClass(i[0])}t.popupClass&&n.addClass(t.popupClass),t.animation()&&n.addClass(r.tooltipAnimationClass)}}}]).directive("uibTooltipPopup",function(){return{replace:!0,scope:{content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"uib/template/tooltip/tooltip-popup.html"}}).directive("uibTooltip",["$uibTooltip",function(e){return e("uibTooltip","tooltip","mouseenter")}]).directive("uibTooltipTemplatePopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"uib/template/tooltip/tooltip-template-popup.html"}}).directive("uibTooltipTemplate",["$uibTooltip",function(e){return e("uibTooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("uibTooltipHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"uib/template/tooltip/tooltip-html-popup.html"}}).directive("uibTooltipHtml",["$uibTooltip",function(e){return e("uibTooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.popover",["ui.bootstrap.tooltip"]).directive("uibPopoverTemplatePopup",function(){return{replace:!0,scope:{title:"@",contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"uib/template/popover/popover-template.html"}}).directive("uibPopoverTemplate",["$uibTooltip",function(e){return e("uibPopoverTemplate","popover","click",{useContentExp:!0})}]).directive("uibPopoverHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",title:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"uib/template/popover/popover-html.html"}}).directive("uibPopoverHtml",["$uibTooltip",function(e){return e("uibPopoverHtml","popover","click",{useContentExp:!0})}]).directive("uibPopoverPopup",function(){return{replace:!0,scope:{title:"@",content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"uib/template/popover/popover.html"}}).directive("uibPopover",["$uibTooltip",function(e){return e("uibPopover","popover","click")}]),angular.module("ui.bootstrap.progressbar",[]).constant("uibProgressConfig",{animate:!0,max:100}).controller("UibProgressController",["$scope","$attrs","uibProgressConfig",function(e,t,n){function r(){return angular.isDefined(e.maxParam)?e.maxParam:n.max}var i=this,a=angular.isDefined(t.animate)?e.$parent.$eval(t.animate):n.animate;this.bars=[],e.max=r(),this.addBar=function(e,t,n){a||t.css({transition:"none"}),this.bars.push(e),e.max=r(),e.title=n&&angular.isDefined(n.title)?n.title:"progressbar",e.$watch("value",function(t){e.recalculatePercentage()}),e.recalculatePercentage=function(){var t=i.bars.reduce(function(e,t){return t.percent=+(100*t.value/t.max).toFixed(2),e+t.percent},0);t>100&&(e.percent-=t-100)},e.$on("$destroy",function(){t=null,i.removeBar(e)})},this.removeBar=function(e){this.bars.splice(this.bars.indexOf(e),1),this.bars.forEach(function(e){e.recalculatePercentage()})},e.$watch("maxParam",function(e){i.bars.forEach(function(e){e.max=r(),e.recalculatePercentage()})})}]).directive("uibProgress",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",require:"uibProgress",scope:{maxParam:"=?max"},templateUrl:"uib/template/progressbar/progress.html"}}).directive("uibBar",function(){return{replace:!0,transclude:!0,require:"^uibProgress",scope:{value:"=",type:"@"},templateUrl:"uib/template/progressbar/bar.html",link:function(e,t,n,r){r.addBar(e,t,n)}}}).directive("uibProgressbar",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",scope:{value:"=",maxParam:"=?max",type:"@"},templateUrl:"uib/template/progressbar/progressbar.html",link:function(e,t,n,r){r.addBar(e,angular.element(t.children()[0]),{title:n.title})}}}),angular.module("ui.bootstrap.rating",[]).constant("uibRatingConfig",{max:5,stateOn:null,stateOff:null,enableReset:!0,titles:["one","two","three","four","five"]}).controller("UibRatingController",["$scope","$attrs","uibRatingConfig",function(e,t,n){var r={$setViewValue:angular.noop},i=this;this.init=function(i){r=i,r.$render=this.render,r.$formatters.push(function(e){return angular.isNumber(e)&&e<<0!==e&&(e=Math.round(e)),e}),this.stateOn=angular.isDefined(t.stateOn)?e.$parent.$eval(t.stateOn):n.stateOn,this.stateOff=angular.isDefined(t.stateOff)?e.$parent.$eval(t.stateOff):n.stateOff,this.enableReset=angular.isDefined(t.enableReset)?e.$parent.$eval(t.enableReset):n.enableReset;var a=angular.isDefined(t.titles)?e.$parent.$eval(t.titles):n.titles;this.titles=angular.isArray(a)&&a.length>0?a:n.titles;var o=angular.isDefined(t.ratingStates)?e.$parent.$eval(t.ratingStates):new Array(angular.isDefined(t.max)?e.$parent.$eval(t.max):n.max);e.range=this.buildTemplateObjects(o)},this.buildTemplateObjects=function(e){for(var t=0,n=e.length;n>t;t++)e[t]=angular.extend({index:t},{stateOn:this.stateOn,stateOff:this.stateOff,title:this.getTitle(t)},e[t]);return e},this.getTitle=function(e){return e>=this.titles.length?e+1:this.titles[e]},e.rate=function(t){if(!e.readonly&&t>=0&&t<=e.range.length){var n=i.enableReset&&r.$viewValue===t?0:t;r.$setViewValue(n),r.$render()}},e.enter=function(t){e.readonly||(e.value=t),e.onHover({value:t})},e.reset=function(){e.value=r.$viewValue,e.onLeave()},e.onKeydown=function(t){/(37|38|39|40)/.test(t.which)&&(t.preventDefault(),t.stopPropagation(),e.rate(e.value+(38===t.which||39===t.which?1:-1)))},this.render=function(){e.value=r.$viewValue,e.title=i.getTitle(e.value-1)}}]).directive("uibRating",function(){return{require:["uibRating","ngModel"],scope:{readonly:"=?readOnly",onHover:"&",onLeave:"&"},controller:"UibRatingController",templateUrl:"uib/template/rating/rating.html",replace:!0,link:function(e,t,n,r){var i=r[0],a=r[1];i.init(a)}}}),angular.module("ui.bootstrap.tabs",[]).controller("UibTabsetController",["$scope",function(e){function t(e){for(var t=0;t<r.tabs.length;t++)if(r.tabs[t].index===e)return t}var n,r=this;r.tabs=[],r.select=function(e,a){if(!i){var o=t(n),s=r.tabs[o];s&&(s.tab.onDeselect({$event:a}),s.tab.active=!1);var l=r.tabs[e];l?(l.tab.onSelect({$event:a}),l.tab.active=!0,r.active=l.index,n=l.index):!l&&angular.isNumber(n)&&(r.active=null,n=null)}},r.addTab=function(e){if(r.tabs.push({tab:e,index:e.index}),r.tabs.sort(function(e,t){return e.index>t.index?1:e.index<t.index?-1:0}),e.index===r.active||!angular.isNumber(r.active)&&1===r.tabs.length){var n=t(e.index);r.select(n)}},r.removeTab=function(e){var n=t(e.index);if(e.index===r.active){var i=n===r.tabs.length-1?n-1:n+1%r.tabs.length;r.select(i)}r.tabs.splice(n,1)},e.$watch("tabset.active",function(e){angular.isNumber(e)&&e!==n&&r.select(t(e))});var i;e.$on("$destroy",function(){i=!0})}]).directive("uibTabset",function(){return{transclude:!0,replace:!0,scope:{},bindToController:{active:"=?",type:"@"},controller:"UibTabsetController",controllerAs:"tabset",templateUrl:function(e,t){return t.templateUrl||"uib/template/tabs/tabset.html"},link:function(e,t,n){e.vertical=angular.isDefined(n.vertical)?e.$parent.$eval(n.vertical):!1,e.justified=angular.isDefined(n.justified)?e.$parent.$eval(n.justified):!1,angular.isUndefined(n.active)&&(e.active=0)}}}).directive("uibTab",["$parse",function(e){return{require:"^uibTabset",replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/tabs/tab.html"},transclude:!0,scope:{heading:"@",index:"=?",classes:"@?",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},controllerAs:"tab",link:function(t,n,r,i,a){t.disabled=!1,r.disable&&t.$parent.$watch(e(r.disable),function(e){t.disabled=!!e}),angular.isUndefined(r.index)&&(i.tabs&&i.tabs.length?t.index=Math.max.apply(null,i.tabs.map(function(e){return e.index}))+1:t.index=0),angular.isUndefined(r.classes)&&(t.classes=""),t.select=function(e){if(!t.disabled){for(var n,r=0;r<i.tabs.length;r++)if(i.tabs[r].tab===t){n=r;break}i.select(n,e)}},i.addTab(t),t.$on("$destroy",function(){i.removeTab(t)}),t.$transcludeFn=a}}}]).directive("uibTabHeadingTransclude",function(){return{restrict:"A",require:"^uibTab",link:function(e,t){e.$watch("headingElement",function(e){e&&(t.html(""),t.append(e))})}}}).directive("uibTabContentTransclude",function(){function e(e){return e.tagName&&(e.hasAttribute("uib-tab-heading")||e.hasAttribute("data-uib-tab-heading")||e.hasAttribute("x-uib-tab-heading")||"uib-tab-heading"===e.tagName.toLowerCase()||"data-uib-tab-heading"===e.tagName.toLowerCase()||"x-uib-tab-heading"===e.tagName.toLowerCase()||"uib:tab-heading"===e.tagName.toLowerCase())}return{restrict:"A",require:"^uibTabset",link:function(t,n,r){var i=t.$eval(r.uibTabContentTransclude).tab;i.$transcludeFn(i.$parent,function(t){angular.forEach(t,function(t){e(t)?i.headingElement=t:n.append(t)})})}}}),angular.module("ui.bootstrap.timepicker",[]).constant("uibTimepickerConfig",{hourStep:1,minuteStep:1,secondStep:1,showMeridian:!0,showSeconds:!1,meridians:null,readonlyInput:!1,mousewheel:!0,arrowkeys:!0,showSpinners:!0,templateUrl:"uib/template/timepicker/timepicker.html"}).controller("UibTimepickerController",["$scope","$element","$attrs","$parse","$log","$locale","uibTimepickerConfig",function(e,t,n,r,i,a,o){function s(){var t=+e.hours,n=e.showMeridian?t>0&&13>t:t>=0&&24>t;return n?(e.showMeridian&&(12===t&&(t=0),e.meridian===$[1]&&(t+=12)),t):void 0}function l(){var t=+e.minutes;return t>=0&&60>t?t:void 0}function u(){var t=+e.seconds;return t>=0&&60>t?t:void 0}function c(e,t){return null===e?"":angular.isDefined(e)&&e.toString().length<2&&!t?"0"+e:e.toString()}function f(e){d(),y.$setViewValue(new Date(v)),p(e)}function d(){y.$setValidity("time",!0),e.invalidHours=!1,e.invalidMinutes=!1,e.invalidSeconds=!1}function p(t){if(y.$modelValue){var n=v.getHours(),r=v.getMinutes(),i=v.getSeconds();e.showMeridian&&(n=0===n||12===n?12:n%12),e.hours="h"===t?n:c(n,!w),"m"!==t&&(e.minutes=c(r)),e.meridian=v.getHours()<12?$[0]:$[1],"s"!==t&&(e.seconds=c(i)),e.meridian=v.getHours()<12?$[0]:$[1]}else e.hours=null,e.minutes=null,e.seconds=null,e.meridian=$[0]}function h(e){v=g(v,e),f()}function m(e,t){return g(e,60*t)}function g(e,t){var n=new Date(e.getTime()+1e3*t),r=new Date(e);return r.setHours(n.getHours(),n.getMinutes(),n.getSeconds()),r}var v=new Date,b=[],y={$setViewValue:angular.noop},$=angular.isDefined(n.meridians)?e.$parent.$eval(n.meridians):o.meridians||a.DATETIME_FORMATS.AMPMS,w=angular.isDefined(n.padHours)?e.$parent.$eval(n.padHours):!0;e.tabindex=angular.isDefined(n.tabindex)?n.tabindex:0,t.removeAttr("tabindex"),this.init=function(t,r){y=t,y.$render=this.render,y.$formatters.unshift(function(e){return e?new Date(e):null});var i=r.eq(0),a=r.eq(1),s=r.eq(2),l=angular.isDefined(n.mousewheel)?e.$parent.$eval(n.mousewheel):o.mousewheel;l&&this.setupMousewheelEvents(i,a,s);var u=angular.isDefined(n.arrowkeys)?e.$parent.$eval(n.arrowkeys):o.arrowkeys;u&&this.setupArrowkeyEvents(i,a,s),e.readonlyInput=angular.isDefined(n.readonlyInput)?e.$parent.$eval(n.readonlyInput):o.readonlyInput,this.setupInputEvents(i,a,s)};var x=o.hourStep;n.hourStep&&b.push(e.$parent.$watch(r(n.hourStep),function(e){x=+e}));var k=o.minuteStep;n.minuteStep&&b.push(e.$parent.$watch(r(n.minuteStep),function(e){k=+e}));var C;b.push(e.$parent.$watch(r(n.min),function(e){var t=new Date(e);C=isNaN(t)?void 0:t}));var M;b.push(e.$parent.$watch(r(n.max),function(e){var t=new Date(e);M=isNaN(t)?void 0:t}));var S=!1;n.ngDisabled&&b.push(e.$parent.$watch(r(n.ngDisabled),function(e){S=e})),e.noIncrementHours=function(){var e=m(v,60*x);return S||e>M||v>e&&C>e},e.noDecrementHours=function(){var e=m(v,60*-x);return S||C>e||e>v&&e>M},e.noIncrementMinutes=function(){var e=m(v,k);return S||e>M||v>e&&C>e},e.noDecrementMinutes=function(){var e=m(v,-k);return S||C>e||e>v&&e>M},e.noIncrementSeconds=function(){var e=g(v,T);return S||e>M||v>e&&C>e},e.noDecrementSeconds=function(){var e=g(v,-T);return S||C>e||e>v&&e>M},e.noToggleMeridian=function(){return v.getHours()<12?S||m(v,720)>M:S||m(v,-720)<C};var T=o.secondStep;n.secondStep&&b.push(e.$parent.$watch(r(n.secondStep),function(e){T=+e})),e.showSeconds=o.showSeconds,n.showSeconds&&b.push(e.$parent.$watch(r(n.showSeconds),function(t){e.showSeconds=!!t})),e.showMeridian=o.showMeridian,n.showMeridian&&b.push(e.$parent.$watch(r(n.showMeridian),function(t){if(e.showMeridian=!!t,y.$error.time){var n=s(),r=l();angular.isDefined(n)&&angular.isDefined(r)&&(v.setHours(n),f())}else p()})),this.setupMousewheelEvents=function(t,n,r){var i=function(e){e.originalEvent&&(e=e.originalEvent);var t=e.wheelDelta?e.wheelDelta:-e.deltaY;return e.detail||t>0};t.bind("mousewheel wheel",function(t){S||e.$apply(i(t)?e.incrementHours():e.decrementHours()),t.preventDefault()}),n.bind("mousewheel wheel",function(t){S||e.$apply(i(t)?e.incrementMinutes():e.decrementMinutes()),t.preventDefault()}),r.bind("mousewheel wheel",function(t){S||e.$apply(i(t)?e.incrementSeconds():e.decrementSeconds()),t.preventDefault()})},this.setupArrowkeyEvents=function(t,n,r){t.bind("keydown",function(t){S||(38===t.which?(t.preventDefault(),e.incrementHours(),e.$apply()):40===t.which&&(t.preventDefault(),e.decrementHours(),e.$apply()))}),n.bind("keydown",function(t){S||(38===t.which?(t.preventDefault(),e.incrementMinutes(),e.$apply()):40===t.which&&(t.preventDefault(),e.decrementMinutes(),e.$apply()))}),r.bind("keydown",function(t){S||(38===t.which?(t.preventDefault(),e.incrementSeconds(),e.$apply()):40===t.which&&(t.preventDefault(),e.decrementSeconds(),e.$apply()))})},this.setupInputEvents=function(t,n,r){if(e.readonlyInput)return e.updateHours=angular.noop,e.updateMinutes=angular.noop,void(e.updateSeconds=angular.noop);var i=function(t,n,r){y.$setViewValue(null),y.$setValidity("time",!1),angular.isDefined(t)&&(e.invalidHours=t),angular.isDefined(n)&&(e.invalidMinutes=n),angular.isDefined(r)&&(e.invalidSeconds=r)};e.updateHours=function(){var e=s(),t=l();y.$setDirty(),angular.isDefined(e)&&angular.isDefined(t)?(v.setHours(e),v.setMinutes(t),C>v||v>M?i(!0):f("h")):i(!0)},t.bind("blur",function(t){y.$setTouched(),null===e.hours||""===e.hours?i(!0):!e.invalidHours&&e.hours<10&&e.$apply(function(){e.hours=c(e.hours,!w)})}),e.updateMinutes=function(){var e=l(),t=s();y.$setDirty(),angular.isDefined(e)&&angular.isDefined(t)?(v.setHours(t),v.setMinutes(e),C>v||v>M?i(void 0,!0):f("m")):i(void 0,!0)},n.bind("blur",function(t){y.$setTouched(),null===e.minutes?i(void 0,!0):!e.invalidMinutes&&e.minutes<10&&e.$apply(function(){e.minutes=c(e.minutes)})}),e.updateSeconds=function(){var e=u();y.$setDirty(),angular.isDefined(e)?(v.setSeconds(e),f("s")):i(void 0,void 0,!0)},r.bind("blur",function(t){!e.invalidSeconds&&e.seconds<10&&e.$apply(function(){e.seconds=c(e.seconds)})})},this.render=function(){var t=y.$viewValue;isNaN(t)?(y.$setValidity("time",!1),i.error('Timepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')):(t&&(v=t),C>v||v>M?(y.$setValidity("time",!1),e.invalidHours=!0,e.invalidMinutes=!0):d(),p())},e.showSpinners=angular.isDefined(n.showSpinners)?e.$parent.$eval(n.showSpinners):o.showSpinners,e.incrementHours=function(){e.noIncrementHours()||h(60*x*60)},e.decrementHours=function(){e.noDecrementHours()||h(60*-x*60)},e.incrementMinutes=function(){e.noIncrementMinutes()||h(60*k)},e.decrementMinutes=function(){e.noDecrementMinutes()||h(60*-k)},e.incrementSeconds=function(){e.noIncrementSeconds()||h(T)},e.decrementSeconds=function(){e.noDecrementSeconds()||h(-T)},e.toggleMeridian=function(){var t=l(),n=s();e.noToggleMeridian()||(angular.isDefined(t)&&angular.isDefined(n)?h(720*(v.getHours()<12?60:-60)):e.meridian=e.meridian===$[0]?$[1]:$[0])},e.blur=function(){y.$setTouched()},e.$on("$destroy",function(){for(;b.length;)b.shift()()})}]).directive("uibTimepicker",["uibTimepickerConfig",function(e){return{require:["uibTimepicker","?^ngModel"],controller:"UibTimepickerController",controllerAs:"timepicker",replace:!0,scope:{},templateUrl:function(t,n){return n.templateUrl||e.templateUrl},link:function(e,t,n,r){var i=r[0],a=r[1];a&&i.init(a,t.find("input"))}}}]),angular.module("ui.bootstrap.typeahead",["ui.bootstrap.debounce","ui.bootstrap.position"]).factory("uibTypeaheadParser",["$parse",function(e){var t=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w\d]*))\s+in\s+([\s\S]+?)$/;return{parse:function(n){var r=n.match(t);if(!r)throw new Error('Expected typeahead specification in form of "_modelValue_ (as _label_)? for _item_ in _collection_" but got "'+n+'".');return{itemName:r[3],source:e(r[4]),viewMapper:e(r[2]||r[1]),modelMapper:e(r[1])}}}}]).controller("UibTypeaheadController",["$scope","$element","$attrs","$compile","$parse","$q","$timeout","$document","$window","$rootScope","$$debounce","$uibPosition","uibTypeaheadParser",function(e,t,n,r,i,a,o,s,l,u,c,f,d){function p(){_.moveInProgress||(_.moveInProgress=!0,_.$digest()),K()}function h(){_.position=E?f.offset(t):f.position(t),_.position.top+=t.prop("offsetHeight")}var m,g,v=[9,13,27,38,40],b=200,y=e.$eval(n.typeaheadMinLength);y||0===y||(y=1),e.$watch(n.typeaheadMinLength,function(e){y=e||0===e?e:1});var $=e.$eval(n.typeaheadWaitMs)||0,w=e.$eval(n.typeaheadEditable)!==!1;e.$watch(n.typeaheadEditable,function(e){w=e!==!1});var x,k,C=i(n.typeaheadLoading).assign||angular.noop,M=i(n.typeaheadOnSelect),S=angular.isDefined(n.typeaheadSelectOnBlur)?e.$eval(n.typeaheadSelectOnBlur):!1,T=i(n.typeaheadNoResults).assign||angular.noop,D=n.typeaheadInputFormatter?i(n.typeaheadInputFormatter):void 0,E=n.typeaheadAppendToBody?e.$eval(n.typeaheadAppendToBody):!1,O=n.typeaheadAppendTo?e.$eval(n.typeaheadAppendTo):null,A=e.$eval(n.typeaheadFocusFirst)!==!1,N=n.typeaheadSelectOnExact?e.$eval(n.typeaheadSelectOnExact):!1,j=i(n.typeaheadIsOpen).assign||angular.noop,L=e.$eval(n.typeaheadShowHint)||!1,P=i(n.ngModel),I=i(n.ngModel+"($$$p)"),F=function(t,n){return angular.isFunction(P(e))&&g&&g.$options&&g.$options.getterSetter?I(t,{$$$p:n}):P.assign(t,n)},z=d.parse(n.uibTypeahead),_=e.$new(),R=e.$on("$destroy",function(){_.$destroy()});_.$on("$destroy",R);var H="typeahead-"+_.$id+"-"+Math.floor(1e4*Math.random());t.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":H});var U,V;L&&(U=angular.element("<div></div>"),U.css("position","relative"),t.after(U),V=t.clone(),V.attr("placeholder",""),V.attr("tabindex","-1"),V.val(""),V.css({position:"absolute",top:"0px",left:"0px","border-color":"transparent","box-shadow":"none",opacity:1,background:"none 0% 0% / auto repeat scroll padding-box border-box rgb(255, 255, 255)",color:"#999"}),t.css({position:"relative","vertical-align":"top","background-color":"transparent"}),U.append(V),V.after(t));var W=angular.element("<div uib-typeahead-popup></div>");W.attr({id:H,matches:"matches",active:"activeIdx",select:"select(activeIdx, evt)","move-in-progress":"moveInProgress",query:"query",position:"position","assign-is-open":"assignIsOpen(isOpen)",debounce:"debounceUpdate"}),angular.isDefined(n.typeaheadTemplateUrl)&&W.attr("template-url",n.typeaheadTemplateUrl),angular.isDefined(n.typeaheadPopupTemplateUrl)&&W.attr("popup-template-url",n.typeaheadPopupTemplateUrl);var B=function(){L&&V.val("")},q=function(){_.matches=[],_.activeIdx=-1,t.attr("aria-expanded",!1),B()},Y=function(e){return H+"-option-"+e};_.$watch("activeIdx",function(e){0>e?t.removeAttr("aria-activedescendant"):t.attr("aria-activedescendant",Y(e))});var G=function(e,t){return _.matches.length>t&&e?e.toUpperCase()===_.matches[t].label.toUpperCase():!1},X=function(n,r){var i={$viewValue:n};C(e,!0),T(e,!1),a.when(z.source(e,i)).then(function(a){var o=n===m.$viewValue;if(o&&x)if(a&&a.length>0){_.activeIdx=A?0:-1,T(e,!1),_.matches.length=0;for(var s=0;s<a.length;s++)i[z.itemName]=a[s],_.matches.push({id:Y(s),label:z.viewMapper(_,i),model:a[s]});if(_.query=n,h(),t.attr("aria-expanded",!0),N&&1===_.matches.length&&G(n,0)&&(angular.isNumber(_.debounceUpdate)||angular.isObject(_.debounceUpdate)?c(function(){_.select(0,r)},angular.isNumber(_.debounceUpdate)?_.debounceUpdate:_.debounceUpdate["default"]):_.select(0,r)),L){var l=_.matches[0].label;angular.isString(n)&&n.length>0&&l.slice(0,n.length).toUpperCase()===n.toUpperCase()?V.val(n+l.slice(n.length)):V.val("")}}else q(),T(e,!0);o&&C(e,!1)},function(){q(),C(e,!1),T(e,!0)})};E&&(angular.element(l).on("resize",p),s.find("body").on("scroll",p));var K=c(function(){_.matches.length&&h(),_.moveInProgress=!1},b);_.moveInProgress=!1,_.query=void 0;var J,Z=function(e){J=o(function(){X(e)},$)},Q=function(){J&&o.cancel(J)};q(),_.assignIsOpen=function(t){j(e,t)},_.select=function(r,i){var a,s,l={};k=!0,l[z.itemName]=s=_.matches[r].model,a=z.modelMapper(e,l),F(e,a),m.$setValidity("editable",!0),m.$setValidity("parse",!0),M(e,{$item:s,$model:a,$label:z.viewMapper(e,l),$event:i}),q(),_.$eval(n.typeaheadFocusOnSelect)!==!1&&o(function(){t[0].focus()},0,!1)},t.on("keydown",function(t){if(0!==_.matches.length&&-1!==v.indexOf(t.which)){if(-1===_.activeIdx&&(9===t.which||13===t.which)||9===t.which&&t.shiftKey)return q(),void _.$digest();t.preventDefault();var n;switch(t.which){case 9:case 13:_.$apply(function(){angular.isNumber(_.debounceUpdate)||angular.isObject(_.debounceUpdate)?c(function(){_.select(_.activeIdx,t)},angular.isNumber(_.debounceUpdate)?_.debounceUpdate:_.debounceUpdate["default"]):_.select(_.activeIdx,t)});break;case 27:t.stopPropagation(),q(),e.$digest();break;case 38:_.activeIdx=(_.activeIdx>0?_.activeIdx:_.matches.length)-1,_.$digest(),n=W.find("li")[_.activeIdx],n.parentNode.scrollTop=n.offsetTop;break;case 40:_.activeIdx=(_.activeIdx+1)%_.matches.length,_.$digest(),n=W.find("li")[_.activeIdx],n.parentNode.scrollTop=n.offsetTop}}}),t.bind("focus",function(e){x=!0,0!==y||m.$viewValue||o(function(){X(m.$viewValue,e)},0)}),t.bind("blur",function(e){S&&_.matches.length&&-1!==_.activeIdx&&!k&&(k=!0,_.$apply(function(){angular.isObject(_.debounceUpdate)&&angular.isNumber(_.debounceUpdate.blur)?c(function(){_.select(_.activeIdx,e)},_.debounceUpdate.blur):_.select(_.activeIdx,e)})),!w&&m.$error.editable&&(m.$viewValue="",m.$setValidity("editable",!0),m.$setValidity("parse",!0),t.val("")),x=!1,k=!1});var ee=function(n){t[0]!==n.target&&3!==n.which&&0!==_.matches.length&&(q(),u.$$phase||e.$digest())};s.on("click",ee),e.$on("$destroy",function(){s.off("click",ee),(E||O)&&te.remove(),E&&(angular.element(l).off("resize",p),s.find("body").off("scroll",p)),W.remove(),L&&U.remove()});var te=r(W)(_);E?s.find("body").append(te):O?angular.element(O).eq(0).append(te):t.after(te),this.init=function(t,n){m=t,g=n,_.debounceUpdate=m.$options&&i(m.$options.debounce)(e),m.$parsers.unshift(function(t){return x=!0,0===y||t&&t.length>=y?$>0?(Q(),Z(t)):X(t):(C(e,!1),Q(),q()),w?t:t?void m.$setValidity("editable",!1):(m.$setValidity("editable",!0),null)}),m.$formatters.push(function(t){var n,r,i={};return w||m.$setValidity("editable",!0),D?(i.$model=t,D(e,i)):(i[z.itemName]=t,n=z.viewMapper(e,i),i[z.itemName]=void 0,r=z.viewMapper(e,i),n!==r?n:t)})}}]).directive("uibTypeahead",function(){return{controller:"UibTypeaheadController",require:["ngModel","^?ngModelOptions","uibTypeahead"],link:function(e,t,n,r){r[2].init(r[0],r[1])}}}).directive("uibTypeaheadPopup",["$$debounce",function(e){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&",assignIsOpen:"&",debounce:"&"},replace:!0,templateUrl:function(e,t){return t.popupTemplateUrl||"uib/template/typeahead/typeahead-popup.html"},link:function(t,n,r){t.templateUrl=r.templateUrl,t.isOpen=function(){var e=t.matches.length>0;return t.assignIsOpen({isOpen:e}),e},t.isActive=function(e){return t.active===e},t.selectActive=function(e){t.active=e},t.selectMatch=function(n,r){var i=t.debounce();angular.isNumber(i)||angular.isObject(i)?e(function(){t.select({activeIdx:n,evt:r})},angular.isNumber(i)?i:i["default"]):t.select({activeIdx:n,evt:r})}}}}]).directive("uibTypeaheadMatch",["$templateRequest","$compile","$parse",function(e,t,n){return{scope:{index:"=",match:"=",query:"="},link:function(r,i,a){var o=n(a.templateUrl)(r.$parent)||"uib/template/typeahead/typeahead-match.html";e(o).then(function(e){var n=angular.element(e.trim());i.replaceWith(n),t(n)(r)})}}}]).filter("uibTypeaheadHighlight",["$sce","$injector","$log",function(e,t,n){function r(e){return e.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}function i(e){return/<.*>/g.test(e)}var a;return a=t.has("$sanitize"),function(t,o){return!a&&i(t)&&n.warn("Unsafe use of typeahead please use ngSanitize"),t=o?(""+t).replace(new RegExp(r(o),"gi"),"<strong>$&</strong>"):t,a||(t=e.trustAsHtml(t)),t}}]),angular.module("uib/template/accordion/accordion-group.html",[]).run(["$templateCache",function(e){e.put("uib/template/accordion/accordion-group.html",'<div class="panel" ng-class="panelClass || \'panel-default\'">\n <div role="tab" id="{{::headingId}}" aria-selected="{{isOpen}}" class="panel-heading" ng-keypress="toggleOpen($event)">\n <h4 class="panel-title">\n <a role="button" data-toggle="collapse" href aria-expanded="{{isOpen}}" aria-controls="{{::panelId}}" tabindex="0" class="accordion-toggle" ng-click="toggleOpen()" uib-accordion-transclude="heading"><span uib-accordion-header ng-class="{\'text-muted\': isDisabled}">{{heading}}</span></a>\n </h4>\n </div>\n <div id="{{::panelId}}" aria-labelledby="{{::headingId}}" aria-hidden="{{!isOpen}}" role="tabpanel" class="panel-collapse collapse" uib-collapse="!isOpen">\n <div class="panel-body" ng-transclude></div>\n </div>\n</div>\n')}]),angular.module("uib/template/accordion/accordion.html",[]).run(["$templateCache",function(e){e.put("uib/template/accordion/accordion.html",'<div role="tablist" class="panel-group" ng-transclude></div>')}]),angular.module("uib/template/alert/alert.html",[]).run(["$templateCache",function(e){e.put("uib/template/alert/alert.html",'<div class="alert" ng-class="[\'alert-\' + (type || \'warning\'), closeable ? \'alert-dismissible\' : null]" role="alert">\n <button ng-show="closeable" type="button" class="close" ng-click="close({$event: $event})">\n <span aria-hidden="true">&times;</span>\n <span class="sr-only">Close</span>\n </button>\n <div ng-transclude></div>\n</div>\n');
}]),angular.module("uib/template/carousel/carousel.html",[]).run(["$templateCache",function(e){e.put("uib/template/carousel/carousel.html",'<div ng-mouseenter="pause()" ng-mouseleave="play()" class="carousel" ng-swipe-right="prev()" ng-swipe-left="next()">\n <div class="carousel-inner" ng-transclude></div>\n <a role="button" href class="left carousel-control" ng-click="prev()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-left"></span>\n <span class="sr-only">previous</span>\n </a>\n <a role="button" href class="right carousel-control" ng-click="next()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-right"></span>\n <span class="sr-only">next</span>\n </a>\n <ol class="carousel-indicators" ng-show="slides.length > 1">\n <li ng-repeat="slide in slides | orderBy:indexOfSlide track by $index" ng-class="{ active: isActive(slide) }" ng-click="select(slide)">\n <span class="sr-only">slide {{ $index + 1 }} of {{ slides.length }}<span ng-if="isActive(slide)">, currently active</span></span>\n </li>\n </ol>\n</div>\n')}]),angular.module("uib/template/carousel/slide.html",[]).run(["$templateCache",function(e){e.put("uib/template/carousel/slide.html",'<div ng-class="{\n \'active\': active\n }" class="item text-center" ng-transclude></div>\n')}]),angular.module("uib/template/datepicker/datepicker.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/datepicker.html",'<div class="uib-datepicker" ng-switch="datepickerMode" role="application" ng-keydown="keydown($event)">\n <uib-daypicker ng-switch-when="day" tabindex="0"></uib-daypicker>\n <uib-monthpicker ng-switch-when="month" tabindex="0"></uib-monthpicker>\n <uib-yearpicker ng-switch-when="year" tabindex="0"></uib-yearpicker>\n</div>\n')}]),angular.module("uib/template/datepicker/day.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/day.html",'<table class="uib-daypicker" role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::5 + showWeeks}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n <tr>\n <th ng-if="showWeeks" class="text-center"></th>\n <th ng-repeat="label in ::labels track by $index" class="text-center"><small aria-label="{{::label.full}}">{{::label.abbr}}</small></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-weeks" ng-repeat="row in rows track by $index">\n <td ng-if="showWeeks" class="text-center h6"><em>{{ weekNumbers[$index] }}</em></td>\n <td ng-repeat="dt in row" class="uib-day text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default btn-sm"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-muted\': dt.secondary, \'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/datepicker/month.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/month.html",'<table class="uib-monthpicker" role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-months" ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row" class="uib-month text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/datepicker/popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/popup.html",'<div>\n <ul class="uib-datepicker-popup dropdown-menu uib-position-measure" dropdown-nested ng-if="isOpen" ng-keydown="keydown($event)" ng-click="$event.stopPropagation()">\n <li ng-transclude></li>\n <li ng-if="showButtonBar" class="uib-button-bar">\n <span class="btn-group pull-left">\n <button type="button" class="btn btn-sm btn-info uib-datepicker-current" ng-click="select(\'today\', $event)" ng-disabled="isDisabled(\'today\')">{{ getText(\'current\') }}</button>\n <button type="button" class="btn btn-sm btn-danger uib-clear" ng-click="select(null, $event)">{{ getText(\'clear\') }}</button>\n </span>\n <button type="button" class="btn btn-sm btn-success pull-right uib-close" ng-click="close($event)">{{ getText(\'close\') }}</button>\n </li>\n </ul>\n</div>\n')}]),angular.module("uib/template/datepicker/year.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/year.html",'<table class="uib-yearpicker" role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::columns - 2}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-years" ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row" class="uib-year text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/modal/backdrop.html",[]).run(["$templateCache",function(e){e.put("uib/template/modal/backdrop.html",'<div class="modal-backdrop"\n uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1040 + (index && 1 || 0) + index*10}"\n></div>\n')}]),angular.module("uib/template/modal/window.html",[]).run(["$templateCache",function(e){e.put("uib/template/modal/window.html",'<div modal-render="{{$isRendered}}" tabindex="-1" role="dialog" class="modal"\n uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1050 + index*10, display: \'block\'}">\n <div class="modal-dialog {{size ? \'modal-\' + size : \'\'}}"><div class="modal-content" uib-modal-transclude></div></div>\n</div>\n')}]),angular.module("uib/template/pager/pager.html",[]).run(["$templateCache",function(e){e.put("uib/template/pager/pager.html",'<ul class="pager">\n <li ng-class="{disabled: noPrevious()||ngDisabled, previous: align}"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-class="{disabled: noNext()||ngDisabled, next: align}"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n</ul>\n')}]),angular.module("uib/template/pagination/pager.html",[]).run(["$templateCache",function(e){e.put("uib/template/pagination/pager.html",'<ul class="pager">\n <li ng-class="{disabled: noPrevious()||ngDisabled, previous: align}"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-class="{disabled: noNext()||ngDisabled, next: align}"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n</ul>\n')}]),angular.module("uib/template/pagination/pagination.html",[]).run(["$templateCache",function(e){e.put("uib/template/pagination/pagination.html",'<ul class="pagination">\n <li ng-if="::boundaryLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-first"><a href ng-click="selectPage(1, $event)">{{::getText(\'first\')}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-prev"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-repeat="page in pages track by $index" ng-class="{active: page.active,disabled: ngDisabled&&!page.active}" class="pagination-page"><a href ng-click="selectPage(page.number, $event)">{{page.text}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-next"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n <li ng-if="::boundaryLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-last"><a href ng-click="selectPage(totalPages, $event)">{{::getText(\'last\')}}</a></li>\n</ul>\n')}]),angular.module("uib/template/tooltip/tooltip-html-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-html-popup.html",'<div class="tooltip"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind-html="contentExp()"></div>\n</div>\n')}]),angular.module("uib/template/tooltip/tooltip-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-popup.html",'<div class="tooltip"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind="content"></div>\n</div>\n')}]),angular.module("uib/template/tooltip/tooltip-template-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-template-popup.html",'<div class="tooltip"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n</div>\n')}]),angular.module("uib/template/popover/popover-html.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover-html.html",'<div class="popover"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind-html="contentExp()"></div>\n </div>\n</div>\n')}]),angular.module("uib/template/popover/popover-template.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover-template.html",'<div class="popover"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n </div>\n</div>\n')}]),angular.module("uib/template/popover/popover.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover.html",'<div class="popover"\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind="content"></div>\n </div>\n</div>\n')}]),angular.module("uib/template/progressbar/bar.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/bar.html",'<div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" ng-transclude></div>\n')}]),angular.module("uib/template/progressbar/progress.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/progress.html",'<div class="progress" ng-transclude aria-labelledby="{{::title}}"></div>')}]),angular.module("uib/template/progressbar/progressbar.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/progressbar.html",'<div class="progress">\n <div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" ng-transclude></div>\n</div>\n')}]),angular.module("uib/template/rating/rating.html",[]).run(["$templateCache",function(e){e.put("uib/template/rating/rating.html",'<span ng-mouseleave="reset()" ng-keydown="onKeydown($event)" tabindex="0" role="slider" aria-valuemin="0" aria-valuemax="{{range.length}}" aria-valuenow="{{value}}" aria-valuetext="{{title}}">\n <span ng-repeat-start="r in range track by $index" class="sr-only">({{ $index < value ? \'*\' : \' \' }})</span>\n <i ng-repeat-end ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || \'glyphicon-star\') || (r.stateOff || \'glyphicon-star-empty\')" ng-attr-title="{{r.title}}"></i>\n</span>\n')}]),angular.module("uib/template/tabs/tab.html",[]).run(["$templateCache",function(e){e.put("uib/template/tabs/tab.html",'<li ng-class="[{active: active, disabled: disabled}, classes]" class="uib-tab nav-item">\n <a href ng-click="select($event)" class="nav-link" uib-tab-heading-transclude>{{heading}}</a>\n</li>\n')}]),angular.module("uib/template/tabs/tabset.html",[]).run(["$templateCache",function(e){e.put("uib/template/tabs/tabset.html",'<div>\n <ul class="nav nav-{{tabset.type || \'tabs\'}}" ng-class="{\'nav-stacked\': vertical, \'nav-justified\': justified}" ng-transclude></ul>\n <div class="tab-content">\n <div class="tab-pane"\n ng-repeat="tab in tabset.tabs"\n ng-class="{active: tabset.active === tab.index}"\n uib-tab-content-transclude="tab">\n </div>\n </div>\n</div>\n')}]),angular.module("uib/template/timepicker/timepicker.html",[]).run(["$templateCache",function(e){e.put("uib/template/timepicker/timepicker.html",'<table class="uib-timepicker">\n <tbody>\n <tr class="text-center" ng-show="::showSpinners">\n <td class="uib-increment hours"><a ng-click="incrementHours()" ng-class="{disabled: noIncrementHours()}" class="btn btn-link" ng-disabled="noIncrementHours()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td>&nbsp;</td>\n <td class="uib-increment minutes"><a ng-click="incrementMinutes()" ng-class="{disabled: noIncrementMinutes()}" class="btn btn-link" ng-disabled="noIncrementMinutes()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showSeconds">&nbsp;</td>\n <td ng-show="showSeconds" class="uib-increment seconds"><a ng-click="incrementSeconds()" ng-class="{disabled: noIncrementSeconds()}" class="btn btn-link" ng-disabled="noIncrementSeconds()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n <tr>\n <td class="form-group uib-time hours" ng-class="{\'has-error\': invalidHours}">\n <input style="width:50px;" type="text" placeholder="HH" ng-model="hours" ng-change="updateHours()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementHours()" ng-blur="blur()">\n </td>\n <td class="uib-separator">:</td>\n <td class="form-group uib-time minutes" ng-class="{\'has-error\': invalidMinutes}">\n <input style="width:50px;" type="text" placeholder="MM" ng-model="minutes" ng-change="updateMinutes()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementMinutes()" ng-blur="blur()">\n </td>\n <td ng-show="showSeconds" class="uib-separator">:</td>\n <td class="form-group uib-time seconds" ng-class="{\'has-error\': invalidSeconds}" ng-show="showSeconds">\n <input style="width:50px;" type="text" placeholder="SS" ng-model="seconds" ng-change="updateSeconds()" class="form-control text-center" ng-readonly="readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementSeconds()" ng-blur="blur()">\n </td>\n <td ng-show="showMeridian" class="uib-time am-pm"><button type="button" ng-class="{disabled: noToggleMeridian()}" class="btn btn-default text-center" ng-click="toggleMeridian()" ng-disabled="noToggleMeridian()" tabindex="{{::tabindex}}">{{meridian}}</button></td>\n </tr>\n <tr class="text-center" ng-show="::showSpinners">\n <td class="uib-decrement hours"><a ng-click="decrementHours()" ng-class="{disabled: noDecrementHours()}" class="btn btn-link" ng-disabled="noDecrementHours()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td>&nbsp;</td>\n <td class="uib-decrement minutes"><a ng-click="decrementMinutes()" ng-class="{disabled: noDecrementMinutes()}" class="btn btn-link" ng-disabled="noDecrementMinutes()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showSeconds">&nbsp;</td>\n <td ng-show="showSeconds" class="uib-decrement seconds"><a ng-click="decrementSeconds()" ng-class="{disabled: noDecrementSeconds()}" class="btn btn-link" ng-disabled="noDecrementSeconds()" tabindex="{{::tabindex}}"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/typeahead/typeahead-match.html",[]).run(["$templateCache",function(e){e.put("uib/template/typeahead/typeahead-match.html",'<a href\n tabindex="-1"\n ng-bind-html="match.label | uibTypeaheadHighlight:query"\n ng-attr-title="{{match.label}}"></a>\n')}]),angular.module("uib/template/typeahead/typeahead-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/typeahead/typeahead-popup.html",'<ul class="dropdown-menu" ng-show="isOpen() && !moveInProgress" ng-style="{top: position().top+\'px\', left: position().left+\'px\'}" role="listbox" aria-hidden="{{!isOpen()}}">\n <li ng-repeat="match in matches track by $index" ng-class="{active: isActive($index) }" ng-mouseenter="selectActive($index)" ng-click="selectMatch($index, $event)" role="option" id="{{::match.id}}">\n <div uib-typeahead-match index="$index" match="match" query="query" template-url="templateUrl"></div>\n </li>\n</ul>\n')}]),angular.module("ui.bootstrap.carousel").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibCarouselCss&&angular.element(document).find("head").prepend('<style type="text/css">.ng-animate.item:not(.left):not(.right){-webkit-transition:0s ease-in-out left;transition:0s ease-in-out left}</style>'),angular.$$uibCarouselCss=!0}),angular.module("ui.bootstrap.position").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibPositionCss&&angular.element(document).find("head").prepend('<style type="text/css">.uib-position-measure{display:block !important;visibility:hidden !important;position:absolute !important;top:-9999px !important;left:-9999px !important;}.uib-position-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll;}</style>'),angular.$$uibPositionCss=!0}),angular.module("ui.bootstrap.datepicker").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibDatepickerCss&&angular.element(document).find("head").prepend('<style type="text/css">.uib-datepicker .uib-title{width:100%;}.uib-day button,.uib-month button,.uib-year button{min-width:100%;}.uib-datepicker-popup.dropdown-menu{display:block;float:none;margin:0;}.uib-button-bar{padding:10px 9px 2px;}.uib-left,.uib-right{width:100%}</style>'),angular.$$uibDatepickerCss=!0}),angular.module("ui.bootstrap.tooltip").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibTooltipCss&&angular.element(document).find("head").prepend('<style type="text/css">[uib-tooltip-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-popup].tooltip.right-bottom > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.right-bottom > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.right-bottom > .tooltip-arrow,[uib-popover-popup].popover.top-left > .arrow,[uib-popover-popup].popover.top-right > .arrow,[uib-popover-popup].popover.bottom-left > .arrow,[uib-popover-popup].popover.bottom-right > .arrow,[uib-popover-popup].popover.left-top > .arrow,[uib-popover-popup].popover.left-bottom > .arrow,[uib-popover-popup].popover.right-top > .arrow,[uib-popover-popup].popover.right-bottom > .arrow,[uib-popover-html-popup].popover.top-left > .arrow,[uib-popover-html-popup].popover.top-right > .arrow,[uib-popover-html-popup].popover.bottom-left > .arrow,[uib-popover-html-popup].popover.bottom-right > .arrow,[uib-popover-html-popup].popover.left-top > .arrow,[uib-popover-html-popup].popover.left-bottom > .arrow,[uib-popover-html-popup].popover.right-top > .arrow,[uib-popover-html-popup].popover.right-bottom > .arrow,[uib-popover-template-popup].popover.top-left > .arrow,[uib-popover-template-popup].popover.top-right > .arrow,[uib-popover-template-popup].popover.bottom-left > .arrow,[uib-popover-template-popup].popover.bottom-right > .arrow,[uib-popover-template-popup].popover.left-top > .arrow,[uib-popover-template-popup].popover.left-bottom > .arrow,[uib-popover-template-popup].popover.right-top > .arrow,[uib-popover-template-popup].popover.right-bottom > .arrow{top:auto;bottom:auto;left:auto;right:auto;margin:0;}[uib-popover-popup].popover,[uib-popover-html-popup].popover,[uib-popover-template-popup].popover{display:block !important;}</style>'),angular.$$uibTooltipCss=!0}),angular.module("ui.bootstrap.timepicker").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibTimepickerCss&&angular.element(document).find("head").prepend('<style type="text/css">.uib-time input{width:50px;}</style>'),angular.$$uibTimepickerCss=!0}),angular.module("ui.bootstrap.typeahead").run(function(){!angular.$$csp().noInlineStyle&&!angular.$$uibTypeaheadCss&&angular.element(document).find("head").prepend('<style type="text/css">[uib-typeahead-popup].dropdown-menu{display:block;}</style>'),angular.$$uibTypeaheadCss=!0})},{}],"/home/stack/stackviz/node_modules/angular-ui-bootstrap/index.js":[function(e,t,n){e("./dist/ui-bootstrap-tpls"),t.exports="ui.bootstrap"},{"./dist/ui-bootstrap-tpls":"/home/stack/stackviz/node_modules/angular-ui-bootstrap/dist/ui-bootstrap-tpls.js"}],"/home/stack/stackviz/node_modules/angular-ui-router/release/angular-ui-router.js":[function(e,t,n){"undefined"!=typeof t&&"undefined"!=typeof n&&t.exports===n&&(t.exports="ui.router"),function(e,t,n){"use strict";function r(e,t){return V(new(V(function(){},{prototype:e})),t)}function i(e){return U(arguments,function(t){t!==e&&U(t,function(t,n){e.hasOwnProperty(n)||(e[n]=t)})}),e}function a(e,t){var n=[];for(var r in e.path){if(e.path[r]!==t.path[r])break;n.push(e.path[r])}return n}function o(e){if(Object.keys)return Object.keys(e);var t=[];return U(e,function(e,n){t.push(n)}),t}function s(e,t){if(Array.prototype.indexOf)return e.indexOf(t,Number(arguments[2])||0);var n=e.length>>>0,r=Number(arguments[2])||0;for(r=0>r?Math.ceil(r):Math.floor(r),0>r&&(r+=n);n>r;r++)if(r in e&&e[r]===t)return r;return-1}function l(e,t,n,r){var i,l=a(n,r),u={},c=[];for(var f in l)if(l[f]&&l[f].params&&(i=o(l[f].params),i.length))for(var d in i)s(c,i[d])>=0||(c.push(i[d]),u[i[d]]=e[i[d]]);return V({},u,t)}function u(e,t,n){if(!n){n=[];for(var r in e)n.push(r)}for(var i=0;i<n.length;i++){var a=n[i];if(e[a]!=t[a])return!1}return!0}function c(e,t){var n={};return U(e,function(e){n[e]=t[e]}),n}function f(e){var t={},n=Array.prototype.concat.apply(Array.prototype,Array.prototype.slice.call(arguments,1));return U(n,function(n){n in e&&(t[n]=e[n])}),t}function d(e){var t={},n=Array.prototype.concat.apply(Array.prototype,Array.prototype.slice.call(arguments,1));for(var r in e)-1==s(n,r)&&(t[r]=e[r]);return t}function p(e,t){var n=H(e),r=n?[]:{};return U(e,function(e,i){t(e,i)&&(r[n?r.length:i]=e)}),r}function h(e,t){var n=H(e)?[]:{};return U(e,function(e,r){n[r]=t(e,r)}),n}function m(e,t){var r=1,a=2,l={},u=[],c=l,f=V(e.when(l),{$$promises:l,$$values:l});this.study=function(l){function p(e,n){if(b[n]!==a){if(v.push(n),b[n]===r)throw v.splice(0,s(v,n)),new Error("Cyclic dependency: "+v.join(" -> "));if(b[n]=r,_(e))g.push(n,[function(){return t.get(e)}],u);else{var i=t.annotate(e);U(i,function(e){e!==n&&l.hasOwnProperty(e)&&p(l[e],e)}),g.push(n,e,i)}v.pop(),b[n]=a}}function h(e){return R(e)&&e.then&&e.$$promises}if(!R(l))throw new Error("'invocables' must be an object");var m=o(l||{}),g=[],v=[],b={};return U(l,p),l=v=b=null,function(r,a,o){function s(){--$||(w||i(y,a.$$values),v.$$values=y,v.$$promises=v.$$promises||!0,delete v.$$inheritedValues,p.resolve(y))}function l(e){v.$$failure=e,p.reject(e)}function u(n,i,a){function u(e){f.reject(e),l(e)}function c(){if(!F(v.$$failure))try{f.resolve(t.invoke(i,o,y)),f.promise.then(function(e){y[n]=e,s()},u)}catch(e){u(e)}}var f=e.defer(),d=0;U(a,function(e){b.hasOwnProperty(e)&&!r.hasOwnProperty(e)&&(d++,b[e].then(function(t){y[e]=t,--d||c()},u))}),d||c(),b[n]=f.promise}if(h(r)&&o===n&&(o=a,a=r,r=null),r){if(!R(r))throw new Error("'locals' must be an object")}else r=c;if(a){if(!h(a))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else a=f;var p=e.defer(),v=p.promise,b=v.$$promises={},y=V({},r),$=1+g.length/3,w=!1;if(F(a.$$failure))return l(a.$$failure),v;a.$$inheritedValues&&i(y,d(a.$$inheritedValues,m)),V(b,a.$$promises),a.$$values?(w=i(y,d(a.$$values,m)),v.$$inheritedValues=d(a.$$values,m),s()):(a.$$inheritedValues&&(v.$$inheritedValues=d(a.$$inheritedValues,m)),a.then(s,l));for(var x=0,k=g.length;k>x;x+=3)r.hasOwnProperty(g[x])?s():u(g[x],g[x+1],g[x+2]);return v}},this.resolve=function(e,t,n,r){return this.study(e)(t,n,r)}}function g(e,t,n){this.fromConfig=function(e,t,n){return F(e.template)?this.fromString(e.template,t):F(e.templateUrl)?this.fromUrl(e.templateUrl,t):F(e.templateProvider)?this.fromProvider(e.templateProvider,t,n):null},this.fromString=function(e,t){return z(e)?e(t):e},this.fromUrl=function(n,r){return z(n)&&(n=n(r)),null==n?null:e.get(n,{cache:t,headers:{Accept:"text/html"}}).then(function(e){return e.data})},this.fromProvider=function(e,t,r){return n.invoke(e,null,r||{params:t})}}function v(e,t,i){function a(t,n,r,i){if(g.push(t),h[t])return h[t];if(!/^\w+([-.]+\w+)*(?:\[\])?$/.test(t))throw new Error("Invalid parameter name '"+t+"' in pattern '"+e+"'");if(m[t])throw new Error("Duplicate parameter name '"+t+"' in pattern '"+e+"'");return m[t]=new q.Param(t,n,r,i),m[t]}function o(e,t,n,r){var i=["",""],a=e.replace(/[\\\[\]\^$*+?.()|{}]/g,"\\$&");if(!t)return a;switch(n){case!1:i=["(",")"+(r?"?":"")];break;case!0:a=a.replace(/\/$/,""),i=["(?:/(",")|/)?"];break;default:i=["("+n+"|",")?"]}return a+i[0]+t+i[1]}function s(i,a){var o,s,l,u,c;return o=i[2]||i[3],c=t.params[o],l=e.substring(d,i.index),s=a?i[4]:i[4]||("*"==i[1]?".*":null),s&&(u=q.type(s)||r(q.type("string"),{pattern:new RegExp(s,t.caseInsensitive?"i":n)})),{id:o,regexp:s,segment:l,type:u,cfg:c}}t=V({params:{}},R(t)?t:{});var l,u=/([:*])([\w\[\]]+)|\{([\w\[\]]+)(?:\:\s*((?:[^{}\\]+|\\.|\{(?:[^{}\\]+|\\.)*\})+))?\}/g,c=/([:]?)([\w\[\].-]+)|\{([\w\[\].-]+)(?:\:\s*((?:[^{}\\]+|\\.|\{(?:[^{}\\]+|\\.)*\})+))?\}/g,f="^",d=0,p=this.segments=[],h=i?i.params:{},m=this.params=i?i.params.$$new():new q.ParamSet,g=[];this.source=e;for(var v,b,y;(l=u.exec(e))&&(v=s(l,!1),!(v.segment.indexOf("?")>=0));)b=a(v.id,v.type,v.cfg,"path"),f+=o(v.segment,b.type.pattern.source,b.squash,b.isOptional),p.push(v.segment),d=u.lastIndex;y=e.substring(d);var $=y.indexOf("?");if($>=0){var w=this.sourceSearch=y.substring($);if(y=y.substring(0,$),this.sourcePath=e.substring(0,d+$),w.length>0)for(d=0;l=c.exec(w);)v=s(l,!0),b=a(v.id,v.type,v.cfg,"search"),d=u.lastIndex}else this.sourcePath=e,this.sourceSearch="";f+=o(y)+(t.strict===!1?"/?":"")+"$",p.push(y),this.regexp=new RegExp(f,t.caseInsensitive?"i":n),this.prefix=p[0],this.$$paramNames=g}function b(e){V(this,e)}function y(){function e(e){return null!=e?e.toString().replace(/~/g,"~~").replace(/\//g,"~2F"):e}function i(e){return null!=e?e.toString().replace(/~2F/g,"/").replace(/~~/g,"~"):e}function a(){return{strict:m,caseInsensitive:d}}function l(e){return z(e)||H(e)&&z(e[e.length-1])}function u(){for(;x.length;){
var e=x.shift();if(e.pattern)throw new Error("You cannot override a type's .pattern at runtime.");t.extend($[e.name],f.invoke(e.def))}}function c(e){V(this,e||{})}q=this;var f,d=!1,m=!0,g=!1,$={},w=!0,x=[],k={string:{encode:e,decode:i,is:function(e){return null==e||!F(e)||"string"==typeof e},pattern:/[^\/]*/},"int":{encode:e,decode:function(e){return parseInt(e,10)},is:function(e){return F(e)&&this.decode(e.toString())===e},pattern:/\d+/},bool:{encode:function(e){return e?1:0},decode:function(e){return 0!==parseInt(e,10)},is:function(e){return e===!0||e===!1},pattern:/0|1/},date:{encode:function(e){return this.is(e)?[e.getFullYear(),("0"+(e.getMonth()+1)).slice(-2),("0"+e.getDate()).slice(-2)].join("-"):n},decode:function(e){if(this.is(e))return e;var t=this.capture.exec(e);return t?new Date(t[1],t[2]-1,t[3]):n},is:function(e){return e instanceof Date&&!isNaN(e.valueOf())},equals:function(e,t){return this.is(e)&&this.is(t)&&e.toISOString()===t.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:t.toJson,decode:t.fromJson,is:t.isObject,equals:t.equals,pattern:/[^\/]*/},any:{encode:t.identity,decode:t.identity,equals:t.equals,pattern:/.*/}};y.$$getDefaultValue=function(e){if(!l(e.value))return e.value;if(!f)throw new Error("Injectable functions cannot be called at configuration time");return f.invoke(e.value)},this.caseInsensitive=function(e){return F(e)&&(d=e),d},this.strictMode=function(e){return F(e)&&(m=e),m},this.defaultSquashPolicy=function(e){if(!F(e))return g;if(e!==!0&&e!==!1&&!_(e))throw new Error("Invalid squash policy: "+e+". Valid policies: false, true, arbitrary-string");return g=e,e},this.compile=function(e,t){return new v(e,V(a(),t))},this.isMatcher=function(e){if(!R(e))return!1;var t=!0;return U(v.prototype,function(n,r){z(n)&&(t=t&&F(e[r])&&z(e[r]))}),t},this.type=function(e,t,n){if(!F(t))return $[e];if($.hasOwnProperty(e))throw new Error("A type named '"+e+"' has already been defined.");return $[e]=new b(V({name:e},t)),n&&(x.push({name:e,def:n}),w||u()),this},U(k,function(e,t){$[t]=new b(V({name:t},e))}),$=r($,{}),this.$get=["$injector",function(e){return f=e,w=!1,u(),U(k,function(e,t){$[t]||($[t]=new b(e))}),this}],this.Param=function(e,r,i,a){function u(e){var t=R(e)?o(e):[],n=-1===s(t,"value")&&-1===s(t,"type")&&-1===s(t,"squash")&&-1===s(t,"array");return n&&(e={value:e}),e.$$fn=l(e.value)?e.value:function(){return e.value},e}function c(n,r,i){if(n.type&&r)throw new Error("Param '"+e+"' has two type configurations.");return r?r:n.type?t.isString(n.type)?$[n.type]:n.type instanceof b?n.type:new b(n.type):"config"===i?$.any:$.string}function d(){var t={array:"search"===a?"auto":!1},n=e.match(/\[\]$/)?{array:!0}:{};return V(t,n,i).array}function m(e,t){var n=e.squash;if(!t||n===!1)return!1;if(!F(n)||null==n)return g;if(n===!0||_(n))return n;throw new Error("Invalid squash policy: '"+n+"'. Valid policies: false, true, or arbitrary string")}function v(e,t,r,i){var a,o,l=[{from:"",to:r||t?n:""},{from:null,to:r||t?n:""}];return a=H(e.replace)?e.replace:[],_(i)&&a.push({from:i,to:n}),o=h(a,function(e){return e.from}),p(l,function(e){return-1===s(o,e.from)}).concat(a)}function y(){if(!f)throw new Error("Injectable functions cannot be called at configuration time");var e=f.invoke(i.$$fn);if(null!==e&&e!==n&&!k.type.is(e))throw new Error("Default value ("+e+") for parameter '"+k.id+"' is not an instance of Type ("+k.type.name+")");return e}function w(e){function t(e){return function(t){return t.from===e}}function n(e){var n=h(p(k.replace,t(e)),function(e){return e.to});return n.length?n[0]:e}return e=n(e),F(e)?k.type.$normalize(e):y()}function x(){return"{Param:"+e+" "+r+" squash: '"+S+"' optional: "+M+"}"}var k=this;i=u(i),r=c(i,r,a);var C=d();r=C?r.$asArray(C,"search"===a):r,"string"!==r.name||C||"path"!==a||i.value!==n||(i.value="");var M=i.value!==n,S=m(i,M),T=v(i,C,M,S);V(this,{id:e,type:r,location:a,array:C,squash:S,replace:T,isOptional:M,value:w,dynamic:n,config:i,toString:x})},c.prototype={$$new:function(){return r(this,V(new c,{$$parent:this}))},$$keys:function(){for(var e=[],t=[],n=this,r=o(c.prototype);n;)t.push(n),n=n.$$parent;return t.reverse(),U(t,function(t){U(o(t),function(t){-1===s(e,t)&&-1===s(r,t)&&e.push(t)})}),e},$$values:function(e){var t={},n=this;return U(n.$$keys(),function(r){t[r]=n[r].value(e&&e[r])}),t},$$equals:function(e,t){var n=!0,r=this;return U(r.$$keys(),function(i){var a=e&&e[i],o=t&&t[i];r[i].type.equals(a,o)||(n=!1)}),n},$$validates:function(e){var r,i,a,o,s,l=this.$$keys();for(r=0;r<l.length&&(i=this[l[r]],a=e[l[r]],a!==n&&null!==a||!i.isOptional);r++){if(o=i.type.$normalize(a),!i.type.is(o))return!1;if(s=i.type.encode(o),t.isString(s)&&!i.type.pattern.exec(s))return!1}return!0},$$parent:n},this.ParamSet=c}function $(e,r){function i(e){var t=/^\^((?:\\[^a-zA-Z0-9]|[^\\\[\]\^$*+?.()|{}]+)*)/.exec(e.source);return null!=t?t[1].replace(/\\(.)/g,"$1"):""}function a(e,t){return e.replace(/\$(\$|\d{1,2})/,function(e,n){return t["$"===n?0:Number(n)]})}function o(e,t,n){if(!n)return!1;var r=e.invoke(t,t,{$match:n});return F(r)?r:!0}function s(r,i,a,o,s){function d(e,t,n){return"/"===g?e:t?g.slice(0,-1)+e:n?g.slice(1)+e:e}function p(e){function t(e){var t=e(a,r);return t?(_(t)&&r.replace().url(t),!0):!1}if(!e||!e.defaultPrevented){m&&r.url()===m;m=n;var i,o=u.length;for(i=0;o>i;i++)if(t(u[i]))return;c&&t(c)}}function h(){return l=l||i.$on("$locationChangeSuccess",p)}var m,g=o.baseHref(),v=r.url();return f||h(),{sync:function(){p()},listen:function(){return h()},update:function(e){return e?void(v=r.url()):void(r.url()!==v&&(r.url(v),r.replace()))},push:function(e,t,i){var a=e.format(t||{});null!==a&&t&&t["#"]&&(a+="#"+t["#"]),r.url(a),m=i&&i.$$avoidResync?r.url():n,i&&i.replace&&r.replace()},href:function(n,i,a){if(!n.validates(i))return null;var o=e.html5Mode();t.isObject(o)&&(o=o.enabled),o=o&&s.history;var l=n.format(i);if(a=a||{},o||null===l||(l="#"+e.hashPrefix()+l),null!==l&&i&&i["#"]&&(l+="#"+i["#"]),l=d(l,o,a.absolute),!a.absolute||!l)return l;var u=!o&&l?"/":"",c=r.port();return c=80===c||443===c?"":":"+c,[r.protocol(),"://",r.host(),c,u,l].join("")}}}var l,u=[],c=null,f=!1;this.rule=function(e){if(!z(e))throw new Error("'rule' must be a function");return u.push(e),this},this.otherwise=function(e){if(_(e)){var t=e;e=function(){return t}}else if(!z(e))throw new Error("'rule' must be a function");return c=e,this},this.when=function(e,t){var n,s=_(t);if(_(e)&&(e=r.compile(e)),!s&&!z(t)&&!H(t))throw new Error("invalid 'handler' in when()");var l={matcher:function(e,t){return s&&(n=r.compile(t),t=["$match",function(e){return n.format(e)}]),V(function(n,r){return o(n,t,e.exec(r.path(),r.search()))},{prefix:_(e.prefix)?e.prefix:""})},regex:function(e,t){if(e.global||e.sticky)throw new Error("when() RegExp must not be global or sticky");return s&&(n=t,t=["$match",function(e){return a(n,e)}]),V(function(n,r){return o(n,t,e.exec(r.path()))},{prefix:i(e)})}},u={matcher:r.isMatcher(e),regex:e instanceof RegExp};for(var c in u)if(u[c])return this.rule(l[c](e,t));throw new Error("invalid 'what' in when()")},this.deferIntercept=function(e){e===n&&(e=!0),f=e},this.$get=s,s.$inject=["$location","$rootScope","$injector","$browser","$sniffer"]}function w(e,i){function a(e){return 0===e.indexOf(".")||0===e.indexOf("^")}function d(e,t){if(!e)return n;var r=_(e),i=r?e:e.name,o=a(i);if(o){if(!t)throw new Error("No reference point given for path '"+i+"'");t=d(t);for(var s=i.split("."),l=0,u=s.length,c=t;u>l;l++)if(""!==s[l]||0!==l){if("^"!==s[l])break;if(!c.parent)throw new Error("Path '"+i+"' not valid for state '"+t.name+"'");c=c.parent}else c=t;s=s.slice(l).join("."),i=c.name+(c.name&&s?".":"")+s}var f=M[i];return!f||!r&&(r||f!==e&&f.self!==e)?n:f}function p(e,t){S[e]||(S[e]=[]),S[e].push(t)}function m(e){for(var t=S[e]||[];t.length;)g(t.shift())}function g(t){t=r(t,{self:t,resolve:t.resolve||{},toString:function(){return this.name}});var n=t.name;if(!_(n)||n.indexOf("@")>=0)throw new Error("State must have a valid name");if(M.hasOwnProperty(n))throw new Error("State '"+n+"' is already defined");var i=-1!==n.indexOf(".")?n.substring(0,n.lastIndexOf(".")):_(t.parent)?t.parent:R(t.parent)&&_(t.parent.name)?t.parent.name:"";if(i&&!M[i])return p(i,t.self);for(var a in D)z(D[a])&&(t[a]=D[a](t,D.$delegates[a]));return M[n]=t,!t[T]&&t.url&&e.when(t.url,["$match","$stateParams",function(e,n){C.$current.navigable==t&&u(e,n)||C.transitionTo(t,e,{inherit:!0,location:!1})}]),m(n),t}function v(e){return e.indexOf("*")>-1}function b(e){for(var t=e.split("."),n=C.$current.name.split("."),r=0,i=t.length;i>r;r++)"*"===t[r]&&(n[r]="*");return"**"===t[0]&&(n=n.slice(s(n,t[1])),n.unshift("**")),"**"===t[t.length-1]&&(n.splice(s(n,t[t.length-2])+1,Number.MAX_VALUE),n.push("**")),t.length!=n.length?!1:n.join("")===t.join("")}function y(e,t){return _(e)&&!F(t)?D[e]:z(t)&&_(e)?(D[e]&&!D.$delegates[e]&&(D.$delegates[e]=D[e]),D[e]=t,this):this}function $(e,t){return R(e)?t=e:t.name=e,g(t),this}function w(e,i,a,s,f,p,m,g,y){function $(t,n,r,a){var o=e.$broadcast("$stateNotFound",t,n,r);if(o.defaultPrevented)return m.update(),E;if(!o.retry)return null;if(a.$retry)return m.update(),O;var s=C.transition=i.when(o.retry);return s.then(function(){return s!==C.transition?S:(t.options.$retry=!0,C.transitionTo(t.to,t.toParams,t.options))},function(){return E}),m.update(),s}function w(e,n,r,o,l,u){function d(){var n=[];return U(e.views,function(r,i){var o=r.resolve&&r.resolve!==e.resolve?r.resolve:{};o.$template=[function(){return a.load(i,{view:r,locals:l.globals,params:p,notify:u.notify})||""}],n.push(f.resolve(o,l.globals,l.resolve,e).then(function(n){if(z(r.controllerProvider)||H(r.controllerProvider)){var a=t.extend({},o,l.globals);n.$$controller=s.invoke(r.controllerProvider,null,a)}else n.$$controller=r.controller;n.$$state=e,n.$$controllerAs=r.controllerAs,l[i]=n}))}),i.all(n).then(function(){return l.globals})}var p=r?n:c(e.params.$$keys(),n),h={$stateParams:p};l.resolve=f.resolve(e.resolve,h,l.resolve,e);var m=[l.resolve.then(function(e){l.globals=e})];return o&&m.push(o),i.all(m).then(d).then(function(e){return l})}var S=i.reject(new Error("transition superseded")),D=i.reject(new Error("transition prevented")),E=i.reject(new Error("transition aborted")),O=i.reject(new Error("transition failed"));return k.locals={resolve:null,globals:{$stateParams:{}}},C={params:{},current:k.self,$current:k,transition:null},C.reload=function(e){return C.transitionTo(C.current,p,{reload:e||!0,inherit:!1,notify:!0})},C.go=function(e,t,n){return C.transitionTo(e,t,V({inherit:!0,relative:C.$current},n))},C.transitionTo=function(t,n,a){n=n||{},a=V({location:!0,inherit:!1,relative:null,notify:!0,reload:!1,$retry:!1},a||{});var o,u=C.$current,f=C.params,h=u.path,g=d(t,a.relative),v=n["#"];if(!F(g)){var b={to:t,toParams:n,options:a},y=$(b,u.self,f,a);if(y)return y;if(t=b.to,n=b.toParams,a=b.options,g=d(t,a.relative),!F(g)){if(!a.relative)throw new Error("No such state '"+t+"'");throw new Error("Could not resolve '"+t+"' from state '"+a.relative+"'")}}if(g[T])throw new Error("Cannot transition to abstract state '"+t+"'");if(a.inherit&&(n=l(p,n||{},C.$current,g)),!g.params.$$validates(n))return O;n=g.params.$$values(n),t=g;var M=t.path,E=0,A=M[E],N=k.locals,j=[];if(a.reload){if(_(a.reload)||R(a.reload)){if(R(a.reload)&&!a.reload.name)throw new Error("Invalid reload state object");var L=a.reload===!0?h[0]:d(a.reload);if(a.reload&&!L)throw new Error("No such reload state '"+(_(a.reload)?a.reload:a.reload.name)+"'");for(;A&&A===h[E]&&A!==L;)N=j[E]=A.locals,E++,A=M[E]}}else for(;A&&A===h[E]&&A.ownParams.$$equals(n,f);)N=j[E]=A.locals,E++,A=M[E];if(x(t,n,u,f,N,a))return v&&(n["#"]=v),C.params=n,W(C.params,p),W(c(t.params.$$keys(),p),t.locals.globals.$stateParams),a.location&&t.navigable&&t.navigable.url&&(m.push(t.navigable.url,n,{$$avoidResync:!0,replace:"replace"===a.location}),m.update(!0)),C.transition=null,i.when(C.current);if(n=c(t.params.$$keys(),n||{}),v&&(n["#"]=v),a.notify&&e.$broadcast("$stateChangeStart",t.self,n,u.self,f,a).defaultPrevented)return e.$broadcast("$stateChangeCancel",t.self,n,u.self,f),null==C.transition&&m.update(),D;for(var P=i.when(N),I=E;I<M.length;I++,A=M[I])N=j[I]=r(N),P=w(A,n,A===t,P,N,a);var z=C.transition=P.then(function(){var r,i,o;if(C.transition!==z)return S;for(r=h.length-1;r>=E;r--)o=h[r],o.self.onExit&&s.invoke(o.self.onExit,o.self,o.locals.globals),o.locals=null;for(r=E;r<M.length;r++)i=M[r],i.locals=j[r],i.self.onEnter&&s.invoke(i.self.onEnter,i.self,i.locals.globals);return C.transition!==z?S:(C.$current=t,C.current=t.self,C.params=n,W(C.params,p),C.transition=null,a.location&&t.navigable&&m.push(t.navigable.url,t.navigable.locals.globals.$stateParams,{$$avoidResync:!0,replace:"replace"===a.location}),a.notify&&e.$broadcast("$stateChangeSuccess",t.self,n,u.self,f),m.update(!0),C.current)},function(r){return C.transition!==z?S:(C.transition=null,o=e.$broadcast("$stateChangeError",t.self,n,u.self,f,r),o.defaultPrevented||m.update(),i.reject(r))});return z},C.is=function(e,t,r){r=V({relative:C.$current},r||{});var i=d(e,r.relative);return F(i)?C.$current!==i?!1:t?u(i.params.$$values(t),p):!0:n},C.includes=function(e,t,r){if(r=V({relative:C.$current},r||{}),_(e)&&v(e)){if(!b(e))return!1;e=C.$current.name}var i=d(e,r.relative);return F(i)?F(C.$current.includes[i.name])?t?u(i.params.$$values(t),p,o(t)):!0:!1:n},C.href=function(e,t,r){r=V({lossy:!0,inherit:!0,absolute:!1,relative:C.$current},r||{});var i=d(e,r.relative);if(!F(i))return null;r.inherit&&(t=l(p,t||{},C.$current,i));var a=i&&r.lossy?i.navigable:i;return a&&a.url!==n&&null!==a.url?m.href(a.url,c(i.params.$$keys().concat("#"),t||{}),{absolute:r.absolute}):null},C.get=function(e,t){if(0===arguments.length)return h(o(M),function(e){return M[e].self});var n=d(e,t||C.$current);return n&&n.self?n.self:null},C}function x(e,t,n,r,i,a){function o(e,t,n){function r(t){return"search"!=e.params[t].location}var i=e.params.$$keys().filter(r),a=f.apply({},[e.params].concat(i)),o=new q.ParamSet(a);return o.$$equals(t,n)}return!a.reload&&e===n&&(i===n.locals||e.self.reloadOnSearch===!1&&o(n,r,t))?!0:void 0}var k,C,M={},S={},T="abstract",D={parent:function(e){if(F(e.parent)&&e.parent)return d(e.parent);var t=/^(.+)\.[^.]+$/.exec(e.name);return t?d(t[1]):k},data:function(e){return e.parent&&e.parent.data&&(e.data=e.self.data=r(e.parent.data,e.data)),e.data},url:function(e){var t=e.url,n={params:e.params||{}};if(_(t))return"^"==t.charAt(0)?i.compile(t.substring(1),n):(e.parent.navigable||k).url.concat(t,n);if(!t||i.isMatcher(t))return t;throw new Error("Invalid url '"+t+"' in state '"+e+"'")},navigable:function(e){return e.url?e:e.parent?e.parent.navigable:null},ownParams:function(e){var t=e.url&&e.url.params||new q.ParamSet;return U(e.params||{},function(e,n){t[n]||(t[n]=new q.Param(n,null,e,"config"))}),t},params:function(e){var t=f(e.ownParams,e.ownParams.$$keys());return e.parent&&e.parent.params?V(e.parent.params.$$new(),t):new q.ParamSet},views:function(e){var t={};return U(F(e.views)?e.views:{"":e},function(n,r){r.indexOf("@")<0&&(r+="@"+e.parent.name),t[r]=n}),t},path:function(e){return e.parent?e.parent.path.concat(e):[]},includes:function(e){var t=e.parent?V({},e.parent.includes):{};return t[e.name]=!0,t},$delegates:{}};k=g({name:"",url:"^",views:null,"abstract":!0}),k.navigable=null,this.decorator=y,this.state=$,this.$get=w,w.$inject=["$rootScope","$q","$view","$injector","$resolve","$stateParams","$urlRouter","$location","$urlMatcherFactory"]}function x(){function e(e,t){return{load:function(e,n){var r,i={template:null,controller:null,view:null,locals:null,notify:!0,async:!0,params:{}};return n=V(i,n),n.view&&(r=t.fromConfig(n.view,n.params,n.locals)),r}}}this.$get=e,e.$inject=["$rootScope","$templateFactory"]}function k(){var e=!1;this.useAnchorScroll=function(){e=!0},this.$get=["$anchorScroll","$timeout",function(t,n){return e?t:function(e){return n(function(){e[0].scrollIntoView()},0,!1)}}]}function C(e,n,r,i){function a(){return n.has?function(e){return n.has(e)?n.get(e):null}:function(e){try{return n.get(e)}catch(t){return null}}}function o(e,n){function r(e){return 1===Y&&G>=4?!!u.enabled(e):1===Y&&G>=2?!!u.enabled():!!l}var i={enter:function(e,t,n){t.after(e),n()},leave:function(e,t){e.remove(),t()}};if(e.noanimation)return i;if(u)return{enter:function(e,n,a){r(e)?t.version.minor>2?u.enter(e,null,n).then(a):u.enter(e,null,n,a):i.enter(e,n,a)},leave:function(e,n){r(e)?t.version.minor>2?u.leave(e).then(n):u.leave(e,n):i.leave(e,n)}};if(l){var a=l&&l(n,e);return{enter:function(e,t,n){a.enter(e,null,t),n()},leave:function(e,t){a.leave(e),t()}}}return i}var s=a(),l=s("$animator"),u=s("$animate"),c={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(n,a,s){return function(n,a,l){function u(){function e(){t&&t.remove(),n&&n.$destroy()}var t=f,n=p;n&&(n._willBeDestroyed=!0),d?(v.leave(d,function(){e(),f=null}),f=d):(e(),f=null),d=null,p=null}function c(o){var c,f=S(n,l,a,i),b=f&&e.$current&&e.$current.locals[f];if((o||b!==h)&&!n._willBeDestroyed){c=n.$new(),h=e.$current.locals[f],c.$emit("$viewContentLoading",f);var y=s(c,function(e){v.enter(e,a,function(){p&&p.$emit("$viewContentAnimationEnded"),(t.isDefined(g)&&!g||n.$eval(g))&&r(e)}),u()});d=y,p=c,p.$emit("$viewContentLoaded",f),p.$eval(m)}}var f,d,p,h,m=l.onload||"",g=l.autoscroll,v=o(l,n);n.$on("$stateChangeSuccess",function(){c(!1)}),c(!0)}}};return c}function M(e,t,n,r){return{restrict:"ECA",priority:-400,compile:function(i){var a=i.html();return function(i,o,s){var l=n.$current,u=S(i,s,o,r),c=l&&l.locals[u];if(c){o.data("$uiView",{name:u,state:c.$$state}),o.html(c.$template?c.$template:a);var f=e(o.contents());if(c.$$controller){c.$scope=i,c.$element=o;var d=t(c.$$controller,c);c.$$controllerAs&&(i[c.$$controllerAs]=d),o.data("$ngControllerController",d),o.children().data("$ngControllerController",d)}f(i)}}}}}function S(e,t,n,r){var i=r(t.uiView||t.name||"")(e),a=n.inheritedData("$uiView");return i.indexOf("@")>=0?i:i+"@"+(a?a.state.name:"")}function T(e,t){var n,r=e.match(/^\s*({[^}]*})\s*$/);if(r&&(e=t+"("+r[1]+")"),n=e.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!n||4!==n.length)throw new Error("Invalid state ref '"+e+"'");return{state:n[1],paramExpr:n[3]||null}}function D(e){var t=e.parent().inheritedData("$uiView");return t&&t.state&&t.state.name?t.state:void 0}function E(e){var t="[object SVGAnimatedString]"===Object.prototype.toString.call(e.prop("href")),n="FORM"===e[0].nodeName;return{attr:n?"action":t?"xlink:href":"href",isAnchor:"A"===e.prop("tagName").toUpperCase(),clickable:!n}}function O(e,t,n,r,i){return function(a){var o=a.which||a.button,s=i();if(!(o>1||a.ctrlKey||a.metaKey||a.shiftKey||e.attr("target"))){var l=n(function(){t.go(s.state,s.params,s.options)});a.preventDefault();var u=r.isAnchor&&!s.href?1:0;a.preventDefault=function(){u--<=0&&n.cancel(l)}}}}function A(e,t){return{relative:D(e)||t.$current,inherit:!0}}function N(e,n){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(r,i,a,o){var s=T(a.uiSref,e.current.name),l={state:s.state,href:null,params:null},u=E(i),c=o[1]||o[0];l.options=V(A(i,e),a.uiSrefOpts?r.$eval(a.uiSrefOpts):{});var f=function(n){n&&(l.params=t.copy(n)),l.href=e.href(s.state,l.params,l.options),c&&c.$$addStateInfo(s.state,l.params),null!==l.href&&a.$set(u.attr,l.href)};s.paramExpr&&(r.$watch(s.paramExpr,function(e){e!==l.params&&f(e)},!0),l.params=t.copy(r.$eval(s.paramExpr))),f(),u.clickable&&i.bind("click",O(i,e,n,u,function(){return l}))}}}function j(e,t){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(n,r,i,a){function o(t){f.state=t[0],f.params=t[1],f.options=t[2],f.href=e.href(f.state,f.params,f.options),l&&l.$$addStateInfo(f.state,f.params),f.href&&i.$set(s.attr,f.href)}var s=E(r),l=a[1]||a[0],u=[i.uiState,i.uiStateParams||null,i.uiStateOpts||null],c="["+u.map(function(e){return e||"null"}).join(", ")+"]",f={state:null,params:null,options:null,href:null};n.$watch(c,o,!0),o(n.$eval(c)),s.clickable&&r.bind("click",O(r,e,t,s,function(){return f}))}}}function L(e,t,n){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(t,r,i,a){function o(t,n,i){var a=e.get(t,D(r)),o=s(t,n);m.push({state:a||{name:t},params:n,hash:o}),g[o]=i}function s(e,n){if(!_(e))throw new Error("state should be a string");return R(n)?e+B(n):(n=t.$eval(n),R(n)?e+B(n):e)}function l(){for(var e=0;e<m.length;e++)f(m[e].state,m[e].params)?u(r,g[m[e].hash]):c(r,g[m[e].hash]),d(m[e].state,m[e].params)?u(r,p):c(r,p)}function u(e,t){a(function(){e.addClass(t)})}function c(e,t){e.removeClass(t)}function f(t,n){return e.includes(t.name,n)}function d(t,n){return e.is(t.name,n)}var p,h,m=[],g={};p=n(i.uiSrefActiveEq||"",!1)(t);try{h=t.$eval(i.uiSrefActive)}catch(v){}h=h||n(i.uiSrefActive||"",!1)(t),R(h)&&U(h,function(n,r){if(_(n)){var i=T(n,e.current.name);o(i.state,t.$eval(i.paramExpr),r)}}),this.$$addStateInfo=function(e,t){R(h)&&m.length>0||(o(e,t,h),l())},t.$on("$stateChangeSuccess",l),l()}]}}function P(e){var t=function(t,n){return e.is(t,n)};return t.$stateful=!0,t}function I(e){var t=function(t,n,r){return e.includes(t,n,r)};return t.$stateful=!0,t}var F=t.isDefined,z=t.isFunction,_=t.isString,R=t.isObject,H=t.isArray,U=t.forEach,V=t.extend,W=t.copy,B=t.toJson;t.module("ui.router.util",["ng"]),t.module("ui.router.router",["ui.router.util"]),t.module("ui.router.state",["ui.router.router","ui.router.util"]),t.module("ui.router",["ui.router.state"]),t.module("ui.router.compat",["ui.router"]),m.$inject=["$q","$injector"],t.module("ui.router.util").service("$resolve",m),g.$inject=["$http","$templateCache","$injector"],t.module("ui.router.util").service("$templateFactory",g);var q;v.prototype.concat=function(e,t){var n={caseInsensitive:q.caseInsensitive(),strict:q.strictMode(),squash:q.defaultSquashPolicy()};return new v(this.sourcePath+e+this.sourceSearch,V(n,t),this)},v.prototype.toString=function(){return this.source},v.prototype.exec=function(e,t){function n(e){function t(e){return e.split("").reverse().join("")}function n(e){return e.replace(/\\-/g,"-")}var r=t(e).split(/-(?!\\)/),i=h(r,t);return h(i,n).reverse()}var r=this.regexp.exec(e);if(!r)return null;t=t||{};var i,a,o,s=this.parameters(),l=s.length,u=this.segments.length-1,c={};if(u!==r.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var f,d;for(i=0;u>i;i++){for(o=s[i],f=this.params[o],d=r[i+1],a=0;a<f.replace.length;a++)f.replace[a].from===d&&(d=f.replace[a].to);d&&f.array===!0&&(d=n(d)),F(d)&&(d=f.type.decode(d)),c[o]=f.value(d)}for(;l>i;i++){for(o=s[i],c[o]=this.params[o].value(t[o]),f=this.params[o],d=t[o],a=0;a<f.replace.length;a++)f.replace[a].from===d&&(d=f.replace[a].to);F(d)&&(d=f.type.decode(d)),c[o]=f.value(d)}return c},v.prototype.parameters=function(e){return F(e)?this.params[e]||null:this.$$paramNames},v.prototype.validates=function(e){return this.params.$$validates(e)},v.prototype.format=function(e){function t(e){return encodeURIComponent(e).replace(/-/g,function(e){return"%5C%"+e.charCodeAt(0).toString(16).toUpperCase()})}e=e||{};var n=this.segments,r=this.parameters(),i=this.params;if(!this.validates(e))return null;var a,o=!1,s=n.length-1,l=r.length,u=n[0];for(a=0;l>a;a++){var c=s>a,f=r[a],d=i[f],p=d.value(e[f]),m=d.isOptional&&d.type.equals(d.value(),p),g=m?d.squash:!1,v=d.type.encode(p);if(c){var b=n[a+1],y=a+1===s;if(g===!1)null!=v&&(u+=H(v)?h(v,t).join("-"):encodeURIComponent(v)),u+=b;else if(g===!0){var $=u.match(/\/$/)?/\/?(.*)/:/(.*)/;u+=b.match($)[1]}else _(g)&&(u+=g+b);y&&d.squash===!0&&"/"===u.slice(-1)&&(u=u.slice(0,-1))}else{if(null==v||m&&g!==!1)continue;if(H(v)||(v=[v]),0===v.length)continue;v=h(v,encodeURIComponent).join("&"+f+"="),u+=(o?"&":"?")+(f+"="+v),o=!0}}return u},b.prototype.is=function(e,t){return!0},b.prototype.encode=function(e,t){return e},b.prototype.decode=function(e,t){return e},b.prototype.equals=function(e,t){return e==t},b.prototype.$subPattern=function(){var e=this.pattern.toString();return e.substr(1,e.length-2)},b.prototype.pattern=/.*/,b.prototype.toString=function(){return"{Type:"+this.name+"}"},b.prototype.$normalize=function(e){return this.is(e)?e:this.decode(e)},b.prototype.$asArray=function(e,t){function r(e,t){function r(e,t){return function(){return e[t].apply(e,arguments)}}function i(e){return H(e)?e:F(e)?[e]:[]}function a(e){switch(e.length){case 0:return n;case 1:return"auto"===t?e[0]:e;default:return e}}function o(e){return!e}function s(e,t){return function(n){if(H(n)&&0===n.length)return n;n=i(n);var r=h(n,e);return t===!0?0===p(r,o).length:a(r)}}function l(e){return function(t,n){var r=i(t),a=i(n);if(r.length!==a.length)return!1;for(var o=0;o<r.length;o++)if(!e(r[o],a[o]))return!1;return!0}}this.encode=s(r(e,"encode")),this.decode=s(r(e,"decode")),this.is=s(r(e,"is"),!0),this.equals=l(r(e,"equals")),this.pattern=e.pattern,this.$normalize=s(r(e,"$normalize")),this.name=e.name,this.$arrayMode=t}if(!e)return this;if("auto"===e&&!t)throw new Error("'auto' array mode is for query parameters only");return new r(this,e)},t.module("ui.router.util").provider("$urlMatcherFactory",y),t.module("ui.router.util").run(["$urlMatcherFactory",function(e){}]),$.$inject=["$locationProvider","$urlMatcherFactoryProvider"],t.module("ui.router.router").provider("$urlRouter",$),w.$inject=["$urlRouterProvider","$urlMatcherFactoryProvider"],t.module("ui.router.state").factory("$stateParams",function(){return{}}).provider("$state",w),x.$inject=[],t.module("ui.router.state").provider("$view",x),t.module("ui.router.state").provider("$uiViewScroll",k);var Y=t.version.major,G=t.version.minor;C.$inject=["$state","$injector","$uiViewScroll","$interpolate"],M.$inject=["$compile","$controller","$state","$interpolate"],t.module("ui.router.state").directive("uiView",C),t.module("ui.router.state").directive("uiView",M),N.$inject=["$state","$timeout"],j.$inject=["$state","$timeout"],L.$inject=["$state","$stateParams","$interpolate"],t.module("ui.router.state").directive("uiSref",N).directive("uiSrefActive",L).directive("uiSrefActiveEq",L).directive("uiState",j),P.$inject=["$state"],I.$inject=["$state"],t.module("ui.router.state").filter("isState",P).filter("includedByState",I)}(window,window.angular)},{}],"/home/stack/stackviz/node_modules/angular/angular.js":[function(e,t,n){!function(e,t,n){"use strict";function r(e,t){return t=t||Error,function(){var n,r,i=2,a=arguments,o=a[0],s="["+(e?e+":":"")+o+"] ",l=a[1];for(s+=l.replace(/\{\d+\}/g,function(e){var t=+e.slice(1,-1),n=t+i;return n<a.length?$e(a[n]):e}),s+="\nhttp://errors.angularjs.org/1.5.2/"+(e?e+"/":"")+o,r=i,n="?";r<a.length;r++,n="&")s+=n+"p"+(r-i)+"="+encodeURIComponent($e(a[r]));return new t(s)}}function i(e){if(null==e||D(e))return!1;if(qr(e)||k(e)||Pr&&e instanceof Pr)return!0;var t="length"in Object(e)&&e.length;return C(t)&&(t>=0&&(t-1 in e||e instanceof Array)||"function"==typeof e.item)}function a(e,t,n){var r,o;if(e)if(S(e))for(r in e)"prototype"==r||"length"==r||"name"==r||e.hasOwnProperty&&!e.hasOwnProperty(r)||t.call(n,e[r],r,e);else if(qr(e)||i(e)){var s="object"!=typeof e;for(r=0,o=e.length;o>r;r++)(s||r in e)&&t.call(n,e[r],r,e)}else if(e.forEach&&e.forEach!==a)e.forEach(t,n,e);else if(x(e))for(r in e)t.call(n,e[r],r,e);else if("function"==typeof e.hasOwnProperty)for(r in e)e.hasOwnProperty(r)&&t.call(n,e[r],r,e);else for(r in e)Er.call(e,r)&&t.call(n,e[r],r,e);return e}function o(e,t,n){for(var r=Object.keys(e).sort(),i=0;i<r.length;i++)t.call(n,e[r[i]],r[i]);return r}function s(e){return function(t,n){e(n,t)}}function l(){return++Br}function u(e,t){t?e.$$hashKey=t:delete e.$$hashKey}function c(e,t,n){for(var r=e.$$hashKey,i=0,a=t.length;a>i;++i){var o=t[i];if(w(o)||S(o))for(var s=Object.keys(o),l=0,f=s.length;f>l;l++){var d=s[l],p=o[d];n&&w(p)?M(p)?e[d]=new Date(p.valueOf()):T(p)?e[d]=new RegExp(p):p.nodeName?e[d]=p.cloneNode(!0):F(p)?e[d]=p.clone():(w(e[d])||(e[d]=qr(p)?[]:{}),c(e[d],[p],!0)):e[d]=p}}return u(e,r),e}function f(e){return c(e,zr.call(arguments,1),!1)}function d(e){return c(e,zr.call(arguments,1),!0)}function p(e){return parseInt(e,10)}function h(e,t){return f(Object.create(e),t)}function m(){}function g(e){return e}function v(e){return function(){return e}}function b(e){return S(e.toString)&&e.toString!==Hr}function y(e){return"undefined"==typeof e}function $(e){return"undefined"!=typeof e}function w(e){return null!==e&&"object"==typeof e}function x(e){return null!==e&&"object"==typeof e&&!Ur(e)}function k(e){return"string"==typeof e}function C(e){return"number"==typeof e}function M(e){return"[object Date]"===Hr.call(e)}function S(e){return"function"==typeof e}function T(e){return"[object RegExp]"===Hr.call(e)}function D(e){return e&&e.window===e}function E(e){return e&&e.$evalAsync&&e.$watch}function O(e){return"[object File]"===Hr.call(e)}function A(e){return"[object FormData]"===Hr.call(e)}function N(e){return"[object Blob]"===Hr.call(e)}function j(e){return"boolean"==typeof e}function L(e){return e&&S(e.then)}function P(e){return e&&C(e.length)&&Yr.test(Hr.call(e))}function I(e){return"[object ArrayBuffer]"===Hr.call(e)}function F(e){return!(!e||!(e.nodeName||e.prop&&e.attr&&e.find))}function z(e){var t,n={},r=e.split(",");for(t=0;t<r.length;t++)n[r[t]]=!0;return n}function _(e){return Or(e.nodeName||e[0]&&e[0].nodeName)}function R(e,t){var n=e.indexOf(t);return n>=0&&e.splice(n,1),n}function H(e,t){function r(e,t){var n,r=t.$$hashKey;if(qr(e))for(var a=0,o=e.length;o>a;a++)t.push(i(e[a]));else if(x(e))for(n in e)t[n]=i(e[n]);else if(e&&"function"==typeof e.hasOwnProperty)for(n in e)e.hasOwnProperty(n)&&(t[n]=i(e[n]));else for(n in e)Er.call(e,n)&&(t[n]=i(e[n]));return u(t,r),t}function i(e){if(!w(e))return e;var t=s.indexOf(e);if(-1!==t)return l[t];if(D(e)||E(e))throw Vr("cpws","Can't copy! Making copies of Window or Scope instances is not supported.");var i=!1,a=o(e);return a===n&&(a=qr(e)?[]:Object.create(Ur(e)),i=!0),s.push(e),l.push(a),i?r(e,a):a}function o(e){switch(Hr.call(e)){case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Float32Array]":case"[object Float64Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return new e.constructor(i(e.buffer));case"[object ArrayBuffer]":if(!e.slice){var t=new ArrayBuffer(e.byteLength);return new Uint8Array(t).set(new Uint8Array(e)),t}return e.slice(0);case"[object Boolean]":case"[object Number]":case"[object String]":case"[object Date]":return new e.constructor(e.valueOf());case"[object RegExp]":var n=new RegExp(e.source,e.toString().match(/[^\/]*$/)[0]);return n.lastIndex=e.lastIndex,n;case"[object Blob]":return new e.constructor([e],{type:e.type})}return S(e.cloneNode)?e.cloneNode(!0):void 0}var s=[],l=[];if(t){if(P(t)||I(t))throw Vr("cpta","Can't copy! TypedArray destination cannot be mutated.");if(e===t)throw Vr("cpi","Can't copy! Source and destination are identical.");return qr(t)?t.length=0:a(t,function(e,n){"$$hashKey"!==n&&delete t[n]}),s.push(e),l.push(t),r(e,t)}return i(e)}function U(e,t){if(qr(e)){t=t||[];for(var n=0,r=e.length;r>n;n++)t[n]=e[n]}else if(w(e)){t=t||{};for(var i in e)"$"===i.charAt(0)&&"$"===i.charAt(1)||(t[i]=e[i])}return t||e}function V(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!==e&&t!==t)return!0;var n,r,i,a=typeof e,o=typeof t;if(a==o&&"object"==a){if(!qr(e)){if(M(e))return M(t)?V(e.getTime(),t.getTime()):!1;if(T(e))return T(t)?e.toString()==t.toString():!1;if(E(e)||E(t)||D(e)||D(t)||qr(t)||M(t)||T(t))return!1;i=ve();for(r in e)if("$"!==r.charAt(0)&&!S(e[r])){if(!V(e[r],t[r]))return!1;i[r]=!0}for(r in t)if(!(r in i)&&"$"!==r.charAt(0)&&$(t[r])&&!S(t[r]))return!1;return!0}if(!qr(t))return!1;if((n=e.length)==t.length){for(r=0;n>r;r++)if(!V(e[r],t[r]))return!1;return!0}}return!1}function W(e,t,n){return e.concat(zr.call(t,n));
}function B(e,t){return zr.call(e,t||0)}function q(e,t){var n=arguments.length>2?B(arguments,2):[];return!S(t)||t instanceof RegExp?t:n.length?function(){return arguments.length?t.apply(e,W(n,arguments,0)):t.apply(e,n)}:function(){return arguments.length?t.apply(e,arguments):t.call(e)}}function Y(e,r){var i=r;return"string"==typeof e&&"$"===e.charAt(0)&&"$"===e.charAt(1)?i=n:D(r)?i="$WINDOW":r&&t===r?i="$DOCUMENT":E(r)&&(i="$SCOPE"),i}function G(e,t){return y(e)?n:(C(t)||(t=t?2:null),JSON.stringify(e,Y,t))}function X(e){return k(e)?JSON.parse(e):e}function K(e,t){e=e.replace(Zr,"");var n=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(n)?t:n}function J(e,t){return e=new Date(e.getTime()),e.setMinutes(e.getMinutes()+t),e}function Z(e,t,n){n=n?-1:1;var r=e.getTimezoneOffset(),i=K(t,r);return J(e,n*(i-r))}function Q(e){e=Pr(e).clone();try{e.empty()}catch(t){}var n=Pr("<div>").append(e).html();try{return e[0].nodeType===ii?Or(n):n.match(/^(<[^>]+>)/)[1].replace(/^<([\w\-]+)/,function(e,t){return"<"+Or(t)})}catch(t){return Or(n)}}function ee(e){try{return decodeURIComponent(e)}catch(t){}}function te(e){var t={};return a((e||"").split("&"),function(e){var n,r,i;e&&(r=e=e.replace(/\+/g,"%20"),n=e.indexOf("="),-1!==n&&(r=e.substring(0,n),i=e.substring(n+1)),r=ee(r),$(r)&&(i=$(i)?ee(i):!0,Er.call(t,r)?qr(t[r])?t[r].push(i):t[r]=[t[r],i]:t[r]=i))}),t}function ne(e){var t=[];return a(e,function(e,n){qr(e)?a(e,function(e){t.push(ie(n,!0)+(e===!0?"":"="+ie(e,!0)))}):t.push(ie(n,!0)+(e===!0?"":"="+ie(e,!0)))}),t.length?t.join("&"):""}function re(e){return ie(e,!0).replace(/%26/gi,"&").replace(/%3D/gi,"=").replace(/%2B/gi,"+")}function ie(e,t){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%3B/gi,";").replace(/%20/g,t?"%20":"+")}function ae(e,t){var n,r,i=Qr.length;for(r=0;i>r;++r)if(n=Qr[r]+t,k(n=e.getAttribute(n)))return n;return null}function oe(e,t){var n,r,i={};a(Qr,function(t){var i=t+"app";!n&&e.hasAttribute&&e.hasAttribute(i)&&(n=e,r=e.getAttribute(i))}),a(Qr,function(t){var i,a=t+"app";!n&&(i=e.querySelector("["+a.replace(":","\\:")+"]"))&&(n=i,r=i.getAttribute(a))}),n&&(i.strictDi=null!==ae(n,"strict-di"),t(n,r?[r]:[],i))}function se(n,r,i){w(i)||(i={});var o={strictDi:!1};i=f(o,i);var s=function(){if(n=Pr(n),n.injector()){var e=n[0]===t?"document":Q(n);throw Vr("btstrpd","App Already Bootstrapped with this Element '{0}'",e.replace(/</,"&lt;").replace(/>/,"&gt;"))}r=r||[],r.unshift(["$provide",function(e){e.value("$rootElement",n)}]),i.debugInfoEnabled&&r.push(["$compileProvider",function(e){e.debugInfoEnabled(!0)}]),r.unshift("ng");var a=it(r,i.strictDi);return a.invoke(["$rootScope","$rootElement","$compile","$injector",function(e,t,n,r){e.$apply(function(){t.data("$injector",r),n(t)(e)})}]),a},l=/^NG_ENABLE_DEBUG_INFO!/,u=/^NG_DEFER_BOOTSTRAP!/;return e&&l.test(e.name)&&(i.debugInfoEnabled=!0,e.name=e.name.replace(l,"")),e&&!u.test(e.name)?s():(e.name=e.name.replace(u,""),Wr.resumeBootstrap=function(e){return a(e,function(e){r.push(e)}),s()},void(S(Wr.resumeDeferredBootstrap)&&Wr.resumeDeferredBootstrap()))}function le(){e.name="NG_ENABLE_DEBUG_INFO!"+e.name,e.location.reload()}function ue(e){var t=Wr.element(e).injector();if(!t)throw Vr("test","no injector found for element argument to getTestability");return t.get("$$testability")}function ce(e,t){return t=t||"_",e.replace(ei,function(e,n){return(n?t:"")+e.toLowerCase()})}function fe(){var t;if(!ti){var r=Jr();Ir=y(r)?e.jQuery:r?e[r]:n,Ir&&Ir.fn.on?(Pr=Ir,f(Ir.fn,{scope:ki.scope,isolateScope:ki.isolateScope,controller:ki.controller,injector:ki.injector,inheritedData:ki.inheritedData}),t=Ir.cleanData,Ir.cleanData=function(e){for(var n,r,i=0;null!=(r=e[i]);i++)n=Ir._data(r,"events"),n&&n.$destroy&&Ir(r).triggerHandler("$destroy");t(e)}):Pr=Ae,Wr.element=Pr,ti=!0}}function de(e,t,n){if(!e)throw Vr("areq","Argument '{0}' is {1}",t||"?",n||"required");return e}function pe(e,t,n){return n&&qr(e)&&(e=e[e.length-1]),de(S(e),t,"not a function, got "+(e&&"object"==typeof e?e.constructor.name||"Object":typeof e)),e}function he(e,t){if("hasOwnProperty"===e)throw Vr("badname","hasOwnProperty is not a valid {0} name",t)}function me(e,t,n){if(!t)return e;for(var r,i=t.split("."),a=e,o=i.length,s=0;o>s;s++)r=i[s],e&&(e=(a=e)[r]);return!n&&S(e)?q(a,e):e}function ge(e){for(var t,n=e[0],r=e[e.length-1],i=1;n!==r&&(n=n.nextSibling);i++)(t||e[i]!==n)&&(t||(t=Pr(zr.call(e,0,i))),t.push(n));return t||e}function ve(){return Object.create(null)}function be(e){function t(e,t,n){return e[t]||(e[t]=n())}var n=r("$injector"),i=r("ng"),a=t(e,"angular",Object);return a.$$minErr=a.$$minErr||r,t(a,"module",function(){var e={};return function(r,a,o){var s=function(e,t){if("hasOwnProperty"===e)throw i("badname","hasOwnProperty is not a valid {0} name",t)};return s(r,"module"),a&&e.hasOwnProperty(r)&&(e[r]=null),t(e,r,function(){function e(e,t,n,r){return r||(r=i),function(){return r[n||"push"]([e,t,arguments]),c}}function t(e,t){return function(n,a){return a&&S(a)&&(a.$$moduleName=r),i.push([e,t,arguments]),c}}if(!a)throw n("nomod","Module '{0}' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.",r);var i=[],s=[],l=[],u=e("$injector","invoke","push",s),c={_invokeQueue:i,_configBlocks:s,_runBlocks:l,requires:a,name:r,provider:t("$provide","provider"),factory:t("$provide","factory"),service:t("$provide","service"),value:e("$provide","value"),constant:e("$provide","constant","unshift"),decorator:t("$provide","decorator"),animation:t("$animateProvider","register"),filter:t("$filterProvider","register"),controller:t("$controllerProvider","register"),directive:t("$compileProvider","directive"),component:t("$compileProvider","component"),config:u,run:function(e){return l.push(e),this}};return o&&u(o),c})}})}function ye(e){var t=[];return JSON.stringify(e,function(e,n){if(n=Y(e,n),w(n)){if(t.indexOf(n)>=0)return"...";t.push(n)}return n})}function $e(e){return"function"==typeof e?e.toString().replace(/ \{[\s\S]*$/,""):y(e)?"undefined":"string"!=typeof e?ye(e):e}function we(t){f(t,{bootstrap:se,copy:H,extend:f,merge:d,equals:V,element:Pr,forEach:a,injector:it,noop:m,bind:q,toJson:G,fromJson:X,identity:g,isUndefined:y,isDefined:$,isString:k,isFunction:S,isObject:w,isNumber:C,isElement:F,isArray:qr,version:li,isDate:M,lowercase:Or,uppercase:Ar,callbacks:{counter:0},getTestability:ue,$$minErr:r,$$csp:Kr,reloadWithDebugInfo:le}),(Fr=be(e))("ng",["ngLocale"],["$provide",function(e){e.provider({$$sanitizeUri:kn}),e.provider("$compile",ht).directive({a:Ea,input:Ga,textarea:Ga,form:La,script:Wo,select:Yo,style:Xo,option:Go,ngBind:Ja,ngBindHtml:Qa,ngBindTemplate:Za,ngClass:to,ngClassEven:ro,ngClassOdd:no,ngCloak:io,ngController:ao,ngForm:Pa,ngHide:Fo,ngIf:lo,ngInclude:uo,ngInit:fo,ngNonBindable:Do,ngPluralize:No,ngRepeat:jo,ngShow:Io,ngStyle:zo,ngSwitch:_o,ngSwitchWhen:Ro,ngSwitchDefault:Ho,ngOptions:Ao,ngTransclude:Vo,ngModel:Mo,ngList:po,ngChange:eo,pattern:Jo,ngPattern:Jo,required:Ko,ngRequired:Ko,minlength:Qo,ngMinlength:Qo,maxlength:Zo,ngMaxlength:Zo,ngValue:Ka,ngModelOptions:To}).directive({ngInclude:co}).directive(Oa).directive(oo),e.provider({$anchorScroll:at,$animate:_i,$animateCss:Ui,$$animateJs:Fi,$$animateQueue:zi,$$AnimateRunner:Hi,$$animateAsyncRun:Ri,$browser:ft,$cacheFactory:dt,$controller:yt,$document:$t,$exceptionHandler:wt,$filter:Fn,$$forceReflow:Yi,$interpolate:Pt,$interval:It,$http:At,$httpParamSerializer:kt,$httpParamSerializerJQLike:Ct,$httpBackend:jt,$xhrFactory:Nt,$location:Kt,$log:Jt,$parse:vn,$rootScope:xn,$q:bn,$$q:yn,$sce:Tn,$sceDelegate:Sn,$sniffer:Dn,$templateCache:pt,$templateRequest:En,$$testability:On,$timeout:An,$window:Ln,$$rAF:wn,$$jqLite:Ze,$$HashMap:Ti,$$cookieReader:In})}])}function xe(){return++ci}function ke(e){return e.replace(pi,function(e,t,n,r){return r?n.toUpperCase():n}).replace(hi,"Moz$1")}function Ce(e){return!bi.test(e)}function Me(e){var t=e.nodeType;return t===ni||!t||t===oi}function Se(e){for(var t in ui[e.ng339])return!0;return!1}function Te(e){for(var t=0,n=e.length;n>t;t++)Pe(e[t])}function De(e,t){var n,r,i,o,s=t.createDocumentFragment(),l=[];if(Ce(e))l.push(t.createTextNode(e));else{for(n=n||s.appendChild(t.createElement("div")),r=(yi.exec(e)||["",""])[1].toLowerCase(),i=wi[r]||wi._default,n.innerHTML=i[1]+e.replace($i,"<$1></$2>")+i[2],o=i[0];o--;)n=n.lastChild;l=W(l,n.childNodes),n=s.firstChild,n.textContent=""}return s.textContent="",s.innerHTML="",a(l,function(e){s.appendChild(e)}),s}function Ee(e,n){n=n||t;var r;return(r=vi.exec(e))?[n.createElement(r[1])]:(r=De(e,n))?r.childNodes:[]}function Oe(e,t){var n=e.parentNode;n&&n.replaceChild(t,e),t.appendChild(e)}function Ae(e){if(e instanceof Ae)return e;var t;if(k(e)&&(e=Gr(e),t=!0),!(this instanceof Ae)){if(t&&"<"!=e.charAt(0))throw gi("nosel","Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element");return new Ae(e)}t?He(this,Ee(e)):He(this,e)}function Ne(e){return e.cloneNode(!0)}function je(e,t){if(t||Pe(e),e.querySelectorAll)for(var n=e.querySelectorAll("*"),r=0,i=n.length;i>r;r++)Pe(n[r])}function Le(e,t,n,r){if($(r))throw gi("offargs","jqLite#off() does not support the `selector` argument");var i=Ie(e),o=i&&i.events,s=i&&i.handle;if(s)if(t){var l=function(t){var r=o[t];$(n)&&R(r||[],n),$(n)&&r&&r.length>0||(di(e,t,s),delete o[t])};a(t.split(" "),function(e){l(e),mi[e]&&l(mi[e])})}else for(t in o)"$destroy"!==t&&di(e,t,s),delete o[t]}function Pe(e,t){var r=e.ng339,i=r&&ui[r];if(i){if(t)return void delete i.data[t];i.handle&&(i.events.$destroy&&i.handle({},"$destroy"),Le(e)),delete ui[r],e.ng339=n}}function Ie(e,t){var r=e.ng339,i=r&&ui[r];return t&&!i&&(e.ng339=r=xe(),i=ui[r]={events:{},data:{},handle:n}),i}function Fe(e,t,n){if(Me(e)){var r=$(n),i=!r&&t&&!w(t),a=!t,o=Ie(e,!i),s=o&&o.data;if(r)s[t]=n;else{if(a)return s;if(i)return s&&s[t];f(s,t)}}}function ze(e,t){return e.getAttribute?(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").indexOf(" "+t+" ")>-1:!1}function _e(e,t){t&&e.setAttribute&&a(t.split(" "),function(t){e.setAttribute("class",Gr((" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").replace(" "+Gr(t)+" "," ")))})}function Re(e,t){if(t&&e.setAttribute){var n=(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ");a(t.split(" "),function(e){e=Gr(e),-1===n.indexOf(" "+e+" ")&&(n+=e+" ")}),e.setAttribute("class",Gr(n))}}function He(e,t){if(t)if(t.nodeType)e[e.length++]=t;else{var n=t.length;if("number"==typeof n&&t.window!==t){if(n)for(var r=0;n>r;r++)e[e.length++]=t[r]}else e[e.length++]=t}}function Ue(e,t){return Ve(e,"$"+(t||"ngController")+"Controller")}function Ve(e,t,n){e.nodeType==oi&&(e=e.documentElement);for(var r=qr(t)?t:[t];e;){for(var i=0,a=r.length;a>i;i++)if($(n=Pr.data(e,r[i])))return n;e=e.parentNode||e.nodeType===si&&e.host}}function We(e){for(je(e,!0);e.firstChild;)e.removeChild(e.firstChild)}function Be(e,t){t||je(e);var n=e.parentNode;n&&n.removeChild(e)}function qe(t,n){n=n||e,"complete"===n.document.readyState?n.setTimeout(t):Pr(n).on("load",t)}function Ye(e,t){var n=Ci[t.toLowerCase()];return n&&Mi[_(e)]&&n}function Ge(e){return Si[e]}function Xe(e,t){var n=function(n,r){n.isDefaultPrevented=function(){return n.defaultPrevented};var i=t[r||n.type],a=i?i.length:0;if(a){if(y(n.immediatePropagationStopped)){var o=n.stopImmediatePropagation;n.stopImmediatePropagation=function(){n.immediatePropagationStopped=!0,n.stopPropagation&&n.stopPropagation(),o&&o.call(n)}}n.isImmediatePropagationStopped=function(){return n.immediatePropagationStopped===!0};var s=i.specialHandlerWrapper||Ke;a>1&&(i=U(i));for(var l=0;a>l;l++)n.isImmediatePropagationStopped()||s(e,n,i[l])}};return n.elem=e,n}function Ke(e,t,n){n.call(e,t)}function Je(e,t,n){var r=t.relatedTarget;r&&(r===e||xi.call(e,r))||n.call(e,t)}function Ze(){this.$get=function(){return f(Ae,{hasClass:function(e,t){return e.attr&&(e=e[0]),ze(e,t)},addClass:function(e,t){return e.attr&&(e=e[0]),Re(e,t)},removeClass:function(e,t){return e.attr&&(e=e[0]),_e(e,t)}})}}function Qe(e,t){var n=e&&e.$$hashKey;if(n)return"function"==typeof n&&(n=e.$$hashKey()),n;var r=typeof e;return n="function"==r||"object"==r&&null!==e?e.$$hashKey=r+":"+(t||l)():r+":"+e}function et(e,t){if(t){var n=0;this.nextUid=function(){return++n}}a(e,this.put,this)}function tt(e){var t=e.toString().replace(Ni,""),n=t.match(Di)||t.match(Ei);return n}function nt(e){var t=tt(e);return t?"function("+(t[1]||"").replace(/[\s\r\n]+/," ")+")":"fn"}function rt(e,t,n){var r,i,o;if("function"==typeof e){if(!(r=e.$inject)){if(r=[],e.length){if(t)throw k(n)&&n||(n=e.name||nt(e)),ji("strictdi","{0} is not using explicit annotation and cannot be invoked in strict mode",n);i=tt(e),a(i[1].split(Oi),function(e){e.replace(Ai,function(e,t,n){r.push(n)})})}e.$inject=r}}else qr(e)?(o=e.length-1,pe(e[o],"fn"),r=e.slice(0,o)):pe(e,"fn",!0);return r}function it(e,t){function r(e){return function(t,n){return w(t)?void a(t,s(e)):e(t,n)}}function i(e,t){if(he(e,"service"),(S(t)||qr(t))&&(t=C.instantiate(t)),!t.$get)throw ji("pget","Provider '{0}' must define $get factory method.",e);return x[e+g]=t}function o(e,t){return function(){var n=D.invoke(t,this);if(y(n))throw ji("undef","Provider '{0}' must return a value from $get factory method.",e);return n}}function l(e,t,n){return i(e,{$get:n!==!1?o(e,t):t})}function u(e,t){return l(e,["$injector",function(e){return e.instantiate(t)}])}function c(e,t){return l(e,v(t),!1)}function f(e,t){he(e,"constant"),x[e]=t,M[e]=t}function d(e,t){var n=C.get(e+g),r=n.$get;n.$get=function(){var e=D.invoke(r,n);return D.invoke(t,null,{$delegate:e})}}function p(e){de(y(e)||qr(e),"modulesToLoad","not an array");var t,n=[];return a(e,function(e){function r(e){var t,n;for(t=0,n=e.length;n>t;t++){var r=e[t],i=C.get(r[0]);i[r[1]].apply(i,r[2])}}if(!$.get(e)){$.put(e,!0);try{k(e)?(t=Fr(e),n=n.concat(p(t.requires)).concat(t._runBlocks),r(t._invokeQueue),r(t._configBlocks)):S(e)?n.push(C.invoke(e)):qr(e)?n.push(C.invoke(e)):pe(e,"module")}catch(i){throw qr(e)&&(e=e[e.length-1]),i.message&&i.stack&&-1==i.stack.indexOf(i.message)&&(i=i.message+"\n"+i.stack),ji("modulerr","Failed to instantiate module {0} due to:\n{1}",e,i.stack||i.message||i)}}}),n}function h(e,n){function r(t,r){if(e.hasOwnProperty(t)){if(e[t]===m)throw ji("cdep","Circular dependency found: {0}",t+" <- "+b.join(" <- "));return e[t]}try{return b.unshift(t),e[t]=m,e[t]=n(t,r)}catch(i){throw e[t]===m&&delete e[t],i}finally{b.shift()}}function i(e,n,i){for(var a=[],o=it.$$annotate(e,t,i),s=0,l=o.length;l>s;s++){var u=o[s];if("string"!=typeof u)throw ji("itkn","Incorrect injection token! Expected service name as string, got {0}",u);a.push(n&&n.hasOwnProperty(u)?n[u]:r(u,i))}return a}function a(e){return 11>=Lr?!1:"function"==typeof e&&/^(?:class\s|constructor\()/.test(Function.prototype.toString.call(e))}function o(e,t,n,r){"string"==typeof n&&(r=n,n=null);var o=i(e,n,r);return qr(e)&&(e=e[e.length-1]),a(e)?(o.unshift(null),new(Function.prototype.bind.apply(e,o))):e.apply(t,o)}function s(e,t,n){var r=qr(e)?e[e.length-1]:e,a=i(e,t,n);return a.unshift(null),new(Function.prototype.bind.apply(r,a))}return{invoke:o,instantiate:s,get:r,annotate:it.$$annotate,has:function(t){return x.hasOwnProperty(t+g)||e.hasOwnProperty(t)}}}t=t===!0;var m={},g="Provider",b=[],$=new et([],!0),x={$provide:{provider:r(i),factory:r(l),service:r(u),value:r(c),constant:r(f),decorator:d}},C=x.$injector=h(x,function(e,t){throw Wr.isString(t)&&b.push(t),ji("unpr","Unknown provider: {0}",b.join(" <- "))}),M={},T=h(M,function(e,t){var r=C.get(e+g,t);return D.invoke(r.$get,r,n,e)}),D=T;x["$injector"+g]={$get:v(T)};var E=p(e);return D=T.get("$injector"),D.strictDi=t,a(E,function(e){e&&D.invoke(e)}),D}function at(){var e=!0;this.disableAutoScrolling=function(){e=!1},this.$get=["$window","$location","$rootScope",function(t,n,r){function i(e){var t=null;return Array.prototype.some.call(e,function(e){return"a"===_(e)?(t=e,!0):void 0}),t}function a(){var e=s.yOffset;if(S(e))e=e();else if(F(e)){var n=e[0],r=t.getComputedStyle(n);e="fixed"!==r.position?0:n.getBoundingClientRect().bottom}else C(e)||(e=0);return e}function o(e){if(e){e.scrollIntoView();var n=a();if(n){var r=e.getBoundingClientRect().top;t.scrollBy(0,r-n)}}else t.scrollTo(0,0)}function s(e){e=k(e)?e:n.hash();var t;e?(t=l.getElementById(e))?o(t):(t=i(l.getElementsByName(e)))?o(t):"top"===e&&o(null):o(null)}var l=t.document;return e&&r.$watch(function(){return n.hash()},function(e,t){e===t&&""===e||qe(function(){r.$evalAsync(s)})}),s}]}function ot(e,t){return e||t?e?t?(qr(e)&&(e=e.join(" ")),qr(t)&&(t=t.join(" ")),e+" "+t):e:t:""}function st(e){for(var t=0;t<e.length;t++){var n=e[t];if(n.nodeType===Pi)return n}}function lt(e){k(e)&&(e=e.split(" "));var t=ve();return a(e,function(e){e.length&&(t[e]=!0)}),t}function ut(e){return w(e)?e:{}}function ct(e,t,n,r){function i(e){try{e.apply(null,B(arguments,1))}finally{if(b--,0===b)for(;$.length;)try{$.pop()()}catch(t){n.error(t)}}}function o(e){var t=e.indexOf("#");return-1===t?"":e.substr(t)}function s(){M=null,u(),c()}function l(){try{return p.state}catch(e){}}function u(){w=l(),w=y(w)?null:w,V(w,D)&&(w=D),D=w}function c(){k===f.url()&&x===w||(k=f.url(),x=w,a(S,function(e){e(f.url(),w)}))}var f=this,d=e.location,p=e.history,h=e.setTimeout,g=e.clearTimeout,v={};f.isMock=!1;var b=0,$=[];f.$$completeOutstandingRequest=i,f.$$incOutstandingRequestCount=function(){b++},f.notifyWhenNoOutstandingRequests=function(e){0===b?e():$.push(e)};var w,x,k=d.href,C=t.find("base"),M=null;u(),x=w,f.url=function(t,n,i){if(y(i)&&(i=null),d!==e.location&&(d=e.location),p!==e.history&&(p=e.history),t){var a=x===i;if(k===t&&(!r.history||a))return f;var s=k&&Ht(k)===Ht(t);return k=t,x=i,!r.history||s&&a?(s&&!M||(M=t),n?d.replace(t):s?d.hash=o(t):d.href=t,d.href!==t&&(M=t)):(p[n?"replaceState":"pushState"](i,"",t),u(),x=w),f}return M||d.href.replace(/%27/g,"'")},f.state=function(){return w};var S=[],T=!1,D=null;f.onUrlChange=function(t){return T||(r.history&&Pr(e).on("popstate",s),Pr(e).on("hashchange",s),T=!0),S.push(t),t},f.$$applicationDestroyed=function(){Pr(e).off("hashchange popstate",s)},f.$$checkUrlChange=c,f.baseHref=function(){var e=C.attr("href");return e?e.replace(/^(https?\:)?\/\/[^\/]*/,""):""},f.defer=function(e,t){var n;return b++,n=h(function(){delete v[n],i(e)},t||0),v[n]=!0,n},f.defer.cancel=function(e){return v[e]?(delete v[e],g(e),i(m),!0):!1}}function ft(){this.$get=["$window","$log","$sniffer","$document",function(e,t,n,r){return new ct(e,r,t,n)}]}function dt(){this.$get=function(){function e(e,n){function i(e){e!=d&&(p?p==e&&(p=e.n):p=e,a(e.n,e.p),a(e,d),d=e,d.n=null)}function a(e,t){e!=t&&(e&&(e.p=t),t&&(t.n=e))}if(e in t)throw r("$cacheFactory")("iid","CacheId '{0}' is already taken!",e);var o=0,s=f({},n,{id:e}),l=ve(),u=n&&n.capacity||Number.MAX_VALUE,c=ve(),d=null,p=null;return t[e]={put:function(e,t){if(!y(t)){if(u<Number.MAX_VALUE){var n=c[e]||(c[e]={key:e});i(n)}return e in l||o++,l[e]=t,o>u&&this.remove(p.key),t}},get:function(e){if(u<Number.MAX_VALUE){var t=c[e];if(!t)return;i(t)}return l[e]},remove:function(e){if(u<Number.MAX_VALUE){var t=c[e];if(!t)return;t==d&&(d=t.p),t==p&&(p=t.n),a(t.n,t.p),delete c[e]}e in l&&(delete l[e],o--)},removeAll:function(){l=ve(),o=0,c=ve(),d=p=null},destroy:function(){l=null,s=null,c=null,delete t[e]},info:function(){return f({},s,{size:o})}}}var t={};return e.info=function(){var e={};return a(t,function(t,n){e[n]=t.info()}),e},e.get=function(e){return t[e]},e}}function pt(){this.$get=["$cacheFactory",function(e){return e("templates")}]}function ht(e,r){function i(e,t,n){var r=/^\s*([@&<]|=(\*?))(\??)\s*(\w*)\s*$/,i={};return a(e,function(e,a){if(e in M)return void(i[a]=M[e]);var o=e.match(r);if(!o)throw Vi("iscp","Invalid {3} for directive '{0}'. Definition: {... {1}: '{2}' ...}",t,a,e,n?"controller bindings definition":"isolate scope definition");i[a]={mode:o[1][0],collection:"*"===o[2],optional:"?"===o[3],attrName:o[4]||a},o[4]&&(M[e]=i[a])}),i}function o(e,t){var n={isolateScope:null,bindToController:null};if(w(e.scope)&&(e.bindToController===!0?(n.bindToController=i(e.scope,t,!0),n.isolateScope={}):n.isolateScope=i(e.scope,t,!1)),w(e.bindToController)&&(n.bindToController=i(e.bindToController,t,!0)),w(n.bindToController)){var r=e.controller,a=e.controllerAs;if(!r)throw Vi("noctrl","Cannot bind to controller without directive '{0}'s controller.",t);if(!bt(r,a))throw Vi("noident","Cannot bind to controller without identifier for directive '{0}'.",t)}return n}function l(e){var t=e.charAt(0);if(!t||t!==Or(t))throw Vi("baddir","Directive name '{0}' is invalid. The first character must be a lowercase letter",e);if(e!==e.trim())throw Vi("baddir","Directive name '{0}' is invalid. The name should not contain leading or trailing whitespaces",e)}var u={},c="Directive",d=/^\s*directive\:\s*([\w\-]+)\s+(.*)$/,p=/(([\w\-]+)(?:\:([^;]+))?;?)/,b=z("ngSrc,ngSrcset,src,srcset"),x=/^(?:(\^\^?)?(\?)?(\^\^?)?)?/,C=/^(on[a-z]+|formaction)$/,M=ve();this.directive=function D(t,n){return he(t,"directive"),k(t)?(l(t),de(n,"directiveFactory"),u.hasOwnProperty(t)||(u[t]=[],e.factory(t+c,["$injector","$exceptionHandler",function(e,n){var r=[];return a(u[t],function(i,a){try{var o=e.invoke(i);S(o)?o={compile:v(o)}:!o.compile&&o.link&&(o.compile=v(o.link)),o.priority=o.priority||0,o.index=a,o.name=o.name||t,o.require=o.require||o.controller&&o.name,o.restrict=o.restrict||"EA",o.$$moduleName=i.$$moduleName,r.push(o)}catch(s){n(s)}}),r}])),u[t].push(n)):a(t,s(D)),this},this.component=function(e,t){function n(e){function n(t){return S(t)||qr(t)?function(n,r){return e.invoke(t,this,{$element:n,$attrs:r})}:t}var i=t.template||t.templateUrl?t.template:"";return{controller:r,controllerAs:bt(t.controller)||t.controllerAs||"$ctrl",template:n(i),templateUrl:n(t.templateUrl),transclude:t.transclude,scope:{},bindToController:t.bindings||{},restrict:"E",require:t.require}}var r=t.controller||m;return a(t,function(e,t){"$"===t.charAt(0)&&(n[t]=e,r[t]=e)}),n.$inject=["$injector"],this.directive(e,n)},this.aHrefSanitizationWhitelist=function(e){return $(e)?(r.aHrefSanitizationWhitelist(e),this):r.aHrefSanitizationWhitelist()},this.imgSrcSanitizationWhitelist=function(e){return $(e)?(r.imgSrcSanitizationWhitelist(e),this):r.imgSrcSanitizationWhitelist()};var T=!0;this.debugInfoEnabled=function(e){return $(e)?(T=e,this):T},this.$get=["$injector","$interpolate","$exceptionHandler","$templateRequest","$parse","$controller","$rootScope","$sce","$animate","$$sanitizeUri",function(e,r,i,s,l,v,$,M,D,O){function A(e,t){if(t){var n,r,i,a=Object.keys(t);for(n=0,r=a.length;r>n;n++)i=a[n],this[i]=t[i]}else this.$attr={};this.$$element=e}function N(e,t,n){me.innerHTML="<span "+t+">";var r=me.firstChild.attributes,i=r[0];r.removeNamedItem(i.name),i.value=n,e.attributes.setNamedItem(i)}function L(e,t){try{e.addClass(t)}catch(n){}}function P(e,n,r,i,a){e instanceof Pr||(e=Pr(e));for(var o=/\S+/,s=0,l=e.length;l>s;s++){var u=e[s];u.nodeType===ii&&u.nodeValue.match(o)&&Oe(u,e[s]=t.createElement("span"))}var c=F(e,n,e,r,i,a);P.$$addScopeClass(e);var f=null;return function(t,n,r){de(t,"scope"),a&&a.needsNewScope&&(t=t.$parent.$new()),r=r||{};var i=r.parentBoundTranscludeFn,o=r.transcludeControllers,s=r.futureParentElement;i&&i.$$boundTransclude&&(i=i.$$boundTransclude),f||(f=I(s));var l;if(l="html"!==f?Pr(ae(f,Pr("<div>").append(e).html())):n?ki.clone.call(e):e,o)for(var u in o)l.data("$"+u+"Controller",o[u].instance);return P.$$addScopeInfo(l,t),n&&n(l,t),c&&c(t,l,l,i),l}}function I(e){var t=e&&e[0];return t&&"foreignobject"!==_(t)&&Hr.call(t).match(/SVG/)?"svg":"html"}function F(e,t,r,i,a,o){function s(e,r,i,a){var o,s,l,u,c,f,d,p,g;if(h){var v=r.length;for(g=new Array(v),c=0;c<m.length;c+=3)d=m[c],g[d]=r[d]}else g=r;for(c=0,f=m.length;f>c;)l=g[m[c++]],o=m[c++],s=m[c++],o?(o.scope?(u=e.$new(),P.$$addScopeInfo(Pr(l),u)):u=e,p=o.transcludeOnThisElement?z(e,o.transclude,a):!o.templateOnThisElement&&a?a:!a&&t?z(e,t):null,o(s,u,l,i,p)):s&&s(e,l.childNodes,n,a)}for(var l,u,c,f,d,p,h,m=[],g=0;g<e.length;g++)l=new A,u=H(e[g],[],l,0===g?i:n,a),c=u.length?Y(u,e[g],l,t,r,null,[],[],o):null,c&&c.scope&&P.$$addScopeClass(l.$$element),d=c&&c.terminal||!(f=e[g].childNodes)||!f.length?null:F(f,c?(c.transcludeOnThisElement||!c.templateOnThisElement)&&c.transclude:t),(c||d)&&(m.push(g,c,d),p=!0,h=h||c),o=null;return p?s:null}function z(e,t,n){function r(r,i,a,o,s){return r||(r=e.$new(!1,s),r.$$transcluded=!0),t(r,i,{parentBoundTranscludeFn:n,transcludeControllers:a,futureParentElement:o})}var i=r.$$slots=ve();for(var a in t.$$slots)t.$$slots[a]?i[a]=z(e,t.$$slots[a],n):i[a]=null;return r}function H(e,t,n,r,i){var a,o,s=e.nodeType,l=n.$attr;switch(s){case ni:J(t,mt(_(e)),"E",r,i);for(var u,c,f,h,m,g,v=e.attributes,b=0,y=v&&v.length;y>b;b++){var $=!1,x=!1;u=v[b],c=u.name,m=Gr(u.value),h=mt(c),(g=$e.test(h))&&(c=c.replace(Wi,"").substr(8).replace(/_(.)/g,function(e,t){return t.toUpperCase()}));var C=h.match(we);C&&Z(C[1])&&($=c,x=c.substr(0,c.length-5)+"end",c=c.substr(0,c.length-6)),f=mt(c.toLowerCase()),l[f]=c,!g&&n.hasOwnProperty(f)||(n[f]=m,Ye(e,f)&&(n[f]=!0)),se(e,t,m,f,g),J(t,f,"A",r,i,$,x)}if(o=e.className,w(o)&&(o=o.animVal),k(o)&&""!==o)for(;a=p.exec(o);)f=mt(a[2]),J(t,f,"C",r,i)&&(n[f]=Gr(a[3])),o=o.substr(a.index+a[0].length);break;case ii:if(11===Lr)for(;e.parentNode&&e.nextSibling&&e.nextSibling.nodeType===ii;)e.nodeValue=e.nodeValue+e.nextSibling.nodeValue,e.parentNode.removeChild(e.nextSibling);ie(t,e.nodeValue);break;case ai:try{a=d.exec(e.nodeValue),a&&(f=mt(a[1]),J(t,f,"M",r,i)&&(n[f]=Gr(a[2])))}catch(M){}}return t.sort(ne),t}function U(e,t,n){var r=[],i=0;if(t&&e.hasAttribute&&e.hasAttribute(t)){do{if(!e)throw Vi("uterdir","Unterminated attribute, found '{0}' but no matching '{1}' found.",t,n);e.nodeType==ni&&(e.hasAttribute(t)&&i++,e.hasAttribute(n)&&i--),r.push(e),e=e.nextSibling}while(i>0)}else r.push(e);return Pr(r)}function W(e,t,n){return function(r,i,a,o,s){return i=U(i[0],t,n),e(r,i,a,o,s)}}function q(e,t,n,r,i,a){var o;return e?P(t,n,r,i,a):function(){return o||(o=P(t,n,r,i,a),t=n=a=null),o.apply(this,arguments)}}function Y(e,t,r,o,s,l,u,c,d){function p(e,t,n,r){e&&(n&&(e=W(e,n,r)),e.require=m.require,e.directiveName=g,(M===m||m.$$isolateScope)&&(e=ue(e,{isolateScope:!0})),u.push(e)),t&&(n&&(t=W(t,n,r)),t.require=m.require,t.directiveName=g,(M===m||m.$$isolateScope)&&(t=ue(t,{isolateScope:!0})),c.push(t))}function h(e,i,o,s,l){function d(e,t,r,i){var a;if(E(e)||(i=r,r=t,t=e,e=n),j&&(a=b),r||(r=j?x.parent():x),!i)return l(e,t,a,r,R);var o=l.$$slots[i];if(o)return o(e,t,a,r,R);if(y(o))throw Vi("noslot",'No parent directive that requires a transclusion with slot name "{0}". Element: {1}',i,Q(x))}var p,h,m,g,v,b,$,x,D,O,N;t===o?(D=r,x=r.$$element):(x=Pr(o),D=new A(x,r)),v=i,M?g=i.$new(!0):k&&(v=i.$parent),l&&($=d,$.$$boundTransclude=l,$.isSlotFilled=function(e){return!!l.$$slots[e]}),C&&(b=X(x,D,$,C,g,i,M)),M&&(P.$$addScopeInfo(x,g,!0,!(T&&(T===M||T===M.$$originalDirective))),P.$$addScopeClass(x,!0),g.$$isolateBindings=M.$$isolateBindings,O=pe(i,D,g,g.$$isolateBindings,M),O&&g.$on("$destroy",O));for(var L in b){var I=C[L],F=b[L],z=I.$$bindings.bindToController;F.identifier&&z&&(N=pe(v,D,F.instance,z,I));var _=F();_!==F.instance&&(F.instance=_,x.data("$"+I.name+"Controller",_),N&&N(),N=pe(v,D,F.instance,z,I))}for(a(C,function(e,t){var n=e.require;e.bindToController&&!qr(n)&&w(n)&&f(b[t].instance,G(t,n,x,b))}),a(b,function(e){S(e.instance.$onInit)&&e.instance.$onInit()}),p=0,h=u.length;h>p;p++)m=u[p],fe(m,m.isolateScope?g:i,x,D,m.require&&G(m.directiveName,m.require,x,b),$);var R=i;for(M&&(M.template||null===M.templateUrl)&&(R=g),e&&e(R,o.childNodes,n,l),p=c.length-1;p>=0;p--)m=c[p],fe(m,m.isolateScope?g:i,x,D,m.require&&G(m.directiveName,m.require,x,b),$)}d=d||{};for(var m,g,v,b,$,x=-Number.MAX_VALUE,k=d.newScopeDirective,C=d.controllerDirectives,M=d.newIsolateScopeDirective,T=d.templateDirective,D=d.nonTlbTranscludeDirective,O=!1,N=!1,j=d.hasElementTranscludeDirective,L=r.$$element=Pr(t),I=l,F=o,z=!1,R=!1,V=0,Y=e.length;Y>V;V++){m=e[V];var J=m.$$start,Z=m.$$end;if(J&&(L=U(t,J,Z)),v=n,x>m.priority)break;if(($=m.scope)&&(m.templateUrl||(w($)?(re("new/isolated scope",M||k,m,L),M=m):re("new/isolated scope",M,m,L)),k=k||m),g=m.name,!z&&(m.replace&&(m.templateUrl||m.template)||m.transclude&&!m.$$tlb)){for(var ne,ie=V+1;ne=e[ie++];)if(ne.transclude&&!ne.$$tlb||ne.replace&&(ne.templateUrl||ne.template)){R=!0;break}z=!0}if(!m.templateUrl&&m.controller&&($=m.controller,C=C||ve(),re("'"+g+"' controller",C[g],m,L),C[g]=m),$=m.transclude)if(O=!0,m.$$tlb||(re("transclusion",D,m,L),D=m),"element"==$)j=!0,x=m.priority,v=L,L=r.$$element=Pr(P.$$createComment(g,r[g])),t=L[0],le(s,B(v),t),F=q(R,v,o,x,I&&I.name,{nonTlbTranscludeDirective:D});else{var oe=ve();if(v=Pr(Ne(t)).contents(),w($)){v=[];var se=ve(),ce=ve();a($,function(e,t){var n="?"===e.charAt(0);e=n?e.substring(1):e,se[e]=t,oe[t]=null,ce[t]=n}),a(L.contents(),function(e){var t=se[mt(_(e))];t?(ce[t]=!0,oe[t]=oe[t]||[],oe[t].push(e)):v.push(e)}),a(ce,function(e,t){if(!e)throw Vi("reqslot","Required transclusion slot `{0}` was not filled.",t)});for(var de in oe)oe[de]&&(oe[de]=q(R,oe[de],o))}L.empty(),F=q(R,v,o,n,n,{needsNewScope:m.$$isolateScope||m.$$newScope}),F.$$slots=oe}if(m.template)if(N=!0,re("template",T,m,L),T=m,$=S(m.template)?m.template(L,r):m.template,$=ye($),m.replace){if(I=m,v=Ce($)?[]:vt(ae(m.templateNamespace,Gr($))),t=v[0],1!=v.length||t.nodeType!==ni)throw Vi("tplrt","Template for directive '{0}' must have exactly one root element. {1}",g,"");le(s,L,t);var he={$attr:{}},me=H(t,[],he),ge=e.splice(V+1,e.length-(V+1));(M||k)&&K(me,M,k),e=e.concat(me).concat(ge),ee(r,he),Y=e.length}else L.html($);if(m.templateUrl)N=!0,re("template",T,m,L),T=m,m.replace&&(I=m),h=te(e.splice(V,e.length-V),L,r,s,O&&F,u,c,{controllerDirectives:C,newScopeDirective:k!==m&&k,newIsolateScopeDirective:M,templateDirective:T,nonTlbTranscludeDirective:D}),Y=e.length;else if(m.compile)try{b=m.compile(L,r,F),S(b)?p(null,b,J,Z):b&&p(b.pre,b.post,J,Z)}catch(be){i(be,Q(L))}m.terminal&&(h.terminal=!0,x=Math.max(x,m.priority))}return h.scope=k&&k.scope===!0,h.transcludeOnThisElement=O,h.templateOnThisElement=N,h.transclude=F,d.hasElementTranscludeDirective=j,h}function G(e,t,n,r){var i;if(k(t)){var o=t.match(x),s=t.substring(o[0].length),l=o[1]||o[3],u="?"===o[2];if("^^"===l?n=n.parent():(i=r&&r[s],i=i&&i.instance),!i){var c="$"+s+"Controller";i=l?n.inheritedData(c):n.data(c)}if(!i&&!u)throw Vi("ctreq","Controller '{0}', required by directive '{1}', can't be found!",s,e)}else if(qr(t)){i=[];for(var f=0,d=t.length;d>f;f++)i[f]=G(e,t[f],n,r)}else w(t)&&(i={},a(t,function(t,a){i[a]=G(e,t,n,r)}));return i||null}function X(e,t,n,r,i,a,o){var s=ve();for(var l in r){var u=r[l],c={$scope:u===o||u.$$isolateScope?i:a,$element:e,$attrs:t,$transclude:n},f=u.controller;"@"==f&&(f=t[u.name]);var d=v(f,c,!0,u.controllerAs);s[u.name]=d,e.data("$"+u.name+"Controller",d.instance)}return s}function K(e,t,n){for(var r=0,i=e.length;i>r;r++)e[r]=h(e[r],{$$isolateScope:t,$$newScope:n})}function J(t,n,r,a,s,l,f){if(n===s)return null;var d=null;if(u.hasOwnProperty(n))for(var p,m=e.get(n+c),g=0,v=m.length;v>g;g++)try{if(p=m[g],(y(a)||a>p.priority)&&-1!=p.restrict.indexOf(r)){if(l&&(p=h(p,{$$start:l,$$end:f})),!p.$$bindings){var b=p.$$bindings=o(p,p.name);w(b.isolateScope)&&(p.$$isolateBindings=b.isolateScope)}t.push(p),d=p}}catch($){i($)}return d}function Z(t){if(u.hasOwnProperty(t))for(var n,r=e.get(t+c),i=0,a=r.length;a>i;i++)if(n=r[i],n.multiElement)return!0;return!1}function ee(e,t){var n=t.$attr,r=e.$attr,i=e.$$element;a(e,function(r,i){"$"!=i.charAt(0)&&(t[i]&&t[i]!==r&&(r+=("style"===i?";":" ")+t[i]),e.$set(i,r,!0,n[i]))}),a(t,function(t,a){"class"==a?(L(i,t),e["class"]=(e["class"]?e["class"]+" ":"")+t):"style"==a?(i.attr("style",i.attr("style")+";"+t),
e.style=(e.style?e.style+";":"")+t):"$"==a.charAt(0)||e.hasOwnProperty(a)||(e[a]=t,r[a]=n[a])})}function te(e,t,n,r,i,o,l,u){var c,f,d=[],p=t[0],m=e.shift(),g=h(m,{templateUrl:null,transclude:null,replace:null,$$originalDirective:m}),v=S(m.templateUrl)?m.templateUrl(t,n):m.templateUrl,b=m.templateNamespace;return t.empty(),s(v).then(function(s){var h,y,$,x;if(s=ye(s),m.replace){if($=Ce(s)?[]:vt(ae(b,Gr(s))),h=$[0],1!=$.length||h.nodeType!==ni)throw Vi("tplrt","Template for directive '{0}' must have exactly one root element. {1}",m.name,v);y={$attr:{}},le(r,t,h);var k=H(h,[],y);w(m.scope)&&K(k,!0),e=k.concat(e),ee(n,y)}else h=p,t.html(s);for(e.unshift(g),c=Y(e,h,n,i,t,m,o,l,u),a(r,function(e,n){e==h&&(r[n]=t[0])}),f=F(t[0].childNodes,i);d.length;){var C=d.shift(),M=d.shift(),S=d.shift(),T=d.shift(),D=t[0];if(!C.$$destroyed){if(M!==p){var E=M.className;u.hasElementTranscludeDirective&&m.replace||(D=Ne(h)),le(S,Pr(M),D),L(Pr(D),E)}x=c.transcludeOnThisElement?z(C,c.transclude,T):T,c(f,C,D,r,x)}}d=null}),function(e,t,n,r,i){var a=i;t.$$destroyed||(d?d.push(t,n,r,a):(c.transcludeOnThisElement&&(a=z(t,c.transclude,i)),c(f,t,n,r,a)))}}function ne(e,t){var n=t.priority-e.priority;return 0!==n?n:e.name!==t.name?e.name<t.name?-1:1:e.index-t.index}function re(e,t,n,r){function i(e){return e?" (module: "+e+")":""}if(t)throw Vi("multidir","Multiple directives [{0}{1}, {2}{3}] asking for {4} on: {5}",t.name,i(t.$$moduleName),n.name,i(n.$$moduleName),e,Q(r))}function ie(e,t){var n=r(t,!0);n&&e.push({priority:0,compile:function(e){var t=e.parent(),r=!!t.length;return r&&P.$$addBindingClass(t),function(e,t){var i=t.parent();r||P.$$addBindingClass(i),P.$$addBindingInfo(i,n.expressions),e.$watch(n,function(e){t[0].nodeValue=e})}}})}function ae(e,n){switch(e=Or(e||"html")){case"svg":case"math":var r=t.createElement("div");return r.innerHTML="<"+e+">"+n+"</"+e+">",r.childNodes[0].childNodes;default:return n}}function oe(e,t){if("srcdoc"==t)return M.HTML;var n=_(e);return"xlinkHref"==t||"form"==n&&"action"==t||"img"!=n&&("src"==t||"ngSrc"==t)?M.RESOURCE_URL:void 0}function se(e,t,n,i,a){var o=oe(e,i);a=b[i]||a;var s=r(n,!0,o,a);if(s){if("multiple"===i&&"select"===_(e))throw Vi("selmulti","Binding to the 'multiple' attribute is not supported. Element: {0}",Q(e));t.push({priority:100,compile:function(){return{pre:function(e,t,l){var u=l.$$observers||(l.$$observers=ve());if(C.test(i))throw Vi("nodomevents","Interpolations for HTML DOM event attributes are disallowed. Please use the ng- versions (such as ng-click instead of onclick) instead.");var c=l[i];c!==n&&(s=c&&r(c,!0,o,a),n=c),s&&(l[i]=s(e),(u[i]||(u[i]=[])).$$inter=!0,(l.$$observers&&l.$$observers[i].$$scope||e).$watch(s,function(e,t){"class"===i&&e!=t?l.$updateClass(e,t):l.$set(i,e)}))}}}})}}function le(e,n,r){var i,a,o=n[0],s=n.length,l=o.parentNode;if(e)for(i=0,a=e.length;a>i;i++)if(e[i]==o){e[i++]=r;for(var u=i,c=u+s-1,f=e.length;f>u;u++,c++)f>c?e[u]=e[c]:delete e[u];e.length-=s-1,e.context===o&&(e.context=r);break}l&&l.replaceChild(r,o);var d=t.createDocumentFragment();for(i=0;s>i;i++)d.appendChild(n[i]);for(Pr.hasData(o)&&(Pr.data(r,Pr.data(o)),Pr(o).off("$destroy")),Pr.cleanData(d.querySelectorAll("*")),i=1;s>i;i++)delete n[i];n[0]=r,n.length=1}function ue(e,t){return f(function(){return e.apply(null,arguments)},e,t)}function fe(e,t,n,r,a,o){try{e(t,n,r,a,o)}catch(s){i(s,Q(n))}}function pe(e,t,n,i,o){var s=[];return a(i,function(i,a){var u,c,f,d,p,h=i.attrName,g=i.optional,v=i.mode;switch(v){case"@":g||Er.call(t,h)||(n[a]=t[h]=void 0),t.$observe(h,function(e){k(e)&&(n[a]=e)}),t.$$observers[h].$$scope=e,u=t[h],k(u)?n[a]=r(u)(e):j(u)&&(n[a]=u);break;case"=":if(!Er.call(t,h)){if(g)break;t[h]=void 0}if(g&&!t[h])break;c=l(t[h]),d=c.literal?V:function(e,t){return e===t||e!==e&&t!==t},f=c.assign||function(){throw u=n[a]=c(e),Vi("nonassign","Expression '{0}' in attribute '{1}' used with directive '{2}' is non-assignable!",t[h],h,o.name)},u=n[a]=c(e);var b=function(t){return d(t,n[a])||(d(t,u)?f(e,t=n[a]):n[a]=t),u=t};b.$stateful=!0,p=i.collection?e.$watchCollection(t[h],b):e.$watch(l(t[h],b),null,c.literal),s.push(p);break;case"<":if(!Er.call(t,h)){if(g)break;t[h]=void 0}if(g&&!t[h])break;c=l(t[h]),n[a]=c(e),p=e.$watch(c,function(e){n[a]=e},c.literal),s.push(p);break;case"&":if(c=t.hasOwnProperty(h)?l(t[h]):m,c===m&&g)break;n[a]=function(t){return c(e,t)}}}),s.length&&function(){for(var e=0,t=s.length;t>e;++e)s[e]()}}var he=/^\w/,me=t.createElement("div");A.prototype={$normalize:mt,$addClass:function(e){e&&e.length>0&&D.addClass(this.$$element,e)},$removeClass:function(e){e&&e.length>0&&D.removeClass(this.$$element,e)},$updateClass:function(e,t){var n=gt(e,t);n&&n.length&&D.addClass(this.$$element,n);var r=gt(t,e);r&&r.length&&D.removeClass(this.$$element,r)},$set:function(e,t,n,r){var o,s=this.$$element[0],l=Ye(s,e),u=Ge(e),c=e;if(l?(this.$$element.prop(e,t),r=l):u&&(this[u]=t,c=u),this[e]=t,r?this.$attr[e]=r:(r=this.$attr[e],r||(this.$attr[e]=r=ce(e,"-"))),o=_(this.$$element),"a"===o&&("href"===e||"xlinkHref"===e)||"img"===o&&"src"===e)this[e]=t=O(t,"src"===e);else if("img"===o&&"srcset"===e){for(var f="",d=Gr(t),p=/(\s+\d+x\s*,|\s+\d+w\s*,|\s+,|,\s+)/,h=/\s/.test(d)?p:/(,)/,m=d.split(h),g=Math.floor(m.length/2),v=0;g>v;v++){var b=2*v;f+=O(Gr(m[b]),!0),f+=" "+Gr(m[b+1])}var $=Gr(m[2*v]).split(/\s/);f+=O(Gr($[0]),!0),2===$.length&&(f+=" "+Gr($[1])),this[e]=t=f}n!==!1&&(null===t||y(t)?this.$$element.removeAttr(r):he.test(r)?this.$$element.attr(r,t):N(this.$$element[0],r,t));var w=this.$$observers;w&&a(w[c],function(e){try{e(t)}catch(n){i(n)}})},$observe:function(e,t){var n=this,r=n.$$observers||(n.$$observers=ve()),i=r[e]||(r[e]=[]);return i.push(t),$.$evalAsync(function(){i.$$inter||!n.hasOwnProperty(e)||y(n[e])||t(n[e])}),function(){R(i,t)}}};var ge=r.startSymbol(),be=r.endSymbol(),ye="{{"==ge&&"}}"==be?g:function(e){return e.replace(/\{\{/g,ge).replace(/}}/g,be)},$e=/^ngAttr[A-Z]/,we=/^(.+)Start$/;return P.$$addBindingInfo=T?function(e,t){var n=e.data("$binding")||[];qr(t)?n=n.concat(t):n.push(t),e.data("$binding",n)}:m,P.$$addBindingClass=T?function(e){L(e,"ng-binding")}:m,P.$$addScopeInfo=T?function(e,t,n,r){var i=n?r?"$isolateScopeNoTemplate":"$isolateScope":"$scope";e.data(i,t)}:m,P.$$addScopeClass=T?function(e,t){L(e,t?"ng-isolate-scope":"ng-scope")}:m,P.$$createComment=function(e,n){var r="";return T&&(r=" "+(e||"")+": "+(n||"")+" "),t.createComment(r)},P}]}function mt(e){return ke(e.replace(Wi,""))}function gt(e,t){var n="",r=e.split(/\s+/),i=t.split(/\s+/);e:for(var a=0;a<r.length;a++){for(var o=r[a],s=0;s<i.length;s++)if(o==i[s])continue e;n+=(n.length>0?" ":"")+o}return n}function vt(e){e=Pr(e);var t=e.length;if(1>=t)return e;for(;t--;){var n=e[t];n.nodeType===ai&&_r.call(e,t,1)}return e}function bt(e,t){if(t&&k(t))return t;if(k(e)){var n=qi.exec(e);if(n)return n[3]}}function yt(){var e={},t=!1;this.has=function(t){return e.hasOwnProperty(t)},this.register=function(t,n){he(t,"controller"),w(t)?f(e,t):e[t]=n},this.allowGlobals=function(){t=!0},this.$get=["$injector","$window",function(i,a){function o(e,t,n,i){if(!e||!w(e.$scope))throw r("$controller")("noscp","Cannot export controller '{0}' as '{1}'! No $scope object provided via `locals`.",i,t);e.$scope[t]=n}return function(r,s,l,u){var c,d,p,h;if(l=l===!0,u&&k(u)&&(h=u),k(r)){if(d=r.match(qi),!d)throw Bi("ctrlfmt","Badly formed controller string '{0}'. Must match `__name__ as __id__` or `__name__`.",r);p=d[1],h=h||d[3],r=e.hasOwnProperty(p)?e[p]:me(s.$scope,p,!0)||(t?me(a,p,!0):n),pe(r,p,!0)}if(l){var m=(qr(r)?r[r.length-1]:r).prototype;c=Object.create(m||null),h&&o(s,h,c,p||r.name);var g;return g=f(function(){var e=i.invoke(r,c,s,p);return e!==c&&(w(e)||S(e))&&(c=e,h&&o(s,h,c,p||r.name)),c},{instance:c,identifier:h})}return c=i.instantiate(r,s,p),h&&o(s,h,c,p||r.name),c}}]}function $t(){this.$get=["$window",function(e){return Pr(e.document)}]}function wt(){this.$get=["$log",function(e){return function(t,n){e.error.apply(e,arguments)}}]}function xt(e){return w(e)?M(e)?e.toISOString():G(e):e}function kt(){this.$get=function(){return function(e){if(!e)return"";var t=[];return o(e,function(e,n){null===e||y(e)||(qr(e)?a(e,function(e){t.push(ie(n)+"="+ie(xt(e)))}):t.push(ie(n)+"="+ie(xt(e))))}),t.join("&")}}}function Ct(){this.$get=function(){return function(e){function t(e,r,i){null===e||y(e)||(qr(e)?a(e,function(e,n){t(e,r+"["+(w(e)?n:"")+"]")}):w(e)&&!M(e)?o(e,function(e,n){t(e,r+(i?"":"[")+n+(i?"":"]"))}):n.push(ie(r)+"="+ie(xt(e))))}if(!e)return"";var n=[];return t(e,"",!0),n.join("&")}}}function Mt(e,t){if(k(e)){var n=e.replace(Zi,"").trim();if(n){var r=t("Content-Type");(r&&0===r.indexOf(Gi)||St(n))&&(e=X(n))}}return e}function St(e){var t=e.match(Ki);return t&&Ji[t[0]].test(e)}function Tt(e){function t(e,t){e&&(r[e]=r[e]?r[e]+", "+t:t)}var n,r=ve();return k(e)?a(e.split("\n"),function(e){n=e.indexOf(":"),t(Or(Gr(e.substr(0,n))),Gr(e.substr(n+1)))}):w(e)&&a(e,function(e,n){t(Or(n),Gr(e))}),r}function Dt(e){var t;return function(n){if(t||(t=Tt(e)),n){var r=t[Or(n)];return void 0===r&&(r=null),r}return t}}function Et(e,t,n,r){return S(r)?r(e,t,n):(a(r,function(r){e=r(e,t,n)}),e)}function Ot(e){return e>=200&&300>e}function At(){var e=this.defaults={transformResponse:[Mt],transformRequest:[function(e){return!w(e)||O(e)||N(e)||A(e)?e:G(e)}],headers:{common:{Accept:"application/json, text/plain, */*"},post:U(Xi),put:U(Xi),patch:U(Xi)},xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",paramSerializer:"$httpParamSerializer"},t=!1;this.useApplyAsync=function(e){return $(e)?(t=!!e,this):t};var i=!0;this.useLegacyPromiseExtensions=function(e){return $(e)?(i=!!e,this):i};var o=this.interceptors=[];this.$get=["$httpBackend","$$cookieReader","$cacheFactory","$rootScope","$q","$injector",function(s,l,u,c,d,p){function h(t){function o(e){var t=f({},e);return t.data=Et(e.data,e.headers,e.status,u.transformResponse),Ot(e.status)?t:d.reject(t)}function s(e,t){var n,r={};return a(e,function(e,i){S(e)?(n=e(t),null!=n&&(r[i]=n)):r[i]=e}),r}function l(t){var n,r,i,a=e.headers,o=f({},t.headers);a=f({},a.common,a[Or(t.method)]);e:for(n in a){r=Or(n);for(i in o)if(Or(i)===r)continue e;o[n]=a[n]}return s(o,U(t))}if(!w(t))throw r("$http")("badreq","Http request configuration must be an object. Received: {0}",t);if(!k(t.url))throw r("$http")("badreq","Http request configuration url must be a string. Received: {0}",t.url);var u=f({method:"get",transformRequest:e.transformRequest,transformResponse:e.transformResponse,paramSerializer:e.paramSerializer},t);u.headers=l(t),u.method=Ar(u.method),u.paramSerializer=k(u.paramSerializer)?p.get(u.paramSerializer):u.paramSerializer;var c=function(t){var r=t.headers,i=Et(t.data,Dt(r),n,t.transformRequest);return y(i)&&a(r,function(e,t){"content-type"===Or(t)&&delete r[t]}),y(t.withCredentials)&&!y(e.withCredentials)&&(t.withCredentials=e.withCredentials),v(t,i).then(o,o)},h=[c,n],m=d.when(u);for(a(C,function(e){(e.request||e.requestError)&&h.unshift(e.request,e.requestError),(e.response||e.responseError)&&h.push(e.response,e.responseError)});h.length;){var g=h.shift(),b=h.shift();m=m.then(g,b)}return i?(m.success=function(e){return pe(e,"fn"),m.then(function(t){e(t.data,t.status,t.headers,u)}),m},m.error=function(e){return pe(e,"fn"),m.then(null,function(t){e(t.data,t.status,t.headers,u)}),m}):(m.success=ea("success"),m.error=ea("error")),m}function m(e){a(arguments,function(e){h[e]=function(t,n){return h(f({},n||{},{method:e,url:t}))}})}function g(e){a(arguments,function(e){h[e]=function(t,n,r){return h(f({},r||{},{method:e,url:t,data:n}))}})}function v(r,i){function a(e,n,r,i){function a(){o(n,e,r,i)}p&&(Ot(e)?p.put(C,[e,n,Tt(r),i]):p.remove(C)),t?c.$applyAsync(a):(a(),c.$$phase||c.$apply())}function o(e,t,n,i){t=t>=-1?t:0,(Ot(t)?g.resolve:g.reject)({data:e,status:t,headers:Dt(n),config:r,statusText:i})}function u(e){o(e.data,e.status,U(e.headers()),e.statusText)}function f(){var e=h.pendingRequests.indexOf(r);-1!==e&&h.pendingRequests.splice(e,1)}var p,m,g=d.defer(),v=g.promise,k=r.headers,C=b(r.url,r.paramSerializer(r.params));if(h.pendingRequests.push(r),v.then(f,f),!r.cache&&!e.cache||r.cache===!1||"GET"!==r.method&&"JSONP"!==r.method||(p=w(r.cache)?r.cache:w(e.cache)?e.cache:x),p&&(m=p.get(C),$(m)?L(m)?m.then(u,u):qr(m)?o(m[1],m[0],U(m[2]),m[3]):o(m,200,{},"OK"):p.put(C,v)),y(m)){var M=jn(r.url)?l()[r.xsrfCookieName||e.xsrfCookieName]:n;M&&(k[r.xsrfHeaderName||e.xsrfHeaderName]=M),s(r.method,C,i,a,k,r.timeout,r.withCredentials,r.responseType)}return v}function b(e,t){return t.length>0&&(e+=(-1==e.indexOf("?")?"?":"&")+t),e}var x=u("$http");e.paramSerializer=k(e.paramSerializer)?p.get(e.paramSerializer):e.paramSerializer;var C=[];return a(o,function(e){C.unshift(k(e)?p.get(e):p.invoke(e))}),h.pendingRequests=[],m("get","delete","head","jsonp"),g("post","put","patch"),h.defaults=e,h}]}function Nt(){this.$get=function(){return function(){return new e.XMLHttpRequest}}}function jt(){this.$get=["$browser","$window","$document","$xhrFactory",function(e,t,n,r){return Lt(e,r,e.defer,t.angular.callbacks,n[0])}]}function Lt(e,t,n,r,i){function o(e,t,n){var a=i.createElement("script"),o=null;return a.type="text/javascript",a.src=e,a.async=!0,o=function(e){di(a,"load",o),di(a,"error",o),i.body.removeChild(a),a=null;var s=-1,l="unknown";e&&("load"!==e.type||r[t].called||(e={type:"error"}),l=e.type,s="error"===e.type?404:200),n&&n(s,l)},fi(a,"load",o),fi(a,"error",o),i.body.appendChild(a),o}return function(i,s,l,u,c,f,d,p){function h(){b&&b(),w&&w.abort()}function g(t,r,i,a,o){$(C)&&n.cancel(C),b=w=null,t(r,i,a,o),e.$$completeOutstandingRequest(m)}if(e.$$incOutstandingRequestCount(),s=s||e.url(),"jsonp"==Or(i)){var v="_"+(r.counter++).toString(36);r[v]=function(e){r[v].data=e,r[v].called=!0};var b=o(s.replace("JSON_CALLBACK","angular.callbacks."+v),v,function(e,t){g(u,e,r[v].data,"",t),r[v]=m})}else{var w=t(i,s);w.open(i,s,!0),a(c,function(e,t){$(e)&&w.setRequestHeader(t,e)}),w.onload=function(){var e=w.statusText||"",t="response"in w?w.response:w.responseText,n=1223===w.status?204:w.status;0===n&&(n=t?200:"file"==Nn(s).protocol?404:0),g(u,n,t,w.getAllResponseHeaders(),e)};var x=function(){g(u,-1,null,null,"")};if(w.onerror=x,w.onabort=x,d&&(w.withCredentials=!0),p)try{w.responseType=p}catch(k){if("json"!==p)throw k}w.send(y(l)?null:l)}if(f>0)var C=n(h,f);else L(f)&&f.then(h)}}function Pt(){var e="{{",t="}}";this.startSymbol=function(t){return t?(e=t,this):e},this.endSymbol=function(e){return e?(t=e,this):t},this.$get=["$parse","$exceptionHandler","$sce",function(n,r,i){function a(e){return"\\\\\\"+e}function o(n){return n.replace(p,e).replace(h,t)}function s(e){if(null==e)return"";switch(typeof e){case"string":break;case"number":e=""+e;break;default:e=G(e)}return e}function l(e,t,n,r){var i;return i=e.$watch(function(e){return i(),r(e)},t,n)}function u(a,u,p,h){function m(e){try{return e=N(e),h&&!$(e)?e:s(e)}catch(t){r(ta.interr(a,t))}}if(!a.length||-1===a.indexOf(e)){var g;if(!u){var b=o(a);g=v(b),g.exp=a,g.expressions=[],g.$$watchDelegate=l}return g}h=!!h;for(var w,x,k,C=0,M=[],T=[],D=a.length,E=[],O=[];D>C;){if(-1==(w=a.indexOf(e,C))||-1==(x=a.indexOf(t,w+c))){C!==D&&E.push(o(a.substring(C)));break}C!==w&&E.push(o(a.substring(C,w))),k=a.substring(w+c,x),M.push(k),T.push(n(k,m)),C=x+d,O.push(E.length),E.push("")}if(p&&E.length>1&&ta.throwNoconcat(a),!u||M.length){var A=function(e){for(var t=0,n=M.length;n>t;t++){if(h&&y(e[t]))return;E[O[t]]=e[t]}return E.join("")},N=function(e){return p?i.getTrusted(p,e):i.valueOf(e)};return f(function(e){var t=0,n=M.length,i=new Array(n);try{for(;n>t;t++)i[t]=T[t](e);return A(i)}catch(o){r(ta.interr(a,o))}},{exp:a,expressions:M,$$watchDelegate:function(e,t){var n;return e.$watchGroup(T,function(r,i){var a=A(r);S(t)&&t.call(this,a,r!==i?n:a,e),n=a})}})}}var c=e.length,d=t.length,p=new RegExp(e.replace(/./g,a),"g"),h=new RegExp(t.replace(/./g,a),"g");return u.startSymbol=function(){return e},u.endSymbol=function(){return t},u}]}function It(){this.$get=["$rootScope","$window","$q","$$q","$browser",function(e,t,n,r,i){function a(a,s,l,u){function c(){f?a.apply(null,d):a(m)}var f=arguments.length>4,d=f?B(arguments,4):[],p=t.setInterval,h=t.clearInterval,m=0,g=$(u)&&!u,v=(g?r:n).defer(),b=v.promise;return l=$(l)?l:0,b.$$intervalId=p(function(){g?i.defer(c):e.$evalAsync(c),v.notify(m++),l>0&&m>=l&&(v.resolve(m),h(b.$$intervalId),delete o[b.$$intervalId]),g||e.$apply()},s),o[b.$$intervalId]=v,b}var o={};return a.cancel=function(e){return e&&e.$$intervalId in o?(o[e.$$intervalId].reject("canceled"),t.clearInterval(e.$$intervalId),delete o[e.$$intervalId],!0):!1},a}]}function Ft(e){for(var t=e.split("/"),n=t.length;n--;)t[n]=re(t[n]);return t.join("/")}function zt(e,t){var n=Nn(e);t.$$protocol=n.protocol,t.$$host=n.hostname,t.$$port=p(n.port)||ra[n.protocol]||null}function _t(e,t){var n="/"!==e.charAt(0);n&&(e="/"+e);var r=Nn(e);t.$$path=decodeURIComponent(n&&"/"===r.pathname.charAt(0)?r.pathname.substring(1):r.pathname),t.$$search=te(r.search),t.$$hash=decodeURIComponent(r.hash),t.$$path&&"/"!=t.$$path.charAt(0)&&(t.$$path="/"+t.$$path)}function Rt(e,t){return 0===t.indexOf(e)?t.substr(e.length):void 0}function Ht(e){var t=e.indexOf("#");return-1==t?e:e.substr(0,t)}function Ut(e){return e.replace(/(#.+)|#$/,"$1")}function Vt(e){return e.substr(0,Ht(e).lastIndexOf("/")+1)}function Wt(e){return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function Bt(e,t,n){this.$$html5=!0,n=n||"",zt(e,this),this.$$parse=function(e){var n=Rt(t,e);if(!k(n))throw ia("ipthprfx",'Invalid url "{0}", missing path prefix "{1}".',e,t);_t(n,this),this.$$path||(this.$$path="/"),this.$$compose()},this.$$compose=function(){var e=ne(this.$$search),n=this.$$hash?"#"+re(this.$$hash):"";this.$$url=Ft(this.$$path)+(e?"?"+e:"")+n,this.$$absUrl=t+this.$$url.substr(1)},this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var a,o,s;return $(a=Rt(e,r))?(o=a,s=$(a=Rt(n,a))?t+(Rt("/",a)||a):e+o):$(a=Rt(t,r))?s=t+a:t==r+"/"&&(s=t),s&&this.$$parse(s),!!s}}function qt(e,t,n){zt(e,this),this.$$parse=function(r){function i(e,t,n){var r,i=/^\/[A-Z]:(\/.*)/;return 0===t.indexOf(n)&&(t=t.replace(n,"")),i.exec(t)?e:(r=i.exec(e),r?r[1]:e)}var a,o=Rt(e,r)||Rt(t,r);y(o)||"#"!==o.charAt(0)?this.$$html5?a=o:(a="",y(o)&&(e=r,this.replace())):(a=Rt(n,o),y(a)&&(a=o)),_t(a,this),this.$$path=i(this.$$path,a,e),this.$$compose()},this.$$compose=function(){var t=ne(this.$$search),r=this.$$hash?"#"+re(this.$$hash):"";this.$$url=Ft(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+(this.$$url?n+this.$$url:"")},this.$$parseLinkUrl=function(t,n){return Ht(e)==Ht(t)?(this.$$parse(t),!0):!1}}function Yt(e,t,n){this.$$html5=!0,qt.apply(this,arguments),this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var a,o;return e==Ht(r)?a=r:(o=Rt(t,r))?a=e+n+o:t===r+"/"&&(a=t),a&&this.$$parse(a),!!a},this.$$compose=function(){var t=ne(this.$$search),r=this.$$hash?"#"+re(this.$$hash):"";this.$$url=Ft(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+n+this.$$url}}function Gt(e){return function(){return this[e]}}function Xt(e,t){return function(n){return y(n)?this[e]:(this[e]=t(n),this.$$compose(),this)}}function Kt(){var e="",t={enabled:!1,requireBase:!0,rewriteLinks:!0};this.hashPrefix=function(t){return $(t)?(e=t,this):e},this.html5Mode=function(e){return j(e)?(t.enabled=e,this):w(e)?(j(e.enabled)&&(t.enabled=e.enabled),j(e.requireBase)&&(t.requireBase=e.requireBase),j(e.rewriteLinks)&&(t.rewriteLinks=e.rewriteLinks),this):t},this.$get=["$rootScope","$browser","$sniffer","$rootElement","$window",function(n,r,i,a,o){function s(e,t,n){var i=u.url(),a=u.$$state;try{r.url(e,t,n),u.$$state=r.state()}catch(o){throw u.url(i),u.$$state=a,o}}function l(e,t){n.$broadcast("$locationChangeSuccess",u.absUrl(),e,u.$$state,t)}var u,c,f,d=r.baseHref(),p=r.url();if(t.enabled){if(!d&&t.requireBase)throw ia("nobase","$location in HTML5 mode requires a <base> tag to be present!");f=Wt(p)+(d||"/"),c=i.history?Bt:Yt}else f=Ht(p),c=qt;var h=Vt(f);u=new c(f,h,"#"+e),u.$$parseLinkUrl(p,p),u.$$state=r.state();var m=/^\s*(javascript|mailto):/i;a.on("click",function(e){if(t.rewriteLinks&&!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&2!=e.which&&2!=e.button){for(var i=Pr(e.target);"a"!==_(i[0]);)if(i[0]===a[0]||!(i=i.parent())[0])return;var s=i.prop("href"),l=i.attr("href")||i.attr("xlink:href");w(s)&&"[object SVGAnimatedString]"===s.toString()&&(s=Nn(s.animVal).href),m.test(s)||!s||i.attr("target")||e.isDefaultPrevented()||u.$$parseLinkUrl(s,l)&&(e.preventDefault(),u.absUrl()!=r.url()&&(n.$apply(),o.angular["ff-684208-preventDefault"]=!0))}}),Ut(u.absUrl())!=Ut(p)&&r.url(u.absUrl(),!0);var g=!0;return r.onUrlChange(function(e,t){return y(Rt(h,e))?void(o.location.href=e):(n.$evalAsync(function(){var r,i=u.absUrl(),a=u.$$state;e=Ut(e),u.$$parse(e),u.$$state=t,r=n.$broadcast("$locationChangeStart",e,i,t,a).defaultPrevented,u.absUrl()===e&&(r?(u.$$parse(i),u.$$state=a,s(i,!1,a)):(g=!1,l(i,a)))}),void(n.$$phase||n.$digest()))}),n.$watch(function(){var e=Ut(r.url()),t=Ut(u.absUrl()),a=r.state(),o=u.$$replace,c=e!==t||u.$$html5&&i.history&&a!==u.$$state;(g||c)&&(g=!1,n.$evalAsync(function(){var t=u.absUrl(),r=n.$broadcast("$locationChangeStart",t,e,u.$$state,a).defaultPrevented;u.absUrl()===t&&(r?(u.$$parse(e),u.$$state=a):(c&&s(t,o,a===u.$$state?null:u.$$state),l(e,a)))})),u.$$replace=!1}),u}]}function Jt(){var e=!0,t=this;this.debugEnabled=function(t){return $(t)?(e=t,this):e},this.$get=["$window",function(n){function r(e){return e instanceof Error&&(e.stack?e=e.message&&-1===e.stack.indexOf(e.message)?"Error: "+e.message+"\n"+e.stack:e.stack:e.sourceURL&&(e=e.message+"\n"+e.sourceURL+":"+e.line)),e}function i(e){var t=n.console||{},i=t[e]||t.log||m,o=!1;try{o=!!i.apply}catch(s){}return o?function(){var e=[];return a(arguments,function(t){e.push(r(t))}),i.apply(t,e)}:function(e,t){i(e,null==t?"":t)}}return{log:i("log"),info:i("info"),warn:i("warn"),error:i("error"),debug:function(){var n=i("debug");return function(){e&&n.apply(t,arguments)}}()}}]}function Zt(e,t){if("__defineGetter__"===e||"__defineSetter__"===e||"__lookupGetter__"===e||"__lookupSetter__"===e||"__proto__"===e)throw oa("isecfld","Attempting to access a disallowed field in Angular expressions! Expression: {0}",t);return e}function Qt(e){return e+""}function en(e,t){if(e){if(e.constructor===e)throw oa("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e.window===e)throw oa("isecwindow","Referencing the Window in Angular expressions is disallowed! Expression: {0}",t);if(e.children&&(e.nodeName||e.prop&&e.attr&&e.find))throw oa("isecdom","Referencing DOM nodes in Angular expressions is disallowed! Expression: {0}",t);if(e===Object)throw oa("isecobj","Referencing Object in Angular expressions is disallowed! Expression: {0}",t)}return e}function tn(e,t){if(e){if(e.constructor===e)throw oa("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e===sa||e===la||e===ua)throw oa("isecff","Referencing call, apply or bind in Angular expressions is disallowed! Expression: {0}",t)}}function nn(e,t){if(e&&(e===0..constructor||e===(!1).constructor||e==="".constructor||e==={}.constructor||e===[].constructor||e===Function.constructor))throw oa("isecaf","Assigning to a constructor is disallowed! Expression: {0}",t)}function rn(e,t){return"undefined"!=typeof e?e:t}function an(e,t){return"undefined"==typeof e?t:"undefined"==typeof t?e:e+t}function on(e,t){var n=e(t);return!n.$stateful}function sn(e,t){var n,r;switch(e.type){case pa.Program:n=!0,a(e.body,function(e){sn(e.expression,t),n=n&&e.expression.constant}),e.constant=n;break;case pa.Literal:e.constant=!0,e.toWatch=[];break;case pa.UnaryExpression:sn(e.argument,t),e.constant=e.argument.constant,e.toWatch=e.argument.toWatch;break;case pa.BinaryExpression:sn(e.left,t),sn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.left.toWatch.concat(e.right.toWatch);break;case pa.LogicalExpression:sn(e.left,t),sn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.constant?[]:[e];break;case pa.ConditionalExpression:sn(e.test,t),sn(e.alternate,t),sn(e.consequent,t),e.constant=e.test.constant&&e.alternate.constant&&e.consequent.constant,e.toWatch=e.constant?[]:[e];break;case pa.Identifier:e.constant=!1,e.toWatch=[e];break;case pa.MemberExpression:sn(e.object,t),e.computed&&sn(e.property,t),e.constant=e.object.constant&&(!e.computed||e.property.constant),e.toWatch=[e];break;case pa.CallExpression:n=e.filter?on(t,e.callee.name):!1,r=[],a(e.arguments,function(e){sn(e,t),n=n&&e.constant,e.constant||r.push.apply(r,e.toWatch)}),e.constant=n,e.toWatch=e.filter&&on(t,e.callee.name)?r:[e];break;case pa.AssignmentExpression:sn(e.left,t),sn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=[e];break;case pa.ArrayExpression:n=!0,r=[],a(e.elements,function(e){sn(e,t),n=n&&e.constant,e.constant||r.push.apply(r,e.toWatch)}),e.constant=n,e.toWatch=r;break;case pa.ObjectExpression:n=!0,r=[],a(e.properties,function(e){sn(e.value,t),n=n&&e.value.constant,e.value.constant||r.push.apply(r,e.value.toWatch)}),e.constant=n,e.toWatch=r;break;case pa.ThisExpression:e.constant=!1,e.toWatch=[];break;case pa.LocalsExpression:e.constant=!1,e.toWatch=[]}}function ln(e){if(1==e.length){var t=e[0].expression,r=t.toWatch;return 1!==r.length?r:r[0]!==t?r:n}}function un(e){return e.type===pa.Identifier||e.type===pa.MemberExpression}function cn(e){return 1===e.body.length&&un(e.body[0].expression)?{type:pa.AssignmentExpression,left:e.body[0].expression,right:{type:pa.NGValueParameter},operator:"="}:void 0}function fn(e){return 0===e.body.length||1===e.body.length&&(e.body[0].expression.type===pa.Literal||e.body[0].expression.type===pa.ArrayExpression||e.body[0].expression.type===pa.ObjectExpression)}function dn(e){return e.constant}function pn(e,t){this.astBuilder=e,this.$filter=t}function hn(e,t){this.astBuilder=e,this.$filter=t}function mn(e){return"constructor"==e}function gn(e){return S(e.valueOf)?e.valueOf():ma.call(e)}function vn(){var e=ve(),t=ve(),r={"true":!0,"false":!1,"null":null,undefined:n};this.addLiteral=function(e,t){r[e]=t},this.$get=["$filter",function(i){function o(n,r,a){var o,l,h;switch(a=a||b,typeof n){case"string":n=n.trim(),h=n;var y=a?t:e;if(o=y[h],!o){":"===n.charAt(0)&&":"===n.charAt(1)&&(l=!0,n=n.substring(2));var $=a?v:g,w=new da($),x=new ha(w,i,$);o=x.parse(n),o.constant?o.$$watchDelegate=d:l?o.$$watchDelegate=o.literal?f:c:o.inputs&&(o.$$watchDelegate=u),a&&(o=s(o)),y[h]=o}return p(o,r);case"function":return p(n,r);default:return p(m,r)}}function s(e){function t(t,n,r,i){var a=b;b=!0;try{return e(t,n,r,i)}finally{b=a}}if(!e)return e;t.$$watchDelegate=e.$$watchDelegate,t.assign=s(e.assign),t.constant=e.constant,t.literal=e.literal;for(var n=0;e.inputs&&n<e.inputs.length;++n)e.inputs[n]=s(e.inputs[n]);return t.inputs=e.inputs,t}function l(e,t){return null==e||null==t?e===t:"object"==typeof e&&(e=gn(e),"object"==typeof e)?!1:e===t||e!==e&&t!==t}function u(e,t,r,i,a){var o,s=i.inputs;if(1===s.length){var u=l;return s=s[0],e.$watch(function(e){var t=s(e);return l(t,u)||(o=i(e,n,n,[t]),u=t&&gn(t)),o},t,r,a)}for(var c=[],f=[],d=0,p=s.length;p>d;d++)c[d]=l,f[d]=null;return e.$watch(function(e){for(var t=!1,r=0,a=s.length;a>r;r++){var u=s[r](e);(t||(t=!l(u,c[r])))&&(f[r]=u,c[r]=u&&gn(u))}return t&&(o=i(e,n,n,f)),o},t,r,a)}function c(e,t,n,r){var i,a;return i=e.$watch(function(e){return r(e)},function(e,n,r){a=e,S(t)&&t.apply(this,arguments),$(e)&&r.$$postDigest(function(){$(a)&&i()})},n)}function f(e,t,n,r){function i(e){var t=!0;return a(e,function(e){$(e)||(t=!1)}),t}var o,s;return o=e.$watch(function(e){return r(e)},function(e,n,r){s=e,S(t)&&t.call(this,e,n,r),i(e)&&r.$$postDigest(function(){i(s)&&o()})},n)}function d(e,t,n,r){var i;return i=e.$watch(function(e){return i(),r(e)},t,n)}function p(e,t){if(!t)return e;var n=e.$$watchDelegate,r=!1,i=n!==f&&n!==c,a=i?function(n,i,a,o){var s=r&&o?o[0]:e(n,i,a,o);return t(s,n,i)}:function(n,r,i,a){var o=e(n,r,i,a),s=t(o,n,r);return $(o)?s:o};return e.$$watchDelegate&&e.$$watchDelegate!==u?a.$$watchDelegate=e.$$watchDelegate:t.$stateful||(a.$$watchDelegate=u,r=!e.inputs,a.inputs=e.inputs?e.inputs:[e]),a}var h=Kr().noUnsafeEval,g={csp:h,expensiveChecks:!1,literals:H(r)},v={csp:h,expensiveChecks:!0,literals:H(r)},b=!1;return o.$$runningExpensiveChecks=function(){return b},o}]}function bn(){this.$get=["$rootScope","$exceptionHandler",function(e,t){return $n(function(t){e.$evalAsync(t)},t)}]}function yn(){this.$get=["$browser","$exceptionHandler",function(e,t){return $n(function(t){e.defer(t)},t)}]}function $n(e,t){function i(){this.$$state={status:0}}function o(e,t){return function(n){t.call(e,n)}}function s(e){var r,i,a;a=e.pending,e.processScheduled=!1,e.pending=n;for(var o=0,s=a.length;s>o;++o){i=a[o][0],r=a[o][e.status];try{S(r)?i.resolve(r(e.value)):1===e.status?i.resolve(e.value):i.reject(e.value)}catch(l){i.reject(l),t(l)}}}function l(t){!t.processScheduled&&t.pending&&(t.processScheduled=!0,e(function(){s(t)}))}function u(){this.promise=new i}function c(e){var t=new u,n=0,r=qr(e)?[]:{};return a(e,function(e,i){n++,v(e).then(function(e){r.hasOwnProperty(i)||(r[i]=e,--n||t.resolve(r))},function(e){r.hasOwnProperty(i)||t.reject(e)})}),0===n&&t.resolve(r),t.promise}var d=r("$q",TypeError),p=function(){var e=new u;return e.resolve=o(e,e.resolve),e.reject=o(e,e.reject),e.notify=o(e,e.notify),e};f(i.prototype,{then:function(e,t,n){if(y(e)&&y(t)&&y(n))return this;var r=new u;return this.$$state.pending=this.$$state.pending||[],this.$$state.pending.push([r,e,t,n]),this.$$state.status>0&&l(this.$$state),r.promise},"catch":function(e){return this.then(null,e)},"finally":function(e,t){return this.then(function(t){return g(t,!0,e)},function(t){return g(t,!1,e)},t)}}),f(u.prototype,{resolve:function(e){this.promise.$$state.status||(e===this.promise?this.$$reject(d("qcycle","Expected promise to be resolved with value other than itself '{0}'",e)):this.$$resolve(e))},$$resolve:function(e){function n(e){s||(s=!0,a.$$resolve(e))}function r(e){s||(s=!0,a.$$reject(e))}var i,a=this,s=!1;try{(w(e)||S(e))&&(i=e&&e.then),S(i)?(this.promise.$$state.status=-1,i.call(e,n,r,o(this,this.notify))):(this.promise.$$state.value=e,this.promise.$$state.status=1,l(this.promise.$$state))}catch(u){r(u),t(u)}},reject:function(e){this.promise.$$state.status||this.$$reject(e)},$$reject:function(e){this.promise.$$state.value=e,this.promise.$$state.status=2,l(this.promise.$$state)},notify:function(n){var r=this.promise.$$state.pending;this.promise.$$state.status<=0&&r&&r.length&&e(function(){for(var e,i,a=0,o=r.length;o>a;a++){i=r[a][0],e=r[a][3];try{i.notify(S(e)?e(n):n)}catch(s){t(s)}}})}});var h=function(e){var t=new u;return t.reject(e),t.promise},m=function(e,t){var n=new u;return t?n.resolve(e):n.reject(e),n.promise},g=function(e,t,n){var r=null;try{S(n)&&(r=n())}catch(i){return m(i,!1)}return L(r)?r.then(function(){return m(e,t)},function(e){return m(e,!1)}):m(e,t)},v=function(e,t,n,r){var i=new u;return i.resolve(e),i.promise.then(t,n,r)},b=v,$=function(e){function t(e){r.resolve(e)}function n(e){r.reject(e)}if(!S(e))throw d("norslvr","Expected resolverFn, got '{0}'",e);var r=new u;return e(t,n),r.promise};return $.prototype=i.prototype,$.defer=p,$.reject=h,$.when=v,$.resolve=b,$.all=c,$}function wn(){this.$get=["$window","$timeout",function(e,t){var n=e.requestAnimationFrame||e.webkitRequestAnimationFrame,r=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame,i=!!n,a=i?function(e){var t=n(e);return function(){r(t)}}:function(e){var n=t(e,16.66,!1);return function(){t.cancel(n)}};return a.supported=i,a}]}function xn(){function e(e){function t(){this.$$watchers=this.$$nextSibling=this.$$childHead=this.$$childTail=null,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$id=l(),this.$$ChildScope=null}return t.prototype=e,t}var t=10,n=r("$rootScope"),o=null,s=null;
this.digestTtl=function(e){return arguments.length&&(t=e),t},this.$get=["$exceptionHandler","$parse","$browser",function(r,u,c){function f(e){e.currentScope.$$destroyed=!0}function d(e){9===Lr&&(e.$$childHead&&d(e.$$childHead),e.$$nextSibling&&d(e.$$nextSibling)),e.$parent=e.$$nextSibling=e.$$prevSibling=e.$$childHead=e.$$childTail=e.$root=e.$$watchers=null}function p(){this.$id=l(),this.$$phase=this.$parent=this.$$watchers=this.$$nextSibling=this.$$prevSibling=this.$$childHead=this.$$childTail=null,this.$root=this,this.$$destroyed=!1,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$$isolateBindings=null}function h(e){if(C.$$phase)throw n("inprog","{0} already in progress",C.$$phase);C.$$phase=e}function g(){C.$$phase=null}function v(e,t){do e.$$watchersCount+=t;while(e=e.$parent)}function b(e,t,n){do e.$$listenerCount[n]-=t,0===e.$$listenerCount[n]&&delete e.$$listenerCount[n];while(e=e.$parent)}function $(){}function x(){for(;D.length;)try{D.shift()()}catch(e){r(e)}s=null}function k(){null===s&&(s=c.defer(function(){C.$apply(x)}))}p.prototype={constructor:p,$new:function(t,n){var r;return n=n||this,t?(r=new p,r.$root=this.$root):(this.$$ChildScope||(this.$$ChildScope=e(this)),r=new this.$$ChildScope),r.$parent=n,r.$$prevSibling=n.$$childTail,n.$$childHead?(n.$$childTail.$$nextSibling=r,n.$$childTail=r):n.$$childHead=n.$$childTail=r,(t||n!=this)&&r.$on("$destroy",f),r},$watch:function(e,t,n,r){var i=u(e);if(i.$$watchDelegate)return i.$$watchDelegate(this,t,n,i,e);var a=this,s=a.$$watchers,l={fn:t,last:$,get:i,exp:r||e,eq:!!n};return o=null,S(t)||(l.fn=m),s||(s=a.$$watchers=[]),s.unshift(l),v(this,1),function(){R(s,l)>=0&&v(a,-1),o=null}},$watchGroup:function(e,t){function n(){l=!1,u?(u=!1,t(i,i,s)):t(i,r,s)}var r=new Array(e.length),i=new Array(e.length),o=[],s=this,l=!1,u=!0;if(!e.length){var c=!0;return s.$evalAsync(function(){c&&t(i,i,s)}),function(){c=!1}}return 1===e.length?this.$watch(e[0],function(e,n,a){i[0]=e,r[0]=n,t(i,e===n?i:r,a)}):(a(e,function(e,t){var a=s.$watch(e,function(e,a){i[t]=e,r[t]=a,l||(l=!0,s.$evalAsync(n))});o.push(a)}),function(){for(;o.length;)o.shift()()})},$watchCollection:function(e,t){function n(e){a=e;var t,n,r,s,l;if(!y(a)){if(w(a))if(i(a)){o!==p&&(o=p,g=o.length=0,f++),t=a.length,g!==t&&(f++,o.length=g=t);for(var u=0;t>u;u++)l=o[u],s=a[u],r=l!==l&&s!==s,r||l===s||(f++,o[u]=s)}else{o!==h&&(o=h={},g=0,f++),t=0;for(n in a)Er.call(a,n)&&(t++,s=a[n],l=o[n],n in o?(r=l!==l&&s!==s,r||l===s||(f++,o[n]=s)):(g++,o[n]=s,f++));if(g>t){f++;for(n in o)Er.call(a,n)||(g--,delete o[n])}}else o!==a&&(o=a,f++);return f}}function r(){if(m?(m=!1,t(a,a,l)):t(a,s,l),c)if(w(a))if(i(a)){s=new Array(a.length);for(var e=0;e<a.length;e++)s[e]=a[e]}else{s={};for(var n in a)Er.call(a,n)&&(s[n]=a[n])}else s=a}n.$stateful=!0;var a,o,s,l=this,c=t.length>1,f=0,d=u(e,n),p=[],h={},m=!0,g=0;return this.$watch(d,r)},$digest:function(){var e,i,a,l,u,f,d,p,m,v,b,y,w=t,k=this,D=[];h("$digest"),c.$$checkUrlChange(),this===C&&null!==s&&(c.defer.cancel(s),x()),o=null;do{for(p=!1,v=k;M.length;){try{y=M.shift(),y.scope.$eval(y.expression,y.locals)}catch(E){r(E)}o=null}e:do{if(f=v.$$watchers)for(d=f.length;d--;)try{if(e=f[d])if(u=e.get,(i=u(v))===(a=e.last)||(e.eq?V(i,a):"number"==typeof i&&"number"==typeof a&&isNaN(i)&&isNaN(a))){if(e===o){p=!1;break e}}else p=!0,o=e,e.last=e.eq?H(i,null):i,l=e.fn,l(i,a===$?i:a,v),5>w&&(b=4-w,D[b]||(D[b]=[]),D[b].push({msg:S(e.exp)?"fn: "+(e.exp.name||e.exp.toString()):e.exp,newVal:i,oldVal:a}))}catch(E){r(E)}if(!(m=v.$$watchersCount&&v.$$childHead||v!==k&&v.$$nextSibling))for(;v!==k&&!(m=v.$$nextSibling);)v=v.$parent}while(v=m);if((p||M.length)&&!w--)throw g(),n("infdig","{0} $digest() iterations reached. Aborting!\nWatchers fired in the last 5 iterations: {1}",t,D)}while(p||M.length);for(g();T.length;)try{T.shift()()}catch(E){r(E)}},$destroy:function(){if(!this.$$destroyed){var e=this.$parent;this.$broadcast("$destroy"),this.$$destroyed=!0,this===C&&c.$$applicationDestroyed(),v(this,-this.$$watchersCount);for(var t in this.$$listenerCount)b(this,this.$$listenerCount[t],t);e&&e.$$childHead==this&&(e.$$childHead=this.$$nextSibling),e&&e.$$childTail==this&&(e.$$childTail=this.$$prevSibling),this.$$prevSibling&&(this.$$prevSibling.$$nextSibling=this.$$nextSibling),this.$$nextSibling&&(this.$$nextSibling.$$prevSibling=this.$$prevSibling),this.$destroy=this.$digest=this.$apply=this.$evalAsync=this.$applyAsync=m,this.$on=this.$watch=this.$watchGroup=function(){return m},this.$$listeners={},this.$$nextSibling=null,d(this)}},$eval:function(e,t){return u(e)(this,t)},$evalAsync:function(e,t){C.$$phase||M.length||c.defer(function(){M.length&&C.$digest()}),M.push({scope:this,expression:u(e),locals:t})},$$postDigest:function(e){T.push(e)},$apply:function(e){try{h("$apply");try{return this.$eval(e)}finally{g()}}catch(t){r(t)}finally{try{C.$digest()}catch(t){throw r(t),t}}},$applyAsync:function(e){function t(){n.$eval(e)}var n=this;e&&D.push(t),e=u(e),k()},$on:function(e,t){var n=this.$$listeners[e];n||(this.$$listeners[e]=n=[]),n.push(t);var r=this;do r.$$listenerCount[e]||(r.$$listenerCount[e]=0),r.$$listenerCount[e]++;while(r=r.$parent);var i=this;return function(){var r=n.indexOf(t);-1!==r&&(n[r]=null,b(i,1,e))}},$emit:function(e,t){var n,i,a,o=[],s=this,l=!1,u={name:e,targetScope:s,stopPropagation:function(){l=!0},preventDefault:function(){u.defaultPrevented=!0},defaultPrevented:!1},c=W([u],arguments,1);do{for(n=s.$$listeners[e]||o,u.currentScope=s,i=0,a=n.length;a>i;i++)if(n[i])try{n[i].apply(null,c)}catch(f){r(f)}else n.splice(i,1),i--,a--;if(l)return u.currentScope=null,u;s=s.$parent}while(s);return u.currentScope=null,u},$broadcast:function(e,t){var n=this,i=n,a=n,o={name:e,targetScope:n,preventDefault:function(){o.defaultPrevented=!0},defaultPrevented:!1};if(!n.$$listenerCount[e])return o;for(var s,l,u,c=W([o],arguments,1);i=a;){for(o.currentScope=i,s=i.$$listeners[e]||[],l=0,u=s.length;u>l;l++)if(s[l])try{s[l].apply(null,c)}catch(f){r(f)}else s.splice(l,1),l--,u--;if(!(a=i.$$listenerCount[e]&&i.$$childHead||i!==n&&i.$$nextSibling))for(;i!==n&&!(a=i.$$nextSibling);)i=i.$parent}return o.currentScope=null,o}};var C=new p,M=C.$$asyncQueue=[],T=C.$$postDigestQueue=[],D=C.$$applyAsyncQueue=[];return C}]}function kn(){var e=/^\s*(https?|ftp|mailto|tel|file):/,t=/^\s*((https?|ftp|file|blob):|data:image\/)/;this.aHrefSanitizationWhitelist=function(t){return $(t)?(e=t,this):e},this.imgSrcSanitizationWhitelist=function(e){return $(e)?(t=e,this):t},this.$get=function(){return function(n,r){var i,a=r?t:e;return i=Nn(n).href,""===i||i.match(a)?n:"unsafe:"+i}}}function Cn(e){if("self"===e)return e;if(k(e)){if(e.indexOf("***")>-1)throw ga("iwcard","Illegal sequence *** in string matcher. String: {0}",e);return e=Xr(e).replace("\\*\\*",".*").replace("\\*","[^:/.?&;]*"),new RegExp("^"+e+"$")}if(T(e))return new RegExp("^"+e.source+"$");throw ga("imatcher",'Matchers may only be "self", string patterns or RegExp objects')}function Mn(e){var t=[];return $(e)&&a(e,function(e){t.push(Cn(e))}),t}function Sn(){this.SCE_CONTEXTS=va;var e=["self"],t=[];this.resourceUrlWhitelist=function(t){return arguments.length&&(e=Mn(t)),e},this.resourceUrlBlacklist=function(e){return arguments.length&&(t=Mn(e)),t},this.$get=["$injector",function(n){function r(e,t){return"self"===e?jn(t):!!e.exec(t.href)}function i(n){var i,a,o=Nn(n.toString()),s=!1;for(i=0,a=e.length;a>i;i++)if(r(e[i],o)){s=!0;break}if(s)for(i=0,a=t.length;a>i;i++)if(r(t[i],o)){s=!1;break}return s}function a(e){var t=function(e){this.$$unwrapTrustedValue=function(){return e}};return e&&(t.prototype=new e),t.prototype.valueOf=function(){return this.$$unwrapTrustedValue()},t.prototype.toString=function(){return this.$$unwrapTrustedValue().toString()},t}function o(e,t){var n=f.hasOwnProperty(e)?f[e]:null;if(!n)throw ga("icontext","Attempted to trust a value in invalid context. Context: {0}; Value: {1}",e,t);if(null===t||y(t)||""===t)return t;if("string"!=typeof t)throw ga("itype","Attempted to trust a non-string value in a content requiring a string: Context: {0}",e);return new n(t)}function s(e){return e instanceof c?e.$$unwrapTrustedValue():e}function l(e,t){if(null===t||y(t)||""===t)return t;var n=f.hasOwnProperty(e)?f[e]:null;if(n&&t instanceof n)return t.$$unwrapTrustedValue();if(e===va.RESOURCE_URL){if(i(t))return t;throw ga("insecurl","Blocked loading resource from url not allowed by $sceDelegate policy. URL: {0}",t.toString())}if(e===va.HTML)return u(t);throw ga("unsafe","Attempting to use an unsafe value in a safe context.")}var u=function(e){throw ga("unsafe","Attempting to use an unsafe value in a safe context.")};n.has("$sanitize")&&(u=n.get("$sanitize"));var c=a(),f={};return f[va.HTML]=a(c),f[va.CSS]=a(c),f[va.URL]=a(c),f[va.JS]=a(c),f[va.RESOURCE_URL]=a(f[va.URL]),{trustAs:o,getTrusted:l,valueOf:s}}]}function Tn(){var e=!0;this.enabled=function(t){return arguments.length&&(e=!!t),e},this.$get=["$parse","$sceDelegate",function(t,n){if(e&&8>Lr)throw ga("iequirks","Strict Contextual Escaping does not support Internet Explorer version < 11 in quirks mode. You can fix this by adding the text <!doctype html> to the top of your HTML document. See http://docs.angularjs.org/api/ng.$sce for more information.");var r=U(va);r.isEnabled=function(){return e},r.trustAs=n.trustAs,r.getTrusted=n.getTrusted,r.valueOf=n.valueOf,e||(r.trustAs=r.getTrusted=function(e,t){return t},r.valueOf=g),r.parseAs=function(e,n){var i=t(n);return i.literal&&i.constant?i:t(n,function(t){return r.getTrusted(e,t)})};var i=r.parseAs,o=r.getTrusted,s=r.trustAs;return a(va,function(e,t){var n=Or(t);r[ke("parse_as_"+n)]=function(t){return i(e,t)},r[ke("get_trusted_"+n)]=function(t){return o(e,t)},r[ke("trust_as_"+n)]=function(t){return s(e,t)}}),r}]}function Dn(){this.$get=["$window","$document",function(e,t){var n,r,i={},a=p((/android (\d+)/.exec(Or((e.navigator||{}).userAgent))||[])[1]),o=/Boxee/i.test((e.navigator||{}).userAgent),s=t[0]||{},l=/^(Moz|webkit|ms)(?=[A-Z])/,u=s.body&&s.body.style,c=!1,f=!1;if(u){for(var d in u)if(r=l.exec(d)){n=r[0],n=n.substr(0,1).toUpperCase()+n.substr(1);break}n||(n="WebkitOpacity"in u&&"webkit"),c=!!("transition"in u||n+"Transition"in u),f=!!("animation"in u||n+"Animation"in u),!a||c&&f||(c=k(u.webkitTransition),f=k(u.webkitAnimation))}return{history:!(!e.history||!e.history.pushState||4>a||o),hasEvent:function(e){if("input"===e&&11>=Lr)return!1;if(y(i[e])){var t=s.createElement("div");i[e]="on"+e in t}return i[e]},csp:Kr(),vendorPrefix:n,transitions:c,animations:f,android:a}}]}function En(){var e;this.httpOptions=function(t){return t?(e=t,this):e},this.$get=["$templateCache","$http","$q","$sce",function(t,n,r,i){function a(o,s){function l(e){if(!s)throw ba("tpload","Failed to load template: {0} (HTTP status: {1} {2})",o,e.status,e.statusText);return r.reject(e)}a.totalPendingRequests++,k(o)&&t.get(o)||(o=i.getTrustedResourceUrl(o));var u=n.defaults&&n.defaults.transformResponse;return qr(u)?u=u.filter(function(e){return e!==Mt}):u===Mt&&(u=null),n.get(o,f({cache:t,transformResponse:u},e))["finally"](function(){a.totalPendingRequests--}).then(function(e){return t.put(o,e.data),e.data},l)}return a.totalPendingRequests=0,a}]}function On(){this.$get=["$rootScope","$browser","$location",function(e,t,n){var r={};return r.findBindings=function(e,t,n){var r=e.getElementsByClassName("ng-binding"),i=[];return a(r,function(e){var r=Wr.element(e).data("$binding");r&&a(r,function(r){if(n){var a=new RegExp("(^|\\s)"+Xr(t)+"(\\s|\\||$)");a.test(r)&&i.push(e)}else-1!=r.indexOf(t)&&i.push(e)})}),i},r.findModels=function(e,t,n){for(var r=["ng-","data-ng-","ng\\:"],i=0;i<r.length;++i){var a=n?"=":"*=",o="["+r[i]+"model"+a+'"'+t+'"]',s=e.querySelectorAll(o);if(s.length)return s}},r.getLocation=function(){return n.url()},r.setLocation=function(t){t!==n.url()&&(n.url(t),e.$digest())},r.whenStable=function(e){t.notifyWhenNoOutstandingRequests(e)},r}]}function An(){this.$get=["$rootScope","$browser","$q","$$q","$exceptionHandler",function(e,t,n,r,i){function a(a,s,l){S(a)||(l=s,s=a,a=m);var u,c=B(arguments,3),f=$(l)&&!l,d=(f?r:n).defer(),p=d.promise;return u=t.defer(function(){try{d.resolve(a.apply(null,c))}catch(t){d.reject(t),i(t)}finally{delete o[p.$$timeoutId]}f||e.$apply()},s),p.$$timeoutId=u,o[u]=d,p}var o={};return a.cancel=function(e){return e&&e.$$timeoutId in o?(o[e.$$timeoutId].reject("canceled"),delete o[e.$$timeoutId],t.defer.cancel(e.$$timeoutId)):!1},a}]}function Nn(e){var t=e;return Lr&&(ya.setAttribute("href",t),t=ya.href),ya.setAttribute("href",t),{href:ya.href,protocol:ya.protocol?ya.protocol.replace(/:$/,""):"",host:ya.host,search:ya.search?ya.search.replace(/^\?/,""):"",hash:ya.hash?ya.hash.replace(/^#/,""):"",hostname:ya.hostname,port:ya.port,pathname:"/"===ya.pathname.charAt(0)?ya.pathname:"/"+ya.pathname}}function jn(e){var t=k(e)?Nn(e):e;return t.protocol===$a.protocol&&t.host===$a.host}function Ln(){this.$get=v(e)}function Pn(e){function t(e){try{return decodeURIComponent(e)}catch(t){return e}}var n=e[0]||{},r={},i="";return function(){var e,a,o,s,l,u=n.cookie||"";if(u!==i)for(i=u,e=i.split("; "),r={},o=0;o<e.length;o++)a=e[o],s=a.indexOf("="),s>0&&(l=t(a.substring(0,s)),y(r[l])&&(r[l]=t(a.substring(s+1))));return r}}function In(){this.$get=Pn}function Fn(e){function t(r,i){if(w(r)){var o={};return a(r,function(e,n){o[n]=t(n,e)}),o}return e.factory(r+n,i)}var n="Filter";this.register=t,this.$get=["$injector",function(e){return function(t){return e.get(t+n)}}],t("currency",Un),t("date",rr),t("filter",zn),t("json",ir),t("limitTo",ar),t("lowercase",Ta),t("number",Vn),t("orderBy",or),t("uppercase",Da)}function zn(){return function(e,t,n){if(!i(e)){if(null==e)return e;throw r("filter")("notarray","Expected array but received: {0}",e)}var a,o,s=Hn(t);switch(s){case"function":a=t;break;case"boolean":case"null":case"number":case"string":o=!0;case"object":a=_n(t,n,o);break;default:return e}return Array.prototype.filter.call(e,a)}}function _n(e,t,n){var r,i=w(e)&&"$"in e;return t===!0?t=V:S(t)||(t=function(e,t){return y(e)?!1:null===e||null===t?e===t:w(t)||w(e)&&!b(e)?!1:(e=Or(""+e),t=Or(""+t),-1!==e.indexOf(t))}),r=function(r){return i&&!w(r)?Rn(r,e.$,t,!1):Rn(r,e,t,n)}}function Rn(e,t,n,r,i){var a=Hn(e),o=Hn(t);if("string"===o&&"!"===t.charAt(0))return!Rn(e,t.substring(1),n,r);if(qr(e))return e.some(function(e){return Rn(e,t,n,r)});switch(a){case"object":var s;if(r){for(s in e)if("$"!==s.charAt(0)&&Rn(e[s],t,n,!0))return!0;return i?!1:Rn(e,t,n,!1)}if("object"===o){for(s in t){var l=t[s];if(!S(l)&&!y(l)){var u="$"===s,c=u?e:e[s];if(!Rn(c,l,n,u,u))return!1}}return!0}return n(e,t);case"function":return!1;default:return n(e,t)}}function Hn(e){return null===e?"null":typeof e}function Un(e){var t=e.NUMBER_FORMATS;return function(e,n,r){return y(n)&&(n=t.CURRENCY_SYM),y(r)&&(r=t.PATTERNS[1].maxFrac),null==e?e:qn(e,t.PATTERNS[1],t.GROUP_SEP,t.DECIMAL_SEP,r).replace(/\u00A4/g,n)}}function Vn(e){var t=e.NUMBER_FORMATS;return function(e,n){return null==e?e:qn(e,t.PATTERNS[0],t.GROUP_SEP,t.DECIMAL_SEP,n)}}function Wn(e){var t,n,r,i,a,o=0;for((n=e.indexOf(xa))>-1&&(e=e.replace(xa,"")),(r=e.search(/e/i))>0?(0>n&&(n=r),n+=+e.slice(r+1),e=e.substring(0,r)):0>n&&(n=e.length),r=0;e.charAt(r)==ka;r++);if(r==(a=e.length))t=[0],n=1;else{for(a--;e.charAt(a)==ka;)a--;for(n-=r,t=[],i=0;a>=r;r++,i++)t[i]=+e.charAt(r)}return n>wa&&(t=t.splice(0,wa-1),o=n-1,n=1),{d:t,e:o,i:n}}function Bn(e,t,n,r){var i=e.d,a=i.length-e.i;t=y(t)?Math.min(Math.max(n,a),r):+t;var o=t+e.i,s=i[o];if(o>0){i.splice(Math.max(e.i,o));for(var l=o;l<i.length;l++)i[l]=0}else{a=Math.max(0,a),e.i=1,i.length=Math.max(1,o=t+1),i[0]=0;for(var u=1;o>u;u++)i[u]=0}if(s>=5)if(0>o-1){for(var c=0;c>o;c--)i.unshift(0),e.i++;i.unshift(1),e.i++}else i[o-1]++;for(;a<Math.max(0,t);a++)i.push(0);var f=i.reduceRight(function(e,t,n,r){return t+=e,r[n]=t%10,Math.floor(t/10)},0);f&&(i.unshift(f),e.i++)}function qn(e,t,n,r,i){if(!k(e)&&!C(e)||isNaN(e))return"";var a,o=!isFinite(e),s=!1,l=Math.abs(e)+"",u="";if(o)u="∞";else{a=Wn(l),Bn(a,i,t.minFrac,t.maxFrac);var c=a.d,f=a.i,d=a.e,p=[];for(s=c.reduce(function(e,t){return e&&!t},!0);0>f;)c.unshift(0),f++;f>0?p=c.splice(f):(p=c,c=[0]);var h=[];for(c.length>t.lgSize&&h.unshift(c.splice(-t.lgSize).join(""));c.length>t.gSize;)h.unshift(c.splice(-t.gSize).join(""));c.length&&h.unshift(c.join("")),u=h.join(n),p.length&&(u+=r+p.join("")),d&&(u+="e+"+d)}return 0>e&&!s?t.negPre+u+t.negSuf:t.posPre+u+t.posSuf}function Yn(e,t,n,r){var i="";for((0>e||r&&0>=e)&&(r?e=-e+1:(e=-e,i="-")),e=""+e;e.length<t;)e=ka+e;return n&&(e=e.substr(e.length-t)),i+e}function Gn(e,t,n,r,i){return n=n||0,function(a){var o=a["get"+e]();return(n>0||o>-n)&&(o+=n),0===o&&-12==n&&(o=12),Yn(o,t,r,i)}}function Xn(e,t,n){return function(r,i){var a=r["get"+e](),o=(n?"STANDALONE":"")+(t?"SHORT":""),s=Ar(o+e);return i[s][a]}}function Kn(e,t,n){var r=-1*n,i=r>=0?"+":"";return i+=Yn(Math[r>0?"floor":"ceil"](r/60),2)+Yn(Math.abs(r%60),2)}function Jn(e){var t=new Date(e,0,1).getDay();return new Date(e,0,(4>=t?5:12)-t)}function Zn(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate()+(4-e.getDay()))}function Qn(e){return function(t){var n=Jn(t.getFullYear()),r=Zn(t),i=+r-+n,a=1+Math.round(i/6048e5);return Yn(a,e)}}function er(e,t){return e.getHours()<12?t.AMPMS[0]:t.AMPMS[1]}function tr(e,t){return e.getFullYear()<=0?t.ERAS[0]:t.ERAS[1]}function nr(e,t){return e.getFullYear()<=0?t.ERANAMES[0]:t.ERANAMES[1]}function rr(e){function t(e){var t;if(t=e.match(n)){var r=new Date(0),i=0,a=0,o=t[8]?r.setUTCFullYear:r.setFullYear,s=t[8]?r.setUTCHours:r.setHours;t[9]&&(i=p(t[9]+t[10]),a=p(t[9]+t[11])),o.call(r,p(t[1]),p(t[2])-1,p(t[3]));var l=p(t[4]||0)-i,u=p(t[5]||0)-a,c=p(t[6]||0),f=Math.round(1e3*parseFloat("0."+(t[7]||0)));return s.call(r,l,u,c,f),r}return e}var n=/^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/;return function(n,r,i){var o,s,l="",u=[];if(r=r||"mediumDate",r=e.DATETIME_FORMATS[r]||r,k(n)&&(n=Sa.test(n)?p(n):t(n)),C(n)&&(n=new Date(n)),!M(n)||!isFinite(n.getTime()))return n;for(;r;)s=Ma.exec(r),s?(u=W(u,s,1),r=u.pop()):(u.push(r),r=null);var c=n.getTimezoneOffset();return i&&(c=K(i,c),n=Z(n,i,!0)),a(u,function(t){o=Ca[t],l+=o?o(n,e.DATETIME_FORMATS,c):"''"===t?"'":t.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),l}}function ir(){return function(e,t){return y(t)&&(t=2),G(e,t)}}function ar(){return function(e,t,n){return t=Math.abs(Number(t))===1/0?Number(t):p(t),isNaN(t)?e:(C(e)&&(e=e.toString()),qr(e)||k(e)?(n=!n||isNaN(n)?0:p(n),n=0>n?Math.max(0,e.length+n):n,t>=0?e.slice(n,n+t):0===n?e.slice(t,e.length):e.slice(Math.max(0,n+t),n)):e)}}function or(e){function t(t,n){return n=n?-1:1,t.map(function(t){var r=1,i=g;if(S(t))i=t;else if(k(t)&&("+"!=t.charAt(0)&&"-"!=t.charAt(0)||(r="-"==t.charAt(0)?-1:1,t=t.substring(1)),""!==t&&(i=e(t),i.constant))){var a=i();i=function(e){return e[a]}}return{get:i,descending:r*n}})}function n(e){switch(typeof e){case"number":case"boolean":case"string":return!0;default:return!1}}function a(e,t){return"function"==typeof e.valueOf&&(e=e.valueOf(),n(e))?e:b(e)&&(e=e.toString(),n(e))?e:t}function o(e,t){var n=typeof e;return null===e?(n="string",e="null"):"string"===n?e=e.toLowerCase():"object"===n&&(e=a(e,t)),{value:e,type:n}}function s(e,t){var n=0;return e.type===t.type?e.value!==t.value&&(n=e.value<t.value?-1:1):n=e.type<t.type?-1:1,n}return function(e,n,a){function l(e,t){return{value:e,predicateValues:c.map(function(n){return o(n.get(e),t)})}}function u(e,t){for(var n=0,r=0,i=c.length;i>r&&!(n=s(e.predicateValues[r],t.predicateValues[r])*c[r].descending);++r);return n}if(null==e)return e;if(!i(e))throw r("orderBy")("notarray","Expected array but received: {0}",e);qr(n)||(n=[n]),0===n.length&&(n=["+"]);var c=t(n,a);c.push({get:function(){return{}},descending:a?-1:1});var f=Array.prototype.map.call(e,l);return f.sort(u),e=f.map(function(e){return e.value})}}function sr(e){return S(e)&&(e={link:e}),e.restrict=e.restrict||"AC",v(e)}function lr(e,t){e.$name=t}function ur(e,t,r,i,o){var s=this,l=[];s.$error={},s.$$success={},s.$pending=n,s.$name=o(t.name||t.ngForm||"")(r),s.$dirty=!1,s.$pristine=!0,s.$valid=!0,s.$invalid=!1,s.$submitted=!1,s.$$parentForm=Aa,s.$rollbackViewValue=function(){a(l,function(e){e.$rollbackViewValue()})},s.$commitViewValue=function(){a(l,function(e){e.$commitViewValue()})},s.$addControl=function(e){he(e.$name,"input"),l.push(e),e.$name&&(s[e.$name]=e),e.$$parentForm=s},s.$$renameControl=function(e,t){var n=e.$name;s[n]===e&&delete s[n],s[t]=e,e.$name=t},s.$removeControl=function(e){e.$name&&s[e.$name]===e&&delete s[e.$name],a(s.$pending,function(t,n){s.$setValidity(n,null,e)}),a(s.$error,function(t,n){s.$setValidity(n,null,e)}),a(s.$$success,function(t,n){s.$setValidity(n,null,e)}),R(l,e),e.$$parentForm=Aa},Cr({ctrl:this,$element:e,set:function(e,t,n){var r=e[t];if(r){var i=r.indexOf(n);-1===i&&r.push(n)}else e[t]=[n]},unset:function(e,t,n){var r=e[t];r&&(R(r,n),0===r.length&&delete e[t])},$animate:i}),s.$setDirty=function(){i.removeClass(e,go),i.addClass(e,vo),s.$dirty=!0,s.$pristine=!1,s.$$parentForm.$setDirty()},s.$setPristine=function(){i.setClass(e,go,vo+" "+Na),s.$dirty=!1,s.$pristine=!0,s.$submitted=!1,a(l,function(e){e.$setPristine()})},s.$setUntouched=function(){a(l,function(e){e.$setUntouched()})},s.$setSubmitted=function(){i.addClass(e,Na),s.$submitted=!0,s.$$parentForm.$setSubmitted()}}function cr(e){e.$formatters.push(function(t){return e.$isEmpty(t)?t:t.toString()})}function fr(e,t,n,r,i,a){dr(e,t,n,r,i,a),cr(r)}function dr(e,t,n,r,i,a){var o=Or(t[0].type);if(!i.android){var s=!1;t.on("compositionstart",function(){s=!0}),t.on("compositionend",function(){s=!1,u()})}var l,u=function(e){if(l&&(a.defer.cancel(l),l=null),!s){var i=t.val(),u=e&&e.type;"password"===o||n.ngTrim&&"false"===n.ngTrim||(i=Gr(i)),(r.$viewValue!==i||""===i&&r.$$hasNativeValidators)&&r.$setViewValue(i,u)}};if(i.hasEvent("input"))t.on("input",u);else{var c=function(e,t,n){l||(l=a.defer(function(){l=null,t&&t.value===n||u(e)}))};t.on("keydown",function(e){var t=e.keyCode;91===t||t>15&&19>t||t>=37&&40>=t||c(e,this,this.value)}),i.hasEvent("paste")&&t.on("paste cut",c)}t.on("change",u),qa[o]&&r.$$hasNativeValidators&&o===n.type&&t.on(Ba,function(e){if(!l){var t=this[Dr],n=t.badInput,r=t.typeMismatch;l=a.defer(function(){l=null,t.badInput===n&&t.typeMismatch===r||u(e)})}}),r.$render=function(){var e=r.$isEmpty(r.$viewValue)?"":r.$viewValue;t.val()!==e&&t.val(e)}}function pr(e,t){if(M(e))return e;if(k(e)){Ua.lastIndex=0;var n=Ua.exec(e);if(n){var r=+n[1],i=+n[2],a=0,o=0,s=0,l=0,u=Jn(r),c=7*(i-1);return t&&(a=t.getHours(),o=t.getMinutes(),s=t.getSeconds(),l=t.getMilliseconds()),new Date(r,0,u.getDate()+c,a,o,s,l)}}return NaN}function hr(e,t){return function(n,r){var i,o;if(M(n))return n;if(k(n)){if('"'==n.charAt(0)&&'"'==n.charAt(n.length-1)&&(n=n.substring(1,n.length-1)),Ia.test(n))return new Date(n);if(e.lastIndex=0,i=e.exec(n))return i.shift(),o=r?{yyyy:r.getFullYear(),MM:r.getMonth()+1,dd:r.getDate(),HH:r.getHours(),mm:r.getMinutes(),ss:r.getSeconds(),sss:r.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},a(i,function(e,n){n<t.length&&(o[t[n]]=+e)}),new Date(o.yyyy,o.MM-1,o.dd,o.HH,o.mm,o.ss||0,1e3*o.sss||0)}return NaN}}function mr(e,t,r,i){return function(a,o,s,l,u,c,f){function d(e){return e&&!(e.getTime&&e.getTime()!==e.getTime())}function p(e){return $(e)&&!M(e)?r(e)||n:e}gr(a,o,s,l),dr(a,o,s,l,u,c);var h,m=l&&l.$options&&l.$options.timezone;if(l.$$parserName=e,l.$parsers.push(function(e){if(l.$isEmpty(e))return null;if(t.test(e)){var i=r(e,h);return m&&(i=Z(i,m)),i}return n}),l.$formatters.push(function(e){if(e&&!M(e))throw ko("datefmt","Expected `{0}` to be a date",e);return d(e)?(h=e,h&&m&&(h=Z(h,m,!0)),f("date")(e,i,m)):(h=null,"")}),$(s.min)||s.ngMin){var g;l.$validators.min=function(e){return!d(e)||y(g)||r(e)>=g},s.$observe("min",function(e){g=p(e),l.$validate()})}if($(s.max)||s.ngMax){var v;l.$validators.max=function(e){return!d(e)||y(v)||r(e)<=v},s.$observe("max",function(e){v=p(e),l.$validate()})}}}function gr(e,t,r,i){var a=t[0],o=i.$$hasNativeValidators=w(a.validity);o&&i.$parsers.push(function(e){var r=t.prop(Dr)||{};return r.badInput||r.typeMismatch?n:e})}function vr(e,t,r,i,a,o){if(gr(e,t,r,i),dr(e,t,r,i,a,o),i.$$parserName="number",i.$parsers.push(function(e){return i.$isEmpty(e)?null:_a.test(e)?parseFloat(e):n}),i.$formatters.push(function(e){if(!i.$isEmpty(e)){if(!C(e))throw ko("numfmt","Expected `{0}` to be a number",e);e=e.toString()}return e}),$(r.min)||r.ngMin){var s;i.$validators.min=function(e){return i.$isEmpty(e)||y(s)||e>=s},r.$observe("min",function(e){$(e)&&!C(e)&&(e=parseFloat(e,10)),s=C(e)&&!isNaN(e)?e:n,i.$validate()})}if($(r.max)||r.ngMax){var l;i.$validators.max=function(e){return i.$isEmpty(e)||y(l)||l>=e},r.$observe("max",function(e){$(e)&&!C(e)&&(e=parseFloat(e,10)),l=C(e)&&!isNaN(e)?e:n,i.$validate()})}}function br(e,t,n,r,i,a){dr(e,t,n,r,i,a),cr(r),r.$$parserName="url",r.$validators.url=function(e,t){var n=e||t;return r.$isEmpty(n)||Fa.test(n)}}function yr(e,t,n,r,i,a){dr(e,t,n,r,i,a),cr(r),r.$$parserName="email",r.$validators.email=function(e,t){var n=e||t;return r.$isEmpty(n)||za.test(n)}}function $r(e,t,n,r){y(n.name)&&t.attr("name",l());var i=function(e){t[0].checked&&r.$setViewValue(n.value,e&&e.type)};t.on("click",i),r.$render=function(){var e=n.value;t[0].checked=e==r.$viewValue},n.$observe("value",r.$render)}function wr(e,t,n,r,i){var a;if($(r)){if(a=e(r),!a.constant)throw ko("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",n,r);return a(t)}return i}function xr(e,t,n,r,i,a,o,s){var l=wr(s,e,"ngTrueValue",n.ngTrueValue,!0),u=wr(s,e,"ngFalseValue",n.ngFalseValue,!1),c=function(e){r.$setViewValue(t[0].checked,e&&e.type)};t.on("click",c),r.$render=function(){t[0].checked=r.$viewValue},r.$isEmpty=function(e){return e===!1},r.$formatters.push(function(e){return V(e,l)}),r.$parsers.push(function(e){return e?l:u})}function kr(e,t){return e="ngClass"+e,["$animate",function(n){function r(e,t){var n=[];e:for(var r=0;r<e.length;r++){for(var i=e[r],a=0;a<t.length;a++)if(i==t[a])continue e;n.push(i)}return n}function i(e){var t=[];return qr(e)?(a(e,function(e){t=t.concat(i(e))}),t):k(e)?e.split(" "):w(e)?(a(e,function(e,n){e&&(t=t.concat(n.split(" ")))}),t):e}return{restrict:"AC",link:function(o,s,l){function u(e){var t=f(e,1);l.$addClass(t)}function c(e){var t=f(e,-1);l.$removeClass(t)}function f(e,t){var n=s.data("$classCounts")||ve(),r=[];return a(e,function(e){(t>0||n[e])&&(n[e]=(n[e]||0)+t,n[e]===+(t>0)&&r.push(e))}),s.data("$classCounts",n),r.join(" ")}function d(e,t){var i=r(t,e),a=r(e,t);i=f(i,1),a=f(a,-1),i&&i.length&&n.addClass(s,i),a&&a.length&&n.removeClass(s,a)}function p(e){if(t===!0||o.$index%2===t){var n=i(e||[]);if(h){if(!V(e,h)){var r=i(h);d(r,n)}}else u(n)}h=U(e)}var h;o.$watch(l[e],p,!0),l.$observe("class",function(t){p(o.$eval(l[e]))}),"ngClass"!==e&&o.$watch("$index",function(n,r){var a=1&n;if(a!==(1&r)){var s=i(o.$eval(l[e]));a===t?u(s):c(s)}})}}}]}function Cr(e){function t(e,t,l){y(t)?r("$pending",e,l):i("$pending",e,l),j(t)?t?(f(s.$error,e,l),c(s.$$success,e,l)):(c(s.$error,e,l),f(s.$$success,e,l)):(f(s.$error,e,l),f(s.$$success,e,l)),s.$pending?(a($o,!0),s.$valid=s.$invalid=n,o("",null)):(a($o,!1),s.$valid=Mr(s.$error),s.$invalid=!s.$valid,o("",s.$valid));var u;u=s.$pending&&s.$pending[e]?n:s.$error[e]?!1:s.$$success[e]?!0:null,o(e,u),s.$$parentForm.$setValidity(e,u,s)}function r(e,t,n){s[e]||(s[e]={}),c(s[e],t,n)}function i(e,t,r){s[e]&&f(s[e],t,r),Mr(s[e])&&(s[e]=n)}function a(e,t){t&&!u[e]?(d.addClass(l,e),u[e]=!0):!t&&u[e]&&(d.removeClass(l,e),u[e]=!1)}function o(e,t){e=e?"-"+ce(e,"-"):"",a(ho+e,t===!0),a(mo+e,t===!1)}var s=e.ctrl,l=e.$element,u={},c=e.set,f=e.unset,d=e.$animate;u[mo]=!(u[ho]=l.hasClass(ho)),s.$setValidity=t}function Mr(e){if(e)for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}function Sr(e){e[0].hasAttribute("selected")&&(e[0].selected=!0)}var Tr=/^\/(.+)\/([a-z]*)$/,Dr="validity",Er=Object.prototype.hasOwnProperty,Or=function(e){return k(e)?e.toLowerCase():e},Ar=function(e){return k(e)?e.toUpperCase():e},Nr=function(e){return k(e)?e.replace(/[A-Z]/g,function(e){return String.fromCharCode(32|e.charCodeAt(0))}):e},jr=function(e){return k(e)?e.replace(/[a-z]/g,function(e){return String.fromCharCode(-33&e.charCodeAt(0))}):e};"i"!=="I".toLowerCase()&&(Or=Nr,Ar=jr);var Lr,Pr,Ir,Fr,zr=[].slice,_r=[].splice,Rr=[].push,Hr=Object.prototype.toString,Ur=Object.getPrototypeOf,Vr=r("ng"),Wr=e.angular||(e.angular={}),Br=0;Lr=t.documentMode,m.$inject=[],g.$inject=[];var qr=Array.isArray,Yr=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array\]$/,Gr=function(e){return k(e)?e.trim():e},Xr=function(e){return e.replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},Kr=function(){function e(){try{return new Function(""),!1}catch(e){return!0}}if(!$(Kr.rules)){var n=t.querySelector("[ng-csp]")||t.querySelector("[data-ng-csp]");if(n){var r=n.getAttribute("ng-csp")||n.getAttribute("data-ng-csp");Kr.rules={noUnsafeEval:!r||-1!==r.indexOf("no-unsafe-eval"),noInlineStyle:!r||-1!==r.indexOf("no-inline-style")}}else Kr.rules={noUnsafeEval:e(),noInlineStyle:!1}}return Kr.rules},Jr=function(){if($(Jr.name_))return Jr.name_;var e,n,r,i,a=Qr.length;for(n=0;a>n;++n)if(r=Qr[n],e=t.querySelector("["+r.replace(":","\\:")+"jq]")){i=e.getAttribute(r+"jq");break}return Jr.name_=i},Zr=/:/g,Qr=["ng-","data-ng-","ng:","x-ng-"],ei=/[A-Z]/g,ti=!1,ni=1,ri=2,ii=3,ai=8,oi=9,si=11,li={full:"1.5.2",major:1,minor:5,dot:2,codeName:"differential-recovery"};Ae.expando="ng339";var ui=Ae.cache={},ci=1,fi=function(e,t,n){e.addEventListener(t,n,!1)},di=function(e,t,n){e.removeEventListener(t,n,!1)};Ae._data=function(e){return this.cache[e[this.expando]]||{}};var pi=/([\:\-\_]+(.))/g,hi=/^moz([A-Z])/,mi={mouseleave:"mouseout",mouseenter:"mouseover"},gi=r("jqLite"),vi=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,bi=/<|&#?\w+;/,yi=/<([\w:-]+)/,$i=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,wi={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};wi.optgroup=wi.option,wi.tbody=wi.tfoot=wi.colgroup=wi.caption=wi.thead,wi.th=wi.td;var xi=Node.prototype.contains||function(e){return!!(16&this.compareDocumentPosition(e))},ki=Ae.prototype={ready:function(n){function r(){i||(i=!0,n())}var i=!1;"complete"===t.readyState?setTimeout(r):(this.on("DOMContentLoaded",r),Ae(e).on("load",r))},toString:function(){var e=[];return a(this,function(t){e.push(""+t)}),"["+e.join(", ")+"]"},eq:function(e){return Pr(e>=0?this[e]:this[this.length+e])},length:0,push:Rr,sort:[].sort,splice:[].splice},Ci={};a("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(e){Ci[Or(e)]=e});var Mi={};a("input,select,option,textarea,button,form,details".split(","),function(e){Mi[e]=!0});var Si={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern"};a({data:Fe,removeData:Pe,hasData:Se,cleanData:Te},function(e,t){Ae[t]=e}),a({data:Fe,inheritedData:Ve,scope:function(e){return Pr.data(e,"$scope")||Ve(e.parentNode||e,["$isolateScope","$scope"])},isolateScope:function(e){return Pr.data(e,"$isolateScope")||Pr.data(e,"$isolateScopeNoTemplate")},controller:Ue,injector:function(e){return Ve(e,"$injector")},removeAttr:function(e,t){e.removeAttribute(t)},hasClass:ze,css:function(e,t,n){return t=ke(t),$(n)?void(e.style[t]=n):e.style[t]},attr:function(e,t,r){var i=e.nodeType;if(i!==ii&&i!==ri&&i!==ai){var a=Or(t);if(Ci[a]){if(!$(r))return e[t]||(e.attributes.getNamedItem(t)||m).specified?a:n;r?(e[t]=!0,e.setAttribute(t,a)):(e[t]=!1,e.removeAttribute(a))}else if($(r))e.setAttribute(t,r);else if(e.getAttribute){var o=e.getAttribute(t,2);return null===o?n:o;
}}},prop:function(e,t,n){return $(n)?void(e[t]=n):e[t]},text:function(){function e(e,t){if(y(t)){var n=e.nodeType;return n===ni||n===ii?e.textContent:""}e.textContent=t}return e.$dv="",e}(),val:function(e,t){if(y(t)){if(e.multiple&&"select"===_(e)){var n=[];return a(e.options,function(e){e.selected&&n.push(e.value||e.text)}),0===n.length?null:n}return e.value}e.value=t},html:function(e,t){return y(t)?e.innerHTML:(je(e,!0),void(e.innerHTML=t))},empty:We},function(e,t){Ae.prototype[t]=function(t,n){var r,i,a=this.length;if(e!==We&&y(2==e.length&&e!==ze&&e!==Ue?t:n)){if(w(t)){for(r=0;a>r;r++)if(e===Fe)e(this[r],t);else for(i in t)e(this[r],i,t[i]);return this}for(var o=e.$dv,s=y(o)?Math.min(a,1):a,l=0;s>l;l++){var u=e(this[l],t,n);o=o?o+u:u}return o}for(r=0;a>r;r++)e(this[r],t,n);return this}}),a({removeData:Pe,on:function(e,t,r,i){if($(i))throw gi("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(Me(e)){var a=Ie(e,!0),o=a.events,s=a.handle;s||(s=a.handle=Xe(e,o));for(var l=t.indexOf(" ")>=0?t.split(" "):[t],u=l.length,c=function(t,n,i){var a=o[t];a||(a=o[t]=[],a.specialHandlerWrapper=n,"$destroy"===t||i||fi(e,t,s)),a.push(r)};u--;)t=l[u],mi[t]?(c(mi[t],Je),c(t,n,!0)):c(t)}},off:Le,one:function(e,t,n){e=Pr(e),e.on(t,function r(){e.off(t,n),e.off(t,r)}),e.on(t,n)},replaceWith:function(e,t){var n,r=e.parentNode;je(e),a(new Ae(t),function(t){n?r.insertBefore(t,n.nextSibling):r.replaceChild(t,e),n=t})},children:function(e){var t=[];return a(e.childNodes,function(e){e.nodeType===ni&&t.push(e)}),t},contents:function(e){return e.contentDocument||e.childNodes||[]},append:function(e,t){var n=e.nodeType;if(n===ni||n===si){t=new Ae(t);for(var r=0,i=t.length;i>r;r++){var a=t[r];e.appendChild(a)}}},prepend:function(e,t){if(e.nodeType===ni){var n=e.firstChild;a(new Ae(t),function(t){e.insertBefore(t,n)})}},wrap:function(e,t){Oe(e,Pr(t).eq(0).clone()[0])},remove:Be,detach:function(e){Be(e,!0)},after:function(e,t){var n=e,r=e.parentNode;t=new Ae(t);for(var i=0,a=t.length;a>i;i++){var o=t[i];r.insertBefore(o,n.nextSibling),n=o}},addClass:Re,removeClass:_e,toggleClass:function(e,t,n){t&&a(t.split(" "),function(t){var r=n;y(r)&&(r=!ze(e,t)),(r?Re:_e)(e,t)})},parent:function(e){var t=e.parentNode;return t&&t.nodeType!==si?t:null},next:function(e){return e.nextElementSibling},find:function(e,t){return e.getElementsByTagName?e.getElementsByTagName(t):[]},clone:Ne,triggerHandler:function(e,t,n){var r,i,o,s=t.type||t,l=Ie(e),u=l&&l.events,c=u&&u[s];c&&(r={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return this.defaultPrevented===!0},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return this.immediatePropagationStopped===!0},stopPropagation:m,type:s,target:e},t.type&&(r=f(r,t)),i=U(c),o=n?[r].concat(n):[r],a(i,function(t){r.isImmediatePropagationStopped()||t.apply(e,o)}))}},function(e,t){Ae.prototype[t]=function(t,n,r){for(var i,a=0,o=this.length;o>a;a++)y(i)?(i=e(this[a],t,n,r),$(i)&&(i=Pr(i))):He(i,e(this[a],t,n,r));return $(i)?i:this},Ae.prototype.bind=Ae.prototype.on,Ae.prototype.unbind=Ae.prototype.off}),et.prototype={put:function(e,t){this[Qe(e,this.nextUid)]=t},get:function(e){return this[Qe(e,this.nextUid)]},remove:function(e){var t=this[e=Qe(e,this.nextUid)];return delete this[e],t}};var Ti=[function(){this.$get=[function(){return et}]}],Di=/^([^\(]+?)=>/,Ei=/^[^\(]*\(\s*([^\)]*)\)/m,Oi=/,/,Ai=/^\s*(_?)(\S+?)\1\s*$/,Ni=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,ji=r("$injector");it.$$annotate=rt;var Li=r("$animate"),Pi=1,Ii="ng-animate",Fi=function(){this.$get=m},zi=function(){var e=new et,t=[];this.$get=["$$AnimateRunner","$rootScope",function(n,r){function i(e,t,n){var r=!1;return t&&(t=k(t)?t.split(" "):qr(t)?t:[],a(t,function(t){t&&(r=!0,e[t]=n)})),r}function o(){a(t,function(t){var n=e.get(t);if(n){var r=lt(t.attr("class")),i="",o="";a(n,function(e,t){var n=!!r[t];e!==n&&(e?i+=(i.length?" ":"")+t:o+=(o.length?" ":"")+t)}),a(t,function(e){i&&Re(e,i),o&&_e(e,o)}),e.remove(t)}}),t.length=0}function s(n,a,s){var l=e.get(n)||{},u=i(l,a,!0),c=i(l,s,!1);(u||c)&&(e.put(n,l),t.push(n),1===t.length&&r.$$postDigest(o))}return{enabled:m,on:m,off:m,pin:m,push:function(e,t,r,i){i&&i(),r=r||{},r.from&&e.css(r.from),r.to&&e.css(r.to),(r.addClass||r.removeClass)&&s(e,r.addClass,r.removeClass);var a=new n;return a.complete(),a}}}]},_i=["$provide",function(e){var t=this;this.$$registeredAnimations=Object.create(null),this.register=function(n,r){if(n&&"."!==n.charAt(0))throw Li("notcsel","Expecting class selector starting with '.' got '{0}'.",n);var i=n+"-animation";t.$$registeredAnimations[n.substr(1)]=i,e.factory(i,r)},this.classNameFilter=function(e){if(1===arguments.length&&(this.$$classNameFilter=e instanceof RegExp?e:null,this.$$classNameFilter)){var t=new RegExp("(\\s+|\\/)"+Ii+"(\\s+|\\/)");if(t.test(this.$$classNameFilter.toString()))throw Li("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',Ii)}return this.$$classNameFilter},this.$get=["$$animateQueue",function(e){function t(e,t,n){if(n){var r=st(n);!r||r.parentNode||r.previousElementSibling||(n=null)}n?n.after(e):t.prepend(e)}return{on:e.on,off:e.off,pin:e.pin,enabled:e.enabled,cancel:function(e){e.end&&e.end()},enter:function(n,r,i,a){return r=r&&Pr(r),i=i&&Pr(i),r=r||i.parent(),t(n,r,i),e.push(n,"enter",ut(a))},move:function(n,r,i,a){return r=r&&Pr(r),i=i&&Pr(i),r=r||i.parent(),t(n,r,i),e.push(n,"move",ut(a))},leave:function(t,n){return e.push(t,"leave",ut(n),function(){t.remove()})},addClass:function(t,n,r){return r=ut(r),r.addClass=ot(r.addclass,n),e.push(t,"addClass",r)},removeClass:function(t,n,r){return r=ut(r),r.removeClass=ot(r.removeClass,n),e.push(t,"removeClass",r)},setClass:function(t,n,r,i){return i=ut(i),i.addClass=ot(i.addClass,n),i.removeClass=ot(i.removeClass,r),e.push(t,"setClass",i)},animate:function(t,n,r,i,a){return a=ut(a),a.from=a.from?f(a.from,n):n,a.to=a.to?f(a.to,r):r,i=i||"ng-inline-animate",a.tempClasses=ot(a.tempClasses,i),e.push(t,"animate",a)}}}]}],Ri=function(){this.$get=["$$rAF",function(e){function t(t){n.push(t),n.length>1||e(function(){for(var e=0;e<n.length;e++)n[e]();n=[]})}var n=[];return function(){var e=!1;return t(function(){e=!0}),function(n){e?n():t(n)}}}]},Hi=function(){this.$get=["$q","$sniffer","$$animateAsyncRun","$document","$timeout",function(e,t,n,r,i){function o(e){this.setHost(e);var t=n(),a=function(e){i(e,0,!1)};this._doneCallbacks=[],this._tick=function(e){var n=r[0];n&&n.hidden?a(e):t(e)},this._state=0}var s=0,l=1,u=2;return o.chain=function(e,t){function n(){return r===e.length?void t(!0):void e[r](function(e){return e===!1?void t(!1):(r++,void n())})}var r=0;n()},o.all=function(e,t){function n(n){i=i&&n,++r===e.length&&t(i)}var r=0,i=!0;a(e,function(e){e.done(n)})},o.prototype={setHost:function(e){this.host=e||{}},done:function(e){this._state===u?e():this._doneCallbacks.push(e)},progress:m,getPromise:function(){if(!this.promise){var t=this;this.promise=e(function(e,n){t.done(function(t){t===!1?n():e()})})}return this.promise},then:function(e,t){return this.getPromise().then(e,t)},"catch":function(e){return this.getPromise()["catch"](e)},"finally":function(e){return this.getPromise()["finally"](e)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(e){var t=this;t._state===s&&(t._state=l,t._tick(function(){t._resolve(e)}))},_resolve:function(e){this._state!==u&&(a(this._doneCallbacks,function(t){t(e)}),this._doneCallbacks.length=0,this._state=u)}},o}]},Ui=function(){this.$get=["$$rAF","$q","$$AnimateRunner",function(e,t,n){return function(t,r){function i(){return e(function(){a(),s||l.complete(),s=!0}),l}function a(){o.addClass&&(t.addClass(o.addClass),o.addClass=null),o.removeClass&&(t.removeClass(o.removeClass),o.removeClass=null),o.to&&(t.css(o.to),o.to=null)}var o=r||{};o.$$prepared||(o=H(o)),o.cleanupStyles&&(o.from=o.to=null),o.from&&(t.css(o.from),o.from=null);var s,l=new n;return{start:i,end:i}}}]},Vi=r("$compile");ht.$inject=["$provide","$$sanitizeUriProvider"];var Wi=/^((?:x|data)[\:\-_])/i,Bi=r("$controller"),qi=/^(\S+)(\s+as\s+([\w$]+))?$/,Yi=function(){this.$get=["$document",function(e){return function(t){return t?!t.nodeType&&t instanceof Pr&&(t=t[0]):t=e[0].body,t.offsetWidth+1}}]},Gi="application/json",Xi={"Content-Type":Gi+";charset=utf-8"},Ki=/^\[|^\{(?!\{)/,Ji={"[":/]$/,"{":/}$/},Zi=/^\)\]\}',?\n/,Qi=r("$http"),ea=function(e){return function(){throw Qi("legacy","The method `{0}` on the promise returned from `$http` has been disabled.",e)}},ta=Wr.$interpolateMinErr=r("$interpolate");ta.throwNoconcat=function(e){throw ta("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",e)},ta.interr=function(e,t){return ta("interr","Can't interpolate: {0}\n{1}",e,t.toString())};var na=/^([^\?#]*)(\?([^#]*))?(#(.*))?$/,ra={http:80,https:443,ftp:21},ia=r("$location"),aa={$$html5:!1,$$replace:!1,absUrl:Gt("$$absUrl"),url:function(e){if(y(e))return this.$$url;var t=na.exec(e);return(t[1]||""===e)&&this.path(decodeURIComponent(t[1])),(t[2]||t[1]||""===e)&&this.search(t[3]||""),this.hash(t[5]||""),this},protocol:Gt("$$protocol"),host:Gt("$$host"),port:Gt("$$port"),path:Xt("$$path",function(e){return e=null!==e?e.toString():"","/"==e.charAt(0)?e:"/"+e}),search:function(e,t){switch(arguments.length){case 0:return this.$$search;case 1:if(k(e)||C(e))e=e.toString(),this.$$search=te(e);else{if(!w(e))throw ia("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");e=H(e,{}),a(e,function(t,n){null==t&&delete e[n]}),this.$$search=e}break;default:y(t)||null===t?delete this.$$search[e]:this.$$search[e]=t}return this.$$compose(),this},hash:Xt("$$hash",function(e){return null!==e?e.toString():""}),replace:function(){return this.$$replace=!0,this}};a([Yt,qt,Bt],function(e){e.prototype=Object.create(aa),e.prototype.state=function(t){if(!arguments.length)return this.$$state;if(e!==Bt||!this.$$html5)throw ia("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=y(t)?null:t,this}});var oa=r("$parse"),sa=Function.prototype.call,la=Function.prototype.apply,ua=Function.prototype.bind,ca=ve();a("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(e){ca[e]=!0});var fa={n:"\n",f:"\f",r:"\r",t:" ",v:"\x0B","'":"'",'"':'"'},da=function(e){this.options=e};da.prototype={constructor:da,lex:function(e){for(this.text=e,this.index=0,this.tokens=[];this.index<this.text.length;){var t=this.text.charAt(this.index);if('"'===t||"'"===t)this.readString(t);else if(this.isNumber(t)||"."===t&&this.isNumber(this.peek()))this.readNumber();else if(this.isIdent(t))this.readIdent();else if(this.is(t,"(){}[].,;:?"))this.tokens.push({index:this.index,text:t}),this.index++;else if(this.isWhitespace(t))this.index++;else{var n=t+this.peek(),r=n+this.peek(2),i=ca[t],a=ca[n],o=ca[r];if(i||a||o){var s=o?r:a?n:t;this.tokens.push({index:this.index,text:s,operator:!0}),this.index+=s.length}else this.throwError("Unexpected next character ",this.index,this.index+1)}}return this.tokens},is:function(e,t){return-1!==t.indexOf(e)},peek:function(e){var t=e||1;return this.index+t<this.text.length?this.text.charAt(this.index+t):!1},isNumber:function(e){return e>="0"&&"9">=e&&"string"==typeof e},isWhitespace:function(e){return" "===e||"\r"===e||" "===e||"\n"===e||"\x0B"===e||" "===e},isIdent:function(e){return e>="a"&&"z">=e||e>="A"&&"Z">=e||"_"===e||"$"===e},isExpOperator:function(e){return"-"===e||"+"===e||this.isNumber(e)},throwError:function(e,t,n){n=n||this.index;var r=$(t)?"s "+t+"-"+this.index+" ["+this.text.substring(t,n)+"]":" "+n;throw oa("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",e,r,this.text)},readNumber:function(){for(var e="",t=this.index;this.index<this.text.length;){var n=Or(this.text.charAt(this.index));if("."==n||this.isNumber(n))e+=n;else{var r=this.peek();if("e"==n&&this.isExpOperator(r))e+=n;else if(this.isExpOperator(n)&&r&&this.isNumber(r)&&"e"==e.charAt(e.length-1))e+=n;else{if(!this.isExpOperator(n)||r&&this.isNumber(r)||"e"!=e.charAt(e.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:t,text:e,constant:!0,value:Number(e)})},readIdent:function(){for(var e=this.index;this.index<this.text.length;){var t=this.text.charAt(this.index);if(!this.isIdent(t)&&!this.isNumber(t))break;this.index++}this.tokens.push({index:e,text:this.text.slice(e,this.index),identifier:!0})},readString:function(e){var t=this.index;this.index++;for(var n="",r=e,i=!1;this.index<this.text.length;){var a=this.text.charAt(this.index);if(r+=a,i){if("u"===a){var o=this.text.substring(this.index+1,this.index+5);o.match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+o+"]"),this.index+=4,n+=String.fromCharCode(parseInt(o,16))}else{var s=fa[a];n+=s||a}i=!1}else if("\\"===a)i=!0;else{if(a===e)return this.index++,void this.tokens.push({index:t,text:r,constant:!0,value:n});n+=a}this.index++}this.throwError("Unterminated quote",t)}};var pa=function(e,t){this.lexer=e,this.options=t};pa.Program="Program",pa.ExpressionStatement="ExpressionStatement",pa.AssignmentExpression="AssignmentExpression",pa.ConditionalExpression="ConditionalExpression",pa.LogicalExpression="LogicalExpression",pa.BinaryExpression="BinaryExpression",pa.UnaryExpression="UnaryExpression",pa.CallExpression="CallExpression",pa.MemberExpression="MemberExpression",pa.Identifier="Identifier",pa.Literal="Literal",pa.ArrayExpression="ArrayExpression",pa.Property="Property",pa.ObjectExpression="ObjectExpression",pa.ThisExpression="ThisExpression",pa.LocalsExpression="LocalsExpression",pa.NGValueParameter="NGValueParameter",pa.prototype={ast:function(e){this.text=e,this.tokens=this.lexer.lex(e);var t=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),t},program:function(){for(var e=[];;)if(this.tokens.length>0&&!this.peek("}",")",";","]")&&e.push(this.expressionStatement()),!this.expect(";"))return{type:pa.Program,body:e}},expressionStatement:function(){return{type:pa.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var e,t=this.expression();e=this.expect("|");)t=this.filter(t);return t},expression:function(){return this.assignment()},assignment:function(){var e=this.ternary();return this.expect("=")&&(e={type:pa.AssignmentExpression,left:e,right:this.assignment(),operator:"="}),e},ternary:function(){var e,t,n=this.logicalOR();return this.expect("?")&&(e=this.expression(),this.consume(":"))?(t=this.expression(),{type:pa.ConditionalExpression,test:n,alternate:e,consequent:t}):n},logicalOR:function(){for(var e=this.logicalAND();this.expect("||");)e={type:pa.LogicalExpression,operator:"||",left:e,right:this.logicalAND()};return e},logicalAND:function(){for(var e=this.equality();this.expect("&&");)e={type:pa.LogicalExpression,operator:"&&",left:e,right:this.equality()};return e},equality:function(){for(var e,t=this.relational();e=this.expect("==","!=","===","!==");)t={type:pa.BinaryExpression,operator:e.text,left:t,right:this.relational()};return t},relational:function(){for(var e,t=this.additive();e=this.expect("<",">","<=",">=");)t={type:pa.BinaryExpression,operator:e.text,left:t,right:this.additive()};return t},additive:function(){for(var e,t=this.multiplicative();e=this.expect("+","-");)t={type:pa.BinaryExpression,operator:e.text,left:t,right:this.multiplicative()};return t},multiplicative:function(){for(var e,t=this.unary();e=this.expect("*","/","%");)t={type:pa.BinaryExpression,operator:e.text,left:t,right:this.unary()};return t},unary:function(){var e;return(e=this.expect("+","-","!"))?{type:pa.UnaryExpression,operator:e.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var e;this.expect("(")?(e=this.filterChain(),this.consume(")")):this.expect("[")?e=this.arrayDeclaration():this.expect("{")?e=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?e=H(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?e={type:pa.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?e=this.identifier():this.peek().constant?e=this.constant():this.throwError("not a primary expression",this.peek());for(var t;t=this.expect("(","[",".");)"("===t.text?(e={type:pa.CallExpression,callee:e,arguments:this.parseArguments()},this.consume(")")):"["===t.text?(e={type:pa.MemberExpression,object:e,property:this.expression(),computed:!0},this.consume("]")):"."===t.text?e={type:pa.MemberExpression,object:e,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return e},filter:function(e){for(var t=[e],n={type:pa.CallExpression,callee:this.identifier(),arguments:t,filter:!0};this.expect(":");)t.push(this.expression());return n},parseArguments:function(){var e=[];if(")"!==this.peekToken().text)do e.push(this.expression());while(this.expect(","));return e},identifier:function(){var e=this.consume();return e.identifier||this.throwError("is not a valid identifier",e),{type:pa.Identifier,name:e.text}},constant:function(){return{type:pa.Literal,value:this.consume().value}},arrayDeclaration:function(){var e=[];if("]"!==this.peekToken().text)do{if(this.peek("]"))break;e.push(this.expression())}while(this.expect(","));return this.consume("]"),{type:pa.ArrayExpression,elements:e}},object:function(){var e,t=[];if("}"!==this.peekToken().text)do{if(this.peek("}"))break;e={type:pa.Property,kind:"init"},this.peek().constant?e.key=this.constant():this.peek().identifier?e.key=this.identifier():this.throwError("invalid key",this.peek()),this.consume(":"),e.value=this.expression(),t.push(e)}while(this.expect(","));return this.consume("}"),{type:pa.ObjectExpression,properties:t}},throwError:function(e,t){throw oa("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",t.text,e,t.index+1,this.text,this.text.substring(t.index))},consume:function(e){if(0===this.tokens.length)throw oa("ueoe","Unexpected end of expression: {0}",this.text);var t=this.expect(e);return t||this.throwError("is unexpected, expecting ["+e+"]",this.peek()),t},peekToken:function(){if(0===this.tokens.length)throw oa("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(e,t,n,r){return this.peekAhead(0,e,t,n,r)},peekAhead:function(e,t,n,r,i){if(this.tokens.length>e){var a=this.tokens[e],o=a.text;if(o===t||o===n||o===r||o===i||!t&&!n&&!r&&!i)return a}return!1},expect:function(e,t,n,r){var i=this.peek(e,t,n,r);return i?(this.tokens.shift(),i):!1},selfReferential:{"this":{type:pa.ThisExpression},$locals:{type:pa.LocalsExpression}}},pn.prototype={compile:function(e,t){var r=this,i=this.astBuilder.ast(e);this.state={nextId:0,filters:{},expensiveChecks:t,fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},sn(i,r.$filter);var o,s="";if(this.stage="assign",o=cn(i)){this.state.computing="assign";var l=this.nextId();this.recurse(o,l),this.return_(l),s="fn.assign="+this.generateFunction("assign","s,v,l")}var u=ln(i.body);r.stage="inputs",a(u,function(e,t){var n="fn"+t;r.state[n]={vars:[],body:[],own:{}},r.state.computing=n;var i=r.nextId();r.recurse(e,i),r.return_(i),r.state.inputs.push(n),e.watchId=t}),this.state.computing="fn",this.stage="main",this.recurse(i);var c='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+s+this.watchFns()+"return fn;",f=new Function("$filter","ensureSafeMemberName","ensureSafeObject","ensureSafeFunction","getStringValue","ensureSafeAssignContext","ifDefined","plus","text",c)(this.$filter,Zt,en,tn,Qt,nn,rn,an,e);return this.state=this.stage=n,f.literal=fn(i),f.constant=dn(i),f},USE:"use",STRICT:"strict",watchFns:function(){var e=[],t=this.state.inputs,n=this;return a(t,function(t){e.push("var "+t+"="+n.generateFunction(t,"s"))}),t.length&&e.push("fn.inputs=["+t.join(",")+"];"),e.join("")},generateFunction:function(e,t){return"function("+t+"){"+this.varsPrefix(e)+this.body(e)+"};"},filterPrefix:function(){var e=[],t=this;return a(this.state.filters,function(n,r){e.push(n+"=$filter("+t.escape(r)+")")}),e.length?"var "+e.join(",")+";":""},varsPrefix:function(e){return this.state[e].vars.length?"var "+this.state[e].vars.join(",")+";":""},body:function(e){return this.state[e].body.join("")},recurse:function(e,t,r,i,o,s){var l,u,c,f,d=this;if(i=i||m,!s&&$(e.watchId))return t=t||this.nextId(),void this.if_("i",this.lazyAssign(t,this.computedMember("i",e.watchId)),this.lazyRecurse(e,t,r,i,o,!0));switch(e.type){case pa.Program:a(e.body,function(t,r){d.recurse(t.expression,n,n,function(e){u=e}),r!==e.body.length-1?d.current().body.push(u,";"):d.return_(u)});break;case pa.Literal:f=this.escape(e.value),this.assign(t,f),i(f);break;case pa.UnaryExpression:this.recurse(e.argument,n,n,function(e){u=e}),f=e.operator+"("+this.ifDefined(u,0)+")",this.assign(t,f),i(f);break;case pa.BinaryExpression:this.recurse(e.left,n,n,function(e){l=e}),this.recurse(e.right,n,n,function(e){u=e}),f="+"===e.operator?this.plus(l,u):"-"===e.operator?this.ifDefined(l,0)+e.operator+this.ifDefined(u,0):"("+l+")"+e.operator+"("+u+")",this.assign(t,f),i(f);break;case pa.LogicalExpression:t=t||this.nextId(),d.recurse(e.left,t),d.if_("&&"===e.operator?t:d.not(t),d.lazyRecurse(e.right,t)),i(t);break;case pa.ConditionalExpression:t=t||this.nextId(),d.recurse(e.test,t),d.if_(t,d.lazyRecurse(e.alternate,t),d.lazyRecurse(e.consequent,t)),i(t);break;case pa.Identifier:t=t||this.nextId(),r&&(r.context="inputs"===d.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",e.name)+"?l:s"),r.computed=!1,r.name=e.name),Zt(e.name),d.if_("inputs"===d.stage||d.not(d.getHasOwnProperty("l",e.name)),function(){d.if_("inputs"===d.stage||"s",function(){o&&1!==o&&d.if_(d.not(d.nonComputedMember("s",e.name)),d.lazyAssign(d.nonComputedMember("s",e.name),"{}")),d.assign(t,d.nonComputedMember("s",e.name))})},t&&d.lazyAssign(t,d.nonComputedMember("l",e.name))),(d.state.expensiveChecks||mn(e.name))&&d.addEnsureSafeObject(t),i(t);break;case pa.MemberExpression:l=r&&(r.context=this.nextId())||this.nextId(),t=t||this.nextId(),d.recurse(e.object,l,n,function(){d.if_(d.notNull(l),function(){o&&1!==o&&d.addEnsureSafeAssignContext(l),e.computed?(u=d.nextId(),d.recurse(e.property,u),d.getStringValue(u),d.addEnsureSafeMemberName(u),o&&1!==o&&d.if_(d.not(d.computedMember(l,u)),d.lazyAssign(d.computedMember(l,u),"{}")),f=d.ensureSafeObject(d.computedMember(l,u)),d.assign(t,f),r&&(r.computed=!0,r.name=u)):(Zt(e.property.name),o&&1!==o&&d.if_(d.not(d.nonComputedMember(l,e.property.name)),d.lazyAssign(d.nonComputedMember(l,e.property.name),"{}")),f=d.nonComputedMember(l,e.property.name),(d.state.expensiveChecks||mn(e.property.name))&&(f=d.ensureSafeObject(f)),d.assign(t,f),r&&(r.computed=!1,r.name=e.property.name))},function(){d.assign(t,"undefined")}),i(t)},!!o);break;case pa.CallExpression:t=t||this.nextId(),e.filter?(u=d.filter(e.callee.name),c=[],a(e.arguments,function(e){var t=d.nextId();d.recurse(e,t),c.push(t)}),f=u+"("+c.join(",")+")",d.assign(t,f),i(t)):(u=d.nextId(),l={},c=[],d.recurse(e.callee,u,l,function(){d.if_(d.notNull(u),function(){d.addEnsureSafeFunction(u),a(e.arguments,function(e){d.recurse(e,d.nextId(),n,function(e){c.push(d.ensureSafeObject(e))})}),l.name?(d.state.expensiveChecks||d.addEnsureSafeObject(l.context),f=d.member(l.context,l.name,l.computed)+"("+c.join(",")+")"):f=u+"("+c.join(",")+")",f=d.ensureSafeObject(f),d.assign(t,f)},function(){d.assign(t,"undefined")}),i(t)}));break;case pa.AssignmentExpression:if(u=this.nextId(),l={},!un(e.left))throw oa("lval","Trying to assign a value to a non l-value");this.recurse(e.left,n,l,function(){d.if_(d.notNull(l.context),function(){d.recurse(e.right,u),d.addEnsureSafeObject(d.member(l.context,l.name,l.computed)),d.addEnsureSafeAssignContext(l.context),f=d.member(l.context,l.name,l.computed)+e.operator+u,d.assign(t,f),i(t||f)})},1);break;case pa.ArrayExpression:c=[],a(e.elements,function(e){d.recurse(e,d.nextId(),n,function(e){c.push(e)})}),f="["+c.join(",")+"]",this.assign(t,f),i(f);break;case pa.ObjectExpression:c=[],a(e.properties,function(e){d.recurse(e.value,d.nextId(),n,function(t){c.push(d.escape(e.key.type===pa.Identifier?e.key.name:""+e.key.value)+":"+t)})}),f="{"+c.join(",")+"}",this.assign(t,f),i(f);break;case pa.ThisExpression:this.assign(t,"s"),i("s");break;case pa.LocalsExpression:this.assign(t,"l"),i("l");break;case pa.NGValueParameter:this.assign(t,"v"),i("v")}},getHasOwnProperty:function(e,t){var n=e+"."+t,r=this.current().own;return r.hasOwnProperty(n)||(r[n]=this.nextId(!1,e+"&&("+this.escape(t)+" in "+e+")")),r[n]},assign:function(e,t){return e?(this.current().body.push(e,"=",t,";"),e):void 0},filter:function(e){return this.state.filters.hasOwnProperty(e)||(this.state.filters[e]=this.nextId(!0)),this.state.filters[e]},ifDefined:function(e,t){return"ifDefined("+e+","+this.escape(t)+")"},plus:function(e,t){return"plus("+e+","+t+")"},return_:function(e){this.current().body.push("return ",e,";")},if_:function(e,t,n){if(e===!0)t();else{var r=this.current().body;r.push("if(",e,"){"),t(),r.push("}"),n&&(r.push("else{"),n(),r.push("}"))}},not:function(e){return"!("+e+")"},notNull:function(e){return e+"!=null"},nonComputedMember:function(e,t){return e+"."+t},computedMember:function(e,t){return e+"["+t+"]"},member:function(e,t,n){return n?this.computedMember(e,t):this.nonComputedMember(e,t)},addEnsureSafeObject:function(e){this.current().body.push(this.ensureSafeObject(e),";")},addEnsureSafeMemberName:function(e){this.current().body.push(this.ensureSafeMemberName(e),";")},addEnsureSafeFunction:function(e){this.current().body.push(this.ensureSafeFunction(e),";")},addEnsureSafeAssignContext:function(e){this.current().body.push(this.ensureSafeAssignContext(e),";")},ensureSafeObject:function(e){return"ensureSafeObject("+e+",text)"},ensureSafeMemberName:function(e){return"ensureSafeMemberName("+e+",text)"},ensureSafeFunction:function(e){return"ensureSafeFunction("+e+",text)"},getStringValue:function(e){this.assign(e,"getStringValue("+e+")")},ensureSafeAssignContext:function(e){return"ensureSafeAssignContext("+e+",text)"},lazyRecurse:function(e,t,n,r,i,a){var o=this;return function(){o.recurse(e,t,n,r,i,a)}},lazyAssign:function(e,t){var n=this;return function(){n.assign(e,t)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(e){return"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)},escape:function(e){if(k(e))return"'"+e.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(C(e))return e.toString();if(e===!0)return"true";if(e===!1)return"false";if(null===e)return"null";if("undefined"==typeof e)return"undefined";throw oa("esc","IMPOSSIBLE")},nextId:function(e,t){var n="v"+this.state.nextId++;return e||this.current().vars.push(n+(t?"="+t:"")),n},current:function(){return this.state[this.state.computing]}},hn.prototype={compile:function(e,t){var n=this,r=this.astBuilder.ast(e);this.expression=e,this.expensiveChecks=t,sn(r,n.$filter);var i,o;(i=cn(r))&&(o=this.recurse(i));var s,l=ln(r.body);l&&(s=[],a(l,function(e,t){var r=n.recurse(e);e.input=r,s.push(r),e.watchId=t}));var u=[];a(r.body,function(e){u.push(n.recurse(e.expression))});var c=0===r.body.length?m:1===r.body.length?u[0]:function(e,t){var n;return a(u,function(r){n=r(e,t)}),n};return o&&(c.assign=function(e,t,n){return o(e,n,t)}),s&&(c.inputs=s),c.literal=fn(r),c.constant=dn(r),c},recurse:function(e,t,r){var i,o,s,l=this;if(e.input)return this.inputs(e.input,e.watchId);switch(e.type){case pa.Literal:return this.value(e.value,t);case pa.UnaryExpression:return o=this.recurse(e.argument),this["unary"+e.operator](o,t);case pa.BinaryExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);case pa.LogicalExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);case pa.ConditionalExpression:return this["ternary?:"](this.recurse(e.test),this.recurse(e.alternate),this.recurse(e.consequent),t);case pa.Identifier:return Zt(e.name,l.expression),l.identifier(e.name,l.expensiveChecks||mn(e.name),t,r,l.expression);case pa.MemberExpression:return i=this.recurse(e.object,!1,!!r),e.computed||(Zt(e.property.name,l.expression),o=e.property.name),e.computed&&(o=this.recurse(e.property)),e.computed?this.computedMember(i,o,t,r,l.expression):this.nonComputedMember(i,o,l.expensiveChecks,t,r,l.expression);case pa.CallExpression:return s=[],a(e.arguments,function(e){s.push(l.recurse(e))}),e.filter&&(o=this.$filter(e.callee.name)),e.filter||(o=this.recurse(e.callee,!0)),e.filter?function(e,r,i,a){for(var l=[],u=0;u<s.length;++u)l.push(s[u](e,r,i,a));var c=o.apply(n,l,a);return t?{context:n,name:n,value:c}:c}:function(e,n,r,i){var a,u=o(e,n,r,i);if(null!=u.value){en(u.context,l.expression),tn(u.value,l.expression);for(var c=[],f=0;f<s.length;++f)c.push(en(s[f](e,n,r,i),l.expression));a=en(u.value.apply(u.context,c),l.expression)}return t?{value:a}:a};case pa.AssignmentExpression:return i=this.recurse(e.left,!0,1),o=this.recurse(e.right),function(e,n,r,a){var s=i(e,n,r,a),u=o(e,n,r,a);return en(s.value,l.expression),nn(s.context),s.context[s.name]=u,t?{value:u}:u};case pa.ArrayExpression:return s=[],a(e.elements,function(e){s.push(l.recurse(e))}),function(e,n,r,i){for(var a=[],o=0;o<s.length;++o)a.push(s[o](e,n,r,i));return t?{value:a}:a};case pa.ObjectExpression:return s=[],a(e.properties,function(e){s.push({key:e.key.type===pa.Identifier?e.key.name:""+e.key.value,value:l.recurse(e.value)})}),function(e,n,r,i){for(var a={},o=0;o<s.length;++o)a[s[o].key]=s[o].value(e,n,r,i);return t?{value:a}:a};case pa.ThisExpression:return function(e){return t?{value:e}:e};case pa.LocalsExpression:return function(e,n){return t?{value:n}:n};case pa.NGValueParameter:return function(e,n,r){return t?{value:r}:r}}},"unary+":function(e,t){return function(n,r,i,a){var o=e(n,r,i,a);return o=$(o)?+o:0,t?{value:o}:o}},"unary-":function(e,t){return function(n,r,i,a){var o=e(n,r,i,a);return o=$(o)?-o:0,t?{value:o}:o}},"unary!":function(e,t){return function(n,r,i,a){var o=!e(n,r,i,a);return t?{value:o}:o}},"binary+":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o),l=t(r,i,a,o),u=an(s,l);return n?{value:u}:u}},"binary-":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o),l=t(r,i,a,o),u=($(s)?s:0)-($(l)?l:0);return n?{value:u}:u}},"binary*":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)*t(r,i,a,o);return n?{value:s}:s}},"binary/":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)/t(r,i,a,o);return n?{value:s}:s}},"binary%":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)%t(r,i,a,o);return n?{value:s}:s}},"binary===":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)===t(r,i,a,o);return n?{value:s}:s}},"binary!==":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)!==t(r,i,a,o);return n?{value:s}:s}},"binary==":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)==t(r,i,a,o);return n?{value:s}:s}},"binary!=":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)!=t(r,i,a,o);return n?{value:s}:s}},"binary<":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)<t(r,i,a,o);return n?{value:s}:s}},"binary>":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)>t(r,i,a,o);return n?{value:s}:s}},"binary<=":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)<=t(r,i,a,o);return n?{value:s}:s}},"binary>=":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)>=t(r,i,a,o);return n?{value:s
}:s}},"binary&&":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)&&t(r,i,a,o);return n?{value:s}:s}},"binary||":function(e,t,n){return function(r,i,a,o){var s=e(r,i,a,o)||t(r,i,a,o);return n?{value:s}:s}},"ternary?:":function(e,t,n,r){return function(i,a,o,s){var l=e(i,a,o,s)?t(i,a,o,s):n(i,a,o,s);return r?{value:l}:l}},value:function(e,t){return function(){return t?{context:n,name:n,value:e}:e}},identifier:function(e,t,r,i,a){return function(o,s,l,u){var c=s&&e in s?s:o;i&&1!==i&&c&&!c[e]&&(c[e]={});var f=c?c[e]:n;return t&&en(f,a),r?{context:c,name:e,value:f}:f}},computedMember:function(e,t,n,r,i){return function(a,o,s,l){var u,c,f=e(a,o,s,l);return null!=f&&(u=t(a,o,s,l),u=Qt(u),Zt(u,i),r&&1!==r&&(nn(f),f&&!f[u]&&(f[u]={})),c=f[u],en(c,i)),n?{context:f,name:u,value:c}:c}},nonComputedMember:function(e,t,r,i,a,o){return function(s,l,u,c){var f=e(s,l,u,c);a&&1!==a&&(nn(f),f&&!f[t]&&(f[t]={}));var d=null!=f?f[t]:n;return(r||mn(t))&&en(d,o),i?{context:f,name:t,value:d}:d}},inputs:function(e,t){return function(n,r,i,a){return a?a[t]:e(n,r,i)}}};var ha=function(e,t,n){this.lexer=e,this.$filter=t,this.options=n,this.ast=new pa(e,n),this.astCompiler=n.csp?new hn(this.ast,t):new pn(this.ast,t)};ha.prototype={constructor:ha,parse:function(e){return this.astCompiler.compile(e,this.options.expensiveChecks)}};var ma=Object.prototype.valueOf,ga=r("$sce"),va={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"},ba=r("$compile"),ya=t.createElement("a"),$a=Nn(e.location.href);Pn.$inject=["$document"],Fn.$inject=["$provide"];var wa=22,xa=".",ka="0";Un.$inject=["$locale"],Vn.$inject=["$locale"];var Ca={yyyy:Gn("FullYear",4,0,!1,!0),yy:Gn("FullYear",2,0,!0,!0),y:Gn("FullYear",1,0,!1,!0),MMMM:Xn("Month"),MMM:Xn("Month",!0),MM:Gn("Month",2,1),M:Gn("Month",1,1),LLLL:Xn("Month",!1,!0),dd:Gn("Date",2),d:Gn("Date",1),HH:Gn("Hours",2),H:Gn("Hours",1),hh:Gn("Hours",2,-12),h:Gn("Hours",1,-12),mm:Gn("Minutes",2),m:Gn("Minutes",1),ss:Gn("Seconds",2),s:Gn("Seconds",1),sss:Gn("Milliseconds",3),EEEE:Xn("Day"),EEE:Xn("Day",!0),a:er,Z:Kn,ww:Qn(2),w:Qn(1),G:tr,GG:tr,GGG:tr,GGGG:nr},Ma=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/,Sa=/^\-?\d+$/;rr.$inject=["$locale"];var Ta=v(Or),Da=v(Ar);or.$inject=["$parse"];var Ea=v({restrict:"E",compile:function(e,t){return t.href||t.xlinkHref?void 0:function(e,t){if("a"===t[0].nodeName.toLowerCase()){var n="[object SVGAnimatedString]"===Hr.call(t.prop("href"))?"xlink:href":"href";t.on("click",function(e){t.attr(n)||e.preventDefault()})}}}}),Oa={};a(Ci,function(e,t){function n(e,n,i){e.$watch(i[r],function(e){i.$set(t,!!e)})}if("multiple"!=e){var r=mt("ng-"+t),i=n;"checked"===e&&(i=function(e,t,i){i.ngModel!==i[r]&&n(e,t,i)}),Oa[r]=function(){return{restrict:"A",priority:100,link:i}}}}),a(Si,function(e,t){Oa[t]=function(){return{priority:100,link:function(e,n,r){if("ngPattern"===t&&"/"==r.ngPattern.charAt(0)){var i=r.ngPattern.match(Tr);if(i)return void r.$set("ngPattern",new RegExp(i[1],i[2]))}e.$watch(r[t],function(e){r.$set(t,e)})}}}}),a(["src","srcset","href"],function(e){var t=mt("ng-"+e);Oa[t]=function(){return{priority:99,link:function(n,r,i){var a=e,o=e;"href"===e&&"[object SVGAnimatedString]"===Hr.call(r.prop("href"))&&(o="xlinkHref",i.$attr[o]="xlink:href",a=null),i.$observe(t,function(t){return t?(i.$set(o,t),void(Lr&&a&&r.prop(a,i[o]))):void("href"===e&&i.$set(o,null))})}}}});var Aa={$addControl:m,$$renameControl:lr,$removeControl:m,$setValidity:m,$setDirty:m,$setPristine:m,$setSubmitted:m},Na="ng-submitted";ur.$inject=["$element","$attrs","$scope","$animate","$interpolate"];var ja=function(e){return["$timeout","$parse",function(t,r){function i(e){return""===e?r('this[""]').assign:r(e).assign||m}var a={name:"form",restrict:e?"EAC":"E",require:["form","^^?form"],controller:ur,compile:function(r,a){r.addClass(go).addClass(ho);var o=a.name?"name":e&&a.ngForm?"ngForm":!1;return{pre:function(e,r,a,s){var l=s[0];if(!("action"in a)){var u=function(t){e.$apply(function(){l.$commitViewValue(),l.$setSubmitted()}),t.preventDefault()};fi(r[0],"submit",u),r.on("$destroy",function(){t(function(){di(r[0],"submit",u)},0,!1)})}var c=s[1]||l.$$parentForm;c.$addControl(l);var d=o?i(l.$name):m;o&&(d(e,l),a.$observe(o,function(t){l.$name!==t&&(d(e,n),l.$$parentForm.$$renameControl(l,t),(d=i(l.$name))(e,l))})),r.on("$destroy",function(){l.$$parentForm.$removeControl(l),d(e,n),f(l,Aa)})}}}};return a}]},La=ja(),Pa=ja(!0),Ia=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,Fa=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:\/?#]+|\[[a-f\d:]+\])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,za=/^[a-z0-9!#$%&'*+\/=?^_`{|}~.-]+@[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i,_a=/^\s*(\-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,Ra=/^(\d{4,})-(\d{2})-(\d{2})$/,Ha=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,Ua=/^(\d{4,})-W(\d\d)$/,Va=/^(\d{4,})-(\d\d)$/,Wa=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,Ba="keydown wheel mousedown",qa=ve();a("date,datetime-local,month,time,week".split(","),function(e){qa[e]=!0});var Ya={text:fr,date:mr("date",Ra,hr(Ra,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":mr("datetimelocal",Ha,hr(Ha,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:mr("time",Wa,hr(Wa,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:mr("week",Ua,pr,"yyyy-Www"),month:mr("month",Va,hr(Va,["yyyy","MM"]),"yyyy-MM"),number:vr,url:br,email:yr,radio:$r,checkbox:xr,hidden:m,button:m,submit:m,reset:m,file:m},Ga=["$browser","$sniffer","$filter","$parse",function(e,t,n,r){return{restrict:"E",require:["?ngModel"],link:{pre:function(i,a,o,s){s[0]&&(Ya[Or(o.type)]||Ya.text)(i,a,o,s[0],t,e,n,r)}}}}],Xa=/^(true|false|\d+)$/,Ka=function(){return{restrict:"A",priority:100,compile:function(e,t){return Xa.test(t.ngValue)?function(e,t,n){n.$set("value",e.$eval(n.ngValue))}:function(e,t,n){e.$watch(n.ngValue,function(e){n.$set("value",e)})}}}},Ja=["$compile",function(e){return{restrict:"AC",compile:function(t){return e.$$addBindingClass(t),function(t,n,r){e.$$addBindingInfo(n,r.ngBind),n=n[0],t.$watch(r.ngBind,function(e){n.textContent=y(e)?"":e})}}}}],Za=["$interpolate","$compile",function(e,t){return{compile:function(n){return t.$$addBindingClass(n),function(n,r,i){var a=e(r.attr(i.$attr.ngBindTemplate));t.$$addBindingInfo(r,a.expressions),r=r[0],i.$observe("ngBindTemplate",function(e){r.textContent=y(e)?"":e})}}}}],Qa=["$sce","$parse","$compile",function(e,t,n){return{restrict:"A",compile:function(r,i){var a=t(i.ngBindHtml),o=t(i.ngBindHtml,function(e){return(e||"").toString()});return n.$$addBindingClass(r),function(t,r,i){n.$$addBindingInfo(r,i.ngBindHtml),t.$watch(o,function(){r.html(e.getTrustedHtml(a(t))||"")})}}}}],eo=v({restrict:"A",require:"ngModel",link:function(e,t,n,r){r.$viewChangeListeners.push(function(){e.$eval(n.ngChange)})}}),to=kr("",!0),no=kr("Odd",0),ro=kr("Even",1),io=sr({compile:function(e,t){t.$set("ngCloak",n),e.removeClass("ng-cloak")}}),ao=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],oo={},so={blur:!0,focus:!0};a("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(e){var t=mt("ng-"+e);oo[t]=["$parse","$rootScope",function(n,r){return{restrict:"A",compile:function(i,a){var o=n(a[t],null,!0);return function(t,n){n.on(e,function(n){var i=function(){o(t,{$event:n})};so[e]&&r.$$phase?t.$evalAsync(i):t.$apply(i)})}}}}]});var lo=["$animate","$compile",function(e,t){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(n,r,i,a,o){var s,l,u;n.$watch(i.ngIf,function(n){n?l||o(function(n,a){l=a,n[n.length++]=t.$$createComment("end ngIf",i.ngIf),s={clone:n},e.enter(n,r.parent(),r)}):(u&&(u.remove(),u=null),l&&(l.$destroy(),l=null),s&&(u=ge(s.clone),e.leave(u).then(function(){u=null}),s=null))})}}}],uo=["$templateRequest","$anchorScroll","$animate",function(e,t,n){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:Wr.noop,compile:function(r,i){var a=i.ngInclude||i.src,o=i.onload||"",s=i.autoscroll;return function(r,i,l,u,c){var f,d,p,h=0,m=function(){d&&(d.remove(),d=null),f&&(f.$destroy(),f=null),p&&(n.leave(p).then(function(){d=null}),d=p,p=null)};r.$watch(a,function(a){var l=function(){!$(s)||s&&!r.$eval(s)||t()},d=++h;a?(e(a,!0).then(function(e){if(!r.$$destroyed&&d===h){var t=r.$new();u.template=e;var s=c(t,function(e){m(),n.enter(e,null,i).then(l)});f=t,p=s,f.$emit("$includeContentLoaded",a),r.$eval(o)}},function(){r.$$destroyed||d===h&&(m(),r.$emit("$includeContentError",a))}),r.$emit("$includeContentRequested",a)):(m(),u.template=null)})}}}}],co=["$compile",function(e){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(n,r,i,a){return Hr.call(r[0]).match(/SVG/)?(r.empty(),void e(De(a.template,t).childNodes)(n,function(e){r.append(e)},{futureParentElement:r})):(r.html(a.template),void e(r.contents())(n))}}}],fo=sr({priority:450,compile:function(){return{pre:function(e,t,n){e.$eval(n.ngInit)}}}}),po=function(){return{restrict:"A",priority:100,require:"ngModel",link:function(e,t,r,i){var o=t.attr(r.$attr.ngList)||", ",s="false"!==r.ngTrim,l=s?Gr(o):o,u=function(e){if(!y(e)){var t=[];return e&&a(e.split(l),function(e){e&&t.push(s?Gr(e):e)}),t}};i.$parsers.push(u),i.$formatters.push(function(e){return qr(e)?e.join(o):n}),i.$isEmpty=function(e){return!e||!e.length}}}},ho="ng-valid",mo="ng-invalid",go="ng-pristine",vo="ng-dirty",bo="ng-untouched",yo="ng-touched",$o="ng-pending",wo="ng-empty",xo="ng-not-empty",ko=r("ngModel"),Co=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$rootScope","$q","$interpolate",function(e,t,r,i,o,s,l,u,c,f){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=n,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=n,this.$name=f(r.name||"",!1)(e),this.$$parentForm=Aa;var d,p=o(r.ngModel),h=p.assign,g=p,v=h,b=null,w=this;this.$$setOptions=function(e){if(w.$options=e,e&&e.getterSetter){var t=o(r.ngModel+"()"),n=o(r.ngModel+"($$$p)");g=function(e){var n=p(e);return S(n)&&(n=t(e)),n},v=function(e,t){S(p(e))?n(e,{$$$p:t}):h(e,t)}}else if(!p.assign)throw ko("nonassign","Expression '{0}' is non-assignable. Element: {1}",r.ngModel,Q(i))},this.$render=m,this.$isEmpty=function(e){return y(e)||""===e||null===e||e!==e},this.$$updateEmptyClasses=function(e){w.$isEmpty(e)?(s.removeClass(i,xo),s.addClass(i,wo)):(s.removeClass(i,wo),s.addClass(i,xo))};var x=0;Cr({ctrl:this,$element:i,set:function(e,t){e[t]=!0},unset:function(e,t){delete e[t]},$animate:s}),this.$setPristine=function(){w.$dirty=!1,w.$pristine=!0,s.removeClass(i,vo),s.addClass(i,go)},this.$setDirty=function(){w.$dirty=!0,w.$pristine=!1,s.removeClass(i,go),s.addClass(i,vo),w.$$parentForm.$setDirty()},this.$setUntouched=function(){w.$touched=!1,w.$untouched=!0,s.setClass(i,bo,yo)},this.$setTouched=function(){w.$touched=!0,w.$untouched=!1,s.setClass(i,yo,bo)},this.$rollbackViewValue=function(){l.cancel(b),w.$viewValue=w.$$lastCommittedViewValue,w.$render()},this.$validate=function(){if(!C(w.$modelValue)||!isNaN(w.$modelValue)){var e=w.$$lastCommittedViewValue,t=w.$$rawModelValue,r=w.$valid,i=w.$modelValue,a=w.$options&&w.$options.allowInvalid;w.$$runValidators(t,e,function(e){a||r===e||(w.$modelValue=e?t:n,w.$modelValue!==i&&w.$$writeModelToScope())})}},this.$$runValidators=function(e,t,r){function i(){var e=w.$$parserName||"parse";return y(d)?(l(e,null),!0):(d||(a(w.$validators,function(e,t){l(t,null)}),a(w.$asyncValidators,function(e,t){l(t,null)})),l(e,d),d)}function o(){var n=!0;return a(w.$validators,function(r,i){var a=r(e,t);n=n&&a,l(i,a)}),n?!0:(a(w.$asyncValidators,function(e,t){l(t,null)}),!1)}function s(){var r=[],i=!0;a(w.$asyncValidators,function(a,o){var s=a(e,t);if(!L(s))throw ko("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",s);l(o,n),r.push(s.then(function(){l(o,!0)},function(){i=!1,l(o,!1)}))}),r.length?c.all(r).then(function(){u(i)},m):u(!0)}function l(e,t){f===x&&w.$setValidity(e,t)}function u(e){f===x&&r(e)}x++;var f=x;return i()&&o()?void s():void u(!1)},this.$commitViewValue=function(){var e=w.$viewValue;l.cancel(b),(w.$$lastCommittedViewValue!==e||""===e&&w.$$hasNativeValidators)&&(w.$$updateEmptyClasses(e),w.$$lastCommittedViewValue=e,w.$pristine&&this.$setDirty(),this.$$parseAndValidate())},this.$$parseAndValidate=function(){function t(){w.$modelValue!==o&&w.$$writeModelToScope()}var r=w.$$lastCommittedViewValue,i=r;if(d=y(i)?n:!0)for(var a=0;a<w.$parsers.length;a++)if(i=w.$parsers[a](i),y(i)){d=!1;break}C(w.$modelValue)&&isNaN(w.$modelValue)&&(w.$modelValue=g(e));var o=w.$modelValue,s=w.$options&&w.$options.allowInvalid;w.$$rawModelValue=i,s&&(w.$modelValue=i,t()),w.$$runValidators(i,w.$$lastCommittedViewValue,function(e){s||(w.$modelValue=e?i:n,t())})},this.$$writeModelToScope=function(){v(e,w.$modelValue),a(w.$viewChangeListeners,function(e){try{e()}catch(n){t(n)}})},this.$setViewValue=function(e,t){w.$viewValue=e,w.$options&&!w.$options.updateOnDefault||w.$$debounceViewValueCommit(t)},this.$$debounceViewValueCommit=function(t){var n,r=0,i=w.$options;i&&$(i.debounce)&&(n=i.debounce,C(n)?r=n:C(n[t])?r=n[t]:C(n["default"])&&(r=n["default"])),l.cancel(b),r?b=l(function(){w.$commitViewValue()},r):u.$$phase?w.$commitViewValue():e.$apply(function(){w.$commitViewValue()})},e.$watch(function(){var t=g(e);if(t!==w.$modelValue&&(w.$modelValue===w.$modelValue||t===t)){w.$modelValue=w.$$rawModelValue=t,d=n;for(var r=w.$formatters,i=r.length,a=t;i--;)a=r[i](a);w.$viewValue!==a&&(w.$$updateEmptyClasses(a),w.$viewValue=w.$$lastCommittedViewValue=a,w.$render(),w.$$runValidators(t,a,m))}return t})}],Mo=["$rootScope",function(e){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Co,priority:1,compile:function(t){return t.addClass(go).addClass(bo).addClass(ho),{pre:function(e,t,n,r){var i=r[0],a=r[1]||i.$$parentForm;i.$$setOptions(r[2]&&r[2].$options),a.$addControl(i),n.$observe("name",function(e){i.$name!==e&&i.$$parentForm.$$renameControl(i,e)}),e.$on("$destroy",function(){i.$$parentForm.$removeControl(i)})},post:function(t,n,r,i){var a=i[0];a.$options&&a.$options.updateOn&&n.on(a.$options.updateOn,function(e){a.$$debounceViewValueCommit(e&&e.type)}),n.on("blur",function(){a.$touched||(e.$$phase?t.$evalAsync(a.$setTouched):t.$apply(a.$setTouched))})}}}}}],So=/(\s+|^)default(\s+|$)/,To=function(){return{restrict:"A",controller:["$scope","$attrs",function(e,t){var n=this;this.$options=H(e.$eval(t.ngModelOptions)),$(this.$options.updateOn)?(this.$options.updateOnDefault=!1,this.$options.updateOn=Gr(this.$options.updateOn.replace(So,function(){return n.$options.updateOnDefault=!0," "}))):this.$options.updateOnDefault=!0}]}},Do=sr({terminal:!0,priority:1e3}),Eo=r("ngOptions"),Oo=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w]*)|(?:\(\s*([\$\w][\$\w]*)\s*,\s*([\$\w][\$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Ao=["$compile","$parse",function(e,n){function r(e,t,r){function a(e,t,n,r,i){this.selectValue=e,this.viewValue=t,this.label=n,this.group=r,this.disabled=i}function o(e){var t;if(!u&&i(e))t=e;else{t=[];for(var n in e)e.hasOwnProperty(n)&&"$"!==n.charAt(0)&&t.push(n)}return t}var s=e.match(Oo);if(!s)throw Eo("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",e,Q(t));var l=s[5]||s[7],u=s[6],c=/ as /.test(s[0])&&s[1],f=s[9],d=n(s[2]?s[1]:l),p=c&&n(c),h=p||d,m=f&&n(f),g=f?function(e,t){return m(r,t)}:function(e){return Qe(e)},v=function(e,t){return g(e,k(e,t))},b=n(s[2]||s[1]),y=n(s[3]||""),$=n(s[4]||""),w=n(s[8]),x={},k=u?function(e,t){return x[u]=t,x[l]=e,x}:function(e){return x[l]=e,x};return{trackBy:f,getTrackByValue:v,getWatchables:n(w,function(e){var t=[];e=e||[];for(var n=o(e),i=n.length,a=0;i>a;a++){var l=e===n?a:n[a],u=e[l],c=k(u,l),f=g(u,c);if(t.push(f),s[2]||s[1]){var d=b(r,c);t.push(d)}if(s[4]){var p=$(r,c);t.push(p)}}return t}),getOptions:function(){for(var e=[],t={},n=w(r)||[],i=o(n),s=i.length,l=0;s>l;l++){var u=n===i?l:i[l],c=n[u],d=k(c,u),p=h(r,d),m=g(p,d),x=b(r,d),C=y(r,d),M=$(r,d),S=new a(m,p,x,C,M);e.push(S),t[m]=S}return{items:e,selectValueMap:t,getOptionFromViewValue:function(e){return t[v(e)]},getViewValueFromOption:function(e){return f?Wr.copy(e.viewValue):e.viewValue}}}}}function o(t,n,i,o){function u(e,t){e.element=t,t.disabled=e.disabled,e.label!==t.label&&(t.label=e.label,t.textContent=e.label),e.value!==t.value&&(t.value=e.selectValue)}function c(e,t,n,r){var i;return t&&Or(t.nodeName)===n?i=t:(i=r.cloneNode(!1),t?e.insertBefore(i,t):e.appendChild(i)),i}function f(e){for(var t;e;)t=e.nextSibling,Be(e),e=t}function d(e){var t=h&&h[0],n=k&&k[0];if(t||n)for(;e&&(e===t||e===n||e.nodeType===ai||"option"===_(e)&&""===e.value);)e=e.nextSibling;return e}function p(){var e=C&&m.readValue();C=M.getOptions();var t={},r=n[0].firstChild;if(x&&n.prepend(h),r=d(r),C.items.forEach(function(e){var i,a,o;$(e.group)?(i=t[e.group],i||(a=c(n[0],r,"optgroup",l),r=a.nextSibling,a.label=e.group,i=t[e.group]={groupElement:a,currentOptionElement:a.firstChild}),o=c(i.groupElement,i.currentOptionElement,"option",s),u(e,o),i.currentOptionElement=o.nextSibling):(o=c(n[0],r,"option",s),u(e,o),r=o.nextSibling)}),Object.keys(t).forEach(function(e){f(t[e].currentOptionElement)}),f(r),g.$render(),!g.$isEmpty(e)){var i=m.readValue(),a=M.trackBy||v;(a?V(e,i):e===i)||(g.$setViewValue(i),g.$render())}}for(var h,m=o[0],g=o[1],v=i.multiple,b=0,y=n.children(),w=y.length;w>b;b++)if(""===y[b].value){h=y.eq(b);break}var x=!!h,k=Pr(s.cloneNode(!1));k.val("?");var C,M=r(i.ngOptions,n,t),S=function(){x||n.prepend(h),n.val(""),h.prop("selected",!0),h.attr("selected",!0)},T=function(){x||h.remove()},D=function(){n.prepend(k),n.val("?"),k.prop("selected",!0),k.attr("selected",!0)},E=function(){k.remove()};v?(g.$isEmpty=function(e){return!e||0===e.length},m.writeValue=function(e){C.items.forEach(function(e){e.element.selected=!1}),e&&e.forEach(function(e){var t=C.getOptionFromViewValue(e);t&&!t.disabled&&(t.element.selected=!0)})},m.readValue=function(){var e=n.val()||[],t=[];return a(e,function(e){var n=C.selectValueMap[e];n&&!n.disabled&&t.push(C.getViewValueFromOption(n))}),t},M.trackBy&&t.$watchCollection(function(){return qr(g.$viewValue)?g.$viewValue.map(function(e){return M.getTrackByValue(e)}):void 0},function(){g.$render()})):(m.writeValue=function(e){var t=C.getOptionFromViewValue(e);t&&!t.disabled?(n[0].value!==t.selectValue&&(E(),T(),n[0].value=t.selectValue,t.element.selected=!0),t.element.setAttribute("selected","selected")):null===e||x?(E(),S()):(T(),D())},m.readValue=function(){var e=C.selectValueMap[n.val()];return e&&!e.disabled?(T(),E(),C.getViewValueFromOption(e)):null},M.trackBy&&t.$watch(function(){return M.getTrackByValue(g.$viewValue)},function(){g.$render()})),x?(h.remove(),e(h)(t),h.removeClass("ng-scope")):h=Pr(s.cloneNode(!1)),p(),t.$watchCollection(M.getWatchables,p)}var s=t.createElement("option"),l=t.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(e,t,n,r){r[0].registerOption=m},post:o}}}],No=["$locale","$interpolate","$log",function(e,t,n){var r=/{}/g,i=/^when(Minus)?(.+)$/;return{link:function(o,s,l){function u(e){s.text(e||"")}var c,f=l.count,d=l.$attr.when&&s.attr(l.$attr.when),p=l.offset||0,h=o.$eval(d)||{},g={},v=t.startSymbol(),b=t.endSymbol(),$=v+f+"-"+p+b,w=Wr.noop;a(l,function(e,t){var n=i.exec(t);if(n){var r=(n[1]?"-":"")+Or(n[2]);h[r]=s.attr(l.$attr[t])}}),a(h,function(e,n){g[n]=t(e.replace(r,$))}),o.$watch(f,function(t){var r=parseFloat(t),i=isNaN(r);if(i||r in h||(r=e.pluralCat(r-p)),r!==c&&!(i&&C(c)&&isNaN(c))){w();var a=g[r];y(a)?(null!=t&&n.debug("ngPluralize: no rule defined for '"+r+"' in "+d),w=m,u()):w=o.$watch(a,u),c=r}})}}}],jo=["$parse","$animate","$compile",function(e,t,o){var s="$$NG_REMOVED",l=r("ngRepeat"),u=function(e,t,n,r,i,a,o){e[n]=r,i&&(e[i]=a),e.$index=t,e.$first=0===t,e.$last=t===o-1,e.$middle=!(e.$first||e.$last),e.$odd=!(e.$even=0===(1&t))},c=function(e){return e.clone[0]},f=function(e){return e.clone[e.clone.length-1]};return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(r,d){var p=d.ngRepeat,h=o.$$createComment("end ngRepeat",p),m=p.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!m)throw l("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",p);var g=m[1],v=m[2],b=m[3],y=m[4];if(m=g.match(/^(?:(\s*[\$\w]+)|\(\s*([\$\w]+)\s*,\s*([\$\w]+)\s*\))$/),!m)throw l("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",g);var $=m[3]||m[1],w=m[2];if(b&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(b)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(b)))throw l("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",b);var x,k,C,M,S={$id:Qe};return y?x=e(y):(C=function(e,t){return Qe(t)},M=function(e){return e}),function(e,r,o,d,m){x&&(k=function(t,n,r){return w&&(S[w]=t),S[$]=n,S.$index=r,x(e,S)});var g=ve();e.$watchCollection(v,function(o){var d,v,y,x,S,T,D,E,O,A,N,j,L=r[0],P=ve();if(b&&(e[b]=o),i(o))O=o,E=k||C;else{E=k||M,O=[];for(var I in o)Er.call(o,I)&&"$"!==I.charAt(0)&&O.push(I)}for(x=O.length,N=new Array(x),d=0;x>d;d++)if(S=o===O?d:O[d],T=o[S],D=E(S,T,d),g[D])A=g[D],delete g[D],P[D]=A,N[d]=A;else{if(P[D])throw a(N,function(e){e&&e.scope&&(g[e.id]=e)}),l("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",p,D,T);N[d]={id:D,scope:n,clone:n},P[D]=!0}for(var F in g){if(A=g[F],j=ge(A.clone),t.leave(j),j[0].parentNode)for(d=0,v=j.length;v>d;d++)j[d][s]=!0;A.scope.$destroy()}for(d=0;x>d;d++)if(S=o===O?d:O[d],T=o[S],A=N[d],A.scope){y=L;do y=y.nextSibling;while(y&&y[s]);c(A)!=y&&t.move(ge(A.clone),null,L),L=f(A),u(A.scope,d,$,T,w,S,x)}else m(function(e,n){A.scope=n;var r=h.cloneNode(!1);e[e.length++]=r,t.enter(e,null,L),L=r,A.clone=e,P[A.id]=A,u(A.scope,d,$,T,w,S,x)});g=P})}}}}],Lo="ng-hide",Po="ng-hide-animate",Io=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngShow,function(t){e[t?"removeClass":"addClass"](n,Lo,{tempClasses:Po})})}}}],Fo=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngHide,function(t){e[t?"addClass":"removeClass"](n,Lo,{tempClasses:Po})})}}}],zo=sr(function(e,t,n){e.$watch(n.ngStyle,function(e,n){n&&e!==n&&a(n,function(e,n){t.css(n,"")}),e&&t.css(e)},!0)}),_o=["$animate","$compile",function(e,t){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(n,r,i,o){var s=i.ngSwitch||i.on,l=[],u=[],c=[],f=[],d=function(e,t){return function(){e.splice(t,1)}};n.$watch(s,function(n){var r,i;for(r=0,i=c.length;i>r;++r)e.cancel(c[r]);for(c.length=0,r=0,i=f.length;i>r;++r){var s=ge(u[r].clone);f[r].$destroy();var p=c[r]=e.leave(s);p.then(d(c,r))}u.length=0,f.length=0,(l=o.cases["!"+n]||o.cases["?"])&&a(l,function(n){n.transclude(function(r,i){f.push(i);var a=n.element;r[r.length++]=t.$$createComment("end ngSwitchWhen");var o={clone:r};u.push(o),e.enter(r,a.parent(),a)})})})}}}],Ro=sr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,r,i){r.cases["!"+n.ngSwitchWhen]=r.cases["!"+n.ngSwitchWhen]||[],r.cases["!"+n.ngSwitchWhen].push({transclude:i,element:t})}}),Ho=sr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,r,i){r.cases["?"]=r.cases["?"]||[],r.cases["?"].push({transclude:i,element:t})}}),Uo=r("ngTransclude"),Vo=sr({restrict:"EAC",link:function(e,t,n,r,i){function a(e){e.length&&(t.empty(),t.append(e))}if(n.ngTransclude===n.$attr.ngTransclude&&(n.ngTransclude=""),!i)throw Uo("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",Q(t));var o=n.ngTransclude||n.ngTranscludeSlot;i(a,null,o)}}),Wo=["$templateCache",function(e){return{restrict:"E",terminal:!0,compile:function(t,n){if("text/ng-template"==n.type){var r=n.id,i=t[0].text;e.put(r,i)}}}}],Bo={$setViewValue:m,$render:m},qo=["$element","$scope",function(e,r){var i=this,a=new et;i.ngModelCtrl=Bo,i.unknownOption=Pr(t.createElement("option")),i.renderUnknownOption=function(t){var n="? "+Qe(t)+" ?";i.unknownOption.val(n),e.prepend(i.unknownOption),e.val(n)},r.$on("$destroy",function(){i.renderUnknownOption=m}),i.removeUnknownOption=function(){i.unknownOption.parent()&&i.unknownOption.remove()},i.readValue=function(){return i.removeUnknownOption(),e.val()},i.writeValue=function(t){i.hasOption(t)?(i.removeUnknownOption(),e.val(t),""===t&&i.emptyOption.prop("selected",!0)):null==t&&i.emptyOption?(i.removeUnknownOption(),e.val("")):i.renderUnknownOption(t)},i.addOption=function(e,t){if(t[0].nodeType!==ai){he(e,'"option value"'),""===e&&(i.emptyOption=t);var n=a.get(e)||0;a.put(e,n+1),i.ngModelCtrl.$render(),Sr(t)}},i.removeOption=function(e){var t=a.get(e);t&&(1===t?(a.remove(e),""===e&&(i.emptyOption=n)):a.put(e,t-1))},i.hasOption=function(e){return!!a.get(e)},i.registerOption=function(e,t,n,r,a){if(r){var o;n.$observe("value",function(e){$(o)&&i.removeOption(o),o=e,i.addOption(e,t)})}else a?e.$watch(a,function(e,r){n.$set("value",e),r!==e&&i.removeOption(r),i.addOption(e,t)}):i.addOption(n.value,t);t.on("$destroy",function(){i.removeOption(n.value),i.ngModelCtrl.$render()})}}],Yo=function(){function e(e,t,n,r){var i=r[1];if(i){var o=r[0];if(o.ngModelCtrl=i,t.on("change",function(){e.$apply(function(){i.$setViewValue(o.readValue())})}),n.multiple){o.readValue=function(){var e=[];return a(t.find("option"),function(t){t.selected&&e.push(t.value)}),e},o.writeValue=function(e){var n=new et(e);a(t.find("option"),function(e){e.selected=$(n.get(e.value))})};var s,l=NaN;e.$watch(function(){l!==i.$viewValue||V(s,i.$viewValue)||(s=U(i.$viewValue),i.$render()),l=i.$viewValue}),i.$isEmpty=function(e){return!e||0===e.length}}}}function t(e,t,n,r){var i=r[1];if(i){var a=r[0];i.$render=function(){a.writeValue(i.$viewValue)}}}return{restrict:"E",require:["select","?ngModel"],controller:qo,priority:1,link:{pre:e,post:t}}},Go=["$interpolate",function(e){return{restrict:"E",priority:100,compile:function(t,n){if($(n.value))var r=e(n.value,!0);else{var i=e(t.text(),!0);i||n.$set("value",t.text())}return function(e,t,n){var a="$selectController",o=t.parent(),s=o.data(a)||o.parent().data(a);s&&s.registerOption(e,t,n,r,i)}}}}],Xo=v({restrict:"E",terminal:!1}),Ko=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){r&&(n.required=!0,r.$validators.required=function(e,t){return!n.required||!r.$isEmpty(t)},n.$observe("required",function(){r.$validate()}))}}},Jo=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,i,a){if(a){var o,s=i.ngPattern||i.pattern;i.$observe("pattern",function(e){if(k(e)&&e.length>0&&(e=new RegExp("^"+e+"$")),e&&!e.test)throw r("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",s,e,Q(t));o=e||n,a.$validate()}),a.$validators.pattern=function(e,t){return a.$isEmpty(t)||y(o)||o.test(t)}}}}},Zo=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=-1;n.$observe("maxlength",function(e){var t=p(e);i=isNaN(t)?-1:t,r.$validate()}),r.$validators.maxlength=function(e,t){return 0>i||r.$isEmpty(t)||t.length<=i}}}}},Qo=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=0;n.$observe("minlength",function(e){i=p(e)||0,r.$validate()}),r.$validators.minlength=function(e,t){return r.$isEmpty(t)||t.length>=i}}}}};return e.angular.bootstrap?void e.console:(fe(),we(Wr),Wr.module("ngLocale",[],["$provide",function(e){function t(e){e+="";var t=e.indexOf(".");return-1==t?0:e.length-t-1}function r(e,r){var i=r;n===i&&(i=Math.min(t(e),3));var a=Math.pow(10,i),o=(e*a|0)%a;return{v:i,f:o}}var i={ZERO:"zero",ONE:"one",TWO:"two",FEW:"few",MANY:"many",OTHER:"other"};e.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a","short":"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(e,t){var n=0|e,a=r(e,t);return 1==n&&0==a.v?i.ONE:i.OTHER}})}]),void Pr(t).ready(function(){oe(t,se)}))}(window,document),!window.angular.$$csp().noInlineStyle&&window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>')},{}],"/home/stack/stackviz/node_modules/angular/index.js":[function(e,t,n){e("./angular"),t.exports=angular},{"./angular":"/home/stack/stackviz/node_modules/angular/angular.js"}],"/home/stack/stackviz/node_modules/codemirror/addon/fold/foldcode.js":[function(e,t,n){!function(r){"object"==typeof n&&"object"==typeof t?r(e("../../lib/codemirror")):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],r):r(CodeMirror)}(function(e){"use strict";function t(t,i,a,o){function s(e){var n=l(t,i);if(!n||n.to.line-n.from.line<u)return null;for(var r=t.findMarksAt(n.from),a=0;a<r.length;++a)if(r[a].__isFold&&"fold"!==o){if(!e)return null;n.cleared=!0,r[a].clear()}return n}if(a&&a.call){var l=a;a=null}else var l=r(t,a,"rangeFinder");"number"==typeof i&&(i=e.Pos(i,0));var u=r(t,a,"minFoldSize"),c=s(!0);if(r(t,a,"scanUp"))for(;!c&&i.line>t.firstLine();)i=e.Pos(i.line-1,0),c=s(!1);if(c&&!c.cleared&&"unfold"!==o){var f=n(t,a);e.on(f,"mousedown",function(t){d.clear(),e.e_preventDefault(t)});var d=t.markText(c.from,c.to,{replacedWith:f,clearOnEnter:!0,__isFold:!0});d.on("clear",function(n,r){e.signal(t,"unfold",t,n,r)}),e.signal(t,"fold",t,c.from,c.to)}}function n(e,t){var n=r(e,t,"widget");if("string"==typeof n){var i=document.createTextNode(n);n=document.createElement("span"),n.appendChild(i),n.className="CodeMirror-foldmarker"}return n}function r(e,t,n){if(t&&void 0!==t[n])return t[n];var r=e.options.foldOptions;return r&&void 0!==r[n]?r[n]:i[n]}e.newFoldFunction=function(e,n){return function(r,i){t(r,i,{rangeFinder:e,widget:n})}},e.defineExtension("foldCode",function(e,n,r){t(this,e,n,r)}),e.defineExtension("isFolded",function(e){for(var t=this.findMarksAt(e),n=0;n<t.length;++n)if(t[n].__isFold)return!0}),e.commands.toggleFold=function(e){e.foldCode(e.getCursor())},e.commands.fold=function(e){
e.foldCode(e.getCursor(),null,"fold")},e.commands.unfold=function(e){e.foldCode(e.getCursor(),null,"unfold")},e.commands.foldAll=function(t){t.operation(function(){for(var n=t.firstLine(),r=t.lastLine();r>=n;n++)t.foldCode(e.Pos(n,0),null,"fold")})},e.commands.unfoldAll=function(t){t.operation(function(){for(var n=t.firstLine(),r=t.lastLine();r>=n;n++)t.foldCode(e.Pos(n,0),null,"unfold")})},e.registerHelper("fold","combine",function(){var e=Array.prototype.slice.call(arguments,0);return function(t,n){for(var r=0;r<e.length;++r){var i=e[r](t,n);if(i)return i}}}),e.registerHelper("fold","auto",function(e,t){for(var n=e.getHelpers(t,"fold"),r=0;r<n.length;r++){var i=n[r](e,t);if(i)return i}});var i={rangeFinder:e.fold.auto,widget:"↔",minFoldSize:0,scanUp:!1};e.defineOption("foldOptions",null),e.defineExtension("foldOption",function(e,t){return r(this,e,t)})})},{"../../lib/codemirror":"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js"}],"/home/stack/stackviz/node_modules/codemirror/addon/fold/foldgutter.js":[function(e,t,n){!function(r){"object"==typeof n&&"object"==typeof t?r(e("../../lib/codemirror"),e("./foldcode")):"function"==typeof define&&define.amd?define(["../../lib/codemirror","./foldcode"],r):r(CodeMirror)}(function(e){"use strict";function t(e){this.options=e,this.from=this.to=0}function n(e){return e===!0&&(e={}),null==e.gutter&&(e.gutter="CodeMirror-foldgutter"),null==e.indicatorOpen&&(e.indicatorOpen="CodeMirror-foldgutter-open"),null==e.indicatorFolded&&(e.indicatorFolded="CodeMirror-foldgutter-folded"),e}function r(e,t){for(var n=e.findMarksAt(f(t)),r=0;r<n.length;++r)if(n[r].__isFold&&n[r].find().from.line==t)return n[r]}function i(e){if("string"==typeof e){var t=document.createElement("div");return t.className=e+" CodeMirror-guttermarker-subtle",t}return e.cloneNode(!0)}function a(e,t,n){var a=e.state.foldGutter.options,o=t,s=e.foldOption(a,"minFoldSize"),l=e.foldOption(a,"rangeFinder");e.eachLine(t,n,function(t){var n=null;if(r(e,o))n=i(a.indicatorFolded);else{var u=f(o,0),c=l&&l(e,u);c&&c.to.line-c.from.line>=s&&(n=i(a.indicatorOpen))}e.setGutterMarker(t,a.gutter,n),++o})}function o(e){var t=e.getViewport(),n=e.state.foldGutter;n&&(e.operation(function(){a(e,t.from,t.to)}),n.from=t.from,n.to=t.to)}function s(e,t,n){var i=e.state.foldGutter;if(i){var a=i.options;if(n==a.gutter){var o=r(e,t);o?o.clear():e.foldCode(f(t,0),a.rangeFinder)}}}function l(e){var t=e.state.foldGutter;if(t){var n=t.options;t.from=t.to=0,clearTimeout(t.changeUpdate),t.changeUpdate=setTimeout(function(){o(e)},n.foldOnChangeTimeSpan||600)}}function u(e){var t=e.state.foldGutter;if(t){var n=t.options;clearTimeout(t.changeUpdate),t.changeUpdate=setTimeout(function(){var n=e.getViewport();t.from==t.to||n.from-t.to>20||t.from-n.to>20?o(e):e.operation(function(){n.from<t.from&&(a(e,n.from,t.from),t.from=n.from),n.to>t.to&&(a(e,t.to,n.to),t.to=n.to)})},n.updateViewportTimeSpan||400)}}function c(e,t){var n=e.state.foldGutter;if(n){var r=t.line;r>=n.from&&r<n.to&&a(e,r,r+1)}}e.defineOption("foldGutter",!1,function(r,i,a){a&&a!=e.Init&&(r.clearGutter(r.state.foldGutter.options.gutter),r.state.foldGutter=null,r.off("gutterClick",s),r.off("change",l),r.off("viewportChange",u),r.off("fold",c),r.off("unfold",c),r.off("swapDoc",l)),i&&(r.state.foldGutter=new t(n(i)),o(r),r.on("gutterClick",s),r.on("change",l),r.on("viewportChange",u),r.on("fold",c),r.on("unfold",c),r.on("swapDoc",l))});var f=e.Pos})},{"../../lib/codemirror":"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js","./foldcode":"/home/stack/stackviz/node_modules/codemirror/addon/fold/foldcode.js"}],"/home/stack/stackviz/node_modules/codemirror/addon/mode/simple.js":[function(e,t,n){!function(r){"object"==typeof n&&"object"==typeof t?r(e("../../lib/codemirror")):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],r):r(CodeMirror)}(function(e){"use strict";function t(e,t){if(!e.hasOwnProperty(t))throw new Error("Undefined state "+t+" in simple mode")}function n(e,t){if(!e)return/(?:)/;var n="";return e instanceof RegExp?(e.ignoreCase&&(n="i"),e=e.source):e=String(e),new RegExp((t===!1?"":"^")+"(?:"+e+")",n)}function r(e){if(!e)return null;if("string"==typeof e)return e.replace(/\./g," ");for(var t=[],n=0;n<e.length;n++)t.push(e[n]&&e[n].replace(/\./g," "));return t}function i(e,i){(e.next||e.push)&&t(i,e.next||e.push),this.regex=n(e.regex),this.token=r(e.token),this.data=e}function a(e,t){return function(n,r){if(r.pending){var i=r.pending.shift();return 0==r.pending.length&&(r.pending=null),n.pos+=i.text.length,i.token}if(r.local){if(r.local.end&&n.match(r.local.end)){var a=r.local.endToken||null;return r.local=r.localState=null,a}var o,a=r.local.mode.token(n,r.localState);return r.local.endScan&&(o=r.local.endScan.exec(n.current()))&&(n.pos=n.start+o.index),a}for(var l=e[r.state],u=0;u<l.length;u++){var c=l[u],f=(!c.data.sol||n.sol())&&n.match(c.regex);if(f){if(c.data.next?r.state=c.data.next:c.data.push?((r.stack||(r.stack=[])).push(r.state),r.state=c.data.push):c.data.pop&&r.stack&&r.stack.length&&(r.state=r.stack.pop()),c.data.mode&&s(t,r,c.data.mode,c.token),c.data.indent&&r.indent.push(n.indentation()+t.indentUnit),c.data.dedent&&r.indent.pop(),f.length>2){r.pending=[];for(var d=2;d<f.length;d++)f[d]&&r.pending.push({text:f[d],token:c.token[d-1]});return n.backUp(f[0].length-(f[1]?f[1].length:0)),c.token[0]}return c.token&&c.token.join?c.token[0]:c.token}}return n.next(),null}}function o(e,t){if(e===t)return!0;if(!e||"object"!=typeof e||!t||"object"!=typeof t)return!1;var n=0;for(var r in e)if(e.hasOwnProperty(r)){if(!t.hasOwnProperty(r)||!o(e[r],t[r]))return!1;n++}for(var r in t)t.hasOwnProperty(r)&&n--;return 0==n}function s(t,r,i,a){var s;if(i.persistent)for(var l=r.persistentStates;l&&!s;l=l.next)(i.spec?o(i.spec,l.spec):i.mode==l.mode)&&(s=l);var u=s?s.mode:i.mode||e.getMode(t,i.spec),c=s?s.state:e.startState(u);i.persistent&&!s&&(r.persistentStates={mode:u,spec:i.spec,state:c,next:r.persistentStates}),r.localState=c,r.local={mode:u,end:i.end&&n(i.end),endScan:i.end&&i.forceEnd!==!1&&n(i.end,!1),endToken:a&&a.join?a[a.length-1]:a}}function l(e,t){for(var n=0;n<t.length;n++)if(t[n]===e)return!0}function u(t,n){return function(r,i,a){if(r.local&&r.local.mode.indent)return r.local.mode.indent(r.localState,i,a);if(null==r.indent||r.local||n.dontIndentStates&&l(r.state,n.dontIndentStates)>-1)return e.Pass;var o=r.indent.length-1,s=t[r.state];e:for(;;){for(var u=0;u<s.length;u++){var c=s[u];if(c.data.dedent&&c.data.dedentIfLineStart!==!1){var f=c.regex.exec(i);if(f&&f[0]){o--,(c.next||c.push)&&(s=t[c.next||c.push]),i=i.slice(f[0].length);continue e}}}break}return 0>o?0:r.indent[o]}}e.defineSimpleMode=function(t,n){e.defineMode(t,function(t){return e.simpleMode(t,n)})},e.simpleMode=function(n,r){t(r,"start");var o={},s=r.meta||{},l=!1;for(var c in r)if(c!=s&&r.hasOwnProperty(c))for(var f=o[c]=[],d=r[c],p=0;p<d.length;p++){var h=d[p];f.push(new i(h,r)),(h.indent||h.dedent)&&(l=!0)}var m={startState:function(){return{state:"start",pending:null,local:null,localState:null,indent:l?[]:null}},copyState:function(t){var n={state:t.state,pending:t.pending,local:t.local,localState:null,indent:t.indent&&t.indent.slice(0)};t.localState&&(n.localState=e.copyState(t.local.mode,t.localState)),t.stack&&(n.stack=t.stack.slice(0));for(var r=t.persistentStates;r;r=r.next)n.persistentStates={mode:r.mode,spec:r.spec,state:r.state==t.localState?n.localState:e.copyState(r.mode,r.state),next:n.persistentStates};return n},token:a(o,n),innerMode:function(e){return e.local&&{mode:e.local.mode,state:e.localState}},indent:u(o,s)};if(s)for(var g in s)s.hasOwnProperty(g)&&(m[g]=s[g]);return m}})},{"../../lib/codemirror":"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js"}],"/home/stack/stackviz/node_modules/codemirror/lib/codemirror.js":[function(e,t,n){!function(e){if("object"==typeof n&&"object"==typeof t)t.exports=e();else{if("function"==typeof define&&define.amd)return define([],e);(this||window).CodeMirror=e()}}(function(){"use strict";function e(n,r){if(!(this instanceof e))return new e(n,r);this.options=r=r?Fi(r):{},Fi(Qa,r,!1),p(r);var i=r.value;"string"==typeof i&&(i=new Co(i,r.mode,null,r.lineSeparator)),this.doc=i;var a=new e.inputStyles[r.inputStyle](this),o=this.display=new t(n,i,a);o.wrapper.CodeMirror=this,u(this),s(this),r.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),r.autofocus&&!Da&&o.input.focus(),v(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:!1,cutIncoming:!1,selectingText:!1,draggingText:!1,highlight:new Oi,keySeq:null,specialChars:null};var l=this;ba&&11>ya&&setTimeout(function(){l.display.input.reset(!0)},20),Ut(this),Xi(),$t(this),this.curOp.forceUpdate=!0,Kr(this,i),r.autofocus&&!Da||l.hasFocus()?setTimeout(zi(vn,this),20):bn(this);for(var c in eo)eo.hasOwnProperty(c)&&eo[c](this,r[c],to);x(this),r.finishInit&&r.finishInit(this);for(var f=0;f<ao.length;++f)ao[f](this);xt(this),$a&&r.lineWrapping&&"optimizelegibility"==getComputedStyle(o.lineDiv).textRendering&&(o.lineDiv.style.textRendering="auto")}function t(e,t,n){var r=this;this.input=n,r.scrollbarFiller=Ui("div",null,"CodeMirror-scrollbar-filler"),r.scrollbarFiller.setAttribute("cm-not-content","true"),r.gutterFiller=Ui("div",null,"CodeMirror-gutter-filler"),r.gutterFiller.setAttribute("cm-not-content","true"),r.lineDiv=Ui("div",null,"CodeMirror-code"),r.selectionDiv=Ui("div",null,null,"position: relative; z-index: 1"),r.cursorDiv=Ui("div",null,"CodeMirror-cursors"),r.measure=Ui("div",null,"CodeMirror-measure"),r.lineMeasure=Ui("div",null,"CodeMirror-measure"),r.lineSpace=Ui("div",[r.measure,r.lineMeasure,r.selectionDiv,r.cursorDiv,r.lineDiv],null,"position: relative; outline: none"),r.mover=Ui("div",[Ui("div",[r.lineSpace],"CodeMirror-lines")],null,"position: relative"),r.sizer=Ui("div",[r.mover],"CodeMirror-sizer"),r.sizerWidth=null,r.heightForcer=Ui("div",null,null,"position: absolute; height: "+Po+"px; width: 1px;"),r.gutters=Ui("div",null,"CodeMirror-gutters"),r.lineGutter=null,r.scroller=Ui("div",[r.sizer,r.heightForcer,r.gutters],"CodeMirror-scroll"),r.scroller.setAttribute("tabIndex","-1"),r.wrapper=Ui("div",[r.scrollbarFiller,r.gutterFiller,r.scroller],"CodeMirror"),ba&&8>ya&&(r.gutters.style.zIndex=-1,r.scroller.style.paddingRight=0),$a||ma&&Da||(r.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(r.wrapper):e(r.wrapper)),r.viewFrom=r.viewTo=t.first,r.reportedViewFrom=r.reportedViewTo=t.first,r.view=[],r.renderedView=null,r.externalMeasured=null,r.viewOffset=0,r.lastWrapHeight=r.lastWrapWidth=0,r.updateLineNumbers=null,r.nativeBarWidth=r.barHeight=r.barWidth=0,r.scrollbarsClipped=!1,r.lineNumWidth=r.lineNumInnerWidth=r.lineNumChars=null,r.alignWidgets=!1,r.cachedCharWidth=r.cachedTextHeight=r.cachedPaddingH=null,r.maxLine=null,r.maxLineLength=0,r.maxLineChanged=!1,r.wheelDX=r.wheelDY=r.wheelStartX=r.wheelStartY=null,r.shift=!1,r.selForContextMenu=null,r.activeTouch=null,n.init(r)}function n(t){t.doc.mode=e.getMode(t.options,t.doc.modeOption),r(t)}function r(e){e.doc.iter(function(e){e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null)}),e.doc.frontier=e.doc.first,_e(e,100),e.state.modeGen++,e.curOp&&Pt(e)}function i(e){e.options.lineWrapping?(Zo(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(Jo(e.display.wrapper,"CodeMirror-wrap"),d(e)),o(e),Pt(e),st(e),setTimeout(function(){b(e)},100)}function a(e){var t=bt(e.display),n=e.options.lineWrapping,r=n&&Math.max(5,e.display.scroller.clientWidth/yt(e.display)-3);return function(i){if(xr(e.doc,i))return 0;var a=0;if(i.widgets)for(var o=0;o<i.widgets.length;o++)i.widgets[o].height&&(a+=i.widgets[o].height);return n?a+(Math.ceil(i.text.length/r)||1)*t:a+t}}function o(e){var t=e.doc,n=a(e);t.iter(function(e){var t=n(e);t!=e.height&&ei(e,t)})}function s(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),st(e)}function l(e){u(e),Pt(e),setTimeout(function(){w(e)},20)}function u(e){var t=e.display.gutters,n=e.options.gutters;Vi(t);for(var r=0;r<n.length;++r){var i=n[r],a=t.appendChild(Ui("div",null,"CodeMirror-gutter "+i));"CodeMirror-linenumbers"==i&&(e.display.lineGutter=a,a.style.width=(e.display.lineNumWidth||1)+"px")}t.style.display=r?"":"none",c(e)}function c(e){var t=e.display.gutters.offsetWidth;e.display.sizer.style.marginLeft=t+"px"}function f(e){if(0==e.height)return 0;for(var t,n=e.text.length,r=e;t=mr(r);){var i=t.find(0,!0);r=i.from.line,n+=i.from.ch-i.to.ch}for(r=e;t=gr(r);){var i=t.find(0,!0);n-=r.text.length-i.from.ch,r=i.to.line,n+=r.text.length-i.to.ch}return n}function d(e){var t=e.display,n=e.doc;t.maxLine=Jr(n,n.first),t.maxLineLength=f(t.maxLine),t.maxLineChanged=!0,n.iter(function(e){var n=f(e);n>t.maxLineLength&&(t.maxLineLength=n,t.maxLine=e)})}function p(e){var t=ji(e.gutters,"CodeMirror-linenumbers");-1==t&&e.lineNumbers?e.gutters=e.gutters.concat(["CodeMirror-linenumbers"]):t>-1&&!e.lineNumbers&&(e.gutters=e.gutters.slice(0),e.gutters.splice(t,1))}function h(e){var t=e.display,n=t.gutters.offsetWidth,r=Math.round(e.doc.height+We(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?n:0,docHeight:r,scrollHeight:r+qe(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:n}}function m(e,t,n){this.cm=n;var r=this.vert=Ui("div",[Ui("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),i=this.horiz=Ui("div",[Ui("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");e(r),e(i),Oo(r,"scroll",function(){r.clientHeight&&t(r.scrollTop,"vertical")}),Oo(i,"scroll",function(){i.clientWidth&&t(i.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,ba&&8>ya&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")}function g(){}function v(t){t.display.scrollbars&&(t.display.scrollbars.clear(),t.display.scrollbars.addClass&&Jo(t.display.wrapper,t.display.scrollbars.addClass)),t.display.scrollbars=new e.scrollbarModel[t.options.scrollbarStyle](function(e){t.display.wrapper.insertBefore(e,t.display.scrollbarFiller),Oo(e,"mousedown",function(){t.state.focused&&setTimeout(function(){t.display.input.focus()},0)}),e.setAttribute("cm-not-content","true")},function(e,n){"horizontal"==n?an(t,e):rn(t,e)},t),t.display.scrollbars.addClass&&Zo(t.display.wrapper,t.display.scrollbars.addClass)}function b(e,t){t||(t=h(e));var n=e.display.barWidth,r=e.display.barHeight;y(e,t);for(var i=0;4>i&&n!=e.display.barWidth||r!=e.display.barHeight;i++)n!=e.display.barWidth&&e.options.lineWrapping&&A(e),y(e,h(e)),n=e.display.barWidth,r=e.display.barHeight}function y(e,t){var n=e.display,r=n.scrollbars.update(t);n.sizer.style.paddingRight=(n.barWidth=r.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=r.bottom)+"px",n.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=r.bottom+"px",n.scrollbarFiller.style.width=r.right+"px"):n.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=r.bottom+"px",n.gutterFiller.style.width=t.gutterWidth+"px"):n.gutterFiller.style.display=""}function $(e,t,n){var r=n&&null!=n.top?Math.max(0,n.top):e.scroller.scrollTop;r=Math.floor(r-Ve(e));var i=n&&null!=n.bottom?n.bottom:r+e.wrapper.clientHeight,a=ni(t,r),o=ni(t,i);if(n&&n.ensure){var s=n.ensure.from.line,l=n.ensure.to.line;a>s?(a=s,o=ni(t,ri(Jr(t,s))+e.wrapper.clientHeight)):Math.min(l,t.lastLine())>=o&&(a=ni(t,ri(Jr(t,l))-e.wrapper.clientHeight),o=l)}return{from:a,to:Math.max(o,a+1)}}function w(e){var t=e.display,n=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var r=C(t)-t.scroller.scrollLeft+e.doc.scrollLeft,i=t.gutters.offsetWidth,a=r+"px",o=0;o<n.length;o++)if(!n[o].hidden){e.options.fixedGutter&&n[o].gutter&&(n[o].gutter.style.left=a);var s=n[o].alignable;if(s)for(var l=0;l<s.length;l++)s[l].style.left=a}e.options.fixedGutter&&(t.gutters.style.left=r+i+"px")}}function x(e){if(!e.options.lineNumbers)return!1;var t=e.doc,n=k(e.options,t.first+t.size-1),r=e.display;if(n.length!=r.lineNumChars){var i=r.measure.appendChild(Ui("div",[Ui("div",n)],"CodeMirror-linenumber CodeMirror-gutter-elt")),a=i.firstChild.offsetWidth,o=i.offsetWidth-a;return r.lineGutter.style.width="",r.lineNumInnerWidth=Math.max(a,r.lineGutter.offsetWidth-o)+1,r.lineNumWidth=r.lineNumInnerWidth+o,r.lineNumChars=r.lineNumInnerWidth?n.length:-1,r.lineGutter.style.width=r.lineNumWidth+"px",c(e),!0}return!1}function k(e,t){return String(e.lineNumberFormatter(t+e.firstLineNumber))}function C(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function M(e,t,n){var r=e.display;this.viewport=t,this.visible=$(r,e.doc,t),this.editorIsHidden=!r.wrapper.offsetWidth,this.wrapperHeight=r.wrapper.clientHeight,this.wrapperWidth=r.wrapper.clientWidth,this.oldDisplayWidth=Ye(e),this.force=n,this.dims=j(e),this.events=[]}function S(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=qe(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=qe(e)+"px",t.scrollbarsClipped=!0)}function T(e,t){var n=e.display,r=e.doc;if(t.editorIsHidden)return Ft(e),!1;if(!t.force&&t.visible.from>=n.viewFrom&&t.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==Ht(e))return!1;x(e)&&(Ft(e),t.dims=j(e));var i=r.first+r.size,a=Math.max(t.visible.from-e.options.viewportMargin,r.first),o=Math.min(i,t.visible.to+e.options.viewportMargin);n.viewFrom<a&&a-n.viewFrom<20&&(a=Math.max(r.first,n.viewFrom)),n.viewTo>o&&n.viewTo-o<20&&(o=Math.min(i,n.viewTo)),Ia&&(a=$r(e.doc,a),o=wr(e.doc,o));var s=a!=n.viewFrom||o!=n.viewTo||n.lastWrapHeight!=t.wrapperHeight||n.lastWrapWidth!=t.wrapperWidth;Rt(e,a,o),n.viewOffset=ri(Jr(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var l=Ht(e);if(!s&&0==l&&!t.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var u=Bi();return l>4&&(n.lineDiv.style.display="none"),L(e,n.updateLineNumbers,t.dims),l>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,u&&Bi()!=u&&u.offsetHeight&&u.focus(),Vi(n.cursorDiv),Vi(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,s&&(n.lastWrapHeight=t.wrapperHeight,n.lastWrapWidth=t.wrapperWidth,_e(e,400)),n.updateLineNumbers=null,!0}function D(e,t){for(var n=t.viewport,r=!0;(r&&e.options.lineWrapping&&t.oldDisplayWidth!=Ye(e)||(n&&null!=n.top&&(n={top:Math.min(e.doc.height+We(e.display)-Ge(e),n.top)}),t.visible=$(e.display,e.doc,n),!(t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)))&&T(e,t);r=!1){A(e);var i=h(e);Le(e),b(e,i),O(e,i)}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function E(e,t){var n=new M(e,t);if(T(e,n)){A(e),D(e,n);var r=h(e);Le(e),b(e,r),O(e,r),n.finish()}}function O(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+qe(e)+"px"}function A(e){for(var t=e.display,n=t.lineDiv.offsetTop,r=0;r<t.view.length;r++){var i,a=t.view[r];if(!a.hidden){if(ba&&8>ya){var o=a.node.offsetTop+a.node.offsetHeight;i=o-n,n=o}else{var s=a.node.getBoundingClientRect();i=s.bottom-s.top}var l=a.line.height-i;if(2>i&&(i=bt(t)),(l>.001||-.001>l)&&(ei(a.line,i),N(a.line),a.rest))for(var u=0;u<a.rest.length;u++)N(a.rest[u])}}}function N(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t)e.widgets[t].height=e.widgets[t].node.parentNode.offsetHeight}function j(e){for(var t=e.display,n={},r={},i=t.gutters.clientLeft,a=t.gutters.firstChild,o=0;a;a=a.nextSibling,++o)n[e.options.gutters[o]]=a.offsetLeft+a.clientLeft+i,r[e.options.gutters[o]]=a.clientWidth;return{fixedPos:C(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:n,gutterWidth:r,wrapperWidth:t.wrapper.clientWidth}}function L(e,t,n){function r(t){var n=t.nextSibling;return $a&&Ea&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),n}for(var i=e.display,a=e.options.lineNumbers,o=i.lineDiv,s=o.firstChild,l=i.view,u=i.viewFrom,c=0;c<l.length;c++){var f=l[c];if(f.hidden);else if(f.node&&f.node.parentNode==o){for(;s!=f.node;)s=r(s);var d=a&&null!=t&&u>=t&&f.lineNumber;f.changes&&(ji(f.changes,"gutter")>-1&&(d=!1),P(e,f,u,n)),d&&(Vi(f.lineNumber),f.lineNumber.appendChild(document.createTextNode(k(e.options,u)))),s=f.node.nextSibling}else{var p=V(e,f,u,n);o.insertBefore(p,s)}u+=f.size}for(;s;)s=r(s)}function P(e,t,n,r){for(var i=0;i<t.changes.length;i++){var a=t.changes[i];"text"==a?_(e,t):"gutter"==a?H(e,t,n,r):"class"==a?R(t):"widget"==a&&U(e,t,r)}t.changes=null}function I(e){return e.node==e.text&&(e.node=Ui("div",null,null,"position: relative"),e.text.parentNode&&e.text.parentNode.replaceChild(e.node,e.text),e.node.appendChild(e.text),ba&&8>ya&&(e.node.style.zIndex=2)),e.node}function F(e){var t=e.bgClass?e.bgClass+" "+(e.line.bgClass||""):e.line.bgClass;if(t&&(t+=" CodeMirror-linebackground"),e.background)t?e.background.className=t:(e.background.parentNode.removeChild(e.background),e.background=null);else if(t){var n=I(e);e.background=n.insertBefore(Ui("div",null,t),n.firstChild)}}function z(e,t){var n=e.display.externalMeasured;return n&&n.line==t.line?(e.display.externalMeasured=null,t.measure=n.measure,n.built):zr(e,t)}function _(e,t){var n=t.text.className,r=z(e,t);t.text==t.node&&(t.node=r.pre),t.text.parentNode.replaceChild(r.pre,t.text),t.text=r.pre,r.bgClass!=t.bgClass||r.textClass!=t.textClass?(t.bgClass=r.bgClass,t.textClass=r.textClass,R(t)):n&&(t.text.className=n)}function R(e){F(e),e.line.wrapClass?I(e).className=e.line.wrapClass:e.node!=e.text&&(e.node.className="");var t=e.textClass?e.textClass+" "+(e.line.textClass||""):e.line.textClass;e.text.className=t||""}function H(e,t,n,r){if(t.gutter&&(t.node.removeChild(t.gutter),t.gutter=null),t.gutterBackground&&(t.node.removeChild(t.gutterBackground),t.gutterBackground=null),t.line.gutterClass){var i=I(t);t.gutterBackground=Ui("div",null,"CodeMirror-gutter-background "+t.line.gutterClass,"left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px; width: "+r.gutterTotalWidth+"px"),i.insertBefore(t.gutterBackground,t.text)}var a=t.line.gutterMarkers;if(e.options.lineNumbers||a){var i=I(t),o=t.gutter=Ui("div",null,"CodeMirror-gutter-wrapper","left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px");if(e.display.input.setUneditable(o),i.insertBefore(o,t.text),t.line.gutterClass&&(o.className+=" "+t.line.gutterClass),!e.options.lineNumbers||a&&a["CodeMirror-linenumbers"]||(t.lineNumber=o.appendChild(Ui("div",k(e.options,n),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+r.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+e.display.lineNumInnerWidth+"px"))),a)for(var s=0;s<e.options.gutters.length;++s){var l=e.options.gutters[s],u=a.hasOwnProperty(l)&&a[l];u&&o.appendChild(Ui("div",[u],"CodeMirror-gutter-elt","left: "+r.gutterLeft[l]+"px; width: "+r.gutterWidth[l]+"px"))}}}function U(e,t,n){t.alignable&&(t.alignable=null);for(var r,i=t.node.firstChild;i;i=r){var r=i.nextSibling;"CodeMirror-linewidget"==i.className&&t.node.removeChild(i)}W(e,t,n)}function V(e,t,n,r){var i=z(e,t);return t.text=t.node=i.pre,i.bgClass&&(t.bgClass=i.bgClass),i.textClass&&(t.textClass=i.textClass),R(t),H(e,t,n,r),W(e,t,r),t.node}function W(e,t,n){if(B(e,t.line,t,n,!0),t.rest)for(var r=0;r<t.rest.length;r++)B(e,t.rest[r],t,n,!1)}function B(e,t,n,r,i){if(t.widgets)for(var a=I(n),o=0,s=t.widgets;o<s.length;++o){var l=s[o],u=Ui("div",[l.node],"CodeMirror-linewidget");l.handleMouseEvents||u.setAttribute("cm-ignore-events","true"),q(l,u,n,r),e.display.input.setUneditable(u),i&&l.above?a.insertBefore(u,n.gutter||n.text):a.appendChild(u),Ci(l,"redraw")}}function q(e,t,n,r){if(e.noHScroll){(n.alignable||(n.alignable=[])).push(t);var i=r.wrapperWidth;t.style.left=r.fixedPos+"px",e.coverGutter||(i-=r.gutterTotalWidth,t.style.paddingLeft=r.gutterTotalWidth+"px"),t.style.width=i+"px"}e.coverGutter&&(t.style.zIndex=5,t.style.position="relative",e.noHScroll||(t.style.marginLeft=-r.gutterTotalWidth+"px"))}function Y(e){return Fa(e.line,e.ch)}function G(e,t){return za(e,t)<0?t:e}function X(e,t){return za(e,t)<0?e:t}function K(e){e.state.focused||(e.display.input.focus(),vn(e))}function J(e,t,n,r,i){var a=e.doc;e.display.shift=!1,r||(r=a.sel);var o=e.state.pasteIncoming||"paste"==i,s=a.splitLines(t),l=null;if(o&&r.ranges.length>1)if(_a&&_a.join("\n")==t){if(r.ranges.length%_a.length==0){l=[];for(var u=0;u<_a.length;u++)l.push(a.splitLines(_a[u]))}}else s.length==r.ranges.length&&(l=Li(s,function(e){return[e]}));for(var u=r.ranges.length-1;u>=0;u--){var c=r.ranges[u],f=c.from(),d=c.to();c.empty()&&(n&&n>0?f=Fa(f.line,f.ch-n):e.state.overwrite&&!o&&(d=Fa(d.line,Math.min(Jr(a,d.line).text.length,d.ch+Ni(s).length))));var p=e.curOp.updateInput,h={from:f,to:d,text:l?l[u%l.length]:s,origin:i||(o?"paste":e.state.cutIncoming?"cut":"+input")};Sn(e.doc,h),Ci(e,"inputRead",e,h)}t&&!o&&Q(e,t),zn(e),e.curOp.updateInput=p,e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=!1}function Z(e,t){var n=e.clipboardData&&e.clipboardData.getData("text/plain");return n?(e.preventDefault(),t.isReadOnly()||t.options.disableInput||Et(t,function(){J(t,n,0,null,"paste")}),!0):void 0}function Q(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var n=e.doc.sel,r=n.ranges.length-1;r>=0;r--){var i=n.ranges[r];if(!(i.head.ch>100||r&&n.ranges[r-1].head.line==i.head.line)){var a=e.getModeAt(i.head),o=!1;if(a.electricChars){for(var s=0;s<a.electricChars.length;s++)if(t.indexOf(a.electricChars.charAt(s))>-1){o=Rn(e,i.head.line,"smart");break}}else a.electricInput&&a.electricInput.test(Jr(e.doc,i.head.line).text.slice(0,i.head.ch))&&(o=Rn(e,i.head.line,"smart"));o&&Ci(e,"electricInput",e,i.head.line)}}}function ee(e){for(var t=[],n=[],r=0;r<e.doc.sel.ranges.length;r++){var i=e.doc.sel.ranges[r].head.line,a={anchor:Fa(i,0),head:Fa(i+1,0)};n.push(a),t.push(e.getRange(a.anchor,a.head))}return{text:t,ranges:n}}function te(e){e.setAttribute("autocorrect","off"),e.setAttribute("autocapitalize","off"),e.setAttribute("spellcheck","false")}function ne(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new Oi,this.inaccurateSelection=!1,this.hasSelection=!1,this.composing=null}function re(){var e=Ui("textarea",null,null,"position: absolute; padding: 0; width: 1px; height: 1em; outline: none"),t=Ui("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return $a?e.style.width="1000px":e.setAttribute("wrap","off"),Ta&&(e.style.border="1px solid black"),te(e),t}function ie(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new Oi,this.gracePeriod=!1}function ae(e,t){var n=Qe(e,t.line);if(!n||n.hidden)return null;var r=Jr(e.doc,t.line),i=Ke(n,r,t.line),a=ii(r),o="left";if(a){var s=ua(a,t.ch);o=s%2?"right":"left"}var l=nt(i.map,t.ch,o);return l.offset="right"==l.collapse?l.end:l.start,l}function oe(e,t){return t&&(e.bad=!0),e}function se(e,t,n){var r;if(t==e.display.lineDiv){if(r=e.display.lineDiv.childNodes[n],!r)return oe(e.clipPos(Fa(e.display.viewTo-1)),!0);t=null,n=0}else for(r=t;;r=r.parentNode){if(!r||r==e.display.lineDiv)return null;if(r.parentNode&&r.parentNode==e.display.lineDiv)break}for(var i=0;i<e.display.view.length;i++){var a=e.display.view[i];if(a.node==r)return le(a,t,n)}}function le(e,t,n){function r(t,n,r){for(var i=-1;i<(c?c.length:0);i++)for(var a=0>i?u.map:c[i],o=0;o<a.length;o+=3){var s=a[o+2];if(s==t||s==n){var l=ti(0>i?e.line:e.rest[i]),f=a[o]+r;return(0>r||s!=t)&&(f=a[o+(r?1:0)]),Fa(l,f)}}}var i=e.text.firstChild,a=!1;if(!t||!Go(i,t))return oe(Fa(ti(e.line),0),!0);if(t==i&&(a=!0,t=i.childNodes[n],n=0,!t)){var o=e.rest?Ni(e.rest):e.line;return oe(Fa(ti(o),o.text.length),a)}var s=3==t.nodeType?t:null,l=t;for(s||1!=t.childNodes.length||3!=t.firstChild.nodeType||(s=t.firstChild,n&&(n=s.nodeValue.length));l.parentNode!=i;)l=l.parentNode;var u=e.measure,c=u.maps,f=r(s,l,n);if(f)return oe(f,a);for(var d=l.nextSibling,p=s?s.nodeValue.length-n:0;d;d=d.nextSibling){if(f=r(d,d.firstChild,0))return oe(Fa(f.line,f.ch-p),a);p+=d.textContent.length}for(var h=l.previousSibling,p=n;h;h=h.previousSibling){if(f=r(h,h.firstChild,-1))return oe(Fa(f.line,f.ch+p),a);p+=d.textContent.length}}function ue(e,t,n,r,i){function a(e){return function(t){return t.id==e}}function o(t){if(1==t.nodeType){var n=t.getAttribute("cm-text");if(null!=n)return""==n&&(n=t.textContent.replace(/\u200b/g,"")),void(s+=n);var c,f=t.getAttribute("cm-marker");if(f){var d=e.findMarks(Fa(r,0),Fa(i+1,0),a(+f));return void(d.length&&(c=d[0].find())&&(s+=Zr(e.doc,c.from,c.to).join(u)))}if("false"==t.getAttribute("contenteditable"))return;for(var p=0;p<t.childNodes.length;p++)o(t.childNodes[p]);/^(pre|div|p)$/i.test(t.nodeName)&&(l=!0)}else if(3==t.nodeType){var h=t.nodeValue;if(!h)return;l&&(s+=u,l=!1),s+=h}}for(var s="",l=!1,u=e.doc.lineSeparator();o(t),t!=n;)t=t.nextSibling;return s}function ce(e,t){this.ranges=e,this.primIndex=t}function fe(e,t){this.anchor=e,this.head=t}function de(e,t){var n=e[t];e.sort(function(e,t){return za(e.from(),t.from())}),t=ji(e,n);for(var r=1;r<e.length;r++){var i=e[r],a=e[r-1];if(za(a.to(),i.from())>=0){var o=X(a.from(),i.from()),s=G(a.to(),i.to()),l=a.empty()?i.from()==i.head:a.from()==a.head;t>=r&&--t,e.splice(--r,2,new fe(l?s:o,l?o:s))}}return new ce(e,t)}function pe(e,t){return new ce([new fe(e,t||e)],0)}function he(e,t){return Math.max(e.first,Math.min(t,e.first+e.size-1))}function me(e,t){if(t.line<e.first)return Fa(e.first,0);var n=e.first+e.size-1;return t.line>n?Fa(n,Jr(e,n).text.length):ge(t,Jr(e,t.line).text.length)}function ge(e,t){var n=e.ch;return null==n||n>t?Fa(e.line,t):0>n?Fa(e.line,0):e}function ve(e,t){return t>=e.first&&t<e.first+e.size}function be(e,t){for(var n=[],r=0;r<t.length;r++)n[r]=me(e,t[r]);return n}function ye(e,t,n,r){if(e.cm&&e.cm.display.shift||e.extend){var i=t.anchor;if(r){var a=za(n,i)<0;a!=za(r,i)<0?(i=n,n=r):a!=za(n,r)<0&&(n=r)}return new fe(i,n)}return new fe(r||n,n)}function $e(e,t,n,r){Se(e,new ce([ye(e,e.sel.primary(),t,n)],0),r)}function we(e,t,n){for(var r=[],i=0;i<e.sel.ranges.length;i++)r[i]=ye(e,e.sel.ranges[i],t[i],null);var a=de(r,e.sel.primIndex);Se(e,a,n)}function xe(e,t,n,r){var i=e.sel.ranges.slice(0);i[t]=n,Se(e,de(i,e.sel.primIndex),r)}function ke(e,t,n,r){Se(e,pe(t,n),r)}function Ce(e,t,n){var r={ranges:t.ranges,update:function(t){this.ranges=[];for(var n=0;n<t.length;n++)this.ranges[n]=new fe(me(e,t[n].anchor),me(e,t[n].head))},origin:n&&n.origin};return jo(e,"beforeSelectionChange",e,r),e.cm&&jo(e.cm,"beforeSelectionChange",e.cm,r),r.ranges!=t.ranges?de(r.ranges,r.ranges.length-1):t}function Me(e,t,n){var r=e.history.done,i=Ni(r);i&&i.ranges?(r[r.length-1]=t,Te(e,t,n)):Se(e,t,n)}function Se(e,t,n){Te(e,t,n),fi(e,e.sel,e.cm?e.cm.curOp.id:NaN,n)}function Te(e,t,n){(Di(e,"beforeSelectionChange")||e.cm&&Di(e.cm,"beforeSelectionChange"))&&(t=Ce(e,t,n));var r=n&&n.bias||(za(t.primary().head,e.sel.primary().head)<0?-1:1);De(e,Oe(e,t,r,!0)),n&&n.scroll===!1||!e.cm||zn(e.cm)}function De(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=e.cm.curOp.selectionChanged=!0,Ti(e.cm)),Ci(e,"cursorActivity",e))}function Ee(e){De(e,Oe(e,e.sel,null,!1),Fo)}function Oe(e,t,n,r){
for(var i,a=0;a<t.ranges.length;a++){var o=t.ranges[a],s=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[a],l=Ne(e,o.anchor,s&&s.anchor,n,r),u=Ne(e,o.head,s&&s.head,n,r);(i||l!=o.anchor||u!=o.head)&&(i||(i=t.ranges.slice(0,a)),i[a]=new fe(l,u))}return i?de(i,t.primIndex):t}function Ae(e,t,n,r,i){var a=Jr(e,t.line);if(a.markedSpans)for(var o=0;o<a.markedSpans.length;++o){var s=a.markedSpans[o],l=s.marker;if((null==s.from||(l.inclusiveLeft?s.from<=t.ch:s.from<t.ch))&&(null==s.to||(l.inclusiveRight?s.to>=t.ch:s.to>t.ch))){if(i&&(jo(l,"beforeCursorEnter"),l.explicitlyCleared)){if(a.markedSpans){--o;continue}break}if(!l.atomic)continue;if(n){var u,c=l.find(0>r?1:-1);if((0>r?l.inclusiveRight:l.inclusiveLeft)&&(c=je(e,c,-r,c&&c.line==t.line?a:null)),c&&c.line==t.line&&(u=za(c,n))&&(0>r?0>u:u>0))return Ae(e,c,t,r,i)}var f=l.find(0>r?-1:1);return(0>r?l.inclusiveLeft:l.inclusiveRight)&&(f=je(e,f,r,f.line==t.line?a:null)),f?Ae(e,f,t,r,i):null}}return t}function Ne(e,t,n,r,i){var a=r||1,o=Ae(e,t,n,a,i)||!i&&Ae(e,t,n,a,!0)||Ae(e,t,n,-a,i)||!i&&Ae(e,t,n,-a,!0);return o?o:(e.cantEdit=!0,Fa(e.first,0))}function je(e,t,n,r){return 0>n&&0==t.ch?t.line>e.first?me(e,Fa(t.line-1)):null:n>0&&t.ch==(r||Jr(e,t.line)).text.length?t.line<e.first+e.size-1?Fa(t.line+1,0):null:new Fa(t.line,t.ch+n)}function Le(e){e.display.input.showSelection(e.display.input.prepareSelection())}function Pe(e,t){for(var n=e.doc,r={},i=r.cursors=document.createDocumentFragment(),a=r.selection=document.createDocumentFragment(),o=0;o<n.sel.ranges.length;o++)if(t!==!1||o!=n.sel.primIndex){var s=n.sel.ranges[o];if(!(s.from().line>=e.display.viewTo||s.to().line<e.display.viewFrom)){var l=s.empty();(l||e.options.showCursorWhenSelecting)&&Ie(e,s.head,i),l||Fe(e,s,a)}}return r}function Ie(e,t,n){var r=pt(e,t,"div",null,null,!e.options.singleCursorHeightPerLine),i=n.appendChild(Ui("div"," ","CodeMirror-cursor"));if(i.style.left=r.left+"px",i.style.top=r.top+"px",i.style.height=Math.max(0,r.bottom-r.top)*e.options.cursorHeight+"px",r.other){var a=n.appendChild(Ui("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));a.style.display="",a.style.left=r.other.left+"px",a.style.top=r.other.top+"px",a.style.height=.85*(r.other.bottom-r.other.top)+"px"}}function Fe(e,t,n){function r(e,t,n,r){0>t&&(t=0),t=Math.round(t),r=Math.round(r),s.appendChild(Ui("div",null,"CodeMirror-selected","position: absolute; left: "+e+"px; top: "+t+"px; width: "+(null==n?c-e:n)+"px; height: "+(r-t)+"px"))}function i(t,n,i){function a(n,r){return dt(e,Fa(t,n),"div",f,r)}var s,l,f=Jr(o,t),d=f.text.length;return ea(ii(f),n||0,null==i?d:i,function(e,t,o){var f,p,h,m=a(e,"left");if(e==t)f=m,p=h=m.left;else{if(f=a(t-1,"right"),"rtl"==o){var g=m;m=f,f=g}p=m.left,h=f.right}null==n&&0==e&&(p=u),f.top-m.top>3&&(r(p,m.top,null,m.bottom),p=u,m.bottom<f.top&&r(p,m.bottom,null,f.top)),null==i&&t==d&&(h=c),(!s||m.top<s.top||m.top==s.top&&m.left<s.left)&&(s=m),(!l||f.bottom>l.bottom||f.bottom==l.bottom&&f.right>l.right)&&(l=f),u+1>p&&(p=u),r(p,f.top,h-p,f.bottom)}),{start:s,end:l}}var a=e.display,o=e.doc,s=document.createDocumentFragment(),l=Be(e.display),u=l.left,c=Math.max(a.sizerWidth,Ye(e)-a.sizer.offsetLeft)-l.right,f=t.from(),d=t.to();if(f.line==d.line)i(f.line,f.ch,d.ch);else{var p=Jr(o,f.line),h=Jr(o,d.line),m=br(p)==br(h),g=i(f.line,f.ch,m?p.text.length+1:null).end,v=i(d.line,m?0:null,d.ch).start;m&&(g.top<v.top-2?(r(g.right,g.top,null,g.bottom),r(u,v.top,v.left,v.bottom)):r(g.right,g.top,v.left-g.right,g.bottom)),g.bottom<v.top&&r(u,g.bottom,null,v.top)}n.appendChild(s)}function ze(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var n=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval(function(){t.cursorDiv.style.visibility=(n=!n)?"":"hidden"},e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function _e(e,t){e.doc.mode.startState&&e.doc.frontier<e.display.viewTo&&e.state.highlight.set(t,zi(Re,e))}function Re(e){var t=e.doc;if(t.frontier<t.first&&(t.frontier=t.first),!(t.frontier>=e.display.viewTo)){var n=+new Date+e.options.workTime,r=so(t.mode,Ue(e,t.frontier)),i=[];t.iter(t.frontier,Math.min(t.first+t.size,e.display.viewTo+500),function(a){if(t.frontier>=e.display.viewFrom){var o=a.styles,s=a.text.length>e.options.maxHighlightLength,l=Lr(e,a,s?so(t.mode,r):r,!0);a.styles=l.styles;var u=a.styleClasses,c=l.classes;c?a.styleClasses=c:u&&(a.styleClasses=null);for(var f=!o||o.length!=a.styles.length||u!=c&&(!u||!c||u.bgClass!=c.bgClass||u.textClass!=c.textClass),d=0;!f&&d<o.length;++d)f=o[d]!=a.styles[d];f&&i.push(t.frontier),a.stateAfter=s?r:so(t.mode,r)}else a.text.length<=e.options.maxHighlightLength&&Ir(e,a.text,r),a.stateAfter=t.frontier%5==0?so(t.mode,r):null;return++t.frontier,+new Date>n?(_e(e,e.options.workDelay),!0):void 0}),i.length&&Et(e,function(){for(var t=0;t<i.length;t++)It(e,i[t],"text")})}}function He(e,t,n){for(var r,i,a=e.doc,o=n?-1:t-(e.doc.mode.innerMode?1e3:100),s=t;s>o;--s){if(s<=a.first)return a.first;var l=Jr(a,s-1);if(l.stateAfter&&(!n||s<=a.frontier))return s;var u=Ro(l.text,null,e.options.tabSize);(null==i||r>u)&&(i=s-1,r=u)}return i}function Ue(e,t,n){var r=e.doc,i=e.display;if(!r.mode.startState)return!0;var a=He(e,t,n),o=a>r.first&&Jr(r,a-1).stateAfter;return o=o?so(r.mode,o):lo(r.mode),r.iter(a,t,function(n){Ir(e,n.text,o);var s=a==t-1||a%5==0||a>=i.viewFrom&&a<i.viewTo;n.stateAfter=s?so(r.mode,o):null,++a}),n&&(r.frontier=a),o}function Ve(e){return e.lineSpace.offsetTop}function We(e){return e.mover.offsetHeight-e.lineSpace.offsetHeight}function Be(e){if(e.cachedPaddingH)return e.cachedPaddingH;var t=Wi(e.measure,Ui("pre","x")),n=window.getComputedStyle?window.getComputedStyle(t):t.currentStyle,r={left:parseInt(n.paddingLeft),right:parseInt(n.paddingRight)};return isNaN(r.left)||isNaN(r.right)||(e.cachedPaddingH=r),r}function qe(e){return Po-e.display.nativeBarWidth}function Ye(e){return e.display.scroller.clientWidth-qe(e)-e.display.barWidth}function Ge(e){return e.display.scroller.clientHeight-qe(e)-e.display.barHeight}function Xe(e,t,n){var r=e.options.lineWrapping,i=r&&Ye(e);if(!t.measure.heights||r&&t.measure.width!=i){var a=t.measure.heights=[];if(r){t.measure.width=i;for(var o=t.text.firstChild.getClientRects(),s=0;s<o.length-1;s++){var l=o[s],u=o[s+1];Math.abs(l.bottom-u.bottom)>2&&a.push((l.bottom+u.top)/2-n.top)}}a.push(n.bottom-n.top)}}function Ke(e,t,n){if(e.line==t)return{map:e.measure.map,cache:e.measure.cache};for(var r=0;r<e.rest.length;r++)if(e.rest[r]==t)return{map:e.measure.maps[r],cache:e.measure.caches[r]};for(var r=0;r<e.rest.length;r++)if(ti(e.rest[r])>n)return{map:e.measure.maps[r],cache:e.measure.caches[r],before:!0}}function Je(e,t){t=br(t);var n=ti(t),r=e.display.externalMeasured=new jt(e.doc,t,n);r.lineN=n;var i=r.built=zr(e,r);return r.text=i.pre,Wi(e.display.lineMeasure,i.pre),r}function Ze(e,t,n,r){return tt(e,et(e,t),n,r)}function Qe(e,t){if(t>=e.display.viewFrom&&t<e.display.viewTo)return e.display.view[zt(e,t)];var n=e.display.externalMeasured;return n&&t>=n.lineN&&t<n.lineN+n.size?n:void 0}function et(e,t){var n=ti(t),r=Qe(e,n);r&&!r.text?r=null:r&&r.changes&&(P(e,r,n,j(e)),e.curOp.forceUpdate=!0),r||(r=Je(e,t));var i=Ke(r,t,n);return{line:t,view:r,rect:null,map:i.map,cache:i.cache,before:i.before,hasHeights:!1}}function tt(e,t,n,r,i){t.before&&(n=-1);var a,o=n+(r||"");return t.cache.hasOwnProperty(o)?a=t.cache[o]:(t.rect||(t.rect=t.view.text.getBoundingClientRect()),t.hasHeights||(Xe(e,t.view,t.rect),t.hasHeights=!0),a=rt(e,t,n,r),a.bogus||(t.cache[o]=a)),{left:a.left,right:a.right,top:i?a.rtop:a.top,bottom:i?a.rbottom:a.bottom}}function nt(e,t,n){for(var r,i,a,o,s=0;s<e.length;s+=3){var l=e[s],u=e[s+1];if(l>t?(i=0,a=1,o="left"):u>t?(i=t-l,a=i+1):(s==e.length-3||t==u&&e[s+3]>t)&&(a=u-l,i=a-1,t>=u&&(o="right")),null!=i){if(r=e[s+2],l==u&&n==(r.insertLeft?"left":"right")&&(o=n),"left"==n&&0==i)for(;s&&e[s-2]==e[s-3]&&e[s-1].insertLeft;)r=e[(s-=3)+2],o="left";if("right"==n&&i==u-l)for(;s<e.length-3&&e[s+3]==e[s+4]&&!e[s+5].insertLeft;)r=e[(s+=3)+2],o="right";break}}return{node:r,start:i,end:a,collapse:o,coverStart:l,coverEnd:u}}function rt(e,t,n,r){var i,a=nt(t.map,n,r),o=a.node,s=a.start,l=a.end,u=a.collapse;if(3==o.nodeType){for(var c=0;4>c;c++){for(;s&&Hi(t.line.text.charAt(a.coverStart+s));)--s;for(;a.coverStart+l<a.coverEnd&&Hi(t.line.text.charAt(a.coverStart+l));)++l;if(ba&&9>ya&&0==s&&l==a.coverEnd-a.coverStart)i=o.parentNode.getBoundingClientRect();else if(ba&&e.options.lineWrapping){var f=Wo(o,s,l).getClientRects();i=f.length?f["right"==r?f.length-1:0]:Va}else i=Wo(o,s,l).getBoundingClientRect()||Va;if(i.left||i.right||0==s)break;l=s,s-=1,u="right"}ba&&11>ya&&(i=it(e.display.measure,i))}else{s>0&&(u=r="right");var f;i=e.options.lineWrapping&&(f=o.getClientRects()).length>1?f["right"==r?f.length-1:0]:o.getBoundingClientRect()}if(ba&&9>ya&&!s&&(!i||!i.left&&!i.right)){var d=o.parentNode.getClientRects()[0];i=d?{left:d.left,right:d.left+yt(e.display),top:d.top,bottom:d.bottom}:Va}for(var p=i.top-t.rect.top,h=i.bottom-t.rect.top,m=(p+h)/2,g=t.view.measure.heights,c=0;c<g.length-1&&!(m<g[c]);c++);var v=c?g[c-1]:0,b=g[c],y={left:("right"==u?i.right:i.left)-t.rect.left,right:("left"==u?i.left:i.right)-t.rect.left,top:v,bottom:b};return i.left||i.right||(y.bogus=!0),e.options.singleCursorHeightPerLine||(y.rtop=p,y.rbottom=h),y}function it(e,t){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!Qi(e))return t;var n=screen.logicalXDPI/screen.deviceXDPI,r=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*n,right:t.right*n,top:t.top*r,bottom:t.bottom*r}}function at(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t<e.rest.length;t++)e.measure.caches[t]={}}function ot(e){e.display.externalMeasure=null,Vi(e.display.lineMeasure);for(var t=0;t<e.display.view.length;t++)at(e.display.view[t])}function st(e){ot(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function lt(){return window.pageXOffset||(document.documentElement||document.body).scrollLeft}function ut(){return window.pageYOffset||(document.documentElement||document.body).scrollTop}function ct(e,t,n,r){if(t.widgets)for(var i=0;i<t.widgets.length;++i)if(t.widgets[i].above){var a=Mr(t.widgets[i]);n.top+=a,n.bottom+=a}if("line"==r)return n;r||(r="local");var o=ri(t);if("local"==r?o+=Ve(e.display):o-=e.display.viewOffset,"page"==r||"window"==r){var s=e.display.lineSpace.getBoundingClientRect();o+=s.top+("window"==r?0:ut());var l=s.left+("window"==r?0:lt());n.left+=l,n.right+=l}return n.top+=o,n.bottom+=o,n}function ft(e,t,n){if("div"==n)return t;var r=t.left,i=t.top;if("page"==n)r-=lt(),i-=ut();else if("local"==n||!n){var a=e.display.sizer.getBoundingClientRect();r+=a.left,i+=a.top}var o=e.display.lineSpace.getBoundingClientRect();return{left:r-o.left,top:i-o.top}}function dt(e,t,n,r,i){return r||(r=Jr(e.doc,t.line)),ct(e,r,Ze(e,r,t.ch,i),n)}function pt(e,t,n,r,i,a){function o(t,o){var s=tt(e,i,t,o?"right":"left",a);return o?s.left=s.right:s.right=s.left,ct(e,r,s,n)}function s(e,t){var n=l[t],r=n.level%2;return e==ta(n)&&t&&n.level<l[t-1].level?(n=l[--t],e=na(n)-(n.level%2?0:1),r=!0):e==na(n)&&t<l.length-1&&n.level<l[t+1].level&&(n=l[++t],e=ta(n)-n.level%2,r=!1),r&&e==n.to&&e>n.from?o(e-1):o(e,r)}r=r||Jr(e.doc,t.line),i||(i=et(e,r));var l=ii(r),u=t.ch;if(!l)return o(u);var c=ua(l,u),f=s(u,c);return null!=os&&(f.other=s(u,os)),f}function ht(e,t){var n=0,t=me(e.doc,t);e.options.lineWrapping||(n=yt(e.display)*t.ch);var r=Jr(e.doc,t.line),i=ri(r)+Ve(e.display);return{left:n,right:n,top:i,bottom:i+r.height}}function mt(e,t,n,r){var i=Fa(e,t);return i.xRel=r,n&&(i.outside=!0),i}function gt(e,t,n){var r=e.doc;if(n+=e.display.viewOffset,0>n)return mt(r.first,0,!0,-1);var i=ni(r,n),a=r.first+r.size-1;if(i>a)return mt(r.first+r.size-1,Jr(r,a).text.length,!0,1);0>t&&(t=0);for(var o=Jr(r,i);;){var s=vt(e,o,i,t,n),l=gr(o),u=l&&l.find(0,!0);if(!l||!(s.ch>u.from.ch||s.ch==u.from.ch&&s.xRel>0))return s;i=ti(o=u.to.line)}}function vt(e,t,n,r,i){function a(r){var i=pt(e,Fa(n,r),"line",t,u);return s=!0,o>i.bottom?i.left-l:o<i.top?i.left+l:(s=!1,i.left)}var o=i-ri(t),s=!1,l=2*e.display.wrapper.clientWidth,u=et(e,t),c=ii(t),f=t.text.length,d=ra(t),p=ia(t),h=a(d),m=s,g=a(p),v=s;if(r>g)return mt(n,p,v,1);for(;;){if(c?p==d||p==fa(t,d,1):1>=p-d){for(var b=h>r||g-r>=r-h?d:p,y=r-(b==d?h:g);Hi(t.text.charAt(b));)++b;var $=mt(n,b,b==d?m:v,-1>y?-1:y>1?1:0);return $}var w=Math.ceil(f/2),x=d+w;if(c){x=d;for(var k=0;w>k;++k)x=fa(t,x,1)}var C=a(x);C>r?(p=x,g=C,(v=s)&&(g+=1e3),f=w):(d=x,h=C,m=s,f-=w)}}function bt(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==Ra){Ra=Ui("pre");for(var t=0;49>t;++t)Ra.appendChild(document.createTextNode("x")),Ra.appendChild(Ui("br"));Ra.appendChild(document.createTextNode("x"))}Wi(e.measure,Ra);var n=Ra.offsetHeight/50;return n>3&&(e.cachedTextHeight=n),Vi(e.measure),n||1}function yt(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=Ui("span","xxxxxxxxxx"),n=Ui("pre",[t]);Wi(e.measure,n);var r=t.getBoundingClientRect(),i=(r.right-r.left)/10;return i>2&&(e.cachedCharWidth=i),i||10}function $t(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:null,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Ba},Wa?Wa.ops.push(e.curOp):e.curOp.ownsGroup=Wa={ops:[e.curOp],delayedCallbacks:[]}}function wt(e){var t=e.delayedCallbacks,n=0;do{for(;n<t.length;n++)t[n].call(null);for(var r=0;r<e.ops.length;r++){var i=e.ops[r];if(i.cursorActivityHandlers)for(;i.cursorActivityCalled<i.cursorActivityHandlers.length;)i.cursorActivityHandlers[i.cursorActivityCalled++].call(null,i.cm)}}while(n<t.length)}function xt(e){var t=e.curOp,n=t.ownsGroup;if(n)try{wt(n)}finally{Wa=null;for(var r=0;r<n.ops.length;r++)n.ops[r].cm.curOp=null;kt(n)}}function kt(e){for(var t=e.ops,n=0;n<t.length;n++)Ct(t[n]);for(var n=0;n<t.length;n++)Mt(t[n]);for(var n=0;n<t.length;n++)St(t[n]);for(var n=0;n<t.length;n++)Tt(t[n]);for(var n=0;n<t.length;n++)Dt(t[n])}function Ct(e){var t=e.cm,n=t.display;S(t),e.updateMaxLine&&d(t),e.mustUpdate=e.viewChanged||e.forceUpdate||null!=e.scrollTop||e.scrollToPos&&(e.scrollToPos.from.line<n.viewFrom||e.scrollToPos.to.line>=n.viewTo)||n.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new M(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Mt(e){e.updatedDisplay=e.mustUpdate&&T(e.cm,e.update)}function St(e){var t=e.cm,n=t.display;e.updatedDisplay&&A(t),e.barMeasure=h(t),n.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=Ze(t,n.maxLine,n.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+e.adjustWidthTo+qe(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+e.adjustWidthTo-Ye(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=n.input.prepareSelection())}function Tt(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&an(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1),e.preparedSelection&&t.display.input.showSelection(e.preparedSelection),(e.updatedDisplay||e.startHeight!=t.doc.height)&&b(t,e.barMeasure),e.updatedDisplay&&O(t,e.barMeasure),e.selectionChanged&&ze(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),!e.focus||e.focus!=Bi()||document.hasFocus&&!document.hasFocus()||K(e.cm)}function Dt(e){var t=e.cm,n=t.display,r=t.doc;if(e.updatedDisplay&&D(t,e.update),null==n.wheelStartX||null==e.scrollTop&&null==e.scrollLeft&&!e.scrollToPos||(n.wheelStartX=n.wheelStartY=null),null==e.scrollTop||n.scroller.scrollTop==e.scrollTop&&!e.forceScroll||(r.scrollTop=Math.max(0,Math.min(n.scroller.scrollHeight-n.scroller.clientHeight,e.scrollTop)),n.scrollbars.setScrollTop(r.scrollTop),n.scroller.scrollTop=r.scrollTop),null==e.scrollLeft||n.scroller.scrollLeft==e.scrollLeft&&!e.forceScroll||(r.scrollLeft=Math.max(0,Math.min(n.scroller.scrollWidth-n.scroller.clientWidth,e.scrollLeft)),n.scrollbars.setScrollLeft(r.scrollLeft),n.scroller.scrollLeft=r.scrollLeft,w(t)),e.scrollToPos){var i=Ln(t,me(r,e.scrollToPos.from),me(r,e.scrollToPos.to),e.scrollToPos.margin);e.scrollToPos.isCursor&&t.state.focused&&jn(t,i)}var a=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(a)for(var s=0;s<a.length;++s)a[s].lines.length||jo(a[s],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&jo(o[s],"unhide");n.wrapper.offsetHeight&&(r.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&jo(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function Et(e,t){if(e.curOp)return t();$t(e);try{return t()}finally{xt(e)}}function Ot(e,t){return function(){if(e.curOp)return t.apply(e,arguments);$t(e);try{return t.apply(e,arguments)}finally{xt(e)}}}function At(e){return function(){if(this.curOp)return e.apply(this,arguments);$t(this);try{return e.apply(this,arguments)}finally{xt(this)}}}function Nt(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);$t(t);try{return e.apply(this,arguments)}finally{xt(t)}}}function jt(e,t,n){this.line=t,this.rest=yr(t),this.size=this.rest?ti(Ni(this.rest))-n+1:1,this.node=this.text=null,this.hidden=xr(e,t)}function Lt(e,t,n){for(var r,i=[],a=t;n>a;a=r){var o=new jt(e.doc,Jr(e.doc,a),a);r=a+o.size,i.push(o)}return i}function Pt(e,t,n,r){null==t&&(t=e.doc.first),null==n&&(n=e.doc.first+e.doc.size),r||(r=0);var i=e.display;if(r&&n<i.viewTo&&(null==i.updateLineNumbers||i.updateLineNumbers>t)&&(i.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=i.viewTo)Ia&&$r(e.doc,t)<i.viewTo&&Ft(e);else if(n<=i.viewFrom)Ia&&wr(e.doc,n+r)>i.viewFrom?Ft(e):(i.viewFrom+=r,i.viewTo+=r);else if(t<=i.viewFrom&&n>=i.viewTo)Ft(e);else if(t<=i.viewFrom){var a=_t(e,n,n+r,1);a?(i.view=i.view.slice(a.index),i.viewFrom=a.lineN,i.viewTo+=r):Ft(e)}else if(n>=i.viewTo){var a=_t(e,t,t,-1);a?(i.view=i.view.slice(0,a.index),i.viewTo=a.lineN):Ft(e)}else{var o=_t(e,t,t,-1),s=_t(e,n,n+r,1);o&&s?(i.view=i.view.slice(0,o.index).concat(Lt(e,o.lineN,s.lineN)).concat(i.view.slice(s.index)),i.viewTo+=r):Ft(e)}var l=i.externalMeasured;l&&(n<l.lineN?l.lineN+=r:t<l.lineN+l.size&&(i.externalMeasured=null))}function It(e,t,n){e.curOp.viewChanged=!0;var r=e.display,i=e.display.externalMeasured;if(i&&t>=i.lineN&&t<i.lineN+i.size&&(r.externalMeasured=null),!(t<r.viewFrom||t>=r.viewTo)){var a=r.view[zt(e,t)];if(null!=a.node){var o=a.changes||(a.changes=[]);-1==ji(o,n)&&o.push(n)}}}function Ft(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function zt(e,t){if(t>=e.display.viewTo)return null;if(t-=e.display.viewFrom,0>t)return null;for(var n=e.display.view,r=0;r<n.length;r++)if(t-=n[r].size,0>t)return r}function _t(e,t,n,r){var i,a=zt(e,t),o=e.display.view;if(!Ia||n==e.doc.first+e.doc.size)return{index:a,lineN:n};for(var s=0,l=e.display.viewFrom;a>s;s++)l+=o[s].size;if(l!=t){if(r>0){if(a==o.length-1)return null;i=l+o[a].size-t,a++}else i=l-t;t+=i,n+=i}for(;$r(e.doc,n)!=n;){if(a==(0>r?0:o.length-1))return null;n+=r*o[a-(0>r?1:0)].size,a+=r}return{index:a,lineN:n}}function Rt(e,t,n){var r=e.display,i=r.view;0==i.length||t>=r.viewTo||n<=r.viewFrom?(r.view=Lt(e,t,n),r.viewFrom=t):(r.viewFrom>t?r.view=Lt(e,t,r.viewFrom).concat(r.view):r.viewFrom<t&&(r.view=r.view.slice(zt(e,t))),r.viewFrom=t,r.viewTo<n?r.view=r.view.concat(Lt(e,r.viewTo,n)):r.viewTo>n&&(r.view=r.view.slice(0,zt(e,n)))),r.viewTo=n}function Ht(e){for(var t=e.display.view,n=0,r=0;r<t.length;r++){var i=t[r];i.hidden||i.node&&!i.changes||++n}return n}function Ut(e){function t(){i.activeTouch&&(a=setTimeout(function(){i.activeTouch=null},1e3),o=i.activeTouch,o.end=+new Date)}function n(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}function r(e,t){if(null==t.left)return!0;var n=t.left-e.left,r=t.top-e.top;return n*n+r*r>400}var i=e.display;Oo(i.scroller,"mousedown",Ot(e,Yt)),ba&&11>ya?Oo(i.scroller,"dblclick",Ot(e,function(t){if(!Si(e,t)){var n=qt(e,t);if(n&&!Zt(e,t)&&!Bt(e.display,t)){To(t);var r=e.findWordAt(n);$e(e.doc,r.anchor,r.head)}}})):Oo(i.scroller,"dblclick",function(t){Si(e,t)||To(t)}),La||Oo(i.scroller,"contextmenu",function(t){yn(e,t)});var a,o={end:0};Oo(i.scroller,"touchstart",function(t){if(!Si(e,t)&&!n(t)){clearTimeout(a);var r=+new Date;i.activeTouch={start:r,moved:!1,prev:r-o.end<=300?o:null},1==t.touches.length&&(i.activeTouch.left=t.touches[0].pageX,i.activeTouch.top=t.touches[0].pageY)}}),Oo(i.scroller,"touchmove",function(){i.activeTouch&&(i.activeTouch.moved=!0)}),Oo(i.scroller,"touchend",function(n){var a=i.activeTouch;if(a&&!Bt(i,n)&&null!=a.left&&!a.moved&&new Date-a.start<300){var o,s=e.coordsChar(i.activeTouch,"page");o=!a.prev||r(a,a.prev)?new fe(s,s):!a.prev.prev||r(a,a.prev.prev)?e.findWordAt(s):new fe(Fa(s.line,0),me(e.doc,Fa(s.line+1,0))),e.setSelection(o.anchor,o.head),e.focus(),To(n)}t()}),Oo(i.scroller,"touchcancel",t),Oo(i.scroller,"scroll",function(){i.scroller.clientHeight&&(rn(e,i.scroller.scrollTop),an(e,i.scroller.scrollLeft,!0),jo(e,"scroll",e))}),Oo(i.scroller,"mousewheel",function(t){on(e,t)}),Oo(i.scroller,"DOMMouseScroll",function(t){on(e,t)}),Oo(i.wrapper,"scroll",function(){i.wrapper.scrollTop=i.wrapper.scrollLeft=0}),i.dragFunctions={enter:function(t){Si(e,t)||Eo(t)},over:function(t){Si(e,t)||(tn(e,t),Eo(t))},start:function(t){en(e,t)},drop:Ot(e,Qt),leave:function(t){Si(e,t)||nn(e)}};var s=i.input.getField();Oo(s,"keyup",function(t){hn.call(e,t)}),Oo(s,"keydown",Ot(e,dn)),Oo(s,"keypress",Ot(e,mn)),Oo(s,"focus",zi(vn,e)),Oo(s,"blur",zi(bn,e))}function Vt(t,n,r){var i=r&&r!=e.Init;if(!n!=!i){var a=t.display.dragFunctions,o=n?Oo:No;o(t.display.scroller,"dragstart",a.start),o(t.display.scroller,"dragenter",a.enter),o(t.display.scroller,"dragover",a.over),o(t.display.scroller,"dragleave",a.leave),o(t.display.scroller,"drop",a.drop)}}function Wt(e){var t=e.display;t.lastWrapHeight==t.wrapper.clientHeight&&t.lastWrapWidth==t.wrapper.clientWidth||(t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize())}function Bt(e,t){for(var n=wi(t);n!=e.wrapper;n=n.parentNode)if(!n||1==n.nodeType&&"true"==n.getAttribute("cm-ignore-events")||n.parentNode==e.sizer&&n!=e.mover)return!0}function qt(e,t,n,r){var i=e.display;if(!n&&"true"==wi(t).getAttribute("cm-not-content"))return null;var a,o,s=i.lineSpace.getBoundingClientRect();try{a=t.clientX-s.left,o=t.clientY-s.top}catch(t){return null}var l,u=gt(e,a,o);if(r&&1==u.xRel&&(l=Jr(e.doc,u.line).text).length==u.ch){var c=Ro(l,l.length,e.options.tabSize)-l.length;u=Fa(u.line,Math.max(0,Math.round((a-Be(e.display).left)/yt(e.display))-c))}return u}function Yt(e){var t=this,n=t.display;if(!(Si(t,e)||n.activeTouch&&n.input.supportsTouch())){if(n.shift=e.shiftKey,Bt(n,e))return void($a||(n.scroller.draggable=!1,setTimeout(function(){n.scroller.draggable=!0},100)));if(!Zt(t,e)){var r=qt(t,e);switch(window.focus(),xi(e)){case 1:t.state.selectingText?t.state.selectingText(e):r?Gt(t,e,r):wi(e)==n.scroller&&To(e);break;case 2:$a&&(t.state.lastMiddleDown=+new Date),r&&$e(t.doc,r),setTimeout(function(){n.input.focus()},20),To(e);break;case 3:La?yn(t,e):gn(t)}}}}function Gt(e,t,n){ba?setTimeout(zi(K,e),0):e.curOp.focus=Bi();var r,i=+new Date;Ua&&Ua.time>i-400&&0==za(Ua.pos,n)?r="triple":Ha&&Ha.time>i-400&&0==za(Ha.pos,n)?(r="double",Ua={time:i,pos:n}):(r="single",Ha={time:i,pos:n});var a,o=e.doc.sel,s=Ea?t.metaKey:t.ctrlKey;e.options.dragDrop&&es&&!e.isReadOnly()&&"single"==r&&(a=o.contains(n))>-1&&(za((a=o.ranges[a]).from(),n)<0||n.xRel>0)&&(za(a.to(),n)>0||n.xRel<0)?Xt(e,t,n,s):Kt(e,t,n,r,s)}function Xt(e,t,n,r){var i=e.display,a=+new Date,o=Ot(e,function(s){$a&&(i.scroller.draggable=!1),e.state.draggingText=!1,No(document,"mouseup",o),No(i.scroller,"drop",o),Math.abs(t.clientX-s.clientX)+Math.abs(t.clientY-s.clientY)<10&&(To(s),!r&&+new Date-200<a&&$e(e.doc,n),$a||ba&&9==ya?setTimeout(function(){document.body.focus(),i.input.focus()},20):i.input.focus())});$a&&(i.scroller.draggable=!0),e.state.draggingText=o,i.scroller.dragDrop&&i.scroller.dragDrop(),Oo(document,"mouseup",o),Oo(i.scroller,"drop",o)}function Kt(e,t,n,r,i){function a(t){if(0!=za(g,t))if(g=t,"rect"==r){for(var i=[],a=e.options.tabSize,o=Ro(Jr(u,n.line).text,n.ch,a),s=Ro(Jr(u,t.line).text,t.ch,a),l=Math.min(o,s),p=Math.max(o,s),h=Math.min(n.line,t.line),m=Math.min(e.lastLine(),Math.max(n.line,t.line));m>=h;h++){var v=Jr(u,h).text,b=Ho(v,l,a);l==p?i.push(new fe(Fa(h,b),Fa(h,b))):v.length>b&&i.push(new fe(Fa(h,b),Fa(h,Ho(v,p,a))))}i.length||i.push(new fe(n,n)),Se(u,de(d.ranges.slice(0,f).concat(i),f),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var y=c,$=y.anchor,w=t;if("single"!=r){if("double"==r)var x=e.findWordAt(t);else var x=new fe(Fa(t.line,0),me(u,Fa(t.line+1,0)));za(x.anchor,$)>0?(w=x.head,$=X(y.from(),x.anchor)):(w=x.anchor,$=G(y.to(),x.head))}var i=d.ranges.slice(0);i[f]=new fe(me(u,$),w),Se(u,de(i,f),zo)}}function o(t){var n=++b,i=qt(e,t,!0,"rect"==r);if(i)if(0!=za(i,g)){e.curOp.focus=Bi(),a(i);var s=$(l,u);(i.line>=s.to||i.line<s.from)&&setTimeout(Ot(e,function(){b==n&&o(t)}),150)}else{var c=t.clientY<v.top?-20:t.clientY>v.bottom?20:0;c&&setTimeout(Ot(e,function(){b==n&&(l.scroller.scrollTop+=c,o(t))}),50)}}function s(t){e.state.selectingText=!1,b=1/0,To(t),l.input.focus(),No(document,"mousemove",y),No(document,"mouseup",w),u.history.lastSelOrigin=null}var l=e.display,u=e.doc;To(t);var c,f,d=u.sel,p=d.ranges;if(i&&!t.shiftKey?(f=u.sel.contains(n),c=f>-1?p[f]:new fe(n,n)):(c=u.sel.primary(),f=u.sel.primIndex),Oa?t.shiftKey&&t.metaKey:t.altKey)r="rect",i||(c=new fe(n,n)),n=qt(e,t,!0,!0),f=-1;else if("double"==r){var h=e.findWordAt(n);c=e.display.shift||u.extend?ye(u,c,h.anchor,h.head):h}else if("triple"==r){var m=new fe(Fa(n.line,0),me(u,Fa(n.line+1,0)));c=e.display.shift||u.extend?ye(u,c,m.anchor,m.head):m}else c=ye(u,c,n);i?-1==f?(f=p.length,Se(u,de(p.concat([c]),f),{scroll:!1,origin:"*mouse"})):p.length>1&&p[f].empty()&&"single"==r&&!t.shiftKey?(Se(u,de(p.slice(0,f).concat(p.slice(f+1)),0),{scroll:!1,origin:"*mouse"}),d=u.sel):xe(u,f,c,zo):(f=0,Se(u,new ce([c],0),zo),d=u.sel);var g=n,v=l.wrapper.getBoundingClientRect(),b=0,y=Ot(e,function(e){xi(e)?o(e):s(e)}),w=Ot(e,s);e.state.selectingText=w,Oo(document,"mousemove",y),Oo(document,"mouseup",w)}function Jt(e,t,n,r){try{var i=t.clientX,a=t.clientY}catch(t){return!1}if(i>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;r&&To(t);var o=e.display,s=o.lineDiv.getBoundingClientRect();if(a>s.bottom||!Di(e,n))return $i(t);a-=s.top-o.viewOffset;for(var l=0;l<e.options.gutters.length;++l){var u=o.gutters.childNodes[l];if(u&&u.getBoundingClientRect().right>=i){var c=ni(e.doc,a),f=e.options.gutters[l];return jo(e,n,e,c,f,t),$i(t)}}}function Zt(e,t){return Jt(e,t,"gutterClick",!0)}function Qt(e){var t=this;if(nn(t),!Si(t,e)&&!Bt(t.display,e)){To(e),ba&&(qa=+new Date);var n=qt(t,e,!0),r=e.dataTransfer.files;if(n&&!t.isReadOnly())if(r&&r.length&&window.FileReader&&window.File)for(var i=r.length,a=Array(i),o=0,s=function(e,r){if(!t.options.allowDropFileTypes||-1!=ji(t.options.allowDropFileTypes,e.type)){var s=new FileReader;s.onload=Ot(t,function(){var e=s.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(e)&&(e=""),a[r]=e,++o==i){n=me(t.doc,n);var l={from:n,to:n,text:t.doc.splitLines(a.join(t.doc.lineSeparator())),origin:"paste"};Sn(t.doc,l),Me(t.doc,pe(n,Za(l)))}}),s.readAsText(e)}},l=0;i>l;++l)s(r[l],l);else{if(t.state.draggingText&&t.doc.sel.contains(n)>-1)return t.state.draggingText(e),void setTimeout(function(){t.display.input.focus()},20);try{var a=e.dataTransfer.getData("Text");if(a){if(t.state.draggingText&&!(Ea?e.altKey:e.ctrlKey))var u=t.listSelections();if(Te(t.doc,pe(n,n)),u)for(var l=0;l<u.length;++l)Nn(t.doc,"",u[l].anchor,u[l].head,"drag");t.replaceSelection(a,"around","paste"),t.display.input.focus()}}catch(e){}}}}function en(e,t){if(ba&&(!e.state.draggingText||+new Date-qa<100))return void Eo(t);if(!Si(e,t)&&!Bt(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!Ca)){var n=Ui("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",ka&&(n.width=n.height=1,e.display.wrapper.appendChild(n),n._top=n.offsetTop),t.dataTransfer.setDragImage(n,0,0),ka&&n.parentNode.removeChild(n)}}function tn(e,t){var n=qt(e,t);if(n){var r=document.createDocumentFragment();Ie(e,n,r),e.display.dragCursor||(e.display.dragCursor=Ui("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),Wi(e.display.dragCursor,r)}}function nn(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function rn(e,t){Math.abs(e.doc.scrollTop-t)<2||(e.doc.scrollTop=t,ma||E(e,{top:t}),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t),e.display.scrollbars.setScrollTop(t),ma&&E(e),_e(e,100))}function an(e,t,n){(n?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)||(t=Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth),e.doc.scrollLeft=t,w(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function on(e,t){var n=Xa(t),r=n.x,i=n.y,a=e.display,o=a.scroller,s=o.scrollWidth>o.clientWidth,l=o.scrollHeight>o.clientHeight;if(r&&s||i&&l){if(i&&Ea&&$a)e:for(var u=t.target,c=a.view;u!=o;u=u.parentNode)for(var f=0;f<c.length;f++)if(c[f].node==u){e.display.currentWheelTarget=u;break e}if(r&&!ma&&!ka&&null!=Ga)return i&&l&&rn(e,Math.max(0,Math.min(o.scrollTop+i*Ga,o.scrollHeight-o.clientHeight))),an(e,Math.max(0,Math.min(o.scrollLeft+r*Ga,o.scrollWidth-o.clientWidth))),(!i||i&&l)&&To(t),void(a.wheelStartX=null);if(i&&null!=Ga){var d=i*Ga,p=e.doc.scrollTop,h=p+a.wrapper.clientHeight;0>d?p=Math.max(0,p+d-50):h=Math.min(e.doc.height,h+d+50),E(e,{top:p,bottom:h})}20>Ya&&(null==a.wheelStartX?(a.wheelStartX=o.scrollLeft,a.wheelStartY=o.scrollTop,a.wheelDX=r,a.wheelDY=i,setTimeout(function(){if(null!=a.wheelStartX){var e=o.scrollLeft-a.wheelStartX,t=o.scrollTop-a.wheelStartY,n=t&&a.wheelDY&&t/a.wheelDY||e&&a.wheelDX&&e/a.wheelDX;a.wheelStartX=a.wheelStartY=null,n&&(Ga=(Ga*Ya+n)/(Ya+1),++Ya)}},200)):(a.wheelDX+=r,a.wheelDY+=i))}}function sn(e,t,n){if("string"==typeof t&&(t=uo[t],!t))return!1;e.display.input.ensurePolled();var r=e.display.shift,i=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),n&&(e.display.shift=!1),i=t(e)!=Io}finally{e.display.shift=r,e.state.suppressEdits=!1}return i}function ln(e,t,n){for(var r=0;r<e.state.keyMaps.length;r++){var i=fo(t,e.state.keyMaps[r],n,e);if(i)return i}return e.options.extraKeys&&fo(t,e.options.extraKeys,n,e)||fo(t,e.options.keyMap,n,e)}function un(e,t,n,r){var i=e.state.keySeq;if(i){if(po(t))return"handled";Ka.set(50,function(){e.state.keySeq==i&&(e.state.keySeq=null,e.display.input.reset())}),t=i+" "+t}var a=ln(e,t,r);return"multi"==a&&(e.state.keySeq=t),"handled"==a&&Ci(e,"keyHandled",e,t,n),"handled"!=a&&"multi"!=a||(To(n),ze(e)),i&&!a&&/\'$/.test(t)?(To(n),!0):!!a}function cn(e,t){var n=ho(t,!0);return n?t.shiftKey&&!e.state.keySeq?un(e,"Shift-"+n,t,function(t){return sn(e,t,!0)})||un(e,n,t,function(t){return("string"==typeof t?/^go[A-Z]/.test(t):t.motion)?sn(e,t):void 0}):un(e,n,t,function(t){return sn(e,t)}):!1}function fn(e,t,n){return un(e,"'"+n+"'",t,function(t){return sn(e,t,!0)})}function dn(e){var t=this;if(t.curOp.focus=Bi(),!Si(t,e)){ba&&11>ya&&27==e.keyCode&&(e.returnValue=!1);var n=e.keyCode;t.display.shift=16==n||e.shiftKey;var r=cn(t,e);ka&&(Ja=r?n:null,!r&&88==n&&!rs&&(Ea?e.metaKey:e.ctrlKey)&&t.replaceSelection("",null,"cut")),
18!=n||/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)||pn(t)}}function pn(e){function t(e){18!=e.keyCode&&e.altKey||(Jo(n,"CodeMirror-crosshair"),No(document,"keyup",t),No(document,"mouseover",t))}var n=e.display.lineDiv;Zo(n,"CodeMirror-crosshair"),Oo(document,"keyup",t),Oo(document,"mouseover",t)}function hn(e){16==e.keyCode&&(this.doc.sel.shift=!1),Si(this,e)}function mn(e){var t=this;if(!(Bt(t.display,e)||Si(t,e)||e.ctrlKey&&!e.altKey||Ea&&e.metaKey)){var n=e.keyCode,r=e.charCode;if(ka&&n==Ja)return Ja=null,void To(e);if(!ka||e.which&&!(e.which<10)||!cn(t,e)){var i=String.fromCharCode(null==r?n:r);fn(t,e,i)||t.display.input.onKeyPress(e)}}}function gn(e){e.state.delayingBlurEvent=!0,setTimeout(function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,bn(e))},100)}function vn(e){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(jo(e,"focus",e),e.state.focused=!0,Zo(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),$a&&setTimeout(function(){e.display.input.reset(!0)},20)),e.display.input.receivedFocus()),ze(e))}function bn(e){e.state.delayingBlurEvent||(e.state.focused&&(jo(e,"blur",e),e.state.focused=!1,Jo(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout(function(){e.state.focused||(e.display.shift=!1)},150))}function yn(e,t){Bt(e.display,t)||$n(e,t)||Si(e,t,"contextmenu")||e.display.input.onContextMenu(t)}function $n(e,t){return Di(e,"gutterContextMenu")?Jt(e,t,"gutterContextMenu",!1):!1}function wn(e,t){if(za(e,t.from)<0)return e;if(za(e,t.to)<=0)return Za(t);var n=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=Za(t).ch-t.to.ch),Fa(n,r)}function xn(e,t){for(var n=[],r=0;r<e.sel.ranges.length;r++){var i=e.sel.ranges[r];n.push(new fe(wn(i.anchor,t),wn(i.head,t)))}return de(n,e.sel.primIndex)}function kn(e,t,n){return e.line==t.line?Fa(n.line,e.ch-t.ch+n.ch):Fa(n.line+(e.line-t.line),e.ch)}function Cn(e,t,n){for(var r=[],i=Fa(e.first,0),a=i,o=0;o<t.length;o++){var s=t[o],l=kn(s.from,i,a),u=kn(Za(s),i,a);if(i=s.to,a=u,"around"==n){var c=e.sel.ranges[o],f=za(c.head,c.anchor)<0;r[o]=new fe(f?u:l,f?l:u)}else r[o]=new fe(l,l)}return new ce(r,e.sel.primIndex)}function Mn(e,t,n){var r={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){this.canceled=!0}};return n&&(r.update=function(t,n,r,i){t&&(this.from=me(e,t)),n&&(this.to=me(e,n)),r&&(this.text=r),void 0!==i&&(this.origin=i)}),jo(e,"beforeChange",e,r),e.cm&&jo(e.cm,"beforeChange",e.cm,r),r.canceled?null:{from:r.from,to:r.to,text:r.text,origin:r.origin}}function Sn(e,t,n){if(e.cm){if(!e.cm.curOp)return Ot(e.cm,Sn)(e,t,n);if(e.cm.state.suppressEdits)return}if(!(Di(e,"beforeChange")||e.cm&&Di(e.cm,"beforeChange"))||(t=Mn(e,t,!0))){var r=Pa&&!n&&lr(e,t.from,t.to);if(r)for(var i=r.length-1;i>=0;--i)Tn(e,{from:r[i].from,to:r[i].to,text:i?[""]:t.text});else Tn(e,t)}}function Tn(e,t){if(1!=t.text.length||""!=t.text[0]||0!=za(t.from,t.to)){var n=xn(e,t);ui(e,t,n,e.cm?e.cm.curOp.id:NaN),On(e,t,n,ar(e,t));var r=[];Xr(e,function(e,n){n||-1!=ji(r,e.history)||(yi(e.history,t),r.push(e.history)),On(e,t,null,ar(e,t))})}}function Dn(e,t,n){if(!e.cm||!e.cm.state.suppressEdits){for(var r,i=e.history,a=e.sel,o="undo"==t?i.done:i.undone,s="undo"==t?i.undone:i.done,l=0;l<o.length&&(r=o[l],n?!r.ranges||r.equals(e.sel):r.ranges);l++);if(l!=o.length){for(i.lastOrigin=i.lastSelOrigin=null;r=o.pop(),r.ranges;){if(di(r,s),n&&!r.equals(e.sel))return void Se(e,r,{clearRedo:!1});a=r}var u=[];di(a,s),s.push({changes:u,generation:i.generation}),i.generation=r.generation||++i.maxGeneration;for(var c=Di(e,"beforeChange")||e.cm&&Di(e.cm,"beforeChange"),l=r.changes.length-1;l>=0;--l){var f=r.changes[l];if(f.origin=t,c&&!Mn(e,f,!1))return void(o.length=0);u.push(oi(e,f));var d=l?xn(e,f):Ni(o);On(e,f,d,sr(e,f)),!l&&e.cm&&e.cm.scrollIntoView({from:f.from,to:Za(f)});var p=[];Xr(e,function(e,t){t||-1!=ji(p,e.history)||(yi(e.history,f),p.push(e.history)),On(e,f,null,sr(e,f))})}}}}function En(e,t){if(0!=t&&(e.first+=t,e.sel=new ce(Li(e.sel.ranges,function(e){return new fe(Fa(e.anchor.line+t,e.anchor.ch),Fa(e.head.line+t,e.head.ch))}),e.sel.primIndex),e.cm)){Pt(e.cm,e.first,e.first-t,t);for(var n=e.cm.display,r=n.viewFrom;r<n.viewTo;r++)It(e.cm,r,"gutter")}}function On(e,t,n,r){if(e.cm&&!e.cm.curOp)return Ot(e.cm,On)(e,t,n,r);if(t.to.line<e.first)return void En(e,t.text.length-1-(t.to.line-t.from.line));if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var i=t.text.length-1-(e.first-t.from.line);En(e,i),t={from:Fa(e.first,0),to:Fa(t.to.line+i,t.to.ch),text:[Ni(t.text)],origin:t.origin}}var a=e.lastLine();t.to.line>a&&(t={from:t.from,to:Fa(a,Jr(e,a).text.length),text:[t.text[0]],origin:t.origin}),t.removed=Zr(e,t.from,t.to),n||(n=xn(e,t)),e.cm?An(e.cm,t,r):qr(e,t,r),Te(e,n,Fo)}}function An(e,t,n){var r=e.doc,i=e.display,o=t.from,s=t.to,l=!1,u=o.line;e.options.lineWrapping||(u=ti(br(Jr(r,o.line))),r.iter(u,s.line+1,function(e){return e==i.maxLine?(l=!0,!0):void 0})),r.sel.contains(t.from,t.to)>-1&&Ti(e),qr(r,t,n,a(e)),e.options.lineWrapping||(r.iter(u,o.line+t.text.length,function(e){var t=f(e);t>i.maxLineLength&&(i.maxLine=e,i.maxLineLength=t,i.maxLineChanged=!0,l=!1)}),l&&(e.curOp.updateMaxLine=!0)),r.frontier=Math.min(r.frontier,o.line),_e(e,400);var c=t.text.length-(s.line-o.line)-1;t.full?Pt(e):o.line!=s.line||1!=t.text.length||Br(e.doc,t)?Pt(e,o.line,s.line+1,c):It(e,o.line,"text");var d=Di(e,"changes"),p=Di(e,"change");if(p||d){var h={from:o,to:s,text:t.text,removed:t.removed,origin:t.origin};p&&Ci(e,"change",e,h),d&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(h)}e.display.selForContextMenu=null}function Nn(e,t,n,r,i){if(r||(r=n),za(r,n)<0){var a=r;r=n,n=a}"string"==typeof t&&(t=e.splitLines(t)),Sn(e,{from:n,to:r,text:t,origin:i})}function jn(e,t){if(!Si(e,"scrollCursorIntoView")){var n=e.display,r=n.sizer.getBoundingClientRect(),i=null;if(t.top+r.top<0?i=!0:t.bottom+r.top>(window.innerHeight||document.documentElement.clientHeight)&&(i=!1),null!=i&&!Sa){var a=Ui("div","",null,"position: absolute; top: "+(t.top-n.viewOffset-Ve(e.display))+"px; height: "+(t.bottom-t.top+qe(e)+n.barHeight)+"px; left: "+t.left+"px; width: 2px;");e.display.lineSpace.appendChild(a),a.scrollIntoView(i),e.display.lineSpace.removeChild(a)}}}function Ln(e,t,n,r){null==r&&(r=0);for(var i=0;5>i;i++){var a=!1,o=pt(e,t),s=n&&n!=t?pt(e,n):o,l=In(e,Math.min(o.left,s.left),Math.min(o.top,s.top)-r,Math.max(o.left,s.left),Math.max(o.bottom,s.bottom)+r),u=e.doc.scrollTop,c=e.doc.scrollLeft;if(null!=l.scrollTop&&(rn(e,l.scrollTop),Math.abs(e.doc.scrollTop-u)>1&&(a=!0)),null!=l.scrollLeft&&(an(e,l.scrollLeft),Math.abs(e.doc.scrollLeft-c)>1&&(a=!0)),!a)break}return o}function Pn(e,t,n,r,i){var a=In(e,t,n,r,i);null!=a.scrollTop&&rn(e,a.scrollTop),null!=a.scrollLeft&&an(e,a.scrollLeft)}function In(e,t,n,r,i){var a=e.display,o=bt(e.display);0>n&&(n=0);var s=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:a.scroller.scrollTop,l=Ge(e),u={};i-n>l&&(i=n+l);var c=e.doc.height+We(a),f=o>n,d=i>c-o;if(s>n)u.scrollTop=f?0:n;else if(i>s+l){var p=Math.min(n,(d?c:i)-l);p!=s&&(u.scrollTop=p)}var h=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:a.scroller.scrollLeft,m=Ye(e)-(e.options.fixedGutter?a.gutters.offsetWidth:0),g=r-t>m;return g&&(r=t+m),10>t?u.scrollLeft=0:h>t?u.scrollLeft=Math.max(0,t-(g?0:10)):r>m+h-3&&(u.scrollLeft=r+(g?0:10)-m),u}function Fn(e,t,n){null==t&&null==n||_n(e),null!=t&&(e.curOp.scrollLeft=(null==e.curOp.scrollLeft?e.doc.scrollLeft:e.curOp.scrollLeft)+t),null!=n&&(e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+n)}function zn(e){_n(e);var t=e.getCursor(),n=t,r=t;e.options.lineWrapping||(n=t.ch?Fa(t.line,t.ch-1):t,r=Fa(t.line,t.ch+1)),e.curOp.scrollToPos={from:n,to:r,margin:e.options.cursorScrollMargin,isCursor:!0}}function _n(e){var t=e.curOp.scrollToPos;if(t){e.curOp.scrollToPos=null;var n=ht(e,t.from),r=ht(e,t.to),i=In(e,Math.min(n.left,r.left),Math.min(n.top,r.top)-t.margin,Math.max(n.right,r.right),Math.max(n.bottom,r.bottom)+t.margin);e.scrollTo(i.scrollLeft,i.scrollTop)}}function Rn(e,t,n,r){var i,a=e.doc;null==n&&(n="add"),"smart"==n&&(a.mode.indent?i=Ue(e,t):n="prev");var o=e.options.tabSize,s=Jr(a,t),l=Ro(s.text,null,o);s.stateAfter&&(s.stateAfter=null);var u,c=s.text.match(/^\s*/)[0];if(r||/\S/.test(s.text)){if("smart"==n&&(u=a.mode.indent(i,s.text.slice(c.length),s.text),u==Io||u>150)){if(!r)return;n="prev"}}else u=0,n="not";"prev"==n?u=t>a.first?Ro(Jr(a,t-1).text,null,o):0:"add"==n?u=l+e.options.indentUnit:"subtract"==n?u=l-e.options.indentUnit:"number"==typeof n&&(u=l+n),u=Math.max(0,u);var f="",d=0;if(e.options.indentWithTabs)for(var p=Math.floor(u/o);p;--p)d+=o,f+=" ";if(u>d&&(f+=Ai(u-d)),f!=c)return Nn(a,f,Fa(t,0),Fa(t,c.length),"+input"),s.stateAfter=null,!0;for(var p=0;p<a.sel.ranges.length;p++){var h=a.sel.ranges[p];if(h.head.line==t&&h.head.ch<c.length){var d=Fa(t,c.length);xe(a,p,new fe(d,d));break}}}function Hn(e,t,n,r){var i=t,a=t;return"number"==typeof t?a=Jr(e,he(e,t)):i=ti(t),null==i?null:(r(a,i)&&e.cm&&It(e.cm,i,n),a)}function Un(e,t){for(var n=e.doc.sel.ranges,r=[],i=0;i<n.length;i++){for(var a=t(n[i]);r.length&&za(a.from,Ni(r).to)<=0;){var o=r.pop();if(za(o.from,a.from)<0){a.from=o.from;break}}r.push(a)}Et(e,function(){for(var t=r.length-1;t>=0;t--)Nn(e.doc,"",r[t].from,r[t].to,"+delete");zn(e)})}function Vn(e,t,n,r,i){function a(){var t=s+n;return t<e.first||t>=e.first+e.size?!1:(s=t,c=Jr(e,t))}function o(e){var t=(i?fa:da)(c,l,n,!0);if(null==t){if(e||!a())return!1;l=i?(0>n?ia:ra)(c):0>n?c.text.length:0}else l=t;return!0}var s=t.line,l=t.ch,u=n,c=Jr(e,s);if("char"==r)o();else if("column"==r)o(!0);else if("word"==r||"group"==r)for(var f=null,d="group"==r,p=e.cm&&e.cm.getHelper(t,"wordChars"),h=!0;!(0>n)||o(!h);h=!1){var m=c.text.charAt(l)||"\n",g=_i(m,p)?"w":d&&"\n"==m?"n":!d||/\s/.test(m)?null:"p";if(!d||h||g||(g="s"),f&&f!=g){0>n&&(n=1,o());break}if(g&&(f=g),n>0&&!o(!h))break}var v=Ne(e,Fa(s,l),t,u,!0);return za(t,v)||(v.hitSide=!0),v}function Wn(e,t,n,r){var i,a=e.doc,o=t.left;if("page"==r){var s=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight);i=t.top+n*(s-(0>n?1.5:.5)*bt(e.display))}else"line"==r&&(i=n>0?t.bottom+3:t.top-3);for(;;){var l=gt(e,o,i);if(!l.outside)break;if(0>n?0>=i:i>=a.height){l.hitSide=!0;break}i+=5*n}return l}function Bn(t,n,r,i){e.defaults[t]=n,r&&(eo[t]=i?function(e,t,n){n!=to&&r(e,t,n)}:r)}function qn(e){for(var t,n,r,i,a=e.split(/-(?!$)/),e=a[a.length-1],o=0;o<a.length-1;o++){var s=a[o];if(/^(cmd|meta|m)$/i.test(s))i=!0;else if(/^a(lt)?$/i.test(s))t=!0;else if(/^(c|ctrl|control)$/i.test(s))n=!0;else{if(!/^s(hift)$/i.test(s))throw new Error("Unrecognized modifier name: "+s);r=!0}}return t&&(e="Alt-"+e),n&&(e="Ctrl-"+e),i&&(e="Cmd-"+e),r&&(e="Shift-"+e),e}function Yn(e){return"string"==typeof e?co[e]:e}function Gn(e,t,n,r,i){if(r&&r.shared)return Xn(e,t,n,r,i);if(e.cm&&!e.cm.curOp)return Ot(e.cm,Gn)(e,t,n,r,i);var a=new vo(e,i),o=za(t,n);if(r&&Fi(r,a,!1),o>0||0==o&&a.clearWhenEmpty!==!1)return a;if(a.replacedWith&&(a.collapsed=!0,a.widgetNode=Ui("span",[a.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||a.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(a.widgetNode.insertLeft=!0)),a.collapsed){if(vr(e,t.line,t,n,a)||t.line!=n.line&&vr(e,n.line,t,n,a))throw new Error("Inserting collapsed marker partially overlapping an existing one");Ia=!0}a.addToHistory&&ui(e,{from:t,to:n,origin:"markText"},e.sel,NaN);var s,l=t.line,u=e.cm;if(e.iter(l,n.line+1,function(e){u&&a.collapsed&&!u.options.lineWrapping&&br(e)==u.display.maxLine&&(s=!0),a.collapsed&&l!=t.line&&ei(e,0),nr(e,new Qn(a,l==t.line?t.ch:null,l==n.line?n.ch:null)),++l}),a.collapsed&&e.iter(t.line,n.line+1,function(t){xr(e,t)&&ei(t,0)}),a.clearOnEnter&&Oo(a,"beforeCursorEnter",function(){a.clear()}),a.readOnly&&(Pa=!0,(e.history.done.length||e.history.undone.length)&&e.clearHistory()),a.collapsed&&(a.id=++go,a.atomic=!0),u){if(s&&(u.curOp.updateMaxLine=!0),a.collapsed)Pt(u,t.line,n.line+1);else if(a.className||a.title||a.startStyle||a.endStyle||a.css)for(var c=t.line;c<=n.line;c++)It(u,c,"text");a.atomic&&Ee(u.doc),Ci(u,"markerAdded",u,a)}return a}function Xn(e,t,n,r,i){r=Fi(r),r.shared=!1;var a=[Gn(e,t,n,r,i)],o=a[0],s=r.widgetNode;return Xr(e,function(e){s&&(r.widgetNode=s.cloneNode(!0)),a.push(Gn(e,me(e,t),me(e,n),r,i));for(var l=0;l<e.linked.length;++l)if(e.linked[l].isParent)return;o=Ni(a)}),new bo(a,o)}function Kn(e){return e.findMarks(Fa(e.first,0),e.clipPos(Fa(e.lastLine())),function(e){return e.parent})}function Jn(e,t){for(var n=0;n<t.length;n++){var r=t[n],i=r.find(),a=e.clipPos(i.from),o=e.clipPos(i.to);if(za(a,o)){var s=Gn(e,a,o,r.primary,r.primary.type);r.markers.push(s),s.parent=r}}}function Zn(e){for(var t=0;t<e.length;t++){var n=e[t],r=[n.primary.doc];Xr(n.primary.doc,function(e){r.push(e)});for(var i=0;i<n.markers.length;i++){var a=n.markers[i];-1==ji(r,a.doc)&&(a.parent=null,n.markers.splice(i--,1))}}}function Qn(e,t,n){this.marker=e,this.from=t,this.to=n}function er(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];if(r.marker==t)return r}}function tr(e,t){for(var n,r=0;r<e.length;++r)e[r]!=t&&(n||(n=[])).push(e[r]);return n}function nr(e,t){e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],t.marker.attachLine(e)}function rr(e,t,n){if(e)for(var r,i=0;i<e.length;++i){var a=e[i],o=a.marker,s=null==a.from||(o.inclusiveLeft?a.from<=t:a.from<t);if(s||a.from==t&&"bookmark"==o.type&&(!n||!a.marker.insertLeft)){var l=null==a.to||(o.inclusiveRight?a.to>=t:a.to>t);(r||(r=[])).push(new Qn(o,a.from,l?null:a.to))}}return r}function ir(e,t,n){if(e)for(var r,i=0;i<e.length;++i){var a=e[i],o=a.marker,s=null==a.to||(o.inclusiveRight?a.to>=t:a.to>t);if(s||a.from==t&&"bookmark"==o.type&&(!n||a.marker.insertLeft)){var l=null==a.from||(o.inclusiveLeft?a.from<=t:a.from<t);(r||(r=[])).push(new Qn(o,l?null:a.from-t,null==a.to?null:a.to-t))}}return r}function ar(e,t){if(t.full)return null;var n=ve(e,t.from.line)&&Jr(e,t.from.line).markedSpans,r=ve(e,t.to.line)&&Jr(e,t.to.line).markedSpans;if(!n&&!r)return null;var i=t.from.ch,a=t.to.ch,o=0==za(t.from,t.to),s=rr(n,i,o),l=ir(r,a,o),u=1==t.text.length,c=Ni(t.text).length+(u?i:0);if(s)for(var f=0;f<s.length;++f){var d=s[f];if(null==d.to){var p=er(l,d.marker);p?u&&(d.to=null==p.to?null:p.to+c):d.to=i}}if(l)for(var f=0;f<l.length;++f){var d=l[f];if(null!=d.to&&(d.to+=c),null==d.from){var p=er(s,d.marker);p||(d.from=c,u&&(s||(s=[])).push(d))}else d.from+=c,u&&(s||(s=[])).push(d)}s&&(s=or(s)),l&&l!=s&&(l=or(l));var h=[s];if(!u){var m,g=t.text.length-2;if(g>0&&s)for(var f=0;f<s.length;++f)null==s[f].to&&(m||(m=[])).push(new Qn(s[f].marker,null,null));for(var f=0;g>f;++f)h.push(m);h.push(l)}return h}function or(e){for(var t=0;t<e.length;++t){var n=e[t];null!=n.from&&n.from==n.to&&n.marker.clearWhenEmpty!==!1&&e.splice(t--,1)}return e.length?e:null}function sr(e,t){var n=mi(e,t),r=ar(e,t);if(!n)return r;if(!r)return n;for(var i=0;i<n.length;++i){var a=n[i],o=r[i];if(a&&o)e:for(var s=0;s<o.length;++s){for(var l=o[s],u=0;u<a.length;++u)if(a[u].marker==l.marker)continue e;a.push(l)}else o&&(n[i]=o)}return n}function lr(e,t,n){var r=null;if(e.iter(t.line,n.line+1,function(e){if(e.markedSpans)for(var t=0;t<e.markedSpans.length;++t){var n=e.markedSpans[t].marker;!n.readOnly||r&&-1!=ji(r,n)||(r||(r=[])).push(n)}}),!r)return null;for(var i=[{from:t,to:n}],a=0;a<r.length;++a)for(var o=r[a],s=o.find(0),l=0;l<i.length;++l){var u=i[l];if(!(za(u.to,s.from)<0||za(u.from,s.to)>0)){var c=[l,1],f=za(u.from,s.from),d=za(u.to,s.to);(0>f||!o.inclusiveLeft&&!f)&&c.push({from:u.from,to:s.from}),(d>0||!o.inclusiveRight&&!d)&&c.push({from:s.to,to:u.to}),i.splice.apply(i,c),l+=c.length-1}}return i}function ur(e){var t=e.markedSpans;if(t){for(var n=0;n<t.length;++n)t[n].marker.detachLine(e);e.markedSpans=null}}function cr(e,t){if(t){for(var n=0;n<t.length;++n)t[n].marker.attachLine(e);e.markedSpans=t}}function fr(e){return e.inclusiveLeft?-1:0}function dr(e){return e.inclusiveRight?1:0}function pr(e,t){var n=e.lines.length-t.lines.length;if(0!=n)return n;var r=e.find(),i=t.find(),a=za(r.from,i.from)||fr(e)-fr(t);if(a)return-a;var o=za(r.to,i.to)||dr(e)-dr(t);return o?o:t.id-e.id}function hr(e,t){var n,r=Ia&&e.markedSpans;if(r)for(var i,a=0;a<r.length;++a)i=r[a],i.marker.collapsed&&null==(t?i.from:i.to)&&(!n||pr(n,i.marker)<0)&&(n=i.marker);return n}function mr(e){return hr(e,!0)}function gr(e){return hr(e,!1)}function vr(e,t,n,r,i){var a=Jr(e,t),o=Ia&&a.markedSpans;if(o)for(var s=0;s<o.length;++s){var l=o[s];if(l.marker.collapsed){var u=l.marker.find(0),c=za(u.from,n)||fr(l.marker)-fr(i),f=za(u.to,r)||dr(l.marker)-dr(i);if(!(c>=0&&0>=f||0>=c&&f>=0)&&(0>=c&&(za(u.to,n)>0||l.marker.inclusiveRight&&i.inclusiveLeft)||c>=0&&(za(u.from,r)<0||l.marker.inclusiveLeft&&i.inclusiveRight)))return!0}}}function br(e){for(var t;t=mr(e);)e=t.find(-1,!0).line;return e}function yr(e){for(var t,n;t=gr(e);)e=t.find(1,!0).line,(n||(n=[])).push(e);return n}function $r(e,t){var n=Jr(e,t),r=br(n);return n==r?t:ti(r)}function wr(e,t){if(t>e.lastLine())return t;var n,r=Jr(e,t);if(!xr(e,r))return t;for(;n=gr(r);)r=n.find(1,!0).line;return ti(r)+1}function xr(e,t){var n=Ia&&t.markedSpans;if(n)for(var r,i=0;i<n.length;++i)if(r=n[i],r.marker.collapsed){if(null==r.from)return!0;if(!r.marker.widgetNode&&0==r.from&&r.marker.inclusiveLeft&&kr(e,t,r))return!0}}function kr(e,t,n){if(null==n.to){var r=n.marker.find(1,!0);return kr(e,r.line,er(r.line.markedSpans,n.marker))}if(n.marker.inclusiveRight&&n.to==t.text.length)return!0;for(var i,a=0;a<t.markedSpans.length;++a)if(i=t.markedSpans[a],i.marker.collapsed&&!i.marker.widgetNode&&i.from==n.to&&(null==i.to||i.to!=n.from)&&(i.marker.inclusiveLeft||n.marker.inclusiveRight)&&kr(e,t,i))return!0}function Cr(e,t,n){ri(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&Fn(e,null,n)}function Mr(e){if(null!=e.height)return e.height;var t=e.doc.cm;if(!t)return 0;if(!Go(document.body,e.node)){var n="position: relative;";e.coverGutter&&(n+="margin-left: -"+t.display.gutters.offsetWidth+"px;"),e.noHScroll&&(n+="width: "+t.display.wrapper.clientWidth+"px;"),Wi(t.display.measure,Ui("div",[e.node],null,n))}return e.height=e.node.parentNode.offsetHeight}function Sr(e,t,n,r){var i=new yo(e,n,r),a=e.cm;return a&&i.noHScroll&&(a.display.alignWidgets=!0),Hn(e,t,"widget",function(t){var n=t.widgets||(t.widgets=[]);if(null==i.insertAt?n.push(i):n.splice(Math.min(n.length-1,Math.max(0,i.insertAt)),0,i),i.line=t,a&&!xr(e,t)){var r=ri(t)<e.scrollTop;ei(t,t.height+Mr(i)),r&&Fn(a,null,i.height),a.curOp.forceUpdate=!0}return!0}),i}function Tr(e,t,n,r){e.text=t,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),null!=e.order&&(e.order=null),ur(e),cr(e,n);var i=r?r(e):1;i!=e.height&&ei(e,i)}function Dr(e){e.parent=null,ur(e)}function Er(e,t){if(e)for(;;){var n=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!n)break;e=e.slice(0,n.index)+e.slice(n.index+n[0].length);var r=n[1]?"bgClass":"textClass";null==t[r]?t[r]=n[2]:new RegExp("(?:^|s)"+n[2]+"(?:$|s)").test(t[r])||(t[r]+=" "+n[2])}return e}function Or(t,n){if(t.blankLine)return t.blankLine(n);if(t.innerMode){var r=e.innerMode(t,n);return r.mode.blankLine?r.mode.blankLine(r.state):void 0}}function Ar(t,n,r,i){for(var a=0;10>a;a++){i&&(i[0]=e.innerMode(t,r).mode);var o=t.token(n,r);if(n.pos>n.start)return o}throw new Error("Mode "+t.name+" failed to advance stream.")}function Nr(e,t,n,r){function i(e){return{start:f.start,end:f.pos,string:f.current(),type:a||null,state:e?so(o.mode,c):c}}var a,o=e.doc,s=o.mode;t=me(o,t);var l,u=Jr(o,t.line),c=Ue(e,t.line,n),f=new mo(u.text,e.options.tabSize);for(r&&(l=[]);(r||f.pos<t.ch)&&!f.eol();)f.start=f.pos,a=Ar(s,f,c),r&&l.push(i(!0));return r?l:i()}function jr(e,t,n,r,i,a,o){var s=n.flattenSpans;null==s&&(s=e.options.flattenSpans);var l,u=0,c=null,f=new mo(t,e.options.tabSize),d=e.options.addModeClass&&[null];for(""==t&&Er(Or(n,r),a);!f.eol();){if(f.pos>e.options.maxHighlightLength?(s=!1,o&&Ir(e,t,r,f.pos),f.pos=t.length,l=null):l=Er(Ar(n,f,r,d),a),d){var p=d[0].name;p&&(l="m-"+(l?p+" "+l:p))}if(!s||c!=l){for(;u<f.start;)u=Math.min(f.start,u+5e4),i(u,c);c=l}f.start=f.pos}for(;u<f.pos;){var h=Math.min(f.pos,u+5e4);i(h,c),u=h}}function Lr(e,t,n,r){var i=[e.state.modeGen],a={};jr(e,t.text,e.doc.mode,n,function(e,t){i.push(e,t)},a,r);for(var o=0;o<e.state.overlays.length;++o){var s=e.state.overlays[o],l=1,u=0;jr(e,t.text,s.mode,!0,function(e,t){for(var n=l;e>u;){var r=i[l];r>e&&i.splice(l,1,e,i[l+1],r),l+=2,u=Math.min(e,r)}if(t)if(s.opaque)i.splice(n,l-n,e,"cm-overlay "+t),l=n+2;else for(;l>n;n+=2){var a=i[n+1];i[n+1]=(a?a+" ":"")+"cm-overlay "+t}},a)}return{styles:i,classes:a.bgClass||a.textClass?a:null}}function Pr(e,t,n){if(!t.styles||t.styles[0]!=e.state.modeGen){var r=Ue(e,ti(t)),i=Lr(e,t,t.text.length>e.options.maxHighlightLength?so(e.doc.mode,r):r);t.stateAfter=r,t.styles=i.styles,i.classes?t.styleClasses=i.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.frontier&&e.doc.frontier++}return t.styles}function Ir(e,t,n,r){var i=e.doc.mode,a=new mo(t,e.options.tabSize);for(a.start=a.pos=r||0,""==t&&Or(i,n);!a.eol();)Ar(i,a,n),a.start=a.pos}function Fr(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?xo:wo;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function zr(e,t){var n=Ui("span",null,null,$a?"padding-right: .1px":null),r={pre:Ui("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,splitSpaces:(ba||$a)&&e.getOption("lineWrapping")};t.measure={};for(var i=0;i<=(t.rest?t.rest.length:0);i++){var a,o=i?t.rest[i-1]:t.line;r.pos=0,r.addToken=Rr,Zi(e.display.measure)&&(a=ii(o))&&(r.addToken=Ur(r.addToken,a)),r.map=[];var s=t!=e.display.externalMeasured&&ti(o);Wr(o,r,Pr(e,o,s)),o.styleClasses&&(o.styleClasses.bgClass&&(r.bgClass=Yi(o.styleClasses.bgClass,r.bgClass||"")),o.styleClasses.textClass&&(r.textClass=Yi(o.styleClasses.textClass,r.textClass||""))),0==r.map.length&&r.map.push(0,0,r.content.appendChild(Ji(e.display.measure))),0==i?(t.measure.map=r.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(r.map),(t.measure.caches||(t.measure.caches=[])).push({}))}return $a&&/\bcm-tab\b/.test(r.content.lastChild.className)&&(r.content.className="cm-tab-wrap-hack"),jo(e,"renderLine",e,t.line,r.pre),r.pre.className&&(r.textClass=Yi(r.pre.className,r.textClass||"")),r}function _r(e){var t=Ui("span","•","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function Rr(e,t,n,r,i,a,o){if(t){var s=e.splitSpaces?t.replace(/ {3,}/g,Hr):t,l=e.cm.state.specialChars,u=!1;if(l.test(t))for(var c=document.createDocumentFragment(),f=0;;){l.lastIndex=f;var d=l.exec(t),p=d?d.index-f:t.length-f;if(p){var h=document.createTextNode(s.slice(f,f+p));ba&&9>ya?c.appendChild(Ui("span",[h])):c.appendChild(h),e.map.push(e.pos,e.pos+p,h),e.col+=p,e.pos+=p}if(!d)break;if(f+=p+1," "==d[0]){var m=e.cm.options.tabSize,g=m-e.col%m,h=c.appendChild(Ui("span",Ai(g),"cm-tab"));h.setAttribute("role","presentation"),h.setAttribute("cm-text"," "),e.col+=g}else if("\r"==d[0]||"\n"==d[0]){var h=c.appendChild(Ui("span","\r"==d[0]?"␍":"␤","cm-invalidchar"));h.setAttribute("cm-text",d[0]),e.col+=1}else{var h=e.cm.options.specialCharPlaceholder(d[0]);h.setAttribute("cm-text",d[0]),ba&&9>ya?c.appendChild(Ui("span",[h])):c.appendChild(h),e.col+=1}e.map.push(e.pos,e.pos+1,h),e.pos++}else{e.col+=t.length;var c=document.createTextNode(s);e.map.push(e.pos,e.pos+t.length,c),ba&&9>ya&&(u=!0),e.pos+=t.length}if(n||r||i||u||o){var v=n||"";r&&(v+=r),i&&(v+=i);var b=Ui("span",[c],v,o);return a&&(b.title=a),e.content.appendChild(b)}e.content.appendChild(c)}}function Hr(e){for(var t=" ",n=0;n<e.length-2;++n)t+=n%2?" ":" ";return t+=" "}function Ur(e,t){return function(n,r,i,a,o,s,l){i=i?i+" cm-force-border":"cm-force-border";for(var u=n.pos,c=u+r.length;;){for(var f=0;f<t.length;f++){var d=t[f];if(d.to>u&&d.from<=u)break}if(d.to>=c)return e(n,r,i,a,o,s,l);e(n,r.slice(0,d.to-u),i,a,null,s,l),a=null,r=r.slice(d.to-u),u=d.to}}}function Vr(e,t,n,r){var i=!r&&n.widgetNode;i&&e.map.push(e.pos,e.pos+t,i),!r&&e.cm.display.input.needsContentAttribute&&(i||(i=e.content.appendChild(document.createElement("span"))),i.setAttribute("cm-marker",n.id)),i&&(e.cm.display.input.setUneditable(i),e.content.appendChild(i)),e.pos+=t}function Wr(e,t,n){var r=e.markedSpans,i=e.text,a=0;if(r)for(var o,s,l,u,c,f,d,p=i.length,h=0,m=1,g="",v=0;;){if(v==h){l=u=c=f=s="",d=null,v=1/0;for(var b,y=[],$=0;$<r.length;++$){var w=r[$],x=w.marker;"bookmark"==x.type&&w.from==h&&x.widgetNode?y.push(x):w.from<=h&&(null==w.to||w.to>h||x.collapsed&&w.to==h&&w.from==h)?(null!=w.to&&w.to!=h&&v>w.to&&(v=w.to,u=""),x.className&&(l+=" "+x.className),x.css&&(s=(s?s+";":"")+x.css),x.startStyle&&w.from==h&&(c+=" "+x.startStyle),x.endStyle&&w.to==v&&(b||(b=[])).push(x.endStyle,w.to),x.title&&!f&&(f=x.title),x.collapsed&&(!d||pr(d.marker,x)<0)&&(d=w)):w.from>h&&v>w.from&&(v=w.from)}if(b)for(var $=0;$<b.length;$+=2)b[$+1]==v&&(u+=" "+b[$]);if(!d||d.from==h)for(var $=0;$<y.length;++$)Vr(t,0,y[$]);if(d&&(d.from||0)==h){if(Vr(t,(null==d.to?p+1:d.to)-h,d.marker,null==d.from),null==d.to)return;d.to==h&&(d=!1)}}if(h>=p)break;for(var k=Math.min(p,v);;){if(g){var C=h+g.length;if(!d){var M=C>k?g.slice(0,k-h):g;t.addToken(t,M,o?o+l:l,c,h+M.length==v?u:"",f,s)}if(C>=k){g=g.slice(k-h),h=k;break}h=C,c=""}g=i.slice(a,a=n[m++]),o=Fr(n[m++],t.cm.options)}}else for(var m=1;m<n.length;m+=2)t.addToken(t,i.slice(a,a=n[m]),Fr(n[m+1],t.cm.options))}function Br(e,t){return 0==t.from.ch&&0==t.to.ch&&""==Ni(t.text)&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function qr(e,t,n,r){function i(e){return n?n[e]:null}function a(e,n,i){Tr(e,n,i,r),Ci(e,"change",e,t)}function o(e,t){for(var n=e,a=[];t>n;++n)a.push(new $o(u[n],i(n),r));return a}var s=t.from,l=t.to,u=t.text,c=Jr(e,s.line),f=Jr(e,l.line),d=Ni(u),p=i(u.length-1),h=l.line-s.line;if(t.full)e.insert(0,o(0,u.length)),e.remove(u.length,e.size-u.length);else if(Br(e,t)){var m=o(0,u.length-1);a(f,f.text,p),h&&e.remove(s.line,h),m.length&&e.insert(s.line,m)}else if(c==f)if(1==u.length)a(c,c.text.slice(0,s.ch)+d+c.text.slice(l.ch),p);else{var m=o(1,u.length-1);m.push(new $o(d+c.text.slice(l.ch),p,r)),a(c,c.text.slice(0,s.ch)+u[0],i(0)),e.insert(s.line+1,m)}else if(1==u.length)a(c,c.text.slice(0,s.ch)+u[0]+f.text.slice(l.ch),i(0)),e.remove(s.line+1,h);else{a(c,c.text.slice(0,s.ch)+u[0],i(0)),a(f,d+f.text.slice(l.ch),p);var m=o(1,u.length-1);h>1&&e.remove(s.line+1,h-1),e.insert(s.line+1,m)}Ci(e,"change",e,t)}function Yr(e){this.lines=e,this.parent=null;for(var t=0,n=0;t<e.length;++t)e[t].parent=this,n+=e[t].height;this.height=n}function Gr(e){this.children=e;for(var t=0,n=0,r=0;r<e.length;++r){var i=e[r];t+=i.chunkSize(),n+=i.height,i.parent=this}this.size=t,this.height=n,this.parent=null}function Xr(e,t,n){function r(e,i,a){if(e.linked)for(var o=0;o<e.linked.length;++o){var s=e.linked[o];if(s.doc!=i){var l=a&&s.sharedHist;n&&!l||(t(s.doc,l),r(s.doc,e,l))}}}r(e,null,!0)}function Kr(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,o(e),n(e),e.options.lineWrapping||d(e),e.options.mode=t.modeOption,Pt(e)}function Jr(e,t){if(t-=e.first,0>t||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var r=0;;++r){var i=n.children[r],a=i.chunkSize();if(a>t){n=i;break}t-=a}return n.lines[t]}function Zr(e,t,n){var r=[],i=t.line;return e.iter(t.line,n.line+1,function(e){var a=e.text;i==n.line&&(a=a.slice(0,n.ch)),i==t.line&&(a=a.slice(t.ch)),r.push(a),++i}),r}function Qr(e,t,n){var r=[];return e.iter(t,n,function(e){r.push(e.text)}),r}function ei(e,t){var n=t-e.height;if(n)for(var r=e;r;r=r.parent)r.height+=n}function ti(e){if(null==e.parent)return null;for(var t=e.parent,n=ji(t.lines,e),r=t.parent;r;t=r,r=r.parent)for(var i=0;r.children[i]!=t;++i)n+=r.children[i].chunkSize();return n+t.first}function ni(e,t){var n=e.first;e:do{for(var r=0;r<e.children.length;++r){var i=e.children[r],a=i.height;if(a>t){e=i;continue e}t-=a,n+=i.chunkSize()}return n}while(!e.lines);for(var r=0;r<e.lines.length;++r){var o=e.lines[r],s=o.height;if(s>t)break;t-=s}return n+r}function ri(e){e=br(e);for(var t=0,n=e.parent,r=0;r<n.lines.length;++r){var i=n.lines[r];if(i==e)break;t+=i.height}for(var a=n.parent;a;n=a,a=n.parent)for(var r=0;r<a.children.length;++r){var o=a.children[r];if(o==n)break;t+=o.height}return t}function ii(e){var t=e.order;return null==t&&(t=e.order=ss(e.text)),t}function ai(e){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e||1}function oi(e,t){var n={from:Y(t.from),to:Za(t),text:Zr(e,t.from,t.to)};return pi(e,n,t.from.line,t.to.line+1),Xr(e,function(e){pi(e,n,t.from.line,t.to.line+1)},!0),n}function si(e){for(;e.length;){var t=Ni(e);if(!t.ranges)break;e.pop()}}function li(e,t){return t?(si(e.done),Ni(e.done)):e.done.length&&!Ni(e.done).ranges?Ni(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),Ni(e.done)):void 0}function ui(e,t,n,r){var i=e.history;i.undone.length=0;var a,o=+new Date;if((i.lastOp==r||i.lastOrigin==t.origin&&t.origin&&("+"==t.origin.charAt(0)&&e.cm&&i.lastModTime>o-e.cm.options.historyEventDelay||"*"==t.origin.charAt(0)))&&(a=li(i,i.lastOp==r))){var s=Ni(a.changes);0==za(t.from,t.to)&&0==za(t.from,s.to)?s.to=Za(t):a.changes.push(oi(e,t))}else{var l=Ni(i.done);for(l&&l.ranges||di(e.sel,i.done),a={changes:[oi(e,t)],generation:i.generation},i.done.push(a);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(n),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=o,i.lastOp=i.lastSelOp=r,i.lastOrigin=i.lastSelOrigin=t.origin,s||jo(e,"historyAdded")}function ci(e,t,n,r){var i=t.charAt(0);return"*"==i||"+"==i&&n.ranges.length==r.ranges.length&&n.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function fi(e,t,n,r){var i=e.history,a=r&&r.origin;n==i.lastSelOp||a&&i.lastSelOrigin==a&&(i.lastModTime==i.lastSelTime&&i.lastOrigin==a||ci(e,a,Ni(i.done),t))?i.done[i.done.length-1]=t:di(t,i.done),i.lastSelTime=+new Date,i.lastSelOrigin=a,i.lastSelOp=n,r&&r.clearRedo!==!1&&si(i.undone)}function di(e,t){var n=Ni(t);n&&n.ranges&&n.equals(e)||t.push(e)}function pi(e,t,n,r){var i=t["spans_"+e.id],a=0;e.iter(Math.max(e.first,n),Math.min(e.first+e.size,r),function(n){n.markedSpans&&((i||(i=t["spans_"+e.id]={}))[a]=n.markedSpans),++a})}function hi(e){if(!e)return null;for(var t,n=0;n<e.length;++n)e[n].marker.explicitlyCleared?t||(t=e.slice(0,n)):t&&t.push(e[n]);return t?t.length?t:null:e}function mi(e,t){var n=t["spans_"+e.id];if(!n)return null;for(var r=0,i=[];r<t.text.length;++r)i.push(hi(n[r]));return i}function gi(e,t,n){for(var r=0,i=[];r<e.length;++r){var a=e[r];if(a.ranges)i.push(n?ce.prototype.deepCopy.call(a):a);else{var o=a.changes,s=[];i.push({changes:s});for(var l=0;l<o.length;++l){var u,c=o[l];if(s.push({from:c.from,to:c.to,text:c.text}),t)for(var f in c)(u=f.match(/^spans_(\d+)$/))&&ji(t,Number(u[1]))>-1&&(Ni(s)[f]=c[f],delete c[f])}}}return i}function vi(e,t,n,r){n<e.line?e.line+=r:t<e.line&&(e.line=t,e.ch=0)}function bi(e,t,n,r){for(var i=0;i<e.length;++i){var a=e[i],o=!0;if(a.ranges){a.copied||(a=e[i]=a.deepCopy(),a.copied=!0);for(var s=0;s<a.ranges.length;s++)vi(a.ranges[s].anchor,t,n,r),vi(a.ranges[s].head,t,n,r)}else{for(var s=0;s<a.changes.length;++s){var l=a.changes[s];if(n<l.from.line)l.from=Fa(l.from.line+r,l.from.ch),l.to=Fa(l.to.line+r,l.to.ch);else if(t<=l.to.line){o=!1;break}}o||(e.splice(0,i+1),i=0)}}}function yi(e,t){var n=t.from.line,r=t.to.line,i=t.text.length-(r-n)-1;bi(e.done,n,r,i),bi(e.undone,n,r,i)}function $i(e){return null!=e.defaultPrevented?e.defaultPrevented:0==e.returnValue}function wi(e){
return e.target||e.srcElement}function xi(e){var t=e.which;return null==t&&(1&e.button?t=1:2&e.button?t=3:4&e.button&&(t=2)),Ea&&e.ctrlKey&&1==t&&(t=3),t}function ki(e,t,n){var r=e._handlers&&e._handlers[t];return n?r&&r.length>0?r.slice():Ao:r||Ao}function Ci(e,t){function n(e){return function(){e.apply(null,a)}}var r=ki(e,t,!1);if(r.length){var i,a=Array.prototype.slice.call(arguments,2);Wa?i=Wa.delayedCallbacks:Lo?i=Lo:(i=Lo=[],setTimeout(Mi,0));for(var o=0;o<r.length;++o)i.push(n(r[o]))}}function Mi(){var e=Lo;Lo=null;for(var t=0;t<e.length;++t)e[t]()}function Si(e,t,n){return"string"==typeof t&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),jo(e,n||t.type,e,t),$i(t)||t.codemirrorIgnore}function Ti(e){var t=e._handlers&&e._handlers.cursorActivity;if(t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),r=0;r<t.length;++r)-1==ji(n,t[r])&&n.push(t[r])}function Di(e,t){return ki(e,t).length>0}function Ei(e){e.prototype.on=function(e,t){Oo(this,e,t)},e.prototype.off=function(e,t){No(this,e,t)}}function Oi(){this.id=null}function Ai(e){for(;Uo.length<=e;)Uo.push(Ni(Uo)+" ");return Uo[e]}function Ni(e){return e[e.length-1]}function ji(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}function Li(e,t){for(var n=[],r=0;r<e.length;r++)n[r]=t(e[r],r);return n}function Pi(){}function Ii(e,t){var n;return Object.create?n=Object.create(e):(Pi.prototype=e,n=new Pi),t&&Fi(t,n),n}function Fi(e,t,n){t||(t={});for(var r in e)!e.hasOwnProperty(r)||n===!1&&t.hasOwnProperty(r)||(t[r]=e[r]);return t}function zi(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function _i(e,t){return t?t.source.indexOf("\\w")>-1&&qo(e)?!0:t.test(e):qo(e)}function Ri(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}function Hi(e){return e.charCodeAt(0)>=768&&Yo.test(e)}function Ui(e,t,n,r){var i=document.createElement(e);if(n&&(i.className=n),r&&(i.style.cssText=r),"string"==typeof t)i.appendChild(document.createTextNode(t));else if(t)for(var a=0;a<t.length;++a)i.appendChild(t[a]);return i}function Vi(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function Wi(e,t){return Vi(e).appendChild(t)}function Bi(){for(var e=document.activeElement;e&&e.root&&e.root.activeElement;)e=e.root.activeElement;return e}function qi(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}function Yi(e,t){for(var n=e.split(" "),r=0;r<n.length;r++)n[r]&&!qi(n[r]).test(t)&&(t+=" "+n[r]);return t}function Gi(e){if(document.body.getElementsByClassName)for(var t=document.body.getElementsByClassName("CodeMirror"),n=0;n<t.length;n++){var r=t[n].CodeMirror;r&&e(r)}}function Xi(){Qo||(Ki(),Qo=!0)}function Ki(){var e;Oo(window,"resize",function(){null==e&&(e=setTimeout(function(){e=null,Gi(Wt)},100))}),Oo(window,"blur",function(){Gi(bn)})}function Ji(e){if(null==Xo){var t=Ui("span","");Wi(e,Ui("span",[t,document.createTextNode("x")])),0!=e.firstChild.offsetHeight&&(Xo=t.offsetWidth<=1&&t.offsetHeight>2&&!(ba&&8>ya))}var n=Xo?Ui("span",""):Ui("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function Zi(e){if(null!=Ko)return Ko;var t=Wi(e,document.createTextNode("AخA")),n=Wo(t,0,1).getBoundingClientRect();if(!n||n.left==n.right)return!1;var r=Wo(t,1,2).getBoundingClientRect();return Ko=r.right-n.right<3}function Qi(e){if(null!=is)return is;var t=Wi(e,Ui("span","x")),n=t.getBoundingClientRect(),r=Wo(t,0,1).getBoundingClientRect();return is=Math.abs(n.left-r.left)>1}function ea(e,t,n,r){if(!e)return r(t,n,"ltr");for(var i=!1,a=0;a<e.length;++a){var o=e[a];(o.from<n&&o.to>t||t==n&&o.to==t)&&(r(Math.max(o.from,t),Math.min(o.to,n),1==o.level?"rtl":"ltr"),i=!0)}i||r(t,n,"ltr")}function ta(e){return e.level%2?e.to:e.from}function na(e){return e.level%2?e.from:e.to}function ra(e){var t=ii(e);return t?ta(t[0]):0}function ia(e){var t=ii(e);return t?na(Ni(t)):e.text.length}function aa(e,t){var n=Jr(e.doc,t),r=br(n);r!=n&&(t=ti(r));var i=ii(r),a=i?i[0].level%2?ia(r):ra(r):0;return Fa(t,a)}function oa(e,t){for(var n,r=Jr(e.doc,t);n=gr(r);)r=n.find(1,!0).line,t=null;var i=ii(r),a=i?i[0].level%2?ra(r):ia(r):r.text.length;return Fa(null==t?ti(r):t,a)}function sa(e,t){var n=aa(e,t.line),r=Jr(e.doc,n.line),i=ii(r);if(!i||0==i[0].level){var a=Math.max(0,r.text.search(/\S/)),o=t.line==n.line&&t.ch<=a&&t.ch;return Fa(n.line,o?0:a)}return n}function la(e,t,n){var r=e[0].level;return t==r?!0:n==r?!1:n>t}function ua(e,t){os=null;for(var n,r=0;r<e.length;++r){var i=e[r];if(i.from<t&&i.to>t)return r;if(i.from==t||i.to==t){if(null!=n)return la(e,i.level,e[n].level)?(i.from!=i.to&&(os=n),r):(i.from!=i.to&&(os=r),n);n=r}}return n}function ca(e,t,n,r){if(!r)return t+n;do t+=n;while(t>0&&Hi(e.text.charAt(t)));return t}function fa(e,t,n,r){var i=ii(e);if(!i)return da(e,t,n,r);for(var a=ua(i,t),o=i[a],s=ca(e,t,o.level%2?-n:n,r);;){if(s>o.from&&s<o.to)return s;if(s==o.from||s==o.to)return ua(i,s)==a?s:(o=i[a+=n],n>0==o.level%2?o.to:o.from);if(o=i[a+=n],!o)return null;s=n>0==o.level%2?ca(e,o.to,-1,r):ca(e,o.from,1,r)}}function da(e,t,n,r){var i=t+n;if(r)for(;i>0&&Hi(e.text.charAt(i));)i+=n;return 0>i||i>e.text.length?null:i}var pa=navigator.userAgent,ha=navigator.platform,ma=/gecko\/\d/i.test(pa),ga=/MSIE \d/.test(pa),va=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(pa),ba=ga||va,ya=ba&&(ga?document.documentMode||6:va[1]),$a=/WebKit\//.test(pa),wa=$a&&/Qt\/\d+\.\d+/.test(pa),xa=/Chrome\//.test(pa),ka=/Opera\//.test(pa),Ca=/Apple Computer/.test(navigator.vendor),Ma=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(pa),Sa=/PhantomJS/.test(pa),Ta=/AppleWebKit/.test(pa)&&/Mobile\/\w+/.test(pa),Da=Ta||/Android|webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(pa),Ea=Ta||/Mac/.test(ha),Oa=/\bCrOS\b/.test(pa),Aa=/win/i.test(ha),Na=ka&&pa.match(/Version\/(\d*\.\d*)/);Na&&(Na=Number(Na[1])),Na&&Na>=15&&(ka=!1,$a=!0);var ja=Ea&&(wa||ka&&(null==Na||12.11>Na)),La=ma||ba&&ya>=9,Pa=!1,Ia=!1;m.prototype=Fi({update:function(e){var t=e.scrollWidth>e.clientWidth+1,n=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var i=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=n?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var a=e.viewWidth-e.barLeft-(n?r:0);this.horiz.firstChild.style.width=e.scrollWidth-e.clientWidth+a+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==r&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?r:0,bottom:t?r:0}},setScrollLeft:function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz)},setScrollTop:function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert)},zeroWidthHack:function(){var e=Ea&&!Ma?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new Oi,this.disableVert=new Oi},enableZeroWidthBar:function(e,t){function n(){var r=e.getBoundingClientRect(),i=document.elementFromPoint(r.left+1,r.bottom-1);i!=e?e.style.pointerEvents="none":t.set(1e3,n)}e.style.pointerEvents="auto",t.set(1e3,n)},clear:function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)}},m.prototype),g.prototype=Fi({update:function(){return{bottom:0,right:0}},setScrollLeft:function(){},setScrollTop:function(){},clear:function(){}},g.prototype),e.scrollbarModel={"native":m,"null":g},M.prototype.signal=function(e,t){Di(e,t)&&this.events.push(arguments)},M.prototype.finish=function(){for(var e=0;e<this.events.length;e++)jo.apply(null,this.events[e])};var Fa=e.Pos=function(e,t){return this instanceof Fa?(this.line=e,void(this.ch=t)):new Fa(e,t)},za=e.cmpPos=function(e,t){return e.line-t.line||e.ch-t.ch},_a=null;ne.prototype=Fi({init:function(e){function t(e){if(!Si(r,e)){if(r.somethingSelected())_a=r.getSelections(),n.inaccurateSelection&&(n.prevInput="",n.inaccurateSelection=!1,a.value=_a.join("\n"),Vo(a));else{if(!r.options.lineWiseCopyCut)return;var t=ee(r);_a=t.text,"cut"==e.type?r.setSelections(t.ranges,null,Fo):(n.prevInput="",a.value=t.text.join("\n"),Vo(a))}"cut"==e.type&&(r.state.cutIncoming=!0)}}var n=this,r=this.cm,i=this.wrapper=re(),a=this.textarea=i.firstChild;e.wrapper.insertBefore(i,e.wrapper.firstChild),Ta&&(a.style.width="0px"),Oo(a,"input",function(){ba&&ya>=9&&n.hasSelection&&(n.hasSelection=null),n.poll()}),Oo(a,"paste",function(e){Si(r,e)||Z(e,r)||(r.state.pasteIncoming=!0,n.fastPoll())}),Oo(a,"cut",t),Oo(a,"copy",t),Oo(e.scroller,"paste",function(t){Bt(e,t)||Si(r,t)||(r.state.pasteIncoming=!0,n.focus())}),Oo(e.lineSpace,"selectstart",function(t){Bt(e,t)||To(t)}),Oo(a,"compositionstart",function(){var e=r.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:r.markText(e,r.getCursor("to"),{className:"CodeMirror-composing"})}}),Oo(a,"compositionend",function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)})},prepareSelection:function(){var e=this.cm,t=e.display,n=e.doc,r=Pe(e);if(e.options.moveInputWithCursor){var i=pt(e,n.sel.primary().head,"div"),a=t.wrapper.getBoundingClientRect(),o=t.lineDiv.getBoundingClientRect();r.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,i.top+o.top-a.top)),r.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,i.left+o.left-a.left))}return r},showSelection:function(e){var t=this.cm,n=t.display;Wi(n.cursorDiv,e.cursors),Wi(n.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},reset:function(e){if(!this.contextMenuPending){var t,n,r=this.cm,i=r.doc;if(r.somethingSelected()){this.prevInput="";var a=i.sel.primary();t=rs&&(a.to().line-a.from().line>100||(n=r.getSelection()).length>1e3);var o=t?"-":n||r.getSelection();this.textarea.value=o,r.state.focused&&Vo(this.textarea),ba&&ya>=9&&(this.hasSelection=o)}else e||(this.prevInput=this.textarea.value="",ba&&ya>=9&&(this.hasSelection=null));this.inaccurateSelection=t}},getField:function(){return this.textarea},supportsTouch:function(){return!1},focus:function(){if("nocursor"!=this.cm.options.readOnly&&(!Da||Bi()!=this.textarea))try{this.textarea.focus()}catch(e){}},blur:function(){this.textarea.blur()},resetPosition:function(){this.wrapper.style.top=this.wrapper.style.left=0},receivedFocus:function(){this.slowPoll()},slowPoll:function(){var e=this;e.pollingFast||e.polling.set(this.cm.options.pollInterval,function(){e.poll(),e.cm.state.focused&&e.slowPoll()})},fastPoll:function(){function e(){var r=n.poll();r||t?(n.pollingFast=!1,n.slowPoll()):(t=!0,n.polling.set(60,e))}var t=!1,n=this;n.pollingFast=!0,n.polling.set(20,e)},poll:function(){var e=this.cm,t=this.textarea,n=this.prevInput;if(this.contextMenuPending||!e.state.focused||ns(t)&&!n&&!this.composing||e.isReadOnly()||e.options.disableInput||e.state.keySeq)return!1;var r=t.value;if(r==n&&!e.somethingSelected())return!1;if(ba&&ya>=9&&this.hasSelection===r||Ea&&/[\uf700-\uf7ff]/.test(r))return e.display.input.reset(),!1;if(e.doc.sel==e.display.selForContextMenu){var i=r.charCodeAt(0);if(8203!=i||n||(n=""),8666==i)return this.reset(),this.cm.execCommand("undo")}for(var a=0,o=Math.min(n.length,r.length);o>a&&n.charCodeAt(a)==r.charCodeAt(a);)++a;var s=this;return Et(e,function(){J(e,r.slice(a),n.length-a,null,s.composing?"*compose":null),r.length>1e3||r.indexOf("\n")>-1?t.value=s.prevInput="":s.prevInput=r,s.composing&&(s.composing.range.clear(),s.composing.range=e.markText(s.composing.start,e.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},ensurePolled:function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},onKeyPress:function(){ba&&ya>=9&&(this.hasSelection=null),this.fastPoll()},onContextMenu:function(e){function t(){if(null!=o.selectionStart){var e=i.somethingSelected(),t=""+(e?o.value:"");o.value="⇚",o.value=t,r.prevInput=e?"":"",o.selectionStart=1,o.selectionEnd=t.length,a.selForContextMenu=i.doc.sel}}function n(){if(r.contextMenuPending=!1,r.wrapper.style.cssText=f,o.style.cssText=c,ba&&9>ya&&a.scrollbars.setScrollTop(a.scroller.scrollTop=l),null!=o.selectionStart){(!ba||ba&&9>ya)&&t();var e=0,n=function(){a.selForContextMenu==i.doc.sel&&0==o.selectionStart&&o.selectionEnd>0&&""==r.prevInput?Ot(i,uo.selectAll)(i):e++<10?a.detectingSelectAll=setTimeout(n,500):a.input.reset()};a.detectingSelectAll=setTimeout(n,200)}}var r=this,i=r.cm,a=i.display,o=r.textarea,s=qt(i,e),l=a.scroller.scrollTop;if(s&&!ka){var u=i.options.resetSelectionOnContextMenu;u&&-1==i.doc.sel.contains(s)&&Ot(i,Se)(i.doc,pe(s),Fo);var c=o.style.cssText,f=r.wrapper.style.cssText;r.wrapper.style.cssText="position: absolute";var d=r.wrapper.getBoundingClientRect();if(o.style.cssText="position: absolute; width: 30px; height: 30px; top: "+(e.clientY-d.top-5)+"px; left: "+(e.clientX-d.left-5)+"px; z-index: 1000; background: "+(ba?"rgba(255, 255, 255, .05)":"transparent")+"; outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",$a)var p=window.scrollY;if(a.input.focus(),$a&&window.scrollTo(null,p),a.input.reset(),i.somethingSelected()||(o.value=r.prevInput=" "),r.contextMenuPending=!0,a.selForContextMenu=i.doc.sel,clearTimeout(a.detectingSelectAll),ba&&ya>=9&&t(),La){Eo(e);var h=function(){No(window,"mouseup",h),setTimeout(n,20)};Oo(window,"mouseup",h)}else setTimeout(n,50)}},readOnlyChanged:function(e){e||this.reset()},setUneditable:Pi,needsContentAttribute:!1},ne.prototype),ie.prototype=Fi({init:function(e){function t(e){if(!Si(r,e)){if(r.somethingSelected())_a=r.getSelections(),"cut"==e.type&&r.replaceSelection("",null,"cut");else{if(!r.options.lineWiseCopyCut)return;var t=ee(r);_a=t.text,"cut"==e.type&&r.operation(function(){r.setSelections(t.ranges,0,Fo),r.replaceSelection("",null,"cut")})}if(e.clipboardData&&!Ta)e.preventDefault(),e.clipboardData.clearData(),e.clipboardData.setData("text/plain",_a.join("\n"));else{var n=re(),i=n.firstChild;r.display.lineSpace.insertBefore(n,r.display.lineSpace.firstChild),i.value=_a.join("\n");var a=document.activeElement;Vo(i),setTimeout(function(){r.display.lineSpace.removeChild(n),a.focus()},50)}}}var n=this,r=n.cm,i=n.div=e.lineDiv;te(i),Oo(i,"paste",function(e){Si(r,e)||Z(e,r)}),Oo(i,"compositionstart",function(e){var t=e.data;if(n.composing={sel:r.doc.sel,data:t,startData:t},t){var i=r.doc.sel.primary(),a=r.getLine(i.head.line),o=a.indexOf(t,Math.max(0,i.head.ch-t.length));o>-1&&o<=i.head.ch&&(n.composing.sel=pe(Fa(i.head.line,o),Fa(i.head.line,o+t.length)))}}),Oo(i,"compositionupdate",function(e){n.composing.data=e.data}),Oo(i,"compositionend",function(e){var t=n.composing;t&&(e.data==t.startData||/\u200b/.test(e.data)||(t.data=e.data),setTimeout(function(){t.handled||n.applyComposition(t),n.composing==t&&(n.composing=null)},50))}),Oo(i,"touchstart",function(){n.forceCompositionEnd()}),Oo(i,"input",function(){n.composing||!r.isReadOnly()&&n.pollContent()||Et(n.cm,function(){Pt(r)})}),Oo(i,"copy",t),Oo(i,"cut",t)},prepareSelection:function(){var e=Pe(this.cm,!1);return e.focus=this.cm.state.focused,e},showSelection:function(e){e&&this.cm.display.view.length&&(e.focus&&this.showPrimarySelection(),this.showMultipleSelections(e))},showPrimarySelection:function(){var e=window.getSelection(),t=this.cm.doc.sel.primary(),n=se(this.cm,e.anchorNode,e.anchorOffset),r=se(this.cm,e.focusNode,e.focusOffset);if(!n||n.bad||!r||r.bad||0!=za(X(n,r),t.from())||0!=za(G(n,r),t.to())){var i=ae(this.cm,t.from()),a=ae(this.cm,t.to());if(i||a){var o=this.cm.display.view,s=e.rangeCount&&e.getRangeAt(0);if(i){if(!a){var l=o[o.length-1].measure,u=l.maps?l.maps[l.maps.length-1]:l.map;a={node:u[u.length-1],offset:u[u.length-2]-u[u.length-3]}}}else i={node:o[0].measure.map[2],offset:0};try{var c=Wo(i.node,i.offset,a.offset,a.node)}catch(f){}c&&(!ma&&this.cm.state.focused?(e.collapse(i.node,i.offset),c.collapsed||e.addRange(c)):(e.removeAllRanges(),e.addRange(c)),s&&null==e.anchorNode?e.addRange(s):ma&&this.startGracePeriod()),this.rememberSelection()}}},startGracePeriod:function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation(function(){e.cm.curOp.selectionChanged=!0})},20)},showMultipleSelections:function(e){Wi(this.cm.display.cursorDiv,e.cursors),Wi(this.cm.display.selectionDiv,e.selection)},rememberSelection:function(){var e=window.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},selectionInEditor:function(){var e=window.getSelection();if(!e.rangeCount)return!1;var t=e.getRangeAt(0).commonAncestorContainer;return Go(this.div,t)},focus:function(){"nocursor"!=this.cm.options.readOnly&&this.div.focus()},blur:function(){this.div.blur()},getField:function(){return this.div},supportsTouch:function(){return!0},receivedFocus:function(){function e(){t.cm.state.focused&&(t.pollSelection(),t.polling.set(t.cm.options.pollInterval,e))}var t=this;this.selectionInEditor()?this.pollSelection():Et(this.cm,function(){t.cm.curOp.selectionChanged=!0}),this.polling.set(this.cm.options.pollInterval,e)},selectionChanged:function(){var e=window.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},pollSelection:function(){if(!this.composing&&!this.gracePeriod&&this.selectionChanged()){var e=window.getSelection(),t=this.cm;this.rememberSelection();var n=se(t,e.anchorNode,e.anchorOffset),r=se(t,e.focusNode,e.focusOffset);n&&r&&Et(t,function(){Se(t.doc,pe(n,r),Fo),(n.bad||r.bad)&&(t.curOp.selectionChanged=!0)})}},pollContent:function(){var e=this.cm,t=e.display,n=e.doc.sel.primary(),r=n.from(),i=n.to();if(r.line<t.viewFrom||i.line>t.viewTo-1)return!1;var a;if(r.line==t.viewFrom||0==(a=zt(e,r.line)))var o=ti(t.view[0].line),s=t.view[0].node;else var o=ti(t.view[a].line),s=t.view[a-1].node.nextSibling;var l=zt(e,i.line);if(l==t.view.length-1)var u=t.viewTo-1,c=t.lineDiv.lastChild;else var u=ti(t.view[l+1].line)-1,c=t.view[l+1].node.previousSibling;for(var f=e.doc.splitLines(ue(e,s,c,o,u)),d=Zr(e.doc,Fa(o,0),Fa(u,Jr(e.doc,u).text.length));f.length>1&&d.length>1;)if(Ni(f)==Ni(d))f.pop(),d.pop(),u--;else{if(f[0]!=d[0])break;f.shift(),d.shift(),o++}for(var p=0,h=0,m=f[0],g=d[0],v=Math.min(m.length,g.length);v>p&&m.charCodeAt(p)==g.charCodeAt(p);)++p;for(var b=Ni(f),y=Ni(d),$=Math.min(b.length-(1==f.length?p:0),y.length-(1==d.length?p:0));$>h&&b.charCodeAt(b.length-h-1)==y.charCodeAt(y.length-h-1);)++h;f[f.length-1]=b.slice(0,b.length-h),f[0]=f[0].slice(p);var w=Fa(o,p),x=Fa(u,d.length?Ni(d).length-h:0);return f.length>1||f[0]||za(w,x)?(Nn(e.doc,f,w,x,"+input"),!0):void 0},ensurePolled:function(){this.forceCompositionEnd()},reset:function(){this.forceCompositionEnd()},forceCompositionEnd:function(){this.composing&&!this.composing.handled&&(this.applyComposition(this.composing),this.composing.handled=!0,this.div.blur(),this.div.focus())},applyComposition:function(e){this.cm.isReadOnly()?Ot(this.cm,Pt)(this.cm):e.data&&e.data!=e.startData&&Ot(this.cm,J)(this.cm,e.data,0,e.sel)},setUneditable:function(e){e.contentEditable="false"},onKeyPress:function(e){e.preventDefault(),this.cm.isReadOnly()||Ot(this.cm,J)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0)},readOnlyChanged:function(e){this.div.contentEditable=String("nocursor"!=e)},onContextMenu:Pi,resetPosition:Pi,needsContentAttribute:!0},ie.prototype),e.inputStyles={textarea:ne,contenteditable:ie},ce.prototype={primary:function(){return this.ranges[this.primIndex]},equals:function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var n=this.ranges[t],r=e.ranges[t];if(0!=za(n.anchor,r.anchor)||0!=za(n.head,r.head))return!1}return!0},deepCopy:function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new fe(Y(this.ranges[t].anchor),Y(this.ranges[t].head));return new ce(e,this.primIndex)},somethingSelected:function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},contains:function(e,t){t||(t=e);for(var n=0;n<this.ranges.length;n++){var r=this.ranges[n];if(za(t,r.from())>=0&&za(e,r.to())<=0)return n}return-1}},fe.prototype={from:function(){return X(this.anchor,this.head)},to:function(){return G(this.anchor,this.head)},empty:function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch}};var Ra,Ha,Ua,Va={left:0,right:0,top:0,bottom:0},Wa=null,Ba=0,qa=0,Ya=0,Ga=null;ba?Ga=-.53:ma?Ga=15:xa?Ga=-.7:Ca&&(Ga=-1/3);var Xa=function(e){var t=e.wheelDeltaX,n=e.wheelDeltaY;return null==t&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),null==n&&e.detail&&e.axis==e.VERTICAL_AXIS?n=e.detail:null==n&&(n=e.wheelDelta),{x:t,y:n}};e.wheelEventPixels=function(e){var t=Xa(e);return t.x*=Ga,t.y*=Ga,t};var Ka=new Oi,Ja=null,Za=e.changeEnd=function(e){return e.text?Fa(e.from.line+e.text.length-1,Ni(e.text).length+(1==e.text.length?e.from.ch:0)):e.to};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,t){var n=this.options,r=n[e];n[e]==t&&"mode"!=e||(n[e]=t,eo.hasOwnProperty(e)&&Ot(this,eo[e])(this,t,r))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](Yn(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,n=0;n<t.length;++n)if(t[n]==e||t[n].name==e)return t.splice(n,1),!0},addOverlay:At(function(t,n){var r=t.token?t:e.getMode(this.options,t);if(r.startState)throw new Error("Overlays may not be stateful.");this.state.overlays.push({mode:r,modeSpec:t,opaque:n&&n.opaque}),this.state.modeGen++,Pt(this)}),removeOverlay:At(function(e){for(var t=this.state.overlays,n=0;n<t.length;++n){var r=t[n].modeSpec;if(r==e||"string"==typeof e&&r.name==e)return t.splice(n,1),this.state.modeGen++,void Pt(this)}}),indentLine:At(function(e,t,n){"string"!=typeof t&&"number"!=typeof t&&(t=null==t?this.options.smartIndent?"smart":"prev":t?"add":"subtract"),ve(this.doc,e)&&Rn(this,e,t,n)}),indentSelection:At(function(e){for(var t=this.doc.sel.ranges,n=-1,r=0;r<t.length;r++){var i=t[r];if(i.empty())i.head.line>n&&(Rn(this,i.head.line,e,!0),n=i.head.line,r==this.doc.sel.primIndex&&zn(this));else{var a=i.from(),o=i.to(),s=Math.max(n,a.line);n=Math.min(this.lastLine(),o.line-(o.ch?0:1))+1;for(var l=s;n>l;++l)Rn(this,l,e);var u=this.doc.sel.ranges;0==a.ch&&t.length==u.length&&u[r].from().ch>0&&xe(this.doc,r,new fe(a,u[r].to()),Fo)}}}),getTokenAt:function(e,t){return Nr(this,e,t)},getLineTokens:function(e,t){return Nr(this,Fa(e),t,!0)},getTokenTypeAt:function(e){e=me(this.doc,e);var t,n=Pr(this,Jr(this.doc,e.line)),r=0,i=(n.length-1)/2,a=e.ch;if(0==a)t=n[2];else for(;;){var o=r+i>>1;if((o?n[2*o-1]:0)>=a)i=o;else{if(!(n[2*o+1]<a)){t=n[2*o+2];break}r=o+1}}var s=t?t.indexOf("cm-overlay "):-1;return 0>s?t:0==s?null:t.slice(0,s-1)},getModeAt:function(t){var n=this.doc.mode;return n.innerMode?e.innerMode(n,this.getTokenAt(t).state).mode:n},getHelper:function(e,t){return this.getHelpers(e,t)[0]},getHelpers:function(e,t){var n=[];if(!oo.hasOwnProperty(t))return n;var r=oo[t],i=this.getModeAt(e);if("string"==typeof i[t])r[i[t]]&&n.push(r[i[t]]);else if(i[t])for(var a=0;a<i[t].length;a++){var o=r[i[t][a]];o&&n.push(o)}else i.helperType&&r[i.helperType]?n.push(r[i.helperType]):r[i.name]&&n.push(r[i.name]);for(var a=0;a<r._global.length;a++){var s=r._global[a];s.pred(i,this)&&-1==ji(n,s.val)&&n.push(s.val)}return n},getStateAfter:function(e,t){var n=this.doc;return e=he(n,null==e?n.first+n.size-1:e),Ue(this,e+1,t)},cursorCoords:function(e,t){var n,r=this.doc.sel.primary();return n=null==e?r.head:"object"==typeof e?me(this.doc,e):e?r.from():r.to(),pt(this,n,t||"page")},charCoords:function(e,t){return dt(this,me(this.doc,e),t||"page")},coordsChar:function(e,t){return e=ft(this,e,t||"page"),gt(this,e.left,e.top)},lineAtHeight:function(e,t){return e=ft(this,{top:e,left:0},t||"page").top,ni(this.doc,e+this.display.viewOffset)},heightAtLine:function(e,t){var n,r=!1;if("number"==typeof e){var i=this.doc.first+this.doc.size-1;e<this.doc.first?e=this.doc.first:e>i&&(e=i,r=!0),n=Jr(this.doc,e)}else n=e;return ct(this,n,{top:0,left:0},t||"page").top+(r?this.doc.height-ri(n):0)},defaultTextHeight:function(){return bt(this.display)},defaultCharWidth:function(){return yt(this.display)},setGutterMarker:At(function(e,t,n){return Hn(this.doc,e,"gutter",function(e){var r=e.gutterMarkers||(e.gutterMarkers={});return r[t]=n,!n&&Ri(r)&&(e.gutterMarkers=null),!0})}),clearGutter:At(function(e){var t=this,n=t.doc,r=n.first;n.iter(function(n){n.gutterMarkers&&n.gutterMarkers[e]&&(n.gutterMarkers[e]=null,It(t,r,"gutter"),Ri(n.gutterMarkers)&&(n.gutterMarkers=null)),++r})}),lineInfo:function(e){if("number"==typeof e){if(!ve(this.doc,e))return null;var t=e;if(e=Jr(this.doc,e),!e)return null}else{var t=ti(e);if(null==t)return null}return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,n,r,i){var a=this.display;e=pt(this,me(this.doc,e));var o=e.bottom,s=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),a.sizer.appendChild(t),"over"==r)o=e.top;else if("above"==r||"near"==r){var l=Math.max(a.wrapper.clientHeight,this.doc.height),u=Math.max(a.sizer.clientWidth,a.lineSpace.clientWidth);("above"==r||e.bottom+t.offsetHeight>l)&&e.top>t.offsetHeight?o=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=l&&(o=e.bottom),s+t.offsetWidth>u&&(s=u-t.offsetWidth)}t.style.top=o+"px",t.style.left=t.style.right="","right"==i?(s=a.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==i?s=0:"middle"==i&&(s=(a.sizer.clientWidth-t.offsetWidth)/2),t.style.left=s+"px"),n&&Pn(this,s,o,s+t.offsetWidth,o+t.offsetHeight)},triggerOnKeyDown:At(dn),triggerOnKeyPress:At(mn),triggerOnKeyUp:hn,execCommand:function(e){return uo.hasOwnProperty(e)?uo[e].call(null,this):void 0},triggerElectric:At(function(e){Q(this,e)}),findPosH:function(e,t,n,r){var i=1;0>t&&(i=-1,t=-t);for(var a=0,o=me(this.doc,e);t>a&&(o=Vn(this.doc,o,i,n,r),!o.hitSide);++a);return o},moveH:At(function(e,t){var n=this;n.extendSelectionsBy(function(r){return n.display.shift||n.doc.extend||r.empty()?Vn(n.doc,r.head,e,t,n.options.rtlMoveVisually):0>e?r.from():r.to()},_o)}),deleteH:At(function(e,t){var n=this.doc.sel,r=this.doc;n.somethingSelected()?r.replaceSelection("",null,"+delete"):Un(this,function(n){var i=Vn(r,n.head,e,t,!1);return 0>e?{from:i,to:n.head}:{from:n.head,to:i}})}),findPosV:function(e,t,n,r){var i=1,a=r;0>t&&(i=-1,t=-t);for(var o=0,s=me(this.doc,e);t>o;++o){var l=pt(this,s,"div");if(null==a?a=l.left:l.left=a,s=Wn(this,l,i,n),s.hitSide)break}return s},moveV:At(function(e,t){var n=this,r=this.doc,i=[],a=!n.display.shift&&!r.extend&&r.sel.somethingSelected();if(r.extendSelectionsBy(function(o){if(a)return 0>e?o.from():o.to();var s=pt(n,o.head,"div");null!=o.goalColumn&&(s.left=o.goalColumn),i.push(s.left);var l=Wn(n,s,e,t);return"page"==t&&o==r.sel.primary()&&Fn(n,null,dt(n,l,"div").top-s.top),l},_o),i.length)for(var o=0;o<r.sel.ranges.length;o++)r.sel.ranges[o].goalColumn=i[o]}),findWordAt:function(e){var t=this.doc,n=Jr(t,e.line).text,r=e.ch,i=e.ch;if(n){var a=this.getHelper(e,"wordChars");(e.xRel<0||i==n.length)&&r?--r:++i;for(var o=n.charAt(r),s=_i(o,a)?function(e){return _i(e,a)}:/\s/.test(o)?function(e){return/\s/.test(e)}:function(e){return!/\s/.test(e)&&!_i(e)};r>0&&s(n.charAt(r-1));)--r;for(;i<n.length&&s(n.charAt(i));)++i}return new fe(Fa(e.line,r),Fa(e.line,i))},toggleOverwrite:function(e){null!=e&&e==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?Zo(this.display.cursorDiv,"CodeMirror-overwrite"):Jo(this.display.cursorDiv,"CodeMirror-overwrite"),jo(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==Bi()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:At(function(e,t){null==e&&null==t||_n(this),null!=e&&(this.curOp.scrollLeft=e),null!=t&&(this.curOp.scrollTop=t)}),getScrollInfo:function(){var e=this.display.scroller;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight-qe(this)-this.display.barHeight,width:e.scrollWidth-qe(this)-this.display.barWidth,clientHeight:Ge(this),clientWidth:Ye(this)}},scrollIntoView:At(function(e,t){if(null==e?(e={from:this.doc.sel.primary().head,to:null},null==t&&(t=this.options.cursorScrollMargin)):"number"==typeof e?e={from:Fa(e,0),to:null}:null==e.from&&(e={from:e,to:null}),e.to||(e.to=e.from),e.margin=t||0,null!=e.from.line)_n(this),this.curOp.scrollToPos=e;else{var n=In(this,Math.min(e.from.left,e.to.left),Math.min(e.from.top,e.to.top)-e.margin,Math.max(e.from.right,e.to.right),Math.max(e.from.bottom,e.to.bottom)+e.margin);this.scrollTo(n.scrollLeft,n.scrollTop)}}),setSize:At(function(e,t){function n(e){return"number"==typeof e||/^\d+$/.test(String(e))?e+"px":e}var r=this;null!=e&&(r.display.wrapper.style.width=n(e)),null!=t&&(r.display.wrapper.style.height=n(t)),r.options.lineWrapping&&ot(this);var i=r.display.viewFrom;r.doc.iter(i,r.display.viewTo,function(e){if(e.widgets)for(var t=0;t<e.widgets.length;t++)if(e.widgets[t].noHScroll){It(r,i,"widget");break}++i}),r.curOp.forceUpdate=!0,jo(r,"refresh",this)}),operation:function(e){return Et(this,e)},refresh:At(function(){var e=this.display.cachedTextHeight;Pt(this),this.curOp.forceUpdate=!0,st(this),this.scrollTo(this.doc.scrollLeft,this.doc.scrollTop),c(this),(null==e||Math.abs(e-bt(this.display))>.5)&&o(this),jo(this,"refresh",this)}),swapDoc:At(function(e){var t=this.doc;return t.cm=null,Kr(this,e),st(this),this.display.input.reset(),this.scrollTo(e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,Ci(this,"swapDoc",this,t),t}),getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},Ei(e);var Qa=e.defaults={},eo=e.optionHandlers={},to=e.Init={toString:function(){return"CodeMirror.Init"}};Bn("value","",function(e,t){e.setValue(t)},!0),Bn("mode",null,function(e,t){e.doc.modeOption=t,n(e)},!0),Bn("indentUnit",2,n,!0),Bn("indentWithTabs",!1),Bn("smartIndent",!0),Bn("tabSize",4,function(e){r(e),st(e),Pt(e)},!0),Bn("lineSeparator",null,function(e,t){if(e.doc.lineSep=t,t){var n=[],r=e.doc.first;e.doc.iter(function(e){for(var i=0;;){var a=e.text.indexOf(t,i);if(-1==a)break;i=a+t.length,n.push(Fa(r,a))}r++});for(var i=n.length-1;i>=0;i--)Nn(e.doc,t,n[i],Fa(n[i].line,n[i].ch+t.length))}}),Bn("specialChars",/[\t\u0000-\u0019\u00ad\u200b-\u200f\u2028\u2029\ufeff]/g,function(t,n,r){t.state.specialChars=new RegExp(n.source+(n.test(" ")?"":"| "),"g"),r!=e.Init&&t.refresh()}),Bn("specialCharPlaceholder",_r,function(e){e.refresh()},!0),Bn("electricChars",!0),Bn("inputStyle",Da?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),Bn("rtlMoveVisually",!Aa),Bn("wholeLineUpdateBefore",!0),Bn("theme","default",function(e){s(e),l(e)},!0),Bn("keyMap","default",function(t,n,r){var i=Yn(n),a=r!=e.Init&&Yn(r);a&&a.detach&&a.detach(t,i),i.attach&&i.attach(t,a||null)}),Bn("extraKeys",null),Bn("lineWrapping",!1,i,!0),Bn("gutters",[],function(e){p(e.options),l(e)},!0),Bn("fixedGutter",!0,function(e,t){e.display.gutters.style.left=t?C(e.display)+"px":"0",
e.refresh()},!0),Bn("coverGutterNextToScrollbar",!1,function(e){b(e)},!0),Bn("scrollbarStyle","native",function(e){v(e),b(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)},!0),Bn("lineNumbers",!1,function(e){p(e.options),l(e)},!0),Bn("firstLineNumber",1,l,!0),Bn("lineNumberFormatter",function(e){return e},l,!0),Bn("showCursorWhenSelecting",!1,Le,!0),Bn("resetSelectionOnContextMenu",!0),Bn("lineWiseCopyCut",!0),Bn("readOnly",!1,function(e,t){"nocursor"==t?(bn(e),e.display.input.blur(),e.display.disabled=!0):e.display.disabled=!1,e.display.input.readOnlyChanged(t)}),Bn("disableInput",!1,function(e,t){t||e.display.input.reset()},!0),Bn("dragDrop",!0,Vt),Bn("allowDropFileTypes",null),Bn("cursorBlinkRate",530),Bn("cursorScrollMargin",0),Bn("cursorHeight",1,Le,!0),Bn("singleCursorHeightPerLine",!0,Le,!0),Bn("workTime",100),Bn("workDelay",100),Bn("flattenSpans",!0,r,!0),Bn("addModeClass",!1,r,!0),Bn("pollInterval",100),Bn("undoDepth",200,function(e,t){e.doc.history.undoDepth=t}),Bn("historyEventDelay",1250),Bn("viewportMargin",10,function(e){e.refresh()},!0),Bn("maxHighlightLength",1e4,r,!0),Bn("moveInputWithCursor",!0,function(e,t){t||e.display.input.resetPosition()}),Bn("tabindex",null,function(e,t){e.display.input.getField().tabIndex=t||""}),Bn("autofocus",null);var no=e.modes={},ro=e.mimeModes={};e.defineMode=function(t,n){e.defaults.mode||"null"==t||(e.defaults.mode=t),arguments.length>2&&(n.dependencies=Array.prototype.slice.call(arguments,2)),no[t]=n},e.defineMIME=function(e,t){ro[e]=t},e.resolveMode=function(t){if("string"==typeof t&&ro.hasOwnProperty(t))t=ro[t];else if(t&&"string"==typeof t.name&&ro.hasOwnProperty(t.name)){var n=ro[t.name];"string"==typeof n&&(n={name:n}),t=Ii(n,t),t.name=n.name}else if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+xml$/.test(t))return e.resolveMode("application/xml");return"string"==typeof t?{name:t}:t||{name:"null"}},e.getMode=function(t,n){var n=e.resolveMode(n),r=no[n.name];if(!r)return e.getMode(t,"text/plain");var i=r(t,n);if(io.hasOwnProperty(n.name)){var a=io[n.name];for(var o in a)a.hasOwnProperty(o)&&(i.hasOwnProperty(o)&&(i["_"+o]=i[o]),i[o]=a[o])}if(i.name=n.name,n.helperType&&(i.helperType=n.helperType),n.modeProps)for(var o in n.modeProps)i[o]=n.modeProps[o];return i},e.defineMode("null",function(){return{token:function(e){e.skipToEnd()}}}),e.defineMIME("text/plain","null");var io=e.modeExtensions={};e.extendMode=function(e,t){var n=io.hasOwnProperty(e)?io[e]:io[e]={};Fi(t,n)},e.defineExtension=function(t,n){e.prototype[t]=n},e.defineDocExtension=function(e,t){Co.prototype[e]=t},e.defineOption=Bn;var ao=[];e.defineInitHook=function(e){ao.push(e)};var oo=e.helpers={};e.registerHelper=function(t,n,r){oo.hasOwnProperty(t)||(oo[t]=e[t]={_global:[]}),oo[t][n]=r},e.registerGlobalHelper=function(t,n,r,i){e.registerHelper(t,n,i),oo[t]._global.push({pred:r,val:i})};var so=e.copyState=function(e,t){if(t===!0)return t;if(e.copyState)return e.copyState(t);var n={};for(var r in t){var i=t[r];i instanceof Array&&(i=i.concat([])),n[r]=i}return n},lo=e.startState=function(e,t,n){return e.startState?e.startState(t,n):!0};e.innerMode=function(e,t){for(;e.innerMode;){var n=e.innerMode(t);if(!n||n.mode==e)break;t=n.state,e=n.mode}return n||{mode:e,state:t}};var uo=e.commands={selectAll:function(e){e.setSelection(Fa(e.firstLine(),0),Fa(e.lastLine()),Fo)},singleSelection:function(e){e.setSelection(e.getCursor("anchor"),e.getCursor("head"),Fo)},killLine:function(e){Un(e,function(t){if(t.empty()){var n=Jr(e.doc,t.head.line).text.length;return t.head.ch==n&&t.head.line<e.lastLine()?{from:t.head,to:Fa(t.head.line+1,0)}:{from:t.head,to:Fa(t.head.line,n)}}return{from:t.from(),to:t.to()}})},deleteLine:function(e){Un(e,function(t){return{from:Fa(t.from().line,0),to:me(e.doc,Fa(t.to().line+1,0))}})},delLineLeft:function(e){Un(e,function(e){return{from:Fa(e.from().line,0),to:e.from()}})},delWrappedLineLeft:function(e){Un(e,function(t){var n=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:n},"div");return{from:r,to:t.from()}})},delWrappedLineRight:function(e){Un(e,function(t){var n=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div");return{from:t.from(),to:r}})},undo:function(e){e.undo()},redo:function(e){e.redo()},undoSelection:function(e){e.undoSelection()},redoSelection:function(e){e.redoSelection()},goDocStart:function(e){e.extendSelection(Fa(e.firstLine(),0))},goDocEnd:function(e){e.extendSelection(Fa(e.lastLine()))},goLineStart:function(e){e.extendSelectionsBy(function(t){return aa(e,t.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(e){e.extendSelectionsBy(function(t){return sa(e,t.head)},{origin:"+move",bias:1})},goLineEnd:function(e){e.extendSelectionsBy(function(t){return oa(e,t.head.line)},{origin:"+move",bias:-1})},goLineRight:function(e){e.extendSelectionsBy(function(t){var n=e.charCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div")},_o)},goLineLeft:function(e){e.extendSelectionsBy(function(t){var n=e.charCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:n},"div")},_o)},goLineLeftSmart:function(e){e.extendSelectionsBy(function(t){var n=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:n},"div");return r.ch<e.getLine(r.line).search(/\S/)?sa(e,t.head):r},_o)},goLineUp:function(e){e.moveV(-1,"line")},goLineDown:function(e){e.moveV(1,"line")},goPageUp:function(e){e.moveV(-1,"page")},goPageDown:function(e){e.moveV(1,"page")},goCharLeft:function(e){e.moveH(-1,"char")},goCharRight:function(e){e.moveH(1,"char")},goColumnLeft:function(e){e.moveH(-1,"column")},goColumnRight:function(e){e.moveH(1,"column")},goWordLeft:function(e){e.moveH(-1,"word")},goGroupRight:function(e){e.moveH(1,"group")},goGroupLeft:function(e){e.moveH(-1,"group")},goWordRight:function(e){e.moveH(1,"word")},delCharBefore:function(e){e.deleteH(-1,"char")},delCharAfter:function(e){e.deleteH(1,"char")},delWordBefore:function(e){e.deleteH(-1,"word")},delWordAfter:function(e){e.deleteH(1,"word")},delGroupBefore:function(e){e.deleteH(-1,"group")},delGroupAfter:function(e){e.deleteH(1,"group")},indentAuto:function(e){e.indentSelection("smart")},indentMore:function(e){e.indentSelection("add")},indentLess:function(e){e.indentSelection("subtract")},insertTab:function(e){e.replaceSelection(" ")},insertSoftTab:function(e){for(var t=[],n=e.listSelections(),r=e.options.tabSize,i=0;i<n.length;i++){var a=n[i].from(),o=Ro(e.getLine(a.line),a.ch,r);t.push(new Array(r-o%r+1).join(" "))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){Et(e,function(){for(var t=e.listSelections(),n=[],r=0;r<t.length;r++){var i=t[r].head,a=Jr(e.doc,i.line).text;if(a)if(i.ch==a.length&&(i=new Fa(i.line,i.ch-1)),i.ch>0)i=new Fa(i.line,i.ch+1),e.replaceRange(a.charAt(i.ch-1)+a.charAt(i.ch-2),Fa(i.line,i.ch-2),i,"+transpose");else if(i.line>e.doc.first){var o=Jr(e.doc,i.line-1).text;o&&e.replaceRange(a.charAt(0)+e.doc.lineSeparator()+o.charAt(o.length-1),Fa(i.line-1,o.length-1),Fa(i.line,1),"+transpose")}n.push(new fe(i,i))}e.setSelections(n)})},newlineAndIndent:function(e){Et(e,function(){for(var t=e.listSelections().length,n=0;t>n;n++){var r=e.listSelections()[n];e.replaceRange(e.doc.lineSeparator(),r.anchor,r.head,"+input"),e.indentLine(r.from().line+1,null,!0)}zn(e)})},toggleOverwrite:function(e){e.toggleOverwrite()}},co=e.keyMap={};co.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},co.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},co.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars"},co.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},co["default"]=Ea?co.macDefault:co.pcDefault,e.normalizeKeyMap=function(e){var t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];if(/^(name|fallthrough|(de|at)tach)$/.test(n))continue;if("..."==r){delete e[n];continue}for(var i=Li(n.split(" "),qn),a=0;a<i.length;a++){var o,s;a==i.length-1?(s=i.join(" "),o=r):(s=i.slice(0,a+1).join(" "),o="...");var l=t[s];if(l){if(l!=o)throw new Error("Inconsistent bindings for "+s)}else t[s]=o}delete e[n]}for(var u in t)e[u]=t[u];return e};var fo=e.lookupKey=function(e,t,n,r){t=Yn(t);var i=t.call?t.call(e,r):t[e];if(i===!1)return"nothing";if("..."===i)return"multi";if(null!=i&&n(i))return"handled";if(t.fallthrough){if("[object Array]"!=Object.prototype.toString.call(t.fallthrough))return fo(e,t.fallthrough,n,r);for(var a=0;a<t.fallthrough.length;a++){var o=fo(e,t.fallthrough[a],n,r);if(o)return o}}},po=e.isModifierKey=function(e){var t="string"==typeof e?e:as[e.keyCode];return"Ctrl"==t||"Alt"==t||"Shift"==t||"Mod"==t},ho=e.keyName=function(e,t){if(ka&&34==e.keyCode&&e["char"])return!1;var n=as[e.keyCode],r=n;return null==r||e.altGraphKey?!1:(e.altKey&&"Alt"!=n&&(r="Alt-"+r),(ja?e.metaKey:e.ctrlKey)&&"Ctrl"!=n&&(r="Ctrl-"+r),(ja?e.ctrlKey:e.metaKey)&&"Cmd"!=n&&(r="Cmd-"+r),!t&&e.shiftKey&&"Shift"!=n&&(r="Shift-"+r),r)};e.fromTextArea=function(t,n){function r(){t.value=u.getValue()}if(n=n?Fi(n):{},n.value=t.value,!n.tabindex&&t.tabIndex&&(n.tabindex=t.tabIndex),!n.placeholder&&t.placeholder&&(n.placeholder=t.placeholder),null==n.autofocus){var i=Bi();n.autofocus=i==t||null!=t.getAttribute("autofocus")&&i==document.body}if(t.form&&(Oo(t.form,"submit",r),!n.leaveSubmitMethodAlone)){var a=t.form,o=a.submit;try{var s=a.submit=function(){r(),a.submit=o,a.submit(),a.submit=s}}catch(l){}}n.finishInit=function(e){e.save=r,e.getTextArea=function(){return t},e.toTextArea=function(){e.toTextArea=isNaN,r(),t.parentNode.removeChild(e.getWrapperElement()),t.style.display="",t.form&&(No(t.form,"submit",r),"function"==typeof t.form.submit&&(t.form.submit=o))}},t.style.display="none";var u=e(function(e){t.parentNode.insertBefore(e,t.nextSibling)},n);return u};var mo=e.StringStream=function(e,t){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0};mo.prototype={eol:function(){return this.pos>=this.string.length},sol:function(){return this.pos==this.lineStart},peek:function(){return this.string.charAt(this.pos)||void 0},next:function(){return this.pos<this.string.length?this.string.charAt(this.pos++):void 0},eat:function(e){var t=this.string.charAt(this.pos);if("string"==typeof e)var n=t==e;else var n=t&&(e.test?e.test(t):e(t));return n?(++this.pos,t):void 0},eatWhile:function(e){for(var t=this.pos;this.eat(e););return this.pos>t},eatSpace:function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},skipToEnd:function(){this.pos=this.string.length},skipTo:function(e){var t=this.string.indexOf(e,this.pos);return t>-1?(this.pos=t,!0):void 0},backUp:function(e){this.pos-=e},column:function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=Ro(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?Ro(this.string,this.lineStart,this.tabSize):0)},indentation:function(){return Ro(this.string,null,this.tabSize)-(this.lineStart?Ro(this.string,this.lineStart,this.tabSize):0)},match:function(e,t,n){if("string"!=typeof e){var r=this.string.slice(this.pos).match(e);return r&&r.index>0?null:(r&&t!==!1&&(this.pos+=r[0].length),r)}var i=function(e){return n?e.toLowerCase():e},a=this.string.substr(this.pos,e.length);return i(a)==i(e)?(t!==!1&&(this.pos+=e.length),!0):void 0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}}};var go=0,vo=e.TextMarker=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++go};Ei(vo),vo.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&$t(e),Di(this,"clear")){var n=this.find();n&&Ci(this,"clear",n.from,n.to)}for(var r=null,i=null,a=0;a<this.lines.length;++a){var o=this.lines[a],s=er(o.markedSpans,this);e&&!this.collapsed?It(e,ti(o),"text"):e&&(null!=s.to&&(i=ti(o)),null!=s.from&&(r=ti(o))),o.markedSpans=tr(o.markedSpans,s),null==s.from&&this.collapsed&&!xr(this.doc,o)&&e&&ei(o,bt(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var a=0;a<this.lines.length;++a){var l=br(this.lines[a]),u=f(l);u>e.display.maxLineLength&&(e.display.maxLine=l,e.display.maxLineLength=u,e.display.maxLineChanged=!0)}null!=r&&e&&this.collapsed&&Pt(e,r,i+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&Ee(e.doc)),e&&Ci(e,"markerCleared",e,this),t&&xt(e),this.parent&&this.parent.clear()}},vo.prototype.find=function(e,t){null==e&&"bookmark"==this.type&&(e=1);for(var n,r,i=0;i<this.lines.length;++i){var a=this.lines[i],o=er(a.markedSpans,this);if(null!=o.from&&(n=Fa(t?a:ti(a),o.from),-1==e))return n;if(null!=o.to&&(r=Fa(t?a:ti(a),o.to),1==e))return r}return n&&{from:n,to:r}},vo.prototype.changed=function(){var e=this.find(-1,!0),t=this,n=this.doc.cm;e&&n&&Et(n,function(){var r=e.line,i=ti(e.line),a=Qe(n,i);if(a&&(at(a),n.curOp.selectionChanged=n.curOp.forceUpdate=!0),n.curOp.updateMaxLine=!0,!xr(t.doc,r)&&null!=t.height){var o=t.height;t.height=null;var s=Mr(t)-o;s&&ei(r,r.height+s)}})},vo.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;t.maybeHiddenMarkers&&-1!=ji(t.maybeHiddenMarkers,this)||(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},vo.prototype.detachLine=function(e){if(this.lines.splice(ji(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}};var go=0,bo=e.SharedTextMarker=function(e,t){this.markers=e,this.primary=t;for(var n=0;n<e.length;++n)e[n].parent=this};Ei(bo),bo.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();Ci(this,"clear")}},bo.prototype.find=function(e,t){return this.primary.find(e,t)};var yo=e.LineWidget=function(e,t,n){if(n)for(var r in n)n.hasOwnProperty(r)&&(this[r]=n[r]);this.doc=e,this.node=t};Ei(yo),yo.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,n=this.line,r=ti(n);if(null!=r&&t){for(var i=0;i<t.length;++i)t[i]==this&&t.splice(i--,1);t.length||(n.widgets=null);var a=Mr(this);ei(n,Math.max(0,n.height-a)),e&&Et(e,function(){Cr(e,n,-a),It(e,r,"widget")})}},yo.prototype.changed=function(){var e=this.height,t=this.doc.cm,n=this.line;this.height=null;var r=Mr(this)-e;r&&(ei(n,n.height+r),t&&Et(t,function(){t.curOp.forceUpdate=!0,Cr(t,n,r)}))};var $o=e.Line=function(e,t,n){this.text=e,cr(this,t),this.height=n?n(this):1};Ei($o),$o.prototype.lineNo=function(){return ti(this)};var wo={},xo={};Yr.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var n=e,r=e+t;r>n;++n){var i=this.lines[n];this.height-=i.height,Dr(i),Ci(i,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,n){this.height+=n,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var r=0;r<t.length;++r)t[r].parent=this},iterN:function(e,t,n){for(var r=e+t;r>e;++e)if(n(this.lines[e]))return!0}},Gr.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var n=0;n<this.children.length;++n){var r=this.children[n],i=r.chunkSize();if(i>e){var a=Math.min(t,i-e),o=r.height;if(r.removeInner(e,a),this.height-=o-r.height,i==a&&(this.children.splice(n--,1),r.parent=null),0==(t-=a))break;e=0}else e-=i}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof Yr))){var s=[];this.collapse(s),this.children=[new Yr(s)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,n){this.size+=t.length,this.height+=n;for(var r=0;r<this.children.length;++r){var i=this.children[r],a=i.chunkSize();if(a>=e){if(i.insertInner(e,t,n),i.lines&&i.lines.length>50){for(;i.lines.length>50;){var o=i.lines.splice(i.lines.length-25,25),s=new Yr(o);i.height-=s.height,this.children.splice(r+1,0,s),s.parent=this}this.maybeSpill()}break}e-=a}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=e.children.splice(e.children.length-5,5),n=new Gr(t);if(e.parent){e.size-=n.size,e.height-=n.height;var r=ji(e.parent.children,e);e.parent.children.splice(r+1,0,n)}else{var i=new Gr(e.children);i.parent=e,e.children=[i,n],e=i}n.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,n){for(var r=0;r<this.children.length;++r){var i=this.children[r],a=i.chunkSize();if(a>e){var o=Math.min(t,a-e);if(i.iterN(e,o,n))return!0;if(0==(t-=o))break;e=0}else e-=a}}};var ko=0,Co=e.Doc=function(e,t,n,r){if(!(this instanceof Co))return new Co(e,t,n,r);null==n&&(n=0),Gr.call(this,[new Yr([new $o("",null)])]),this.first=n,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.frontier=n;var i=Fa(n,0);this.sel=pe(i),this.history=new ai(null),this.id=++ko,this.modeOption=t,this.lineSep=r,this.extend=!1,"string"==typeof e&&(e=this.splitLines(e)),qr(this,{from:i,to:i,text:e}),Se(this,pe(i),Fo)};Co.prototype=Ii(Gr.prototype,{constructor:Co,iter:function(e,t,n){n?this.iterN(e-this.first,t-e,n):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var n=0,r=0;r<t.length;++r)n+=t[r].height;this.insertInner(e-this.first,t,n)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=Qr(this,this.first,this.first+this.size);return e===!1?t:t.join(e||this.lineSeparator())},setValue:Nt(function(e){var t=Fa(this.first,0),n=this.first+this.size-1;Sn(this,{from:t,to:Fa(n,Jr(this,n).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),Se(this,pe(t))}),replaceRange:function(e,t,n,r){t=me(this,t),n=n?me(this,n):t,Nn(this,e,t,n,r)},getRange:function(e,t,n){var r=Zr(this,me(this,e),me(this,t));return n===!1?r:r.join(n||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){return ve(this,e)?Jr(this,e):void 0},getLineNumber:function(e){return ti(e)},getLineHandleVisualStart:function(e){return"number"==typeof e&&(e=Jr(this,e)),br(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return me(this,e)},getCursor:function(e){var t,n=this.sel.primary();return t=null==e||"head"==e?n.head:"anchor"==e?n.anchor:"end"==e||"to"==e||e===!1?n.to():n.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Nt(function(e,t,n){ke(this,me(this,"number"==typeof e?Fa(e,t||0):e),null,n)}),setSelection:Nt(function(e,t,n){ke(this,me(this,e),me(this,t||e),n)}),extendSelection:Nt(function(e,t,n){$e(this,me(this,e),t&&me(this,t),n)}),extendSelections:Nt(function(e,t){we(this,be(this,e),t)}),extendSelectionsBy:Nt(function(e,t){var n=Li(this.sel.ranges,e);we(this,be(this,n),t)}),setSelections:Nt(function(e,t,n){if(e.length){for(var r=0,i=[];r<e.length;r++)i[r]=new fe(me(this,e[r].anchor),me(this,e[r].head));null==t&&(t=Math.min(e.length-1,this.sel.primIndex)),Se(this,de(i,t),n)}}),addSelection:Nt(function(e,t,n){var r=this.sel.ranges.slice(0);r.push(new fe(me(this,e),me(this,t||e))),Se(this,de(r,r.length-1),n)}),getSelection:function(e){for(var t,n=this.sel.ranges,r=0;r<n.length;r++){var i=Zr(this,n[r].from(),n[r].to());t=t?t.concat(i):i}return e===!1?t:t.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],n=this.sel.ranges,r=0;r<n.length;r++){var i=Zr(this,n[r].from(),n[r].to());e!==!1&&(i=i.join(e||this.lineSeparator())),t[r]=i}return t},replaceSelection:function(e,t,n){for(var r=[],i=0;i<this.sel.ranges.length;i++)r[i]=e;this.replaceSelections(r,t,n||"+input")},replaceSelections:Nt(function(e,t,n){for(var r=[],i=this.sel,a=0;a<i.ranges.length;a++){var o=i.ranges[a];r[a]={from:o.from(),to:o.to(),text:this.splitLines(e[a]),origin:n}}for(var s=t&&"end"!=t&&Cn(this,r,t),a=r.length-1;a>=0;a--)Sn(this,r[a]);s?Me(this,s):this.cm&&zn(this.cm)}),undo:Nt(function(){Dn(this,"undo")}),redo:Nt(function(){Dn(this,"redo")}),undoSelection:Nt(function(){Dn(this,"undo",!0)}),redoSelection:Nt(function(){Dn(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,n=0,r=0;r<e.done.length;r++)e.done[r].ranges||++t;for(var r=0;r<e.undone.length;r++)e.undone[r].ranges||++n;return{undo:t,redo:n}},clearHistory:function(){this.history=new ai(this.history.maxGeneration)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:gi(this.history.done),undone:gi(this.history.undone)}},setHistory:function(e){var t=this.history=new ai(this.history.maxGeneration);t.done=gi(e.done.slice(0),null,!0),t.undone=gi(e.undone.slice(0),null,!0)},addLineClass:Nt(function(e,t,n){return Hn(this,e,"gutter"==t?"gutter":"class",function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass";if(e[r]){if(qi(n).test(e[r]))return!1;e[r]+=" "+n}else e[r]=n;return!0})}),removeLineClass:Nt(function(e,t,n){return Hn(this,e,"gutter"==t?"gutter":"class",function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass",i=e[r];if(!i)return!1;if(null==n)e[r]=null;else{var a=i.match(qi(n));if(!a)return!1;var o=a.index+a[0].length;e[r]=i.slice(0,a.index)+(a.index&&o!=i.length?" ":"")+i.slice(o)||null}return!0})}),addLineWidget:Nt(function(e,t,n){return Sr(this,e,t,n)}),removeLineWidget:function(e){e.clear()},markText:function(e,t,n){return Gn(this,me(this,e),me(this,t),n,n&&n.type||"range")},setBookmark:function(e,t){var n={replacedWith:t&&(null==t.nodeType?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return e=me(this,e),Gn(this,e,e,n,"bookmark")},findMarksAt:function(e){e=me(this,e);var t=[],n=Jr(this,e.line).markedSpans;if(n)for(var r=0;r<n.length;++r){var i=n[r];(null==i.from||i.from<=e.ch)&&(null==i.to||i.to>=e.ch)&&t.push(i.marker.parent||i.marker)}return t},findMarks:function(e,t,n){e=me(this,e),t=me(this,t);var r=[],i=e.line;return this.iter(e.line,t.line+1,function(a){var o=a.markedSpans;if(o)for(var s=0;s<o.length;s++){var l=o[s];null!=l.to&&i==e.line&&e.ch>=l.to||null==l.from&&i!=e.line||null!=l.from&&i==t.line&&l.from>=t.ch||n&&!n(l.marker)||r.push(l.marker.parent||l.marker)}++i}),r},getAllMarks:function(){var e=[];return this.iter(function(t){var n=t.markedSpans;if(n)for(var r=0;r<n.length;++r)null!=n[r].from&&e.push(n[r].marker)}),e},posFromIndex:function(e){var t,n=this.first,r=this.lineSeparator().length;return this.iter(function(i){var a=i.text.length+r;return a>e?(t=e,!0):(e-=a,void++n)}),me(this,Fa(n,t))},indexFromPos:function(e){e=me(this,e);var t=e.ch;if(e.line<this.first||e.ch<0)return 0;var n=this.lineSeparator().length;return this.iter(this.first,e.line,function(e){t+=e.text.length+n}),t},copy:function(e){var t=new Co(Qr(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,n=this.first+this.size;null!=e.from&&e.from>t&&(t=e.from),null!=e.to&&e.to<n&&(n=e.to);var r=new Co(Qr(this,t,n),e.mode||this.modeOption,t,this.lineSep);return e.sharedHist&&(r.history=this.history),(this.linked||(this.linked=[])).push({doc:r,sharedHist:e.sharedHist}),r.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],Jn(r,Kn(this)),r},unlinkDoc:function(t){if(t instanceof e&&(t=t.doc),this.linked)for(var n=0;n<this.linked.length;++n){var r=this.linked[n];if(r.doc==t){this.linked.splice(n,1),t.unlinkDoc(this),Zn(Kn(this));break}}if(t.history==this.history){var i=[t.id];Xr(t,function(e){i.push(e.id)},!0),t.history=new ai(null),t.history.done=gi(this.history.done,i),t.history.undone=gi(this.history.undone,i)}},iterLinkedDocs:function(e){Xr(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):ts(e)},lineSeparator:function(){return this.lineSep||"\n"}}),Co.prototype.eachLine=Co.prototype.iter;var Mo="iter insert remove copy getEditor constructor".split(" ");for(var So in Co.prototype)Co.prototype.hasOwnProperty(So)&&ji(Mo,So)<0&&(e.prototype[So]=function(e){return function(){return e.apply(this.doc,arguments)}}(Co.prototype[So]));Ei(Co);var To=e.e_preventDefault=function(e){e.preventDefault?e.preventDefault():e.returnValue=!1},Do=e.e_stopPropagation=function(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},Eo=e.e_stop=function(e){To(e),Do(e)},Oo=e.on=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var r=e._handlers||(e._handlers={}),i=r[t]||(r[t]=[]);i.push(n)}},Ao=[],No=e.off=function(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else for(var r=ki(e,t,!1),i=0;i<r.length;++i)if(r[i]==n){r.splice(i,1);break}},jo=e.signal=function(e,t){var n=ki(e,t,!0);if(n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i<n.length;++i)n[i].apply(null,r)},Lo=null,Po=30,Io=e.Pass={toString:function(){return"CodeMirror.Pass"}},Fo={scroll:!1},zo={origin:"*mouse"},_o={origin:"+move"};Oi.prototype.set=function(e,t){clearTimeout(this.id),this.id=setTimeout(t,e)};var Ro=e.countColumn=function(e,t,n,r,i){null==t&&(t=e.search(/[^\s\u00a0]/),-1==t&&(t=e.length));for(var a=r||0,o=i||0;;){var s=e.indexOf(" ",a);if(0>s||s>=t)return o+(t-a);o+=s-a,o+=n-o%n,a=s+1}},Ho=e.findColumn=function(e,t,n){for(var r=0,i=0;;){var a=e.indexOf(" ",r);-1==a&&(a=e.length);var o=a-r;if(a==e.length||i+o>=t)return r+Math.min(o,t-i);if(i+=a-r,i+=n-i%n,r=a+1,i>=t)return r}},Uo=[""],Vo=function(e){e.select()};Ta?Vo=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:ba&&(Vo=function(e){try{e.select()}catch(t){}});var Wo,Bo=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,qo=e.isWordChar=function(e){return/\w/.test(e)||e>"€"&&(e.toUpperCase()!=e.toLowerCase()||Bo.test(e))},Yo=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;Wo=document.createRange?function(e,t,n,r){var i=document.createRange();return i.setEnd(r||e,n),i.setStart(e,t),i}:function(e,t,n){var r=document.body.createTextRange();try{r.moveToElementText(e.parentNode)}catch(i){return r}return r.collapse(!0),r.moveEnd("character",n),r.moveStart("character",t),r};var Go=e.contains=function(e,t){if(3==t.nodeType&&(t=t.parentNode),e.contains)return e.contains(t);do if(11==t.nodeType&&(t=t.host),t==e)return!0;while(t=t.parentNode)};ba&&11>ya&&(Bi=function(){try{return document.activeElement}catch(e){return document.body}});var Xo,Ko,Jo=e.rmClass=function(e,t){var n=e.className,r=qi(t).exec(n);if(r){var i=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(i?r[1]+i:"")}},Zo=e.addClass=function(e,t){var n=e.className;qi(t).test(n)||(e.className+=(n?" ":"")+t)},Qo=!1,es=function(){if(ba&&9>ya)return!1;var e=Ui("div");return"draggable"in e||"dragDrop"in e}(),ts=e.splitLines=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,n=[],r=e.length;r>=t;){var i=e.indexOf("\n",t);-1==i&&(i=e.length);var a=e.slice(t,"\r"==e.charAt(i-1)?i-1:i),o=a.indexOf("\r");-1!=o?(n.push(a.slice(0,o)),t+=o+1):(n.push(a),t=i+1)}return n}:function(e){return e.split(/\r\n?|\n/)},ns=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(t){return!1}}:function(e){try{var t=e.ownerDocument.selection.createRange()}catch(n){}return t&&t.parentElement()==e?0!=t.compareEndPoints("StartToEnd",t):!1;
},rs=function(){var e=Ui("div");return"oncopy"in e?!0:(e.setAttribute("oncopy","return;"),"function"==typeof e.oncopy)}(),is=null,as=e.keyNames={3:"Enter",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",127:"Delete",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"};!function(){for(var e=0;10>e;e++)as[e+48]=as[e+96]=String(e);for(var e=65;90>=e;e++)as[e]=String.fromCharCode(e);for(var e=1;12>=e;e++)as[e+111]=as[e+63235]="F"+e}();var os,ss=function(){function e(e){return 247>=e?n.charAt(e):e>=1424&&1524>=e?"R":e>=1536&&1773>=e?r.charAt(e-1536):e>=1774&&2220>=e?"r":e>=8192&&8203>=e?"w":8204==e?"b":"L"}function t(e,t,n){this.level=e,this.from=t,this.to=n}var n="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",r="rrrrrrrrrrrr,rNNmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmrrrrrrrnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmNmmmm",i=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,a=/[stwN]/,o=/[LRr]/,s=/[Lb1n]/,l=/[1n]/,u="L";return function(n){if(!i.test(n))return!1;for(var r,c=n.length,f=[],d=0;c>d;++d)f.push(r=e(n.charCodeAt(d)));for(var d=0,p=u;c>d;++d){var r=f[d];"m"==r?f[d]=p:p=r}for(var d=0,h=u;c>d;++d){var r=f[d];"1"==r&&"r"==h?f[d]="n":o.test(r)&&(h=r,"r"==r&&(f[d]="R"))}for(var d=1,p=f[0];c-1>d;++d){var r=f[d];"+"==r&&"1"==p&&"1"==f[d+1]?f[d]="1":","!=r||p!=f[d+1]||"1"!=p&&"n"!=p||(f[d]=p),p=r}for(var d=0;c>d;++d){var r=f[d];if(","==r)f[d]="N";else if("%"==r){for(var m=d+1;c>m&&"%"==f[m];++m);for(var g=d&&"!"==f[d-1]||c>m&&"1"==f[m]?"1":"N",v=d;m>v;++v)f[v]=g;d=m-1}}for(var d=0,h=u;c>d;++d){var r=f[d];"L"==h&&"1"==r?f[d]="L":o.test(r)&&(h=r)}for(var d=0;c>d;++d)if(a.test(f[d])){for(var m=d+1;c>m&&a.test(f[m]);++m);for(var b="L"==(d?f[d-1]:u),y="L"==(c>m?f[m]:u),g=b||y?"L":"R",v=d;m>v;++v)f[v]=g;d=m-1}for(var $,w=[],d=0;c>d;)if(s.test(f[d])){var x=d;for(++d;c>d&&s.test(f[d]);++d);w.push(new t(0,x,d))}else{var k=d,C=w.length;for(++d;c>d&&"L"!=f[d];++d);for(var v=k;d>v;)if(l.test(f[v])){v>k&&w.splice(C,0,new t(1,k,v));var M=v;for(++v;d>v&&l.test(f[v]);++v);w.splice(C,0,new t(2,M,v)),k=v}else++v;d>k&&w.splice(C,0,new t(1,k,d))}return 1==w[0].level&&($=n.match(/^\s+/))&&(w[0].from=$[0].length,w.unshift(new t(0,0,$[0].length))),1==Ni(w).level&&($=n.match(/\s+$/))&&(Ni(w).to-=$[0].length,w.push(new t(0,c-$[0].length,c))),2==w[0].level&&w.unshift(new t(1,w[0].to,w[0].to)),w[0].level!=Ni(w).level&&w.push(new t(w[0].level,c,c)),w}}();return e.version="5.14.2",e})},{}],"/home/stack/stackviz/node_modules/d3-array/build/d3-array.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_array={})}(this,function(e){"use strict";function t(e,t){return t>e?-1:e>t?1:e>=t?0:NaN}function n(e){return 1===e.length&&(e=r(e)),{left:function(t,n,r,i){for(null==r&&(r=0),null==i&&(i=t.length);i>r;){var a=r+i>>>1;e(t[a],n)<0?r=a+1:i=a}return r},right:function(t,n,r,i){for(null==r&&(r=0),null==i&&(i=t.length);i>r;){var a=r+i>>>1;e(t[a],n)>0?i=a:r=a+1}return r}}}function r(e){return function(n,r){return t(e(n),r)}}function i(e,t){return e>t?-1:t>e?1:t>=e?0:NaN}function a(e){return null===e?NaN:+e}function o(e,t){var n,r,i=e.length,o=0,s=0,l=-1,u=0;if(null==t)for(;++l<i;)isNaN(n=a(e[l]))||(r=n-o,o+=r/++u,s+=r*(n-o));else for(;++l<i;)isNaN(n=a(t(e[l],l,e)))||(r=n-o,o+=r/++u,s+=r*(n-o));return u>1?s/(u-1):void 0}function s(e,t){var n=o(e,t);return n?Math.sqrt(n):n}function l(e,t){var n,r,i,a=-1,o=e.length;if(null==t){for(;++a<o;)if(null!=(r=e[a])&&r>=r){n=i=r;break}for(;++a<o;)null!=(r=e[a])&&(n>r&&(n=r),r>i&&(i=r))}else{for(;++a<o;)if(null!=(r=t(e[a],a,e))&&r>=r){n=i=r;break}for(;++a<o;)null!=(r=t(e[a],a,e))&&(n>r&&(n=r),r>i&&(i=r))}return[n,i]}function u(e){return function(){return e}}function c(e){return e}function f(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):3>i?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((t-e)/n)),a=new Array(i);++r<i;)a[r]=e+r*n;return a}function d(e,t,n){var r=p(e,t,n);return f(Math.ceil(e/r)*r,Math.floor(t/r)*r+r/2,r)}function p(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),a=r/i;return a>=I?i*=10:a>=F?i*=5:a>=z&&(i*=2),e>t?-i:i}function h(e){return Math.ceil(Math.log(e.length)/Math.LN2)+1}function m(e){return+e}function g(){function e(e){var i,a,o=e.length,s=new Array(o);for(i=0;o>i;++i)s[i]=+t(e[i],i,e);var l=n(s),u=+l[0],c=+l[1],f=r(s,u,c);Array.isArray(f)||(f=d(u,c,+f));var p=f.length;for(i=0;p>i;++i)f[i]=+f[i];for(;f[0]<=u;)f.shift(),--p;for(;f[p-1]>=c;)f.pop(),--p;var h,m=new Array(p+1);for(i=0;p>=i;++i)h=m[i]=[],h.x0=i>0?f[i-1]:u,h.x1=p>i?f[i]:c;for(i=0;o>i;++i)a=s[i],a>=u&&c>=a&&m[L(f,a,0,p)].push(e[i]);return m}var t=c,n=l,r=h;return e.value=function(n){return arguments.length?(t="function"==typeof n?n:u(+n),e):t},e.domain=function(t){return arguments.length?(n="function"==typeof t?t:u([+t[0],+t[1]]),e):n},e.thresholds=function(t){return arguments.length?(r="function"==typeof t?t:u(Array.isArray(t)?Array.prototype.map.call(t,m):+t),e):r},e}function v(e,t,n){if(null==n&&(n=a),r=e.length){if((t=+t)<=0||2>r)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),s=+n(e[o],o,e),l=+n(e[o+1],o+1,e);return s+(l-s)*(i-o)}}function b(e,n,r){return e.sort(t),Math.ceil((r-n)/(2*(v(e,.75)-v(e,.25))*Math.pow(e.length,-1/3)))}function y(e,t,n){return Math.ceil((n-t)/(3.5*s(e)*Math.pow(e.length,-1/3)))}function $(e,t){var n,r,i=-1,a=e.length;if(null==t){for(;++i<a;)if(null!=(r=e[i])&&r>=r){n=r;break}for(;++i<a;)null!=(r=e[i])&&r>n&&(n=r)}else{for(;++i<a;)if(null!=(r=t(e[i],i,e))&&r>=r){n=r;break}for(;++i<a;)null!=(r=t(e[i],i,e))&&r>n&&(n=r)}return n}function w(e,t){var n,r=0,i=e.length,o=-1,s=i;if(null==t)for(;++o<i;)isNaN(n=a(e[o]))?--s:r+=n;else for(;++o<i;)isNaN(n=a(t(e[o],o,e)))?--s:r+=n;return s?r/s:void 0}function x(e,n){var r,i=[],o=e.length,s=-1;if(null==n)for(;++s<o;)isNaN(r=a(e[s]))||i.push(r);else for(;++s<o;)isNaN(r=a(n(e[s],s,e)))||i.push(r);return v(i.sort(t),.5)}function k(e){for(var t,n,r,i=e.length,a=-1,o=0;++a<i;)o+=e[a].length;for(n=new Array(o);--i>=0;)for(r=e[i],t=r.length;--t>=0;)n[--o]=r[t];return n}function C(e,t){var n,r,i=-1,a=e.length;if(null==t){for(;++i<a;)if(null!=(r=e[i])&&r>=r){n=r;break}for(;++i<a;)null!=(r=e[i])&&n>r&&(n=r)}else{for(;++i<a;)if(null!=(r=t(e[i],i,e))&&r>=r){n=r;break}for(;++i<a;)null!=(r=t(e[i],i,e))&&n>r&&(n=r)}return n}function M(e){for(var t=0,n=e.length-1,r=e[0],i=new Array(0>n?0:n);n>t;)i[t]=[r,r=e[++t]];return i}function S(e,t){for(var n=t.length,r=new Array(n);n--;)r[n]=e[t[n]];return r}function T(e,n){if(r=e.length){var r,i,a=0,o=0,s=e[o];for(n||(n=t);++a<r;)(n(i=e[a],s)<0||0!==n(s,s))&&(s=i,o=a);return 0===n(s,s)?o:void 0}}function D(e,t,n){for(var r,i,a=(null==n?e.length:n)-(t=null==t?0:+t);a;)i=Math.random()*a--|0,r=e[a+t],e[a+t]=e[i+t],e[i+t]=r;return e}function E(e,t){var n,r=0,i=e.length,a=-1;if(null==t)for(;++a<i;)(n=+e[a])&&(r+=n);else for(;++a<i;)(n=+t(e[a],a,e))&&(r+=n);return r}function O(e){if(!(i=e.length))return[];for(var t=-1,n=C(e,A),r=new Array(n);++t<n;)for(var i,a=-1,o=r[t]=new Array(i);++a<i;)o[a]=e[a][t];return r}function A(e){return e.length}function N(){return O(arguments)}var j=n(t),L=j.right,P=j.left,I=Math.sqrt(50),F=Math.sqrt(10),z=Math.sqrt(2),_="0.7.1";e.version=_,e.bisect=L,e.bisectRight=L,e.bisectLeft=P,e.ascending=t,e.bisector=n,e.descending=i,e.deviation=s,e.extent=l,e.histogram=g,e.thresholdFreedmanDiaconis=b,e.thresholdScott=y,e.thresholdSturges=h,e.max=$,e.mean=w,e.median=x,e.merge=k,e.min=C,e.pairs=M,e.permute=S,e.quantile=v,e.range=f,e.scan=T,e.shuffle=D,e.sum=E,e.ticks=d,e.tickStep=p,e.transpose=O,e.variance=o,e.zip=N})},{}],"/home/stack/stackviz/node_modules/d3-collection/build/d3-collection.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_collection=e.d3_collection||{})}(this,function(e){"use strict";function t(){}function n(e,n){var r=new t;if(e instanceof t)e.each(function(e,t){r.set(t,e)});else if(Array.isArray(e)){var i,a=-1,o=e.length;if(null==n)for(;++a<o;)r.set(a,e[a]);else for(;++a<o;)r.set(n(i=e[a],a,e),i)}else if(e)for(var s in e)r.set(s,e[s]);return r}function r(){function e(t,i,a,o){if(i>=c.length)return null!=l?l(t):null!=r?t.sort(r):t;for(var s,u,f,d=-1,p=t.length,h=c[i++],m=n(),g=a();++d<p;)(f=m.get(s=h(u=t[d])+""))?f.push(u):m.set(s,[u]);return m.each(function(t,n){o(g,n,e(t,i,a,o))}),g}function t(e,n){if(++n>c.length)return e;var r,i=f[n-1];return null!=l&&n>=c.length?r=e.entries():(r=[],e.each(function(e,i){r.push({key:i,values:t(e,n)})})),null!=i?r.sort(function(e,t){return i(e.key,t.key)}):r}var r,l,u,c=[],f=[];return u={object:function(t){return e(t,0,i,a)},map:function(t){return e(t,0,o,s)},entries:function(n){return t(e(n,0,o,s),0)},key:function(e){return c.push(e),u},sortKeys:function(e){return f[c.length-1]=e,u},sortValues:function(e){return r=e,u},rollup:function(e){return l=e,u}}}function i(){return{}}function a(e,t,n){e[t]=n}function o(){return n()}function s(e,t,n){e.set(t,n)}function l(){}function u(e,t){var n=new l;if(e instanceof l)e.each(function(e){n.add(e)});else if(e){var r=-1,i=e.length;if(null==t)for(;++r<i;)n.add(e[r]);else for(;++r<i;)n.add(t(e[r],r,e))}return n}function c(e){var t=[];for(var n in e)t.push(n);return t}function f(e){var t=[];for(var n in e)t.push(e[n]);return t}function d(e){var t=[];for(var n in e)t.push({key:n,value:e[n]});return t}var p="0.2.0",h="$";t.prototype=n.prototype={constructor:t,has:function(e){return h+e in this},get:function(e){return this[h+e]},set:function(e,t){return this[h+e]=t,this},remove:function(e){var t=h+e;return t in this&&delete this[t]},clear:function(){for(var e in this)e[0]===h&&delete this[e]},keys:function(){var e=[];for(var t in this)t[0]===h&&e.push(t.slice(1));return e},values:function(){var e=[];for(var t in this)t[0]===h&&e.push(this[t]);return e},entries:function(){var e=[];for(var t in this)t[0]===h&&e.push({key:t.slice(1),value:this[t]});return e},size:function(){var e=0;for(var t in this)t[0]===h&&++e;return e},empty:function(){for(var e in this)if(e[0]===h)return!1;return!0},each:function(e){for(var t in this)t[0]===h&&e(this[t],t.slice(1),this)}};var m=n.prototype;l.prototype=u.prototype={constructor:l,has:m.has,add:function(e){return e+="",this[h+e]=e,this},remove:m.remove,clear:m.clear,values:m.keys,size:m.size,empty:m.empty,each:m.each},e.version=p,e.nest=r,e.set=u,e.map=n,e.keys=c,e.values=f,e.entries=d})},{}],"/home/stack/stackviz/node_modules/d3-dsv/build/d3-dsv.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_dsv=e.d3_dsv||{})}(this,function(e){"use strict";function t(e){return new Function("d","return {"+e.map(function(e,t){return JSON.stringify(e)+": d["+t+"]"}).join(",")+"}")}function n(e,n){var r=t(e);return function(t,i){return n(r(t),i,e)}}function r(e){var t=Object.create(null),n=[];return e.forEach(function(e){for(var r in e)r in t||n.push(t[r]=r)}),n}function i(e){function i(e,r){var i,o,s=a(e,function(e,a){return i?i(e,a-1):(o=e,void(i=r?n(e,r):t(e)))});return s.columns=o,s}function a(e,t){function n(){if(u>=l)return o;if(i)return i=!1,a;var t,n=u;if(34===e.charCodeAt(n)){for(var r=n;r++<l;)if(34===e.charCodeAt(r)){if(34!==e.charCodeAt(r+1))break;++r}return u=r+2,t=e.charCodeAt(r+1),13===t?(i=!0,10===e.charCodeAt(r+2)&&++u):10===t&&(i=!0),e.slice(n+1,r).replace(/""/g,'"')}for(;l>u;){var s=1;if(t=e.charCodeAt(u++),10===t)i=!0;else if(13===t)i=!0,10===e.charCodeAt(u)&&(++u,++s);else if(t!==f)continue;return e.slice(n,u-s)}return e.slice(n)}for(var r,i,a={},o={},s=[],l=e.length,u=0,c=0;(r=n())!==o;){for(var d=[];r!==a&&r!==o;)d.push(r),r=n();t&&null==(d=t(d,c++))||s.push(d)}return s}function o(t,n){return null==n&&(n=r(t)),[n.map(u).join(e)].concat(t.map(function(t){return n.map(function(e){return u(t[e])}).join(e)})).join("\n")}function s(e){return e.map(l).join("\n")}function l(t){return t.map(u).join(e)}function u(e){return null==e?"":c.test(e+="")?'"'+e.replace(/\"/g,'""')+'"':e}var c=new RegExp('["'+e+"\n]"),f=e.charCodeAt(0);return{parse:i,parseRows:a,format:o,formatRows:s}}var a="0.3.2",o=i(","),s=o.parse,l=o.parseRows,u=o.format,c=o.formatRows,f=i(" "),d=f.parse,p=f.parseRows,h=f.format,m=f.formatRows;e.version=a,e.dsvFormat=i,e.csvParse=s,e.csvParseRows=l,e.csvFormat=u,e.csvFormatRows=c,e.tsvParse=d,e.tsvParseRows=p,e.tsvFormat=h,e.tsvFormatRows=m})},{}],"/home/stack/stackviz/node_modules/d3-ease/build/d3-ease.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_ease={})}(this,function(e){"use strict";function t(e){return+e}function n(e){return e*e}function r(e){return e*(2-e)}function i(e){return((e*=2)<=1?e*e:--e*(2-e)+1)/2}function a(e){return e*e*e}function o(e){return--e*e*e+1}function s(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}function l(e){return 1-Math.cos(e*M)}function u(e){return Math.sin(e*M)}function c(e){return(1-Math.cos(C*e))/2}function f(e){return Math.pow(2,10*e-10)}function d(e){return 1-Math.pow(2,-10*e)}function p(e){return((e*=2)<=1?Math.pow(2,10*e-10):2-Math.pow(2,10-10*e))/2}function h(e){return 1-Math.sqrt(1-e*e)}function m(e){return Math.sqrt(1- --e*e)}function g(e){return((e*=2)<=1?1-Math.sqrt(1-e*e):Math.sqrt(1-(e-=2)*e)+1)/2}function v(e){return 1-b(1-e)}function b(e){return(e=+e)<S?P*e*e:D>e?P*(e-=T)*e+E:A>e?P*(e-=O)*e+N:P*(e-=j)*e+L}function y(e){return((e*=2)<=1?1-b(1-e):b(e-1)+1)/2}var $=3,w=function Y(e){function t(t){return Math.pow(t,e)}return e=+e,t.exponent=Y,t}($),x=function G(e){function t(t){return 1-Math.pow(1-t,e)}return e=+e,t.exponent=G,t}($),k=function X(e){function t(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,t.exponent=X,t}($),C=Math.PI,M=C/2,S=4/11,T=6/11,D=8/11,E=.75,O=9/11,A=10/11,N=.9375,j=21/22,L=63/64,P=1/S/S,I=1.70158,F=function K(e){function t(t){return t*t*((e+1)*t-e)}return e=+e,t.overshoot=K,t}(I),z=function J(e){function t(t){return--t*t*((e+1)*t+e)+1}return e=+e,t.overshoot=J,t}(I),_=function Z(e){function t(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,t.overshoot=Z,t}(I),R=2*Math.PI,H=1,U=.3,V=function Q(e,t){function n(n){return e*Math.pow(2,10*--n)*Math.sin((r-n)/t)}var r=Math.asin(1/(e=Math.max(1,e)))*(t/=R);return n.amplitude=function(e){return Q(e,t*R)},n.period=function(t){return Q(e,t)},n}(H,U),W=function ee(e,t){function n(n){return 1-e*Math.pow(2,-10*(n=+n))*Math.sin((n+r)/t)}var r=Math.asin(1/(e=Math.max(1,e)))*(t/=R);return n.amplitude=function(e){return ee(e,t*R)},n.period=function(t){return ee(e,t)},n}(H,U),B=function te(e,t){function n(n){return((n=2*n-1)<0?e*Math.pow(2,10*n)*Math.sin((r-n)/t):2-e*Math.pow(2,-10*n)*Math.sin((r+n)/t))/2}var r=Math.asin(1/(e=Math.max(1,e)))*(t/=R);return n.amplitude=function(e){return te(e,t*R)},n.period=function(t){return te(e,t)},n}(H,U),q="0.7.0";e.version=q,e.easeLinear=t,e.easeQuad=i,e.easeQuadIn=n,e.easeQuadOut=r,e.easeQuadInOut=i,e.easeCubic=s,e.easeCubicIn=a,e.easeCubicOut=o,e.easeCubicInOut=s,e.easePoly=k,e.easePolyIn=w,e.easePolyOut=x,e.easePolyInOut=k,e.easeSin=c,e.easeSinIn=l,e.easeSinOut=u,e.easeSinInOut=c,e.easeExp=p,e.easeExpIn=f,e.easeExpOut=d,e.easeExpInOut=p,e.easeCircle=g,e.easeCircleIn=h,e.easeCircleOut=m,e.easeCircleInOut=g,e.easeBounce=b,e.easeBounceIn=v,e.easeBounceOut=b,e.easeBounceInOut=y,e.easeBack=_,e.easeBackIn=F,e.easeBackOut=z,e.easeBackInOut=_,e.easeElastic=W,e.easeElasticIn=V,e.easeElasticOut=W,e.easeElasticInOut=B})},{}],"/home/stack/stackviz/node_modules/d3-interpolate/build/d3-interpolate.js":[function(e,t,n){!function(r,i){"object"==typeof n&&"undefined"!=typeof t?i(n,e("d3-color")):"function"==typeof define&&define.amd?define(["exports","d3-color"],i):i(r.d3_interpolate=r.d3_interpolate||{},r.d3_color)}(this,function(e,t){"use strict";function n(e){return function(){return e}}function r(e,t){return function(n){return e+n*t}}function i(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function a(e,t){var i=t-e;return i?r(e,i>180||-180>i?i-360*Math.round(i/360):i):n(isNaN(e)?t:e)}function o(e){return 1===(e=+e)?s:function(t,r){return r-t?i(t,r,e):n(isNaN(t)?r:t)}}function s(e,t){var i=t-e;return i?r(e,i):n(isNaN(e)?t:e)}function l(e,t){var n,r=[],i=[],a=e?e.length:0,o=t?t.length:0,s=Math.min(a,o);for(n=0;s>n;++n)r.push(h(e[n],t[n]));for(;a>n;++n)i[n]=e[n];for(;o>n;++n)i[n]=t[n];return function(e){for(n=0;s>n;++n)i[n]=r[n](e);return i}}function u(e,t){return e=+e,t-=e,function(n){return e+t*n}}function c(e,t){var n,r={},i={};null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={});for(n in e)n in t?r[n]=h(e[n],t[n]):i[n]=e[n];for(n in t)n in e||(i[n]=t[n]);return function(e){for(n in r)i[n]=r[n](e);return i}}function f(e){return function(){return e}}function d(e){return function(t){return e(t)+""}}function p(e,t){var n,r,i,a=L.lastIndex=P.lastIndex=0,o=-1,s=[],l=[];for(e+="",t+="";(n=L.exec(e))&&(r=P.exec(t));)(i=r.index)>a&&(i=t.slice(a,i),s[o]?s[o]+=i:s[++o]=i),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,l.push({i:o,x:u(n,r)})),a=P.lastIndex;return a<t.length&&(i=t.slice(a),s[o]?s[o]+=i:s[++o]=i),s.length<2?l[0]?d(l[0].x):f(t):(t=l.length,function(e){for(var n,r=0;t>r;++r)s[(n=l[r]).i]=n.x(e);return s.join("")})}function h(e,r){var i,a=typeof r;return null==r||"boolean"===a?n(r):("number"===a?u:"string"===a?(i=t.color(r))?(r=i,j):p:r instanceof t.color?j:Array.isArray(r)?l:c)(e,r)}function m(e,t){return e=+e,t-=e,function(n){return Math.round(e+t*n)}}function g(e,t,n,r,i,a){if(e*r===t*n)return null;var o=Math.sqrt(e*e+t*t);e/=o,t/=o;var s=e*n+t*r;n-=e*s,r-=t*s;var l=Math.sqrt(n*n+r*r);return n/=l,r/=l,s/=l,t*n>e*r&&(e=-e,t=-t,s=-s,o=-o),{translateX:i,translateY:a,rotate:Math.atan2(t,e)*I,skewX:Math.atan(s)*I,scaleX:o,scaleY:l}}function v(e){if("none"===e)return F;E||(E=document.createElement("DIV"),O=document.documentElement,A=document.defaultView),E.style.transform=e,e=A.getComputedStyle(O.appendChild(E),null).getPropertyValue("transform"),O.removeChild(E);var t=e.slice(7,-1).split(",");return g(+t[0],+t[1],+t[2],+t[3],+t[4],+t[5])}function b(e){N||(N=document.createElementNS("http://www.w3.org/2000/svg","g")),N.setAttribute("transform",null==e?"":e);var t=N.transform.baseVal.consolidate().matrix;return g(t.a,t.b,t.c,t.d,t.e,t.f)}function y(e,t,n,r){function i(e){return e.length?e.pop()+" ":""}function a(e,r,i,a,o,s){if(e!==i||r!==a){var l=o.push("translate(",null,t,null,n);s.push({i:l-4,x:u(e,i)},{i:l-2,x:u(r,a)})}else(i||a)&&o.push("translate("+i+t+a+n)}function o(e,t,n,a){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(i(n)+"rotate(",null,r)-2,x:u(e,t)})):t&&n.push(i(n)+"rotate("+t+r)}function s(e,t,n,a){e!==t?a.push({i:n.push(i(n)+"skewX(",null,r)-2,x:u(e,t)}):t&&n.push(i(n)+"skewX("+t+r)}function l(e,t,n,r,a,o){if(e!==n||t!==r){var s=a.push(i(a)+"scale(",null,",",null,")");o.push({i:s-4,x:u(e,n)},{i:s-2,x:u(t,r)})}else 1===n&&1===r||a.push(i(a)+"scale("+n+","+r+")")}return function(t,n){var r=[],i=[];return t=e(t),n=e(n),a(t.translateX,t.translateY,n.translateX,n.translateY,r,i),o(t.rotate,n.rotate,r,i),s(t.skewX,n.skewX,r,i),l(t.scaleX,t.scaleY,n.scaleX,n.scaleY,r,i),t=n=null,function(e){for(var t,n=-1,a=i.length;++n<a;)r[(t=i[n]).i]=t.x(e);return r.join("")}}}function $(e){return((e=Math.exp(e))+1/e)/2}function w(e){return((e=Math.exp(e))-1/e)/2}function x(e){return((e=Math.exp(2*e))-1)/(e+1)}function k(e,t){var n,r,i=e[0],a=e[1],o=e[2],s=t[0],l=t[1],u=t[2],c=s-i,f=l-a,d=c*c+f*f;if(V>d)r=Math.log(u/o)/R,n=function(e){return[i+e*c,a+e*f,o*Math.exp(R*e*r)]};else{var p=Math.sqrt(d),h=(u*u-o*o+U*d)/(2*o*H*p),m=(u*u-o*o-U*d)/(2*u*H*p),g=Math.log(Math.sqrt(h*h+1)-h),v=Math.log(Math.sqrt(m*m+1)-m);r=(v-g)/R,n=function(e){var t=e*r,n=$(g),s=o/(H*p)*(n*x(R*t+g)-w(g));return[i+s*c,a+s*f,o*n/$(R*t+g)]}}return n.duration=1e3*r,n}function C(e,n){var r=a((e=t.hsl(e)).h,(n=t.hsl(n)).h),i=s(e.s,n.s),o=s(e.l,n.l),l=s(e.opacity,n.opacity);return function(t){return e.h=r(t),e.s=i(t),e.l=o(t),e.opacity=l(t),e+""}}function M(e,n){var r=s((e=t.hsl(e)).h,(n=t.hsl(n)).h),i=s(e.s,n.s),a=s(e.l,n.l),o=s(e.opacity,n.opacity);return function(t){return e.h=r(t),e.s=i(t),e.l=a(t),e.opacity=o(t),e+""}}function S(e,n){var r=s((e=t.lab(e)).l,(n=t.lab(n)).l),i=s(e.a,n.a),a=s(e.b,n.b),o=s(e.opacity,n.opacity);return function(t){return e.l=r(t),e.a=i(t),e.b=a(t),e.opacity=o(t),e+""}}function T(e,n){var r=a((e=t.hcl(e)).h,(n=t.hcl(n)).h),i=s(e.c,n.c),o=s(e.l,n.l),l=s(e.opacity,n.opacity);return function(t){return e.h=r(t),e.c=i(t),e.l=o(t),e.opacity=l(t),e+""}}function D(e,n){var r=s((e=t.hcl(e)).h,(n=t.hcl(n)).h),i=s(e.c,n.c),a=s(e.l,n.l),o=s(e.opacity,n.opacity);return function(t){return e.h=r(t),e.c=i(t),e.l=a(t),e.opacity=o(t),e+""}}var E,O,A,N,j=function Y(e){function n(e,n){var i=r((e=t.rgb(e)).r,(n=t.rgb(n)).r),a=r(e.g,n.g),o=r(e.b,n.b),s=r(e.opacity,n.opacity);return function(t){return e.r=i(t),e.g=a(t),e.b=o(t),e.opacity=s(t),e+""}}var r=o(e);return n.gamma=Y,n}(1),L=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,P=new RegExp(L.source,"g"),I=180/Math.PI,F={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},z=y(v,"px, ","px)","deg)"),_=y(b,", ",")",")"),R=Math.SQRT2,H=2,U=4,V=1e-12,W=function G(e){function n(n,r){var i=a((n=t.cubehelix(n)).h,(r=t.cubehelix(r)).h),o=s(n.s,r.s),l=s(n.l,r.l),u=s(n.opacity,r.opacity);return function(t){return n.h=i(t),n.s=o(t),n.l=l(Math.pow(t,e)),n.opacity=u(t),n+""}}return e=+e,n.gamma=G,n}(1),B=function X(e){function n(n,r){var i=s((n=t.cubehelix(n)).h,(r=t.cubehelix(r)).h),a=s(n.s,r.s),o=s(n.l,r.l),l=s(n.opacity,r.opacity);return function(t){return n.h=i(t),n.s=a(t),n.l=o(Math.pow(t,e)),n.opacity=l(t),n+""}}return e=+e,n.gamma=X,n}(1),q="0.7.0";e.version=q,e.interpolate=h,e.interpolateArray=l,e.interpolateNumber=u,e.interpolateObject=c,e.interpolateRound=m,e.interpolateString=p,e.interpolateTransformCss=z,e.interpolateTransformSvg=_,e.interpolateZoom=k,e.interpolateRgb=j,e.interpolateHsl=C,e.interpolateHslLong=M,e.interpolateLab=S,e.interpolateHcl=T,e.interpolateHclLong=D,e.interpolateCubehelix=W,e.interpolateCubehelixLong=B})},{"d3-color":"/home/stack/stackviz/node_modules/d3-interpolate/node_modules/d3-color/build/d3-color.js"}],"/home/stack/stackviz/node_modules/d3-interpolate/node_modules/d3-color/build/d3-color.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_color=e.d3_color||{})}(this,function(e){"use strict";function t(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function n(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function r(){}function i(e){var t;return e=(e+"").trim().toLowerCase(),(t=O.exec(e))?(t=parseInt(t[1],16),new u(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1)):(t=A.exec(e))?a(parseInt(t[1],16)):(t=N.exec(e))?new u(t[1],t[2],t[3],1):(t=j.exec(e))?new u(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=L.exec(e))?o(t[1],t[2],t[3],t[4]):(t=P.exec(e))?o(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=I.exec(e))?c(t[1],t[2]/100,t[3]/100,1):(t=F.exec(e))?c(t[1],t[2]/100,t[3]/100,t[4]):z.hasOwnProperty(e)?a(z[e]):"transparent"===e?new u(NaN,NaN,NaN,0):null}function a(e){return new u(e>>16&255,e>>8&255,255&e,1)}function o(e,t,n,r){return 0>=r&&(e=t=n=NaN),new u(e,t,n,r)}function s(e){return e instanceof r||(e=i(e)),e?(e=e.rgb(),new u(e.r,e.g,e.b,e.opacity)):new u}function l(e,t,n,r){return 1===arguments.length?s(e):new u(e,t,n,null==r?1:r)}function u(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function c(e,t,n,r){return 0>=r?e=t=n=NaN:0>=n||n>=1?e=t=NaN:0>=t&&(e=NaN),new p(e,t,n,r)}function f(e){if(e instanceof p)return new p(e.h,e.s,e.l,e.opacity);if(e instanceof r||(e=i(e)),!e)return new p;if(e instanceof p)return e;e=e.rgb();var t=e.r/255,n=e.g/255,a=e.b/255,o=Math.min(t,n,a),s=Math.max(t,n,a),l=NaN,u=s-o,c=(s+o)/2;return u?(l=t===s?(n-a)/u+6*(a>n):n===s?(a-t)/u+2:(t-n)/u+4,u/=.5>c?s+o:2-s-o,l*=60):u=c>0&&1>c?0:l,new p(l,u,c,e.opacity)}function d(e,t,n,r){return 1===arguments.length?f(e):new p(e,t,n,null==r?1:r)}function p(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function h(e,t,n){return 255*(60>e?t+(n-t)*e/60:180>e?n:240>e?t+(n-t)*(240-e)/60:t)}function m(e){if(e instanceof v)return new v(e.l,e.a,e.b,e.opacity);if(e instanceof C){var t=e.h*_;return new v(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}e instanceof u||(e=s(e));var n=w(e.r),r=w(e.g),i=w(e.b),a=b((.4124564*n+.3575761*r+.1804375*i)/U),o=b((.2126729*n+.7151522*r+.072175*i)/V),l=b((.0193339*n+.119192*r+.9503041*i)/W);return new v(116*o-16,500*(a-o),200*(o-l),e.opacity)}function g(e,t,n,r){return 1===arguments.length?m(e):new v(e,t,n,null==r?1:r)}function v(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function b(e){return e>G?Math.pow(e,1/3):e/Y+B}function y(e){return e>q?e*e*e:Y*(e-B)}function $(e){return 255*(.0031308>=e?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function w(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function x(e){if(e instanceof C)return new C(e.h,e.c,e.l,e.opacity);e instanceof v||(e=m(e));var t=Math.atan2(e.b,e.a)*R;return new C(0>t?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function k(e,t,n,r){return 1===arguments.length?x(e):new C(e,t,n,null==r?1:r)}function C(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function M(e){if(e instanceof T)return new T(e.h,e.s,e.l,e.opacity);e instanceof u||(e=s(e));var t=e.r/255,n=e.g/255,r=e.b/255,i=(ne*r+ee*t-te*n)/(ne+ee-te),a=r-i,o=(Q*(n-i)-J*a)/Z,l=Math.sqrt(o*o+a*a)/(Q*i*(1-i)),c=l?Math.atan2(o,a)*R-120:NaN;return new T(0>c?c+360:c,l,i,e.opacity)}function S(e,t,n,r){return 1===arguments.length?M(e):new T(e,t,n,null==r?1:r)}function T(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}var D=.7,E=1/D,O=/^#([0-9a-f]{3})$/,A=/^#([0-9a-f]{6})$/,N=/^rgb\(\s*([-+]?\d+)\s*,\s*([-+]?\d+)\s*,\s*([-+]?\d+)\s*\)$/,j=/^rgb\(\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*\)$/,L=/^rgba\(\s*([-+]?\d+)\s*,\s*([-+]?\d+)\s*,\s*([-+]?\d+)\s*,\s*([-+]?\d+(?:\.\d+)?)\s*\)$/,P=/^rgba\(\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)\s*\)$/,I=/^hsl\(\s*([-+]?\d+(?:\.\d+)?)\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*\)$/,F=/^hsla\(\s*([-+]?\d+(?:\.\d+)?)\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)%\s*,\s*([-+]?\d+(?:\.\d+)?)\s*\)$/,z={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};t(r,i,{displayable:function(){return this.rgb().displayable()},toString:function(){return this.rgb()+""}}),t(u,l,n(r,{brighter:function(e){return e=null==e?E:Math.pow(E,e),new u(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?D:Math.pow(D,e),new u(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},toString:function(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(1===e?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}})),t(p,d,n(r,{brighter:function(e){return e=null==e?E:Math.pow(E,e),new p(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?D:Math.pow(D,e),new p(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(.5>n?n:1-n)*t,i=2*n-r;return new u(h(e>=240?e-240:e+120,i,r),h(e,i,r),h(120>e?e+240:e-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var _=Math.PI/180,R=180/Math.PI,H=18,U=.95047,V=1,W=1.08883,B=4/29,q=6/29,Y=3*q*q,G=q*q*q;t(v,g,n(r,{brighter:function(e){return new v(this.l+H*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new v(this.l-H*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return e=V*y(e),t=U*y(t),n=W*y(n),new u($(3.2404542*t-1.5371385*e-.4985314*n),$(-.969266*t+1.8760108*e+.041556*n),$(.0556434*t-.2040259*e+1.0572252*n),this.opacity)}})),t(C,k,n(r,{brighter:function(e){return new C(this.h,this.c,this.l+H*(null==e?1:e),this.opacity)},darker:function(e){return new C(this.h,this.c,this.l-H*(null==e?1:e),this.opacity);
},rgb:function(){return m(this).rgb()}}));var X=-.14861,K=1.78277,J=-.29227,Z=-.90649,Q=1.97294,ee=Q*Z,te=Q*K,ne=K*J-Z*X;t(T,S,n(r,{brighter:function(e){return e=null==e?E:Math.pow(E,e),new T(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?D:Math.pow(D,e),new T(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*_,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),i=Math.sin(e);return new u(255*(t+n*(X*r+K*i)),255*(t+n*(J*r+Z*i)),255*(t+n*(Q*r)),this.opacity)}}));var re="0.4.2";e.version=re,e.color=i,e.rgb=l,e.hsl=d,e.lab=g,e.hcl=k,e.cubehelix=S})},{}],"/home/stack/stackviz/node_modules/d3-scale/build/d3-scale.js":[function(e,t,n){!function(r,i){"object"==typeof n&&"undefined"!=typeof t?i(n,e("d3-array"),e("d3-collection"),e("d3-interpolate"),e("d3-format"),e("d3-time"),e("d3-time-format"),e("d3-color")):"function"==typeof define&&define.amd?define(["exports","d3-array","d3-collection","d3-interpolate","d3-format","d3-time","d3-time-format","d3-color"],i):i(r.d3_scale=r.d3_scale||{},r.d3_array,r.d3_collection,r.d3_interpolate,r.d3_format,r.d3_time,r.d3_time_format,r.d3_color)}(this,function(e,t,n,r,i,a,o,s){"use strict";function l(){function e(e){var n=e+"",o=t.get(n);if(!o){if(a!==le)return a;t.set(n,o=r.push(e))}return i[(o-1)%i.length]}var t=n.map(),r=[],i=[],a=le;return e.domain=function(i){if(!arguments.length)return r.slice();r=[],t=n.map();for(var a,o,s=-1,l=i.length;++s<l;)t.has(o=(a=i[s])+"")||t.set(o,r.push(a));return e},e.range=function(t){return arguments.length?(i=se.call(t),e):i.slice()},e.unknown=function(t){return arguments.length?(a=t,e):a},e.copy=function(){return l().domain(r).range(i).unknown(a)},e}function u(){function e(){var e=a().length,i=s[1]<s[0],l=s[i-0],u=s[1-i];n=(u-l)/Math.max(1,e-f+2*d),c&&(n=Math.floor(n)),l+=(u-l-n*(e-f))*p,r=n*(1-f),c&&(l=Math.round(l),r=Math.round(r));var h=t.range(e).map(function(e){return l+n*e});return o(i?h.reverse():h)}var n,r,i=l().unknown(void 0),a=i.domain,o=i.range,s=[0,1],c=!1,f=0,d=0,p=.5;return delete i.unknown,i.domain=function(t){return arguments.length?(a(t),e()):a()},i.range=function(t){return arguments.length?(s=[+t[0],+t[1]],e()):s.slice()},i.rangeRound=function(t){return s=[+t[0],+t[1]],c=!0,e()},i.bandwidth=function(){return r},i.step=function(){return n},i.round=function(t){return arguments.length?(c=!!t,e()):c},i.padding=function(t){return arguments.length?(f=d=Math.max(0,Math.min(1,t)),e()):f},i.paddingInner=function(t){return arguments.length?(f=Math.max(0,Math.min(1,t)),e()):f},i.paddingOuter=function(t){return arguments.length?(d=Math.max(0,Math.min(1,t)),e()):d},i.align=function(t){return arguments.length?(p=Math.max(0,Math.min(1,t)),e()):p},i.copy=function(){return u().domain(a()).range(s).round(c).paddingInner(f).paddingOuter(d).align(p)},e()}function c(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return c(t())},e}function f(){return c(u().paddingInner(1))}function d(e){return function(){return e}}function p(e){return+e}function h(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:d(t)}function m(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return t>=e?0:e>=n?1:r(e)}}}function g(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return 0>=e?t:e>=1?n:r(e)}}}function v(e,t,n,r){var i=e[0],a=e[1],o=t[0],s=t[1];return i>a?(i=n(a,i),o=r(s,o)):(i=n(i,a),o=r(o,s)),function(e){return o(i(e))}}function b(e,n,r,i){var a=Math.min(e.length,n.length)-1,o=new Array(a),s=new Array(a),l=-1;for(e[a]<e[0]&&(e=e.slice().reverse(),n=n.slice().reverse());++l<a;)o[l]=r(e[l],e[l+1]),s[l]=i(n[l],n[l+1]);return function(n){var r=t.bisect(e,n,1,a)-1;return s[r](o[r](n))}}function y(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp())}function $(e,t){function n(){return a=Math.min(l.length,u.length)>2?b:v,o=s=null,i}function i(t){return(o||(o=a(l,u,f?m(e):e,c)))(+t)}var a,o,s,l=ue,u=ue,c=r.interpolate,f=!1;return i.invert=function(e){return(s||(s=a(u,l,h,f?g(t):t)))(+e)},i.domain=function(e){return arguments.length?(l=oe.call(e,p),n()):l.slice()},i.range=function(e){return arguments.length?(u=se.call(e),n()):u.slice()},i.rangeRound=function(e){return u=se.call(e),c=r.interpolateRound,n()},i.clamp=function(e){return arguments.length?(f=!!e,n()):f},i.interpolate=function(e){return arguments.length?(c=e,n()):c},n()}function w(e,n,r){var a,o=e[0],s=e[e.length-1],l=t.tickStep(o,s,null==n?10:n);switch(r=i.formatSpecifier(null==r?",f":r),r.type){case"s":var u=Math.max(Math.abs(o),Math.abs(s));return null!=r.precision||isNaN(a=i.precisionPrefix(l,u))||(r.precision=a),i.formatPrefix(r,u);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(a=i.precisionRound(l,Math.max(Math.abs(o),Math.abs(s))))||(r.precision=a-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(a=i.precisionFixed(l))||(r.precision=a-2*("%"===r.type))}return i.format(r)}function x(e){var n=e.domain;return e.ticks=function(e){var r=n();return t.ticks(r[0],r[r.length-1],null==e?10:e)},e.tickFormat=function(e,t){return w(n(),e,t)},e.nice=function(r){var i=n(),a=i.length-1,o=null==r?10:r,s=i[0],l=i[a],u=t.tickStep(s,l,o);return u&&(u=t.tickStep(Math.floor(s/u)*u,Math.ceil(l/u)*u,o),i[0]=Math.floor(s/u)*u,i[a]=Math.ceil(l/u)*u,n(i)),e},e}function k(){var e=$(h,r.interpolateNumber);return e.copy=function(){return y(e,k())},x(e)}function C(){function e(e){return+e}var t=[0,1];return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=oe.call(n,p),e):t.slice()},e.copy=function(){return C().domain(t)},x(e)}function M(e,t){e=e.slice();var n,r=0,i=e.length-1,a=e[r],o=e[i];return a>o&&(n=r,r=i,i=n,n=a,a=o,o=n),e[r]=t.floor(a),e[i]=t.ceil(o),e}function S(e,t){return(t=Math.log(t/e))?function(n){return Math.log(n/e)/t}:d(t)}function T(e,t){return 0>e?function(n){return-Math.pow(-t,n)*Math.pow(-e,1-n)}:function(n){return Math.pow(t,n)*Math.pow(e,1-n)}}function D(e){return isFinite(e)?+("1e"+e):0>e?0:e}function E(e){return 10===e?D:e===Math.E?Math.exp:function(t){return Math.pow(e,t)}}function O(e){return e===Math.E?Math.log:10===e&&Math.log10||2===e&&Math.log2||(e=Math.log(e),function(t){return Math.log(t)/e})}function A(e){return function(t){return-e(-t)}}function N(){function e(){return o=O(a),s=E(a),r()[0]<0&&(o=A(o),s=A(s)),n}var n=$(S,T).domain([1,10]),r=n.domain,a=10,o=O(10),s=E(10);return n.base=function(t){return arguments.length?(a=+t,e()):a},n.domain=function(t){return arguments.length?(r(t),e()):r()},n.ticks=function(e){var n,i=r(),l=i[0],u=i[i.length-1];(n=l>u)&&(p=l,l=u,u=p);var c,f,d,p=o(l),h=o(u),m=null==e?10:+e,g=[];if(!(a%1)&&m>h-p){if(p=Math.round(p)-1,h=Math.round(h)+1,l>0){for(;h>p;++p)for(f=1,c=s(p);a>f;++f)if(d=c*f,!(l>d)){if(d>u)break;g.push(d)}}else for(;h>p;++p)for(f=a-1,c=s(p);f>=1;--f)if(d=c*f,!(l>d)){if(d>u)break;g.push(d)}n&&g.reverse()}else g=t.ticks(p,h,Math.min(h-p,m)).map(s);return g},n.tickFormat=function(e,t){if(null==t&&(t=10===a?".0e":","),"function"!=typeof t&&(t=i.format(t)),e===1/0)return t;null==e&&(e=10);var r=Math.max(1,a*e/n.ticks().length);return function(e){var n=e/s(Math.round(o(e)));return a-.5>n*a&&(n*=a),r>=n?t(e):""}},n.nice=function(){return r(M(r(),{floor:function(e){return s(Math.floor(o(e)))},ceil:function(e){return s(Math.ceil(o(e)))}}))},n.copy=function(){return y(n,N().base(a))},n}function j(e,t){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}function L(){function e(e,t){return(t=j(t,n)-(e=j(e,n)))?function(r){return(j(r,n)-e)/t}:d(t)}function t(e,t){return t=j(t,n)-(e=j(e,n)),function(r){return j(e+t*r,1/n)}}var n=1,r=$(e,t),i=r.domain;return r.exponent=function(e){return arguments.length?(n=+e,i(i())):n},r.copy=function(){return y(r,L().exponent(n))},x(r)}function P(){return L().exponent(.5)}function I(){function e(){var e=0,o=Math.max(1,i.length);for(a=new Array(o-1);++e<o;)a[e-1]=t.quantile(r,e/o);return n}function n(e){return isNaN(e=+e)?void 0:i[t.bisect(a,e)]}var r=[],i=[],a=[];return n.invertExtent=function(e){var t=i.indexOf(e);return 0>t?[NaN,NaN]:[t>0?a[t-1]:r[0],t<a.length?a[t]:r[r.length-1]]},n.domain=function(n){if(!arguments.length)return r.slice();r=[];for(var i,a=0,o=n.length;o>a;++a)i=n[a],null==i||isNaN(i=+i)||r.push(i);return r.sort(t.ascending),e()},n.range=function(t){return arguments.length?(i=se.call(t),e()):i.slice()},n.quantiles=function(){return a.slice()},n.copy=function(){return I().domain(r).range(i)},n}function F(){function e(e){return e>=e?s[t.bisect(o,e,0,a)]:void 0}function n(){var t=-1;for(o=new Array(a);++t<a;)o[t]=((t+1)*i-(t-a)*r)/(a+1);return e}var r=0,i=1,a=1,o=[.5],s=[0,1];return e.domain=function(e){return arguments.length?(r=+e[0],i=+e[1],n()):[r,i]},e.range=function(e){return arguments.length?(a=(s=se.call(e)).length-1,n()):s.slice()},e.invertExtent=function(e){var t=s.indexOf(e);return 0>t?[NaN,NaN]:1>t?[r,o[0]]:t>=a?[o[a-1],i]:[o[t-1],o[t]]},e.copy=function(){return F().domain([r,i]).range(s)},x(e)}function z(){function e(e){return e>=e?r[t.bisect(n,e,0,i)]:void 0}var n=[.5],r=[0,1],i=1;return e.domain=function(t){return arguments.length?(n=se.call(t),i=Math.min(n.length,r.length-1),e):n.slice()},e.range=function(t){return arguments.length?(r=se.call(t),i=Math.min(n.length,r.length-1),e):r.slice()},e.invertExtent=function(e){var t=r.indexOf(e);return[n[t-1],n[t]]},e.copy=function(){return z().domain(n).range(r)},e}function _(e){return new Date(e)}function R(e,n,i,a,o,s,l,u,c){function f(t){return(l(t)<t?v:s(t)<t?b:o(t)<t?w:a(t)<t?x:n(t)<t?i(t)<t?k:C:e(t)<t?S:T)(t)}function d(n,r,i,a){if(null==n&&(n=10),"number"==typeof n){var o=Math.abs(i-r)/n,s=t.bisector(function(e){return e[2]}).right(D,o);s===D.length?(a=t.tickStep(r/ge,i/ge,n),n=e):s?(s=D[o/D[s-1][2]<D[s][2]/o?s-1:s],a=s[1],n=s[0]):(a=t.tickStep(r,i,n),n=u)}return null==a?n:n.every(a)}var p=$(h,r.interpolateNumber),m=p.invert,g=p.domain,v=c(".%L"),b=c(":%S"),w=c("%I:%M"),x=c("%I %p"),k=c("%a %d"),C=c("%b %d"),S=c("%B"),T=c("%Y"),D=[[l,1,ce],[l,5,5*ce],[l,15,15*ce],[l,30,30*ce],[s,1,fe],[s,5,5*fe],[s,15,15*fe],[s,30,30*fe],[o,1,de],[o,3,3*de],[o,6,6*de],[o,12,12*de],[a,1,pe],[a,2,2*pe],[i,1,he],[n,1,me],[n,3,3*me],[e,1,ge]];return p.invert=function(e){return new Date(m(e))},p.domain=function(e){return arguments.length?g(e):g().map(_)},p.ticks=function(e,t){var n,r=g(),i=r[0],a=r[r.length-1],o=i>a;return o&&(n=i,i=a,a=n),n=d(e,i,a,t),n=n?n.range(i,a+1):[],o?n.reverse():n},p.tickFormat=function(e,t){return null==t?f:c(t)},p.nice=function(e,t){var n=g();return(e=d(e,n[0],n[n.length-1],t))?g(M(n,e)):p},p.copy=function(){return y(p,R(e,n,i,a,o,s,l,u,c))},p}function H(){return R(a.timeYear,a.timeMonth,a.timeWeek,a.timeDay,a.timeHour,a.timeMinute,a.timeSecond,a.timeMillisecond,o.timeFormat).domain([new Date(2e3,0,1),new Date(2e3,0,2)])}function U(){return R(a.utcYear,a.utcMonth,a.utcWeek,a.utcDay,a.utcHour,a.utcMinute,a.utcSecond,a.utcMillisecond,o.utcFormat).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)])}function V(e){return e.match(/.{6}/g).map(function(e){return"#"+e})}function W(){return l().range(ve)}function B(){return l().range(be)}function q(){return l().range(ye)}function Y(){return l().range($e)}function G(){return k().interpolate(r.interpolateCubehelixLong).range([s.cubehelix(300,.5,0),s.cubehelix(-240,.5,1)])}function X(e){function t(t){var a=(t-n)/(r-n);return e(i?Math.max(0,Math.min(1,a)):a)}var n=0,r=1,i=!1;return t.domain=function(e){return arguments.length?(n=+e[0],r=+e[1],t):[n,r]},t.clamp=function(e){return arguments.length?(i=!!e,t):i},t.copy=function(){return X(e).domain([n,r]).clamp(i)},x(t)}function K(){return X(r.interpolateCubehelixLong(s.cubehelix(-100,.75,.35),s.cubehelix(80,1.5,.8)))}function J(){return X(r.interpolateCubehelixLong(s.cubehelix(260,.75,.35),s.cubehelix(80,1.5,.8)))}function Z(){var e=s.cubehelix();return X(function(t){(0>t||t>1)&&(t-=Math.floor(t));var n=Math.abs(t-.5);return e.h=360*t-100,e.s=1.5-1.5*n,e.l=.8-.9*n,e+""})}function Q(e){var t=X(function(t){return e[Math.round(t*e.length-t)]}).clamp(!0);return delete t.clamp,t}function ee(){return Q(we)}function te(){return Q(xe)}function ne(){return Q(ke)}function re(){return Q(Ce)}var ie="0.7.2",ae=Array.prototype,oe=ae.map,se=ae.slice,le={name:"implicit"},ue=[0,1],ce=1e3,fe=60*ce,de=60*fe,pe=24*de,he=7*pe,me=30*pe,ge=365*pe,ve=V("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),be=V("393b795254a36b6ecf9c9ede6379398ca252b5cf6bcedb9c8c6d31bd9e39e7ba52e7cb94843c39ad494ad6616be7969c7b4173a55194ce6dbdde9ed6"),ye=V("3182bd6baed69ecae1c6dbefe6550dfd8d3cfdae6bfdd0a231a35474c476a1d99bc7e9c0756bb19e9ac8bcbddcdadaeb636363969696bdbdbdd9d9d9"),$e=V("1f77b4aec7e8ff7f0effbb782ca02c98df8ad62728ff98969467bdc5b0d58c564bc49c94e377c2f7b6d27f7f7fc7c7c7bcbd22dbdb8d17becf9edae5"),we=V("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725"),xe=V("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf"),ke=V("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4"),Ce=V("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921");e.version=ie,e.scaleBand=u,e.scalePoint=f,e.scaleIdentity=C,e.scaleLinear=k,e.scaleLog=N,e.scaleOrdinal=l,e.scaleImplicit=le,e.scalePow=L,e.scaleSqrt=P,e.scaleQuantile=I,e.scaleQuantize=F,e.scaleThreshold=z,e.scaleTime=H,e.scaleUtc=U,e.scaleCategory10=W,e.scaleCategory20b=B,e.scaleCategory20c=q,e.scaleCategory20=Y,e.scaleCubehelix=G,e.scaleRainbow=Z,e.scaleWarm=K,e.scaleCool=J,e.scaleViridis=ee,e.scaleMagma=te,e.scaleInferno=ne,e.scalePlasma=re,e.scaleSequential=X})},{"d3-array":"/home/stack/stackviz/node_modules/d3-array/build/d3-array.js","d3-collection":"/home/stack/stackviz/node_modules/d3-collection/build/d3-collection.js","d3-color":"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-color/build/d3-color.js","d3-format":"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-format/build/d3-format.js","d3-interpolate":"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-interpolate/build/d3-interpolate.js","d3-time":"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-time/build/d3-time.js","d3-time-format":"/home/stack/stackviz/node_modules/d3-time-format/build/d3-time-format.js"}],"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-color/build/d3-color.js":[function(e,t,n){arguments[4]["/home/stack/stackviz/node_modules/d3-interpolate/node_modules/d3-color/build/d3-color.js"][0].apply(n,arguments)},{}],"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-format/build/d3-format.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_format={})}(this,function(e){"use strict";function t(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function n(e){return e=t(Math.abs(e)),e?e[1]:NaN}function r(e,t){return function(n,r){for(var i=n.length,a=[],o=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),a.push(n.substring(i-=s,i+s)),!((l+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function i(e,t){e=e.toPrecision(t);e:for(var n,r=e.length,i=1,a=-1;r>i;++i)switch(e[i]){case".":a=n=i;break;case"0":0===a&&(a=i),n=i;break;case"e":break e;default:a>0&&(a=0)}return a>0?e.slice(0,a)+e.slice(n+1):e}function a(e,n){var r=t(e,n);if(!r)return e+"";var i=r[0],a=r[1],o=a-(h=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,s=i.length;return o===s?i:o>s?i+new Array(o-s+1).join("0"):o>0?i.slice(0,o)+"."+i.slice(o):"0."+new Array(1-o).join("0")+t(e,Math.max(0,n+o-1))[0]}function o(e,n){var r=t(e,n);if(!r)return e+"";var i=r[0],a=r[1];return 0>a?"0."+new Array(-a).join("0")+i:i.length>a+1?i.slice(0,a+1)+"."+i.slice(a+1):i+new Array(a-i.length+2).join("0")}function s(e){return new l(e)}function l(e){if(!(t=g.exec(e)))throw new Error("invalid format: "+e);var t,n=t[1]||" ",r=t[2]||">",i=t[3]||"-",a=t[4]||"",o=!!t[5],s=t[6]&&+t[6],l=!!t[7],u=t[8]&&+t[8].slice(1),c=t[9]||"";"n"===c?(l=!0,c="g"):m[c]||(c=""),(o||"0"===n&&"="===r)&&(o=!0,n="0",r="="),this.fill=n,this.align=r,this.sign=i,this.symbol=a,this.zero=o,this.width=s,this.comma=l,this.precision=u,this.type=c}function u(e){return e}function c(e){function t(e){function t(e){var t,o,s,u=b,m=y;if("c"===g)m=$(e)+m,e="";else{e=+e;var x=(0>e||0>1/e)&&(e*=-1,!0);if(e=$(e,p),x)for(t=-1,o=e.length,x=!1;++t<o;)if(s=e.charCodeAt(t),s>48&&58>s||"x"===g&&s>96&&103>s||"X"===g&&s>64&&71>s){x=!0;break}if(u=(x?"("===i?i:"-":"-"===i||"("===i?"":i)+u,m=m+("s"===g?v[8+h/3]:"")+(x&&"("===i?")":""),w)for(t=-1,o=e.length;++t<o;)if(s=e.charCodeAt(t),48>s||s>57){m=(46===s?l+e.slice(t+1):e.slice(t))+m,e=e.slice(0,t);break}}d&&!c&&(e=a(e,1/0));var k=u.length+e.length+m.length,C=f>k?new Array(f-k+1).join(n):"";switch(d&&c&&(e=a(C+e,C.length?f-m.length:1/0),C=""),r){case"<":return u+e+m+C;case"=":return u+C+e+m;case"^":return C.slice(0,k=C.length>>1)+u+e+m+C.slice(k)}return C+u+e+m}e=s(e);var n=e.fill,r=e.align,i=e.sign,u=e.symbol,c=e.zero,f=e.width,d=e.comma,p=e.precision,g=e.type,b="$"===u?o[0]:"#"===u&&/[boxX]/.test(g)?"0"+g.toLowerCase():"",y="$"===u?o[1]:/[%p]/.test(g)?"%":"",$=m[g],w=!g||/[defgprs%]/.test(g);return p=null==p?g?6:12:/[gprs]/.test(g)?Math.max(1,Math.min(21,p)):Math.max(0,Math.min(20,p)),t.toString=function(){return e+""},t}function i(e,r){var i=t((e=s(e),e.type="f",e)),a=3*Math.max(-8,Math.min(8,Math.floor(n(r)/3))),o=Math.pow(10,-a),l=v[8+a/3];return function(e){return i(o*e)+l}}var a=e.grouping&&e.thousands?r(e.grouping,e.thousands):u,o=e.currency,l=e.decimal;return{format:t,formatPrefix:i}}function f(e){return Math.max(0,-n(Math.abs(e)))}function d(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(n(t)/3)))-n(Math.abs(e)))}function p(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,n(t)-n(e))+1}var h,m={"":i,"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.round(e).toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return o(100*e,t)},r:o,s:a,X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}},g=/^(?:(.)?([<>=^]))?([+\-\( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?([a-z%])?$/i;l.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+this.type};var v=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"],b=c({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),y=c({decimal:",",thousands:".",grouping:[3],currency:[""," €"]}),$=c({decimal:",",thousands:" ",grouping:[3],currency:[""," Kč"]}),w=c({decimal:",",thousands:"'",grouping:[3],currency:[""," CHF"]}),x=c({decimal:",",thousands:".",grouping:[3],currency:[""," €"]}),k=c({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),C=c({decimal:".",thousands:",",grouping:[3],currency:["£",""]}),M=c({decimal:",",thousands:".",grouping:[3],currency:[""," €"]}),S=c({decimal:",",thousands:" ",grouping:[3],currency:[""," €"]}),T=c({decimal:",",thousands:" ",grouping:[3],currency:["","$"]}),D=c({decimal:",",thousands:".",grouping:[3],currency:[""," €"]}),E=c({decimal:".",thousands:",",grouping:[3],currency:["₪",""]}),O=c({decimal:",",thousands:" ",grouping:[3],currency:[""," Ft"]}),A=c({decimal:",",thousands:".",grouping:[3],currency:["€",""]}),N=c({decimal:".",thousands:",",grouping:[3],currency:["","円"]}),j=c({decimal:".",thousands:",",grouping:[3],currency:["₩",""]}),L=c({decimal:",",thousands:".",grouping:[3],currency:[""," ден."]}),P=c({decimal:",",thousands:".",grouping:[3],currency:["€ ",""]}),I=c({decimal:",",thousands:".",grouping:[3],currency:["","zł"]}),F=c({decimal:",",thousands:".",grouping:[3],currency:["R$",""]}),z=c({decimal:",",thousands:" ",grouping:[3],currency:[""," руб."]}),_=c({decimal:",",thousands:" ",grouping:[3],currency:["","SEK"]}),R=c({decimal:".",thousands:",",grouping:[3],currency:["¥",""]}),H=b.format,U=b.formatPrefix,V="0.5.1";e.version=V,e.format=H,e.formatPrefix=U,e.formatLocale=c,e.formatCaEs=y,e.formatCsCz=$,e.formatDeCh=w,e.formatDeDe=x,e.formatEnCa=k,e.formatEnGb=C,e.formatEnUs=b,e.formatEsEs=M,e.formatFiFi=S,e.formatFrCa=T,e.formatFrFr=D,e.formatHeIl=E,e.formatHuHu=O,e.formatItIt=A,e.formatJaJp=N,e.formatKoKr=j,e.formatMkMk=L,e.formatNlNl=P,e.formatPlPl=I,e.formatPtBr=F,e.formatRuRu=z,e.formatSvSe=_,e.formatZhCn=R,e.formatSpecifier=s,e.precisionFixed=f,e.precisionPrefix=d,e.precisionRound=p})},{}],"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-interpolate/build/d3-interpolate.js":[function(e,t,n){!function(r,i){"object"==typeof n&&"undefined"!=typeof t?i(n,e("d3-color")):"function"==typeof define&&define.amd?define(["exports","d3-color"],i):i(r.d3_interpolate=r.d3_interpolate||{},r.d3_color)}(this,function(e,t){"use strict";function n(e,t,n,r,i){var a=e*e,o=a*e;return((1-3*e+3*a-o)*t+(4-6*a+3*o)*n+(1+3*e+3*a-3*o)*r+o*i)/6}function r(e){var t=e.length-1;return function(r){var i=0>=r?r=0:r>=1?(r=1,t-1):Math.floor(r*t),a=e[i],o=e[i+1],s=i>0?e[i-1]:2*a-o,l=t-1>i?e[i+2]:2*o-a;return n((r-i/t)*t,s,a,o,l)}}function i(e){var t=e.length;return function(r){var i=Math.floor(((r%=1)<0?++r:r)*t),a=e[(i+t-1)%t],o=e[i%t],s=e[(i+1)%t],l=e[(i+2)%t];return n((r-i/t)*t,a,o,s,l)}}function a(e){return function(){return e}}function o(e,t){return function(n){return e+n*t}}function s(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function l(e,t){var n=t-e;return n?o(e,n>180||-180>n?n-360*Math.round(n/360):n):a(isNaN(e)?t:e)}function u(e){return 1===(e=+e)?c:function(t,n){return n-t?s(t,n,e):a(isNaN(t)?n:t)}}function c(e,t){var n=t-e;return n?o(e,n):a(isNaN(e)?t:e)}function f(e){return function(n){var r,i,a=n.length,o=new Array(a),s=new Array(a),l=new Array(a);for(r=0;a>r;++r)i=t.rgb(n[r]),o[r]=i.r||0,s[r]=i.g||0,l[r]=i.b||0;return o=e(o),s=e(s),l=e(l),i.opacity=1,function(e){return i.r=o(e),i.g=s(e),i.b=l(e),i+""}}}function d(e,t){var n,r=t?t.length:0,i=e?Math.min(r,e.length):0,a=new Array(r),o=new Array(r);for(n=0;i>n;++n)a[n]=b(e[n],t[n]);for(;r>n;++n)o[n]=t[n];return function(e){for(n=0;i>n;++n)o[n]=a[n](e);return o}}function p(e,t){return e=+e,t-=e,function(n){return e+t*n}}function h(e,t){var n,r={},i={};null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={});for(n in t)n in e?r[n]=b(e[n],t[n]):i[n]=t[n];return function(e){for(n in r)i[n]=r[n](e);return i}}function m(e){return function(){return e}}function g(e){return function(t){return e(t)+""}}function v(e,t){var n,r,i,a=H.lastIndex=U.lastIndex=0,o=-1,s=[],l=[];for(e+="",t+="";(n=H.exec(e))&&(r=U.exec(t));)(i=r.index)>a&&(i=t.slice(a,i),s[o]?s[o]+=i:s[++o]=i),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,l.push({i:o,x:p(n,r)})),a=U.lastIndex;return a<t.length&&(i=t.slice(a),s[o]?s[o]+=i:s[++o]=i),s.length<2?l[0]?g(l[0].x):m(t):(t=l.length,function(e){for(var n,r=0;t>r;++r)s[(n=l[r]).i]=n.x(e);return s.join("")})}function b(e,n){var r,i=typeof n;return null==n||"boolean"===i?a(n):("number"===i?p:"string"===i?(r=t.color(n))?(n=r,z):v:n instanceof t.color?z:Array.isArray(n)?d:h)(e,n)}function y(e,t){return e=+e,t-=e,function(n){return Math.round(e+t*n)}}function $(e,t,n,r,i,a){if(e*r===t*n)return null;var o=Math.sqrt(e*e+t*t);e/=o,t/=o;var s=e*n+t*r;n-=e*s,r-=t*s;var l=Math.sqrt(n*n+r*r);return n/=l,r/=l,s/=l,t*n>e*r&&(e=-e,t=-t,s=-s,o=-o),{translateX:i,translateY:a,rotate:Math.atan2(t,e)*V,skewX:Math.atan(s)*V,scaleX:o,scaleY:l}}function w(e){if("none"===e)return W;j||(j=document.createElement("DIV"),L=document.documentElement,P=document.defaultView),j.style.transform=e,e=P.getComputedStyle(L.appendChild(j),null).getPropertyValue("transform"),L.removeChild(j);var t=e.slice(7,-1).split(",");return $(+t[0],+t[1],+t[2],+t[3],+t[4],+t[5])}function x(e){I||(I=document.createElementNS("http://www.w3.org/2000/svg","g")),I.setAttribute("transform",null==e?"":e);var t=I.transform.baseVal.consolidate().matrix;return $(t.a,t.b,t.c,t.d,t.e,t.f)}function k(e,t,n,r){function i(e){return e.length?e.pop()+" ":""}function a(e,r,i,a,o,s){if(e!==i||r!==a){var l=o.push("translate(",null,t,null,n);s.push({i:l-4,x:p(e,i)},{i:l-2,x:p(r,a)})}else(i||a)&&o.push("translate("+i+t+a+n)}function o(e,t,n,a){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(i(n)+"rotate(",null,r)-2,x:p(e,t)})):t&&n.push(i(n)+"rotate("+t+r)}function s(e,t,n,a){e!==t?a.push({i:n.push(i(n)+"skewX(",null,r)-2,x:p(e,t)}):t&&n.push(i(n)+"skewX("+t+r)}function l(e,t,n,r,a,o){if(e!==n||t!==r){var s=a.push(i(a)+"scale(",null,",",null,")");o.push({i:s-4,x:p(e,n)},{i:s-2,x:p(t,r)})}else 1===n&&1===r||a.push(i(a)+"scale("+n+","+r+")")}return function(t,n){var r=[],i=[];return t=e(t),n=e(n),a(t.translateX,t.translateY,n.translateX,n.translateY,r,i),o(t.rotate,n.rotate,r,i),s(t.skewX,n.skewX,r,i),l(t.scaleX,t.scaleY,n.scaleX,n.scaleY,r,i),t=n=null,function(e){for(var t,n=-1,a=i.length;++n<a;)r[(t=i[n]).i]=t.x(e);return r.join("")}}}function C(e){return((e=Math.exp(e))+1/e)/2}function M(e){return((e=Math.exp(e))-1/e)/2}function S(e){return((e=Math.exp(2*e))-1)/(e+1)}function T(e,t){var n,r,i=e[0],a=e[1],o=e[2],s=t[0],l=t[1],u=t[2],c=s-i,f=l-a,d=c*c+f*f;if(K>d)r=Math.log(u/o)/Y,n=function(e){return[i+e*c,a+e*f,o*Math.exp(Y*e*r)]};else{var p=Math.sqrt(d),h=(u*u-o*o+X*d)/(2*o*G*p),m=(u*u-o*o-X*d)/(2*u*G*p),g=Math.log(Math.sqrt(h*h+1)-h),v=Math.log(Math.sqrt(m*m+1)-m);r=(v-g)/Y,n=function(e){var t=e*r,n=C(g),s=o/(G*p)*(n*S(Y*t+g)-M(g));return[i+s*c,a+s*f,o*n/C(Y*t+g)]}}return n.duration=1e3*r,n}function D(e){return function(n,r){var i=e((n=t.hsl(n)).h,(r=t.hsl(r)).h),a=c(n.s,r.s),o=c(n.l,r.l),s=c(n.opacity,r.opacity);return function(e){return n.h=i(e),n.s=a(e),n.l=o(e),n.opacity=s(e),n+""}}}function E(e,n){var r=c((e=t.lab(e)).l,(n=t.lab(n)).l),i=c(e.a,n.a),a=c(e.b,n.b),o=c(e.opacity,n.opacity);
return function(t){return e.l=r(t),e.a=i(t),e.b=a(t),e.opacity=o(t),e+""}}function O(e){return function(n,r){var i=e((n=t.hcl(n)).h,(r=t.hcl(r)).h),a=c(n.c,r.c),o=c(n.l,r.l),s=c(n.opacity,r.opacity);return function(e){return n.h=i(e),n.c=a(e),n.l=o(e),n.opacity=s(e),n+""}}}function A(e){return function n(r){function i(n,i){var a=e((n=t.cubehelix(n)).h,(i=t.cubehelix(i)).h),o=c(n.s,i.s),s=c(n.l,i.l),l=c(n.opacity,i.opacity);return function(e){return n.h=a(e),n.s=o(e),n.l=s(Math.pow(e,r)),n.opacity=l(e),n+""}}return r=+r,i.gamma=n,i}(1)}function N(e,t){for(var n=new Array(t),r=0;t>r;++r)n[r]=e(r/(t-1));return n}var j,L,P,I,F="0.8.3",z=function re(e){function n(e,n){var i=r((e=t.rgb(e)).r,(n=t.rgb(n)).r),a=r(e.g,n.g),o=r(e.b,n.b),s=r(e.opacity,n.opacity);return function(t){return e.r=i(t),e.g=a(t),e.b=o(t),e.opacity=s(t),e+""}}var r=u(e);return n.gamma=re,n}(1),_=f(r),R=f(i),H=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,U=new RegExp(H.source,"g"),V=180/Math.PI,W={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},B=k(w,"px, ","px)","deg)"),q=k(x,", ",")",")"),Y=Math.SQRT2,G=2,X=4,K=1e-12,J=D(l),Z=D(c),Q=O(l),ee=O(c),te=A(l),ne=A(c);e.version=F,e.interpolate=b,e.interpolateArray=d,e.interpolateBasis=r,e.interpolateBasisClosed=i,e.interpolateNumber=p,e.interpolateObject=h,e.interpolateRound=y,e.interpolateString=v,e.interpolateTransformCss=B,e.interpolateTransformSvg=q,e.interpolateZoom=T,e.interpolateRgb=z,e.interpolateRgbBasis=_,e.interpolateRgbBasisClosed=R,e.interpolateHsl=J,e.interpolateHslLong=Z,e.interpolateLab=E,e.interpolateHcl=Q,e.interpolateHclLong=ee,e.interpolateCubehelix=te,e.interpolateCubehelixLong=ne,e.quantize=N,Object.defineProperty(e,"__esModule",{value:!0})})},{"d3-color":"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-color/build/d3-color.js"}],"/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-time/build/d3-time.js":[function(e,t,n){!function(e,r){"object"==typeof n&&"undefined"!=typeof t?r(n):"function"==typeof define&&define.amd?define(["exports"],r):r(e.d3_time=e.d3_time||{})}(this,function(e){"use strict";function t(e,n,r,i){function s(t){return e(t=new Date(+t)),t}return s.floor=s,s.ceil=function(t){return e(t=new Date(t-1)),n(t,1),e(t),t},s.round=function(e){var t=s(e),n=s.ceil(e);return n-e>e-t?t:n},s.offset=function(e,t){return n(e=new Date(+e),null==t?1:Math.floor(t)),e},s.range=function(t,r,i){var a=[];if(t=s.ceil(t),i=null==i?1:Math.floor(i),!(r>t&&i>0))return a;do a.push(new Date(+t));while(n(t,i),e(t),r>t);return a},s.filter=function(r){return t(function(t){for(;e(t),!r(t);)t.setTime(t-1)},function(e,t){for(;--t>=0;)for(;n(e,1),!r(e););})},r&&(s.count=function(t,n){return a.setTime(+t),o.setTime(+n),e(a),e(o),Math.floor(r(a,o))},s.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?s.filter(i?function(t){return i(t)%e===0}:function(t){return s.count(0,t)%e===0}):s:null}),s}function n(e){return t(function(t){t.setHours(0,0,0,0),t.setDate(t.getDate()-(t.getDay()+7-e)%7)},function(e,t){e.setDate(e.getDate()+7*t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*u)/d})}function r(e){return t(function(t){t.setUTCHours(0,0,0,0),t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7)},function(e,t){e.setUTCDate(e.getUTCDate()+7*t)},function(e,t){return(t-e)/d})}var i="0.2.6",a=new Date,o=new Date,s=t(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});s.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?t(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):s:null};var l=1e3,u=6e4,c=36e5,f=864e5,d=6048e5,p=t(function(e){e.setTime(Math.floor(e/l)*l)},function(e,t){e.setTime(+e+t*l)},function(e,t){return(t-e)/l},function(e){return e.getUTCSeconds()}),h=t(function(e){e.setTime(Math.floor(e/u)*u)},function(e,t){e.setTime(+e+t*u)},function(e,t){return(t-e)/u},function(e){return e.getMinutes()}),m=t(function(e){var t=e.getTimezoneOffset()*u%c;0>t&&(t+=c),e.setTime(Math.floor((+e-t)/c)*c+t)},function(e,t){e.setTime(+e+t*c)},function(e,t){return(t-e)/c},function(e){return e.getHours()}),g=t(function(e){e.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*u)/f},function(e){return e.getDate()-1}),v=n(0),b=n(1),y=n(2),$=n(3),w=n(4),x=n(5),k=n(6),C=t(function(e){e.setHours(0,0,0,0),e.setDate(1)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())},function(e){return e.getMonth()}),M=t(function(e){e.setHours(0,0,0,0),e.setMonth(0,1)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()}),S=t(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*u)},function(e,t){return(t-e)/u},function(e){return e.getUTCMinutes()}),T=t(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+t*c)},function(e,t){return(t-e)/c},function(e){return e.getUTCHours()}),D=t(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/f},function(e){return e.getUTCDate()-1}),E=r(0),O=r(1),A=r(2),N=r(3),j=r(4),L=r(5),P=r(6),I=t(function(e){e.setUTCHours(0,0,0,0),e.setUTCDate(1)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())},function(e){return e.getUTCMonth()}),F=t(function(e){e.setUTCHours(0,0,0,0),e.setUTCMonth(0,1)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()}),z=s.range,_=p.range,R=h.range,H=m.range,U=g.range,V=v.range,W=b.range,B=y.range,q=$.range,Y=w.range,G=x.range,X=k.range,K=v.range,J=C.range,Z=M.range,Q=z,ee=_,te=S.range,ne=T.range,re=D.range,ie=E.range,ae=O.range,oe=A.range,se=N.range,le=j.range,ue=L.range,ce=P.range,fe=E.range,de=I.range,pe=F.range;e.timeMilliseconds=z,e.timeSeconds=_,e.timeMinutes=R,e.timeHours=H,e.timeDays=U,e.timeSundays=V,e.timeMondays=W,e.timeTuesdays=B,e.timeWednesdays=q,e.timeThursdays=Y,e.timeFridays=G,e.timeSaturdays=X,e.timeWeeks=K,e.timeMonths=J,e.timeYears=Z,e.utcMilliseconds=Q,e.utcSeconds=ee,e.utcMinutes=te,e.utcHours=ne,e.utcDays=re,e.utcSundays=ie,e.utcMondays=ae,e.utcTuesdays=oe,e.utcWednesdays=se,e.utcThursdays=le,e.utcFridays=ue,e.utcSaturdays=ce,e.utcWeeks=fe,e.utcMonths=de,e.utcYears=pe,e.timeMillisecond=s,e.timeSecond=p,e.timeMinute=h,e.timeHour=m,e.timeDay=g,e.timeSunday=v,e.timeMonday=b,e.timeTuesday=y,e.timeWednesday=$,e.timeThursday=w,e.timeFriday=x,e.timeSaturday=k,e.timeWeek=v,e.timeMonth=C,e.timeYear=M,e.utcMillisecond=s,e.utcSecond=p,e.utcMinute=S,e.utcHour=T,e.utcDay=D,e.utcSunday=E,e.utcMonday=O,e.utcTuesday=A,e.utcWednesday=N,e.utcThursday=j,e.utcFriday=L,e.utcSaturday=P,e.utcWeek=E,e.utcMonth=I,e.utcYear=F,e.version=i,e.timeInterval=t,Object.defineProperty(e,"__esModule",{value:!0})})},{}],"/home/stack/stackviz/node_modules/d3-time-format/build/d3-time-format.js":[function(e,t,n){!function(r,i){"object"==typeof n&&"undefined"!=typeof t?i(n,e("d3-time")):"function"==typeof define&&define.amd?define(["exports","d3-time"],i):i(r.d3_time_format=r.d3_time_format||{},r.d3_time)}(this,function(e,t){"use strict";function n(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function r(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function i(e){return{y:e,m:0,d:1,H:0,M:0,S:0,L:0}}function a(e){function t(e,t){return function(n){var r,i,a,o=[],s=-1,l=0,u=e.length;for(n instanceof Date||(n=new Date(+n));++s<u;)37===e.charCodeAt(s)&&(o.push(e.slice(l,s)),null!=(i=ne[r=e.charAt(++s)])?r=e.charAt(++s):i="e"===r?" ":"0",(a=t[r])&&(r=a(n,i)),o.push(r),l=s+1);return o.push(e.slice(l,s)),o.join("")}}function a(e,t){return function(n){var a=i(1900),s=o(a,e,n+="",0);if(s!=n.length)return null;if("p"in a&&(a.H=a.H%12+12*a.p),"W"in a||"U"in a){"w"in a||(a.w="W"in a?1:0);var l="Z"in a?r(i(a.y)).getUTCDay():t(i(a.y)).getDay();a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(l+5)%7:a.w+7*a.U-(l+6)%7}return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,r(a)):t(a)}}function o(e,t,n,r){for(var i,a,o=0,s=t.length,l=n.length;s>o;){if(r>=l)return-1;if(i=t.charCodeAt(o++),37===i){if(i=t.charAt(o++),a=Fe[i in ne?t.charAt(o++):i],!a||(r=a(e,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function s(e,t,n){var r=Me.exec(t.slice(n));return r?(e.p=Se[r[0].toLowerCase()],n+r[0].length):-1}function Q(e,t,n){var r=Ee.exec(t.slice(n));return r?(e.w=Oe[r[0].toLowerCase()],n+r[0].length):-1}function ee(e,t,n){var r=Te.exec(t.slice(n));return r?(e.w=De[r[0].toLowerCase()],n+r[0].length):-1}function te(e,t,n){var r=je.exec(t.slice(n));return r?(e.m=Le[r[0].toLowerCase()],n+r[0].length):-1}function re(e,t,n){var r=Ae.exec(t.slice(n));return r?(e.m=Ne[r[0].toLowerCase()],n+r[0].length):-1}function ie(e,t,n){return o(e,ve,t,n)}function ae(e,t,n){return o(e,be,t,n)}function oe(e,t,n){return o(e,ye,t,n)}function se(e){return xe[e.getDay()]}function le(e){return we[e.getDay()]}function ue(e){return Ce[e.getMonth()]}function ce(e){return ke[e.getMonth()]}function fe(e){return $e[+(e.getHours()>=12)]}function de(e){return xe[e.getUTCDay()]}function pe(e){return we[e.getUTCDay()]}function he(e){return Ce[e.getUTCMonth()]}function me(e){return ke[e.getUTCMonth()]}function ge(e){return $e[+(e.getUTCHours()>=12)]}var ve=e.dateTime,be=e.date,ye=e.time,$e=e.periods,we=e.days,xe=e.shortDays,ke=e.months,Ce=e.shortMonths,Me=l($e),Se=u($e),Te=l(we),De=u(we),Ee=l(xe),Oe=u(xe),Ae=l(ke),Ne=u(ke),je=l(Ce),Le=u(Ce),Pe={a:se,A:le,b:ue,B:ce,c:null,d:C,e:C,H:M,I:S,j:T,L:D,m:E,M:O,p:fe,S:A,U:N,w:j,W:L,x:null,X:null,y:P,Y:I,Z:F,"%":Z},Ie={a:de,A:pe,b:he,B:me,c:null,d:z,e:z,H:_,I:R,j:H,L:U,m:V,M:W,p:ge,S:B,U:q,w:Y,W:G,x:null,X:null,y:X,Y:K,Z:J,"%":Z},Fe={a:Q,A:ee,b:te,B:re,c:ie,d:v,e:v,H:y,I:y,j:b,L:x,m:g,M:$,p:s,S:w,U:f,w:c,W:d,x:ae,X:oe,y:h,Y:p,Z:m,"%":k};return Pe.x=t(be,Pe),Pe.X=t(ye,Pe),Pe.c=t(ve,Pe),Ie.x=t(be,Ie),Ie.X=t(ye,Ie),Ie.c=t(ve,Ie),{format:function(e){var n=t(e+="",Pe);return n.toString=function(){return e},n},parse:function(e){var t=a(e+="",n);return t.toString=function(){return e},t},utcFormat:function(e){var n=t(e+="",Ie);return n.toString=function(){return e},n},utcParse:function(e){var t=a(e,r);return t.toString=function(){return e},t}}}function o(e,t,n){var r=0>e?"-":"",i=(r?-e:e)+"",a=i.length;return r+(n>a?new Array(n-a+1).join(t)+i:i)}function s(e){return e.replace(ae,"\\$&")}function l(e){return new RegExp("^(?:"+e.map(s).join("|")+")","i")}function u(e){for(var t={},n=-1,r=e.length;++n<r;)t[e[n].toLowerCase()]=n;return t}function c(e,t,n){var r=re.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function f(e,t,n){var r=re.exec(t.slice(n));return r?(e.U=+r[0],n+r[0].length):-1}function d(e,t,n){var r=re.exec(t.slice(n));return r?(e.W=+r[0],n+r[0].length):-1}function p(e,t,n){var r=re.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function h(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function m(e,t,n){var r=/^(Z)|([+-]\d\d)(?:\:?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function g(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function v(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function b(e,t,n){var r=re.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function y(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function $(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function w(e,t,n){var r=re.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function x(e,t,n){var r=re.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function k(e,t,n){var r=ie.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function C(e,t){return o(e.getDate(),t,2)}function M(e,t){return o(e.getHours(),t,2)}function S(e,t){return o(e.getHours()%12||12,t,2)}function T(e,n){return o(1+t.timeDay.count(t.timeYear(e),e),n,3)}function D(e,t){return o(e.getMilliseconds(),t,3)}function E(e,t){return o(e.getMonth()+1,t,2)}function O(e,t){return o(e.getMinutes(),t,2)}function A(e,t){return o(e.getSeconds(),t,2)}function N(e,n){return o(t.timeSunday.count(t.timeYear(e),e),n,2)}function j(e){return e.getDay()}function L(e,n){return o(t.timeMonday.count(t.timeYear(e),e),n,2)}function P(e,t){return o(e.getFullYear()%100,t,2)}function I(e,t){return o(e.getFullYear()%1e4,t,4)}function F(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+o(t/60|0,"0",2)+o(t%60,"0",2)}function z(e,t){return o(e.getUTCDate(),t,2)}function _(e,t){return o(e.getUTCHours(),t,2)}function R(e,t){return o(e.getUTCHours()%12||12,t,2)}function H(e,n){return o(1+t.utcDay.count(t.utcYear(e),e),n,3)}function U(e,t){return o(e.getUTCMilliseconds(),t,3)}function V(e,t){return o(e.getUTCMonth()+1,t,2)}function W(e,t){return o(e.getUTCMinutes(),t,2)}function B(e,t){return o(e.getUTCSeconds(),t,2)}function q(e,n){return o(t.utcSunday.count(t.utcYear(e),e),n,2)}function Y(e){return e.getUTCDay()}function G(e,n){return o(t.utcMonday.count(t.utcYear(e),e),n,2)}function X(e,t){return o(e.getUTCFullYear()%100,t,2)}function K(e,t){return o(e.getUTCFullYear()%1e4,t,4)}function J(){return"+0000"}function Z(){return"%"}function Q(e){return e.toISOString()}function ee(e){var t=new Date(e);return isNaN(t)?null:t}var te="0.3.2",ne={"-":"",_:" ",0:"0"},re=/^\s*\d+/,ie=/^%/,ae=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,oe=a({dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),se=a({dateTime:"%A, %e de %B de %Y, %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["diumenge","dilluns","dimarts","dimecres","dijous","divendres","dissabte"],shortDays:["dg.","dl.","dt.","dc.","dj.","dv.","ds."],months:["gener","febrer","març","abril","maig","juny","juliol","agost","setembre","octubre","novembre","desembre"],shortMonths:["gen.","febr.","març","abr.","maig","juny","jul.","ag.","set.","oct.","nov.","des."]}),le=a({dateTime:"%A, der %e. %B %Y, %X",date:"%d.%m.%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],shortDays:["So","Mo","Di","Mi","Do","Fr","Sa"],months:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],shortMonths:["Jan","Feb","Mrz","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"]}),ue=a({dateTime:"%A, der %e. %B %Y, %X",date:"%d.%m.%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],shortDays:["So","Mo","Di","Mi","Do","Fr","Sa"],months:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],shortMonths:["Jan","Feb","Mrz","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"]}),ce=a({dateTime:"%a %b %e %X %Y",date:"%Y-%m-%d",time:"%H:%M:%S",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),fe=a({dateTime:"%a %e %b %X %Y",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),de=a({dateTime:"%A, %e de %B de %Y, %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["domingo","lunes","martes","miércoles","jueves","viernes","sábado"],shortDays:["dom","lun","mar","mié","jue","vie","sáb"],months:["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"],shortMonths:["ene","feb","mar","abr","may","jun","jul","ago","sep","oct","nov","dic"]}),pe=a({dateTime:"%A, %-d. %Bta %Y klo %X",date:"%-d.%-m.%Y",time:"%H:%M:%S",periods:["a.m.","p.m."],days:["sunnuntai","maanantai","tiistai","keskiviikko","torstai","perjantai","lauantai"],shortDays:["Su","Ma","Ti","Ke","To","Pe","La"],months:["tammikuu","helmikuu","maaliskuu","huhtikuu","toukokuu","kesäkuu","heinäkuu","elokuu","syyskuu","lokakuu","marraskuu","joulukuu"],shortMonths:["Tammi","Helmi","Maalis","Huhti","Touko","Kesä","Heinä","Elo","Syys","Loka","Marras","Joulu"]}),he=a({dateTime:"%a %e %b %Y %X",date:"%Y-%m-%d",time:"%H:%M:%S",periods:["",""],days:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"],shortDays:["dim","lun","mar","mer","jeu","ven","sam"],months:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"],shortMonths:["jan","fév","mar","avr","mai","jui","jul","aoû","sep","oct","nov","déc"]}),me=a({dateTime:"%A, le %e %B %Y, %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"],shortDays:["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],months:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"],shortMonths:["janv.","févr.","mars","avr.","mai","juin","juil.","août","sept.","oct.","nov.","déc."]}),ge=a({dateTime:"%A, %e ב%B %Y %X",date:"%d.%m.%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["ראשון","שני","שלישי","רביעי","חמישי","שישי","שבת"],shortDays:["א׳","ב׳","ג׳","ד׳","ה׳","ו׳","ש׳"],months:["ינואר","פברואר","מרץ","אפריל","מאי","יוני","יולי","אוגוסט","ספטמבר","אוקטובר","נובמבר","דצמבר"],shortMonths:["ינו׳","פבר׳","מרץ","אפר׳","מאי","יוני","יולי","אוג׳","ספט׳","אוק׳","נוב׳","דצמ׳"]}),ve=a({dateTime:"%Y. %B %-e., %A %X",date:"%Y. %m. %d.",time:"%H:%M:%S",periods:["de.","du."],days:["vasárnap","hétfő","kedd","szerda","csütörtök","péntek","szombat"],shortDays:["V","H","K","Sze","Cs","P","Szo"],months:["január","február","március","április","május","június","július","augusztus","szeptember","október","november","december"],shortMonths:["jan.","feb.","már.","ápr.","máj.","jún.","júl.","aug.","szept.","okt.","nov.","dec."]}),be=a({dateTime:"%A %e %B %Y, %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Domenica","Lunedì","Martedì","Mercoledì","Giovedì","Venerdì","Sabato"],shortDays:["Dom","Lun","Mar","Mer","Gio","Ven","Sab"],months:["Gennaio","Febbraio","Marzo","Aprile","Maggio","Giugno","Luglio","Agosto","Settembre","Ottobre","Novembre","Dicembre"],shortMonths:["Gen","Feb","Mar","Apr","Mag","Giu","Lug","Ago","Set","Ott","Nov","Dic"]}),ye=a({dateTime:"%Y %b %e %a %X",date:"%Y/%m/%d",time:"%H:%M:%S",periods:["AM","PM"],days:["日曜日","月曜日","火曜日","水曜日","木曜日","金曜日","土曜日"],shortDays:["日","月","火","水","木","金","土"],months:["睦月","如月","弥生","卯月","皐月","水無月","文月","葉月","長月","神無月","霜月","師走"],shortMonths:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"]}),$e=a({dateTime:"%Y/%m/%d %a %X",date:"%Y/%m/%d",time:"%H:%M:%S",periods:["오전","오후"],days:["일요일","월요일","화요일","수요일","목요일","금요일","토요일"],shortDays:["일","월","화","수","목","금","토"],months:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"],shortMonths:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"]}),we=a({dateTime:"%A, %e %B %Y г. %X",date:"%d.%m.%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["недела","понеделник","вторник","среда","четврток","петок","сабота"],shortDays:["нед","пон","вто","сре","чет","пет","саб"],months:["јануари","февруари","март","април","мај","јуни","јули","август","септември","октомври","ноември","декември"],shortMonths:["јан","фев","мар","апр","мај","јун","јул","авг","сеп","окт","ное","дек"]}),xe=a({dateTime:"%a %e %B %Y %T",date:"%d-%m-%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["zondag","maandag","dinsdag","woensdag","donderdag","vrijdag","zaterdag"],shortDays:["zo","ma","di","wo","do","vr","za"],months:["januari","februari","maart","april","mei","juni","juli","augustus","september","oktober","november","december"],shortMonths:["jan","feb","mrt","apr","mei","jun","jul","aug","sep","okt","nov","dec"]}),ke=a({dateTime:"%A, %e %B %Y, %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Niedziela","Poniedziałek","Wtorek","Środa","Czwartek","Piątek","Sobota"],shortDays:["Niedz.","Pon.","Wt.","Śr.","Czw.","Pt.","Sob."],months:["Styczeń","Luty","Marzec","Kwiecień","Maj","Czerwiec","Lipiec","Sierpień","Wrzesień","Październik","Listopad","Grudzień"],shortMonths:["Stycz.","Luty","Marz.","Kwie.","Maj","Czerw.","Lipc.","Sierp.","Wrz.","Paźdz.","Listop.","Grudz."]}),Ce=a({dateTime:"%A, %e de %B de %Y. %X",date:"%d/%m/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Domingo","Segunda","Terça","Quarta","Quinta","Sexta","Sábado"],shortDays:["Dom","Seg","Ter","Qua","Qui","Sex","Sáb"],months:["Janeiro","Fevereiro","Março","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],shortMonths:["Jan","Fev","Mar","Abr","Mai","Jun","Jul","Ago","Set","Out","Nov","Dez"]}),Me=a({dateTime:"%A, %e %B %Y г. %X",date:"%d.%m.%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["воскресенье","понедельник","вторник","среда","четверг","пятница","суббота"],shortDays:["вс","пн","вт","ср","чт","пт","сб"],months:["января","февраля","марта","апреля","мая","июня","июля","августа","сентября","октября","ноября","декабря"],shortMonths:["янв","фев","мар","апр","май","июн","июл","авг","сен","окт","ноя","дек"]}),Se=a({dateTime:"%A den %d %B %Y %X",date:"%Y-%m-%d",time:"%H:%M:%S",periods:["fm","em"],days:["Söndag","Måndag","Tisdag","Onsdag","Torsdag","Fredag","Lördag"],shortDays:["Sön","Mån","Tis","Ons","Tor","Fre","Lör"],months:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],shortMonths:["Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec"]}),Te=a({dateTime:"%x %A %X",date:"%Y年%-m月%-d日",time:"%H:%M:%S",periods:["上午","下午"],days:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],shortDays:["周日","周一","周二","周三","周四","周五","周六"],months:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],shortMonths:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]}),De="%Y-%m-%dT%H:%M:%S.%LZ",Ee=Date.prototype.toISOString?Q:oe.utcFormat(De),Oe=+new Date("2000-01-01T00:00:00.000Z")?ee:oe.utcParse(De),Ae=oe.format,Ne=oe.parse,je=oe.utcFormat,Le=oe.utcParse;e.timeFormat=Ae,e.timeParse=Ne,e.utcFormat=je,e.utcParse=Le,e.version=te,e.timeFormatLocale=a,e.timeFormatCaEs=se,e.timeFormatDeCh=le,e.timeFormatDeDe=ue,e.timeFormatEnCa=ce,e.timeFormatEnGb=fe,e.timeFormatEnUs=oe,e.timeFormatEsEs=de,e.timeFormatFiFi=pe,e.timeFormatFrCa=he,e.timeFormatFrFr=me,e.timeFormatHeIl=ge,e.timeFormatHuHu=ve,e.timeFormatItIt=be,e.timeFormatJaJp=ye,e.timeFormatKoKr=$e,e.timeFormatMkMk=we,e.timeFormatNlNl=xe,e.timeFormatPlPl=ke,e.timeFormatPtBr=Ce,e.timeFormatRuRu=Me,e.timeFormatSvSe=Se,e.timeFormatZhCn=Te,e.isoFormat=Ee,e.isoParse=Oe})},{"d3-time":"/home/stack/stackviz/node_modules/d3-time-format/node_modules/d3-time/build/d3-time.js"}],"/home/stack/stackviz/node_modules/d3-time-format/node_modules/d3-time/build/d3-time.js":[function(e,t,n){arguments[4]["/home/stack/stackviz/node_modules/d3-scale/node_modules/d3-time/build/d3-time.js"][0].apply(n,arguments)},{}],"/home/stack/stackviz/node_modules/nprogress/nprogress.js":[function(e,t,n){!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof n?t.exports=r():e.NProgress=r()}(this,function(){function e(e,t,n){return t>e?t:e>n?n:e}function t(e){return 100*(-1+e)}function n(e,n,r){var i;return i="translate3d"===u.positionUsing?{transform:"translate3d("+t(e)+"%,0,0)"}:"translate"===u.positionUsing?{transform:"translate("+t(e)+"%,0)"}:{"margin-left":t(e)+"%"},i.transition="all "+n+"ms "+r,i}function r(e,t){var n="string"==typeof e?e:o(e);return n.indexOf(" "+t+" ")>=0}function i(e,t){var n=o(e),i=n+t;r(n,t)||(e.className=i.substring(1))}function a(e,t){var n,i=o(e);r(e,t)&&(n=i.replace(" "+t+" "," "),e.className=n.substring(1,n.length-1))}function o(e){return(" "+(e.className||"")+" ").replace(/\s+/gi," ")}function s(e){e&&e.parentNode&&e.parentNode.removeChild(e)}var l={};l.version="0.2.0";var u=l.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,barSelector:'[role="bar"]',spinnerSelector:'[role="spinner"]',parent:"body",template:'<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'};l.configure=function(e){var t,n;for(t in e)n=e[t],void 0!==n&&e.hasOwnProperty(t)&&(u[t]=n);return this},l.status=null,l.set=function(t){var r=l.isStarted();t=e(t,u.minimum,1),l.status=1===t?null:t;var i=l.render(!r),a=i.querySelector(u.barSelector),o=u.speed,s=u.easing;return i.offsetWidth,c(function(e){""===u.positionUsing&&(u.positionUsing=l.getPositioningCSS()),f(a,n(t,o,s)),1===t?(f(i,{transition:"none",opacity:1}),i.offsetWidth,setTimeout(function(){f(i,{transition:"all "+o+"ms linear",opacity:0}),setTimeout(function(){l.remove(),e()},o)},o)):setTimeout(e,o)}),this},l.isStarted=function(){return"number"==typeof l.status},l.start=function(){l.status||l.set(0);var e=function(){setTimeout(function(){l.status&&(l.trickle(),e())},u.trickleSpeed)};return u.trickle&&e(),this},l.done=function(e){return e||l.status?l.inc(.3+.5*Math.random()).set(1):this},l.inc=function(t){var n=l.status;return n?("number"!=typeof t&&(t=(1-n)*e(Math.random()*n,.1,.95)),n=e(n+t,0,.994),l.set(n)):l.start()},l.trickle=function(){return l.inc(Math.random()*u.trickleRate)},function(){var e=0,t=0;l.promise=function(n){return n&&"resolved"!==n.state()?(0===t&&l.start(),e++,t++,n.always(function(){t--,0===t?(e=0,l.done()):l.set((e-t)/e)}),this):this}}(),l.render=function(e){if(l.isRendered())return document.getElementById("nprogress");i(document.documentElement,"nprogress-busy");var n=document.createElement("div");n.id="nprogress",n.innerHTML=u.template;var r,a=n.querySelector(u.barSelector),o=e?"-100":t(l.status||0),c=document.querySelector(u.parent);return f(a,{transition:"all 0 linear",transform:"translate3d("+o+"%,0,0)"}),u.showSpinner||(r=n.querySelector(u.spinnerSelector),r&&s(r)),c!=document.body&&i(c,"nprogress-custom-parent"),c.appendChild(n),n},l.remove=function(){a(document.documentElement,"nprogress-busy"),a(document.querySelector(u.parent),"nprogress-custom-parent");var e=document.getElementById("nprogress");e&&s(e)},l.isRendered=function(){return!!document.getElementById("nprogress")},l.getPositioningCSS=function(){var e=document.body.style,t="WebkitTransform"in e?"Webkit":"MozTransform"in e?"Moz":"msTransform"in e?"ms":"OTransform"in e?"O":"";return t+"Perspective"in e?"translate3d":t+"Transform"in e?"translate":"margin"};var c=function(){function e(){var n=t.shift();n&&n(e)}var t=[];return function(n){t.push(n),1==t.length&&e()}}(),f=function(){function e(e){return e.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(e,t){return t.toUpperCase()})}function t(e){var t=document.body.style;if(e in t)return e;for(var n,r=i.length,a=e.charAt(0).toUpperCase()+e.slice(1);r--;)if(n=i[r]+a,n in t)return n;return e}function n(n){return n=e(n),a[n]||(a[n]=t(n))}function r(e,t,r){t=n(t),e.style[t]=r}var i=["Webkit","O","Moz","ms"],a={};return function(e,t){var n,i,a=arguments;if(2==a.length)for(n in t)i=t[n],void 0!==i&&t.hasOwnProperty(n)&&r(e,n,i);else r(e,a[1],a[2])}}();return l})},{}]},{},["/home/stack/stackviz/app/js/main.js"]);
//# sourceMappingURL=main.js.map