return!!a},va:function(b){returna.a.Gb(b,b.ownerDocument.documentElement)},Ra:function(b){return!!a.a.Ua(b,a.a.va)},v:function(a){returna&&a.tagName&&a.tagName.toLowerCase()},r:function(b,d,f){vare=h&&g[d];if(e||"undefined"==typeofu)if(e||"function"!=typeofb.addEventListener)if("undefined"!=typeofb.attachEvent){vars=function(a){f.call(b,a)},l="on"+d;b.attachEvent(l,s);a.a.C.ea(b,function(){b.detachEvent(l,s)})}elsethrowError("Browser doesn't support addEventListener or attachEvent");elseb.addEventListener(d,
f,!1);else{if(c(b,d)){varn=f;f=function(a,b){varf=this.checked;b&&(this.checked=!0!==b.Ab);n.call(this,a);this.checked=f}}u(b).bind(d,f)}},da:function(a,b){if(!a||!a.nodeType)throwError("element must be a DOM node when calling triggerEvent");if("undefined"!=typeofu){varf=[];c(a,b)&&f.push({Ab:a.checked});u(a).trigger(b,f)}elseif("function"==typeofw.createEvent)if("function"==typeofa.dispatchEvent)f=w.createEvent(e[b]||"HTMLEvents"),f.initEvent(b,!0,!0,y,0,0,0,0,0,!1,!1,!1,!1,0,a),a.dispatchEvent(f);
elsethrowError("The supplied element doesn't support dispatchEvent");elseif("undefined"!=typeofa.fireEvent)c(a,b)&&(a.checked=!0!==a.checked),a.fireEvent("on"+b);elsethrowError("Browser doesn't support triggering events");},c:function(b){returna.M(b)?b():b},Ha:function(b){returna.M(b)?b.t():b},ma:function(b,c,f){if(c){vard=/\S+/g,e=b.className.match(d)||[];a.a.n(c.match(d),function(b){a.a.V(e,b,f)});b.className=e.join("")}},Ma:function(b,c){varf=a.a.c(c);if(null===f||f===q)f="";vard=a.e.firstChild(b);
d;c++)b.push(a[c]);returnb},cc:6===h,dc:7===h,ja:h,ab:function(b,c){for(varf=a.a.Q(b.getElementsByTagName("input")).concat(a.a.Q(b.getElementsByTagName("textarea"))),d="string"==typeofc?function(a){returna.name===c}:function(a){returnc.test(a.name)},e=[],g=f.length-1;0<=g;g--)d(f[g])&&e.push(f[g]);returne},Wb:function(b){return"string"==typeofb&&(b=a.a.la(b))?B&&B.parse?B.parse(b):(newFunction("return "+b))():null},Na:function(b,c,f){if(!B||!B.stringify)throwError("Cannot find JSON.stringify(). Some browsers (e.g., IE < 8) don't support it natively, but you can overcome this by adding a script reference to json2.js, downloadable from http://www.json.org/json2.js");
typeofc)throwError("Callback must be a function");b(a,!0).push(c)},mb:function(c,e){varg=b(c,!1);g&&(a.a.ia(g,e),0==g.length&&a.a.f.set(c,d,q))},L:function(b){if(e[b.nodeType]&&(c(b),g[b.nodeType])){vard=[];a.a.X(d,b.getElementsByTagName("*"));for(varm=0,f=d.length;m<f;m++)c(d[m])}returnb},removeNode:function(b){a.L(b);b.parentNode&&b.parentNode.removeChild(b)}}};a.L=a.a.C.L;a.removeNode=a.a.C.removeNode;a.b("cleanNode",a.L);a.b("removeNode",a.removeNode);a.b("utils.domNodeDisposal",a.a.C);
a.b("utils.parseHtmlFragment",a.a.Fa);a.b("utils.setHtml",a.a.Ka);a.u=function(){functionb(c,e){if(c)if(8==c.nodeType){varg=a.u.jb(c.nodeValue);null!=g&&e.push({Fb:c,Tb:g})}elseif(1==c.nodeType)for(varg=0,h=c.childNodes,k=h.length;g<k;g++)b(h[g],e)}varc={};return{Ca:function(a){if("function"!=typeofa)throwError("You can only pass a function to ko.memoization.memoize()");varb=(4294967296*(1+Math.random())|0).toString(16).substring(1)+(4294967296*(1+Math.random())|0).toString(16).substring(1);
c[b]=a;return"\x3c!--[ko_memo:"+b+"]--\x3e"},ub:function(a,b){varg=c[a];if(g===q)throwError("Couldn't find any memo with ID "+a+". Perhaps it's already been unmemoized.");try{returng.apply(null,b||[]),!0}finally{deletec[a]}},vb:function(c,e){varg=[];b(c,g);for(varh=0,k=g.length;h<k;h++){varm=g[h].Fb,f=[m];e&&a.a.X(f,e);a.u.ub(g[h].Tb,f);m.nodeValue="";m.parentNode&&m.parentNode.removeChild(m)}},jb:function(a){return(a=a.match(/^\[ko_memo\:(.*?)\]$/))?a[1]:null}}}();a.b("memoization",a.u);a.b("memoization.memoize",
end:function(){b.pop()},lb:function(c){if(!a.fb(c))throwError("Only subscribable things can act as dependencies");if(0<b.length){vard=b[b.length-1];!d||0<=a.a.l(d.Za,c)||(d.Za.push(c),d.qa(c))}},p:function(a,d,e){try{returnb.push(null),a.apply(d,e||[])}finally{b.pop()}}}}();a.q=function(b){functionc(){if(0<arguments.length)returnc.equalityComparer&&c.equalityComparer(d,arguments[0])||(c.O(),d=arguments[0],c.N()),this;a.i.lb(c);returnd}vard=b;a.ca.call(c);c.t=function(){returnd};c.N=function(){c.notifySubscribers(d)};
a.gb);a.ba=function(b){b=b||[];if("object"!=typeofb||!("length"inb))throwError("The argument passed when initializing an observable array must be an array, or null, or undefined.");b=a.q(b);a.a.extend(b,a.ba.fn);returnb.extend({trackArrayChanges:!0})};a.ba.fn={remove:function(b){for(varc=this.t(),d=[],e="function"!=typeofb||a.M(b)?function(a){returna===b}:b,g=0;g<c.length;g++){varh=c[g];e(h)&&(0===d.length&&this.O(),d.push(h),c.splice(g,1),g--)}d.length&&this.N();returnd},removeAll:function(b){if(b===
p=!0;return}}elsel=!1;s=!0;try{varb=a.a.ha(z,function(a){returna.target});a.i.Wa(function(c){vard;0<=(d=a.a.l(b,c))?b[d]=q:z.push(c.T(g))});for(vard=c?n.call(c):n(),e=b.length-1;0<=e;e--)b[e]&&z.splice(e,1)[0].B();p=!0;k.equalityComparer&&k.equalityComparer(f,d)||(k.notifySubscribers(f,"beforeChange"),f=d,k.notifySubscribers(f))}finally{a.i.end(),s=!1}z.length||D()}}functionk(){if(0<arguments.length){if("function"===typeofr)r.apply(c,arguments);elsethrowError("Cannot write a value to a ko.computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");
returnthis}p||h();a.i.lb(k);returnf}functionm(){return!p||0<z.length}varf,p=!1,s=!1,l=!1,n=b;n&&"object"==typeofn?(d=n,n=d.read):(d=d||{},n||(n=d.read));if("function"!=typeofn)throwError("Pass a function that returns the value of the ko.computed");varr=d.write,v=d.disposeWhenNodeIsRemoved||d.I||null,t=d.disposeWhen||d.ua,E=t,D=e,z=[],x=null;c||(c=d.owner);k.t=function(){p||h();returnf};k.Kb=function(){returnz.length};k.Nb="function"===typeofd.write;k.B=function(){D()};k.aa=m;a.ca.call(k);
[];this.Qa=[]}a.tb=function(c){if(0==arguments.length)throwError("When calling ko.toJS, pass the object you want to convert.");returnb(c,function(b){for(varc=0;a.M(b)&&10>c;c++)b=b();returnb})};a.toJSON=function(b,c,d){b=a.tb(b);returna.a.Na(b,c,d)};d.prototype={save:function(b,c){vard=a.a.l(this.keys,b);0<=d?this.Qa[d]=c:(this.keys.push(b),this.Qa.push(c))},get:function(b){b=a.a.l(this.keys,b);return0<=b?this.Qa[b]:q}}})();a.b("toJS",a.tb);a.b("toJSON",a.toJSON);(function(){a.k={o:function(b){switch(a.a.v(b)){case"option":return!0===
d){for(vare=a,k=1,n=[];e=e.nextSibling;){if(c(e)&&(k--,0===k))returnn;n.push(e);b(e)&&k++}if(!d)throwError("Cannot find closing comment tag to match: "+a.nodeValue);returnnull}functione(a,b){varc=d(a,b);returnc?0<c.length?c[c.length-1].nextSibling:a.nextSibling:null}varg=w&&"\x3c!--test--\x3e"===w.createComment("test").text,h=g?/^\x3c!--\s*ko(?:\s+([\s\S]+))?\s*--\x3e$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,k=g?/^\x3c!--\s*\/ko\s*--\x3e$/:/^\s*\/ko\s*$/,m={ul:!0,ol:!0};a.e={P:{},childNodes:function(a){returnb(a)?
(f.push(e),a.a.n(k.after,function(c){if(b[c]){if(-1!==a.a.l(f,c))throwError("Cannot combine the following bindings, because they have a cyclic dependency: "+f.join(", "));D(c)}}),f.pop()),c.push({key:e,bb:k}));d[e]=!0}});returnc}functionm(b,d,f,g){varh=a.a.f.get(b,s);if(!d){if(h)throwError("You cannot apply bindings multiple times to the same element.");a.a.f.set(b,s,!0)}!h&&g&&a.rb(b,f);varm;if(d&&"function"!==typeofd)m=d;else{varp=a.H.instance,l=p.getBindingAccessors||e;if(d||f.A){varA=
a.h(function(){(m=d?d(f,b):l.call(p,b,f))&&f.A&&f.A();returnm},null,{I:b});m&&A.aa()||(A=null)}elsem=a.i.p(l,p,[b,f])}varu;if(m){varw=A?function(a){returnfunction(){returnc(A()[a])}}:function(a){returnm[a]},y=function(){returna.a.Da(A?A():m,c)};y.get=function(a){returnm[a]&&c(w(a))};y.has=function(a){returnainm};g=k(m);a.a.n(g,function(c){vard=c.bb.init,e=c.bb.update,k=c.key;if(8===b.nodeType&&!a.e.P[k])throwError("The binding '"+k+"' cannot be used with virtual elements");try{"function"==
typeofd&&a.i.p(function(){vara=d(b,w(k),y,f.$data,f);if(a&&a.controlsDescendantBindings){if(u!==q)throwError("Multiple bindings ("+u+" and "+k+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");u=k}}),"function"==typeofe&&a.h(function(){e(b,w(k),y,f.$data,f)},null,{I:b})}catch(g){throwg.message='Unable to process binding "'+k+": "+m[k]+'"\nMessage: '+g.message,g;}})}return{shouldBindDescendants:u===q}}functionf(b){returnb&&
a.e.ib(b);returnm(b,c,f(d),!0)};a.xb=function(c,e,k){k=f(k);returna.pa(c,"function"===typeofe?d(e.bind(null,k,c)):a.a.Da(e,b),k)};a.Ta=function(a,b){1!==b.nodeType&&8!==b.nodeType||g(f(a),b,!0)};a.Sa=function(a,b){if(b&&1!==b.nodeType&&8!==b.nodeType)throwError("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");b=b||y.document.body;h(f(a),b,!0)};a.ta=function(b){switch(b.nodeType){case1:case8:varc=a.rb(b);if(c)returnc;if(b.parentNode)returna.ta(b.parentNode)}returnq};
null,[b,d?"focusin":"focusout"]))}};a.g.U.hasfocus=!0;a.d.hasFocus=a.d.hasfocus;a.g.U.hasFocus=!0;a.d.html={init:function(){return{controlsDescendantBindings:!0}},update:function(b,c){a.a.Ka(b,c())}};varL=a.a.f.D();H("if");H("ifnot",!1,!0);H("with",!0,!1,function(a,c){returna.createChildContext(c)});a.d.options={init:function(b){if("select"!==a.a.v(b))throwError("options binding applies only to SELECT elements");for(;0<b.length;)b.remove(0);return{controlsDescendantBindings:!0}},update:function(b,
a.g.oa(e,d,"selectedOptions",g)})},update:function(b,c){if("select"!=a.a.v(b))throwError("values binding applies only to SELECT elements");vard=a.a.c(c());d&&"number"==typeofd.length&&a.a.n(b.getElementsByTagName("option"),function(b){varc=0<=a.a.l(d,a.k.o(b));a.a.qb(b,c)})}};a.g.U.selectedOptions=!0;a.d.style={update:function(b,c){vard=a.a.c(c()||{});a.a.K(d,function(c,d){d=a.a.c(d);b.style[c]=d||""})}};a.d.submit={init:function(b,c,d,e,g){if("function"!=typeofc())throwError("The value for a submit binding must be a function");
};a.w.prototype.createJavaScriptEvaluatorBlock=function(){throwError("Override createJavaScriptEvaluatorBlock");};a.w.prototype.makeTemplateSource=function(b,c){if("string"==typeofb){c=c||w;vard=c.getElementById(b);if(!d)throwError("Cannot find template with ID "+b);returnnewa.m.j(d)}if(1==b.nodeType||8==b.nodeType)returnnewa.m.W(b);throwError("Unknown template type: "+b);};a.w.prototype.renderTemplate=function(a,c,d,e){a=this.makeTemplateSource(a,e);returnthis.renderTemplateSource(a,c,
d)};a.w.prototype.isTemplateRewritten=function(a,c){return!1===this.allowTemplateRewriting?!0:this.makeTemplateSource(a,c).data("isRewritten")};a.w.prototype.rewriteTemplate=function(a,c,d){a=this.makeTemplateSource(a,d);c=c(a.text());a.text(c);a.data("isRewritten",!0)};a.b("templateEngine",a.w);a.Oa=function(){functionb(b,c,d,k){b=a.g.Ga(b);for(varm=a.g.Y,f=0;f<b.length;f++){varp=b[f].key;if(m.hasOwnProperty(p)){vars=m[p];if("function"===typeofs){if(p=s(b[f].value))throwError(p);}elseif(!s)throwError("This template engine does not support the '"+
p+"' binding within its templates");}}d="ko.__tr_ambtns(function($context,$element){return(function(){return{ "+a.g.ka(b,{valueAccessors:!0})+" } })()},'"+d.toLowerCase()+"')";returnk.createJavaScriptEvaluatorBlock(d)+c}varc=/(<([a-z]+\d*)(?:\s+(?!data-bind\s*=\s*)[a-z0-9\-]+(?:=(?:\"[^\"]*\"|\'[^\']*\'))?)*\s+)data-bind\s*=\s*(["'])([\s\S]*?)\3/gi,d=/\x3c!--\s*ko\b\s*([\s\S]*?)\s*--\x3e/g;return{Ib:function(b,c,d){c.isTemplateRewritten(b,d)||c.rewriteTemplate(b,function(b){returna.Oa.Ub(b,c)},
d)},Ub:function(a,g){returna.replace(c,function(a,c,d,f,e){returnb(e,c,d,g)}).replace(d,function(a,c){returnb(c,"\x3c!-- ko --\x3e","#comment",g)})},yb:function(b,c){returna.u.Ca(function(d,k){varm=d.nextSibling;m&&m.nodeName.toLowerCase()===c&&a.pa(m,b,k)})}}}();a.b("__tr_ambtns",a.Oa.yb);(function(){a.m={};a.m.j=function(a){this.j=a};a.m.j.prototype.text=function(){varb=a.a.v(this.j),b="script"===b?"text":"textarea"===b?"value":"innerHTML";if(0==arguments.length)returnthis.j[b];varc=arguments[0];
0;if(!f)return;f===e?c.push(f):(c.push(f,e),a.a.$(c,g))}b(f,e,function(b){1!==b.nodeType&&8!==b.nodeType||a.Sa(d,b)});b(f,e,function(b){1!==b.nodeType&&8!==b.nodeType||a.u.vb(b,[d])});a.a.$(c,g)}}functiond(a){returna.nodeType?a:0<a.length?a[0]:null}functione(b,e,f,h,s){s=s||{};varl=b&&d(b),l=l&&l.ownerDocument,n=s.templateEngine||g;a.Oa.Ib(f,n,l);f=n.renderTemplate(f,h,s,l);if("number"!=typeoff.length||0<f.length&&"number"!=typeoff[0].nodeType)throwError("Template engine must return an array of DOM nodes");
l=!1;switch(e){case"replaceChildren":a.e.S(b,f);l=!0;break;case"replaceNode":a.a.nb(b,f);l=!0;break;case"ignoreTargetNode":break;default:throwError("Unknown renderMode: "+e);}l&&(c(f,h),s.afterRender&&a.i.p(s.afterRender,null,[f,h.$data]));returnf}varg;a.La=function(b){if(b!=q&&!(binstanceofa.w))throwError("templateEngine must inherit from ko.templateEngine");g=b};a.Ia=function(b,c,f,h,s){f=f||{};if((f.templateEngine||g)==q)throwError("Set a template engine before calling renderTemplate");
a.a.c(c());d={};e=!0;varl,n=null;"string"!=typeofc&&(d=c,c=a.a.c(d.name),"if"ind&&(e=a.a.c(d["if"])),e&&"ifnot"ind&&(e=!a.a.c(d.ifnot)),l=a.a.c(d.data));"foreach"ind?n=a.$b(c||b,e&&d.foreach||[],d,b,g):e?(g="data"ind?g.createChildContext(l,d.as):g,n=a.Ia(c||b,g,d,b)):a.e.Z(b);g=n;(l=a.a.f.get(b,h))&&"function"==typeofl.B&&l.B();a.a.f.set(b,h,g&&g.aa()?g:q)}};a.g.Y.template=function(b){b=a.g.Ga(b);return1==b.length&&b[0].unknown||a.g.Sb(b,"name")?null:"This template engine does not support anonymous templates nested within its templates"};
newa.J;a.La(a.J.Aa);a.b("nativeTemplateEngine",a.J);(function(){a.Ba=function(){vara=this.Rb=function(){if("undefined"==typeofu||!u.tmpl)return0;try{if(0<=u.tmpl.tag.tmpl.open.toString().indexOf("__"))return2}catch(a){}return1}();this.renderTemplateSource=function(b,e,g){g=g||{};if(2>a)throwError("Your version of jQuery.tmpl is too old. Please upgrade to jQuery.tmpl 1.0.0pre or later.");varh=b.data("precompiled");h||(h=b.text()||"",h=u.template(null,"{{ko_with $item.koBindingContext}}"+h+
<p>Written by <ahref="https://github.com/ashish01/knockoutjs-todos">Ashish Sharma</a>, <ahref="http://knockmeout.net">Ryan Niemeyer</a> and <ahref="https://twitter.com/loicknuchel">Loïc Knuchel</a></p>
<p>Part of <ahref="http://todomvc.com">TodoMVC</a></p>
16);for(;a&&a!=b;)a=a.parentNode;return!!a},Ja:function(b){returna.a.cc(b,b.ownerDocument.documentElement)},ob:function(b){return!!a.a.qb(b,a.a.Ja)},t:function(a){returna&&a.tagName&&a.tagName.toLowerCase()},n:function(b,c,d){vare=g&&k[c];if(!e&&r)r(b).bind(c,d);elseif(e||"function"!=typeofb.addEventListener)if("undefined"!=typeofb.attachEvent){varf=function(a){d.call(b,a)},h="on"+c;b.attachEvent(h,f);a.a.w.da(b,function(){b.detachEvent(h,f)})}elsethrowError("Browser doesn't support addEventListener or attachEvent");
elseb.addEventListener(c,d,!1)},oa:function(b,c){if(!b||!b.nodeType)throwError("element must be a DOM node when calling triggerEvent");vard;"input"===a.a.t(b)&&b.type&&"click"==c.toLowerCase()?(d=b.type,d="checkbox"==d||"radio"==d):d=!1;if(r&&!d)r(b).trigger(c);elseif("function"==typeofy.createEvent)if("function"==typeofb.dispatchEvent)d=y.createEvent(h[c]||"HTMLEvents"),d.initEvent(c,!0,!0,v,0,0,0,0,0,!1,!1,!1,!1,0,b),b.dispatchEvent(d);elsethrowError("The supplied element doesn't support dispatchEvent");
elseif(d&&b.click)b.click();elseif("undefined"!=typeofb.fireEvent)b.fireEvent("on"+c);elsethrowError("Browser doesn't support triggering events");},c:function(b){returna.C(b)?b():b},Xa:function(b){returna.C(b)?b.v():b},Ba:function(b,c,d){if(c){varg=/\S+/g,e=b.className.match(g)||[];a.a.u(c.match(g),function(b){a.a.ea(e,b,d)});b.className=e.join("")}},bb:function(b,c){vard=a.a.c(c);if(null===d||d===n)d="";varg=a.f.firstChild(b);!g||3!=g.nodeType||a.f.nextSibling(g)?a.f.T(b,[b.ownerDocument.createTextNode(d)]):
a.a.S(b.getElementsByTagName("input")).concat(a.a.S(b.getElementsByTagName("textarea"))),g="string"==typeofc?function(a){returna.name===c}:function(a){returnc.test(a.name)},e=[],f=d.length-1;0<=f;f--)g(d[f])&&e.push(d[f]);returne},pc:function(b){return"string"==typeofb&&(b=a.a.cb(b))?D&&D.parse?D.parse(b):(newFunction("return "+b))():null},eb:function(b,c,d){if(!D||!D.stringify)throwError("Cannot find JSON.stringify(). Some browsers (e.g., IE < 8) don't support it natively, but you can overcome this by adding a script reference to json2.js, downloadable from http://www.json.org/json2.js");
c}}};a.b("utils.domData",a.a.e);a.b("utils.domData.clear",a.a.e.clear);a.a.w=newfunction(){functionb(b,d){varg=a.a.e.get(b,c);g===n&&d&&(g=[],a.a.e.set(b,c,g));returng}functiond(c){vare=b(c,!1);if(e)for(vare=e.slice(0),g=0;g<e.length;g++)e[g](c);a.a.e.clear(c);a.a.w.cleanExternalData(c);if(f[c.nodeType])for(e=c.firstChild;c=e;)e=c.nextSibling,8===c.nodeType&&d(c)}varc=a.a.e.F(),e={1:!0,8:!0,9:!0},f={1:!0,9:!0};return{da:function(a,c){if("function"!=typeofc)throwError("Callback must be a function");
a.a.ba);a.b("utils.setHtml",a.a.$a);a.D=function(){functionb(c,d){if(c)if(8==c.nodeType){varf=a.D.Gb(c.nodeValue);null!=f&&d.push({bc:c,mc:f})}elseif(1==c.nodeType)for(varf=0,h=c.childNodes,k=h.length;f<k;f++)b(h[f],d)}vard={};return{Ua:function(a){if("function"!=typeofa)throwError("You can only pass a function to ko.memoization.memoize()");varb=(4294967296*(1+Math.random())|0).toString(16).substring(1)+(4294967296*(1+Math.random())|0).toString(16).substring(1);d[b]=a;return"\x3c!--[ko_memo:"+
b+"]--\x3e"},Rb:function(a,b){varf=d[a];if(f===n)throwError("Couldn't find any memo with ID "+a+". Perhaps it's already been unmemoized.");try{returnf.apply(null,b||[]),!0}finally{deleted[a]}},Sb:function(c,d){varf=[];b(c,f);for(varh=0,k=f.length;h<k;h++){varg=f[h].bc,m=[g];d&&a.a.ga(m,d);a.D.Rb(f[h].mc,m);g.nodeValue="";g.parentNode&&g.parentNode.removeChild(g)}},Gb:function(a){return(a=a.match(/^\[ko_memo\:(.*?)\]$/))?a[1]:null}}}();a.b("memoization",a.D);a.b("memoization.memoize",a.D.Ua);
e=a}functiond(){e=c.pop()}varc=[],e,f=0;return{Ea:b,end:d,Jb:function(b){if(e){if(!a.Db(b))throwError("Only subscribable things can act as dependencies");e.wa(b,b.Vb||(b.Vb=++f))}},B:function(a,c,g){try{returnb(),a.apply(c,g||[])}finally{d()}},la:function(){if(e)returne.s.la()},ma:function(){if(e)returne.ma}}}();a.b("computedContext",a.Y);a.b("computedContext.getDependenciesCount",a.Y.la);a.b("computedContext.isInitial",a.Y.ma);a.b("computedContext.isSleeping",a.Y.zc);a.p=function(b){functiond(){if(0<
d?!0:a.Ma(b[F],d)};a.C=function(b){returna.Ma(b,a.p)};a.Ra=function(b){return"function"==typeofb&&b[F]===a.p||"function"==typeofb&&b[F]===a.j&&b.hc?!0:!1};a.b("observable",a.p);a.b("isObservable",a.C);a.b("isWriteableObservable",a.Ra);a.b("isWritableObservable",a.Ra);a.aa=function(b){b=b||[];if("object"!=typeofb||!("length"inb))throwError("The argument passed when initializing an observable array must be an array, or null, or undefined.");b=a.p(b);a.a.Aa(b,a.aa.fn);returnb.extend({trackArrayChanges:!0})};
p?h:Math.min(d+(m[1]||0),h),p=d+p-2,z=Math.max(h,p),u=[],t=[],E=2;d<z;++d,++E)d<h&&t.push(l("deleted",b[d],d)),d<p&&u.push(l("added",m[E],d));a.a.wb(t,u);break;default:return}e=s}}}};a.s=a.j=function(b,d,c){functione(){a.a.G(v,function(a,b){b.K()});v={}}functionf(){e();A=0;u=!0;q=!1}functionh(){vara=g.throttleEvaluation;a&&0<=a?(clearTimeout(O),O=setTimeout(k,a)):g.ib?g.ib():k()}functionk(b){if(p){if(E)throwError("A 'pure' computed must not be called recursively");}elseif(!u){if(J&&J()){if(!z){r();
typeofG)G.apply(d,arguments);elsethrowError("Cannot write a value to a ko.computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");returnthis}a.k.Jb(g);q&&k(!0);returns}functionm(){q&&!A&&k(!0);returns}functionl(){returnq||0<A}vars,q=!0,p=!1,z=!1,u=!1,t=b,E=!1,x=!1;t&&"object"==typeoft?(c=t,t=c.read):(c=c||{},t||(t=c.read));if("function"!=typeoft)throwError("Pass a function that returns the value of the ko.computed");varG=c.write,
0;c<a.length;c++)b(c);"function"==typeofa.toJSON&&b("toJSON")}elsefor(cina)b(c)}functionc(){this.keys=[];this.hb=[]}a.Qb=function(c){if(0==arguments.length)throwError("When calling ko.toJS, pass the object you want to convert.");returnb(c,function(b){for(varc=0;a.C(b)&&10>c;c++)b=b();returnb})};a.toJSON=function(b,c,d){b=a.Qb(b);returna.a.eb(b,c,d)};c.prototype={save:function(b,c){vard=a.a.m(this.keys,b);0<=d?this.hb[d]=c:(this.keys.push(b),this.hb.push(c))},get:function(b){b=a.a.m(this.keys,
a.h.ya);(function(){functionb(a){return8==a.nodeType&&h.test(f?a.text:a.nodeValue)}functiond(a){return8==a.nodeType&&k.test(f?a.text:a.nodeValue)}functionc(a,c){for(varg=a,e=1,f=[];g=g.nextSibling;){if(d(g)&&(e--,0===e))returnf;f.push(g);b(g)&&e++}if(!c)throwError("Cannot find closing comment tag to match: "+a.nodeValue);returnnull}functione(a,b){vard=c(a,b);returnd?0<d.length?d[d.length-1].nextSibling:a.nextSibling:null}varf=y&&"\x3c!--test--\x3e"===y.createComment("test").text,h=f?
k(b,g,d)}functionk(b,c,d){varg=!0,e=1===c.nodeType;e&&a.f.Fb(c);if(e&&d||a.J.instance.nodeHasBindings(c))g=m(c,null,b,d).shouldBindDescendants;g&&!s[a.a.t(c)]&&h(b,c,!e)}functiong(b){varc=[],d={},g=[];a.a.G(b,functionG(e){if(!d[e]){varl=a.getBindingHandler(e);l&&(l.after&&(g.push(e),a.a.u(l.after,function(c){if(b[c]){if(-1!==a.a.m(g,c))throwError("Cannot combine the following bindings, because they have a cyclic dependency: "+g.join(", "));G(c)}}),g.length--),c.push({key:e,zb:l}));d[e]=!0}});
returnc}functionm(b,c,e,l){varm=a.a.e.get(b,q);if(!c){if(m)throwError("You cannot apply bindings multiple times to the same element.");a.a.e.set(b,q,!0)}!m&&l&&a.Ob(b,e);varh;if(c&&"function"!==typeofc)h=c;else{vark=a.J.instance,s=k.getBindingAccessors||f,p=a.j(function(){(h=c?c(e,b):s.call(k,b,e))&&e.I&&e.I();returnh},null,{o:b});h&&p.Z()||(p=null)}varr;if(h){varv=p?function(a){returnfunction(){returnd(p()[a])}}:function(a){returnh[a]},A=function(){returna.a.na(p?p():h,d)};A.get=function(a){returnh[a]&&
d(v(a))};A.has=function(a){returnainh};l=g(h);a.a.u(l,function(c){vard=c.zb.init,g=c.zb.update,l=c.key;if(8===b.nodeType&&!a.f.Q[l])throwError("The binding '"+l+"' cannot be used with virtual elements");try{"function"==typeofd&&a.k.B(function(){vara=d(b,v(l),A,e.$data,e);if(a&&a.controlsDescendantBindings){if(r!==n)throwError("Multiple bindings ("+r+" and "+l+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");r=l}}),
"function"==typeofg&&a.j(function(){g(b,v(l),A,e.$data,e)},null,{o:b})}catch(f){throwf.message='Unable to process binding "'+l+": "+h[l]+'"\nMessage: '+f.message,f;}})}return{shouldBindDescendants:r===n}}functionl(b){returnb&&binstanceofa.N?b:newa.N(b)}a.d={};vars={script:!0};a.getBindingHandler=function(b){returna.d[b]};a.N=function(b,c,d,g){vare=this,l="function"==typeofb&&!a.C(b),f,m=a.j(function(){varf=l?b():b,h=a.a.c(f);c?(c.I&&c.I(),a.a.extend(e,c),m&&(e.I=m)):(e.$parents=[],e.$root=
this.$data,this,null,function(c,d){c.$rawData=d.$rawData;a.a.extend(c,"function"==typeofb?b():b)})};varq=a.a.e.F(),p=a.a.e.F();a.Ob=function(b,c){if(2==arguments.length)a.a.e.set(b,p,c),c.I&&c.I.Tb(b);elsereturna.a.e.get(b,p)};a.ra=function(b,c,d){1===b.nodeType&&a.f.Fb(b);returnm(b,c,l(d),!0)};a.Wb=function(b,c,d){d=l(d);returna.ra(b,e(c,d,b),d)};a.Ca=function(a,b){1!==b.nodeType&&8!==b.nodeType||h(l(a),b,!0)};a.pb=function(a,b){!r&&v.jQuery&&(r=v.jQuery);if(b&&1!==b.nodeType&&8!==b.nodeType)throwError("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");
c(d,function(a){h[d]=a;deletef[d];l?e.notifySubscribers(a):setTimeout(function(){e.notifySubscribers(a)},0)}),l=!0);e.U(g)}functionc(a,b){e("getConfig",[a],function(c){c?e("loadComponent",[a,c],function(a){b(a)}):b(null)})}functione(c,d,f,l){l||(l=a.g.loaders.slice(0));varh=l.shift();if(h){varq=h[c];if(q){varp=!1;if(q.apply(h,d.concat(function(a){p?f(null):null!==a?f(a):e(c,d,f,l)}))!==b&&(p=!0,!h.suppressLoaderExceptions))throwError("Component loaders must supply values by invoking the callback, not by returning values synchronously.");
ainstanceofDocumentFragment:a&&11===a.nodeType}functionf(a,b,c){"string"===typeofb.require?N||v.require?(N||v.require)([b.require],c):a("Uses require, but no AMD loader is present"):c(b)}functionh(a){returnfunction(b){throwError("Component '"+a+"': "+b);}}vark={};a.g.register=function(b,c){if(!c)throwError("Invalid configuration for "+b);if(a.g.Qa(b))throwError("Component "+b+" is already registered");k[b]=c};a.g.Qa=function(a){returnaink};a.g.vc=function(b){deletek[b];a.g.tb(b)};a.g.ub=
{getConfig:function(a,b){b(k.hasOwnProperty(a)?k[a]:null)},loadComponent:function(a,c,d){vare=h(a);f(e,c,function(c){b(a,e,c,d)})},loadTemplate:function(b,d,g){b=h(b);if("string"===typeofd)g(a.a.ba(d));elseif(dinstanceofArray)g(d);elseif(e(d))g(a.a.S(d.childNodes));elseif(d.element)if(d=d.element,v.HTMLElement?dinstanceofHTMLElement:d&&d.tagName&&1===d.nodeType)g(c(d));elseif("string"===typeofd){varf=y.getElementById(d);f?g(c(f)):b("Cannot find element with ID "+d)}elseb("Unknown element type: "+
a.s(function(){returna.a.c(d())},null,{o:b}):d.v()});h.hasOwnProperty("$raw")||(h.$raw=f);returnh}return{$raw:{}}}a.g.getComponentNameForNode=function(b){b=a.a.t(b);returna.g.Qa(b)&&b};a.g.mb=function(c,d,f,h){if(1===d.nodeType){vark=a.g.getComponentNameForNode(d);if(k){c=c||{};if(c.component)throwError('Cannot use the "component" binding on a custom element matching a component');varg={name:k,params:b(d,f)};c.component=h?function(){returng}:g}}returnc};vard=newa.J;9>a.a.L&&(a.g.register=
if(!f)throwError("No component name specified");varp=m=++b;a.g.get(f,function(b){if(m===p){k();if(!b)throwError("Unknown component '"+f+"'");varc=b.template;if(!c)throwError("Component '"+f+"' has no template");c=a.a.ia(c);a.f.T(d,c);varc=q,e=b.createViewModel;b=e?e.call(b,c,{element:d}):c;c=h.createChildContext(b);g=b;a.Ca(c,d)}})},null,{o:d});return{controlsDescendantBindings:!0}}};a.f.Q.component=!0})();varP={"class":"className","for":"htmlFor"};a.d.attr={update:function(b,d){varc=a.a.c(d())||
varK={};a.d.options={init:function(b){if("select"!==a.a.t(b))throwError("options binding applies only to SELECT elements");for(;0<b.length;)b.remove(0);return{controlsDescendantBindings:!0}},update:function(b,d,c){functione(){returna.a.ta(b.options,function(a){returna.selected})}functionf(a,b,c){vard=typeofb;return"function"==d?b(a):"string"==d?a[b]:c}functionh(c,d){if(s.length){vare=0<=a.a.m(s,a.i.q(d[0]));a.a.Nb(d[0],e);q&&!e&&a.k.B(a.a.oa,null,[b,"change"])}}vark=0!=b.length&&b.multiple?
s[0]:s.length||0<=b.selectedIndex)&&a.a.oa(b,"change")});a.a.dc(b);k&&20<Math.abs(k-b.scrollTop)&&(b.scrollTop=k)}};a.d.options.Va=a.a.e.F();a.d.selectedOptions={after:["options","foreach"],init:function(b,d,c){a.a.n(b,"change",function(){vare=d(),f=[];a.a.u(b.getElementsByTagName("option"),function(b){b.selected&&f.push(a.i.q(b))});a.h.pa(e,c,"selectedOptions",f)})},update:function(b,d){if("select"!=a.a.t(b))throwError("values binding applies only to SELECT elements");varc=a.a.c(d());c&&"number"==
typeofc.length&&a.a.u(b.getElementsByTagName("option"),function(b){vard=0<=a.a.m(c,a.i.q(b));a.a.Nb(b,d)})}};a.h.V.selectedOptions=!0;a.d.style={update:function(b,d){varc=a.a.c(d()||{});a.a.G(c,function(c,d){d=a.a.c(d);if(null===d||d===n||!1===d)d="";b.style[c]=d})}};a.d.submit={init:function(b,d,c,e,f){if("function"!=typeofd())throwError("The value for a submit binding must be a function");a.a.n(b,"submit",function(a){varc,e=d();try{c=e.call(f.$data,b)}finally{!0!==c&&(a.preventDefault?a.preventDefault():
a.H.prototype.makeTemplateSource=function(b,d){if("string"==typeofb){d=d||y;varc=d.getElementById(b);if(!c)throwError("Cannot find template with ID "+b);returnnewa.r.l(c)}if(1==b.nodeType||8==b.nodeType)returnnewa.r.fa(b);throwError("Unknown template type: "+b);};a.H.prototype.renderTemplate=function(a,d,c,e){a=this.makeTemplateSource(a,e);returnthis.renderTemplateSource(a,d,c)};a.H.prototype.isTemplateRewritten=function(a,d){return!1===this.allowTemplateRewriting?!0:this.makeTemplateSource(a,
d).data("isRewritten")};a.H.prototype.rewriteTemplate=function(a,d,c){a=this.makeTemplateSource(a,c);d=d(a.text());a.text(d);a.data("isRewritten",!0)};a.b("templateEngine",a.H);a.fb=function(){functionb(b,c,d,k){b=a.h.Wa(b);for(varg=a.h.ha,m=0;m<b.length;m++){varl=b[m].key;if(g.hasOwnProperty(l)){vars=g[l];if("function"===typeofs){if(l=s(b[m].value))throwError(l);}elseif(!s)throwError("This template engine does not support the '"+l+"' binding within its templates");}}d="ko.__tr_ambtns(function($context,$element){return(function(){return{ "+
"\x3c!-- ko --\x3e","#comment",f)})},Xb:function(b,c){returna.D.Ua(function(d,k){varg=d.nextSibling;g&&g.nodeName.toLowerCase()===c&&a.ra(g,b,k)})}}}();a.b("__tr_ambtns",a.fb.Xb);(function(){a.r={};a.r.l=function(a){this.l=a};a.r.l.prototype.text=function(){varb=a.a.t(this.l),b="script"===b?"text":"textarea"===b?"value":"innerHTML";if(0==arguments.length)returnthis.l[b];vard=arguments[0];"innerHTML"===b?a.a.$a(this.l,d):this.l[b]=d};varb=a.a.e.F()+"_";a.r.l.prototype.data=function(c){if(1===
a.pb(d,b)});b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.D.Sb(b,[d])});a.a.ka(c,h)}}functionc(a){returna.nodeType?a:0<a.length?a[0]:null}functione(b,e,f,k,q){q=q||{};varp=b&&c(b),p=p&&p.ownerDocument,n=q.templateEngine||h;a.fb.ec(f,n,p);f=n.renderTemplate(f,k,q,p);if("number"!=typeoff.length||0<f.length&&"number"!=typeoff[0].nodeType)throwError("Template engine must return an array of DOM nodes");p=!1;switch(e){case"replaceChildren":a.f.T(b,f);p=!0;break;case"replaceNode":a.a.Lb(b,
f);p=!0;break;case"ignoreTargetNode":break;default:throwError("Unknown renderMode: "+e);}p&&(d(f,k),q.afterRender&&a.k.B(q.afterRender,null,[f,k.$data]));returnf}functionf(b,c,d){returna.C(b)?b():"function"===typeofb?b(c,d):b}varh;a.ab=function(b){if(b!=n&&!(binstanceofa.H))throwError("templateEngine must inherit from ko.templateEngine");h=b};a.Ya=function(b,d,k,s,q){k=k||{};if((k.templateEngine||h)==n)throwError("Set a template engine before calling renderTemplate");q=q||"replaceChildren";
c.name,"if"inc&&(d=a.a.c(c["if"])),d&&"ifnot"inc&&(d=!a.a.c(c.ifnot)),r=a.a.c(c.data));"foreach"inc?e=a.tc(h||b,d&&c.foreach||[],c,b,f):d?(f="data"inc?f.createChildContext(r,c.as):f,e=a.Ya(h||b,f,c,b)):a.f.ja(b);f=e;(r=a.a.e.get(b,k))&&"function"==typeofr.K&&r.K();a.a.e.set(b,k,f&&f.Z()?f:n)}};a.h.ha.template=function(b){b=a.h.Wa(b);return1==b.length&&b[0].unknown||a.h.lc(b,"name")?null:"This template engine does not support anonymous templates nested within its templates"};a.f.Q.template=!0})();
a.b("nativeTemplateEngine",a.O);(function(){a.Sa=function(){vara=this.kc=function(){if(!r||!r.tmpl)return0;try{if(0<=r.tmpl.tag.tmpl.open.toString().indexOf("__"))return2}catch(a){}return1}();this.renderTemplateSource=function(b,e,f){f=f||{};if(2>a)throwError("Your version of jQuery.tmpl is too old. Please upgrade to jQuery.tmpl 1.0.0pre or later.");varh=b.data("precompiled");h||(h=b.text()||"",h=r.template(null,"{{ko_with $item.koBindingContext}}"+h+"{{/ko_with}}"),b.data("precompiled",h));