agens-viewer
Version:
Simple AgensGraph web UI client that easy to run and use
6 lines • 464 kB
JavaScript
!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=304)}([function(t,e,n){var r;try{r={cloneDeep:n(241),constant:n(56),defaults:n(242),each:n(82),filter:n(85),find:n(243),flatten:n(112),forEach:n(83),forIn:n(248),has:n(96),isUndefined:n(97),last:n(249),map:n(98),mapValues:n(250),max:n(251),merge:n(253),min:n(259),minBy:n(260),now:n(261),pick:n(262),range:n(267),reduce:n(100),sortBy:n(270),uniqueId:n(275),values:n(105),zipObject:n(276)}}catch(t){}r||(r=window._),t.exports=r},function(t,e){var n=Array.isArray;t.exports=n},function(t,e,n){var r,i,o;
/*!
* Knockout JavaScript library v3.5.0
* (c) The Knockout.js team - http://knockoutjs.com/
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
*/!function(a){var s=this||(0,eval)("this"),u=s.document,c=s.navigator,f=s.jQuery,h=s.JSON;f||"undefined"==typeof jQuery||(f=jQuery),function(a){i=[e,n],void 0===(o="function"==typeof(r=a)?r.apply(e,i):r)||(t.exports=o)}(function(t,e){function n(t,e){return(null===t||typeof t in A)&&t===e}function r(t,e){var n;return function(){n||(n=x.a.setTimeout(function(){n=a,t()},e))}}function i(t,e){var n;return function(){clearTimeout(n),n=x.a.setTimeout(t,e)}}function o(t,e){e&&"change"!==e?"beforeChange"===e?this.oc(t):this.bb(t,e):this.pc(t)}function l(t,e){null!==e&&e.s&&e.s()}function d(t,e){var n=this.pd,r=n[C];r.qa||(this.Pb&&this.kb[e]?(n.tc(e,t,this.kb[e]),this.kb[e]=null,--this.Pb):r.F[e]||n.tc(e,t,r.G?{da:t}:n.Zc(t)),t.Ka&&t.fd())}var p,g,v,m,y,b,x=void 0!==t?t:{};x.b=function(t,e){for(var n=t.split("."),r=x,i=0;i<n.length-1;i++)r=r[n[i]];r[n[n.length-1]]=e},x.J=function(t,e,n){t[e]=n},x.version="3.5.0",x.b("version",x.version),x.options={deferUpdates:!1,useOnlyNativeEvents:!1,foreachHidesDestroyed:!1},x.a=function(){function t(t,e){for(var n in t)i.call(t,n)&&e(n,t[n])}function e(t,e){if(e)for(var n in e)i.call(e,n)&&(t[n]=e[n]);return t}function n(t,e){return t.__proto__=e,t}function r(t,e,n,r){var i=t[e].match(y)||[];x.a.C(n.match(y),function(t){x.a.Oa(i,t,r)}),t[e]=i.join(" ")}var i=Object.prototype.hasOwnProperty,o={__proto__:[]}instanceof Array,l="function"==typeof Symbol,d={},p={};d[c&&/Firefox\/2/i.test(c.userAgent)?"KeyboardEvent":"UIEvents"]=["keyup","keydown","keypress"],d.MouseEvents="click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave".split(" "),t(d,function(t,e){if(e.length)for(var n=0,r=e.length;n<r;n++)p[e[n]]=t});var g,v={propertychange:!0},m=u&&function(){for(var t=3,e=u.createElement("div"),n=e.getElementsByTagName("i");e.innerHTML="\x3c!--[if gt IE "+ ++t+"]><i></i><![endif]--\x3e",n[0];);return 4<t?t:a}(),y=/\S+/g;return{Ic:["authenticity_token",/^__RequestVerificationToken(_.*)?$/],C:function(t,e,n){for(var r=0,i=t.length;r<i;r++)e.call(n,t[r],r,t)},A:"function"==typeof Array.prototype.indexOf?function(t,e){return Array.prototype.indexOf.call(t,e)}:function(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n]===e)return n;return-1},Lb:function(t,e,n){for(var r=0,i=t.length;r<i;r++)if(e.call(n,t[r],r,t))return t[r];return a},hb:function(t,e){var n=x.a.A(t,e);0<n?t.splice(n,1):0===n&&t.shift()},vc:function(t){var e=[];return t&&x.a.C(t,function(t){0>x.a.A(e,t)&&e.push(t)}),e},Mb:function(t,e,n){var r=[];if(t)for(var i=0,o=t.length;i<o;i++)r.push(e.call(n,t[i],i));return r},fb:function(t,e,n){var r=[];if(t)for(var i=0,o=t.length;i<o;i++)e.call(n,t[i],i)&&r.push(t[i]);return r},gb:function(t,e){if(e instanceof Array)t.push.apply(t,e);else for(var n=0,r=e.length;n<r;n++)t.push(e[n]);return t},Oa:function(t,e,n){var r=x.a.A(x.a.$b(t),e);0>r?n&&t.push(e):n||t.splice(r,1)},Ba:o,extend:e,setPrototypeOf:n,zb:o?n:e,O:t,Ha:function(t,e,n){if(!t)return t;var r,o={};for(r in t)i.call(t,r)&&(o[r]=e.call(n,t[r],r,t));return o},Sb:function(t){for(;t.firstChild;)x.removeNode(t.firstChild)},Xb:function(t){for(var e=((t=x.a.la(t))[0]&&t[0].ownerDocument||u).createElement("div"),n=0,r=t.length;n<r;n++)e.appendChild(x.na(t[n]));return e},Ca:function(t,e){for(var n=0,r=t.length,i=[];n<r;n++){var o=t[n].cloneNode(!0);i.push(e?x.na(o):o)}return i},ua:function(t,e){if(x.a.Sb(t),e)for(var n=0,r=e.length;n<r;n++)t.appendChild(e[n])},Wc:function(t,e){var n=t.nodeType?[t]:t;if(0<n.length){for(var r=n[0],i=r.parentNode,o=0,a=e.length;o<a;o++)i.insertBefore(e[o],r);for(o=0,a=n.length;o<a;o++)x.removeNode(n[o])}},Ua:function(t,e){if(t.length){for(e=8===e.nodeType&&e.parentNode||e;t.length&&t[0].parentNode!==e;)t.splice(0,1);for(;1<t.length&&t[t.length-1].parentNode!==e;)t.length--;if(1<t.length){var n=t[0],r=t[t.length-1];for(t.length=0;n!==r;)t.push(n),n=n.nextSibling;t.push(r)}}return t},Yc:function(t,e){7>m?t.setAttribute("selected",e):t.selected=e},Cb:function(t){return null===t||t===a?"":t.trim?t.trim():t.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")},Td:function(t,e){return t=t||"",!(e.length>t.length)&&t.substring(0,e.length)===e},ud:function(t,e){if(t===e)return!0;if(11===t.nodeType)return!1;if(e.contains)return e.contains(1!==t.nodeType?t.parentNode:t);if(e.compareDocumentPosition)return 16==(16&e.compareDocumentPosition(t));for(;t&&t!=e;)t=t.parentNode;return!!t},Rb:function(t){return x.a.ud(t,t.ownerDocument.documentElement)},jd:function(t){return!!x.a.Lb(t,x.a.Rb)},P:function(t){return t&&t.tagName&&t.tagName.toLowerCase()},zc:function(t){return x.onError?function(){try{return t.apply(this,arguments)}catch(t){throw x.onError&&x.onError(t),t}}:t},setTimeout:function(t,e){return setTimeout(x.a.zc(t),e)},Fc:function(t){setTimeout(function(){throw x.onError&&x.onError(t),t},0)},H:function(t,e,n){var r=x.a.zc(n);if(n=v[e],x.options.useOnlyNativeEvents||n||!f)if(n||"function"!=typeof t.addEventListener){if(void 0===t.attachEvent)throw Error("Browser doesn't support addEventListener or attachEvent");var i=function(e){r.call(t,e)},o="on"+e;t.attachEvent(o,i),x.a.I.za(t,function(){t.detachEvent(o,i)})}else t.addEventListener(e,r,!1);else g||(g="function"==typeof f(t).on?"on":"bind"),f(t)[g](e,r)},Fb:function(t,e){if(!t||!t.nodeType)throw Error("element must be a DOM node when calling triggerEvent");var n;if(n=!("input"!==x.a.P(t)||!t.type||"click"!=e.toLowerCase())&&("checkbox"==(n=t.type)||"radio"==n),x.options.useOnlyNativeEvents||!f||n)if("function"==typeof u.createEvent){if("function"!=typeof t.dispatchEvent)throw Error("The supplied element doesn't support dispatchEvent");(n=u.createEvent(p[e]||"HTMLEvents")).initEvent(e,!0,!0,s,0,0,0,0,0,!1,!1,!1,!1,0,t),t.dispatchEvent(n)}else if(n&&t.click)t.click();else{if(void 0===t.fireEvent)throw Error("Browser doesn't support triggering events");t.fireEvent("on"+e)}else f(t).trigger(e)},c:function(t){return x.N(t)?t():t},$b:function(t){return x.N(t)?t.w():t},Eb:function(t,e,n){var i;e&&("object"==typeof t.classList?(i=t.classList[n?"add":"remove"],x.a.C(e.match(y),function(e){i.call(t.classList,e)})):"string"==typeof t.className.baseVal?r(t.className,"baseVal",e,n):r(t,"className",e,n))},Ab:function(t,e){var n=x.a.c(e);null!==n&&n!==a||(n="");var r=x.h.firstChild(t);!r||3!=r.nodeType||x.h.nextSibling(r)?x.h.ua(t,[t.ownerDocument.createTextNode(n)]):r.data=n,x.a.zd(t)},Xc:function(t,e){if(t.name=e,7>=m)try{var n=t.name.replace(/[&<>'"]/g,function(t){return"&#"+t.charCodeAt(0)+";"});t.mergeAttributes(u.createElement("<input name='"+n+"'/>"),!1)}catch(t){}},zd:function(t){9<=m&&(t=1==t.nodeType?t:t.parentNode).style&&(t.style.zoom=t.style.zoom)},vd:function(t){if(m){var e=t.style.width;t.style.width=0,t.style.width=e}},Od:function(t,e){t=x.a.c(t),e=x.a.c(e);for(var n=[],r=t;r<=e;r++)n.push(r);return n},la:function(t){for(var e=[],n=0,r=t.length;n<r;n++)e.push(t[n]);return e},Da:function(t){return l?Symbol(t):t},Xd:6===m,Yd:7===m,W:m,Kc:function(t,e){for(var n=x.a.la(t.getElementsByTagName("input")).concat(x.a.la(t.getElementsByTagName("textarea"))),r="string"==typeof e?function(t){return t.name===e}:function(t){return e.test(t.name)},i=[],o=n.length-1;0<=o;o--)r(n[o])&&i.push(n[o]);return i},Md:function(t){return"string"==typeof t&&(t=x.a.Cb(t))?h&&h.parse?h.parse(t):new Function("return "+t)():null},fc:function(t,e,n){if(!h||!h.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 h.stringify(x.a.c(t),e,n)},Nd:function(e,n,r){var i=(r=r||{}).params||{},o=r.includeFields||this.Ic,a=e;if("object"==typeof e&&"form"===x.a.P(e)){a=e.action;for(var s=o.length-1;0<=s;s--)for(var c=x.a.Kc(e,o[s]),f=c.length-1;0<=f;f--)i[c[f].name]=c[f].value}n=x.a.c(n);var h=u.createElement("form");for(var l in h.style.display="none",h.action=a,h.method="post",n)(e=u.createElement("input")).type="hidden",e.name=l,e.value=x.a.fc(x.a.c(n[l])),h.appendChild(e);t(i,function(t,e){var n=u.createElement("input");n.type="hidden",n.name=t,n.value=e,h.appendChild(n)}),u.body.appendChild(h),r.submitter?r.submitter(h):h.submit(),setTimeout(function(){h.parentNode.removeChild(h)},0)}}}(),x.b("utils",x.a),x.b("utils.arrayForEach",x.a.C),x.b("utils.arrayFirst",x.a.Lb),x.b("utils.arrayFilter",x.a.fb),x.b("utils.arrayGetDistinctValues",x.a.vc),x.b("utils.arrayIndexOf",x.a.A),x.b("utils.arrayMap",x.a.Mb),x.b("utils.arrayPushAll",x.a.gb),x.b("utils.arrayRemoveItem",x.a.hb),x.b("utils.cloneNodes",x.a.Ca),x.b("utils.createSymbolOrString",x.a.Da),x.b("utils.extend",x.a.extend),x.b("utils.fieldsIncludedWithJsonPost",x.a.Ic),x.b("utils.getFormFields",x.a.Kc),x.b("utils.objectMap",x.a.Ha),x.b("utils.peekObservable",x.a.$b),x.b("utils.postJson",x.a.Nd),x.b("utils.parseJson",x.a.Md),x.b("utils.registerEventHandler",x.a.H),x.b("utils.stringifyJson",x.a.fc),x.b("utils.range",x.a.Od),x.b("utils.toggleDomNodeCssClass",x.a.Eb),x.b("utils.triggerEvent",x.a.Fb),x.b("utils.unwrapObservable",x.a.c),x.b("utils.objectForEach",x.a.O),x.b("utils.addOrRemoveItem",x.a.Oa),x.b("utils.setTextContent",x.a.Ab),x.b("unwrap",x.a.c),Function.prototype.bind||(Function.prototype.bind=function(t){var e=this;if(1===arguments.length)return function(){return e.apply(t,arguments)};var n=Array.prototype.slice.call(arguments,1);return function(){var r=n.slice(0);return r.push.apply(r,arguments),e.apply(t,r)}}),x.a.g=new function(){var t,e,n=0,r="__ko__"+(new Date).getTime(),i={};return x.a.W?(t=function(t,e){var o=t[r];if(!o||"null"===o||!i[o]){if(!e)return a;o=t[r]="ko"+n++,i[o]={}}return i[o]},e=function(t){var e=t[r];return!!e&&(delete i[e],t[r]=null,!0)}):(t=function(t,e){var n=t[r];return!n&&e&&(n=t[r]={}),n},e=function(t){return!!t[r]&&(delete t[r],!0)}),{get:function(e,n){var r=t(e,!1);return r&&r[n]},set:function(e,n,r){(e=t(e,r!==a))&&(e[n]=r)},Tb:function(e,n,r){return(e=t(e,!0))[n]||(e[n]=r)},clear:e,Z:function(){return n+++r}}},x.b("utils.domData",x.a.g),x.b("utils.domData.clear",x.a.g.clear),x.a.I=new function(){function t(t,e){var n=x.a.g.get(t,r);return n===a&&e&&(n=[],x.a.g.set(t,r,n)),n}function e(e){if(r=t(e,!1))for(var r=r.slice(0),i=0;i<r.length;i++)r[i](e);x.a.g.clear(e),x.a.I.cleanExternalData(e),o[e.nodeType]&&n(e.childNodes,!0)}function n(t,n){for(var r,i=[],o=0;o<t.length;o++)if((!n||8===t[o].nodeType)&&(e(i[i.length]=r=t[o]),t[o]!==r))for(;o--&&-1==x.a.A(i,t[o]););}var r=x.a.g.Z(),i={1:!0,8:!0,9:!0},o={1:!0,9:!0};return{za:function(e,n){if("function"!=typeof n)throw Error("Callback must be a function");t(e,!0).push(n)},xb:function(e,n){var i=t(e,!1);i&&(x.a.hb(i,n),0==i.length&&x.a.g.set(e,r,a))},na:function(t){return i[t.nodeType]&&(e(t),o[t.nodeType]&&n(t.getElementsByTagName("*"))),t},removeNode:function(t){x.na(t),t.parentNode&&t.parentNode.removeChild(t)},cleanExternalData:function(t){f&&"function"==typeof f.cleanData&&f.cleanData([t])}}},x.na=x.a.I.na,x.removeNode=x.a.I.removeNode,x.b("cleanNode",x.na),x.b("removeNode",x.removeNode),x.b("utils.domNodeDisposal",x.a.I),x.b("utils.domNodeDisposal.addDisposeCallback",x.a.I.za),x.b("utils.domNodeDisposal.removeDisposeCallback",x.a.I.xb),p=[0,"",""],y={thead:g=[1,"<table>","</table>"],tbody:g,tfoot:g,tr:[2,"<table><tbody>","</tbody></table>"],td:v=[3,"<table><tbody><tr>","</tr></tbody></table>"],th:v,option:m=[1,"<select multiple='multiple'>","</select>"],optgroup:m},b=8>=x.a.W,x.a.ta=function(t,e){var n;if(f){if(f.parseHTML)n=f.parseHTML(t,e)||[];else if((n=f.clean([t],e))&&n[0]){for(var r=n[0];r.parentNode&&11!==r.parentNode.nodeType;)r=r.parentNode;r.parentNode&&r.parentNode.removeChild(r)}}else{(n=e)||(n=u),r=n.parentWindow||n.defaultView||s;var i,o=x.a.Cb(t).toLowerCase(),a=n.createElement("div");for(i=(o=o.match(/^(?:\x3c!--.*?--\x3e\s*?)*?<([a-z]+)[\s>]/))&&y[o[1]]||p,o=i[0],i="ignored<div>"+i[1]+t+i[2]+"</div>","function"==typeof r.innerShiv?a.appendChild(r.innerShiv(i)):(b&&n.body.appendChild(a),a.innerHTML=i,b&&a.parentNode.removeChild(a));o--;)a=a.lastChild;n=x.a.la(a.lastChild.childNodes)}return n},x.a.Ld=function(t,e){var n=x.a.ta(t,e);return n.length&&n[0].parentElement||x.a.Xb(n)},x.a.dc=function(t,e){if(x.a.Sb(t),null!==(e=x.a.c(e))&&e!==a)if("string"!=typeof e&&(e=e.toString()),f)f(t).html(e);else for(var n=x.a.ta(e,t.ownerDocument),r=0;r<n.length;r++)t.appendChild(n[r])},x.b("utils.parseHtmlFragment",x.a.ta),x.b("utils.setHtml",x.a.dc),x.aa=function(){var t={};return{Wb:function(e){if("function"!=typeof e)throw Error("You can only pass a function to ko.memoization.memoize()");var n=(4294967296*(1+Math.random())|0).toString(16).substring(1)+(4294967296*(1+Math.random())|0).toString(16).substring(1);return t[n]=e,"\x3c!--[ko_memo:"+n+"]--\x3e"},ad:function(e,n){var r=t[e];if(r===a)throw Error("Couldn't find any memo with ID "+e+". Perhaps it's already been unmemoized.");try{return r.apply(null,n||[]),!0}finally{delete t[e]}},bd:function(t,e){var n=[];!function t(e,n){if(e)if(8==e.nodeType)null!=(r=x.aa.Tc(e.nodeValue))&&n.push({sd:e,Jd:r});else if(1==e.nodeType)for(var r=0,i=e.childNodes,o=i.length;r<o;r++)t(i[r],n)}(t,n);for(var r=0,i=n.length;r<i;r++){var o=n[r].sd,a=[o];e&&x.a.gb(a,e),x.aa.ad(n[r].Jd,a),o.nodeValue="",o.parentNode&&o.parentNode.removeChild(o)}},Tc:function(t){return(t=t.match(/^\[ko_memo\:(.*?)\]$/))?t[1]:null}}}(),x.b("memoization",x.aa),x.b("memoization.memoize",x.aa.Wb),x.b("memoization.unmemoize",x.aa.ad),x.b("memoization.parseMemoText",x.aa.Tc),x.b("memoization.unmemoizeDomNodeAndDescendants",x.aa.bd),x.ma=function(){function t(){if(r)for(var t,e=r,i=0;o<r;)if(t=n[o++]){if(o>e){if(5e3<=++i){o=r,x.a.Fc(Error("'Too much recursion' after processing "+i+" task groups."));break}e=r}try{t()}catch(t){x.a.Fc(t)}}}function e(){t(),o=r=n.length=0}var n=[],r=0,i=1,o=0;return{scheduler:s.MutationObserver?function(t){var e=u.createElement("div");return new MutationObserver(t).observe(e,{attributes:!0}),function(){e.classList.toggle("foo")}}(e):u&&"onreadystatechange"in u.createElement("script")?function(t){var e=u.createElement("script");e.onreadystatechange=function(){e.onreadystatechange=null,u.documentElement.removeChild(e),e=null,t()},u.documentElement.appendChild(e)}:function(t){setTimeout(t,0)},yb:function(t){return r||x.ma.scheduler(e),n[r++]=t,i++},cancel:function(t){(t-=i-r)>=o&&t<r&&(n[t]=null)},resetForTesting:function(){var t=r-o;return o=r=n.length=0,t},Rd:t}}(),x.b("tasks",x.ma),x.b("tasks.schedule",x.ma.yb),x.b("tasks.runEarly",x.ma.Rd),x.Ta={throttle:function(t,e){t.throttleEvaluation=e;var n=null;return x.$({read:t,write:function(r){clearTimeout(n),n=x.a.setTimeout(function(){t(r)},e)}})},rateLimit:function(t,e){var n,o,a;"number"==typeof e?n=e:(n=e.timeout,o=e.method),t.Hb=!1,a="function"==typeof o?o:"notifyWhenChangesStop"==o?i:r,t.tb(function(t){return a(t,n,e)})},deferred:function(t,e){if(!0!==e)throw Error("The 'deferred' extender only accepts the value 'true', because it is not supported to turn deferral off once enabled.");t.Hb||(t.Hb=!0,t.tb(function(e){var n,r=!1;return function(){if(!r){x.ma.cancel(n),n=x.ma.yb(e);try{r=!0,t.notifySubscribers(a,"dirty")}finally{r=!1}}}}))},notify:function(t,e){t.equalityComparer="always"==e?null:n}};var A={undefined:1,boolean:1,number:1,string:1};x.b("extenders",x.Ta),x.gc=function(t,e,n){this.da=t,this.kc=e,this.lc=n,this.Ib=!1,this.ab=this.Jb=null,x.J(this,"dispose",this.s),x.J(this,"disposeWhenNodeIsRemoved",this.l)},x.gc.prototype.s=function(){this.Ib||(this.ab&&x.a.I.xb(this.Jb,this.ab),this.Ib=!0,this.lc(),this.da=this.kc=this.lc=this.Jb=this.ab=null)},x.gc.prototype.l=function(t){this.Jb=t,x.a.I.za(t,this.ab=this.s.bind(this))},x.R=function(){x.a.zb(this,w),w.ob(this)};var w={ob:function(t){t.S={change:[]},t.rc=1},subscribe:function(t,e,n){var r=this;n=n||"change";var i=new x.gc(r,e?t.bind(e):t,function(){x.a.hb(r.S[n],i),r.cb&&r.cb(n)});return r.Qa&&r.Qa(n),r.S[n]||(r.S[n]=[]),r.S[n].push(i),i},notifySubscribers:function(t,e){if("change"===(e=e||"change")&&this.Gb(),this.Wa(e)){var n="change"===e&&this.dd||this.S[e].slice(0);try{x.v.wc();for(var r,i=0;r=n[i];++i)r.Ib||r.kc(t)}finally{x.v.end()}}},mb:function(){return this.rc},Cd:function(t){return this.mb()!==t},Gb:function(){++this.rc},tb:function(t){var e,n,r,i,a,s=this,u=x.N(s);s.bb||(s.bb=s.notifySubscribers,s.notifySubscribers=o);var c=t(function(){s.Ka=!1,u&&i===s&&(i=s.mc?s.mc():s());var t=n||a&&s.qb(r,i);a=n=e=!1,t&&s.bb(r=i)});s.pc=function(t,n){n&&s.Ka||(a=!n),s.dd=s.S.change.slice(0),s.Ka=e=!0,i=t,c()},s.oc=function(t){e||(r=t,s.bb(t,"beforeChange"))},s.qc=function(){a=!0},s.fd=function(){s.qb(r,s.w(!0))&&(n=!0)}},Wa:function(t){return this.S[t]&&this.S[t].length},Ad:function(t){if(t)return this.S[t]&&this.S[t].length||0;var e=0;return x.a.O(this.S,function(t,n){"dirty"!==t&&(e+=n.length)}),e},qb:function(t,e){return!this.equalityComparer||!this.equalityComparer(t,e)},toString:function(){return"[object Object]"},extend:function(t){var e=this;return t&&x.a.O(t,function(t,n){var r=x.Ta[t];"function"==typeof r&&(e=r(e,n)||e)}),e}};x.J(w,"init",w.ob),x.J(w,"subscribe",w.subscribe),x.J(w,"extend",w.extend),x.J(w,"getSubscriptionsCount",w.Ad),x.a.Ba&&x.a.setPrototypeOf(w,Function.prototype),x.R.fn=w,x.Pc=function(t){return null!=t&&"function"==typeof t.subscribe&&"function"==typeof t.notifySubscribers},x.b("subscribable",x.R),x.b("isSubscribable",x.Pc),x.U=x.v=function(){function t(t){r.push(n),n=t}function e(){n=r.pop()}var n,r=[],i=0;return{wc:t,end:e,ac:function(t){if(n){if(!x.Pc(t))throw Error("Only subscribable things can act as dependencies");n.nd.call(n.od,t,t.ed||(t.ed=++i))}},K:function(n,r,i){try{return t(),n.apply(r,i||[])}finally{e()}},pa:function(){if(n)return n.o.pa()},Va:function(){if(n)return n.o.Va()},rb:function(){if(n)return n.rb},o:function(){if(n)return n.o}}}(),x.b("computedContext",x.U),x.b("computedContext.getDependenciesCount",x.U.pa),x.b("computedContext.getDependencies",x.U.Va),x.b("computedContext.isInitial",x.U.rb),x.b("computedContext.registerDependency",x.U.ac),x.b("ignoreDependencies",x.Wd=x.v.K);var _=x.a.Da("_latestValue");x.sa=function(t){function e(){return 0<arguments.length?(e.qb(e[_],arguments[0])&&(e.xa(),e[_]=arguments[0],e.wa()),this):(x.v.ac(e),e[_])}return e[_]=t,x.a.Ba||x.a.extend(e,x.R.fn),x.R.fn.ob(e),x.a.zb(e,E),x.options.deferUpdates&&x.Ta.deferred(e,!0),e};var E={equalityComparer:n,w:function(){return this[_]},wa:function(){this.notifySubscribers(this[_],"spectate"),this.notifySubscribers(this[_])},xa:function(){this.notifySubscribers(this[_],"beforeChange")}};x.a.Ba&&x.a.setPrototypeOf(E,x.R.fn);var M=x.sa.Na="__ko_proto__";E[M]=x.sa,x.N=function(t){if((t="function"==typeof t&&t[M])&&t!==E[M]&&t!==x.o.fn[M])throw Error("Invalid object that looks like an observable; possibly from another Knockout instance");return!!t},x.Ya=function(t){return"function"==typeof t&&(t[M]===E[M]||t[M]===x.o.fn[M]&&t.Mc)},x.b("observable",x.sa),x.b("isObservable",x.N),x.b("isWriteableObservable",x.Ya),x.b("isWritableObservable",x.Ya),x.b("observable.fn",E),x.J(E,"peek",E.w),x.J(E,"valueHasMutated",E.wa),x.J(E,"valueWillMutate",E.xa),x.Ia=function(t){if("object"!=typeof(t=t||[])||!("length"in t))throw Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");return t=x.sa(t),x.a.zb(t,x.Ia.fn),t.extend({trackArrayChanges:!0})},x.Ia.fn={remove:function(t){for(var e=this.w(),n=[],r="function"!=typeof t||x.N(t)?function(e){return e===t}:t,i=0;i<e.length;i++){var o=e[i];if(r(o)){if(0===n.length&&this.xa(),e[i]!==o)throw Error("Array modified during remove; cannot remove item");n.push(o),e.splice(i,1),i--}}return n.length&&this.wa(),n},removeAll:function(t){if(t===a){var e=this.w(),n=e.slice(0);return this.xa(),e.splice(0,e.length),this.wa(),n}return t?this.remove(function(e){return 0<=x.a.A(t,e)}):[]},destroy:function(t){var e=this.w(),n="function"!=typeof t||x.N(t)?function(e){return e===t}:t;this.xa();for(var r=e.length-1;0<=r;r--){var i=e[r];n(i)&&(i._destroy=!0)}this.wa()},destroyAll:function(t){return t===a?this.destroy(function(){return!0}):t?this.destroy(function(e){return 0<=x.a.A(t,e)}):[]},indexOf:function(t){var e=this();return x.a.A(e,t)},replace:function(t,e){var n=this.indexOf(t);0<=n&&(this.xa(),this.w()[n]=e,this.wa())},sorted:function(t){var e=this().slice(0);return t?e.sort(t):e.sort()},reversed:function(){return this().slice(0).reverse()}},x.a.Ba&&x.a.setPrototypeOf(x.Ia.fn,x.sa.fn),x.a.C("pop push reverse shift sort splice unshift".split(" "),function(t){x.Ia.fn[t]=function(){var e=this.w();this.xa(),this.yc(e,t,arguments);var n=e[t].apply(e,arguments);return this.wa(),n===e?this:n}}),x.a.C(["slice"],function(t){x.Ia.fn[t]=function(){var e=this();return e[t].apply(e,arguments)}}),x.Oc=function(t){return x.N(t)&&"function"==typeof t.remove&&"function"==typeof t.push},x.b("observableArray",x.Ia),x.b("isObservableArray",x.Oc),x.Ta.trackArrayChanges=function(t,e){function n(){function e(){if(c){var e,n=[].concat(t.w()||[]);t.Wa("arrayChange")&&((!u||1<c)&&(u=x.a.Ob(i,n,t.Nb)),e=u),i=n,u=null,c=0,e&&e.length&&t.notifySubscribers(e,"arrayChange")}}s?e():(s=!0,o=t.notifySubscribers,t.notifySubscribers=function(t,e){return e&&"change"!==e||++c,o.apply(this,arguments)},i=[].concat(t.w()||[]),u=null,r=t.subscribe(e))}if(t.Nb={},e&&"object"==typeof e&&x.a.extend(t.Nb,e),t.Nb.sparse=!0,!t.yc){var r,i,o,s=!1,u=null,c=0,f=t.Qa,h=t.cb;t.Qa=function(e){f&&f.call(t,e),"arrayChange"===e&&n()},t.cb=function(e){h&&h.call(t,e),"arrayChange"!==e||t.Wa("arrayChange")||(o&&(t.notifySubscribers=o,o=a),r&&r.s(),r=null,s=!1,i=a)},t.yc=function(t,e,n){function r(t,e,n){return i[i.length]={status:t,value:e,index:n}}if(s&&!c){var i=[],o=t.length,a=n.length,f=0;switch(e){case"push":f=o;case"unshift":for(e=0;e<a;e++)r("added",n[e],f+e);break;case"pop":f=o-1;case"shift":o&&r("deleted",t[f],f);break;case"splice":e=Math.min(Math.max(0,0>n[0]?o+n[0]:n[0]),o),o=1===a?o:Math.min(e+(n[1]||0),o),a=e+a-2,f=Math.max(o,a);for(var h=[],l=[],d=2;e<f;++e,++d)e<o&&l.push(r("deleted",t[e],e)),e<a&&h.push(r("added",n[d],e));x.a.Jc(l,h);break;default:return}u=i}}}};var C=x.a.Da("_state");x.o=x.$=function(t,e,n){function r(){if(0<arguments.length){if("function"!=typeof i)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 i.apply(o.lb,arguments),this}return o.qa||x.v.ac(r),(o.ka||o.G&&r.Xa())&&r.ha(),o.X}if("object"==typeof t?n=t:(n=n||{},t&&(n.read=t)),"function"!=typeof n.read)throw Error("Pass a function that returns the value of the ko.computed");var i=n.write,o={X:a,ra:!0,ka:!0,pb:!1,hc:!1,qa:!1,vb:!1,G:!1,Vc:n.read,lb:e||n.owner,l:n.disposeWhenNodeIsRemoved||n.l||null,Sa:n.disposeWhen||n.Sa,Qb:null,F:{},V:0,Hc:null};return r[C]=o,r.Mc="function"==typeof i,x.a.Ba||x.a.extend(r,x.R.fn),x.R.fn.ob(r),x.a.zb(r,S),n.pure?(o.vb=!0,o.G=!0,x.a.extend(r,k)):n.deferEvaluation&&x.a.extend(r,O),x.options.deferUpdates&&x.Ta.deferred(r,!0),o.l&&(o.hc=!0,o.l.nodeType||(o.l=null)),o.G||n.deferEvaluation||r.ha(),o.l&&r.ja()&&x.a.I.za(o.l,o.Qb=function(){r.s()}),r};var S={equalityComparer:n,pa:function(){return this[C].V},Va:function(){var t=[];return x.a.O(this[C].F,function(e,n){t[n.La]=n.da}),t},Ub:function(t){if(!this[C].V)return!1;var e=this.Va();return-1!==x.a.A(e,t)||!!x.a.Lb(e,function(e){return e.Ub&&e.Ub(t)})},tc:function(t,e,n){if(this[C].vb&&e===this)throw Error("A 'pure' computed must not be called recursively");this[C].F[t]=n,n.La=this[C].V++,n.Ma=e.mb()},Xa:function(){var t,e,n=this[C].F;for(t in n)if(Object.prototype.hasOwnProperty.call(n,t)&&(e=n[t],this.Ja&&e.da.Ka||e.da.Cd(e.Ma)))return!0},Id:function(){this.Ja&&!this[C].pb&&this.Ja(!1)},ja:function(){var t=this[C];return t.ka||0<t.V},Qd:function(){this.Ka?this[C].ka&&(this[C].ra=!0):this.Gc()},Zc:function(t){if(t.Hb){var e=t.subscribe(this.Id,this,"dirty"),n=t.subscribe(this.Qd,this);return{da:t,s:function(){e.s(),n.s()}}}return t.subscribe(this.Gc,this)},Gc:function(){var t=this,e=t.throttleEvaluation;e&&0<=e?(clearTimeout(this[C].Hc),this[C].Hc=x.a.setTimeout(function(){t.ha(!0)},e)):t.Ja?t.Ja(!0):t.ha(!0)},ha:function(t){var e=this[C],n=e.Sa,r=!1;if(!e.pb&&!e.qa){if(e.l&&!x.a.Rb(e.l)||n&&n()){if(!e.hc)return void this.s()}else e.hc=!1;e.pb=!0;try{r=this.yd(t)}finally{e.pb=!1}return r}},yd:function(t){var e=this[C],n=!1,r=e.vb?a:!e.V;n={pd:this,kb:e.F,Pb:e.V},x.v.wc({od:n,nd:d,o:this,rb:r}),e.F={},e.V=0;var i=this.xd(e,n);return e.V?n=this.qb(e.X,i):(this.s(),n=!0),n&&(e.G?this.Gb():this.notifySubscribers(e.X,"beforeChange"),e.X=i,this.notifySubscribers(e.X,"spectate"),!e.G&&t&&this.notifySubscribers(e.X),this.qc&&this.qc()),r&&this.notifySubscribers(e.X,"awake"),n},xd:function(t,e){try{var n=t.Vc;return t.lb?n.call(t.lb):n()}finally{x.v.end(),e.Pb&&!t.G&&x.a.O(e.kb,l),t.ra=t.ka=!1}},w:function(t){var e=this[C];return(e.ka&&(t||!e.V)||e.G&&this.Xa())&&this.ha(),e.X},tb:function(t){x.R.fn.tb.call(this,t),this.mc=function(){return this[C].G||(this[C].ra?this.ha():this[C].ka=!1),this[C].X},this.Ja=function(t){this.oc(this[C].X),this[C].ka=!0,t&&(this[C].ra=!0),this.pc(this,!t)}},s:function(){var t=this[C];!t.G&&t.F&&x.a.O(t.F,function(t,e){e.s&&e.s()}),t.l&&t.Qb&&x.a.I.xb(t.l,t.Qb),t.F=a,t.V=0,t.qa=!0,t.ra=!1,t.ka=!1,t.G=!1,t.l=a,t.Sa=a,t.Vc=a,this.Mc||(t.lb=a)}},k={Qa:function(t){var e=this,n=e[C];if(!n.qa&&n.G&&"change"==t){if(n.G=!1,n.ra||e.Xa())n.F=null,n.V=0,e.ha()&&e.Gb();else{var r=[];x.a.O(n.F,function(t,e){r[e.La]=t}),x.a.C(r,function(t,r){var i=n.F[t],o=e.Zc(i.da);o.La=r,o.Ma=i.Ma,n.F[t]=o}),e.Xa()&&e.ha()&&e.Gb()}n.qa||e.notifySubscribers(n.X,"awake")}},cb:function(t){var e=this[C];e.qa||"change"!=t||this.Wa("change")||(x.a.O(e.F,function(t,n){n.s&&(e.F[t]={da:n.da,La:n.La,Ma:n.Ma},n.s())}),e.G=!0,this.notifySubscribers(a,"asleep"))},mb:function(){var t=this[C];return t.G&&(t.ra||this.Xa())&&this.ha(),x.R.fn.mb.call(this)}},O={Qa:function(t){"change"!=t&&"beforeChange"!=t||this.w()}};x.a.Ba&&x.a.setPrototypeOf(S,x.R.fn);var P=x.sa.Na;S[P]=x.o,x.Nc=function(t){return"function"==typeof t&&t[P]===S[P]},x.Ed=function(t){return x.Nc(t)&&t[C]&&t[C].vb},x.b("computed",x.o),x.b("dependentObservable",x.o),x.b("isComputed",x.Nc),x.b("isPureComputed",x.Ed),x.b("computed.fn",S),x.J(S,"peek",S.w),x.J(S,"dispose",S.s),x.J(S,"isActive",S.ja),x.J(S,"getDependenciesCount",S.pa),x.J(S,"getDependencies",S.Va),x.wb=function(t,e){return"function"==typeof t?x.o(t,e,{pure:!0}):((t=x.a.extend({},t)).pure=!0,x.o(t,e))},x.b("pureComputed",x.wb),function(){function t(n,r,i){if(i=i||new e,"object"!=typeof(n=r(n))||null===n||n===a||n instanceof RegExp||n instanceof Date||n instanceof String||n instanceof Number||n instanceof Boolean)return n;var o=n instanceof Array?[]:{};return i.save(n,o),function(t,e){if(t instanceof Array){for(var n=0;n<t.length;n++)e(n);"function"==typeof t.toJSON&&e("toJSON")}else for(n in t)e(n)}(n,function(e){var s=r(n[e]);switch(typeof s){case"boolean":case"number":case"string":case"function":o[e]=s;break;case"object":case"undefined":var u=i.get(s);o[e]=u!==a?u:t(s,r,i)}}),o}function e(){this.keys=[],this.values=[]}x.$c=function(e){if(0==arguments.length)throw Error("When calling ko.toJS, pass the object you want to convert.");return t(e,function(t){for(var e=0;x.N(t)&&10>e;e++)t=t();return t})},x.toJSON=function(t,e,n){return t=x.$c(t),x.a.fc(t,e,n)},e.prototype={constructor:e,save:function(t,e){var n=x.a.A(this.keys,t);0<=n?this.values[n]=e:(this.keys.push(t),this.values.push(e))},get:function(t){return 0<=(t=x.a.A(this.keys,t))?this.values[t]:a}}}(),x.b("toJS",x.$c),x.b("toJSON",x.toJSON),x.Vd=function(t,e,n){function r(e){var r=x.wb(t,n).extend({Ga:"always"}),i=r.subscribe(function(t){t&&(i.s(),e(t))});return r.notifySubscribers(r.w()),i}return"function"!=typeof Promise||e?r(e.bind(n)):new Promise(r)},x.b("when",x.Vd),x.u={L:function(t){switch(x.a.P(t)){case"option":return!0===t.__ko__hasDomDataOptionValue__?x.a.g.get(t,x.f.options.Yb):7>=x.a.W?t.getAttributeNode("value")&&t.getAttributeNode("value").specified?t.value:t.text:t.value;case"select":return 0<=t.selectedIndex?x.u.L(t.options[t.selectedIndex]):a;default:return t.value}},ya:function(t,e,n){switch(x.a.P(t)){case"option":"string"==typeof e?(x.a.g.set(t,x.f.options.Yb,a),"__ko__hasDomDataOptionValue__"in t&&delete t.__ko__hasDomDataOptionValue__,t.value=e):(x.a.g.set(t,x.f.options.Yb,e),t.__ko__hasDomDataOptionValue__=!0,t.value="number"==typeof e?e:"");break;case"select":""!==e&&null!==e||(e=a);for(var r,i=-1,o=0,s=t.options.length;o<s;++o)if((r=x.u.L(t.options[o]))==e||""===r&&e===a){i=o;break}(n||0<=i||e===a&&1<t.size)&&(t.selectedIndex=i,6===x.a.W&&x.a.setTimeout(function(){t.selectedIndex=i},0));break;default:null!==e&&e!==a||(e=""),t.value=e}}},x.b("selectExtensions",x.u),x.b("selectExtensions.readValue",x.u.L),x.b("selectExtensions.writeValue",x.u.ya),x.m=function(){function t(t){123===(t=x.a.Cb(t)).charCodeAt(0)&&(t=t.slice(1,-1));var e,n=[],a=(t+="\n,").match(r),s=[],u=0;if(1<a.length){for(var c,f=0;c=a[f];++f){var h=c.charCodeAt(0);if(44===h){if(0>=u){n.push(e&&s.length?{key:e,value:s.join("")}:{unknown:e||s.join("")}),e=u=0,s=[];continue}}else if(58===h){if(!u&&!e&&1===s.length){e=s.pop();continue}}else{if(47===h&&1<c.length&&(47===c.charCodeAt(1)||42===c.charCodeAt(1)))continue;47===h&&f&&1<c.length?(h=a[f-1].match(i))&&!o[h[0]]&&(a=(t=t.substr(t.indexOf(c)+1)).match(r),f=-1,c="/"):40===h||123===h||91===h?++u:41===h||125===h||93===h?--u:e||s.length||34!==h&&39!==h||(c=c.slice(1,-1))}s.push(c)}if(0<u)throw Error("Unbalanced parentheses, braces, or brackets")}return n}var e=["true","false","null","undefined"],n=/^(?:[$_a-z][$\w]*|(.+)(\.\s*[$_a-z][$\w]*|\[.+\]))$/i,r=RegExp("\"(?:\\\\.|[^\"])*\"|'(?:\\\\.|[^'])*'|`(?:\\\\.|[^`])*`|/\\*(?:[^*]|\\*+[^*/])*\\*+/|//.*\n|/(?:\\\\.|[^/])+/w*|[^\\s:,/][^,\"'`{}()/:[\\]]*[^\\s,\"'`{}()/:[\\]]|[^\\s]","g"),i=/[\])"'A-Za-z0-9_$]+$/,o={in:1,return:1,typeof:1},a={};return{Ra:[],va:a,Zb:t,ub:function(r,i){function o(t,r){var i;if(!f){var h=x.getBindingHandler(t);if(h&&h.preprocess&&!(r=h.preprocess(r,t,o)))return;(h=a[t])&&(i=r,0<=x.a.A(e,i)?i=!1:(h=i.match(n),i=null!==h&&(h[1]?"Object("+h[1]+")"+h[2]:i)),h=i),h&&u.push("'"+("string"==typeof a[t]?a[t]:t)+"':function(_z){"+i+"=_z}")}c&&(r="function(){return "+r+" }"),s.push("'"+t+"':"+r)}var s=[],u=[],c=(i=i||{}).valueAccessors,f=i.bindingParams,h="string"==typeof r?t(r):r;return x.a.C(h,function(t){o(t.key||t.unknown,t.value)}),u.length&&o("_ko_property_writers","{"+u.join(",")+" }"),s.join(",")},Hd:function(t,e){for(var n=0;n<t.length;n++)if(t[n].key==e)return!0;return!1},$a:function(t,e,n,r,i){t&&x.N(t)?!x.Ya(t)||i&&t.w()===r||t(r):(t=e.get("_ko_property_writers"))&&t[n]&&t[n](r)}}}(),x.b("expressionRewriting",x.m),x.b("expressionRewriting.bindingRewriteValidators",x.m.Ra),x.b("expressionRewriting.parseObjectLiteral",x.m.Zb),x.b("expressionRewriting.preProcessBindings",x.m.ub),x.b("expressionRewriting._twoWayBindings",x.m.va),x.b("jsonExpressionRewriting",x.m),x.b("jsonExpressionRewriting.insertPropertyAccessorsIntoJson",x.m.ub),function(){function t(t){return 8==t.nodeType&&o.test(i?t.text:t.nodeValue)}function e(t){return 8==t.nodeType&&a.test(i?t.text:t.nodeValue)}function n(n,r){for(var i=n,o=1,a=[];i=i.nextSibling;){if(e(i)&&(x.a.g.set(i,c,!0),0==--o))return a;a.push(i),t(i)&&o++}if(!r)throw Error("Cannot find closing comment tag to match: "+n.nodeValue);return null}function r(t,e){var r=n(t,e);return r?0<r.length?r[r.length-1].nextSibling:t.nextSibling:null}var i=u&&"\x3c!--test--\x3e"===u.createComment("test").text,o=i?/^\x3c!--\s*ko(?:\s+([\s\S]+))?\s*--\x3e$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,a=i?/^\x3c!--\s*\/ko\s*--\x3e$/:/^\s*\/ko\s*$/,s={ul:!0,ol:!0},c="__ko_matchedEndComment__";x.h={ea:{},childNodes:function(e){return t(e)?n(e):e.childNodes},Ea:function(e){if(t(e))for(var n=0,r=(e=x.h.childNodes(e)).length;n<r;n++)x.removeNode(e[n]);else x.a.Sb(e)},ua:function(e,n){if(t(e)){x.h.Ea(e);for(var r=e.nextSibling,i=0,o=n.length;i<o;i++)r.parentNode.insertBefore(n[i],r)}else x.a.ua(e,n)},Uc:function(e,n){t(e)?e.parentNode.insertBefore(n,e.nextSibling):e.firstChild?e.insertBefore(n,e.firstChild):e.appendChild(n)},Vb:function(e,n,r){r?t(e)?e.parentNode.insertBefore(n,r.nextSibling):r.nextSibling?e.insertBefore(n,r.nextSibling):e.appendChild(n):x.h.Uc(e,n)},firstChild:function(n){if(t(n))return!n.nextSibling||e(n.nextSibling)?null:n.nextSibling;if(n.firstChild&&e(n.firstChild))throw Error("Found invalid end comment, as the first child of "+n);return n.firstChild},nextSibling:function(n){if(t(n)&&(n=r(n)),n.nextSibling&&e(n.nextSibling)){var i=n.nextSibling;if(e(i)&&!x.a.g.get(i,c))throw Error("Found end comment without a matching opening comment, as child of "+n);return null}return n.nextSibling},Bd:t,Ud:function(t){return(t=(i?t.text:t.nodeValue).match(o))?t[1]:null},Rc:function(n){if(s[x.a.P(n)]){var i=n.firstChild;if(i)do{if(1===i.nodeType){var o,a=null;if(o=i.firstChild)do{if(a)a.push(o);else if(t(o)){var u=r(o,!0);u?o=u:a=[o]}else e(o)&&(a=[o])}while(o=o.nextSibling);if(o=a)for(a=i.nextSibling,u=0;u<o.length;u++)a?n.insertBefore(o[u],a):n.appendChild(o[u])}}while(i=i.nextSibling)}}}}(),x.b("virtualElements",x.h),x.b("virtualElements.allowedBindings",x.h.ea),x.b("virtualElements.emptyNode",x.h.Ea),x.b("virtualElements.insertAfter",x.h.Vb),x.b("virtualElements.prepend",x.h.Uc),x.b("virtualElements.setDomNodeChildren",x.h.ua),x.ga=function(){this.md={}},x.a.extend(x.ga.prototype,{nodeHasBindings:function(t){switch(t.nodeType){case 1:return null!=t.getAttribute("data-bind")||x.i.getComponentNameForNode(t);case 8:return x.h.Bd(t);default:return!1}},getBindings:function(t,e){var n=(n=this.getBindingsString(t,e))?this.parseBindingsString(n,e,t):null;return x.i.sc(n,t,e,!1)},getBindingAccessors:function(t,e){var n=(n=this.getBindingsString(t,e))?this.parseBindingsString(n,e,t,{valueAccessors:!0}):null;return x.i.sc(n,t,e,!0)},getBindingsString:function(t){switch(t.nodeType){case 1:return t.getAttribute("data-bind");case 8:return x.h.Ud(t);default:return null}},parseBindingsString:function(t,e,n,r){try{var i,o=this.md,a=t+(r&&r.valueAccessors||"");if(!(i=o[a])){var s,u="with($context){with($data||{}){return{"+x.m.ub(t,r)+"}}}";s=new Function("$context","$element",u),i=o[a]=s}return i(e,n)}catch(e){throw e.message="Unable to parse bindings.\nBindings value: "+t+"\nMessage: "+e.message,e}}}),x.ga.instance=new x.ga,x.b("bindingProvider",x.ga),function(){function t(t){var e=(t=x.a.g.get(t,A))&&t.M;e&&(t.M=null,e.Sc())}function e(e,n,r){this.node=e,this.xc=n,this.ib=[],this.T=!1,n.M||x.a.I.za(e,t),r&&r.M&&(r.M.ib.push(e),this.Kb=r)}function n(t){return function(){return t}}function r(t){return t()}function i(t){return x.a.Ha(x.v.K(t),function(e,n){return function(){return t()[n]}})}function o(t,e,r){return"function"==typeof t?i(t.bind(null,e,r)):x.a.Ha(t,n)}function c(t,e){return i(this.getBindings.bind(this,t,e))}function h(t,e){var n=x.h.firstChild(e);if(n){var r,i=x.ga.instance,o=i.preprocessNode;if(o){for(;r=n;)n=x.h.nextSibling(r),o.call(i,r);n=x.h.firstChild(e)}for(;r=n;)n=x.h.nextSibling(r),l(t,r)}x.j.Ga(e,x.j.T)}function l(t,e){var n=t,r=1===e.nodeType;r&&x.h.Rc(e),(r||x.ga.instance.nodeHasBindings(e))&&(n=d(e,null,t).bindingContextForDescendants),n&&!y[x.a.P(e)]&&h(n,e)}function d(t,e,n){var i,o=x.a.g.Tb(t,A,{}),s=o.gd;if(!e){if(s)throw Error("You cannot apply bindings multiple times to the same element.");o.gd=!0}if(s||(o.context=n),e&&"function"!=typeof e)i=e;else{var u=x.ga.instance,f=u.getBindingAccessors||c,h=x.$(function(){return(i=e?e(n,t):f.call(u,t,n))&&(n[g]&&n[g](),n[m]&&n[m]()),i},null,{l:t});i&&h.ja()||(h=null)}var l,d=n;if(i){var p=function(){return x.a.Ha(h?h():i,r)},v=h?function(t){return function(){return r(h()[t])}}:function(t){return i[t]};p.get=function(t){return i[t]&&r(v(t))},p.has=function(t){return t in i},x.j.T in i&&x.j.subscribe(t,x.j.T,function(){var e=(0,i[x.j.T])();if(e){var n=x.h.childNodes(t);n.length&&e(n,x.Dc(n[0]))}}),x.j.oa in i&&(d=x.j.Bb(t,n),x.j.subscribe(t,x.j.oa,function(){var e=(0,i[x.j.oa])();e&&x.h.firstChild(t)&&e(t)})),o=function(t){var e=[],n={},r=[];return x.a.O(t,function i(o){if(!n[o]){var a=x.getBindingHandler(o);a&&(a.after&&(r.push(o),x.a.C(a.after,function(e){if(t[e]){if(-1!==x.a.A(r,e))throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+r.join(", "));i(e)}}),r.length--),e.push({key:o,Lc:a})),n[o]=!0}}),e}(i),x.a.C(o,function(e){var n=e.Lc.init,r=e.Lc.update,o=e.key;if(8===t.nodeType&&!x.h.ea[o])throw Error("The binding '"+o+"' cannot be used with virtual elements");try{"function"==typeof n&&x.v.K(function(){var e=n(t,v(o),p,d.$data,d);if(e&&e.controlsDescendantBindings){if(l!==a)throw Error("Multiple bindings ("+l+" and "+o+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");l=o}}),"function"==typeof r&&x.$(function(){r(t,v(o),p,d.$data,d)},null,{l:t})}catch(t){throw t.message='Unable to process binding "'+o+": "+i[o]+'"\nMessage: '+t.message,t}})}return{shouldBindDescendants:o=l===a,bindingContextForDescendants:o&&d}}function p(t,e){return t&&t instanceof x.fa?t:new x.fa(t,a,a,e)}var g=x.a.Da("_subscribable"),v=x.a.Da("_ancestorBindingInfo"),m=x.a.Da("_dataDependency");x.f={};var y={script:!0,textarea:!0,template:!0};x.getBindingHandler=function(t){return x.f[t]};var b={};x.fa=function(t,e,n,r,i){function o(){var t=h?f():f,i=x.a.c(t);return e?(x.a.extend(u,e),v in e&&(u[v]=e[v])):(u.$parents=[],u.$root=i,u.ko=x),u[g]=s,c?i=u.$data:(u.$rawData=t,u.$data=i),n&&(u[n]=i),r&&r(u,e,i),e&&e[g]&&!x.U.o().Ub(e[g])&&e[g](),l&&(u[m]=l),u.$data}var s,u=this,c=t===b,f=c?a:t,h="function"==typeof f&&!x.N(f),l=i&&i.dataDependency;i&&i.exportDependencies?o():((s=x.wb(o)).w(),s.ja()?s.equalityComparer=null:u[g]=a)},x.fa.prototype.createChildContext=function(t,e,n,r){if(!r&&e&&"object"==typeof e&&(e=(r=e).as,n=r.extend),e&&r&&r.noChildContext){var i="function"==typeof t&&!x.N(t);return new x.fa(b,this,null,function(r){n&&n(r),r[e]=i?t():t},r)}return new x.fa(t,this,e,function(t,e){t.$parentContext=e,t.$parent=e.$data,t.$parents=(e.$parents||[]).slice(0),t.$parents.unshift(t.$parent),n&&n(t)},r)},x.fa.prototype.extend=function(t,e){return new x.fa(b,this,null,function(e){x.a.extend(e,"function"==typeof t?t(e):t)},e)};var A=x.a.g.Z();e.prototype.Sc=function(){this.Kb&&this.Kb.M&&this.Kb.M.rd(this.node)},e.prototype.rd=function(t){x.a.hb(this.ib,t),!this.ib.length&&this.T&&this.Bc()},e.prototype.Bc=function(){this.T=!0,this.xc.M&&!this.ib.length&&(this.xc.M=null,x.a.I.xb(this.node,t),x.j.Ga(this.node,x.j.oa),this.Sc())},x.j={T:"childrenComplete",oa:"descendantsComplete",subscribe:function(t,e,n,r){return(t=x.a.g.Tb(t,A,{})).Fa||(t.Fa=new x.R),t.Fa.subscribe(n,r,e)},Ga:function(t,e){var n=x.a.g.get(t,A);if(n&&(n.Fa&&n.Fa.notifySubscribers(t,e),e==x.j.T))if(n.M)n.M.Bc();else if(n.M===a&&n.Fa&&n.Fa.Wa(x.j.oa))throw Error("descendantsComplete event not supported for bindings on this node")},Bb:function(t,n){var r=x.a.g.Tb(t,A,{});return r.M||(r.M=new e(t,r,n[v])),n[v]==r?n:n.extend(function(t){t[v]=r})}},x.Sd=function(t){return(t=x.a.g.get(t,A))&&t.context},x.eb=function(t,e,n){return 1===t.nodeType&&x.h.Rc(t),d(t,e,p(n))},x.kd=function(t,e,n){return n=p(n),x.eb(t,o(e,n,t),n)},x.Pa=function(t,e){1!==e.nodeType&&8!==e.nodeType||h(p(t),e)},x.uc=function(t,e,n){if(!f&&s.jQuery&&(f=s.jQuery),2>arguments.length){if(!(e=u.body))throw Error("ko.applyBindings: could not find document.body; has the document been loaded?")}else if(!e||1!==e.nodeType&&8!==e.nodeType)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");l(p(t,n),e)},x.Cc=function(t){return!t||1!==t.nodeType&&8!==t.nodeType?a:x.Sd(t)},x.Dc=function(t){return(t=x.Cc(t))?t.$data:a},x.b("bindingHandlers",x.f),x.b("bindingEvent",x.j),x.b("bindingEvent.subscribe",x.j.subscribe),x.b("bindingEvent.startPossiblyAsyncContentBinding",x.j.Bb),x.b("applyBindings",x.uc),x.b("applyBindingsToDescendants",x.Pa),x.b("applyBindingAccessorsToNode",x.eb),x.b("applyBindingsToNode",x.kd),x.b("contextFor",x.Cc),x.b("dataFor",x.Dc)}(),function(t){function e(e,r){var a,s=Object.prototype.hasOwnProperty.call(i,e)?i[e]:t;s?s.subscribe(r):((s=i[e]=new x.R).subscribe(r),n(e,function(t,n){var r=!(!n||!n.synchronous);o[e]={definition:t,Fd:r},delete i[e],a||r?s.notifySubscribers(t):x.ma.yb(function(){s.notifySubscribers(t)})}),a=!0)}function n(t,e){r("getConfig",[t],function(n){n?r("loadComponent",[t,n],function(t){e(t,n)}):e(null,null)})}function r(e,n,i,o){o||(o=x.i.loaders.slice(0));var a=o.shift();if(a){var s=a[e];if(s){var u=!1;if(s.apply(a,n.concat(function(t){u?i(null):null!==t?i(t):r(e,n,i,o)}))!==t&&(u=!0,!a.suppressLoaderExceptions))throw Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.")}else r(e,n,i,o)}else i(null)}var i={},o={};x.i={get:function(n,r){var i=Object.prototype.hasOwnProperty.call(o,n)?o[n]:t;i?i.Fd?x.v.K(function(){r(i.definition)}):x.ma.yb(function(){r(i.definition)}):e(n,r)},Ac:function(t){delete o[t]},nc:r},x.i.loaders=[],x.b("components",x.i),x.b("components.get",x.i.get),x.b("components.clearCachedDefinition",x.i.Ac)}(),function(){function t(t,e,n,r){function o(){0==--s&&r(a)}var a={},s=2,u=n.template;n=n.viewModel,u?i(e,u,function(e){x.i.nc("loadTemplate",[t,e],function(t){a.template=t,o()})}):o(),n?i(e,n,function(e){x.i.nc("loadViewModel",[t,e],function(t){a[c]=t,o()})}):o()}function n(t){switch(x.a.P(t)){case"script":return x.a.ta(t.text);case"textarea":return x.a.ta(t.value);case"template":if(r(t.content))return x.a.Ca(t.content.childNodes)}return x.a.Ca(t.childNodes)}function r(t){return s.DocumentFragment?t instanceof DocumentFragment:t&&11===t.nodeType}function i(t,n,r){"string"==typeof n.require?e||s.require?(e||s.require)([n.require],r):t("Uses require, but no AMD loader is present"):r(n)}function o(t){return function(e){throw Error("Component '"+t+"': "+e)}}var a={};x.i.register=function(t,e){if(!e)throw Error("Invalid configuration for "+t);if(x.i.sb(t))throw Error("Component "+t+" is already registered");a[t]=e},x.i.sb=function(t){return Object.prototype.hasOwnProperty.call(a,t)},x.i.unregister=function(t){delete a[t],x.i.Ac(t)},x.i.Ec={getConfig:function(t,e){e(x.i.sb(t)?a[t]:null)},loadComponent:function(e,n,r){var a=o(e);i(a,n,function(n){t(e,a,n,r)})},loadTemplate:function(t,e,i){if(t=o(t),"string"==typeof e)i(x.a.ta(e));else if(e instanceof Array)i(e);else if(r(e))i(x.a.la(e.childNodes));else if(e.element)if(e=e.element,s.HTMLElement?e instanceof HTMLElement:e&&e.tagName&&1===e.nodeType)i(n(e));else if("string"==typeof e){var a=u.getElementById(e);a?i(n(a)):t("Cannot find element with ID "+e)}else t("Unknown element type: "+e);else t("Unknown template value: "+e)},loadViewModel:function(t,e,n){!function t(e,n,r){if("function"==typeof n)r(function(t){return new n(t)});else if("function"==typeof n[c])r(n[c]);else if("instance"in n){var i=n.instance;r(function(){return i})}else"viewModel"in n?t(e,n.viewModel,r):e("Unknown viewModel value: "+n)}(o(t),e,n)}};var c="createViewModel";x.b("components.register",x.i.register),x.b("components.isRegistered",x.i.sb),x.b("components.unregister",x.i.unregister),x.b("components.defaultLoader",x.i.Ec),x.i.loaders.push(x.i.Ec),x.i.cd=a}(),function(){function t(t,n){if(r=t.getAttribute("params")){var r=e.parseBindingsString(r,n,t,{valueAccessors:!0,bindingParams:!0}),i=(r=x.a.Ha(r,function(e){return x.o(e,null,{l:t})}),x.a.Ha(r,function(e){var n=e.w();return e.ja()?x.o({read:function(){return x.a.c(e())},write:x.Ya(n)&&function(t){e()(t)},l:t}):n}));return Object.prototype.hasOwnProperty.call(i,"$raw")||(i.$raw=r),i}return{$raw:{}}}x.i.getComponentNameForNode=function(t){var e=x.a.P(t);if(x.i.sb(e)&&(-1!=e.indexOf("-")||"[object HTMLUnknownElement]"==""+t||8>=x.a.W&&t.tagName===e))return e},x.i.sc=function(e,n,r,i){if(1===n.nodeType){var o=x.i.getComponentNameForNode(n);if(o){if((e=e||{}).component)throw Error('Cannot use the "component" binding on a custom element matching a component');var a={name:o,params:t(n,r)};e.component=i?function(){return a}:a}}return e};var e=new x.ga;9>x.a.W&&(x.i.register=function(t){return function(e){return t.apply(this,arguments)}}(x.i.register),u.createDocumentFragment=function(t){return function(){var e,n=t(),r=x.i.cd;for(e in r);return n}}(u.createDocumentFragment))}(),function(){var t=0;x.f.component={init:function(e,n,r,i,o){function a(){var t=s&&s.dispose;"function"==typeof t&&t.call(s),c&&c.s(),u=s=c=null}var s,u,c,f=x.a.la(x.h.childNodes(e));return x.h.Ea(e),x.a.I.za(e,a),x.o(function(){var r,i,h=x.a.c(n());if("string"==typeof h?r=h:(r=x.a.c(h.name),i=x.a.c(h.params)),!r)throw Error("No component name specified");var l=x.j.Bb(e,o),d=u=++t;x.i.get(r,function(t){if(u===d){if(a(),!t)throw Error("Unknown component '"+r+"'");!function(t,e,n){if(!(e=e.template))throw Error("Component '"+t+"' has no template");t=x.a.Ca(e),x.h.ua(n,t)}(r,t,e);var n=function(t,e,n){var r=t.createViewModel;return r?r.call(t,e,n):e}(t,i,{element:e,templateNodes:f});t=l.createChildContext(n,{extend:function(t){t.$component=n,t.$componentTemplateNodes=f}}),n&&n.koDescendantsComplete&&(c=x.j.subscribe(e,x.j.oa,n.koDescendantsComplete,n)),s=n,x.Pa(t,e)}})},null,{l:e}),{controlsDescendantBindings:!0}}},x.h.ea.component=!0}();var T={class:"className",for:"htmlFor"};x.f.attr={update:function(t,e){var n=x.a.c(e())||{};x.a.O(n,function(e,n){n=x.a.c(n);var r=e.indexOf(":"),i=(r="lookupNamespaceURI"in t&&0<r&&t.lookupNamespaceURI(e.substr(0,r)),!1===n||null===n||n===a);i?r?t.removeAttributeNS(r,e):t.removeAttribute(e):n=n.toString(),8>=x.a.W&&e in T?(e=T[e],i?t.removeAttribute(e):t[e]=n):i||(r?t.setAttributeNS(r,e,n):t.setAttribute(e,n)),"name"===e&&x.a.Xc(t,i?"":n)})}},x.f.checked={after:["value","attr"],init:function(t,e,n){function r(){var r=t.checked,u=i();if(!x.U.rb()&&(r||!s&&!x.U.pa())){var h=x.v.K(e);if(c){var d=f?h.w():h,p=l;l=u,p!==u?r&&(x.a.Oa(d,u,!0),x.a.Oa(d,p,!1)):x.a.Oa(d,u,r),f&&x.Ya(h)&&h(d)}else o&&(u===a?u=r:r||(u=a)),x.m.$a(h,n,"checked",u,!0)}}var i=x.wb(function(){return n.has("checkedValue")?x.a.c(n.get("checkedValue")):h?n.has("value")?x.a.c(n.get("value")):t.value:void 0}),o="checkbox"==t.type,s="radio"==t.type;if(o||s){var u=e(),c=o&&x.a.c(u)instanceof Array,f=!(c&&u.push&&u.splice),h=s||c,l=c?i():a;s&&!t.name&&x.f.uniqueName.init(t,function(){return!0}),x.o(r,null,{l:t}),x.a.H(t,"click",r),x.o(function(){var n=x.a.c(e()),r=i();c?(t.checked=0<=x.a.A(n,r),l=r):t.checked=o&&r===a?!!n:i()===n},null,{l:t}),u=a}}},x.m.va.checked=!0,x.f.checkedValue={update:function(t,e){t.value=x.a.c(e())}},x.f.class={update:function(t,e){var n=x.a.Cb(x.a.c(e()));x.a.Eb(t,t.__ko__cssValue,!1),t.__ko__cssValue=n,x.a.Eb(t,n,!0)}},x.f.css={update:function(t,e){var n=x.a.c(e());null!==n&&"object"==typeof n?x.a.O(n,function(e,n){n=x.a.c(n),x.a.Eb(t,e,n)}):x.f.class.update(t,e)}},x.f.enable={update:function(t,e){var n=x.a.c(e());n&&t.disabled?t.removeAttribute("disabled"):n||t.disabled||(t.disabled=!0)}},x.f.disable={update:function(t,e){x.f.enable.update(t,function(){return!x.a.c(e())})}},x.f.event={init:function(t,e,n,r,i){var o=e()||{};x.a.O(o,function(o){"string"==typeof o&&x.a.H(t,o,function(t){var a,s=e()[o];if(s){try{var u=x.a.la(arguments);r=i.$data,u.unshift(r),a=s.apply(r,u)}finally{!0!==a&&(t.preventDefault?t.preventDefault():t.returnValue=!1)}!1===n.get(o+"Bubble")&&(t.cancelBubble=!0,t.stopPropagation&&t.stopPropagation())}})})}},x.f.foreach={Qc:function(t){return function(){var e=t(),n=x.a.$b(e);return n&&"number"!=typeof n.length?(x.a.c(e),{foreach:n.data,as:n.as,noChildContext:n.noChildContext,includeDestroyed:n.includeDestroyed,afterAdd:n.afterAdd,beforeRemove:n.beforeRemove,afterRender:n.afterRender,beforeMove:n.beforeMove,afterMove:n.afterMove,templateEngine:x.ba.Na}):{foreach:e,templateEngine:x.ba.Na}}},init:function(t,e){return x.f.template.init(t,x.f.foreach.Qc(e))},update:function(t,e,n,r,i){return x.f.template.update(t,x.f.foreach.Qc(e),n,r,i)}},x.m.Ra.foreach=!1,x.h.ea.foreach=!0,x.f.hasfocus={init:function(t,e,n){function r(r){t.__ko_hasfocusUpdating=!0;var i=t.ownerDocument;if("activeElement"in i){var o;try{o=i.activeElement}catch(t){o=i.body}r=o===t}i=e(),x.m.$a(i,n,"hasfocus",r,!0),t.__ko_hasfocusLastValue=r,t.__ko_hasfocusUpdating=!1}v