@webqit/oohtml 1.9.24 → 1.10.1

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/state-api.js CHANGED
@@ -1,3 +1,3 @@
1
- (()=>{function g(t){return!Array.isArray(t)&&typeof t=="object"&&t}function T(t){return typeof t}function v(t,...e){globalThis.WebQitInternalsRegistry||(globalThis.WebQitInternalsRegistry=new Map);var r=globalThis.WebQitInternalsRegistry.get(t);if(!r){if(r=new Map,e[0]===!1)return r;globalThis.WebQitInternalsRegistry.set(t,r)}for(var o,i;o=e.shift();)if((i=r)&&!(r=r.get(o))){if(r=new Map,e[0]===!1)return r;i.set(o,r)}return r}function h(t){return Array.isArray(t)}function ge(t){return t===!0||t===!1}function te(t){return typeof t=="function"}function Ye(t){return te(t)&&/^class\s?/.test(Function.prototype.toString.call(t))}function Te(t){return t===null||t===""}function A(t){return arguments.length&&(t===void 0||typeof t>"u")}function d(t){return Array.isArray(t)||typeof t=="object"&&t||te(t)}function Ke(t){return Te(t)||A(t)||t===!1||t===0||d(t)&&!Object.keys(t).length}function _(t){return te(t)||t&&{}.toString.call(t)==="[object function]"}function U(t){return t instanceof Number||typeof t=="number"}function F(t){return U(t)||t!==!0&&t!==!1&&t!==null&&t!==""&&!isNaN(t*1)}function Se(t){return g(t)&&Object.getPrototypeOf(t)===Object.prototype}function z(t){return t instanceof String||typeof t=="string"&&t!==null}function ke(t){return!z(t)&&!A(t.length)}function H(t,e=1){var r=0;t.forEach(i=>{r++});var o=t.slice(t.length-r,e);return arguments.length>1?o:o[0]}function j(t,e=1){return arguments.length>1?H(t.slice().reverse(),e).reverse():H(t.slice().reverse())}function Ce(t,...e){return e.forEach(r=>{t.indexOf(r)<0&&t.push(r)}),t}function et(o,e){e=e||Object.prototype,e=e&&!h(e)?[e]:e;for(var r=[],o=o;o&&(!e||e.indexOf(o)<0)&&o.name!=="default";)r.push(o),o=o?Object.getPrototypeOf(o):null;return r}function tt(t,e){var r=[];return et(t,e).forEach(o=>{Ce(r,...Object.getOwnPropertyNames(o))}),r}function D(t,e,r=!1,o=!1,i=!1){var s=0,n=t.shift();if((F(n)||n===!0||n===!1)&&(s=n,n=t.shift()),!t.length)throw new Error("_merge() requires two or more array/objects.");return t.forEach((f,m)=>{!d(f)&&!_(f)||(r?tt(f):Object.getOwnPropertyNames(f)).forEach(u=>{if(!!e(u,n,f,m)){var p=n[u],a=f[u];if((h(p)&&h(a)||g(p)&&g(a))&&(s===!0||s>0))n[u]=h(p)&&h(a)?[]:{},D([F(s)?s-1:s,n[u],p,a],e,r,o,i);else if(h(n)&&h(f))o?n[u]=a:n.push(a);else try{i?Object.defineProperty(n,u,Object.getOwnPropertyDescriptor(f,u)):n[u]=f[u]}catch{}}})}),n}function W(t,e){var r=void 0;return d(t)&&Object.keys(t).forEach((o,i)=>{r!==!1&&(r=e(F(o)?parseFloat(o):o,t[o],i))}),r}function M(...t){return D(t,(e,r,o)=>!0,!1,!1,!1)}function ue(t,e,r=null,o=!1){return e.length>t.length?-1:(typeof r=="number"?o?t.slice(0,r+1+(r<0?t.length:0)):t.slice(r):t).reduce((i,s,n)=>{var[f,m,u]=i;if(!o&&f>-1)return[f,m,u];var p=u+1,a=s===e[p]?p===0?[n,0]:[m,p]:[-1,-1];return a[1]===e.length-1&&(a[1]=-1,a[0]>-1)?[a[0]].concat(a):[f].concat(a)},[-1,-1,-1])[0]+(o||typeof r!="number"?0:r>-1?r:t.length-r)}function me(t,e,r=null,o=!1){var i=ue(t,e,r,o);return i===-1?[]:t.slice(i+e.length)}function rt(t,e){return t.reduce((r,o,i)=>r||e(o,i),!1)}function y(t,e=!0){return h(t)?t:!e&&g(t)?[t]:t!==!1&&t!==0&&Ke(t)?[]:ke(t)?Array.prototype.slice.call(t):g(t)?Object.values(t):[t]}function Fe(t,e,r=null){return h(e)?t.filter(o=>r?e.filter(i=>r(o,i)).length:e.indexOf(o)===-1):[]}function G(t,e,r=null){return r||r!==!1&&t.dotSafe&&e.dotSafe?t.join(".")===e.join("."):t.length===e.length&&t.reduce((o,i,s)=>o&&i===e[s],!0)}var xt=function(t,e=1,r=!0){return!F(e)||e<=0||(!h(t)&&g(t)&&r&&(t=Object.values(t)),!h(t))?t:t.reduce((o,i)=>h(i)||g(i)&&r?o.concat(xt(h(i)?i:Object.values(i),e-1,r)):o.concat(i),[])},ot=xt;function _e(t,e,r=null){return h(e)?t.filter(o=>r?e.filter(i=>r(o,i)).length:e.indexOf(o)!==-1):[]}function ve(t,e,r=null){return r||r!==!1&&t.dotSafe&&e.dotSafe?(t.join(".")+".").startsWith(e.join(".")+"."):e.reduce((o,i,s)=>o&&i===t[s],!0)}function it(t){let e=(r,o,i)=>i.indexOf(r)===o;return t.filter(e)}function re(t){return(nt(t)?t:y(t).length?[t]:[]).reduce((e,r)=>e.concat([y(r)]),[]).map(e=>J.resolve(e))}var J=class extends Array{static resolve(e){return e.every(r=>!(r+"").includes("."))?new J().concat(e):e}get dotSafe(){return!0}};function nt(t){return y(t).reduce((e,r)=>e||h(r),!1)}function st(t){return t.filter(e=>e||e===0).length!==t.length}function Ot(t){return t.filter(e=>st(y(e))).length>0}var oe=class{constructor(e){this.target=e,this.fireables=[],this.currentlyFiring=[]}add(e){return this.fireables.push(e),e}remove(e){this.fireables=this.fireables.filter(r=>r!==e)}removeMatches(e){this.match(e).forEach(r=>{this.fireables=this.fireables.filter(o=>o!==r)})}match(e){return this.fireables.filter(r=>{var o=re(r.filter),i=y((r.params||{}).tags),s=re(e.filter),n=y((e.params||{}).tags);return(!e.originalHandler||r.handler===e.originalHandler)&&(!s.length||G(s,o))&&(!n.length||n.length===i.length&&_e(i,n).length===n.length)})}static _getFirebase(e,r,o=!0,i=this.__namespace){if(!d(r))throw new Error('Subject must be of type object; "'+T(r)+'" given!');var s=this;return i&&globalThis.WebQitObserverNamespaceRegistry.has(e+"-"+i)&&(s=globalThis.WebQitObserverNamespaceRegistry.get(e+"-"+i),e+="-"+i),!v(r,"firebases").has(e)&&o&&v(r,"firebases").set(e,new s(r)),v(r,"firebases").get(e)}static _namespace(e,r,o=null){if(e+="-"+r,arguments.length===2)return globalThis.WebQitObserverNamespaceRegistry.get(e);if(!(o.prototype instanceof this))throw new Error(`The implementation of the namespace ${this.name}.${r} must be a subclass of ${this.name}.`);globalThis.WebQitObserverNamespaceRegistry.set(e,o),o.__namespace=r}};globalThis.WebQitObserverNamespaceRegistry||(globalThis.WebQitObserverNamespaceRegistry=new Map);var ie=class{constructor(e,r){this.target=e,this.handler=r.handler,this.filter=r.filter,this.params=r.params}disconnect(){this.disconnected=!0}};var ye=class extends ie{fire(e,r,o){return this.disconnected||this.filter&&!_e(y(this.filter),[e.type]).length?r(...Array.prototype.slice.call(arguments,2)):this.handler(e,o,r)}};function ae(t,e,r=!0,o=!0,i=!1,s=!1){if(h(t)&&h(e)){var n=[],f=!0;return t.forEach(m=>{if(!!f){var u=!1;W(e,(p,a)=>{(!u||o&&d(m))&&(u=r(m,a),(h(u)&&!u.length||g(u)&&!Object.keys(u).length)&&(u=!1),d(u)&&o&&(m=u))}),d(u)?n.push(o?u:m):ge(u)?i&&!u||!i&&u?n.push(m):s&&(f=!1):n.push(u)}}),n}if(g(t)&&g(e)){var n={},f=!0;return Object.keys(t).forEach(p=>{if(!!f){var a=r(t[p],e[p]);(h(a)&&!a.length||g(a)&&!Object.keys(a).length)&&(a=!1),d(a)?n[p]=o?a:t[p]:ge(a)?i&&!a||!i&&a?n[p]=t[p]:s&&(f=!1):n[p]=a}}),n}}function Ae(t,e=[],r=!0){var o=0;return F(arguments[0])&&d(arguments[1])&&(o=arguments[0],t=arguments[1],e=arguments[2]||[]),D([o,{},t],(i,s,n)=>_(e)?e(i):h(e)&&e.length?e.indexOf(i)>-1:!0,!1,!1,r)}function je(t,e=[]){return D([{},t],(r,o,i)=>{if(!_(i[r]))return _(e)?e(r):h(e)&&e.length?e.indexOf(r)>-1:!0},!1,!1,!1)}var ft=function(t,e,r=!0,o=1){if(h(t)&&h(e)&&t.length!==e.length)return!r;if(g(t)&&g(e)){var i=Object.keys(t),s=Object.keys(e);if(!i.length&&!s.length)return Se(t)&&Se(e)?r:t===e===r;if(!ft(i,s))return!r}if(o>0&&(h(t)&&h(e)||g(t)&&g(e))){var n=ae(t,e,(f,m)=>ft(f,m,r,o-1),!1,!1,!0);return h(n)?n.length===t.length&&n.length===e.length:g(n)&&g(t)?Object.keys(n).length===Object.keys(t).length&&Object.keys(n).length===Object.keys(e).length:n}return _(r)?r(t,e):U(t)&&U(e)&&isNaN(t)&&isNaN(e)?r:t===e===r},ut=ft;var le=class{constructor(e,r){if(this.target=e,!r.type)throw new Error("Action type must be given in definition!");W(r,(o,i)=>{Object.defineProperty(this,o,{value:i,enumerable:!0})}),Object.seal(this)}};var E=class extends oe{add(e){return super.add(new ye(this.target,e))}fire(e,r=null){if(e instanceof le||(e=new le(this.target,e)),this.currentlyFiring.filter(s=>s.type===e.type&&s.name===e.name).length)return r?r():void 0;this.currentlyFiring.push(e);let o=(s,...n)=>{var f=this.fireables[s];return f?f.fire(e,(...m)=>o(s+1,...m),...n):r?r(...n):n[0]};var i=o(0);return this.currentlyFiring.pop(),i}static getFirebase(e,r=!0,o=null){return super._getFirebase("interceptor",...arguments)}static namespace(e,r=null){return super._namespace("interceptor",...arguments)}};function w(t){return v(t,!1).get(t)||t}function P(t,e,r={},o={}){if(!e||!d(e))throw new Error("Target must be of type object!");e=w(e);var i,s=function(n){return arguments.length?n:Reflect[t](e,...Object.values(r))};return(i=E.getFirebase(e,!1,o.namespace))?i.fire({type:t,...r},s):s()}function Ne(t,e,r,o={}){return P("apply",t,{thisArgument:e,argumentsList:r},o)}function De(t,e,r=null,o={}){return P("construct",t,arguments.length>2?{argumentsList:e,newTarget:r}:{argumentsList:e},o)}var q=class{constructor(e,r=!1){this._={},this._.target=e,this._.cancellable=r,this._.propagationStopped=!1,this._.defaultPrevented=!1,this._.promisesInstance=null,this._.promises=[]}get target(){return this._.target}get cancellable(){return this._.cancellable}stopPropagation(){this._.propagationStopped=!0}get propagationStopped(){return this._.propagationStopped}preventDefault(){this._.defaultPrevented=!0}get defaultPrevented(){return this._.defaultPrevented}waitUntil(e){e instanceof Promise&&(this._.promises.push(e),this._.promisesInstance=null)}get promises(){return!this._.promisesInstance&&this._.promises.length&&(this._.promisesInstance=Promise.all(this._.promises)),this._.promisesInstance}respondWith(e){var r,o=g(e)&&!A(e.propagationStopped)&&!A(e.defaultPrevented);e===!1||o&&e.propagationStopped?this.stopPropagation():e===!1||o&&e.defaultPrevented?this.preventDefault():(e instanceof Promise&&(r=e)||o&&(r=e.promises))&&this.waitUntil(r)}};var be=class extends ie{constructor(e,r){if(super(e,r),this.filters2D=re(this.filter),this.filtersIsOriginally2D=nt(this.filter),this.filtersIsDynamic=Ot(this.filters2D),this.filtersIsDynamic&&this.filters2D.length>1)throw new Error('Only one "Dynamic Filter" must be observed at a time! "'+this.filters2D.map(o=>"["+o.join(", ")+"]").join(", ")+'" have been bound together.')}fire(e){if(this.disconnected||this.params.type&&!rt(e,n=>this.params.type===n.type))return;let r=n=>!["set","def"].includes(n.type)||!this.params.diff||(_(this.params.diff)?this.params.diff(n.value,n.oldValue):n.value!==n.oldValue);var o=new q(this.target);if(this.filters2D.length){var i=e.filter(n=>this.filters2D.filter((f,m)=>{var u=f.slice();return this.filtersIsDynamic&&n.path.forEach((p,a)=>{u[a]=u[a]||u[a]===0?u[a]:p}),(!this.filtersIsDynamic||!st(u))&&r(n)&&(!this.params.subtree&&G(u,n.path)||this.params.suptree&&ve(u,n.path)&&(!F(this.params.suptree)||me(u,n.path).length<=this.params.suptree)||this.params.subtree&&n.path.length>=u.length&&ve(n.path,u)&&(!F(this.params.subtree)||me(n.path,u).length<=this.params.subtree))}).length);if(i.length)if(this.filtersIsOriginally2D||this.params.subtree){var s=i;g(this.filter)&&(s={...this.filter},i.forEach((n,f)=>{s[n.name]=n})),o.respondWith(this.handler(s,o))}else i.forEach((n,f)=>{o.respondWith(this.handler(n,o))})}else(this.params.subtree||e.filter(n=>G(n.path,[n.name])).length===e.length)&&e.filter(n=>r(n)).length&&o.respondWith(this.handler(e,o));return o}};var Z=class{constructor(e,r){if(this.target=e,r.originalSubject||(this.originalSubject=e),!("type"in r))throw new Error("Mutation type must be given in definition!");if(!("name"in r))throw new Error("Property name must be given in definition!");W(r,(o,i)=>{o==="path"&&(i=J.resolve(i)),Object.defineProperty(this,o,{value:i,enumerable:!0})}),this.path||Object.defineProperty(this,"path",{value:J.resolve([r.name]),enumerable:!0}),Object.seal(this)}};var x=class extends oe{constructor(e){super(e),this.buffers=[]}add(e){return super.add(new be(this.target,e))}fire(e,r){var o=new q(this.target,r);return e=y(e,!1).map(i=>i instanceof Z?i:new Z(this.target,i)),this.buffers.length?(j(this.buffers)(e),o):(this.currentlyFiring.filter(i=>e.filter(s=>i.type===s.type&&i.name===s.name).length).length,this.fireables.forEach(i=>{if(o.propagationStopped&&r)return o;o.respondWith(i.fire(e))}),o)}static getFirebase(e,r=!0,o=null){return super._getFirebase("observer",...arguments)}static namespace(e,r=null){return super._namespace("observer",...arguments)}};function $(t,e,r=null,o={}){if(t=r||t,!t||!d(t))throw new Error("Target must be of type object!");t=w(t);var i=y(e),s=i.map(n=>{var f,m=function(u){return arguments.length?u:v(t,"accessorizedProps").has(n)&&v(t,"accessorizedProps").get(n).touch(!0)?v(t,"accessorizedProps").get(n).get():r?Reflect.get(t,n,r):Reflect.get(t,n)};return(f=E.getFirebase(t,!0,o.namespace))?f.fire({type:"get",name:n,related:i,receiver:r},m):m()});return h(e)?s:s[0]}function Me(t,e,r=null,o={}){if(t=w(t),!t||!d(t))throw new Error('Observable subjects must be of type object; "'+T(t)+'" given!');if(_(e)&&(o=arguments.length>2?r:{},r=e,e=null),!_(r))throw new Error('Handler must be a function; "'+T(r)+'" given!');var i,s=x.getFirebase(t,!0,o.namespace),n={filter:e,handler:r,params:o};if((n.filter||n.params.subtree==="*"||n.params.subtree&&pe(t))&&X(t,n.filter,n.params.subtree,o.namespace),n.params.unique&&(i=s.match({filter:e,params:o})).length){if(n.params.unique!=="replace")return i[0];s.remove(i[0])}return s.add(n)}function Y(t,e,r,o=null,i={}){if(t!==r){var s;if(Me(r,(f,m)=>{if(s=x.getFirebase(t,!1,i.namespace)){var u=f.map(p=>{var a=p;do if(a.target===t)return;while(a=a.src);var l={};return W(p,(c,b)=>{c!=="target"&&c!=="name"&&c!=="path"&&c!=="src"&&(l[c]=b)}),l.name=e,l.path=[e].concat(p.path),l.originalSubject=p.originalSubject,l.src=p,new Z(t,l)}).filter(p=>p);if(u.length)return s.fire(u,m.cancellable)}},{subtree:!0,...i,unique:!0,tags:[at,e,t]}),g(o)&&(s=x.getFirebase(t,!1,i.namespace))){var n=M({name:e,type:"set",value:r,related:[e]},o);let f=s.fire(n,i.cancellable);if(i.eventTypeReturn)return f}}}var at={};function X(t,e=null,r=!1,o=null){if(!t||!d(t))throw new Error("Target must be of type object!");var i=x.getFirebase(t,!0,o);if(!(!i||i.build)){i.build=r;var s=re(e),n=!s.length||s.filter(m=>!m[0]&&m[0]!==0).length?Object.keys(t):s.map(m=>m[0]),f=s.length?s.map(m=>m.slice(1)).filter(m=>m.length):null;i.subBuild=f&&f.length?f:null,n.forEach(m=>{var u=$(t,m,null,{namespace:o});try{d(u)&&(Y(t,m,u,null,params),(i.subBuild&&pe(u)||(_isFunction(r)?r(u):r&&pe(u)))&&X(u,i.subBuild,r,o))}catch{}})}}var pe=t=>(t instanceof Object||t instanceof Array||t instanceof Function)&&(typeof window>"u"||t!==window);function $e(t,e,r=null,o={}){if(t=w(t),!t||!d(t))throw new Error('Observable subjects must be of type object; "'+T(t)+'" given!');if(_(e)&&(o=arguments.length>2?r:{},r=e,e=null),r&&!_(r))throw new Error('Handler must be a function; "'+T(r)+'" given!');var i;if(i=x.getFirebase(t,!1,o.namespace))return i.removeMatches({filter:e,originalHandler:r,params:o})}function K(t,e,r,o=null,i={}){$e(r,null,null,{...i,tags:[at,e,t]});var s;if(g(o)&&(s=x.getFirebase(t,!1,i.namespace))){var n=M({name:e,type:"del",oldValue:r,related:[e]},o);s.fire(n,i.cancellable)}}function k(t,e,r={}){return P("has",t,{name:e},r)}function Ie(t,e,r,o={}){e=r.receiver||e;var i=r.keysOrPayload,s=r.value;if(!e||!d(e))throw new Error("Target must be of type object!");g(i)&&(o=s||{},s=null),e=w(e);var n=E.getFirebase(e,!1,o.namespace),f=x.getFirebase(e,!1,o.namespace);let m=(c,b,C,de)=>{var dt="set",L;t&&(dt="defineProperty",L=b||{},b=L.value);var Ee=!1,Pe;k(e,c,o)&&(Ee=!0,Pe=$(e,c,r.receiver,o));var N={name:c,type:dt,value:b,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe},gt=function(_t){return arguments.length&&(L?L=_t:b=_t),L?v(e,"accessorizedProps",!1).has(c)&&!v(e,"accessorizedProps").get(c).restore()?!1:(Object.defineProperty(e,c,L),!0):v(e,"accessorizedProps",!1).has(c)?v(e,"accessorizedProps").get(c).set(b):(e[c]=b,!0)};if(n){var Qt=L?{type:"defineProperty",name:c,descriptor:L,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe}:{type:"set",name:c,value:b,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe};N.success=n.fire(Qt,gt)}else N.success=gt();return N.success&&N.value!==N.oldValue&&(d(N.oldValue)&&K(e,c,N.oldValue,null,o),d(N.value)&&(Y(e,c,N.value,null,o),f&&(f.subBuild||f.build&&pe(N.value))&&X(N.value,f.subBuild,f.build,o.namespace))),N};var u,p=[];h(i)||(z(i)||U(i))&&(u=y(i))?p=u.map(c=>m(c,s,u,o.detail)):g(i)&&(u=Object.keys(i))&&(p=u.map(c=>m(c,i[c],u,o.detail)));var a=p.filter(c=>c.success!==!1),l;return f?(l=f.fire(a,o.cancellable),l.successCount=a.length):o.eventTypeReturn&&(l=new q(e)),o.eventTypeReturn?l:a.length>0}function We(t,e,r=null,o={}){return Ie(!0,t,{keysOrPayload:e,value:r},o)}function qe(t,e,r={}){if(!t||!d(t))throw new Error("Target must be of type object!");t=w(t);var o=y(e),i=o.map(m=>{var u;k(t,m,r)&&(u=$(t,m,null,r));var p={name:m,type:"deleteProperty",related:o,detail:r.detail,oldValue:u},a,l=function(c){return arguments.length?c:v(t,"accessorizedProps",!1).has(m)&&!v(t,"accessorizedProps").get(m).restore()?!1:(delete t[m],!0)};return(a=E.getFirebase(t,!1,r.namespace))?p.success=a.fire({type:"deleteProperty",name:m,oldValue:u,related:o},l):p.success=l(),p.success&&d(p.oldValue)&&K(t,m,p.oldValue,null,r),p}),s=i.filter(m=>m.success!==!1),n,f;return(n=x.getFirebase(t,!1,r.namespace))?(f=n.fire(s,r.cancellable),f.successCount=s.length):r.eventTypeReturn&&(f=new q(t)),r.eventTypeReturn?f:s.length>0}function Re(t,e,r={}){return P("getOwnPropertyDescriptor",t,{name:e},r)}function Qe(t,e={}){return P("getPrototypeOf",t,{},e)}function Ue(t,e={}){return P("isExtensible",t,{},e)}function ze(t,e={}){return P("ownKeys",t,{},e)}function Be(t,e={}){return P("preventExtensions",t,{},e)}function ce(t,e,r=null,o=null,i={}){return Ie(!1,t,arguments.length>3?{keysOrPayload:e,value:r,receiver:o}:{keysOrPayload:e,value:r},i)}function Ve(t,e,r={}){return P("setPrototypeOf",t,{prototype:e},r)}function Et(t,e=[],r={}){r=g(e)?e:r;var o=(arguments.length===1?Object.keys(t):y(e)).map(i=>{if(v(t,"accessorizedProps").has(i)&&v(t,"accessorizedProps").get(i).touch(!0))return!1;let s=()=>{for(var l,c=t;!l&&(c=Object.getPrototypeOf(c));)l=Object.getOwnPropertyDescriptor(c,i);return l};var n=Object.getOwnPropertyDescriptor(t,i),f,m;n||(f={writable:!0,enumerable:!(i in t),configurable:r.configurable!==!1});var u={...n||f};"value"in u&&delete u.value,"writable"in u&&delete u.writable,u.get=()=>{if(a.ongoingGets.length)return a.get();a.ongoingGets.push(1);var l=$(t,i,null,r);return a.ongoingGets.pop(),l};var p;u.set=l=>{if(a.ongoingSets.length)return a.set(l);a.ongoingSets.push(1);var c=ce(t,i,l,null,r);return a.ongoingSets.pop(),c};var a={ongoingGets:[],ongoingSets:[],get:function(){var l=n;return l||(m?l=f:l=s()||f),l.get?l.get.call(t):l.value},set:function(l){var c=n;return c||(m?c=f:(c=s())?"value"in c&&(c=f,m=!0):(c=f,m=!0)),c.set||c.get?c.set?c.set.call(t,l):!1:(c.value=l,!0)},restore:function(){try{return this.intact()&&(n||m?Object.defineProperty(t,i,n||f):delete t[i],v(t,"accessorizedProps").delete(i)),!0}catch{}return!1},intact:function(){return(Object.getOwnPropertyDescriptor(t,i)||{}).get===u.get},touch:function(l=!1){return this.intact()||(l?!this.restore():!1)}};try{return Object.defineProperty(t,i,u),v(t,"accessorizedProps").set(i,a),!0}catch{}return!1});return h(e)?o:o[0]}function Pt(t,e=[],r={}){r=g(e)?e:r;var o=(arguments.length===1?Object.keys(t):y(e)).map(i=>v(t,"accessorizedProps",!1).has(i)?v(t,"accessorizedProps").get(i).restore():!0);return h(e)?o:o[0]}function Tt(t,e={}){if(!d(t))throw new Error('Object must be of type target; "'+T(t)+'" given!');var r=new Proxy(t,{apply:(o,i,s)=>Ne(o,i,s,e),construct:(o,i,s=null)=>De(o,i,s,e),defineProperty:(o,i,s)=>We(o,i,s,e),deleteProperty:(o,i)=>qe(o,i,e),get:(o,i,s=null)=>{var n=$(o,i,s,e);return e.proxyAutoBinding!==!1&&_(n)&&!Ye(n)?n.bind(r):n},getOwnPropertyDescriptor:(o,i)=>Re(o,i,e),getPrototypeOf:o=>Qe(o,e),has:(o,i)=>k(o,i,e),isExtensible:o=>Ue(o,e),ownKeys:o=>ze(o,e),preventExtensions:o=>Be(o,e),set:(o,i,s,n=null)=>ce(o,i,s,n,e),setPrototypeOf:(o,i)=>Ve(o,i,e)});return v(r).set(r,t),r}function St(t,e,r={}){if(t=w(t),!d(t))throw new Error('Object must be of type target; "'+T(handler)+'" given!');var o={},i=!0;g(e)||(_(e)?e={"":e}:_(r)&&(e={[e]:r},r=arguments.length>3?arguments[3]:{}),i=!1);var s=E.getFirebase(t,!0,r.namespace);return Object.keys(e).forEach(n=>{if(!_(e[n]))throw new Error("Callback"+(n===null?"":" for "+n)+' must be a function; "'+T(e[n])+'" given!');var f={filter:n,handler:e[n],params:r},m;if(f.params.unique&&(m=s.match(f)).length){if(f.params.unique!=="replace")return m[0];s.remove(m[0])}i?o[n]=s.add(f):o=s.add(f)}),o}function Ct(t,e=null,r={}){if(t=w(t),!t||!d(t))throw new Error('Object must be of type target; "'+T(t)+'" given!');var o=E.getFirebase(t,!1,r.namespace);_isObject(e)||(_(e)?e={[null]:e}:_(r)&&(e={[e]:r},r=arguments.length>3?arguments[3]:{}),isOriginallyObj=!1),(o=E.getFirebase(t,!1,r.namespace))&&Object.keys(e).forEach(i=>{if(!_(e[i]))throw new Error("Callback"+(i===null?"":" for "+i)+' must be a function; "'+T(e[i])+'" given!');var s={filter:i,originalHandler:e[i],params:r};return o.removeMatches(s)})}function Ft(t,...e){var r=e.map(s=>{if(s=w(s),!d(s))throw new Error("Target must be of type object!");return{target:s,subjectCopy:h(s)?s.slice(0):Ae(s)}}),o=t(...e);let i=()=>{r.map(s=>{var n=Object.keys(s.subjectCopy),f=Object.keys(s.target),m=[],u=it(n.concat(f)).map(a=>{if(s.subjectCopy[a]!==s.target[a]){m.push(a);var l={name:a,related:m,buffered:!0};return f.includes(a)?(l.type="set",l.value=s.target[a],n.includes(a)&&(l.isUpdate=!0)):l.type="del",n.includes(a)&&(l.oldValue=s.subjectCopy[a]),d(s.subjectCopy[a])&&K(s.target,a,s.subjectCopy[a]),d(s.target[a])&&Y(s.target,a,s.target[a]),l}}).filter(a=>a),p;if(u.length&&(p=x.getFirebase(s.target,!1)))return p.fire(u)})};return o instanceof Promise?o.then(i):i(),o}var R={apply:Ne,construct:De,defineProperty:We,deleteProperty:qe,get:$,getOwnPropertyDescriptor:Re,getPrototypeOf:Qe,has:k,isExtensible:Ue,ownKeys:ze,preventExtensions:Be,set:ce,setPrototypeOf:Ve,accessorize:Et,unaccessorize:Pt,proxy:Tt,unproxy:w,observe:Me,unobserve:$e,intercept:St,unintercept:Ct,closure:Ft,build:X,link:Y,unlink:K,Observers:x,Interceptors:E};function Q(t){return!Array.isArray(t)&&typeof t=="object"&&t}function At(t){var e=typeof t.InstallTrigger<"u";if(e)return"firefox";var r=/constructor/i.test(t.HTMLElement)||function(u){return u.toString()==="[object SafariRemoteNotification]"}(!t.safari||typeof t.safari<"u"&&t.safari.pushNotification);if(r)return"safari";var o=!!t.chrome&&(!!t.chrome.webstore||!!t.chrome.runtime),i=o&&t.navigator.userAgent.indexOf("Edg")!=-1,s=!!t.opr&&!!t.opr.addons||!!t.opera||t.navigator.userAgent.indexOf(" OPR/")>=0,n=!!t.document.documentMode,f=!n&&!!t.StyleMedia,m=(o||s)&&!!t.CSS;return f?"edge":n?"ie":s?"opera":i?"ie-chromium":o?"chrome":"unknown"}function jt(t){var e=t.getComputedStyle(t.document.documentElement,""),r=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||e.Olink===""&&["","o"])[1],o=("WebKit|Moz|Ms|O".match(new RegExp("("+r+")","i"))||[])[1];return{api:o,prefix:r,css:"-"+r+"-"}}function B(){if(!(Q(this)&&this.window)&&typeof window>"u")throw new Error("A window context is required.");let t=Q(this)&&this.window?this.window:window;if(t.WebQit||(t.WebQit={}),!t.WebQit.window){let e,r;Object.defineProperty(t.WebQit,"window",{get:()=>t}),Object.defineProperty(t.WebQit,"vendor",{value:{getName:()=>(e||(e=At(t)),e),getPrefix:()=>(r||(r=jt(t)),r)}})}return t.WebQit}function Le(t){return typeof t=="function"}function I(t){return Array.isArray(t)||typeof t=="object"&&t||Le(t)}function Nt(t){return t instanceof Number||typeof t=="number"}function ne(t){return Nt(t)||t!==!0&&t!==!1&&t!==null&&t!==""&&!isNaN(t*1)}var xe=class{constructor(e,r=!0){this.window=e,this.async=r,this.readCallbacks=[],this.writeCallbacks=[],this._run()}_run(){this.window.requestAnimationFrame(()=>{this.readCallbacks.forEach((e,r)=>{e&&!e()&&(this.readCallbacks[r]=null)}),this.writeCallbacks.forEach((e,r)=>{e&&!e()&&(this.writeCallbacks[r]=null)}),this._run()})}onread(e,r=!1){if(r)return new Promise((o,i)=>{this.async===!1?e(o,i):this.readCallbacks.push(()=>{e(o,i)})});this.async===!1?e():this.readCallbacks.push(e)}onwrite(e,r=!1){if(r)return new Promise((o,i)=>{this.async===!1?e(o,i):this.writeCallbacks.push(()=>{e(o,i)})});this.async===!1?e():this.writeCallbacks.push(e)}cycle(e,r,o){this.onread(()=>{var i=e(o);if(i){var s=n=>{this.onwrite(()=>{var f=r(n,o);if(f){var m=u=>{this.cycle(e,r,u)};f instanceof Promise?f.then(m):m()}})};i instanceof Promise?i.then(s):s()}})}};function V(t){return t instanceof String||typeof t=="string"&&t!==null}function se(t){return Array.isArray(t)}function he(t){return arguments.length&&(t===void 0||typeof t>"u")}function Dt(t){return!V(t)&&!he(t.length)}function He(t){return t===null||t===""}function Mt(t){return He(t)||he(t)||t===!1||t===0||I(t)&&!Object.keys(t).length}function S(t,e=!0){return se(t)?t:!e&&Q(t)?[t]:t!==!1&&t!==0&&Mt(t)?[]:Dt(t)?Array.prototype.slice.call(t):Q(t)?Object.values(t):[t]}function Oe(t){let e=B.call(this);e.DOM.isDOMReady||e.window.document.readyState==="complete"?t(e.window):(e.window.domReadyCallbacks||(e.window.domReadyCallbacks=[],e.window.document.addEventListener("DOMContentLoaded",()=>{e.DOM.isDOMReady=!0,e.window.domReadyCallbacks.splice(0).forEach(r=>r(e.window))},!1)),e.window.domReadyCallbacks.push(t))}var we=class{constructor(e){this.window=e}onAdded(e,r,o={}){return o.on="added",this.onPresenceChange(e,(i,s,n,f,m)=>{r(i,s,n,f,m)},o)}onRemoved(e,r,o={}){return o.on="removed",this.onPresenceChange(e,(i,s,n,f,m)=>{r(i,s,n,f,m)},o)}onPresent(e,r,o={}){Oe.call(this.window,()=>{this.window.MutationObserver&&this.onAdded(e,(i,s)=>{i.forEach(n=>r(n,s))},o),V(e)?S(this.window.document.querySelectorAll(e)).forEach(i=>r(i,1)):e.parentNode&&r(e,1)})}onAbsent(e,r,o={}){Oe.call(this.window,()=>{this.window.MutationObserver&&onRemoved(e,(i,s)=>{i.forEach(n=>r(n,s))},o),V(e)?S(this.window.document.querySelectorAll(e)).length===0&&r(null,0):e.parentNode||r(e,0)})}onPresenceChange(e,r,o={}){e=S(e,!1);var i=(a,l)=>{if(l=l.filter(C=>C.matches),V(a)){var c=l.filter(C=>C.matches(a));if(o.observeIndirectMutation!==!1&&(c=l.reduce((C,de)=>C.concat(S(de.querySelectorAll(a))),c),c.length))return c}else{if(l.includes(a))return[a];if(o.observeIndirectMutation!==!1&&l.length){for(var b=a;b=b.parentNode;)if(l.includes(b))return[a]}}},s=(a,l)=>(l.$$searchCache||(l.$$searchCache=new Map),a.reduce((c,b)=>{var C;return l.$$searchCache.has(b)?C=l.$$searchCache.get(b):(C=i(b,l,V(b))||[],l.$$searchCache.set(b,C)),c.concat(C)},[])),n=new Set,f=new Set,m=(a,l,c)=>{l&&o.on==="removed"||!l&&o.on==="added"||(a=s(e,a)).length&&(o.maintainCallState?(a.forEach(b=>{l?(n.add(b),f.delete(b)):(n.delete(b),f.add(b))}),r(a,l,c,n,f)):r(a,l,c))},u=o.context||this.window.document.documentElement,p=this._observe(u,(a,l,c,b)=>{o.ignoreTransients||(m(a,0,!0),m(a.concat(l),1,!0),m(l,0,!0)),m(b,0),m(c,1)});return p}onAttrChange(e,r,o=[]){var i=new this.window.MutationObserver(r),s={attributes:!0,attributeOldValue:!0};return o&&(s.attributeFilter=o),i.observe(e,s),i}onTreeChange(e,r,o=!1){var i=new this.window.MutationObserver(r),s={childList:!0,subtree:o};return i.observe(e,s),i}onMutation(e,r,o){var i=new this.window.MutationObserver(r);return i.observe(e,o),i}_observe(e,r){if(!lt.has(e)){let i=new Set,s=new this.window.MutationObserver(n=>{if(!!i.size){var f=n.reduce((a,l)=>a.concat(S(l.addedNodes)),[]),m=n.reduce((a,l)=>a.concat(S(l.removedNodes)),[]),u=[],p=[];f=new Set(f),m=new Set(m),f.forEach(a=>{m.has(a)&&(m.delete(a),f.delete(a),a.isConnected?u.push(a):p.push(a))}),f=[...f],m=[...m],i.forEach(a=>a(u,p,f,m))}});s.observe(e,{childList:!0,subtree:!0}),lt.set(e,{callbacks:i,observer:s})}let o=lt.get(e);return o.callbacks.add(r),{disconnect(){o.callbacks.delete(r)},reconnect(){o.callbacks.add(r)}}}},lt=new Map;function $t(t){rr(t),or(t),ir(t)}function rr(t){t.CSS||(t.CSS={}),t.CSS.escape||(t.CSS.escape=e=>e.replace(/([\:@\~\$\&])/g,"\\$1"))}function or(t){"isConnected"in t.Node.prototype||Object.defineProperty(t.Node.prototype,"isConnected",{get:function(){return!this.ownerDocument||!(this.ownerDocument.compareDocumentPosition(this)&this.DOCUMENT_POSITION_DISCONNECTED)}})}function ir(t){t.Element.prototype.matches||(t.Element.prototype.matches=t.Element.prototype.matchesSelector||t.Element.prototype.mozMatchesSelector||t.Element.prototype.msMatchesSelector||t.Element.prototype.oMatchesSelector||t.Element.prototype.webkitMatchesSelector||function(e){for(var r=(this.document||this.ownerDocument).querySelectorAll(e),o=r.length;--o>=0&&r.item(o)!==this;);return o>-1})}function Ge(t,e=null,r=!1){let o=B.call(this);if(V(t)){var i;if(t.trim().startsWith("<")){var s=o.window.document.createElement("div");s.innerHTML=t,i=r?S(s.children):s.firstChild}else i=r?S(Wt.call(this,t,e)):pt.call(this,t,e);return i}return t instanceof o.window.Element?r?[t]:t:r?S(t):t}function It(t,e=null){return Ge.call(this,t,e,!0)}function pt(t,e=null,r=!1){let o=B.call(this);e=e||o.window.document;var i,s=r?"querySelectorAll":"querySelector";try{i=e[s](t)}catch{try{i=e[s](t.replace(/\:is\(/g,":matches("))}catch{try{i=e[s](t.replace(/\:is\(/g,":-webkit-any("))}catch{try{i=e[s](t.replace(/\:is\(/g,":-moz-any("))}catch(u){throw u}}}}return i}function Wt(t,e=null){return pt.call(this,t,e,!0)}function fe(t){return Le(t)||t&&{}.toString.call(t)==="[object function]"}function ee(t,e,r={},o={}){e=S(e).slice();for(var i=t;!he(i)&&!He(i)&&e.length;){var s=e.shift();if(!(r.get?r.get(i,s):I(i)?s in i:i[s])){o.exists=!1;return}i=r.get?r.get(i,s):i[s]}return o.exists=!0,i}function Je(t,e,r,o={},i={}){let s=(p,a,l)=>i.set?i.set(p,a,l):(ne(e[f])&&se(p)?p.push(l):p[a]=l,!0);e=S(e);for(var n=t,f=0;f<e.length;f++)if(f<e.length-1){if(!n||!I(n)&&!fe(n))return!1;var m=ee(n,e[f],i);if(!I(m)){if(i.buildTree===!1)return!1;m=fe(i.buildTree)?i.buildTree(f):ne(e[f+1])?[]:{};var u=s(n,e[f],m);if(!u)return!1}n=m}else return s(n,e[f],r)}function qt(t,e,r=!1,o={}){e=S(e);var i=!1;do{var s=e.pop(),s=s===""?0:s,n=t;e.length&&(n=ee(t,e,{},o)),(I(n)||fe(n))&&(o.has?o.has(n,s):s in n)&&(o.deleteProperty?i=o.deleteProperty(n,s):o.del?i=o.del(n,s):(delete n[s],i=!0))}while(i&&r&&e.length&&(I(n)||fe(n))&&!(o.keys?o.keys(n):Object.keys(n)).length);return i}function ct(t,e,r={}){var o={};return ee(t,e,r,o),o.exists}function ht(t,e=!1){let r=B.call(this);var o={};return!(o.el=r.window.document.head.querySelector('meta[name="oohtml"]'))&&e&&(o.el=r.window.document.createElement("meta"),o.el.setAttribute("name",t),r.window.document.head.append(o.el)),o.el&&(o.vars=(o.el.getAttribute("content")||"").split(";").filter(i=>i).reduce((i,s)=>{var n=s.split("=").map(f=>f.trim());return Je(i,n[0].split("."),n[1]==="true"?!0:n[1]==="false"?!1:ne(n[1])?parseInt(n[1]):n[1]),i},{})),o.get=function(i){return ee(this.vars,i.split("."))},o.set=function(i,s=null,n=!1){var f=Q(i)?i:{[i]:s===!0?"true":s};if(n=arguments.length<3?s:n,Object.keys(f).forEach(m=>{if(f[m]===!1)qt(this.vars,m.split("."));else if(Q(f[m]))Object.keys(f[m]).forEach(p=>{var a=(m+"."+p).split(".");(!n||!ct(this.vars,a))&&Je(this.vars,a,f[m][p])});else{var u=m.split(".");(!n||!ct(this.vars,u))&&Je(this.vars,u,f[m])}}),e){let m=(u,p)=>Object.keys(p).reduce((a,l)=>{var c=(u?u+".":"")+l;return Q(p[l])?a.push(...m(c,p[l])):a.push(c+"="+p[l]),a},[]);this.el.setAttribute("content",m("",this.vars).join(";"))}return!0},o.defaults=function(i,s=null){return this.set(i,s,!0)},o}function Ze(){let t=B.call(this);return t.DOM||(t.DOM={},$t(t.window),t.DOM.reflow=new xe(t.window),t.DOM.mutations=new we(t.window),t.DOM.meta=ht.bind(t.window),t.DOM.query=Ge.bind(t.window),t.DOM.queryAll=It.bind(t.window),t.DOM.ready=Oe.bind(t.window)),t}var O=class{static lex(e,r,o={}){if(!z(e=e+""))throw new Error("Argument1 must be a string!");var i=u=>({delims:u.delims.slice(),options:je(u.options),nesting:u.nesting.slice(),maxDepth:u.maxDepth,comments:u.comments.slice(),tokens:u.tokens.slice(),matches:u.matches.slice(),matchesi:je(u.matchesi)});if(O.$cache[e]&&o.cache!==!1)for(var s=0;s<O.$cache[e].length;s++){var n=O.$cache[e][s];if(ut(n.delims,r))return i(n)}var f=new O(e,o),m=f.lex(r);return o.cache!==!1&&(O.$cache[e]=O.$cache[e]||[],O.$cache[e].push(m)),i(m)}static split(e,r,o){return O.lex(e,r,o).tokens}static match(e,r,o){return O.lex(e,r,o).matches}constructor(e,r){if(!z(e))throw new Error("Lexer requires the first argument to be a string.");this.$str=e,this.$options=r||{},this.$options.blocks||(this.$options.blocks=O.$blocks),this.$options.quotes||(this.$options.quotes=O.$quotes),this.$options.comments||(this.$options.comments=O.$comments)}lex(e,r){for(var o={delims:y(e),options:M(!0,{},this.$options,r||{}),nesting:[],maxDepth:0,comments:[],tokens:[],matches:[],matchesi:{}},i=0;typeof i=="number";)i=this._evalCharsAt(o,i);if(o.nesting.length)throw new Error("Error parsing the string: "+this.$str+". Unterminated blocks: "+ot(o.nesting).join(", "));return o}_evalCharsAt(e,r){if(!(r>=this.$str.length)){var o=1,i={},s={},n={};if(e.openComment||(s=this._testQuotes(e,r)),e.openQuote||(i=this._testComments(e,r)),e.openComment||i.ending)if(!e.nesting.length&&!n.ending){var f=i.starting||i.ending||this.$str[r];o=f.length,this._push(e,f,"comments",i.starting)}else this._push(e,this.$str[r]);else if(e.openQuote||s.ending)this._push(e,this.$str[r]);else{if(e.options.limit&&e.matches.length===e.options.limit)return this._push(e,this.$str[r]),r+1;n=this._testNesting(e,r);var n=this._testNesting(e,r),m=this._testChars(e.options.stopChars||[],e,r);if(!e.nesting.length&&m!==!1){e.options.stopChar=m,e.options.stopCharForward=this.$str.substr(r);return}if(!e.delims.length)e.nesting.length===2&&n.starting?(e.matches.push(null),this._push(e,n.starting),o=n.starting.length):!e.nesting.length&&n.ending?(this._push(e,n.ending),o=n.ending.length,e.matches.push(null)):this._push(e,this.$str[r]);else if(!e.nesting.length&&!n.ending){this._push(e,"");var u=this._testChars(e.delims,e,r);if(u!==!1&&(e.matches.push(u),e.matchesi[r]=u,o=u.length||1,!e.options.preserveDelims)){var p=r+(u.length||1);return p===this.$str.length&&this._push(e,""),p}this._push(e,u||this.$str[r])}else{var f=n.starting||n.ending||this.$str[r];o=f.length,this._push(e,f)}}return r+o}}_testQuotes(e,r){var o={};return(e.options.quotes||[]).forEach(i=>{this.$str.substr(r,1)===i&&(e.openQuote?i===e.openQuote&&(e.openQuote=!1,o.ending=i):(e.openQuote=i,o.starting=i))}),o}_testComments(e,r){var o={};return(e.options.comments||[]).forEach(i=>{if(e.openComment){if(j(i)===j(e.openComment)){var n=j(i);this.$str.substr(r).startsWith(n)&&(e.openComment=!1,o.ending=n)}}else{var s=H(i);this.$str.substr(r).startsWith(s)&&(e.openComment=i,o.starting=s)}}),o}_testNesting(e,r){var o={};return(e.options.blocks||[]).forEach(i=>{var s=H(i);if(this.$str.substr(r).startsWith(s))e.nesting=e.nesting.concat([i]),o.starting=s;else if(e.nesting.length&&j(i)===j(j(e.nesting))){var n=j(i);this.$str.substr(r).startsWith(n)&&(e.nesting=e.nesting.slice(0,-1),o.ending=n)}}),e.maxDepth=Math.max(e.maxDepth,e.nesting.length),o}_testChars(e,r,o){for(var i=0;i<e.length;i++){var s=e[i];if(_(s)){var n=s(this.$str.substr(0,o),this.$str.substr(o),r.tokens.slice());if(n!==!1)return n}if(r.options.useRegex){var f=this.$str.substr(o).match(new RegExp("^"+s,r.options.useRegex!==!0?r.options.useRegex:""));if(f)return f[0]}if(!r.options.ci&&this.$str.substr(o,s.length)===s||r.options.ci&&this.$str.substr(o,s.length).toLowerCase()===s.toLowerCase())return s}return!1}_push(e,r,o="tokens",i=!1){var s=e.matches.length;if(A(e.tokens[s])&&(e.tokens[s]=""),o==="comments"){e.tokens[s].comments||(e.tokens[s]=new String(e.tokens[s]),e.tokens[s].comments=[]);var n=e.tokens[s].comments.length-(!e.tokens[s].comments.length||i?0:1);e.tokens[s].comments[n]=(e.tokens[s].comments[n]||"")+r}else{var f=e.tokens[s].comments;e.tokens[s]=e.tokens[s]+r}}split(e,r,o){return this.lex(r,o).tokens}match(e,r,o){return this.lex(r,o).matches}regParse(e,r){return this.lex(e,M({useRegex:!0},r||{}))}regSplit(e,r){return this.regParse(e,r).tokens}regMatch(e,r){return this.regParse(e,r).matches}};O.$blocks=[["(",")"],["[","]"],["{","}"]];O.$quotes=['"',"'","`"];O.$comments=[["/*","*/"],["//",`
1
+ (()=>{function g(t){return!Array.isArray(t)&&typeof t=="object"&&t}function T(t){return typeof t}function v(t,...e){globalThis.WebQitInternalsRegistry||(globalThis.WebQitInternalsRegistry=new Map);var r=globalThis.WebQitInternalsRegistry.get(t);if(!r){if(r=new Map,e[0]===!1)return r;globalThis.WebQitInternalsRegistry.set(t,r)}for(var o,i;o=e.shift();)if((i=r)&&!(r=r.get(o))){if(r=new Map,e[0]===!1)return r;i.set(o,r)}return r}function h(t){return Array.isArray(t)}function ge(t){return t===!0||t===!1}function te(t){return typeof t=="function"}function Ye(t){return te(t)&&/^class\s?/.test(Function.prototype.toString.call(t))}function Te(t){return t===null||t===""}function A(t){return arguments.length&&(t===void 0||typeof t>"u")}function d(t){return Array.isArray(t)||typeof t=="object"&&t||te(t)}function Ke(t){return Te(t)||A(t)||t===!1||t===0||d(t)&&!Object.keys(t).length}function _(t){return te(t)||t&&{}.toString.call(t)==="[object function]"}function U(t){return t instanceof Number||typeof t=="number"}function F(t){return U(t)||t!==!0&&t!==!1&&t!==null&&t!==""&&!isNaN(t*1)}function Se(t){return g(t)&&Object.getPrototypeOf(t)===Object.prototype}function z(t){return t instanceof String||typeof t=="string"&&t!==null}function ke(t){return!z(t)&&!A(t.length)}function H(t,e=1){var r=0;t.forEach(i=>{r++});var o=t.slice(t.length-r,e);return arguments.length>1?o:o[0]}function j(t,e=1){return arguments.length>1?H(t.slice().reverse(),e).reverse():H(t.slice().reverse())}function Ce(t,...e){return e.forEach(r=>{t.indexOf(r)<0&&t.push(r)}),t}function et(o,e){e=e||Object.prototype,e=e&&!h(e)?[e]:e;for(var r=[],o=o;o&&(!e||e.indexOf(o)<0)&&o.name!=="default";)r.push(o),o=o?Object.getPrototypeOf(o):null;return r}function tt(t,e){var r=[];return et(t,e).forEach(o=>{Ce(r,...Object.getOwnPropertyNames(o))}),r}function D(t,e,r=!1,o=!1,i=!1){var s=0,n=t.shift();if((F(n)||n===!0||n===!1)&&(s=n,n=t.shift()),!t.length)throw new Error("_merge() requires two or more array/objects.");return t.forEach((f,m)=>{!d(f)&&!_(f)||(r?tt(f):Object.getOwnPropertyNames(f)).forEach(u=>{if(!!e(u,n,f,m)){var p=n[u],a=f[u];if((h(p)&&h(a)||g(p)&&g(a))&&(s===!0||s>0))n[u]=h(p)&&h(a)?[]:{},D([F(s)?s-1:s,n[u],p,a],e,r,o,i);else if(h(n)&&h(f))o?n[u]=a:n.push(a);else try{i?Object.defineProperty(n,u,Object.getOwnPropertyDescriptor(f,u)):n[u]=f[u]}catch{}}})}),n}function q(t,e){var r=void 0;return d(t)&&Object.keys(t).forEach((o,i)=>{r!==!1&&(r=e(F(o)?parseFloat(o):o,t[o],i))}),r}function M(...t){return D(t,(e,r,o)=>!0,!1,!1,!1)}function ue(t,e,r=null,o=!1){return e.length>t.length?-1:(typeof r=="number"?o?t.slice(0,r+1+(r<0?t.length:0)):t.slice(r):t).reduce((i,s,n)=>{var[f,m,u]=i;if(!o&&f>-1)return[f,m,u];var p=u+1,a=s===e[p]?p===0?[n,0]:[m,p]:[-1,-1];return a[1]===e.length-1&&(a[1]=-1,a[0]>-1)?[a[0]].concat(a):[f].concat(a)},[-1,-1,-1])[0]+(o||typeof r!="number"?0:r>-1?r:t.length-r)}function me(t,e,r=null,o=!1){var i=ue(t,e,r,o);return i===-1?[]:t.slice(i+e.length)}function rt(t,e){return t.reduce((r,o,i)=>r||e(o,i),!1)}function y(t,e=!0){return h(t)?t:!e&&g(t)?[t]:t!==!1&&t!==0&&Ke(t)?[]:ke(t)?Array.prototype.slice.call(t):g(t)?Object.values(t):[t]}function Fe(t,e,r=null){return h(e)?t.filter(o=>r?e.filter(i=>r(o,i)).length:e.indexOf(o)===-1):[]}function G(t,e,r=null){return r||r!==!1&&t.dotSafe&&e.dotSafe?t.join(".")===e.join("."):t.length===e.length&&t.reduce((o,i,s)=>o&&i===e[s],!0)}var xt=function(t,e=1,r=!0){return!F(e)||e<=0||(!h(t)&&g(t)&&r&&(t=Object.values(t)),!h(t))?t:t.reduce((o,i)=>h(i)||g(i)&&r?o.concat(xt(h(i)?i:Object.values(i),e-1,r)):o.concat(i),[])},ot=xt;function _e(t,e,r=null){return h(e)?t.filter(o=>r?e.filter(i=>r(o,i)).length:e.indexOf(o)!==-1):[]}function ve(t,e,r=null){return r||r!==!1&&t.dotSafe&&e.dotSafe?(t.join(".")+".").startsWith(e.join(".")+"."):e.reduce((o,i,s)=>o&&i===t[s],!0)}function it(t){let e=(r,o,i)=>i.indexOf(r)===o;return t.filter(e)}function re(t){return(nt(t)?t:y(t).length?[t]:[]).reduce((e,r)=>e.concat([y(r)]),[]).map(e=>J.resolve(e))}var J=class extends Array{static resolve(e){return e.every(r=>!(r+"").includes("."))?new J().concat(e):e}get dotSafe(){return!0}};function nt(t){return y(t).reduce((e,r)=>e||h(r),!1)}function st(t){return t.filter(e=>e||e===0).length!==t.length}function Ot(t){return t.filter(e=>st(y(e))).length>0}var oe=class{constructor(e){this.target=e,this.fireables=[],this.currentlyFiring=[]}add(e){return this.fireables.push(e),e}remove(e){this.fireables=this.fireables.filter(r=>r!==e)}removeMatches(e){this.match(e).forEach(r=>{this.fireables=this.fireables.filter(o=>o!==r)})}match(e){return this.fireables.filter(r=>{var o=re(r.filter),i=y((r.params||{}).tags),s=re(e.filter),n=y((e.params||{}).tags);return(!e.originalHandler||r.handler===e.originalHandler)&&(!s.length||G(s,o))&&(!n.length||n.length===i.length&&_e(i,n).length===n.length)})}static _getFirebase(e,r,o=!0,i=this.__namespace){if(!d(r))throw new Error('Subject must be of type object; "'+T(r)+'" given!');var s=this;return i&&globalThis.WebQitObserverNamespaceRegistry.has(e+"-"+i)&&(s=globalThis.WebQitObserverNamespaceRegistry.get(e+"-"+i),e+="-"+i),!v(r,"firebases").has(e)&&o&&v(r,"firebases").set(e,new s(r)),v(r,"firebases").get(e)}static _namespace(e,r,o=null){if(e+="-"+r,arguments.length===2)return globalThis.WebQitObserverNamespaceRegistry.get(e);if(!(o.prototype instanceof this))throw new Error(`The implementation of the namespace ${this.name}.${r} must be a subclass of ${this.name}.`);globalThis.WebQitObserverNamespaceRegistry.set(e,o),o.__namespace=r}};globalThis.WebQitObserverNamespaceRegistry||(globalThis.WebQitObserverNamespaceRegistry=new Map);var ie=class{constructor(e,r){this.target=e,this.handler=r.handler,this.filter=r.filter,this.params=r.params}disconnect(){this.disconnected=!0}};var ye=class extends ie{fire(e,r,o){return this.disconnected||this.filter&&!_e(y(this.filter),[e.type]).length?r(...Array.prototype.slice.call(arguments,2)):this.handler(e,o,r)}};function ae(t,e,r=!0,o=!0,i=!1,s=!1){if(h(t)&&h(e)){var n=[],f=!0;return t.forEach(m=>{if(!!f){var u=!1;q(e,(p,a)=>{(!u||o&&d(m))&&(u=r(m,a),(h(u)&&!u.length||g(u)&&!Object.keys(u).length)&&(u=!1),d(u)&&o&&(m=u))}),d(u)?n.push(o?u:m):ge(u)?i&&!u||!i&&u?n.push(m):s&&(f=!1):n.push(u)}}),n}if(g(t)&&g(e)){var n={},f=!0;return Object.keys(t).forEach(p=>{if(!!f){var a=r(t[p],e[p]);(h(a)&&!a.length||g(a)&&!Object.keys(a).length)&&(a=!1),d(a)?n[p]=o?a:t[p]:ge(a)?i&&!a||!i&&a?n[p]=t[p]:s&&(f=!1):n[p]=a}}),n}}function Ae(t,e=[],r=!0){var o=0;return F(arguments[0])&&d(arguments[1])&&(o=arguments[0],t=arguments[1],e=arguments[2]||[]),D([o,{},t],(i,s,n)=>_(e)?e(i):h(e)&&e.length?e.indexOf(i)>-1:!0,!1,!1,r)}function je(t,e=[]){return D([{},t],(r,o,i)=>{if(!_(i[r]))return _(e)?e(r):h(e)&&e.length?e.indexOf(r)>-1:!0},!1,!1,!1)}var ft=function(t,e,r=!0,o=1){if(h(t)&&h(e)&&t.length!==e.length)return!r;if(g(t)&&g(e)){var i=Object.keys(t),s=Object.keys(e);if(!i.length&&!s.length)return Se(t)&&Se(e)?r:t===e===r;if(!ft(i,s))return!r}if(o>0&&(h(t)&&h(e)||g(t)&&g(e))){var n=ae(t,e,(f,m)=>ft(f,m,r,o-1),!1,!1,!0);return h(n)?n.length===t.length&&n.length===e.length:g(n)&&g(t)?Object.keys(n).length===Object.keys(t).length&&Object.keys(n).length===Object.keys(e).length:n}return _(r)?r(t,e):U(t)&&U(e)&&isNaN(t)&&isNaN(e)?r:t===e===r},ut=ft;var le=class{constructor(e,r){if(this.target=e,!r.type)throw new Error("Action type must be given in definition!");q(r,(o,i)=>{Object.defineProperty(this,o,{value:i,enumerable:!0})}),Object.seal(this)}};var E=class extends oe{add(e){return super.add(new ye(this.target,e))}fire(e,r=null){if(e instanceof le||(e=new le(this.target,e)),this.currentlyFiring.filter(s=>s.type===e.type&&s.name===e.name).length)return r?r():void 0;this.currentlyFiring.push(e);let o=(s,...n)=>{var f=this.fireables[s];return f?f.fire(e,(...m)=>o(s+1,...m),...n):r?r(...n):n[0]};var i=o(0);return this.currentlyFiring.pop(),i}static getFirebase(e,r=!0,o=null){return super._getFirebase("interceptor",...arguments)}static namespace(e,r=null){return super._namespace("interceptor",...arguments)}};function w(t){return v(t,!1).get(t)||t}function P(t,e,r={},o={}){if(!e||!d(e))throw new Error("Target must be of type object!");e=w(e);var i,s=function(n){return arguments.length?n:Reflect[t](e,...Object.values(r))};return(i=E.getFirebase(e,!1,o.namespace))?i.fire({type:t,...r},s):s()}function Ne(t,e,r,o={}){return P("apply",t,{thisArgument:e,argumentsList:r},o)}function De(t,e,r=null,o={}){return P("construct",t,arguments.length>2?{argumentsList:e,newTarget:r}:{argumentsList:e},o)}var W=class{constructor(e,r=!1){this._={},this._.target=e,this._.cancellable=r,this._.propagationStopped=!1,this._.defaultPrevented=!1,this._.promisesInstance=null,this._.promises=[]}get target(){return this._.target}get cancellable(){return this._.cancellable}stopPropagation(){this._.propagationStopped=!0}get propagationStopped(){return this._.propagationStopped}preventDefault(){this._.defaultPrevented=!0}get defaultPrevented(){return this._.defaultPrevented}waitUntil(e){e instanceof Promise&&(this._.promises.push(e),this._.promisesInstance=null)}get promises(){return!this._.promisesInstance&&this._.promises.length&&(this._.promisesInstance=Promise.all(this._.promises)),this._.promisesInstance}respondWith(e){var r,o=g(e)&&!A(e.propagationStopped)&&!A(e.defaultPrevented);e===!1||o&&e.propagationStopped?this.stopPropagation():e===!1||o&&e.defaultPrevented?this.preventDefault():(e instanceof Promise&&(r=e)||o&&(r=e.promises))&&this.waitUntil(r)}};var be=class extends ie{constructor(e,r){if(super(e,r),this.filters2D=re(this.filter),this.filtersIsOriginally2D=nt(this.filter),this.filtersIsDynamic=Ot(this.filters2D),this.filtersIsDynamic&&this.filters2D.length>1)throw new Error('Only one "Dynamic Filter" must be observed at a time! "'+this.filters2D.map(o=>"["+o.join(", ")+"]").join(", ")+'" have been bound together.')}fire(e){if(this.disconnected||this.params.type&&!rt(e,n=>this.params.type===n.type))return;let r=n=>!["set","def"].includes(n.type)||!this.params.diff||(_(this.params.diff)?this.params.diff(n.value,n.oldValue):n.value!==n.oldValue);var o=new W(this.target);if(this.filters2D.length){var i=e.filter(n=>this.filters2D.filter((f,m)=>{var u=f.slice();return this.filtersIsDynamic&&n.path.forEach((p,a)=>{u[a]=u[a]||u[a]===0?u[a]:p}),(!this.filtersIsDynamic||!st(u))&&r(n)&&(!this.params.subtree&&G(u,n.path)||this.params.suptree&&ve(u,n.path)&&(!F(this.params.suptree)||me(u,n.path).length<=this.params.suptree)||this.params.subtree&&n.path.length>=u.length&&ve(n.path,u)&&(!F(this.params.subtree)||me(n.path,u).length<=this.params.subtree))}).length);if(i.length)if(this.filtersIsOriginally2D||this.params.subtree){var s=i;g(this.filter)&&(s={...this.filter},i.forEach((n,f)=>{s[n.name]=n})),o.respondWith(this.handler(s,o))}else i.forEach((n,f)=>{o.respondWith(this.handler(n,o))})}else(this.params.subtree||e.filter(n=>G(n.path,[n.name])).length===e.length)&&e.filter(n=>r(n)).length&&o.respondWith(this.handler(e,o));return o}};var Z=class{constructor(e,r){if(this.target=e,r.originalSubject||(this.originalSubject=e),!("type"in r))throw new Error("Mutation type must be given in definition!");if(!("name"in r))throw new Error("Property name must be given in definition!");q(r,(o,i)=>{o==="path"&&(i=J.resolve(i)),Object.defineProperty(this,o,{value:i,enumerable:!0})}),this.path||Object.defineProperty(this,"path",{value:J.resolve([r.name]),enumerable:!0}),Object.seal(this)}};var x=class extends oe{constructor(e){super(e),this.buffers=[]}add(e){return super.add(new be(this.target,e))}fire(e,r){var o=new W(this.target,r);return e=y(e,!1).map(i=>i instanceof Z?i:new Z(this.target,i)),this.buffers.length?(j(this.buffers)(e),o):(this.currentlyFiring.filter(i=>e.filter(s=>i.type===s.type&&i.name===s.name).length).length,this.fireables.forEach(i=>{if(o.propagationStopped&&r)return o;o.respondWith(i.fire(e))}),o)}static getFirebase(e,r=!0,o=null){return super._getFirebase("observer",...arguments)}static namespace(e,r=null){return super._namespace("observer",...arguments)}};function $(t,e,r=null,o={}){if(t=r||t,!t||!d(t))throw new Error("Target must be of type object!");t=w(t);var i=y(e),s=i.map(n=>{var f,m=function(u){return arguments.length?u:v(t,"accessorizedProps").has(n)&&v(t,"accessorizedProps").get(n).touch(!0)?v(t,"accessorizedProps").get(n).get():r?Reflect.get(t,n,r):Reflect.get(t,n)};return(f=E.getFirebase(t,!0,o.namespace))?f.fire({type:"get",name:n,related:i,receiver:r},m):m()});return h(e)?s:s[0]}function Me(t,e,r=null,o={}){if(t=w(t),!t||!d(t))throw new Error('Observable subjects must be of type object; "'+T(t)+'" given!');if(_(e)&&(o=arguments.length>2?r:{},r=e,e=null),!_(r))throw new Error('Handler must be a function; "'+T(r)+'" given!');var i,s=x.getFirebase(t,!0,o.namespace),n={filter:e,handler:r,params:o};if((n.filter||n.params.subtree==="*"||n.params.subtree&&pe(t))&&X(t,n.filter,n.params.subtree,o.namespace),n.params.unique&&(i=s.match({filter:e,params:o})).length){if(n.params.unique!=="replace")return i[0];s.remove(i[0])}return s.add(n)}function Y(t,e,r,o=null,i={}){if(t!==r){var s;if(Me(r,(f,m)=>{if(s=x.getFirebase(t,!1,i.namespace)){var u=f.map(p=>{var a=p;do if(a.target===t)return;while(a=a.src);var l={};return q(p,(c,b)=>{c!=="target"&&c!=="name"&&c!=="path"&&c!=="src"&&(l[c]=b)}),l.name=e,l.path=[e].concat(p.path),l.originalSubject=p.originalSubject,l.src=p,new Z(t,l)}).filter(p=>p);if(u.length)return s.fire(u,m.cancellable)}},{subtree:!0,...i,unique:!0,tags:[at,e,t]}),g(o)&&(s=x.getFirebase(t,!1,i.namespace))){var n=M({name:e,type:"set",value:r,related:[e]},o);let f=s.fire(n,i.cancellable);if(i.eventTypeReturn)return f}}}var at={};function X(t,e=null,r=!1,o=null){if(!t||!d(t))throw new Error("Target must be of type object!");var i=x.getFirebase(t,!0,o);if(!(!i||i.build)){i.build=r;var s=re(e),n=!s.length||s.filter(m=>!m[0]&&m[0]!==0).length?Object.keys(t):s.map(m=>m[0]),f=s.length?s.map(m=>m.slice(1)).filter(m=>m.length):null;i.subBuild=f&&f.length?f:null,n.forEach(m=>{var u=$(t,m,null,{namespace:o});try{d(u)&&(Y(t,m,u,null,params),(i.subBuild&&pe(u)||(_isFunction(r)?r(u):r&&pe(u)))&&X(u,i.subBuild,r,o))}catch{}})}}var pe=t=>(t instanceof Object||t instanceof Array||t instanceof Function)&&(typeof window>"u"||t!==window);function $e(t,e,r=null,o={}){if(t=w(t),!t||!d(t))throw new Error('Observable subjects must be of type object; "'+T(t)+'" given!');if(_(e)&&(o=arguments.length>2?r:{},r=e,e=null),r&&!_(r))throw new Error('Handler must be a function; "'+T(r)+'" given!');var i;if(i=x.getFirebase(t,!1,o.namespace))return i.removeMatches({filter:e,originalHandler:r,params:o})}function K(t,e,r,o=null,i={}){$e(r,null,null,{...i,tags:[at,e,t]});var s;if(g(o)&&(s=x.getFirebase(t,!1,i.namespace))){var n=M({name:e,type:"del",oldValue:r,related:[e]},o);s.fire(n,i.cancellable)}}function k(t,e,r={}){return P("has",t,{name:e},r)}function Ie(t,e,r,o={}){e=r.receiver||e;var i=r.keysOrPayload,s=r.value;if(!e||!d(e))throw new Error("Target must be of type object!");g(i)&&(o=s||{},s=null),e=w(e);var n=E.getFirebase(e,!1,o.namespace),f=x.getFirebase(e,!1,o.namespace);let m=(c,b,C,de)=>{var dt="set",L;t&&(dt="defineProperty",L=b||{},b=L.value);var Ee=!1,Pe;k(e,c,o)&&(Ee=!0,Pe=$(e,c,r.receiver,o));var N={name:c,type:dt,value:b,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe},gt=function(_t){return arguments.length&&(L?L=_t:b=_t),L?v(e,"accessorizedProps",!1).has(c)&&!v(e,"accessorizedProps").get(c).restore()?!1:(Object.defineProperty(e,c,L),!0):v(e,"accessorizedProps",!1).has(c)?v(e,"accessorizedProps").get(c).set(b):(e[c]=b,!0)};if(n){var Qt=L?{type:"defineProperty",name:c,descriptor:L,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe}:{type:"set",name:c,value:b,receiver:r.receiver,related:C,detail:de,isUpdate:Ee,oldValue:Pe};N.success=n.fire(Qt,gt)}else N.success=gt();return N.success&&N.value!==N.oldValue&&(d(N.oldValue)&&K(e,c,N.oldValue,null,o),d(N.value)&&(Y(e,c,N.value,null,o),f&&(f.subBuild||f.build&&pe(N.value))&&X(N.value,f.subBuild,f.build,o.namespace))),N};var u,p=[];h(i)||(z(i)||U(i))&&(u=y(i))?p=u.map(c=>m(c,s,u,o.detail)):g(i)&&(u=Object.keys(i))&&(p=u.map(c=>m(c,i[c],u,o.detail)));var a=p.filter(c=>c.success!==!1),l;return f?(l=f.fire(a,o.cancellable),l.successCount=a.length):o.eventTypeReturn&&(l=new W(e)),o.eventTypeReturn?l:a.length>0}function qe(t,e,r=null,o={}){return Ie(!0,t,{keysOrPayload:e,value:r},o)}function We(t,e,r={}){if(!t||!d(t))throw new Error("Target must be of type object!");t=w(t);var o=y(e),i=o.map(m=>{var u;k(t,m,r)&&(u=$(t,m,null,r));var p={name:m,type:"deleteProperty",related:o,detail:r.detail,oldValue:u},a,l=function(c){return arguments.length?c:v(t,"accessorizedProps",!1).has(m)&&!v(t,"accessorizedProps").get(m).restore()?!1:(delete t[m],!0)};return(a=E.getFirebase(t,!1,r.namespace))?p.success=a.fire({type:"deleteProperty",name:m,oldValue:u,related:o},l):p.success=l(),p.success&&d(p.oldValue)&&K(t,m,p.oldValue,null,r),p}),s=i.filter(m=>m.success!==!1),n,f;return(n=x.getFirebase(t,!1,r.namespace))?(f=n.fire(s,r.cancellable),f.successCount=s.length):r.eventTypeReturn&&(f=new W(t)),r.eventTypeReturn?f:s.length>0}function Re(t,e,r={}){return P("getOwnPropertyDescriptor",t,{name:e},r)}function Qe(t,e={}){return P("getPrototypeOf",t,{},e)}function Ue(t,e={}){return P("isExtensible",t,{},e)}function ze(t,e={}){return P("ownKeys",t,{},e)}function Be(t,e={}){return P("preventExtensions",t,{},e)}function ce(t,e,r=null,o=null,i={}){return Ie(!1,t,arguments.length>3?{keysOrPayload:e,value:r,receiver:o}:{keysOrPayload:e,value:r},i)}function Ve(t,e,r={}){return P("setPrototypeOf",t,{prototype:e},r)}function Et(t,e=[],r={}){r=g(e)?e:r;var o=(arguments.length===1?Object.keys(t):y(e)).map(i=>{if(v(t,"accessorizedProps").has(i)&&v(t,"accessorizedProps").get(i).touch(!0))return!1;let s=()=>{for(var l,c=t;!l&&(c=Object.getPrototypeOf(c));)l=Object.getOwnPropertyDescriptor(c,i);return l};var n=Object.getOwnPropertyDescriptor(t,i),f,m;n||(f={writable:!0,enumerable:!(i in t),configurable:r.configurable!==!1});var u={...n||f};"value"in u&&delete u.value,"writable"in u&&delete u.writable,u.get=()=>{if(a.ongoingGets.length)return a.get();a.ongoingGets.push(1);var l=$(t,i,null,r);return a.ongoingGets.pop(),l};var p;u.set=l=>{if(a.ongoingSets.length)return a.set(l);a.ongoingSets.push(1);var c=ce(t,i,l,null,r);return a.ongoingSets.pop(),c};var a={ongoingGets:[],ongoingSets:[],get:function(){var l=n;return l||(m?l=f:l=s()||f),l.get?l.get.call(t):l.value},set:function(l){var c=n;return c||(m?c=f:(c=s())?"value"in c&&(c=f,m=!0):(c=f,m=!0)),c.set||c.get?c.set?c.set.call(t,l):!1:(c.value=l,!0)},restore:function(){try{return this.intact()&&(n||m?Object.defineProperty(t,i,n||f):delete t[i],v(t,"accessorizedProps").delete(i)),!0}catch{}return!1},intact:function(){return(Object.getOwnPropertyDescriptor(t,i)||{}).get===u.get},touch:function(l=!1){return this.intact()||(l?!this.restore():!1)}};try{return Object.defineProperty(t,i,u),v(t,"accessorizedProps").set(i,a),!0}catch{}return!1});return h(e)?o:o[0]}function Pt(t,e=[],r={}){r=g(e)?e:r;var o=(arguments.length===1?Object.keys(t):y(e)).map(i=>v(t,"accessorizedProps",!1).has(i)?v(t,"accessorizedProps").get(i).restore():!0);return h(e)?o:o[0]}function Tt(t,e={}){if(!d(t))throw new Error('Object must be of type target; "'+T(t)+'" given!');var r=new Proxy(t,{apply:(o,i,s)=>Ne(o,i,s,e),construct:(o,i,s=null)=>De(o,i,s,e),defineProperty:(o,i,s)=>qe(o,i,s,e),deleteProperty:(o,i)=>We(o,i,e),get:(o,i,s=null)=>{var n=$(o,i,s,e);return e.proxyAutoBinding!==!1&&_(n)&&!Ye(n)?n.bind(r):n},getOwnPropertyDescriptor:(o,i)=>Re(o,i,e),getPrototypeOf:o=>Qe(o,e),has:(o,i)=>k(o,i,e),isExtensible:o=>Ue(o,e),ownKeys:o=>ze(o,e),preventExtensions:o=>Be(o,e),set:(o,i,s,n=null)=>ce(o,i,s,n,e),setPrototypeOf:(o,i)=>Ve(o,i,e)});return v(r).set(r,t),r}function St(t,e,r={}){if(t=w(t),!d(t))throw new Error('Object must be of type target; "'+T(handler)+'" given!');var o={},i=!0;g(e)||(_(e)?e={"":e}:_(r)&&(e={[e]:r},r=arguments.length>3?arguments[3]:{}),i=!1);var s=E.getFirebase(t,!0,r.namespace);return Object.keys(e).forEach(n=>{if(!_(e[n]))throw new Error("Callback"+(n===null?"":" for "+n)+' must be a function; "'+T(e[n])+'" given!');var f={filter:n,handler:e[n],params:r},m;if(f.params.unique&&(m=s.match(f)).length){if(f.params.unique!=="replace")return m[0];s.remove(m[0])}i?o[n]=s.add(f):o=s.add(f)}),o}function Ct(t,e=null,r={}){if(t=w(t),!t||!d(t))throw new Error('Object must be of type target; "'+T(t)+'" given!');var o=E.getFirebase(t,!1,r.namespace);_isObject(e)||(_(e)?e={[null]:e}:_(r)&&(e={[e]:r},r=arguments.length>3?arguments[3]:{}),isOriginallyObj=!1),(o=E.getFirebase(t,!1,r.namespace))&&Object.keys(e).forEach(i=>{if(!_(e[i]))throw new Error("Callback"+(i===null?"":" for "+i)+' must be a function; "'+T(e[i])+'" given!');var s={filter:i,originalHandler:e[i],params:r};return o.removeMatches(s)})}function Ft(t,...e){var r=e.map(s=>{if(s=w(s),!d(s))throw new Error("Target must be of type object!");return{target:s,subjectCopy:h(s)?s.slice(0):Ae(s)}}),o=t(...e);let i=()=>{r.map(s=>{var n=Object.keys(s.subjectCopy),f=Object.keys(s.target),m=[],u=it(n.concat(f)).map(a=>{if(s.subjectCopy[a]!==s.target[a]){m.push(a);var l={name:a,related:m,buffered:!0};return f.includes(a)?(l.type="set",l.value=s.target[a],n.includes(a)&&(l.isUpdate=!0)):l.type="del",n.includes(a)&&(l.oldValue=s.subjectCopy[a]),d(s.subjectCopy[a])&&K(s.target,a,s.subjectCopy[a]),d(s.target[a])&&Y(s.target,a,s.target[a]),l}}).filter(a=>a),p;if(u.length&&(p=x.getFirebase(s.target,!1)))return p.fire(u)})};return o instanceof Promise?o.then(i):i(),o}var R={apply:Ne,construct:De,defineProperty:qe,deleteProperty:We,get:$,getOwnPropertyDescriptor:Re,getPrototypeOf:Qe,has:k,isExtensible:Ue,ownKeys:ze,preventExtensions:Be,set:ce,setPrototypeOf:Ve,accessorize:Et,unaccessorize:Pt,proxy:Tt,unproxy:w,observe:Me,unobserve:$e,intercept:St,unintercept:Ct,closure:Ft,build:X,link:Y,unlink:K,Observers:x,Interceptors:E};function Q(t){return!Array.isArray(t)&&typeof t=="object"&&t}function At(t){var e=typeof t.InstallTrigger<"u";if(e)return"firefox";var r=/constructor/i.test(t.HTMLElement)||function(u){return u.toString()==="[object SafariRemoteNotification]"}(!t.safari||typeof t.safari<"u"&&t.safari.pushNotification);if(r)return"safari";var o=!!t.chrome&&(!!t.chrome.webstore||!!t.chrome.runtime),i=o&&t.navigator.userAgent.indexOf("Edg")!=-1,s=!!t.opr&&!!t.opr.addons||!!t.opera||t.navigator.userAgent.indexOf(" OPR/")>=0,n=!!t.document.documentMode,f=!n&&!!t.StyleMedia,m=(o||s)&&!!t.CSS;return f?"edge":n?"ie":s?"opera":i?"ie-chromium":o?"chrome":"unknown"}function jt(t){var e=t.getComputedStyle(t.document.documentElement,""),r=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||e.Olink===""&&["","o"])[1],o=("WebKit|Moz|Ms|O".match(new RegExp("("+r+")","i"))||[])[1];return{api:o,prefix:r,css:"-"+r+"-"}}function B(){if(!(Q(this)&&this.window)&&typeof window>"u")throw new Error("A window context is required.");let t=Q(this)&&this.window?this.window:window;if(t.WebQit||(t.WebQit={}),!t.WebQit.window){let e,r;Object.defineProperty(t.WebQit,"window",{get:()=>t}),Object.defineProperty(t.WebQit,"vendor",{value:{getName:()=>(e||(e=At(t)),e),getPrefix:()=>(r||(r=jt(t)),r)}})}return t.WebQit}function Le(t){return typeof t=="function"}function I(t){return Array.isArray(t)||typeof t=="object"&&t||Le(t)}function Nt(t){return t instanceof Number||typeof t=="number"}function ne(t){return Nt(t)||t!==!0&&t!==!1&&t!==null&&t!==""&&!isNaN(t*1)}var xe=class{constructor(e,r=!0){this.window=e,this.async=r,this.readCallbacks=[],this.writeCallbacks=[],this._run()}_run(){this.window.requestAnimationFrame(()=>{this.readCallbacks.forEach((e,r)=>{e&&!e()&&(this.readCallbacks[r]=null)}),this.writeCallbacks.forEach((e,r)=>{e&&!e()&&(this.writeCallbacks[r]=null)}),this._run()})}onread(e,r=!1){if(r)return new Promise((o,i)=>{this.async===!1?e(o,i):this.readCallbacks.push(()=>{e(o,i)})});this.async===!1?e():this.readCallbacks.push(e)}onwrite(e,r=!1){if(r)return new Promise((o,i)=>{this.async===!1?e(o,i):this.writeCallbacks.push(()=>{e(o,i)})});this.async===!1?e():this.writeCallbacks.push(e)}cycle(e,r,o){this.onread(()=>{var i=e(o);if(i){var s=n=>{this.onwrite(()=>{var f=r(n,o);if(f){var m=u=>{this.cycle(e,r,u)};f instanceof Promise?f.then(m):m()}})};i instanceof Promise?i.then(s):s()}})}};function V(t){return t instanceof String||typeof t=="string"&&t!==null}function se(t){return Array.isArray(t)}function he(t){return arguments.length&&(t===void 0||typeof t>"u")}function Dt(t){return!V(t)&&!he(t.length)}function He(t){return t===null||t===""}function Mt(t){return He(t)||he(t)||t===!1||t===0||I(t)&&!Object.keys(t).length}function S(t,e=!0){return se(t)?t:!e&&Q(t)?[t]:t!==!1&&t!==0&&Mt(t)?[]:Dt(t)?Array.prototype.slice.call(t):Q(t)?Object.values(t):[t]}function Oe(t){let e=B.call(this);e.DOM.isDOMReady||e.window.document.readyState==="complete"?t(e.window):(e.window.domReadyCallbacks||(e.window.domReadyCallbacks=[],e.window.document.addEventListener("DOMContentLoaded",()=>{e.DOM.isDOMReady=!0,e.window.domReadyCallbacks.splice(0).forEach(r=>r(e.window))},!1)),e.window.domReadyCallbacks.push(t))}var we=class{constructor(e){this.window=e}onAdded(e,r,o={}){return o.on="added",this.onPresenceChange(e,(i,s,n,f,m)=>{r(i,s,n,f,m)},o)}onRemoved(e,r,o={}){return o.on="removed",this.onPresenceChange(e,(i,s,n,f,m)=>{r(i,s,n,f,m)},o)}onPresent(e,r,o={}){Oe.call(this.window,()=>{this.window.MutationObserver&&this.onAdded(e,(i,s)=>{i.forEach(n=>r(n,s))},o),V(e)?S(this.window.document.querySelectorAll(e)).forEach(i=>r(i,1)):e.parentNode&&r(e,1)})}onAbsent(e,r,o={}){Oe.call(this.window,()=>{this.window.MutationObserver&&onRemoved(e,(i,s)=>{i.forEach(n=>r(n,s))},o),V(e)?S(this.window.document.querySelectorAll(e)).length===0&&r(null,0):e.parentNode||r(e,0)})}onPresenceChange(e,r,o={}){e=S(e,!1);var i=(a,l)=>{if(l=l.filter(C=>C.matches),V(a)){var c=l.filter(C=>C.matches(a));if(o.observeIndirectMutation!==!1&&(c=l.reduce((C,de)=>C.concat(S(de.querySelectorAll(a))),c),c.length))return c}else{if(l.includes(a))return[a];if(o.observeIndirectMutation!==!1&&l.length){for(var b=a;b=b.parentNode;)if(l.includes(b))return[a]}}},s=(a,l)=>(l.$$searchCache||(l.$$searchCache=new Map),a.reduce((c,b)=>{var C;return l.$$searchCache.has(b)?C=l.$$searchCache.get(b):(C=i(b,l,V(b))||[],l.$$searchCache.set(b,C)),c.concat(C)},[])),n=new Set,f=new Set,m=(a,l,c)=>{l&&o.on==="removed"||!l&&o.on==="added"||(a=s(e,a)).length&&(o.maintainCallState?(a.forEach(b=>{l?(n.add(b),f.delete(b)):(n.delete(b),f.add(b))}),r(a,l,c,n,f)):r(a,l,c))},u=o.context||this.window.document.documentElement,p=this._observe(u,(a,l,c,b)=>{o.ignoreTransients||(m(a,0,!0),m(a.concat(l),1,!0),m(l,0,!0)),m(b,0),m(c,1)});return p}onAttrChange(e,r,o=[]){var i=new this.window.MutationObserver(r),s={attributes:!0,attributeOldValue:!0};return o&&(s.attributeFilter=o),i.observe(e,s),i}onTreeChange(e,r,o=!1){var i=new this.window.MutationObserver(r),s={childList:!0,subtree:o};return i.observe(e,s),i}onMutation(e,r,o){var i=new this.window.MutationObserver(r);return i.observe(e,o),i}_observe(e,r){if(!lt.has(e)){let i=new Set,s=new this.window.MutationObserver(n=>{if(!!i.size){var f=n.reduce((a,l)=>a.concat(S(l.addedNodes)),[]),m=n.reduce((a,l)=>a.concat(S(l.removedNodes)),[]),u=[],p=[];f=new Set(f),m=new Set(m),f.forEach(a=>{m.has(a)&&(m.delete(a),f.delete(a),a.isConnected?u.push(a):p.push(a))}),f=[...f],m=[...m],i.forEach(a=>a(u,p,f,m))}});s.observe(e,{childList:!0,subtree:!0}),lt.set(e,{callbacks:i,observer:s})}let o=lt.get(e);return o.callbacks.add(r),{disconnect(){o.callbacks.delete(r)},reconnect(){o.callbacks.add(r)}}}},lt=new Map;function $t(t){rr(t),or(t),ir(t)}function rr(t){t.CSS||(t.CSS={}),t.CSS.escape||(t.CSS.escape=e=>e.replace(/([\:@\~\$\&])/g,"\\$1"))}function or(t){"isConnected"in t.Node.prototype||Object.defineProperty(t.Node.prototype,"isConnected",{get:function(){return!this.ownerDocument||!(this.ownerDocument.compareDocumentPosition(this)&this.DOCUMENT_POSITION_DISCONNECTED)}})}function ir(t){t.Element.prototype.matches||(t.Element.prototype.matches=t.Element.prototype.matchesSelector||t.Element.prototype.mozMatchesSelector||t.Element.prototype.msMatchesSelector||t.Element.prototype.oMatchesSelector||t.Element.prototype.webkitMatchesSelector||function(e){for(var r=(this.document||this.ownerDocument).querySelectorAll(e),o=r.length;--o>=0&&r.item(o)!==this;);return o>-1})}function Ge(t,e=null,r=!1){let o=B.call(this);if(V(t)){var i;if(t.trim().startsWith("<")){var s=o.window.document.createElement("div");s.innerHTML=t,i=r?S(s.children):s.firstChild}else i=r?S(qt.call(this,t,e)):pt.call(this,t,e);return i}return t instanceof o.window.Element?r?[t]:t:r?S(t):t}function It(t,e=null){return Ge.call(this,t,e,!0)}function pt(t,e=null,r=!1){let o=B.call(this);e=e||o.window.document;var i,s=r?"querySelectorAll":"querySelector";try{i=e[s](t)}catch{try{i=e[s](t.replace(/\:is\(/g,":matches("))}catch{try{i=e[s](t.replace(/\:is\(/g,":-webkit-any("))}catch{try{i=e[s](t.replace(/\:is\(/g,":-moz-any("))}catch(u){throw u}}}}return i}function qt(t,e=null){return pt.call(this,t,e,!0)}function fe(t){return Le(t)||t&&{}.toString.call(t)==="[object function]"}function ee(t,e,r={},o={}){e=S(e).slice();for(var i=t;!he(i)&&!He(i)&&e.length;){var s=e.shift();if(!(r.get?r.get(i,s):I(i)?s in i:i[s])){o.exists=!1;return}i=r.get?r.get(i,s):i[s]}return o.exists=!0,i}function Je(t,e,r,o={},i={}){let s=(p,a,l)=>i.set?i.set(p,a,l):(ne(e[f])&&se(p)?p.push(l):p[a]=l,!0);e=S(e);for(var n=t,f=0;f<e.length;f++)if(f<e.length-1){if(!n||!I(n)&&!fe(n))return!1;var m=ee(n,e[f],i);if(!I(m)){if(i.buildTree===!1)return!1;m=fe(i.buildTree)?i.buildTree(f):ne(e[f+1])?[]:{};var u=s(n,e[f],m);if(!u)return!1}n=m}else return s(n,e[f],r)}function Wt(t,e,r=!1,o={}){e=S(e);var i=!1;do{var s=e.pop(),s=s===""?0:s,n=t;e.length&&(n=ee(t,e,{},o)),(I(n)||fe(n))&&(o.has?o.has(n,s):s in n)&&(o.deleteProperty?i=o.deleteProperty(n,s):o.del?i=o.del(n,s):(delete n[s],i=!0))}while(i&&r&&e.length&&(I(n)||fe(n))&&!(o.keys?o.keys(n):Object.keys(n)).length);return i}function ct(t,e,r={}){var o={};return ee(t,e,r,o),o.exists}function ht(t,e=!1){let r=B.call(this);var o={};return!(o.el=r.window.document.head.querySelector('meta[name="oohtml"]'))&&e&&(o.el=r.window.document.createElement("meta"),o.el.setAttribute("name",t),r.window.document.head.append(o.el)),o.el&&(o.vars=(o.el.getAttribute("content")||"").split(";").filter(i=>i).reduce((i,s)=>{var n=s.split("=").map(f=>f.trim());return Je(i,n[0].split("."),n[1]==="true"?!0:n[1]==="false"?!1:ne(n[1])?parseInt(n[1]):n[1]),i},{})),o.get=function(i){return ee(this.vars,i.split("."))},o.set=function(i,s=null,n=!1){var f=Q(i)?i:{[i]:s===!0?"true":s};if(n=arguments.length<3?s:n,Object.keys(f).forEach(m=>{if(f[m]===!1)Wt(this.vars,m.split("."));else if(Q(f[m]))Object.keys(f[m]).forEach(p=>{var a=(m+"."+p).split(".");(!n||!ct(this.vars,a))&&Je(this.vars,a,f[m][p])});else{var u=m.split(".");(!n||!ct(this.vars,u))&&Je(this.vars,u,f[m])}}),e){let m=(u,p)=>Object.keys(p).reduce((a,l)=>{var c=(u?u+".":"")+l;return Q(p[l])?a.push(...m(c,p[l])):a.push(c+"="+p[l]),a},[]);this.el.setAttribute("content",m("",this.vars).join(";"))}return!0},o.defaults=function(i,s=null){return this.set(i,s,!0)},o}function Ze(){let t=B.call(this);return t.DOM||(t.DOM={},$t(t.window),t.DOM.reflow=new xe(t.window),t.DOM.mutations=new we(t.window),t.DOM.meta=ht.bind(t.window),t.DOM.query=Ge.bind(t.window),t.DOM.queryAll=It.bind(t.window),t.DOM.ready=Oe.bind(t.window)),t}var O=class{static lex(e,r,o={}){if(!z(e=e+""))throw new Error("Argument1 must be a string!");var i=u=>({delims:u.delims.slice(),options:je(u.options),nesting:u.nesting.slice(),maxDepth:u.maxDepth,comments:u.comments.slice(),tokens:u.tokens.slice(),matches:u.matches.slice(),matchesi:je(u.matchesi)});if(O.$cache[e]&&o.cache!==!1)for(var s=0;s<O.$cache[e].length;s++){var n=O.$cache[e][s];if(ut(n.delims,r))return i(n)}var f=new O(e,o),m=f.lex(r);return o.cache!==!1&&(O.$cache[e]=O.$cache[e]||[],O.$cache[e].push(m)),i(m)}static split(e,r,o){return O.lex(e,r,o).tokens}static match(e,r,o){return O.lex(e,r,o).matches}constructor(e,r){if(!z(e))throw new Error("Lexer requires the first argument to be a string.");this.$str=e,this.$options=r||{},this.$options.blocks||(this.$options.blocks=O.$blocks),this.$options.quotes||(this.$options.quotes=O.$quotes),this.$options.comments||(this.$options.comments=O.$comments)}lex(e,r){for(var o={delims:y(e),options:M(!0,{},this.$options,r||{}),nesting:[],maxDepth:0,comments:[],tokens:[],matches:[],matchesi:{}},i=0;typeof i=="number";)i=this._evalCharsAt(o,i);if(o.nesting.length)throw new Error("Error parsing the string: "+this.$str+". Unterminated blocks: "+ot(o.nesting).join(", "));return o}_evalCharsAt(e,r){if(!(r>=this.$str.length)){var o=1,i={},s={},n={};if(e.openComment||(s=this._testQuotes(e,r)),e.openQuote||(i=this._testComments(e,r)),e.openComment||i.ending)if(!e.nesting.length&&!n.ending){var f=i.starting||i.ending||this.$str[r];o=f.length,this._push(e,f,"comments",i.starting)}else this._push(e,this.$str[r]);else if(e.openQuote||s.ending)this._push(e,this.$str[r]);else{if(e.options.limit&&e.matches.length===e.options.limit)return this._push(e,this.$str[r]),r+1;n=this._testNesting(e,r);var n=this._testNesting(e,r),m=this._testChars(e.options.stopChars||[],e,r);if(!e.nesting.length&&m!==!1){e.options.stopChar=m,e.options.stopCharForward=this.$str.substr(r);return}if(!e.delims.length)e.nesting.length===2&&n.starting?(e.matches.push(null),this._push(e,n.starting),o=n.starting.length):!e.nesting.length&&n.ending?(this._push(e,n.ending),o=n.ending.length,e.matches.push(null)):this._push(e,this.$str[r]);else if(!e.nesting.length&&!n.ending){this._push(e,"");var u=this._testChars(e.delims,e,r);if(u!==!1&&(e.matches.push(u),e.matchesi[r]=u,o=u.length||1,!e.options.preserveDelims)){var p=r+(u.length||1);return p===this.$str.length&&this._push(e,""),p}this._push(e,u||this.$str[r])}else{var f=n.starting||n.ending||this.$str[r];o=f.length,this._push(e,f)}}return r+o}}_testQuotes(e,r){var o={};return(e.options.quotes||[]).forEach(i=>{this.$str.substr(r,1)===i&&(e.openQuote?i===e.openQuote&&(e.openQuote=!1,o.ending=i):(e.openQuote=i,o.starting=i))}),o}_testComments(e,r){var o={};return(e.options.comments||[]).forEach(i=>{if(e.openComment){if(j(i)===j(e.openComment)){var n=j(i);this.$str.substr(r).startsWith(n)&&(e.openComment=!1,o.ending=n)}}else{var s=H(i);this.$str.substr(r).startsWith(s)&&(e.openComment=i,o.starting=s)}}),o}_testNesting(e,r){var o={};return(e.options.blocks||[]).forEach(i=>{var s=H(i);if(this.$str.substr(r).startsWith(s))e.nesting=e.nesting.concat([i]),o.starting=s;else if(e.nesting.length&&j(i)===j(j(e.nesting))){var n=j(i);this.$str.substr(r).startsWith(n)&&(e.nesting=e.nesting.slice(0,-1),o.ending=n)}}),e.maxDepth=Math.max(e.maxDepth,e.nesting.length),o}_testChars(e,r,o){for(var i=0;i<e.length;i++){var s=e[i];if(_(s)){var n=s(this.$str.substr(0,o),this.$str.substr(o),r.tokens.slice());if(n!==!1)return n}if(r.options.useRegex){var f=this.$str.substr(o).match(new RegExp("^"+s,r.options.useRegex!==!0?r.options.useRegex:""));if(f)return f[0]}if(!r.options.ci&&this.$str.substr(o,s.length)===s||r.options.ci&&this.$str.substr(o,s.length).toLowerCase()===s.toLowerCase())return s}return!1}_push(e,r,o="tokens",i=!1){var s=e.matches.length;if(A(e.tokens[s])&&(e.tokens[s]=""),o==="comments"){e.tokens[s].comments||(e.tokens[s]=new String(e.tokens[s]),e.tokens[s].comments=[]);var n=e.tokens[s].comments.length-(!e.tokens[s].comments.length||i?0:1);e.tokens[s].comments[n]=(e.tokens[s].comments[n]||"")+r}else{var f=e.tokens[s].comments;e.tokens[s]=e.tokens[s]+r}}split(e,r,o){return this.lex(r,o).tokens}match(e,r,o){return this.lex(r,o).matches}regParse(e,r){return this.lex(e,M({useRegex:!0},r||{}))}regSplit(e,r){return this.regParse(e,r).tokens}regMatch(e,r){return this.regParse(e,r).matches}};O.$blocks=[["(",")"],["[","]"],["{","}"]];O.$quotes=['"',"'","`"];O.$comments=[["/*","*/"],["//",`
2
2
  `]];O.$cache=Object.create(null);function Rt(t,e={}){let r=Ze.call(this);return r.OOHTML||(r.OOHTML={}),r.OOHTML.meta||(r.OOHTML.meta=r.DOM.meta("oohtml",!0)),r.OOHTML.meta.defaults(M(3,t,e)),r.OOHTML.meta}function Xe(t={}){let e=Ze.call(this);if(t.onDomReady){e.DOM.ready(()=>{Xe.call(this,{...t,onDomReady:!1})});return}let r=e.window,o=e.window.document,i=Rt.call(this,{api:{state:"state",setState:"setState",clearState:"clearState"}},t.params),s=function(n,f=null){if(!v(n,"oohtml").has("state")||f){let m=f||Object.create(null),u=v(n,"oohtml").get("state");if(v(n,"oohtml").set("state",m),u&&R.unlink&&R.unlink(n,i.get("api.state"),u),R.link){let p=f?{isUpdate:!!u,oldValue:u}:null;R.link(n,i.get("api.state"),m,p)}}return v(n,"oohtml").get("state")};if(i.get("api.state")in r.Element.prototype)throw new Error('The "Element" class already has a "'+i.get("api.state")+'" property!');if(Object.defineProperty(r.Element.prototype,i.get("api.state"),{get:function(){return R.proxy(s(this))}}),i.get("api.setState")in r.Element.prototype)throw new Error('The "Element" class already has a "'+i.get("api.setState")+'" property!');if(Object.defineProperty(r.Element.prototype,i.get("api.setState"),{value:function(n,f={}){if(!f.update)s(this,n);else{var m=s(this);if(f.update!=="merge"){var u=Fe(Object.keys(m),Object.keys(n));R.deleteProperty(m,u)}R.set(m,n)}}}),i.get("api.clearState")in r.Element.prototype)throw new Error('The "Element" class already has a "'+i.get("api.clearState")+'" property!');if(Object.defineProperty(r.Element.prototype,i.get("api.clearState"),{value:function(){s(this,{})}}),i.get("api.state")in o)throw new Error('The "document" object already has a "'+i.get("api.state")+'" property!');if(Object.defineProperty(o,i.get("api.state"),{get:function(){return R.proxy(s(o))}}),i.get("api.setState")in o)throw new Error('The "document" object already has a "'+i.get("api.setState")+'" property!');if(Object.defineProperty(o,i.get("api.setState"),{value:function(n,f={}){if(!f.update)s(o,n);else{var m=s(o);if(f.update!=="merge"){var u=Fe(Object.keys(m),Object.keys(n));R.deleteProperty(m,u)}R.set(m,n)}}}),i.get("api.clearState")in o)throw new Error('The "document" object already has a "'+i.get("api.clearState")+'" property!');Object.defineProperty(o,i.get("api.clearState"),{value:function(){s(o,{})}})}Xe.call(window);})();
3
3
  //# sourceMappingURL=state-api.js.map