/*!
 * Knockout JavaScript library v3.5.0-pre
 * (c) The Knockout.js team - http://knockoutjs.com/
 * License: MIT (http://www.opensource.org/licenses/mit-license.php)
 */

(function() {(function(n){var y=this||(0,eval)("this"),v=y.document,M=y.navigator,r=y.jQuery,G=y.JSON;(function(n){"function"===typeof define&&define.amd?define(["exports","require"],n):"object"===typeof exports&&"object"===typeof module?n(module.exports||exports):n(y.ko={})})(function(N,O){function J(a,d){return null===a||typeof a in T?a===d:!1}function U(b,d){var c;return function(){c||(c=a.a.setTimeout(function(){c=n;b()},d))}}function V(b,d){var c;return function(){clearTimeout(c);c=a.a.setTimeout(b,d)}}function W(a,
d){d&&"change"!==d?"beforeChange"===d?this.Qb(a):this.Sa(a,d):this.Rb(a)}function X(a,d){null!==d&&d.o&&d.o()}function Y(a,d){var c=this.Oc,e=c[w];e.ba||(this.vb&&this.Ya[d]?(c.Vb(d,a,this.Ya[d]),this.Ya[d]=null,--this.vb):e.D[d]||c.Vb(d,a,e.F?{ra:a}:c.Bc(a)))}function K(b,d,c,e){a.f[b]={init:function(b,g,h,m,l){var k,p;a.u(function(){var u=g(),q=a.a.c(u),q=!c!==!q,A=!p;if(A||d||q!==k)A&&a.Ea.Ja()&&(p=a.a.Da(a.g.childNodes(b),!0)),q?(A||a.g.ma(b,a.a.Da(p)),a.Va(e?e(l,u):l,b)):a.g.Ga(b),k=q},null,
{l:b});return{controlsDescendantBindings:!0}}};a.j.Ca[b]=!1;a.g.ea[b]=!0}var a="undefined"!==typeof N?N:{};a.b=function(b,d){for(var c=b.split("."),e=a,f=0;f<c.length-1;f++)e=e[c[f]];e[c[c.length-1]]=d};a.R=function(a,d,c){a[d]=c};a.version="3.5.0-pre";a.b("version",a.version);a.options={deferUpdates:!1,useOnlyNativeEvents:!1};a.a=function(){function b(a,b){for(var d in a)a.hasOwnProperty(d)&&b(d,a[d])}function d(a,b){if(b)for(var d in b)b.hasOwnProperty(d)&&(a[d]=b[d]);return a}function c(a,b){a.__proto__=
b;return a}function e(b,d,c,e){var k=b[d].match(p)||[];a.a.C(c.match(p),function(b){a.a.za(k,b,e)});b[d]=k.join(" ")}var f={__proto__:[]}instanceof Array,g="function"===typeof Symbol,h={},m={};h[M&&/Firefox\/2/i.test(M.userAgent)?"KeyboardEvent":"UIEvents"]=["keyup","keydown","keypress"];h.MouseEvents="click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave".split(" ");b(h,function(a,b){if(b.length)for(var d=0,c=b.length;d<c;d++)m[b[d]]=a});var l={propertychange:!0},k=
v&&function(){for(var a=3,b=v.createElement("div"),d=b.getElementsByTagName("i");b.innerHTML="\x3c!--[if gt IE "+ ++a+"]><i></i><![endif]--\x3e",d[0];);return 4<a?a:n}(),p=/\S+/g;return{jc:["authenticity_token",/^__RequestVerificationToken(_.*)?$/],C:function(a,b){for(var d=0,c=a.length;d<c;d++)b(a[d],d)},A:function(b,d,c){if(c){d=a.a.Na(d);c=0;for(var e=b.length;c<e;c++)if(a.a.Na(b[c])===d)return c}else{if("function"==typeof Array.prototype.indexOf)return Array.prototype.indexOf.call(b,d);c=0;for(e=
b.length;c<e;c++)if(b[c]===d)return c}return-1},Yb:function(a,b,d){for(var c=0,e=a.length;c<e;c++)if(b.call(d,a[c],c))return a[c];return null},Xa:function(b,d){var c=a.a.A(b,d);0<c?b.splice(c,1):0===c&&b.shift()},Zb:function(b){b=b||[];for(var d=[],c=0,e=b.length;c<e;c++)0>a.a.A(d,b[c])&&d.push(b[c]);return d},pb:function(a,b){a=a||[];for(var d=[],c=0,e=a.length;c<e;c++)d.push(b(a[c],c));return d},Wa:function(a,b){a=a||[];for(var d=[],c=0,e=a.length;c<e;c++)b(a[c],c)&&d.push(a[c]);return d},Aa:function(a,
b){if(b instanceof Array)a.push.apply(a,b);else for(var d=0,c=b.length;d<c;d++)a.push(b[d]);return a},za:function(b,d,c,e){var k=a.a.A(a.a.Na(b),d,e);e&&!a.J(d)&&(d=a.O(d));0>k?c&&b.push(d):c||b.splice(k,1)},ta:f,extend:d,setPrototypeOf:c,jb:f?c:d,N:b,Ma:function(a,b){if(!a)return a;var d={},c;for(c in a)a.hasOwnProperty(c)&&(d[c]=b(a[c],c,a));return d},yb:function(b){for(;b.firstChild;)a.removeNode(b.firstChild)},qc:function(b){b=a.a.fa(b);for(var d=(b[0]&&b[0].ownerDocument||v).createElement("div"),
c=0,e=b.length;c<e;c++)d.appendChild(a.ia(b[c]));return d},Da:function(b,d){for(var c=0,e=b.length,k=[];c<e;c++){var l=b[c].cloneNode(!0);k.push(d?a.ia(l):l)}return k},ma:function(b,d){a.a.yb(b);if(d)for(var c=0,e=d.length;c<e;c++)b.appendChild(d[c])},xc:function(b,d){var c=b.nodeType?[b]:b;if(0<c.length){for(var e=c[0],k=e.parentNode,l=0,f=d.length;l<f;l++)k.insertBefore(d[l],e);l=0;for(f=c.length;l<f;l++)a.removeNode(c[l])}},Ia:function(a,b){if(a.length){for(b=8===b.nodeType&&b.parentNode||b;a.length&&
a[0].parentNode!==b;)a.splice(0,1);for(;1<a.length&&a[a.length-1].parentNode!==b;)a.length--;if(1<a.length){var d=a[0],c=a[a.length-1];for(a.length=0;d!==c;)a.push(d),d=d.nextSibling;a.push(c)}}return a},zc:function(a,b){7>k?a.setAttribute("selected",b):a.selected=b},lb:function(a){return null===a||a===n?"":a.trim?a.trim():a.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")},ud:function(a,b){a=a||"";return b.length>a.length?!1:a.substring(0,b.length)===b},Tc:function(a,b){if(a===b)return!0;if(11===
a.nodeType)return!1;if(b.contains)return b.contains(3===a.nodeType?a.parentNode:a);if(b.compareDocumentPosition)return 16==(b.compareDocumentPosition(a)&16);for(;a&&a!=b;)a=a.parentNode;return!!a},xb:function(b){return a.a.Tc(b,b.ownerDocument.documentElement)},Wb:function(b){return!!a.a.Yb(b,a.a.xb)},K:function(a){return a&&a.tagName&&a.tagName.toLowerCase()},bc:function(b){return a.onError?function(){try{return b.apply(this,arguments)}catch(d){throw a.onError&&a.onError(d),d;}}:b},setTimeout:function(b,
d){return setTimeout(a.a.bc(b),d)},gc:function(b){setTimeout(function(){a.onError&&a.onError(b);throw b;},0)},B:function(b,d,c){var e=a.a.bc(c);c=k&&l[d];if(a.options.useOnlyNativeEvents||c||!r)if(c||"function"!=typeof b.addEventListener)if("undefined"!=typeof b.attachEvent){var f=function(a){e.call(b,a)},m="on"+d;b.attachEvent(m,f);a.a.P.ya(b,function(){b.detachEvent(m,f)})}else throw Error("Browser doesn't support addEventListener or attachEvent");else b.addEventListener(d,e,!1);else r(b).bind(d,
e)},Oa:function(b,d){if(!b||!b.nodeType)throw Error("element must be a DOM node when calling triggerEvent");var c;"input"===a.a.K(b)&&b.type&&"click"==d.toLowerCase()?(c=b.type,c="checkbox"==c||"radio"==c):c=!1;if(a.options.useOnlyNativeEvents||!r||c)if("function"==typeof v.createEvent)if("function"==typeof b.dispatchEvent)c=v.createEvent(m[d]||"HTMLEvents"),c.initEvent(d,!0,!0,y,0,0,0,0,0,!1,!1,!1,!1,0,b),b.dispatchEvent(c);else throw Error("The supplied element doesn't support dispatchEvent");else if(c&&
b.click)b.click();else if("undefined"!=typeof b.fireEvent)b.fireEvent("on"+d);else throw Error("Browser doesn't support triggering events");else r(b).trigger(d)},c:function(b){return a.J(b)?b():b},wd:function(b){return a.J(b)?b:a.O(b)},Na:function(b){return a.J(b)?b.G():b},nb:function(b,d,c){var k;d&&("object"===typeof b.classList?(k=b.classList[c?"add":"remove"],a.a.C(d.match(p),function(a){k.call(b.classList,a)})):"string"===typeof b.className.baseVal?e(b.className,"baseVal",d,c):e(b,"className",
d,c))},kb:function(b,d){var c=a.a.c(d);if(null===c||c===n)c="";var e=a.g.firstChild(b);!e||3!=e.nodeType||a.g.nextSibling(e)?a.g.ma(b,[b.ownerDocument.createTextNode(c)]):e.data=c;a.a.Yc(b)},yc:function(a,b){a.name=b;if(7>=k)try{a.mergeAttributes(v.createElement("<input name='"+a.name+"'/>"),!1)}catch(c){}},Yc:function(a){9<=k&&(a=1==a.nodeType?a:a.parentNode,a.style&&(a.style.zoom=a.style.zoom))},Uc:function(a){if(k){var b=a.style.width;a.style.width=0;a.style.width=b}},od:function(b,c){b=a.a.c(b);
c=a.a.c(c);for(var d=[],e=b;e<=c;e++)d.push(e);return d},fa:function(a){for(var b=[],c=0,d=a.length;c<d;c++)b.push(a[c]);return b},ec:function(a){return g?Symbol(a):a},yd:6===k,zd:7===k,M:k,lc:function(b,c){for(var d=a.a.fa(b.getElementsByTagName("input")).concat(a.a.fa(b.getElementsByTagName("textarea"))),e="string"==typeof c?function(a){return a.name===c}:function(a){return c.test(a.name)},k=[],l=d.length-1;0<=l;l--)e(d[l])&&k.push(d[l]);return k},md:function(b){return"string"==typeof b&&(b=a.a.lb(b))?
G&&G.parse?G.parse(b):(new Function("return "+b))():null},Lb:function(b,c,d){if(!G||!G.stringify)throw Error("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");return G.stringify(a.a.c(b),c,d)},nd:function(c,d,e){e=e||{};var k=e.params||{},l=e.includeFields||this.jc,f=c;if("object"==typeof c&&"form"===a.a.K(c))for(var f=c.action,m=l.length-1;0<=m;m--)for(var g=
a.a.lc(c,l[m]),h=g.length-1;0<=h;h--)k[g[h].name]=g[h].value;d=a.a.c(d);var p=v.createElement("form");p.style.display="none";p.action=f;p.method="post";for(var n in d)c=v.createElement("input"),c.type="hidden",c.name=n,c.value=a.a.Lb(a.a.c(d[n])),p.appendChild(c);b(k,function(a,b){var c=v.createElement("input");c.type="hidden";c.name=a;c.value=b;p.appendChild(c)});v.body.appendChild(p);e.submitter?e.submitter(p):p.submit();setTimeout(function(){p.parentNode.removeChild(p)},0)}}}();a.b("utils",a.a);
a.b("utils.arrayForEach",a.a.C);a.b("utils.arrayFirst",a.a.Yb);a.b("utils.arrayFilter",a.a.Wa);a.b("utils.arrayGetDistinctValues",a.a.Zb);a.b("utils.arrayIndexOf",a.a.A);a.b("utils.arrayMap",a.a.pb);a.b("utils.arrayPushAll",a.a.Aa);a.b("utils.arrayRemoveItem",a.a.Xa);a.b("utils.extend",a.a.extend);a.b("utils.fieldsIncludedWithJsonPost",a.a.jc);a.b("utils.getFormFields",a.a.lc);a.b("utils.peekObservable",a.a.Na);a.b("utils.postJson",a.a.nd);a.b("utils.parseJson",a.a.md);a.b("utils.registerEventHandler",
a.a.B);a.b("utils.stringifyJson",a.a.Lb);a.b("utils.range",a.a.od);a.b("utils.toggleDomNodeCssClass",a.a.nb);a.b("utils.triggerEvent",a.a.Oa);a.b("utils.unwrapObservable",a.a.c);a.b("utils.objectForEach",a.a.N);a.b("utils.addOrRemoveItem",a.a.za);a.b("utils.setTextContent",a.a.kb);a.b("unwrap",a.a.c);Function.prototype.bind||(Function.prototype.bind=function(a){var d=this;if(1===arguments.length)return function(){return d.apply(a,arguments)};var c=Array.prototype.slice.call(arguments,1);return function(){var e=
c.slice(0);e.push.apply(e,arguments);return d.apply(a,e)}});a.a.h=new function(){function a(b,g){var h=b[c];if(!h||"null"===h||!e[h]){if(!g)return n;h=b[c]="ko"+d++;e[h]={}}return e[h]}var d=0,c="__ko__"+(new Date).getTime(),e={};return{get:function(c,d){var e=a(c,!1);return e===n?n:e[d]},set:function(c,d,e){if(e!==n||a(c,!1)!==n)a(c,!0)[d]=e},clear:function(a){var b=a[c];return b?(delete e[b],a[c]=null,!0):!1},S:function(){return d++ +c}}};a.b("utils.domData",a.a.h);a.b("utils.domData.clear",a.a.h.clear);
a.a.P=new function(){function b(b,d){var e=a.a.h.get(b,c);e===n&&d&&(e=[],a.a.h.set(b,c,e));return e}function d(c){var e=b(c,!1);if(e)for(var e=e.slice(0),m=0;m<e.length;m++)e[m](c);a.a.h.clear(c);a.a.P.cleanExternalData(c);if(f[c.nodeType])for(e=c.firstChild;c=e;)e=c.nextSibling,8===c.nodeType&&d(c)}var c=a.a.h.S(),e={1:!0,8:!0,9:!0},f={1:!0,9:!0};return{ya:function(a,c){if("function"!=typeof c)throw Error("Callback must be a function");b(a,!0).push(c)},wc:function(d,e){var f=b(d,!1);f&&(a.a.Xa(f,
e),0==f.length&&a.a.h.set(d,c,n))},ia:function(b){if(e[b.nodeType]&&(d(b),f[b.nodeType])){var c=[];a.a.Aa(c,b.getElementsByTagName("*"));for(var m=0,l=c.length;m<l;m++)d(c[m])}return b},removeNode:function(b){a.ia(b);b.parentNode&&b.parentNode.removeChild(b)},cleanExternalData:function(a){r&&"function"==typeof r.cleanData&&r.cleanData([a])}}};a.ia=a.a.P.ia;a.removeNode=a.a.P.removeNode;a.b("cleanNode",a.ia);a.b("removeNode",a.removeNode);a.b("utils.domNodeDisposal",a.a.P);a.b("utils.domNodeDisposal.addDisposeCallback",
a.a.P.ya);a.b("utils.domNodeDisposal.removeDisposeCallback",a.a.P.wc);(function(){var b=[0,"",""],d=[1,"<table>","</table>"],c=[3,"<table><tbody><tr>","</tr></tbody></table>"],e=[1,"<select multiple='multiple'>","</select>"],f={thead:d,tbody:d,tfoot:d,tr:[2,"<table><tbody>","</tbody></table>"],td:c,th:c,option:e,optgroup:e},g=8>=a.a.M;a.a.va=function(c,d){var e;if(r)if(r.parseHTML)e=r.parseHTML(c,d)||[];else{if((e=r.clean([c],d))&&e[0]){for(var k=e[0];k.parentNode&&11!==k.parentNode.nodeType;)k=k.parentNode;
k.parentNode&&k.parentNode.removeChild(k)}}else{(e=d)||(e=v);var k=e.parentWindow||e.defaultView||y,p=a.a.lb(c).toLowerCase(),u=e.createElement("div"),q;q=(p=p.match(/^<([a-z]+)[ >]/))&&f[p[1]]||b;p=q[0];q="ignored<div>"+q[1]+c+q[2]+"</div>";"function"==typeof k.innerShiv?u.appendChild(k.innerShiv(q)):(g&&e.appendChild(u),u.innerHTML=q,g&&u.parentNode.removeChild(u));for(;p--;)u=u.lastChild;e=a.a.fa(u.lastChild.childNodes)}return e};a.a.Jb=function(b,c){a.a.yb(b);c=a.a.c(c);if(null!==c&&c!==n)if("string"!=
typeof c&&(c=c.toString()),r)r(b).html(c);else for(var d=a.a.va(c,b.ownerDocument),e=0;e<d.length;e++)b.appendChild(d[e])}})();a.b("utils.parseHtmlFragment",a.a.va);a.b("utils.setHtml",a.a.Jb);a.W=function(){function b(c,d){if(c)if(8==c.nodeType){var f=a.W.sc(c.nodeValue);null!=f&&d.push({Sc:c,kd:f})}else if(1==c.nodeType)for(var f=0,g=c.childNodes,h=g.length;f<h;f++)b(g[f],d)}var d={};return{Eb:function(a){if("function"!=typeof a)throw Error("You can only pass a function to ko.memoization.memoize()");
var b=(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"},Ec:function(a,b){var f=d[a];if(f===n)throw Error("Couldn't find any memo with ID "+a+". Perhaps it's already been unmemoized.");try{return f.apply(null,b||[]),!0}finally{delete d[a]}},Fc:function(c,d){var f=[];b(c,f);for(var g=0,h=f.length;g<h;g++){var m=f[g].Sc,l=[m];d&&a.a.Aa(l,d);a.W.Ec(f[g].kd,l);m.nodeValue="";m.parentNode&&m.parentNode.removeChild(m)}},
sc:function(a){return(a=a.match(/^\[ko_memo\:(.*?)\]$/))?a[1]:null}}}();a.b("memoization",a.W);a.b("memoization.memoize",a.W.Eb);a.b("memoization.unmemoize",a.W.Ec);a.b("memoization.parseMemoText",a.W.sc);a.b("memoization.unmemoizeDomNodeAndDescendants",a.W.Fc);a.ga=function(){function b(){if(f)for(var b=f,c=0,d;h<f;)if(d=e[h++]){if(h>b){if(5E3<=++c){h=f;a.a.gc(Error("'Too much recursion' after processing "+c+" task groups."));break}b=f}try{d()}catch(p){a.a.gc(p)}}}function d(){b();h=f=e.length=0}
var c,e=[],f=0,g=1,h=0;y.MutationObserver?c=function(a){var b=v.createElement("div");(new MutationObserver(a)).observe(b,{attributes:!0});return function(){b.classList.toggle("foo")}}(d):c=v&&"onreadystatechange"in v.createElement("script")?function(a){var b=v.createElement("script");b.onreadystatechange=function(){b.onreadystatechange=null;v.documentElement.removeChild(b);b=null;a()};v.documentElement.appendChild(b)}:function(a){setTimeout(a,0)};return{scheduler:c,ib:function(b){f||a.ga.scheduler(d);
e[f++]=b;return g++},cancel:function(a){a=a-(g-f);a>=h&&a<f&&(e[a]=null)},resetForTesting:function(){var a=f-h;h=f=e.length=0;return a},sd:b}}();a.b("tasks",a.ga);a.b("tasks.schedule",a.ga.ib);a.b("tasks.runEarly",a.ga.sd);a.Ha={throttle:function(b,d){b.throttleEvaluation=d;var c=null;return a.L({read:b,write:function(e){clearTimeout(c);c=a.a.setTimeout(function(){b(e)},d)}})},rateLimit:function(a,d){var c,e,f;"number"==typeof d?c=d:(c=d.timeout,e=d.method);a.ob=!1;f="notifyWhenChangesStop"==e?V:
U;a.fb(function(a){return f(a,c)})},deferred:function(b,d){if(!0!==d)throw Error("The 'deferred' extender only accepts the value 'true', because it is not supported to turn deferral off once enabled.");b.ob||(b.ob=!0,b.fb(function(c){var d;return function(){a.ga.cancel(d);d=a.ga.ib(c);b.notifySubscribers(n,"dirty")}}))},notify:function(a,d){a.equalityComparer="always"==d?null:J}};var T={undefined:1,"boolean":1,number:1,string:1};a.b("extenders",a.Ha);a.Cc=function(b,d,c){this.ra=b;this.qb=d;this.Rc=
c;this.ba=!1;a.R(this,"dispose",this.o)};a.Cc.prototype.o=function(){this.ba=!0;this.Rc()};a.T=function(){a.a.jb(this,E);E.Bb(this)};var E={Bb:function(a){a.U={};a.Tb=1},subscribe:function(b,d,c){var e=this;c=c||"change";var f=new a.Cc(e,d?b.bind(d):b,function(){a.a.Xa(e.U[c],f);e.Ta&&e.Ta(c)});e.Ba&&e.Ba(c);e.U[c]||(e.U[c]=[]);e.U[c].push(f);return f},notifySubscribers:function(b,d){d=d||"change";"change"===d&&this.Gc();if(this.ab(d))try{a.s.$b();for(var c=this.U[d].slice(0),e=0,f;f=c[e];++e)f.ba||
f.qb(b)}finally{a.s.end()}},Za:function(){return this.Tb},ad:function(a){return this.Za()!==a},Gc:function(){++this.Tb},fb:function(b){var d=this,c=a.J(d),e,f,g;d.Sa||(d.Sa=d.notifySubscribers,d.notifySubscribers=W);var h=b(function(){d.Sb=!1;c&&g===d&&(g=d());e=!1;d.Cb(f,g)&&d.Sa(f=g)});d.Rb=function(a){d.Sb=e=!0;g=a;h()};d.Qb=function(a){e||(f=a,d.Sa(a,"beforeChange"))}},ab:function(a){return this.U[a]&&this.U[a].length},Zc:function(b){if(b)return this.U[b]&&this.U[b].length||0;var d=0;a.a.N(this.U,
function(a,b){"dirty"!==a&&(d+=b.length)});return d},Cb:function(a,d){return!this.equalityComparer||!this.equalityComparer(a,d)},extend:function(b){var d=this;b&&a.a.N(b,function(b,e){var f=a.Ha[b];"function"==typeof f&&(d=f(d,e)||d)});return d}};a.R(E,"subscribe",E.subscribe);a.R(E,"extend",E.extend);a.R(E,"getSubscriptionsCount",E.Zc);a.a.ta&&a.a.setPrototypeOf(E,Function.prototype);a.T.fn=E;a.oc=function(a){return null!=a&&"function"==typeof a.subscribe&&"function"==typeof a.notifySubscribers};
a.b("subscribable",a.T);a.b("isSubscribable",a.oc);a.Ea=a.s=function(){function b(a){c.push(e);e=a}function d(){e=c.pop()}var c=[],e,f=0;return{$b:b,end:d,vc:function(b){if(e){if(!a.oc(b))throw Error("Only subscribable things can act as dependencies");e.qb.call(e.Nc,b,b.Jc||(b.Jc=++f))}},I:function(a,c,e){try{return b(),a.apply(c,e||[])}finally{d()}},Ja:function(){if(e)return e.u.Ja()},eb:function(){if(e)return e.eb}}}();a.b("computedContext",a.Ea);a.b("computedContext.getDependenciesCount",a.Ea.Ja);
a.b("computedContext.isInitial",a.Ea.eb);a.b("ignoreDependencies",a.xd=a.s.I);var F=a.a.ec("_latestValue");a.O=function(b){function d(){if(0<arguments.length)return d.Cb(d[F],arguments[0])&&(d.pa(),d[F]=arguments[0],d.oa()),this;a.s.vc(d);return d[F]}d[F]=b;a.a.ta||a.a.extend(d,a.T.fn);a.T.fn.Bb(d);a.a.jb(d,C);a.options.deferUpdates&&a.Ha.deferred(d,!0);return d};var C={equalityComparer:J,G:function(){return this[F]},oa:function(){this.notifySubscribers(this[F])},pa:function(){this.notifySubscribers(this[F],
"beforeChange")}};a.a.ta&&a.a.setPrototypeOf(C,a.T.fn);var I=a.O.xa="__ko_proto__";C[I]=a.O;a.$a=function(b,d){return null===b||b===n||b[I]===n?!1:b[I]===d?!0:a.$a(b[I],d)};a.J=function(b){return a.$a(b,a.O)};a.Ka=function(b){return"function"==typeof b&&b[I]===a.O||"function"==typeof b&&b[I]===a.L&&b.bd?!0:!1};a.b("observable",a.O);a.b("isObservable",a.J);a.b("isWriteableObservable",a.Ka);a.b("isWritableObservable",a.Ka);a.b("observable.fn",C);a.R(C,"peek",C.G);a.R(C,"valueHasMutated",C.oa);a.R(C,
"valueWillMutate",C.pa);a.ua=function(b){b=b||[];if("object"!=typeof b||!("length"in b))throw Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");b=a.O(b);a.a.jb(b,a.ua.fn);return b.extend({trackArrayChanges:!0})};a.ua.fn={remove:function(b){for(var d=this.G(),c=[],e="function"!=typeof b||a.J(b)?function(a){return a===b}:b,f=0;f<d.length;f++){var g=d[f];e(g)&&(0===c.length&&this.pa(),c.push(g),d.splice(f,1),f--)}c.length&&this.oa();return c},
removeAll:function(b){if(b===n){var d=this.G(),c=d.slice(0);this.pa();d.splice(0,d.length);this.oa();return c}return b?this.remove(function(c){return 0<=a.a.A(b,c)}):[]},destroy:function(b){var d=this.G(),c="function"!=typeof b||a.J(b)?function(a){return a===b}:b;this.pa();for(var e=d.length-1;0<=e;e--)c(d[e])&&(d[e]._destroy=!0);this.oa()},destroyAll:function(b){return b===n?this.destroy(function(){return!0}):b?this.destroy(function(d){return 0<=a.a.A(b,d)}):[]},indexOf:function(b){var d=this();
return a.a.A(d,b)},replace:function(a,d){var c=this.indexOf(a);0<=c&&(this.pa(),this.G()[c]=d,this.oa())}};a.a.ta&&a.a.setPrototypeOf(a.ua.fn,a.O.fn);a.a.C("pop push reverse shift sort splice unshift".split(" "),function(b){a.ua.fn[b]=function(){var a=this.G();this.pa();this.ac(a,b,arguments);var c=a[b].apply(a,arguments);this.oa();return c===a?this:c}});a.a.C(["slice"],function(b){a.ua.fn[b]=function(){var a=this();return a[b].apply(a,arguments)}});a.b("observableArray",a.ua);a.Ha.trackArrayChanges=
function(b,d){function c(){if(!e){e=!0;var c=b.notifySubscribers;b.notifySubscribers=function(a,b){b&&"change"!==b||++h;return c.apply(this,arguments)};var d=[].concat(b.G()||[]);f=null;g=b.subscribe(function(c){c=[].concat(c||[]);if(b.ab("arrayChange")){var e;if(!f||1<h)f=a.a.sb(d,c,b.rb);e=f}d=c;f=null;h=0;e&&e.length&&b.notifySubscribers(e,"arrayChange")})}}b.rb={};d&&"object"==typeof d&&a.a.extend(b.rb,d);b.rb.sparse=!0;if(!b.ac){var e=!1,f=null,g,h=0,m=b.Ba,l=b.Ta;b.Ba=function(a){m&&m.call(b,
a);"arrayChange"===a&&c()};b.Ta=function(a){l&&l.call(b,a);"arrayChange"!==a||b.ab("arrayChange")||(g.o(),e=!1)};b.ac=function(b,c,d){function l(a,b,c){return m[m.length]={status:a,value:b,index:c}}if(e&&!h){var m=[],g=b.length,t=d.length,H=0;switch(c){case "push":H=g;case "unshift":for(c=0;c<t;c++)l("added",d[c],H+c);break;case "pop":H=g-1;case "shift":g&&l("deleted",b[H],H);break;case "splice":c=Math.min(Math.max(0,0>d[0]?g+d[0]:d[0]),g);for(var g=1===t?g:Math.min(c+(d[1]||0),g),t=c+t-2,H=Math.max(g,
t),P=[],n=[],Q=2;c<H;++c,++Q)c<g&&n.push(l("deleted",b[c],c)),c<t&&P.push(l("added",d[Q],c));a.a.kc(n,P);break;default:return}f=m}}}};var w=a.a.ec("_state");a.u=a.L=function(b,d,c){function e(){if(0<arguments.length){if("function"===typeof f)f.apply(g.zb,arguments);else throw Error("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.");return this}a.s.vc(e);(g.ca||g.F&&e.bb())&&e.ja();return g.da}"object"===typeof b?
c=b:(c=c||{},b&&(c.read=b));if("function"!=typeof c.read)throw Error("Pass a function that returns the value of the ko.computed");var f=c.write,g={da:n,ca:!0,cb:!1,Mb:!1,ba:!1,hb:!1,F:!1,pd:c.read,zb:d||c.owner,l:c.disposeWhenNodeIsRemoved||c.l||null,Fa:c.disposeWhen||c.Fa,wb:null,D:{},V:0,ic:null};e[w]=g;e.bd="function"===typeof f;a.a.ta||a.a.extend(e,a.T.fn);a.T.fn.Bb(e);a.a.jb(e,B);c.pure?(g.hb=!0,g.F=!0,a.a.extend(e,aa)):c.deferEvaluation&&a.a.extend(e,ba);a.options.deferUpdates&&a.Ha.deferred(e,
!0);g.l&&(g.Mb=!0,g.l.nodeType||(g.l=null));g.F||c.deferEvaluation||e.ja();g.l&&e.ka()&&a.a.P.ya(g.l,g.wb=function(){e.o()});return e};var B={equalityComparer:J,Ja:function(){return this[w].V},Vb:function(a,d,c){if(this[w].hb&&d===this)throw Error("A 'pure' computed must not be called recursively");this[w].D[a]=c;c.Ra=this[w].V++;c.wa=d.Za()},bb:function(){var a,d,c=this[w].D;for(a in c)if(c.hasOwnProperty(a)&&(d=c[a],d.ra.ad(d.wa)))return!0},jd:function(){this.Qa&&!this[w].cb&&this.Qa()},ka:function(){return this[w].ca||
0<this[w].V},rd:function(){this.Sb||this.hc()},Bc:function(a){if(a.ob&&!this[w].l){var d=a.subscribe(this.jd,this,"dirty"),c=a.subscribe(this.rd,this);return{ra:a,o:function(){d.o();c.o()}}}return a.subscribe(this.hc,this)},hc:function(){var b=this,d=b.throttleEvaluation;d&&0<=d?(clearTimeout(this[w].ic),this[w].ic=a.a.setTimeout(function(){b.ja(!0)},d)):b.Qa?b.Qa():b.ja(!0)},ja:function(b){var d=this[w],c=d.Fa;if(!d.cb&&!d.ba){if(d.l&&!a.a.xb(d.l)||c&&c()){if(!d.Mb){this.o();return}}else d.Mb=!1;
d.cb=!0;try{this.Xc(b)}finally{d.cb=!1}d.V||this.o()}},Xc:function(b){var d=this[w],c=d.hb?n:!d.V,e={Oc:this,Ya:d.D,vb:d.V};a.s.$b({Nc:e,qb:Y,u:this,eb:c});d.D={};d.V=0;e=this.Wc(d,e);this.Cb(d.da,e)&&(d.F||this.notifySubscribers(d.da,"beforeChange"),d.da=e,d.F?this.Gc():b&&this.notifySubscribers(d.da));c&&this.notifySubscribers(d.da,"awake")},Wc:function(b,d){try{var c=b.pd;return b.zb?c.call(b.zb):c()}finally{a.s.end(),d.vb&&!b.F&&a.a.N(d.Ya,X),b.ca=!1}},G:function(){var a=this[w];(a.ca&&!a.V||
a.F&&this.bb())&&this.ja();return a.da},fb:function(b){a.T.fn.fb.call(this,b);this.Qa=function(){this.Qb(this[w].da);this[w].ca=!0;this.Rb(this)}},o:function(){var b=this[w];!b.F&&b.D&&a.a.N(b.D,function(a,b){b.o&&b.o()});b.l&&b.wb&&a.a.P.wc(b.l,b.wb);b.D=null;b.V=0;b.ba=!0;b.ca=!1;b.F=!1;b.l=null}},aa={Ba:function(b){var d=this,c=d[w];if(!c.ba&&c.F&&"change"==b){c.F=!1;if(c.ca||d.bb())c.D=null,c.V=0,c.ca=!0,d.ja();else{var e=[];a.a.N(c.D,function(a,b){e[b.Ra]=a});a.a.C(e,function(a,b){var e=c.D[a],
m=d.Bc(e.ra);m.Ra=b;m.wa=e.wa;c.D[a]=m})}c.ba||d.notifySubscribers(c.da,"awake")}},Ta:function(b){var d=this[w];d.ba||"change"!=b||this.ab("change")||(a.a.N(d.D,function(a,b){b.o&&(d.D[a]={ra:b.ra,Ra:b.Ra,wa:b.wa},b.o())}),d.F=!0,this.notifySubscribers(n,"asleep"))},Za:function(){var b=this[w];b.F&&(b.ca||this.bb())&&this.ja();return a.T.fn.Za.call(this)}},ba={Ba:function(a){"change"!=a&&"beforeChange"!=a||this.G()}};a.a.ta&&a.a.setPrototypeOf(B,a.T.fn);var R=a.O.xa;a.u[R]=a.O;B[R]=a.u;a.dd=function(b){return a.$a(b,
a.u)};a.ed=function(b){return a.$a(b,a.u)&&b[w]&&b[w].hb};a.b("computed",a.u);a.b("dependentObservable",a.u);a.b("isComputed",a.dd);a.b("isPureComputed",a.ed);a.b("computed.fn",B);a.R(B,"peek",B.G);a.R(B,"dispose",B.o);a.R(B,"isActive",B.ka);a.R(B,"getDependenciesCount",B.Ja);a.uc=function(b,d){if("function"===typeof b)return a.u(b,d,{pure:!0});b=a.a.extend({},b);b.pure=!0;return a.u(b,d)};a.b("pureComputed",a.uc);(function(){function b(a,f,g){g=g||new c;a=f(a);if("object"!=typeof a||null===a||a===
n||a instanceof RegExp||a instanceof Date||a instanceof String||a instanceof Number||a instanceof Boolean)return a;var h=a instanceof Array?[]:{};g.save(a,h);d(a,function(c){var d=f(a[c]);switch(typeof d){case "boolean":case "number":case "string":case "function":h[c]=d;break;case "object":case "undefined":var k=g.get(d);h[c]=k!==n?k:b(d,f,g)}});return h}function d(a,b){if(a instanceof Array){for(var c=0;c<a.length;c++)b(c);"function"==typeof a.toJSON&&b("toJSON")}else for(c in a)b(c)}function c(){this.keys=
[];this.values=[]}a.Dc=function(c){if(0==arguments.length)throw Error("When calling ko.toJS, pass the object you want to convert.");return b(c,function(b){for(var c=0;a.J(b)&&10>c;c++)b=b();return b})};a.toJSON=function(b,c,d){b=a.Dc(b);return a.a.Lb(b,c,d)};c.prototype={constructor:c,save:function(b,c){var d=a.a.A(this.keys,b);0<=d?this.values[d]=c:(this.keys.push(b),this.values.push(c))},get:function(b){b=a.a.A(this.keys,b);return 0<=b?this.values[b]:n}}})();a.b("toJS",a.Dc);a.b("toJSON",a.toJSON);
(function(){a.m={H:function(b){switch(a.a.K(b)){case "option":return!0===b.__ko__hasDomDataOptionValue__?a.a.h.get(b,a.f.options.Fb):7>=a.a.M?b.getAttributeNode("value")&&b.getAttributeNode("value").specified?b.value:b.text:b.value;case "select":return 0<=b.selectedIndex?a.m.H(b.options[b.selectedIndex]):n;default:return b.value}},qa:function(b,d,c){switch(a.a.K(b)){case "option":switch(typeof d){case "string":a.a.h.set(b,a.f.options.Fb,n);"__ko__hasDomDataOptionValue__"in b&&delete b.__ko__hasDomDataOptionValue__;
b.value=d;break;default:a.a.h.set(b,a.f.options.Fb,d),b.__ko__hasDomDataOptionValue__=!0,b.value="number"===typeof d?d:""}break;case "select":if(""===d||null===d)d=n;for(var e=-1,f=0,g=b.options.length,h;f<g;++f)if(h=a.m.H(b.options[f]),h==d||""==h&&d===n){e=f;break}if(c||0<=e||d===n&&1<b.size)b.selectedIndex=e;break;default:if(null===d||d===n)d="";b.value=d}}}})();a.b("selectExtensions",a.m);a.b("selectExtensions.readValue",a.m.H);a.b("selectExtensions.writeValue",a.m.qa);a.j=function(){function b(b){b=
a.a.lb(b);123===b.charCodeAt(0)&&(b=b.slice(1,-1));var c=[],d=b.match(e),p,h=[],q=0;if(d){d.push(",");for(var A=0,z;z=d[A];++A){var t=z.charCodeAt(0);if(44===t){if(0>=q){c.push(p&&h.length?{key:p,value:h.join("")}:{unknown:p||h.join("")});p=q=0;h=[];continue}}else if(58===t){if(!q&&!p&&1===h.length){p=h.pop();continue}}else 47===t&&A&&1<z.length?(t=d[A-1].match(f))&&!g[t[0]]&&(b=b.substr(b.indexOf(z)+1),d=b.match(e),d.push(","),A=-1,z="/"):40===t||123===t||91===t?++q:41===t||125===t||93===t?--q:p||
h.length||34!==t&&39!==t||(z=z.slice(1,-1));h.push(z)}}return c}var d=["true","false","null","undefined"],c=/^(?:[$_a-z][$\w]*|(.+)(\.\s*[$_a-z][$\w]*|\[.+\]))$/i,e=RegExp("\"(?:[^\"\\\\]|\\\\.)*\"|'(?:[^'\\\\]|\\\\.)*'|/(?:[^/\\\\]|\\\\.)*/w*|[^\\s:,/][^,\"'{}()/:[\\]]*[^\\s,\"'{}()/:[\\]]|[^\\s]","g"),f=/[\])"'A-Za-z0-9_$]+$/,g={"in":1,"return":1,"typeof":1},h={};return{Ca:[],na:h,Gb:b,gb:function(e,l){function k(b,e){var l;if(!A){var m=a.getBindingHandler(b);if(m&&m.preprocess&&!(e=m.preprocess(e,
b,k)))return;if(m=h[b])l=e,0<=a.a.A(d,l)?l=!1:(m=l.match(c),l=null===m?!1:m[1]?"Object("+m[1]+")"+m[2]:l),m=l;m&&g.push("'"+b+"':function(_z){"+l+"=_z}")}q&&(e="function(){return "+e+" }");f.push("'"+b+"':"+e)}l=l||{};var f=[],g=[],q=l.valueAccessors,A=l.bindingParams,z="string"===typeof e?b(e):e;a.a.C(z,function(a){k(a.key||a.unknown,a.value)});g.length&&k("_ko_property_writers","{"+g.join(",")+" }");return f.join(",")},hd:function(a,b){for(var c=0;c<a.length;c++)if(a[c].key==b)return!0;return!1},
Pa:function(b,c,d,e,f){if(b&&a.J(b))!a.Ka(b)||f&&b.G()===e||b(e);else if((b=c.get("_ko_property_writers"))&&b[d])b[d](e)}}}();a.b("expressionRewriting",a.j);a.b("expressionRewriting.bindingRewriteValidators",a.j.Ca);a.b("expressionRewriting.parseObjectLiteral",a.j.Gb);a.b("expressionRewriting.preProcessBindings",a.j.gb);a.b("expressionRewriting._twoWayBindings",a.j.na);a.b("jsonExpressionRewriting",a.j);a.b("jsonExpressionRewriting.insertPropertyAccessorsIntoJson",a.j.gb);(function(){function b(a){return 8==
a.nodeType&&g.test(f?a.text:a.nodeValue)}function d(a){return 8==a.nodeType&&h.test(f?a.text:a.nodeValue)}function c(a,c){for(var e=a,f=1,m=[];e=e.nextSibling;){if(d(e)&&(f--,0===f))return m;m.push(e);b(e)&&f++}if(!c)throw Error("Cannot find closing comment tag to match: "+a.nodeValue);return null}function e(a,b){var d=c(a,b);return d?0<d.length?d[d.length-1].nextSibling:a.nextSibling:null}var f=v&&"\x3c!--test--\x3e"===v.createComment("test").text,g=f?/^\x3c!--\s*ko(?:\s+([\s\S]+))?\s*--\x3e$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,
h=f?/^\x3c!--\s*\/ko\s*--\x3e$/:/^\s*\/ko\s*$/,m={ul:!0,ol:!0};a.g={ea:{},childNodes:function(a){return b(a)?c(a):a.childNodes},Ga:function(c){if(b(c)){c=a.g.childNodes(c);for(var d=0,e=c.length;d<e;d++)a.removeNode(c[d])}else a.a.yb(c)},ma:function(c,d){if(b(c)){a.g.Ga(c);for(var e=c.nextSibling,f=0,m=d.length;f<m;f++)e.parentNode.insertBefore(d[f],e)}else a.a.ma(c,d)},tc:function(a,c){b(a)?a.parentNode.insertBefore(c,a.nextSibling):a.firstChild?a.insertBefore(c,a.firstChild):a.appendChild(c)},nc:function(c,
d,e){e?b(c)?c.parentNode.insertBefore(d,e.nextSibling):e.nextSibling?c.insertBefore(d,e.nextSibling):c.appendChild(d):a.g.tc(c,d)},firstChild:function(a){return b(a)?!a.nextSibling||d(a.nextSibling)?null:a.nextSibling:a.firstChild},nextSibling:function(a){b(a)&&(a=e(a));return a.nextSibling&&d(a.nextSibling)?null:a.nextSibling},$c:b,vd:function(a){return(a=(f?a.text:a.nodeValue).match(g))?a[1]:null},rc:function(c){if(m[a.a.K(c)]){var k=c.firstChild;if(k){do if(1===k.nodeType){var f;f=k.firstChild;
var h=null;if(f){do if(h)h.push(f);else if(b(f)){var g=e(f,!0);g?f=g:h=[f]}else d(f)&&(h=[f]);while(f=f.nextSibling)}if(f=h)for(h=k.nextSibling,g=0;g<f.length;g++)h?c.insertBefore(f[g],h):c.appendChild(f[g])}while(k=k.nextSibling)}}}}})();a.b("virtualElements",a.g);a.b("virtualElements.allowedBindings",a.g.ea);a.b("virtualElements.emptyNode",a.g.Ga);a.b("virtualElements.insertAfter",a.g.nc);a.b("virtualElements.prepend",a.g.tc);a.b("virtualElements.setDomNodeChildren",a.g.ma);(function(){a.aa=function(){this.Mc=
{}};a.a.extend(a.aa.prototype,{nodeHasBindings:function(b){switch(b.nodeType){case 1:return null!=b.getAttribute("data-bind")||a.i.getComponentNameForNode(b);case 8:return a.g.$c(b);default:return!1}},getBindings:function(b,d){var c=this.getBindingsString(b,d),c=c?this.parseBindingsString(c,d,b):null;return a.i.Ub(c,b,d,!1)},getBindingAccessors:function(b,d){var c=this.getBindingsString(b,d),c=c?this.parseBindingsString(c,d,b,{valueAccessors:!0}):null;return a.i.Ub(c,b,d,!0)},getBindingsString:function(b){switch(b.nodeType){case 1:return b.getAttribute("data-bind");
case 8:return a.g.vd(b);default:return null}},parseBindingsString:function(b,d,c,e){try{var f=this.Mc,g=b+(e&&e.valueAccessors||""),h;if(!(h=f[g])){var m,l="with($context){with($data||{}){return{"+a.j.gb(b,e)+"}}}";m=new Function("$context","$element",l);h=f[g]=m}return h(d,c)}catch(k){throw k.message="Unable to parse bindings.\nBindings value: "+b+"\nMessage: "+k.message,k;}}});a.aa.instance=new a.aa})();a.b("bindingProvider",a.aa);(function(){function b(a){return function(){return a}}function d(a){return a()}
function c(b){return a.a.Ma(a.s.I(b),function(a,c){return function(){return b()[c]}})}function e(d,e,k){return"function"===typeof d?c(d.bind(null,e,k)):a.a.Ma(d,b)}function f(a,b){return c(this.getBindings.bind(this,a,b))}function g(b,c,d){var e,k=a.g.firstChild(c),f=a.aa.instance,l=f.preprocessNode;if(l){for(;e=k;)k=a.g.nextSibling(e),l.call(f,e);k=a.g.firstChild(c)}for(;e=k;)k=a.g.nextSibling(e),h(b,e,d)}function h(b,c,d){var e=!0,k=1===c.nodeType;k&&a.g.rc(c);if(k&&d||a.aa.instance.nodeHasBindings(c))e=
l(c,null,b,d).shouldBindDescendants;e&&!p[a.a.K(c)]&&g(b,c,!k)}function m(b){var c=[],d={},e=[];a.a.N(b,function Z(k){if(!d[k]){var f=a.getBindingHandler(k);f&&(f.after&&(e.push(k),a.a.C(f.after,function(c){if(b[c]){if(-1!==a.a.A(e,c))throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+e.join(", "));Z(c)}}),e.length--),c.push({key:k,mc:f}));d[k]=!0}});return c}function l(b,c,e,k){var l=a.a.h.get(b,u);if(!c){if(l)throw Error("You cannot apply bindings multiple times to the same element.");
a.a.h.set(b,u,!0)}!l&&k&&a.Ac(b,e);var h;if(c&&"function"!==typeof c)h=c;else{var g=a.aa.instance,p=g.getBindingAccessors||f,q=a.L(function(){(h=c?c(e,b):p.call(g,b,e))&&e.Z&&e.Z();return h},null,{l:b});h&&q.ka()||(q=null)}var v;if(h){var r=function(){return a.a.Ma(q?q():h,d)},w=q?function(a){return function(){return d(q()[a])}}:function(a){return h[a]};r.get=function(a){return h[a]&&d(w(a))};r.has=function(a){return a in h};k=m(h);a.a.C(k,function(c){var d=c.mc.init,k=c.mc.update,f=c.key;if(8===
b.nodeType&&!a.g.ea[f])throw Error("The binding '"+f+"' cannot be used with virtual elements");try{"function"==typeof d&&a.s.I(function(){var a=d(b,w(f),r,e.$data,e);if(a&&a.controlsDescendantBindings){if(v!==n)throw Error("Multiple bindings ("+v+" and "+f+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");v=f}}),"function"==typeof k&&a.L(function(){k(b,w(f),r,e.$data,e)},null,{l:b})}catch(l){throw l.message='Unable to process binding "'+
f+": "+h[f]+'"\nMessage: '+l.message,l;}})}return{shouldBindDescendants:v===n}}function k(b){return b&&b instanceof a.$?b:new a.$(b)}a.f={};var p={script:!0,textarea:!0,template:!0};a.getBindingHandler=function(b){return a.f[b]};a.$=function(b,c,d,e,k){function f(){var k=m?b():b,l=a.a.c(k);c?(c.Z&&c.Z(),a.a.extend(h,c),h.Z=p):(h.$parents=[],h.$root=l,h.ko=a);h.$rawData=k;h.$data=l;d&&(h[d]=l);e&&e(h,c,l);return h.$data}function l(){return g&&!a.a.Wb(g)}var h=this,m="function"==typeof b&&!a.J(b),g,
p;k&&k.exportDependencies?f():(p=a.L(f,null,{Fa:l,l:!0}),p.ka()&&(h.Z=p,p.equalityComparer=null,g=[],p.Hc=function(b){g.push(b);a.a.P.ya(b,function(b){a.a.Xa(g,b);g.length||(p.o(),h.Z=p=n)})}))};a.$.prototype.createChildContext=function(b,c,d,e){return new a.$(b,this,c,function(a,b){a.$parentContext=b;a.$parent=b.$data;a.$parents=(b.$parents||[]).slice(0);a.$parents.unshift(a.$parent);d&&d(a)},e)};a.$.prototype.extend=function(b){return new a.$(this.Z||this.$data,this,null,function(c,d){c.$rawData=
d.$rawData;a.a.extend(c,"function"==typeof b?b():b)})};a.$.prototype.dc=function(a,b){return this.createChildContext(a,b,null,{exportDependencies:!0})};var u=a.a.h.S(),q=a.a.h.S();a.Ac=function(b,c){if(2==arguments.length)a.a.h.set(b,q,c),c.Z&&c.Z.Hc(b);else return a.a.h.get(b,q)};a.Ua=function(b,c,d){1===b.nodeType&&a.g.rc(b);return l(b,c,k(d),!0)};a.Kc=function(b,c,d){d=k(d);return a.Ua(b,e(c,d,b),d)};a.Va=function(a,b){1!==b.nodeType&&8!==b.nodeType||g(k(a),b,!0)};a.Xb=function(a,b){!r&&y.jQuery&&
(r=y.jQuery);if(b&&1!==b.nodeType&&8!==b.nodeType)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");b=b||y.document.body;h(k(a),b,!0)};a.ub=function(b){switch(b.nodeType){case 1:case 8:var c=a.Ac(b);if(c)return c;if(b.parentNode)return a.ub(b.parentNode)}return n};a.Qc=function(b){return(b=a.ub(b))?b.$data:n};a.b("bindingHandlers",a.f);a.b("applyBindings",a.Xb);a.b("applyBindingsToDescendants",a.Va);a.b("applyBindingAccessorsToNode",
a.Ua);a.b("applyBindingsToNode",a.Kc);a.b("contextFor",a.ub);a.b("dataFor",a.Qc)})();(function(b){function d(d,e){var l=f.hasOwnProperty(d)?f[d]:b,k;l?l.subscribe(e):(l=f[d]=new a.T,l.subscribe(e),c(d,function(b,c){var e=!(!c||!c.synchronous);g[d]={definition:b,fd:e};delete f[d];k||e?l.notifySubscribers(b):a.ga.ib(function(){l.notifySubscribers(b)})}),k=!0)}function c(a,b){e("getConfig",[a],function(c){c?e("loadComponent",[a,c],function(a){b(a,c)}):b(null,null)})}function e(c,d,f,k){k||(k=a.i.loaders.slice(0));
var g=k.shift();if(g){var u=g[c];if(u){var q=!1;if(u.apply(g,d.concat(function(a){q?f(null):null!==a?f(a):e(c,d,f,k)}))!==b&&(q=!0,!g.suppressLoaderExceptions))throw Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.");}else e(c,d,f,k)}else f(null)}var f={},g={};a.i={get:function(c,e){var f=g.hasOwnProperty(c)?g[c]:b;f?f.fd?a.s.I(function(){e(f.definition)}):a.ga.ib(function(){e(f.definition)}):d(c,e)},cc:function(a){delete g[a]},Pb:e};a.i.loaders=
[];a.b("components",a.i);a.b("components.get",a.i.get);a.b("components.clearCachedDefinition",a.i.cc)})();(function(){function b(b,c,d,e){function g(){0===--z&&e(h)}var h={},z=2,t=d.template;d=d.viewModel;t?f(c,t,function(c){a.i.Pb("loadTemplate",[b,c],function(a){h.template=a;g()})}):g();d?f(c,d,function(c){a.i.Pb("loadViewModel",[b,c],function(a){h[m]=a;g()})}):g()}function d(a,b,c){if("function"===typeof b)c(function(a){return new b(a)});else if("function"===typeof b[m])c(b[m]);else if("instance"in
b){var e=b.instance;c(function(){return e})}else"viewModel"in b?d(a,b.viewModel,c):a("Unknown viewModel value: "+b)}function c(b){switch(a.a.K(b)){case "script":return a.a.va(b.text);case "textarea":return a.a.va(b.value);case "template":if(e(b.content))return a.a.Da(b.content.childNodes)}return a.a.Da(b.childNodes)}function e(a){return y.DocumentFragment?a instanceof DocumentFragment:a&&11===a.nodeType}function f(a,b,c){"string"===typeof b.require?O||y.require?(O||y.require)([b.require],c):a("Uses require, but no AMD loader is present"):
c(b)}function g(a){return function(b){throw Error("Component '"+a+"': "+b);}}var h={};a.i.register=function(b,c){if(!c)throw Error("Invalid configuration for "+b);if(a.i.Db(b))throw Error("Component "+b+" is already registered");h[b]=c};a.i.Db=function(a){return h.hasOwnProperty(a)};a.i.unregister=function(b){delete h[b];a.i.cc(b)};a.i.fc={getConfig:function(a,b){b(h.hasOwnProperty(a)?h[a]:null)},loadComponent:function(a,c,d){var e=g(a);f(e,c,function(c){b(a,e,c,d)})},loadTemplate:function(b,d,f){b=
g(b);if("string"===typeof d)f(a.a.va(d));else if(d instanceof Array)f(d);else if(e(d))f(a.a.fa(d.childNodes));else if(d.element)if(d=d.element,y.HTMLElement?d instanceof HTMLElement:d&&d.tagName&&1===d.nodeType)f(c(d));else if("string"===typeof d){var h=v.getElementById(d);h?f(c(h)):b("Cannot find element with ID "+d)}else b("Unknown element type: "+d);else b("Unknown template value: "+d)},loadViewModel:function(a,b,c){d(g(a),b,c)}};var m="createViewModel";a.b("components.register",a.i.register);
a.b("components.isRegistered",a.i.Db);a.b("components.unregister",a.i.unregister);a.b("components.defaultLoader",a.i.fc);a.i.loaders.push(a.i.fc);a.i.Ic=h})();(function(){function b(b,e){var f=b.getAttribute("params");if(f){var f=d.parseBindingsString(f,e,b,{valueAccessors:!0,bindingParams:!0}),f=a.a.Ma(f,function(d){return a.u(d,null,{l:b})}),g=a.a.Ma(f,function(d){var e=d.G();return d.ka()?a.u({read:function(){return a.a.c(d())},write:a.Ka(e)&&function(a){d()(a)},l:b}):e});g.hasOwnProperty("$raw")||
(g.$raw=f);return g}return{$raw:{}}}a.i.getComponentNameForNode=function(b){var d=a.a.K(b);if(a.i.Db(d)&&(-1!=d.indexOf("-")||"[object HTMLUnknownElement]"==""+b||8>=a.a.M&&b.tagName===d))return d};a.i.Ub=function(c,d,f,g){if(1===d.nodeType){var h=a.i.getComponentNameForNode(d);if(h){c=c||{};if(c.component)throw Error('Cannot use the "component" binding on a custom element matching a component');var m={name:h,params:b(d,f)};c.component=g?function(){return m}:m}}return c};var d=new a.aa;9>a.a.M&&(a.i.register=
function(a){return function(b){return a.apply(this,arguments)}}(a.i.register),v.createDocumentFragment=function(b){return function(){var d=b(),f=a.i.Ic,g;for(g in f);return d}}(v.createDocumentFragment))})();(function(b){function d(b,c,d){c=c.template;if(!c)throw Error("Component '"+b+"' has no template");b=a.a.Da(c);a.g.ma(d,b)}function c(a,b,c,d){var e=a.createViewModel;return e?e.call(a,d,{element:b,templateNodes:c}):d}var e=0;a.f.component={init:function(f,g,h,m,l){function k(){var a=p&&p.dispose;
"function"===typeof a&&a.call(p);u=p=null}var p,u,q=a.a.fa(a.g.childNodes(f));a.a.P.ya(f,k);a.u(function(){var h=a.a.c(g()),m,t;"string"===typeof h?m=h:(m=a.a.c(h.name),t=a.a.c(h.params));if(!m)throw Error("No component name specified");var n=u=++e;a.i.get(m,function(e){if(u===n){k();if(!e)throw Error("Unknown component '"+m+"'");d(m,e,f);var g=c(e,f,q,t);e=l.createChildContext(g,b,function(a){a.$component=g;a.$componentTemplateNodes=q});p=g;a.Va(e,f)}})},null,{l:f});return{controlsDescendantBindings:!0}}};
a.g.ea.component=!0})();var S={"class":"className","for":"htmlFor"};a.f.attr={update:function(b,d){var c=a.a.c(d())||{};a.a.N(c,function(c,d){d=a.a.c(d);var g=!1===d||null===d||d===n;g&&b.removeAttribute(c);8>=a.a.M&&c in S?(c=S[c],g?b.removeAttribute(c):b[c]=d):g||b.setAttribute(c,d.toString());"name"===c&&a.a.yc(b,g?"":d.toString())})}};(function(){a.f.checked={after:["value","attr"],init:function(b,d,c){function e(){var e=b.checked,f=A?g():e;if(!a.Ea.eb()&&(!l||e)){var k=a.s.I(d);if(p){var m=u?
k.G():k;q!==f?(e&&(a.a.za(m,f,!0,h),a.a.za(m,q,!1,h)),q=f):a.a.za(m,f,e,h);u&&a.Ka(k)&&k(m)}else a.j.Pa(k,c,"checked",f,!0)}}function f(){var c=a.a.c(d());p?b.checked=0<=a.a.A(c,g(),h):m?b.checked=c:b.checked=g()===c}var g=a.uc(function(){return c.has("checkedValue")?a.a.c(c.get("checkedValue")):c.has("value")?a.a.c(c.get("value")):b.value}),h=c.has("checkedArrayContainsObservables")&&c.get("checkedArrayContainsObservables"),m="checkbox"==b.type,l="radio"==b.type;if(m||l){var k=d(),p=m&&a.a.c(k)instanceof
Array,u=!(p&&k.push&&k.splice),q=p?g():n,A=l||p;l&&!b.name&&a.f.uniqueName.init(b,function(){return!0});a.u(e,null,{l:b});a.a.B(b,"click",e);a.u(f,null,{l:b});k=n}}};a.j.na.checked=!0;a.f.checkedValue={update:function(b,d){b.value=a.a.c(d())}}})();a.f["class"]=a.f.css={update:function(b,d){var c=a.a.c(d());null!==c&&"object"==typeof c?a.a.N(c,function(c,d){d=a.a.c(d);a.a.nb(b,c,d)}):(c=a.a.lb(String(c||"")),a.a.nb(b,b.__ko__cssValue,!1),b.__ko__cssValue=c,a.a.nb(b,c,!0))}};a.f.enable={update:function(b,
d){var c=a.a.c(d());c&&b.disabled?b.removeAttribute("disabled"):c||b.disabled||(b.disabled=!0)}};a.f.disable={update:function(b,d){a.f.enable.update(b,function(){return!a.a.c(d())})}};a.f.event={init:function(b,d,c,e,f){var g=d()||{};a.a.N(g,function(g){"string"==typeof g&&a.a.B(b,g,function(b){var l,k=d()[g];if(k){try{var p=a.a.fa(arguments);e=f.$data;p.unshift(e);l=k.apply(e,p)}finally{!0!==l&&(b.preventDefault?b.preventDefault():b.returnValue=!1)}!1===c.get(g+"Bubble")&&(b.cancelBubble=!0,b.stopPropagation&&
b.stopPropagation())}})})}};a.f.foreach={pc:function(b){return function(){var d=b(),c=a.a.Na(d);if(!c||"number"==typeof c.length)return{foreach:d,templateEngine:a.X.xa};a.a.c(d);return{foreach:c.data,as:c.as,includeDestroyed:c.includeDestroyed,afterAdd:c.afterAdd,beforeRemove:c.beforeRemove,afterRender:c.afterRender,beforeMove:c.beforeMove,afterMove:c.afterMove,templateEngine:a.X.xa}}},init:function(b,d){return a.f.template.init(b,a.f.foreach.pc(d))},update:function(b,d,c,e,f){return a.f.template.update(b,
a.f.foreach.pc(d),c,e,f)}};a.j.Ca.foreach=!1;a.g.ea.foreach=!0;a.f.hasfocus={init:function(b,d,c){function e(e){b.__ko_hasfocusUpdating=!0;var f=b.ownerDocument;if("activeElement"in f){var g;try{g=f.activeElement}catch(k){g=f.body}e=g===b}f=d();a.j.Pa(f,c,"hasfocus",e,!0);b.__ko_hasfocusLastValue=e;b.__ko_hasfocusUpdating=!1}var f=e.bind(null,!0),g=e.bind(null,!1);a.a.B(b,"focus",f);a.a.B(b,"focusin",f);a.a.B(b,"blur",g);a.a.B(b,"focusout",g)},update:function(b,d){var c=!!a.a.c(d());b.__ko_hasfocusUpdating||
b.__ko_hasfocusLastValue===c||(c?b.focus():b.blur(),!c&&b.__ko_hasfocusLastValue&&b.ownerDocument.body.focus(),a.s.I(a.a.Oa,null,[b,c?"focusin":"focusout"]))}};a.j.na.hasfocus=!0;a.f.hasFocus=a.f.hasfocus;a.j.na.hasFocus=!0;a.f.html={init:function(){return{controlsDescendantBindings:!0}},update:function(b,d){a.a.Jb(b,d())}};K("if");K("ifnot",!1,!0);K("with",!0,!1,function(a,d){return a.dc(d)});a.f.let={init:function(b,d,c,e,f){d=f.extend(d);a.Va(d,b);return{controlsDescendantBindings:!0}}};a.g.ea.let=
!0;var L={};a.f.options={init:function(b){if("select"!==a.a.K(b))throw Error("options binding applies only to SELECT elements");for(;0<b.length;)b.remove(0);return{controlsDescendantBindings:!0}},update:function(b,d,c){function e(){return a.a.Wa(b.options,function(a){return a.selected})}function f(a,b,c){var d=typeof b;return"function"==d?b(a):"string"==d?a[b]:c}function g(d,e){if(A&&k)a.m.qa(b,a.a.c(c.get("value")),!0);else if(q.length){var f=0<=a.a.A(q,a.m.H(e[0]),!0);a.a.zc(e[0],f);A&&!f&&a.s.I(a.a.Oa,
null,[b,"change"])}}var h=b.multiple,m=0!=b.length&&h?b.scrollTop:null,l=a.a.c(d()),k=c.get("valueAllowUnset")&&c.has("value"),p=c.get("optionsIncludeDestroyed");d={};var u,q=[];k||(h?q=a.a.pb(e(),a.m.H):0<=b.selectedIndex&&q.push(a.m.H(b.options[b.selectedIndex])));l&&("undefined"==typeof l.length&&(l=[l]),u=a.a.Wa(l,function(b){return p||b===n||null===b||!a.a.c(b._destroy)}),c.has("optionsCaption")&&(l=a.a.c(c.get("optionsCaption")),null!==l&&l!==n&&u.unshift(L)));var A=!1;d.beforeRemove=function(a){b.removeChild(a)};
l=g;c.has("optionsAfterRender")&&"function"==typeof c.get("optionsAfterRender")&&(l=function(b,d){g(0,d);a.s.I(c.get("optionsAfterRender"),null,[d[0],b!==L?b:n])});a.a.Ib(b,u,function(d,e,g){g.length&&(q=!k&&g[0].selected?[a.m.H(g[0])]:[],A=!0);e=b.ownerDocument.createElement("option");d===L?(a.a.kb(e,c.get("optionsCaption")),a.m.qa(e,n)):(g=f(d,c.get("optionsValue"),d),a.m.qa(e,a.a.c(g)),d=f(d,c.get("optionsText"),g),a.a.kb(e,d));return[e]},d,l);a.s.I(function(){if(k)a.m.qa(b,a.a.c(c.get("value")),
!0);else{var d;h?d=q.length&&e().length<q.length:d=q.length&&0<=b.selectedIndex?a.m.H(b.options[b.selectedIndex])!==q[0]:q.length||0<=b.selectedIndex;d&&a.a.Oa(b,"change")}});a.a.Uc(b);m&&20<Math.abs(m-b.scrollTop)&&(b.scrollTop=m)}};a.f.options.Fb=a.a.h.S();a.f.selectedOptions={after:["options","foreach"],init:function(b,d,c){a.a.B(b,"change",function(){var e=d(),f=[];a.a.C(b.getElementsByTagName("option"),function(b){b.selected&&f.push(a.a.wd(a.m.H(b)))});a.j.Pa(e,c,"selectedOptions",f)})},update:function(b,
d){if("select"!=a.a.K(b))throw Error("values binding applies only to SELECT elements");var c=a.a.c(d()),e=b.scrollTop;c&&"number"==typeof c.length&&a.a.C(b.getElementsByTagName("option"),function(b){var d=0<=a.a.A(c,a.m.H(b),!0);b.selected!=d&&a.a.zc(b,d)});b.scrollTop=e}};a.j.na.selectedOptions=!0;a.f.style={update:function(b,d){var c=a.a.c(d()||{});a.a.N(c,function(c,d){d=a.a.c(d);if(null===d||d===n||!1===d)d="";b.style[c]=d})}};a.f.submit={init:function(b,d,c,e,f){if("function"!=typeof d())throw Error("The value for a submit binding must be a function");
a.a.B(b,"submit",function(a){var c,e=d();try{c=e.call(f.$data,b)}finally{!0!==c&&(a.preventDefault?a.preventDefault():a.returnValue=!1)}})}};a.f.text={init:function(){return{controlsDescendantBindings:!0}},update:function(b,d){a.a.kb(b,d())}};a.g.ea.text=!0;(function(){if(y&&y.navigator)var b=function(a){if(a)return parseFloat(a[1])},d=y.opera&&y.opera.version&&parseInt(y.opera.version()),c=y.navigator.userAgent,e=b(c.match(/^(?:(?!chrome).)*version\/([^ ]*) safari/i)),f=b(c.match(/Firefox\/([^ ]*)/));
if(10>a.a.M)var g=a.a.h.S(),h=a.a.h.S(),m=function(b){var c=this.activeElement;(c=c&&a.a.h.get(c,h))&&c(b)},l=function(b,c){var d=b.ownerDocument;a.a.h.get(d,g)||(a.a.h.set(d,g,!0),a.a.B(d,"selectionchange",m));a.a.h.set(b,h,c)};a.f.textInput={init:function(b,c,g){function h(c,d){a.a.B(b,c,d)}function m(){var d=a.a.c(c());if(null===d||d===n)d="";w!==n&&d===w?a.a.setTimeout(m,4):b.value!==d&&(v=d,b.value=d)}function z(){r||(w=b.value,r=a.a.setTimeout(t,4))}function t(){clearTimeout(r);w=r=n;var d=
b.value;v!==d&&(v=d,a.j.Pa(c(),g,"textInput",d))}var v=b.value,r,w,y=9==a.a.M?z:t;10>a.a.M?(h("propertychange",function(a){"value"===a.propertyName&&y(a)}),8==a.a.M&&(h("keyup",t),h("keydown",t)),8<=a.a.M&&(l(b,y),h("dragend",z))):(h("input",t),5>e&&"textarea"===a.a.K(b)?(h("keydown",z),h("paste",z),h("cut",z)):11>d?h("keydown",z):4>f&&(h("DOMAutoComplete",t),h("dragdrop",t),h("drop",t)));h("change",t);a.u(m,null,{l:b})}};a.j.na.textInput=!0;a.f.textinput={preprocess:function(a,b,c){c("textInput",
a)}}})();a.f.uniqueName={init:function(b,d){if(d()){var c="ko_unique_"+ ++a.f.uniqueName.Pc;a.a.yc(b,c)}}};a.f.uniqueName.Pc=0;a.f.value={after:["options","foreach"],init:function(b,d,c){if("input"!=b.tagName.toLowerCase()||"checkbox"!=b.type&&"radio"!=b.type){var e=["change"],f=c.get("valueUpdate"),g=!1,h=null;f&&("string"==typeof f&&(f=[f]),a.a.Aa(e,f),e=a.a.Zb(e));var m=function(){h=null;g=!1;var e=d(),f=a.m.H(b);a.j.Pa(e,c,"value",f)};!a.a.M||"input"!=b.tagName.toLowerCase()||"text"!=b.type||
"off"==b.autocomplete||b.form&&"off"==b.form.autocomplete||-1!=a.a.A(e,"propertychange")||(a.a.B(b,"propertychange",function(){g=!0}),a.a.B(b,"focus",function(){g=!1}),a.a.B(b,"blur",function(){g&&m()}));a.a.C(e,function(c){var d=m;a.a.ud(c,"after")&&(d=function(){h=a.m.H(b);a.a.setTimeout(m,0)},c=c.substring(5));a.a.B(b,c,d)});var l=function(){var e=a.a.c(d()),f=a.m.H(b);if(null!==h&&e===h)a.a.setTimeout(l,0);else if(e!==f)if("select"===a.a.K(b)){var g=c.get("valueAllowUnset"),f=function(){a.m.qa(b,
e,g)};f();g||e===a.m.H(b)?a.a.setTimeout(f,0):a.s.I(a.a.Oa,null,[b,"change"])}else a.m.qa(b,e)};a.u(l,null,{l:b})}else a.Ua(b,{checkedValue:d})},update:function(){}};a.j.na.value=!0;a.f.visible={update:function(b,d){var c=a.a.c(d()),e="none"!=b.style.display;c&&!e?b.style.display="":!c&&e&&(b.style.display="none")}};(function(b){a.f[b]={init:function(d,c,e,f,g){return a.f.event.init.call(this,d,function(){var a={};a[b]=c();return a},e,f,g)}}})("click");a.Y=function(){};a.Y.prototype.renderTemplateSource=
function(){throw Error("Override renderTemplateSource");};a.Y.prototype.createJavaScriptEvaluatorBlock=function(){throw Error("Override createJavaScriptEvaluatorBlock");};a.Y.prototype.makeTemplateSource=function(b,d){if("string"==typeof b){d=d||v;var c=d.getElementById(b);if(!c)throw Error("Cannot find template with ID "+b);return new a.w.v(c)}if(1==b.nodeType||8==b.nodeType)return new a.w.ha(b);throw Error("Unknown template type: "+b);};a.Y.prototype.renderTemplate=function(a,d,c,e){a=this.makeTemplateSource(a,
e);return this.renderTemplateSource(a,d,c,e)};a.Y.prototype.isTemplateRewritten=function(a,d){return!1===this.allowTemplateRewriting?!0:this.makeTemplateSource(a,d).data("isRewritten")};a.Y.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.Y);a.Nb=function(){function b(b,c,d,h){b=a.j.Gb(b);for(var m=a.j.Ca,l=0;l<b.length;l++){var k=b[l].key;if(m.hasOwnProperty(k)){var p=m[k];if("function"===typeof p){if(k=
p(b[l].value))throw Error(k);}else if(!p)throw Error("This template engine does not support the '"+k+"' binding within its templates");}}d="ko.__tr_ambtns(function($context,$element){return(function(){return{ "+a.j.gb(b,{valueAccessors:!0})+" } })()},'"+d.toLowerCase()+"')";return h.createJavaScriptEvaluatorBlock(d)+c}var d=/(<([a-z]+\d*)(?:\s+(?!data-bind\s*=\s*)[a-z0-9\-]+(?:=(?:\"[^\"]*\"|\'[^\']*\'|[^>]*))?)*\s+)data-bind\s*=\s*(["'])([\s\S]*?)\3/gi,c=/\x3c!--\s*ko\b\s*([\s\S]*?)\s*--\x3e/g;return{Vc:function(b,
c,d){c.isTemplateRewritten(b,d)||c.rewriteTemplate(b,function(b){return a.Nb.ld(b,c)},d)},ld:function(a,f){return a.replace(d,function(a,c,d,e,k){return b(k,c,d,f)}).replace(c,function(a,c){return b(c,"\x3c!-- ko --\x3e","#comment",f)})},Lc:function(b,c){return a.W.Eb(function(d,h){var m=d.nextSibling;m&&m.nodeName.toLowerCase()===c&&a.Ua(m,b,h)})}}}();a.b("__tr_ambtns",a.Nb.Lc);(function(){a.w={};a.w.v=function(b){if(this.v=b){var d=a.a.K(b);this.mb="script"===d?1:"textarea"===d?2:"template"==d&&
b.content&&11===b.content.nodeType?3:4}};a.w.v.prototype.text=function(){var b=1===this.mb?"text":2===this.mb?"value":"innerHTML";if(0==arguments.length)return this.v[b];var d=arguments[0];"innerHTML"===b?a.a.Jb(this.v,d):this.v[b]=d};var b=a.a.h.S()+"_";a.w.v.prototype.data=function(c){if(1===arguments.length)return a.a.h.get(this.v,b+c);a.a.h.set(this.v,b+c,arguments[1])};var d=a.a.h.S();a.w.v.prototype.nodes=function(){var b=this.v;if(0==arguments.length)return(a.a.h.get(b,d)||{}).tb||(3===this.mb?
b.content:4===this.mb?b:n);a.a.h.set(b,d,{tb:arguments[0]})};a.w.ha=function(a){this.v=a};a.w.ha.prototype=new a.w.v;a.w.ha.prototype.constructor=a.w.ha;a.w.ha.prototype.text=function(){if(0==arguments.length){var b=a.a.h.get(this.v,d)||{};b.Ob===n&&b.tb&&(b.Ob=b.tb.innerHTML);return b.Ob}a.a.h.set(this.v,d,{Ob:arguments[0]})};a.b("templateSources",a.w);a.b("templateSources.domElement",a.w.v);a.b("templateSources.anonymousTemplate",a.w.ha)})();(function(){function b(b,d,c){var e;for(d=a.g.nextSibling(d);b&&
(e=b)!==d;)b=a.g.nextSibling(e),c(e,b)}function d(d,c){if(d.length){var e=d[0],f=d[d.length-1],g=e.parentNode,h=a.aa.instance,n=h.preprocessNode;if(n){b(e,f,function(a,b){var d=a.previousSibling,c=n.call(h,a);c&&(a===e&&(e=c[0]||b),a===f&&(f=c[c.length-1]||d))});d.length=0;if(!e)return;e===f?d.push(e):(d.push(e,f),a.a.Ia(d,g))}b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.Xb(c,b)});b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.W.Fc(b,[c])});a.a.Ia(d,g)}}function c(a){return a.nodeType?
a:0<a.length?a[0]:null}function e(b,e,f,h,u){u=u||{};var q=(b&&c(b)||f||{}).ownerDocument,n=u.templateEngine||g;a.Nb.Vc(f,n,q);f=n.renderTemplate(f,h,u,q);if("number"!=typeof f.length||0<f.length&&"number"!=typeof f[0].nodeType)throw Error("Template engine must return an array of DOM nodes");q=!1;switch(e){case "replaceChildren":a.g.ma(b,f);q=!0;break;case "replaceNode":a.a.xc(b,f);q=!0;break;case "ignoreTargetNode":break;default:throw Error("Unknown renderMode: "+e);}q&&(d(f,h),u.afterRender&&a.s.I(u.afterRender,
null,[f,h.$data]));return f}function f(b,d,c){return a.J(b)?b():"function"===typeof b?b(d,c):b}var g;a.Kb=function(b){if(b!=n&&!(b instanceof a.Y))throw Error("templateEngine must inherit from ko.templateEngine");g=b};a.Hb=function(b,d,h,p,u){h=h||{};if((h.templateEngine||g)==n)throw Error("Set a template engine before calling renderTemplate");u=u||"replaceChildren";if(p){var q=c(p);return a.L(function(){var g=d&&d instanceof a.$?d:new a.$(d,null,null,null,{exportDependencies:!0}),n=f(b,g.$data,g),
g=e(p,u,n,g,h);"replaceNode"==u&&(p=g,q=c(p))},null,{Fa:function(){return!q||!a.a.xb(q)},l:q&&"replaceNode"==u?q.parentNode:q})}return a.W.Eb(function(c){a.Hb(b,d,h,c,"replaceNode")})};a.qd=function(b,c,g,h,u){function q(a,b){d(b,r);g.afterRender&&g.afterRender(b,a);r=null}function v(a,d){r=u.createChildContext(a,g.as,function(a){a.$index=d});var c=f(b,a,r);return e(null,"ignoreTargetNode",c,r,g)}var r;return a.L(function(){var b=a.a.c(c)||[];"undefined"==typeof b.length&&(b=[b]);b=a.a.Wa(b,function(b){return g.includeDestroyed||
b===n||null===b||!a.a.c(b._destroy)});a.s.I(a.a.Ib,null,[h,b,v,g,q])},null,{l:h})};var h=a.a.h.S();a.f.template={init:function(b,d){var c=a.a.c(d());if("string"==typeof c||c.name)a.g.Ga(b);else{if("nodes"in c){c=c.nodes||[];if(a.J(c))throw Error('The "nodes" option must be a plain, non-observable array.');c=a.a.qc(c)}else c=a.g.childNodes(b),c=a.a.qc(c);(new a.w.ha(b)).nodes(c)}return{controlsDescendantBindings:!0}},update:function(b,c,d,e,f){var g=c();c=a.a.c(g);d=!0;e=null;"string"==typeof c?c=
{}:(g=c.name,"if"in c&&(d=a.a.c(c["if"])),d&&"ifnot"in c&&(d=!a.a.c(c.ifnot)));"foreach"in c?e=a.qd(g||b,d&&c.foreach||[],c,b,f):d?(f="data"in c?f.dc(c.data,c.as):f,e=a.Hb(g||b,f,c,b)):a.g.Ga(b);f=e;(c=a.a.h.get(b,h))&&"function"==typeof c.o&&c.o();a.a.h.set(b,h,f&&f.ka()?f:n)}};a.j.Ca.template=function(b){b=a.j.Gb(b);return 1==b.length&&b[0].unknown||a.j.hd(b,"name")?null:"This template engine does not support anonymous templates nested within its templates"};a.g.ea.template=!0})();a.b("setTemplateEngine",
a.Kb);a.b("renderTemplate",a.Hb);a.a.kc=function(a,d,c){if(a.length&&d.length){var e,f,g,h,m;for(e=f=0;(!c||e<c)&&(h=a[f]);++f){for(g=0;m=d[g];++g)if(h.value===m.value){h.moved=m.index;m.moved=h.index;d.splice(g,1);e=g=0;break}e+=g}}};a.a.sb=function(){function b(b,c,e,f,g){var h=Math.min,m=Math.max,l=[],k,p=b.length,n,q=c.length,r=q-p||1,v=p+q+1,t,w,y;for(k=0;k<=p;k++)for(w=t,l.push(t=[]),y=h(q,k+r),n=m(0,k-1);n<=y;n++)t[n]=n?k?b[k-1]===c[n-1]?w[n-1]:h(w[n]||v,t[n-1]||v)+1:n+1:k+1;h=[];m=[];r=[];
k=p;for(n=q;k||n;)q=l[k][n]-1,n&&q===l[k][n-1]?m.push(h[h.length]={status:e,value:c[--n],index:n}):k&&q===l[k-1][n]?r.push(h[h.length]={status:f,value:b[--k],index:k}):(--n,--k,g.sparse||h.push({status:"retained",value:c[n]}));a.a.kc(r,m,!g.dontLimitMoves&&10*p);return h.reverse()}return function(a,c,e){e="boolean"===typeof e?{dontLimitMoves:e}:e||{};a=a||[];c=c||[];return a.length<c.length?b(a,c,"added","deleted",e):b(c,a,"deleted","added",e)}}();a.b("utils.compareArrays",a.a.sb);(function(){function b(b,
c,d,h,m){var l=[],k=a.L(function(){var k=c(d,m,a.a.Ia(l,b))||[];0<l.length&&(a.a.xc(l,k),h&&a.s.I(h,null,[d,k,m]));l.length=0;a.a.Aa(l,k)},null,{l:b,Fa:function(){return!a.a.Wb(l)}});return{la:l,L:k.ka()?k:n}}var d=a.a.h.S(),c=a.a.h.S();a.a.Ib=function(e,f,g,h,m){function l(b,c){x=u[c];w!==c&&(E[b]=x);x.Ab(w++);a.a.Ia(x.la,e);v.push(x);B.push(x)}function k(b,c){if(b)for(var d=0,e=c.length;d<e;d++)c[d]&&a.a.C(c[d].la,function(a){b(a,d,c[d].sa)})}f=f||[];h=h||{};var p=a.a.h.get(e,d)===n,u=a.a.h.get(e,
d)||[],q=a.a.pb(u,function(a){return a.sa}),r=a.a.sb(q,f,h.dontLimitMoves),v=[],t=0,w=0,y=[],B=[];f=[];for(var E=[],q=[],x,D=0,C,F;C=r[D];D++)switch(F=C.moved,C.status){case "deleted":F===n&&(x=u[t],x.L&&(x.L.o(),x.L=n),a.a.Ia(x.la,e).length&&(h.beforeRemove&&(v.push(x),B.push(x),x.sa===c?x=null:f[D]=x),x&&y.push.apply(y,x.la)));t++;break;case "retained":l(D,t++);break;case "added":F!==n?l(D,F):(x={sa:C.value,Ab:a.O(w++)},v.push(x),B.push(x),p||(q[D]=x))}a.a.h.set(e,d,v);k(h.beforeMove,E);a.a.C(y,
h.beforeRemove?a.ia:a.removeNode);for(var D=0,p=a.g.firstChild(e),G;x=B[D];D++){x.la||a.a.extend(x,b(e,g,x.sa,m,x.Ab));for(t=0;r=x.la[t];p=r.nextSibling,G=r,t++)r!==p&&a.g.nc(e,r,G);!x.cd&&m&&(m(x.sa,x.la,x.Ab),x.cd=!0)}k(h.beforeRemove,f);for(D=0;D<f.length;++D)f[D]&&(f[D].sa=c);k(h.afterMove,E);k(h.afterAdd,q)}})();a.b("utils.setDomNodeChildrenFromArrayMapping",a.a.Ib);a.X=function(){this.allowTemplateRewriting=!1};a.X.prototype=new a.Y;a.X.prototype.constructor=a.X;a.X.prototype.renderTemplateSource=
function(b,d,c,e){if(d=(9>a.a.M?0:b.nodes)?b.nodes():null)return a.a.fa(d.cloneNode(!0).childNodes);b=b.text();return a.a.va(b,e)};a.X.xa=new a.X;a.Kb(a.X.xa);a.b("nativeTemplateEngine",a.X);(function(){a.La=function(){var a=this.gd=function(){if(!r||!r.tmpl)return 0;try{if(0<=r.tmpl.tag.tmpl.open.toString().indexOf("__"))return 2}catch(a){}return 1}();this.renderTemplateSource=function(b,e,f,g){g=g||v;f=f||{};if(2>a)throw Error("Your version of jQuery.tmpl is too old. Please upgrade to jQuery.tmpl 1.0.0pre or later.");
var h=b.data("precompiled");h||(h=b.text()||"",h=r.template(null,"{{ko_with $item.koBindingContext}}"+h+"{{/ko_with}}"),b.data("precompiled",h));b=[e.$data];e=r.extend({koBindingContext:e},f.templateOptions);e=r.tmpl(h,b,e);e.appendTo(g.createElement("div"));r.fragments={};return e};this.createJavaScriptEvaluatorBlock=function(a){return"{{ko_code ((function() { return "+a+" })()) }}"};this.addTemplate=function(a,b){v.write("<script type='text/html' id='"+a+"'>"+b+"\x3c/script>")};0<a&&(r.tmpl.tag.ko_code=
{open:"__.push($1 || '');"},r.tmpl.tag.ko_with={open:"with($1) {",close:"} "})};a.La.prototype=new a.Y;a.La.prototype.constructor=a.La;var b=new a.La;0<b.gd&&a.Kb(b);a.b("jqueryTmplTemplateEngine",a.La)})()})})();})();
