@tko/build.knockout 4.0.0-beta1.6 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser.js +2109 -1531
- package/dist/browser.js.map +4 -4
- package/dist/browser.min.js +10 -11
- package/dist/browser.min.js.map +4 -4
- package/dist/common.js +1 -1
- package/dist/index.cjs +2106 -1528
- package/dist/index.cjs.map +4 -4
- package/dist/index.js +11 -11
- package/dist/index.js.map +2 -2
- package/dist/index.mjs +11 -11
- package/dist/index.mjs.map +2 -2
- package/helpers/jasmine.extensions.js +19 -1
- package/package.json +17 -18
- package/LICENSE +0 -22
package/dist/browser.min.js
CHANGED
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
var ko=(()=>{var Jr=Object.defineProperty;var lo=Object.getOwnPropertyDescriptor;var co=Object.getOwnPropertyNames;var fo=Object.prototype.hasOwnProperty;var ot=(t,e)=>{for(var r in e)Jr(t,r,{get:e[r],enumerable:!0})},po=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of co(e))!fo.call(t,i)&&i!==r&&Jr(t,i,{get:()=>e[i],enumerable:!(n=lo(e,i))||n.enumerable});return t};var ho=t=>po(Jr({},"__esModule",{value:!0}),t);var sa={};ot(sa,{default:()=>ia});var{isArray:Vt}=Array;function I(t,e,r){arguments.length>2&&(e=e.bind(r));for(let n=0,i=t.length;n<i;++n)e(t[n],n,t)}function U(t,e){return(Vt(t)?t:[...t]).indexOf(e)}function hr(t,e,r){return(Vt(t)?t:[...t]).find(e,r)}function ut(t=[],e,r){return arguments.length>2&&(e=e.bind(r)),t===null?[]:Array.from(t,e)}function at(t,e){var r=U(t,e);r>0?t.splice(r,1):r===0&&t.shift()}function oi(t=[]){let e=new Set;return t===null?[]:(Vt(t)?t:[...t]).filter(r=>e.has(r)?!1:e.add(r))}function We(t,e,r){return arguments.length>2&&(e=e.bind(r)),t===null?[]:(Vt(t)?t:[...t]).filter(e)}function lt(t,e){if(Vt(e))t.push.apply(t,e);else for(var r=0,n=e.length;r<n;r++)t.push(e[r]);return t}function Oe(t,e,r){var n=U(typeof t.peek=="function"?t.peek():t,e);n<0?r&&t.push(e):r||t.splice(n,1)}function le(t){return Array.from(t)}function ui(t,e){t=typeof t=="function"?t():t,e=typeof e=="function"?e():e;for(var r=[],n=t;n<=e;n++)r.push(n);return r}function Gr(t,e,r){if(t.length&&e.length){var n,i,s,o,u;for(n=i=0;(!r||n<r)&&(o=t[i]);++i){for(s=0;u=e[s];++s)if(o.value===u.value){o.moved=u.index,u.moved=o.index,e.splice(s,1),n=s=0;break}n+=s}}}var ni="added",ii="deleted";function ct(t,e,r){return r=typeof r=="boolean"?{dontLimitMoves:r}:r||{},t=t||[],e=e||[],t.length<e.length?si(t,e,ni,ii,r):si(e,t,ii,ni,r)}function si(t,e,r,n,i){var s=Math.min,o=Math.max,u=[],a,l=t.length,f,m=e.length,h=m-l||1,p=l+m+1,A,x,b,P;for(a=0;a<=l;a++)for(x=A,u.push(A=[]),b=s(m,a+h),P=o(0,a-1),f=P;f<=b;f++)if(!f)A[f]=a+1;else if(!a)A[f]=f+1;else if(t[a-1]===e[f-1])A[f]=x[f-1];else{var F=x[f]||p,E=A[f-1]||p;A[f]=s(F,E)+1}var B=[],w,R=[],M=[];for(a=l,f=m;a||f;)w=u[a][f]-1,f&&w===u[a][f-1]?R.push(B[B.length]={status:r,value:e[--f],index:f}):a&&w===u[a-1][f]?M.push(B[B.length]={status:n,value:t[--a],index:a}):(--f,--a,i.sparse||B.push({status:"retained",value:e[f]}));return Gr(M,R,!i.dontLimitMoves&&l*10),B.reverse()}var mr={deferUpdates:!1,useOnlyNativeEvents:!1,protoProperty:"__ko_proto__",defaultBindingAttribute:"data-bind",allowVirtualElements:!0,bindingGlobals:Object.create(null),bindingProviderInstance:null,createChildContextWithAs:!1,jQuery:globalThis.jQuery,Promise:globalThis.Promise,taskScheduler:null,debug:!1,global:globalThis,document:globalThis.document,filters:{},includeDestroyed:!1,foreachHidesDestroyed:!1,onError:function(t){throw t},set:function(t,e){mr[t]=e},getBindingHandler(){},cleanExternalData(){}};Object.defineProperty(mr,"$",{get:function(){return mr.jQuery}});var c=mr;function Yr(t){return c.onError?(...e)=>{try{return t(...e)}catch(r){c.onError(r)}}:t}function zr(t){ce(function(){throw t},0)}function ce(t,e){return setTimeout(Yr(t),e)}function gr(t,e){var r;return function(...n){r||(r=ce(function(){r=void 0,t(...n)},e))}}function vr(t,e){var r;return function(...n){clearTimeout(r),r=ce(()=>t(...n),e)}}var $=c.document&&function(){for(var t=3,e=c.document.createElement("div"),r=e.getElementsByTagName("i");e.innerHTML="<!--[if gt IE "+ ++t+"]><i></i><![endif]-->",r[0];);if(!t){let n=window.navigator.userAgent;return ua.match(/MSIE ([^ ]+)/)||ua.match(/rv:([^ )]+)/)}return t>4?t:void 0}();function Y(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Rt(t){return t===null?!1:typeof t=="object"||typeof t=="function"}function L(t,e){if(e)for(var r in e)Y(e,r)&&(t[r]=e[r]);return t}function O(t,e){for(var r in t)Y(t,r)&&e(r,t[r])}function ge(t,e,r){if(!t)return t;arguments.length>2&&(e=e.bind(r));var n={};for(var i in t)Y(t,i)&&(n[i]=e(t[i],i,t));return n}function Xr(t,e){return Y(t,e)?t[e]:void 0}function Zr(t,e){if(e||(e=[]),!t||typeof t!="object"||t.constructor!==Object||e.indexOf(t)!==-1)return t;e.push(t);var r={};for(var n in t)Y(t,n)&&(r[n]=Zr(t[n],e));return r}function ai(t){let e=new Set;return JSON.stringify(t,(r,n)=>e.has(n)?"...":(typeof n=="object"&&e.add(n),n))}function en(t){return Rt(t)&&typeof t.then=="function"}function mo(){try{return Object.defineProperty(function(){},"length",{}),!0}catch(t){return!1}}var go=mo();function br(t,e){go&&Object.defineProperty(t,"length",e)}function Ue(t){return t==null?"":t.trim?t.trim():t.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")}function li(t,e){return t=t||"",e.length>t.length?!1:t.substring(0,e.length)===e}function ci(t){return typeof t=="string"&&(t=Ue(t),t)?JSON&&JSON.parse?JSON.parse(t):new Function("return "+t)():null}var vo=typeof Symbol=="function";function z(t){return vo?Symbol(t):t}var tn=/\S+/g;function dt(t,e,r){var n;!e||(typeof t.classList=="object"?(n=t.classList[r?"add":"remove"],I(e.match(tn),function(i){n.call(t.classList,i)})):typeof t.className.baseVal=="string"?di(t.className,"baseVal",e,r):di(t,"className",e,r))}function di(t,e,r,n){var i=t[e].match(tn)||[];I(r.match(tn),function(s){Oe(i,s,n)}),t[e]=i.join(" ")}var J=c.global&&c.global.jQuery;function rn(t,e){if(t===e)return!0;if(t.nodeType===11)return!1;if(e.contains)return e.contains(t.nodeType!==1?t.parentNode:t);if(e.compareDocumentPosition)return(e.compareDocumentPosition(t)&16)==16;for(;t&&t!=e;)t=t.parentNode;return!!t}function Mt(t){return rn(t,t.ownerDocument.documentElement)}function fi(t){return!!hr(t,Mt)}function V(t){return t&&t.tagName&&t.tagName.toLowerCase()}function pi(t){return window.HTMLElement?t instanceof HTMLElement:t&&t.tagName&&t.nodeType===1}function nn(t){return window.DocumentFragment?t instanceof DocumentFragment:t&&t.nodeType===11}var y={};ot(y,{clear:()=>on,get:()=>Qe,getOrSet:()=>Eo,nextKey:()=>Lt,set:()=>xe});var bo=new Date().getTime(),$t=`__ko__${bo}`,yr=Symbol("Knockout data"),Ar,hi=0,yo={getDataForNode(t,e){let r=t[yr];return!r&&e&&(r=t[yr]={}),r},clear(t){return t[yr]?(delete t[yr],!0):!1}},Ao={getDataforNode(t,e){let r=t[$t];if(!(r&&r!=="null"&&Ar[r])){if(!e)return;r=t[$t]="ko"+hi++,Ar[r]={}}return Ar[r]},clear(t){let e=t[$t];return e?(delete Ar[e],t[$t]=null,!0):!1}},{getDataForNode:sn,clear:on}=$?Ao:yo;function Lt(){return hi+++$t}function Qe(t,e){let r=sn(t,!1);return r&&r[e]}function xe(t,e,r){var n=sn(t,r!==void 0);n&&(n[e]=r)}function Eo(t,e,r){let n=sn(t,!0);return n[e]||(n[e]=r)}var un=Lt(),Co={1:!0,8:!0,9:!0},mi={1:!0,9:!0};function an(t,e){var r=Qe(t,un);return r===void 0&&e&&(r=[],xe(t,un,r)),r}function xo(t){xe(t,un,void 0)}function gi(t){var e=an(t,!1);if(e){e=e.slice(0);for(let r=0;r<e.length;r++)e[r](t)}on(t);for(let r=0,n=ft.length;r<n;++r)ft[r](t);c.cleanExternalData&&c.cleanExternalData(t),mi[t.nodeType]&&vi(t.childNodes,!0)}function vi(t,e){let r=[],n;for(var i=0;i<t.length;i++)if((!e||t[i].nodeType===8)&&(gi(r[r.length]=n=t[i]),t[i]!==n))for(;i--&&U(r,t[i])===-1;);}function de(t,e){if(typeof e!="function")throw new Error("Callback must be a function");an(t,!0).push(e)}function pt(t,e){var r=an(t,!1);r&&(at(r,e),r.length===0&&xo(t))}function X(t){return Co[t.nodeType]&&(gi(t),mi[t.nodeType]&&vi(t.getElementsByTagName("*"))),t}function ve(t){X(t),t.parentNode&&t.parentNode.removeChild(t)}var ft=[];function bi(t){ft.push(t)}function yi(t){let e=ft.indexOf(t);e>=0&&ft.splice(e,1)}function Do(t){var e=J?J.cleanData:null;e&&e([t])}ft.push(Do);var cn={},Ai={},Fo=c.global.navigator&&/Firefox\/2/i.test(c.global.navigator.userAgent)?"KeyboardEvent":"UIEvents";cn[Fo]=["keyup","keydown","keypress"];cn.MouseEvents=["click","dblclick","mousedown","mouseup","mousemove","mouseover","mouseout","mouseenter","mouseleave"];O(cn,function(t,e){if(e.length)for(var r=0,n=e.length;r<n;r++)Ai[e[r]]=t});function Bo(t,e){if(V(t)!=="input"||!t.type||e.toLowerCase()!="click")return!1;var r=t.type;return r=="checkbox"||r=="radio"}var wo={propertychange:!0},ln;function Q(t,e,r,n=!1){let i=Yr(r),s=$&&wo[e],o=Boolean(n);if(!c.useOnlyNativeEvents&&!s&&!o&&J)ln||(ln=typeof J(t).on=="function"?"on":"bind"),J(t)[ln](e,i);else if(!s&&typeof t.addEventListener=="function")t.addEventListener(e,i,n);else if(typeof t.attachEvent!="undefined"){let u=function(l){i.call(t,l)},a="on"+e;t.attachEvent(a,u),de(t,function(){t.detachEvent(a,u)})}else throw new Error("Browser doesn't support addEventListener or attachEvent")}function Ke(t,e){if(!(t&&t.nodeType))throw new Error("element must be a DOM node when calling triggerEvent");var r=Bo(t,e);if(!c.useOnlyNativeEvents&&J&&!r)J(t).trigger(e);else if(typeof document.createEvent=="function")if(typeof t.dispatchEvent=="function"){var n=Ai[e]||"HTMLEvents",i=document.createEvent(n);i.initEvent(e,!0,!0,c.global,0,0,0,0,0,!1,!1,!1,!1,0,t),t.dispatchEvent(i)}else throw new Error("The supplied element doesn't support dispatchEvent");else if(r&&t.click)t.click();else if(typeof t.fireEvent!="undefined")t.fireEvent("on"+e);else throw new Error("Browser doesn't support triggering events")}function Ht(t){for(var e=le(t),r=e[0]&&e[0].ownerDocument||document,n=r.createElement("div"),i=0,s=e.length;i<s;i++)n.appendChild(X(e[i]));return n}function De(t,e){for(var r=0,n=t.length,i=[];r<n;r++){var s=t[r].cloneNode(!0);i.push(e?X(s):s)}return i}function Ei(t,e){if(jt(t),e)for(var r=0,n=e.length;r<n;r++)t.appendChild(e[r])}function Er(t,e){var r=t.nodeType?[t]:t;if(r.length>0){for(var n=r[0],i=n.parentNode,s=0,o=e.length;s<o;s++)i.insertBefore(e[s],n);for(s=0,o=r.length;s<o;s++)ve(r[s])}}function Cr(t,e){if(t.name=e,$<=7)try{t.mergeAttributes(document.createElement("<input name='"+t.name+"'/>"),!1)}catch(r){}}function jt(t){for(;t.firstChild;)ve(t.firstChild)}function qe(t,e){if(t.length){for(e=e.nodeType===8&&e.parentNode||e;t.length&&t[0].parentNode!==e;)t.splice(0,1);for(;t.length>1&&t[t.length-1].parentNode!==e;)t.length--;if(t.length>1){var r=t[0],n=t[t.length-1];for(t.length=0;r!==n;)t.push(r),r=r.nextSibling;t.push(n)}}return t}function xr(t,e){$<7?t.setAttribute("selected",e):t.selected=e}function Ci(t){if($>=9){var e=t.nodeType==1?t:t.parentNode;e.style&&(e.style.zoom=e.style.zoom)}}function xi(t){if($){var e=t.style.width;t.style.width=0,t.style.width=e}}var v={};ot(v,{allowedBindings:()=>_o,childNodes:()=>wi,emptyNode:()=>Dr,endCommentRegex:()=>Di,firstChild:()=>Br,getVirtualChildren:()=>fn,hasBindingValue:()=>ko,insertAfter:()=>Io,isEndComment:()=>Pe,isStartComment:()=>ie,lastChild:()=>Oo,nextSibling:()=>wr,normaliseVirtualElementDomStructure:()=>Ro,prepend:()=>Si,previousSibling:()=>Po,setDomNodeChildren:()=>Fr,startCommentRegex:()=>dn,virtualNodeBindingValue:()=>Vo});var Wt=c.document&&c.document.createComment("test").text==="<!--test-->",dn=Wt?/^<!--\s*ko(?:\s+([\s\S]+))?\s*-->$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,Di=Wt?/^<!--\s*\/ko\s*-->$/:/^\s*\/ko\s*$/,So={ul:!0,ol:!0};function ie(t){return t.nodeType==8&&dn.test(Wt?t.text:t.nodeValue)}function Pe(t){return t.nodeType==8&&Di.test(Wt?t.text:t.nodeValue)}function No(t){return Pe(t)&&!Qe(t,Fi)}var Fi="__ko_matchedEndComment__";function fn(t,e){for(var r=t,n=1,i=[];r=r.nextSibling;){if(Pe(r)&&(xe(r,Fi,!0),n--,n===0))return i;i.push(r),ie(r)&&n++}if(!e)throw new Error("Cannot find closing comment tag to match: "+t.nodeValue);return null}function Bi(t,e){var r=fn(t,e);return r?r.length>0?r[r.length-1].nextSibling:t.nextSibling:null}function To(t){var e=t.firstChild,r=null;if(e)do if(r)r.push(e);else if(ie(e)){var n=Bi(e,!0);n?e=n:r=[e]}else Pe(e)&&(r=[e]);while(e=e.nextSibling);return r}var _o={},ko=ie;function wi(t){return ie(t)?fn(t):t.childNodes}function Dr(t){if(!ie(t))jt(t);else for(var e=wi(t),r=0,n=e.length;r<n;r++)ve(e[r])}function Fr(t,e){if(!ie(t))Ei(t,e);else{Dr(t);let i=t.nextSibling,s=i.parentNode;for(var r=0,n=e.length;r<n;++r)s.insertBefore(e[r],i)}}function Si(t,e){ie(t)?t.parentNode.insertBefore(e,t.nextSibling):t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}function Io(t,e,r){r?ie(t)?t.parentNode.insertBefore(e,r.nextSibling):r.nextSibling?t.insertBefore(e,r.nextSibling):t.appendChild(e):Si(t,e)}function Br(t){if(!ie(t)){if(t.firstChild&&Pe(t.firstChild))throw new Error("Found invalid end comment, as the first child of "+t.outerHTML);return t.firstChild}return!t.nextSibling||Pe(t.nextSibling)?null:t.nextSibling}function Oo(t){let e=Br(t),r;do r=e;while(e=wr(e));return r}function wr(t){if(ie(t)&&(t=Bi(t)),t.nextSibling&&Pe(t.nextSibling)){if(No(t.nextSibling))throw Error("Found end comment without a matching opening comment, as next sibling of "+t.outerHTML);return null}else return t.nextSibling}function Po(t){var e=0;do if(t.nodeType===8)if(ie(t)){if(--e===0)return t}else Pe(t)&&e++;else if(e===0)return t;while(t=t.previousSibling)}function Vo(t){var e=(Wt?t.text:t.nodeValue).match(dn);return e?e[1]:null}function Ro(t){if(!!So[V(t)]){var e=t.firstChild;if(e)do if(e.nodeType===1){var r=To(e);if(r)for(var n=e.nextSibling,i=0;i<r.length;i++)n?t.insertBefore(r[i],n):t.appendChild(r[i])}while(e=e.nextSibling)}}var Mo=[0,"",""],Ut=[1,"<table>","</table>"],$o=[2,"<table><tbody>","</tbody></table>"],Lo=[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],Ni=[3,"<table><tbody><tr>","</tr></tbody></table>"],Ti=[1,"<select multiple='multiple'>","</select>"],Ho=[1,"<fieldset>","</fieldset>"],jo=[1,"<map>","</map>"],Wo=[1,"<object>","</object>"],Uo={area:jo,col:Lo,colgroup:Ut,caption:Ut,legend:Ho,thead:Ut,tbody:Ut,tfoot:Ut,tr:$o,td:Ni,th:Ni,option:Ti,optgroup:Ti,param:Wo},_i=c.document&&"content"in c.document.createElement("template");function Qo(t){let e=t.match(/^(?:<!--.*?-->\s*?)*?<([a-z]+)[\s>]/);return e&&Uo[e[1]]||Mo}function Ko(t,e){e||(e=document);var r=e.parentWindow||e.defaultView||window,n=Ue(t).toLowerCase(),i=e.createElement("div"),s=Qo(n),o=s[0],u="ignored<div>"+s[1]+t+s[2]+"</div>";for(typeof r.innerShiv=="function"?i.appendChild(r.innerShiv(u)):i.innerHTML=u;o--;)i=i.lastChild;return le(i.lastChild.childNodes)}function qo(t,e){e||(e=document);var r=e.createElement("template");return r.innerHTML=t,le(r.content.childNodes)}function Jo(t,e){if(J.parseHTML)return J.parseHTML(t,e)||[];var r=J.clean([t],e);if(r&&r[0]){for(var n=r[0];n.parentNode&&n.parentNode.nodeType!==11;)n=n.parentNode;n.parentNode&&n.parentNode.removeChild(n)}return r}function be(t,e){return _i?qo(t,e):J?Jo(t,e):Ko(t,e)}function ki(t,e){let r=be(t,e);return r.length&&r[0].parentElement||Ht(r)}function ht(t,e){if(jt(t),typeof e=="function"&&(e=e()),e!=null)if(typeof e!="string"&&(e=e.toString()),J&&!_i)J(t).html(e);else{var r=be(e,t.ownerDocument);if(t.nodeType===8)e===null?Dr(t):Fr(t,r);else for(var n=0;n<r.length;n++)t.appendChild(r[n])}}function Je(t,e){var r=typeof e=="function"?e():e;r==null&&(r="");var n=Br(t);!n||n.nodeType!=3||wr(n)?Fr(t,[t.ownerDocument.createTextNode(r)]):n.data=r,Ci(t)}var Sr=Symbol("Knockout selectExtensions hasDomDataProperty"),_={optionValueDomDataKey:Lt(),readValue:function(t){switch(V(t)){case"option":return t[Sr]===!0?Qe(t,_.optionValueDomDataKey):t.value;case"select":return t.selectedIndex>=0?_.readValue(t.options[t.selectedIndex]):void 0;default:return t.value}},writeValue:function(t,e,r){switch(V(t)){case"option":typeof e=="string"?(xe(t,_.optionValueDomDataKey,void 0),Sr in t&&delete t[Sr],t.value=e):(xe(t,_.optionValueDomDataKey,e),t[Sr]=!0,t.value=typeof e=="number"?e:"");break;case"select":(e===""||e===null)&&(e=void 0);var n=-1;for(let i=0,s=t.options.length,o;i<s;++i){o=_.readValue(t.options[i]);let u=o===e,a=o===""&&e===void 0,l=typeof e=="number"&&Number(o)===e;if(u||a||l){n=i;break}}(r||n>=0||e===void 0&&t.size>1)&&(t.selectedIndex=n);break;default:e==null&&(e=""),t.value=e;break}}};var Ge={};ot(Ge,{memoize:()=>Yo,parseMemoText:()=>Vi,unmemoize:()=>Pi,unmemoizeDomNodeAndDescendants:()=>zo});var pn={};function Ii(){return((1+Math.random())*4294967296|0).toString(16).substring(1)}function Go(){return Ii()+Ii()}function Oi(t,e){if(!!t){if(t.nodeType==8){var r=Vi(t.nodeValue);r!=null&&e.push({domNode:t,memoId:r})}else if(t.nodeType==1)for(var n=0,i=t.childNodes,s=i.length;n<s;n++)Oi(i[n],e)}}function Yo(t){if(typeof t!="function")throw new Error("You can only pass a function to memoization.memoize()");var e=Go();return pn[e]=t,"<!--[ko_memo:"+e+"]-->"}function Pi(t,e){var r=pn[t];if(r===void 0)throw new Error("Couldn't find any memo with ID "+t+". Perhaps it's already been unmemoized.");try{return r.apply(null,e||[]),!0}finally{delete pn[t]}}function zo(t,e){var r=[];Oi(t,r);for(var n=0,i=r.length;n<i;n++){var s=r[n].domNode,o=[s];e&<(o,e),Pi(r[n].memoId,o),s.nodeValue="",s.parentNode&&s.parentNode.removeChild(s)}}function Vi(t){var e=t.match(/^\[ko_memo\:(.*?)\]$/);return e?e[1]:null}var ye={};ot(ye,{cancel:()=>eu,resetForTesting:()=>tu,runEarly:()=>Mi,schedule:()=>Zo});var Qt=[],se=0,Ri=1,Ve=0,Fe=c.global;Fe&&Fe.MutationObserver&&!(Fe.navigator&&Fe.navigator.standalone)?c.taskScheduler=function(t){var e=Fe.document.createElement("div");return new Fe.MutationObserver(t).observe(e,{attributes:!0}),function(){e.classList.toggle("foo")}}($i):Fe&&Fe.document&&"onreadystatechange"in Fe.document.createElement("script")?c.taskScheduler=function(t){var e=document.createElement("script");e.onreadystatechange=function(){e.onreadystatechange=null,document.documentElement.removeChild(e),e=null,t()},document.documentElement.appendChild(e)}:c.taskScheduler=function(t){setTimeout(t,0)};function Mi(){if(se){for(var t=se,e=0,r;Ve<se;)if(r=Qt[Ve++]){if(Ve>t){if(++e>=5e3){Ve=se,zr(Error("'Too much recursion' after processing "+e+" task groups."));break}t=se}try{r()}catch(n){zr(n)}}}}function $i(){Mi(),Ve=se=Qt.length=0}function Xo(){c.taskScheduler($i)}function Zo(t){return se||Xo(),Qt[se++]=t,Ri++}function eu(t){var e=t-(Ri-se);e>=Ve&&e<se&&(Qt[e]=null)}function tu(){var t=se-Ve;return Ve=se=Qt.length=0,t}var C={};ot(C,{begin:()=>Nr,end:()=>Tr,getDependencies:()=>ou,getDependenciesCount:()=>su,ignore:()=>iu,ignoreDependencies:()=>iu,isInitial:()=>uu,registerDependency:()=>mn});var hn=Symbol("Knockout Subscribable");function mt(t){return t&&t[hn]||!1}var Li=[],oe,ru=0;function nu(){return++ru}function Nr(t){Li.push(oe),oe=t}function Tr(){oe=Li.pop()}function mn(t){if(oe){if(!mt(t))throw new Error("Only subscribable things can act as dependencies");oe.callback.call(oe.callbackTarget,t,t._id||(t._id=nu()))}}function iu(t,e,r){try{return Nr(),t.apply(e,r||[])}finally{Tr()}}function su(){if(oe)return oe.computed.getDependenciesCount()}function ou(){if(oe)return oe.computed.getDependencies()}function uu(){if(oe)return oe.isInitial}function Kt(t){t._deferUpdates||(t._deferUpdates=!0,t.limit(function(e){let r,n=!1;return function(){if(!n){ye.cancel(r),r=ye.schedule(e);try{n=!0,t.notifySubscribers(void 0,"dirty")}finally{n=!1}}}}))}var qt=class{constructor(e,r,n){this._target=e,this._callback=r.next,this._disposeCallback=n,this._isDisposed=!1,this._domNodeDisposalCallback=null}dispose(){this._domNodeDisposalCallback&&pt(this._node,this._domNodeDisposalCallback),this._isDisposed=!0,this._disposeCallback()}disposeWhenNodeIsRemoved(e){this._node=e,de(e,this._domNodeDisposalCallback=this.dispose.bind(this))}unsubscribe(){this.dispose()}get closed(){return this._isDisposed}};var au={undefined:1,boolean:1,number:1,string:1};function gt(t,e){var r=t===null||typeof t in au;return r?t===e:!1}function gn(t){var e=this;return t&&O(t,function(r,n){var i=Ae[r];typeof i=="function"?e=i(e,n)||e:c.onError(new Error("Extender not found: "+r))}),e}function lu(t,e){t.equalityComparer=e=="always"?null:gt}function cu(t,e){if(e!==!0)throw new Error("The 'deferred' extender only accepts the value 'true', because it is not supported to turn deferral off once enabled.");Kt(t)}function du(t,e){var r,n,i;typeof e=="number"?r=e:(r=e.timeout,n=e.method),t._deferUpdates=!1,i=n==="notifyWhenChangesStop"?vr:gr,t.limit(function(s){return i(s,r)})}var Ae={notify:lu,deferred:cu,rateLimit:du};var Z=Symbol("Knockout latest value");Symbol.observable||(Symbol.observable=Symbol.for("@tko/Symbol.observable"));function K(){Object.setPrototypeOf(this,_r),_r.init(this)}var Be="change",_r={[hn]:!0,[Symbol.observable](){return this},init(t){t._subscriptions={change:[]},t._versionNumber=1},subscribe(t,e,r){let n=typeof t=="object"&&t.next;r=r||Be;let i=n?t:{next:e?t.bind(e):t},s=new qt(this,i,()=>{at(this._subscriptions[r],s),this.afterSubscriptionRemove&&this.afterSubscriptionRemove(r)});return this.beforeSubscriptionAdd&&this.beforeSubscriptionAdd(r),this._subscriptions[r]||(this._subscriptions[r]=[]),this._subscriptions[r].push(s),n&&Z in this&&i.next(this[Z]),s},notifySubscribers(t,e){if(e=e||Be,e===Be&&this.updateVersion(),this.hasSubscriptionsForEvent(e)){let r=e===Be&&this._changeSubscriptions||[...this._subscriptions[e]];try{Nr();for(let n=0,i;i=r[n];++n)i._isDisposed||i._callback(t)}finally{Tr()}}},getVersion(){return this._versionNumber},hasChanged(t){return this.getVersion()!==t},updateVersion(){++this._versionNumber},hasSubscriptionsForEvent(t){return this._subscriptions[t]&&this._subscriptions[t].length},getSubscriptionsCount(t){if(t)return this._subscriptions[t]&&this._subscriptions[t].length||0;var e=0;return O(this._subscriptions,function(r,n){r!=="dirty"&&(e+=n.length)}),e},isDifferent(t,e){return!this.equalityComparer||!this.equalityComparer(t,e)},once(t){let e=this.subscribe(r=>{e.dispose(),t(r)})},when(t,e){let r=this.peek(),n=arguments.length>1,i=typeof t=="function"?t:s=>s===t;return i(r)?c.Promise.resolve(n?e:r):new c.Promise((s,o)=>{let u=this.subscribe(a=>{i(a)&&(u.dispose(),s(n?e:a))})})},yet(t,...e){let r=typeof t=="function"?t:i=>i===t,n=i=>!r(i);return this.when(n,...e)},next(){return new Promise(t=>this.once(t))},toString(){return"[object Object]"},extend:gn};Object.setPrototypeOf(_r,Function.prototype);K.fn=_r;function S(t){function e(){return arguments.length>0?(e.isDifferent(e[Z],arguments[0])&&(e.valueWillMutate(),e[Z]=arguments[0],e.valueHasMutated()),this):(mn(e),e[Z])}return br(e,{value:void 0}),e[Z]=t,K.fn.init(e),Object.setPrototypeOf(e,S.fn),c.deferUpdates&&Kt(e),e}S.fn={equalityComparer:gt,peek(){return this[Z]},valueHasMutated(){this.notifySubscribers(this[Z],"spectate"),this.notifySubscribers(this[Z])},valueWillMutate(){this.notifySubscribers(this[Z],"beforeChange")},modify(t,e=!0){return this(t(e?this.peek():this()))},isWriteable:!0};function fu(t,e){!e||e===Be?this._limitChange(t):e==="beforeChange"?this._limitBeforeChange(t):this._origNotifySubscribers(t,e)}K.fn.limit=function(e){var r=this,n=T(r),i="beforeChange",s,o,u,a,l;r._origNotifySubscribers||(r._origNotifySubscribers=r.notifySubscribers,r.notifySubscribers=fu);var f=e(function(){r._notificationIsPending=!1,n&&a===r&&(a=r._evalIfChanged?r._evalIfChanged():r());let m=o||l&&r.isDifferent(u,a);r._notifyNextChange=l=s=!1,m&&r._origNotifySubscribers(u=a)});Object.assign(r,{_limitChange(m,h){(!h||!r._notificationIsPending)&&(l=!h),r._changeSubscriptions=[...r._subscriptions[Be]],r._notificationIsPending=s=!0,a=m,f()},_limitBeforeChange(m){s||(u=m,r._origNotifySubscribers(m,i))},_notifyNextChangeIfValueIsDifferent(){r.isDifferent(u,r.peek(!0))&&(o=!0)},_recordUpdate(){l=!0}})};Object.setPrototypeOf(S.fn,K.fn);var Hi=S.protoProperty=c.protoProperty;S.fn[Hi]=S;S.observablePrototypes=new Set([S]);function T(t){let e=typeof t=="function"&&t[Hi];if(e&&!S.observablePrototypes.has(e))throw Error("Invalid object that looks like an observable; possibly from another Knockout instance");return!!e}function d(t){return T(t)?t():t}function vt(t){return T(t)?t.peek():t}function te(t){return T(t)&&t.isWriteable}var bt="arrayChange";function Ye(t,e){if(t.compareArrayOptions={},e&&typeof e=="object"&&L(t.compareArrayOptions,e),t.compareArrayOptions.sparse=!0,t.cacheDiffForKnownOperation)return;let r=!1,n=null,i,s=0,o,u=t.beforeSubscriptionAdd,a=t.afterSubscriptionRemove;t.beforeSubscriptionAdd=function(m){u&&u.call(t,m),m===bt&&l()},t.afterSubscriptionRemove=function(m){a&&a.call(t,m),m===bt&&!t.hasSubscriptionsForEvent(bt)&&(o&&(t.notifySubscribers=o,o=void 0),i&&i.dispose(),i=null,r=!1)};function l(){if(!r){r=!0,o=t.notifySubscribers,t.notifySubscribers=function(h,p){return(!p||p===Be)&&++s,o.apply(this,arguments)};var m=[].concat(t.peek()===void 0?[]:t.peek());n=null,i=t.subscribe(function(h){let p;h=[].concat(h||[]),t.hasSubscriptionsForEvent(bt)&&(p=f(m,h)),m=h,n=null,s=0,p&&p.length&&t.notifySubscribers(p,bt)})}}function f(m,h){return(!n||s>1)&&(n=Ye.compareArrays(m,h,t.compareArrayOptions)),n}t.cacheDiffForKnownOperation=function(m,h,p){if(!r||s)return;var A=[],x=m.length,b=p.length,P=0;function F(H,Ie,pr){return A[A.length]={status:H,value:Ie,index:pr}}switch(h){case"push":P=x;case"unshift":for(let H=0;H<b;H++)F("added",p[H],P+H);break;case"pop":P=x-1;case"shift":x&&F("deleted",m[P],P);break;case"splice":var E=Math.min(Math.max(0,p[0]<0?x+p[0]:p[0]),x),B=b===1?x:Math.min(E+(p[1]||0),x),w=E+b-2,R=Math.max(B,w),M=[],ne=[];for(let H=E,Ie=2;H<R;++H,++Ie)H<B&&ne.push(F("deleted",m[H],H)),H<w&&M.push(F("added",p[Ie],H));Gr(ne,M);break;default:return}n=A}}Ye.compareArrays=ct;Ae.trackArrayChanges=Ye;function fe(t){if(t=t||[],typeof t!="object"||!("length"in t))throw new Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");var e=S(t);return Object.setPrototypeOf(e,fe.fn),Ye(e),br(e,{get:()=>e().length}),e}function Jt(t){return T(t)&&typeof t.remove=="function"&&typeof t.push=="function"}fe.fn={remove(t){for(var e=this.peek(),r=[],n=typeof t=="function"&&!T(t)?t:function(o){return o===t},i=0;i<e.length;i++){var s=e[i];if(n(s)){if(r.length===0&&this.valueWillMutate(),e[i]!==s)throw Error("Array modified during remove; cannot remove item");r.push(s),e.splice(i,1),i--}}return r.length&&this.valueHasMutated(),r},removeAll(t){if(t===void 0){var e=this.peek(),r=e.slice(0);return this.valueWillMutate(),e.splice(0,e.length),this.valueHasMutated(),r}return t?this.remove(function(n){return U(t,n)>=0}):[]},destroy(t){var e=this.peek(),r=typeof t=="function"&&!T(t)?t:function(s){return s===t};this.valueWillMutate();for(var n=e.length-1;n>=0;n--){var i=e[n];r(i)&&(i._destroy=!0)}this.valueHasMutated()},destroyAll(t){return t===void 0?this.destroy(function(){return!0}):t?this.destroy(function(e){return U(t,e)>=0}):[]},indexOf(t){return U(this(),t)},replace(t,e){var r=this.indexOf(t);r>=0&&(this.valueWillMutate(),this.peek()[r]=e,this.valueHasMutated())},sorted(t){return[...this()].sort(t)},reversed(){return[...this()].reverse()},[Symbol.iterator]:function*(){yield*this()}};Object.setPrototypeOf(fe.fn,S.fn);I(["pop","push","reverse","shift","sort","splice","unshift"],function(t){fe.fn[t]=function(){var e=this.peek();this.valueWillMutate(),this.cacheDiffForKnownOperation(e,t,arguments);var r=e[t].apply(e,arguments);return this.valueHasMutated(),r===e?this:r}});I(["slice"],function(t){fe.fn[t]=function(){var e=this();return e[t].apply(e,arguments)}});fe.trackArrayChanges=Ye;var pu=10;function yt(t){if(arguments.length==0)throw new Error("When calling ko.toJS, pass the object you want to convert.");return ji(t,function(e){for(var r=0;T(e)&&r<pu;r++)e=e();return e})}function vn(t,e,r){var n=yt(t);return JSON.stringify(n,e,r)}function ji(t,e,r=new Map){t=e(t);var n=typeof t=="object"&&t!==null&&t!==void 0&&!(t instanceof RegExp)&&!(t instanceof Date)&&!(t instanceof String)&&!(t instanceof Number)&&!(t instanceof Boolean);if(!n)return t;var i=t instanceof Array?[]:{};return r.set(t,i),hu(t,function(s){var o=e(t[s]);switch(typeof o){case"boolean":case"number":case"string":case"function":i[s]=o;break;case"object":case"undefined":var u=r.get(o);i[s]=u!==void 0?u:ji(o,e,r);break}}),i}function hu(t,e){if(t instanceof Array){for(var r=0;r<t.length;r++)e(r);typeof t.toJSON=="function"&&e("toJSON")}else for(var n in t)e(n)}var mu=Math.pow;function bn(){}function gu(t,e){for(;typeof e=="function";)e=e();return e}var g={"@":gu,"#":(t,e)=>()=>d(e),"=>":bn,"!":function(e,r){return!r},"!!":function(e,r){return!!r},"++":function(e,r){return++r},"--":function(e,r){return--r},"**":function(e,r){return mu(e,r)},"*":function(e,r){return e*r},"/":function(e,r){return e/r},"%":function(e,r){return e%r},"+":function(e,r){return e+r},"-":function(e,r){return(e||0)-(r||0)},"&-":function(e,r){return-1*r},"<":function(e,r){return e<r},"<=":function(e,r){return e<=r},">":function(e,r){return e>r},">=":function(e,r){return e>=r},"==":function(e,r){return e==r},"!=":function(e,r){return e!=r},"===":function(e,r){return e===r},"!==":function(e,r){return e!==r},"&":function(e,r){return e&r},"^":function(e,r){return e^r},"|":function(e,r){return e|r},"&&":function(e,r){return e&&r},"||":function(e,r){return e||r},"??":function(e,r){return e!=null?e:r},".":function(e,r){return e==null?void 0:e[r]},"?.":function(e,r){return e==null?void 0:e[r]},"[":function(e,r){return e==null?void 0:e[r]},",":function(e,r){return r},call:function(e,r){return e.apply(null,r)}};g["@"].precedence=21;g["#"].precedence=21;g["."].precedence=19;g["["].precedence=19;g["?."].precedence=19;g["!"].precedence=16;g["!!"].precedence=16;g["++"].precedence=16;g["--"].precedence=16;g["&-"].precedence=16;g["**"].precedent=15;g["%"].precedence=14;g["*"].precedence=14;g["/"].precedence=14;g["+"].precedence=13;g["-"].precedence=13;g["|"].precedence=12;g["^"].precedence=11;g["&"].precedence=10;g["<"].precedence=11;g["<="].precedence=11;g[">"].precedence=11;g[">="].precedence=11;g["=="].precedence=10;g["!="].precedence=10;g["==="].precedence=10;g["!=="].precedence=10;g["&&"].precedence=6;g["||"].precedence=5;g["??"].precedence=5;g["&&"].earlyOut=t=>!t;g["||"].earlyOut=t=>t;g["??"].earlyOut=t=>t;g[","].precedence=2;g.call.precedence=1;g["=>"].precedence=1;var Wi=Symbol("Node - Is Expression Or Identifier"),D=class{constructor(e,r,n){this.lhs=e,this.op=r,this.rhs=n}static get operators(){return g}get_leaf_value(e,r,n,i){return typeof e=="function"?d(e()):typeof e!="object"||e===null?e:e[D.isExpressionOrIdentifierSymbol]?d(e.get_value(void 0,r,n,i)):e}get_value(e,r,n,s){var s=this;if(s.op===bn)return(...l)=>{let f=r;return s.lhs&&(f=s.lhs.extendContext(r,l)),s.get_leaf_value(s.rhs,f,n,s)};let o=s.get_leaf_value(s.lhs,r,n,s),u=s.op.earlyOut;if(u&&u(o))return o;let a=s.get_leaf_value(s.rhs,r,n,s);return s.op(o,a,r,n)}static get isExpressionOrIdentifierSymbol(){return Wi}get[Wi](){return!0}static value_of(e,r,n,i){return e&&e[D.isExpressionOrIdentifierSymbol]?e.get_value(e,r,n,i):e}static create_root(e,r=!1){let n=[],i=[];for(let s=0;s<e.length;s+=2){n.push(e[s]);let o=e[s+1],u=(o==null?void 0:o.precedence)||0;for(;i.length&&u<=i[i.length-1].precedence;){let a=n.pop(),l=n.pop();n.push(new D(l,i.pop(),a))}i.push(o)}if(n.length!==1)throw new Error(`unexpected nodes remain in shunting yard output stack: ${n}`);return n[0]}};g["?"]=function(e,r,n,i,s){return D.value_of(e?r.yes:r.no,n,i,s)};g["?"].precedence=4;var Re=class{constructor(e){this.nodes=e,this.root=D.create_root(e)}get_value(e,r,n,i){return this.root||(this.root=D.create_root(this.nodes)),this.root.get_value(e,r,n,i)}};Re.prototype[D.isExpressionOrIdentifierSymbol]=!0;var Ee=class{constructor(e,r){this.parser=e,this.args=r}get_value(e,r,n,i){for(var s=[],o=0,u=this.args.length;o<u;++o)s.push(D.value_of(this.args[o],r,n,i));return s}get[D.isExpressionOrIdentifierSymbol](){return!0}};var Ui=/[\$A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,Qi=/[\$0-9A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/;var j=class{constructor(e,r,n){this.token=r,this.dereferences=n,this.parser=e}dereference(e,r,n,i){let s,o=this.dereferences||[],u=r.$data||{},a,l,f;for(l=0,f=o.length;l<f;++l)if(s=D.value_of(o[l],r,n,i),typeof e=="function"&&o[l]instanceof Ee)e=e.apply(a||u,s),a=e;else{if(e==null)return e;a=e,e=D.value_of(e[s],r,n,i)}return typeof e=="function"&&f>0&&a!==e&&!Y(a,s)?e.bind(a):e}get_value(e,r,n,i){let s=e&&!(e instanceof j)?D.value_of(e,r,n,i)[this.token]:r.lookup(this.token,n,i);return this.dereference(s,r,n,i)}assign(e,r,n){te(e[r])?e[r](n):T(e[r])||(e[r]=n)}set_value(e,r,n){let i=r.$data||{},s=this.dereferences||[],o=this.token,u,a,l;if(Rt(i)&&o in i)l=i;else if(o in r)l=r;else if(o in n)l=n;else throw new Error("Identifier::set_value -- The property '"+o+"' does not exist on the $data, $context, or globals.");if(a=s.length,a===0){this.assign(l,o,e);return}for(l=l[o],u=0;u<a-1;++u)o=s[u],o instanceof Ee?l=l():l=l[D.value_of(o)];if(s[u]===!0)throw new Error("Cannot assign a value to a function.");s[u]&&this.assign(l,D.value_of(s[u]),e)}static is_valid_start_char(e){return Ui.test(e)}static is_valid_continue_char(e){return Qi.test(e)}get[D.isExpressionOrIdentifierSymbol](){return!0}};var ze=class{constructor(e,r){r instanceof Re&&(r=r.root);try{this.names=ze.nodeTreeToNames(r)}catch(n){e.error(n)}}extendContext(e,r){if(this.names){let n={};return this.names.forEach((i,s)=>{n[i]=r[s]}),e.extend(n)}else return e}get[D.isExpressionOrIdentifierSymbol](){return!0}static nodeTreeToNames(e){let r=[];for(;e;)if(e instanceof j)r.push(e.token),e=null;else if(this.isCommaNode(e))r.push(e.rhs.token),e=e.lhs;else throw new Error(`only simple identifiers allowed in lambda parameter list but found ${JSON.stringify(e,null,2)}`);return r.reverse(),r}static isCommaNode(e){return e instanceof D&&e.op===g[","]&&e.rhs instanceof j}};var At=class{constructor(e,r){Object.assign(this,{yes:e,no:r})}get_value(){return this}get[D.isExpressionOrIdentifierSymbol](){return!0}};var Ki={"'":"'",'"':'"',"`":"`","\\":"\\","/":"/",$:"$",b:"\b",f:"\f",n:`
|
|
3
|
-
`,r:"\r",t:" "},
|
|
4
|
-
`||e==="\r")););e=this.next()}else if(
|
|
5
|
-
${
|
|
6
|
-
${this.text}
|
|
1
|
+
// @tko/build.knockout 🥊 4.0.0 IIFE
|
|
2
|
+
"use strict";var ko=(()=>{var Pn=Object.defineProperty;var Zs=Object.getOwnPropertyDescriptor;var eo=Object.getOwnPropertyNames;var to=Object.prototype.hasOwnProperty;var Mn=(n,e)=>(e=Symbol[n])?e:Symbol.for("Symbol."+n),Vn=n=>{throw TypeError(n)},Yr=Math.pow;var Ge=(n,e)=>{for(var t in e)Pn(n,t,{get:e[t],enumerable:!0})},no=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of eo(e))!to.call(n,i)&&i!==t&&Pn(n,i,{get:()=>e[i],enumerable:!(r=Zs(e,i))||r.enumerable});return n};var ro=n=>no(Pn({},"__esModule",{value:!0}),n);var Xr=(n,e,t)=>e.has(n)||Vn("Cannot "+t);var Rn=(n,e,t)=>(Xr(n,e,"read from private field"),t?t.call(n):e.get(n)),Zr=(n,e,t)=>e.has(n)?Vn("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(n):e.set(n,t),ei=(n,e,t,r)=>(Xr(n,e,"write to private field"),r?r.call(n,t):e.set(n,t),t);var Ye=(n,e,t)=>new Promise((r,i)=>{var s=u=>{try{a(t.next(u))}catch(l){i(l)}},o=u=>{try{a(t.throw(u))}catch(l){i(l)}},a=u=>u.done?r(u.value):Promise.resolve(u.value).then(s,o);a((t=t.apply(n,e)).next())}),io=function(n,e){this[0]=n,this[1]=e};var ke=n=>{var e=n[Mn("asyncIterator")],t=!1,r,i={};return e==null?(e=n[Mn("iterator")](),r=s=>i[s]=o=>e[s](o)):(e=e.call(n),r=s=>i[s]=o=>{if(t){if(t=!1,s==="throw")throw o;return o}return t=!0,{done:!1,value:new io(new Promise(a=>{var u=e[s](o);u instanceof Object||Vn("Object expected"),a(u)}),1)}}),i[Mn("iterator")]=()=>i,r("next"),"throw"in e?r("throw"):i.throw=s=>{throw s},"return"in e&&r("return"),i};var Hu={};Ge(Hu,{default:()=>$u});var{isArray:St}=Array;function P(n,e,t){arguments.length>2&&(e=e.bind(t));for(let r=0,i=n.length;r<i;++r)e(n[r],r,n)}function j(n,e){return(St(n)?n:[...n]).indexOf(e)}function rn(n,e,t){return(St(n)?n:[...n]).find(e,t)}function Xe(n,e,t){return arguments.length>2&&(e=e.bind(t)),n===null?[]:Array.from(n,e)}function Ze(n,e){let t=j(n,e);t>0?n.splice(t,1):t===0&&n.shift()}function ii(n){let e=new Set;return n===null?[]:(St(n)?n:[...n]).filter(t=>e.has(t)?!1:e.add(t))}function Me(n,e,t){return arguments.length>2&&(e=e.bind(t)),n===null?[]:(St(n)?n:[...n]).filter(e)}function et(n,e){if(St(e))n.push.apply(n,e);else for(let t=0,r=e.length;t<r;t++)n.push(e[t]);return n}function we(n,e,t){let r=j(typeof n.peek=="function"?n.peek():n,e);r<0?t&&n.push(e):t||n.splice(r,1)}function ue(n){return Array.from(n)}function si(n,e){let t=typeof n=="function"?n():n,r=typeof e=="function"?e():e,i=[];for(let s=t;s<=r;s++)i.push(s);return i}function Ln(n,e,t){if(n.length&&e.length){let r,i,s,o,a;for(r=i=0;(!t||r<t)&&(o=n[i]);++i){for(s=0;a=e[s];++s)if(o.value===a.value){o.moved=a.index,a.moved=o.index,e.splice(s,1),r=s=0;break}r+=s}}}var ti="added",ni="deleted";function tt(n,e,t){return t=typeof t=="boolean"?{dontLimitMoves:t}:t||{},n=n||[],e=e||[],n.length<e.length?ri(n,e,ti,ni,t):ri(e,n,ni,ti,t)}function ri(n,e,t,r,i){let s=Math.min,o=Math.max,a=new Array,u,l=n.length,d,p=e.length,b=p-l||1,m=l+p+1,A,v,h,T;for(u=0;u<=l;u++)for(v=A,a.push(A=new Array),h=s(p,u+b),T=o(0,u-1),d=T;d<=h;d++)if(!d)A[d]=u+1;else if(!u)A[d]=d+1;else if(n[u-1]===e[d-1])A[d]=v[d-1];else{let _=v[d]||m,M=A[d-1]||m;A[d]=s(_,M)+1}let k=new Array,g,N=new Array,C=new Array;for(u=l,d=p;u||d;)g=a[u][d]-1,d&&g===a[u][d-1]?N.push(k[k.length]={status:t,value:e[--d],index:d}):u&&g===a[u-1][d]?C.push(k[k.length]={status:r,value:n[--u],index:u}):(--d,--u,i!=null&&i.sparse||k.push({status:"retained",value:e[d]}));return Ln(C,N,!i.dontLimitMoves&&l*10),k.reverse()}var $n=class{constructor(){this.bindingStringPreparsers=[],this.knockoutInstance=null,this.deferUpdates=!1,this.useOnlyNativeEvents=!0,this.useTemplateTag=!0,this.protoProperty="__ko_proto__",this.defaultBindingAttribute="data-bind",this.allowVirtualElements=!0,this.bindingGlobals=Object.create(null),this.createChildContextWithAs=!1,this.disableJQueryUsage=!1,this.Promise=globalThis.Promise,this.taskScheduler=null,this.debug=!1,this.templateSizeLimit=4096,this.allowScriptTagsInTemplates=!1,this._sanitizeWarningLogged=!1,this.global=globalThis,this.document=globalThis.document,this.filters={},this.includeDestroyed=!1,this.foreachHidesDestroyed=!1}get jQuery(){var e;if(!this.disableJQueryUsage)return(e=this._jQuery)!=null?e:globalThis.jQuery}set jQuery(e){e?(this._jQuery=e,this.disableJQueryUsage=!1):(this.disableJQueryUsage=!0,this._jQuery=void 0)}sanitizeHtmlTemplate(e){return this._sanitizeWarningLogged||(console.warn("WARNING -- You don't have a HTML sanitizer configured. Please configure options.sanitizeHtmlTemplate to avoid XSS vulnerabilities."),this._sanitizeWarningLogged=!0),e}onError(e,t=!0){if(t)throw e;return e}set(e,t){this[e]=t}getBindingHandler(e){return null}cleanExternalData(e,t){}},so=new $n,c=so;function Hn(n){return c.onError?(...e)=>{try{return n(...e)}catch(t){c.onError(t)}}:n}function jn(n){ae(function(){throw n},0)}function ae(n,e){return setTimeout(Hn(n),e)}function sn(n,e){let t;return function(...r){t||(t=ae(function(){t=void 0,n(...r)},e))}}function on(n,e){let t;return function(...r){clearTimeout(t),t=ae(()=>n(...r),e)}}function J(n,e){return Object.prototype.hasOwnProperty.call(n,e)}function Tt(n){return n===null?!1:typeof n=="object"||typeof n=="function"}function L(n,e){if(e)for(let t of Object.keys(e))J(e,t)&&(n[t]=e[t]);return n}function V(n,e){for(let t in n)J(n,t)&&e(t,n[t])}function pe(n,e,t){if(!n)return n;arguments.length>2&&(e=e.bind(t));let r={};for(let i in n)J(n,i)&&(r[i]=e(n[i],i,n));return r}function Wn(n,e){return J(n,e)?n[e]:void 0}function Un(n,e){if(e||(e=new Array),!n||typeof n!="object"||n.constructor!==Object||e.indexOf(n)!==-1)return n;e.push(n);let t={};for(let r in n)J(n,r)&&(t[r]=Un(n[r],e));return t}function oi(n){let e=new Set;return JSON.stringify(n,(t,r)=>e.has(r)?"...":(typeof r=="object"&&e.add(r),r))}function Qn(n){return Tt(n)&&typeof n.then=="function"}function oo(){try{return Object.defineProperty(function(){},"length",{}),!0}catch(n){return!1}}var uo=oo();function un(n,e){uo&&Object.defineProperty(n,"length",e)}function _t(n){return n==null?"":n.trim?n.trim():n.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")}function ui(n,e){return n=n||"",e.length>n.length?!1:n.substring(0,e.length)===e}function ai(n){return typeof n=="string"&&(n=_t(n),n)?JSON.parse(n):null}var ao=typeof Symbol=="function";function z(n){return ao?Symbol(n):n}var Kn=/\S+/g;function nt(n,e,t){let r;e&&(typeof n.classList=="object"?(r=n.classList[t?"add":"remove"],P(e.match(Kn),function(i){r.call(n.classList,i)})):typeof n.className.baseVal=="string"?li(n.className,"baseVal",e,t):li(n,"className",e,t))}function li(n,e,t,r){let i=n[e].match(Kn)||[];P(t.match(Kn),function(s){we(i,s,r)}),n[e]=i.join(" ")}function qn(n,e){if(n===e)return!0;if(n.nodeType===Node.DOCUMENT_FRAGMENT_NODE)return!1;if(e.contains)return e.contains(n.nodeType!==Node.ELEMENT_NODE?n.parentNode:n);if(e.compareDocumentPosition)return(e.compareDocumentPosition(n)&16)==16;let t=n;for(;t&&t!=e;)t=t.parentNode;return!!t}function Ot(n){return qn(n,n.ownerDocument.documentElement)}function ci(n){return!!rn(n,Ot)}function R(n){return n&&n.tagName&&n.tagName.toLowerCase()}function di(n){return window.HTMLElement?n instanceof HTMLElement:n&&n.tagName&&n.nodeType===Node.ELEMENT_NODE}function Jn(n){return window.DocumentFragment?n instanceof DocumentFragment:n&&n.nodeType===Node.DOCUMENT_FRAGMENT_NODE}var zn={},fi={};zn.UIEvents=["keyup","keydown","keypress"];zn.MouseEvents=["click","dblclick","mousedown","mouseup","mousemove","mouseover","mouseout","mouseenter","mouseleave"];V(zn,function(n,e){if(e.length)for(let t=0,r=e.length;t<r;t++)fi[e[t]]=n});function lo(n,e){if(R(n)!=="input"||!n.type||e.toLowerCase()!="click")return!1;let t=n.type;return t=="checkbox"||t=="radio"}function K(n,e,t,r=!1){let i=Hn(t),s=!!r,o=c.jQuery;if(!c.useOnlyNativeEvents&&!s&&o)o(n).on(e,i);else if(typeof n.addEventListener=="function")n.addEventListener(e,i,r);else throw new Error("Browser doesn't support addEventListener")}function co(n){return typeof n.click=="function"}function Pe(n,e){if(!(n&&n.nodeType))throw new Error("element must be a DOM node when calling triggerEvent");let t=lo(n,e);if(!c.useOnlyNativeEvents&&c.jQuery&&!t)c.jQuery(n).trigger(e);else if(typeof document.createEvent=="function")if(typeof n.dispatchEvent=="function"){let r=fi[e]||"HTMLEvents",i=document.createEvent(r);i.initEvent(e,!0,!0,c.global,0,0,0,0,0,!1,!1,!1,!1,0,n),n.dispatchEvent(i)}else throw new Error("The supplied element doesn't support dispatchEvent");else if(t&&co(n))n.click();else throw new Error("Browser doesn't support triggering events")}var D={};Ge(D,{clear:()=>Xn,get:()=>Ve,getOrSet:()=>mo,nextKey:()=>It,set:()=>ye});var fo=new Date().getTime(),po=`__ko__${fo}`,an=Symbol("Knockout data");var ho=0;function Gn(n){return n!=="__proto__"&&n!=="constructor"&&n!=="prototype"}function Yn(n,e){let t=n[an];return!t&&e&&(t=n[an]={}),t}function Xn(n){return n[an]?(delete n[an],!0):!1}function It(){return ho+++po}function Ve(n,e){if(!Gn(e))throw new Error("Unsafe key for DOM data: "+e);let t=Yn(n,!1);return t&&t[e]}function ye(n,e,t){if(!Gn(e))throw new Error("Unsafe key for DOM data: "+e);let r=Yn(n,t!==void 0);r&&(r[e]=t)}function mo(n,e,t){if(!Gn(e))throw new Error("Unsafe key for DOM data: "+e);let r=Yn(n,!0);return r[e]||(r[e]=t)}var Zn=It(),go={1:!0,8:!0,9:!0},pi={1:!0,9:!0};function er(n,e){let t=Ve(n,Zn);return t===void 0&&e&&(t=new Array,ye(n,Zn,t)),t}function bo(n){ye(n,Zn,void 0)}function hi(n){let e=er(n,!1);if(e){e=e.slice(0);for(let t=0;t<e.length;t++)e[t](n)}Xn(n);for(let t=0,r=rt.length;t<r;++t)rt[t](n);c.cleanExternalData&&c.cleanExternalData(n),pi[n.nodeType]&&mi(n.childNodes,!0)}function mi(n,e){let t=new Array,r;for(let i=0;i<n.length;i++)if((!e||n[i].nodeType===Node.COMMENT_NODE)&&(hi(t[t.length]=r=n[i]),n[i]!==r))for(;i--&&j(t,n[i])===-1;);}function Ae(n,e){if(typeof e!="function")throw new Error("Callback must be a function");er(n,!0).push(e)}function it(n,e){let t=er(n,!1);t&&(Ze(t,e),t.length===0&&bo(n))}function G(n){return go[n.nodeType]&&(hi(n),pi[n.nodeType]&&n instanceof Element&&mi(n.getElementsByTagName("*"))),n}function he(n){n&&(G(n),n.parentNode&&n.parentNode.removeChild(n))}var rt=new Array;function gi(n){rt.push(n)}function bi(n){let e=rt.indexOf(n);e>=0&&rt.splice(e,1)}function Eo(n){let e=c.jQuery?c.jQuery.cleanData:null;e&&e([n])}rt.push(Eo);function kt(n){let e=ue(n),r=(e[0]&&e[0].ownerDocument||document).createElement("div");for(let i=0,s=e.length;i<s;i++)r.appendChild(G(e[i]));return r}function De(n,e){let t=new Array;for(let r=0;r<n.length;r++){let i=n[r].cloneNode(!0);t.push(e?G(i):i)}return t}function Ei(n,e){if(Mt(n),e)for(let t=0;t<e.length;t++)n.appendChild(e[t])}function ln(n,e){let t=Array.isArray(n)?n:[n];if(t.length>0){let r=t[0],i=r.parentNode;for(let s=0;s<e.length;s++)i==null||i.insertBefore(e[s],r);for(let s=0;s<t.length;s++)he(t[s])}}function Mt(n){for(;n.firstChild;)he(n.firstChild)}function Re(n,e){if(n.length){for(e=e.nodeType===Node.COMMENT_NODE&&e.parentNode||e;n.length&&n[0].parentNode!==e;)n.splice(0,1);for(;n.length>1&&n[n.length-1].parentNode!==e;)n.length--;if(n.length>1){let t=n[0],r=n[n.length-1];for(n.length=0;t!==r;)n.push(t),t=t.nextSibling;n.push(r)}}return n}function cn(n,e){n.selected=e}var y={};Ge(y,{allowedBindings:()=>Co,childNodes:()=>Ci,emptyNode:()=>dn,endCommentRegex:()=>yi,firstChild:()=>pn,getVirtualChildren:()=>nr,hasBindingValue:()=>xo,insertAfter:()=>vo,isEndComment:()=>Be,isStartComment:()=>ne,lastChild:()=>Fo,nextSibling:()=>hn,normaliseVirtualElementDomStructure:()=>No,prepend:()=>xi,previousSibling:()=>wo,setDomNodeChildren:()=>fn,startCommentRegex:()=>tr,virtualNodeBindingValue:()=>Bo});var tr=/^\s*ko(?:\s+([\s\S]+))?\s*$/,yi=/^\s*\/ko\s*$/,yo={ul:!0,ol:!0};function ne(n){return n.nodeType===Node.COMMENT_NODE&&tr.test(n.nodeValue)}function Be(n){return n.nodeType===Node.COMMENT_NODE&&yi.test(n.nodeValue)}function Ao(n){return Be(n)&&!Ve(n,Ai)}var Ai="__ko_matchedEndComment__";function nr(n,e){let t=n,r=1,i=new Array;for(;t=t.nextSibling;){if(Be(t)&&(ye(t,Ai,!0),r--,r===0))return i;i.push(t),ne(t)&&r++}if(!e)throw new Error("Cannot find closing comment tag to match: "+n.nodeValue);return null}function Di(n,e){let t=nr(n,e);return t?t.length>0?t[t.length-1].nextSibling:n.nextSibling:null}function Do(n){let e=n.firstChild,t=null;if(e)do if(t)t.push(e);else if(ne(e)){let r=Di(e,!0);r?e=r:t=[e]}else Be(e)&&(t=[e]);while(e=e.nextSibling);return t}var Co=Object.create(null),xo=ne;function Ci(n){return ne(n)?nr(n):n.childNodes}function dn(n){if(!ne(n))Mt(n);else{let e=Ci(n);for(let t=0,r=e.length;t<r;t++)he(e[t])}}function fn(n,e){if(!ne(n))Ei(n,e);else{dn(n);let t=n.nextSibling;if(t&&t.parentNode){let r=t.parentNode;for(let i=0,s=e.length;i<s;++i)r.insertBefore(e[i],t)}}}function xi(n,e){var t;ne(n)?(t=n.parentNode)==null||t.insertBefore(e,n.nextSibling):n.firstChild?n.insertBefore(e,n.firstChild):n.appendChild(e)}function vo(n,e,t){var r;t?ne(n)?(r=n.parentNode)==null||r.insertBefore(e,t.nextSibling):t.nextSibling?n.insertBefore(e,t.nextSibling):n.appendChild(e):xi(n,e)}function pn(n){if(!ne(n)){if(n.firstChild&&Be(n.firstChild))throw new Error("Found invalid end comment, as the first child of "+n.outerHTML);return n.firstChild}return!n.nextSibling||Be(n.nextSibling)?null:n.nextSibling}function Fo(n){let e=pn(n);if(!e)return null;let t;do t=e;while(e=hn(e));return t}function hn(n){if(ne(n)&&(n=Di(n)),n.nextSibling&&Be(n.nextSibling)){if(Ao(n.nextSibling))throw Error("Found end comment without a matching opening comment, as next sibling of "+n.outerHTML);return null}else return n.nextSibling}function wo(n){let e=0;do if(n.nodeType===Node.COMMENT_NODE)if(ne(n)){if(--e===0)return n}else Be(n)&&e++;else if(e===0)return n;while(n=n.previousSibling)}function Bo(n){let e=n.nodeValue.match(tr);return e?e[1]:null}function No(n){if(!yo[R(n)])return;let e=n.firstChild;if(e)do if(e.nodeType===Node.ELEMENT_NODE){let t=Do(e);if(t){let r=e.nextSibling;for(let i=0;i<t.length;i++)r?n.insertBefore(t[i],r):n.appendChild(t[i])}}while(e=e.nextSibling)}var vi=c.useTemplateTag&&c.document&&"content"in c.document.createElement("template");function So(n,e){e||(e=document);let t=e.createElement("div");return t.innerHTML=n,ue(t.childNodes)}function To(n,e){e||(e=document);let t=e.createElement("template");return t.innerHTML=n,ue(t.content.childNodes)}function _o(n,e){let t=c.jQuery;return t?t.parseHTML(n,e)||[]:[]}function le(n,e){let t=Fi(n);return vi?To(t,e):c.jQuery?_o(t,e):So(t,e)}var Oo=/<script\b[^>]*>([\s\S]*?)<\/script[^>]*>/i;function Fi(n){if(!n)return"";if(c.templateSizeLimit>0&&n.length>c.templateSizeLimit)throw new Error("Template is too long. Please configure the 'templateSizeLimit'");if(!c.allowScriptTagsInTemplates&&Oo.test(n))throw new Error("Script-tag in template detected.");return c.sanitizeHtmlTemplate(n)}function wi(n,e){let t=le(n,e);return t.length&&t[0].parentElement||kt(t)}function st(n,e){if(Mt(n),typeof e=="function"&&(e=e()),e!=null){typeof e!="string"&&(e=e.toString());let t=c.jQuery;if(t&&!vi){let r=Fi(e);t(n).html(r)}else{let r;if(n.ownerDocument?r=le(e,n.ownerDocument):r=le(e),n.nodeType===Node.COMMENT_NODE)e===null?dn(n):fn(n,r);else for(let i=0;i<r.length;i++)n.appendChild(r[i])}}}function Le(n,e){let t=typeof e=="function"?e():e;t==null&&(t="");let r=pn(n);!r||r.nodeType!==Node.TEXT_NODE||hn(r)?fn(n,[n.ownerDocument.createTextNode(t)]):r.data=t}var mn=Symbol("Knockout selectExtensions hasDomDataProperty"),O={optionValueDomDataKey:It(),readValue:function(n){switch(R(n)){case"option":return n[mn]===!0?Ve(n,O.optionValueDomDataKey):n.value;case"select":{let e=n;return e.selectedIndex>=0?O.readValue(e.options[e.selectedIndex]):void 0}default:return n.value}},writeValue:function(n,e,t){switch(R(n)){case"option":if(typeof e=="string")ye(n,O.optionValueDomDataKey,void 0),mn in n&&delete n[mn],n.value=e;else{let r=n;ye(n,O.optionValueDomDataKey,e),r[mn]=!0,r.value=typeof e=="number"?e:""}break;case"select":{(e===""||e===null)&&(e=void 0);let r=-1,i=n;for(let s=0,o=i.options.length,a;s<o;++s){a=O.readValue(i.options[s]);let u=a===e,l=a===""&&e===void 0,d=typeof e=="number"&&Number(a)===e;if(u||l||d){r=s;break}}(t||r>=0||e===void 0&&i.size>1)&&(i.selectedIndex=r)}break;default:e==null&&(e=""),n.value=e;break}}};var $e={};Ge($e,{memoize:()=>ko,parseMemoText:()=>Ti,unmemoize:()=>Si,unmemoizeDomNodeAndDescendants:()=>Mo});var rr={};function Bi(){return((1+Math.random())*4294967296|0).toString(16).substring(1)}function Io(){return Bi()+Bi()}function Ni(n,e){if(n){if(n.nodeType===Node.COMMENT_NODE){let r=Ti(n.nodeValue);r!=null&&e.push({domNode:n,memoId:r})}else if(n.nodeType===Node.ELEMENT_NODE)for(let t=0,r=n.childNodes,i=r.length;t<i;t++)Ni(r[t],e)}}function ko(n){if(typeof n!="function")throw new Error("You can only pass a function to memoization.memoize()");let e=Io();return rr[e]=n,"<!--[ko_memo:"+e+"]-->"}function Si(n,e){let t=rr[n];if(t===void 0)throw new Error("Couldn't find any memo with ID "+n+". Perhaps it's already been unmemoized.");try{return t.apply(null,e||[]),!0}finally{delete rr[n]}}function Mo(n,e){let t=new Array;Ni(n,t);for(let r=0,i=t.length;r<i;r++){let s=t[r].domNode,o=[s];e&&et(o,e),Si(t[r].memoId,o),s.nodeValue="",s.parentNode&&s.parentNode.removeChild(s)}}function Ti(n){if(!n)return null;let e=n.match(/^\[ko_memo\:(.*?)\]$/);return e?e[1]:null}var me={};Ge(me,{cancel:()=>Ro,resetForTesting:()=>Lo,runEarly:()=>Oi,schedule:()=>Vo});var Pt=new Array,re=0,_i=1,Ne=0,ot=c.global;ot&&ot.MutationObserver&&!(ot.navigator&&ot.navigator.standalone)?c.taskScheduler=(function(n){let e=ot.document.createElement("div");return new ot.MutationObserver(n).observe(e,{attributes:!0}),function(){e.classList.toggle("foo")}})(Ii):c.taskScheduler=function(n){setTimeout(n,0)};function Oi(){if(re){let n=re,e=0;for(let t;Ne<re;)if(t=Pt[Ne++]){if(Ne>n){if(++e>=5e3){Ne=re,jn(Error("'Too much recursion' after processing "+e+" task groups."));break}n=re}try{t()}catch(r){jn(r)}}}}function Ii(){Oi(),Ne=re=Pt.length=0}function Po(){c.taskScheduler(Ii)}function Vo(n){return re||Po(),Pt[re++]=n,_i++}function Ro(n){let e=n-(_i-re);e>=Ne&&e<re&&(Pt[e]=null)}function Lo(){let n=re-Ne;return Ne=re=Pt.length=0,n}var x={};Ge(x,{begin:()=>gn,end:()=>bn,getDependencies:()=>Uo,getDependenciesCount:()=>Wo,ignore:()=>jo,ignoreDependencies:()=>jo,isInitial:()=>Qo,registerDependency:()=>sr});var ir=Symbol("Knockout Subscribable");function ut(n){return n&&n[ir]||!1}var ki=new Array,ie,$o=0;function Ho(){return++$o}function gn(n){ki.push(ie),ie=n}function bn(){ie=ki.pop()}function sr(n){if(ie){if(!ut(n))throw new Error("Only subscribable things can act as dependencies");ie.callback.call(ie.callbackTarget,n,n._id||(n._id=Ho()))}}function jo(n,e,t){try{return gn(),n.apply(e,t||[])}finally{bn()}}function Wo(){if(ie)return ie.computed.getDependenciesCount()}function Uo(){if(ie)return ie.computed.getDependencies()}function Qo(){if(ie)return ie.isInitial}function Vt(n){n._deferUpdates||(n._deferUpdates=!0,n.limit(function(e){let t,r=!1;return function(){if(!r){me.cancel(t),t=me.schedule(e);try{r=!0,n.notifySubscribers(void 0,"dirty")}finally{r=!1}}}}))}var Rt=class{constructor(e,t,r){this._target=e,this._callback=t.next,this._disposeCallback=r,this._isDisposed=!1,this._domNodeDisposalCallback=null}dispose(){this._domNodeDisposalCallback&&it(this._node,this._domNodeDisposalCallback),this._isDisposed=!0,this._disposeCallback()}disposeWhenNodeIsRemoved(e){this._node=e,Ae(e,this._domNodeDisposalCallback=this.dispose.bind(this))}unsubscribe(){this.dispose()}get closed(){return this._isDisposed}};var Ko={undefined:1,boolean:1,number:1,string:1};function at(n,e){return n===null||typeof n in Ko?n===e:!1}function or(n){let e=this;return n&&V(n,function(t,r){let i=ge[t];typeof i=="function"?e=i(e,r)||e:c.onError(new Error("Extender not found: "+t))}),e}function qo(n,e){n.equalityComparer=e=="always"?null:at}function Jo(n,e){if(e!==!0)throw new Error("The 'deferred' extender only accepts the value 'true', because it is not supported to turn deferral off once enabled.");Vt(n)}function zo(n,e){let t,r,i;typeof e=="number"?t=e:(t=e.timeout,r=e.method),n._deferUpdates=!1,i=r==="notifyWhenChangesStop"?on:sn,n.limit(function(s){return i(s,t)})}var ge={notify:qo,deferred:Jo,rateLimit:zo};var Y=Symbol("Knockout latest value");Symbol.observable||(Symbol.observable=Symbol.for("@tko/Symbol.observable"));var W=function(){Object.setPrototypeOf(this,En),En.init(this)},Ce="change",En={[ir]:!0,[Symbol.observable](){return this},init(n){n._subscriptions={change:[]},n._versionNumber=1},subscribe(n,e,t){let r=typeof n=="object"&&n.next;t=t||Ce;let i=r?n:{next:e?n.bind(e):n},s=new Rt(this,i,()=>{Ze(this._subscriptions[t],s),this.afterSubscriptionRemove&&this.afterSubscriptionRemove(t)});return this.beforeSubscriptionAdd&&this.beforeSubscriptionAdd(t),this._subscriptions[t]||(this._subscriptions[t]=new Array),this._subscriptions[t].push(s),r&&Y in this&&i.next(this[Y]),s},notifySubscribers(n,e){if(e=e||Ce,e===Ce&&this.updateVersion(),this.hasSubscriptionsForEvent(e)){let t=e===Ce&&this._changeSubscriptions||[...this._subscriptions[e]];try{gn();for(let r=0,i;i=t[r];++r)i._isDisposed||i._callback(n)}finally{bn()}}},getVersion(){return this._versionNumber},hasChanged(n){return this.getVersion()!==n},updateVersion(){++this._versionNumber},hasSubscriptionsForEvent(n){return this._subscriptions[n]&&this._subscriptions[n].length},getSubscriptionsCount(n){if(n)return this._subscriptions[n]&&this._subscriptions[n].length||0;{let e=0;return V(this._subscriptions,function(t,r){t!=="dirty"&&(e+=r.length)}),e}},isDifferent(n,e){return!this.equalityComparer||!this.equalityComparer(n,e)},once(n){let e=this.subscribe(t=>{e.dispose(),n(t)})},when(n,e){let t=this.peek(),r=arguments.length>1,i=typeof n=="function"?n:s=>s===n;return i(t)?c.Promise.resolve(r?e:t):new c.Promise((s,o)=>{let a=this.subscribe(u=>{i(u)&&(a.dispose(),s(r?e:u))})})},yet(n,...e){let t=typeof n=="function"?n:i=>i===n,r=i=>!t(i);return this.when(r,...e)},next(){return new Promise(n=>this.once(n))},toString(){return"[object Object]"},extend:or};Object.setPrototypeOf(En,Function.prototype);W.fn=En;function w(n){function e(){return arguments.length>0?(e.isDifferent(e[Y],arguments[0])&&(e.valueWillMutate(),e[Y]=arguments[0],e.valueHasMutated()),this):(sr(e),e[Y])}return un(e,{value:void 0}),e[Y]=n,W.fn.init(e),Object.setPrototypeOf(e,w.fn),c.deferUpdates&&Vt(e),e}w.fn={equalityComparer:at,peek(){return this[Y]},valueHasMutated(){this.notifySubscribers(this[Y],"spectate"),this.notifySubscribers(this[Y])},valueWillMutate(){this.notifySubscribers(this[Y],"beforeChange")},modify(n,e=!0){this(n(e?this.peek():this()))},isWriteable:!0};function Go(n,e){!e||e===Ce?this._limitChange(n):e==="beforeChange"?this._limitBeforeChange(n):this._origNotifySubscribers(n,e)}W.fn.limit=function(e){let t=this,r=S(t),i="beforeChange",s,o,a,u,l;t._origNotifySubscribers||(t._origNotifySubscribers=t.notifySubscribers,t.notifySubscribers=Go);let d=e(function(){t._notificationIsPending=!1,r&&u===t&&(u=t._evalIfChanged?t._evalIfChanged():t());let p=o||l&&t.isDifferent(a,u);t._notifyNextChange=l=s=!1,p&&t._origNotifySubscribers(a=u)});Object.assign(t,{_limitChange(p,b){(!b||!t._notificationIsPending)&&(l=!b),t._changeSubscriptions=[...t._subscriptions[Ce]],t._notificationIsPending=s=!0,u=p,d()},_limitBeforeChange(p){s||(a=p,t._origNotifySubscribers(p,i))},_notifyNextChangeIfValueIsDifferent(){t.isDifferent(a,t.peek(!0))&&(o=!0)},_recordUpdate(){l=!0}})};Object.setPrototypeOf(w.fn,W.fn);var Mi=w.protoProperty=c.protoProperty;w.fn[Mi]=w;w.observablePrototypes=new Set([w]);function S(n){let e=typeof n=="function"&&n[Mi];if(e&&!w.observablePrototypes.has(e))throw Error("Invalid object that looks like an observable; possibly from another Knockout instance");return!!e}function f(n){return S(n)?n():n}function lt(n){return S(n)?n.peek():n}function Q(n){return S(n)&&n.isWriteable}var ct="arrayChange";function He(n,e){if(n.compareArrayOptions={},e&&typeof e=="object"&&L(n.compareArrayOptions,e),n.compareArrayOptions.sparse=!0,n.cacheDiffForKnownOperation)return;let t=!1,r=null,i,s=0,o,a=n.beforeSubscriptionAdd,u=n.afterSubscriptionRemove;n.beforeSubscriptionAdd=function(p){a&&a.call(n,p),p===ct&&l()},n.afterSubscriptionRemove=function(p){u&&u.call(n,p),p===ct&&!n.hasSubscriptionsForEvent(ct)&&(o&&(n.notifySubscribers=o,o=void 0),i&&i.dispose(),i=null,t=!1)};function l(){if(t)return;t=!0,o=n.notifySubscribers,n.notifySubscribers=function(b,m){return(!m||m===Ce)&&++s,o.apply(this,arguments)};let p=new Array().concat(n.peek()===void 0?[]:n.peek());r=null,i=n.subscribe(function(b){let m;b=new Array().concat(b||[]),n.hasSubscriptionsForEvent(ct)&&(m=d(p,b)),p=b,r=null,s=0,m&&m.length&&n.notifySubscribers(m,ct)})}function d(p,b){return(!r||s>1)&&(r=He.compareArrays(p,b,n.compareArrayOptions)),r}n.cacheDiffForKnownOperation=function(p,b,m){if(!t||s)return;let A=new Array,v=p.length,h=m.length,T=0;function k(g,N,C){return A[A.length]={status:g,value:N,index:C}}switch(b){case"push":T=v;case"unshift":for(let g=0;g<h;g++)k("added",m[g],T+g);break;case"pop":T=v-1;case"shift":v&&k("deleted",p[T],T);break;case"splice":{let g=Math.min(Math.max(0,m[0]<0?v+m[0]:m[0]),v),N=h===1?v:Math.min(g+(m[1]||0),v),C=g+h-2,_=Math.max(N,C),M=new Array,H=new Array;for(let te=g,Gr=2;te<_;++te,++Gr)te<N&&H.push(k("deleted",p[te],te)),te<C&&M.push(k("added",m[Gr],te));Ln(H,M)}break;default:return}r=A}}He.compareArrays=tt;ge.trackArrayChanges=He;function ce(n){if(n=n||[],typeof n!="object"||!("length"in n))throw new Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");let e=Object.setPrototypeOf(w(n),ce.fn);return He(e),un(e,{get:()=>{var t;return(t=e())==null?void 0:t.length}}),e}function Lt(n){return S(n)&&typeof n.remove=="function"&&typeof n.push=="function"}ce.fn={remove(n){let e=this.peek(),t=new Array,r=typeof n=="function"&&!S(n)?n:function(i){return i===n};for(let i=0;i<e.length;i++){let s=e[i];if(r(s)){if(t.length===0&&this.valueWillMutate(),e[i]!==s)throw Error("Array modified during remove; cannot remove item");t.push(s),e.splice(i,1),i--}}return t.length&&this.valueHasMutated(),t},removeAll(n){if(n===void 0){let e=this.peek(),t=e.slice(0);return this.valueWillMutate(),e.splice(0,e.length),this.valueHasMutated(),t}return n?this.remove(function(e){return j(n,e)>=0}):[]},destroy(n){let e=this.peek(),t=typeof n=="function"&&!S(n)?n:function(r){return r===n};this.valueWillMutate();for(let r=e.length-1;r>=0;r--){let i=e[r];t(i)&&(i._destroy=!0)}this.valueHasMutated()},destroyAll(n){return n===void 0?this.destroy(function(){return!0}):n?this.destroy(function(e){return j(n,e)>=0}):[]},indexOf(n){return j(this(),n)},replace(n,e){let t=this.indexOf(n);t>=0&&(this.valueWillMutate(),this.peek()[t]=e,this.valueHasMutated())},sorted(n){return[...this()].sort(n)},reversed(){return[...this()].reverse()},[Symbol.iterator]:function*(){yield*ke(this())}};Object.setPrototypeOf(ce.fn,w.fn);P(["pop","push","reverse","shift","sort","splice","unshift"],function(n){ce.fn[n]=function(){let e=this.peek();this.valueWillMutate(),this.cacheDiffForKnownOperation(e,n,arguments);let t=e[n].apply(e,arguments);return this.valueHasMutated(),t===e?this:t}});P(["slice"],function(n){ce.fn[n]=function(){let e=this();return e[n].apply(e,arguments)}});ce.trackArrayChanges=He;var Yo=10;function dt(n){if(arguments.length==0)throw new Error("When calling ko.toJS, pass the object you want to convert.");return Pi(n,function(e){for(let t=0;S(e)&&t<Yo;t++)e=e();return e})}function ur(n,e,t){let r=dt(n);return JSON.stringify(r,e,t)}function Pi(n,e,t=new Map){if(n=e(n),!(typeof n=="object"&&n!==null&&n!==void 0&&!(n instanceof RegExp)&&!(n instanceof Date)&&!(n instanceof String)&&!(n instanceof Number)&&!(n instanceof Boolean)))return n;let i=n instanceof Array?[]:{};return t.set(n,i),Xo(n,function(s){let o=e(n[s]);switch(typeof o){case"boolean":case"number":case"string":case"function":i[s]=o;break;case"object":case"undefined":{let a=t.get(o);i[s]=a!==void 0?a:Pi(o,e,t)}break}}),i}function Xo(n,e){if(n instanceof Array){for(let t=0;t<n.length;t++)e(t);typeof n.toJSON=="function"&&e("toJSON")}else for(let t in n)e(t)}function ar(){}function Zo(n,e){for(;typeof e=="function";)e=e();return e}var E={"@":Zo,"#":(n,e)=>()=>f(e),"=>":ar,"!":function(e,t){return!t},"!!":function(e,t){return!!t},"++":function(e,t){return++t},"--":function(e,t){return--t},"**":function(e,t){return Yr(e,t)},"*":function(e,t){return e*t},"/":function(e,t){return e/t},"%":function(e,t){return e%t},"+":function(e,t){return e+t},"-":function(e,t){return(e||0)-(t||0)},"&-":function(e,t){return-1*t},"<":function(e,t){return e<t},"<=":function(e,t){return e<=t},">":function(e,t){return e>t},">=":function(e,t){return e>=t},"==":function(e,t){return e==t},"!=":function(e,t){return e!=t},"===":function(e,t){return e===t},"!==":function(e,t){return e!==t},"&":function(e,t){return e&t},"^":function(e,t){return e^t},"|":function(e,t){return e|t},"&&":function(e,t){return e&&t},"||":function(e,t){return e||t},"??":function(e,t){return e!=null?e:t},".":function(e,t){return e==null?void 0:e[t]},"?.":function(e,t){return e==null?void 0:e[t]},"[":function(e,t){return e==null?void 0:e[t]},",":function(e,t){return t},call:function(e,t){return e.apply(null,t)}};E["@"].precedence=21;E["#"].precedence=21;E["."].precedence=19;E["["].precedence=19;E["?."].precedence=19;E["!"].precedence=16;E["!!"].precedence=16;E["++"].precedence=16;E["--"].precedence=16;E["&-"].precedence=16;E["**"].precedence=15;E["%"].precedence=14;E["*"].precedence=14;E["/"].precedence=14;E["+"].precedence=13;E["-"].precedence=13;E["|"].precedence=12;E["^"].precedence=11;E["&"].precedence=10;E["<"].precedence=11;E["<="].precedence=11;E[">"].precedence=11;E[">="].precedence=11;E["=="].precedence=10;E["!="].precedence=10;E["==="].precedence=10;E["!=="].precedence=10;E["&&"].precedence=6;E["||"].precedence=5;E["??"].precedence=5;E["&&"].earlyOut=n=>!n;E["||"].earlyOut=n=>n;E["??"].earlyOut=n=>n;E[","].precedence=2;E.call.precedence=1;E["=>"].precedence=1;var Vi=Symbol("Node - Is Expression Or Identifier"),F=class n{constructor(e,t,r){this.lhs=e,this.op=t,this.rhs=r}static get operators(){return E}get_leaf_value(e,t,r,i){return typeof e=="function"?f(e()):typeof e!="object"||e===null?e:e[n.isExpressionOrIdentifierSymbol]?f(e.get_value(void 0,t,r,i)):e}get_value(e,t,r,s){var s=this;if(s.op===ar)return(...l)=>{let d=t;return s.lhs&&(d=s.lhs.extendContext(t,l)),s.get_leaf_value(s.rhs,d,r,s)};let o=s.get_leaf_value(s.lhs,t,r,s),a=s.op.earlyOut;if(a&&a(o))return o;let u=s.get_leaf_value(s.rhs,t,r,s);return s.op(o,u,t,r)}static get isExpressionOrIdentifierSymbol(){return Vi}get[Vi](){return!0}static value_of(e,t,r,i){return e&&e[n.isExpressionOrIdentifierSymbol]?e.get_value(e,t,r,i):e}static create_root(e,t=!1){let r=new Array,i=new Array;for(let s=0;s<e.length;s+=2){r.push(e[s]);let o=e[s+1],a=(o==null?void 0:o.precedence)||0;for(;i.length&&a<=i[i.length-1].precedence;){let u=r.pop(),l=r.pop();r.push(new n(l,i.pop(),u))}i.push(o)}if(r.length!==1)throw new Error(`unexpected nodes remain in shunting yard output stack: ${r}`);return r[0]}};E["?"]=function(e,t,r,i,s){return F.value_of(e?t.yes:t.no,r,i,s)};E["?"].precedence=4;var Se=class{constructor(e){this.nodes=e,this.root=F.create_root(e)}get_value(e,t,r,i){return this.root||(this.root=F.create_root(this.nodes)),this.root.get_value(e,t,r,i)}};Se.prototype[F.isExpressionOrIdentifierSymbol]=!0;var be=class{constructor(e,t){this.parser=e,this.args=t}get_value(e,t,r,i){let s=new Array;for(let o=0,a=this.args.length;o<a;++o)s.push(F.value_of(this.args[o],t,r,i));return s}get[F.isExpressionOrIdentifierSymbol](){return!0}};var Ri=/[\$A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,Li=/[\$0-9A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/;var U=class n{constructor(e,t,r){this.token=t,this.dereferences=r,this.parser=e}dereference(e,t,r,i){let s,o=this.dereferences||[],a=t.$data||{},u,l,d;for(l=0,d=o.length;l<d;++l)if(s=F.value_of(o[l],t,r,i),typeof e=="function"&&o[l]instanceof be)e=e.apply(u||a,s),u=e;else{if(e==null)return e;u=e,e=F.value_of(e[s],t,r,i)}return typeof e=="function"&&d>0&&u!==e&&!J(u,s)?e.bind(u):e}get_value(e,t,r,i){let s=e&&!(e instanceof n)?F.value_of(e,t,r,i)[this.token]:t.lookup(this.token,r,i);return this.dereference(s,t,r,i)}assign(e,t,r){Q(e[t])?e[t](r):S(e[t])||(e[t]=r)}set_value(e,t,r){let i=t.$data||{},s=this.dereferences||[],o=this.token,a,u,l;if(Tt(i)&&o in i)l=i;else if(o in t)l=t;else if(o in r)l=r;else throw new Error("Identifier::set_value -- The property '"+o+"' does not exist on the $data, $context, or globals.");if(u=s.length,u===0){this.assign(l,o,e);return}for(l=l[o],a=0;a<u-1;++a)o=s[a],o instanceof be?l=l():l=l[F.value_of(o)];if(s[a]===!0)throw new Error("Cannot assign a value to a function.");s[a]&&this.assign(l,F.value_of(s[a]),e)}static is_valid_start_char(e){return Ri.test(e)}static is_valid_continue_char(e){return Li.test(e)}get[F.isExpressionOrIdentifierSymbol](){return!0}};var ft,lr=class lr{constructor(e,t){Zr(this,ft);t instanceof Se&&(t=t.root);try{ei(this,ft,lr.nodeTreeToNames(t))}catch(r){e.error(r)}}extendContext(e,t){if(Rn(this,ft)){let r={};return Rn(this,ft).forEach((i,s)=>{r[i]=t[s]}),e.extend(r)}else return e}get[F.isExpressionOrIdentifierSymbol](){return!0}static nodeTreeToNames(e){let t=new Array;for(;e;)if(e instanceof U)t.push(e.token),e=null;else if(this.isCommaNode(e))t.push(e.rhs.token),e=e.lhs;else throw new Error(`only simple identifiers allowed in lambda parameter list but found ${JSON.stringify(e,null,2)}`);return t.reverse(),t}static isCommaNode(e){return e instanceof F&&e.op===E[","]&&e.rhs instanceof U}};ft=new WeakMap;var $t=lr;var pt=class{constructor(e,t){Object.assign(this,{yes:e,no:t})}get_value(){return this}get[F.isExpressionOrIdentifierSymbol](){return!0}};var $i={"'":"'",'"':'"',"`":"`","\\":"\\","/":"/",$:"$",b:"\b",f:"\f",n:`
|
|
3
|
+
`,r:"\r",t:" "},Te=class{white(){let e=this.ch;for(;e&&e<=" ";)e=this.next();return this.comment(e)}comment(e){if(e!=="/")return e;let t=this.at,r=this.lookahead();if(r==="/"){for(;e&&(e=this.next(),!(e===`
|
|
4
|
+
`||e==="\r")););e=this.next()}else if(r==="*"){for(;e;)if(e=this.next(),e==="*"&&this.lookahead()==="/"){this.next();break}return e||this.error("Unclosed comment, starting at character "+t),this.next(),this.white()}return e}next(e){return e&&e!==this.ch&&this.error("Expected '"+e+"' but got '"+this.ch+"'"),this.ch=this.text.charAt(this.at),this.at+=1,this.ch}lookahead(){return this.text[this.at]}error(e){throw e instanceof Error?e:this.createError(e)}createError(e){let[t,r]=e.name?[e.name,e.message]:[e,""],i=`
|
|
5
|
+
${t} ${r} of ${this.text}
|
|
7
6
|
`+Array(this.at).join(" ")+`_/ \u{1F525} \\_
|
|
8
|
-
`;
|
|
9
|
-
`,"/(?:\\\\.|[^/])+/\\w*","[^\\s:,/][^"+
|
|
10
|
-
,`;var r=[],n=e.match(Ji),i,s=[],o=0;if(n.length<=1)return[];for(var u=0,a;a=n[u];++u){var l=a.charCodeAt(0);if(l===44){if(o<=0){r.push(i&&s.length?{key:i,value:s.join("")}:{unknown:i||s.join("")}),i=o=0,s=[];continue}}else if(l===58){if(!o&&!i&&s.length===1){i=s.pop();continue}}else{if(l===47&&a.length>1&&(a.charCodeAt(1)===47||a.charCodeAt(1)===42))continue;if(l===47&&u&&a.length>1){var f=n[u-1].match(vu);f&&!bu[f[0]]&&(e=e.substr(e.indexOf(a)+1),n=e.match(Ji),u=-1,a="/")}else l===40||l===123||l===91?++o:l===41||l===125||l===93?--o:!i&&!s.length&&(l===34||l===39)&&(a=a.slice(1,-1))}s.push(a)}return r}var k=z("_state"),yu={dependencyTracking:null,dependenciesCount:0,isDisposed:!0,isStale:!1,isDirty:!1,isSleeping:!1,disposeWhenNodeIsRemoved:null,readFunction:null,_options:null};function N(t,e,r){if(typeof t=="object"?r=t:(r=r||{},t&&(r.read=t)),typeof r.read!="function")throw Error("Pass a function that returns the value of the computed");var n=r.write,i={latestValue:void 0,isStale:!0,isDirty:!0,isBeingEvaluated:!1,suppressDisposalUntilDisposeWhenReturnsFalse:!1,isDisposed:!1,pure:!1,isSleeping:!1,readFunction:r.read,evaluatorFunctionTarget:e||r.owner,disposeWhenNodeIsRemoved:r.disposeWhenNodeIsRemoved||r.disposeWhenNodeIsRemoved||null,disposeWhen:r.disposeWhen||r.disposeWhen,domNodeDisposalCallback:null,dependencyTracking:{},dependenciesCount:0,evaluationTimeoutInstance:null};function s(){if(arguments.length>0){if(typeof n=="function")n.apply(i.evaluatorFunctionTarget,arguments);else throw new Error("Cannot write a value to a computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");return this}else return i.isDisposed||C.registerDependency(s),(i.isDirty||i.isSleeping&&s.haveDependenciesChanged())&&s.evaluateImmediate(),i.latestValue}return s[k]=i,s.isWriteable=typeof n=="function",K.fn.init(s),Object.setPrototypeOf(s,N.fn),r.pure?(i.pure=!0,i.isSleeping=!0,L(s,Cu)):r.deferEvaluation&&L(s,xu),c.deferUpdates&&Ae.deferred(s,!0),c.debug&&(s._options=r),i.disposeWhenNodeIsRemoved&&(i.suppressDisposalUntilDisposeWhenReturnsFalse=!0,i.disposeWhenNodeIsRemoved.nodeType||(i.disposeWhenNodeIsRemoved=null)),!i.isSleeping&&!r.deferEvaluation&&s.evaluateImmediate(),i.disposeWhenNodeIsRemoved&&s.isActive()&&de(i.disposeWhenNodeIsRemoved,i.domNodeDisposalCallback=function(){s.dispose()}),s}function Au(t,e){e!==null&&e.dispose&&e.dispose()}function Eu(t,e){var r=this.computedObservable,n=r[k];n.isDisposed||(this.disposalCount&&this.disposalCandidates[e]?(r.addDependencyTracking(e,t,this.disposalCandidates[e]),this.disposalCandidates[e]=null,--this.disposalCount):n.dependencyTracking[e]||r.addDependencyTracking(e,t,n.isSleeping?{_target:t}:r.subscribeToDependency(t)),t._notificationIsPending&&t._notifyNextChangeIfValueIsDifferent())}N.fn={equalityComparer:gt,getDependenciesCount(){return this[k].dependenciesCount},getDependencies(){let t=this[k].dependencyTracking,e=[];return O(t,function(r,n){e[n._order]=n._target}),e},addDependencyTracking(t,e,r){if(this[k].pure&&e===this)throw Error("A 'pure' computed must not be called recursively");this[k].dependencyTracking[t]=r,r._order=this[k].dependenciesCount++,r._version=e.getVersion()},haveDependenciesChanged(){var t,e,r=this[k].dependencyTracking;for(t in r)if(Y(r,t)&&(e=r[t],this._evalDelayed&&e._target._notificationIsPending||e._target.hasChanged(e._version)))return!0},markDirty(){this._evalDelayed&&!this[k].isBeingEvaluated&&this._evalDelayed(!1)},isActive(){let t=this[k];return t.isDirty||t.dependenciesCount>0},respondToChange(){this._notificationIsPending?this[k].isDirty&&(this[k].isStale=!0):this.evaluatePossiblyAsync()},subscribeToDependency(t){if(t._deferUpdates){var e=t.subscribe(this.markDirty,this,"dirty"),r=t.subscribe(this.respondToChange,this);return{_target:t,dispose(){e.dispose(),r.dispose()}}}else return t.subscribe(this.evaluatePossiblyAsync,this)},evaluatePossiblyAsync(){var t=this,e=t.throttleEvaluation;e&&e>=0?(clearTimeout(this[k].evaluationTimeoutInstance),this[k].evaluationTimeoutInstance=ce(function(){t.evaluateImmediate(!0)},e)):t._evalDelayed?t._evalDelayed(!0):t.evaluateImmediate(!0)},evaluateImmediate(t){var e=this,r=e[k],n=r.disposeWhen,i=!1;if(!r.isBeingEvaluated&&!r.isDisposed){if(r.disposeWhenNodeIsRemoved&&!Mt(r.disposeWhenNodeIsRemoved)||n&&n()){if(!r.suppressDisposalUntilDisposeWhenReturnsFalse){e.dispose();return}}else r.suppressDisposalUntilDisposeWhenReturnsFalse=!1;r.isBeingEvaluated=!0;try{i=this.evaluateImmediate_CallReadWithDependencyDetection(t)}finally{r.isBeingEvaluated=!1}return i}},evaluateImmediate_CallReadWithDependencyDetection(t){var e=this,r=e[k],n=!1,i=r.pure?void 0:!r.dependenciesCount,s={computedObservable:e,disposalCandidates:r.dependencyTracking,disposalCount:r.dependenciesCount};C.begin({callbackTarget:s,callback:Eu,computed:e,isInitial:i}),r.dependencyTracking={},r.dependenciesCount=0;var o=this.evaluateImmediate_CallReadThenEndDependencyDetection(r,s);return r.dependenciesCount?n=e.isDifferent(r.latestValue,o):(e.dispose(),n=!0),n&&(r.isSleeping?e.updateVersion():e.notifySubscribers(r.latestValue,"beforeChange"),r.latestValue=o,c.debug&&(e._latestValue=o),e.notifySubscribers(r.latestValue,"spectate"),!r.isSleeping&&t&&e.notifySubscribers(r.latestValue),e._recordUpdate&&e._recordUpdate()),i&&e.notifySubscribers(r.latestValue,"awake"),n},evaluateImmediate_CallReadThenEndDependencyDetection(t,e){try{var r=t.readFunction;return t.evaluatorFunctionTarget?r.call(t.evaluatorFunctionTarget):r()}finally{C.end(),e.disposalCount&&!t.isSleeping&&O(e.disposalCandidates,Au),t.isStale=t.isDirty=!1}},peek(t){let e=this[k];return(e.isDirty&&(t||!e.dependenciesCount)||e.isSleeping&&this.haveDependenciesChanged())&&this.evaluateImmediate(),e.latestValue},get[Z](){return this.peek()},limit(t){let e=this[k];K.fn.limit.call(this,t),Object.assign(this,{_evalIfChanged(){return this[k].isSleeping||(this[k].isStale?this.evaluateImmediate():this[k].isDirty=!1),e.latestValue},_evalDelayed(r){this._limitBeforeChange(e.latestValue),e.isDirty=!0,r&&(e.isStale=!0),this._limitChange(this,!r)}})},dispose(){var t=this[k];!t.isSleeping&&t.dependencyTracking&&O(t.dependencyTracking,function(e,r){r.dispose&&r.dispose()}),t.disposeWhenNodeIsRemoved&&t.domNodeDisposalCallback&&pt(t.disposeWhenNodeIsRemoved,t.domNodeDisposalCallback),Object.assign(t,yu)}};var Cu={beforeSubscriptionAdd(t){var e=this,r=e[k];if(!r.isDisposed&&r.isSleeping&&t==="change"){if(r.isSleeping=!1,r.isStale||e.haveDependenciesChanged())r.dependencyTracking=null,r.dependenciesCount=0,e.evaluateImmediate()&&e.updateVersion();else{var n=[];O(r.dependencyTracking,function(i,s){n[s._order]=i}),I(n,function(i,s){var o=r.dependencyTracking[i],u=e.subscribeToDependency(o._target);u._order=s,u._version=o._version,r.dependencyTracking[i]=u}),e.haveDependenciesChanged()&&e.evaluateImmediate()&&e.updateVersion()}r.isDisposed||e.notifySubscribers(r.latestValue,"awake")}},afterSubscriptionRemove(t){var e=this[k];!e.isDisposed&&t==="change"&&!this.hasSubscriptionsForEvent("change")&&(O(e.dependencyTracking,function(r,n){n.dispose&&(e.dependencyTracking[r]={_target:n._target,_order:n._order,_version:n._version},n.dispose())}),e.isSleeping=!0,this.notifySubscribers(void 0,"asleep"))},getVersion(){var t=this[k];return t.isSleeping&&(t.isStale||this.haveDependenciesChanged())&&this.evaluateImmediate(),K.fn.getVersion.call(this)}},xu={beforeSubscriptionAdd(t){(t==="change"||t==="beforeChange")&&this.peek()}};Object.setPrototypeOf(N.fn,K.fn);var Gi=S.protoProperty;N.fn[Gi]=N;S.observablePrototypes.add(N);function Ct(t){return typeof t=="function"&&t[Gi]===N}function yn(t){return Ct(t)&&t[k]&&t[k].pure}function we(t,e){return typeof t=="function"?N(t,e,{pure:!0}):(t=L({},t),t.pure=!0,N(t,e))}function Yi(t,e){t.throttleEvaluation=e;var r=null;return N({read:t,write:function(n){clearTimeout(r),r=setTimeout(function(){t(n)},e)}})}Ae.throttle=Yi;var Xi=Symbol("Knockout Proxied Object"),Zi=Symbol("Knockout Proxied Observables");function Du(t,e){return N({owner:t,read:e,write:e,pure:"pure"in e?e.pure:!0,deferEvaluation:"deferEvaluation"in e?e.deferEvaluation:!0}).extend({deferred:!0})}function es(t,e,r,n){if(t[e])t[e](r);else{let i=Array.isArray(r)?fe:typeof r=="function"?Du.bind(null,n):S;t[e]=i(r)}}function zi(t,e,r){for(let n of Object.keys(e))es(t,n,e[n],r);return e}function kr(t){let e={[Xi]:t};e[Zi]=e;let r=new Proxy(function(){},{has(n,i){return i in e},get(n,i){return d(e[i])},set(n,i,s,o){return es(e,i,s,r),t[i]=s,!0},deleteProperty(n){return delete e[n],delete t[n]},apply(n,i,[s]){return s?(zi(e,s,r),Object.assign(t,s)):t},getPrototypeOf(){return Object.getPrototypeOf(t)},setPrototypeOf(n,i){return Object.setPrototypeOf(t,i)},defineProperty(n,i,s){return Object.defineProperty(t,i,s)},preventExtensions(){return Object.preventExtensions(t)},isExtensible(){return Object.isExtensible(t)},ownKeys(){return[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)]}});return zi(e,t,r),r}function ts(t,e){return t[Zi][e]}function Fu(t,e){return ts(t,e).peek()}function Bu(t){return Xi in t}Object.assign(kr,{getObservable:ts,peek:Fu,isProxied:Bu});function wu(t,e,r){let n=we(t,e).extend({notify:"always"}),i=n.subscribe(s=>{s&&(i.dispose(),r(s))});return n.notifySubscribers(n.peek()),i}function An(t,e,r){let n=wu.bind(null,t,r);return e?n(e.bind(r)):new Promise(n)}var Gt=z("LifeCycle Subscriptions List"),xt=z("LifeCycle Anchor Node"),G=class{static mixInto(e){let r=e.prototype||e,n=G.prototype;for(let i of Object.getOwnPropertyNames(n))r[i]=n[i]}subscribe(e,r,n){typeof r=="string"&&(r=this[r]),this.addDisposable(e.subscribe(r,this,n))}computed(e){if(typeof e=="string"&&(e={read:this[e],write:this[e]}),typeof e=="object")e=Object.assign({owner:this},e);else if(typeof e=="function"){let r=Object.getPrototypeOf(this);r&&r[e.name]===e&&(e=e.bind(this)),e={read:e,write:e}}else throw new Error("LifeCycle::computed not given a valid type.");return e.disposeWhenNodeIsRemoved=this[xt],this.addDisposable(N(e))}addEventListener(...e){let r=e[0].nodeType?e.shift():this[xt],[n,i,s]=e,o=typeof i=="string"?this[i].bind(this):i;this.__addEventListener(r,n,o,s)}__addEventListener(e,r,n,i){e.addEventListener(r,n,i);function s(){e.removeEventListener(r,n)}de(e,s),this.addDisposable({dispose:s})}anchorTo(e){"addDisposable"in e?(e.addDisposable(this),this[xt]=null):(this[xt]=e,de(e,()=>this[xt]===e&&this.dispose()))}dispose(){(this[Gt]||[]).forEach(r=>r.dispose()),this[Gt]=[],this[xt]=null}addDisposable(e){let r=this[Gt]||[];if(this[Gt]||(this[Gt]=r),typeof e.dispose!="function")throw new Error("Lifecycle::addDisposable argument missing `dispose`.");return r.push(e),e}};var Ir=Symbol("_ancestorBindingInfo"),rs=y.nextKey(),W={childrenComplete:"childrenComplete",descendantsComplete:"descendantsComplete",subscribe(t,e,r,n){let i=y.getOrSet(t,rs,{});return i.eventSubscribable||(i.eventSubscribable=new K),i.eventSubscribable.subscribe(r,n,e)},notify(t,e){let r=y.get(t,rs);r&&r.eventSubscribable&&r.eventSubscribable.notifySubscribers(t,e)}};var En=y.nextKey(),$e=Symbol("Knockout Context Subscription"),ns=Symbol("Knockout Parent Indicator");function Se(t,e,r,n,i){let s=this,o=t===ns,u=o?void 0:t,a=typeof u=="function"&&!T(u);s.ko=c.knockoutInstance;let l,f;function m(){let h=a?u():u,p=d(h);return e?(e[$e]&&e[$e](),L(s,e),Ir in e&&(s[Ir]=e[Ir])):(s.$parents=[],s.$root=p),s[$e]=f,o?p=s.$data:(s.$rawData=h,s.$data=p),r&&(s[r]=p),n&&n(s,e,p),s.$data}i&&i.exportDependencies?m():(f=we(m),f.peek(),f.isActive()?(s[$e]=f,f.equalityComparer=null):s[$e]=void 0)}Object.assign(Se.prototype,{lookup(t,e,r){switch(t){case"$element":return r;case"$context":return this;case"this":case"$data":return this.$data}let n=this.$data;if(Rt(n)&&t in n)return n[t];if(t in this)return this[t];if(t in e)return e[t];throw new Error(`The variable "${t}" was not found on $data, $context, or globals.`)},createChildContext(t,e,r,n){return new Se(t,this,e,function(i,s){i.$parentContext=s,i.$parent=s.$data,i.$parents=(s.$parents||[]).slice(0),i.$parents.unshift(i.$parent),r&&r(i)},n)},extend(t){return new Se(ns,this,null,function(e,r){L(e,typeof t=="function"?t.call(e):t)})},createStaticChildContext(t,e){return this.createChildContext(t,e,null,{exportDependencies:!0})}});function Su(t){let e=y.get(t,En);return e&&e.context}function Ne(t){if(t&&(t.nodeType===1||t.nodeType===8))return Su(t)}function Or(t){var e=Ne(t);return e?e.$data:void 0}var Nu=(t,e,r)=>new Promise((n,i)=>{var s=a=>{try{u(r.next(a))}catch(l){i(l)}},o=a=>{try{u(r.throw(a))}catch(l){i(l)}},u=a=>a.done?n(a.value):Promise.resolve(a.value).then(s,o);u((r=r.apply(t,e)).next())}),Dt=class{constructor({asyncBindingsApplied:e,rootNode:r,bindingContext:n}){Object.assign(this,{rootNode:r,bindingContext:n,isSync:e.size===0,isComplete:this.isSync}),this.isSync||(this.completionPromise=this.completeWhenBindingsFinish(e))}completeWhenBindingsFinish(e){return Nu(this,null,function*(){return yield Promise.all(e),this.isComplete=!0,this})}};var ee=class extends G{constructor(e){super();let{$element:r,valueAccessor:n,allBindings:i,$context:s}=e;Object.assign(this,{valueAccessor:n,allBindings:i,$element:r,$context:s,$data:s.$data}),this.anchorTo(r)}get value(){return this.valueAccessor()}set value(e){let r=this.valueAccessor();te(r)?r(e):this.valueAccessor(e)}get controlsDescendants(){return!1}static get allowVirtualElements(){return!1}static get isBindingHandlerClass(){return!0}get bindingCompleted(){return!0}static registerAs(e,r=c.bindingProviderInstance){r.bindingHandlers.set(e,this)}},is=Symbol("Async Binding Resolved"),re=class extends ee{constructor(e){super(e),this.bindingCompletion=new Promise(r=>{this[is]=r}),this.completeBinding=r=>this[is](r)}get bindingCompleted(){return this.bindingCompletion}};var Tu=c.global.WeakMap||Map,Cn=new Tu,Xe=class extends ee{constructor(e){super(e);let r=this.handler;this.onError=e.onError,typeof r.dispose=="function"&&this.addDisposable(r);try{this.initReturn=r.init&&r.init(...this.legacyArgs)}catch(n){e.onError("init",n)}}onValueChange(){let e=this.handler;if(typeof e.update=="function")try{e.update(...this.legacyArgs)}catch(r){this.onError("update",r)}}get legacyArgs(){return[this.$element,this.valueAccessor,this.allBindings,this.$data,this.$context]}get controlsDescendants(){return(this.initReturn||this.handler||{}).controlsDescendantBindings}static getOrCreateFor(e,r){if(Cn.has(r))return Cn.get(r);let n=this.createFor(e,r);return Cn.set(r,n),n}static createFor(e,r){if(typeof r=="function"){let[n,i]=[r,r.dispose];return class extends Xe{get handler(){let s=n.bind(this),o=i?i.bind(this):null;return{init:s,dispose:o}}static get after(){return r.after}static get allowVirtualElements(){return r.allowVirtualElements||v.allowedBindings[e]}}}if(typeof r=="object")return class extends Xe{get handler(){return r}static get after(){return r.after}static get allowVirtualElements(){return r.allowVirtualElements||v.allowedBindings[e]}};throw new Error("The given handler is not an appropriate type.")}};var _u={script:!0,textarea:!0,template:!0};function zt(){return c.bindingProviderInstance.instance||c.bindingProviderInstance}function os(t,e){return(t.FOR_NODE_TYPES||[1,3,8]).includes(e.nodeType)}function us(t,e){if(!!t)return t.isBindingHandlerClass?t:Xe.getOrCreateFor(e,t)}function ku(t,e){if(!(!e||typeof e.getBindingHandler!="function"))return us(e.getBindingHandler(t))}function Iu(t){let e=c.getBindingHandler(t)||zt().bindingHandlers.get(t);return us(e,t)}function Yt(t){return t()}function as(t,e,r){let n=v.firstChild(e);if(!n)return;let i,s=zt(),o=s.preprocessNode;if(o){for(;i=n;)n=v.nextSibling(i),o.call(s,i);n=v.firstChild(e)}for(;i=n;)n=v.nextSibling(i),ds(t,i,r);W.notify(e,W.childrenComplete)}function ls(t){let e=zt();return os(e,t)&&e.nodeHasBindings(t)}function cs(t){return ls(t)||[...t.childNodes].some(e=>cs(e))}function ds(t,e,r){var n=e.nodeType===1;n&&v.normaliseVirtualElementDomStructure(e);let i=n||ls(e),{shouldBindDescendants:s}=i?fs(e,null,t,r):{shouldBindDescendants:!0};s&&!_u[V(e)]&&as(t,e,r)}function*Ou(t,e){let r=[],n={},i=[];O(t,function s(o){if(!n[o]){let u=ku(o,e)||Iu(o);if(!u)return;u.after&&(i.push(o),I(u.after,function(a){if(!!t[a]){if(U(i,a)!==-1)throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+i.join(", "));s(a)}}),i.length--),r.push([o,u])}n[o]=!0});for(let s of r)yield s}function fs(t,e,r,n){let i=y.getOrSet(t,En,{}),s=i.alreadyBound;if(!e){if(s)return cs(t)&&ss({during:"apply",errorCaptured:new Error("You cannot apply bindings multiple times to the same element."),element:t,bindingContext:r}),!1;i.alreadyBound=!0}s||(i.context=r);var o;if(e&&typeof e!="function")o=e;else{let h=zt(),p=h.getBindingAccessors;if(os(h,t)){var u=N(function(){return o=e?e(r,t):p.call(h,t,r),o&&r[$e]&&r[$e](),o},null,{disposeWhenNodeIsRemoved:t});(!o||!u.isActive())&&(u=null)}}var a;if(o){let h=function(){return ge(u?u():o,Yt)};var l=h;let p=r.$component||{},A={};y.set(t,"bindingHandlers",A);let x=u?F=>function(E){let B=u()[F];return arguments.length===0?Yt(B):B(E)}:F=>o[F];h.has=F=>F in o,h.get=F=>o[F]&&Yt(x(F)),W.childrenComplete in o&&W.subscribe(t,W.childrenComplete,()=>{let F=Yt(o[W.childrenComplete]);if(!F)return;let E=v.childNodes(t);E.length&&F(E,Or(E[0]))});let b=Ou(o,p),P=new Set;for(let[F,E]of b){let B=function(w,R){ss({during:w,errorCaptured:R,bindings:o,allBindings:h,bindingKey:F,bindingContext:r,element:t,valueAccessor:x(F)})};var f=B;if(t.nodeType===8&&!E.allowVirtualElements)throw new Error(`The binding '${F}' cannot be used with virtual elements`);try{let w=C.ignore(()=>new E({allBindings:h,$element:t,$context:r,onError:B,valueAccessor(...R){return x(F)(...R)}}));if(w.onValueChange&&C.ignore(()=>w.computed("onValueChange")),A[F]=w,w.controlsDescendants){if(a!==void 0)throw new Error("Multiple bindings ("+a+" and "+F+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");a=F}w.bindingCompleted instanceof Promise&&(n.add(w.bindingCompleted),P.add(w.bindingCompleted))}catch(w){B("creation",w)}}Pu(t,o,P)}return{shouldBindDescendants:a===void 0}}function Pu(t,e,r){let n=W.descendantsComplete in e,i=v.firstChild(t),s=n&&Yt(e[W.descendantsComplete]),o=()=>{W.notify(t,W.descendantsComplete),s&&i&&s(t)};r.size?Promise.all(r).then(o):o()}function Pr(t,e){return t&&t instanceof Se?t:new Se(t,void 0,void 0,e)}function Xt(t,e,r,n){return t.nodeType===1&&v.normaliseVirtualElementDomStructure(t),fs(t,e,Pr(r),n)}function ps(t,e,r){let n=new Set,i=Pr(r),s=zt().makeBindingAccessors(e,i,t);return Xt(t,s,i,n),new Dt({asyncBindingsApplied:n,rootNode:t,bindingContext:i})}function ue(t,e){let r=new Set;if(e.nodeType===1||e.nodeType===8){let n=Pr(t);return as(n,e,r),new Dt({asyncBindingsApplied:r,rootNode:e,bindingContext:n})}return new Dt({asyncBindingsApplied:r,rootNode:e})}function Ft(t,e,r){let n=new Set;if(!c.jQuery===void 0&&c.jQuery&&(c.jQuery=c.jQuery),e){if(e.nodeType!==1&&e.nodeType!==8)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node")}else if(e=window.document.body,!e)throw Error("ko.applyBindings: could not find window.document.body; has the document been loaded?");let i=Pr(t,r);return ds(i,e,n),Promise.all(n)}function ss(t){var e,r;t.bindingKey?(e=t.errorCaptured,t.message='Unable to process binding "'+t.bindingKey+'" in binding "'+t.bindingKey+`"
|
|
11
|
-
Message: `+(e.message?e.message:e)):e=t.errorCaptured;try{L(e,t)}catch(n){t.stack=e.stack,e=new Error(e.message?e.message:e),L(e,t)}c.onError(e)}function Vu(t,e,r,n,i){var s=[],o=N(function(){var u=e(r,i,qe(s,t))||[];s.length>0&&(Er(s,u),n&&C.ignore(n,null,[r,u,i])),s.length=0,lt(s,u)},null,{disposeWhenNodeIsRemoved:t,disposeWhen:function(){return!fi(s)}});return{mappedNodes:s,dependentObservable:o.isActive()?o:void 0}}var hs=y.nextKey(),ms=y.nextKey();function Bt(t,e,r,n,i,s){e=e||[],typeof e.length=="undefined"&&(e=[e]),n=n||{};let o=y.get(t,hs),u=!o;var a=[],l=0,f=0,m=[],h=[],p=[],A=[],x=[],b;let P=0;function F(Ce){b={arrayEntry:Ce,indexObservable:S(f++)},a.push(b),h.push(b),u||x.push(b)}function E(Ce){b=o[Ce],f!==Ce&&A.push(b),b.indexObservable(f++),qe(b.mappedNodes,t),a.push(b),h.push(b)}function B(Ce,qr){if(Ce)for(var Pt=0,uo=qr.length;Pt<uo;Pt++)I(qr[Pt].mappedNodes,function(ao){Ce(ao,Pt,qr[Pt].arrayEntry)})}if(u)I(e,F);else{if(!s||o&&o._countWaitingForRemove){var w=u?[]:ut(o,function(Ce){return Ce.arrayEntry}),R={dontLimitMoves:n.dontLimitMoves,sparse:!0};s=ct(w,e,R)}for(var M=0,ne,H,Ie;ne=s[M];M++)switch(H=ne.moved,Ie=ne.index,ne.status){case"deleted":for(;l<Ie;)E(l++);H===void 0&&(b=o[l],b.dependentObservable&&(b.dependentObservable.dispose(),b.dependentObservable=void 0),qe(b.mappedNodes,t).length&&(n.beforeRemove&&(a.push(b),h.push(b),P++,b.arrayEntry===ms?b=null:p.push(b)),b&&m.push.apply(m,b.mappedNodes))),l++;break;case"added":for(;f<Ie;)E(l++);H!==void 0?E(H):F(ne.value);break}for(;f<e.length;)E(l++);a._countWaitingForRemove=P}y.set(t,hs,a),B(n.beforeMove,A),I(m,n.beforeRemove?X:ve),M=0;for(var pr=v.firstChild(t),ti,Ot;b=h[M];M++){b.mappedNodes||L(b,Vu(t,r,b.arrayEntry,i,b.indexObservable));for(var ri=0;Ot=b.mappedNodes[ri];pr=Ot.nextSibling,ti=Ot,ri++)Ot!==pr&&v.insertAfter(t,Ot,ti);!b.initialized&&i&&(i(b.arrayEntry,b.mappedNodes,b.indexObservable),b.initialized=!0)}for(B(n.beforeRemove,p),M=0;M<p.length;++M)p[M].arrayEntry=ms;B(n.afterMove,A),B(n.afterAdd,x)}var Ru=(t,e,r)=>new Promise((n,i)=>{var s=a=>{try{u(r.next(a))}catch(l){i(l)}},o=a=>{try{u(r.throw(a))}catch(l){i(l)}},u=a=>a.done?n(a.value):Promise.resolve(a.value).then(s,o);u((r=r.apply(t,e)).next())}),Ze=class extends re{get controlsDescendants(){return!0}applyBindingsToDescendants(e,r){return Ru(this,null,function*(){let n=ue(e,this.$element);n.isSync?this.bindingCompletion=n:yield n.completionPromise,r&&r(n),this.completeBinding(n)})}};var vs=1,bs=2,ys=3,As=4;function Le(t){if(this.domElement=t,!!t){var e=V(t);this.templateType=e==="script"?vs:e==="textarea"?bs:e=="template"&&t.content&&t.content.nodeType===11?ys:As}}Le.prototype.text=function(){var t=this.templateType===vs?"text":this.templateType===bs?"value":"innerHTML";if(arguments.length==0)return this.domElement[t];var e=arguments[0];t==="innerHTML"?ht(this.domElement,e):this.domElement[t]=e};var gs=y.nextKey()+"_";Le.prototype.data=function(t){if(arguments.length===1)return y.get(this.domElement,gs+t);y.set(this.domElement,gs+t,arguments[1])};var Es=y.nextKey();function Cs(t){return y.get(t,Es)||{}}function xn(t,e){y.set(t,Es,e)}Le.prototype.nodes=function(){var t=this.domElement;if(arguments.length==0){let r=Cs(t),n=r.containerData||(this.templateType===ys?t.content:this.templateType===As?t:void 0);if(!n||r.alwaysCheckText){let i=this.text();i&&(n=ki(i,t.ownerDocument),this.text(""),xn(t,{containerData:n,alwaysCheckText:!0}))}return n}else{var e=arguments[0];xn(t,{containerData:e})}};function pe(t){this.domElement=t}pe.prototype=new Le;pe.prototype.constructor=pe;pe.prototype.text=function(){if(arguments.length==0){var t=Cs(this.domElement);return t.textData===void 0&&t.containerData&&(t.textData=t.containerData.innerHTML),t.textData}else{var e=arguments[0];xn(this.domElement,{textData:e})}};function et(){}L(et.prototype,{renderTemplateSource:function(t,e,r,n){r.onError("Override renderTemplateSource")},createJavaScriptEvaluatorBlock:function(t){c.onError("Override createJavaScriptEvaluatorBlock")},makeTemplateSource:function(t,e){if(typeof t=="string"){e=e||document;var r=e.getElementById(t);return r||c.onError("Cannot find template with ID "+t),new Le(r)}else{if(t.nodeType==1||t.nodeType==8)return new pe(t);c.onError("Unknown template type: "+t)}},renderTemplate:function(t,e,r,n){var i=this.makeTemplateSource(t,n);return this.renderTemplateSource(i,e,r,n)}});var Bn,xs=y.nextKey();function Vr(t){if(t!==void 0&&!(t instanceof et))throw new Error("templateEngine must inherit from ko.templateEngine");Bn=t}function Dn(t,e,r){let n,i=t,s=v.nextSibling(e);for(;i&&(n=i)!==s;)i=v.nextSibling(n),r(n,i)}function Fs(t,e,r){if(t.length){var n=t[0],i=t[t.length-1],s=n.parentNode,o=c.bindingProviderInstance,u=o.preprocessNode;if(u){if(Dn(n,i,function(a,l){var f=a.previousSibling,m=u.call(o,a);m&&(a===n&&(n=m[0]||l),a===i&&(i=m[m.length-1]||f))}),t.length=0,!n)return;n===i?t.push(n):(t.push(n,i),qe(t,s))}Dn(n,i,function(a){(a.nodeType===1||a.nodeType===8)&&Ft(e,a).then(r)}),Dn(n,i,function(a){(a.nodeType===1||a.nodeType===8)&&Ge.unmemoizeDomNodeAndDescendants(a,[e])}),qe(t,s)}}function Fn(t){return t.nodeType?t:t.length>0?t[0]:null}function Bs(t,e,r,n,i,s){i=i||{};var o=t&&Fn(t),u=(o||r||{}).ownerDocument,a=i.templateEngine||Bn,l=a.renderTemplate(r,n,i,u);if(typeof l.length!="number"||l.length>0&&typeof l[0].nodeType!="number")throw new Error("Template engine must return an array of DOM nodes");var f=!1;switch(e){case"replaceChildren":v.setDomNodeChildren(t,l),f=!0;break;case"replaceNode":Er(t,l),f=!0;break;case"ignoreTargetNode":break;default:throw new Error("Unknown renderMode: "+e)}return f&&(Fs(l,n,s),i.afterRender&&C.ignore(i.afterRender,null,[l,n.$data]),e==="replaceChildren"&&W.notify(t,W.childrenComplete)),l}function ws(t,e,r){return T(t)?t():typeof t=="function"?t(e,r):t}function Rr(t,e,r,n,i,s){if(r=r||{},(r.templateEngine||Bn)===void 0)throw new Error("Set a template engine before calling renderTemplate");if(i=i||"replaceChildren",n){var o=Fn(n),u=function(){return!o||!Mt(o)},a=o&&i==="replaceNode"?o.parentNode:o;return N(function(){var l=e&&e instanceof Se?e:new Se(e,null,null,null,{exportDependencies:!0}),f=ws(t,l.$data,l);let m=Bs(n,i,f,l,r,s);i==="replaceNode"&&(n=m,o=Fn(n))},null,{disposeWhen:u,disposeWhenNodeIsRemoved:a})}else return Ge.memoize(function(l){Rr(t,e,r,l,"replaceNode")})}function Ss(t,e,r,n,i,s){var o;function u(h,p){r.as?c.createChildContextWithAs?o=i.createChildContext(h,r.as,x=>{x.$index=p}):o=i.extend({[r.as]:h,$index:p}):o=i.createChildContext(h,r.as,x=>{x.$index=p});var A=ws(t,h,o);return Bs(n,"ignoreTargetNode",A,o,r,s)}var a=function(h,p){Fs(p,o,s),r.afterRender&&r.afterRender(p,h),o=null};function l(h,p){C.ignore(Bt,null,[n,h,u,r,a,p]),W.notify(n,W.childrenComplete)}let f=r.includeDestroyed===!1||c.foreachHidesDestroyed&&!r.includeDestroyed;if(!f&&!r.beforeRemove&&Jt(e)){l(e.peek());var m=e.subscribe(function(h){l(e(),h)},null,"arrayChange");return m.disposeWhenNodeIsRemoved(n),m}else return N(function(){var h=d(e)||[];Symbol.iterator in h||(h=[h]),f&&(h=We(h,function(A){return A==null||!d(A._destroy)})),l(h)},null,{disposeWhenNodeIsRemoved:n})}var Ds=y.nextKey(),wt=class extends re{constructor(e){super(e);let r=this.$element,n=d(this.value);y.set(r,"conditional",{elseChainSatisfied:S(!0)}),typeof n=="string"||n.name?this.bindNamedTemplate():"nodes"in n?this.bindNodeTemplate(n.nodes||[]):this.bindAnonymousTemplate()}bindNamedTemplate(){v.emptyNode(this.$element)}bindNodeTemplate(e){if(T(e))throw new Error('The "nodes" option must be a plain, non-observable array.');let r=e[0]&&e[0].parentNode;(!r||!y.get(r,xs))&&(r=Ht(e),y.set(r,xs,!0)),new pe(this.$element).nodes(r)}bindAnonymousTemplate(){let e=v.childNodes(this.$element);if(e.length===0)throw new Error("Anonymous template defined, but no template content was provided.");let r=Ht(e);new pe(this.$element).nodes(r)}onValueChange(){let e=this.$element,r=this.$context;var n=this.value,i=d(n),s=!0,o=null,u=y.get(e,"conditional").elseChainSatisfied,a;if(typeof i=="string"?(a=n,i={}):(a=i.name,"if"in i&&(s=d(i.if)),s&&"ifnot"in i&&(s=!d(i.ifnot))),"foreach"in i){var l=s&&i.foreach||[];o=Ss(a||e,l,i,e,r,this.completeBinding),u((d(l)||[]).length!==0)}else if(s){var f="data"in i?r.createStaticChildContext(i.data,i.as):r;o=Rr(a||e,f,i,e,void 0,this.completeBinding),u(!0)}else v.emptyNode(e),u(!1);this.disposeOldComputedAndStoreNewOne(e,o)}disposeOldComputedAndStoreNewOne(e,r){let n=y.get(e,Ds);n&&typeof n.dispose=="function"&&n.dispose(),y.set(e,Ds,r&&(!r.isActive||r.isActive())?r:void 0)}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};function ae(){}ae.prototype=new et;ae.prototype.constructor=ae;ae.prototype.renderTemplateSource=function(t,e,r,n){var i=!($<9),s=i?t.nodes:null,o=s?t.nodes():null;if(o)return le(o.cloneNode(!0).childNodes);var u=t.text();return be(u,n)};ae.instance=new ae;Vr(ae.instance);var Mr=class extends wt{get value(){let e=this.valueAccessor(),r=vt(e);return!r||typeof r.length=="number"?{foreach:e,templateEngine:ae.instance}:(d(e),{foreach:r.data,as:r.as,includeDestroyed:r.includeDestroyed,afterAdd:r.afterAdd,beforeRemove:r.beforeRemove,afterRender:r.afterRender,beforeMove:r.beforeMove,afterMove:r.afterMove,templateEngine:ae.instance})}};var Ns={foreach:Mr,template:wt};var Ts={addDisposeCallback:de,removeDisposeCallback:pt,removeNode:ve,addCleaner:bi,removeCleaner:yi,get cleanExternalData(){return c.cleanExternalData},set cleanExternalData(t){c.set("cleanExternalData",t)}},Mu=Object.assign({addOrRemoveItem:Oe,arrayFilter:We,arrayFirst:hr,arrayForEach:I,arrayGetDistinctValues:oi,arrayIndexOf:U,arrayMap:ut,arrayPushAll:lt,arrayRemoveItem:at,cloneNodes:De,compareArrays:ct,createSymbolOrString:z,domData:y,domNodeDisposal:Ts,extend:L,filters:c.filters,objectForEach:O,objectMap:ge,parseHtmlFragment:be,parseJson:ci,parseObjectLiteral:Et,peekObservable:vt,range:ui,registerEventHandler:Q,setDomNodeChildrenFromArrayMapping:Bt,setHtml:ht,setTextContent:Je,toggleDomNodeCssClass:dt,triggerEvent:Ke,unwrapObservable:d}),wn={cleanNode:X,dependencyDetection:C,computedContext:C,filters:c.filters,ignoreDependencies:C.ignore,memoization:Ge,options:c,removeNode:ve,selectExtensions:_,tasks:ye,utils:Mu,LifeCycle:G,isObservable:T,isSubscribable:mt,isWriteableObservable:te,isWritableObservable:te,observable:S,observableArray:fe,isObservableArray:Jt,peek:vt,subscribable:K,unwrap:d,toJS:yt,toJSON:vn,proxy:kr,computed:N,dependentObservable:N,isComputed:Ct,isPureComputed:yn,pureComputed:we,when:An,nativeTemplateEngine:ae,renderTemplate:Rr,setTemplateEngine:Vr,templateEngine:et,templateSources:{domElement:Le,anonymousTemplate:pe},applyBindingAccessorsToNode:Xt,applyBindings:Ft,applyBindingsToDescendants:ue,applyBindingsToNode:ps,contextFor:Ne,dataFor:Or,BindingHandler:ee,AsyncBindingHandler:re,virtualElements:v,domNodeDisposal:Ts,bindingEvent:W},Zt=class{constructor({provider:e,bindings:r,extenders:n,filters:i,options:s}){if(Object.assign(wn.options,s,{filters:i,bindingProviderInstance:e}),e.setGlobals(wn.options.bindingGlobals),Array.isArray(r))for(let o of r)e.bindingHandlers.set(o);else e.bindingHandlers.set(r);this.providedProperties={extenders:Object.assign(Ae,n),bindingHandlers:e.bindingHandlers,bindingProvider:e}}create(...e){let r=Object.assign({get getBindingHandler(){return c.getBindingHandler},set getBindingHandler(n){c.set("getBindingHandler",n)}},wn,this.providedProperties,...e);return r.options.knockoutInstance=r,r}};var er=class{set(e,r){typeof e=="string"?this[e]=r:typeof e=="object"?(r!==void 0&&c.onError(new Error("Given extraneous `value` parameter (first param should be a string, but it was an object)."+e)),Object.assign(this,e)):c.onError(new Error("Given a bad binding handler type: "+e))}get(e){let[r]=e.split(".");return this[r]}};var q=class{constructor(e={}){if(this.constructor===q)throw new Error("Provider is an abstract base class.");if(!("FOR_NODE_TYPES"in this))throw new Error("Providers must have FOR_NODE_TYPES property");this.bindingHandlers=e.bindingHandlers||new er,this.globals=e.globals||{}}setGlobals(e){this.globals=e}get preemptive(){return!1}nodeHasBindings(){}getBindingAccessors(){}preprocessNode(e){}postProcess(){}get instance(){return this._overloadInstance||this}set instance(e){!e||e===this?this._overloadInstance=void 0:this._overloadInstance=new Sn(e,this)}makeAccessorsFromFunction(e){return ge(C.ignore(e),(r,n)=>()=>e()[n])}makeValueAccessor(e){return()=>e}makeBindingAccessors(e,r,n){return typeof e=="function"?this.makeAccessorsFromFunction(e.bind(null,r,n)):ge(e,this.makeValueAccessor)}},Sn=class extends q{get FOR_NODE_TYPES(){return[1,3,8]}constructor(e,r){super(),Object.assign(this,{providerObject:e}),this.bindingHandlers=e.bindingHandlers||r.bindingHandlers}getBindingsAndMakeAccessors(e,r){let n=this.providerObject.getBindings.bind(this.providerObject,e,r);return this.makeAccessorsFromFunction(n)}getBindingAccessors(e,r){return this.providerObject.getBindingAccessors?this.providerObject.getBindingAccessors(e,r):this.getBindingsAndMakeAccessors(e,r)}nodeHasBindings(e){return this.providerObject.nodeHasBindings(e)}preprocessNode(e){if(this.providerObject.preprocessNode)return this.providerObject.preprocessNode(e)}};var He=class extends q{*processBinding(e,r){let[n,i]=e.split("."),s=this.bindingHandlers.get(n);if(s&&s.preprocess){let o=[],u=(...a)=>o.push(a);r=s.preprocess(r,e,u);for(let[a,l]of o)yield*this.processBinding(a,l)}else i&&(r=`{${i}:${r}}`);yield`'${n}':${r}`}*generateBindingString(e){let r=typeof e=="string"?Et(e):e;for(let{key:n,unknown:i,value:s}of r)yield*this.processBinding(n||i,s)}preProcessBindings(e){return Array.from(this.generateBindingString(e)).join(",")}getBindingAccessors(e,r){let n=e&&this.getBindingString(e);if(!n)return;let i=this.preProcessBindings(n);return new Me().parse(i,r,this.globals,e)}getBindingString(){throw new Error("Overload getBindingString.")}};var St=class extends He{get FOR_NODE_TYPES(){return[1,8]}preprocessNode(e){if(e.tagName==="KO"){let r=e.parentNode,n=[...e.childNodes],i=[...this.genElementBindingStrings(e)].join(","),s=document.createComment("ko "+i),o=document.createComment("/ko");r.insertBefore(s,e);for(let u of n)r.insertBefore(u,e);return r.insertBefore(o,e),e.remove(),[s,...n,o]}}*genElementBindingStrings(e){for(let{name:r,value:n}of e.attributes)yield`${r.replace(/^ko-/,"")}: ${n}`}getBindingString(e){if(e.nodeType===document.COMMENT_NODE)return v.virtualNodeBindingValue(e)}nodeHasBindings(e){if(e.nodeType===document.COMMENT_NODE)return v.isStartComment(e)}};var Nt=class extends He{get FOR_NODE_TYPES(){return[1]}get BIND_ATTRIBUTE(){return"data-bind"}getBindingString(e){if(e.nodeType===document.ELEMENT_NODE)return e.getAttribute(this.BIND_ATTRIBUTE)}nodeHasBindings(e){if(e.nodeType===document.ELEMENT_NODE)return e.hasAttribute(this.BIND_ATTRIBUTE)}};var Nn={},Tn={};function $u(t,e){var r=Xr(Nn,t),n;r?r.subscribe(e):(r=Nn[t]=new K,r.subscribe(e),Lu(t,function(i,s){var o=!!(s&&s.synchronous);Tn[t]={definition:i,isSynchronousComponent:o},delete Nn[t],n||o?r.notifySubscribers(i):ye.schedule(function(){r.notifySubscribers(i)})}),n=!0)}function Lu(t,e){tr("getConfig",[t],function(r){r?tr("loadComponent",[t,r],function(n){e(n,r)}):e(null,null)})}function tr(t,e,r,n){n||(n=he.loaders.slice(0));var i=n.shift();if(i){var s=i[t];if(s){var o=!1,u=s.apply(i,e.concat(function(a){o?r(null):a!==null?r(a):tr(t,e,r,n)}));if(u!==void 0&&(o=!0,!i.suppressLoaderExceptions))throw new Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.")}else tr(t,e,r,n)}else r(null)}var he={get(t,e){var r=Xr(Tn,t);r?r.isSynchronousComponent?C.ignore(function(){e(r.definition)}):ye.schedule(function(){e(r.definition)}):$u(t,e)},clearCachedDefinition(t){delete Tn[t]},_getFirstResultFromLoaders:tr,loaders:[]};var tt={},$r=Symbol("Knockout View Model ViewModel factory");function Lr(t,e){if(!e)throw new Error("Invalid configuration for "+t);if(On(t))throw new Error("Component "+t+" is already registered");let r=t.includes("-")&&t.toLowerCase()===t;!e.ignoreCustomElementWarning&&!r&&console.log(`
|
|
7
|
+
`;return new Error(i)}name(){let e="",t;this.white();let r=this.ch;for((r==="'"||r==='"')&&(t=r,r=this.next());r;){if(t&&r===t)return this.white(),r=this.next(),r!==":"&&r!==","&&this.error("Object name: "+e+" missing closing "+t),e;if(r===":"||r<=" "||r===","||r==="|")return e;e+=r,r=this.next()}return e}number(){let e,t="",r=this.ch;for(r==="-"&&(t="-",r=this.next("-"));r>="0"&&r<="9";)t+=r,r=this.next();if(r===".")for(t+=".",r=this.next();r&&r>="0"&&r<="9";)t+=r,r=this.next();if(r==="e"||r==="E")for(t+=r,r=this.next(),(r==="-"||r==="+")&&(t+=r,r=this.next());r>="0"&&r<="9";)t+=r,r=this.next();if(e=+t,!isFinite(e))c.onError(new Error("Bad number: "+e+" in "+t));else return e}objectAddValue(e,t,r){r&&r[F.isExpressionOrIdentifierSymbol]?Object.defineProperty(e,t,{get:()=>F.value_of(r,...this.currentContextGlobals),enumerable:!0}):Array.isArray(r)?Object.defineProperty(e,t,{get:()=>r.map(i=>F.value_of(i,...this.currentContextGlobals)),enumerable:!0}):e[t]=r}object(){let e,t={},r=this.ch;if(r==="{"){if(this.next("{"),r=this.white(),r==="}")return r=this.next("}"),t;for(;r;){if(r==='"'||r==="'"||r==="`"?e=this.string():e=this.name(),J(t,e)&&this.error('Duplicate key "'+e+'"'),this.white()===":")r=this.next(":"),this.objectAddValue(t,e,this.singleValueExpression());else{let i=new U(this,e,[]);this.objectAddValue(t,e,i)}if(r=this.white(),r==="}")return r=this.next("}"),t;if(this.next(","),r=this.white(),r==="}")return r=this.next("}"),t}}throw this.createError("Bad object")}readString(e){let t="",r=[""],i=E["+"],s,o,a,u=e==="`",l=this.next();for(;l;){if(l===e)return l=this.next(),u&&r.push(i),r.push(t),r;if(l==="\\")if(l=this.next(),l==="u"){for(a=0,o=0;o<4&&(s=parseInt(l=this.next(),16),!!isFinite(s));o+=1)a=a*16+s;t+=String.fromCharCode(a)}else if(typeof $i[l]=="string")t+=$i[l];else break;else u&&l==="$"?(l=this.next(),l==="{"?(this.next("{"),r.push(i),r.push(t),r.push(i),r.push(this.expression()),t=""):t+="$"+l):t+=l;l=this.next()}throw this.createError("Bad string")}string(){var t,r;let e=this.ch;if(e==='"')return(t=this.readString('"'))==null?void 0:t.join("");if(e==="'")return(r=this.readString("'"))==null?void 0:r.join("");if(e==="`")return F.create_root(this.readString("`"));this.error("Bad string")}array(){let e=new Array,t=this.ch;if(t==="["){if(t=this.next("["),this.white(),t==="]")return t=this.next("]"),e;for(;t;){if(e.push(this.singleValueExpression()),t=this.white(),t==="]")return t=this.next("]"),e;this.next(","),t=this.white()}}throw this.createError("Bad array")}value(){this.white();let e=this.ch;switch(e){case"{":return this.object();case"[":return this.array();case'"':case"'":case"`":return this.string();case"-":return this.number();default:return e>="0"&&e<="9"?this.number():this.identifier()}}operator(e){let t="",r,i=this.white(),s=U.is_valid_start_char;for(;i&&!(s(i)||i<=" "||i===""||i==='"'||i==="'"||i==="{"||i==="("||i==="`"||i===")"||i<="9"&&i>="0"||!e.not_an_array&&i==="["||(t+=i,i=this.next(),i==="@"));)s=U.is_valid_continue_char;return t!==""&&(e.prefix&&t==="-"&&(t="&-"),r=E[t],r||this.error("Bad operator: '"+t+"'.")),r}filter(){let e=this.next(),t=new Array,r=function(o){return o},i=this.name();for(c.filters[i]||c.onError(new Error("Cannot find filter by the name of: "+i)),e=this.white();e;){if(e===":"&&(e=this.next(),t.push(this.singleValueExpression("|"))),e==="|"){r=this.filter();break}if(e===",")break;e=this.white()}function s(o,a,u,l,d){let p=[o];for(let b=0,m=t.length;b<m;++b)p.push(F.value_of(t[b],u,l,d));return r(c.filters[i].apply(u,p),a,u,l,d)}return s.precedence=1,s}expression(e=!1,t=!0){let r,i=new Array,s=this.white();for(;s&&(r=this.operator({prefix:!0}),r&&(i.push(void 0),i.push(r),s=this.white()),s==="("?(this.next(),i.push(this.expression()),this.next(")")):i.push(this.value()),s=this.white(),!(s===":"||s==="}"||s==="]"||s===")"||s===""||s==="`"||s==="|"&&e==="|"||s===","&&!t));){if(s==="|"&&this.lookahead()!=="|"&&e){i.push(this.filter()),i.push(void 0);break}if(r=this.operator({not_an_array:!0}),r===E["?"]){this.ternary(i);break}else r===E["."]||r===E["?."]?(i.push(r),i.push(this.member()),r=null):r===E["["]?(i.push(r),i.push(this.expression()),s=this.next("]"),r=null):r===E["=>"]?(i[i.length-1]=new $t(this,i[i.length-1]),i.push(r)):r&&i.push(r);if(s=this.white(),s==="]"||!r&&s==="(")break}if(i.length===0)return;let o=this.dereferences();if(i.length===1&&!o.length)return i[0];for(let a=0,u=o.length;a<u;++a){let l=o[a];l.constructor===be?i.push(E.call):i.push(E["."]),i.push(l)}return new Se(i)}singleValueExpression(e=!1){return this.expression(e,!1)}ternary(e){let t=new pt;t.yes=this.singleValueExpression(),this.next(":"),t.no=this.singleValueExpression(),e.push(E["?"]),e.push(t)}funcArguments(){let e=new Array,t=this.next("(");for(;t;){if(t=this.white(),t===")")return this.next(")"),new be(this,e);e.push(this.singleValueExpression()),t=this.white(),t!==")"&&this.next(",")}throw this.createError("Bad arguments to function")}member(){let e="",t=this.white(),r=U.is_valid_start_char;for(;t&&r(t);)e+=t,t=this.next(),r=U.is_valid_continue_char;return e}dereference(){let e,t=this.white();for(;t;){if(t==="(")return this.funcArguments();if(t==="[")return this.next("["),e=this.expression(),this.white(),this.next("]"),e;if(t===".")return this.next("."),this.member();break}}dereferences(){let e=this.white(),t=new Array,r;for(;e&&(r=this.dereference(),r!==void 0);)t.push(r);return t}identifier(){let e="",t=U.is_valid_start_char,r=this.white();for(;r&&t(r);)e+=r,r=this.next(),t=U.is_valid_continue_char;switch(e){case"true":return!0;case"false":return!1;case"null":return null;case"undefined":return;case"function":throw new Error("Knockout: Anonymous functions are no longer supported, but `=>` lambdas are. In: "+this.text)}return new U(this,e,this.dereferences())}readBindings(){let e,t={},r,i,s=this.ch;for(;s;)e=this.name(),r=this.white(),!r||r===","?(r?s=this.next(","):s="",t[e]=null):(e.indexOf(".")!==-1?(e=e.split("."),t[e[0]]=t[e[0]]||{},e.length!==2?c.onError(new Error("Binding "+e+" should have two parts (a.b).")):t[e[0]].constructor!==Object&&c.onError(new Error("Binding "+e[0]+"."+e[1]+" paired with a non-object.")),s=this.next(":"),this.objectAddValue(t[e[0]],e[1],this.singleValueExpression(!0))):(s=this.next(":"),t[e]&&typeof t[e]=="object"&&t[e].constructor===Object?(i=this.singleValueExpression(!0),typeof i!="object"||i.constructor!==Object?c.onError(new Error("Expected plain object for "+e+" value.")):L(t[e],i)):t[e]=this.singleValueExpression(!0)),this.white(),this.ch?s=this.next(","):s="");return t}valueAsAccessor(e,t,r,i){if(!e)return()=>e;if(typeof e=="function")return e;if(e[F.isExpressionOrIdentifierSymbol])return()=>F.value_of(e,t,r,i);if(Array.isArray(e))return()=>e.map(s=>F.value_of(s,t,r,i));if(typeof e!="function")return()=>Un(e);throw new Error("Value has cannot be converted to accessor: "+e)}convertToAccessors(e,t,r,i){return V(e,(s,o)=>{o instanceof U?Object.defineProperty(e,s,{value:function(a,u){let l=o.get_value(void 0,t,r,i);if(arguments.length===0)return l;let d=a===l;if(!(u&&u.onlyIfChanged&&d))return o.set_value(a,t,r)}}):e[s]=this.valueAsAccessor(o,t,r,i)}),e}preparse(e=""){return(c.bindingStringPreparsers||[]).reduce((r,i)=>i(r),e.trim())}runParse(e,t){this.text=this.preparse(e),this.at=0,this.ch=" ";try{let r=t();return this.white(),this.ch&&this.error("Syntax Error"),r}catch(r){c.onError(r)}}parse(e,t={},r={},i){if(!e)return()=>null;this.currentContextGlobals=[t,r,i];let s=()=>this.readBindings(),o=this.runParse(e,s);return this.convertToAccessors(o,t,r,i)}parseExpression(e,t={},r={},i){if(!e)return()=>"";this.currentContextGlobals=[t,r,i];let s=()=>this.singleValueExpression(!0),o=this.runParse(e,s);return this.valueAsAccessor(o,t,r,i)}};var Hi=",\"'`{}()/:[\\]",ji=RegExp(['"(?:\\\\.|[^"])*"',"'(?:\\\\.|[^'])*'","`(?:\\\\.|[^`])*`","/\\*(?:[^*]|\\*+[^*/])*\\*+/",`//.*
|
|
8
|
+
`,"/(?:\\\\.|[^/])+/\\w*","[^\\s:,/][^"+Hi+"]*[^\\s"+Hi+"]","[^\\s]"].join("|"),"g"),eu=/[\])"'A-Za-z0-9_$]+$/,tu={in:1,return:1,typeof:1};function ht(n){let e=_t(n);e.charCodeAt(0)===123&&(e=e.slice(1,-1)),e+=`
|
|
9
|
+
,`;let t=new Array,r=e.match(ji),i,s=new Array,o=0;if(r.length<=1)return[];for(let a=0,u;u=r[a];++a){let l=u.charCodeAt(0);if(l===44){if(o<=0){t.push(i&&s.length?{key:i,value:s.join("")}:{unknown:i||s.join("")}),i=o=0,s=new Array;continue}}else if(l===58){if(!o&&!i&&s.length===1){i=s.pop();continue}}else{if(l===47&&u.length>1&&(u.charCodeAt(1)===47||u.charCodeAt(1)===42))continue;if(l===47&&a&&u.length>1){let d=r[a-1].match(eu);d&&!tu[d[0]]&&(e=e.substr(e.indexOf(u)+1),r=e.match(ji),a=-1,u="/")}else l===40||l===123||l===91?++o:l===41||l===125||l===93?--o:!i&&!s.length&&(l===34||l===39)&&(u=u.slice(1,-1))}s.push(u)}return t}var I=z("_state"),nu={dependencyTracking:null,dependenciesCount:0,isDisposed:!0,isStale:!1,isDirty:!1,isSleeping:!1,disposeWhenNodeIsRemoved:null,readFunction:null,_options:null};function B(n,e,t){if(typeof n=="object"?t=n:(t=t||{},n&&(t.read=n)),typeof(t==null?void 0:t.read)!="function")throw Error("Pass a function that returns the value of the computed");let r=t.write,i={latestValue:void 0,isStale:!0,isDirty:!0,isBeingEvaluated:!1,suppressDisposalUntilDisposeWhenReturnsFalse:!1,isDisposed:!1,pure:!1,isSleeping:!1,readFunction:t.read,evaluatorFunctionTarget:e||t.owner,disposeWhenNodeIsRemoved:t.disposeWhenNodeIsRemoved||null,disposeWhen:t.disposeWhen,domNodeDisposalCallback:null,dependencyTracking:{},dependenciesCount:0,evaluationTimeoutInstance:null};function s(){if(arguments.length>0){if(typeof r=="function")r.apply(i.evaluatorFunctionTarget,arguments);else throw new Error("Cannot write a value to a computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");return this}else return i.isDisposed||x.registerDependency(s),(i.isDirty||i.isSleeping&&s.haveDependenciesChanged())&&s.evaluateImmediate(),i.latestValue}return s[I]=i,s.isWriteable=typeof r=="function",W.fn.init(s),Object.setPrototypeOf(s,B.fn),t.pure?(i.pure=!0,i.isSleeping=!0,L(s,su)):t.deferEvaluation&&L(s,ou),c.deferUpdates&&ge.deferred(s,!0),c.debug&&(s._options=t),i.disposeWhenNodeIsRemoved&&(i.suppressDisposalUntilDisposeWhenReturnsFalse=!0,i.disposeWhenNodeIsRemoved.nodeType||(i.disposeWhenNodeIsRemoved=null)),!i.isSleeping&&!t.deferEvaluation&&s.evaluateImmediate(),i.disposeWhenNodeIsRemoved&&s.isActive()&&Ae(i.disposeWhenNodeIsRemoved,i.domNodeDisposalCallback=function(){s.dispose()}),s}function ru(n,e){e!==null&&e.dispose&&e.dispose()}function iu(n,e){let t=this.computedObservable,r=t[I];r.isDisposed||(this.disposalCount&&this.disposalCandidates[e]?(t.addDependencyTracking(e,n,this.disposalCandidates[e]),this.disposalCandidates[e]=null,--this.disposalCount):r.dependencyTracking[e]||t.addDependencyTracking(e,n,r.isSleeping?{_target:n}:t.subscribeToDependency(n)),n._notificationIsPending&&n._notifyNextChangeIfValueIsDifferent())}B.fn={equalityComparer:at,getDependenciesCount(){return this[I].dependenciesCount},getDependencies(){let n=this[I].dependencyTracking,e=new Array;return V(n,function(t,r){e[r._order]=r._target}),e},addDependencyTracking(n,e,t){if(this[I].pure&&e===this)throw Error("A 'pure' computed must not be called recursively");this[I].dependencyTracking[n]=t,t._order=this[I].dependenciesCount++,t._version=e.getVersion()},haveDependenciesChanged(){let n,e,t=this[I].dependencyTracking;for(n in t)if(J(t,n)&&(e=t[n],this._evalDelayed&&e._target._notificationIsPending||e._target.hasChanged(e._version)))return!0;return!1},markDirty(){this._evalDelayed&&!this[I].isBeingEvaluated&&this._evalDelayed(!1)},isActive(){let n=this[I];return n.isDirty||n.dependenciesCount>0},respondToChange(){this._notificationIsPending?this[I].isDirty&&(this[I].isStale=!0):this.evaluatePossiblyAsync()},subscribeToDependency(n){if(n._deferUpdates){let e=n.subscribe(this.markDirty,this,"dirty"),t=n.subscribe(this.respondToChange,this);return{_target:n,dispose(){e.dispose(),t.dispose()}}}else return n.subscribe(this.evaluatePossiblyAsync,this)},evaluatePossiblyAsync(){let n=this,e=n.throttleEvaluation;e&&e>=0?(clearTimeout(this[I].evaluationTimeoutInstance),this[I].evaluationTimeoutInstance=ae(function(){n.evaluateImmediate(!0)},e)):n._evalDelayed?n._evalDelayed(!0):n.evaluateImmediate(!0)},evaluateImmediate(n){let e=this,t=e[I],r=t.disposeWhen,i=!1;if(!t.isBeingEvaluated&&!t.isDisposed){if(t.disposeWhenNodeIsRemoved&&!Ot(t.disposeWhenNodeIsRemoved)||r&&r()){if(!t.suppressDisposalUntilDisposeWhenReturnsFalse){e.dispose();return}}else t.suppressDisposalUntilDisposeWhenReturnsFalse=!1;t.isBeingEvaluated=!0;try{i=this.evaluateImmediate_CallReadWithDependencyDetection(n)}finally{t.isBeingEvaluated=!1}return i}},evaluateImmediate_CallReadWithDependencyDetection(n){let e=this,t=e[I],r=!1,i=t.pure?void 0:!t.dependenciesCount,s={computedObservable:e,disposalCandidates:t.dependencyTracking,disposalCount:t.dependenciesCount};x.begin({callbackTarget:s,callback:iu,computed:e,isInitial:i}),t.dependencyTracking={},t.dependenciesCount=0;let o=this.evaluateImmediate_CallReadThenEndDependencyDetection(t,s);return t.dependenciesCount?r=e.isDifferent(t.latestValue,o):(e.dispose(),r=!0),r&&(t.isSleeping?e.updateVersion():e.notifySubscribers(t.latestValue,"beforeChange"),t.latestValue=o,c.debug&&(e._latestValue=o),e.notifySubscribers(t.latestValue,"spectate"),!t.isSleeping&&n&&e.notifySubscribers(t.latestValue),e._recordUpdate&&e._recordUpdate()),i&&e.notifySubscribers(t.latestValue,"awake"),r},evaluateImmediate_CallReadThenEndDependencyDetection(n,e){try{let t=n.readFunction;return n.evaluatorFunctionTarget?t.call(n.evaluatorFunctionTarget):t()}finally{x.end(),e.disposalCount&&!n.isSleeping&&V(e.disposalCandidates,ru),n.isStale=n.isDirty=!1}},peek(n){let e=this[I];return(e.isDirty&&(n||!e.dependenciesCount)||e.isSleeping&&this.haveDependenciesChanged())&&this.evaluateImmediate(),e.latestValue},get[Y](){return this.peek()},limit(n){let e=this[I];W.fn.limit.call(this,n),Object.assign(this,{_evalIfChanged(){return this[I].isSleeping||(this[I].isStale?this.evaluateImmediate():this[I].isDirty=!1),e.latestValue},_evalDelayed(t){this._limitBeforeChange(e.latestValue),e.isDirty=!0,t&&(e.isStale=!0),this._limitChange(this,!t)}})},dispose(){let n=this[I];!n.isSleeping&&n.dependencyTracking&&V(n.dependencyTracking,function(e,t){t.dispose&&t.dispose()}),n.disposeWhenNodeIsRemoved&&n.domNodeDisposalCallback&&it(n.disposeWhenNodeIsRemoved,n.domNodeDisposalCallback),Object.assign(n,nu)}};var su={beforeSubscriptionAdd(n){let e=this,t=e[I];if(!t.isDisposed&&t.isSleeping&&n==="change"){if(t.isSleeping=!1,t.isStale||e.haveDependenciesChanged())t.dependencyTracking=null,t.dependenciesCount=0,e.evaluateImmediate()&&e.updateVersion();else{let r=new Array;V(t.dependencyTracking,function(i,s){r[s._order]=i}),P(r,function(i,s){let o=t.dependencyTracking[i],a=e.subscribeToDependency(o._target);a._order=s,a._version=o._version,t.dependencyTracking[i]=a}),e.haveDependenciesChanged()&&e.evaluateImmediate()&&e.updateVersion()}t.isDisposed||e.notifySubscribers(t.latestValue,"awake")}},afterSubscriptionRemove(n){let e=this[I];!e.isDisposed&&n==="change"&&!this.hasSubscriptionsForEvent("change")&&(V(e.dependencyTracking,function(t,r){r.dispose&&(e.dependencyTracking[t]={_target:r._target,_order:r._order,_version:r._version},r.dispose())}),e.isSleeping=!0,this.notifySubscribers(void 0,"asleep"))},getVersion(){let n=this[I];return n.isSleeping&&(n.isStale||this.haveDependenciesChanged())&&this.evaluateImmediate(),W.fn.getVersion.call(this)}},ou={beforeSubscriptionAdd(n){(n==="change"||n==="beforeChange")&&this.peek()}};Object.setPrototypeOf(B.fn,W.fn);var Wi=w.protoProperty;B.fn[Wi]=B;w.observablePrototypes.add(B);function mt(n){return typeof n=="function"&&n[Wi]===B}function cr(n){return mt(n)&&n[I]&&n[I].pure}function xe(n,e){if(typeof n=="function")return B(n,e,{pure:!0});{let t=n;return t=L({},t),t.pure=!0,B(t,e)}}function Ui(n,e){n.throttleEvaluation=e;let t;return B({read:n,write:function(r){clearTimeout(t),t=setTimeout(function(){n(r)},e)}})}var uu=ge;uu.throttle=Ui;var Ki=Symbol("Knockout Proxied Object"),qi=Symbol("Knockout Proxied Observables");function au(n,e){return B({owner:n,read:e,write:e,pure:"pure"in e?e.pure:!0,deferEvaluation:"deferEvaluation"in e?e.deferEvaluation:!0}).extend({deferred:!0})}function Ji(n,e,t,r){if(n[e])n[e](t);else{let i=Array.isArray(t)?ce:typeof t=="function"?au.bind(null,r):w;n[e]=i(t)}}function Qi(n,e,t){for(let r of Object.keys(e))Ji(n,r,e[r],t);return e}function yn(n){let e={[Ki]:n};e[qi]=e;let t=new Proxy(function(){},{has(r,i){return i in e},get(r,i){return f(e[i])},set(r,i,s,o){return Ji(e,i,s,t),n[i]=s,!0},deleteProperty(r){return delete e[r],delete n[r]},apply(r,i,[s]){return s?(Qi(e,s,t),Object.assign(n,s)):n},getPrototypeOf(){return Object.getPrototypeOf(n)},setPrototypeOf(r,i){return Object.setPrototypeOf(n,i)},defineProperty(r,i,s){return Object.defineProperty(n,i,s)},preventExtensions(){return Object.preventExtensions(n)},isExtensible(){return Object.isExtensible(n)},ownKeys(){return[...Object.getOwnPropertyNames(n),...Object.getOwnPropertySymbols(n)]}});return Qi(e,n,t),t}function zi(n,e){return n[qi][e]}function lu(n,e){return zi(n,e).peek()}function cu(n){return Ki in n}Object.assign(yn,{getObservable:zi,peek:lu,isProxied:cu});function du(n,e,t){let r=xe(n,e).extend({notify:"always"}),i=r.subscribe(s=>{s&&(i.dispose(),t(s))});return r.notifySubscribers(r.peek()),i}function dr(n,e,t){let r=du.bind(null,n,t);return e?r(e.bind(t)):new Promise(r)}var Ht=z("LifeCycle Subscriptions List"),gt=z("LifeCycle Anchor Node"),X=class n{static mixInto(e){let t=e.prototype||e,r=n.prototype;for(let i of Object.getOwnPropertyNames(r))t[i]=r[i]}subscribe(e,t,r){typeof t=="string"&&(t=this[t]),this.addDisposable(e.subscribe(t,this,r))}computed(e){if(typeof e=="string"&&(e={read:this[e],write:this[e]}),typeof e=="object")e=Object.assign({owner:this},e);else if(typeof e=="function"){let t=Object.getPrototypeOf(this);t&&t[e.name]===e&&(e=e.bind(this)),e={read:e,write:e}}else throw new Error("LifeCycle::computed not given a valid type.");return e.disposeWhenNodeIsRemoved=this[gt],this.addDisposable(B(e))}addEventListener(...e){let t=e[0].nodeType?e.shift():this[gt],[r,i,s]=e,o=typeof i=="string"?this[i].bind(this):i;this.__addEventListener(t,r,o,s)}__addEventListener(e,t,r,i){e.addEventListener(t,r,i);function s(){e.removeEventListener(t,r)}Ae(e,s),this.addDisposable({dispose:s})}anchorTo(e){"addDisposable"in e?(e.addDisposable(this),this[gt]=null):(this[gt]=e,Ae(e,()=>this[gt]===e&&this.dispose()))}dispose(){(this[Ht]||[]).forEach(t=>t.dispose()),this[Ht]=new Array,this[gt]=null}addDisposable(e){let t=this[Ht]||[];if(this[Ht]||(this[Ht]=t),typeof e.dispose!="function")throw new Error("Lifecycle::addDisposable argument missing `dispose`.");return t.push(e),e}};var An=Symbol("_ancestorBindingInfo"),Gi=D.nextKey(),$={childrenComplete:"childrenComplete",descendantsComplete:"descendantsComplete",subscribe(n,e,t,r){let i=D.getOrSet(n,Gi,{});return i.eventSubscribable||(i.eventSubscribable=new W),i.eventSubscribable.subscribe(t,r,e)},notify(n,e){let t=D.get(n,Gi);t&&t.eventSubscribable&&t.eventSubscribable.notifySubscribers(n,e)}};var fr=D.nextKey(),_e=Symbol("Knockout Context Subscription"),Yi=Symbol("Knockout Parent Indicator"),ve=function(e,t,r,i,s){let o=this,a=e===Yi,u=a?void 0:e,l=typeof u=="function"&&!S(u);o.ko=c.knockoutInstance;let d;function p(){let b=l?u():u,m=f(b);return t?(t[_e]&&t[_e](),L(o,t),An in t&&(o[An]=t[An])):(o.$parents=new Array,o.$root=m),o[_e]=d,a?m=o.$data:(o.$rawData=b,o.$data=m),r&&(o[r]=m),i&&i(o,t,m),o.$data}s&&s.exportDependencies?p():(d=xe(p),d.peek(),d.isActive()?(o[_e]=d,d.equalityComparer=null):o[_e]=void 0)};Object.assign(ve.prototype,{lookup(n,e,t){switch(n){case"$element":return t;case"$context":return this;case"this":case"$data":return this.$data}let r=this.$data;if(Tt(r)&&n in r)return r[n];if(n in this)return this[n];if(n in e)return e[n];throw new Error(`The variable "${n}" was not found on $data, $context, or globals.`)},createChildContext(n,e,t,r){return new ve(n,this,e,function(i,s){var o;i.$parentContext=s,i.$parent=s==null?void 0:s.$data,i.$parents=((o=s==null?void 0:s.$parents)!=null?o:[]).slice(0),i.$parents.unshift(i.$parent),t&&t(i)},r)},extend(n){return new ve(Yi,this,void 0,function(e,t){L(e,typeof n=="function"?n.call(e):n)})},createStaticChildContext(n,e){return this.createChildContext(n,e,null,{exportDependencies:!0})}});function fu(n){let e=D.get(n,fr);return e&&e.context}function Fe(n){if(n&&(n.nodeType===Node.ELEMENT_NODE||n.nodeType===Node.COMMENT_NODE))return fu(n)}function Dn(n){let e=Fe(n);return e?e.$data:void 0}var bt=class{constructor({asyncBindingsApplied:e,rootNode:t,bindingContext:r}){this.rootNode=t,this.bindingContext=r,this.isSync=e.size===0,this.isComplete=this.isSync,this.isSync||(this.completionPromise=this.completeWhenBindingsFinish(e))}completeWhenBindingsFinish(e){return Ye(this,null,function*(){return yield Promise.all(e),this.isComplete=!0,this})}};var Z=class extends X{constructor(e){super();let{$element:t,valueAccessor:r,allBindings:i,$context:s}=e;this.$element=t,this.valueAccessor=r,this.allBindings=i,this.$context=s,this.$data=s.$data,this.anchorTo(t)}get value(){return this.valueAccessor()}set value(e){let t=this.valueAccessor();Q(t)?t(e):this.valueAccessor(e)}get controlsDescendants(){return!1}static get allowVirtualElements(){return!1}static get isBindingHandlerClass(){return!0}get bindingCompleted(){return!0}static registerAs(e,t=c.bindingProviderInstance){t.bindingHandlers.set(e,this)}static registerBindingHandler(e,t,r=c.bindingProviderInstance){r.bindingHandlers.set(t,e)}},Xi=Symbol("Async Binding Resolved"),ee=class extends Z{constructor(e){super(e),this.bindingCompletion=new Promise(t=>{this[Xi]=t}),this.completeBinding=t=>this[Xi](t)}get bindingCompleted(){return this.bindingCompletion}};var pu=c.global.WeakMap||Map,pr=new pu,Cn=class n extends Z{get handler(){}constructor(e){super(e);let t=this.handler;this.onError=e.onError,typeof t.dispose=="function"&&this.addDisposable(t);try{this.initReturn=t.init&&t.init(...this.legacyArgs)}catch(r){e.onError("init",r)}}onValueChange(){let e=this.handler;if(typeof e.update=="function")try{e.update(...this.legacyArgs)}catch(t){this.onError("update",t)}}get legacyArgs(){return[this.$element,this.valueAccessor,this.allBindings,this.$data,this.$context]}get controlsDescendants(){return(this.initReturn||this.handler||{}).controlsDescendantBindings}static getOrCreateFor(e,t){if(pr.has(t))return pr.get(t);let r=this.createFor(e,t);return pr.set(t,r),r}static createFor(e,t){if(typeof t=="function"){let[r,i]=[t,t.dispose];return class extends n{get handler(){let s=r.bind(this),o=i?i.bind(this):null;return{init:s,dispose:o}}static get after(){return t.after}static get allowVirtualElements(){return t.allowVirtualElements||y.allowedBindings[e]}}}if(typeof t=="object")return class extends n{get handler(){return t}static get after(){return t.after}static get allowVirtualElements(){return t.allowVirtualElements||y.allowedBindings[e]}};throw new Error("The given handler is not an appropriate type.")}};var hu={script:!0,textarea:!0,template:!0};function Wt(){return c.bindingProviderInstance.instance||c.bindingProviderInstance}function es(n,e){return(n.FOR_NODE_TYPES||[Node.ELEMENT_NODE,Node.TEXT_NODE,Node.COMMENT_NODE]).includes(e.nodeType)}function ts(n,e){if(n)return n.isBindingHandlerClass?n:Cn.getOrCreateFor(e,n)}function mu(n,e){if(!(!e||typeof e.getBindingHandler!="function"))return ts(e.getBindingHandler(n))}function gu(n){let e=c.getBindingHandler(n)||Wt().bindingHandlers.get(n);return ts(e,n)}function jt(n){return n()}function ns(n,e,t){let r=y.firstChild(e);if(!r)return;let i,s=Wt(),o=s.preprocessNode;if(o){for(;i=r;)r=y.nextSibling(i),o.call(s,i);r=y.firstChild(e)}for(;i=r;)r=y.nextSibling(i),ss(n,i,t);$.notify(e,$.childrenComplete)}function rs(n){let e=Wt();return es(e,n)&&e.nodeHasBindings(n)}function is(n){return rs(n)||[...n.childNodes].some(e=>is(e))}function ss(n,e,t){let r=e.nodeType===Node.ELEMENT_NODE;r&&y.normaliseVirtualElementDomStructure(e);let i=r||rs(e),{shouldBindDescendants:s}=i?os(e,null,n,t):{shouldBindDescendants:!0};s&&!hu[R(e)]&&ns(n,e,t)}function*bu(n,e){let t=[],r={},i=new Array;V(n,function s(o){if(!r[o]){let a=mu(o,e)||gu(o);if(!a)return;a.after&&(i.push(o),P(a.after,function(u){if(n[u]){if(j(i,u)!==-1)throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+i.join(", "));s(u)}}),i.length--),t.push([o,a])}r[o]=!0});for(let s of t)yield s}function os(n,e,t,r){let i=D.getOrSet(n,fr,{}),s=i.alreadyBound;if(!e){if(s)return is(n)&&Zi({during:"apply",errorCaptured:new Error("You cannot apply bindings multiple times to the same element."),element:n,bindingContext:t}),!1;i.alreadyBound=!0}s||(i.context=t);let o=null,a=null;if(e&&typeof e!="function")o=e;else{let d=Wt(),p=d.getBindingAccessors;es(d,n)&&(a=B(function(){return o=e?e(t,n):p.call(d,n,t),o&&t[_e]&&t[_e](),o},null,{disposeWhenNodeIsRemoved:n}),(!o||!a.isActive())&&(a=null))}let u;if(o){let d=t.$component||{},p={};D.set(n,"bindingHandlers",p);let b=a?h=>function(T){let k=a()[h];return arguments.length===0?jt(k):k(T)}:h=>o[h],m=function(){return pe(a?a():o,jt)};m.has=h=>h in o,m.get=h=>o[h]&&jt(b(h)),$.childrenComplete in o&&$.subscribe(n,$.childrenComplete,()=>{let h=jt(o[$.childrenComplete]);if(!h)return;let T=y.childNodes(n);T.length&&h(T,Dn(T[0]))},null);let A=bu(o,d),v=new Set;for(let[h,T]of A){let k=function(g,N){Zi({during:g,errorCaptured:N,bindings:o,allBindings:m,bindingKey:h,bindingContext:t,element:n,valueAccessor:b(h)})};if(n.nodeType===Node.COMMENT_NODE&&!T.allowVirtualElements)throw new Error(`The binding '${h}' cannot be used with virtual elements`);try{let g=x.ignore(()=>new T({allBindings:m,$element:n,$context:t,onError:k,valueAccessor(...N){return b(h)(...N)}}));if(g.onValueChange&&x.ignore(()=>g.computed("onValueChange")),p[h]=g,g.controlsDescendants){if(u!==void 0)throw new Error("Multiple bindings ("+u+" and "+h+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");u=h}g.bindingCompleted instanceof Promise&&(r.add(g.bindingCompleted),v.add(g.bindingCompleted))}catch(g){let N=g instanceof Error?g:new Error(String(g));k("creation",N)}}Eu(n,o,v)}return{shouldBindDescendants:u===void 0}}function Eu(n,e,t){let r=$.descendantsComplete in e,i=y.firstChild(n),s=r&&jt(e[$.descendantsComplete]),o=()=>{$.notify(n,$.descendantsComplete),s&&i&&s(n)};t.size?Promise.all(t).then(o):o()}function xn(n,e){return n&&n instanceof ve?n:new ve(n,void 0,void 0,e)}function Ut(n,e,t,r){return n.nodeType===Node.ELEMENT_NODE&&y.normaliseVirtualElementDomStructure(n),os(n,e,xn(t),r)}function us(n,e,t){let r=new Set,i=xn(t),s=Wt().makeBindingAccessors(e,i,n);return Ut(n,s,i,r),new bt({asyncBindingsApplied:r,rootNode:n,bindingContext:i})}function se(n,e){let t=new Set,r=xn(n);return e.nodeType===Node.ELEMENT_NODE||e.nodeType===Node.COMMENT_NODE?(ns(r,e,t),new bt({asyncBindingsApplied:t,rootNode:e,bindingContext:r})):new bt({asyncBindingsApplied:t,rootNode:e,bindingContext:r})}function Et(n,e,t){let r=new Set;if(e){if(e.nodeType!==Node.ELEMENT_NODE&&e.nodeType!==Node.COMMENT_NODE)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node")}else if(e=window.document.body,!e)throw Error("ko.applyBindings: could not find window.document.body; has the document been loaded?");let i=xn(n,t);return ss(i,e,r),Promise.all(r)}function Zi(n){let e;n.bindingKey?(e=n.errorCaptured,n.message='Unable to process binding "'+n.bindingKey+'" in binding "'+n.bindingKey+`"
|
|
10
|
+
Message: `+(e.message?e.message:e)):e=n.errorCaptured;try{L(e,n)}catch(t){n.stack=e.stack;let r=e.message||String(e),i=e.name;e=new Error(r),i&&i!=="Error"&&(e.name=i),L(e,n)}c.onError(e)}function yu(n,e,t,r,i){let s=[],o=B(function(){let a=e(t,i,Re(s,n))||[];s.length>0&&(ln(s,a),r&&x.ignore(r,null,[t,a,i])),s.length=0,et(s,a)},null,{disposeWhenNodeIsRemoved:n,disposeWhen:function(){return!ci(s)}});return{mappedNodes:s,dependentObservable:o.isActive()?o:void 0}}var as=D.nextKey(),ls=D.nextKey();function yt(n,e,t,r,i,s){e=e||[],typeof e.length=="undefined"&&(e=[e]),r=r||{};let o=D.get(n,as),a=!o,u=new Array,l=0,d=0,p=[],b=[],m=[],A=[],v=[],h,T=0;function k(C){h={arrayEntry:C,indexObservable:w(d++)},u.push(h),b.push(h),a||v.push(h)}function g(C){h=o[C],d!==C&&A.push(h),h.indexObservable(d++),Re(h.mappedNodes,n),u.push(h),b.push(h)}function N(C,_){if(C)for(let M=0,H=_.length;M<H;M++)P(_[M].mappedNodes,function(te){C(te,M,_[M].arrayEntry)})}if(a)P(e,k);else{if(!s||o&&o._countWaitingForRemove){let C=Xe(o,function(M){return M.arrayEntry}),_={dontLimitMoves:r.dontLimitMoves,sparse:!0};s=tt(C,e,_)}for(let C=0,_,M,H;_=s[C];C++)switch(M=_.moved,H=_.index,_.status){case"deleted":for(;l<H;)g(l++);M===void 0&&(h=o[l],h.dependentObservable&&(h.dependentObservable.dispose(),h.dependentObservable=void 0),Re(h.mappedNodes,n).length&&(r.beforeRemove&&(u.push(h),b.push(h),T++,h.arrayEntry===ls?h=null:m.push(h)),h!=null&&h.mappedNodes&&p.push.apply(p,h.mappedNodes))),l++;break;case"added":for(;d<H;)g(l++);M!==void 0?g(M):k(_.value);break}for(;d<e.length;)g(l++);u._countWaitingForRemove=T}D.set(n,as,u),N(r.beforeMove,A),P(p,r.beforeRemove?G:he);for(let C=0,_=y.firstChild(n),M,H;h=b[C];C++){h.mappedNodes||L(h,yu(n,t,h.arrayEntry,i,h.indexObservable));for(let te=0;H=h.mappedNodes[te];_=H.nextSibling,M=H,te++)H!==_&&y.insertAfter(n,H,M);!h.initialized&&i&&(i(h.arrayEntry,h.mappedNodes,h.indexObservable),h.initialized=!0)}N(r.beforeRemove,m);for(let C=0;C<m.length;++C)m[C].arrayEntry=ls;N(r.afterMove,A),N(r.afterAdd,v)}var je=class extends ee{get controlsDescendants(){return!0}applyBindingsToDescendants(e,t){return Ye(this,null,function*(){let r=se(e,this.$element);r.isSync?this.bindingCompletion=r:yield r.completionPromise,t&&t(r),this.completeBinding(r)})}};var cs=1,ds=2,fs=3,hr=4,Au=5,ps=D.nextKey()+"_",hs=D.nextKey();function ms(n){return D.get(n,hs)||{}}function mr(n,e){D.set(n,hs,e)}var We=class{constructor(e){if(this.domElement=e,e.nodeType===Node.COMMENT_NODE)this.templateType=hr;else{let t=R(this.domElement);this.templateType=t==="script"?cs:t==="textarea"?ds:t=="template"&&e.content&&e.content.nodeType===Node.DOCUMENT_FRAGMENT_NODE?fs:hr}}text(e){let t=this.templateType===cs?"text":this.templateType===ds?"value":"innerHTML";if(arguments.length==0)return this.domElement[t];t==="innerHTML"?st(this.domElement,e):this.domElement[t]=e}data(e,t){if(arguments.length===1)return D.get(this.domElement,ps+e);D.set(this.domElement,ps+e,t)}nodes(e){let t=this.domElement;if(arguments.length==0){let r=ms(t),i=r.containerData||(this.templateType===fs?t.content:this.templateType===hr?t:void 0);if(!i||r.alwaysCheckText){let s=this.text();s&&(i=wi(s,t.ownerDocument),this.text(""),mr(t,{containerData:i,alwaysCheckText:!0}))}return i}else mr(t,{containerData:e})}},Ee=class extends We{constructor(e){super(e),this.templateType=Au}text(e){if(arguments.length==0){let t=ms(this.domElement);return t.textData===void 0&&t.containerData&&(t.textData=t.containerData.innerHTML),t.textData}else mr(this.domElement,{textData:e})}};function Ue(){}L(Ue.prototype,{renderTemplateSource(n,e,t,r){t.onError("Override renderTemplateSource")},createJavaScriptEvaluatorBlock(n){c.onError(new Error("Override createJavaScriptEvaluatorBlock"))},makeTemplateSource(n,e){if(typeof n=="string"){e=e||document;let t=e.getElementById(n);if(!t)throw c.onError(new Error("Cannot find template with ID "+n),!1);return new We(t)}else{if(n.nodeType===Node.ELEMENT_NODE)return new Ee(n);if(n.nodeType===Node.COMMENT_NODE)return new Ee(n);throw c.onError(new Error("Unknown template type: "+n),!1)}},renderTemplate(n,e,t,r){let i=this.makeTemplateSource(n,r);return this.renderTemplateSource(i,e,t,r)}});var Er,gs=D.nextKey();function vn(n){if(n!==void 0&&!(n instanceof Ue))throw new Error("templateEngine must inherit from ko.templateEngine");Er=n}function gr(n,e,t){let r,i=n,s=y.nextSibling(e);for(;i&&(r=i)!==s;)i=y.nextSibling(r),t(r,i)}function Es(n,e,t){if(n.length){let r=n[0],i=n[n.length-1],s=r.parentNode,o=c.bindingProviderInstance,a=o.preprocessNode;if(a){if(gr(r,i,function(u,l){let d=u.previousSibling,p=a.call(o,u);p&&(u===r&&(r=p[0]||l),u===i&&(i=p[p.length-1]||d))}),n.length=0,!r)return;r===i?n.push(r):(n.push(r,i),Re(n,s))}gr(r,i,function(u){(u.nodeType===Node.ELEMENT_NODE||u.nodeType===Node.COMMENT_NODE)&&Et(e,u).then(t)}),gr(r,i,function(u){(u.nodeType===Node.ELEMENT_NODE||u.nodeType===Node.COMMENT_NODE)&&$e.unmemoizeDomNodeAndDescendants(u,[e])}),Re(n,s)}}function br(n){return n.nodeType?n:n.length>0?n[0]:null}function ys(n,e,t,r,i,s){i=i||{};let a=(n&&br(n)||t||{}).ownerDocument,l=(i.templateEngine||Er).renderTemplate(t,r,i,a);if(typeof l.length!="number"||l.length>0&&typeof l[0].nodeType!="number")throw new Error("Template engine must return an array of DOM nodes");let d=!1;switch(e){case"replaceChildren":y.setDomNodeChildren(n,l),d=!0;break;case"replaceNode":ln(n,l),d=!0;break;case"ignoreTargetNode":break;default:throw new Error("Unknown renderMode: "+e)}return d&&(Es(l,r,s),i.afterRender&&x.ignore(i.afterRender,null,[l,r.$data]),e==="replaceChildren"&&$.notify(n,$.childrenComplete)),l}function As(n,e,t){return S(n)?n():typeof n=="function"?n(e,t):n}function Fn(n,e,t,r,i,s){if(t=t||{},(t.templateEngine||Er)===void 0)throw new Error("Set a template engine before calling renderTemplate");if(i=i||"replaceChildren",r){let o=br(r),a=function(){return!o||!Ot(o)},u=o&&i==="replaceNode"?o.parentNode:o;return B(function(){let l=e&&e instanceof ve?e:new ve(e,void 0,void 0,void 0,{exportDependencies:!0}),d=As(n,l.$data,l),p=ys(r,i,d,l,t,s);i==="replaceNode"&&(r=p,o=br(r))},null,{disposeWhen:a,disposeWhenNodeIsRemoved:u})}else return $e.memoize(function(o){Fn(n,e,t,o,"replaceNode")})}function Ds(n,e,t,r,i,s){let o;function a(p,b){t.as?c.createChildContextWithAs?o=i.createChildContext(p,t.as,A=>{A.$index=b}):o=i.extend({[t.as]:p,$index:b}):o=i.createChildContext(p,t.as,A=>{A.$index=b});let m=As(n,p,o);return ys(r,"ignoreTargetNode",m,o,t,s)}let u=function(p,b){Es(b,o,s),t.afterRender&&t.afterRender(b,p),o=null};function l(p,b){x.ignore(yt,null,[r,p,a,t,u,b]),$.notify(r,$.childrenComplete)}let d=t.includeDestroyed===!1||c.foreachHidesDestroyed&&!t.includeDestroyed;if(!d&&!t.beforeRemove&&Lt(e)){l(e.peek());let p=e.subscribe(function(b){l(e(),b)},null,"arrayChange");return p.disposeWhenNodeIsRemoved(r),p}else return B(function(){let p=f(e)||[];Symbol.iterator in p||(p=[p]),d&&(p=Me(p,function(m){return m==null||!f(m._destroy)})),l(p)},null,{disposeWhenNodeIsRemoved:r})}var bs=D.nextKey(),At=class extends ee{constructor(e){super(e);let t=this.$element,r=f(this.value);D.set(t,"conditional",{elseChainSatisfied:w(!0)}),typeof r=="string"||r.name?this.bindNamedTemplate():"nodes"in r?this.bindNodeTemplate(r.nodes||[]):this.bindAnonymousTemplate()}bindNamedTemplate(){y.emptyNode(this.$element)}bindNodeTemplate(e){if(S(e))throw new Error('The "nodes" option must be a plain, non-observable array.');let t=e[0]&&e[0].parentNode;(!t||!D.get(t,gs))&&(t=kt(e),D.set(t,gs,!0)),new Ee(this.$element).nodes(t)}bindAnonymousTemplate(){let e=y.childNodes(this.$element);if(e.length===0)throw new Error("Anonymous template defined, but no template content was provided.");let t=kt(e);new Ee(this.$element).nodes(t)}onValueChange(){let e=this.$element,t=this.$context,r=this.value,i=f(r),s=!0,o=null,a=D.get(e,"conditional").elseChainSatisfied,u;if(typeof i=="string"?(u=r,i={}):(u=i.name,"if"in i&&(s=f(i.if)),s&&"ifnot"in i&&(s=!f(i.ifnot))),"foreach"in i){let l=s&&i.foreach||[];o=Ds(u||e,l,i,e,t,this.completeBinding),a((f(l)||[]).length!==0)}else if(s){let l="data"in i?t.createStaticChildContext(i.data,i.as):t;o=Fn(u||e,l,i,e,void 0,this.completeBinding),a(!0)}else y.emptyNode(e),a(!1);this.disposeOldComputedAndStoreNewOne(e,o)}disposeOldComputedAndStoreNewOne(e,t){let r=D.get(e,bs);r&&typeof r.dispose=="function"&&r.dispose(),D.set(e,bs,t&&(!t.isActive||t.isActive())?t:void 0)}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};function oe(){}oe.prototype=new Ue;oe.prototype.constructor=oe;oe.prototype.renderTemplateSource=function(n,e,t,r){let i=n.nodes?n.nodes():null;if(i)return ue(i.cloneNode(!0).childNodes);{let s=n.text();return le(s,r)}};oe.instance=new oe;vn(oe.instance);var wn=class extends At{get value(){let e=this.valueAccessor(),t=lt(e);return!t||typeof t.length=="number"?{foreach:e,templateEngine:oe.instance}:(f(e),{foreach:t.data,as:t.as,includeDestroyed:t.includeDestroyed,afterAdd:t.afterAdd,beforeRemove:t.beforeRemove,afterRender:t.afterRender,beforeMove:t.beforeMove,afterMove:t.afterMove,templateEngine:oe.instance})}};var Cs={foreach:wn,template:At};var xs={addDisposeCallback:Ae,removeDisposeCallback:it,removeNode:he,addCleaner:gi,removeCleaner:bi,get cleanExternalData(){return c.cleanExternalData},set cleanExternalData(n){c.set("cleanExternalData",n)}},Du={addOrRemoveItem:we,arrayFilter:Me,arrayFirst:rn,arrayForEach:P,arrayGetDistinctValues:ii,arrayIndexOf:j,arrayMap:Xe,arrayPushAll:et,arrayRemoveItem:Ze,cloneNodes:De,compareArrays:tt,createSymbolOrString:z,domData:D,domNodeDisposal:xs,extend:L,filters:c.filters,objectForEach:V,objectMap:pe,parseHtmlFragment:le,parseJson:ai,parseObjectLiteral:ht,peekObservable:lt,range:si,registerEventHandler:K,setDomNodeChildrenFromArrayMapping:yt,setHtml:st,setTextContent:Le,toggleDomNodeCssClass:nt,triggerEvent:Pe,unwrapObservable:f},yr={cleanNode:G,dependencyDetection:x,computedContext:x,filters:c.filters,ignoreDependencies:x.ignore,memoization:$e,options:c,removeNode:he,selectExtensions:O,tasks:me,utils:Du,LifeCycle:X,isObservable:S,isSubscribable:ut,isWriteableObservable:Q,isWritableObservable:Q,observable:w,observableArray:ce,isObservableArray:Lt,peek:lt,subscribable:W,unwrap:f,toJS:dt,toJSON:ur,proxy:yn,computed:B,dependentObservable:B,isComputed:mt,isPureComputed:cr,pureComputed:xe,when:dr,nativeTemplateEngine:oe,renderTemplate:Fn,setTemplateEngine:vn,templateEngine:Ue,templateSources:{domElement:We,anonymousTemplate:Ee},applyBindingAccessorsToNode:Ut,applyBindings:Et,applyBindingsToDescendants:se,applyBindingsToNode:us,contextFor:Fe,dataFor:Dn,BindingHandler:Z,AsyncBindingHandler:ee,virtualElements:y,domNodeDisposal:xs,bindingEvent:$},Qt=class{constructor({provider:e,bindings:t,extenders:r,filters:i,options:s}){if(Object.assign(yr.options,s,{filters:i,bindingProviderInstance:e}),e.setGlobals(yr.options.bindingGlobals),Array.isArray(t))for(let o of t)e.bindingHandlers.set(o);else e.bindingHandlers.set(t);this.providedProperties={extenders:Object.assign(ge,r),bindingHandlers:e.bindingHandlers,bindingProvider:e}}create(...e){let t=Object.assign({get getBindingHandler(){return c.getBindingHandler},set getBindingHandler(r){c.set("getBindingHandler",r)}},yr,this.providedProperties,...e);return t.options.knockoutInstance=t,t}};var Dt=class{set(e,t){typeof e=="string"?this[e]=t:typeof e=="object"?(t!==void 0&&c.onError(new Error("Given extraneous `value` parameter (first param should be a string, but it was an object)."+e)),Object.assign(this,e)):c.onError(new Error("Given a bad binding handler type: "+e))}get(e){let[t]=e.split(".");return this[t]}};var q=class n{constructor(e){if(this.constructor===n)throw new Error("Provider is an abstract base class.");if(!("FOR_NODE_TYPES"in this))throw new Error("Providers must have FOR_NODE_TYPES property");this.bindingHandlers=(e==null?void 0:e.bindingHandlers)||new Dt,this.globals=(e==null?void 0:e.globals)||{}}get FOR_NODE_TYPES(){throw new Error("Providers must override FOR_NODE_TYPES property")}setGlobals(e){this.globals=e}get preemptive(){return!1}nodeHasBindings(e,t){return!1}getBindingAccessors(e,t){return Object.create(null)}preprocessNode(e){return[e]}postProcess(){}get instance(){return this._overloadInstance||this}set instance(e){!e||e===this?this._overloadInstance=void 0:this._overloadInstance=new Ar(e,this)}makeAccessorsFromFunction(e){return pe(x.ignore(e),(t,r)=>()=>e()[r])}makeValueAccessor(e){return()=>e}makeBindingAccessors(e,t,r){return typeof e=="function"?this.makeAccessorsFromFunction(e.bind(null,t,r)):pe(e,this.makeValueAccessor)}},Ar=class extends q{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE,Node.TEXT_NODE,Node.COMMENT_NODE]}constructor(e,t){super(),Object.assign(this,{providerObject:e}),this.bindingHandlers=e.bindingHandlers||t.bindingHandlers}getBindingsAndMakeAccessors(e,t){let r=this.providerObject.getBindings.bind(this.providerObject,e,t);return this.makeAccessorsFromFunction(r)}getBindingAccessors(e,t){return this.providerObject.getBindingAccessors?this.providerObject.getBindingAccessors(e,t):this.getBindingsAndMakeAccessors(e,t)}nodeHasBindings(e){return this.providerObject.nodeHasBindings(e)}preprocessNode(e){return this.providerObject.preprocessNode?this.providerObject.preprocessNode(e):null}};var Oe=class extends q{*processBinding(e,t){let[r,i]=e.split("."),s=this.bindingHandlers.get(r);if(s&&s.preprocess){let o=new Array,a=(...u)=>o.push(u);t=s.preprocess(t,e,a);for(let[u,l]of o)yield*ke(this.processBinding(u,l))}else i&&(t=`{${i}:${t}}`);yield`'${r}':${t}`}*generateBindingString(e){let t=typeof e=="string"?ht(e):e;for(let{key:r,unknown:i,value:s}of t)yield*ke(this.processBinding(r||i,s))}preProcessBindings(e){return Array.from(this.generateBindingString(e)).join(",")}getBindingAccessors(e,t){let r=e&&this.getBindingString(e);if(!r)return;let i=this.preProcessBindings(r);return new Te().parse(i,t,this.globals,e)}getBindingString(e){throw new Error("Overload getBindingString.")}};var Ct=class extends Oe{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE,Node.COMMENT_NODE]}preprocessNode(e){if(e instanceof Element&&e.tagName==="KO"){let t=e.parentNode,r=[...e.childNodes],i=[...this.genElementBindingStrings(e)].join(","),s=document.createComment("ko "+i),o=document.createComment("/ko");t==null||t.insertBefore(s,e);for(let a of r)t==null||t.insertBefore(a,e);return t==null||t.insertBefore(o,e),e.remove(),[s,...r,o]}return null}*genElementBindingStrings(e){for(let{name:t,value:r}of e.attributes)yield`${t.replace(/^ko-/,"")}: ${r}`}getBindingString(e){return e.nodeType===Node.COMMENT_NODE?y.virtualNodeBindingValue(e):null}nodeHasBindings(e,t){return e.nodeType===Node.COMMENT_NODE?y.isStartComment(e):!1}};var xt=class extends Oe{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE]}get BIND_ATTRIBUTE(){return"data-bind"}getBindingString(e){return e.nodeType===Node.ELEMENT_NODE?e.getAttribute(this.BIND_ATTRIBUTE):null}nodeHasBindings(e,t){return e.nodeType===Node.ELEMENT_NODE?e.hasAttribute(this.BIND_ATTRIBUTE):!1}};var Dr={},Cr={};function Cu(n,e){let t=Wn(Dr,n),r;t?t.subscribe(e):(t=Dr[n]=new W,t.subscribe(e),xu(n,function(i,s){let o=!!(s&&s.synchronous);Cr[n]={definition:i,isSynchronousComponent:o},delete Dr[n],r||o?t.notifySubscribers(i):me.schedule(function(){t.notifySubscribers(i)})}),r=!0)}function xu(n,e){Kt("getConfig",[n],function(t){t?Kt("loadComponent",[n,t],function(r){e(r,t)}):e(null,null)})}function Kt(n,e,t,r){r||(r=de.loaders.slice(0));let i=r.shift();if(i){let s=i[n];if(s){let o=!1;if(s.apply(i,e.concat(function(u){o?t(null):u!==null?t(u):Kt(n,e,t,r)}))!==void 0&&(o=!0,!i.suppressLoaderExceptions))throw new Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.")}else Kt(n,e,t,r)}else t(null)}var de={get(n,e){let t=Wn(Cr,n);t?t.isSynchronousComponent?x.ignore(function(){e(t.definition)}):me.schedule(function(){e(t.definition)}):Cu(n,e)},clearCachedDefinition(n){delete Cr[n]},_getFirstResultFromLoaders:Kt,loaders:new Array};var Qe={},Bn=Symbol("Knockout View Model ViewModel factory");function Nn(n,e){if(!e)throw new Error("Invalid configuration for "+n);if(wr(n))throw new Error("Component "+n+" is already registered");let t=n.includes("-")&&n.toLowerCase()===n;!e.ignoreCustomElementWarning&&!t&&console.log(`
|
|
12
11
|
\u{1F94A} Knockout warning: components for custom elements must be lowercase and contain a dash. To ignore this warning, add to the 'config' of .register(componentName, config):
|
|
13
12
|
|
|
14
13
|
ignoreCustomElementWarning: true
|
|
15
|
-
`),tt[t]=e}function On(t){return Y(tt,t)}function ks(t){delete tt[t],he.clearCachedDefinition(t)}var Pn={getConfig:function(t,e){var r=Y(tt,t)?tt[t]:null;e(r)},loadComponent:function(t,e,r){var n=_n(t);In(n,e,function(i){Hu(t,n,i,r)})},loadTemplate:function(t,e,r){ju(_n(t),e,r)},loadViewModel:function(t,e,r){Is(_n(t),e,r)}},kn="createViewModel";function Hu(t,e,r,n){var i={},s=2,o=function(){--s===0&&n(i)},u=r.template,a=r.viewModel;u?In(e,u,function(l){he._getFirstResultFromLoaders("loadTemplate",[t,l],function(f){i.template=f,o()})}):o(),a?In(e,a,function(l){he._getFirstResultFromLoaders("loadViewModel",[t,l],function(f){i[kn]=f,o()})}):o()}function ju(t,e,r){if(typeof e=="string")r(be(e));else if(e instanceof Array)r(e);else if(nn(e))r(le(e.childNodes));else if(e.element){var n=e.element;if(pi(n))r(_s(n));else if(typeof n=="string"){var i=document.getElementById(n);i?r(_s(i)):t("Cannot find element with ID "+n)}else t("Unknown element type: "+n)}else e.elementName?r(e):t("Unknown template value: "+e)}function Is(t,e,r){if(e[$r])r((...i)=>e[$r](...i));else if(typeof e=="function")r(function(i){return new e(i)});else if(typeof e[kn]=="function")r(e[kn]);else if("instance"in e){var n=e.instance;r(function(){return n})}else"viewModel"in e?Is(t,e.viewModel,r):t("Unknown viewModel value: "+e)}function _s(t){switch(V(t)){case"script":return be(t.text);case"textarea":return be(t.value);case"template":if(nn(t.content))return De(t.content.childNodes)}return De(t.childNodes)}function In(t,e,r){typeof e.require=="string"?window.amdRequire||window.require?(window.amdRequire||window.require)([e.require],r):t("Uses require, but no AMD loader is present"):r(e)}function _n(t){return function(e){throw new Error("Component '"+t+"': "+e)}}he.loaders.push(Pn);var Hr=class extends G{static get customElementName(){return this.name.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}static get template(){if(!("template"in this.prototype))return{element:this.element}}static get element(){throw new Error("[ComponentABC] `element` must be overloaded.")}static get sync(){return!0}static[$r](e,r){return new this(e,r)}static register(e=this.customElementName){let r=this,{template:n}=this,i=this.sync;Lr(e,{viewModel:r,template:n,synchronous:i})}};var rt={ComponentABC:Hr,get:he.get,clearCachedDefinition:he.clearCachedDefinition,register:Lr,isRegistered:On,unregister:ks,defaultLoader:Pn,_allRegisteredComponents:tt,get loaders(){return he.loaders},set loaders(t){he.loaders=t}};var Tt=class extends q{get FOR_NODE_TYPES(){return[1]}preprocessNode(e){if(e.tagName==="SLOT"){let r=e.parentNode,n=e.getAttribute("name")||"",i=document.createComment(`ko slot: "${n}"`),s=document.createComment("/ko");return r.insertBefore(i,e),r.insertBefore(s,e),r.removeChild(e),[i,s]}}nodeHasBindings(e){return Boolean(this.getComponentNameForNode(e))}getBindingAccessors(e,r){let n=this.getComponentNameForNode(e);return n?{component:()=>({name:n,params:this.getComponentParams(e,r)})}:void 0}getComponentNameForNode(e){if(e.nodeType!==e.ELEMENT_NODE)return;let r=V(e);if(rt.isRegistered(r)){let n=r.includes("-"),i=""+e=="[object HTMLUnknownElement]";if(n||i)return r}}getComponentParams(e,r){let n=new Me(e,r,this.globals),i=(e.getAttribute("params")||"").trim(),s=n.parse(i,r,e);if(!s||Object.keys(s).length===0)return{$raw:{}};let o=ge(s,a=>N(a,null,{disposeWhenNodeIsRemoved:e})),u=ge(o,a=>this.makeParamValue(e,a));return Object.assign({$raw:o},u)}makeParamValue(e,r){let n=r.peek();if(!r.isActive())return n;let i=te(n);return N({read:()=>d(r()),write:i?s=>r()(s):null,disposeWhenNodeIsRemoved:e})}};var _t=class extends q{get FOR_NODE_TYPES(){return[1]}get PREFIX(){return"ko-"}getBindingAttributesList(e){return e.hasAttributes()?Array.from(e.attributes).filter(r=>r.name.startsWith(this.PREFIX)):[]}nodeHasBindings(e){return this.getBindingAttributesList(e).length>0}getBindingAccessors(e,r){return Object.assign({},...this.handlersFromAttributes(e,r))}*handlersFromAttributes(e,r){for(let n of this.getBindingAttributesList(e))yield{[n.name.substr(this.PREFIX.length)]:()=>this.getValue(n.value,r,e)}}getValue(e,r,n){if(!e)return;let i=r.$data;switch(e){case"$element":return n;case"$context":return r;case"this":case"$data":return r.$data}if(i instanceof Object&&e in i)return i[e];if(e in r)return r[e];if(e in this.globals)return this.globals[e];throw new Error(`The variable '${e} not found.`)}};var kt=class extends q{get FOR_NODE_TYPES(){return this.nodeTypes}constructor(e={}){super(e);let r=e.providers||[];this.nodeTypeMap={},this.nodeTypes=[],this.providers=[],r.forEach(n=>this.addProvider(n))}setGlobals(e){[this,...this.providers].forEach(r=>r.globals=e)}addProvider(e){this.providers.push(e),e.bindingHandlers=this.bindingHandlers,e.globals=this.globals;let r=this.nodeTypeMap;for(let n of e.FOR_NODE_TYPES)r[n]||(r[n]=[]),r[n].push(e);this.nodeTypes=Object.keys(this.nodeTypeMap).map(n=>parseInt(n,10))}providersFor(e){return this.nodeTypeMap[e.nodeType]||[]}nodeHasBindings(e){return this.providersFor(e).some(r=>r.nodeHasBindings(e))}preprocessNode(e){for(let r of this.providersFor(e)){let n=r.preprocessNode(e);if(n)return n}}*enumerateProviderBindings(e,r){for(let n of this.providersFor(e)){let i=n.getBindingAccessors(e,r);if(!!i&&(yield*Object.entries(i||{}),n.preemptive))return}}getBindingAccessors(e,r){let n={};for(let[i,s]of this.enumerateProviderBindings(e,r)){if(i in n)throw new Error(`The binding "${i}" is duplicated by multiple providers`);n[i]=s}return n}};var Os={update:function(t,e,r){var n=d(e())||{};O(n,function(i,s){s=d(s);var o=i.indexOf(":"),u=o>0&&t.lookupNamespaceURI(i.substr(0,o));let a=s===!1||s===null||s===void 0;a?u?t.removeAttributeNS(u,i):t.removeAttribute(i):(s=s.toString(),u?t.setAttributeNS(u,i,s):t.setAttribute(i,s)),i==="name"&&Cr(t,a?"":s)})}};var Ps={after:["value","attr"],init:function(t,e,r){var n=we(function(){if(r.has("checkedValue"))return d(r.get("checkedValue"));if(m)return r.has("value")?d(r.get("value")):t.value});function i(){var p=t.checked,A=n();if(!C.isInitial()&&!(!p&&(u||C.getDependenciesCount()))){var x=C.ignore(e);if(l){var b=f?x.peek():x,P=h;h=A,P!==A?(p&&(Oe(b,A,!0),Oe(b,P,!1)),h=A):Oe(b,A,p),f&&te(x)&&x(b)}else o&&(A===void 0?A=p:p||(A=void 0)),e(A,{onlyIfChanged:!0})}}function s(){var p=p=d(e()),A=n();l?(t.checked=U(p,A)>=0,h=A):o&&A===void 0?t.checked=!!p:t.checked=n()===p}var o=t.type=="checkbox",u=t.type=="radio";if(!(!o&&!u)){var a=e(),l=o&&d(a)instanceof Array,f=!(l&&a.push&&a.splice),m=u||l,h=l?n():void 0;N(i,null,{disposeWhenNodeIsRemoved:t}),Q(t,"click",i),N(s,null,{disposeWhenNodeIsRemoved:t}),a=void 0}}},Vs={update:function(t,e){t.value=d(e())}};function Ms(t){return{init:function(e,r,n,i,s){var o=function(){var u={};return u[t]=r(),u};jr.init.call(this,e,o,n,i,s)}}}function Rs(t){return typeof t=="function"?{handler:t}:t||{}}var jr={init:function(t,e,r,n,i){var s=e()||{};O(s,function(o,u){let{passive:a,capture:l,once:f,debounce:m,throttle:h}=Rs(u),p=(l||a||f)&&{capture:l,passive:a,once:f},A=(x,...b)=>{var P;let{handler:F,passive:E,bubble:B,preventDefault:w}=Rs(e()[o]);try{if(F){let M=i.$data,ne=[M,x,...b];P=F.apply(M,ne)}}finally{w!==void 0?d(w)&&x.preventDefault():P!==!0&&(E||x.preventDefault())}let R=r.get(o+"Bubble")!==!1;(B===!1||!R)&&(x.cancelBubble=!0,x.stopPropagation&&x.stopPropagation())};m&&(A=vr(A,m)),h&&(A=gr(A,h)),Q(t,o,A,p||!1)})}},$s={init:jr.init,preprocess:function(t,e,r){r(e.replace("on.",""),"=>"+t)}};var Ls=Ms("click");var rr={aliases:["class"],update:function(t,e){var r=d(e());r!==null&&typeof r=="object"?O(r,function(n,i){i=d(i),dt(t,n,i)}):(r=Ue(String(r||"")),dt(t,t[rr.classesWrittenByBindingKey],!1),t[rr.classesWrittenByBindingKey]=r,dt(t,r,!0))},classesWrittenByBindingKey:z("__ko__cssValue")};var nr=class extends ee{onDescendantsComplete(){typeof this.value=="function"&&this.value(this.$element)}static get allowVirtualElements(){return!0}};var Vn={update:function(t,e){var r=d(e());r&&t.disabled?t.removeAttribute("disabled"):!r&&!t.disabled&&(t.disabled=!0)}},Hs={update:function(t,e){Vn.update(t,function(){return!d(e())})}};var Rn=z("__ko_hasfocusUpdating"),Mn=z("__ko_hasfocusLastValue"),$n={init:function(t,e){var r=function(s){t[Rn]=!0;var o=t.ownerDocument;if("activeElement"in o){var u;try{u=o.activeElement}catch(a){u=o.body}s=u===t}e(s,{onlyIfChanged:!0}),t[Mn]=s,t[Rn]=!1},n=r.bind(null,!0),i=r.bind(null,!1);Q(t,"focus",n),Q(t,"focusin",n),Q(t,"blur",i),Q(t,"focusout",i)},update:function(t,e){var r=!!d(e());!t[Rn]&&t[Mn]!==r&&(r?t.focus():t.blur(),!r&&t[Mn]&&t.ownerDocument.body.focus(),C.ignore(Ke,null,[t,r?"focusin":"focusout"]))}};var js={init:function(){return{controlsDescendantBindings:!0}},update:function(t,e){ht(t,e())},allowVirtualElements:!0};var Ws={init:function(t,e,r,n,i){var s=i.extend(e);return ue(s,t),{controlsDescendantBindings:!0}},allowVirtualElements:!0};var Ln={},Us={init:function(t){if(V(t)!=="select")throw new Error("options binding applies only to SELECT elements");for(;t.length>0;)t.remove(0);return{controlsDescendantBindings:!0}},update:function(t,e,r){function n(){return We(t.options,function(E){return E.selected})}var i=t.length==0,s=t.multiple,o=!i&&s?t.scrollTop:null,u=d(e()),a=r.get("valueAllowUnset")&&r.has("value"),l=r.get("optionsIncludeDestroyed"),f={},m,h,p=[];a||(s?p=ut(n(),_.readValue):t.selectedIndex>=0&&p.push(_.readValue(t.options[t.selectedIndex]))),u&&(typeof u.length=="undefined"&&(u=[u]),h=We(u,function(E){return l||E===void 0||E===null||!d(E._destroy)}),r.has("optionsCaption")&&(m=d(r.get("optionsCaption")),m!=null&&h.unshift(Ln)));function A(E,B,w){var R=typeof B;return R==="function"?B(E):R=="string"?E[B]:w}var x=!1;function b(E,B,w){w.length&&(p=!a&&w[0].selected?[_.readValue(w[0])]:[],x=!0);var R=t.ownerDocument.createElement("option");if(E===Ln)Je(R,r.get("optionsCaption")),_.writeValue(R,void 0);else{var M=A(E,r.get("optionsValue"),E);_.writeValue(R,d(M));var ne=A(E,r.get("optionsText"),M);Je(R,ne)}return[R]}f.beforeRemove=function(E){t.removeChild(E)};function P(E,B){if(x&&a)_.writeValue(t,d(r.get("value")),!0);else if(p.length){var w=U(p,_.readValue(B[0]))>=0;xr(B[0],w),x&&!w&&C.ignore(Ke,null,[t,"change"])}}var F=P;r.has("optionsAfterRender")&&typeof r.get("optionsAfterRender")=="function"&&(F=function(E,B){P(E,B),C.ignore(r.get("optionsAfterRender"),null,[B[0],E!==Ln?E:void 0])}),Bt(t,h,b,f,F),C.ignore(function(){if(a)_.writeValue(t,d(r.get("value")),!0);else{var E;s?E=p.length&&n().length<p.length:E=p.length&&t.selectedIndex>=0?_.readValue(t.options[t.selectedIndex])!==p[0]:p.length||t.selectedIndex>=0,E&&Ke(t,"change")}}),xi(t),o&&Math.abs(o-t.scrollTop)>20&&(t.scrollTop=o)}};var Qs={after:["options","foreach"],init:function(t,e,r){Q(t,"change",function(){var n=e(),i=[];I(t.getElementsByTagName("option"),function(s){s.selected&&i.push(_.readValue(s))}),e(i)})},update:function(t,e){if(V(t)!="select")throw new Error("values binding applies only to SELECT elements");var r=d(e()),n=t.scrollTop;r&&typeof r.length=="number"&&I(t.getElementsByTagName("option"),function(i){var s=U(r,_.readValue(i))>=0;i.selected!=s&&xr(i,s)}),t.scrollTop=n}};var{jQueryInstance:Ks}=c,qs={update:function(t,e){var r=d(e()||{});O(r,function(n,i){if(i=d(i),(i==null||i===!1)&&(i=""),Ks)Ks(t).css(n,i);else{n=n.replace(/-(\w)/g,(o,u)=>u.toUpperCase());let s=t.style[n];t.style[n]=i,i!==s&&t.style[n]===s&&!isNaN(i)&&(t.style[n]=i+"px")}})}};var Js={init:function(t,e,r,n,i){if(typeof e()!="function")throw new Error("The value for a submit binding must be a function");Q(t,"submit",function(s){var o,u=e();try{o=u.call(i.$data,t)}finally{o!==!0&&(s.preventDefault?s.preventDefault():s.returnValue=!1)}})}};var Gs={init:function(){return{controlsDescendantBindings:!0}},update:function(t,e){Je(t,e())},allowVirtualElements:!0};var Ys,Hn,jn,nt=class extends ee{get aliases(){return"textinput"}constructor(...e){super(...e),this.previousElementValue=this.$element.value,c.debug&&this.constructor._forceUpdateOn&&I(this.constructor._forceUpdateOn,r=>{r.slice(0,5)==="after"?this.addEventListener(r.slice(5),"deferUpdateModel"):this.addEventListener(r,"updateModel")});for(let r of this.eventsIndicatingSyncValueChange())this.addEventListener(r,"updateModel");for(let r of this.eventsIndicatingDeferValueChange())this.addEventListener(r,"deferUpdateModel");this.computed("updateView")}eventsIndicatingSyncValueChange(){return["input","change","blur"]}eventsIndicatingDeferValueChange(){return[]}updateModel(e){let r=this.$element;clearTimeout(this.timeoutHandle),this.elementValueBeforeEvent=this.timeoutHandle=void 0;let n=r.value;this.previousElementValue!==n&&(c.debug&&e&&(r._ko_textInputProcessedEvent=e.type),this.previousElementValue=n,this.value=n)}deferUpdateModel(e){let r=this.$element;if(!this.timeoutHandle){this.elementValueBeforeEvent=r.value;let n=c.debug?this.updateModel.bind(this,{type:e.type}):this.updateModel;this.timeoutHandle=ce(n,4)}}updateView(){let e=d(this.value);e==null&&(e=""),this.elementValueBeforeEvent!==void 0&&e===this.elementValueBeforeEvent?setTimeout(this.updateView.bind(this),4):this.$element.value!==e&&(this.previousElementValue=e,this.$element.value=e,this.previousElementValue=this.$element.value)}},sr=class extends nt{constructor(...e){super(...e),$<11&&this.addEventListener("propertychange",r=>r.propertyName==="value"&&this.updateModel(r)),$>=8&&$<10&&(this.watchForSelectionChangeEvent(),this.addEventListener("dragend","deferUpdateModel"))}eventsIndicatingSyncValueChange(){return[...super.eventsIndicatingValueChange(),"keypress"]}selectionChangeHandler(e){let r=this.activeElement,n=r&&y.get(r,selectionChangeHandlerName);n&&n(e)}watchForSelectionChangeEvent(e,r){let n=e.ownerDocument;y.get(n,selectionChangeRegisteredName)||(y.set(n,selectionChangeRegisteredName,!0),Q(n,"selectionchange",this.selectionChangeHandler.bind(n))),y.set(e,selectionChangeHandlerName,handler)}},Wn=class extends sr{updateModel(...e){this.deferUpdateModel(...e)}},Un=class extends sr{eventsIndicatingValueChange(){return[...super.eventsIndicatingValueChange(),"keyup","keydown"]}},Qn=class extends nt{eventsIndicatingDeferValueChange(){return["keydown","paste","cut"]}},Kn=class extends nt{eventsIndicatingDeferValueChange(){return["keydown"]}},qn=class extends nt{eventsIndicatingValueChange(){return[...super.eventsIndicatingSyncValueChange(),"DOMAutoComplete","dragdrop","drop"]}},ir=c.global;if(ir.navigator){let t=n=>n&&parseFloat(n[1]),e=ir.navigator.userAgent,r=e.match(/Chrome\/([^ ]+)/);Ys=ir.opera&&ir.opera.version&&parseInt(ir.opera.version()),Hn=t(e.match(/Version\/([^ ]+) Safari/)),jn=t(e.match(/Firefox\/([^ ]*)/))}var Jn=$===8?Un:$===9?Wn:$?sr:Hn&&Hn<5?Qn:Ys<11?Kn:jn&&jn<4?qn:nt;var Gn={init:function(t,e){if(e()){var r="ko_unique_"+ ++Gn.currentIndex;Cr(t,r)}},currentIndex:0};var Wr=class extends ee{static get after(){return["options","foreach","template"]}constructor(...e){if(super(...e),this.isCheckboxOrRadio){Xt(this.$element,{checkedValue:this.valueAccessor});return}this.propertyChangedFired=!1,this.elementValueBeforeEvent=null,this.ieAutoCompleteHackNeeded&&(this.addEventListener("propertyChange",()=>this.propertyChangedFired=!0),this.addEventListener("focus",()=>this.propertyChangedFired=!1),this.addEventListener("blur",()=>this.propertyChangeFired&&this.valueUpdateHandler())),I(this.eventsToCatch,r=>this.registerEvent(r)),this.isInput&&this.$element.type==="file"?this.updateFromModel=this.updateFromModelForFile:this.updateFromModel=this.updateFromModelForValue,this.computed("updateFromModel")}get eventsToCatch(){let e=this.allBindings.get("valueUpdate"),r=typeof e=="string"?[e]:e||[];return[...new Set(["change",...r])]}get isInput(){return V(this.$element)==="input"}get isCheckboxOrRadio(){let e=this.$element;return this.isInput&&(e.type=="checkbox"||e.type=="radio")}get ieAutoCompleteHackNeeded(){return $&&isInputElement&&this.$element.type=="text"&&this.$element.autocomplete!="off"&&(!this.$element.form||this.$element.form.autocomplete!="off")}valueUpdateHandler(){this.elementValueBeforeEvent=null,this.propertyChangedFired=!1,this.value=_.readValue(this.$element)}registerEvent(e){var r=this.valueUpdateHandler.bind(this);li(e,"after")&&(r=()=>{this.elementValueBeforeEvent=_.readValue(this.$element),ce(this.valueUpdateHandler.bind(this),0)},e=e.substring(5)),this.addEventListener(e,r)}updateFromModelForFile(){var e=d(this.value);e==null||e===""?this.$element.value="":C.ignore(this.valueUpdateHandler,this)}updateFromModelForValue(){let e=this.$element;var r=d(this.value),n=_.readValue(e);if(this.elementValueBeforeEvent!==null&&r===this.elementValueBeforeEvent){ce(this.updateFromModel.bind(this),0);return}if(!(r===n&&n!==void 0))if(V(e)==="select"){let i=this.allBindings.get("valueAllowUnset");_.writeValue(e,r,i),!i&&r!==_.readValue(e)&&C.ignore(this.valueUpdateHandler,this)}else _.writeValue(e,r)}};var Yn={update:function(t,e){var r=d(e()),n=t.style.display!=="none";r&&!n?t.style.display="":!r&&n&&(t.style.display="none")}},zs={update:function(t,e){Yn.update.call(this,t,()=>!d(e()))}};var Xs={init:function(t,e,r,n,i){var s=i.createChildContext(e);return ue(s,t),{controlsDescendantBindings:!0}},allowVirtualElements:!0};var Zs={attr:Os,checked:Ps,checkedValue:Vs,click:Ls,css:rr,class:rr,descendantsComplete:nr,enable:Vn,event:jr,disable:Hs,hasfocus:$n,hasFocus:$n,hidden:zs,html:js,let:Ws,on:$s,options:Us,selectedOptions:Qs,style:qs,submit:Js,text:Gs,textInput:Jn,textinput:Jn,uniqueName:Gn,using:Xs,value:Wr,visible:Yn};var Wu=(t,e,r)=>new Promise((n,i)=>{var s=a=>{try{u(r.next(a))}catch(l){i(l)}},o=a=>{try{u(r.throw(a))}catch(l){i(l)}},u=a=>a.done?n(a.value):Promise.resolve(a.value).then(s,o);u((r=r.apply(t,e)).next())}),it=class extends re{constructor(e){super(e),this.hasElse=this.detectElse(this.$element);let r=this.completesElseChain=S();y.set(this.$element,"conditional",{elseChainSatisfied:r})}getIfElseNodes(){if(this.ifElseNodes)return this.ifElseNodes;if(C.getDependenciesCount()||this.hasElse)return this.cloneIfElseNodes(this.$element,this.hasElse)}render(){let e=!this.ifElseNodes,{shouldDisplay:r}=this.renderStatus();if(this.ifElseNodes=this.getIfElseNodes()||{},r){let n=e&&!this.hasElse;this.renderAndApplyBindings(this.ifElseNodes.ifNodes,n)}else this.hasElse?this.renderAndApplyBindings(this.ifElseNodes.elseNodes):v.emptyNode(this.$element)}renderAndApplyBindings(e,r){return Wu(this,null,function*(){r||v.setDomNodeChildren(this.$element,De(e));let n=yield ue(this.bindingContext,this.$element);this.completeBinding(n)})}get elseChainIsAlreadySatisfied(){return!1}isElseNode(e){return e.nodeType===8&&e.nodeValue.trim().toLowerCase()==="else"}detectElse(e){for(var r=v.childNodes(e),n=0,i=r.length;n<i;++n)if(this.isElseNode(r[n]))return!0;return!1}cloneIfElseNodes(e,r){let n=v.childNodes(e),i=[],s=[],o=i;for(var u=0,a=n.length;u<a;++u)r&&this.isElseNode(n[u])?(o=s,r=!1):o.push(X(n[u].cloneNode(!0)));return{ifNodes:i,elseNodes:s}}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};var st=class extends it{constructor(...e){super(...e),this.ifCondition=this.computed(()=>!!d(this.value)),this.computed("render")}shouldDisplayIf(){return this.ifCondition()}get bindingContext(){return this.ifCondition.isActive()?this.$context.extend(()=>(this.ifCondition(),null)):this.$context}renderStatus(){let e=this.shouldDisplayIf();return this.elseChainIsAlreadySatisfied?(e=!1,this.completesElseChain(!0)):this.completesElseChain(e),{shouldDisplay:e}}},or=class extends st{shouldDisplayIf(){return!super.shouldDisplayIf()}};var Ur=class extends it{constructor(...e){super(...e),this.asOption=this.allBindings.get("as");let r=this.asOption&&!c.createChildContextWithAs?()=>Boolean(d(this.value)):()=>d(this.value);this.conditional=this.computed(r),this.computed("render")}get bindingContext(){return this.asOption?c.createChildContextWithAs?this.$context.createChildContext(this.value,this.asOption):this.$context.extend({[this.asOption]:this.value}):this.$context.createChildContext(this.valueAccessor)}renderStatus(){return{shouldDisplay:Boolean(this.conditional())}}};var ur=class extends st{shouldDisplayIf(){return super.shouldDisplayIf()||this.value===void 0}get elseChainIsAlreadySatisfied(){return this._elseChain||(this._elseChain=this.readElseChain()),d(this._elseChain.elseChainSatisfied)}readElseChain(){let e=this.$element;do e=e.previousSibling;while(e&&e.nodeType!==1&&e.nodeType!==8);return e?(e.nodeType===8&&(e=v.previousSibling(e)),y.get(e,"conditional")||{}):!1}};var eo={if:st,with:Ur,ifnot:or,unless:or,else:ur,elseif:ur};var Uu=9007199254740991;function Qu(t){return!!t&&typeof t=="object"&&t.constructor===Object}var Ku=c.document&&typeof c.document.createDocumentFragment=="function";function qu(t){var e=document.createElement("div"),r;return t.content?r=t.content:t.tagName==="SCRIPT"?(r=document.createElement("div"),r.innerHTML=t.text):r=t,I(v.childNodes(r),function(n){n&&e.insertBefore(n.cloneNode(!0),null)}),e}function Ju(t,e){return{status:"added",value:t,index:e}}var ar=z("_ko_ffe_pending_delete_index"),Te=class extends re{constructor(e){super(e);let r={};Qu(this.value)&&Object.assign(r,this.value),this.as=r.as||this.allBindings.get("as"),this.data=r.data||(d(this.$context.$rawData)===this.value?this.$context.$rawData:this.value),this.container=v.isStartComment(this.$element)?this.$element.parentNode:this.$element,this.generateContext=this.createContextGenerator(this.as),this.$indexHasBeenRequested=!1,this.templateNode=qu(r.templateNode||(r.name?document.getElementById(r.name).cloneNode(!0):this.$element)),["afterAdd","beforeRemove","afterQueueFlush","beforeQueueFlush"].forEach(i=>{this[i]=r[i]||this.allBindings.get(i)}),this.changeQueue=[],this.firstLastNodesList=[],this.indexesToDelete=[],this.rendering_queued=!1,this.pendingDeletes=[],this.isNotEmpty=S(Boolean(d(this.data).length)),y.set(this.$element,"conditional",{elseChainSatisfied:this.isNotEmpty}),v.emptyNode(this.$element);let n=d(this.data);n&&n.map?this.onArrayChange(n.map(Ju),!0):this.completeBinding(),T(this.data)&&(this.data.indexOf||(this.data=this.data.extend({trackArrayChanges:!0})),this.changeSubs=this.data.subscribe(this.onArrayChange,this,"arrayChange"))}dispose(){this.changeSubs&&this.changeSubs.dispose(),this.flushPendingDeletes()}onArrayChange(e,r){for(var n={added:[],deleted:[]},i=0,s=e.length;i<s;i++){if(n.added.length&&e[i].status==="added"){var o=n.added[n.added.length-1],u=o.isBatch?o.index+o.values.length-1:o.index;if(u+1===e[i].index){o.isBatch||(o={isBatch:!0,status:"added",index:o.index,values:[o.value]},n.added.splice(n.added.length-1,1,o)),o.values.push(e[i].value);continue}}n[e[i].status].push(e[i])}n.deleted.length>0&&(this.changeQueue.push.apply(this.changeQueue,n.deleted),this.changeQueue.push({status:"clearDeletedIndexes"})),this.changeQueue.push.apply(this.changeQueue,n.added),this.changeQueue.length>0&&!this.rendering_queued&&(this.rendering_queued=!0,r?this.processQueue():Te.animateFrame.call(window,()=>this.processQueue()))}startQueueFlush(){typeof this.beforeQueueFlush=="function"&&this.beforeQueueFlush(this.changeQueue)}endQueueFlush(){typeof this.afterQueueFlush=="function"&&this.afterQueueFlush(this.changeQueue)}processQueue(){var e=!d(this.data).length,r=Uu;this.startQueueFlush(),I(this.changeQueue,n=>{typeof n.index=="number"&&(r=Math.min(r,n.index)),this[n.status](n)}),this.flushPendingDeletes(),this.rendering_queued=!1,this.$indexHasBeenRequested&&this.updateIndexes(r),this.endQueueFlush(),this.changeQueue=[],e!==!this.isNotEmpty()&&this.isNotEmpty(!e)}_first$indexRequest(e){this.$indexHasBeenRequested=!0;for(let r=0,n=this.firstLastNodesList.length;r<n;++r){let i=this.getContextStartingFrom(this.firstLastNodesList[r].first);i&&(i.$index=S(r))}return e.$index()}_contextExtensions(e){return Object.assign(e,{$list:this.data}),this.$indexHasBeenRequested?e.$index=e.$index||S():Object.defineProperty(e,"$index",{value:()=>this._first$indexRequest(e),configurable:!0,writable:!0}),e}createContextGenerator(e){let r=this.$context;return e?n=>this._contextExtensions(r.extend({[e]:n})):n=>r.createChildContext(n,null,i=>this._contextExtensions(i))}updateFirstLastNodesList(e,r){let n=r[0],i=r[r.length-1];this.firstLastNodesList.splice(e,0,{first:n,last:i})}added(e){var r=e.index,n=e.isBatch?e.values:[e.value],i=this.getLastNodeBeforeIndex(r);let s=[],o=[];for(var u,a=0,l=n.length;a<l;++a){var f=this.getPendingDeleteFor(n[a]);if(f&&f.nodesets.length)u=f.nodesets.pop(),this.updateFirstLastNodesList(r+a,u);else{var m=this.templateNode.cloneNode(!0);u=v.childNodes(m),this.updateFirstLastNodesList(r+a,u);let h=ue(this.generateContext(n[a]),m);o.push(h)}s.push(...u)}typeof this.afterAdd=="function"?this.afterAdd({nodeOrArrayInserted:this.insertAllAfter(s,i),foreachInstance:this}):this.insertAllAfter(s,i),this.completeBinding(Promise.all(o))}getNodesForIndex(e){let r=[],n=this.firstLastNodesList[e].first,i=this.firstLastNodesList[e].last;for(r.push(n);n&&n!==i;)n=n.nextSibling,r.push(n);return r}getLastNodeBeforeIndex(e){return e<1||e-1>=this.firstLastNodesList.length?null:this.firstLastNodesList[e-1].last}activeChildElement(e){var r=document.activeElement;if(rn(r,e))return r}insertAllAfter(e,r){let n,i,s,o=null,u=this.$element;if(e.nodeType===void 0&&e.length===void 0)throw new Error("Expected a single node or a node array");if(e.nodeType!==void 0)return o=this.activeChildElement(e),v.insertAfter(u,e,r),[e];if(e.length===1)o=this.activeChildElement(e[0]),v.insertAfter(u,e[0],r);else if(Ku){for(n=document.createDocumentFragment(),s=0,i=e.length;s!==i;++s)o=o||this.activeChildElement(e[s]),n.appendChild(e[s]);v.insertAfter(u,n,r)}else for(s=e.length-1;s>=0;--s){o=o||this.activeChildElement(e[s]);var a=e[s];if(!a)break;v.insertAfter(u,a,r)}return o&&o.focus(),e}shouldDelayDeletion(e){return e&&(typeof e=="object"||typeof e=="function")}getPendingDeleteFor(e){var r=e&&e[ar];return r===void 0?null:this.pendingDeletes[r]}getOrCreatePendingDeleteFor(e){var r=this.getPendingDeleteFor(e);return r||(r={data:e,nodesets:[]},e[ar]=this.pendingDeletes.length,this.pendingDeletes.push(r),r)}deleted(e){this.shouldDelayDeletion(e.value)?this.getOrCreatePendingDeleteFor(e.value).nodesets.push(this.getNodesForIndex(e.index)):this.removeNodes(this.getNodesForIndex(e.index)),this.indexesToDelete.push(e.index)}removeNodes(e){if(!e.length)return;function r(){for(var i=e[0].parentNode,s=e.length-1;s>=0;--s)X(e[s]),i.removeChild(e[s])}if(this.beforeRemove){var n=this.beforeRemove({nodesToRemove:e,foreachInstance:this})||{};typeof n.then=="function"&&n.then(r,c.onError)}else r()}flushPendingDeletes(){for(let r=0,n=this.pendingDeletes.length;r!==n;++r){for(var e=this.pendingDeletes[r];e.nodesets.length;)this.removeNodes(e.nodesets.pop());e.data&&e.data[ar]!==void 0&&delete e.data[ar]}this.pendingDeletes=[]}clearDeletedIndexes(){for(let e=this.indexesToDelete.length-1;e>=0;--e)this.firstLastNodesList.splice(this.indexesToDelete[e],1);this.indexesToDelete=[]}updateIndexes(e){let r;for(let n=e,i=this.firstLastNodesList.length;n<i;++n)r=this.getContextStartingFrom(this.firstLastNodesList[n].first),r&&r.$index(n)}getContextStartingFrom(e){let r;for(;e;){if(r=Ne(e),r)return r;e=e.nextSibling}}static setSync(e){let r=c.global;e?Te.animateFrame=function(n){n()}:Te.animateFrame=r.requestAnimationFrame||r.webkitRequestAnimationFrame||r.mozRequestAnimationFrame||r.msRequestAnimationFrame||function(n){return r.setTimeout(n,1e3/60)}}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}static get ForEach(){return this}static get PENDING_DELETE_INDEX_SYM(){return ar}};var to={foreach:Te};Te.setSync(!1);var me=Symbol("Knockout native bindings"),je=class extends q{get FOR_NODE_TYPES(){return[1,3]}get preemptive(){return!0}nodeHasBindings(e){return e[me]?Object.keys(e[me]||{}).some(r=>r.startsWith("ko-")):!1}preprocessNode(e){return e[me]?e:null}onlyBindings([e]){return e.startsWith("ko-")}valueAsAccessor([e,r]){let n=e.replace(/^ko-/,""),i=T(r)?r:()=>r;return{[n]:i}}getBindingAccessors(e){let r=Object.entries(e[me]||{}).filter(this.onlyBindings);return r.length?Object.assign({},...r.map(this.valueAsAccessor)):null}static addValueToNode(e,r,n){let i=e[me]||(e[me]={});i[r]=n}static getNodeValues(e){return e[me]}};var Gu=25,Yu=1e3,Xn=[],zn=null;function ro(t){Xn.push(t),no()}function no(){!zn&&Xn.length&&(zn=setTimeout(zu,Gu))}function zu(){zn=null;let t=Xn.splice(0,Yu);for(let e of t)X(e);no()}var It=Symbol("Knockout - Original JSX"),Qr={svg:"http://www.w3.org/2000/svg",html:"http://www.w3.org/1999/xhtml",xml:"http://www.w3.org/XML/1998/namespace",xlink:"http://www.w3.org/1999/xlink",xmlns:"http://www.w3.org/2000/xmlns/"};function io(t){return t&&typeof t[Symbol.iterator]=="function"}var _e=class extends G{constructor(e,r,n=null,i,s){super();let o=r.nodeType===8,u=this.getParentTarget(r);if(T(e))if(e.extend({trackArrayChanges:!0}),this.subscribe(e,this.observableArrayChange,"arrayChange"),n)this.adoptedInsertBefore=!0;else{let f=o?r.nextSibling:null;n=this.createComment("O"),u.insertBefore(n,f)}o&&!n&&(n=r.nextSibling,this.adoptedInsertBefore=!0),this.anchorTo(n||r),Object.assign(this,{insertBefore:n,noInitialBinding:s,parentNode:r,parentNodeTarget:u,xmlns:i,nodeArrayOrObservableAtIndex:[],subscriptionsForNode:new Map});let a=d(e);(Ct(e)||a!=null)&&this.observableArrayChange(this.createInitialAdditions(a)),this.noInitialBinding=!1}getParentTarget(e){return"content"in e?e.content:e.nodeType===8?e.parentNode:e}remove(){this.dispose()}dispose(){super.dispose();let e=this.insertBefore;e&&this.parentNodeTarget===e.parentNode&&!this.adoptedInsertBefore&&this.parentNodeTarget.removeChild(e),this.removeAllPriorNodes(),Object.assign(this,{parentNode:null,parentNodeTarget:null,insertBefore:null,nodeArrayOrObservableAtIndex:[]});for(let n of this.subscriptionsForNode.values())n.forEach(i=>i.dispose());this.subscriptionsForNode.clear()}createInitialAdditions(e){let r="added";return typeof possibleIteratable=="object"&&posibleIterable!==null&&Symbol.iterator in e&&(e=[...e]),Array.isArray(e)?e.map((n,i)=>({index:i,status:r,value:n})):[{status:r,index:0,value:e}]}observableArrayChange(e){let r=[],n=[];for(let i in e){let s=e[i];s.status==="added"?r.push([s.index,s.value]):n.unshift([s.index,s.value])}n.forEach(i=>this.delChange(...i)),r.forEach(i=>this.addChange(...i))}addChange(e,r){this.nodeArrayOrObservableAtIndex.splice(e,0,this.injectNode(r,this.lastNodeFor(e)))}injectNode(e,r){let n;if(T(e)){let{parentNode:i,xmlns:s}=this;n=[new _e(e,i,r,s,this.noInitialBinding)]}else if(typeof e!="string"&&io(e)){n=[];for(let i of e)n.unshift(this.injectNode(i,r))}else{let i=Ne(this.parentNode),s="content"in this.parentNode,o=i&&!s&&!this.noInitialBinding;Array.isArray(e)?n=e.map(u=>this.anyToNode(u)):n=[this.anyToNode(e)];for(let u of n)this.parentNodeTarget.insertBefore(u,r),o&&this.canApplyBindings(u)&&Ft(i,u)}return n}canApplyBindings(e){return e.nodeType===1||e.nodeType===8}delChange(e){this.removeNodeArrayOrObservable(this.nodeArrayOrObservableAtIndex[e]),this.nodeArrayOrObservableAtIndex.splice(e,1)}getSubscriptionsForNode(e){if(!this.subscriptionsForNode.has(e)){let r=[];return this.subscriptionsForNode.set(e,r),r}return this.subscriptionsForNode.get(e)}isJsx(e){return typeof e.elementName=="string"&&"children"in e&&"attributes"in e}anyToNode(e){if(en(e))return this.futureJsxNode(e);switch(typeof e){case"object":if(e instanceof Error)return this.createComment(e.toString());if(e===null)return this.createComment(String(e));if(e instanceof Node)return this.cloneJSXorMoveNode(e);if(Symbol.iterator in e)return e;break;case"function":return this.anyToNode(e());case"undefined":case"symbol":return this.createComment(String(e));case"string":return this.createTextNode(e);case"boolean":case"number":case"bigint":default:return this.createTextNode(String(e))}return this.isJsx(e)?this.jsxToNode(e):this.createComment(ai(e))}createComment(e){let r=document.createComment(e);return r[me]=!0,r}createTextNode(e){let r=document.createTextNode(e);return r[me]=!0,r}cloneJSXorMoveNode(e){return It in e?this.jsxToNode(e[It]):e}jsxToNode(e){let r=e.attributes.xmlns||Qr[e.elementName]||this.xmlns,n=document.createElementNS(r||Qr.html,e.elementName);return n[It]=e,T(e.attributes)&&this.getSubscriptionsForNode(n).push(e.attributes.subscribe(s=>{this.updateAttributes(n,d(s))})),this.updateAttributes(n,d(e.attributes)),this.addDisposable(new _e(e.children,n,null,r,this.noInitialBinding)),n}futureJsxNode(e){let r=S();e.then(r).catch(i=>r(i instanceof Error?i:Error(i)));let n=new _e(r,this.parentNode,null,this.xmlns,this.noInitialBinding);return this.addDisposable(n),n.insertBefore}updateAttributes(e,r){let n=this.getSubscriptionsForNode(e),i=new Set([...e.attributes].map(s=>s.name));for(let[s,o]of Object.entries(r||{}))i.delete(s),T(o)&&n.push(o.subscribe(u=>this.setNodeAttribute(e,s,o))),this.setNodeAttribute(e,s,o);for(let s of i)this.setNodeAttribute(e,s,void 0)}getNamespaceOfAttribute(e){let[r,...n]=e.split(":");return r==="xmlns"||n.length&&Qr[r]?Qr[r]:null}setNodeAttribute(e,r,n){let i=d(n);if(je.addValueToNode(e,r,n),i===void 0)e.removeAttributeNS(null,r);else if(en(n))Promise.resolve(n).then(s=>this.setNodeAttribute(e,r,s));else{let s=this.getNamespaceOfAttribute(r);e.setAttributeNS(s,r,String(i))}}lastNodeFor(e){let r=this.nodeArrayOrObservableAtIndex[e]||[],[n]=r.slice(-1),i=n instanceof _e?n.insertBefore:n||this.insertBefore;return i&&i.parentNode?i:null}removeAllPriorNodes(){let{nodeArrayOrObservableAtIndex:e}=this;for(;e.length;)this.removeNodeArrayOrObservable(e.pop())}removeNodeArrayOrObservable(e){for(let r of e){if(r instanceof _e){r.dispose();continue}let n=r;delete n[It],this.detachAndDispose(n);let i=this.subscriptionsForNode.get(n);i&&(i.forEach(s=>s.dispose()),this.subscriptionsForNode.delete(n))}}detachAndDispose(e){if(io(e))for(let r of e)this.detachAndDispose(r);else e.remove();ro(e)}},lr=_e;function Zn(t){if(T(t))return!0;let e=d(t);return e?e.elementName?!0:!(!Array.isArray(e)||!e.length||e[0]instanceof window.Node):!1}function ei(t){return t[It]}var Xu=Symbol("JSX Fragment");var Zu=0,cr=class extends Ze{constructor(e){super(e),this.originalChildNodes=le(v.childNodes(this.$element)),this.computed("computeApplyComponent")}cloneTemplateIntoElement(e,r,n){if(!r)throw new Error("Component '"+e+"' has no template");if(Zn(r))v.emptyNode(n),this.addDisposable(new lr(r,n,null,void 0,!0));else{let i=De(r);v.setDomNodeChildren(n,i)}}createViewModel(e,r,n,i){let s=e.createViewModel;return s?s.call(e,i,{element:r,templateNodes:n}):i}makeTemplateSlotNodes(e){return Object.assign({},...this.genSlotsByName(e))}*genSlotsByName(e){for(let r of e){if(r.nodeType!==1)continue;let n=r.getAttribute("slot");!n||(yield{[n]:r})}}computeApplyComponent(){let e=d(this.value),r,n;if(typeof e=="string"?r=e:(r=d(e.name),n=je.getNodeValues(this.$element)||d(e.params)),this.latestComponentName=r,!r)throw new Error("No component name specified");this.loadingOperationId=this.currentLoadingOperationId=++Zu,rt.get(r,i=>this.applyComponentDefinition(r,n,i))}makeChildBindingContext(e){let r=n=>Object.assign(n,{$component:e,$componentTemplateNodes:this.originalChildNodes,$componentTemplateSlotNodes:this.makeTemplateSlotNodes(this.originalChildNodes)});return this.$context.createChildContext(e,void 0,r)}applyComponentDefinition(e,r,n){if(this.currentLoadingOperationId!==this.loadingOperationId||this.latestComponentName!==e)return;this.cleanUpState();let i=this.$element;if(!n)throw new Error("Unknown component '"+e+"'");n.template&&this.cloneTemplateIntoElement(e,n.template,i);let s=this.createViewModel(n,i,this.originalChildNodes,r);this.childBindingContext=this.makeChildBindingContext(s);let o=s&&s.template;if(!o&&!n.template)throw new Error("Component '"+e+"' has no template");n.template||this.cloneTemplateIntoElement(e,o,i),s instanceof G&&s.anchorTo(this.$element),this.currentViewModel=s;let u=this.onBindingComplete.bind(this,s);this.applyBindingsToDescendants(this.childBindingContext,u)}onBindingComplete(e,r){e&&e.koDescendantsComplete&&e.koDescendantsComplete(this.$element),this.completeBinding(r)}cleanUpState(){let e=this.currentViewModel,r=e&&e.dispose;typeof r=="function"&&r.call(e),this.currentViewModel=null,this.currentLoadingOperationId=null}dispose(){this.cleanUpState(),super.dispose()}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};var dr=class extends Ze{constructor(...e){super(...e);let r=this.getSlot(this.value),n=Ne(r),i=this.$context.extend({$slotContext:n,$slotData:n&&n.$data});this.replaceSlotWithNode(this.$element,r),this.applyBindingsToDescendants(i)}replaceSlotWithNode(e,r){let n=this.cloneNodeFromOriginal(r);v.emptyNode(e),this.addDisposable(new lr(n,e,void 0,void 0,!0))}cloneNodeFromOriginal(e){if(!e)return[];let r=ei(e);return r?r.children:"content"in e?[...document.importNode(e.content,!0).childNodes]:(Array.isArray(e)?e:[e]).map(i=>i.cloneNode(!0))}getSlot(e){let{$componentTemplateSlotNodes:r}=this.$context;return e?r[e]:r[""]||[...this.$context.$componentTemplateNodes].filter(n=>!n.getAttribute||!n.getAttribute("slot"))}static get allowVirtualElements(){return!0}};var so={component:cr,slot:dr};var Kr=String.prototype,ke={};ke.uppercase=function(t){return Kr.toUpperCase.call(d(t))};ke.lowercase=function(t){return Kr.toLowerCase.call(d(t))};ke.default=function(t,e){return t=d(t),typeof t=="function"?t:typeof t=="string"?Kr.trim.call(t)===""?e:t:t==null||t.length==0?e:t};ke.replace=function(t,e,r){return Kr.replace.call(d(t),e,r)};ke.fit=function(t,e,r,n){if(t=d(t),e&&(""+t).length>e)switch(r=""+(r||"..."),e=e-r.length,t=""+t,n){case"left":return r+t.slice(-e);case"middle":var i=Math.ceil(e/2);return t.substr(0,i)+r+t.slice(i-e);default:return t.substr(0,e)+r}else return t};ke.json=function(t,e,r){return JSON.stringify(yt(t),r,e)};ke.number=function(t){return(+d(t)).toLocaleString()};var ea=/\bfunction\s*\(([^)]*)\)\s*\{\s*(?:(return\s)?([^}]+?)[;\s]*)?\}/g;function fr(t){return t.replace(ea,(e,r,n,i)=>{i&&!n&&(i+=" && undefined");let s=`(${r.trim()}) => ${i}`;return fr.silent||console.log(`Knockout: Replace "${e}" with "${s}"`),s})}var oo=new Nt,ta={preProcessBindings:t=>oo.preProcessBindings(t)},ra=new Zt({filters:ke,provider:new kt({providers:[new Tt,oo,new St,new _t]}),bindings:[Zs,Ns,eo,so,{each:to.foreach}],options:{bindingGlobals:c.global,bindingStringPreparsers:[fr]}}),na="4.0.0-beta1.6",ia=ra.create({version:na,components:rt,Component:rt.ComponentABC,expressionRewriting:ta});return ho(sa);})();
|
|
14
|
+
`),Qe[n]=e}function wr(n){return J(Qe,n)}function Fs(n){delete Qe[n],de.clearCachedDefinition(n)}var Br={getConfig(n,e){let t=J(Qe,n)?Qe[n]:null;e(t)},loadComponent(n,e,t){let r=xr(n);Fr(r,e,function(i){vu(n,r,i,t)})},loadTemplate(n,e,t){Fu(xr(n),e,t)},loadViewModel(n,e,t){ws(xr(n),e,t)}},vr="createViewModel";function vu(n,e,t,r){let i={},s=function(){--u===0&&r(i)},o=t.template,a=t.viewModel,u=2;o?Fr(e,o,function(l){de._getFirstResultFromLoaders("loadTemplate",[n,l],function(d){i.template=d,s()})}):s(),a?Fr(e,a,function(l){de._getFirstResultFromLoaders("loadViewModel",[n,l],function(d){i[vr]=d,s()})}):s()}function Fu(n,e,t){if(typeof e=="string")t(le(e));else if(e instanceof Array)t(e);else if(Jn(e))t(ue(e.childNodes));else if(e.element){let r=e.element;if(di(r))t(vs(r));else if(typeof r=="string"){let i=document.getElementById(r);i?t(vs(i)):n("Cannot find element with ID "+r)}else n("Unknown element type: "+r)}else e.elementName?t(e):n("Unknown template value: "+e)}function ws(n,e,t){if(e[Bn])t((...r)=>e[Bn](...r));else if(typeof e=="function")t(function(r){return new e(r)});else if(typeof e[vr]=="function")t(e[vr]);else if("instance"in e){let r=e.instance;t(function(){return r})}else"viewModel"in e?ws(n,e.viewModel,t):n("Unknown viewModel value: "+e)}function vs(n){switch(R(n)){case"script":return le(n.text);case"textarea":return le(n.value);case"template":if(Jn(n.content))return De(n.content.childNodes)}return De(n.childNodes)}function Fr(n,e,t){typeof e.require=="string"?window.amdRequire||window.require?(window.amdRequire||window.require)([e.require],t):n("Uses require, but no AMD loader is present"):t(e)}function xr(n){return function(e){throw new Error("Component '"+n+"': "+e)}}de.loaders.push(Br);var Sn=class extends X{static get customElementName(){return this.name.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}static get template(){if(!("template"in this.prototype))return{element:this.element}}static get element(){throw new Error("[ComponentABC] `element` must be overloaded.")}static get sync(){return!0}static[Bn](e,t){return new this(e,t)}static register(e=this.customElementName){let t=this,{template:r}=this,i=this.sync;Nn(e,{viewModel:t,template:r,synchronous:i})}};var Ke={ComponentABC:Sn,get:de.get,clearCachedDefinition:de.clearCachedDefinition,register:Nn,isRegistered:wr,unregister:Fs,defaultLoader:Br,_allRegisteredComponents:Qe,get loaders(){return de.loaders},set loaders(n){de.loaders=n}};var vt=class extends q{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE]}preprocessNode(e){if(e instanceof Element&&e.tagName==="SLOT"){let t=e.parentNode,r=e.getAttribute("name")||"",i=document.createComment(`ko slot: "${r}"`),s=document.createComment("/ko");if(!t)throw Error("Missing parent node");return t.insertBefore(i,e),t.insertBefore(s,e),t.removeChild(e),[i,s]}return null}nodeHasBindings(e){return!!this.getComponentNameForNode(e)}getBindingAccessors(e,t){let r=this.getComponentNameForNode(e);return r?{component:()=>({name:r,params:this.getComponentParams(e,t)})}:Object.create(null)}getComponentNameForNode(e){if(!(e instanceof Element)||e.nodeType!==Node.ELEMENT_NODE)return null;let t=R(e);if(Ke.isRegistered(t)){let r=t.includes("-"),i=""+e=="[object HTMLUnknownElement]";if(r||i)return t}return null}getComponentParams(e,t){if(!(e instanceof Element))return{$raw:{}};let r=new Te(e,t,this.globals),i=(e.getAttribute("params")||"").trim(),s=r.parse(i,t,void 0,e);if(!s||Object.keys(s).length===0)return{$raw:{}};let o=pe(s,u=>B(u,null,{disposeWhenNodeIsRemoved:e})),a=pe(o,u=>this.makeParamValue(e,u));return Object.assign({$raw:o},a)}makeParamValue(e,t){let r=t.peek();if(!t.isActive())return r;let i=Q(r);return B({read:()=>f(t()),write:i?s=>t()(s):void 0,disposeWhenNodeIsRemoved:e})}};var Ft=class extends q{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE]}get PREFIX(){return"ko-"}getBindingAttributesList(e){return e instanceof Element?e.hasAttributes()?Array.from(e.attributes).filter(t=>t.name.startsWith(this.PREFIX)):[]:[]}nodeHasBindings(e){return this.getBindingAttributesList(e).length>0}getBindingAccessors(e,t){return Object.assign({},...this.handlersFromAttributes(e,t))}*handlersFromAttributes(e,t){for(let r of this.getBindingAttributesList(e))yield{[r.name.substring(this.PREFIX.length)]:()=>this.getValue(r.value,t,e)}}getValue(e,t,r){if(!e)return;let i=t.$data;switch(e){case"$element":return r;case"$context":return t;case"this":case"$data":return t.$data}if(i instanceof Object&&e in i)return i[e];if(e in t)return t[e];if(e in this.globals)return this.globals[e];throw new Error(`The variable '${e} not found.`)}};var wt=class extends q{get FOR_NODE_TYPES(){return this.nodeTypes}constructor(e){super(e);let t=(e==null?void 0:e.providers)||[];this.nodeTypeMap={},this.nodeTypes=[],this.providers=[],t.forEach(r=>this.addProvider(r))}setGlobals(e){[this,...this.providers].forEach(t=>t.globals=e)}addProvider(e){this.providers.push(e),e.bindingHandlers=this.bindingHandlers,e.globals=this.globals;let t=this.nodeTypeMap;for(let r of e.FOR_NODE_TYPES)t[r]||(t[r]=new Array),t[r].push(e);this.nodeTypes=Object.keys(this.nodeTypeMap).map(r=>parseInt(r,10))}providersFor(e){return this.nodeTypeMap[e.nodeType]||[]}nodeHasBindings(e,t){return this.providersFor(e).some(r=>r.nodeHasBindings(e))}preprocessNode(e){for(let t of this.providersFor(e)){let r=t.preprocessNode(e);if(r)return r}return null}*enumerateProviderBindings(e,t){for(let r of this.providersFor(e)){let i=r.getBindingAccessors(e,t);if(i&&(yield*ke(Object.entries(i||{})),r.preemptive))return}}getBindingAccessors(e,t){let r={};for(let[i,s]of this.enumerateProviderBindings(e,t)){if(i in r)throw new Error(`The binding "${i}" is duplicated by multiple providers`);r[i]=s}return r}};var Bs={update:function(n,e,t){let r=f(e())||{};V(r,function(i,s){s=f(s);let o=i.indexOf(":"),a=o>0&&n.lookupNamespaceURI(i.substr(0,o)),u=s===!1||s===null||s===void 0;u?a?n.removeAttributeNS(a,i):n.removeAttribute(i):(s=s.toString(),a?n.setAttributeNS(a,i,s):n.setAttribute(i,s)),i==="name"&&(n.name=u?"":s)})}};var Ns={after:["value","attr"],init:function(n,e,t){let r=xe(function(){if(t.has("checkedValue"))return f(t.get("checkedValue"));if(p)return t.has("value")?f(t.get("value")):n.value});function i(){let m=n.checked,A=r();if(x.isInitial()||!m&&(a||x.getDependenciesCount()))return;let v=x.ignore(e);if(l){let h=d?v.peek():v,T=b;b=A,T!==A?(m&&(we(h,A,!0),we(h,T,!1)),b=A):we(h,A,m),d&&Q(v)&&v(h)}else{o&&(A===void 0?A=m:m||(A=void 0));let h=e(A,{onlyIfChanged:!0});Q(h)&&h.peek()!==A&&h(A)}}function s(){let m=f(e()),A=r();l?(n.checked=j(m,A)>=0,b=A):o&&A===void 0?n.checked=!!m:n.checked=r()===m}let o=n.type=="checkbox",a=n.type=="radio";if(!o&&!a)return;let u=e(),l=o&&f(u)instanceof Array,d=!(l&&u.push&&u.splice),p=a||l,b=l?r():void 0;B(i,null,{disposeWhenNodeIsRemoved:n}),K(n,"click",i),B(s,null,{disposeWhenNodeIsRemoved:n}),u=void 0}},Ss={update:function(n,e){n.value=f(e())}};function _s(n){return{init:function(e,t,r,i,s){let o=function(){let a={};return a[n]=t(),a};Tn.init.call(this,e,o,r,i,s)}}}function Ts(n){return typeof n=="function"?{handler:n}:n||{}}var Tn={init:function(n,e,t,r,i){let s=e()||{};V(s,function(o,a){let{passive:u,capture:l,once:d,debounce:p,throttle:b}=Ts(a),m=(l||u||d)&&{capture:l,passive:u,once:d},A=(v,...h)=>{let T,{handler:k,passive:g,bubble:N,preventDefault:C}=Ts(e()[o]);try{if(k){let M=i.$data,H=[M,v,...h];T=k.apply(M,H)}}finally{C!==void 0?f(C)&&v.preventDefault():T!==!0&&(g||v.preventDefault())}let _=t.get(o+"Bubble")!==!1;(N===!1||!_)&&(v.cancelBubble=!0,v.stopPropagation&&v.stopPropagation())};p&&(A=on(A,p)),b&&(A=sn(A,b)),K(n,o,A,m||!1)})}},Os={init:Tn.init,preprocess:function(n,e,t){t(e.replace("on.",""),"=>"+n)}};var Is=_s("click");var qt={aliases:["class"],update:function(n,e){let t=f(e());t!==null&&typeof t=="object"?V(t,function(r,i){i=f(i),nt(n,r,i)}):(t=_t(String(t||"")),nt(n,n[qt.classesWrittenByBindingKey],!1),n[qt.classesWrittenByBindingKey]=t,nt(n,t,!0))},classesWrittenByBindingKey:z("__ko__cssValue")};var Jt=class extends Z{onDescendantsComplete(){typeof this.value=="function"&&this.value(this.$element)}static get allowVirtualElements(){return!0}};var Nr={update:function(n,e){let t=f(e());t&&n.disabled?n.removeAttribute("disabled"):!t&&!n.disabled&&(n.disabled=!0)}},ks={update:function(n,e){Nr.update(n,function(){return!f(e())})}};var Sr=z("__ko_hasfocusUpdating"),Tr=z("__ko_hasfocusLastValue"),_r={init:function(n,e,t){let r=function(o){n[Sr]=!0;let a=n.ownerDocument;if("activeElement"in a){let l;try{l=a.activeElement}catch(d){l=a.body}o=l===n}let u=e(o,{onlyIfChanged:!0});Q(u)&&u.peek()!==o&&u(o),n[Tr]=o,n[Sr]=!1},i=r.bind(null,!0),s=r.bind(null,!1);K(n,"focus",i),K(n,"focusin",i),K(n,"blur",s),K(n,"focusout",s)},update:function(n,e){let t=!!f(e());!n[Sr]&&n[Tr]!==t&&(t?n.focus():n.blur(),!t&&n[Tr]&&n.ownerDocument.body.focus(),x.ignore(Pe,null,[n,t?"focusin":"focusout"]))}};var Ms={init:function(){return{controlsDescendantBindings:!0}},update:function(n,e){st(n,e())},allowVirtualElements:!0};var Ps={init:function(n,e,t,r,i){let s=i.extend(e);return se(s,n),{controlsDescendantBindings:!0}},allowVirtualElements:!0};var Or={},Vs={init:function(n){if(R(n)!=="select")throw new Error("options binding applies only to SELECT elements");for(;n.length>0;)n.remove(0);return{controlsDescendantBindings:!0}},update:function(n,e,t){function r(){return Me(n.options,function(g){return g.selected})}let i=n.length==0,s=n.multiple,o=!i&&s?n.scrollTop:null,a=f(e()),u=t.get("valueAllowUnset")&&t.has("value"),l=t.get("optionsIncludeDestroyed"),d={},p,b,m=new Array;u||(s?m=Xe(r(),O.readValue):n.selectedIndex>=0&&m.push(O.readValue(n.options[n.selectedIndex]))),a&&(typeof a.length=="undefined"&&(a=[a]),b=Me(a,function(g){return l||g===void 0||g===null||!f(g._destroy)}),t.has("optionsCaption")&&(p=f(t.get("optionsCaption")),p!=null&&b.unshift(Or)));function A(g,N,C){let _=typeof N;return _==="function"?N(g):_=="string"?g[N]:C}let v=!1;function h(g,N,C){C.length&&(m=!u&&C[0].selected?[O.readValue(C[0])]:[],v=!0);let _=n.ownerDocument.createElement("option");if(g===Or)Le(_,t.get("optionsCaption")),O.writeValue(_,void 0);else{let M=A(g,t.get("optionsValue"),g);O.writeValue(_,f(M));let H=A(g,t.get("optionsText"),M);Le(_,H)}return[_]}d.beforeRemove=function(g){n.removeChild(g)};function T(g,N){if(v&&u)O.writeValue(n,f(t.get("value")),!0);else if(m.length){let C=j(m,O.readValue(N[0]))>=0;cn(N[0],C),v&&!C&&x.ignore(Pe,null,[n,"change"])}}let k=T;t.has("optionsAfterRender")&&typeof t.get("optionsAfterRender")=="function"&&(k=function(g,N){T(g,N),x.ignore(t.get("optionsAfterRender"),null,[N[0],g!==Or?g:void 0])}),yt(n,b,h,d,k),x.ignore(function(){if(u)O.writeValue(n,f(t.get("value")),!0);else{let g;s?g=m.length&&r().length<m.length:g=m.length&&n.selectedIndex>=0?O.readValue(n.options[n.selectedIndex])!==m[0]:m.length||n.selectedIndex>=0,g&&Pe(n,"change")}}),o&&Math.abs(o-n.scrollTop)>20&&(n.scrollTop=o)}};var Rs={after:["options","foreach"],init:function(n,e,t){K(n,"change",function(){let r=e(),i=new Array;P(n.getElementsByTagName("option"),function(s){s.selected&&i.push(O.readValue(s))}),e(i)})},update:function(n,e){if(R(n)!="select")throw new Error("values binding applies only to SELECT elements");let t=f(e()),r=n.scrollTop;t&&typeof t.length=="number"&&P(n.getElementsByTagName("option"),function(i){let s=j(t,O.readValue(i))>=0;i.selected!=s&&cn(i,s)}),n.scrollTop=r}};var Ls={update:function(n,e){let t=f(e()||{});V(t,function(r,i){if(i=f(i),(i==null||i===!1)&&(i=""),c.jQuery)jQuery(n).css(r,i);else{r=r.replace(/-(\w)/g,(o,a)=>a.toUpperCase());let s=n.style[r];n.style[r]=i,i!==s&&n.style[r]===s&&!isNaN(i)&&(n.style[r]=i+"px")}})}};var $s={init:function(n,e,t,r,i){if(typeof e()!="function")throw new Error("The value for a submit binding must be a function");K(n,"submit",function(s){let o,a=e();try{o=a.call(i.$data,n)}finally{o!==!0&&(s.preventDefault?s.preventDefault():s.returnValue=!1)}})}};var Hs={init:function(){return{controlsDescendantBindings:!0}},update:function(n,e){Le(n,e())},allowVirtualElements:!0};var Hr=/MSIE ([^ ;]+)|rv:([^ )]+)/,Ir,kr,Mr,Pr,qe=class extends Z{get aliases(){return"textinput"}constructor(...e){super(...e),this.previousElementValue=this.$element.value,c.debug&&this.constructor._forceUpdateOn&&P(this.constructor._forceUpdateOn,t=>{t.slice(0,5)==="after"?this.addEventListener(t.slice(5),"deferUpdateModel"):this.addEventListener(t,"updateModel")});for(let t of this.eventsIndicatingSyncValueChange())this.addEventListener(t,"updateModel");for(let t of this.eventsIndicatingDeferValueChange())this.addEventListener(t,"deferUpdateModel");this.computed("updateView")}eventsIndicatingSyncValueChange(){return["input","change","blur"]}eventsIndicatingDeferValueChange(){return[]}updateModel(e){let t=this.$element;clearTimeout(this.timeoutHandle),this.elementValueBeforeEvent=this.timeoutHandle=void 0;let r=t.value;this.previousElementValue!==r&&(c.debug&&e&&(t._ko_textInputProcessedEvent=e.type),this.previousElementValue=r,this.value=r)}deferUpdateModel(e){let t=this.$element;if(!this.timeoutHandle){this.elementValueBeforeEvent=t.value;let r=c.debug?this.updateModel.bind(this,{type:e.type}):this.updateModel;this.timeoutHandle=ae(r,4)}}updateView(){let e=f(this.value);e==null&&(e=""),this.elementValueBeforeEvent!==void 0&&e===this.elementValueBeforeEvent?setTimeout(this.updateView.bind(this),4):this.$element.value!==e&&(this.previousElementValue=e,this.$element.value=e,this.previousElementValue=this.$element.value)}},Vr=class extends qe{eventsIndicatingSyncValueChange(){return[...super.eventsIndicatingSyncValueChange(),"keypress"]}},Rr=class extends qe{eventsIndicatingDeferValueChange(){return["keydown","paste","cut"]}},Lr=class extends qe{eventsIndicatingDeferValueChange(){return["keydown"]}},$r=class extends qe{eventsIndicatingValueChange(){return[...super.eventsIndicatingSyncValueChange(),"DOMAutoComplete","dragdrop","drop"]}},zt=c.global;if(zt.navigator){let n=r=>r&&parseFloat(r[1]),e=zt.navigator.userAgent;if(!e.match(/Chrome\/([^ ]+)/)){Ir=zt.opera&&zt.opera.version&&parseInt(zt.opera.version()),kr=n(e.match(/Version\/([^ ]+) Safari/)),Mr=n(e.match(/Firefox\/([^ ]*)/));let r=e.match(Hr);Pr=r&&(parseFloat(r[1])||parseFloat(r[2]))}}var jr=Pr&&Pr<=11?Vr:kr&&kr<5?Rr:Ir&&Ir<11?Lr:Mr&&Mr<4?$r:qe;var Wr={init:function(n,e){if(e()){let t="ko_unique_"+ ++Wr.currentIndex;n.name=t}},currentIndex:0};var _n=class extends Z{static get after(){return["options","foreach","template"]}constructor(...e){if(super(...e),this.isCheckboxOrRadio){Ut(this.$element,{checkedValue:this.valueAccessor});return}this.propertyChangedFired=!1,this.elementValueBeforeEvent=null,this.ieAutoCompleteHackNeeded&&(this.addEventListener("propertyChange",()=>this.propertyChangedFired=!0),this.addEventListener("focus",()=>this.propertyChangedFired=!1),this.addEventListener("blur",()=>this.propertyChangeFired&&this.valueUpdateHandler())),P(this.eventsToCatch,t=>this.registerEvent(t)),this.isInput&&this.$element.type==="file"?this.updateFromModel=this.updateFromModelForFile:this.updateFromModel=this.updateFromModelForValue,this.computed("updateFromModel")}get eventsToCatch(){let e=this.allBindings.get("valueUpdate"),t=typeof e=="string"?[e]:e||[];return[...new Set(["change",...t])]}get isInput(){return R(this.$element)==="input"}get isCheckboxOrRadio(){let e=this.$element;return this.isInput&&(e.type=="checkbox"||e.type=="radio")}get ieAutoCompleteHackNeeded(){return this.isInput&&this.$element.type=="text"&&this.$element.autocomplete!="off"&&(!this.$element.form||this.$element.form.autocomplete!="off")&&Hr.test(window.navigator.userAgent)}valueUpdateHandler(){this.elementValueBeforeEvent=null,this.propertyChangedFired=!1,this.value=O.readValue(this.$element)}registerEvent(e){let t=this.valueUpdateHandler.bind(this);ui(e,"after")&&(t=()=>{this.elementValueBeforeEvent=O.readValue(this.$element),ae(this.valueUpdateHandler.bind(this),0)},e=e.substring(5)),this.addEventListener(e,t)}updateFromModelForFile(){let e=f(this.value);e==null||e===""?this.$element.value="":x.ignore(this.valueUpdateHandler,this)}updateFromModelForValue(){let e=this.$element,t=f(this.value),r=O.readValue(e);if(this.elementValueBeforeEvent!==null&&t===this.elementValueBeforeEvent){ae(this.updateFromModel.bind(this),0);return}if(!(t===r&&r!==void 0))if(R(e)==="select"){let i=this.allBindings.get("valueAllowUnset");O.writeValue(e,t,i),!i&&t!==O.readValue(e)&&x.ignore(this.valueUpdateHandler,this)}else O.writeValue(e,t)}};var Ur={update:function(n,e){let t=f(e()),r=n.style.display!=="none";t&&!r?n.style.display="":!t&&r&&(n.style.display="none")}},js={update:function(n,e){Ur.update.call(this,n,()=>!f(e()))}};var Ws={init:function(n,e,t,r,i){let s=i.createChildContext(e);return se(s,n),{controlsDescendantBindings:!0}},allowVirtualElements:!0};var Us={attr:Bs,checked:Ns,checkedValue:Ss,click:Is,css:qt,class:qt,descendantsComplete:Jt,enable:Nr,event:Tn,disable:ks,hasfocus:_r,hasFocus:_r,hidden:js,html:Ms,let:Ps,on:Os,options:Vs,selectedOptions:Rs,style:Ls,submit:$s,text:Hs,textInput:jr,textinput:jr,uniqueName:Wr,using:Ws,value:_n,visible:Ur};var Je=class extends ee{get bindingContext(){throw new Error("bindingContext() must be implemented in the child class")}constructor(e){super(e),this.hasElse=this.detectElse(this.$element);let t=this.completesElseChain=w();D.set(this.$element,"conditional",{elseChainSatisfied:t})}getIfElseNodes(){if(this.ifElseNodes)return this.ifElseNodes;if(x.getDependenciesCount()||this.hasElse)return this.cloneIfElseNodes(this.$element,this.hasElse)}renderStatus(){throw new Error("renderStatus() must be implemented in the child class")}render(){let e=!this.ifElseNodes,{shouldDisplay:t}=this.renderStatus();if(this.ifElseNodes=this.getIfElseNodes()||{},t){let r=e&&!this.hasElse;this.renderAndApplyBindings(this.ifElseNodes.ifNodes,r)}else this.hasElse?this.renderAndApplyBindings(this.ifElseNodes.elseNodes):y.emptyNode(this.$element)}renderAndApplyBindings(e,t){return Ye(this,null,function*(){t||y.setDomNodeChildren(this.$element,De(e));let r=yield se(this.bindingContext,this.$element);this.completeBinding(r)})}get elseChainIsAlreadySatisfied(){return!1}isElseNode(e){return e.nodeType===Node.COMMENT_NODE&&e.nodeValue.trim().toLowerCase()==="else"}detectElse(e){let t=y.childNodes(e);for(let r=0,i=t.length;r<i;++r)if(this.isElseNode(t[r]))return!0;return!1}cloneIfElseNodes(e,t){let r=y.childNodes(e),i=new Array,s=new Array,o=i;for(let a=0,u=r.length;a<u;++a)t&&this.isElseNode(r[a])?(o=s,t=!1):o.push(G(r[a].cloneNode(!0)));return{ifNodes:i,elseNodes:s}}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};var ze=class extends Je{constructor(...e){super(...e),this.ifCondition=this.computed(()=>!!f(this.value)),this.computed("render")}shouldDisplayIf(){return this.ifCondition()}get bindingContext(){return this.ifCondition.isActive()?this.$context.extend(()=>(this.ifCondition(),null)):this.$context}renderStatus(){let e=this.shouldDisplayIf();return this.elseChainIsAlreadySatisfied?(e=!1,this.completesElseChain(!0)):this.completesElseChain(e),{shouldDisplay:e}}},Gt=class extends ze{shouldDisplayIf(){return!super.shouldDisplayIf()}};var On=class extends Je{constructor(...e){super(...e),this.asOption=this.allBindings.get("as");let t=this.asOption&&!c.createChildContextWithAs?()=>!!f(this.value):()=>f(this.value);this.conditional=this.computed(t),this.computed("render")}get bindingContext(){return this.asOption?c.createChildContextWithAs?this.$context.createChildContext(this.value,this.asOption):this.$context.extend({[this.asOption]:this.value}):this.$context.createChildContext(this.valueAccessor)}renderStatus(){return{shouldDisplay:!!this.conditional()}}};var Yt=class extends ze{shouldDisplayIf(){return super.shouldDisplayIf()||this.value===void 0}get elseChainIsAlreadySatisfied(){return this._elseChain||(this._elseChain=this.readElseChain()),f(this._elseChain.elseChainSatisfied)}readElseChain(){let e=this.$element;do e=e.previousSibling;while(e&&e.nodeType!==Node.ELEMENT_NODE&&e.nodeType!==Node.COMMENT_NODE);return e?(e.nodeType===Node.COMMENT_NODE&&(e=y.previousSibling(e)),D.get(e,"conditional")||{}):!1}};var Qs={if:ze,with:On,ifnot:Gt,unless:Gt,else:Yt,elseif:Yt};var wu=9007199254740991;function Bu(n){return!!n&&typeof n=="object"&&n.constructor===Object}var Nu=c.document&&typeof c.document.createDocumentFragment=="function";function Su(n){let e=document.createElement("div"),t;return n.content?t=n.content:n.tagName==="SCRIPT"?(t=document.createElement("div"),t.innerHTML=n.text):t=n,P(y.childNodes(t),function(r){r&&e.insertBefore(r.cloneNode(!0),null)}),e}function Tu(n,e){return{status:"added",value:n,index:e}}var Xt=z("_ko_ffe_pending_delete_index"),Zt=class n extends ee{constructor(e){var i;super(e);let t={};Bu(this.value)&&Object.assign(t,this.value),this.as=t.as||this.allBindings.get("as"),this.data=t.data||(f(this.$context.$rawData)===this.value?this.$context.$rawData:this.value),this.container=y.isStartComment(this.$element)?this.$element.parentNode:this.$element,this.generateContext=this.createContextGenerator(this.as),this.$indexHasBeenRequested=!1,this.templateNode=Su(t.templateNode||(t.name?(i=document.getElementById(t.name))==null?void 0:i.cloneNode(!0):this.$element)),["afterAdd","beforeRemove","afterQueueFlush","beforeQueueFlush"].forEach(s=>{this[s]=t[s]||this.allBindings.get(s)}),this.changeQueue=new Array,this.firstLastNodesList=new Array,this.indexesToDelete=new Array,this.rendering_queued=!1,this.pendingDeletes=new Array,this.isNotEmpty=w(!!f(this.data).length),D.set(this.$element,"conditional",{elseChainSatisfied:this.isNotEmpty}),y.emptyNode(this.$element);let r=f(this.data);r&&r.map?this.onArrayChange(r.map(Tu),!0):this.completeBinding(),S(this.data)&&(this.data.indexOf||(this.data=this.data.extend({trackArrayChanges:!0})),this.changeSubs=this.data.subscribe(this.onArrayChange,this,"arrayChange"))}dispose(){this.changeSubs&&this.changeSubs.dispose(),this.flushPendingDeletes()}onArrayChange(e,t){let r={added:[],deleted:[]};for(let i=0,s=e.length;i<s;i++){if(r.added.length&&e[i].status==="added"){let o=r.added[r.added.length-1];if((o.isBatch?o.index+o.values.length-1:o.index)+1===e[i].index){o.isBatch||(o={isBatch:!0,status:"added",index:o.index,values:[o.value]},r.added.splice(r.added.length-1,1,o)),o.values.push(e[i].value);continue}}r[e[i].status].push(e[i])}r.deleted.length>0&&(this.changeQueue.push.apply(this.changeQueue,r.deleted),this.changeQueue.push({status:"clearDeletedIndexes"})),this.changeQueue.push.apply(this.changeQueue,r.added),this.changeQueue.length>0&&!this.rendering_queued&&(this.rendering_queued=!0,t?this.processQueue():n.animateFrame.call(window,()=>this.processQueue()))}startQueueFlush(){typeof this.beforeQueueFlush=="function"&&this.beforeQueueFlush(this.changeQueue)}endQueueFlush(){typeof this.afterQueueFlush=="function"&&this.afterQueueFlush(this.changeQueue)}processQueue(){let e=!f(this.data).length,t=wu;this.startQueueFlush(),P(this.changeQueue,r=>{typeof r.index=="number"&&(t=Math.min(t,r.index)),this[r.status](r)}),this.flushPendingDeletes(),this.rendering_queued=!1,this.$indexHasBeenRequested&&this.updateIndexes(t),this.endQueueFlush(),this.changeQueue=new Array,e!==!this.isNotEmpty()&&this.isNotEmpty(!e)}_first$indexRequest(e){this.$indexHasBeenRequested=!0;for(let t=0,r=this.firstLastNodesList.length;t<r;++t){let i=this.getContextStartingFrom(this.firstLastNodesList[t].first);i&&(i.$index=w(t))}return e.$index()}_contextExtensions(e){return Object.assign(e,{$list:this.data}),this.$indexHasBeenRequested?e.$index=e.$index||w():Object.defineProperty(e,"$index",{value:()=>this._first$indexRequest(e),configurable:!0,writable:!0}),e}createContextGenerator(e){let t=this.$context;return e?r=>this._contextExtensions(t.extend({[e]:r})):r=>t.createChildContext(r,void 0,i=>this._contextExtensions(i))}updateFirstLastNodesList(e,t){let r=t[0],i=t[t.length-1];this.firstLastNodesList.splice(e,0,{first:r,last:i})}added(e){let t=e.index,r=e.isBatch?e.values:[e.value],i=this.getLastNodeBeforeIndex(t),s=[],o=new Array,a;for(let u=0,l=r.length;u<l;++u){let d=this.getPendingDeleteFor(r[u]);if(d&&d.nodesets.length)a=d.nodesets.pop(),this.updateFirstLastNodesList(t+u,a);else{let p=this.templateNode.cloneNode(!0);a=y.childNodes(p),this.updateFirstLastNodesList(t+u,a);let b=se(this.generateContext(r[u]),p);o.push(b)}s.push(...a)}typeof this.afterAdd=="function"?this.afterAdd({nodeOrArrayInserted:this.insertAllAfter(s,i),foreachInstance:this}):this.insertAllAfter(s,i),this.completeBinding(Promise.all(o))}getNodesForIndex(e){let t=new Array,r=this.firstLastNodesList[e].first,i=this.firstLastNodesList[e].last;for(t.push(r);r&&r!==i;)r=r.nextSibling,t.push(r);return t}getLastNodeBeforeIndex(e){return e<1||e-1>=this.firstLastNodesList.length?null:this.firstLastNodesList[e-1].last}activeChildElement(e){let t=document.activeElement;return qn(t,e)?t:null}insertAllAfter(e,t){let r,i,s,o=null,a=this.$element;if(e.nodeType===void 0&&e.length===void 0)throw new Error("Expected a single node or a node array");if(e.nodeType!==void 0)return o=this.activeChildElement(e),y.insertAfter(a,e,t),[e];if(e.length===1)o=this.activeChildElement(e[0]),y.insertAfter(a,e[0],t);else if(Nu){for(r=document.createDocumentFragment(),s=0,i=e.length;s!==i;++s)o=o||this.activeChildElement(e[s]),r.appendChild(e[s]);y.insertAfter(a,r,t)}else for(s=e.length-1;s>=0;--s){o=o||this.activeChildElement(e[s]);let u=e[s];if(!u)break;y.insertAfter(a,u,t)}return o&&o.focus(),e}shouldDelayDeletion(e){return e&&(typeof e=="object"||typeof e=="function")}getPendingDeleteFor(e){let t=e&&e[Xt];return t===void 0?null:this.pendingDeletes[t]}getOrCreatePendingDeleteFor(e){let t=this.getPendingDeleteFor(e);return t||(t={data:e,nodesets:[]},e[Xt]=this.pendingDeletes.length,this.pendingDeletes.push(t),t)}deleted(e){this.shouldDelayDeletion(e.value)?this.getOrCreatePendingDeleteFor(e.value).nodesets.push(this.getNodesForIndex(e.index)):this.removeNodes(this.getNodesForIndex(e.index)),this.indexesToDelete.push(e.index)}removeNodes(e){if(!e.length)return;function t(){let r=e[0].parentNode;for(let i=e.length-1;i>=0;--i)G(e[i]),r.removeChild(e[i])}if(this.beforeRemove){let r=this.beforeRemove({nodesToRemove:e,foreachInstance:this})||{};typeof r.then=="function"&&r.then(t,c.onError)}else t()}flushPendingDeletes(){for(let e=0,t=this.pendingDeletes.length;e!==t;++e){let r=this.pendingDeletes[e];for(;r.nodesets.length;)this.removeNodes(r.nodesets.pop());r.data&&r.data[Xt]!==void 0&&delete r.data[Xt]}this.pendingDeletes=new Array}clearDeletedIndexes(){for(let e=this.indexesToDelete.length-1;e>=0;--e)this.firstLastNodesList.splice(this.indexesToDelete[e],1);this.indexesToDelete=new Array}updateIndexes(e){let t;for(let r=e,i=this.firstLastNodesList.length;r<i;++r)t=this.getContextStartingFrom(this.firstLastNodesList[r].first),t&&t.$index(r)}getContextStartingFrom(e){let t;for(;e;){if(t=Fe(e),t)return t;e=e.nextSibling}}static setSync(e){let t=c.global;e?n.animateFrame=function(r){r()}:n.animateFrame=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.msRequestAnimationFrame||function(r){return t.setTimeout(r,1e3/60)}}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}static get ForEach(){return this}static get PENDING_DELETE_INDEX_SYM(){return Xt}};var Ks={foreach:Zt};Zt.setSync(!1);var fe=Symbol("Knockout native bindings"),Ie=class extends q{get FOR_NODE_TYPES(){return[Node.ELEMENT_NODE,Node.TEXT_NODE]}get preemptive(){return!0}nodeHasBindings(e,t){return e[fe]?Object.keys(e[fe]||{}).some(r=>r.startsWith("ko-")):!1}preprocessNode(e){return e[fe]?[e]:null}onlyBindings([e]){return e.startsWith("ko-")}valueAsAccessor([e,t]){let r=e.replace(/^ko-/,""),i=S(t)?t:()=>t;return{[r]:i}}getBindingAccessors(e,t){let r=Object.entries(e[fe]||{}).filter(this.onlyBindings);return r.length?Object.assign({},...r.map(this.valueAsAccessor)):null}static addValueToNode(e,t,r){let i=e[fe]||(e[fe]={});i[t]=r}static getNodeValues(e){return e[fe]}};var _u=25,Ou=1e3,Kr=new Array,Qr=null;function qs(n){Kr.push(n),Js()}function Js(){!Qr&&Kr.length&&(Qr=setTimeout(Iu,_u))}function Iu(){Qr=null;let n=Kr.splice(0,Ou);for(let e of n)G(e);Js()}var Bt=Symbol("Knockout - Original JSX"),In={svg:"http://www.w3.org/2000/svg",html:"http://www.w3.org/1999/xhtml",xml:"http://www.w3.org/XML/1998/namespace",xlink:"http://www.w3.org/1999/xlink",xmlns:"http://www.w3.org/2000/xmlns/"};function zs(n){return n&&typeof n[Symbol.iterator]=="function"}var qr=class n extends X{constructor(e,t,r=null,i,s){super();let o=t.nodeType===Node.COMMENT_NODE,a=this.getParentTarget(t);if(S(e))if(e.extend({trackArrayChanges:!0}),this.subscribe(e,this.observableArrayChange,"arrayChange"),r)this.adoptedInsertBefore=!0;else{let d=o?t.nextSibling:null;r=this.createComment("O"),a==null||a.insertBefore(r,d)}o&&!r&&(r=t.nextSibling,this.adoptedInsertBefore=!0),this.anchorTo(r||t),Object.assign(this,{insertBefore:r,noInitialBinding:s,parentNode:t,parentNodeTarget:a,xmlns:i,nodeArrayOrObservableAtIndex:[],subscriptionsForNode:new Map});let u=f(e);(mt(e)||u!=null)&&this.observableArrayChange(this.createInitialAdditions(u)),this.noInitialBinding=!1}getParentTarget(e){return"content"in e?e.content:e.nodeType===Node.COMMENT_NODE?e.parentNode:e}remove(){this.dispose()}dispose(){var r;super.dispose();let e=this.insertBefore;e&&this.parentNodeTarget===e.parentNode&&!this.adoptedInsertBefore&&((r=this.parentNodeTarget)==null||r.removeChild(e)),this.removeAllPriorNodes(),Object.assign(this,{parentNode:null,parentNodeTarget:null,insertBefore:null,nodeArrayOrObservableAtIndex:[]});for(let i of this.subscriptionsForNode.values())i.forEach(s=>s.dispose());this.subscriptionsForNode.clear()}createInitialAdditions(e){let t="added";return typeof e=="object"&&e!==null&&Symbol.iterator in e&&(e=[...e]),Array.isArray(e)?e.map((r,i)=>({index:i,status:t,value:r})):[{status:t,index:0,value:e}]}observableArrayChange(e){let t=[],r=[];for(let i in e){let s=e[i];s.status==="added"?t.push([s.index,s.value]):r.unshift([s.index,s.value])}r.forEach(i=>this.delChange(...i)),t.forEach(i=>this.addChange(...i))}addChange(e,t){this.nodeArrayOrObservableAtIndex.splice(e,0,this.injectNode(t,this.lastNodeFor(e)))}injectNode(e,t){var i;let r;if(S(e)){let{parentNode:s,xmlns:o}=this;r=[new n(e,s,t,o,this.noInitialBinding)]}else if(typeof e!="string"&&zs(e)){r=new Array;for(let s of e)r.unshift(this.injectNode(s,t))}else{let s=Fe(this.parentNode),o="content"in this.parentNode,a=s&&!o&&!this.noInitialBinding;Array.isArray(e)?r=e.map(u=>this.anyToNode(u)):r=[this.anyToNode(e)];for(let u of r)(i=this.parentNodeTarget)==null||i.insertBefore(u,t),a&&this.canApplyBindings(u)&&Et(s,u)}return r}canApplyBindings(e){return e.nodeType===Node.ELEMENT_NODE||e.nodeType===Node.COMMENT_NODE}delChange(e,t){this.removeNodeArrayOrObservable(this.nodeArrayOrObservableAtIndex[e]),this.nodeArrayOrObservableAtIndex.splice(e,1)}getSubscriptionsForNode(e){if(!this.subscriptionsForNode.has(e)){let t=new Array;return this.subscriptionsForNode.set(e,t),t}return this.subscriptionsForNode.get(e)}isJsx(e){return typeof e.elementName=="string"&&"children"in e&&"attributes"in e}anyToNode(e){if(Qn(e))return this.futureJsxNode(e);switch(typeof e){case"object":if(e instanceof Error)return this.createComment(e.toString());if(e===null)return this.createComment(String(e));if(e instanceof Node)return this.cloneJSXorMoveNode(e);if(Symbol.iterator in e)return e;break;case"function":return this.anyToNode(e());case"undefined":case"symbol":return this.createComment(String(e));case"string":return this.createTextNode(e);default:return this.createTextNode(String(e))}return this.isJsx(e)?this.jsxToNode(e):this.createComment(oi(e))}createComment(e){let t=document.createComment(e);return t[fe]=!0,t}createTextNode(e){let t=document.createTextNode(e);return t[fe]=!0,t}cloneJSXorMoveNode(e){return Bt in e?this.jsxToNode(e[Bt]):e}jsxToNode(e){let t=e.attributes.xmlns||In[e.elementName]||this.xmlns,r=document.createElementNS(t||In.html,e.elementName);return r[Bt]=e,S(e.attributes)&&this.getSubscriptionsForNode(r).push(e.attributes.subscribe(s=>{this.updateAttributes(r,f(s))})),this.updateAttributes(r,f(e.attributes)),this.addDisposable(new n(e.children,r,null,t,this.noInitialBinding)),r}futureJsxNode(e){let t=w();e.then(t).catch(i=>t(i instanceof Error?i:Error(i)));let r=new n(t,this.parentNode,null,this.xmlns,this.noInitialBinding);return this.addDisposable(r),r.insertBefore}updateAttributes(e,t){let r=this.getSubscriptionsForNode(e),i=new Set([...e.attributes].map(s=>s.name));for(let[s,o]of Object.entries(t||{}))i.delete(s),S(o)&&r.push(o.subscribe(a=>this.setNodeAttribute(e,s,o))),this.setNodeAttribute(e,s,o);for(let s of i)this.setNodeAttribute(e,s,void 0)}getNamespaceOfAttribute(e){let[t,...r]=e.split(":");return t==="xmlns"||r.length&&In[t]?In[t]:null}setNodeAttribute(e,t,r){let i=f(r);if(Ie.addValueToNode(e,t,r),i===void 0)e.removeAttributeNS(null,t);else if(Qn(r))Promise.resolve(r).then(s=>this.setNodeAttribute(e,t,s));else{let s=this.getNamespaceOfAttribute(t);e.setAttributeNS(s,t,String(i))}}lastNodeFor(e){let t=this.nodeArrayOrObservableAtIndex[e]||[],[r]=t.slice(-1),i=r instanceof n?r.insertBefore:r||this.insertBefore;return i&&i.parentNode?i:null}removeAllPriorNodes(){let{nodeArrayOrObservableAtIndex:e}=this;for(;e.length;)this.removeNodeArrayOrObservable(e.pop())}removeNodeArrayOrObservable(e){for(let t of e){if(t instanceof n){t.dispose();continue}let r=t;delete r[Bt],this.detachAndDispose(r);let i=this.subscriptionsForNode.get(r);i&&(i.forEach(s=>s.dispose()),this.subscriptionsForNode.delete(r))}}detachAndDispose(e){if(zs(e))for(let t of e)this.detachAndDispose(t);else e.remove();qs(e)}},en=qr;function Jr(n){if(S(n))return!0;let e=f(n);return e?e.elementName?!0:!(!Array.isArray(e)||!e.length||e[0]instanceof window.Node):!1}function zr(n){return n[Bt]}var ku=0,tn=class extends je{constructor(e){super(e),this.originalChildNodes=ue(y.childNodes(this.$element)),this.computed("computeApplyComponent")}cloneTemplateIntoElement(e,t,r){if(!t)throw new Error("Component '"+e+"' has no template");if(Jr(t))y.emptyNode(r),this.addDisposable(new en(t,r,null,void 0,!0));else{let i=De(t);y.setDomNodeChildren(r,i)}}createViewModel(e,t,r,i){let s=e.createViewModel;return s?s.call(e,i,{element:t,templateNodes:r}):i}makeTemplateSlotNodes(e){return Object.assign({},...this.genSlotsByName(e))}*genSlotsByName(e){for(let t of e){if(t.nodeType!==Node.ELEMENT_NODE)continue;let r=t.getAttribute("slot");r&&(yield{[r]:t})}}computeApplyComponent(){let e=f(this.value),t,r;if(typeof e=="string"?t=e:(t=f(e.name),r=Ie.getNodeValues(this.$element)||f(e.params)),this.latestComponentName=t,!t)throw new Error("No component name specified");this.loadingOperationId=this.currentLoadingOperationId=++ku,Ke.get(t,i=>this.applyComponentDefinition(t,r,i))}makeChildBindingContext(e){let t=r=>Object.assign(r,{$component:e,$componentTemplateNodes:this.originalChildNodes,$componentTemplateSlotNodes:this.makeTemplateSlotNodes(this.originalChildNodes)});return this.$context.createChildContext(e,void 0,t)}applyComponentDefinition(e,t,r){if(this.currentLoadingOperationId!==this.loadingOperationId||this.latestComponentName!==e)return;this.cleanUpState();let i=this.$element;if(!r)throw new Error("Unknown component '"+e+"'");r.template&&this.cloneTemplateIntoElement(e,r.template,i);let s=this.createViewModel(r,i,this.originalChildNodes,t);this.childBindingContext=this.makeChildBindingContext(s);let o=s&&s.template;if(!o&&!r.template)throw new Error("Component '"+e+"' has no template");r.template||this.cloneTemplateIntoElement(e,o,i),s instanceof X&&s.anchorTo(this.$element),this.currentViewModel=s;let a=this.onBindingComplete.bind(this,s);this.applyBindingsToDescendants(this.childBindingContext,a)}onBindingComplete(e,t){e&&e.koDescendantsComplete&&e.koDescendantsComplete(this.$element),this.completeBinding(t)}cleanUpState(){let e=this.currentViewModel,t=e&&e.dispose;typeof t=="function"&&t.call(e),this.currentViewModel=null,this.currentLoadingOperationId=null}dispose(){this.cleanUpState(),super.dispose()}get controlsDescendants(){return!0}static get allowVirtualElements(){return!0}};var nn=class extends je{constructor(e){super(e);let t=this.getSlot(this.value),r=Fe(t),i=this.$context.extend({$slotContext:r,$slotData:r&&r.$data});this.replaceSlotWithNode(this.$element,t),this.applyBindingsToDescendants(i)}replaceSlotWithNode(e,t){let r=this.cloneNodeFromOriginal(t);y.emptyNode(e),this.addDisposable(new en(r,e,void 0,void 0,!0))}cloneNodeFromOriginal(e){if(!e)return[];let t=zr(e);return t?t.children:"content"in e?[...document.importNode(e.content,!0).childNodes]:(Array.isArray(e)?e:[e]).map(i=>i.cloneNode(!0))}getSlot(e){let{$componentTemplateSlotNodes:t}=this.$context;return e?t[e]:t[""]||[...this.$context.$componentTemplateNodes].filter(r=>!r.getAttribute||!r.getAttribute("slot"))}static get allowVirtualElements(){return!0}};var Gs={component:tn,slot:nn};var kn=String.prototype,Ys={uppercase:function(n){return kn.toUpperCase.call(f(n))},lowercase:function(n){return kn.toLowerCase.call(f(n))},default:function(n,e){return n=f(n),typeof n=="function"?n:typeof n=="string"?kn.trim.call(n)===""?e:n:n==null||n.length==0?e:n},replace:function(n,e,t){return kn.replace.call(f(n),e,t)},fit:function(n,e,t,r){if(n=f(n),e&&(""+n).length>e)switch(t=""+(t||"..."),e=e-t.length,n=""+n,r){case"left":return t+n.slice(-e);case"middle":{let i=Math.ceil(e/2);return n.substr(0,i)+t+n.slice(i-e)}default:return n.substr(0,e)+t}else return n},json:function(n,e,t){return JSON.stringify(dt(n),t,e)},number:function(n){return(+f(n)).toLocaleString()}};var Mu=/\bfunction\s*\(([^)]*)\)\s*\{\s*(?:(return\s)?([^}]+?)[;\s]*)?\}/g;function Nt(n){return n.replace(Mu,(e,t,r,i)=>{i&&!r&&(i+=" && undefined");let s=`(${t.trim()}) => ${i}`;return Nt.silent||console.log(`Knockout: Replace "${e}" with "${s}"`),s})}Nt.silent=!1;var Xs=new xt,Pu={preProcessBindings:n=>Xs.preProcessBindings(n)},Vu=new wt({providers:[new vt,Xs,new Ct,new Ft]}),Ru=new Qt({provider:Vu,bindings:[Us,Cs,Qs,Gs,{each:Ks.foreach}],extenders:{},filters:Ys,options:{bindingGlobals:c.global,bindingStringPreparsers:[Nt]}}),Lu="4.0.0",$u=Ru.create({version:Lu,components:Ke,Component:Ke.ComponentABC,expressionRewriting:Pu});return ro(Hu);})();
|
|
16
15
|
(typeof self !== 'undefined' ? self : typeof window !== 'undefined' ? window : global).ko = ko.default
|